From 2a4c0a5b7c220ba4b1de2fe29a3d2051b660a5f8 Mon Sep 17 00:00:00 2001 From: mlisnic Date: Fri, 6 Sep 2024 23:03:42 +0000 Subject: [PATCH] deploy: b3e3fd5167c5769173b338ade971e07d1f86e993 --- .../{index-Aw5fbeSx.js => index-Xl2hxeGS.js} | 482 +++++++++--------- index.html | 2 +- 2 files changed, 242 insertions(+), 242 deletions(-) rename assets/{index-Aw5fbeSx.js => index-Xl2hxeGS.js} (82%) diff --git a/assets/index-Aw5fbeSx.js b/assets/index-Xl2hxeGS.js similarity index 82% rename from assets/index-Aw5fbeSx.js rename to assets/index-Xl2hxeGS.js index 2595d43ee..bc3bb6a3d 100644 --- a/assets/index-Aw5fbeSx.js +++ b/assets/index-Xl2hxeGS.js @@ -6,7 +6,7 @@ var qhe=Object.defineProperty;var Ghe=(e,t,n)=>t in e?qhe(e,t,{enumerable:!0,con * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var C_=Symbol.for("react.element"),Qhe=Symbol.for("react.portal"),Xhe=Symbol.for("react.fragment"),Jhe=Symbol.for("react.strict_mode"),Zhe=Symbol.for("react.profiler"),epe=Symbol.for("react.provider"),tpe=Symbol.for("react.context"),npe=Symbol.for("react.forward_ref"),rpe=Symbol.for("react.suspense"),ipe=Symbol.for("react.memo"),spe=Symbol.for("react.lazy"),l5=Symbol.iterator;function ope(e){return e===null||typeof e!="object"?null:(e=l5&&e[l5]||e["@@iterator"],typeof e=="function"?e:null)}var Bq={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},jq=Object.assign,Uq={};function pg(e,t,n){this.props=e,this.context=t,this.refs=Uq,this.updater=n||Bq}pg.prototype.isReactComponent={};pg.prototype.setState=function(e,t){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")};pg.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function Vq(){}Vq.prototype=pg.prototype;function yD(e,t,n){this.props=e,this.context=t,this.refs=Uq,this.updater=n||Bq}var vD=yD.prototype=new Vq;vD.constructor=yD;jq(vD,pg.prototype);vD.isPureReactComponent=!0;var c5=Array.isArray,zq=Object.prototype.hasOwnProperty,_D={current:null},Hq={key:!0,ref:!0,__self:!0,__source:!0};function Wq(e,t,n){var r,i={},s=null,o=null;if(t!=null)for(r in t.ref!==void 0&&(o=t.ref),t.key!==void 0&&(s=""+t.key),t)zq.call(t,r)&&!Hq.hasOwnProperty(r)&&(i[r]=t[r]);var a=arguments.length-2;if(a===1)i.children=n;else if(1t in e?qhe(e,t,{enumerable:!0,con * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var fpe=w,dpe=Symbol.for("react.element"),hpe=Symbol.for("react.fragment"),ppe=Object.prototype.hasOwnProperty,mpe=fpe.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,gpe={key:!0,ref:!0,__self:!0,__source:!0};function qq(e,t,n){var r,i={},s=null,o=null;n!==void 0&&(s=""+n),t.key!==void 0&&(s=""+t.key),t.ref!==void 0&&(o=t.ref);for(r in t)ppe.call(t,r)&&!gpe.hasOwnProperty(r)&&(i[r]=t[r]);if(e&&e.defaultProps)for(r in t=e.defaultProps,t)i[r]===void 0&&(i[r]=t[r]);return{$$typeof:dpe,type:e,key:s,ref:o,props:i,_owner:mpe.current}}tx.Fragment=hpe;tx.jsx=qq;tx.jsxs=qq;Mq.exports=tx;var C=Mq.exports,U2={},Gq={exports:{}},Do={},Yq={exports:{}},Kq={};/** + */var fpe=w,dpe=Symbol.for("react.element"),hpe=Symbol.for("react.fragment"),ppe=Object.prototype.hasOwnProperty,mpe=fpe.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,gpe={key:!0,ref:!0,__self:!0,__source:!0};function qq(e,t,n){var r,i={},s=null,o=null;n!==void 0&&(s=""+n),t.key!==void 0&&(s=""+t.key),t.ref!==void 0&&(o=t.ref);for(r in t)ppe.call(t,r)&&!gpe.hasOwnProperty(r)&&(i[r]=t[r]);if(e&&e.defaultProps)for(r in t=e.defaultProps,t)i[r]===void 0&&(i[r]=t[r]);return{$$typeof:dpe,type:e,key:s,ref:o,props:i,_owner:mpe.current}}tx.Fragment=hpe;tx.jsx=qq;tx.jsxs=qq;Mq.exports=tx;var C=Mq.exports,j2={},Gq={exports:{}},Do={},Yq={exports:{}},Kq={};/** * @license React * scheduler.production.min.js * @@ -30,14 +30,14 @@ var qhe=Object.defineProperty;var Ghe=(e,t,n)=>t in e?qhe(e,t,{enumerable:!0,con * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var Qq=w,Ao=ype;function Re(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),V2=Object.prototype.hasOwnProperty,vpe=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,d5={},h5={};function _pe(e){return V2.call(h5,e)?!0:V2.call(d5,e)?!1:vpe.test(e)?h5[e]=!0:(d5[e]=!0,!1)}function bpe(e,t,n,r){if(n!==null&&n.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return r?!1:n!==null?!n.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function wpe(e,t,n,r){if(t===null||typeof t>"u"||bpe(e,t,n,r))return!0;if(r)return!1;if(n!==null)switch(n.type){case 3:return!t;case 4:return t===!1;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}function Ss(e,t,n,r,i,s,o){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=r,this.attributeNamespace=i,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=s,this.removeEmptyString=o}var Fi={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){Fi[e]=new Ss(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];Fi[t]=new Ss(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){Fi[e]=new Ss(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){Fi[e]=new Ss(e,2,!1,e,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){Fi[e]=new Ss(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){Fi[e]=new Ss(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){Fi[e]=new Ss(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){Fi[e]=new Ss(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){Fi[e]=new Ss(e,5,!1,e.toLowerCase(),null,!1,!1)});var wD=/[\-:]([a-z])/g;function ED(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var t=e.replace(wD,ED);Fi[t]=new Ss(t,1,!1,e,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(wD,ED);Fi[t]=new Ss(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(wD,ED);Fi[t]=new Ss(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){Fi[e]=new Ss(e,1,!1,e.toLowerCase(),null,!1,!1)});Fi.xlinkHref=new Ss("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){Fi[e]=new Ss(e,1,!1,e.toLowerCase(),null,!0,!0)});function SD(e,t,n,r){var i=Fi.hasOwnProperty(t)?Fi[t]:null;(i!==null?i.type!==0:r||!(2"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),U2=Object.prototype.hasOwnProperty,vpe=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,f5={},d5={};function _pe(e){return U2.call(d5,e)?!0:U2.call(f5,e)?!1:vpe.test(e)?d5[e]=!0:(f5[e]=!0,!1)}function bpe(e,t,n,r){if(n!==null&&n.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return r?!1:n!==null?!n.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function wpe(e,t,n,r){if(t===null||typeof t>"u"||bpe(e,t,n,r))return!0;if(r)return!1;if(n!==null)switch(n.type){case 3:return!t;case 4:return t===!1;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}function Ss(e,t,n,r,i,s,o){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=r,this.attributeNamespace=i,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=s,this.removeEmptyString=o}var Fi={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){Fi[e]=new Ss(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];Fi[t]=new Ss(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){Fi[e]=new Ss(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){Fi[e]=new Ss(e,2,!1,e,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){Fi[e]=new Ss(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){Fi[e]=new Ss(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){Fi[e]=new Ss(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){Fi[e]=new Ss(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){Fi[e]=new Ss(e,5,!1,e.toLowerCase(),null,!1,!1)});var bD=/[\-:]([a-z])/g;function wD(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var t=e.replace(bD,wD);Fi[t]=new Ss(t,1,!1,e,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(bD,wD);Fi[t]=new Ss(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(bD,wD);Fi[t]=new Ss(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){Fi[e]=new Ss(e,1,!1,e.toLowerCase(),null,!1,!1)});Fi.xlinkHref=new Ss("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){Fi[e]=new Ss(e,1,!1,e.toLowerCase(),null,!0,!0)});function ED(e,t,n,r){var i=Fi.hasOwnProperty(t)?Fi[t]:null;(i!==null?i.type!==0:r||!(2a||i[o]!==s[a]){var u=` -`+i[o].replace(" at new "," at ");return e.displayName&&u.includes("")&&(u=u.replace("",e.displayName)),u}while(1<=o&&0<=a);break}}}finally{tP=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?z0(e):""}function Epe(e){switch(e.tag){case 5:return z0(e.type);case 16:return z0("Lazy");case 13:return z0("Suspense");case 19:return z0("SuspenseList");case 0:case 2:case 15:return e=nP(e.type,!1),e;case 11:return e=nP(e.type.render,!1),e;case 1:return e=nP(e.type,!0),e;default:return""}}function q2(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 Ep:return"Fragment";case wp:return"Portal";case z2:return"Profiler";case TD:return"StrictMode";case H2:return"Suspense";case W2:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case Zq:return(e.displayName||"Context")+".Consumer";case Jq:return(e._context.displayName||"Context")+".Provider";case ID:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case xD:return t=e.displayName||null,t!==null?t:q2(e.type)||"Memo";case kc:t=e._payload,e=e._init;try{return q2(e(t))}catch{}}return null}function Spe(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 q2(t);case 8:return t===TD?"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 Sf(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function tG(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function Tpe(e){var t=tG(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 i=n.get,s=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(o){r=""+o,s.call(this,o)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(o){r=""+o},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function j1(e){e._valueTracker||(e._valueTracker=Tpe(e))}function nG(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=tG(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function oE(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 G2(e,t){var n=t.checked;return yr({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function m5(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=Sf(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 rG(e,t){t=t.checked,t!=null&&SD(e,"checked",t,!1)}function Y2(e,t){rG(e,t);var n=Sf(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")?K2(e,t.type,n):t.hasOwnProperty("defaultValue")&&K2(e,t.type,Sf(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function g5(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 K2(e,t,n){(t!=="number"||oE(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var H0=Array.isArray;function qp(e,t,n,r){if(e=e.options,t){t={};for(var i=0;i"+t.valueOf().toString()+"",t=U1.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function tv(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var cy={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},Ipe=["Webkit","ms","Moz","O"];Object.keys(cy).forEach(function(e){Ipe.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),cy[t]=cy[e]})});function aG(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||cy.hasOwnProperty(e)&&cy[e]?(""+t).trim():t+"px"}function uG(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,i=aG(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,i):e[n]=i}}var xpe=yr({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 J2(e,t){if(t){if(xpe[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(Re(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(Re(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(Re(61))}if(t.style!=null&&typeof t.style!="object")throw Error(Re(62))}}function Z2(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 eR=null;function CD(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var tR=null,Gp=null,Yp=null;function _5(e){if(e=O_(e)){if(typeof tR!="function")throw Error(Re(280));var t=e.stateNode;t&&(t=ox(t),tR(e.stateNode,e.type,t))}}function lG(e){Gp?Yp?Yp.push(e):Yp=[e]:Gp=e}function cG(){if(Gp){var e=Gp,t=Yp;if(Yp=Gp=null,_5(e),t)for(e=0;e>>=0,e===0?32:31-(Mpe(e)/Fpe|0)|0}var V1=64,z1=4194304;function W0(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 cE(e,t){var n=e.pendingLanes;if(n===0)return 0;var r=0,i=e.suspendedLanes,s=e.pingedLanes,o=n&268435455;if(o!==0){var a=o&~i;a!==0?r=W0(a):(s&=o,s!==0&&(r=W0(s)))}else o=n&~i,o!==0?r=W0(o):s!==0&&(r=W0(s));if(r===0)return 0;if(t!==0&&t!==r&&!(t&i)&&(i=r&-r,s=t&-t,i>=s||i===16&&(s&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 A_(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-ja(t),e[t]=n}function Vpe(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=dy),A5=" ",P5=!1;function OG(e,t){switch(e){case"keyup":return gme.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function RG(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var Sp=!1;function vme(e,t){switch(e){case"compositionend":return RG(t);case"keypress":return t.which!==32?null:(P5=!0,A5);case"textInput":return e=t.data,e===A5&&P5?null:e;default:return null}}function _me(e,t){if(Sp)return e==="compositionend"||!$D&&OG(e,t)?(e=AG(),mw=ND=qc=null,Sp=!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=k5(n)}}function $G(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?$G(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function LG(){for(var e=window,t=oE();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=oE(e.document)}return t}function LD(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 Ame(e){var t=LG(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&$G(n.ownerDocument.documentElement,n)){if(r!==null&&LD(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 i=n.textContent.length,s=Math.min(r.start,i);r=r.end===void 0?s:Math.min(r.end,i),!e.extend&&s>r&&(i=r,r=s,s=i),i=D5(n,s);var o=D5(n,r);i&&o&&(e.rangeCount!==1||e.anchorNode!==i.node||e.anchorOffset!==i.offset||e.focusNode!==o.node||e.focusOffset!==o.offset)&&(t=t.createRange(),t.setStart(i.node,i.offset),e.removeAllRanges(),s>r?(e.addRange(t),e.extend(o.node,o.offset)):(t.setEnd(o.node,o.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,Tp=null,aR=null,py=null,uR=!1;function $5(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;uR||Tp==null||Tp!==oE(r)||(r=Tp,"selectionStart"in r&&LD(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}),py&&av(py,r)||(py=r,r=hE(aR,"onSelect"),0Cp||(e.current=pR[Cp],pR[Cp]=null,Cp--)}function Xn(e,t){Cp++,pR[Cp]=e.current,e.current=t}var Tf={},os=Gf(Tf),Ks=Gf(!1),rh=Tf;function xm(e,t){var n=e.type.contextTypes;if(!n)return Tf;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var i={},s;for(s in n)i[s]=t[s];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=i),i}function Qs(e){return e=e.childContextTypes,e!=null}function mE(){ir(Ks),ir(os)}function V5(e,t,n){if(os.current!==Tf)throw Error(Re(168));Xn(os,t),Xn(Ks,n)}function WG(e,t,n){var r=e.stateNode;if(t=t.childContextTypes,typeof r.getChildContext!="function")return n;r=r.getChildContext();for(var i in r)if(!(i in t))throw Error(Re(108,Spe(e)||"Unknown",i));return yr({},n,r)}function gE(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||Tf,rh=os.current,Xn(os,e),Xn(Ks,Ks.current),!0}function z5(e,t,n){var r=e.stateNode;if(!r)throw Error(Re(169));n?(e=WG(e,t,rh),r.__reactInternalMemoizedMergedChildContext=e,ir(Ks),ir(os),Xn(os,e)):ir(Ks),Xn(Ks,n)}var El=null,ax=!1,gP=!1;function qG(e){El===null?El=[e]:El.push(e)}function jme(e){ax=!0,qG(e)}function Yf(){if(!gP&&El!==null){gP=!0;var e=0,t=Fn;try{var n=El;for(Fn=1;e>=o,i-=o,Pl=1<<32-ja(t)+i|n<A?(R=I,I=null):R=I.sibling;var F=d(g,I,b[A],S);if(F===null){I===null&&(I=R);break}e&&I&&F.alternate===null&&t(g,I),v=s(F,v,A),E===null?T=F:E.sibling=F,E=F,I=R}if(A===b.length)return n(g,I),dr&&hd(g,A),T;if(I===null){for(;AA?(R=I,I=null):R=I.sibling;var L=d(g,I,F.value,S);if(L===null){I===null&&(I=R);break}e&&I&&L.alternate===null&&t(g,I),v=s(L,v,A),E===null?T=L:E.sibling=L,E=L,I=R}if(F.done)return n(g,I),dr&&hd(g,A),T;if(I===null){for(;!F.done;A++,F=b.next())F=f(g,F.value,S),F!==null&&(v=s(F,v,A),E===null?T=F:E.sibling=F,E=F);return dr&&hd(g,A),T}for(I=r(g,I);!F.done;A++,F=b.next())F=h(I,g,A,F.value,S),F!==null&&(e&&F.alternate!==null&&I.delete(F.key===null?A:F.key),v=s(F,v,A),E===null?T=F:E.sibling=F,E=F);return e&&I.forEach(function(B){return t(g,B)}),dr&&hd(g,A),T}function y(g,v,b,S){if(typeof b=="object"&&b!==null&&b.type===Ep&&b.key===null&&(b=b.props.children),typeof b=="object"&&b!==null){switch(b.$$typeof){case B1:e:{for(var T=b.key,E=v;E!==null;){if(E.key===T){if(T=b.type,T===Ep){if(E.tag===7){n(g,E.sibling),v=i(E,b.props.children),v.return=g,g=v;break e}}else if(E.elementType===T||typeof T=="object"&&T!==null&&T.$$typeof===kc&&Q5(T)===E.type){n(g,E.sibling),v=i(E,b.props),v.ref=c0(g,E,b),v.return=g,g=v;break e}n(g,E);break}else t(g,E);E=E.sibling}b.type===Ep?(v=Qd(b.props.children,g.mode,S,b.key),v.return=g,g=v):(S=Sw(b.type,b.key,b.props,null,g.mode,S),S.ref=c0(g,v,b),S.return=g,g=S)}return o(g);case wp:e:{for(E=b.key;v!==null;){if(v.key===E)if(v.tag===4&&v.stateNode.containerInfo===b.containerInfo&&v.stateNode.implementation===b.implementation){n(g,v.sibling),v=i(v,b.children||[]),v.return=g,g=v;break e}else{n(g,v);break}else t(g,v);v=v.sibling}v=TP(b,g.mode,S),v.return=g,g=v}return o(g);case kc:return E=b._init,y(g,v,E(b._payload),S)}if(H0(b))return p(g,v,b,S);if(s0(b))return m(g,v,b,S);Q1(g,b)}return typeof b=="string"&&b!==""||typeof b=="number"?(b=""+b,v!==null&&v.tag===6?(n(g,v.sibling),v=i(v,b),v.return=g,g=v):(n(g,v),v=SP(b,g.mode,S),v.return=g,g=v),o(g)):n(g,v)}return y}var Am=eY(!0),tY=eY(!1),R_={},Mu=Gf(R_),fv=Gf(R_),dv=Gf(R_);function kd(e){if(e===R_)throw Error(Re(174));return e}function WD(e,t){switch(Xn(dv,t),Xn(fv,e),Xn(Mu,R_),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:X2(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=X2(t,e)}ir(Mu),Xn(Mu,t)}function Pm(){ir(Mu),ir(fv),ir(dv)}function nY(e){kd(dv.current);var t=kd(Mu.current),n=X2(t,e.type);t!==n&&(Xn(fv,e),Xn(Mu,n))}function qD(e){fv.current===e&&(ir(Mu),ir(fv))}var mr=Gf(0);function EE(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||n.data==="$?"||n.data==="$!"))return t}else if(t.tag===19&&t.memoizedProps.revealOrder!==void 0){if(t.flags&128)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var yP=[];function GD(){for(var e=0;en?n:4,e(!0);var r=vP.transition;vP.transition={};try{e(!1),t()}finally{Fn=n,vP.transition=r}}function vY(){return ia().memoizedState}function Hme(e,t,n){var r=uf(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},_Y(e))bY(t,n);else if(n=QG(e,t,n,r),n!==null){var i=_s();Ua(n,e,r,i),wY(n,t,r)}}function Wme(e,t,n){var r=uf(e),i={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(_Y(e))bY(t,i);else{var s=e.alternate;if(e.lanes===0&&(s===null||s.lanes===0)&&(s=t.lastRenderedReducer,s!==null))try{var o=t.lastRenderedState,a=s(o,n);if(i.hasEagerState=!0,i.eagerState=a,Wa(a,o)){var u=t.interleaved;u===null?(i.next=i,zD(t)):(i.next=u.next,u.next=i),t.interleaved=i;return}}catch{}finally{}n=QG(e,t,i,r),n!==null&&(i=_s(),Ua(n,e,r,i),wY(n,t,r))}}function _Y(e){var t=e.alternate;return e===gr||t!==null&&t===gr}function bY(e,t){my=SE=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function wY(e,t,n){if(n&4194240){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,PD(e,n)}}var TE={readContext:ra,useCallback:Wi,useContext:Wi,useEffect:Wi,useImperativeHandle:Wi,useInsertionEffect:Wi,useLayoutEffect:Wi,useMemo:Wi,useReducer:Wi,useRef:Wi,useState:Wi,useDebugValue:Wi,useDeferredValue:Wi,useTransition:Wi,useMutableSource:Wi,useSyncExternalStore:Wi,useId:Wi,unstable_isNewReconciler:!1},qme={readContext:ra,useCallback:function(e,t){return uu().memoizedState=[e,t===void 0?null:t],e},useContext:ra,useEffect:J5,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,_w(4194308,4,hY.bind(null,t,e),n)},useLayoutEffect:function(e,t){return _w(4194308,4,e,t)},useInsertionEffect:function(e,t){return _w(4,2,e,t)},useMemo:function(e,t){var n=uu();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=uu();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=Hme.bind(null,gr,e),[r.memoizedState,e]},useRef:function(e){var t=uu();return e={current:e},t.memoizedState=e},useState:X5,useDebugValue:JD,useDeferredValue:function(e){return uu().memoizedState=e},useTransition:function(){var e=X5(!1),t=e[0];return e=zme.bind(null,e[1]),uu().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var r=gr,i=uu();if(dr){if(n===void 0)throw Error(Re(407));n=n()}else{if(n=t(),gi===null)throw Error(Re(349));sh&30||sY(r,t,n)}i.memoizedState=n;var s={value:n,getSnapshot:t};return i.queue=s,J5(aY.bind(null,r,s,e),[e]),r.flags|=2048,mv(9,oY.bind(null,r,s,n,t),void 0,null),n},useId:function(){var e=uu(),t=gi.identifierPrefix;if(dr){var n=Ol,r=Pl;n=(r&~(1<<32-ja(r)-1)).toString(32)+n,t=":"+t+"R"+n,n=hv++,0")&&(u=u.replace("",e.displayName)),u}while(1<=o&&0<=a);break}}}finally{tP=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?z0(e):""}function Epe(e){switch(e.tag){case 5:return z0(e.type);case 16:return z0("Lazy");case 13:return z0("Suspense");case 19:return z0("SuspenseList");case 0:case 2:case 15:return e=nP(e.type,!1),e;case 11:return e=nP(e.type.render,!1),e;case 1:return e=nP(e.type,!0),e;default:return""}}function W2(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 Ep:return"Fragment";case wp:return"Portal";case V2:return"Profiler";case SD:return"StrictMode";case z2:return"Suspense";case H2:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case Zq:return(e.displayName||"Context")+".Consumer";case Jq:return(e._context.displayName||"Context")+".Provider";case TD:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case ID:return t=e.displayName||null,t!==null?t:W2(e.type)||"Memo";case kc:t=e._payload,e=e._init;try{return W2(e(t))}catch{}}return null}function Spe(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 W2(t);case 8:return t===SD?"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 Sf(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function tG(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function Tpe(e){var t=tG(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 i=n.get,s=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(o){r=""+o,s.call(this,o)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(o){r=""+o},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function j1(e){e._valueTracker||(e._valueTracker=Tpe(e))}function nG(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=tG(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function oE(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 q2(e,t){var n=t.checked;return yr({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function p5(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=Sf(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 rG(e,t){t=t.checked,t!=null&&ED(e,"checked",t,!1)}function G2(e,t){rG(e,t);var n=Sf(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")?Y2(e,t.type,n):t.hasOwnProperty("defaultValue")&&Y2(e,t.type,Sf(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function m5(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 Y2(e,t,n){(t!=="number"||oE(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var H0=Array.isArray;function qp(e,t,n,r){if(e=e.options,t){t={};for(var i=0;i"+t.valueOf().toString()+"",t=U1.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function tv(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var cy={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},Ipe=["Webkit","ms","Moz","O"];Object.keys(cy).forEach(function(e){Ipe.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),cy[t]=cy[e]})});function aG(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||cy.hasOwnProperty(e)&&cy[e]?(""+t).trim():t+"px"}function uG(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,i=aG(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,i):e[n]=i}}var xpe=yr({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 X2(e,t){if(t){if(xpe[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(Re(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(Re(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(Re(61))}if(t.style!=null&&typeof t.style!="object")throw Error(Re(62))}}function J2(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 Z2=null;function xD(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var eR=null,Gp=null,Yp=null;function v5(e){if(e=O_(e)){if(typeof eR!="function")throw Error(Re(280));var t=e.stateNode;t&&(t=ox(t),eR(e.stateNode,e.type,t))}}function lG(e){Gp?Yp?Yp.push(e):Yp=[e]:Gp=e}function cG(){if(Gp){var e=Gp,t=Yp;if(Yp=Gp=null,v5(e),t)for(e=0;e>>=0,e===0?32:31-(Mpe(e)/Fpe|0)|0}var V1=64,z1=4194304;function W0(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 cE(e,t){var n=e.pendingLanes;if(n===0)return 0;var r=0,i=e.suspendedLanes,s=e.pingedLanes,o=n&268435455;if(o!==0){var a=o&~i;a!==0?r=W0(a):(s&=o,s!==0&&(r=W0(s)))}else o=n&~i,o!==0?r=W0(o):s!==0&&(r=W0(s));if(r===0)return 0;if(t!==0&&t!==r&&!(t&i)&&(i=r&-r,s=t&-t,i>=s||i===16&&(s&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 A_(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-ja(t),e[t]=n}function Vpe(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=dy),C5=" ",A5=!1;function OG(e,t){switch(e){case"keyup":return gme.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function RG(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var Sp=!1;function vme(e,t){switch(e){case"compositionend":return RG(t);case"keypress":return t.which!==32?null:(A5=!0,C5);case"textInput":return e=t.data,e===C5&&A5?null:e;default:return null}}function _me(e,t){if(Sp)return e==="compositionend"||!DD&&OG(e,t)?(e=AG(),mw=RD=qc=null,Sp=!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=N5(n)}}function $G(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?$G(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function LG(){for(var e=window,t=oE();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=oE(e.document)}return t}function $D(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 Ame(e){var t=LG(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&$G(n.ownerDocument.documentElement,n)){if(r!==null&&$D(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 i=n.textContent.length,s=Math.min(r.start,i);r=r.end===void 0?s:Math.min(r.end,i),!e.extend&&s>r&&(i=r,r=s,s=i),i=k5(n,s);var o=k5(n,r);i&&o&&(e.rangeCount!==1||e.anchorNode!==i.node||e.anchorOffset!==i.offset||e.focusNode!==o.node||e.focusOffset!==o.offset)&&(t=t.createRange(),t.setStart(i.node,i.offset),e.removeAllRanges(),s>r?(e.addRange(t),e.extend(o.node,o.offset)):(t.setEnd(o.node,o.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,Tp=null,oR=null,py=null,aR=!1;function D5(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;aR||Tp==null||Tp!==oE(r)||(r=Tp,"selectionStart"in r&&$D(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}),py&&av(py,r)||(py=r,r=hE(oR,"onSelect"),0Cp||(e.current=hR[Cp],hR[Cp]=null,Cp--)}function Xn(e,t){Cp++,hR[Cp]=e.current,e.current=t}var Tf={},os=Gf(Tf),Ks=Gf(!1),rh=Tf;function xm(e,t){var n=e.type.contextTypes;if(!n)return Tf;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var i={},s;for(s in n)i[s]=t[s];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=i),i}function Qs(e){return e=e.childContextTypes,e!=null}function mE(){ir(Ks),ir(os)}function U5(e,t,n){if(os.current!==Tf)throw Error(Re(168));Xn(os,t),Xn(Ks,n)}function WG(e,t,n){var r=e.stateNode;if(t=t.childContextTypes,typeof r.getChildContext!="function")return n;r=r.getChildContext();for(var i in r)if(!(i in t))throw Error(Re(108,Spe(e)||"Unknown",i));return yr({},n,r)}function gE(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||Tf,rh=os.current,Xn(os,e),Xn(Ks,Ks.current),!0}function V5(e,t,n){var r=e.stateNode;if(!r)throw Error(Re(169));n?(e=WG(e,t,rh),r.__reactInternalMemoizedMergedChildContext=e,ir(Ks),ir(os),Xn(os,e)):ir(Ks),Xn(Ks,n)}var El=null,ax=!1,gP=!1;function qG(e){El===null?El=[e]:El.push(e)}function jme(e){ax=!0,qG(e)}function Yf(){if(!gP&&El!==null){gP=!0;var e=0,t=Fn;try{var n=El;for(Fn=1;e>=o,i-=o,Pl=1<<32-ja(t)+i|n<A?(R=I,I=null):R=I.sibling;var F=d(g,I,b[A],S);if(F===null){I===null&&(I=R);break}e&&I&&F.alternate===null&&t(g,I),v=s(F,v,A),E===null?T=F:E.sibling=F,E=F,I=R}if(A===b.length)return n(g,I),dr&&hd(g,A),T;if(I===null){for(;AA?(R=I,I=null):R=I.sibling;var L=d(g,I,F.value,S);if(L===null){I===null&&(I=R);break}e&&I&&L.alternate===null&&t(g,I),v=s(L,v,A),E===null?T=L:E.sibling=L,E=L,I=R}if(F.done)return n(g,I),dr&&hd(g,A),T;if(I===null){for(;!F.done;A++,F=b.next())F=f(g,F.value,S),F!==null&&(v=s(F,v,A),E===null?T=F:E.sibling=F,E=F);return dr&&hd(g,A),T}for(I=r(g,I);!F.done;A++,F=b.next())F=h(I,g,A,F.value,S),F!==null&&(e&&F.alternate!==null&&I.delete(F.key===null?A:F.key),v=s(F,v,A),E===null?T=F:E.sibling=F,E=F);return e&&I.forEach(function(B){return t(g,B)}),dr&&hd(g,A),T}function y(g,v,b,S){if(typeof b=="object"&&b!==null&&b.type===Ep&&b.key===null&&(b=b.props.children),typeof b=="object"&&b!==null){switch(b.$$typeof){case B1:e:{for(var T=b.key,E=v;E!==null;){if(E.key===T){if(T=b.type,T===Ep){if(E.tag===7){n(g,E.sibling),v=i(E,b.props.children),v.return=g,g=v;break e}}else if(E.elementType===T||typeof T=="object"&&T!==null&&T.$$typeof===kc&&K5(T)===E.type){n(g,E.sibling),v=i(E,b.props),v.ref=c0(g,E,b),v.return=g,g=v;break e}n(g,E);break}else t(g,E);E=E.sibling}b.type===Ep?(v=Qd(b.props.children,g.mode,S,b.key),v.return=g,g=v):(S=Sw(b.type,b.key,b.props,null,g.mode,S),S.ref=c0(g,v,b),S.return=g,g=S)}return o(g);case wp:e:{for(E=b.key;v!==null;){if(v.key===E)if(v.tag===4&&v.stateNode.containerInfo===b.containerInfo&&v.stateNode.implementation===b.implementation){n(g,v.sibling),v=i(v,b.children||[]),v.return=g,g=v;break e}else{n(g,v);break}else t(g,v);v=v.sibling}v=TP(b,g.mode,S),v.return=g,g=v}return o(g);case kc:return E=b._init,y(g,v,E(b._payload),S)}if(H0(b))return p(g,v,b,S);if(s0(b))return m(g,v,b,S);Q1(g,b)}return typeof b=="string"&&b!==""||typeof b=="number"?(b=""+b,v!==null&&v.tag===6?(n(g,v.sibling),v=i(v,b),v.return=g,g=v):(n(g,v),v=SP(b,g.mode,S),v.return=g,g=v),o(g)):n(g,v)}return y}var Am=eY(!0),tY=eY(!1),R_={},Mu=Gf(R_),fv=Gf(R_),dv=Gf(R_);function kd(e){if(e===R_)throw Error(Re(174));return e}function HD(e,t){switch(Xn(dv,t),Xn(fv,e),Xn(Mu,R_),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:Q2(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=Q2(t,e)}ir(Mu),Xn(Mu,t)}function Pm(){ir(Mu),ir(fv),ir(dv)}function nY(e){kd(dv.current);var t=kd(Mu.current),n=Q2(t,e.type);t!==n&&(Xn(fv,e),Xn(Mu,n))}function WD(e){fv.current===e&&(ir(Mu),ir(fv))}var mr=Gf(0);function EE(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||n.data==="$?"||n.data==="$!"))return t}else if(t.tag===19&&t.memoizedProps.revealOrder!==void 0){if(t.flags&128)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var yP=[];function qD(){for(var e=0;en?n:4,e(!0);var r=vP.transition;vP.transition={};try{e(!1),t()}finally{Fn=n,vP.transition=r}}function vY(){return ia().memoizedState}function Hme(e,t,n){var r=uf(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},_Y(e))bY(t,n);else if(n=QG(e,t,n,r),n!==null){var i=_s();Ua(n,e,r,i),wY(n,t,r)}}function Wme(e,t,n){var r=uf(e),i={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(_Y(e))bY(t,i);else{var s=e.alternate;if(e.lanes===0&&(s===null||s.lanes===0)&&(s=t.lastRenderedReducer,s!==null))try{var o=t.lastRenderedState,a=s(o,n);if(i.hasEagerState=!0,i.eagerState=a,Wa(a,o)){var u=t.interleaved;u===null?(i.next=i,VD(t)):(i.next=u.next,u.next=i),t.interleaved=i;return}}catch{}finally{}n=QG(e,t,i,r),n!==null&&(i=_s(),Ua(n,e,r,i),wY(n,t,r))}}function _Y(e){var t=e.alternate;return e===gr||t!==null&&t===gr}function bY(e,t){my=SE=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function wY(e,t,n){if(n&4194240){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,AD(e,n)}}var TE={readContext:ra,useCallback:Wi,useContext:Wi,useEffect:Wi,useImperativeHandle:Wi,useInsertionEffect:Wi,useLayoutEffect:Wi,useMemo:Wi,useReducer:Wi,useRef:Wi,useState:Wi,useDebugValue:Wi,useDeferredValue:Wi,useTransition:Wi,useMutableSource:Wi,useSyncExternalStore:Wi,useId:Wi,unstable_isNewReconciler:!1},qme={readContext:ra,useCallback:function(e,t){return uu().memoizedState=[e,t===void 0?null:t],e},useContext:ra,useEffect:X5,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,_w(4194308,4,hY.bind(null,t,e),n)},useLayoutEffect:function(e,t){return _w(4194308,4,e,t)},useInsertionEffect:function(e,t){return _w(4,2,e,t)},useMemo:function(e,t){var n=uu();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=uu();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=Hme.bind(null,gr,e),[r.memoizedState,e]},useRef:function(e){var t=uu();return e={current:e},t.memoizedState=e},useState:Q5,useDebugValue:XD,useDeferredValue:function(e){return uu().memoizedState=e},useTransition:function(){var e=Q5(!1),t=e[0];return e=zme.bind(null,e[1]),uu().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var r=gr,i=uu();if(dr){if(n===void 0)throw Error(Re(407));n=n()}else{if(n=t(),gi===null)throw Error(Re(349));sh&30||sY(r,t,n)}i.memoizedState=n;var s={value:n,getSnapshot:t};return i.queue=s,X5(aY.bind(null,r,s,e),[e]),r.flags|=2048,mv(9,oY.bind(null,r,s,n,t),void 0,null),n},useId:function(){var e=uu(),t=gi.identifierPrefix;if(dr){var n=Ol,r=Pl;n=(r&~(1<<32-ja(r)-1)).toString(32)+n,t=":"+t+"R"+n,n=hv++,0<\/script>",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=o.createElement(n,{is:r.is}):(e=o.createElement(n),n==="select"&&(o=e,r.multiple?o.multiple=!0:r.size&&(o.size=r.size))):e=o.createElementNS(e,n),e[vu]=t,e[cv]=r,OY(e,t,!1,!1),t.stateNode=e;e:{switch(o=Z2(n,r),n){case"dialog":er("cancel",e),er("close",e),i=r;break;case"iframe":case"object":case"embed":er("load",e),i=r;break;case"video":case"audio":for(i=0;iRm&&(t.flags|=128,r=!0,f0(s,!1),t.lanes=4194304)}else{if(!r)if(e=EE(o),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),f0(s,!0),s.tail===null&&s.tailMode==="hidden"&&!o.alternate&&!dr)return qi(t),null}else 2*Lr()-s.renderingStartTime>Rm&&n!==1073741824&&(t.flags|=128,r=!0,f0(s,!1),t.lanes=4194304);s.isBackwards?(o.sibling=t.child,t.child=o):(n=s.last,n!==null?n.sibling=o:t.child=o,s.last=o)}return s.tail!==null?(t=s.tail,s.rendering=t,s.tail=t.sibling,s.renderingStartTime=Lr(),t.sibling=null,n=mr.current,Xn(mr,r?n&1|2:n&1),t):(qi(t),null);case 22:case 23:return i$(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?mo&1073741824&&(qi(t),t.subtreeFlags&6&&(t.flags|=8192)):qi(t),null;case 24:return null;case 25:return null}throw Error(Re(156,t.tag))}function ege(e,t){switch(FD(t),t.tag){case 1:return Qs(t.type)&&mE(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Pm(),ir(Ks),ir(os),GD(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return qD(t),null;case 13:if(ir(mr),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(Re(340));Cm()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return ir(mr),null;case 4:return Pm(),null;case 10:return VD(t.type._context),null;case 22:case 23:return i$(),null;case 24:return null;default:return null}}var J1=!1,Zi=!1,tge=typeof WeakSet=="function"?WeakSet:Set,qe=null;function Rp(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){Ir(e,t,r)}else n.current=null}function xR(e,t,n){try{n()}catch(r){Ir(e,t,r)}}var aF=!1;function nge(e,t){if(lR=fE,e=LG(),LD(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 i=r.anchorOffset,s=r.focusNode;r=r.focusOffset;try{n.nodeType,s.nodeType}catch{n=null;break e}var o=0,a=-1,u=-1,l=0,c=0,f=e,d=null;t:for(;;){for(var h;f!==n||i!==0&&f.nodeType!==3||(a=o+i),f!==s||r!==0&&f.nodeType!==3||(u=o+r),f.nodeType===3&&(o+=f.nodeValue.length),(h=f.firstChild)!==null;)d=f,f=h;for(;;){if(f===e)break t;if(d===n&&++l===i&&(a=o),d===s&&++c===r&&(u=o),(h=f.nextSibling)!==null)break;f=d,d=f.parentNode}f=h}n=a===-1||u===-1?null:{start:a,end:u}}else n=null}n=n||{start:0,end:0}}else n=null;for(cR={focusedElem:e,selectionRange:n},fE=!1,qe=t;qe!==null;)if(t=qe,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,qe=e;else for(;qe!==null;){t=qe;try{var p=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(p!==null){var m=p.memoizedProps,y=p.memoizedState,g=t.stateNode,v=g.getSnapshotBeforeUpdate(t.elementType===t.type?m:Ca(t.type,m),y);g.__reactInternalSnapshotBeforeUpdate=v}break;case 3:var b=t.stateNode.containerInfo;b.nodeType===1?b.textContent="":b.nodeType===9&&b.documentElement&&b.removeChild(b.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(Re(163))}}catch(S){Ir(t,t.return,S)}if(e=t.sibling,e!==null){e.return=t.return,qe=e;break}qe=t.return}return p=aF,aF=!1,p}function gy(e,t,n){var r=t.updateQueue;if(r=r!==null?r.lastEffect:null,r!==null){var i=r=r.next;do{if((i.tag&e)===e){var s=i.destroy;i.destroy=void 0,s!==void 0&&xR(t,n,s)}i=i.next}while(i!==r)}}function cx(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 CR(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 kY(e){var t=e.alternate;t!==null&&(e.alternate=null,kY(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[vu],delete t[cv],delete t[hR],delete t[Fme],delete t[Bme])),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 DY(e){return e.tag===5||e.tag===3||e.tag===4}function uF(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||DY(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 AR(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=pE));else if(r!==4&&(e=e.child,e!==null))for(AR(e,t,n),e=e.sibling;e!==null;)AR(e,t,n),e=e.sibling}function PR(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(PR(e,t,n),e=e.sibling;e!==null;)PR(e,t,n),e=e.sibling}var Ci=null,Aa=!1;function _c(e,t,n){for(n=n.child;n!==null;)$Y(e,t,n),n=n.sibling}function $Y(e,t,n){if(Lu&&typeof Lu.onCommitFiberUnmount=="function")try{Lu.onCommitFiberUnmount(nx,n)}catch{}switch(n.tag){case 5:Zi||Rp(n,t);case 6:var r=Ci,i=Aa;Ci=null,_c(e,t,n),Ci=r,Aa=i,Ci!==null&&(Aa?(e=Ci,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):Ci.removeChild(n.stateNode));break;case 18:Ci!==null&&(Aa?(e=Ci,n=n.stateNode,e.nodeType===8?mP(e.parentNode,n):e.nodeType===1&&mP(e,n),sv(e)):mP(Ci,n.stateNode));break;case 4:r=Ci,i=Aa,Ci=n.stateNode.containerInfo,Aa=!0,_c(e,t,n),Ci=r,Aa=i;break;case 0:case 11:case 14:case 15:if(!Zi&&(r=n.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){i=r=r.next;do{var s=i,o=s.destroy;s=s.tag,o!==void 0&&(s&2||s&4)&&xR(n,t,o),i=i.next}while(i!==r)}_c(e,t,n);break;case 1:if(!Zi&&(Rp(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(a){Ir(n,t,a)}_c(e,t,n);break;case 21:_c(e,t,n);break;case 22:n.mode&1?(Zi=(r=Zi)||n.memoizedState!==null,_c(e,t,n),Zi=r):_c(e,t,n);break;default:_c(e,t,n)}}function lF(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new tge),t.forEach(function(r){var i=fge.bind(null,e,r);n.has(r)||(n.add(r),r.then(i,i))})}}function wa(e,t){var n=t.deletions;if(n!==null)for(var r=0;ri&&(i=o),r&=~s}if(r=i,r=Lr()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*ige(r/1960))-r,10e?16:e,Gc===null)var r=!1;else{if(e=Gc,Gc=null,CE=0,vn&6)throw Error(Re(331));var i=vn;for(vn|=4,qe=e.current;qe!==null;){var s=qe,o=s.child;if(qe.flags&16){var a=s.deletions;if(a!==null){for(var u=0;uLr()-n$?Kd(e,0):t$|=n),Xs(e,t)}function zY(e,t){t===0&&(e.mode&1?(t=z1,z1<<=1,!(z1&130023424)&&(z1=4194304)):t=1);var n=_s();e=Hl(e,t),e!==null&&(A_(e,t,n),Xs(e,n))}function cge(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),zY(e,n)}function fge(e,t){var n=0;switch(e.tag){case 13:var r=e.stateNode,i=e.memoizedState;i!==null&&(n=i.retryLane);break;case 19:r=e.stateNode;break;default:throw Error(Re(314))}r!==null&&r.delete(t),zY(e,n)}var HY;HY=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||Ks.current)Hs=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return Hs=!1,Jme(e,t,n);Hs=!!(e.flags&131072)}else Hs=!1,dr&&t.flags&1048576&&GG(t,vE,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;bw(e,t),e=t.pendingProps;var i=xm(t,os.current);Qp(t,n),i=KD(null,t,r,e,i,n);var s=QD();return t.flags|=1,typeof i=="object"&&i!==null&&typeof i.render=="function"&&i.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,Qs(r)?(s=!0,gE(t)):s=!1,t.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,HD(t),i.updater=ux,t.stateNode=i,i._reactInternals=t,_R(t,r,e,n),t=ER(null,t,r,!0,s,n)):(t.tag=0,dr&&s&&MD(t),ps(null,t,i,n),t=t.child),t;case 16:r=t.elementType;e:{switch(bw(e,t),e=t.pendingProps,i=r._init,r=i(r._payload),t.type=r,i=t.tag=hge(r),e=Ca(r,e),i){case 0:t=wR(null,t,r,e,n);break e;case 1:t=iF(null,t,r,e,n);break e;case 11:t=nF(null,t,r,e,n);break e;case 14:t=rF(null,t,r,Ca(r.type,e),n);break e}throw Error(Re(306,r,""))}return t;case 0:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:Ca(r,i),wR(e,t,r,i,n);case 1:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:Ca(r,i),iF(e,t,r,i,n);case 3:e:{if(CY(t),e===null)throw Error(Re(387));r=t.pendingProps,s=t.memoizedState,i=s.element,XG(e,t),wE(t,r,null,n);var o=t.memoizedState;if(r=o.element,s.isDehydrated)if(s={element:r,isDehydrated:!1,cache:o.cache,pendingSuspenseBoundaries:o.pendingSuspenseBoundaries,transitions:o.transitions},t.updateQueue.baseState=s,t.memoizedState=s,t.flags&256){i=Om(Error(Re(423)),t),t=sF(e,t,r,n,i);break e}else if(r!==i){i=Om(Error(Re(424)),t),t=sF(e,t,r,n,i);break e}else for(bo=sf(t.stateNode.containerInfo.firstChild),Io=t,dr=!0,Oa=null,n=tY(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(Cm(),r===i){t=Wl(e,t,n);break e}ps(e,t,r,n)}t=t.child}return t;case 5:return nY(t),e===null&&gR(t),r=t.type,i=t.pendingProps,s=e!==null?e.memoizedProps:null,o=i.children,fR(r,i)?o=null:s!==null&&fR(r,s)&&(t.flags|=32),xY(e,t),ps(e,t,o,n),t.child;case 6:return e===null&&gR(t),null;case 13:return AY(e,t,n);case 4:return WD(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=Am(t,null,r,n):ps(e,t,r,n),t.child;case 11:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:Ca(r,i),nF(e,t,r,i,n);case 7:return ps(e,t,t.pendingProps,n),t.child;case 8:return ps(e,t,t.pendingProps.children,n),t.child;case 12:return ps(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(r=t.type._context,i=t.pendingProps,s=t.memoizedProps,o=i.value,Xn(_E,r._currentValue),r._currentValue=o,s!==null)if(Wa(s.value,o)){if(s.children===i.children&&!Ks.current){t=Wl(e,t,n);break e}}else for(s=t.child,s!==null&&(s.return=t);s!==null;){var a=s.dependencies;if(a!==null){o=s.child;for(var u=a.firstContext;u!==null;){if(u.context===r){if(s.tag===1){u=Ml(-1,n&-n),u.tag=2;var l=s.updateQueue;if(l!==null){l=l.shared;var c=l.pending;c===null?u.next=u:(u.next=c.next,c.next=u),l.pending=u}}s.lanes|=n,u=s.alternate,u!==null&&(u.lanes|=n),yR(s.return,n,t),a.lanes|=n;break}u=u.next}}else if(s.tag===10)o=s.type===t.type?null:s.child;else if(s.tag===18){if(o=s.return,o===null)throw Error(Re(341));o.lanes|=n,a=o.alternate,a!==null&&(a.lanes|=n),yR(o,n,t),o=s.sibling}else o=s.child;if(o!==null)o.return=s;else for(o=s;o!==null;){if(o===t){o=null;break}if(s=o.sibling,s!==null){s.return=o.return,o=s;break}o=o.return}s=o}ps(e,t,i.children,n),t=t.child}return t;case 9:return i=t.type,r=t.pendingProps.children,Qp(t,n),i=ra(i),r=r(i),t.flags|=1,ps(e,t,r,n),t.child;case 14:return r=t.type,i=Ca(r,t.pendingProps),i=Ca(r.type,i),rF(e,t,r,i,n);case 15:return TY(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:Ca(r,i),bw(e,t),t.tag=1,Qs(r)?(e=!0,gE(t)):e=!1,Qp(t,n),ZG(t,r,i),_R(t,r,i,n),ER(null,t,r,!0,e,n);case 19:return PY(e,t,n);case 22:return IY(e,t,n)}throw Error(Re(156,t.tag))};function WY(e,t){return yG(e,t)}function dge(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 ea(e,t,n,r){return new dge(e,t,n,r)}function o$(e){return e=e.prototype,!(!e||!e.isReactComponent)}function hge(e){if(typeof e=="function")return o$(e)?1:0;if(e!=null){if(e=e.$$typeof,e===ID)return 11;if(e===xD)return 14}return 2}function lf(e,t){var n=e.alternate;return n===null?(n=ea(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 Sw(e,t,n,r,i,s){var o=2;if(r=e,typeof e=="function")o$(e)&&(o=1);else if(typeof e=="string")o=5;else e:switch(e){case Ep:return Qd(n.children,i,s,t);case TD:o=8,i|=8;break;case z2:return e=ea(12,n,t,i|2),e.elementType=z2,e.lanes=s,e;case H2:return e=ea(13,n,t,i),e.elementType=H2,e.lanes=s,e;case W2:return e=ea(19,n,t,i),e.elementType=W2,e.lanes=s,e;case eG:return dx(n,i,s,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case Jq:o=10;break e;case Zq:o=9;break e;case ID:o=11;break e;case xD:o=14;break e;case kc:o=16,r=null;break e}throw Error(Re(130,e==null?e:typeof e,""))}return t=ea(o,n,t,i),t.elementType=e,t.type=r,t.lanes=s,t}function Qd(e,t,n,r){return e=ea(7,e,r,t),e.lanes=n,e}function dx(e,t,n,r){return e=ea(22,e,r,t),e.elementType=eG,e.lanes=n,e.stateNode={isHidden:!1},e}function SP(e,t,n){return e=ea(6,e,null,t),e.lanes=n,e}function TP(e,t,n){return t=ea(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function pge(e,t,n,r,i){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=iP(0),this.expirationTimes=iP(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=iP(0),this.identifierPrefix=r,this.onRecoverableError=i,this.mutableSourceEagerHydrationData=null}function a$(e,t,n,r,i,s,o,a,u){return e=new pge(e,t,n,a,u),t===1?(t=1,s===!0&&(t|=8)):t=0,s=ea(3,null,null,t),e.current=s,s.stateNode=e,s.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},HD(s),e}function mge(e,t,n){var r=3"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(KY)}catch(e){console.error(e)}}KY(),Gq.exports=Do;var lc=Gq.exports,yF=lc;U2.createRoot=yF.createRoot,U2.hydrateRoot=yF.hydrateRoot;const QY=w.createContext({storageEngine:void 0,setStorageEngine:()=>{}}),sa=()=>w.useContext(QY);function bge({children:e}){const[t,n]=N.useState(void 0),r=N.useMemo(()=>({storageEngine:t,setStorageEngine:n}),[t]);return C.jsx(QY.Provider,{value:r,children:e})}/** +`+s.stack}return{value:e,source:t,stack:i,digest:null}}function wP(e,t,n){return{value:e,source:null,stack:n??null,digest:t??null}}function _R(e,t){try{console.error(t.value)}catch(n){setTimeout(function(){throw n})}}var Kme=typeof WeakMap=="function"?WeakMap:Map;function EY(e,t,n){n=Ml(-1,n),n.tag=3,n.payload={element:null};var r=t.value;return n.callback=function(){xE||(xE=!0,PR=r),_R(e,t)},n}function SY(e,t,n){n=Ml(-1,n),n.tag=3;var r=e.type.getDerivedStateFromError;if(typeof r=="function"){var i=t.value;n.payload=function(){return r(i)},n.callback=function(){_R(e,t)}}var s=e.stateNode;return s!==null&&typeof s.componentDidCatch=="function"&&(n.callback=function(){_R(e,t),typeof r!="function"&&(af===null?af=new Set([this]):af.add(this));var o=t.stack;this.componentDidCatch(t.value,{componentStack:o!==null?o:""})}),n}function J5(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new Kme;var i=new Set;r.set(t,i)}else i=r.get(t),i===void 0&&(i=new Set,r.set(t,i));i.has(n)||(i.add(n),e=lge.bind(null,e,t,n),t.then(e,e))}function Z5(e){do{var t;if((t=e.tag===13)&&(t=e.memoizedState,t=t!==null?t.dehydrated!==null:!0),t)return e;e=e.return}while(e!==null);return null}function eF(e,t,n,r,i){return e.mode&1?(e.flags|=65536,e.lanes=i,e):(e===t?e.flags|=65536:(e.flags|=128,n.flags|=131072,n.flags&=-52805,n.tag===1&&(n.alternate===null?n.tag=17:(t=Ml(-1,1),t.tag=2,of(n,t,1))),n.lanes|=1),e)}var Qme=uc.ReactCurrentOwner,Hs=!1;function ps(e,t,n,r){t.child=e===null?tY(t,null,n,r):Am(t,e.child,n,r)}function tF(e,t,n,r,i){n=n.render;var s=t.ref;return Qp(t,i),r=YD(e,t,n,r,s,i),n=KD(),e!==null&&!Hs?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~i,Wl(e,t,i)):(dr&&n&&LD(t),t.flags|=1,ps(e,t,r,i),t.child)}function nF(e,t,n,r,i){if(e===null){var s=n.type;return typeof s=="function"&&!s$(s)&&s.defaultProps===void 0&&n.compare===null&&n.defaultProps===void 0?(t.tag=15,t.type=s,TY(e,t,s,r,i)):(e=Sw(n.type,null,r,t,t.mode,i),e.ref=t.ref,e.return=t,t.child=e)}if(s=e.child,!(e.lanes&i)){var o=s.memoizedProps;if(n=n.compare,n=n!==null?n:av,n(o,r)&&e.ref===t.ref)return Wl(e,t,i)}return t.flags|=1,e=lf(s,r),e.ref=t.ref,e.return=t,t.child=e}function TY(e,t,n,r,i){if(e!==null){var s=e.memoizedProps;if(av(s,r)&&e.ref===t.ref)if(Hs=!1,t.pendingProps=r=s,(e.lanes&i)!==0)e.flags&131072&&(Hs=!0);else return t.lanes=e.lanes,Wl(e,t,i)}return bR(e,t,n,r,i)}function IY(e,t,n){var r=t.pendingProps,i=r.children,s=e!==null?e.memoizedState:null;if(r.mode==="hidden")if(!(t.mode&1))t.memoizedState={baseLanes:0,cachePool:null,transitions:null},Xn(Np,mo),mo|=n;else{if(!(n&1073741824))return e=s!==null?s.baseLanes|n:n,t.lanes=t.childLanes=1073741824,t.memoizedState={baseLanes:e,cachePool:null,transitions:null},t.updateQueue=null,Xn(Np,mo),mo|=e,null;t.memoizedState={baseLanes:0,cachePool:null,transitions:null},r=s!==null?s.baseLanes:n,Xn(Np,mo),mo|=r}else s!==null?(r=s.baseLanes|n,t.memoizedState=null):r=n,Xn(Np,mo),mo|=r;return ps(e,t,i,n),t.child}function xY(e,t){var n=t.ref;(e===null&&n!==null||e!==null&&e.ref!==n)&&(t.flags|=512,t.flags|=2097152)}function bR(e,t,n,r,i){var s=Qs(n)?rh:os.current;return s=xm(t,s),Qp(t,i),n=YD(e,t,n,r,s,i),r=KD(),e!==null&&!Hs?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~i,Wl(e,t,i)):(dr&&r&&LD(t),t.flags|=1,ps(e,t,n,i),t.child)}function rF(e,t,n,r,i){if(Qs(n)){var s=!0;gE(t)}else s=!1;if(Qp(t,i),t.stateNode===null)bw(e,t),ZG(t,n,r),vR(t,n,r,i),r=!0;else if(e===null){var o=t.stateNode,a=t.memoizedProps;o.props=a;var u=o.context,l=n.contextType;typeof l=="object"&&l!==null?l=ra(l):(l=Qs(n)?rh:os.current,l=xm(t,l));var c=n.getDerivedStateFromProps,f=typeof c=="function"||typeof o.getSnapshotBeforeUpdate=="function";f||typeof o.UNSAFE_componentWillReceiveProps!="function"&&typeof o.componentWillReceiveProps!="function"||(a!==r||u!==l)&&Y5(t,o,r,l),Dc=!1;var d=t.memoizedState;o.state=d,wE(t,r,o,i),u=t.memoizedState,a!==r||d!==u||Ks.current||Dc?(typeof c=="function"&&(yR(t,n,c,r),u=t.memoizedState),(a=Dc||G5(t,n,a,r,d,u,l))?(f||typeof o.UNSAFE_componentWillMount!="function"&&typeof o.componentWillMount!="function"||(typeof o.componentWillMount=="function"&&o.componentWillMount(),typeof o.UNSAFE_componentWillMount=="function"&&o.UNSAFE_componentWillMount()),typeof o.componentDidMount=="function"&&(t.flags|=4194308)):(typeof o.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=r,t.memoizedState=u),o.props=r,o.state=u,o.context=l,r=a):(typeof o.componentDidMount=="function"&&(t.flags|=4194308),r=!1)}else{o=t.stateNode,XG(e,t),a=t.memoizedProps,l=t.type===t.elementType?a:Ca(t.type,a),o.props=l,f=t.pendingProps,d=o.context,u=n.contextType,typeof u=="object"&&u!==null?u=ra(u):(u=Qs(n)?rh:os.current,u=xm(t,u));var h=n.getDerivedStateFromProps;(c=typeof h=="function"||typeof o.getSnapshotBeforeUpdate=="function")||typeof o.UNSAFE_componentWillReceiveProps!="function"&&typeof o.componentWillReceiveProps!="function"||(a!==f||d!==u)&&Y5(t,o,r,u),Dc=!1,d=t.memoizedState,o.state=d,wE(t,r,o,i);var p=t.memoizedState;a!==f||d!==p||Ks.current||Dc?(typeof h=="function"&&(yR(t,n,h,r),p=t.memoizedState),(l=Dc||G5(t,n,l,r,d,p,u)||!1)?(c||typeof o.UNSAFE_componentWillUpdate!="function"&&typeof o.componentWillUpdate!="function"||(typeof o.componentWillUpdate=="function"&&o.componentWillUpdate(r,p,u),typeof o.UNSAFE_componentWillUpdate=="function"&&o.UNSAFE_componentWillUpdate(r,p,u)),typeof o.componentDidUpdate=="function"&&(t.flags|=4),typeof o.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof o.componentDidUpdate!="function"||a===e.memoizedProps&&d===e.memoizedState||(t.flags|=4),typeof o.getSnapshotBeforeUpdate!="function"||a===e.memoizedProps&&d===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=p),o.props=r,o.state=p,o.context=u,r=l):(typeof o.componentDidUpdate!="function"||a===e.memoizedProps&&d===e.memoizedState||(t.flags|=4),typeof o.getSnapshotBeforeUpdate!="function"||a===e.memoizedProps&&d===e.memoizedState||(t.flags|=1024),r=!1)}return wR(e,t,n,r,s,i)}function wR(e,t,n,r,i,s){xY(e,t);var o=(t.flags&128)!==0;if(!r&&!o)return i&&V5(t,n,!1),Wl(e,t,s);r=t.stateNode,Qme.current=t;var a=o&&typeof n.getDerivedStateFromError!="function"?null:r.render();return t.flags|=1,e!==null&&o?(t.child=Am(t,e.child,null,s),t.child=Am(t,null,a,s)):ps(e,t,a,s),t.memoizedState=r.state,i&&V5(t,n,!0),t.child}function CY(e){var t=e.stateNode;t.pendingContext?U5(e,t.pendingContext,t.pendingContext!==t.context):t.context&&U5(e,t.context,!1),HD(e,t.containerInfo)}function iF(e,t,n,r,i){return Cm(),FD(i),t.flags|=256,ps(e,t,n,r),t.child}var ER={dehydrated:null,treeContext:null,retryLane:0};function SR(e){return{baseLanes:e,cachePool:null,transitions:null}}function AY(e,t,n){var r=t.pendingProps,i=mr.current,s=!1,o=(t.flags&128)!==0,a;if((a=o)||(a=e!==null&&e.memoizedState===null?!1:(i&2)!==0),a?(s=!0,t.flags&=-129):(e===null||e.memoizedState!==null)&&(i|=1),Xn(mr,i&1),e===null)return mR(t),e=t.memoizedState,e!==null&&(e=e.dehydrated,e!==null)?(t.mode&1?e.data==="$!"?t.lanes=8:t.lanes=1073741824:t.lanes=1,null):(o=r.children,e=r.fallback,s?(r=t.mode,s=t.child,o={mode:"hidden",children:o},!(r&1)&&s!==null?(s.childLanes=0,s.pendingProps=o):s=dx(o,r,0,null),e=Qd(e,r,n,null),s.return=t,e.return=t,s.sibling=e,t.child=s,t.child.memoizedState=SR(n),t.memoizedState=ER,e):JD(t,o));if(i=e.memoizedState,i!==null&&(a=i.dehydrated,a!==null))return Xme(e,t,o,r,a,i,n);if(s){s=r.fallback,o=t.mode,i=e.child,a=i.sibling;var u={mode:"hidden",children:r.children};return!(o&1)&&t.child!==i?(r=t.child,r.childLanes=0,r.pendingProps=u,t.deletions=null):(r=lf(i,u),r.subtreeFlags=i.subtreeFlags&14680064),a!==null?s=lf(a,s):(s=Qd(s,o,n,null),s.flags|=2),s.return=t,r.return=t,r.sibling=s,t.child=r,r=s,s=t.child,o=e.child.memoizedState,o=o===null?SR(n):{baseLanes:o.baseLanes|n,cachePool:null,transitions:o.transitions},s.memoizedState=o,s.childLanes=e.childLanes&~n,t.memoizedState=ER,r}return s=e.child,e=s.sibling,r=lf(s,{mode:"visible",children:r.children}),!(t.mode&1)&&(r.lanes=n),r.return=t,r.sibling=null,e!==null&&(n=t.deletions,n===null?(t.deletions=[e],t.flags|=16):n.push(e)),t.child=r,t.memoizedState=null,r}function JD(e,t){return t=dx({mode:"visible",children:t},e.mode,0,null),t.return=e,e.child=t}function X1(e,t,n,r){return r!==null&&FD(r),Am(t,e.child,null,n),e=JD(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function Xme(e,t,n,r,i,s,o){if(n)return t.flags&256?(t.flags&=-257,r=wP(Error(Re(422))),X1(e,t,o,r)):t.memoizedState!==null?(t.child=e.child,t.flags|=128,null):(s=r.fallback,i=t.mode,r=dx({mode:"visible",children:r.children},i,0,null),s=Qd(s,i,o,null),s.flags|=2,r.return=t,s.return=t,r.sibling=s,t.child=r,t.mode&1&&Am(t,e.child,null,o),t.child.memoizedState=SR(o),t.memoizedState=ER,s);if(!(t.mode&1))return X1(e,t,o,null);if(i.data==="$!"){if(r=i.nextSibling&&i.nextSibling.dataset,r)var a=r.dgst;return r=a,s=Error(Re(419)),r=wP(s,r,void 0),X1(e,t,o,r)}if(a=(o&e.childLanes)!==0,Hs||a){if(r=gi,r!==null){switch(o&-o){case 4:i=2;break;case 16:i=8;break;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:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:i=32;break;case 536870912:i=268435456;break;default:i=0}i=i&(r.suspendedLanes|o)?0:i,i!==0&&i!==s.retryLane&&(s.retryLane=i,Hl(e,i),Ua(r,e,i,-1))}return i$(),r=wP(Error(Re(421))),X1(e,t,o,r)}return i.data==="$?"?(t.flags|=128,t.child=e.child,t=cge.bind(null,e),i._reactRetry=t,null):(e=s.treeContext,bo=sf(i.nextSibling),Io=t,dr=!0,Oa=null,e!==null&&(Ho[Wo++]=Pl,Ho[Wo++]=Ol,Ho[Wo++]=ih,Pl=e.id,Ol=e.overflow,ih=t),t=JD(t,r.children),t.flags|=4096,t)}function sF(e,t,n){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),gR(e.return,t,n)}function EP(e,t,n,r,i){var s=e.memoizedState;s===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:i}:(s.isBackwards=t,s.rendering=null,s.renderingStartTime=0,s.last=r,s.tail=n,s.tailMode=i)}function PY(e,t,n){var r=t.pendingProps,i=r.revealOrder,s=r.tail;if(ps(e,t,r.children,n),r=mr.current,r&2)r=r&1|2,t.flags|=128;else{if(e!==null&&e.flags&128)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&sF(e,n,t);else if(e.tag===19)sF(e,n,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;e.sibling===null;){if(e.return===null||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}r&=1}if(Xn(mr,r),!(t.mode&1))t.memoizedState=null;else switch(i){case"forwards":for(n=t.child,i=null;n!==null;)e=n.alternate,e!==null&&EE(e)===null&&(i=n),n=n.sibling;n=i,n===null?(i=t.child,t.child=null):(i=n.sibling,n.sibling=null),EP(t,!1,i,n,s);break;case"backwards":for(n=null,i=t.child,t.child=null;i!==null;){if(e=i.alternate,e!==null&&EE(e)===null){t.child=i;break}e=i.sibling,i.sibling=n,n=i,i=e}EP(t,!0,n,null,s);break;case"together":EP(t,!1,null,null,void 0);break;default:t.memoizedState=null}return t.child}function bw(e,t){!(t.mode&1)&&e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2)}function Wl(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),oh|=t.lanes,!(n&t.childLanes))return null;if(e!==null&&t.child!==e.child)throw Error(Re(153));if(t.child!==null){for(e=t.child,n=lf(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=lf(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function Jme(e,t,n){switch(t.tag){case 3:CY(t),Cm();break;case 5:nY(t);break;case 1:Qs(t.type)&&gE(t);break;case 4:HD(t,t.stateNode.containerInfo);break;case 10:var r=t.type._context,i=t.memoizedProps.value;Xn(_E,r._currentValue),r._currentValue=i;break;case 13:if(r=t.memoizedState,r!==null)return r.dehydrated!==null?(Xn(mr,mr.current&1),t.flags|=128,null):n&t.child.childLanes?AY(e,t,n):(Xn(mr,mr.current&1),e=Wl(e,t,n),e!==null?e.sibling:null);Xn(mr,mr.current&1);break;case 19:if(r=(n&t.childLanes)!==0,e.flags&128){if(r)return PY(e,t,n);t.flags|=128}if(i=t.memoizedState,i!==null&&(i.rendering=null,i.tail=null,i.lastEffect=null),Xn(mr,mr.current),r)break;return null;case 22:case 23:return t.lanes=0,IY(e,t,n)}return Wl(e,t,n)}var OY,TR,RY,NY;OY=function(e,t){for(var n=t.child;n!==null;){if(n.tag===5||n.tag===6)e.appendChild(n.stateNode);else if(n.tag!==4&&n.child!==null){n.child.return=n,n=n.child;continue}if(n===t)break;for(;n.sibling===null;){if(n.return===null||n.return===t)return;n=n.return}n.sibling.return=n.return,n=n.sibling}};TR=function(){};RY=function(e,t,n,r){var i=e.memoizedProps;if(i!==r){e=t.stateNode,kd(Mu.current);var s=null;switch(n){case"input":i=q2(e,i),r=q2(e,r),s=[];break;case"select":i=yr({},i,{value:void 0}),r=yr({},r,{value:void 0}),s=[];break;case"textarea":i=K2(e,i),r=K2(e,r),s=[];break;default:typeof i.onClick!="function"&&typeof r.onClick=="function"&&(e.onclick=pE)}X2(n,r);var o;n=null;for(l in i)if(!r.hasOwnProperty(l)&&i.hasOwnProperty(l)&&i[l]!=null)if(l==="style"){var a=i[l];for(o in a)a.hasOwnProperty(o)&&(n||(n={}),n[o]="")}else l!=="dangerouslySetInnerHTML"&&l!=="children"&&l!=="suppressContentEditableWarning"&&l!=="suppressHydrationWarning"&&l!=="autoFocus"&&(ev.hasOwnProperty(l)?s||(s=[]):(s=s||[]).push(l,null));for(l in r){var u=r[l];if(a=i!=null?i[l]:void 0,r.hasOwnProperty(l)&&u!==a&&(u!=null||a!=null))if(l==="style")if(a){for(o in a)!a.hasOwnProperty(o)||u&&u.hasOwnProperty(o)||(n||(n={}),n[o]="");for(o in u)u.hasOwnProperty(o)&&a[o]!==u[o]&&(n||(n={}),n[o]=u[o])}else n||(s||(s=[]),s.push(l,n)),n=u;else l==="dangerouslySetInnerHTML"?(u=u?u.__html:void 0,a=a?a.__html:void 0,u!=null&&a!==u&&(s=s||[]).push(l,u)):l==="children"?typeof u!="string"&&typeof u!="number"||(s=s||[]).push(l,""+u):l!=="suppressContentEditableWarning"&&l!=="suppressHydrationWarning"&&(ev.hasOwnProperty(l)?(u!=null&&l==="onScroll"&&er("scroll",e),s||a===u||(s=[])):(s=s||[]).push(l,u))}n&&(s=s||[]).push("style",n);var l=s;(t.updateQueue=l)&&(t.flags|=4)}};NY=function(e,t,n,r){n!==r&&(t.flags|=4)};function f0(e,t){if(!dr)switch(e.tailMode){case"hidden":t=e.tail;for(var n=null;t!==null;)t.alternate!==null&&(n=t),t=t.sibling;n===null?e.tail=null:n.sibling=null;break;case"collapsed":n=e.tail;for(var r=null;n!==null;)n.alternate!==null&&(r=n),n=n.sibling;r===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:r.sibling=null}}function qi(e){var t=e.alternate!==null&&e.alternate.child===e.child,n=0,r=0;if(t)for(var i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags&14680064,r|=i.flags&14680064,i.return=e,i=i.sibling;else for(i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags,r|=i.flags,i.return=e,i=i.sibling;return e.subtreeFlags|=r,e.childLanes=n,t}function Zme(e,t,n){var r=t.pendingProps;switch(MD(t),t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return qi(t),null;case 1:return Qs(t.type)&&mE(),qi(t),null;case 3:return r=t.stateNode,Pm(),ir(Ks),ir(os),qD(),r.pendingContext&&(r.context=r.pendingContext,r.pendingContext=null),(e===null||e.child===null)&&(K1(t)?t.flags|=4:e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,Oa!==null&&(NR(Oa),Oa=null))),TR(e,t),qi(t),null;case 5:WD(t);var i=kd(dv.current);if(n=t.type,e!==null&&t.stateNode!=null)RY(e,t,n,r,i),e.ref!==t.ref&&(t.flags|=512,t.flags|=2097152);else{if(!r){if(t.stateNode===null)throw Error(Re(166));return qi(t),null}if(e=kd(Mu.current),K1(t)){r=t.stateNode,n=t.type;var s=t.memoizedProps;switch(r[vu]=t,r[cv]=s,e=(t.mode&1)!==0,n){case"dialog":er("cancel",r),er("close",r);break;case"iframe":case"object":case"embed":er("load",r);break;case"video":case"audio":for(i=0;i<\/script>",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=o.createElement(n,{is:r.is}):(e=o.createElement(n),n==="select"&&(o=e,r.multiple?o.multiple=!0:r.size&&(o.size=r.size))):e=o.createElementNS(e,n),e[vu]=t,e[cv]=r,OY(e,t,!1,!1),t.stateNode=e;e:{switch(o=J2(n,r),n){case"dialog":er("cancel",e),er("close",e),i=r;break;case"iframe":case"object":case"embed":er("load",e),i=r;break;case"video":case"audio":for(i=0;iRm&&(t.flags|=128,r=!0,f0(s,!1),t.lanes=4194304)}else{if(!r)if(e=EE(o),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),f0(s,!0),s.tail===null&&s.tailMode==="hidden"&&!o.alternate&&!dr)return qi(t),null}else 2*Lr()-s.renderingStartTime>Rm&&n!==1073741824&&(t.flags|=128,r=!0,f0(s,!1),t.lanes=4194304);s.isBackwards?(o.sibling=t.child,t.child=o):(n=s.last,n!==null?n.sibling=o:t.child=o,s.last=o)}return s.tail!==null?(t=s.tail,s.rendering=t,s.tail=t.sibling,s.renderingStartTime=Lr(),t.sibling=null,n=mr.current,Xn(mr,r?n&1|2:n&1),t):(qi(t),null);case 22:case 23:return r$(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?mo&1073741824&&(qi(t),t.subtreeFlags&6&&(t.flags|=8192)):qi(t),null;case 24:return null;case 25:return null}throw Error(Re(156,t.tag))}function ege(e,t){switch(MD(t),t.tag){case 1:return Qs(t.type)&&mE(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Pm(),ir(Ks),ir(os),qD(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return WD(t),null;case 13:if(ir(mr),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(Re(340));Cm()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return ir(mr),null;case 4:return Pm(),null;case 10:return UD(t.type._context),null;case 22:case 23:return r$(),null;case 24:return null;default:return null}}var J1=!1,Zi=!1,tge=typeof WeakSet=="function"?WeakSet:Set,qe=null;function Rp(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){Ir(e,t,r)}else n.current=null}function IR(e,t,n){try{n()}catch(r){Ir(e,t,r)}}var oF=!1;function nge(e,t){if(uR=fE,e=LG(),$D(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 i=r.anchorOffset,s=r.focusNode;r=r.focusOffset;try{n.nodeType,s.nodeType}catch{n=null;break e}var o=0,a=-1,u=-1,l=0,c=0,f=e,d=null;t:for(;;){for(var h;f!==n||i!==0&&f.nodeType!==3||(a=o+i),f!==s||r!==0&&f.nodeType!==3||(u=o+r),f.nodeType===3&&(o+=f.nodeValue.length),(h=f.firstChild)!==null;)d=f,f=h;for(;;){if(f===e)break t;if(d===n&&++l===i&&(a=o),d===s&&++c===r&&(u=o),(h=f.nextSibling)!==null)break;f=d,d=f.parentNode}f=h}n=a===-1||u===-1?null:{start:a,end:u}}else n=null}n=n||{start:0,end:0}}else n=null;for(lR={focusedElem:e,selectionRange:n},fE=!1,qe=t;qe!==null;)if(t=qe,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,qe=e;else for(;qe!==null;){t=qe;try{var p=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(p!==null){var m=p.memoizedProps,y=p.memoizedState,g=t.stateNode,v=g.getSnapshotBeforeUpdate(t.elementType===t.type?m:Ca(t.type,m),y);g.__reactInternalSnapshotBeforeUpdate=v}break;case 3:var b=t.stateNode.containerInfo;b.nodeType===1?b.textContent="":b.nodeType===9&&b.documentElement&&b.removeChild(b.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(Re(163))}}catch(S){Ir(t,t.return,S)}if(e=t.sibling,e!==null){e.return=t.return,qe=e;break}qe=t.return}return p=oF,oF=!1,p}function gy(e,t,n){var r=t.updateQueue;if(r=r!==null?r.lastEffect:null,r!==null){var i=r=r.next;do{if((i.tag&e)===e){var s=i.destroy;i.destroy=void 0,s!==void 0&&IR(t,n,s)}i=i.next}while(i!==r)}}function cx(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 xR(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 kY(e){var t=e.alternate;t!==null&&(e.alternate=null,kY(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[vu],delete t[cv],delete t[dR],delete t[Fme],delete t[Bme])),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 DY(e){return e.tag===5||e.tag===3||e.tag===4}function aF(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||DY(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 CR(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=pE));else if(r!==4&&(e=e.child,e!==null))for(CR(e,t,n),e=e.sibling;e!==null;)CR(e,t,n),e=e.sibling}function AR(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(AR(e,t,n),e=e.sibling;e!==null;)AR(e,t,n),e=e.sibling}var Ci=null,Aa=!1;function _c(e,t,n){for(n=n.child;n!==null;)$Y(e,t,n),n=n.sibling}function $Y(e,t,n){if(Lu&&typeof Lu.onCommitFiberUnmount=="function")try{Lu.onCommitFiberUnmount(nx,n)}catch{}switch(n.tag){case 5:Zi||Rp(n,t);case 6:var r=Ci,i=Aa;Ci=null,_c(e,t,n),Ci=r,Aa=i,Ci!==null&&(Aa?(e=Ci,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):Ci.removeChild(n.stateNode));break;case 18:Ci!==null&&(Aa?(e=Ci,n=n.stateNode,e.nodeType===8?mP(e.parentNode,n):e.nodeType===1&&mP(e,n),sv(e)):mP(Ci,n.stateNode));break;case 4:r=Ci,i=Aa,Ci=n.stateNode.containerInfo,Aa=!0,_c(e,t,n),Ci=r,Aa=i;break;case 0:case 11:case 14:case 15:if(!Zi&&(r=n.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){i=r=r.next;do{var s=i,o=s.destroy;s=s.tag,o!==void 0&&(s&2||s&4)&&IR(n,t,o),i=i.next}while(i!==r)}_c(e,t,n);break;case 1:if(!Zi&&(Rp(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(a){Ir(n,t,a)}_c(e,t,n);break;case 21:_c(e,t,n);break;case 22:n.mode&1?(Zi=(r=Zi)||n.memoizedState!==null,_c(e,t,n),Zi=r):_c(e,t,n);break;default:_c(e,t,n)}}function uF(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new tge),t.forEach(function(r){var i=fge.bind(null,e,r);n.has(r)||(n.add(r),r.then(i,i))})}}function wa(e,t){var n=t.deletions;if(n!==null)for(var r=0;ri&&(i=o),r&=~s}if(r=i,r=Lr()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*ige(r/1960))-r,10e?16:e,Gc===null)var r=!1;else{if(e=Gc,Gc=null,CE=0,vn&6)throw Error(Re(331));var i=vn;for(vn|=4,qe=e.current;qe!==null;){var s=qe,o=s.child;if(qe.flags&16){var a=s.deletions;if(a!==null){for(var u=0;uLr()-t$?Kd(e,0):e$|=n),Xs(e,t)}function zY(e,t){t===0&&(e.mode&1?(t=z1,z1<<=1,!(z1&130023424)&&(z1=4194304)):t=1);var n=_s();e=Hl(e,t),e!==null&&(A_(e,t,n),Xs(e,n))}function cge(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),zY(e,n)}function fge(e,t){var n=0;switch(e.tag){case 13:var r=e.stateNode,i=e.memoizedState;i!==null&&(n=i.retryLane);break;case 19:r=e.stateNode;break;default:throw Error(Re(314))}r!==null&&r.delete(t),zY(e,n)}var HY;HY=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||Ks.current)Hs=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return Hs=!1,Jme(e,t,n);Hs=!!(e.flags&131072)}else Hs=!1,dr&&t.flags&1048576&&GG(t,vE,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;bw(e,t),e=t.pendingProps;var i=xm(t,os.current);Qp(t,n),i=YD(null,t,r,e,i,n);var s=KD();return t.flags|=1,typeof i=="object"&&i!==null&&typeof i.render=="function"&&i.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,Qs(r)?(s=!0,gE(t)):s=!1,t.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,zD(t),i.updater=ux,t.stateNode=i,i._reactInternals=t,vR(t,r,e,n),t=wR(null,t,r,!0,s,n)):(t.tag=0,dr&&s&&LD(t),ps(null,t,i,n),t=t.child),t;case 16:r=t.elementType;e:{switch(bw(e,t),e=t.pendingProps,i=r._init,r=i(r._payload),t.type=r,i=t.tag=hge(r),e=Ca(r,e),i){case 0:t=bR(null,t,r,e,n);break e;case 1:t=rF(null,t,r,e,n);break e;case 11:t=tF(null,t,r,e,n);break e;case 14:t=nF(null,t,r,Ca(r.type,e),n);break e}throw Error(Re(306,r,""))}return t;case 0:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:Ca(r,i),bR(e,t,r,i,n);case 1:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:Ca(r,i),rF(e,t,r,i,n);case 3:e:{if(CY(t),e===null)throw Error(Re(387));r=t.pendingProps,s=t.memoizedState,i=s.element,XG(e,t),wE(t,r,null,n);var o=t.memoizedState;if(r=o.element,s.isDehydrated)if(s={element:r,isDehydrated:!1,cache:o.cache,pendingSuspenseBoundaries:o.pendingSuspenseBoundaries,transitions:o.transitions},t.updateQueue.baseState=s,t.memoizedState=s,t.flags&256){i=Om(Error(Re(423)),t),t=iF(e,t,r,n,i);break e}else if(r!==i){i=Om(Error(Re(424)),t),t=iF(e,t,r,n,i);break e}else for(bo=sf(t.stateNode.containerInfo.firstChild),Io=t,dr=!0,Oa=null,n=tY(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(Cm(),r===i){t=Wl(e,t,n);break e}ps(e,t,r,n)}t=t.child}return t;case 5:return nY(t),e===null&&mR(t),r=t.type,i=t.pendingProps,s=e!==null?e.memoizedProps:null,o=i.children,cR(r,i)?o=null:s!==null&&cR(r,s)&&(t.flags|=32),xY(e,t),ps(e,t,o,n),t.child;case 6:return e===null&&mR(t),null;case 13:return AY(e,t,n);case 4:return HD(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=Am(t,null,r,n):ps(e,t,r,n),t.child;case 11:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:Ca(r,i),tF(e,t,r,i,n);case 7:return ps(e,t,t.pendingProps,n),t.child;case 8:return ps(e,t,t.pendingProps.children,n),t.child;case 12:return ps(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(r=t.type._context,i=t.pendingProps,s=t.memoizedProps,o=i.value,Xn(_E,r._currentValue),r._currentValue=o,s!==null)if(Wa(s.value,o)){if(s.children===i.children&&!Ks.current){t=Wl(e,t,n);break e}}else for(s=t.child,s!==null&&(s.return=t);s!==null;){var a=s.dependencies;if(a!==null){o=s.child;for(var u=a.firstContext;u!==null;){if(u.context===r){if(s.tag===1){u=Ml(-1,n&-n),u.tag=2;var l=s.updateQueue;if(l!==null){l=l.shared;var c=l.pending;c===null?u.next=u:(u.next=c.next,c.next=u),l.pending=u}}s.lanes|=n,u=s.alternate,u!==null&&(u.lanes|=n),gR(s.return,n,t),a.lanes|=n;break}u=u.next}}else if(s.tag===10)o=s.type===t.type?null:s.child;else if(s.tag===18){if(o=s.return,o===null)throw Error(Re(341));o.lanes|=n,a=o.alternate,a!==null&&(a.lanes|=n),gR(o,n,t),o=s.sibling}else o=s.child;if(o!==null)o.return=s;else for(o=s;o!==null;){if(o===t){o=null;break}if(s=o.sibling,s!==null){s.return=o.return,o=s;break}o=o.return}s=o}ps(e,t,i.children,n),t=t.child}return t;case 9:return i=t.type,r=t.pendingProps.children,Qp(t,n),i=ra(i),r=r(i),t.flags|=1,ps(e,t,r,n),t.child;case 14:return r=t.type,i=Ca(r,t.pendingProps),i=Ca(r.type,i),nF(e,t,r,i,n);case 15:return TY(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:Ca(r,i),bw(e,t),t.tag=1,Qs(r)?(e=!0,gE(t)):e=!1,Qp(t,n),ZG(t,r,i),vR(t,r,i,n),wR(null,t,r,!0,e,n);case 19:return PY(e,t,n);case 22:return IY(e,t,n)}throw Error(Re(156,t.tag))};function WY(e,t){return yG(e,t)}function dge(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 ea(e,t,n,r){return new dge(e,t,n,r)}function s$(e){return e=e.prototype,!(!e||!e.isReactComponent)}function hge(e){if(typeof e=="function")return s$(e)?1:0;if(e!=null){if(e=e.$$typeof,e===TD)return 11;if(e===ID)return 14}return 2}function lf(e,t){var n=e.alternate;return n===null?(n=ea(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 Sw(e,t,n,r,i,s){var o=2;if(r=e,typeof e=="function")s$(e)&&(o=1);else if(typeof e=="string")o=5;else e:switch(e){case Ep:return Qd(n.children,i,s,t);case SD:o=8,i|=8;break;case V2:return e=ea(12,n,t,i|2),e.elementType=V2,e.lanes=s,e;case z2:return e=ea(13,n,t,i),e.elementType=z2,e.lanes=s,e;case H2:return e=ea(19,n,t,i),e.elementType=H2,e.lanes=s,e;case eG:return dx(n,i,s,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case Jq:o=10;break e;case Zq:o=9;break e;case TD:o=11;break e;case ID:o=14;break e;case kc:o=16,r=null;break e}throw Error(Re(130,e==null?e:typeof e,""))}return t=ea(o,n,t,i),t.elementType=e,t.type=r,t.lanes=s,t}function Qd(e,t,n,r){return e=ea(7,e,r,t),e.lanes=n,e}function dx(e,t,n,r){return e=ea(22,e,r,t),e.elementType=eG,e.lanes=n,e.stateNode={isHidden:!1},e}function SP(e,t,n){return e=ea(6,e,null,t),e.lanes=n,e}function TP(e,t,n){return t=ea(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function pge(e,t,n,r,i){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=iP(0),this.expirationTimes=iP(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=iP(0),this.identifierPrefix=r,this.onRecoverableError=i,this.mutableSourceEagerHydrationData=null}function o$(e,t,n,r,i,s,o,a,u){return e=new pge(e,t,n,a,u),t===1?(t=1,s===!0&&(t|=8)):t=0,s=ea(3,null,null,t),e.current=s,s.stateNode=e,s.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},zD(s),e}function mge(e,t,n){var r=3"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(KY)}catch(e){console.error(e)}}KY(),Gq.exports=Do;var lc=Gq.exports,gF=lc;j2.createRoot=gF.createRoot,j2.hydrateRoot=gF.hydrateRoot;const QY=w.createContext({storageEngine:void 0,setStorageEngine:()=>{}}),sa=()=>w.useContext(QY);function bge({children:e}){const[t,n]=N.useState(void 0),r=N.useMemo(()=>({storageEngine:t,setStorageEngine:n}),[t]);return C.jsx(QY.Provider,{value:r,children:e})}/** * @remix-run/router v1.15.1 * * Copyright (c) Remix Software Inc. @@ -46,7 +46,7 @@ Error generating stack: `+s.message+` * LICENSE.md file in the root directory of this source tree. * * @license MIT - */function yv(){return yv=Object.assign?Object.assign.bind():function(e){for(var t=1;t"u")throw new Error(t)}function XY(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function Ege(){return Math.random().toString(36).substr(2,8)}function _F(e,t){return{usr:e.state,key:e.key,idx:t}}function DR(e,t,n,r){return n===void 0&&(n=null),yv({pathname:typeof e=="string"?e:e.pathname,search:"",hash:""},typeof t=="string"?yg(t):t,{state:n,key:t&&t.key||r||Ege()})}function JY(e){let{pathname:t="/",search:n="",hash:r=""}=e;return n&&n!=="?"&&(t+=n.charAt(0)==="?"?n:"?"+n),r&&r!=="#"&&(t+=r.charAt(0)==="#"?r:"#"+r),t}function yg(e){let t={};if(e){let n=e.indexOf("#");n>=0&&(t.hash=e.substr(n),e=e.substr(0,n));let r=e.indexOf("?");r>=0&&(t.search=e.substr(r),e=e.substr(0,r)),e&&(t.pathname=e)}return t}function Sge(e,t,n,r){r===void 0&&(r={});let{window:i=document.defaultView,v5Compat:s=!1}=r,o=i.history,a=Yc.Pop,u=null,l=c();l==null&&(l=0,o.replaceState(yv({},o.state,{idx:l}),""));function c(){return(o.state||{idx:null}).idx}function f(){a=Yc.Pop;let y=c(),g=y==null?null:y-l;l=y,u&&u({action:a,location:m.location,delta:g})}function d(y,g){a=Yc.Push;let v=DR(m.location,y,g);n&&n(v,y),l=c()+1;let b=_F(v,l),S=m.createHref(v);try{o.pushState(b,"",S)}catch(T){if(T instanceof DOMException&&T.name==="DataCloneError")throw T;i.location.assign(S)}s&&u&&u({action:a,location:m.location,delta:1})}function h(y,g){a=Yc.Replace;let v=DR(m.location,y,g);n&&n(v,y),l=c();let b=_F(v,l),S=m.createHref(v);o.replaceState(b,"",S),s&&u&&u({action:a,location:m.location,delta:0})}function p(y){let g=i.location.origin!=="null"?i.location.origin:i.location.href,v=typeof y=="string"?y:JY(y);return v=v.replace(/ $/,"%20"),Fr(g,"No window.location.(origin|href) available to create URL for href: "+v),new URL(v,g)}let m={get action(){return a},get location(){return e(i,o)},listen(y){if(u)throw new Error("A history only accepts one active listener");return i.addEventListener(vF,f),u=y,()=>{i.removeEventListener(vF,f),u=null}},createHref(y){return t(i,y)},createURL:p,encodeLocation(y){let g=p(y);return{pathname:g.pathname,search:g.search,hash:g.hash}},push:d,replace:h,go(y){return o.go(y)}};return m}var bF;(function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"})(bF||(bF={}));function Tge(e,t,n){n===void 0&&(n="/");let r=typeof t=="string"?yg(t):t,i=tK(r.pathname||"/",n);if(i==null)return null;let s=ZY(e);Ige(s);let o=null;for(let a=0;o==null&&a{let u={relativePath:a===void 0?s.path||"":a,caseSensitive:s.caseSensitive===!0,childrenIndex:o,route:s};u.relativePath.startsWith("/")&&(Fr(u.relativePath.startsWith(r),'Absolute route path "'+u.relativePath+'" nested under path '+('"'+r+'" is not valid. An absolute child route path ')+"must start with the combined path of all its parent routes."),u.relativePath=u.relativePath.slice(r.length));let l=cf([r,u.relativePath]),c=n.concat(u);s.children&&s.children.length>0&&(Fr(s.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+l+'".')),ZY(s.children,t,c,l)),!(s.path==null&&!s.index)&&t.push({path:l,score:Nge(l,s.index),routesMeta:c})};return e.forEach((s,o)=>{var a;if(s.path===""||!((a=s.path)!=null&&a.includes("?")))i(s,o);else for(let u of eK(s.path))i(s,o,u)}),t}function eK(e){let t=e.split("/");if(t.length===0)return[];let[n,...r]=t,i=n.endsWith("?"),s=n.replace(/\?$/,"");if(r.length===0)return i?[s,""]:[s];let o=eK(r.join("/")),a=[];return a.push(...o.map(u=>u===""?s:[s,u].join("/"))),i&&a.push(...o),a.map(u=>e.startsWith("/")&&u===""?"/":u)}function Ige(e){e.sort((t,n)=>t.score!==n.score?n.score-t.score:kge(t.routesMeta.map(r=>r.childrenIndex),n.routesMeta.map(r=>r.childrenIndex)))}const xge=/^:[\w-]+$/,Cge=3,Age=2,Pge=1,Oge=10,Rge=-2,wF=e=>e==="*";function Nge(e,t){let n=e.split("/"),r=n.length;return n.some(wF)&&(r+=Rge),t&&(r+=Age),n.filter(i=>!wF(i)).reduce((i,s)=>i+(xge.test(s)?Cge:s===""?Pge:Oge),r)}function kge(e,t){return e.length===t.length&&e.slice(0,-1).every((r,i)=>r===t[i])?e[e.length-1]-t[t.length-1]:0}function Dge(e,t){let{routesMeta:n}=e,r={},i="/",s=[];for(let o=0;o{let{paramName:d,isOptional:h}=c;if(d==="*"){let m=a[f]||"";o=s.slice(0,s.length-m.length).replace(/(.)\/+$/,"$1")}const p=a[f];return h&&!p?l[d]=void 0:l[d]=(p||"").replace(/%2F/g,"/"),l},{}),pathname:s,pathnameBase:o,pattern:e}}function Lge(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!0),XY(e==="*"||!e.endsWith("*")||e.endsWith("/*"),'Route path "'+e+'" will be treated as if it were '+('"'+e.replace(/\*$/,"/*")+'" because the `*` character must ')+"always follow a `/` in the pattern. To get rid of this warning, "+('please change the route path to "'+e.replace(/\*$/,"/*")+'".'));let r=[],i="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(o,a,u)=>(r.push({paramName:a,isOptional:u!=null}),u?"/?([^\\/]+)?":"/([^\\/]+)"));return e.endsWith("*")?(r.push({paramName:"*"}),i+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?i+="\\/*$":e!==""&&e!=="/"&&(i+="(?:(?=\\/|$))"),[new RegExp(i,t?void 0:"i"),r]}function Mge(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return XY(!1,'The URL path "'+e+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent '+("encoding ("+t+").")),e}}function tK(e,t){if(t==="/")return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=t.endsWith("/")?t.length-1:t.length,r=e.charAt(n);return r&&r!=="/"?null:e.slice(n)||"/"}function Fge(e,t){t===void 0&&(t="/");let{pathname:n,search:r="",hash:i=""}=typeof e=="string"?yg(e):e;return{pathname:n?n.startsWith("/")?n:Bge(n,t):t,search:Vge(r),hash:zge(i)}}function Bge(e,t){let n=t.replace(/\/+$/,"").split("/");return e.split("/").forEach(i=>{i===".."?n.length>1&&n.pop():i!=="."&&n.push(i)}),n.length>1?n.join("/"):"/"}function IP(e,t,n,r){return"Cannot include a '"+e+"' character in a manually specified "+("`to."+t+"` field ["+JSON.stringify(r)+"]. Please separate it out to the ")+("`to."+n+"` field. Alternatively you may provide the full path as ")+'a string in and the router will parse it for you.'}function jge(e){return e.filter((t,n)=>n===0||t.route.path&&t.route.path.length>0)}function f$(e,t){let n=jge(e);return t?n.map((r,i)=>i===e.length-1?r.pathname:r.pathnameBase):n.map(r=>r.pathnameBase)}function d$(e,t,n,r){r===void 0&&(r=!1);let i;typeof e=="string"?i=yg(e):(i=yv({},e),Fr(!i.pathname||!i.pathname.includes("?"),IP("?","pathname","search",i)),Fr(!i.pathname||!i.pathname.includes("#"),IP("#","pathname","hash",i)),Fr(!i.search||!i.search.includes("#"),IP("#","search","hash",i)));let s=e===""||i.pathname==="",o=s?"/":i.pathname,a;if(o==null)a=n;else{let f=t.length-1;if(!r&&o.startsWith("..")){let d=o.split("/");for(;d[0]==="..";)d.shift(),f-=1;i.pathname=d.join("/")}a=f>=0?t[f]:"/"}let u=Fge(i,a),l=o&&o!=="/"&&o.endsWith("/"),c=(s||o===".")&&n.endsWith("/");return!u.pathname.endsWith("/")&&(l||c)&&(u.pathname+="/"),u}const cf=e=>e.join("/").replace(/\/\/+/g,"/"),Uge=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),Vge=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,zge=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e;function Hge(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}const nK=["post","put","patch","delete"];new Set(nK);const Wge=["get",...nK];new Set(Wge);/** + */function yv(){return yv=Object.assign?Object.assign.bind():function(e){for(var t=1;t"u")throw new Error(t)}function XY(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function Ege(){return Math.random().toString(36).substr(2,8)}function vF(e,t){return{usr:e.state,key:e.key,idx:t}}function kR(e,t,n,r){return n===void 0&&(n=null),yv({pathname:typeof e=="string"?e:e.pathname,search:"",hash:""},typeof t=="string"?yg(t):t,{state:n,key:t&&t.key||r||Ege()})}function JY(e){let{pathname:t="/",search:n="",hash:r=""}=e;return n&&n!=="?"&&(t+=n.charAt(0)==="?"?n:"?"+n),r&&r!=="#"&&(t+=r.charAt(0)==="#"?r:"#"+r),t}function yg(e){let t={};if(e){let n=e.indexOf("#");n>=0&&(t.hash=e.substr(n),e=e.substr(0,n));let r=e.indexOf("?");r>=0&&(t.search=e.substr(r),e=e.substr(0,r)),e&&(t.pathname=e)}return t}function Sge(e,t,n,r){r===void 0&&(r={});let{window:i=document.defaultView,v5Compat:s=!1}=r,o=i.history,a=Yc.Pop,u=null,l=c();l==null&&(l=0,o.replaceState(yv({},o.state,{idx:l}),""));function c(){return(o.state||{idx:null}).idx}function f(){a=Yc.Pop;let y=c(),g=y==null?null:y-l;l=y,u&&u({action:a,location:m.location,delta:g})}function d(y,g){a=Yc.Push;let v=kR(m.location,y,g);n&&n(v,y),l=c()+1;let b=vF(v,l),S=m.createHref(v);try{o.pushState(b,"",S)}catch(T){if(T instanceof DOMException&&T.name==="DataCloneError")throw T;i.location.assign(S)}s&&u&&u({action:a,location:m.location,delta:1})}function h(y,g){a=Yc.Replace;let v=kR(m.location,y,g);n&&n(v,y),l=c();let b=vF(v,l),S=m.createHref(v);o.replaceState(b,"",S),s&&u&&u({action:a,location:m.location,delta:0})}function p(y){let g=i.location.origin!=="null"?i.location.origin:i.location.href,v=typeof y=="string"?y:JY(y);return v=v.replace(/ $/,"%20"),Fr(g,"No window.location.(origin|href) available to create URL for href: "+v),new URL(v,g)}let m={get action(){return a},get location(){return e(i,o)},listen(y){if(u)throw new Error("A history only accepts one active listener");return i.addEventListener(yF,f),u=y,()=>{i.removeEventListener(yF,f),u=null}},createHref(y){return t(i,y)},createURL:p,encodeLocation(y){let g=p(y);return{pathname:g.pathname,search:g.search,hash:g.hash}},push:d,replace:h,go(y){return o.go(y)}};return m}var _F;(function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"})(_F||(_F={}));function Tge(e,t,n){n===void 0&&(n="/");let r=typeof t=="string"?yg(t):t,i=tK(r.pathname||"/",n);if(i==null)return null;let s=ZY(e);Ige(s);let o=null;for(let a=0;o==null&&a{let u={relativePath:a===void 0?s.path||"":a,caseSensitive:s.caseSensitive===!0,childrenIndex:o,route:s};u.relativePath.startsWith("/")&&(Fr(u.relativePath.startsWith(r),'Absolute route path "'+u.relativePath+'" nested under path '+('"'+r+'" is not valid. An absolute child route path ')+"must start with the combined path of all its parent routes."),u.relativePath=u.relativePath.slice(r.length));let l=cf([r,u.relativePath]),c=n.concat(u);s.children&&s.children.length>0&&(Fr(s.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+l+'".')),ZY(s.children,t,c,l)),!(s.path==null&&!s.index)&&t.push({path:l,score:Nge(l,s.index),routesMeta:c})};return e.forEach((s,o)=>{var a;if(s.path===""||!((a=s.path)!=null&&a.includes("?")))i(s,o);else for(let u of eK(s.path))i(s,o,u)}),t}function eK(e){let t=e.split("/");if(t.length===0)return[];let[n,...r]=t,i=n.endsWith("?"),s=n.replace(/\?$/,"");if(r.length===0)return i?[s,""]:[s];let o=eK(r.join("/")),a=[];return a.push(...o.map(u=>u===""?s:[s,u].join("/"))),i&&a.push(...o),a.map(u=>e.startsWith("/")&&u===""?"/":u)}function Ige(e){e.sort((t,n)=>t.score!==n.score?n.score-t.score:kge(t.routesMeta.map(r=>r.childrenIndex),n.routesMeta.map(r=>r.childrenIndex)))}const xge=/^:[\w-]+$/,Cge=3,Age=2,Pge=1,Oge=10,Rge=-2,bF=e=>e==="*";function Nge(e,t){let n=e.split("/"),r=n.length;return n.some(bF)&&(r+=Rge),t&&(r+=Age),n.filter(i=>!bF(i)).reduce((i,s)=>i+(xge.test(s)?Cge:s===""?Pge:Oge),r)}function kge(e,t){return e.length===t.length&&e.slice(0,-1).every((r,i)=>r===t[i])?e[e.length-1]-t[t.length-1]:0}function Dge(e,t){let{routesMeta:n}=e,r={},i="/",s=[];for(let o=0;o{let{paramName:d,isOptional:h}=c;if(d==="*"){let m=a[f]||"";o=s.slice(0,s.length-m.length).replace(/(.)\/+$/,"$1")}const p=a[f];return h&&!p?l[d]=void 0:l[d]=(p||"").replace(/%2F/g,"/"),l},{}),pathname:s,pathnameBase:o,pattern:e}}function Lge(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!0),XY(e==="*"||!e.endsWith("*")||e.endsWith("/*"),'Route path "'+e+'" will be treated as if it were '+('"'+e.replace(/\*$/,"/*")+'" because the `*` character must ')+"always follow a `/` in the pattern. To get rid of this warning, "+('please change the route path to "'+e.replace(/\*$/,"/*")+'".'));let r=[],i="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(o,a,u)=>(r.push({paramName:a,isOptional:u!=null}),u?"/?([^\\/]+)?":"/([^\\/]+)"));return e.endsWith("*")?(r.push({paramName:"*"}),i+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?i+="\\/*$":e!==""&&e!=="/"&&(i+="(?:(?=\\/|$))"),[new RegExp(i,t?void 0:"i"),r]}function Mge(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return XY(!1,'The URL path "'+e+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent '+("encoding ("+t+").")),e}}function tK(e,t){if(t==="/")return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=t.endsWith("/")?t.length-1:t.length,r=e.charAt(n);return r&&r!=="/"?null:e.slice(n)||"/"}function Fge(e,t){t===void 0&&(t="/");let{pathname:n,search:r="",hash:i=""}=typeof e=="string"?yg(e):e;return{pathname:n?n.startsWith("/")?n:Bge(n,t):t,search:Vge(r),hash:zge(i)}}function Bge(e,t){let n=t.replace(/\/+$/,"").split("/");return e.split("/").forEach(i=>{i===".."?n.length>1&&n.pop():i!=="."&&n.push(i)}),n.length>1?n.join("/"):"/"}function IP(e,t,n,r){return"Cannot include a '"+e+"' character in a manually specified "+("`to."+t+"` field ["+JSON.stringify(r)+"]. Please separate it out to the ")+("`to."+n+"` field. Alternatively you may provide the full path as ")+'a string in and the router will parse it for you.'}function jge(e){return e.filter((t,n)=>n===0||t.route.path&&t.route.path.length>0)}function c$(e,t){let n=jge(e);return t?n.map((r,i)=>i===e.length-1?r.pathname:r.pathnameBase):n.map(r=>r.pathnameBase)}function f$(e,t,n,r){r===void 0&&(r=!1);let i;typeof e=="string"?i=yg(e):(i=yv({},e),Fr(!i.pathname||!i.pathname.includes("?"),IP("?","pathname","search",i)),Fr(!i.pathname||!i.pathname.includes("#"),IP("#","pathname","hash",i)),Fr(!i.search||!i.search.includes("#"),IP("#","search","hash",i)));let s=e===""||i.pathname==="",o=s?"/":i.pathname,a;if(o==null)a=n;else{let f=t.length-1;if(!r&&o.startsWith("..")){let d=o.split("/");for(;d[0]==="..";)d.shift(),f-=1;i.pathname=d.join("/")}a=f>=0?t[f]:"/"}let u=Fge(i,a),l=o&&o!=="/"&&o.endsWith("/"),c=(s||o===".")&&n.endsWith("/");return!u.pathname.endsWith("/")&&(l||c)&&(u.pathname+="/"),u}const cf=e=>e.join("/").replace(/\/\/+/g,"/"),Uge=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),Vge=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,zge=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e;function Hge(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}const nK=["post","put","patch","delete"];new Set(nK);const Wge=["get",...nK];new Set(Wge);/** * React Router v6.22.1 * * Copyright (c) Remix Software Inc. @@ -55,7 +55,7 @@ Error generating stack: `+s.message+` * LICENSE.md file in the root directory of this source tree. * * @license MIT - */function vv(){return vv=Object.assign?Object.assign.bind():function(e){for(var t=1;t{a.current=!0}),w.useCallback(function(l,c){if(c===void 0&&(c={}),!a.current)return;if(typeof l=="number"){r.go(l);return}let f=d$(l,JSON.parse(o),s,c.relative==="path");e==null&&t!=="/"&&(f.pathname=f.pathname==="/"?t:cf([t,f.pathname])),(c.replace?r.replace:r.push)(f,c.state,c)},[t,r,o,s,e])}const Kge=w.createContext(null);function Qge(e){let t=w.useContext(cl).outlet;return t&&w.createElement(Kge.Provider,{value:e},t)}function uh(){let{matches:e}=w.useContext(cl),t=e[e.length-1];return t?t.params:{}}function Xge(e,t){let{relative:n}=t===void 0?{}:t,{future:r}=w.useContext(Rh),{matches:i}=w.useContext(cl),{pathname:s}=Nh(),o=JSON.stringify(f$(i,r.v7_relativeSplatPath));return w.useMemo(()=>d$(e,JSON.parse(o),s,n==="path"),[e,o,s,n])}function sK(e,t){return Jge(e,t)}function Jge(e,t,n,r){vg()||Fr(!1);let{navigator:i}=w.useContext(Rh),{matches:s}=w.useContext(cl),o=s[s.length-1],a=o?o.params:{};o&&o.pathname;let u=o?o.pathnameBase:"/";o&&o.route;let l=Nh(),c;if(t){var f;let y=typeof t=="string"?yg(t):t;u==="/"||(f=y.pathname)!=null&&f.startsWith(u)||Fr(!1),c=y}else c=l;let d=c.pathname||"/",h=d;if(u!=="/"){let y=u.replace(/^\//,"").split("/");h="/"+d.replace(/^\//,"").split("/").slice(y.length).join("/")}let p=Tge(e,{pathname:h}),m=r0e(p&&p.map(y=>Object.assign({},y,{params:Object.assign({},a,y.params),pathname:cf([u,i.encodeLocation?i.encodeLocation(y.pathname).pathname:y.pathname]),pathnameBase:y.pathnameBase==="/"?u:cf([u,i.encodeLocation?i.encodeLocation(y.pathnameBase).pathname:y.pathnameBase])})),s,n,r);return t&&m?w.createElement(yx.Provider,{value:{location:vv({pathname:"/",search:"",hash:"",state:null,key:"default"},c),navigationType:Yc.Pop}},m):m}function Zge(){let e=a0e(),t=Hge(e)?e.status+" "+e.statusText:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null,i={padding:"0.5rem",backgroundColor:"rgba(200,200,200, 0.5)"};return w.createElement(w.Fragment,null,w.createElement("h2",null,"Unexpected Application Error!"),w.createElement("h3",{style:{fontStyle:"italic"}},t),n?w.createElement("pre",{style:i},n):null,null)}const e0e=w.createElement(Zge,null);class t0e extends w.Component{constructor(t){super(t),this.state={location:t.location,revalidation:t.revalidation,error:t.error}}static getDerivedStateFromError(t){return{error:t}}static getDerivedStateFromProps(t,n){return n.location!==t.location||n.revalidation!=="idle"&&t.revalidation==="idle"?{error:t.error,location:t.location,revalidation:t.revalidation}:{error:t.error!==void 0?t.error:n.error,location:n.location,revalidation:t.revalidation||n.revalidation}}componentDidCatch(t,n){console.error("React Router caught the following error during render",t,n)}render(){return this.state.error!==void 0?w.createElement(cl.Provider,{value:this.props.routeContext},w.createElement(rK.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function n0e(e){let{routeContext:t,match:n,children:r}=e,i=w.useContext(h$);return i&&i.static&&i.staticContext&&(n.route.errorElement||n.route.ErrorBoundary)&&(i.staticContext._deepestRenderedBoundaryId=n.route.id),w.createElement(cl.Provider,{value:t},r)}function r0e(e,t,n,r){var i;if(t===void 0&&(t=[]),n===void 0&&(n=null),r===void 0&&(r=null),e==null){var s;if((s=n)!=null&&s.errors)e=n.matches;else return null}let o=e,a=(i=n)==null?void 0:i.errors;if(a!=null){let c=o.findIndex(f=>f.route.id&&(a==null?void 0:a[f.route.id]));c>=0||Fr(!1),o=o.slice(0,Math.min(o.length,c+1))}let u=!1,l=-1;if(n&&r&&r.v7_partialHydration)for(let c=0;c=0?o=o.slice(0,l+1):o=[o[0]];break}}}return o.reduceRight((c,f,d)=>{let h,p=!1,m=null,y=null;n&&(h=a&&f.route.id?a[f.route.id]:void 0,m=f.route.errorElement||e0e,u&&(l<0&&d===0?(l0e("route-fallback",!1),p=!0,y=null):l===d&&(p=!0,y=f.route.hydrateFallbackElement||null)));let g=t.concat(o.slice(0,d+1)),v=()=>{let b;return h?b=m:p?b=y:f.route.Component?b=w.createElement(f.route.Component,null):f.route.element?b=f.route.element:b=c,w.createElement(n0e,{match:f,routeContext:{outlet:c,matches:g,isDataRoute:n!=null},children:b})};return n&&(f.route.ErrorBoundary||f.route.errorElement||d===0)?w.createElement(t0e,{location:n.location,revalidation:n.revalidation,component:m,error:h,children:v(),routeContext:{outlet:null,matches:g,isDataRoute:!0}}):v()},null)}var oK=function(e){return e.UseBlocker="useBlocker",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e}(oK||{}),OE=function(e){return e.UseBlocker="useBlocker",e.UseLoaderData="useLoaderData",e.UseActionData="useActionData",e.UseRouteError="useRouteError",e.UseNavigation="useNavigation",e.UseRouteLoaderData="useRouteLoaderData",e.UseMatches="useMatches",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e.UseRouteId="useRouteId",e}(OE||{});function i0e(e){let t=w.useContext(h$);return t||Fr(!1),t}function s0e(e){let t=w.useContext(qge);return t||Fr(!1),t}function o0e(e){let t=w.useContext(cl);return t||Fr(!1),t}function aK(e){let t=o0e(),n=t.matches[t.matches.length-1];return n.route.id||Fr(!1),n.route.id}function a0e(){var e;let t=w.useContext(rK),n=s0e(OE.UseRouteError),r=aK(OE.UseRouteError);return t!==void 0?t:(e=n.errors)==null?void 0:e[r]}function u0e(){let{router:e}=i0e(oK.UseNavigateStable),t=aK(OE.UseNavigateStable),n=w.useRef(!1);return iK(()=>{n.current=!0}),w.useCallback(function(i,s){s===void 0&&(s={}),n.current&&(typeof i=="number"?e.navigate(i):e.navigate(i,vv({fromRouteId:t},s)))},[e,t])}const EF={};function l0e(e,t,n){!t&&!EF[e]&&(EF[e]=!0)}function c0e(e){let{to:t,replace:n,state:r,relative:i}=e;vg()||Fr(!1);let{future:s,static:o}=w.useContext(Rh),{matches:a}=w.useContext(cl),{pathname:u}=Nh(),l=Kf(),c=d$(t,f$(a,s.v7_relativeSplatPath),u,i==="path"),f=JSON.stringify(c);return w.useEffect(()=>l(JSON.parse(f),{replace:n,state:r,relative:i}),[l,f,i,n,r]),null}function f0e(e){return Qge(e.context)}function $R(e){Fr(!1)}function d0e(e){let{basename:t="/",children:n=null,location:r,navigationType:i=Yc.Pop,navigator:s,static:o=!1,future:a}=e;vg()&&Fr(!1);let u=t.replace(/^\/*/,"/"),l=w.useMemo(()=>({basename:u,navigator:s,static:o,future:vv({v7_relativeSplatPath:!1},a)}),[u,a,s,o]);typeof r=="string"&&(r=yg(r));let{pathname:c="/",search:f="",hash:d="",state:h=null,key:p="default"}=r,m=w.useMemo(()=>{let y=tK(c,u);return y==null?null:{location:{pathname:y,search:f,hash:d,state:h,key:p},navigationType:i}},[u,c,f,d,h,p,i]);return m==null?null:w.createElement(Rh.Provider,{value:l},w.createElement(yx.Provider,{children:n,value:m}))}function h0e(e){let{children:t,location:n}=e;return sK(LR(t),n)}new Promise(()=>{});function LR(e,t){t===void 0&&(t=[]);let n=[];return w.Children.forEach(e,(r,i)=>{if(!w.isValidElement(r))return;let s=[...t,i];if(r.type===w.Fragment){n.push.apply(n,LR(r.props.children,s));return}r.type!==$R&&Fr(!1),!r.props.index||!r.props.children||Fr(!1);let o={id:r.props.id||s.join("-"),caseSensitive:r.props.caseSensitive,element:r.props.element,Component:r.props.Component,index:r.props.index,path:r.props.path,loader:r.props.loader,action:r.props.action,errorElement:r.props.errorElement,ErrorBoundary:r.props.ErrorBoundary,hasErrorBoundary:r.props.ErrorBoundary!=null||r.props.errorElement!=null,shouldRevalidate:r.props.shouldRevalidate,handle:r.props.handle,lazy:r.props.lazy};r.props.children&&(o.children=LR(r.props.children,s)),n.push(o)}),n}/** + */function vv(){return vv=Object.assign?Object.assign.bind():function(e){for(var t=1;t{a.current=!0}),w.useCallback(function(l,c){if(c===void 0&&(c={}),!a.current)return;if(typeof l=="number"){r.go(l);return}let f=f$(l,JSON.parse(o),s,c.relative==="path");e==null&&t!=="/"&&(f.pathname=f.pathname==="/"?t:cf([t,f.pathname])),(c.replace?r.replace:r.push)(f,c.state,c)},[t,r,o,s,e])}const Kge=w.createContext(null);function Qge(e){let t=w.useContext(cl).outlet;return t&&w.createElement(Kge.Provider,{value:e},t)}function uh(){let{matches:e}=w.useContext(cl),t=e[e.length-1];return t?t.params:{}}function Xge(e,t){let{relative:n}=t===void 0?{}:t,{future:r}=w.useContext(Rh),{matches:i}=w.useContext(cl),{pathname:s}=Nh(),o=JSON.stringify(c$(i,r.v7_relativeSplatPath));return w.useMemo(()=>f$(e,JSON.parse(o),s,n==="path"),[e,o,s,n])}function sK(e,t){return Jge(e,t)}function Jge(e,t,n,r){vg()||Fr(!1);let{navigator:i}=w.useContext(Rh),{matches:s}=w.useContext(cl),o=s[s.length-1],a=o?o.params:{};o&&o.pathname;let u=o?o.pathnameBase:"/";o&&o.route;let l=Nh(),c;if(t){var f;let y=typeof t=="string"?yg(t):t;u==="/"||(f=y.pathname)!=null&&f.startsWith(u)||Fr(!1),c=y}else c=l;let d=c.pathname||"/",h=d;if(u!=="/"){let y=u.replace(/^\//,"").split("/");h="/"+d.replace(/^\//,"").split("/").slice(y.length).join("/")}let p=Tge(e,{pathname:h}),m=r0e(p&&p.map(y=>Object.assign({},y,{params:Object.assign({},a,y.params),pathname:cf([u,i.encodeLocation?i.encodeLocation(y.pathname).pathname:y.pathname]),pathnameBase:y.pathnameBase==="/"?u:cf([u,i.encodeLocation?i.encodeLocation(y.pathnameBase).pathname:y.pathnameBase])})),s,n,r);return t&&m?w.createElement(yx.Provider,{value:{location:vv({pathname:"/",search:"",hash:"",state:null,key:"default"},c),navigationType:Yc.Pop}},m):m}function Zge(){let e=a0e(),t=Hge(e)?e.status+" "+e.statusText:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null,i={padding:"0.5rem",backgroundColor:"rgba(200,200,200, 0.5)"};return w.createElement(w.Fragment,null,w.createElement("h2",null,"Unexpected Application Error!"),w.createElement("h3",{style:{fontStyle:"italic"}},t),n?w.createElement("pre",{style:i},n):null,null)}const e0e=w.createElement(Zge,null);class t0e extends w.Component{constructor(t){super(t),this.state={location:t.location,revalidation:t.revalidation,error:t.error}}static getDerivedStateFromError(t){return{error:t}}static getDerivedStateFromProps(t,n){return n.location!==t.location||n.revalidation!=="idle"&&t.revalidation==="idle"?{error:t.error,location:t.location,revalidation:t.revalidation}:{error:t.error!==void 0?t.error:n.error,location:n.location,revalidation:t.revalidation||n.revalidation}}componentDidCatch(t,n){console.error("React Router caught the following error during render",t,n)}render(){return this.state.error!==void 0?w.createElement(cl.Provider,{value:this.props.routeContext},w.createElement(rK.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function n0e(e){let{routeContext:t,match:n,children:r}=e,i=w.useContext(d$);return i&&i.static&&i.staticContext&&(n.route.errorElement||n.route.ErrorBoundary)&&(i.staticContext._deepestRenderedBoundaryId=n.route.id),w.createElement(cl.Provider,{value:t},r)}function r0e(e,t,n,r){var i;if(t===void 0&&(t=[]),n===void 0&&(n=null),r===void 0&&(r=null),e==null){var s;if((s=n)!=null&&s.errors)e=n.matches;else return null}let o=e,a=(i=n)==null?void 0:i.errors;if(a!=null){let c=o.findIndex(f=>f.route.id&&(a==null?void 0:a[f.route.id]));c>=0||Fr(!1),o=o.slice(0,Math.min(o.length,c+1))}let u=!1,l=-1;if(n&&r&&r.v7_partialHydration)for(let c=0;c=0?o=o.slice(0,l+1):o=[o[0]];break}}}return o.reduceRight((c,f,d)=>{let h,p=!1,m=null,y=null;n&&(h=a&&f.route.id?a[f.route.id]:void 0,m=f.route.errorElement||e0e,u&&(l<0&&d===0?(l0e("route-fallback",!1),p=!0,y=null):l===d&&(p=!0,y=f.route.hydrateFallbackElement||null)));let g=t.concat(o.slice(0,d+1)),v=()=>{let b;return h?b=m:p?b=y:f.route.Component?b=w.createElement(f.route.Component,null):f.route.element?b=f.route.element:b=c,w.createElement(n0e,{match:f,routeContext:{outlet:c,matches:g,isDataRoute:n!=null},children:b})};return n&&(f.route.ErrorBoundary||f.route.errorElement||d===0)?w.createElement(t0e,{location:n.location,revalidation:n.revalidation,component:m,error:h,children:v(),routeContext:{outlet:null,matches:g,isDataRoute:!0}}):v()},null)}var oK=function(e){return e.UseBlocker="useBlocker",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e}(oK||{}),OE=function(e){return e.UseBlocker="useBlocker",e.UseLoaderData="useLoaderData",e.UseActionData="useActionData",e.UseRouteError="useRouteError",e.UseNavigation="useNavigation",e.UseRouteLoaderData="useRouteLoaderData",e.UseMatches="useMatches",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e.UseRouteId="useRouteId",e}(OE||{});function i0e(e){let t=w.useContext(d$);return t||Fr(!1),t}function s0e(e){let t=w.useContext(qge);return t||Fr(!1),t}function o0e(e){let t=w.useContext(cl);return t||Fr(!1),t}function aK(e){let t=o0e(),n=t.matches[t.matches.length-1];return n.route.id||Fr(!1),n.route.id}function a0e(){var e;let t=w.useContext(rK),n=s0e(OE.UseRouteError),r=aK(OE.UseRouteError);return t!==void 0?t:(e=n.errors)==null?void 0:e[r]}function u0e(){let{router:e}=i0e(oK.UseNavigateStable),t=aK(OE.UseNavigateStable),n=w.useRef(!1);return iK(()=>{n.current=!0}),w.useCallback(function(i,s){s===void 0&&(s={}),n.current&&(typeof i=="number"?e.navigate(i):e.navigate(i,vv({fromRouteId:t},s)))},[e,t])}const wF={};function l0e(e,t,n){!t&&!wF[e]&&(wF[e]=!0)}function c0e(e){let{to:t,replace:n,state:r,relative:i}=e;vg()||Fr(!1);let{future:s,static:o}=w.useContext(Rh),{matches:a}=w.useContext(cl),{pathname:u}=Nh(),l=Kf(),c=f$(t,c$(a,s.v7_relativeSplatPath),u,i==="path"),f=JSON.stringify(c);return w.useEffect(()=>l(JSON.parse(f),{replace:n,state:r,relative:i}),[l,f,i,n,r]),null}function f0e(e){return Qge(e.context)}function DR(e){Fr(!1)}function d0e(e){let{basename:t="/",children:n=null,location:r,navigationType:i=Yc.Pop,navigator:s,static:o=!1,future:a}=e;vg()&&Fr(!1);let u=t.replace(/^\/*/,"/"),l=w.useMemo(()=>({basename:u,navigator:s,static:o,future:vv({v7_relativeSplatPath:!1},a)}),[u,a,s,o]);typeof r=="string"&&(r=yg(r));let{pathname:c="/",search:f="",hash:d="",state:h=null,key:p="default"}=r,m=w.useMemo(()=>{let y=tK(c,u);return y==null?null:{location:{pathname:y,search:f,hash:d,state:h,key:p},navigationType:i}},[u,c,f,d,h,p,i]);return m==null?null:w.createElement(Rh.Provider,{value:l},w.createElement(yx.Provider,{children:n,value:m}))}function h0e(e){let{children:t,location:n}=e;return sK($R(t),n)}new Promise(()=>{});function $R(e,t){t===void 0&&(t=[]);let n=[];return w.Children.forEach(e,(r,i)=>{if(!w.isValidElement(r))return;let s=[...t,i];if(r.type===w.Fragment){n.push.apply(n,$R(r.props.children,s));return}r.type!==DR&&Fr(!1),!r.props.index||!r.props.children||Fr(!1);let o={id:r.props.id||s.join("-"),caseSensitive:r.props.caseSensitive,element:r.props.element,Component:r.props.Component,index:r.props.index,path:r.props.path,loader:r.props.loader,action:r.props.action,errorElement:r.props.errorElement,ErrorBoundary:r.props.ErrorBoundary,hasErrorBoundary:r.props.ErrorBoundary!=null||r.props.errorElement!=null,shouldRevalidate:r.props.shouldRevalidate,handle:r.props.handle,lazy:r.props.lazy};r.props.children&&(o.children=$R(r.props.children,s)),n.push(o)}),n}/** * React Router DOM v6.22.1 * * Copyright (c) Remix Software Inc. @@ -64,20 +64,20 @@ Error generating stack: `+s.message+` * LICENSE.md file in the root directory of this source tree. * * @license MIT - */function MR(e){return e===void 0&&(e=""),new URLSearchParams(typeof e=="string"||Array.isArray(e)||e instanceof URLSearchParams?e:Object.keys(e).reduce((t,n)=>{let r=e[n];return t.concat(Array.isArray(r)?r.map(i=>[n,i]):[[n,r]])},[]))}function p0e(e,t){let n=MR(e);return t&&t.forEach((r,i)=>{n.has(i)||t.getAll(i).forEach(s=>{n.append(i,s)})}),n}const m0e="6";try{window.__reactRouterVersion=m0e}catch{}const g0e="startTransition",SF=Zy[g0e];function y0e(e){let{basename:t,children:n,future:r,window:i}=e,s=w.useRef();s.current==null&&(s.current=wge({window:i,v5Compat:!0}));let o=s.current,[a,u]=w.useState({action:o.action,location:o.location}),{v7_startTransition:l}=r||{},c=w.useCallback(f=>{l&&SF?SF(()=>u(f)):u(f)},[u,l]);return w.useLayoutEffect(()=>o.listen(c),[o,c]),w.createElement(d0e,{basename:t,children:n,location:a.location,navigationType:a.action,navigator:o,future:r})}var TF;(function(e){e.UseScrollRestoration="useScrollRestoration",e.UseSubmit="useSubmit",e.UseSubmitFetcher="useSubmitFetcher",e.UseFetcher="useFetcher",e.useViewTransitionState="useViewTransitionState"})(TF||(TF={}));var IF;(function(e){e.UseFetcher="useFetcher",e.UseFetchers="useFetchers",e.UseScrollRestoration="useScrollRestoration"})(IF||(IF={}));function p$(e){let t=w.useRef(MR(e)),n=w.useRef(!1),r=Nh(),i=w.useMemo(()=>p0e(r.search,n.current?null:t.current),[r.search]),s=Kf(),o=w.useCallback((a,u)=>{const l=MR(typeof a=="function"?a(i):a);n.current=!0,s("?"+l,u)},[s,i]);return[i,o]}function RE(e,t){let n=e;for(;(n=n.parentElement)&&!n.matches(t););return n}function v0e(e,t,n){for(let r=e-1;r>=0;r-=1)if(!t[r].disabled)return r;if(n){for(let r=t.length-1;r>-1;r-=1)if(!t[r].disabled)return r}return e}function _0e(e,t,n){for(let r=e+1;r{var u;n==null||n(a);const l=Array.from(((u=RE(a.currentTarget,e))==null?void 0:u.querySelectorAll(t))||[]).filter(m=>b0e(a.currentTarget,m,e)),c=l.findIndex(m=>a.currentTarget===m),f=_0e(c,l,r),d=v0e(c,l,r),h=s==="rtl"?d:f,p=s==="rtl"?f:d;switch(a.key){case"ArrowRight":{o==="horizontal"&&(a.stopPropagation(),a.preventDefault(),l[h].focus(),i&&l[h].click());break}case"ArrowLeft":{o==="horizontal"&&(a.stopPropagation(),a.preventDefault(),l[p].focus(),i&&l[p].click());break}case"ArrowUp":{o==="vertical"&&(a.stopPropagation(),a.preventDefault(),l[d].focus(),i&&l[d].click());break}case"ArrowDown":{o==="vertical"&&(a.stopPropagation(),a.preventDefault(),l[f].focus(),i&&l[f].click());break}case"Home":{a.stopPropagation(),a.preventDefault(),!l[0].disabled&&l[0].focus();break}case"End":{a.stopPropagation(),a.preventDefault();const m=l.length-1;!l[m].disabled&&l[m].focus();break}}}}function E0e(e,t,n){var r;return n?Array.from(((r=RE(n,t))==null?void 0:r.querySelectorAll(e))||[]).findIndex(i=>i===n):null}function N_(e){const t=w.createContext(null);return[({children:i,value:s})=>N.createElement(t.Provider,{value:s},i),()=>{const i=w.useContext(t);if(i===null)throw new Error(e);return i}]}function lh(e){return Array.isArray(e)?e:[e]}const S0e=()=>{};function T0e(e,t={active:!0}){return typeof e!="function"||!t.active?t.onKeyDown||S0e:n=>{var r;n.key==="Escape"&&(e(n),(r=t.onTrigger)==null||r.call(t))}}function wo(e,t){return n=>{e==null||e(n),t==null||t(n)}}function I0e(e){return Object.keys(e)}function x0e(){const[e,t]=w.useState(-1);return[e,{setHovered:t,resetHovered:()=>t(-1)}]}function uK({data:e}){const t=[],n=[],r=e.reduce((i,s,o)=>(s.group?i[s.group]?i[s.group].push(o):i[s.group]=[o]:n.push(o),i),{});return Object.keys(r).forEach(i=>{t.push(...r[i].map(s=>e[s]))}),t.push(...n.map(i=>e[i])),t}function _g(e){return Array.isArray(e)||e===null?!1:typeof e=="object"?e.type!==N.Fragment:!1}function lK(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e))for(t=0;t({fontFamily:e.fontFamily||"sans-serif"})}var P0e=Object.defineProperty,xF=Object.getOwnPropertySymbols,O0e=Object.prototype.hasOwnProperty,R0e=Object.prototype.propertyIsEnumerable,CF=(e,t,n)=>t in e?P0e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,AF=(e,t)=>{for(var n in t||(t={}))O0e.call(t,n)&&CF(e,n,t[n]);if(xF)for(var n of xF(t))R0e.call(t,n)&&CF(e,n,t[n]);return e};function N0e(e){return t=>({WebkitTapHighlightColor:"transparent",[t||"&:focus"]:AF({},e.focusRing==="always"||e.focusRing==="auto"?e.focusRingStyles.styles(e):e.focusRingStyles.resetStyles(e)),[t?t.replace(":focus",":focus:not(:focus-visible)"):"&:focus:not(:focus-visible)"]:AF({},e.focusRing==="auto"||e.focusRing==="never"?e.focusRingStyles.resetStyles(e):null)})}function k_(e){return t=>typeof e.primaryShade=="number"?e.primaryShade:e.primaryShade[t||e.colorScheme]}function m$(e){const t=k_(e);return(n,r,i=!0,s=!0)=>{if(typeof n=="string"&&n.includes(".")){const[a,u]=n.split("."),l=parseInt(u,10);if(a in e.colors&&l>=0&&l<10)return e.colors[a][typeof r=="number"&&!s?r:l]}const o=typeof r=="number"?r:t();return n in e.colors?e.colors[n][o]:i?e.colors[e.primaryColor][o]:n}}function fK(e){let t="";for(let n=1;n{const i={from:(r==null?void 0:r.from)||e.defaultGradient.from,to:(r==null?void 0:r.to)||e.defaultGradient.to,deg:(r==null?void 0:r.deg)||e.defaultGradient.deg};return`linear-gradient(${i.deg}deg, ${t(i.from,n(),!1)} 0%, ${t(i.to,n(),!1)} 100%)`}}function g$(e){if(typeof e.size=="number")return e.size;const t=e.sizes[e.size];return t!==void 0?t:e.size||e.sizes.md}function $0e(e){return t=>`@media (min-width: ${g$({size:t,sizes:e.breakpoints})}px)`}function L0e(e){return t=>`@media (max-width: ${g$({size:t,sizes:e.breakpoints})-1}px)`}function M0e(e){return/^#?([0-9A-F]{3}){1,2}$/i.test(e)}function F0e(e){let t=e.replace("#","");if(t.length===3){const o=t.split("");t=[o[0],o[0],o[1],o[1],o[2],o[2]].join("")}const n=parseInt(t,16),r=n>>16&255,i=n>>8&255,s=n&255;return{r,g:i,b:s,a:1}}function B0e(e){const[t,n,r,i]=e.replace(/[^0-9,.]/g,"").split(",").map(Number);return{r:t,g:n,b:r,a:i||1}}function y$(e){return M0e(e)?F0e(e):e.startsWith("rgb")?B0e(e):{r:0,g:0,b:0,a:1}}function fp(e,t){if(typeof e!="string"||t>1||t<0)return"rgba(0, 0, 0, 1)";const{r:n,g:r,b:i}=y$(e);return`rgba(${n}, ${r}, ${i}, ${t})`}function j0e(e=0){return{position:"absolute",top:e,right:e,left:e,bottom:e}}function U0e(e,t){const{r:n,g:r,b:i,a:s}=y$(e),o=1-t,a=u=>Math.round(u*o);return`rgba(${a(n)}, ${a(r)}, ${a(i)}, ${s})`}function V0e(e,t){const{r:n,g:r,b:i,a:s}=y$(e),o=a=>Math.round(a+(255-a)*t);return`rgba(${o(n)}, ${o(r)}, ${o(i)}, ${s})`}function z0e(e){return t=>{if(typeof t=="number")return t;const n=typeof e.defaultRadius=="number"?e.defaultRadius:e.radius[e.defaultRadius]||e.defaultRadius;return e.radius[t]||t||n}}function H0e(e,t){if(typeof e=="string"&&e.includes(".")){const[n,r]=e.split("."),i=parseInt(r,10);if(n in t.colors&&i>=0&&i<10)return{isSplittedColor:!0,key:n,shade:i}}return{isSplittedColor:!1}}function W0e(e){const t=m$(e),n=k_(e),r=dK(e);return({variant:i,color:s,gradient:o,primaryFallback:a})=>{const u=H0e(s,e);switch(i){case"light":return{border:"transparent",background:fp(t(s,e.colorScheme==="dark"?8:0,a,!1),e.colorScheme==="dark"?.2:1),color:s==="dark"?e.colorScheme==="dark"?e.colors.dark[0]:e.colors.dark[9]:t(s,e.colorScheme==="dark"?2:n("light")),hover:fp(t(s,e.colorScheme==="dark"?7:1,a,!1),e.colorScheme==="dark"?.25:.65)};case"subtle":return{border:"transparent",background:"transparent",color:s==="dark"?e.colorScheme==="dark"?e.colors.dark[0]:e.colors.dark[9]:t(s,e.colorScheme==="dark"?2:n("light")),hover:fp(t(s,e.colorScheme==="dark"?8:0,a,!1),e.colorScheme==="dark"?.2:1)};case"outline":return{border:t(s,e.colorScheme==="dark"?5:n("light")),background:"transparent",color:t(s,e.colorScheme==="dark"?5:n("light")),hover:e.colorScheme==="dark"?fp(t(s,5,a,!1),.05):fp(t(s,0,a,!1),.35)};case"default":return{border:e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[4],background:e.colorScheme==="dark"?e.colors.dark[6]:e.white,color:e.colorScheme==="dark"?e.white:e.black,hover:e.colorScheme==="dark"?e.colors.dark[5]:e.colors.gray[0]};case"white":return{border:"transparent",background:e.white,color:t(s,n()),hover:null};case"transparent":return{border:"transparent",color:s==="dark"?e.colorScheme==="dark"?e.colors.dark[0]:e.colors.dark[9]:t(s,e.colorScheme==="dark"?2:n("light")),background:"transparent",hover:null};case"gradient":return{background:r(o),color:e.white,border:"transparent",hover:null};default:{const l=n(),c=u.isSplittedColor?u.shade:l,f=u.isSplittedColor?u.key:s;return{border:"transparent",background:t(f,c,a),color:e.white,hover:t(f,c===9?8:c+1)}}}}}function q0e(e){return t=>{const n=k_(e)(t);return e.colors[e.primaryColor][n]}}function G0e(e){return{"@media (hover: hover)":{"&:hover":e},"@media (hover: none)":{"&:active":e}}}function Y0e(e){return()=>({userSelect:"none",color:e.colorScheme==="dark"?e.colors.dark[3]:e.colors.gray[5]})}const Qr={fontStyles:A0e,themeColor:m$,focusStyles:N0e,linearGradient:k0e,radialGradient:D0e,smallerThan:L0e,largerThan:$0e,rgba:fp,size:g$,cover:j0e,darken:U0e,lighten:V0e,radius:z0e,variant:W0e,primaryShade:k_,hover:G0e,gradient:dK,primaryColor:q0e,placeholderStyles:Y0e};var K0e=Object.defineProperty,Q0e=Object.defineProperties,X0e=Object.getOwnPropertyDescriptors,PF=Object.getOwnPropertySymbols,J0e=Object.prototype.hasOwnProperty,Z0e=Object.prototype.propertyIsEnumerable,OF=(e,t,n)=>t in e?K0e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,eye=(e,t)=>{for(var n in t||(t={}))J0e.call(t,n)&&OF(e,n,t[n]);if(PF)for(var n of PF(t))Z0e.call(t,n)&&OF(e,n,t[n]);return e},tye=(e,t)=>Q0e(e,X0e(t));function nye(e){return tye(eye({},e),{fn:{fontStyles:Qr.fontStyles(e),themeColor:Qr.themeColor(e),focusStyles:Qr.focusStyles(e),largerThan:Qr.largerThan(e),smallerThan:Qr.smallerThan(e),radialGradient:Qr.radialGradient,linearGradient:Qr.linearGradient,gradient:Qr.gradient(e),rgba:Qr.rgba,size:Qr.size,cover:Qr.cover,lighten:Qr.lighten,darken:Qr.darken,primaryShade:Qr.primaryShade(e),radius:Qr.radius(e),variant:Qr.variant(e),hover:Qr.hover,primaryColor:Qr.primaryColor(e),placeholderStyles:Qr.placeholderStyles(e)}})}const hK=["xs","sm","md","lg","xl"],rye={dir:"ltr",primaryShade:{light:6,dark:8},focusRing:"auto",loader:"oval",dateFormat:"MMMM D, YYYY",colorScheme:"light",white:"#fff",black:"#000",defaultRadius:"sm",transitionTimingFunction:"ease",colors:C0e,lineHeight:1.55,fontFamily:"-apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Helvetica, Arial, sans-serif, Apple Color Emoji, Segoe UI Emoji",fontFamilyMonospace:"ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, Liberation Mono, Courier New, monospace",primaryColor:"blue",respectReducedMotion:!0,cursorType:"default",defaultGradient:{from:"indigo",to:"cyan",deg:45},shadows:{xs:"0 1px 3px rgba(0, 0, 0, 0.05), 0 1px 2px rgba(0, 0, 0, 0.1)",sm:"0 1px 3px rgba(0, 0, 0, 0.05), rgba(0, 0, 0, 0.05) 0px 10px 15px -5px, rgba(0, 0, 0, 0.04) 0px 7px 7px -5px",md:"0 1px 3px rgba(0, 0, 0, 0.05), rgba(0, 0, 0, 0.05) 0px 20px 25px -5px, rgba(0, 0, 0, 0.04) 0px 10px 10px -5px",lg:"0 1px 3px rgba(0, 0, 0, 0.05), rgba(0, 0, 0, 0.05) 0px 28px 23px -7px, rgba(0, 0, 0, 0.04) 0px 12px 12px -7px",xl:"0 1px 3px rgba(0, 0, 0, 0.05), rgba(0, 0, 0, 0.05) 0px 36px 28px -7px, rgba(0, 0, 0, 0.04) 0px 17px 17px -7px"},fontSizes:{xs:12,sm:14,md:16,lg:18,xl:20},radius:{xs:2,sm:4,md:8,lg:16,xl:32},spacing:{xs:10,sm:12,md:16,lg:20,xl:24},breakpoints:{xs:576,sm:768,md:992,lg:1200,xl:1400},headings:{fontFamily:"-apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Helvetica, Arial, sans-serif, Apple Color Emoji, Segoe UI Emoji",fontWeight:700,sizes:{h1:{fontSize:34,lineHeight:1.3,fontWeight:void 0},h2:{fontSize:26,lineHeight:1.35,fontWeight:void 0},h3:{fontSize:22,lineHeight:1.4,fontWeight:void 0},h4:{fontSize:18,lineHeight:1.45,fontWeight:void 0},h5:{fontSize:16,lineHeight:1.5,fontWeight:void 0},h6:{fontSize:14,lineHeight:1.5,fontWeight:void 0}}},other:{},components:{},activeStyles:{transform:"translateY(1px)"},datesLocale:"en",globalStyles:void 0,focusRingStyles:{styles:e=>({outlineOffset:2,outline:`2px solid ${e.colors[e.primaryColor][e.colorScheme==="dark"?7:5]}`}),resetStyles:()=>({outline:"none"}),inputStyles:e=>({outline:"none",borderColor:e.colors[e.primaryColor][typeof e.primaryShade=="object"?e.primaryShade[e.colorScheme]:e.primaryShade]})}},pK=nye(rye);function iye(e){if(e.sheet)return e.sheet;for(var t=0;t0?Oi(bg,--no):0,Nm--,Wr===10&&(Nm=1,_x--),Wr}function xo(){return Wr=no2||bv(Wr)>3?"":" "}function yye(e,t){for(;--t&&xo()&&!(Wr<48||Wr>102||Wr>57&&Wr<65||Wr>70&&Wr<97););return D_(e,Tw()+(t<6&&Fu()==32&&xo()==32))}function BR(e){for(;xo();)switch(Wr){case e:return no;case 34:case 39:e!==34&&e!==39&&BR(Wr);break;case 40:e===41&&BR(e);break;case 92:xo();break}return no}function vye(e,t){for(;xo()&&e+Wr!==57;)if(e+Wr===84&&Fu()===47)break;return"/*"+D_(t,no-1)+"*"+vx(e===47?e:xo())}function _ye(e){for(;!bv(Fu());)xo();return D_(e,no)}function bye(e){return bK(xw("",null,null,null,[""],e=_K(e),0,[0],e))}function xw(e,t,n,r,i,s,o,a,u){for(var l=0,c=0,f=o,d=0,h=0,p=0,m=1,y=1,g=1,v=0,b="",S=i,T=s,E=r,I=b;y;)switch(p=v,v=xo()){case 40:if(p!=108&&Oi(I,f-1)==58){FR(I+=An(Iw(v),"&","&\f"),"&\f")!=-1&&(g=-1);break}case 34:case 39:case 91:I+=Iw(v);break;case 9:case 10:case 13:case 32:I+=gye(p);break;case 92:I+=yye(Tw()-1,7);continue;case 47:switch(Fu()){case 42:case 47:tb(wye(vye(xo(),Tw()),t,n),u);break;default:I+="/"}break;case 123*m:a[l++]=gu(I)*g;case 125*m:case 59:case 0:switch(v){case 0:case 125:y=0;case 59+c:g==-1&&(I=An(I,/\f/g,"")),h>0&&gu(I)-f&&tb(h>32?NF(I+";",r,n,f-1):NF(An(I," ","")+";",r,n,f-2),u);break;case 59:I+=";";default:if(tb(E=RF(I,t,n,l,c,i,a,b,S=[],T=[],f),s),v===123)if(c===0)xw(I,t,E,E,S,s,f,a,T);else switch(d===99&&Oi(I,3)===110?100:d){case 100:case 108:case 109:case 115:xw(e,E,E,r&&tb(RF(e,E,E,0,0,i,a,b,i,S=[],f),T),i,T,f,a,r?S:T);break;default:xw(I,E,E,E,[""],T,0,a,T)}}l=c=h=0,m=g=1,b=I="",f=o;break;case 58:f=1+gu(I),h=p;default:if(m<1){if(v==123)--m;else if(v==125&&m++==0&&mye()==125)continue}switch(I+=vx(v),v*m){case 38:g=c>0?1:(I+="\f",-1);break;case 44:a[l++]=(gu(I)-1)*g,g=1;break;case 64:Fu()===45&&(I+=Iw(xo())),d=Fu(),c=f=gu(b=I+=_ye(Tw())),v++;break;case 45:p===45&&gu(I)==2&&(m=0)}}return s}function RF(e,t,n,r,i,s,o,a,u,l,c){for(var f=i-1,d=i===0?s:[""],h=b$(d),p=0,m=0,y=0;p0?d[g]+" "+v:An(v,/&\f/g,d[g])))&&(u[y++]=b);return bx(e,t,n,i===0?v$:a,u,l,c)}function wye(e,t,n){return bx(e,t,n,mK,vx(pye()),_v(e,2,-2),0)}function NF(e,t,n,r){return bx(e,t,n,_$,_v(e,0,r),_v(e,r+1,-1),r)}function Jp(e,t){for(var n="",r=b$(e),i=0;i6)switch(Oi(e,t+1)){case 109:if(Oi(e,t+4)!==45)break;case 102:return An(e,/(.+:)(.+)-([^]+)/,"$1"+Cn+"$2-$3$1"+NE+(Oi(e,t+3)==108?"$3":"$2-$3"))+e;case 115:return~FR(e,"stretch")?wK(An(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(Oi(e,t+1)!==115)break;case 6444:switch(Oi(e,gu(e)-3-(~FR(e,"!important")&&10))){case 107:return An(e,":",":"+Cn)+e;case 101:return An(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+Cn+(Oi(e,14)===45?"inline-":"")+"box$3$1"+Cn+"$2$3$1"+Qi+"$2box$3")+e}break;case 5936:switch(Oi(e,t+11)){case 114:return Cn+e+Qi+An(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return Cn+e+Qi+An(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return Cn+e+Qi+An(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return Cn+e+Qi+e+e}return e}var Rye=function(t,n,r,i){if(t.length>-1&&!t.return)switch(t.type){case _$:t.return=wK(t.value,t.length);break;case gK:return Jp([h0(t,{value:An(t.value,"@","@"+Cn)})],i);case v$:if(t.length)return hye(t.props,function(s){switch(dye(s,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return Jp([h0(t,{props:[An(s,/:(read-\w+)/,":"+NE+"$1")]})],i);case"::placeholder":return Jp([h0(t,{props:[An(s,/:(plac\w+)/,":"+Cn+"input-$1")]}),h0(t,{props:[An(s,/:(plac\w+)/,":"+NE+"$1")]}),h0(t,{props:[An(s,/:(plac\w+)/,Qi+"input-$1")]})],i)}return""})}},Nye=[Rye],EK=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(m){var y=m.getAttribute("data-emotion");y.indexOf(" ")!==-1&&(document.head.appendChild(m),m.setAttribute("data-s",""))})}var i=t.stylisPlugins||Nye,s={},o,a=[];o=t.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+n+' "]'),function(m){for(var y=m.getAttribute("data-emotion").split(" "),g=1;g{let r=e[n];return t.concat(Array.isArray(r)?r.map(i=>[n,i]):[[n,r]])},[]))}function p0e(e,t){let n=LR(e);return t&&t.forEach((r,i)=>{n.has(i)||t.getAll(i).forEach(s=>{n.append(i,s)})}),n}const m0e="6";try{window.__reactRouterVersion=m0e}catch{}const g0e="startTransition",EF=Zy[g0e];function y0e(e){let{basename:t,children:n,future:r,window:i}=e,s=w.useRef();s.current==null&&(s.current=wge({window:i,v5Compat:!0}));let o=s.current,[a,u]=w.useState({action:o.action,location:o.location}),{v7_startTransition:l}=r||{},c=w.useCallback(f=>{l&&EF?EF(()=>u(f)):u(f)},[u,l]);return w.useLayoutEffect(()=>o.listen(c),[o,c]),w.createElement(d0e,{basename:t,children:n,location:a.location,navigationType:a.action,navigator:o,future:r})}var SF;(function(e){e.UseScrollRestoration="useScrollRestoration",e.UseSubmit="useSubmit",e.UseSubmitFetcher="useSubmitFetcher",e.UseFetcher="useFetcher",e.useViewTransitionState="useViewTransitionState"})(SF||(SF={}));var TF;(function(e){e.UseFetcher="useFetcher",e.UseFetchers="useFetchers",e.UseScrollRestoration="useScrollRestoration"})(TF||(TF={}));function h$(e){let t=w.useRef(LR(e)),n=w.useRef(!1),r=Nh(),i=w.useMemo(()=>p0e(r.search,n.current?null:t.current),[r.search]),s=Kf(),o=w.useCallback((a,u)=>{const l=LR(typeof a=="function"?a(i):a);n.current=!0,s("?"+l,u)},[s,i]);return[i,o]}function RE(e,t){let n=e;for(;(n=n.parentElement)&&!n.matches(t););return n}function v0e(e,t,n){for(let r=e-1;r>=0;r-=1)if(!t[r].disabled)return r;if(n){for(let r=t.length-1;r>-1;r-=1)if(!t[r].disabled)return r}return e}function _0e(e,t,n){for(let r=e+1;r{var u;n==null||n(a);const l=Array.from(((u=RE(a.currentTarget,e))==null?void 0:u.querySelectorAll(t))||[]).filter(m=>b0e(a.currentTarget,m,e)),c=l.findIndex(m=>a.currentTarget===m),f=_0e(c,l,r),d=v0e(c,l,r),h=s==="rtl"?d:f,p=s==="rtl"?f:d;switch(a.key){case"ArrowRight":{o==="horizontal"&&(a.stopPropagation(),a.preventDefault(),l[h].focus(),i&&l[h].click());break}case"ArrowLeft":{o==="horizontal"&&(a.stopPropagation(),a.preventDefault(),l[p].focus(),i&&l[p].click());break}case"ArrowUp":{o==="vertical"&&(a.stopPropagation(),a.preventDefault(),l[d].focus(),i&&l[d].click());break}case"ArrowDown":{o==="vertical"&&(a.stopPropagation(),a.preventDefault(),l[f].focus(),i&&l[f].click());break}case"Home":{a.stopPropagation(),a.preventDefault(),!l[0].disabled&&l[0].focus();break}case"End":{a.stopPropagation(),a.preventDefault();const m=l.length-1;!l[m].disabled&&l[m].focus();break}}}}function E0e(e,t,n){var r;return n?Array.from(((r=RE(n,t))==null?void 0:r.querySelectorAll(e))||[]).findIndex(i=>i===n):null}function N_(e){const t=w.createContext(null);return[({children:i,value:s})=>N.createElement(t.Provider,{value:s},i),()=>{const i=w.useContext(t);if(i===null)throw new Error(e);return i}]}function lh(e){return Array.isArray(e)?e:[e]}const S0e=()=>{};function T0e(e,t={active:!0}){return typeof e!="function"||!t.active?t.onKeyDown||S0e:n=>{var r;n.key==="Escape"&&(e(n),(r=t.onTrigger)==null||r.call(t))}}function wo(e,t){return n=>{e==null||e(n),t==null||t(n)}}function I0e(e){return Object.keys(e)}function x0e(){const[e,t]=w.useState(-1);return[e,{setHovered:t,resetHovered:()=>t(-1)}]}function uK({data:e}){const t=[],n=[],r=e.reduce((i,s,o)=>(s.group?i[s.group]?i[s.group].push(o):i[s.group]=[o]:n.push(o),i),{});return Object.keys(r).forEach(i=>{t.push(...r[i].map(s=>e[s]))}),t.push(...n.map(i=>e[i])),t}function _g(e){return Array.isArray(e)||e===null?!1:typeof e=="object"?e.type!==N.Fragment:!1}function lK(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e))for(t=0;t({fontFamily:e.fontFamily||"sans-serif"})}var P0e=Object.defineProperty,IF=Object.getOwnPropertySymbols,O0e=Object.prototype.hasOwnProperty,R0e=Object.prototype.propertyIsEnumerable,xF=(e,t,n)=>t in e?P0e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,CF=(e,t)=>{for(var n in t||(t={}))O0e.call(t,n)&&xF(e,n,t[n]);if(IF)for(var n of IF(t))R0e.call(t,n)&&xF(e,n,t[n]);return e};function N0e(e){return t=>({WebkitTapHighlightColor:"transparent",[t||"&:focus"]:CF({},e.focusRing==="always"||e.focusRing==="auto"?e.focusRingStyles.styles(e):e.focusRingStyles.resetStyles(e)),[t?t.replace(":focus",":focus:not(:focus-visible)"):"&:focus:not(:focus-visible)"]:CF({},e.focusRing==="auto"||e.focusRing==="never"?e.focusRingStyles.resetStyles(e):null)})}function k_(e){return t=>typeof e.primaryShade=="number"?e.primaryShade:e.primaryShade[t||e.colorScheme]}function p$(e){const t=k_(e);return(n,r,i=!0,s=!0)=>{if(typeof n=="string"&&n.includes(".")){const[a,u]=n.split("."),l=parseInt(u,10);if(a in e.colors&&l>=0&&l<10)return e.colors[a][typeof r=="number"&&!s?r:l]}const o=typeof r=="number"?r:t();return n in e.colors?e.colors[n][o]:i?e.colors[e.primaryColor][o]:n}}function fK(e){let t="";for(let n=1;n{const i={from:(r==null?void 0:r.from)||e.defaultGradient.from,to:(r==null?void 0:r.to)||e.defaultGradient.to,deg:(r==null?void 0:r.deg)||e.defaultGradient.deg};return`linear-gradient(${i.deg}deg, ${t(i.from,n(),!1)} 0%, ${t(i.to,n(),!1)} 100%)`}}function m$(e){if(typeof e.size=="number")return e.size;const t=e.sizes[e.size];return t!==void 0?t:e.size||e.sizes.md}function $0e(e){return t=>`@media (min-width: ${m$({size:t,sizes:e.breakpoints})}px)`}function L0e(e){return t=>`@media (max-width: ${m$({size:t,sizes:e.breakpoints})-1}px)`}function M0e(e){return/^#?([0-9A-F]{3}){1,2}$/i.test(e)}function F0e(e){let t=e.replace("#","");if(t.length===3){const o=t.split("");t=[o[0],o[0],o[1],o[1],o[2],o[2]].join("")}const n=parseInt(t,16),r=n>>16&255,i=n>>8&255,s=n&255;return{r,g:i,b:s,a:1}}function B0e(e){const[t,n,r,i]=e.replace(/[^0-9,.]/g,"").split(",").map(Number);return{r:t,g:n,b:r,a:i||1}}function g$(e){return M0e(e)?F0e(e):e.startsWith("rgb")?B0e(e):{r:0,g:0,b:0,a:1}}function fp(e,t){if(typeof e!="string"||t>1||t<0)return"rgba(0, 0, 0, 1)";const{r:n,g:r,b:i}=g$(e);return`rgba(${n}, ${r}, ${i}, ${t})`}function j0e(e=0){return{position:"absolute",top:e,right:e,left:e,bottom:e}}function U0e(e,t){const{r:n,g:r,b:i,a:s}=g$(e),o=1-t,a=u=>Math.round(u*o);return`rgba(${a(n)}, ${a(r)}, ${a(i)}, ${s})`}function V0e(e,t){const{r:n,g:r,b:i,a:s}=g$(e),o=a=>Math.round(a+(255-a)*t);return`rgba(${o(n)}, ${o(r)}, ${o(i)}, ${s})`}function z0e(e){return t=>{if(typeof t=="number")return t;const n=typeof e.defaultRadius=="number"?e.defaultRadius:e.radius[e.defaultRadius]||e.defaultRadius;return e.radius[t]||t||n}}function H0e(e,t){if(typeof e=="string"&&e.includes(".")){const[n,r]=e.split("."),i=parseInt(r,10);if(n in t.colors&&i>=0&&i<10)return{isSplittedColor:!0,key:n,shade:i}}return{isSplittedColor:!1}}function W0e(e){const t=p$(e),n=k_(e),r=dK(e);return({variant:i,color:s,gradient:o,primaryFallback:a})=>{const u=H0e(s,e);switch(i){case"light":return{border:"transparent",background:fp(t(s,e.colorScheme==="dark"?8:0,a,!1),e.colorScheme==="dark"?.2:1),color:s==="dark"?e.colorScheme==="dark"?e.colors.dark[0]:e.colors.dark[9]:t(s,e.colorScheme==="dark"?2:n("light")),hover:fp(t(s,e.colorScheme==="dark"?7:1,a,!1),e.colorScheme==="dark"?.25:.65)};case"subtle":return{border:"transparent",background:"transparent",color:s==="dark"?e.colorScheme==="dark"?e.colors.dark[0]:e.colors.dark[9]:t(s,e.colorScheme==="dark"?2:n("light")),hover:fp(t(s,e.colorScheme==="dark"?8:0,a,!1),e.colorScheme==="dark"?.2:1)};case"outline":return{border:t(s,e.colorScheme==="dark"?5:n("light")),background:"transparent",color:t(s,e.colorScheme==="dark"?5:n("light")),hover:e.colorScheme==="dark"?fp(t(s,5,a,!1),.05):fp(t(s,0,a,!1),.35)};case"default":return{border:e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[4],background:e.colorScheme==="dark"?e.colors.dark[6]:e.white,color:e.colorScheme==="dark"?e.white:e.black,hover:e.colorScheme==="dark"?e.colors.dark[5]:e.colors.gray[0]};case"white":return{border:"transparent",background:e.white,color:t(s,n()),hover:null};case"transparent":return{border:"transparent",color:s==="dark"?e.colorScheme==="dark"?e.colors.dark[0]:e.colors.dark[9]:t(s,e.colorScheme==="dark"?2:n("light")),background:"transparent",hover:null};case"gradient":return{background:r(o),color:e.white,border:"transparent",hover:null};default:{const l=n(),c=u.isSplittedColor?u.shade:l,f=u.isSplittedColor?u.key:s;return{border:"transparent",background:t(f,c,a),color:e.white,hover:t(f,c===9?8:c+1)}}}}}function q0e(e){return t=>{const n=k_(e)(t);return e.colors[e.primaryColor][n]}}function G0e(e){return{"@media (hover: hover)":{"&:hover":e},"@media (hover: none)":{"&:active":e}}}function Y0e(e){return()=>({userSelect:"none",color:e.colorScheme==="dark"?e.colors.dark[3]:e.colors.gray[5]})}const Qr={fontStyles:A0e,themeColor:p$,focusStyles:N0e,linearGradient:k0e,radialGradient:D0e,smallerThan:L0e,largerThan:$0e,rgba:fp,size:m$,cover:j0e,darken:U0e,lighten:V0e,radius:z0e,variant:W0e,primaryShade:k_,hover:G0e,gradient:dK,primaryColor:q0e,placeholderStyles:Y0e};var K0e=Object.defineProperty,Q0e=Object.defineProperties,X0e=Object.getOwnPropertyDescriptors,AF=Object.getOwnPropertySymbols,J0e=Object.prototype.hasOwnProperty,Z0e=Object.prototype.propertyIsEnumerable,PF=(e,t,n)=>t in e?K0e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,eye=(e,t)=>{for(var n in t||(t={}))J0e.call(t,n)&&PF(e,n,t[n]);if(AF)for(var n of AF(t))Z0e.call(t,n)&&PF(e,n,t[n]);return e},tye=(e,t)=>Q0e(e,X0e(t));function nye(e){return tye(eye({},e),{fn:{fontStyles:Qr.fontStyles(e),themeColor:Qr.themeColor(e),focusStyles:Qr.focusStyles(e),largerThan:Qr.largerThan(e),smallerThan:Qr.smallerThan(e),radialGradient:Qr.radialGradient,linearGradient:Qr.linearGradient,gradient:Qr.gradient(e),rgba:Qr.rgba,size:Qr.size,cover:Qr.cover,lighten:Qr.lighten,darken:Qr.darken,primaryShade:Qr.primaryShade(e),radius:Qr.radius(e),variant:Qr.variant(e),hover:Qr.hover,primaryColor:Qr.primaryColor(e),placeholderStyles:Qr.placeholderStyles(e)}})}const hK=["xs","sm","md","lg","xl"],rye={dir:"ltr",primaryShade:{light:6,dark:8},focusRing:"auto",loader:"oval",dateFormat:"MMMM D, YYYY",colorScheme:"light",white:"#fff",black:"#000",defaultRadius:"sm",transitionTimingFunction:"ease",colors:C0e,lineHeight:1.55,fontFamily:"-apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Helvetica, Arial, sans-serif, Apple Color Emoji, Segoe UI Emoji",fontFamilyMonospace:"ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, Liberation Mono, Courier New, monospace",primaryColor:"blue",respectReducedMotion:!0,cursorType:"default",defaultGradient:{from:"indigo",to:"cyan",deg:45},shadows:{xs:"0 1px 3px rgba(0, 0, 0, 0.05), 0 1px 2px rgba(0, 0, 0, 0.1)",sm:"0 1px 3px rgba(0, 0, 0, 0.05), rgba(0, 0, 0, 0.05) 0px 10px 15px -5px, rgba(0, 0, 0, 0.04) 0px 7px 7px -5px",md:"0 1px 3px rgba(0, 0, 0, 0.05), rgba(0, 0, 0, 0.05) 0px 20px 25px -5px, rgba(0, 0, 0, 0.04) 0px 10px 10px -5px",lg:"0 1px 3px rgba(0, 0, 0, 0.05), rgba(0, 0, 0, 0.05) 0px 28px 23px -7px, rgba(0, 0, 0, 0.04) 0px 12px 12px -7px",xl:"0 1px 3px rgba(0, 0, 0, 0.05), rgba(0, 0, 0, 0.05) 0px 36px 28px -7px, rgba(0, 0, 0, 0.04) 0px 17px 17px -7px"},fontSizes:{xs:12,sm:14,md:16,lg:18,xl:20},radius:{xs:2,sm:4,md:8,lg:16,xl:32},spacing:{xs:10,sm:12,md:16,lg:20,xl:24},breakpoints:{xs:576,sm:768,md:992,lg:1200,xl:1400},headings:{fontFamily:"-apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Helvetica, Arial, sans-serif, Apple Color Emoji, Segoe UI Emoji",fontWeight:700,sizes:{h1:{fontSize:34,lineHeight:1.3,fontWeight:void 0},h2:{fontSize:26,lineHeight:1.35,fontWeight:void 0},h3:{fontSize:22,lineHeight:1.4,fontWeight:void 0},h4:{fontSize:18,lineHeight:1.45,fontWeight:void 0},h5:{fontSize:16,lineHeight:1.5,fontWeight:void 0},h6:{fontSize:14,lineHeight:1.5,fontWeight:void 0}}},other:{},components:{},activeStyles:{transform:"translateY(1px)"},datesLocale:"en",globalStyles:void 0,focusRingStyles:{styles:e=>({outlineOffset:2,outline:`2px solid ${e.colors[e.primaryColor][e.colorScheme==="dark"?7:5]}`}),resetStyles:()=>({outline:"none"}),inputStyles:e=>({outline:"none",borderColor:e.colors[e.primaryColor][typeof e.primaryShade=="object"?e.primaryShade[e.colorScheme]:e.primaryShade]})}},pK=nye(rye);function iye(e){if(e.sheet)return e.sheet;for(var t=0;t0?Oi(bg,--no):0,Nm--,Wr===10&&(Nm=1,_x--),Wr}function xo(){return Wr=no2||bv(Wr)>3?"":" "}function yye(e,t){for(;--t&&xo()&&!(Wr<48||Wr>102||Wr>57&&Wr<65||Wr>70&&Wr<97););return D_(e,Tw()+(t<6&&Fu()==32&&xo()==32))}function FR(e){for(;xo();)switch(Wr){case e:return no;case 34:case 39:e!==34&&e!==39&&FR(Wr);break;case 40:e===41&&FR(e);break;case 92:xo();break}return no}function vye(e,t){for(;xo()&&e+Wr!==57;)if(e+Wr===84&&Fu()===47)break;return"/*"+D_(t,no-1)+"*"+vx(e===47?e:xo())}function _ye(e){for(;!bv(Fu());)xo();return D_(e,no)}function bye(e){return bK(xw("",null,null,null,[""],e=_K(e),0,[0],e))}function xw(e,t,n,r,i,s,o,a,u){for(var l=0,c=0,f=o,d=0,h=0,p=0,m=1,y=1,g=1,v=0,b="",S=i,T=s,E=r,I=b;y;)switch(p=v,v=xo()){case 40:if(p!=108&&Oi(I,f-1)==58){MR(I+=An(Iw(v),"&","&\f"),"&\f")!=-1&&(g=-1);break}case 34:case 39:case 91:I+=Iw(v);break;case 9:case 10:case 13:case 32:I+=gye(p);break;case 92:I+=yye(Tw()-1,7);continue;case 47:switch(Fu()){case 42:case 47:tb(wye(vye(xo(),Tw()),t,n),u);break;default:I+="/"}break;case 123*m:a[l++]=gu(I)*g;case 125*m:case 59:case 0:switch(v){case 0:case 125:y=0;case 59+c:g==-1&&(I=An(I,/\f/g,"")),h>0&&gu(I)-f&&tb(h>32?RF(I+";",r,n,f-1):RF(An(I," ","")+";",r,n,f-2),u);break;case 59:I+=";";default:if(tb(E=OF(I,t,n,l,c,i,a,b,S=[],T=[],f),s),v===123)if(c===0)xw(I,t,E,E,S,s,f,a,T);else switch(d===99&&Oi(I,3)===110?100:d){case 100:case 108:case 109:case 115:xw(e,E,E,r&&tb(OF(e,E,E,0,0,i,a,b,i,S=[],f),T),i,T,f,a,r?S:T);break;default:xw(I,E,E,E,[""],T,0,a,T)}}l=c=h=0,m=g=1,b=I="",f=o;break;case 58:f=1+gu(I),h=p;default:if(m<1){if(v==123)--m;else if(v==125&&m++==0&&mye()==125)continue}switch(I+=vx(v),v*m){case 38:g=c>0?1:(I+="\f",-1);break;case 44:a[l++]=(gu(I)-1)*g,g=1;break;case 64:Fu()===45&&(I+=Iw(xo())),d=Fu(),c=f=gu(b=I+=_ye(Tw())),v++;break;case 45:p===45&&gu(I)==2&&(m=0)}}return s}function OF(e,t,n,r,i,s,o,a,u,l,c){for(var f=i-1,d=i===0?s:[""],h=_$(d),p=0,m=0,y=0;p0?d[g]+" "+v:An(v,/&\f/g,d[g])))&&(u[y++]=b);return bx(e,t,n,i===0?y$:a,u,l,c)}function wye(e,t,n){return bx(e,t,n,mK,vx(pye()),_v(e,2,-2),0)}function RF(e,t,n,r){return bx(e,t,n,v$,_v(e,0,r),_v(e,r+1,-1),r)}function Jp(e,t){for(var n="",r=_$(e),i=0;i6)switch(Oi(e,t+1)){case 109:if(Oi(e,t+4)!==45)break;case 102:return An(e,/(.+:)(.+)-([^]+)/,"$1"+Cn+"$2-$3$1"+NE+(Oi(e,t+3)==108?"$3":"$2-$3"))+e;case 115:return~MR(e,"stretch")?wK(An(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(Oi(e,t+1)!==115)break;case 6444:switch(Oi(e,gu(e)-3-(~MR(e,"!important")&&10))){case 107:return An(e,":",":"+Cn)+e;case 101:return An(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+Cn+(Oi(e,14)===45?"inline-":"")+"box$3$1"+Cn+"$2$3$1"+Qi+"$2box$3")+e}break;case 5936:switch(Oi(e,t+11)){case 114:return Cn+e+Qi+An(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return Cn+e+Qi+An(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return Cn+e+Qi+An(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return Cn+e+Qi+e+e}return e}var Rye=function(t,n,r,i){if(t.length>-1&&!t.return)switch(t.type){case v$:t.return=wK(t.value,t.length);break;case gK:return Jp([h0(t,{value:An(t.value,"@","@"+Cn)})],i);case y$:if(t.length)return hye(t.props,function(s){switch(dye(s,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return Jp([h0(t,{props:[An(s,/:(read-\w+)/,":"+NE+"$1")]})],i);case"::placeholder":return Jp([h0(t,{props:[An(s,/:(plac\w+)/,":"+Cn+"input-$1")]}),h0(t,{props:[An(s,/:(plac\w+)/,":"+NE+"$1")]}),h0(t,{props:[An(s,/:(plac\w+)/,Qi+"input-$1")]})],i)}return""})}},Nye=[Rye],EK=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(m){var y=m.getAttribute("data-emotion");y.indexOf(" ")!==-1&&(document.head.appendChild(m),m.setAttribute("data-s",""))})}var i=t.stylisPlugins||Nye,s={},o,a=[];o=t.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+n+' "]'),function(m){for(var y=m.getAttribute("data-emotion").split(" "),g=1;g=4;++r,i-=4)n=e.charCodeAt(r)&255|(e.charCodeAt(++r)&255)<<8|(e.charCodeAt(++r)&255)<<16|(e.charCodeAt(++r)&255)<<24,n=(n&65535)*1540483477+((n>>>16)*59797<<16),n^=n>>>24,t=(n&65535)*1540483477+((n>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(i){case 3:t^=(e.charCodeAt(r+2)&255)<<16;case 2:t^=(e.charCodeAt(r+1)&255)<<8;case 1:t^=e.charCodeAt(r)&255,t=(t&65535)*1540483477+((t>>>16)*59797<<16)}return t^=t>>>13,t=(t&65535)*1540483477+((t>>>16)*59797<<16),((t^t>>>15)>>>0).toString(36)}var Wye={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},qye=/[A-Z]|^ms/g,Gye=/_EMO_([^_]+?)_([^]*?)_EMO_/g,AK=function(t){return t.charCodeAt(1)===45},DF=function(t){return t!=null&&typeof t!="boolean"},xP=Iye(function(e){return AK(e)?e:e.replace(qye,"-$&").toLowerCase()}),$F=function(t,n){switch(t){case"animation":case"animationName":if(typeof n=="string")return n.replace(Gye,function(r,i,s){return yu={name:i,styles:s,next:yu},i})}return Wye[t]!==1&&!AK(t)&&typeof n=="number"&&n!==0?n+"px":n};function wv(e,t,n){if(n==null)return"";if(n.__emotion_styles!==void 0)return n;switch(typeof n){case"boolean":return"";case"object":{if(n.anim===1)return yu={name:n.name,styles:n.styles,next:yu},n.name;if(n.styles!==void 0){var r=n.next;if(r!==void 0)for(;r!==void 0;)yu={name:r.name,styles:r.styles,next:yu},r=r.next;var i=n.styles+";";return i}return Yye(e,t,n)}case"function":{if(e!==void 0){var s=yu,o=n(e);return yu=s,wv(e,t,o)}break}}if(t==null)return n;var a=t[n];return a!==void 0?a:n}function Yye(e,t,n){var r="";if(Array.isArray(n))for(var i=0;i(e[n]!==void 0&&(t[n]=e[n]),t),{})}var eve=Object.defineProperty,FF=Object.getOwnPropertySymbols,tve=Object.prototype.hasOwnProperty,nve=Object.prototype.propertyIsEnumerable,BF=(e,t,n)=>t in e?eve(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,CP=(e,t)=>{for(var n in t||(t={}))tve.call(t,n)&&BF(e,n,t[n]);if(FF)for(var n of FF(t))nve.call(t,n)&&BF(e,n,t[n]);return e};const NK=w.createContext({theme:pK});function ji(){var e;return((e=w.useContext(NK))==null?void 0:e.theme)||pK}function rve(e){const t=ji(),n=r=>{var i,s;return{styles:((i=t.components[r])==null?void 0:i.styles)||{},classNames:((s=t.components[r])==null?void 0:s.classNames)||{}}};return Array.isArray(e)?e.map(n):[n(e)]}function kK(){var e;return(e=w.useContext(NK))==null?void 0:e.emotionCache}function Ve(e,t,n){var r;const i=ji(),s=(r=i.components[e])==null?void 0:r.defaultProps,o=typeof s=="function"?s(i):s;return CP(CP(CP({},t),o),RK(n))}const ive={app:100,modal:200,popover:300,overlay:400,max:9999};function cc(e){return ive[e]}function sve(e,t){const n=w.useRef();return(!n.current||t.length!==n.current.prevDeps.length||n.current.prevDeps.map((r,i)=>r===t[i]).indexOf(!1)>=0)&&(n.current={v:e(),prevDeps:[...t]}),n.current.v}const ove=EK({key:"mantine",prepend:!0});function ave(){return kK()||ove}var uve=Object.defineProperty,jF=Object.getOwnPropertySymbols,lve=Object.prototype.hasOwnProperty,cve=Object.prototype.propertyIsEnumerable,UF=(e,t,n)=>t in e?uve(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,fve=(e,t)=>{for(var n in t||(t={}))lve.call(t,n)&&UF(e,n,t[n]);if(jF)for(var n of jF(t))cve.call(t,n)&&UF(e,n,t[n]);return e};const AP="ref";function dve(e){let t;if(e.length!==1)return{args:e,ref:t};const[n]=e;if(!(n instanceof Object))return{args:e,ref:t};if(!(AP in n))return{args:e,ref:t};t=n[AP];const r=fve({},n);return delete r[AP],{args:[r],ref:t}}const{cssFactory:hve}=(()=>{function e(n,r,i){const s=[],o=Vye(n,s,i);return s.length<2?i:o+r(s)}function t(n){const{cache:r}=n,i=(...o)=>{const{ref:a,args:u}=dve(o),l=T$(u,r.registered);return CK(r,l,!1),`${r.key}-${l.name}${a===void 0?"":` ${a}`}`};return{css:i,cx:(...o)=>e(r.registered,i,cK(o))}}return{cssFactory:t}})();function DK(){const e=ave();return sve(()=>hve({cache:e}),[e])}function pve({cx:e,classes:t,context:n,classNames:r,name:i,cache:s}){const o=n.reduce((a,u)=>(Object.keys(u.classNames).forEach(l=>{typeof a[l]!="string"?a[l]=`${u.classNames[l]}`:a[l]=`${a[l]} ${u.classNames[l]}`}),a),{});return Object.keys(t).reduce((a,u)=>(a[u]=e(t[u],o[u],r!=null&&r[u],Array.isArray(i)?i.filter(Boolean).map(l=>`${(s==null?void 0:s.key)||"mantine"}-${l}-${u}`).join(" "):i?`${(s==null?void 0:s.key)||"mantine"}-${i}-${u}`:null),a),{})}var mve=Object.defineProperty,VF=Object.getOwnPropertySymbols,gve=Object.prototype.hasOwnProperty,yve=Object.prototype.propertyIsEnumerable,zF=(e,t,n)=>t in e?mve(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,PP=(e,t)=>{for(var n in t||(t={}))gve.call(t,n)&&zF(e,n,t[n]);if(VF)for(var n of VF(t))yve.call(t,n)&&zF(e,n,t[n]);return e};function vve(e){return`__mantine-ref-${e||""}`}function HF(e,t,n){const r=i=>typeof i=="function"?i(t,n||{}):i||{};return Array.isArray(e)?e.map(i=>r(i.styles)).reduce((i,s)=>(Object.keys(s).forEach(o=>{i[o]?i[o]=PP(PP({},i[o]),s[o]):i[o]=PP({},s[o])}),i),{}):r(e)}function lt(e){const t=typeof e=="function"?e:()=>e;function n(r,i){const s=ji(),o=rve(i==null?void 0:i.name),a=kK(),{css:u,cx:l}=DK(),c=t(s,r,vve),f=HF(i==null?void 0:i.styles,s,r),d=HF(o,s,r),h=Object.fromEntries(Object.keys(c).map(p=>{const m=l({[u(c[p])]:!(i!=null&&i.unstyled)},u(d[p]),u(f[p]));return[p,m]}));return{classes:pve({cx:l,classes:h,context:o,classNames:i==null?void 0:i.classNames,name:i==null?void 0:i.name,cache:a}),cx:l,theme:s}}return n}function $K({styles:e}){const t=ji();return N.createElement(Jye,{styles:OK(typeof e=="function"?e(t):e)})}var _ve=Object.defineProperty,bve=Object.defineProperties,wve=Object.getOwnPropertyDescriptors,WF=Object.getOwnPropertySymbols,Eve=Object.prototype.hasOwnProperty,Sve=Object.prototype.propertyIsEnumerable,qF=(e,t,n)=>t in e?_ve(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,p0=(e,t)=>{for(var n in t||(t={}))Eve.call(t,n)&&qF(e,n,t[n]);if(WF)for(var n of WF(t))Sve.call(t,n)&&qF(e,n,t[n]);return e},m0=(e,t)=>bve(e,wve(t));const g0={in:{opacity:1,transform:"scale(1)"},out:{opacity:0,transform:"scale(.9) translateY(10px)"},transitionProperty:"transform, opacity"},nb={fade:{in:{opacity:1},out:{opacity:0},transitionProperty:"opacity"},scale:{in:{opacity:1,transform:"scale(1)"},out:{opacity:0,transform:"scale(0)"},common:{transformOrigin:"top"},transitionProperty:"transform, opacity"},"scale-y":{in:{opacity:1,transform:"scaleY(1)"},out:{opacity:0,transform:"scaleY(0)"},common:{transformOrigin:"top"},transitionProperty:"transform, opacity"},"scale-x":{in:{opacity:1,transform:"scaleX(1)"},out:{opacity:0,transform:"scaleX(0)"},common:{transformOrigin:"left"},transitionProperty:"transform, opacity"},"skew-up":{in:{opacity:1,transform:"translateY(0) skew(0deg, 0deg)"},out:{opacity:0,transform:"translateY(-20px) skew(-10deg, -5deg)"},common:{transformOrigin:"top"},transitionProperty:"transform, opacity"},"skew-down":{in:{opacity:1,transform:"translateY(0) skew(0deg, 0deg)"},out:{opacity:0,transform:"translateY(20px) skew(-10deg, -5deg)"},common:{transformOrigin:"bottom"},transitionProperty:"transform, opacity"},"rotate-left":{in:{opacity:1,transform:"translateY(0) rotate(0deg)"},out:{opacity:0,transform:"translateY(20px) rotate(-5deg)"},common:{transformOrigin:"bottom"},transitionProperty:"transform, opacity"},"rotate-right":{in:{opacity:1,transform:"translateY(0) rotate(0deg)"},out:{opacity:0,transform:"translateY(20px) rotate(5deg)"},common:{transformOrigin:"top"},transitionProperty:"transform, opacity"},"slide-down":{in:{opacity:1,transform:"translateY(0)"},out:{opacity:0,transform:"translateY(-100%)"},common:{transformOrigin:"top"},transitionProperty:"transform, opacity"},"slide-up":{in:{opacity:1,transform:"translateY(0)"},out:{opacity:0,transform:"translateY(100%)"},common:{transformOrigin:"bottom"},transitionProperty:"transform, opacity"},"slide-left":{in:{opacity:1,transform:"translateX(0)"},out:{opacity:0,transform:"translateX(100%)"},common:{transformOrigin:"left"},transitionProperty:"transform, opacity"},"slide-right":{in:{opacity:1,transform:"translateX(0)"},out:{opacity:0,transform:"translateX(-100%)"},common:{transformOrigin:"right"},transitionProperty:"transform, opacity"},pop:m0(p0({},g0),{common:{transformOrigin:"center center"}}),"pop-bottom-left":m0(p0({},g0),{common:{transformOrigin:"bottom left"}}),"pop-bottom-right":m0(p0({},g0),{common:{transformOrigin:"bottom right"}}),"pop-top-left":m0(p0({},g0),{common:{transformOrigin:"top left"}}),"pop-top-right":m0(p0({},g0),{common:{transformOrigin:"top right"}})},GF=["mousedown","touchstart"];function Tve(e,t,n){const r=w.useRef();return w.useEffect(()=>{const i=s=>{const{target:o}=s??{};if(Array.isArray(n)){const a=(o==null?void 0:o.hasAttribute("data-ignore-outside-clicks"))||!document.body.contains(o)&&o.tagName!=="HTML";n.every(l=>!!l&&!s.composedPath().includes(l))&&!a&&e()}else r.current&&!r.current.contains(o)&&e()};return(t||GF).forEach(s=>document.addEventListener(s,i)),()=>{(t||GF).forEach(s=>document.removeEventListener(s,i))}},[r,e,n]),r}function Ive(e,t){try{return e.addEventListener("change",t),()=>e.removeEventListener("change",t)}catch{return e.addListener(t),()=>e.removeListener(t)}}function xve(e,t){return typeof t=="boolean"?t:typeof window<"u"&&"matchMedia"in window?window.matchMedia(e).matches:!1}function Cve(e,t,{getInitialValueInEffect:n}={getInitialValueInEffect:!0}){const[r,i]=w.useState(n?t:xve(e,t)),s=w.useRef();return w.useEffect(()=>{if("matchMedia"in window)return s.current=window.matchMedia(e),i(s.current.matches),Ive(s.current,o=>i(o.matches))},[e]),r}function ff(e,t,n){return Math.min(Math.max(e,t),n)}const I$=typeof document<"u"?w.useLayoutEffect:w.useEffect;function Js(e,t){const n=w.useRef(!1);w.useEffect(()=>()=>{n.current=!1},[]),w.useEffect(()=>{if(n.current)return e();n.current=!0},t)}function LK({opened:e,shouldReturnFocus:t=!0}){const n=w.useRef(),r=()=>{var i;n.current&&"focus"in n.current&&typeof n.current.focus=="function"&&((i=n.current)==null||i.focus({preventScroll:!0}))};return Js(()=>{let i=-1;const s=o=>{o.key==="Tab"&&window.clearTimeout(i)};return document.addEventListener("keydown",s),e?n.current=document.activeElement:t&&(i=window.setTimeout(r,10)),()=>{window.clearTimeout(i),document.removeEventListener("keydown",s)}},[e,t]),r}const Ave=/input|select|textarea|button|object/,MK="a, input, select, textarea, button, object, [tabindex]";function Pve(e){return e.style.display==="none"}function Ove(e){if(e.getAttribute("aria-hidden")||e.getAttribute("hidden")||e.getAttribute("type")==="hidden")return!1;let n=e;for(;n&&!(n===document.body||n.nodeType===11);){if(Pve(n))return!1;n=n.parentNode}return!0}function FK(e){let t=e.getAttribute("tabindex");return t===null&&(t=void 0),parseInt(t,10)}function jR(e){const t=e.nodeName.toLowerCase(),n=!Number.isNaN(FK(e));return(Ave.test(t)&&!e.disabled||e instanceof HTMLAnchorElement&&e.href||n)&&Ove(e)}function BK(e){const t=FK(e);return(Number.isNaN(t)||t>=0)&&jR(e)}function Rve(e){return Array.from(e.querySelectorAll(MK)).filter(BK)}function Nve(e,t){const n=Rve(e);if(!n.length){t.preventDefault();return}const r=n[t.shiftKey?0:n.length-1],i=e.getRootNode();if(!(r===i.activeElement||e===i.activeElement))return;t.preventDefault();const o=n[t.shiftKey?n.length-1:0];o&&o.focus()}function kve(e,t="body > :not(script)"){const n=Array.from(document.querySelectorAll(t)).map(r=>{var i;if((i=r==null?void 0:r.shadowRoot)!=null&&i.contains(e)||r.contains(e))return;const s=r.getAttribute("aria-hidden");return(s===null||s==="false")&&r.setAttribute("aria-hidden","true"),{node:r,ariaHidden:s}});return()=>{n.forEach(r=>{r&&(r.ariaHidden===null?r.node.removeAttribute("aria-hidden"):r.node.setAttribute("aria-hidden",r.ariaHidden))})}}function jK(e=!0){const t=w.useRef(),n=w.useRef(null),r=w.useCallback(i=>{if(e){if(i===null){n.current&&(n.current(),n.current=null);return}if(n.current=kve(i),t.current!==i)if(i){const s=()=>{let o=i.querySelector("[data-autofocus]");if(!o){const a=Array.from(i.querySelectorAll(MK));o=a.find(BK)||a.find(jR)||null,!o&&jR(i)&&(o=i)}o&&o.focus({preventScroll:!0})};setTimeout(()=>{i.getRootNode()&&s()}),t.current=i}else t.current=null}},[e]);return w.useEffect(()=>{if(!e)return;const i=s=>{s.key==="Tab"&&t.current&&Nve(t.current,s)};return document.addEventListener("keydown",i),()=>{document.removeEventListener("keydown",i),n.current&&n.current()}},[e]),r}const Dve=e=>(e+1)%1e6;function $ve(){const[,e]=w.useReducer(Dve,0);return e}const Lve=()=>`mantine-${Math.random().toString(36).slice(2,11)}`,Mve=N.useId||(()=>{});function Fve(){const[e,t]=w.useState("");return I$(()=>{t(Lve())},[]),e}function Bve(){const e=Mve();return e?`mantine-${e.replace(/:/g,"")}`:""}function tu(e){return typeof e=="string"?e:Bve()||Fve()}function UR(e,t,n){w.useEffect(()=>(window.addEventListener(e,t,n),()=>window.removeEventListener(e,t,n)),[e,t])}function UK(e,t){typeof e=="function"?e(t):typeof e=="object"&&e!==null&&"current"in e&&(e.current=t)}function VK(...e){return t=>{e.forEach(n=>UK(n,t))}}function fa(...e){return w.useCallback(VK(...e),e)}function zK(e,t,n="ltr"){const r=w.useRef(),i=w.useRef(!1),s=w.useRef(!1),o=w.useRef(0),[a,u]=w.useState(!1);return w.useEffect(()=>{i.current=!0},[]),w.useEffect(()=>{const l=({x:v,y:b})=>{cancelAnimationFrame(o.current),o.current=requestAnimationFrame(()=>{if(i.current&&r.current){r.current.style.userSelect="none";const S=r.current.getBoundingClientRect();if(S.width&&S.height){const T=ff((v-S.left)/S.width,0,1);e({x:n==="ltr"?T:1-T,y:ff((b-S.top)/S.height,0,1)})}}})},c=()=>{document.addEventListener("mousemove",m),document.addEventListener("mouseup",h),document.addEventListener("touchmove",g),document.addEventListener("touchend",h)},f=()=>{document.removeEventListener("mousemove",m),document.removeEventListener("mouseup",h),document.removeEventListener("touchmove",g),document.removeEventListener("touchend",h)},d=()=>{!s.current&&i.current&&(s.current=!0,typeof(t==null?void 0:t.onScrubStart)=="function"&&t.onScrubStart(),u(!0),c())},h=()=>{s.current&&i.current&&(s.current=!1,u(!1),f(),setTimeout(()=>{typeof(t==null?void 0:t.onScrubEnd)=="function"&&t.onScrubEnd()},0))},p=v=>{d(),v.preventDefault(),m(v)},m=v=>l({x:v.clientX,y:v.clientY}),y=v=>{v.cancelable&&v.preventDefault(),d(),g(v)},g=v=>{v.cancelable&&v.preventDefault(),l({x:v.changedTouches[0].clientX,y:v.changedTouches[0].clientY})};return r.current.addEventListener("mousedown",p),r.current.addEventListener("touchstart",y,{passive:!1}),()=>{r.current&&(r.current.removeEventListener("mousedown",p),r.current.removeEventListener("touchstart",y))}},[n,e]),{ref:r,active:a}}function oa({value:e,defaultValue:t,finalValue:n,onChange:r=()=>{}}){const[i,s]=w.useState(t!==void 0?t:n),o=a=>{s(a),r==null||r(a)};return e!==void 0?[e,r,!0]:[i,o,!1]}function Rx(e,t){return Cve("(prefers-reduced-motion: reduce)",e,t)}const jve=e=>e<.5?2*e*e:-1+(4-2*e)*e,Uve=({axis:e,target:t,parent:n,alignment:r,offset:i,isList:s})=>{if(!t||!n&&typeof document>"u")return 0;const o=!!n,u=(n||document.body).getBoundingClientRect(),l=t.getBoundingClientRect(),c=f=>l[f]-u[f];if(e==="y"){const f=c("top");if(f===0)return 0;if(r==="start"){const h=f-i;return h<=l.height*(s?0:1)||!s?h:0}const d=o?u.height:window.innerHeight;if(r==="end"){const h=f+i-d+l.height;return h>=-l.height*(s?0:1)||!s?h:0}return r==="center"?f-d/2+l.height/2:0}if(e==="x"){const f=c("left");if(f===0)return 0;if(r==="start"){const h=f-i;return h<=l.width||!s?h:0}const d=o?u.width:window.innerWidth;if(r==="end"){const h=f+i-d+l.width;return h>=-l.width||!s?h:0}return r==="center"?f-d/2+l.width/2:0}return 0},Vve=({axis:e,parent:t})=>{if(!t&&typeof document>"u")return 0;const n=e==="y"?"scrollTop":"scrollLeft";if(t)return t[n];const{body:r,documentElement:i}=document;return r[n]+i[n]},zve=({axis:e,parent:t,distance:n})=>{if(!t&&typeof document>"u")return;const r=e==="y"?"scrollTop":"scrollLeft";if(t)t[r]=n;else{const{body:i,documentElement:s}=document;i[r]=n,s[r]=n}};function HK({duration:e=1250,axis:t="y",onScrollFinish:n,easing:r=jve,offset:i=0,cancelable:s=!0,isList:o=!1}={}){const a=w.useRef(0),u=w.useRef(0),l=w.useRef(!1),c=w.useRef(null),f=w.useRef(null),d=Rx(),h=()=>{a.current&&cancelAnimationFrame(a.current)},p=w.useCallback(({alignment:y="start"}={})=>{var g;l.current=!1,a.current&&h();const v=(g=Vve({parent:c.current,axis:t}))!=null?g:0,b=Uve({parent:c.current,target:f.current,axis:t,alignment:y,offset:i,isList:o})-(c.current?0:v);function S(){u.current===0&&(u.current=performance.now());const E=performance.now()-u.current,I=d||e===0?1:E/e,A=v+b*r(I);zve({parent:c.current,axis:t,distance:A}),!l.current&&I<1?a.current=requestAnimationFrame(S):(typeof n=="function"&&n(),u.current=0,a.current=0,h())}S()},[t,e,r,o,i,n,d]),m=()=>{s&&(l.current=!0)};return UR("wheel",m,{passive:!0}),UR("touchmove",m,{passive:!0}),w.useEffect(()=>h,[]),{scrollableRef:c,targetRef:f,scrollIntoView:p,cancel:h}}const Hve={x:0,y:0,width:0,height:0,top:0,left:0,bottom:0,right:0};function Nx(){const e=w.useRef(0),t=w.useRef(null),[n,r]=w.useState(Hve),i=w.useMemo(()=>typeof window<"u"?new ResizeObserver(s=>{const o=s[0];o&&(cancelAnimationFrame(e.current),e.current=requestAnimationFrame(()=>{t.current&&r(o.contentRect)}))}):null,[]);return w.useEffect(()=>(t.current&&i.observe(t.current),()=>{i.disconnect(),e.current&&cancelAnimationFrame(e.current)}),[t.current]),[t,n]}function Wve(){if(typeof window>"u"||typeof document>"u")return 0;const e=parseInt(window.getComputedStyle(document.body).paddingRight,10),t=window.innerWidth-document.documentElement.clientWidth;return e+t}const qve=({disableBodyPadding:e})=>{const t=e?null:Wve();return`body { + */var _i=typeof Symbol=="function"&&Symbol.for,b$=_i?Symbol.for("react.element"):60103,w$=_i?Symbol.for("react.portal"):60106,wx=_i?Symbol.for("react.fragment"):60107,Ex=_i?Symbol.for("react.strict_mode"):60108,Sx=_i?Symbol.for("react.profiler"):60114,Tx=_i?Symbol.for("react.provider"):60109,Ix=_i?Symbol.for("react.context"):60110,E$=_i?Symbol.for("react.async_mode"):60111,xx=_i?Symbol.for("react.concurrent_mode"):60111,Cx=_i?Symbol.for("react.forward_ref"):60112,Ax=_i?Symbol.for("react.suspense"):60113,kye=_i?Symbol.for("react.suspense_list"):60120,Px=_i?Symbol.for("react.memo"):60115,Ox=_i?Symbol.for("react.lazy"):60116,Dye=_i?Symbol.for("react.block"):60121,$ye=_i?Symbol.for("react.fundamental"):60117,Lye=_i?Symbol.for("react.responder"):60118,Mye=_i?Symbol.for("react.scope"):60119;function Lo(e){if(typeof e=="object"&&e!==null){var t=e.$$typeof;switch(t){case b$:switch(e=e.type,e){case E$:case xx:case wx:case Sx:case Ex:case Ax:return e;default:switch(e=e&&e.$$typeof,e){case Ix:case Cx:case Ox:case Px:case Tx:return e;default:return t}}case w$:return t}}}function TK(e){return Lo(e)===xx}jn.AsyncMode=E$;jn.ConcurrentMode=xx;jn.ContextConsumer=Ix;jn.ContextProvider=Tx;jn.Element=b$;jn.ForwardRef=Cx;jn.Fragment=wx;jn.Lazy=Ox;jn.Memo=Px;jn.Portal=w$;jn.Profiler=Sx;jn.StrictMode=Ex;jn.Suspense=Ax;jn.isAsyncMode=function(e){return TK(e)||Lo(e)===E$};jn.isConcurrentMode=TK;jn.isContextConsumer=function(e){return Lo(e)===Ix};jn.isContextProvider=function(e){return Lo(e)===Tx};jn.isElement=function(e){return typeof e=="object"&&e!==null&&e.$$typeof===b$};jn.isForwardRef=function(e){return Lo(e)===Cx};jn.isFragment=function(e){return Lo(e)===wx};jn.isLazy=function(e){return Lo(e)===Ox};jn.isMemo=function(e){return Lo(e)===Px};jn.isPortal=function(e){return Lo(e)===w$};jn.isProfiler=function(e){return Lo(e)===Sx};jn.isStrictMode=function(e){return Lo(e)===Ex};jn.isSuspense=function(e){return Lo(e)===Ax};jn.isValidElementType=function(e){return typeof e=="string"||typeof e=="function"||e===wx||e===xx||e===Sx||e===Ex||e===Ax||e===kye||typeof e=="object"&&e!==null&&(e.$$typeof===Ox||e.$$typeof===Px||e.$$typeof===Tx||e.$$typeof===Ix||e.$$typeof===Cx||e.$$typeof===$ye||e.$$typeof===Lye||e.$$typeof===Mye||e.$$typeof===Dye)};jn.typeOf=Lo;SK.exports=jn;var Fye=SK.exports,IK=Fye,Bye={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},jye={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},xK={};xK[IK.ForwardRef]=Bye;xK[IK.Memo]=jye;var Uye=!0;function Vye(e,t,n){var r="";return n.split(" ").forEach(function(i){e[i]!==void 0?t.push(e[i]+";"):r+=i+" "}),r}var zye=function(t,n,r){var i=t.key+"-"+n.name;(r===!1||Uye===!1)&&t.registered[i]===void 0&&(t.registered[i]=n.styles)},CK=function(t,n,r){zye(t,n,r);var i=t.key+"-"+n.name;if(t.inserted[n.name]===void 0){var s=n;do t.insert(n===s?"."+i:"",s,t.sheet,!0),s=s.next;while(s!==void 0)}};function Hye(e){for(var t=0,n,r=0,i=e.length;i>=4;++r,i-=4)n=e.charCodeAt(r)&255|(e.charCodeAt(++r)&255)<<8|(e.charCodeAt(++r)&255)<<16|(e.charCodeAt(++r)&255)<<24,n=(n&65535)*1540483477+((n>>>16)*59797<<16),n^=n>>>24,t=(n&65535)*1540483477+((n>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(i){case 3:t^=(e.charCodeAt(r+2)&255)<<16;case 2:t^=(e.charCodeAt(r+1)&255)<<8;case 1:t^=e.charCodeAt(r)&255,t=(t&65535)*1540483477+((t>>>16)*59797<<16)}return t^=t>>>13,t=(t&65535)*1540483477+((t>>>16)*59797<<16),((t^t>>>15)>>>0).toString(36)}var Wye={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},qye=/[A-Z]|^ms/g,Gye=/_EMO_([^_]+?)_([^]*?)_EMO_/g,AK=function(t){return t.charCodeAt(1)===45},kF=function(t){return t!=null&&typeof t!="boolean"},xP=Iye(function(e){return AK(e)?e:e.replace(qye,"-$&").toLowerCase()}),DF=function(t,n){switch(t){case"animation":case"animationName":if(typeof n=="string")return n.replace(Gye,function(r,i,s){return yu={name:i,styles:s,next:yu},i})}return Wye[t]!==1&&!AK(t)&&typeof n=="number"&&n!==0?n+"px":n};function wv(e,t,n){if(n==null)return"";if(n.__emotion_styles!==void 0)return n;switch(typeof n){case"boolean":return"";case"object":{if(n.anim===1)return yu={name:n.name,styles:n.styles,next:yu},n.name;if(n.styles!==void 0){var r=n.next;if(r!==void 0)for(;r!==void 0;)yu={name:r.name,styles:r.styles,next:yu},r=r.next;var i=n.styles+";";return i}return Yye(e,t,n)}case"function":{if(e!==void 0){var s=yu,o=n(e);return yu=s,wv(e,t,o)}break}}if(t==null)return n;var a=t[n];return a!==void 0?a:n}function Yye(e,t,n){var r="";if(Array.isArray(n))for(var i=0;i(e[n]!==void 0&&(t[n]=e[n]),t),{})}var eve=Object.defineProperty,MF=Object.getOwnPropertySymbols,tve=Object.prototype.hasOwnProperty,nve=Object.prototype.propertyIsEnumerable,FF=(e,t,n)=>t in e?eve(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,CP=(e,t)=>{for(var n in t||(t={}))tve.call(t,n)&&FF(e,n,t[n]);if(MF)for(var n of MF(t))nve.call(t,n)&&FF(e,n,t[n]);return e};const NK=w.createContext({theme:pK});function ji(){var e;return((e=w.useContext(NK))==null?void 0:e.theme)||pK}function rve(e){const t=ji(),n=r=>{var i,s;return{styles:((i=t.components[r])==null?void 0:i.styles)||{},classNames:((s=t.components[r])==null?void 0:s.classNames)||{}}};return Array.isArray(e)?e.map(n):[n(e)]}function kK(){var e;return(e=w.useContext(NK))==null?void 0:e.emotionCache}function Ve(e,t,n){var r;const i=ji(),s=(r=i.components[e])==null?void 0:r.defaultProps,o=typeof s=="function"?s(i):s;return CP(CP(CP({},t),o),RK(n))}const ive={app:100,modal:200,popover:300,overlay:400,max:9999};function cc(e){return ive[e]}function sve(e,t){const n=w.useRef();return(!n.current||t.length!==n.current.prevDeps.length||n.current.prevDeps.map((r,i)=>r===t[i]).indexOf(!1)>=0)&&(n.current={v:e(),prevDeps:[...t]}),n.current.v}const ove=EK({key:"mantine",prepend:!0});function ave(){return kK()||ove}var uve=Object.defineProperty,BF=Object.getOwnPropertySymbols,lve=Object.prototype.hasOwnProperty,cve=Object.prototype.propertyIsEnumerable,jF=(e,t,n)=>t in e?uve(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,fve=(e,t)=>{for(var n in t||(t={}))lve.call(t,n)&&jF(e,n,t[n]);if(BF)for(var n of BF(t))cve.call(t,n)&&jF(e,n,t[n]);return e};const AP="ref";function dve(e){let t;if(e.length!==1)return{args:e,ref:t};const[n]=e;if(!(n instanceof Object))return{args:e,ref:t};if(!(AP in n))return{args:e,ref:t};t=n[AP];const r=fve({},n);return delete r[AP],{args:[r],ref:t}}const{cssFactory:hve}=(()=>{function e(n,r,i){const s=[],o=Vye(n,s,i);return s.length<2?i:o+r(s)}function t(n){const{cache:r}=n,i=(...o)=>{const{ref:a,args:u}=dve(o),l=S$(u,r.registered);return CK(r,l,!1),`${r.key}-${l.name}${a===void 0?"":` ${a}`}`};return{css:i,cx:(...o)=>e(r.registered,i,cK(o))}}return{cssFactory:t}})();function DK(){const e=ave();return sve(()=>hve({cache:e}),[e])}function pve({cx:e,classes:t,context:n,classNames:r,name:i,cache:s}){const o=n.reduce((a,u)=>(Object.keys(u.classNames).forEach(l=>{typeof a[l]!="string"?a[l]=`${u.classNames[l]}`:a[l]=`${a[l]} ${u.classNames[l]}`}),a),{});return Object.keys(t).reduce((a,u)=>(a[u]=e(t[u],o[u],r!=null&&r[u],Array.isArray(i)?i.filter(Boolean).map(l=>`${(s==null?void 0:s.key)||"mantine"}-${l}-${u}`).join(" "):i?`${(s==null?void 0:s.key)||"mantine"}-${i}-${u}`:null),a),{})}var mve=Object.defineProperty,UF=Object.getOwnPropertySymbols,gve=Object.prototype.hasOwnProperty,yve=Object.prototype.propertyIsEnumerable,VF=(e,t,n)=>t in e?mve(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,PP=(e,t)=>{for(var n in t||(t={}))gve.call(t,n)&&VF(e,n,t[n]);if(UF)for(var n of UF(t))yve.call(t,n)&&VF(e,n,t[n]);return e};function vve(e){return`__mantine-ref-${e||""}`}function zF(e,t,n){const r=i=>typeof i=="function"?i(t,n||{}):i||{};return Array.isArray(e)?e.map(i=>r(i.styles)).reduce((i,s)=>(Object.keys(s).forEach(o=>{i[o]?i[o]=PP(PP({},i[o]),s[o]):i[o]=PP({},s[o])}),i),{}):r(e)}function lt(e){const t=typeof e=="function"?e:()=>e;function n(r,i){const s=ji(),o=rve(i==null?void 0:i.name),a=kK(),{css:u,cx:l}=DK(),c=t(s,r,vve),f=zF(i==null?void 0:i.styles,s,r),d=zF(o,s,r),h=Object.fromEntries(Object.keys(c).map(p=>{const m=l({[u(c[p])]:!(i!=null&&i.unstyled)},u(d[p]),u(f[p]));return[p,m]}));return{classes:pve({cx:l,classes:h,context:o,classNames:i==null?void 0:i.classNames,name:i==null?void 0:i.name,cache:a}),cx:l,theme:s}}return n}function $K({styles:e}){const t=ji();return N.createElement(Jye,{styles:OK(typeof e=="function"?e(t):e)})}var _ve=Object.defineProperty,bve=Object.defineProperties,wve=Object.getOwnPropertyDescriptors,HF=Object.getOwnPropertySymbols,Eve=Object.prototype.hasOwnProperty,Sve=Object.prototype.propertyIsEnumerable,WF=(e,t,n)=>t in e?_ve(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,p0=(e,t)=>{for(var n in t||(t={}))Eve.call(t,n)&&WF(e,n,t[n]);if(HF)for(var n of HF(t))Sve.call(t,n)&&WF(e,n,t[n]);return e},m0=(e,t)=>bve(e,wve(t));const g0={in:{opacity:1,transform:"scale(1)"},out:{opacity:0,transform:"scale(.9) translateY(10px)"},transitionProperty:"transform, opacity"},nb={fade:{in:{opacity:1},out:{opacity:0},transitionProperty:"opacity"},scale:{in:{opacity:1,transform:"scale(1)"},out:{opacity:0,transform:"scale(0)"},common:{transformOrigin:"top"},transitionProperty:"transform, opacity"},"scale-y":{in:{opacity:1,transform:"scaleY(1)"},out:{opacity:0,transform:"scaleY(0)"},common:{transformOrigin:"top"},transitionProperty:"transform, opacity"},"scale-x":{in:{opacity:1,transform:"scaleX(1)"},out:{opacity:0,transform:"scaleX(0)"},common:{transformOrigin:"left"},transitionProperty:"transform, opacity"},"skew-up":{in:{opacity:1,transform:"translateY(0) skew(0deg, 0deg)"},out:{opacity:0,transform:"translateY(-20px) skew(-10deg, -5deg)"},common:{transformOrigin:"top"},transitionProperty:"transform, opacity"},"skew-down":{in:{opacity:1,transform:"translateY(0) skew(0deg, 0deg)"},out:{opacity:0,transform:"translateY(20px) skew(-10deg, -5deg)"},common:{transformOrigin:"bottom"},transitionProperty:"transform, opacity"},"rotate-left":{in:{opacity:1,transform:"translateY(0) rotate(0deg)"},out:{opacity:0,transform:"translateY(20px) rotate(-5deg)"},common:{transformOrigin:"bottom"},transitionProperty:"transform, opacity"},"rotate-right":{in:{opacity:1,transform:"translateY(0) rotate(0deg)"},out:{opacity:0,transform:"translateY(20px) rotate(5deg)"},common:{transformOrigin:"top"},transitionProperty:"transform, opacity"},"slide-down":{in:{opacity:1,transform:"translateY(0)"},out:{opacity:0,transform:"translateY(-100%)"},common:{transformOrigin:"top"},transitionProperty:"transform, opacity"},"slide-up":{in:{opacity:1,transform:"translateY(0)"},out:{opacity:0,transform:"translateY(100%)"},common:{transformOrigin:"bottom"},transitionProperty:"transform, opacity"},"slide-left":{in:{opacity:1,transform:"translateX(0)"},out:{opacity:0,transform:"translateX(100%)"},common:{transformOrigin:"left"},transitionProperty:"transform, opacity"},"slide-right":{in:{opacity:1,transform:"translateX(0)"},out:{opacity:0,transform:"translateX(-100%)"},common:{transformOrigin:"right"},transitionProperty:"transform, opacity"},pop:m0(p0({},g0),{common:{transformOrigin:"center center"}}),"pop-bottom-left":m0(p0({},g0),{common:{transformOrigin:"bottom left"}}),"pop-bottom-right":m0(p0({},g0),{common:{transformOrigin:"bottom right"}}),"pop-top-left":m0(p0({},g0),{common:{transformOrigin:"top left"}}),"pop-top-right":m0(p0({},g0),{common:{transformOrigin:"top right"}})},qF=["mousedown","touchstart"];function Tve(e,t,n){const r=w.useRef();return w.useEffect(()=>{const i=s=>{const{target:o}=s??{};if(Array.isArray(n)){const a=(o==null?void 0:o.hasAttribute("data-ignore-outside-clicks"))||!document.body.contains(o)&&o.tagName!=="HTML";n.every(l=>!!l&&!s.composedPath().includes(l))&&!a&&e()}else r.current&&!r.current.contains(o)&&e()};return(t||qF).forEach(s=>document.addEventListener(s,i)),()=>{(t||qF).forEach(s=>document.removeEventListener(s,i))}},[r,e,n]),r}function Ive(e,t){try{return e.addEventListener("change",t),()=>e.removeEventListener("change",t)}catch{return e.addListener(t),()=>e.removeListener(t)}}function xve(e,t){return typeof t=="boolean"?t:typeof window<"u"&&"matchMedia"in window?window.matchMedia(e).matches:!1}function Cve(e,t,{getInitialValueInEffect:n}={getInitialValueInEffect:!0}){const[r,i]=w.useState(n?t:xve(e,t)),s=w.useRef();return w.useEffect(()=>{if("matchMedia"in window)return s.current=window.matchMedia(e),i(s.current.matches),Ive(s.current,o=>i(o.matches))},[e]),r}function ff(e,t,n){return Math.min(Math.max(e,t),n)}const T$=typeof document<"u"?w.useLayoutEffect:w.useEffect;function Js(e,t){const n=w.useRef(!1);w.useEffect(()=>()=>{n.current=!1},[]),w.useEffect(()=>{if(n.current)return e();n.current=!0},t)}function LK({opened:e,shouldReturnFocus:t=!0}){const n=w.useRef(),r=()=>{var i;n.current&&"focus"in n.current&&typeof n.current.focus=="function"&&((i=n.current)==null||i.focus({preventScroll:!0}))};return Js(()=>{let i=-1;const s=o=>{o.key==="Tab"&&window.clearTimeout(i)};return document.addEventListener("keydown",s),e?n.current=document.activeElement:t&&(i=window.setTimeout(r,10)),()=>{window.clearTimeout(i),document.removeEventListener("keydown",s)}},[e,t]),r}const Ave=/input|select|textarea|button|object/,MK="a, input, select, textarea, button, object, [tabindex]";function Pve(e){return e.style.display==="none"}function Ove(e){if(e.getAttribute("aria-hidden")||e.getAttribute("hidden")||e.getAttribute("type")==="hidden")return!1;let n=e;for(;n&&!(n===document.body||n.nodeType===11);){if(Pve(n))return!1;n=n.parentNode}return!0}function FK(e){let t=e.getAttribute("tabindex");return t===null&&(t=void 0),parseInt(t,10)}function BR(e){const t=e.nodeName.toLowerCase(),n=!Number.isNaN(FK(e));return(Ave.test(t)&&!e.disabled||e instanceof HTMLAnchorElement&&e.href||n)&&Ove(e)}function BK(e){const t=FK(e);return(Number.isNaN(t)||t>=0)&&BR(e)}function Rve(e){return Array.from(e.querySelectorAll(MK)).filter(BK)}function Nve(e,t){const n=Rve(e);if(!n.length){t.preventDefault();return}const r=n[t.shiftKey?0:n.length-1],i=e.getRootNode();if(!(r===i.activeElement||e===i.activeElement))return;t.preventDefault();const o=n[t.shiftKey?n.length-1:0];o&&o.focus()}function kve(e,t="body > :not(script)"){const n=Array.from(document.querySelectorAll(t)).map(r=>{var i;if((i=r==null?void 0:r.shadowRoot)!=null&&i.contains(e)||r.contains(e))return;const s=r.getAttribute("aria-hidden");return(s===null||s==="false")&&r.setAttribute("aria-hidden","true"),{node:r,ariaHidden:s}});return()=>{n.forEach(r=>{r&&(r.ariaHidden===null?r.node.removeAttribute("aria-hidden"):r.node.setAttribute("aria-hidden",r.ariaHidden))})}}function jK(e=!0){const t=w.useRef(),n=w.useRef(null),r=w.useCallback(i=>{if(e){if(i===null){n.current&&(n.current(),n.current=null);return}if(n.current=kve(i),t.current!==i)if(i){const s=()=>{let o=i.querySelector("[data-autofocus]");if(!o){const a=Array.from(i.querySelectorAll(MK));o=a.find(BK)||a.find(BR)||null,!o&&BR(i)&&(o=i)}o&&o.focus({preventScroll:!0})};setTimeout(()=>{i.getRootNode()&&s()}),t.current=i}else t.current=null}},[e]);return w.useEffect(()=>{if(!e)return;const i=s=>{s.key==="Tab"&&t.current&&Nve(t.current,s)};return document.addEventListener("keydown",i),()=>{document.removeEventListener("keydown",i),n.current&&n.current()}},[e]),r}const Dve=e=>(e+1)%1e6;function $ve(){const[,e]=w.useReducer(Dve,0);return e}const Lve=()=>`mantine-${Math.random().toString(36).slice(2,11)}`,Mve=N.useId||(()=>{});function Fve(){const[e,t]=w.useState("");return T$(()=>{t(Lve())},[]),e}function Bve(){const e=Mve();return e?`mantine-${e.replace(/:/g,"")}`:""}function tu(e){return typeof e=="string"?e:Bve()||Fve()}function jR(e,t,n){w.useEffect(()=>(window.addEventListener(e,t,n),()=>window.removeEventListener(e,t,n)),[e,t])}function UK(e,t){typeof e=="function"?e(t):typeof e=="object"&&e!==null&&"current"in e&&(e.current=t)}function VK(...e){return t=>{e.forEach(n=>UK(n,t))}}function fa(...e){return w.useCallback(VK(...e),e)}function zK(e,t,n="ltr"){const r=w.useRef(),i=w.useRef(!1),s=w.useRef(!1),o=w.useRef(0),[a,u]=w.useState(!1);return w.useEffect(()=>{i.current=!0},[]),w.useEffect(()=>{const l=({x:v,y:b})=>{cancelAnimationFrame(o.current),o.current=requestAnimationFrame(()=>{if(i.current&&r.current){r.current.style.userSelect="none";const S=r.current.getBoundingClientRect();if(S.width&&S.height){const T=ff((v-S.left)/S.width,0,1);e({x:n==="ltr"?T:1-T,y:ff((b-S.top)/S.height,0,1)})}}})},c=()=>{document.addEventListener("mousemove",m),document.addEventListener("mouseup",h),document.addEventListener("touchmove",g),document.addEventListener("touchend",h)},f=()=>{document.removeEventListener("mousemove",m),document.removeEventListener("mouseup",h),document.removeEventListener("touchmove",g),document.removeEventListener("touchend",h)},d=()=>{!s.current&&i.current&&(s.current=!0,typeof(t==null?void 0:t.onScrubStart)=="function"&&t.onScrubStart(),u(!0),c())},h=()=>{s.current&&i.current&&(s.current=!1,u(!1),f(),setTimeout(()=>{typeof(t==null?void 0:t.onScrubEnd)=="function"&&t.onScrubEnd()},0))},p=v=>{d(),v.preventDefault(),m(v)},m=v=>l({x:v.clientX,y:v.clientY}),y=v=>{v.cancelable&&v.preventDefault(),d(),g(v)},g=v=>{v.cancelable&&v.preventDefault(),l({x:v.changedTouches[0].clientX,y:v.changedTouches[0].clientY})};return r.current.addEventListener("mousedown",p),r.current.addEventListener("touchstart",y,{passive:!1}),()=>{r.current&&(r.current.removeEventListener("mousedown",p),r.current.removeEventListener("touchstart",y))}},[n,e]),{ref:r,active:a}}function oa({value:e,defaultValue:t,finalValue:n,onChange:r=()=>{}}){const[i,s]=w.useState(t!==void 0?t:n),o=a=>{s(a),r==null||r(a)};return e!==void 0?[e,r,!0]:[i,o,!1]}function Rx(e,t){return Cve("(prefers-reduced-motion: reduce)",e,t)}const jve=e=>e<.5?2*e*e:-1+(4-2*e)*e,Uve=({axis:e,target:t,parent:n,alignment:r,offset:i,isList:s})=>{if(!t||!n&&typeof document>"u")return 0;const o=!!n,u=(n||document.body).getBoundingClientRect(),l=t.getBoundingClientRect(),c=f=>l[f]-u[f];if(e==="y"){const f=c("top");if(f===0)return 0;if(r==="start"){const h=f-i;return h<=l.height*(s?0:1)||!s?h:0}const d=o?u.height:window.innerHeight;if(r==="end"){const h=f+i-d+l.height;return h>=-l.height*(s?0:1)||!s?h:0}return r==="center"?f-d/2+l.height/2:0}if(e==="x"){const f=c("left");if(f===0)return 0;if(r==="start"){const h=f-i;return h<=l.width||!s?h:0}const d=o?u.width:window.innerWidth;if(r==="end"){const h=f+i-d+l.width;return h>=-l.width||!s?h:0}return r==="center"?f-d/2+l.width/2:0}return 0},Vve=({axis:e,parent:t})=>{if(!t&&typeof document>"u")return 0;const n=e==="y"?"scrollTop":"scrollLeft";if(t)return t[n];const{body:r,documentElement:i}=document;return r[n]+i[n]},zve=({axis:e,parent:t,distance:n})=>{if(!t&&typeof document>"u")return;const r=e==="y"?"scrollTop":"scrollLeft";if(t)t[r]=n;else{const{body:i,documentElement:s}=document;i[r]=n,s[r]=n}};function HK({duration:e=1250,axis:t="y",onScrollFinish:n,easing:r=jve,offset:i=0,cancelable:s=!0,isList:o=!1}={}){const a=w.useRef(0),u=w.useRef(0),l=w.useRef(!1),c=w.useRef(null),f=w.useRef(null),d=Rx(),h=()=>{a.current&&cancelAnimationFrame(a.current)},p=w.useCallback(({alignment:y="start"}={})=>{var g;l.current=!1,a.current&&h();const v=(g=Vve({parent:c.current,axis:t}))!=null?g:0,b=Uve({parent:c.current,target:f.current,axis:t,alignment:y,offset:i,isList:o})-(c.current?0:v);function S(){u.current===0&&(u.current=performance.now());const E=performance.now()-u.current,I=d||e===0?1:E/e,A=v+b*r(I);zve({parent:c.current,axis:t,distance:A}),!l.current&&I<1?a.current=requestAnimationFrame(S):(typeof n=="function"&&n(),u.current=0,a.current=0,h())}S()},[t,e,r,o,i,n,d]),m=()=>{s&&(l.current=!0)};return jR("wheel",m,{passive:!0}),jR("touchmove",m,{passive:!0}),w.useEffect(()=>h,[]),{scrollableRef:c,targetRef:f,scrollIntoView:p,cancel:h}}const Hve={x:0,y:0,width:0,height:0,top:0,left:0,bottom:0,right:0};function Nx(){const e=w.useRef(0),t=w.useRef(null),[n,r]=w.useState(Hve),i=w.useMemo(()=>typeof window<"u"?new ResizeObserver(s=>{const o=s[0];o&&(cancelAnimationFrame(e.current),e.current=requestAnimationFrame(()=>{t.current&&r(o.contentRect)}))}):null,[]);return w.useEffect(()=>(t.current&&i.observe(t.current),()=>{i.disconnect(),e.current&&cancelAnimationFrame(e.current)}),[t.current]),[t,n]}function Wve(){if(typeof window>"u"||typeof document>"u")return 0;const e=parseInt(window.getComputedStyle(document.body).paddingRight,10),t=window.innerWidth-document.documentElement.clientWidth;return e+t}const qve=({disableBodyPadding:e})=>{const t=e?null:Wve();return`body { --removed-scroll-width: ${t}px; touch-action: none; overflow: hidden !important; position: relative !important; ${t?"padding-right: var(--removed-scroll-width) !important;":""} - `};function Gve(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function Yve(e){(document.head||document.getElementsByTagName("head")[0]).appendChild(e)}function Kve(){const e=document.createElement("style");return e.type="text/css",e.setAttribute("mantine-scroll-lock",""),e}function Qve(e,t={disableBodyPadding:!1}){const[n,r]=w.useState(e||!1),i=w.useRef(0),{disableBodyPadding:s}=t,o=w.useRef(null),a=()=>{i.current=window.scrollY;const l=qve({disableBodyPadding:s}),c=Kve();Gve(c,l),Yve(c),o.current=c},u=()=>{o!=null&&o.current&&(o.current.parentNode.removeChild(o.current),o.current=null)};return w.useEffect(()=>(n?a():u(),u),[n]),w.useEffect(()=>{e!==void 0&&r(e)},[e]),w.useEffect(()=>{e===void 0&&typeof window<"u"&&window.document.body.style.overflow==="hidden"&&r(!0)},[r]),[n,r]}function Xve(){const{userAgent:e}=window.navigator,t=/(Macintosh)|(MacIntel)|(MacPPC)|(Mac68K)/i,n=/(Win32)|(Win64)|(Windows)|(WinCE)/i,r=/(iPhone)|(iPad)|(iPod)/i;return t.test(e)?"macos":r.test(e)?"ios":n.test(e)?"windows":/Android/i.test(e)?"android":/Linux/i.test(e)?"linux":"undetermined"}function Jve(){return typeof window<"u"?Xve():"undetermined"}function Zve(e){return t=>{if(!t)e(t);else if(typeof t=="function")e(t);else if(typeof t=="object"&&"nativeEvent"in t){const{currentTarget:n}=t;n.type==="checkbox"?e(n.checked):e(n.value)}else e(t)}}function e_e(e){const[t,n]=w.useState(e);return[t,Zve(n)]}function x$(e=!1,t){const{onOpen:n,onClose:r}=t||{},[i,s]=w.useState(e),o=w.useCallback(()=>{s(l=>l||(n==null||n(),!0))},[n]),a=w.useCallback(()=>{s(l=>l&&(r==null||r(),!1))},[r]),u=w.useCallback(()=>{i?a():o()},[a,o,i]);return[i,{open:o,close:a,toggle:u}]}function t_e(){return`mantine-${Math.random().toString(36).slice(2,11)}`}var YF=Object.getOwnPropertySymbols,n_e=Object.prototype.hasOwnProperty,r_e=Object.prototype.propertyIsEnumerable,i_e=(e,t)=>{var n={};for(var r in e)n_e.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&YF)for(var r of YF(e))t.indexOf(r)<0&&r_e.call(e,r)&&(n[r]=e[r]);return n};function Qf(e){const t=e,{m:n,mx:r,my:i,mt:s,mb:o,ml:a,mr:u,p:l,px:c,py:f,pt:d,pb:h,pl:p,pr:m,bg:y,c:g,opacity:v,ff:b,fz:S,fw:T,lts:E,ta:I,lh:A,fs:R,tt:F,td:L,w:B,miw:J,maw:V,h:re,mih:oe,mah:ae,bgsz:ee,bgp:ue,bgr:P,bga:W,pos:Q,top:x,left:O,bottom:$,right:q,inset:ce,display:fe}=t,de=i_e(t,["m","mx","my","mt","mb","ml","mr","p","px","py","pt","pb","pl","pr","bg","c","opacity","ff","fz","fw","lts","ta","lh","fs","tt","td","w","miw","maw","h","mih","mah","bgsz","bgp","bgr","bga","pos","top","left","bottom","right","inset","display"]);return{systemStyles:RK({m:n,mx:r,my:i,mt:s,mb:o,ml:a,mr:u,p:l,px:c,py:f,pt:d,pb:h,pl:p,pr:m,bg:y,c:g,opacity:v,ff:b,fz:S,fw:T,lts:E,ta:I,lh:A,fs:R,tt:F,td:L,w:B,miw:J,maw:V,h:re,mih:oe,mah:ae,bgsz:ee,bgp:ue,bgr:P,bga:W,pos:Q,top:x,left:O,bottom:$,right:q,inset:ce,display:fe}),rest:de}}function s_e(e,t){const n=Object.keys(e).filter(r=>r!=="base").sort((r,i)=>t.fn.size({size:r,sizes:t.breakpoints})-t.fn.size({size:i,sizes:t.breakpoints}));return"base"in e?["base",...n]:n}function o_e({value:e,theme:t,getValue:n,property:r}){if(e==null)return;if(typeof e=="object")return s_e(e,t).reduce((o,a)=>{if(a==="base"&&e.base!==void 0){const l=n(e.base,t);return Array.isArray(r)?(r.forEach(c=>{o[c]=l}),o):(o[r]=l,o)}const u=n(e[a],t);return Array.isArray(r)?(o[t.fn.largerThan(a)]={},r.forEach(l=>{o[t.fn.largerThan(a)][l]=u}),o):(o[t.fn.largerThan(a)]={[r]:u},o)},{});const i=n(e,t);return Array.isArray(r)?r.reduce((s,o)=>(s[o]=i,s),{}):{[r]:i}}function a_e(e,t){return e==="dimmed"?t.colorScheme==="dark"?t.colors.dark[2]:t.colors.gray[6]:t.fn.variant({variant:"filled",color:e,primaryFallback:!1}).background}function u_e(e){return e}function l_e(e,t){return t.fn.size({size:e,sizes:t.fontSizes})}const c_e=["-xs","-sm","-md","-lg","-xl"];function f_e(e,t){return c_e.includes(e)?t.fn.size({size:e.replace("-",""),sizes:t.spacing})*-1:t.fn.size({size:e,sizes:t.spacing})}const d_e={color:a_e,default:u_e,fontSize:l_e,spacing:f_e},h_e={m:{type:"spacing",property:"margin"},mt:{type:"spacing",property:"marginTop"},mb:{type:"spacing",property:"marginBottom"},ml:{type:"spacing",property:"marginLeft"},mr:{type:"spacing",property:"marginRight"},mx:{type:"spacing",property:["marginRight","marginLeft"]},my:{type:"spacing",property:["marginTop","marginBottom"]},p:{type:"spacing",property:"padding"},pt:{type:"spacing",property:"paddingTop"},pb:{type:"spacing",property:"paddingBottom"},pl:{type:"spacing",property:"paddingLeft"},pr:{type:"spacing",property:"paddingRight"},px:{type:"spacing",property:["paddingRight","paddingLeft"]},py:{type:"spacing",property:["paddingTop","paddingBottom"]},bg:{type:"color",property:"background"},c:{type:"color",property:"color"},opacity:{type:"default",property:"opacity"},ff:{type:"default",property:"fontFamily"},fz:{type:"fontSize",property:"fontSize"},fw:{type:"default",property:"fontWeight"},lts:{type:"default",property:"letterSpacing"},ta:{type:"default",property:"textAlign"},lh:{type:"default",property:"lineHeight"},fs:{type:"default",property:"fontStyle"},tt:{type:"default",property:"textTransform"},td:{type:"default",property:"textDecoration"},w:{type:"spacing",property:"width"},miw:{type:"spacing",property:"minWidth"},maw:{type:"spacing",property:"maxWidth"},h:{type:"spacing",property:"height"},mih:{type:"spacing",property:"minHeight"},mah:{type:"spacing",property:"maxHeight"},bgsz:{type:"default",property:"background-size"},bgp:{type:"default",property:"background-position"},bgr:{type:"default",property:"background-repeat"},bga:{type:"default",property:"background-attachment"},pos:{type:"default",property:"position"},top:{type:"default",property:"top"},left:{type:"default",property:"left"},bottom:{type:"default",property:"bottom"},right:{type:"default",property:"right"},inset:{type:"default",property:"inset"},display:{type:"default",property:"display"}};var p_e=Object.defineProperty,KF=Object.getOwnPropertySymbols,m_e=Object.prototype.hasOwnProperty,g_e=Object.prototype.propertyIsEnumerable,QF=(e,t,n)=>t in e?p_e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,XF=(e,t)=>{for(var n in t||(t={}))m_e.call(t,n)&&QF(e,n,t[n]);if(KF)for(var n of KF(t))g_e.call(t,n)&&QF(e,n,t[n]);return e};function VR(e,t,n=h_e){return Object.keys(n).reduce((i,s)=>(s in e&&e[s]!==void 0&&i.push(o_e({value:e[s],getValue:d_e[n[s].type],property:n[s].property,theme:t})),i),[]).reduce((i,s)=>(Object.keys(s).forEach(o=>{typeof s[o]=="object"&&s[o]!==null&&o in i?i[o]=XF(XF({},i[o]),s[o]):i[o]=s[o]}),i),{})}function JF(e,t){return typeof e=="function"?e(t):e}function y_e(e,t,n){const r=ji(),{css:i,cx:s}=DK();return Array.isArray(e)?s(n,i(VR(t,r)),e.map(o=>i(JF(o,r)))):s(n,i(JF(e,r)),i(VR(t,r)))}var v_e=Object.defineProperty,kE=Object.getOwnPropertySymbols,WK=Object.prototype.hasOwnProperty,qK=Object.prototype.propertyIsEnumerable,ZF=(e,t,n)=>t in e?v_e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,__e=(e,t)=>{for(var n in t||(t={}))WK.call(t,n)&&ZF(e,n,t[n]);if(kE)for(var n of kE(t))qK.call(t,n)&&ZF(e,n,t[n]);return e},b_e=(e,t)=>{var n={};for(var r in e)WK.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&kE)for(var r of kE(e))t.indexOf(r)<0&&qK.call(e,r)&&(n[r]=e[r]);return n};const GK=w.forwardRef((e,t)=>{var n=e,{className:r,component:i,style:s,sx:o}=n,a=b_e(n,["className","component","style","sx"]);const{systemStyles:u,rest:l}=Qf(a),c=i||"div";return N.createElement(c,__e({ref:t,className:y_e(o,u,r),style:s},l))});GK.displayName="@mantine/core/Box";const it=GK;var w_e=Object.defineProperty,E_e=Object.defineProperties,S_e=Object.getOwnPropertyDescriptors,e8=Object.getOwnPropertySymbols,T_e=Object.prototype.hasOwnProperty,I_e=Object.prototype.propertyIsEnumerable,t8=(e,t,n)=>t in e?w_e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,n8=(e,t)=>{for(var n in t||(t={}))T_e.call(t,n)&&t8(e,n,t[n]);if(e8)for(var n of e8(t))I_e.call(t,n)&&t8(e,n,t[n]);return e},x_e=(e,t)=>E_e(e,S_e(t)),C_e=lt(e=>({root:x_e(n8(n8({},e.fn.focusStyles()),e.fn.fontStyles()),{cursor:"pointer",border:0,padding:0,appearance:"none",fontSize:e.fontSizes.md,backgroundColor:"transparent",textAlign:"left",color:e.colorScheme==="dark"?e.colors.dark[0]:e.black,textDecoration:"none",boxSizing:"border-box"})})),A_e=Object.defineProperty,DE=Object.getOwnPropertySymbols,YK=Object.prototype.hasOwnProperty,KK=Object.prototype.propertyIsEnumerable,r8=(e,t,n)=>t in e?A_e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,P_e=(e,t)=>{for(var n in t||(t={}))YK.call(t,n)&&r8(e,n,t[n]);if(DE)for(var n of DE(t))KK.call(t,n)&&r8(e,n,t[n]);return e},O_e=(e,t)=>{var n={};for(var r in e)YK.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&DE)for(var r of DE(e))t.indexOf(r)<0&&KK.call(e,r)&&(n[r]=e[r]);return n};const QK=w.forwardRef((e,t)=>{const n=Ve("UnstyledButton",{},e),{className:r,component:i="button",unstyled:s}=n,o=O_e(n,["className","component","unstyled"]),{classes:a,cx:u}=C_e(null,{name:"UnstyledButton",unstyled:s});return N.createElement(it,P_e({component:i,ref:t,className:u(a.root,r),type:i==="button"?"button":void 0},o))});QK.displayName="@mantine/core/UnstyledButton";const kx=QK;var R_e=Object.defineProperty,N_e=Object.defineProperties,k_e=Object.getOwnPropertyDescriptors,$E=Object.getOwnPropertySymbols,XK=Object.prototype.hasOwnProperty,JK=Object.prototype.propertyIsEnumerable,i8=(e,t,n)=>t in e?R_e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ud=(e,t)=>{for(var n in t||(t={}))XK.call(t,n)&&i8(e,n,t[n]);if($E)for(var n of $E(t))JK.call(t,n)&&i8(e,n,t[n]);return e},OP=(e,t)=>N_e(e,k_e(t)),D_e=(e,t)=>{var n={};for(var r in e)XK.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&$E)for(var r of $E(e))t.indexOf(r)<0&&JK.call(e,r)&&(n[r]=e[r]);return n};function $_e(e){if(!e||typeof e=="string")return 0;const t=e/36;return Math.round((4+15*t**.25+t/5)*10)}function RP(e){return e!=null&&e.current?e.current.scrollHeight:"auto"}const rb=typeof window<"u"&&window.requestAnimationFrame;function L_e({transitionDuration:e,transitionTimingFunction:t="ease",onTransitionEnd:n=()=>{},opened:r}){const i=w.useRef(null),s="0px",o={display:"none",height:"0px",overflow:"hidden"},[a,u]=w.useState(r?{}:o),l=p=>{lc.flushSync(()=>u(p))},c=p=>{l(m=>ud(ud({},m),p))};function f(p){return{transition:`height ${e||$_e(p)}ms ${t}`}}Js(()=>{rb(r?()=>{c({willChange:"height",display:"block",overflow:"hidden"}),rb(()=>{const p=RP(i);c(OP(ud({},f(p)),{height:p}))})}:()=>{const p=RP(i);c(OP(ud({},f(p)),{willChange:"height",height:p})),rb(()=>c({height:s,overflow:"hidden"}))})},[r]);const d=p=>{if(!(p.target!==i.current||p.propertyName!=="height"))if(r){const m=RP(i);m===a.height?l({}):c({height:m}),n()}else a.height===s&&(l(o),n())};function h(p={}){var m=p,{style:y={},refKey:g="ref"}=m,v=D_e(m,["style","refKey"]);const b=v[g];return OP(ud({"aria-hidden":!r},v),{[g]:VK(i,b),onTransitionEnd:d,style:ud(ud({boxSizing:"border-box"},y),a)})}return h}var M_e=Object.defineProperty,LE=Object.getOwnPropertySymbols,ZK=Object.prototype.hasOwnProperty,eQ=Object.prototype.propertyIsEnumerable,s8=(e,t,n)=>t in e?M_e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ib=(e,t)=>{for(var n in t||(t={}))ZK.call(t,n)&&s8(e,n,t[n]);if(LE)for(var n of LE(t))eQ.call(t,n)&&s8(e,n,t[n]);return e},F_e=(e,t)=>{var n={};for(var r in e)ZK.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&LE)for(var r of LE(e))t.indexOf(r)<0&&eQ.call(e,r)&&(n[r]=e[r]);return n};const B_e={transitionDuration:200,transitionTimingFunction:"ease",animateOpacity:!0},tQ=w.forwardRef((e,t)=>{const n=Ve("Collapse",B_e,e),{children:r,in:i,transitionDuration:s,transitionTimingFunction:o,style:a,onTransitionEnd:u,animateOpacity:l}=n,c=F_e(n,["children","in","transitionDuration","transitionTimingFunction","style","onTransitionEnd","animateOpacity"]),f=ji(),d=Rx(),p=(f.respectReducedMotion?d:!1)?0:s,{systemStyles:m,rest:y}=Qf(c),g=L_e({opened:i,transitionDuration:p,transitionTimingFunction:o,onTransitionEnd:u});return p===0?i?N.createElement(it,ib({},y),r):null:N.createElement(it,ib({},g(ib(ib({style:a,ref:t},y),m))),N.createElement("div",{style:{opacity:i||!l?1:0,transition:l?`opacity ${p}ms ${o}`:"none"}},r))});tQ.displayName="@mantine/core/Collapse";var j_e=Object.defineProperty,o8=Object.getOwnPropertySymbols,U_e=Object.prototype.hasOwnProperty,V_e=Object.prototype.propertyIsEnumerable,a8=(e,t,n)=>t in e?j_e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,z_e=(e,t)=>{for(var n in t||(t={}))U_e.call(t,n)&&a8(e,n,t[n]);if(o8)for(var n of o8(t))V_e.call(t,n)&&a8(e,n,t[n]);return e};function H_e(e){return N.createElement("svg",z_e({viewBox:"0 0 15 15",fill:"none",xmlns:"http://www.w3.org/2000/svg",width:16,height:16},e),N.createElement("path",{d:"M3.13523 6.15803C3.3241 5.95657 3.64052 5.94637 3.84197 6.13523L7.5 9.56464L11.158 6.13523C11.3595 5.94637 11.6759 5.95657 11.8648 6.15803C12.0536 6.35949 12.0434 6.67591 11.842 6.86477L7.84197 10.6148C7.64964 10.7951 7.35036 10.7951 7.15803 10.6148L3.15803 6.86477C2.95657 6.67591 2.94637 6.35949 3.13523 6.15803Z",fill:"currentColor",fillRule:"evenodd",clipRule:"evenodd"}))}var W_e=Object.defineProperty,q_e=Object.defineProperties,G_e=Object.getOwnPropertyDescriptors,u8=Object.getOwnPropertySymbols,Y_e=Object.prototype.hasOwnProperty,K_e=Object.prototype.propertyIsEnumerable,l8=(e,t,n)=>t in e?W_e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,nQ=(e,t)=>{for(var n in t||(t={}))Y_e.call(t,n)&&l8(e,n,t[n]);if(u8)for(var n of u8(t))K_e.call(t,n)&&l8(e,n,t[n]);return e},Q_e=(e,t)=>q_e(e,G_e(t));const G0={xs:18,sm:22,md:28,lg:34,xl:44};function X_e({variant:e,theme:t,color:n,gradient:r}){const i=t.fn.variant({color:n,variant:e,gradient:r});return e==="gradient"?{border:0,backgroundImage:i.background,color:i.color,"&:hover":t.fn.hover({backgroundSize:"200%"})}:nQ({border:`1px solid ${i.border}`,backgroundColor:i.background,color:i.color},t.fn.hover({backgroundColor:i.hover}))}var J_e=lt((e,{color:t,size:n,radius:r,variant:i,gradient:s})=>({root:Q_e(nQ({},X_e({variant:i,theme:e,color:t,gradient:s})),{position:"relative",height:e.fn.size({size:n,sizes:G0}),minHeight:e.fn.size({size:n,sizes:G0}),width:e.fn.size({size:n,sizes:G0}),minWidth:e.fn.size({size:n,sizes:G0}),borderRadius:e.fn.radius(r),padding:0,lineHeight:1,display:"flex",alignItems:"center",justifyContent:"center","&:active":e.activeStyles,"&:disabled, &[data-disabled]":{color:e.colors.gray[e.colorScheme==="dark"?6:4],cursor:"not-allowed",backgroundColor:i==="transparent"?void 0:e.fn.themeColor("gray",e.colorScheme==="dark"?8:1),borderColor:i==="transparent"?void 0:e.fn.themeColor("gray",e.colorScheme==="dark"?8:1),backgroundImage:"none",pointerEvents:"none","&:active":{transform:"none"}},"&[data-loading]":{pointerEvents:"none","&::before":{content:'""',position:"absolute",top:-1,left:-1,right:-1,bottom:-1,backgroundColor:e.colorScheme==="dark"?e.fn.rgba(e.colors.dark[7],.5):"rgba(255, 255, 255, .5)",borderRadius:e.fn.radius(r),cursor:"not-allowed"}}})})),Z_e=Object.defineProperty,ME=Object.getOwnPropertySymbols,rQ=Object.prototype.hasOwnProperty,iQ=Object.prototype.propertyIsEnumerable,c8=(e,t,n)=>t in e?Z_e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,e1e=(e,t)=>{for(var n in t||(t={}))rQ.call(t,n)&&c8(e,n,t[n]);if(ME)for(var n of ME(t))iQ.call(t,n)&&c8(e,n,t[n]);return e},t1e=(e,t)=>{var n={};for(var r in e)rQ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&ME)for(var r of ME(e))t.indexOf(r)<0&&iQ.call(e,r)&&(n[r]=e[r]);return n};function n1e(e){var t=e,{size:n,color:r}=t,i=t1e(t,["size","color"]);return N.createElement("svg",e1e({viewBox:"0 0 135 140",xmlns:"http://www.w3.org/2000/svg",fill:r,width:`${n}px`},i),N.createElement("rect",{y:"10",width:"15",height:"120",rx:"6"},N.createElement("animate",{attributeName:"height",begin:"0.5s",dur:"1s",values:"120;110;100;90;80;70;60;50;40;140;120",calcMode:"linear",repeatCount:"indefinite"}),N.createElement("animate",{attributeName:"y",begin:"0.5s",dur:"1s",values:"10;15;20;25;30;35;40;45;50;0;10",calcMode:"linear",repeatCount:"indefinite"})),N.createElement("rect",{x:"30",y:"10",width:"15",height:"120",rx:"6"},N.createElement("animate",{attributeName:"height",begin:"0.25s",dur:"1s",values:"120;110;100;90;80;70;60;50;40;140;120",calcMode:"linear",repeatCount:"indefinite"}),N.createElement("animate",{attributeName:"y",begin:"0.25s",dur:"1s",values:"10;15;20;25;30;35;40;45;50;0;10",calcMode:"linear",repeatCount:"indefinite"})),N.createElement("rect",{x:"60",width:"15",height:"140",rx:"6"},N.createElement("animate",{attributeName:"height",begin:"0s",dur:"1s",values:"120;110;100;90;80;70;60;50;40;140;120",calcMode:"linear",repeatCount:"indefinite"}),N.createElement("animate",{attributeName:"y",begin:"0s",dur:"1s",values:"10;15;20;25;30;35;40;45;50;0;10",calcMode:"linear",repeatCount:"indefinite"})),N.createElement("rect",{x:"90",y:"10",width:"15",height:"120",rx:"6"},N.createElement("animate",{attributeName:"height",begin:"0.25s",dur:"1s",values:"120;110;100;90;80;70;60;50;40;140;120",calcMode:"linear",repeatCount:"indefinite"}),N.createElement("animate",{attributeName:"y",begin:"0.25s",dur:"1s",values:"10;15;20;25;30;35;40;45;50;0;10",calcMode:"linear",repeatCount:"indefinite"})),N.createElement("rect",{x:"120",y:"10",width:"15",height:"120",rx:"6"},N.createElement("animate",{attributeName:"height",begin:"0.5s",dur:"1s",values:"120;110;100;90;80;70;60;50;40;140;120",calcMode:"linear",repeatCount:"indefinite"}),N.createElement("animate",{attributeName:"y",begin:"0.5s",dur:"1s",values:"10;15;20;25;30;35;40;45;50;0;10",calcMode:"linear",repeatCount:"indefinite"})))}var r1e=Object.defineProperty,FE=Object.getOwnPropertySymbols,sQ=Object.prototype.hasOwnProperty,oQ=Object.prototype.propertyIsEnumerable,f8=(e,t,n)=>t in e?r1e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,i1e=(e,t)=>{for(var n in t||(t={}))sQ.call(t,n)&&f8(e,n,t[n]);if(FE)for(var n of FE(t))oQ.call(t,n)&&f8(e,n,t[n]);return e},s1e=(e,t)=>{var n={};for(var r in e)sQ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&FE)for(var r of FE(e))t.indexOf(r)<0&&oQ.call(e,r)&&(n[r]=e[r]);return n};function o1e(e){var t=e,{size:n,color:r}=t,i=s1e(t,["size","color"]);return N.createElement("svg",i1e({width:`${n}px`,height:`${n}px`,viewBox:"0 0 38 38",xmlns:"http://www.w3.org/2000/svg",stroke:r},i),N.createElement("g",{fill:"none",fillRule:"evenodd"},N.createElement("g",{transform:"translate(2.5 2.5)",strokeWidth:"5"},N.createElement("circle",{strokeOpacity:".5",cx:"16",cy:"16",r:"16"}),N.createElement("path",{d:"M32 16c0-9.94-8.06-16-16-16"},N.createElement("animateTransform",{attributeName:"transform",type:"rotate",from:"0 16 16",to:"360 16 16",dur:"1s",repeatCount:"indefinite"})))))}var a1e=Object.defineProperty,BE=Object.getOwnPropertySymbols,aQ=Object.prototype.hasOwnProperty,uQ=Object.prototype.propertyIsEnumerable,d8=(e,t,n)=>t in e?a1e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,u1e=(e,t)=>{for(var n in t||(t={}))aQ.call(t,n)&&d8(e,n,t[n]);if(BE)for(var n of BE(t))uQ.call(t,n)&&d8(e,n,t[n]);return e},l1e=(e,t)=>{var n={};for(var r in e)aQ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&BE)for(var r of BE(e))t.indexOf(r)<0&&uQ.call(e,r)&&(n[r]=e[r]);return n};function c1e(e){var t=e,{size:n,color:r}=t,i=l1e(t,["size","color"]);return N.createElement("svg",u1e({width:`${n}px`,height:`${n/4}px`,viewBox:"0 0 120 30",xmlns:"http://www.w3.org/2000/svg",fill:r},i),N.createElement("circle",{cx:"15",cy:"15",r:"15"},N.createElement("animate",{attributeName:"r",from:"15",to:"15",begin:"0s",dur:"0.8s",values:"15;9;15",calcMode:"linear",repeatCount:"indefinite"}),N.createElement("animate",{attributeName:"fill-opacity",from:"1",to:"1",begin:"0s",dur:"0.8s",values:"1;.5;1",calcMode:"linear",repeatCount:"indefinite"})),N.createElement("circle",{cx:"60",cy:"15",r:"9",fillOpacity:"0.3"},N.createElement("animate",{attributeName:"r",from:"9",to:"9",begin:"0s",dur:"0.8s",values:"9;15;9",calcMode:"linear",repeatCount:"indefinite"}),N.createElement("animate",{attributeName:"fill-opacity",from:"0.5",to:"0.5",begin:"0s",dur:"0.8s",values:".5;1;.5",calcMode:"linear",repeatCount:"indefinite"})),N.createElement("circle",{cx:"105",cy:"15",r:"15"},N.createElement("animate",{attributeName:"r",from:"15",to:"15",begin:"0s",dur:"0.8s",values:"15;9;15",calcMode:"linear",repeatCount:"indefinite"}),N.createElement("animate",{attributeName:"fill-opacity",from:"1",to:"1",begin:"0s",dur:"0.8s",values:"1;.5;1",calcMode:"linear",repeatCount:"indefinite"})))}var f1e=Object.defineProperty,jE=Object.getOwnPropertySymbols,lQ=Object.prototype.hasOwnProperty,cQ=Object.prototype.propertyIsEnumerable,h8=(e,t,n)=>t in e?f1e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,d1e=(e,t)=>{for(var n in t||(t={}))lQ.call(t,n)&&h8(e,n,t[n]);if(jE)for(var n of jE(t))cQ.call(t,n)&&h8(e,n,t[n]);return e},h1e=(e,t)=>{var n={};for(var r in e)lQ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&jE)for(var r of jE(e))t.indexOf(r)<0&&cQ.call(e,r)&&(n[r]=e[r]);return n};const NP={bars:n1e,oval:o1e,dots:c1e},p1e={xs:18,sm:22,md:36,lg:44,xl:58},m1e={size:"md"};function Xf(e){const t=Ve("Loader",m1e,e),{size:n,color:r,variant:i}=t,s=h1e(t,["size","color","variant"]),o=ji(),a=i in NP?i:o.loader;return N.createElement(it,d1e({role:"presentation",component:NP[a]||NP.bars,size:o.fn.size({size:n,sizes:p1e}),color:o.fn.variant({variant:"filled",primaryFallback:!1,color:r||o.primaryColor}).background},s))}Xf.displayName="@mantine/core/Loader";var g1e=Object.defineProperty,UE=Object.getOwnPropertySymbols,fQ=Object.prototype.hasOwnProperty,dQ=Object.prototype.propertyIsEnumerable,p8=(e,t,n)=>t in e?g1e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,m8=(e,t)=>{for(var n in t||(t={}))fQ.call(t,n)&&p8(e,n,t[n]);if(UE)for(var n of UE(t))dQ.call(t,n)&&p8(e,n,t[n]);return e},y1e=(e,t)=>{var n={};for(var r in e)fQ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&UE)for(var r of UE(e))t.indexOf(r)<0&&dQ.call(e,r)&&(n[r]=e[r]);return n};const v1e={color:"gray",size:"md",variant:"subtle",loading:!1},hQ=w.forwardRef((e,t)=>{const n=Ve("ActionIcon",v1e,e),{className:r,color:i,children:s,radius:o,size:a,variant:u,gradient:l,disabled:c,loaderProps:f,loading:d,unstyled:h}=n,p=y1e(n,["className","color","children","radius","size","variant","gradient","disabled","loaderProps","loading","unstyled"]),{classes:m,cx:y,theme:g}=J_e({size:a,radius:o,color:i,variant:u,gradient:l},{name:"ActionIcon",unstyled:h}),v=g.fn.variant({color:i,variant:u}),b=N.createElement(Xf,m8({color:v.color,size:g.fn.size({size:a,sizes:G0})-12},f));return N.createElement(kx,m8({className:y(m.root,r),ref:t,disabled:c,"data-disabled":c||void 0,"data-loading":d||void 0,unstyled:h},p),d?b:s)});hQ.displayName="@mantine/core/ActionIcon";const pQ=hQ;function mQ(e){const{children:t,target:n,className:r}=Ve("Portal",{},e),i=ji(),[s,o]=w.useState(!1),a=w.useRef();return I$(()=>(o(!0),a.current=n?typeof n=="string"?document.querySelector(n):n:document.createElement("div"),n||document.body.appendChild(a.current),()=>{!n&&document.body.removeChild(a.current)}),[n]),s?lc.createPortal(N.createElement("div",{className:r,dir:i.dir},t),a.current):null}mQ.displayName="@mantine/core/Portal";var _1e=Object.defineProperty,VE=Object.getOwnPropertySymbols,gQ=Object.prototype.hasOwnProperty,yQ=Object.prototype.propertyIsEnumerable,g8=(e,t,n)=>t in e?_1e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,b1e=(e,t)=>{for(var n in t||(t={}))gQ.call(t,n)&&g8(e,n,t[n]);if(VE)for(var n of VE(t))yQ.call(t,n)&&g8(e,n,t[n]);return e},w1e=(e,t)=>{var n={};for(var r in e)gQ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&VE)for(var r of VE(e))t.indexOf(r)<0&&yQ.call(e,r)&&(n[r]=e[r]);return n};function $_(e){var t=e,{withinPortal:n=!0,children:r}=t,i=w1e(t,["withinPortal","children"]);return n?N.createElement(mQ,b1e({},i),r):N.createElement(N.Fragment,null,r)}$_.displayName="@mantine/core/OptionalPortal";var E1e=Object.defineProperty,S1e=Object.defineProperties,T1e=Object.getOwnPropertyDescriptors,y8=Object.getOwnPropertySymbols,I1e=Object.prototype.hasOwnProperty,x1e=Object.prototype.propertyIsEnumerable,v8=(e,t,n)=>t in e?E1e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,kP=(e,t)=>{for(var n in t||(t={}))I1e.call(t,n)&&v8(e,n,t[n]);if(y8)for(var n of y8(t))x1e.call(t,n)&&v8(e,n,t[n]);return e},_8=(e,t)=>S1e(e,T1e(t));function C1e({variant:e,color:t,theme:n}){if(e==="filled")return{backgroundColor:n.fn.variant({variant:"filled",color:t}).background,color:n.white};if(e==="outline"){const i=n.fn.variant({variant:"outline",color:t});return{color:i.color,borderColor:i.border,backgroundColor:n.colorScheme==="dark"?n.colors.dark[6]:n.white}}const r=n.fn.variant({variant:"light",color:t});return{backgroundColor:r.background,color:r.color}}var A1e=lt((e,{color:t,radius:n,variant:r})=>({root:kP(_8(kP({},e.fn.fontStyles()),{position:"relative",overflow:"hidden",padding:`${e.spacing.sm}px ${e.spacing.md}px`,borderRadius:e.fn.radius(n),border:"1px solid transparent"}),C1e({variant:r,color:t,theme:e})),wrapper:{display:"flex"},body:{flex:1},title:{boxSizing:"border-box",margin:0,marginBottom:7,display:"flex",alignItems:"center",justifyContent:"space-between",lineHeight:e.lineHeight,fontSize:e.fontSizes.sm,fontWeight:700,"&[data-with-close-button]":{paddingRight:e.spacing.md}},label:{display:"block",overflow:"hidden",textOverflow:"ellipsis"},icon:{lineHeight:1,width:20,height:20,display:"flex",alignItems:"center",justifyContent:"flex-start",marginRight:e.spacing.md,marginTop:1},message:_8(kP({},e.fn.fontStyles()),{lineHeight:e.lineHeight,textOverflow:"ellipsis",overflow:"hidden",fontSize:e.fontSizes.sm,color:r==="filled"?e.white:e.colorScheme==="dark"?r==="light"?e.white:e.colors.dark[0]:e.black}),closeButton:{position:"absolute",top:e.spacing.sm,right:e.spacing.sm,color:"inherit"}})),P1e=Object.defineProperty,b8=Object.getOwnPropertySymbols,O1e=Object.prototype.hasOwnProperty,R1e=Object.prototype.propertyIsEnumerable,w8=(e,t,n)=>t in e?P1e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,N1e=(e,t)=>{for(var n in t||(t={}))O1e.call(t,n)&&w8(e,n,t[n]);if(b8)for(var n of b8(t))R1e.call(t,n)&&w8(e,n,t[n]);return e};function vQ(e){return N.createElement("svg",N1e({viewBox:"0 0 15 15",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e),N.createElement("path",{d:"M11.7816 4.03157C12.0062 3.80702 12.0062 3.44295 11.7816 3.2184C11.5571 2.99385 11.193 2.99385 10.9685 3.2184L7.50005 6.68682L4.03164 3.2184C3.80708 2.99385 3.44301 2.99385 3.21846 3.2184C2.99391 3.44295 2.99391 3.80702 3.21846 4.03157L6.68688 7.49999L3.21846 10.9684C2.99391 11.193 2.99391 11.557 3.21846 11.7816C3.44301 12.0061 3.80708 12.0061 4.03164 11.7816L7.50005 8.31316L10.9685 11.7816C11.193 12.0061 11.5571 12.0061 11.7816 11.7816C12.0062 11.557 12.0062 11.193 11.7816 10.9684L8.31322 7.49999L11.7816 4.03157Z",fill:"currentColor",fillRule:"evenodd",clipRule:"evenodd"}))}vQ.displayName="@mantine/core/CloseIcon";var k1e=Object.defineProperty,zE=Object.getOwnPropertySymbols,_Q=Object.prototype.hasOwnProperty,bQ=Object.prototype.propertyIsEnumerable,E8=(e,t,n)=>t in e?k1e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,D1e=(e,t)=>{for(var n in t||(t={}))_Q.call(t,n)&&E8(e,n,t[n]);if(zE)for(var n of zE(t))bQ.call(t,n)&&E8(e,n,t[n]);return e},$1e=(e,t)=>{var n={};for(var r in e)_Q.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&zE)for(var r of zE(e))t.indexOf(r)<0&&bQ.call(e,r)&&(n[r]=e[r]);return n};const L1e={xs:12,sm:14,md:16,lg:20,xl:24},M1e={size:"md"},wQ=w.forwardRef((e,t)=>{const n=Ve("CloseButton",M1e,e),{iconSize:r,size:i="md"}=n,s=$1e(n,["iconSize","size"]),o=ji(),a=r||o.fn.size({size:i,sizes:L1e});return N.createElement(pQ,D1e({size:i,ref:t},s),N.createElement(vQ,{width:a,height:a}))});wQ.displayName="@mantine/core/CloseButton";const Dx=wQ;var F1e=Object.defineProperty,HE=Object.getOwnPropertySymbols,EQ=Object.prototype.hasOwnProperty,SQ=Object.prototype.propertyIsEnumerable,S8=(e,t,n)=>t in e?F1e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,B1e=(e,t)=>{for(var n in t||(t={}))EQ.call(t,n)&&S8(e,n,t[n]);if(HE)for(var n of HE(t))SQ.call(t,n)&&S8(e,n,t[n]);return e},j1e=(e,t)=>{var n={};for(var r in e)EQ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&HE)for(var r of HE(e))t.indexOf(r)<0&&SQ.call(e,r)&&(n[r]=e[r]);return n};const U1e={variant:"light"},TQ=w.forwardRef((e,t)=>{const n=Ve("Alert",U1e,e),{id:r,className:i,title:s,variant:o,children:a,color:u,classNames:l,icon:c,styles:f,onClose:d,radius:h,withCloseButton:p,closeButtonLabel:m,unstyled:y}=n,g=j1e(n,["id","className","title","variant","children","color","classNames","icon","styles","onClose","radius","withCloseButton","closeButtonLabel","unstyled"]),{classes:v,cx:b}=A1e({color:u,radius:h,variant:o},{classNames:l,styles:f,unstyled:y,name:"Alert"}),S=tu(r),T=s&&`${S}-title`,E=`${S}-body`;return N.createElement(it,B1e({id:S,role:"alert","aria-labelledby":T,"aria-describedby":E,className:b(v.root,v[o],i),ref:t},g),N.createElement("div",{className:v.wrapper},c&&N.createElement("div",{className:v.icon},c),N.createElement("div",{className:v.body},s&&N.createElement("div",{className:v.title,"data-with-close-button":p||void 0},N.createElement("span",{id:T,className:v.label},s)),p&&N.createElement(Dx,{className:v.closeButton,onClick:d,variant:"transparent",size:16,iconSize:16,"aria-label":m}),N.createElement("div",{id:E,className:v.message},a))))});TQ.displayName="@mantine/core/Alert";var V1e=Object.defineProperty,z1e=Object.defineProperties,H1e=Object.getOwnPropertyDescriptors,T8=Object.getOwnPropertySymbols,W1e=Object.prototype.hasOwnProperty,q1e=Object.prototype.propertyIsEnumerable,I8=(e,t,n)=>t in e?V1e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,y0=(e,t)=>{for(var n in t||(t={}))W1e.call(t,n)&&I8(e,n,t[n]);if(T8)for(var n of T8(t))q1e.call(t,n)&&I8(e,n,t[n]);return e},G1e=(e,t)=>z1e(e,H1e(t));function Y1e({underline:e,strikethrough:t}){const n=[];return e&&n.push("underline"),t&&n.push("line-through"),n.length>0?n.join(" "):"none"}function K1e({theme:e,color:t,variant:n}){return t==="dimmed"?e.colorScheme==="dark"?e.colors.dark[2]:e.colors.gray[6]:typeof t=="string"&&(t in e.colors||t.split(".")[0]in e.colors)?e.fn.variant({variant:"filled",color:t}).background:n==="link"?e.colors[e.primaryColor][e.colorScheme==="dark"?4:7]:t||"inherit"}function Q1e(e){return typeof e=="number"?{overflow:"hidden",textOverflow:"ellipsis",display:"-webkit-box",WebkitLineClamp:e,WebkitBoxOrient:"vertical"}:null}function X1e({theme:e,truncate:t}){return t==="start"?{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",direction:e.dir==="ltr"?"rtl":"ltr",textAlign:e.dir==="ltr"?"right":"left"}:t?{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"}:null}var J1e=lt((e,{color:t,variant:n,size:r,lineClamp:i,truncate:s,inline:o,inherit:a,underline:u,gradient:l,weight:c,transform:f,align:d,strikethrough:h,italic:p})=>{const m=e.fn.variant({variant:"gradient",gradient:l});return{root:y0(G1e(y0(y0(y0(y0({},e.fn.fontStyles()),e.fn.focusStyles()),Q1e(i)),X1e({theme:e,truncate:s})),{color:K1e({color:t,theme:e,variant:n}),fontFamily:a?"inherit":e.fontFamily,fontSize:a||r===void 0?"inherit":e.fn.size({size:r,sizes:e.fontSizes}),lineHeight:a?"inherit":o?1:e.lineHeight,textDecoration:Y1e({underline:u,strikethrough:h}),WebkitTapHighlightColor:"transparent",fontWeight:a?"inherit":c,textTransform:f,textAlign:d,fontStyle:p?"italic":void 0}),e.fn.hover(n==="link"&&u===void 0?{textDecoration:"underline"}:void 0)),gradient:{backgroundImage:m.background,WebkitBackgroundClip:"text",WebkitTextFillColor:"transparent"}}}),Z1e=Object.defineProperty,WE=Object.getOwnPropertySymbols,IQ=Object.prototype.hasOwnProperty,xQ=Object.prototype.propertyIsEnumerable,x8=(e,t,n)=>t in e?Z1e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ebe=(e,t)=>{for(var n in t||(t={}))IQ.call(t,n)&&x8(e,n,t[n]);if(WE)for(var n of WE(t))xQ.call(t,n)&&x8(e,n,t[n]);return e},tbe=(e,t)=>{var n={};for(var r in e)IQ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&WE)for(var r of WE(e))t.indexOf(r)<0&&xQ.call(e,r)&&(n[r]=e[r]);return n};const nbe={variant:"text"},CQ=w.forwardRef((e,t)=>{const n=Ve("Text",nbe,e),{className:r,size:i,weight:s,transform:o,color:a,align:u,variant:l,lineClamp:c,truncate:f,gradient:d,inline:h,inherit:p,underline:m,strikethrough:y,italic:g,classNames:v,styles:b,unstyled:S,span:T}=n,E=tbe(n,["className","size","weight","transform","color","align","variant","lineClamp","truncate","gradient","inline","inherit","underline","strikethrough","italic","classNames","styles","unstyled","span"]),{classes:I,cx:A}=J1e({variant:l,color:a,size:i,lineClamp:c,truncate:f,inline:h,inherit:p,underline:m,strikethrough:y,italic:g,weight:s,transform:o,align:u,gradient:d},{unstyled:S,name:"Text"});return N.createElement(it,ebe({ref:t,className:A(I.root,{[I.gradient]:l==="gradient"},r),component:T?"span":"div"},E))});CQ.displayName="@mantine/core/Text";const rt=CQ;var rbe=lt(()=>({root:{backgroundColor:"transparent",cursor:"pointer",padding:0,border:0}})),ibe=Object.defineProperty,qE=Object.getOwnPropertySymbols,AQ=Object.prototype.hasOwnProperty,PQ=Object.prototype.propertyIsEnumerable,C8=(e,t,n)=>t in e?ibe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,A8=(e,t)=>{for(var n in t||(t={}))AQ.call(t,n)&&C8(e,n,t[n]);if(qE)for(var n of qE(t))PQ.call(t,n)&&C8(e,n,t[n]);return e},sbe=(e,t)=>{var n={};for(var r in e)AQ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&qE)for(var r of qE(e))t.indexOf(r)<0&&PQ.call(e,r)&&(n[r]=e[r]);return n};const obe={},OQ=w.forwardRef((e,t)=>{const n=Ve("Anchor",obe,e),{component:r,className:i,unstyled:s}=n,o=sbe(n,["component","className","unstyled"]),{classes:a,cx:u}=rbe(null,{name:"Anchor",unstyled:s}),l=r==="button"?{type:"button"}:null;return N.createElement(rt,A8(A8({component:r||"a",variant:"link",ref:t,className:u(a.root,i)},l),o))});OQ.displayName="@mantine/core/Anchor";const RQ=OQ,NQ=w.createContext({zIndex:1e3,fixed:!1,layout:"default"}),abe=NQ.Provider;function kQ(){return w.useContext(NQ)}function $x(e,t){if(!e)return[];const n=Object.keys(e).filter(r=>r!=="base").map(r=>[t.fn.size({size:r,sizes:t.breakpoints}),e[r]]);return n.sort((r,i)=>r[0]-i[0]),n}var ube=Object.defineProperty,lbe=Object.defineProperties,cbe=Object.getOwnPropertyDescriptors,P8=Object.getOwnPropertySymbols,fbe=Object.prototype.hasOwnProperty,dbe=Object.prototype.propertyIsEnumerable,O8=(e,t,n)=>t in e?ube(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,sb=(e,t)=>{for(var n in t||(t={}))fbe.call(t,n)&&O8(e,n,t[n]);if(P8)for(var n of P8(t))dbe.call(t,n)&&O8(e,n,t[n]);return e},R8=(e,t)=>lbe(e,cbe(t)),hbe=lt((e,{height:t,width:n,fixed:r,position:i,hiddenBreakpoint:s,zIndex:o,section:a,withBorder:u,layout:l})=>{const c=typeof n=="object"&&n!==null?$x(n,e).reduce((d,[h,p])=>(d[`@media (min-width: ${h}px)`]={width:p,minWidth:p},d),{}):null,f=u?{[a==="navbar"?"borderRight":"borderLeft"]:`1px solid ${e.colorScheme==="dark"?e.colors.dark[5]:e.colors.gray[2]}`}:{};return{root:R8(sb(sb(R8(sb(sb({},e.fn.fontStyles()),i),{top:l==="alt"?0:(i==null?void 0:i.top)||"var(--mantine-header-height)",bottom:0,zIndex:o,height:t||(l==="alt"?"auto":"calc(100vh - var(--mantine-header-height, 0px) - var(--mantine-footer-height, 0px))"),width:(n==null?void 0:n.base)||"100%",position:r?"fixed":"static",boxSizing:"border-box",display:"flex",flexDirection:"column",backgroundColor:e.colorScheme==="dark"?e.colors.dark[7]:e.white}),f),c),{"&[data-hidden]":{[`@media (max-width: ${e.fn.size({size:s,sizes:e.breakpoints})-1}px)`]:{display:"none"}}})}});const pbe=hbe;var mbe=Object.defineProperty,GE=Object.getOwnPropertySymbols,DQ=Object.prototype.hasOwnProperty,$Q=Object.prototype.propertyIsEnumerable,N8=(e,t,n)=>t in e?mbe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,k8=(e,t)=>{for(var n in t||(t={}))DQ.call(t,n)&&N8(e,n,t[n]);if(GE)for(var n of GE(t))$Q.call(t,n)&&N8(e,n,t[n]);return e},gbe=(e,t)=>{var n={};for(var r in e)DQ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&GE)for(var r of GE(e))t.indexOf(r)<0&&$Q.call(e,r)&&(n[r]=e[r]);return n};const C$=w.forwardRef((e,t)=>{var n=e,{width:r,height:i,fixed:s=!1,position:o,zIndex:a,hiddenBreakpoint:u="md",hidden:l=!1,withBorder:c=!0,className:f,classNames:d,styles:h,children:p,section:m,__staticSelector:y,unstyled:g}=n,v=gbe(n,["width","height","fixed","position","zIndex","hiddenBreakpoint","hidden","withBorder","className","classNames","styles","children","section","__staticSelector","unstyled"]);const b=kQ(),{classes:S,cx:T,theme:E}=pbe({width:r,height:i,fixed:b.fixed||s,position:o,hiddenBreakpoint:u,zIndex:a||b.zIndex||cc("app"),section:m,withBorder:c,layout:b.layout},{classNames:d,styles:h,name:y,unstyled:g}),I=$x(r,E).reduce((A,[R,F])=>(A[`@media (min-width: ${R}px)`]={[`--mantine-${m}-width`]:`${F}px`},A),{});return N.createElement(it,k8({component:m==="navbar"?"nav":"aside",ref:t,"data-hidden":l||void 0,className:T(S.root,f)},v),p,N.createElement($K,{styles:()=>({":root":k8({[`--mantine-${m}-width`]:r!=null&&r.base?`${r.base}px`:"0px"},I)})}))});C$.displayName="@mantine/core/HorizontalSection";var ybe=Object.defineProperty,YE=Object.getOwnPropertySymbols,LQ=Object.prototype.hasOwnProperty,MQ=Object.prototype.propertyIsEnumerable,D8=(e,t,n)=>t in e?ybe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,vbe=(e,t)=>{for(var n in t||(t={}))LQ.call(t,n)&&D8(e,n,t[n]);if(YE)for(var n of YE(t))MQ.call(t,n)&&D8(e,n,t[n]);return e},_be=(e,t)=>{var n={};for(var r in e)LQ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&YE)for(var r of YE(e))t.indexOf(r)<0&&MQ.call(e,r)&&(n[r]=e[r]);return n};const FQ=w.forwardRef((e,t)=>{var n=e,{children:r,grow:i=!1,sx:s}=n,o=_be(n,["children","grow","sx"]);return N.createElement(it,vbe({ref:t,sx:[{flex:i?1:0,boxSizing:"border-box"},...lh(s)]},o),r)});FQ.displayName="@mantine/core/Section";const BQ=FQ;var bbe=Object.defineProperty,$8=Object.getOwnPropertySymbols,wbe=Object.prototype.hasOwnProperty,Ebe=Object.prototype.propertyIsEnumerable,L8=(e,t,n)=>t in e?bbe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Sbe=(e,t)=>{for(var n in t||(t={}))wbe.call(t,n)&&L8(e,n,t[n]);if($8)for(var n of $8(t))Ebe.call(t,n)&&L8(e,n,t[n]);return e};const Tbe={fixed:!1,position:{top:0,left:0},hiddenBreakpoint:"md",hidden:!1},_y=w.forwardRef((e,t)=>{const n=Ve("Navbar",Tbe,e);return N.createElement(C$,Sbe({section:"navbar",__staticSelector:"Navbar",ref:t},n))});_y.Section=BQ;_y.displayName="@mantine/core/Navbar";var Ibe=Object.defineProperty,xbe=Object.defineProperties,Cbe=Object.getOwnPropertyDescriptors,M8=Object.getOwnPropertySymbols,Abe=Object.prototype.hasOwnProperty,Pbe=Object.prototype.propertyIsEnumerable,F8=(e,t,n)=>t in e?Ibe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,DP=(e,t)=>{for(var n in t||(t={}))Abe.call(t,n)&&F8(e,n,t[n]);if(M8)for(var n of M8(t))Pbe.call(t,n)&&F8(e,n,t[n]);return e},B8=(e,t)=>xbe(e,Cbe(t)),Obe=lt((e,{height:t,fixed:n,position:r,zIndex:i,borderPosition:s,layout:o})=>{const a=typeof t=="object"&&t!==null?$x(t,e).reduce((u,[l,c])=>(u[`@media (min-width: ${l}px)`]={height:c,minHeight:c},u),{}):null;return{root:B8(DP(B8(DP(DP({},e.fn.fontStyles()),r),{zIndex:i,left:o==="alt"?"var(--mantine-navbar-width, 0)":0,right:o==="alt"?"var(--mantine-aside-width, 0)":0,height:typeof t=="object"?(t==null?void 0:t.base)||"100%":t,maxHeight:typeof t=="object"?(t==null?void 0:t.base)||"100%":t,position:n?"fixed":"static",boxSizing:"border-box",backgroundColor:e.colorScheme==="dark"?e.colors.dark[7]:e.white}),a),{borderBottom:s==="bottom"?`1px solid ${e.colorScheme==="dark"?e.colors.dark[5]:e.colors.gray[2]}`:void 0,borderTop:s==="top"?`1px solid ${e.colorScheme==="dark"?e.colors.dark[5]:e.colors.gray[2]}`:void 0})}});const Rbe=Obe;var Nbe=Object.defineProperty,KE=Object.getOwnPropertySymbols,jQ=Object.prototype.hasOwnProperty,UQ=Object.prototype.propertyIsEnumerable,j8=(e,t,n)=>t in e?Nbe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,U8=(e,t)=>{for(var n in t||(t={}))jQ.call(t,n)&&j8(e,n,t[n]);if(KE)for(var n of KE(t))UQ.call(t,n)&&j8(e,n,t[n]);return e},kbe=(e,t)=>{var n={};for(var r in e)jQ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&KE)for(var r of KE(e))t.indexOf(r)<0&&UQ.call(e,r)&&(n[r]=e[r]);return n};const VQ=w.forwardRef((e,t)=>{var n=e,{children:r,className:i,classNames:s,styles:o,height:a,fixed:u=!1,withBorder:l=!0,position:c,zIndex:f,section:d,unstyled:h,__staticSelector:p}=n,m=kbe(n,["children","className","classNames","styles","height","fixed","withBorder","position","zIndex","section","unstyled","__staticSelector"]);const y=kQ(),g=f||y.zIndex||cc("app"),{classes:v,cx:b,theme:S}=Rbe({height:a,fixed:y.fixed||u,position:c,zIndex:typeof g=="number"&&y.layout==="default"?g+1:g,layout:y.layout,borderPosition:l?d==="header"?"bottom":"top":"none"},{name:p,classNames:s,styles:o,unstyled:h}),T=typeof a=="object"&&a!==null?$x(a,S).reduce((E,[I,A])=>(E[`@media (min-width: ${I}px)`]={[`--mantine-${d}-height`]:`${A}px`},E),{}):null;return N.createElement(it,U8({component:d==="header"?"header":"footer",className:b(v.root,i),ref:t},m),r,N.createElement($K,{styles:()=>({":root":U8({[`--mantine-${d}-height`]:typeof a=="object"?`${a==null?void 0:a.base}px`||"100%":`${a}px`},T)})}))});VQ.displayName="@mantine/core/VerticalSection";var Dbe=Object.defineProperty,$be=Object.defineProperties,Lbe=Object.getOwnPropertyDescriptors,V8=Object.getOwnPropertySymbols,Mbe=Object.prototype.hasOwnProperty,Fbe=Object.prototype.propertyIsEnumerable,z8=(e,t,n)=>t in e?Dbe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Bbe=(e,t)=>{for(var n in t||(t={}))Mbe.call(t,n)&&z8(e,n,t[n]);if(V8)for(var n of V8(t))Fbe.call(t,n)&&z8(e,n,t[n]);return e},jbe=(e,t)=>$be(e,Lbe(t));const Ube={fixed:!1,position:{top:0,left:0,right:0}},zQ=w.forwardRef((e,t)=>{const n=Ve("Header",Ube,e);return N.createElement(VQ,jbe(Bbe({section:"header",__staticSelector:"Header"},n),{ref:t}))});zQ.displayName="@mantine/core/Header";var Vbe=Object.defineProperty,H8=Object.getOwnPropertySymbols,zbe=Object.prototype.hasOwnProperty,Hbe=Object.prototype.propertyIsEnumerable,W8=(e,t,n)=>t in e?Vbe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Wbe=(e,t)=>{for(var n in t||(t={}))zbe.call(t,n)&&W8(e,n,t[n]);if(H8)for(var n of H8(t))Hbe.call(t,n)&&W8(e,n,t[n]);return e};const qbe={fixed:!1,position:{top:0,right:0},hiddenBreakpoint:"md",hidden:!1},A$=w.forwardRef((e,t)=>{const n=Ve("Aside",qbe,e);return N.createElement(C$,Wbe({section:"aside",__staticSelector:"Aside",ref:t},n))});A$.Section=BQ;A$.displayName="@mantine/core/Aside";var Gbe=Object.defineProperty,q8=Object.getOwnPropertySymbols,Ybe=Object.prototype.hasOwnProperty,Kbe=Object.prototype.propertyIsEnumerable,G8=(e,t,n)=>t in e?Gbe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Qbe=(e,t)=>{for(var n in t||(t={}))Ybe.call(t,n)&&G8(e,n,t[n]);if(q8)for(var n of q8(t))Kbe.call(t,n)&&G8(e,n,t[n]);return e};function Xbe(e,t){const n=t.fn.size({size:e.padding,sizes:t.spacing}),r=e.navbarOffsetBreakpoint?t.fn.size({size:e.navbarOffsetBreakpoint,sizes:t.breakpoints}):null,i=e.asideOffsetBreakpoint?t.fn.size({size:e.asideOffsetBreakpoint,sizes:t.breakpoints}):null;return e.fixed?{minHeight:"100vh",paddingTop:`calc(var(--mantine-header-height, 0px) + ${n}px)`,paddingBottom:`calc(var(--mantine-footer-height, 0px) + ${n}px)`,paddingLeft:`calc(var(--mantine-navbar-width, 0px) + ${n}px)`,paddingRight:`calc(var(--mantine-aside-width, 0px) + ${n}px)`,[`@media (max-width: ${r-1}px)`]:{paddingLeft:n},[`@media (max-width: ${i-1}px)`]:{paddingRight:n}}:{padding:n}}var Jbe=lt((e,t)=>({root:{boxSizing:"border-box"},body:{display:"flex",boxSizing:"border-box"},main:Qbe({flex:1,width:"100vw",boxSizing:"border-box"},Xbe(t,e))})),Zbe=Object.defineProperty,QE=Object.getOwnPropertySymbols,HQ=Object.prototype.hasOwnProperty,WQ=Object.prototype.propertyIsEnumerable,Y8=(e,t,n)=>t in e?Zbe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ewe=(e,t)=>{for(var n in t||(t={}))HQ.call(t,n)&&Y8(e,n,t[n]);if(QE)for(var n of QE(t))WQ.call(t,n)&&Y8(e,n,t[n]);return e},twe=(e,t)=>{var n={};for(var r in e)HQ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&QE)for(var r of QE(e))t.indexOf(r)<0&&WQ.call(e,r)&&(n[r]=e[r]);return n};const nwe={fixed:!0,padding:"md"},qQ=w.forwardRef((e,t)=>{const n=Ve("AppShell",nwe,e),{children:r,navbar:i,header:s,footer:o,aside:a,fixed:u,zIndex:l,padding:c,navbarOffsetBreakpoint:f,asideOffsetBreakpoint:d,className:h,styles:p,classNames:m,unstyled:y,hidden:g,layout:v}=n,b=twe(n,["children","navbar","header","footer","aside","fixed","zIndex","padding","navbarOffsetBreakpoint","asideOffsetBreakpoint","className","styles","classNames","unstyled","hidden","layout"]),{classes:S,cx:T}=Jbe({padding:c,fixed:u,navbarOffsetBreakpoint:f,asideOffsetBreakpoint:d},{styles:p,classNames:m,unstyled:y,name:"AppShell"});return g?N.createElement(N.Fragment,null,r):N.createElement(abe,{value:{fixed:u,zIndex:l,layout:v}},N.createElement(it,ewe({className:T(S.root,h),ref:t},b),s,N.createElement("div",{className:S.body},i,N.createElement("main",{className:S.main},r),a),o))});qQ.displayName="@mantine/core/AppShell";const ob={xs:1,sm:2,md:3,lg:4,xl:5};function ab(e,t){const n=e.fn.variant({variant:"outline",color:t}).border;return typeof t=="string"&&(t in e.colors||t.split(".")[0]in e.colors)?n:t===void 0?e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[4]:t}var rwe=lt((e,{size:t,variant:n,color:r})=>({root:{},withLabel:{borderTop:"0 !important"},left:{"&::before":{display:"none"}},right:{"&::after":{display:"none"}},label:{display:"flex",alignItems:"center","&::before":{content:'""',flex:1,height:1,borderTop:`${e.fn.size({size:t,sizes:ob})}px ${n} ${ab(e,r)}`,marginRight:e.spacing.xs},"&::after":{content:'""',flex:1,borderTop:`${e.fn.size({size:t,sizes:ob})}px ${n} ${ab(e,r)}`,marginLeft:e.spacing.xs}},labelDefaultStyles:{color:r==="dark"?e.colors.dark[1]:e.fn.themeColor(r,e.colorScheme==="dark"?5:e.fn.primaryShade(),!1)},horizontal:{border:0,borderTopWidth:e.fn.size({size:t,sizes:ob}),borderTopColor:ab(e,r),borderTopStyle:n,margin:0},vertical:{border:0,alignSelf:"stretch",height:"auto",borderLeftWidth:e.fn.size({size:t,sizes:ob}),borderLeftColor:ab(e,r),borderLeftStyle:n}})),iwe=Object.defineProperty,swe=Object.defineProperties,owe=Object.getOwnPropertyDescriptors,XE=Object.getOwnPropertySymbols,GQ=Object.prototype.hasOwnProperty,YQ=Object.prototype.propertyIsEnumerable,K8=(e,t,n)=>t in e?iwe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Q8=(e,t)=>{for(var n in t||(t={}))GQ.call(t,n)&&K8(e,n,t[n]);if(XE)for(var n of XE(t))YQ.call(t,n)&&K8(e,n,t[n]);return e},awe=(e,t)=>swe(e,owe(t)),uwe=(e,t)=>{var n={};for(var r in e)GQ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&XE)for(var r of XE(e))t.indexOf(r)<0&&YQ.call(e,r)&&(n[r]=e[r]);return n};const lwe={orientation:"horizontal",size:"xs",labelPosition:"left",variant:"solid"},df=w.forwardRef((e,t)=>{const n=Ve("Divider",lwe,e),{className:r,color:i,orientation:s,size:o,label:a,labelPosition:u,labelProps:l,variant:c,styles:f,classNames:d,unstyled:h}=n,p=uwe(n,["className","color","orientation","size","label","labelPosition","labelProps","variant","styles","classNames","unstyled"]),{classes:m,cx:y}=rwe({color:i,size:o,variant:c},{classNames:d,styles:f,unstyled:h,name:"Divider"}),g=s==="vertical",v=s==="horizontal",b=!!a&&v,S=!(l!=null&&l.color);return N.createElement(it,Q8({ref:t,className:y(m.root,{[m.vertical]:g,[m.horizontal]:v,[m.withLabel]:b},r),role:"separator"},p),b&&N.createElement(rt,awe(Q8({},l),{size:(l==null?void 0:l.size)||"xs",sx:{marginTop:2},className:y(m.label,m[u],{[m.labelDefaultStyles]:S})}),a))});df.displayName="@mantine/core/Divider";var cwe=Object.defineProperty,fwe=Object.defineProperties,dwe=Object.getOwnPropertyDescriptors,X8=Object.getOwnPropertySymbols,hwe=Object.prototype.hasOwnProperty,pwe=Object.prototype.propertyIsEnumerable,J8=(e,t,n)=>t in e?cwe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Z8=(e,t)=>{for(var n in t||(t={}))hwe.call(t,n)&&J8(e,n,t[n]);if(X8)for(var n of X8(t))pwe.call(t,n)&&J8(e,n,t[n]);return e},mwe=(e,t)=>fwe(e,dwe(t)),gwe=lt((e,{size:t})=>({item:mwe(Z8({},e.fn.fontStyles()),{boxSizing:"border-box",textAlign:"left",width:"100%",padding:`${e.fn.size({size:t,sizes:e.spacing})/1.5}px ${e.fn.size({size:t,sizes:e.spacing})}px`,cursor:"pointer",fontSize:e.fn.size({size:t,sizes:e.fontSizes}),color:e.colorScheme==="dark"?e.colors.dark[0]:e.black,borderRadius:e.fn.radius(),"&[data-hovered]":{backgroundColor:e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[1]},"&[data-selected]":Z8({backgroundColor:e.fn.variant({variant:"filled"}).background,color:e.fn.variant({variant:"filled"}).color},e.fn.hover({backgroundColor:e.fn.variant({variant:"filled"}).hover})),"&[data-disabled]":{cursor:"default",color:e.colors.dark[2]}}),nothingFound:{boxSizing:"border-box",color:e.colors.gray[6],paddingTop:e.fn.size({size:t,sizes:e.spacing})/2,paddingBottom:e.fn.size({size:t,sizes:e.spacing})/2,textAlign:"center"},separator:{boxSizing:"border-box",textAlign:"left",width:"100%",padding:`${e.fn.size({size:t,sizes:e.spacing})/1.5}px ${e.fn.size({size:t,sizes:e.spacing})}px`},separatorLabel:{color:e.colorScheme==="dark"?e.colors.dark[3]:e.colors.gray[5]}})),ywe=Object.defineProperty,e9=Object.getOwnPropertySymbols,vwe=Object.prototype.hasOwnProperty,_we=Object.prototype.propertyIsEnumerable,t9=(e,t,n)=>t in e?ywe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,bwe=(e,t)=>{for(var n in t||(t={}))vwe.call(t,n)&&t9(e,n,t[n]);if(e9)for(var n of e9(t))_we.call(t,n)&&t9(e,n,t[n]);return e};function P$({data:e,hovered:t,classNames:n,styles:r,isItemSelected:i,uuid:s,__staticSelector:o,onItemHover:a,onItemSelect:u,itemsRefs:l,itemComponent:c,size:f,nothingFound:d,creatable:h,createLabel:p,unstyled:m}){const{classes:y}=gwe({size:f},{classNames:n,styles:r,unstyled:m,name:o}),g=[],v=[];let b=null;const S=(E,I)=>{const A=typeof i=="function"?i(E.value):!1;return N.createElement(c,bwe({key:E.value,className:y.item,"data-disabled":E.disabled||void 0,"data-hovered":!E.disabled&&t===I||void 0,"data-selected":!E.disabled&&A||void 0,selected:A,onMouseEnter:()=>a(I),id:`${s}-${I}`,role:"option",tabIndex:-1,"aria-selected":t===I,ref:R=>{l&&l.current&&(l.current[E.value]=R)},onMouseDown:E.disabled?null:R=>{R.preventDefault(),u(E)},disabled:E.disabled},E))};let T=null;if(e.forEach((E,I)=>{E.creatable?b=I:E.group?(T!==E.group&&(T=E.group,v.push(N.createElement("div",{className:y.separator,key:`__mantine-divider-${I}`},N.createElement(df,{classNames:{label:y.separatorLabel},label:E.group})))),v.push(S(E,I))):g.push(S(E,I))}),h){const E=e[b];g.push(N.createElement("div",{key:t_e(),className:y.item,"data-hovered":t===b||void 0,onMouseEnter:()=>a(b),onMouseDown:I=>{I.preventDefault(),u(E)},tabIndex:-1,ref:I=>{l&&l.current&&(l.current[E.value]=I)}},p))}return v.length>0&&g.length>0&&g.unshift(N.createElement("div",{className:y.separator,key:"empty-group-separator"},N.createElement(df,null))),v.length>0||g.length>0?N.createElement(N.Fragment,null,v,g):N.createElement(rt,{size:f,unstyled:m,className:y.nothingFound},d)}P$.displayName="@mantine/core/SelectItems";var wwe=Object.defineProperty,JE=Object.getOwnPropertySymbols,KQ=Object.prototype.hasOwnProperty,QQ=Object.prototype.propertyIsEnumerable,n9=(e,t,n)=>t in e?wwe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Ewe=(e,t)=>{for(var n in t||(t={}))KQ.call(t,n)&&n9(e,n,t[n]);if(JE)for(var n of JE(t))QQ.call(t,n)&&n9(e,n,t[n]);return e},Swe=(e,t)=>{var n={};for(var r in e)KQ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&JE)for(var r of JE(e))t.indexOf(r)<0&&QQ.call(e,r)&&(n[r]=e[r]);return n};const O$=w.forwardRef((e,t)=>{var n=e,{label:r,value:i}=n,s=Swe(n,["label","value"]);return N.createElement("div",Ewe({ref:t},s),r||i)});O$.displayName="@mantine/core/DefaultItem";function Twe(e,t){typeof e=="function"?e(t):e!=null&&(e.current=t)}function XQ(...e){return t=>e.forEach(n=>Twe(n,t))}function kh(...e){return w.useCallback(XQ(...e),e)}const JQ=w.forwardRef((e,t)=>{const{children:n,...r}=e,i=w.Children.toArray(n),s=i.find(xwe);if(s){const o=s.props.children,a=i.map(u=>u===s?w.Children.count(o)>1?w.Children.only(null):w.isValidElement(o)?o.props.children:null:u);return w.createElement(zR,pr({},r,{ref:t}),w.isValidElement(o)?w.cloneElement(o,void 0,a):null)}return w.createElement(zR,pr({},r,{ref:t}),n)});JQ.displayName="Slot";const zR=w.forwardRef((e,t)=>{const{children:n,...r}=e;return w.isValidElement(n)?w.cloneElement(n,{...Cwe(r,n.props),ref:XQ(t,n.ref)}):w.Children.count(n)>1?w.Children.only(null):null});zR.displayName="SlotClone";const Iwe=({children:e})=>w.createElement(w.Fragment,null,e);function xwe(e){return w.isValidElement(e)&&e.type===Iwe}function Cwe(e,t){const n={...t};for(const r in t){const i=e[r],s=t[r];/^on[A-Z]/.test(r)?i&&s?n[r]=(...a)=>{s(...a),i(...a)}:i&&(n[r]=i):r==="style"?n[r]={...i,...s}:r==="className"&&(n[r]=[i,s].filter(Boolean).join(" "))}return{...e,...n}}const Awe=["a","button","div","h2","h3","img","label","li","nav","ol","p","span","svg","ul"],L_=Awe.reduce((e,t)=>{const n=w.forwardRef((r,i)=>{const{asChild:s,...o}=r,a=s?JQ:t;return w.useEffect(()=>{window[Symbol.for("radix-ui")]=!0},[]),w.createElement(a,pr({},o,{ref:i}))});return n.displayName=`Primitive.${t}`,{...e,[t]:n}},{}),HR=globalThis!=null&&globalThis.document?w.useLayoutEffect:()=>{};function Pwe(e,t){return w.useReducer((n,r)=>{const i=t[n][r];return i??n},e)}const M_=e=>{const{present:t,children:n}=e,r=Owe(t),i=typeof n=="function"?n({present:r.isPresent}):w.Children.only(n),s=kh(r.ref,i.ref);return typeof n=="function"||r.isPresent?w.cloneElement(i,{ref:s}):null};M_.displayName="Presence";function Owe(e){const[t,n]=w.useState(),r=w.useRef({}),i=w.useRef(e),s=w.useRef("none"),o=e?"mounted":"unmounted",[a,u]=Pwe(o,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return w.useEffect(()=>{const l=ub(r.current);s.current=a==="mounted"?l:"none"},[a]),HR(()=>{const l=r.current,c=i.current;if(c!==e){const d=s.current,h=ub(l);e?u("MOUNT"):h==="none"||(l==null?void 0:l.display)==="none"?u("UNMOUNT"):u(c&&d!==h?"ANIMATION_OUT":"UNMOUNT"),i.current=e}},[e,u]),HR(()=>{if(t){const l=f=>{const h=ub(r.current).includes(f.animationName);f.target===t&&h&&lc.flushSync(()=>u("ANIMATION_END"))},c=f=>{f.target===t&&(s.current=ub(r.current))};return t.addEventListener("animationstart",c),t.addEventListener("animationcancel",l),t.addEventListener("animationend",l),()=>{t.removeEventListener("animationstart",c),t.removeEventListener("animationcancel",l),t.removeEventListener("animationend",l)}}else u("ANIMATION_END")},[t,u]),{isPresent:["mounted","unmountSuspended"].includes(a),ref:w.useCallback(l=>{l&&(r.current=getComputedStyle(l)),n(l)},[])}}function ub(e){return(e==null?void 0:e.animationName)||"none"}function Rwe(e,t=[]){let n=[];function r(s,o){const a=w.createContext(o),u=n.length;n=[...n,o];function l(f){const{scope:d,children:h,...p}=f,m=(d==null?void 0:d[e][u])||a,y=w.useMemo(()=>p,Object.values(p));return w.createElement(m.Provider,{value:y},h)}function c(f,d){const h=(d==null?void 0:d[e][u])||a,p=w.useContext(h);if(p)return p;if(o!==void 0)return o;throw new Error(`\`${f}\` must be used within \`${s}\``)}return l.displayName=s+"Provider",[l,c]}const i=()=>{const s=n.map(o=>w.createContext(o));return function(a){const u=(a==null?void 0:a[e])||s;return w.useMemo(()=>({[`__scope${e}`]:{...a,[e]:u}}),[a,u])}};return i.scopeName=e,[r,Nwe(i,...t)]}function Nwe(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(i=>({useScope:i(),scopeName:i.scopeName}));return function(s){const o=r.reduce((a,{useScope:u,scopeName:l})=>{const f=u(s)[`__scope${l}`];return{...a,...f}},{});return w.useMemo(()=>({[`__scope${t.scopeName}`]:o}),[o])}};return n.scopeName=t.scopeName,n}function wd(e){const t=w.useRef(e);return w.useEffect(()=>{t.current=e}),w.useMemo(()=>(...n)=>{var r;return(r=t.current)===null||r===void 0?void 0:r.call(t,...n)},[])}const kwe=w.createContext(void 0);function Dwe(e){const t=w.useContext(kwe);return e||t||"ltr"}function $we(e,[t,n]){return Math.min(n,Math.max(t,e))}function Xd(e,t,{checkForDefaultPrevented:n=!0}={}){return function(i){if(e==null||e(i),n===!1||!i.defaultPrevented)return t==null?void 0:t(i)}}function Lwe(e,t){return w.useReducer((n,r)=>{const i=t[n][r];return i??n},e)}const ZQ="ScrollArea",[eX,idt]=Rwe(ZQ),[Mwe,da]=eX(ZQ),Fwe=w.forwardRef((e,t)=>{const{__scopeScrollArea:n,type:r="hover",dir:i,scrollHideDelay:s=600,...o}=e,[a,u]=w.useState(null),[l,c]=w.useState(null),[f,d]=w.useState(null),[h,p]=w.useState(null),[m,y]=w.useState(null),[g,v]=w.useState(0),[b,S]=w.useState(0),[T,E]=w.useState(!1),[I,A]=w.useState(!1),R=kh(t,L=>u(L)),F=Dwe(i);return w.createElement(Mwe,{scope:n,type:r,dir:F,scrollHideDelay:s,scrollArea:a,viewport:l,onViewportChange:c,content:f,onContentChange:d,scrollbarX:h,onScrollbarXChange:p,scrollbarXEnabled:T,onScrollbarXEnabledChange:E,scrollbarY:m,onScrollbarYChange:y,scrollbarYEnabled:I,onScrollbarYEnabledChange:A,onCornerWidthChange:v,onCornerHeightChange:S},w.createElement(L_.div,pr({dir:F},o,{ref:R,style:{position:"relative","--radix-scroll-area-corner-width":g+"px","--radix-scroll-area-corner-height":b+"px",...e.style}})))}),Bwe="ScrollAreaViewport",jwe=w.forwardRef((e,t)=>{const{__scopeScrollArea:n,children:r,...i}=e,s=da(Bwe,n),o=w.useRef(null),a=kh(t,o,s.onViewportChange);return w.createElement(w.Fragment,null,w.createElement("style",{dangerouslySetInnerHTML:{__html:"[data-radix-scroll-area-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-scroll-area-viewport]::-webkit-scrollbar{display:none}"}}),w.createElement(L_.div,pr({"data-radix-scroll-area-viewport":""},i,{ref:a,style:{overflowX:s.scrollbarXEnabled?"scroll":"hidden",overflowY:s.scrollbarYEnabled?"scroll":"hidden",...e.style}}),w.createElement("div",{ref:s.onContentChange,style:{minWidth:"100%",display:"table"}},r)))}),fc="ScrollAreaScrollbar",Uwe=w.forwardRef((e,t)=>{const{forceMount:n,...r}=e,i=da(fc,e.__scopeScrollArea),{onScrollbarXEnabledChange:s,onScrollbarYEnabledChange:o}=i,a=e.orientation==="horizontal";return w.useEffect(()=>(a?s(!0):o(!0),()=>{a?s(!1):o(!1)}),[a,s,o]),i.type==="hover"?w.createElement(Vwe,pr({},r,{ref:t,forceMount:n})):i.type==="scroll"?w.createElement(zwe,pr({},r,{ref:t,forceMount:n})):i.type==="auto"?w.createElement(tX,pr({},r,{ref:t,forceMount:n})):i.type==="always"?w.createElement(R$,pr({},r,{ref:t})):null}),Vwe=w.forwardRef((e,t)=>{const{forceMount:n,...r}=e,i=da(fc,e.__scopeScrollArea),[s,o]=w.useState(!1);return w.useEffect(()=>{const a=i.scrollArea;let u=0;if(a){const l=()=>{window.clearTimeout(u),o(!0)},c=()=>{u=window.setTimeout(()=>o(!1),i.scrollHideDelay)};return a.addEventListener("pointerenter",l),a.addEventListener("pointerleave",c),()=>{window.clearTimeout(u),a.removeEventListener("pointerenter",l),a.removeEventListener("pointerleave",c)}}},[i.scrollArea,i.scrollHideDelay]),w.createElement(M_,{present:n||s},w.createElement(tX,pr({"data-state":s?"visible":"hidden"},r,{ref:t})))}),zwe=w.forwardRef((e,t)=>{const{forceMount:n,...r}=e,i=da(fc,e.__scopeScrollArea),s=e.orientation==="horizontal",o=Mx(()=>u("SCROLL_END"),100),[a,u]=Lwe("hidden",{hidden:{SCROLL:"scrolling"},scrolling:{SCROLL_END:"idle",POINTER_ENTER:"interacting"},interacting:{SCROLL:"interacting",POINTER_LEAVE:"idle"},idle:{HIDE:"hidden",SCROLL:"scrolling",POINTER_ENTER:"interacting"}});return w.useEffect(()=>{if(a==="idle"){const l=window.setTimeout(()=>u("HIDE"),i.scrollHideDelay);return()=>window.clearTimeout(l)}},[a,i.scrollHideDelay,u]),w.useEffect(()=>{const l=i.viewport,c=s?"scrollLeft":"scrollTop";if(l){let f=l[c];const d=()=>{const h=l[c];f!==h&&(u("SCROLL"),o()),f=h};return l.addEventListener("scroll",d),()=>l.removeEventListener("scroll",d)}},[i.viewport,s,u,o]),w.createElement(M_,{present:n||a!=="hidden"},w.createElement(R$,pr({"data-state":a==="hidden"?"hidden":"visible"},r,{ref:t,onPointerEnter:Xd(e.onPointerEnter,()=>u("POINTER_ENTER")),onPointerLeave:Xd(e.onPointerLeave,()=>u("POINTER_LEAVE"))})))}),tX=w.forwardRef((e,t)=>{const n=da(fc,e.__scopeScrollArea),{forceMount:r,...i}=e,[s,o]=w.useState(!1),a=e.orientation==="horizontal",u=Mx(()=>{if(n.viewport){const l=n.viewport.offsetWidth{const{orientation:n="vertical",...r}=e,i=da(fc,e.__scopeScrollArea),s=w.useRef(null),o=w.useRef(0),[a,u]=w.useState({content:0,viewport:0,scrollbar:{size:0,paddingStart:0,paddingEnd:0}}),l=sX(a.viewport,a.content),c={...r,sizes:a,onSizesChange:u,hasThumb:l>0&&l<1,onThumbChange:d=>s.current=d,onThumbPointerUp:()=>o.current=0,onThumbPointerDown:d=>o.current=d};function f(d,h){return Xwe(d,o.current,a,h)}return n==="horizontal"?w.createElement(Hwe,pr({},c,{ref:t,onThumbPositionChange:()=>{if(i.viewport&&s.current){const d=i.viewport.scrollLeft,h=r9(d,a,i.dir);s.current.style.transform=`translate3d(${h}px, 0, 0)`}},onWheelScroll:d=>{i.viewport&&(i.viewport.scrollLeft=d)},onDragScroll:d=>{i.viewport&&(i.viewport.scrollLeft=f(d,i.dir))}})):n==="vertical"?w.createElement(Wwe,pr({},c,{ref:t,onThumbPositionChange:()=>{if(i.viewport&&s.current){const d=i.viewport.scrollTop,h=r9(d,a);s.current.style.transform=`translate3d(0, ${h}px, 0)`}},onWheelScroll:d=>{i.viewport&&(i.viewport.scrollTop=d)},onDragScroll:d=>{i.viewport&&(i.viewport.scrollTop=f(d))}})):null}),Hwe=w.forwardRef((e,t)=>{const{sizes:n,onSizesChange:r,...i}=e,s=da(fc,e.__scopeScrollArea),[o,a]=w.useState(),u=w.useRef(null),l=kh(t,u,s.onScrollbarXChange);return w.useEffect(()=>{u.current&&a(getComputedStyle(u.current))},[u]),w.createElement(rX,pr({"data-orientation":"horizontal"},i,{ref:l,sizes:n,style:{bottom:0,left:s.dir==="rtl"?"var(--radix-scroll-area-corner-width)":0,right:s.dir==="ltr"?"var(--radix-scroll-area-corner-width)":0,"--radix-scroll-area-thumb-width":Lx(n)+"px",...e.style},onThumbPointerDown:c=>e.onThumbPointerDown(c.x),onDragScroll:c=>e.onDragScroll(c.x),onWheelScroll:(c,f)=>{if(s.viewport){const d=s.viewport.scrollLeft+c.deltaX;e.onWheelScroll(d),aX(d,f)&&c.preventDefault()}},onResize:()=>{u.current&&s.viewport&&o&&r({content:s.viewport.scrollWidth,viewport:s.viewport.offsetWidth,scrollbar:{size:u.current.clientWidth,paddingStart:ZE(o.paddingLeft),paddingEnd:ZE(o.paddingRight)}})}}))}),Wwe=w.forwardRef((e,t)=>{const{sizes:n,onSizesChange:r,...i}=e,s=da(fc,e.__scopeScrollArea),[o,a]=w.useState(),u=w.useRef(null),l=kh(t,u,s.onScrollbarYChange);return w.useEffect(()=>{u.current&&a(getComputedStyle(u.current))},[u]),w.createElement(rX,pr({"data-orientation":"vertical"},i,{ref:l,sizes:n,style:{top:0,right:s.dir==="ltr"?0:void 0,left:s.dir==="rtl"?0:void 0,bottom:"var(--radix-scroll-area-corner-height)","--radix-scroll-area-thumb-height":Lx(n)+"px",...e.style},onThumbPointerDown:c=>e.onThumbPointerDown(c.y),onDragScroll:c=>e.onDragScroll(c.y),onWheelScroll:(c,f)=>{if(s.viewport){const d=s.viewport.scrollTop+c.deltaY;e.onWheelScroll(d),aX(d,f)&&c.preventDefault()}},onResize:()=>{u.current&&s.viewport&&o&&r({content:s.viewport.scrollHeight,viewport:s.viewport.offsetHeight,scrollbar:{size:u.current.clientHeight,paddingStart:ZE(o.paddingTop),paddingEnd:ZE(o.paddingBottom)}})}}))}),[qwe,nX]=eX(fc),rX=w.forwardRef((e,t)=>{const{__scopeScrollArea:n,sizes:r,hasThumb:i,onThumbChange:s,onThumbPointerUp:o,onThumbPointerDown:a,onThumbPositionChange:u,onDragScroll:l,onWheelScroll:c,onResize:f,...d}=e,h=da(fc,n),[p,m]=w.useState(null),y=kh(t,R=>m(R)),g=w.useRef(null),v=w.useRef(""),b=h.viewport,S=r.content-r.viewport,T=wd(c),E=wd(u),I=Mx(f,10);function A(R){if(g.current){const F=R.clientX-g.current.left,L=R.clientY-g.current.top;l({x:F,y:L})}}return w.useEffect(()=>{const R=F=>{const L=F.target;(p==null?void 0:p.contains(L))&&T(F,S)};return document.addEventListener("wheel",R,{passive:!1}),()=>document.removeEventListener("wheel",R,{passive:!1})},[b,p,S,T]),w.useEffect(E,[r,E]),km(p,I),km(h.content,I),w.createElement(qwe,{scope:n,scrollbar:p,hasThumb:i,onThumbChange:wd(s),onThumbPointerUp:wd(o),onThumbPositionChange:E,onThumbPointerDown:wd(a)},w.createElement(L_.div,pr({},d,{ref:y,style:{position:"absolute",...d.style},onPointerDown:Xd(e.onPointerDown,R=>{R.button===0&&(R.target.setPointerCapture(R.pointerId),g.current=p.getBoundingClientRect(),v.current=document.body.style.webkitUserSelect,document.body.style.webkitUserSelect="none",A(R))}),onPointerMove:Xd(e.onPointerMove,A),onPointerUp:Xd(e.onPointerUp,R=>{const F=R.target;F.hasPointerCapture(R.pointerId)&&F.releasePointerCapture(R.pointerId),document.body.style.webkitUserSelect=v.current,g.current=null})})))}),WR="ScrollAreaThumb",Gwe=w.forwardRef((e,t)=>{const{forceMount:n,...r}=e,i=nX(WR,e.__scopeScrollArea);return w.createElement(M_,{present:n||i.hasThumb},w.createElement(Ywe,pr({ref:t},r)))}),Ywe=w.forwardRef((e,t)=>{const{__scopeScrollArea:n,style:r,...i}=e,s=da(WR,n),o=nX(WR,n),{onThumbPositionChange:a}=o,u=kh(t,f=>o.onThumbChange(f)),l=w.useRef(),c=Mx(()=>{l.current&&(l.current(),l.current=void 0)},100);return w.useEffect(()=>{const f=s.viewport;if(f){const d=()=>{if(c(),!l.current){const h=Jwe(f,a);l.current=h,a()}};return a(),f.addEventListener("scroll",d),()=>f.removeEventListener("scroll",d)}},[s.viewport,c,a]),w.createElement(L_.div,pr({"data-state":o.hasThumb?"visible":"hidden"},i,{ref:u,style:{width:"var(--radix-scroll-area-thumb-width)",height:"var(--radix-scroll-area-thumb-height)",...r},onPointerDownCapture:Xd(e.onPointerDownCapture,f=>{const h=f.target.getBoundingClientRect(),p=f.clientX-h.left,m=f.clientY-h.top;o.onThumbPointerDown({x:p,y:m})}),onPointerUp:Xd(e.onPointerUp,o.onThumbPointerUp)}))}),iX="ScrollAreaCorner",Kwe=w.forwardRef((e,t)=>{const n=da(iX,e.__scopeScrollArea),r=!!(n.scrollbarX&&n.scrollbarY);return n.type!=="scroll"&&r?w.createElement(Qwe,pr({},e,{ref:t})):null}),Qwe=w.forwardRef((e,t)=>{const{__scopeScrollArea:n,...r}=e,i=da(iX,n),[s,o]=w.useState(0),[a,u]=w.useState(0),l=!!(s&&a);return km(i.scrollbarX,()=>{var c;const f=((c=i.scrollbarX)===null||c===void 0?void 0:c.offsetHeight)||0;i.onCornerHeightChange(f),u(f)}),km(i.scrollbarY,()=>{var c;const f=((c=i.scrollbarY)===null||c===void 0?void 0:c.offsetWidth)||0;i.onCornerWidthChange(f),o(f)}),l?w.createElement(L_.div,pr({},r,{ref:t,style:{width:s,height:a,position:"absolute",right:i.dir==="ltr"?0:void 0,left:i.dir==="rtl"?0:void 0,bottom:0,...e.style}})):null});function ZE(e){return e?parseInt(e,10):0}function sX(e,t){const n=e/t;return isNaN(n)?0:n}function Lx(e){const t=sX(e.viewport,e.content),n=e.scrollbar.paddingStart+e.scrollbar.paddingEnd,r=(e.scrollbar.size-n)*t;return Math.max(r,18)}function Xwe(e,t,n,r="ltr"){const i=Lx(n),s=i/2,o=t||s,a=i-o,u=n.scrollbar.paddingStart+o,l=n.scrollbar.size-n.scrollbar.paddingEnd-a,c=n.content-n.viewport,f=r==="ltr"?[0,c]:[c*-1,0];return oX([u,l],f)(e)}function r9(e,t,n="ltr"){const r=Lx(t),i=t.scrollbar.paddingStart+t.scrollbar.paddingEnd,s=t.scrollbar.size-i,o=t.content-t.viewport,a=s-r,u=n==="ltr"?[0,o]:[o*-1,0],l=$we(e,u);return oX([0,o],[0,a])(l)}function oX(e,t){return n=>{if(e[0]===e[1]||t[0]===t[1])return t[0];const r=(t[1]-t[0])/(e[1]-e[0]);return t[0]+r*(n-e[0])}}function aX(e,t){return e>0&&e{})=>{let n={left:e.scrollLeft,top:e.scrollTop},r=0;return function i(){const s={left:e.scrollLeft,top:e.scrollTop},o=n.left!==s.left,a=n.top!==s.top;(o||a)&&t(),n=s,r=window.requestAnimationFrame(i)}(),()=>window.cancelAnimationFrame(r)};function Mx(e,t){const n=wd(e),r=w.useRef(0);return w.useEffect(()=>()=>window.clearTimeout(r.current),[]),w.useCallback(()=>{window.clearTimeout(r.current),r.current=window.setTimeout(n,t)},[n,t])}function km(e,t){const n=wd(t);HR(()=>{let r=0;if(e){const i=new ResizeObserver(()=>{cancelAnimationFrame(r),r=window.requestAnimationFrame(n)});return i.observe(e),()=>{window.cancelAnimationFrame(r),i.unobserve(e)}}},[e,n])}const Zwe=Fwe,eEe=jwe,i9=Uwe,s9=Gwe,tEe=Kwe;var nEe=lt((e,{scrollbarSize:t,offsetScrollbars:n,scrollbarHovered:r,hidden:i},s)=>({root:{overflow:"hidden"},viewport:{width:"100%",height:"100%",paddingRight:n?t:void 0,paddingBottom:n?t:void 0},scrollbar:{display:i?"none":"flex",userSelect:"none",touchAction:"none",boxSizing:"border-box",padding:t/5,transition:"background-color 150ms ease, opacity 150ms ease","&:hover":{backgroundColor:e.colorScheme==="dark"?e.colors.dark[8]:e.colors.gray[0],[`& .${s("thumb")}`]:{backgroundColor:e.colorScheme==="dark"?e.fn.rgba(e.white,.5):e.fn.rgba(e.black,.5)}},'&[data-orientation="vertical"]':{width:t},'&[data-orientation="horizontal"]':{flexDirection:"column",height:t},'&[data-state="hidden"]':{display:"none",opacity:0}},thumb:{ref:s("thumb"),flex:1,backgroundColor:e.colorScheme==="dark"?e.fn.rgba(e.white,.4):e.fn.rgba(e.black,.4),borderRadius:t,position:"relative",transition:"background-color 150ms ease",display:i?"none":void 0,overflow:"hidden","&::before":{content:'""',position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)",width:"100%",height:"100%",minWidth:44,minHeight:44}},corner:{backgroundColor:e.colorScheme==="dark"?e.colors.dark[6]:e.colors.gray[0],transition:"opacity 150ms ease",opacity:r?1:0,display:i?"none":void 0}})),rEe=Object.defineProperty,iEe=Object.defineProperties,sEe=Object.getOwnPropertyDescriptors,eS=Object.getOwnPropertySymbols,uX=Object.prototype.hasOwnProperty,lX=Object.prototype.propertyIsEnumerable,o9=(e,t,n)=>t in e?rEe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,qR=(e,t)=>{for(var n in t||(t={}))uX.call(t,n)&&o9(e,n,t[n]);if(eS)for(var n of eS(t))lX.call(t,n)&&o9(e,n,t[n]);return e},cX=(e,t)=>iEe(e,sEe(t)),fX=(e,t)=>{var n={};for(var r in e)uX.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&eS)for(var r of eS(e))t.indexOf(r)<0&&lX.call(e,r)&&(n[r]=e[r]);return n};const dX={scrollbarSize:12,scrollHideDelay:1e3,type:"hover",offsetScrollbars:!1},Fx=w.forwardRef((e,t)=>{const n=Ve("ScrollArea",dX,e),{children:r,className:i,classNames:s,styles:o,scrollbarSize:a,scrollHideDelay:u,type:l,dir:c,offsetScrollbars:f,viewportRef:d,onScrollPositionChange:h,unstyled:p,viewportProps:m}=n,y=fX(n,["children","className","classNames","styles","scrollbarSize","scrollHideDelay","type","dir","offsetScrollbars","viewportRef","onScrollPositionChange","unstyled","viewportProps"]),[g,v]=w.useState(!1),b=ji(),{classes:S,cx:T}=nEe({scrollbarSize:a,offsetScrollbars:f,scrollbarHovered:g,hidden:l==="never"},{name:"ScrollArea",classNames:s,styles:o,unstyled:p});return N.createElement(Zwe,{type:l==="never"?"always":l,scrollHideDelay:u,dir:c||b.dir,ref:t,asChild:!0},N.createElement(it,qR({className:T(S.root,i)},y),N.createElement(eEe,cX(qR({},m),{className:S.viewport,ref:d,onScroll:typeof h=="function"?({currentTarget:E})=>h({x:E.scrollLeft,y:E.scrollTop}):void 0}),r),N.createElement(i9,{orientation:"horizontal",className:S.scrollbar,forceMount:!0,onMouseEnter:()=>v(!0),onMouseLeave:()=>v(!1)},N.createElement(s9,{className:S.thumb})),N.createElement(i9,{orientation:"vertical",className:S.scrollbar,forceMount:!0,onMouseEnter:()=>v(!0),onMouseLeave:()=>v(!1)},N.createElement(s9,{className:S.thumb})),N.createElement(tEe,{className:S.corner})))}),hX=w.forwardRef((e,t)=>{const n=Ve("ScrollAreaAutosize",dX,e),{maxHeight:r,children:i,classNames:s,styles:o,scrollbarSize:a,scrollHideDelay:u,type:l,dir:c,offsetScrollbars:f,viewportRef:d,onScrollPositionChange:h,unstyled:p,sx:m}=n,y=fX(n,["maxHeight","children","classNames","styles","scrollbarSize","scrollHideDelay","type","dir","offsetScrollbars","viewportRef","onScrollPositionChange","unstyled","sx"]);return N.createElement(it,cX(qR({},y),{ref:t,sx:[{display:"flex",maxHeight:r},...lh(m)]}),N.createElement(it,{sx:{display:"flex",flexDirection:"column",flex:1}},N.createElement(Fx,{classNames:s,styles:o,scrollHideDelay:u,scrollbarSize:a,type:l,dir:c,offsetScrollbars:f,viewportRef:d,onScrollPositionChange:h,unstyled:p},i)))});hX.displayName="@mantine/core/ScrollAreaAutosize";Fx.displayName="@mantine/core/ScrollArea";Fx.Autosize=hX;const N$=Fx;var oEe=Object.defineProperty,aEe=Object.defineProperties,uEe=Object.getOwnPropertyDescriptors,tS=Object.getOwnPropertySymbols,pX=Object.prototype.hasOwnProperty,mX=Object.prototype.propertyIsEnumerable,a9=(e,t,n)=>t in e?oEe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,u9=(e,t)=>{for(var n in t||(t={}))pX.call(t,n)&&a9(e,n,t[n]);if(tS)for(var n of tS(t))mX.call(t,n)&&a9(e,n,t[n]);return e},lEe=(e,t)=>aEe(e,uEe(t)),cEe=(e,t)=>{var n={};for(var r in e)pX.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&tS)for(var r of tS(e))t.indexOf(r)<0&&mX.call(e,r)&&(n[r]=e[r]);return n};const Bx=w.forwardRef((e,t)=>{var n=e,{style:r}=n,i=cEe(n,["style"]);return N.createElement(N$,lEe(u9({},i),{style:u9({width:"100%"},r),viewportRef:t}),i.children)});Bx.displayName="@mantine/core/SelectScrollArea";var fEe=lt(()=>({dropdown:{},itemsWrapper:{padding:4,display:"flex",width:"100%",boxSizing:"border-box"}}));const qa=Math.min,es=Math.max,nS=Math.round,lb=Math.floor,If=e=>({x:e,y:e}),dEe={left:"right",right:"left",bottom:"top",top:"bottom"},hEe={start:"end",end:"start"};function GR(e,t,n){return es(e,qa(t,n))}function ql(e,t){return typeof e=="function"?e(t):e}function Ga(e){return e.split("-")[0]}function wg(e){return e.split("-")[1]}function k$(e){return e==="x"?"y":"x"}function D$(e){return e==="y"?"height":"width"}function Dh(e){return["top","bottom"].includes(Ga(e))?"y":"x"}function $$(e){return k$(Dh(e))}function pEe(e,t,n){n===void 0&&(n=!1);const r=wg(e),i=$$(e),s=D$(i);let o=i==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[s]>t.floating[s]&&(o=rS(o)),[o,rS(o)]}function mEe(e){const t=rS(e);return[YR(e),t,YR(t)]}function YR(e){return e.replace(/start|end/g,t=>hEe[t])}function gEe(e,t,n){const r=["left","right"],i=["right","left"],s=["top","bottom"],o=["bottom","top"];switch(e){case"top":case"bottom":return n?t?i:r:t?r:i;case"left":case"right":return t?s:o;default:return[]}}function yEe(e,t,n,r){const i=wg(e);let s=gEe(Ga(e),n==="start",r);return i&&(s=s.map(o=>o+"-"+i),t&&(s=s.concat(s.map(YR)))),s}function rS(e){return e.replace(/left|right|bottom|top/g,t=>dEe[t])}function vEe(e){return{top:0,right:0,bottom:0,left:0,...e}}function L$(e){return typeof e!="number"?vEe(e):{top:e,right:e,bottom:e,left:e}}function Dm(e){return{...e,top:e.y,left:e.x,right:e.x+e.width,bottom:e.y+e.height}}function l9(e,t,n){let{reference:r,floating:i}=e;const s=Dh(t),o=$$(t),a=D$(o),u=Ga(t),l=s==="y",c=r.x+r.width/2-i.width/2,f=r.y+r.height/2-i.height/2,d=r[a]/2-i[a]/2;let h;switch(u){case"top":h={x:c,y:r.y-i.height};break;case"bottom":h={x:c,y:r.y+r.height};break;case"right":h={x:r.x+r.width,y:f};break;case"left":h={x:r.x-i.width,y:f};break;default:h={x:r.x,y:r.y}}switch(wg(t)){case"start":h[o]-=d*(n&&l?-1:1);break;case"end":h[o]+=d*(n&&l?-1:1);break}return h}const _Ee=async(e,t,n)=>{const{placement:r="bottom",strategy:i="absolute",middleware:s=[],platform:o}=n,a=s.filter(Boolean),u=await(o.isRTL==null?void 0:o.isRTL(t));let l=await o.getElementRects({reference:e,floating:t,strategy:i}),{x:c,y:f}=l9(l,r,u),d=r,h={},p=0;for(let m=0;m({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:i,rects:s,platform:o,elements:a,middlewareData:u}=t,{element:l,padding:c=0}=ql(e,t)||{};if(l==null)return{};const f=L$(c),d={x:n,y:r},h=$$(i),p=D$(h),m=await o.getDimensions(l),y=h==="y",g=y?"top":"left",v=y?"bottom":"right",b=y?"clientHeight":"clientWidth",S=s.reference[p]+s.reference[h]-d[h]-s.floating[p],T=d[h]-s.reference[h],E=await(o.getOffsetParent==null?void 0:o.getOffsetParent(l));let I=E?E[b]:0;(!I||!await(o.isElement==null?void 0:o.isElement(E)))&&(I=a.floating[b]||s.floating[p]);const A=S/2-T/2,R=I/2-m[p]/2-1,F=qa(f[g],R),L=qa(f[v],R),B=F,J=I-m[p]-L,V=I/2-m[p]/2+A,re=GR(B,V,J),oe=!u.arrow&&wg(i)!=null&&V!==re&&s.reference[p]/2-(VB<=0)){var R,F;const B=(((R=s.flip)==null?void 0:R.index)||0)+1,J=T[B];if(J)return{data:{index:B,overflows:A},reset:{placement:J}};let V=(F=A.filter(re=>re.overflows[0]<=0).sort((re,oe)=>re.overflows[1]-oe.overflows[1])[0])==null?void 0:F.placement;if(!V)switch(h){case"bestFit":{var L;const re=(L=A.map(oe=>[oe.placement,oe.overflows.filter(ae=>ae>0).reduce((ae,ee)=>ae+ee,0)]).sort((oe,ae)=>oe[1]-ae[1])[0])==null?void 0:L[0];re&&(V=re);break}case"initialPlacement":V=a;break}if(i!==V)return{reset:{placement:V}}}return{}}}};function gX(e){const t=qa(...e.map(s=>s.left)),n=qa(...e.map(s=>s.top)),r=es(...e.map(s=>s.right)),i=es(...e.map(s=>s.bottom));return{x:t,y:n,width:r-t,height:i-n}}function EEe(e){const t=e.slice().sort((i,s)=>i.y-s.y),n=[];let r=null;for(let i=0;ir.height/2?n.push([s]):n[n.length-1].push(s),r=s}return n.map(i=>Dm(gX(i)))}const SEe=function(e){return e===void 0&&(e={}),{name:"inline",options:e,async fn(t){const{placement:n,elements:r,rects:i,platform:s,strategy:o}=t,{padding:a=2,x:u,y:l}=ql(e,t),c=Array.from(await(s.getClientRects==null?void 0:s.getClientRects(r.reference))||[]),f=EEe(c),d=Dm(gX(c)),h=L$(a);function p(){if(f.length===2&&f[0].left>f[1].right&&u!=null&&l!=null)return f.find(y=>u>y.left-h.left&&uy.top-h.top&&l=2){if(Dh(n)==="y"){const F=f[0],L=f[f.length-1],B=Ga(n)==="top",J=F.top,V=L.bottom,re=B?F.left:L.left,oe=B?F.right:L.right,ae=oe-re,ee=V-J;return{top:J,bottom:V,left:re,right:oe,width:ae,height:ee,x:re,y:J}}const y=Ga(n)==="left",g=es(...f.map(F=>F.right)),v=qa(...f.map(F=>F.left)),b=f.filter(F=>y?F.left===v:F.right===g),S=b[0].top,T=b[b.length-1].bottom,E=v,I=g,A=I-E,R=T-S;return{top:S,bottom:T,left:E,right:I,width:A,height:R,x:E,y:S}}return d}const m=await s.getElementRects({reference:{getBoundingClientRect:p},floating:r.floating,strategy:o});return i.reference.x!==m.reference.x||i.reference.y!==m.reference.y||i.reference.width!==m.reference.width||i.reference.height!==m.reference.height?{reset:{rects:m}}:{}}}};async function TEe(e,t){const{placement:n,platform:r,elements:i}=e,s=await(r.isRTL==null?void 0:r.isRTL(i.floating)),o=Ga(n),a=wg(n),u=Dh(n)==="y",l=["left","top"].includes(o)?-1:1,c=s&&u?-1:1,f=ql(t,e);let{mainAxis:d,crossAxis:h,alignmentAxis:p}=typeof f=="number"?{mainAxis:f,crossAxis:0,alignmentAxis:null}:{mainAxis:0,crossAxis:0,alignmentAxis:null,...f};return a&&typeof p=="number"&&(h=a==="end"?p*-1:p),u?{x:h*c,y:d*l}:{x:d*l,y:h*c}}const yX=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:i,y:s,placement:o,middlewareData:a}=t,u=await TEe(t,e);return o===((n=a.offset)==null?void 0:n.placement)&&(r=a.arrow)!=null&&r.alignmentOffset?{}:{x:i+u.x,y:s+u.y,data:{...u,placement:o}}}}},IEe=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:i}=t,{mainAxis:s=!0,crossAxis:o=!1,limiter:a={fn:y=>{let{x:g,y:v}=y;return{x:g,y:v}}},...u}=ql(e,t),l={x:n,y:r},c=await M$(t,u),f=Dh(Ga(i)),d=k$(f);let h=l[d],p=l[f];if(s){const y=d==="y"?"top":"left",g=d==="y"?"bottom":"right",v=h+c[y],b=h-c[g];h=GR(v,h,b)}if(o){const y=f==="y"?"top":"left",g=f==="y"?"bottom":"right",v=p+c[y],b=p-c[g];p=GR(v,p,b)}const m=a.fn({...t,[d]:h,[f]:p});return{...m,data:{x:m.x-n,y:m.y-r}}}}},xEe=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:i,rects:s,middlewareData:o}=t,{offset:a=0,mainAxis:u=!0,crossAxis:l=!0}=ql(e,t),c={x:n,y:r},f=Dh(i),d=k$(f);let h=c[d],p=c[f];const m=ql(a,t),y=typeof m=="number"?{mainAxis:m,crossAxis:0}:{mainAxis:0,crossAxis:0,...m};if(u){const b=d==="y"?"height":"width",S=s.reference[d]-s.floating[b]+y.mainAxis,T=s.reference[d]+s.reference[b]-y.mainAxis;hT&&(h=T)}if(l){var g,v;const b=d==="y"?"width":"height",S=["top","left"].includes(Ga(i)),T=s.reference[f]-s.floating[b]+(S&&((g=o.offset)==null?void 0:g[f])||0)+(S?0:y.crossAxis),E=s.reference[f]+s.reference[b]+(S?0:((v=o.offset)==null?void 0:v[f])||0)-(S?y.crossAxis:0);pE&&(p=E)}return{[d]:h,[f]:p}}}},CEe=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){const{placement:n,rects:r,platform:i,elements:s}=t,{apply:o=()=>{},...a}=ql(e,t),u=await M$(t,a),l=Ga(n),c=wg(n),f=Dh(n)==="y",{width:d,height:h}=r.floating;let p,m;l==="top"||l==="bottom"?(p=l,m=c===(await(i.isRTL==null?void 0:i.isRTL(s.floating))?"start":"end")?"left":"right"):(m=l,p=c==="end"?"top":"bottom");const y=h-u[p],g=d-u[m],v=!t.middlewareData.shift;let b=y,S=g;if(f){const E=d-u.left-u.right;S=c||v?qa(g,E):E}else{const E=h-u.top-u.bottom;b=c||v?qa(y,E):E}if(v&&!c){const E=es(u.left,0),I=es(u.right,0),A=es(u.top,0),R=es(u.bottom,0);f?S=d-2*(E!==0||I!==0?E+I:es(u.left,u.right)):b=h-2*(A!==0||R!==0?A+R:es(u.top,u.bottom))}await o({...t,availableWidth:S,availableHeight:b});const T=await i.getDimensions(s.floating);return d!==T.width||h!==T.height?{reset:{rects:!0}}:{}}}};function xf(e){return vX(e)?(e.nodeName||"").toLowerCase():"#document"}function Co(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function dc(e){var t;return(t=(vX(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function vX(e){return e instanceof Node||e instanceof Co(e).Node}function Gl(e){return e instanceof Element||e instanceof Co(e).Element}function Qu(e){return e instanceof HTMLElement||e instanceof Co(e).HTMLElement}function c9(e){return typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof Co(e).ShadowRoot}function F_(e){const{overflow:t,overflowX:n,overflowY:r,display:i}=aa(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!["inline","contents"].includes(i)}function AEe(e){return["table","td","th"].includes(xf(e))}function F$(e){const t=B$(),n=aa(e);return n.transform!=="none"||n.perspective!=="none"||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||["transform","perspective","filter"].some(r=>(n.willChange||"").includes(r))||["paint","layout","strict","content"].some(r=>(n.contain||"").includes(r))}function PEe(e){let t=$m(e);for(;Qu(t)&&!jx(t);){if(F$(t))return t;t=$m(t)}return null}function B$(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function jx(e){return["html","body","#document"].includes(xf(e))}function aa(e){return Co(e).getComputedStyle(e)}function Ux(e){return Gl(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.pageXOffset,scrollTop:e.pageYOffset}}function $m(e){if(xf(e)==="html")return e;const t=e.assignedSlot||e.parentNode||c9(e)&&e.host||dc(e);return c9(t)?t.host:t}function _X(e){const t=$m(e);return jx(t)?e.ownerDocument?e.ownerDocument.body:e.body:Qu(t)&&F_(t)?t:_X(t)}function Fl(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const i=_X(e),s=i===((r=e.ownerDocument)==null?void 0:r.body),o=Co(i);return s?t.concat(o,o.visualViewport||[],F_(i)?i:[],o.frameElement&&n?Fl(o.frameElement):[]):t.concat(i,Fl(i,[],n))}function bX(e){const t=aa(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const i=Qu(e),s=i?e.offsetWidth:n,o=i?e.offsetHeight:r,a=nS(n)!==s||nS(r)!==o;return a&&(n=s,r=o),{width:n,height:r,$:a}}function j$(e){return Gl(e)?e:e.contextElement}function Zp(e){const t=j$(e);if(!Qu(t))return If(1);const n=t.getBoundingClientRect(),{width:r,height:i,$:s}=bX(t);let o=(s?nS(n.width):n.width)/r,a=(s?nS(n.height):n.height)/i;return(!o||!Number.isFinite(o))&&(o=1),(!a||!Number.isFinite(a))&&(a=1),{x:o,y:a}}const OEe=If(0);function wX(e){const t=Co(e);return!B$()||!t.visualViewport?OEe:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function REe(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==Co(e)?!1:t}function ch(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const i=e.getBoundingClientRect(),s=j$(e);let o=If(1);t&&(r?Gl(r)&&(o=Zp(r)):o=Zp(e));const a=REe(s,n,r)?wX(s):If(0);let u=(i.left+a.x)/o.x,l=(i.top+a.y)/o.y,c=i.width/o.x,f=i.height/o.y;if(s){const d=Co(s),h=r&&Gl(r)?Co(r):r;let p=d,m=p.frameElement;for(;m&&r&&h!==p;){const y=Zp(m),g=m.getBoundingClientRect(),v=aa(m),b=g.left+(m.clientLeft+parseFloat(v.paddingLeft))*y.x,S=g.top+(m.clientTop+parseFloat(v.paddingTop))*y.y;u*=y.x,l*=y.y,c*=y.x,f*=y.y,u+=b,l+=S,p=Co(m),m=p.frameElement}}return Dm({width:c,height:f,x:u,y:l})}const NEe=[":popover-open",":modal"];function EX(e){return NEe.some(t=>{try{return e.matches(t)}catch{return!1}})}function kEe(e){let{elements:t,rect:n,offsetParent:r,strategy:i}=e;const s=i==="fixed",o=dc(r),a=t?EX(t.floating):!1;if(r===o||a&&s)return n;let u={scrollLeft:0,scrollTop:0},l=If(1);const c=If(0),f=Qu(r);if((f||!f&&!s)&&((xf(r)!=="body"||F_(o))&&(u=Ux(r)),Qu(r))){const d=ch(r);l=Zp(r),c.x=d.x+r.clientLeft,c.y=d.y+r.clientTop}return{width:n.width*l.x,height:n.height*l.y,x:n.x*l.x-u.scrollLeft*l.x+c.x,y:n.y*l.y-u.scrollTop*l.y+c.y}}function DEe(e){return Array.from(e.getClientRects())}function SX(e){return ch(dc(e)).left+Ux(e).scrollLeft}function $Ee(e){const t=dc(e),n=Ux(e),r=e.ownerDocument.body,i=es(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),s=es(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let o=-n.scrollLeft+SX(e);const a=-n.scrollTop;return aa(r).direction==="rtl"&&(o+=es(t.clientWidth,r.clientWidth)-i),{width:i,height:s,x:o,y:a}}function LEe(e,t){const n=Co(e),r=dc(e),i=n.visualViewport;let s=r.clientWidth,o=r.clientHeight,a=0,u=0;if(i){s=i.width,o=i.height;const l=B$();(!l||l&&t==="fixed")&&(a=i.offsetLeft,u=i.offsetTop)}return{width:s,height:o,x:a,y:u}}function MEe(e,t){const n=ch(e,!0,t==="fixed"),r=n.top+e.clientTop,i=n.left+e.clientLeft,s=Qu(e)?Zp(e):If(1),o=e.clientWidth*s.x,a=e.clientHeight*s.y,u=i*s.x,l=r*s.y;return{width:o,height:a,x:u,y:l}}function f9(e,t,n){let r;if(t==="viewport")r=LEe(e,n);else if(t==="document")r=$Ee(dc(e));else if(Gl(t))r=MEe(t,n);else{const i=wX(e);r={...t,x:t.x-i.x,y:t.y-i.y}}return Dm(r)}function TX(e,t){const n=$m(e);return n===t||!Gl(n)||jx(n)?!1:aa(n).position==="fixed"||TX(n,t)}function FEe(e,t){const n=t.get(e);if(n)return n;let r=Fl(e,[],!1).filter(a=>Gl(a)&&xf(a)!=="body"),i=null;const s=aa(e).position==="fixed";let o=s?$m(e):e;for(;Gl(o)&&!jx(o);){const a=aa(o),u=F$(o);!u&&a.position==="fixed"&&(i=null),(s?!u&&!i:!u&&a.position==="static"&&!!i&&["absolute","fixed"].includes(i.position)||F_(o)&&!u&&TX(e,o))?r=r.filter(c=>c!==o):i=a,o=$m(o)}return t.set(e,r),r}function BEe(e){let{element:t,boundary:n,rootBoundary:r,strategy:i}=e;const o=[...n==="clippingAncestors"?FEe(t,this._c):[].concat(n),r],a=o[0],u=o.reduce((l,c)=>{const f=f9(t,c,i);return l.top=es(f.top,l.top),l.right=qa(f.right,l.right),l.bottom=qa(f.bottom,l.bottom),l.left=es(f.left,l.left),l},f9(t,a,i));return{width:u.right-u.left,height:u.bottom-u.top,x:u.left,y:u.top}}function jEe(e){const{width:t,height:n}=bX(e);return{width:t,height:n}}function UEe(e,t,n){const r=Qu(t),i=dc(t),s=n==="fixed",o=ch(e,!0,s,t);let a={scrollLeft:0,scrollTop:0};const u=If(0);if(r||!r&&!s)if((xf(t)!=="body"||F_(i))&&(a=Ux(t)),r){const f=ch(t,!0,s,t);u.x=f.x+t.clientLeft,u.y=f.y+t.clientTop}else i&&(u.x=SX(i));const l=o.left+a.scrollLeft-u.x,c=o.top+a.scrollTop-u.y;return{x:l,y:c,width:o.width,height:o.height}}function d9(e,t){return!Qu(e)||aa(e).position==="fixed"?null:t?t(e):e.offsetParent}function IX(e,t){const n=Co(e);if(!Qu(e)||EX(e))return n;let r=d9(e,t);for(;r&&AEe(r)&&aa(r).position==="static";)r=d9(r,t);return r&&(xf(r)==="html"||xf(r)==="body"&&aa(r).position==="static"&&!F$(r))?n:r||PEe(e)||n}const VEe=async function(e){const t=this.getOffsetParent||IX,n=this.getDimensions;return{reference:UEe(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,...await n(e.floating)}}};function zEe(e){return aa(e).direction==="rtl"}const HEe={convertOffsetParentRelativeRectToViewportRelativeRect:kEe,getDocumentElement:dc,getClippingRect:BEe,getOffsetParent:IX,getElementRects:VEe,getClientRects:DEe,getDimensions:jEe,getScale:Zp,isElement:Gl,isRTL:zEe};function WEe(e,t){let n=null,r;const i=dc(e);function s(){var a;clearTimeout(r),(a=n)==null||a.disconnect(),n=null}function o(a,u){a===void 0&&(a=!1),u===void 0&&(u=1),s();const{left:l,top:c,width:f,height:d}=e.getBoundingClientRect();if(a||t(),!f||!d)return;const h=lb(c),p=lb(i.clientWidth-(l+f)),m=lb(i.clientHeight-(c+d)),y=lb(l),v={rootMargin:-h+"px "+-p+"px "+-m+"px "+-y+"px",threshold:es(0,qa(1,u))||1};let b=!0;function S(T){const E=T[0].intersectionRatio;if(E!==u){if(!b)return o();E?o(!1,E):r=setTimeout(()=>{o(!1,1e-7)},100)}b=!1}try{n=new IntersectionObserver(S,{...v,root:i.ownerDocument})}catch{n=new IntersectionObserver(S,v)}n.observe(e)}return o(!0),s}function qEe(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:i=!0,ancestorResize:s=!0,elementResize:o=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:u=!1}=r,l=j$(e),c=i||s?[...l?Fl(l):[],...Fl(t)]:[];c.forEach(g=>{i&&g.addEventListener("scroll",n,{passive:!0}),s&&g.addEventListener("resize",n)});const f=l&&a?WEe(l,n):null;let d=-1,h=null;o&&(h=new ResizeObserver(g=>{let[v]=g;v&&v.target===l&&h&&(h.unobserve(t),cancelAnimationFrame(d),d=requestAnimationFrame(()=>{var b;(b=h)==null||b.observe(t)})),n()}),l&&!u&&h.observe(l),h.observe(t));let p,m=u?ch(e):null;u&&y();function y(){const g=ch(e);m&&(g.x!==m.x||g.y!==m.y||g.width!==m.width||g.height!==m.height)&&n(),m=g,p=requestAnimationFrame(y)}return n(),()=>{var g;c.forEach(v=>{i&&v.removeEventListener("scroll",n),s&&v.removeEventListener("resize",n)}),f==null||f(),(g=h)==null||g.disconnect(),h=null,u&&cancelAnimationFrame(p)}}const U$=IEe,xX=wEe,GEe=CEe,h9=bEe,CX=SEe,YEe=xEe,KEe=(e,t,n)=>{const r=new Map,i={platform:HEe,...n},s={...i.platform,_c:r};return _Ee(e,t,{...i,platform:s})},AX=e=>{const{element:t,padding:n}=e;function r(i){return Object.prototype.hasOwnProperty.call(i,"current")}return{name:"arrow",options:e,fn(i){return r(t)?t.current!=null?h9({element:t.current,padding:n}).fn(i):{}:t?h9({element:t,padding:n}).fn(i):{}}}};var Cw=typeof document<"u"?w.useLayoutEffect:w.useEffect;function iS(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let n,r,i;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(n=e.length,n!=t.length)return!1;for(r=n;r--!==0;)if(!iS(e[r],t[r]))return!1;return!0}if(i=Object.keys(e),n=i.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!Object.prototype.hasOwnProperty.call(t,i[r]))return!1;for(r=n;r--!==0;){const s=i[r];if(!(s==="_owner"&&e.$$typeof)&&!iS(e[s],t[s]))return!1}return!0}return e!==e&&t!==t}function p9(e){const t=w.useRef(e);return Cw(()=>{t.current=e}),t}function QEe(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:i,whileElementsMounted:s,open:o}=e,[a,u]=w.useState({x:null,y:null,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[l,c]=w.useState(r);iS(l,r)||c(r);const f=w.useRef(null),d=w.useRef(null),h=w.useRef(a),p=p9(s),m=p9(i),[y,g]=w.useState(null),[v,b]=w.useState(null),S=w.useCallback(F=>{f.current!==F&&(f.current=F,g(F))},[]),T=w.useCallback(F=>{d.current!==F&&(d.current=F,b(F))},[]),E=w.useCallback(()=>{if(!f.current||!d.current)return;const F={placement:t,strategy:n,middleware:l};m.current&&(F.platform=m.current),KEe(f.current,d.current,F).then(L=>{const B={...L,isPositioned:!0};I.current&&!iS(h.current,B)&&(h.current=B,lc.flushSync(()=>{u(B)}))})},[l,t,n,m]);Cw(()=>{o===!1&&h.current.isPositioned&&(h.current.isPositioned=!1,u(F=>({...F,isPositioned:!1})))},[o]);const I=w.useRef(!1);Cw(()=>(I.current=!0,()=>{I.current=!1}),[]),Cw(()=>{if(y&&v){if(p.current)return p.current(y,v,E);E()}},[y,v,E,p]);const A=w.useMemo(()=>({reference:f,floating:d,setReference:S,setFloating:T}),[S,T]),R=w.useMemo(()=>({reference:y,floating:v}),[y,v]);return w.useMemo(()=>({...a,update:E,refs:A,elements:R,reference:S,floating:T}),[a,E,A,R,S,T])}var Lm=typeof document<"u"?w.useLayoutEffect:w.useEffect;let $P=!1,XEe=0;const m9=()=>"floating-ui-"+XEe++;function JEe(){const[e,t]=w.useState(()=>$P?m9():void 0);return Lm(()=>{e==null&&t(m9())},[]),w.useEffect(()=>{$P||($P=!0)},[]),e}const ZEe=Zy.useId,g9=ZEe||JEe;function eSe(){const e=new Map;return{emit(t,n){var r;(r=e.get(t))==null||r.forEach(i=>i(n))},on(t,n){e.set(t,[...e.get(t)||[],n])},off(t,n){e.set(t,(e.get(t)||[]).filter(r=>r!==n))}}}const tSe=w.createContext(null),nSe=w.createContext(null),PX=()=>{var e;return((e=w.useContext(tSe))==null?void 0:e.id)||null},V$=()=>w.useContext(nSe);function Kc(e){return(e==null?void 0:e.ownerDocument)||document}function rSe(){const e=navigator.userAgentData;return e!=null&&e.platform?e.platform:navigator.platform}function iSe(){const e=navigator.userAgentData;return e&&Array.isArray(e.brands)?e.brands.map(t=>{let{brand:n,version:r}=t;return n+"/"+r}).join(" "):navigator.userAgent}function z$(e){return Kc(e).defaultView||window}function Pu(e){return e?e instanceof z$(e).Element:!1}function OX(e){return e?e instanceof z$(e).HTMLElement:!1}function sSe(e){if(typeof ShadowRoot>"u")return!1;const t=z$(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function oSe(e){if(e.mozInputSource===0&&e.isTrusted)return!0;const t=/Android/i;return(t.test(rSe())||t.test(iSe()))&&e.pointerType?e.type==="click"&&e.buttons===1:e.detail===0&&!e.pointerType}function aSe(e){return e.width===0&&e.height===0||e.width===1&&e.height===1&&e.pressure===0&&e.detail===0&&e.pointerType!=="mouse"||e.width<1&&e.height<1&&e.pressure===0&&e.detail===0}function RX(e,t){const n=["mouse","pen"];return t||n.push("",void 0),n.includes(e)}function y9(e){const t=w.useRef(e);return Lm(()=>{t.current=e}),t}const v9="data-floating-ui-safe-polygon";function Aw(e,t,n){return n&&!RX(n)?0:typeof e=="number"?e:e==null?void 0:e[t]}const uSe=function(e,t){let{enabled:n=!0,delay:r=0,handleClose:i=null,mouseOnly:s=!1,restMs:o=0,move:a=!0}=t===void 0?{}:t;const{open:u,onOpenChange:l,dataRef:c,events:f,elements:{domReference:d,floating:h},refs:p}=e,m=V$(),y=PX(),g=y9(i),v=y9(r),b=w.useRef(),S=w.useRef(),T=w.useRef(),E=w.useRef(),I=w.useRef(!0),A=w.useRef(!1),R=w.useRef(()=>{}),F=w.useCallback(()=>{var V;const re=(V=c.current.openEvent)==null?void 0:V.type;return(re==null?void 0:re.includes("mouse"))&&re!=="mousedown"},[c]);w.useEffect(()=>{if(!n)return;function V(){clearTimeout(S.current),clearTimeout(E.current),I.current=!0}return f.on("dismiss",V),()=>{f.off("dismiss",V)}},[n,f]),w.useEffect(()=>{if(!n||!g.current||!u)return;function V(){F()&&l(!1)}const re=Kc(h).documentElement;return re.addEventListener("mouseleave",V),()=>{re.removeEventListener("mouseleave",V)}},[h,u,l,n,g,c,F]);const L=w.useCallback(function(V){V===void 0&&(V=!0);const re=Aw(v.current,"close",b.current);re&&!T.current?(clearTimeout(S.current),S.current=setTimeout(()=>l(!1),re)):V&&(clearTimeout(S.current),l(!1))},[v,l]),B=w.useCallback(()=>{R.current(),T.current=void 0},[]),J=w.useCallback(()=>{if(A.current){const V=Kc(p.floating.current).body;V.style.pointerEvents="",V.removeAttribute(v9),A.current=!1}},[p]);return w.useEffect(()=>{if(!n)return;function V(){return c.current.openEvent?["click","mousedown"].includes(c.current.openEvent.type):!1}function re(ee){if(clearTimeout(S.current),I.current=!1,s&&!RX(b.current)||o>0&&Aw(v.current,"open")===0)return;c.current.openEvent=ee;const ue=Aw(v.current,"open",b.current);ue?S.current=setTimeout(()=>{l(!0)},ue):l(!0)}function oe(ee){if(V())return;R.current();const ue=Kc(h);if(clearTimeout(E.current),g.current){u||clearTimeout(S.current),T.current=g.current({...e,tree:m,x:ee.clientX,y:ee.clientY,onClose(){J(),B(),L()}});const P=T.current;ue.addEventListener("mousemove",P),R.current=()=>{ue.removeEventListener("mousemove",P)};return}L()}function ae(ee){V()||g.current==null||g.current({...e,tree:m,x:ee.clientX,y:ee.clientY,onClose(){J(),B(),L()}})(ee)}if(Pu(d)){const ee=d;return u&&ee.addEventListener("mouseleave",ae),h==null||h.addEventListener("mouseleave",ae),a&&ee.addEventListener("mousemove",re,{once:!0}),ee.addEventListener("mouseenter",re),ee.addEventListener("mouseleave",oe),()=>{u&&ee.removeEventListener("mouseleave",ae),h==null||h.removeEventListener("mouseleave",ae),a&&ee.removeEventListener("mousemove",re),ee.removeEventListener("mouseenter",re),ee.removeEventListener("mouseleave",oe)}}},[d,h,n,e,s,o,a,L,B,J,l,u,m,v,g,c]),Lm(()=>{var V;if(n&&u&&(V=g.current)!=null&&V.__options.blockPointerEvents&&F()){const ae=Kc(h).body;if(ae.setAttribute(v9,""),ae.style.pointerEvents="none",A.current=!0,Pu(d)&&h){var re,oe;const ee=d,ue=m==null||(re=m.nodesRef.current.find(P=>P.id===y))==null||(oe=re.context)==null?void 0:oe.elements.floating;return ue&&(ue.style.pointerEvents=""),ee.style.pointerEvents="auto",h.style.pointerEvents="auto",()=>{ee.style.pointerEvents="",h.style.pointerEvents=""}}}},[n,u,y,h,d,m,g,c,F]),Lm(()=>{u||(b.current=void 0,B(),J())},[u,B,J]),w.useEffect(()=>()=>{B(),clearTimeout(S.current),clearTimeout(E.current),J()},[n,B,J]),w.useMemo(()=>{if(!n)return{};function V(re){b.current=re.pointerType}return{reference:{onPointerDown:V,onPointerEnter:V,onMouseMove(){u||o===0||(clearTimeout(E.current),E.current=setTimeout(()=>{I.current||l(!0)},o))}},floating:{onMouseEnter(){clearTimeout(S.current)},onMouseLeave(){f.emit("dismiss",{type:"mouseLeave",data:{returnFocus:!1}}),L(!1)}}}},[f,n,o,u,l,L])},NX=w.createContext({delay:0,initialDelay:0,timeoutMs:0,currentId:null,setCurrentId:()=>{},setState:()=>{},isInstantPhase:!1}),kX=()=>w.useContext(NX),lSe=e=>{let{children:t,delay:n,timeoutMs:r=0}=e;const[i,s]=w.useReducer((u,l)=>({...u,...l}),{delay:n,timeoutMs:r,initialDelay:n,currentId:null,isInstantPhase:!1}),o=w.useRef(null),a=w.useCallback(u=>{s({currentId:u})},[]);return Lm(()=>{i.currentId?o.current===null?o.current=i.currentId:s({isInstantPhase:!0}):(s({isInstantPhase:!1}),o.current=null)},[i.currentId]),w.createElement(NX.Provider,{value:w.useMemo(()=>({...i,setState:s,setCurrentId:a}),[i,s,a])},t)},cSe=(e,t)=>{let{open:n,onOpenChange:r}=e,{id:i}=t;const{currentId:s,setCurrentId:o,initialDelay:a,setState:u,timeoutMs:l}=kX();w.useEffect(()=>{s&&(u({delay:{open:1,close:Aw(a,"close")}}),s!==i&&r(!1))},[i,r,u,s,a]),w.useEffect(()=>{function c(){r(!1),u({delay:a,currentId:null})}if(!n&&s===i)if(l){const f=window.setTimeout(c,l);return()=>{clearTimeout(f)}}else c()},[n,u,s,i,r,a,l]),w.useEffect(()=>{n&&o(i)},[n,o,i])};function fSe(e){let t=e.activeElement;for(;((n=t)==null||(r=n.shadowRoot)==null?void 0:r.activeElement)!=null;){var n,r;t=t.shadowRoot.activeElement}return t}function _9(e,t){if(!e||!t)return!1;const n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&sSe(n)){let r=t;do{if(r&&e===r)return!0;r=r.parentNode||r.host}while(r)}return!1}function LP(e,t){let n=e.filter(i=>{var s;return i.parentId===t&&((s=i.context)==null?void 0:s.open)})||[],r=n;for(;r.length;)r=e.filter(i=>{var s;return(s=r)==null?void 0:s.some(o=>{var a;return i.parentId===o.id&&((a=i.context)==null?void 0:a.open)})})||[],n=n.concat(r);return n}function dSe(e){return"composedPath"in e?e.composedPath()[0]:e.target}const hSe=Zy.useInsertionEffect,pSe=hSe||(e=>e());function DX(e){const t=w.useRef(()=>{});return pSe(()=>{t.current=e}),w.useCallback(function(){for(var n=arguments.length,r=new Array(n),i=0;i!1),T=typeof d=="function"?S:d,E=w.useRef(!1),{escapeKeyBubbles:I,outsidePressBubbles:A}=ySe(g);return w.useEffect(()=>{if(!n||!c)return;l.current.__escapeKeyBubbles=I,l.current.__outsidePressBubbles=A;function R(V){if(V.key==="Escape"){const re=v?LP(v.nodesRef.current,s):[];if(re.length>0){let oe=!0;if(re.forEach(ae=>{var ee;if((ee=ae.context)!=null&&ee.open&&!ae.context.dataRef.current.__escapeKeyBubbles){oe=!1;return}}),!oe)return}i.emit("dismiss",{type:"escapeKey",data:{returnFocus:{preventScroll:!1}}}),r(!1)}}function F(V){const re=E.current;if(E.current=!1,re||typeof T=="function"&&!T(V))return;const oe=dSe(V);if(OX(oe)&&u){const ue=u.ownerDocument.defaultView||window,P=oe.scrollWidth>oe.clientWidth,W=oe.scrollHeight>oe.clientHeight;let Q=W&&V.offsetX>oe.clientWidth;if(W&&ue.getComputedStyle(oe).direction==="rtl"&&(Q=V.offsetX<=oe.offsetWidth-oe.clientWidth),Q||P&&V.offsetY>oe.clientHeight)return}const ae=v&&LP(v.nodesRef.current,s).some(ue=>{var P;return Pw(V,(P=ue.context)==null?void 0:P.elements.floating)});if(Pw(V,u)||Pw(V,a)||ae)return;const ee=v?LP(v.nodesRef.current,s):[];if(ee.length>0){let ue=!0;if(ee.forEach(P=>{var W;if((W=P.context)!=null&&W.open&&!P.context.dataRef.current.__outsidePressBubbles){ue=!1;return}}),!ue)return}i.emit("dismiss",{type:"outsidePress",data:{returnFocus:b?{preventScroll:!0}:oSe(V)||aSe(V)}}),r(!1)}function L(){r(!1)}const B=Kc(u);f&&B.addEventListener("keydown",R),T&&B.addEventListener(h,F);let J=[];return y&&(Pu(a)&&(J=Fl(a)),Pu(u)&&(J=J.concat(Fl(u))),!Pu(o)&&o&&o.contextElement&&(J=J.concat(Fl(o.contextElement)))),J=J.filter(V=>{var re;return V!==((re=B.defaultView)==null?void 0:re.visualViewport)}),J.forEach(V=>{V.addEventListener("scroll",L,{passive:!0})}),()=>{f&&B.removeEventListener("keydown",R),T&&B.removeEventListener(h,F),J.forEach(V=>{V.removeEventListener("scroll",L)})}},[l,u,a,o,f,T,h,i,v,s,n,r,y,c,I,A,b]),w.useEffect(()=>{E.current=!1},[T,h]),w.useMemo(()=>c?{reference:{[mSe[m]]:()=>{p&&(i.emit("dismiss",{type:"referencePress",data:{returnFocus:!1}}),r(!1))}},floating:{[gSe[h]]:()=>{E.current=!0}}}:{},[c,i,p,h,m,r])},_Se=function(e,t){let{open:n,onOpenChange:r,dataRef:i,events:s,refs:o,elements:{floating:a,domReference:u}}=e,{enabled:l=!0,keyboardOnly:c=!0}=t===void 0?{}:t;const f=w.useRef(""),d=w.useRef(!1),h=w.useRef();return w.useEffect(()=>{if(!l)return;const m=Kc(a).defaultView||window;function y(){!n&&OX(u)&&u===fSe(Kc(u))&&(d.current=!0)}return m.addEventListener("blur",y),()=>{m.removeEventListener("blur",y)}},[a,u,n,l]),w.useEffect(()=>{if(!l)return;function p(m){(m.type==="referencePress"||m.type==="escapeKey")&&(d.current=!0)}return s.on("dismiss",p),()=>{s.off("dismiss",p)}},[s,l]),w.useEffect(()=>()=>{clearTimeout(h.current)},[]),w.useMemo(()=>l?{reference:{onPointerDown(p){let{pointerType:m}=p;f.current=m,d.current=!!(m&&c)},onMouseLeave(){d.current=!1},onFocus(p){var m;d.current||p.type==="focus"&&((m=i.current.openEvent)==null?void 0:m.type)==="mousedown"&&i.current.openEvent&&Pw(i.current.openEvent,u)||(i.current.openEvent=p.nativeEvent,r(!0))},onBlur(p){d.current=!1;const m=p.relatedTarget,y=Pu(m)&&m.hasAttribute("data-floating-ui-focus-guard")&&m.getAttribute("data-type")==="outside";h.current=setTimeout(()=>{_9(o.floating.current,m)||_9(u,m)||y||r(!1)})}}}:{},[l,c,u,o,i,r])},bSe=function(e,t){let{open:n}=e,{enabled:r=!0,role:i="dialog"}=t===void 0?{}:t;const s=g9(),o=g9();return w.useMemo(()=>{const a={id:s,role:i};return r?i==="tooltip"?{reference:{"aria-describedby":n?s:void 0},floating:a}:{reference:{"aria-expanded":n?"true":"false","aria-haspopup":i==="alertdialog"?"dialog":i,"aria-controls":n?s:void 0,...i==="listbox"&&{role:"combobox"},...i==="menu"&&{id:o}},floating:{...a,...i==="menu"&&{"aria-labelledby":o}}}:{}},[r,i,n,s,o])};function H$(e){e===void 0&&(e={});const{open:t=!1,onOpenChange:n,nodeId:r}=e,i=QEe(e),s=V$(),o=w.useRef(null),a=w.useRef({}),u=w.useState(()=>eSe())[0],[l,c]=w.useState(null),f=w.useCallback(g=>{const v=Pu(g)?{getBoundingClientRect:()=>g.getBoundingClientRect(),contextElement:g}:g;i.refs.setReference(v)},[i.refs]),d=w.useCallback(g=>{(Pu(g)||g===null)&&(o.current=g,c(g)),(Pu(i.refs.reference.current)||i.refs.reference.current===null||g!==null&&!Pu(g))&&i.refs.setReference(g)},[i.refs]),h=w.useMemo(()=>({...i.refs,setReference:d,setPositionReference:f,domReference:o}),[i.refs,d,f]),p=w.useMemo(()=>({...i.elements,domReference:l}),[i.elements,l]),m=DX(n),y=w.useMemo(()=>({...i,refs:h,elements:p,dataRef:a,nodeId:r,events:u,open:t,onOpenChange:m}),[i,r,u,t,m,h,p]);return Lm(()=>{const g=s==null?void 0:s.nodesRef.current.find(v=>v.id===r);g&&(g.context=y)}),w.useMemo(()=>({...i,context:y,refs:h,reference:d,positionReference:f}),[i,h,y,d,f])}function MP(e,t,n){const r=new Map;return{...n==="floating"&&{tabIndex:-1},...e,...t.map(i=>i?i[n]:null).concat(e).reduce((i,s)=>(s&&Object.entries(s).forEach(o=>{let[a,u]=o;if(a.indexOf("on")===0){if(r.has(a)||r.set(a,[]),typeof u=="function"){var l;(l=r.get(a))==null||l.push(u),i[a]=function(){for(var c,f=arguments.length,d=new Array(f),h=0;hp(...d))}}}else i[a]=u}),i),{})}}const wSe=function(e){e===void 0&&(e=[]);const t=e,n=w.useCallback(s=>MP(s,e,"reference"),t),r=w.useCallback(s=>MP(s,e,"floating"),t),i=w.useCallback(s=>MP(s,e,"item"),e.map(s=>s==null?void 0:s.item));return w.useMemo(()=>({getReferenceProps:n,getFloatingProps:r,getItemProps:i}),[n,r,i])};function $X({opened:e,floating:t,positionDependencies:n}){const[r,i]=w.useState(0);w.useEffect(()=>{if(t.refs.reference.current&&t.refs.floating.current)return qEe(t.refs.reference.current,t.refs.floating.current,t.update)},[t.refs.reference.current,t.refs.floating.current,e,r]),Js(()=>{t.update()},n),Js(()=>{i(s=>s+1)},[e])}function ESe(e){const t=[yX(e.offset)];return e.middlewares.shift&&t.push(U$({limiter:YEe()})),e.middlewares.flip&&t.push(xX()),e.middlewares.inline&&t.push(CX()),t.push(AX({element:e.arrowRef,padding:e.arrowOffset})),t}function SSe(e){const[t,n]=oa({value:e.opened,defaultValue:e.defaultOpened,finalValue:!1,onChange:e.onChange}),r=()=>{var o;(o=e.onClose)==null||o.call(e),n(!1)},i=()=>{var o,a;t?((o=e.onClose)==null||o.call(e),n(!1)):((a=e.onOpen)==null||a.call(e),n(!0))},s=H$({placement:e.position,middleware:[...ESe(e),...e.width==="target"?[GEe({apply({rects:o}){var a,u;Object.assign((u=(a=s.refs.floating.current)==null?void 0:a.style)!=null?u:{},{width:`${o.reference.width}px`})}})]:[]]});return $X({opened:e.opened,positionDependencies:e.positionDependencies,floating:s}),Js(()=>{var o;(o=e.onPositionChange)==null||o.call(e,s.placement)},[s.placement]),{floating:s,controlled:typeof e.opened=="boolean",opened:t,onClose:r,onToggle:i}}const LX={context:"Popover component was not found in the tree",children:"Popover.Target component children should be an element or a component that accepts ref, fragments, strings, numbers and other primitive values are not supported"},[TSe,MX]=N_(LX.context);var ISe=Object.defineProperty,xSe=Object.defineProperties,CSe=Object.getOwnPropertyDescriptors,sS=Object.getOwnPropertySymbols,FX=Object.prototype.hasOwnProperty,BX=Object.prototype.propertyIsEnumerable,b9=(e,t,n)=>t in e?ISe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,cb=(e,t)=>{for(var n in t||(t={}))FX.call(t,n)&&b9(e,n,t[n]);if(sS)for(var n of sS(t))BX.call(t,n)&&b9(e,n,t[n]);return e},ASe=(e,t)=>xSe(e,CSe(t)),PSe=(e,t)=>{var n={};for(var r in e)FX.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&sS)for(var r of sS(e))t.indexOf(r)<0&&BX.call(e,r)&&(n[r]=e[r]);return n};const OSe={refProp:"ref",popupType:"dialog"},jX=w.forwardRef((e,t)=>{const n=Ve("PopoverTarget",OSe,e),{children:r,refProp:i,popupType:s}=n,o=PSe(n,["children","refProp","popupType"]);if(!_g(r))throw new Error(LX.children);const a=o,u=MX(),l=fa(u.reference,r.ref,t),c=u.withRoles?{"aria-haspopup":s,"aria-expanded":u.opened,"aria-controls":u.getDropdownId(),id:u.getTargetId()}:{};return w.cloneElement(r,cb(ASe(cb(cb(cb({},a),c),u.targetProps),{className:cK(u.targetProps.className,a.className,r.props.className),[i]:l}),u.controlled?null:{onClick:u.onToggle}))});jX.displayName="@mantine/core/PopoverTarget";var RSe=lt((e,{radius:t,shadow:n})=>({dropdown:{position:"absolute",backgroundColor:e.white,background:e.colorScheme==="dark"?e.colors.dark[6]:e.white,border:`1px solid ${e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[2]}`,padding:`${e.spacing.sm}px ${e.spacing.md}px`,boxShadow:e.shadows[n]||n||"none",borderRadius:e.fn.radius(t),"&:focus":{outline:0}},arrow:{backgroundColor:"inherit",border:`1px solid ${e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[2]}`,zIndex:1}}));const NSe=RSe;var kSe=Object.defineProperty,w9=Object.getOwnPropertySymbols,DSe=Object.prototype.hasOwnProperty,$Se=Object.prototype.propertyIsEnumerable,E9=(e,t,n)=>t in e?kSe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Xh=(e,t)=>{for(var n in t||(t={}))DSe.call(t,n)&&E9(e,n,t[n]);if(w9)for(var n of w9(t))$Se.call(t,n)&&E9(e,n,t[n]);return e};const S9={entering:"in",entered:"in",exiting:"out",exited:"out","pre-exiting":"out","pre-entering":"out"};function UX({transition:e,state:t,duration:n,timingFunction:r}){const i={transitionDuration:`${n}ms`,transitionTimingFunction:r};return typeof e=="string"?e in nb?Xh(Xh(Xh({transitionProperty:nb[e].transitionProperty},i),nb[e].common),nb[e][S9[t]]):null:Xh(Xh(Xh({transitionProperty:e.transitionProperty},i),e.common),e[S9[t]])}function VX({duration:e,exitDuration:t,timingFunction:n,mounted:r,onEnter:i,onExit:s,onEntered:o,onExited:a}){const u=ji(),l=Rx(),c=u.respectReducedMotion?l:!1,[f,d]=w.useState(r?"entered":"exited");let h=c?0:e;const p=w.useRef(-1),m=y=>{const g=y?i:s,v=y?o:a;if(d(y?"pre-entering":"pre-exiting"),window.clearTimeout(p.current),h=c?0:y?e:t,h===0)typeof g=="function"&&g(),typeof v=="function"&&v(),d(y?"entered":"exited");else{const b=window.setTimeout(()=>{typeof g=="function"&&g(),d(y?"entering":"exiting")},10);p.current=window.setTimeout(()=>{window.clearTimeout(b),typeof v=="function"&&v(),d(y?"entered":"exited")},h)}};return Js(()=>{m(r)},[r]),w.useEffect(()=>()=>window.clearTimeout(p.current),[]),{transitionDuration:h,transitionStatus:f,transitionTimingFunction:n||u.transitionTimingFunction}}function Vx({transition:e,duration:t=250,exitDuration:n=t,mounted:r,children:i,timingFunction:s,onExit:o,onEntered:a,onEnter:u,onExited:l}){const{transitionDuration:c,transitionStatus:f,transitionTimingFunction:d}=VX({mounted:r,exitDuration:n,duration:t,timingFunction:s,onExit:o,onEntered:a,onEnter:u,onExited:l});return c===0?r?N.createElement(N.Fragment,null,i({})):null:f==="exited"?null:N.createElement(N.Fragment,null,i(UX({transition:e,duration:c,state:f,timingFunction:d})))}Vx.displayName="@mantine/core/Transition";function zX({children:e,active:t=!0,refProp:n="ref"}){const r=jK(t),i=fa(r,e==null?void 0:e.ref);return _g(e)?w.cloneElement(e,{[n]:i}):e}zX.displayName="@mantine/core/FocusTrap";var LSe=Object.defineProperty,MSe=Object.defineProperties,FSe=Object.getOwnPropertyDescriptors,T9=Object.getOwnPropertySymbols,BSe=Object.prototype.hasOwnProperty,jSe=Object.prototype.propertyIsEnumerable,I9=(e,t,n)=>t in e?LSe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,bc=(e,t)=>{for(var n in t||(t={}))BSe.call(t,n)&&I9(e,n,t[n]);if(T9)for(var n of T9(t))jSe.call(t,n)&&I9(e,n,t[n]);return e},fb=(e,t)=>MSe(e,FSe(t));function x9(e,t,n,r){return e==="center"||r==="center"?{top:t}:e==="end"?{bottom:n}:e==="start"?{top:n}:{}}function C9(e,t,n,r,i){return e==="center"||r==="center"?{left:t}:e==="end"?{[i==="ltr"?"right":"left"]:n}:e==="start"?{[i==="ltr"?"left":"right"]:n}:{}}const USe={bottom:"borderTopLeftRadius",left:"borderTopRightRadius",right:"borderBottomLeftRadius",top:"borderBottomRightRadius"};function VSe({position:e,withBorder:t,arrowSize:n,arrowOffset:r,arrowRadius:i,arrowPosition:s,arrowX:o,arrowY:a,dir:u}){const[l,c="center"]=e.split("-"),f={width:n,height:n,transform:"rotate(45deg)",position:"absolute",[USe[l]]:i},d=t?-n/2-1:-n/2;return l==="left"?fb(bc(bc({},f),x9(c,a,r,s)),{right:d,borderLeft:0,borderBottom:0}):l==="right"?fb(bc(bc({},f),x9(c,a,r,s)),{left:d,borderRight:0,borderTop:0}):l==="top"?fb(bc(bc({},f),C9(c,o,r,s,u)),{bottom:d,borderTop:0,borderLeft:0}):l==="bottom"?fb(bc(bc({},f),C9(c,o,r,s,u)),{top:d,borderBottom:0,borderRight:0}):{}}var zSe=Object.defineProperty,HSe=Object.defineProperties,WSe=Object.getOwnPropertyDescriptors,oS=Object.getOwnPropertySymbols,HX=Object.prototype.hasOwnProperty,WX=Object.prototype.propertyIsEnumerable,A9=(e,t,n)=>t in e?zSe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,qSe=(e,t)=>{for(var n in t||(t={}))HX.call(t,n)&&A9(e,n,t[n]);if(oS)for(var n of oS(t))WX.call(t,n)&&A9(e,n,t[n]);return e},GSe=(e,t)=>HSe(e,WSe(t)),YSe=(e,t)=>{var n={};for(var r in e)HX.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&oS)for(var r of oS(e))t.indexOf(r)<0&&WX.call(e,r)&&(n[r]=e[r]);return n};const W$=w.forwardRef((e,t)=>{var n=e,{withBorder:r,position:i,arrowSize:s,arrowOffset:o,arrowRadius:a,arrowPosition:u,visible:l,arrowX:c,arrowY:f}=n,d=YSe(n,["withBorder","position","arrowSize","arrowOffset","arrowRadius","arrowPosition","visible","arrowX","arrowY"]);const h=ji();return l?N.createElement("div",GSe(qSe({},d),{ref:t,style:VSe({withBorder:r,position:i,arrowSize:s,arrowOffset:o,arrowRadius:a,arrowPosition:u,dir:h.dir,arrowX:c,arrowY:f})})):null});W$.displayName="@mantine/core/FloatingArrow";var KSe=Object.defineProperty,QSe=Object.defineProperties,XSe=Object.getOwnPropertyDescriptors,aS=Object.getOwnPropertySymbols,qX=Object.prototype.hasOwnProperty,GX=Object.prototype.propertyIsEnumerable,P9=(e,t,n)=>t in e?KSe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,db=(e,t)=>{for(var n in t||(t={}))qX.call(t,n)&&P9(e,n,t[n]);if(aS)for(var n of aS(t))GX.call(t,n)&&P9(e,n,t[n]);return e},O9=(e,t)=>QSe(e,XSe(t)),JSe=(e,t)=>{var n={};for(var r in e)qX.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&aS)for(var r of aS(e))t.indexOf(r)<0&&GX.call(e,r)&&(n[r]=e[r]);return n};const ZSe={};function YX(e){const t=Ve("PopoverDropdown",ZSe,e),{style:n,className:r,children:i,onKeyDownCapture:s}=t,o=JSe(t,["style","className","children","onKeyDownCapture"]),a=MX(),{classes:u,cx:l}=NSe({radius:a.radius,shadow:a.shadow},{name:a.__staticSelector,classNames:a.classNames,styles:a.styles,unstyled:a.unstyled}),c=LK({opened:a.opened,shouldReturnFocus:a.returnFocus}),f=a.withRoles?{"aria-labelledby":a.getTargetId(),id:a.getDropdownId(),role:"dialog"}:{};return a.disabled?null:N.createElement($_,{withinPortal:a.withinPortal},N.createElement(Vx,{mounted:a.opened,transition:a.transition,duration:a.transitionDuration,exitDuration:typeof a.exitTransitionDuration=="number"?a.exitTransitionDuration:a.transitionDuration},d=>{var h,p;return N.createElement(zX,{active:a.trapFocus},N.createElement(it,db(O9(db({},f),{tabIndex:-1,key:a.placement,ref:a.floating,style:O9(db(db({},n),d),{zIndex:a.zIndex,top:(h=a.y)!=null?h:0,left:(p=a.x)!=null?p:0,width:a.width==="target"?void 0:a.width}),className:l(u.dropdown,r),onKeyDownCapture:T0e(a.onClose,{active:a.closeOnEscape,onTrigger:c,onKeyDown:s}),"data-position":a.placement}),o),i,N.createElement(W$,{ref:a.arrowRef,arrowX:a.arrowX,arrowY:a.arrowY,visible:a.withArrow,withBorder:!0,position:a.placement,arrowSize:a.arrowSize,arrowRadius:a.arrowRadius,arrowOffset:a.arrowOffset,arrowPosition:a.arrowPosition,className:u.arrow})))}))}YX.displayName="@mantine/core/PopoverDropdown";function KX(e,t){if(e==="rtl"&&(t.includes("right")||t.includes("left"))){const[n,r]=t.split("-"),i=n==="right"?"left":"right";return r===void 0?i:`${i}-${r}`}return t}var R9=Object.getOwnPropertySymbols,eTe=Object.prototype.hasOwnProperty,tTe=Object.prototype.propertyIsEnumerable,nTe=(e,t)=>{var n={};for(var r in e)eTe.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&R9)for(var r of R9(e))t.indexOf(r)<0&&tTe.call(e,r)&&(n[r]=e[r]);return n};const rTe={position:"bottom",offset:8,positionDependencies:[],transition:"fade",transitionDuration:150,middlewares:{flip:!0,shift:!0,inline:!1},arrowSize:7,arrowOffset:5,arrowRadius:0,arrowPosition:"side",closeOnClickOutside:!0,withinPortal:!1,closeOnEscape:!0,trapFocus:!1,withRoles:!0,returnFocus:!1,clickOutsideEvents:["mousedown","touchstart"],zIndex:cc("popover"),__staticSelector:"Popover",width:"max-content"};function yi(e){var t,n,r,i,s,o;const a=w.useRef(null),u=Ve("Popover",rTe,e),{children:l,position:c,offset:f,onPositionChange:d,positionDependencies:h,opened:p,transition:m,transitionDuration:y,width:g,middlewares:v,withArrow:b,arrowSize:S,arrowOffset:T,arrowRadius:E,arrowPosition:I,unstyled:A,classNames:R,styles:F,closeOnClickOutside:L,withinPortal:B,closeOnEscape:J,clickOutsideEvents:V,trapFocus:re,onClose:oe,onOpen:ae,onChange:ee,zIndex:ue,radius:P,shadow:W,id:Q,defaultOpened:x,exitTransitionDuration:O,__staticSelector:$,withRoles:q,disabled:ce,returnFocus:fe}=u,de=nTe(u,["children","position","offset","onPositionChange","positionDependencies","opened","transition","transitionDuration","width","middlewares","withArrow","arrowSize","arrowOffset","arrowRadius","arrowPosition","unstyled","classNames","styles","closeOnClickOutside","withinPortal","closeOnEscape","clickOutsideEvents","trapFocus","onClose","onOpen","onChange","zIndex","radius","shadow","id","defaultOpened","exitTransitionDuration","__staticSelector","withRoles","disabled","returnFocus"]),[ve,Ee]=w.useState(null),[ge,nt]=w.useState(null),Je=tu(Q),yt=ji(),ke=SSe({middlewares:v,width:g,position:KX(yt.dir,c),offset:f+(b?S/2:0),arrowRef:a,arrowOffset:T,onPositionChange:d,positionDependencies:h,opened:p,defaultOpened:x,onChange:ee,onOpen:ae,onClose:oe});Tve(()=>L&&ke.onClose(),V,[ve,ge]);const at=w.useCallback(cn=>{Ee(cn),ke.floating.reference(cn)},[ke.floating.reference]),St=w.useCallback(cn=>{nt(cn),ke.floating.floating(cn)},[ke.floating.floating]);return N.createElement(TSe,{value:{returnFocus:fe,disabled:ce,controlled:ke.controlled,reference:at,floating:St,x:ke.floating.x,y:ke.floating.y,arrowX:(r=(n=(t=ke.floating)==null?void 0:t.middlewareData)==null?void 0:n.arrow)==null?void 0:r.x,arrowY:(o=(s=(i=ke.floating)==null?void 0:i.middlewareData)==null?void 0:s.arrow)==null?void 0:o.y,opened:ke.opened,arrowRef:a,transition:m,transitionDuration:y,exitTransitionDuration:O,width:g,withArrow:b,arrowSize:S,arrowOffset:T,arrowRadius:E,arrowPosition:I,placement:ke.floating.placement,trapFocus:re,withinPortal:B,zIndex:ue,radius:P,shadow:W,closeOnEscape:J,onClose:ke.onClose,onToggle:ke.onToggle,getTargetId:()=>`${Je}-target`,getDropdownId:()=>`${Je}-dropdown`,withRoles:q,targetProps:de,__staticSelector:$,classNames:R,styles:F,unstyled:A}},l)}yi.Target=jX;yi.Dropdown=YX;yi.displayName="@mantine/core/Popover";var iTe=Object.defineProperty,uS=Object.getOwnPropertySymbols,QX=Object.prototype.hasOwnProperty,XX=Object.prototype.propertyIsEnumerable,N9=(e,t,n)=>t in e?iTe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,sTe=(e,t)=>{for(var n in t||(t={}))QX.call(t,n)&&N9(e,n,t[n]);if(uS)for(var n of uS(t))XX.call(t,n)&&N9(e,n,t[n]);return e},oTe=(e,t)=>{var n={};for(var r in e)QX.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&uS)for(var r of uS(e))t.indexOf(r)<0&&XX.call(e,r)&&(n[r]=e[r]);return n};function aTe(e){var t=e,{children:n,component:r="div",maxHeight:i=220,direction:s="column",id:o,innerRef:a,__staticSelector:u,styles:l,classNames:c,unstyled:f}=t,d=oTe(t,["children","component","maxHeight","direction","id","innerRef","__staticSelector","styles","classNames","unstyled"]);const{classes:h}=fEe(null,{name:u,styles:l,classNames:c,unstyled:f});return N.createElement(yi.Dropdown,sTe({p:0,onMouseDown:p=>p.preventDefault()},d),N.createElement("div",{style:{maxHeight:i,display:"flex"}},N.createElement(it,{component:r||"div",id:`${o}-items`,"aria-labelledby":`${o}-label`,role:"listbox",onMouseDown:p=>p.preventDefault(),style:{flex:1,overflowY:r!==Bx?"auto":void 0},"data-combobox-popover":!0,ref:a},N.createElement("div",{className:h.itemsWrapper,style:{flexDirection:s}},n))))}function hf({opened:e,transition:t="fade",transitionDuration:n=0,shadow:r,withinPortal:i,children:s,__staticSelector:o,onDirectionChange:a,switchDirectionOnFlip:u,zIndex:l,dropdownPosition:c,positionDependencies:f=[],classNames:d,styles:h,unstyled:p,readOnly:m}){return N.createElement(yi,{unstyled:p,classNames:d,styles:h,width:"target",withRoles:!1,opened:e,middlewares:{flip:c==="flip",shift:!1},position:c==="flip"?"bottom":c,positionDependencies:f,zIndex:l,__staticSelector:o,withinPortal:i,transition:t,transitionDuration:n,shadow:r,disabled:m,onPositionChange:y=>u&&(a==null?void 0:a(y==="top"?"column-reverse":"column"))},s)}hf.Target=yi.Target;hf.Dropdown=aTe;var uTe=Object.defineProperty,lTe=Object.defineProperties,cTe=Object.getOwnPropertyDescriptors,lS=Object.getOwnPropertySymbols,JX=Object.prototype.hasOwnProperty,ZX=Object.prototype.propertyIsEnumerable,k9=(e,t,n)=>t in e?uTe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,hb=(e,t)=>{for(var n in t||(t={}))JX.call(t,n)&&k9(e,n,t[n]);if(lS)for(var n of lS(t))ZX.call(t,n)&&k9(e,n,t[n]);return e},fTe=(e,t)=>lTe(e,cTe(t)),dTe=(e,t)=>{var n={};for(var r in e)JX.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&lS)for(var r of lS(e))t.indexOf(r)<0&&ZX.call(e,r)&&(n[r]=e[r]);return n};function eJ(e,t,n){const r=Ve(e,t,n),{label:i,description:s,error:o,required:a,classNames:u,styles:l,className:c,unstyled:f,__staticSelector:d,sx:h,errorProps:p,labelProps:m,descriptionProps:y,wrapperProps:g,id:v,size:b,style:S,inputContainer:T,inputWrapperOrder:E,withAsterisk:I}=r,A=dTe(r,["label","description","error","required","classNames","styles","className","unstyled","__staticSelector","sx","errorProps","labelProps","descriptionProps","wrapperProps","id","size","style","inputContainer","inputWrapperOrder","withAsterisk"]),R=tu(v),{systemStyles:F,rest:L}=Qf(A),B=hb({label:i,description:s,error:o,required:a,classNames:u,className:c,__staticSelector:d,sx:h,errorProps:p,labelProps:m,descriptionProps:y,unstyled:f,styles:l,id:R,size:b,style:S,inputContainer:T,inputWrapperOrder:E,withAsterisk:I},g);return fTe(hb({},L),{classNames:u,styles:l,unstyled:f,wrapperProps:hb(hb({},B),F),inputProps:{required:a,classNames:u,styles:l,unstyled:f,id:R,size:b,__staticSelector:d,invalid:!!o}})}var hTe=lt((e,{size:t})=>({label:{display:"inline-block",fontSize:e.fn.size({size:t,sizes:e.fontSizes}),fontWeight:500,color:e.colorScheme==="dark"?e.colors.dark[0]:e.colors.gray[9],wordBreak:"break-word",cursor:"default",WebkitTapHighlightColor:"transparent"},required:{color:e.fn.variant({variant:"filled",color:"red"}).background}})),pTe=Object.defineProperty,cS=Object.getOwnPropertySymbols,tJ=Object.prototype.hasOwnProperty,nJ=Object.prototype.propertyIsEnumerable,D9=(e,t,n)=>t in e?pTe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,mTe=(e,t)=>{for(var n in t||(t={}))tJ.call(t,n)&&D9(e,n,t[n]);if(cS)for(var n of cS(t))nJ.call(t,n)&&D9(e,n,t[n]);return e},gTe=(e,t)=>{var n={};for(var r in e)tJ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&cS)for(var r of cS(e))t.indexOf(r)<0&&nJ.call(e,r)&&(n[r]=e[r]);return n};const yTe={labelElement:"label",size:"sm"},q$=w.forwardRef((e,t)=>{const n=Ve("InputLabel",yTe,e),{labelElement:r,children:i,required:s,size:o,classNames:a,styles:u,unstyled:l,className:c,htmlFor:f,__staticSelector:d}=n,h=gTe(n,["labelElement","children","required","size","classNames","styles","unstyled","className","htmlFor","__staticSelector"]),{classes:p,cx:m}=hTe({size:o},{name:["InputWrapper",d],classNames:a,styles:u,unstyled:l});return N.createElement(it,mTe({component:r,ref:t,className:m(p.label,c),htmlFor:r==="label"?f:void 0},h),i,s&&N.createElement("span",{className:p.required,"aria-hidden":!0}," *"))});q$.displayName="@mantine/core/InputLabel";var vTe=lt((e,{size:t})=>({error:{wordBreak:"break-word",color:e.fn.variant({variant:"filled",color:"red"}).background,fontSize:e.fn.size({size:t,sizes:e.fontSizes})-2,lineHeight:1.2,display:"block"}})),_Te=Object.defineProperty,fS=Object.getOwnPropertySymbols,rJ=Object.prototype.hasOwnProperty,iJ=Object.prototype.propertyIsEnumerable,$9=(e,t,n)=>t in e?_Te(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,bTe=(e,t)=>{for(var n in t||(t={}))rJ.call(t,n)&&$9(e,n,t[n]);if(fS)for(var n of fS(t))iJ.call(t,n)&&$9(e,n,t[n]);return e},wTe=(e,t)=>{var n={};for(var r in e)rJ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&fS)for(var r of fS(e))t.indexOf(r)<0&&iJ.call(e,r)&&(n[r]=e[r]);return n};const ETe={size:"sm"},G$=w.forwardRef((e,t)=>{const n=Ve("InputError",ETe,e),{children:r,className:i,classNames:s,styles:o,unstyled:a,size:u,__staticSelector:l}=n,c=wTe(n,["children","className","classNames","styles","unstyled","size","__staticSelector"]),{classes:f,cx:d}=vTe({size:u},{name:["InputWrapper",l],classNames:s,styles:o,unstyled:a});return N.createElement(rt,bTe({className:d(f.error,i),ref:t},c),r)});G$.displayName="@mantine/core/InputError";var STe=lt((e,{size:t})=>({description:{wordBreak:"break-word",color:e.colorScheme==="dark"?e.colors.dark[2]:e.colors.gray[6],fontSize:e.fn.size({size:t,sizes:e.fontSizes})-2,lineHeight:1.2,display:"block"}})),TTe=Object.defineProperty,dS=Object.getOwnPropertySymbols,sJ=Object.prototype.hasOwnProperty,oJ=Object.prototype.propertyIsEnumerable,L9=(e,t,n)=>t in e?TTe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ITe=(e,t)=>{for(var n in t||(t={}))sJ.call(t,n)&&L9(e,n,t[n]);if(dS)for(var n of dS(t))oJ.call(t,n)&&L9(e,n,t[n]);return e},xTe=(e,t)=>{var n={};for(var r in e)sJ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&dS)for(var r of dS(e))t.indexOf(r)<0&&oJ.call(e,r)&&(n[r]=e[r]);return n};const CTe={size:"sm"},Y$=w.forwardRef((e,t)=>{const n=Ve("InputDescription",CTe,e),{children:r,className:i,classNames:s,styles:o,unstyled:a,size:u,__staticSelector:l}=n,c=xTe(n,["children","className","classNames","styles","unstyled","size","__staticSelector"]),{classes:f,cx:d}=STe({size:u},{name:["InputWrapper",l],classNames:s,styles:o,unstyled:a});return N.createElement(rt,ITe({color:"dimmed",className:d(f.description,i),ref:t,unstyled:a},c),r)});Y$.displayName="@mantine/core/InputDescription";const aJ=w.createContext({offsetBottom:!1,offsetTop:!1,describedBy:void 0}),ATe=aJ.Provider,PTe=()=>w.useContext(aJ);function OTe(e,{hasDescription:t,hasError:n}){const r=e.findIndex(u=>u==="input"),i=e[r-1],s=e[r+1];return{offsetBottom:t&&s==="description"||n&&s==="error",offsetTop:t&&i==="description"||n&&i==="error"}}var RTe=Object.defineProperty,NTe=Object.defineProperties,kTe=Object.getOwnPropertyDescriptors,M9=Object.getOwnPropertySymbols,DTe=Object.prototype.hasOwnProperty,$Te=Object.prototype.propertyIsEnumerable,F9=(e,t,n)=>t in e?RTe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,LTe=(e,t)=>{for(var n in t||(t={}))DTe.call(t,n)&&F9(e,n,t[n]);if(M9)for(var n of M9(t))$Te.call(t,n)&&F9(e,n,t[n]);return e},MTe=(e,t)=>NTe(e,kTe(t)),FTe=lt(e=>({root:MTe(LTe({},e.fn.fontStyles()),{lineHeight:e.lineHeight})})),BTe=Object.defineProperty,jTe=Object.defineProperties,UTe=Object.getOwnPropertyDescriptors,hS=Object.getOwnPropertySymbols,uJ=Object.prototype.hasOwnProperty,lJ=Object.prototype.propertyIsEnumerable,B9=(e,t,n)=>t in e?BTe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,wc=(e,t)=>{for(var n in t||(t={}))uJ.call(t,n)&&B9(e,n,t[n]);if(hS)for(var n of hS(t))lJ.call(t,n)&&B9(e,n,t[n]);return e},j9=(e,t)=>jTe(e,UTe(t)),VTe=(e,t)=>{var n={};for(var r in e)uJ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&hS)for(var r of hS(e))t.indexOf(r)<0&&lJ.call(e,r)&&(n[r]=e[r]);return n};const zTe={labelElement:"label",size:"sm",inputContainer:e=>e,inputWrapperOrder:["label","description","input","error"]},cJ=w.forwardRef((e,t)=>{const n=Ve("InputWrapper",zTe,e),{className:r,label:i,children:s,required:o,id:a,error:u,description:l,labelElement:c,labelProps:f,descriptionProps:d,errorProps:h,classNames:p,styles:m,size:y,inputContainer:g,__staticSelector:v,unstyled:b,inputWrapperOrder:S,withAsterisk:T}=n,E=VTe(n,["className","label","children","required","id","error","description","labelElement","labelProps","descriptionProps","errorProps","classNames","styles","size","inputContainer","__staticSelector","unstyled","inputWrapperOrder","withAsterisk"]),{classes:I,cx:A}=FTe(null,{classNames:p,styles:m,name:["InputWrapper",v],unstyled:b}),R={classNames:p,styles:m,unstyled:b,size:y,__staticSelector:v},F=typeof T=="boolean"?T:o,L=a?`${a}-error`:h==null?void 0:h.id,B=a?`${a}-description`:d==null?void 0:d.id,V=`${!!u&&typeof u!="boolean"?L:""} ${l?B:""}`,re=V.trim().length>0?V.trim():void 0,oe=i&&N.createElement(q$,wc(wc({key:"label",labelElement:c,id:a?`${a}-label`:void 0,htmlFor:a,required:F},R),f),i),ae=l&&N.createElement(Y$,j9(wc(wc({key:"description"},d),R),{size:(d==null?void 0:d.size)||R.size,id:(d==null?void 0:d.id)||B}),l),ee=N.createElement(w.Fragment,{key:"input"},g(s)),ue=typeof u!="boolean"&&u&&N.createElement(G$,j9(wc(wc({},h),R),{size:(h==null?void 0:h.size)||R.size,key:"error",id:(h==null?void 0:h.id)||L}),u),P=S.map(W=>{switch(W){case"label":return oe;case"input":return ee;case"description":return ae;case"error":return ue;default:return null}});return N.createElement(ATe,{value:wc({describedBy:re},OTe(S,{hasDescription:!!ae,hasError:!!ue}))},N.createElement(it,wc({className:A(I.root,r),ref:t},E),P))});cJ.displayName="@mantine/core/InputWrapper";var HTe=Object.defineProperty,pS=Object.getOwnPropertySymbols,fJ=Object.prototype.hasOwnProperty,dJ=Object.prototype.propertyIsEnumerable,U9=(e,t,n)=>t in e?HTe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,WTe=(e,t)=>{for(var n in t||(t={}))fJ.call(t,n)&&U9(e,n,t[n]);if(pS)for(var n of pS(t))dJ.call(t,n)&&U9(e,n,t[n]);return e},qTe=(e,t)=>{var n={};for(var r in e)fJ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&pS)for(var r of pS(e))t.indexOf(r)<0&&dJ.call(e,r)&&(n[r]=e[r]);return n};const GTe={},hJ=w.forwardRef((e,t)=>{const n=Ve("InputPlaceholder",GTe,e),{sx:r}=n,i=qTe(n,["sx"]);return N.createElement(it,WTe({component:"span",sx:[s=>s.fn.placeholderStyles(),...lh(r)],ref:t},i))});hJ.displayName="@mantine/core/InputPlaceholder";var YTe=Object.defineProperty,KTe=Object.defineProperties,QTe=Object.getOwnPropertyDescriptors,V9=Object.getOwnPropertySymbols,XTe=Object.prototype.hasOwnProperty,JTe=Object.prototype.propertyIsEnumerable,z9=(e,t,n)=>t in e?YTe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,pb=(e,t)=>{for(var n in t||(t={}))XTe.call(t,n)&&z9(e,n,t[n]);if(V9)for(var n of V9(t))JTe.call(t,n)&&z9(e,n,t[n]);return e},FP=(e,t)=>KTe(e,QTe(t));const $s={xs:30,sm:36,md:42,lg:50,xl:60};function ZTe({theme:e,variant:t}){return t==="default"?{border:`1px solid ${e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[4]}`,backgroundColor:e.colorScheme==="dark"?e.colors.dark[6]:e.white,transition:"border-color 100ms ease","&:focus, &:focus-within":e.focusRingStyles.inputStyles(e)}:t==="filled"?{border:"1px solid transparent",backgroundColor:e.colorScheme==="dark"?e.colors.dark[5]:e.colors.gray[1],"&:focus, &:focus-within":e.focusRingStyles.inputStyles(e)}:{borderWidth:0,color:e.colorScheme==="dark"?e.colors.dark[0]:e.black,backgroundColor:"transparent",minHeight:28,outline:0,"&:focus, &:focus-within":{outline:"none",borderColor:"transparent"},"&:disabled":{backgroundColor:"transparent","&:focus, &:focus-within":{outline:"none",borderColor:"transparent"}}}}var eIe=lt((e,{size:t,multiline:n,radius:r,variant:i,invalid:s,rightSectionWidth:o,withRightSection:a,iconWidth:u,offsetBottom:l,offsetTop:c,pointer:f})=>{const d=e.fn.variant({variant:"filled",color:"red"}).background,h=i==="default"||i==="filled"?{minHeight:e.fn.size({size:t,sizes:$s}),paddingLeft:e.fn.size({size:t,sizes:$s})/3,paddingRight:a?o:e.fn.size({size:t,sizes:$s})/3,borderRadius:e.fn.radius(r)}:null;return{wrapper:{position:"relative",marginTop:c?`calc(${e.spacing.xs}px / 2)`:void 0,marginBottom:l?`calc(${e.spacing.xs}px / 2)`:void 0},input:pb(FP(pb(FP(pb({},e.fn.fontStyles()),{height:n?i==="unstyled"?void 0:"auto":e.fn.size({size:t,sizes:$s}),WebkitTapHighlightColor:"transparent",lineHeight:n?e.lineHeight:`${e.fn.size({size:t,sizes:$s})-2}px`,appearance:"none",resize:"none",boxSizing:"border-box",fontSize:e.fn.size({size:t,sizes:e.fontSizes}),width:"100%",color:e.colorScheme==="dark"?e.colors.dark[0]:e.black,display:"block",textAlign:"left",cursor:f?"pointer":void 0}),h),{"&:disabled":{backgroundColor:e.colorScheme==="dark"?e.colors.dark[6]:e.colors.gray[1],color:e.colors.dark[2],opacity:.6,cursor:"not-allowed","&::placeholder":{color:e.colors.dark[2]}},"&::placeholder":FP(pb({},e.fn.placeholderStyles()),{opacity:1}),"&::-webkit-inner-spin-button, &::-webkit-outer-spin-button, &::-webkit-search-decoration, &::-webkit-search-cancel-button, &::-webkit-search-results-button, &::-webkit-search-results-decoration":{appearance:"none"},"&[type=number]":{MozAppearance:"textfield"}}),ZTe({theme:e,variant:i})),withIcon:{paddingLeft:typeof u=="number"?u:e.fn.size({size:t,sizes:$s})},invalid:{color:d,borderColor:d,"&::placeholder":{opacity:1,color:d}},disabled:{backgroundColor:e.colorScheme==="dark"?e.colors.dark[6]:e.colors.gray[1],color:e.colors.dark[2],opacity:.6,cursor:"not-allowed","&::placeholder":{color:e.colors.dark[2]}},icon:{pointerEvents:"none",position:"absolute",zIndex:1,left:0,top:0,bottom:0,display:"flex",alignItems:"center",justifyContent:"center",width:typeof u=="number"?u:e.fn.size({size:t,sizes:$s}),color:s?e.colors.red[e.colorScheme==="dark"?6:7]:e.colorScheme==="dark"?e.colors.dark[2]:e.colors.gray[5]},rightSection:{position:"absolute",top:0,bottom:0,right:0,display:"flex",alignItems:"center",justifyContent:"center",width:o}}}),tIe=Object.defineProperty,nIe=Object.defineProperties,rIe=Object.getOwnPropertyDescriptors,mS=Object.getOwnPropertySymbols,pJ=Object.prototype.hasOwnProperty,mJ=Object.prototype.propertyIsEnumerable,H9=(e,t,n)=>t in e?tIe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,mb=(e,t)=>{for(var n in t||(t={}))pJ.call(t,n)&&H9(e,n,t[n]);if(mS)for(var n of mS(t))mJ.call(t,n)&&H9(e,n,t[n]);return e},W9=(e,t)=>nIe(e,rIe(t)),iIe=(e,t)=>{var n={};for(var r in e)pJ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&mS)for(var r of mS(e))t.indexOf(r)<0&&mJ.call(e,r)&&(n[r]=e[r]);return n};const sIe={rightSectionWidth:36,size:"sm",variant:"default"},$h=w.forwardRef((e,t)=>{const n=Ve("Input",sIe,e),{className:r,invalid:i,required:s,disabled:o,variant:a,icon:u,style:l,rightSectionWidth:c,iconWidth:f,rightSection:d,rightSectionProps:h,radius:p,size:m,wrapperProps:y,classNames:g,styles:v,__staticSelector:b,multiline:S,sx:T,unstyled:E,pointer:I}=n,A=iIe(n,["className","invalid","required","disabled","variant","icon","style","rightSectionWidth","iconWidth","rightSection","rightSectionProps","radius","size","wrapperProps","classNames","styles","__staticSelector","multiline","sx","unstyled","pointer"]),{offsetBottom:R,offsetTop:F,describedBy:L}=PTe(),{classes:B,cx:J}=eIe({radius:p,size:m,multiline:S,variant:a,invalid:i,rightSectionWidth:c,iconWidth:f,withRightSection:!!d,offsetBottom:R,offsetTop:F,pointer:I},{classNames:g,styles:v,name:["Input",b],unstyled:E}),{systemStyles:V,rest:re}=Qf(A);return N.createElement(it,mb(mb({className:J(B.wrapper,r),sx:T,style:l},V),y),u&&N.createElement("div",{className:B.icon},u),N.createElement(it,W9(mb({component:"input"},re),{ref:t,required:s,"aria-invalid":i,"aria-describedby":L,disabled:o,className:J(B[`${a}Variant`],B.input,{[B.withIcon]:u,[B.invalid]:i,[B.disabled]:o})})),d&&N.createElement("div",W9(mb({},h),{className:B.rightSection}),d))});$h.displayName="@mantine/core/Input";$h.Wrapper=cJ;$h.Label=q$;$h.Description=Y$;$h.Error=G$;$h.Placeholder=hJ;const Zs=$h;var oIe=Object.defineProperty,aIe=Object.defineProperties,uIe=Object.getOwnPropertyDescriptors,q9=Object.getOwnPropertySymbols,lIe=Object.prototype.hasOwnProperty,cIe=Object.prototype.propertyIsEnumerable,G9=(e,t,n)=>t in e?oIe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,BP=(e,t)=>{for(var n in t||(t={}))lIe.call(t,n)&&G9(e,n,t[n]);if(q9)for(var n of q9(t))cIe.call(t,n)&&G9(e,n,t[n]);return e},fIe=(e,t)=>aIe(e,uIe(t));const jP={xs:{fontSize:9,height:16},sm:{fontSize:10,height:18},md:{fontSize:11,height:20},lg:{fontSize:13,height:26},xl:{fontSize:16,height:32}},dIe={xs:4,sm:4,md:6,lg:8,xl:10};function hIe({theme:e,variant:t,color:n,size:r,gradient:i}){if(t==="dot"){const o=e.fn.size({size:r,sizes:dIe});return{backgroundColor:"transparent",color:e.colorScheme==="dark"?e.colors.dark[0]:e.colors.gray[7],border:`1px solid ${e.colorScheme==="dark"?e.colors.dark[3]:e.colors.gray[3]}`,paddingLeft:e.fn.size({size:r,sizes:e.spacing})/1.5-o/2,"&::before":{content:'""',display:"block",width:o,height:o,borderRadius:o,backgroundColor:e.fn.themeColor(n,e.colorScheme==="dark"?4:e.fn.primaryShade("light"),!0),marginRight:o}}}const s=e.fn.variant({color:n,variant:t,gradient:i});return{background:s.background,color:s.color,border:`${t==="gradient"?0:1}px solid ${s.border}`}}var pIe=lt((e,{color:t,size:n,radius:r,gradient:i,fullWidth:s,variant:o})=>{const{fontSize:a,height:u}=n in jP?jP[n]:jP.md;return{leftSection:{marginRight:`calc(${e.spacing.xs}px / 2)`},rightSection:{marginLeft:`calc(${e.spacing.xs}px / 2)`},inner:{whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis"},root:BP(fIe(BP(BP({},e.fn.focusStyles()),e.fn.fontStyles()),{fontSize:a,height:u,WebkitTapHighlightColor:"transparent",lineHeight:`${u-2}px`,textDecoration:"none",padding:`0 ${e.fn.size({size:n,sizes:e.spacing})/1.5}px`,boxSizing:"border-box",display:s?"flex":"inline-flex",alignItems:"center",justifyContent:"center",width:s?"100%":"auto",textTransform:"uppercase",borderRadius:e.fn.radius(r),fontWeight:700,letterSpacing:.25,cursor:"inherit",textOverflow:"ellipsis",overflow:"hidden"}),hIe({theme:e,variant:o,color:t,size:n,gradient:i}))}}),mIe=Object.defineProperty,gS=Object.getOwnPropertySymbols,gJ=Object.prototype.hasOwnProperty,yJ=Object.prototype.propertyIsEnumerable,Y9=(e,t,n)=>t in e?mIe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,gIe=(e,t)=>{for(var n in t||(t={}))gJ.call(t,n)&&Y9(e,n,t[n]);if(gS)for(var n of gS(t))yJ.call(t,n)&&Y9(e,n,t[n]);return e},yIe=(e,t)=>{var n={};for(var r in e)gJ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&gS)for(var r of gS(e))t.indexOf(r)<0&&yJ.call(e,r)&&(n[r]=e[r]);return n};const vIe={variant:"light",size:"md",radius:"xl"},vJ=w.forwardRef((e,t)=>{const n=Ve("Badge",vIe,e),{className:r,color:i,variant:s,fullWidth:o,children:a,size:u,leftSection:l,rightSection:c,radius:f,gradient:d,classNames:h,styles:p,unstyled:m}=n,y=yIe(n,["className","color","variant","fullWidth","children","size","leftSection","rightSection","radius","gradient","classNames","styles","unstyled"]),{classes:g,cx:v}=pIe({size:u,fullWidth:o,color:i,radius:f,variant:s,gradient:d},{classNames:h,styles:p,name:"Badge",unstyled:m});return N.createElement(it,gIe({className:v(g.root,r),ref:t},y),l&&N.createElement("span",{className:g.leftSection},l),N.createElement("span",{className:g.inner},a),c&&N.createElement("span",{className:g.rightSection},c))});vJ.displayName="@mantine/core/Badge";const _Ie=vJ;var bIe=Object.defineProperty,K9=Object.getOwnPropertySymbols,wIe=Object.prototype.hasOwnProperty,EIe=Object.prototype.propertyIsEnumerable,Q9=(e,t,n)=>t in e?bIe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,SIe=(e,t)=>{for(var n in t||(t={}))wIe.call(t,n)&&Q9(e,n,t[n]);if(K9)for(var n of K9(t))EIe.call(t,n)&&Q9(e,n,t[n]);return e};function TIe(e){return N.createElement("svg",SIe({width:"20",height:"20",viewBox:"0 0 409.294 409.294",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg"},e),N.createElement("path",{d:"M0 204.647v175.412h175.412V204.647H58.471c0-64.48 52.461-116.941 116.941-116.941V29.235C78.684 29.235 0 107.919 0 204.647zM409.294 87.706V29.235c-96.728 0-175.412 78.684-175.412 175.412v175.412h175.412V204.647H292.353c0-64.48 52.461-116.941 116.941-116.941z"}))}var IIe=Object.defineProperty,xIe=Object.defineProperties,CIe=Object.getOwnPropertyDescriptors,X9=Object.getOwnPropertySymbols,AIe=Object.prototype.hasOwnProperty,PIe=Object.prototype.propertyIsEnumerable,J9=(e,t,n)=>t in e?IIe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,OIe=(e,t)=>{for(var n in t||(t={}))AIe.call(t,n)&&J9(e,n,t[n]);if(X9)for(var n of X9(t))PIe.call(t,n)&&J9(e,n,t[n]);return e},RIe=(e,t)=>xIe(e,CIe(t)),NIe=lt((e,{color:t})=>({root:RIe(OIe({},e.fn.fontStyles()),{fontSize:e.fontSizes.lg,lineHeight:e.lineHeight,color:e.colorScheme==="dark"?e.colors.dark[0]:e.black,margin:0,borderTopRightRadius:e.radius.sm,borderBottomRightRadius:e.radius.sm,padding:`${e.spacing.md}px ${e.spacing.lg}px`}),inner:{display:"flex"},body:{flex:1,overflow:"hidden",textOverflow:"ellipsis"},icon:{color:e.fn.variant({variant:"filled",color:t}).background,marginRight:e.spacing.lg,marginTop:2,width:22},cite:{display:"block",fontSize:e.fontSizes.sm,marginTop:e.spacing.xs,color:e.colorScheme==="dark"?e.colors.dark[2]:e.colors.gray[6],overflow:"hidden",textOverflow:"ellipsis"}})),kIe=Object.defineProperty,yS=Object.getOwnPropertySymbols,_J=Object.prototype.hasOwnProperty,bJ=Object.prototype.propertyIsEnumerable,Z9=(e,t,n)=>t in e?kIe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,DIe=(e,t)=>{for(var n in t||(t={}))_J.call(t,n)&&Z9(e,n,t[n]);if(yS)for(var n of yS(t))bJ.call(t,n)&&Z9(e,n,t[n]);return e},$Ie=(e,t)=>{var n={};for(var r in e)_J.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&yS)for(var r of yS(e))t.indexOf(r)<0&&bJ.call(e,r)&&(n[r]=e[r]);return n};const LIe={color:"gray",icon:N.createElement(TIe,null)},wJ=w.forwardRef((e,t)=>{const n=Ve("Blockquote",LIe,e),{className:r,color:i,icon:s,cite:o,children:a,classNames:u,styles:l,unstyled:c}=n,f=$Ie(n,["className","color","icon","cite","children","classNames","styles","unstyled"]),{classes:d,cx:h}=NIe({color:i},{classNames:u,styles:l,unstyled:c,name:"Blockquote"});return N.createElement(it,DIe({component:"blockquote",className:h(d.root,r),ref:t},f),N.createElement("div",{className:d.inner},s&&N.createElement("div",{className:d.icon},s),N.createElement("div",{className:d.body},a,o&&N.createElement("cite",{className:d.cite},o))))});wJ.displayName="@mantine/core/Blockquote";var MIe=lt((e,{orientation:t,buttonBorderWidth:n})=>({root:{display:"flex",flexDirection:t==="vertical"?"column":"row","& [data-button]":{"&:first-of-type":{borderBottomRightRadius:0,[t==="vertical"?"borderBottomLeftRadius":"borderTopRightRadius"]:0,[t==="vertical"?"borderBottomWidth":"borderRightWidth"]:n/2},"&:last-of-type":{borderTopLeftRadius:0,[t==="vertical"?"borderTopRightRadius":"borderBottomLeftRadius"]:0,[t==="vertical"?"borderTopWidth":"borderLeftWidth"]:n/2},"&:not(:first-of-type):not(:last-of-type)":{borderRadius:0,[t==="vertical"?"borderTopWidth":"borderLeftWidth"]:n/2,[t==="vertical"?"borderBottomWidth":"borderRightWidth"]:n/2},"& + [data-button]":{[t==="vertical"?"marginTop":"marginLeft"]:-n,"@media (min-resolution: 192dpi)":{[t==="vertical"?"marginTop":"marginLeft"]:0}}}}})),FIe=Object.defineProperty,vS=Object.getOwnPropertySymbols,EJ=Object.prototype.hasOwnProperty,SJ=Object.prototype.propertyIsEnumerable,eB=(e,t,n)=>t in e?FIe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,BIe=(e,t)=>{for(var n in t||(t={}))EJ.call(t,n)&&eB(e,n,t[n]);if(vS)for(var n of vS(t))SJ.call(t,n)&&eB(e,n,t[n]);return e},jIe=(e,t)=>{var n={};for(var r in e)EJ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&vS)for(var r of vS(e))t.indexOf(r)<0&&SJ.call(e,r)&&(n[r]=e[r]);return n};const UIe={orientation:"horizontal",buttonBorderWidth:1},TJ=w.forwardRef((e,t)=>{const n=Ve("ButtonGroup",UIe,e),{className:r,orientation:i,buttonBorderWidth:s,unstyled:o}=n,a=jIe(n,["className","orientation","buttonBorderWidth","unstyled"]),{classes:u,cx:l}=MIe({orientation:i,buttonBorderWidth:s},{name:"ButtonGroup",unstyled:o});return N.createElement(it,BIe({className:l(u.root,r),ref:t},a))});TJ.displayName="@mantine/core/ButtonGroup";var VIe=Object.defineProperty,zIe=Object.defineProperties,HIe=Object.getOwnPropertyDescriptors,tB=Object.getOwnPropertySymbols,WIe=Object.prototype.hasOwnProperty,qIe=Object.prototype.propertyIsEnumerable,nB=(e,t,n)=>t in e?VIe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Ed=(e,t)=>{for(var n in t||(t={}))WIe.call(t,n)&&nB(e,n,t[n]);if(tB)for(var n of tB(t))qIe.call(t,n)&&nB(e,n,t[n]);return e},KR=(e,t)=>zIe(e,HIe(t));const QR={xs:{height:$s.xs,paddingLeft:14,paddingRight:14},sm:{height:$s.sm,paddingLeft:18,paddingRight:18},md:{height:$s.md,paddingLeft:22,paddingRight:22},lg:{height:$s.lg,paddingLeft:26,paddingRight:26},xl:{height:$s.xl,paddingLeft:32,paddingRight:32},"compact-xs":{height:22,paddingLeft:7,paddingRight:7},"compact-sm":{height:26,paddingLeft:8,paddingRight:8},"compact-md":{height:30,paddingLeft:10,paddingRight:10},"compact-lg":{height:34,paddingLeft:12,paddingRight:12},"compact-xl":{height:40,paddingLeft:14,paddingRight:14}};function GIe({compact:e,size:t,withLeftIcon:n,withRightIcon:r}){if(e)return QR[`compact-${t}`];const i=QR[t];return KR(Ed({},i),{paddingLeft:n?i.paddingLeft/1.5:i.paddingLeft,paddingRight:r?i.paddingRight/1.5:i.paddingRight})}const YIe=e=>({display:e?"block":"inline-block",width:e?"100%":"auto"});function KIe({variant:e,theme:t,color:n,gradient:r}){const i=t.fn.variant({color:n,variant:e,gradient:r});return e==="gradient"?{border:0,backgroundImage:i.background,color:i.color,"&:hover":t.fn.hover({backgroundSize:"200%"})}:Ed({border:`1px solid ${i.border}`,backgroundColor:i.background,color:i.color},t.fn.hover({backgroundColor:i.hover}))}var QIe=lt((e,{color:t,size:n,radius:r,fullWidth:i,compact:s,gradient:o,variant:a,withLeftIcon:u,withRightIcon:l})=>({root:KR(Ed(KR(Ed(Ed(Ed(Ed({},GIe({compact:s,size:n,withLeftIcon:u,withRightIcon:l})),e.fn.fontStyles()),e.fn.focusStyles()),YIe(i)),{borderRadius:e.fn.radius(r),fontWeight:600,position:"relative",lineHeight:1,fontSize:e.fn.size({size:n,sizes:e.fontSizes}),userSelect:"none",cursor:"pointer"}),KIe({variant:a,theme:e,color:t,gradient:o})),{"&:active":e.activeStyles,"&:disabled, &[data-disabled]":{borderColor:"transparent",backgroundColor:e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[2],color:e.colorScheme==="dark"?e.colors.dark[6]:e.colors.gray[5],cursor:"not-allowed",backgroundImage:"none",pointerEvents:"none","&:active":{transform:"none"}},"&[data-loading]":{pointerEvents:"none","&::before":{content:'""',position:"absolute",top:-1,left:-1,right:-1,bottom:-1,backgroundColor:e.colorScheme==="dark"?e.fn.rgba(e.colors.dark[7],.5):"rgba(255, 255, 255, .5)",borderRadius:e.fn.radius(r),cursor:"not-allowed"}}}),icon:{display:"flex",alignItems:"center"},leftIcon:{marginRight:10},rightIcon:{marginLeft:10},centerLoader:{position:"absolute",left:"50%",transform:"translateX(-50%)",opacity:.5},inner:{display:"flex",alignItems:"center",justifyContent:"center",height:"100%",overflow:"visible"},label:{whiteSpace:"nowrap",height:"100%",overflow:"hidden",display:"flex",alignItems:"center"}})),XIe=Object.defineProperty,_S=Object.getOwnPropertySymbols,IJ=Object.prototype.hasOwnProperty,xJ=Object.prototype.propertyIsEnumerable,rB=(e,t,n)=>t in e?XIe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,iB=(e,t)=>{for(var n in t||(t={}))IJ.call(t,n)&&rB(e,n,t[n]);if(_S)for(var n of _S(t))xJ.call(t,n)&&rB(e,n,t[n]);return e},JIe=(e,t)=>{var n={};for(var r in e)IJ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&_S)for(var r of _S(e))t.indexOf(r)<0&&xJ.call(e,r)&&(n[r]=e[r]);return n};const ZIe={size:"sm",type:"button",variant:"filled",loaderPosition:"left"},K$=w.forwardRef((e,t)=>{const n=Ve("Button",ZIe,e),{className:r,size:i,color:s,type:o,disabled:a,children:u,leftIcon:l,rightIcon:c,fullWidth:f,variant:d,radius:h,uppercase:p,compact:m,loading:y,loaderPosition:g,loaderProps:v,gradient:b,classNames:S,styles:T,unstyled:E}=n,I=JIe(n,["className","size","color","type","disabled","children","leftIcon","rightIcon","fullWidth","variant","radius","uppercase","compact","loading","loaderPosition","loaderProps","gradient","classNames","styles","unstyled"]),{classes:A,cx:R,theme:F}=QIe({radius:h,color:s,size:i,fullWidth:f,compact:m,gradient:b,variant:d,withLeftIcon:!!l,withRightIcon:!!c},{name:"Button",unstyled:E,classNames:S,styles:T}),L=F.fn.variant({color:s,variant:d}),B=N.createElement(Xf,iB({color:L.color,size:F.fn.size({size:i,sizes:QR}).height/2},v));return N.createElement(kx,iB({className:R(A.root,r),type:o,disabled:a,"data-button":!0,"data-disabled":a||void 0,"data-loading":y||void 0,ref:t,unstyled:E},I),N.createElement("div",{className:A.inner},(l||y&&g==="left")&&N.createElement("span",{className:R(A.icon,A.leftIcon)},y&&g==="left"?B:l),y&&g==="center"&&N.createElement("span",{className:A.centerLoader},B),N.createElement("span",{className:A.label,style:{textTransform:p?"uppercase":void 0}},u),(c||y&&g==="right")&&N.createElement("span",{className:R(A.icon,A.rightIcon)},y&&g==="right"?B:c)))});K$.displayName="@mantine/core/Button";K$.Group=TJ;const Ws=K$;var exe=lt((e,{radius:t,shadow:n,withBorder:r})=>({root:{outline:0,WebkitTapHighlightColor:"transparent",display:"block",textDecoration:"none",color:e.colorScheme==="dark"?e.colors.dark[0]:e.black,backgroundColor:e.colorScheme==="dark"?e.colors.dark[7]:e.white,boxSizing:"border-box",borderRadius:e.fn.radius(t),boxShadow:e.shadows[n]||n||"none",border:r?`1px solid ${e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[3]}`:void 0}})),txe=Object.defineProperty,bS=Object.getOwnPropertySymbols,CJ=Object.prototype.hasOwnProperty,AJ=Object.prototype.propertyIsEnumerable,sB=(e,t,n)=>t in e?txe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,nxe=(e,t)=>{for(var n in t||(t={}))CJ.call(t,n)&&sB(e,n,t[n]);if(bS)for(var n of bS(t))AJ.call(t,n)&&sB(e,n,t[n]);return e},rxe=(e,t)=>{var n={};for(var r in e)CJ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&bS)for(var r of bS(e))t.indexOf(r)<0&&AJ.call(e,r)&&(n[r]=e[r]);return n};const ixe={},PJ=w.forwardRef((e,t)=>{const n=Ve("Paper",ixe,e),{className:r,children:i,radius:s,withBorder:o,shadow:a,unstyled:u}=n,l=rxe(n,["className","children","radius","withBorder","shadow","unstyled"]),{classes:c,cx:f}=exe({radius:s,shadow:a,withBorder:o},{name:"Paper",unstyled:u});return N.createElement(it,nxe({className:f(c.root,r),ref:t},l),i)});PJ.displayName="@mantine/core/Paper";const wS=PJ,OJ=w.createContext({padding:0}),sxe=OJ.Provider,oxe=()=>w.useContext(OJ).padding;var axe=lt((e,{padding:t,withBorder:n,inheritPadding:r})=>{const i=e.fn.size({size:t,sizes:e.spacing}),s=-1*i,o=e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[3];return{cardSection:{display:"block",marginLeft:s,marginRight:s,paddingLeft:r?i:void 0,paddingRight:r?i:void 0,borderTop:n&&`1px solid ${o}`,borderBottom:n&&`1px solid ${o}`,"& + &":{borderTop:0},"&[data-first]":{marginTop:s,borderTop:0,borderBottom:n&&`1px solid ${o}`},"&[data-last]":{marginBottom:s,borderBottom:0}}}});const uxe=axe;var lxe=Object.defineProperty,ES=Object.getOwnPropertySymbols,RJ=Object.prototype.hasOwnProperty,NJ=Object.prototype.propertyIsEnumerable,oB=(e,t,n)=>t in e?lxe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,cxe=(e,t)=>{for(var n in t||(t={}))RJ.call(t,n)&&oB(e,n,t[n]);if(ES)for(var n of ES(t))NJ.call(t,n)&&oB(e,n,t[n]);return e},fxe=(e,t)=>{var n={};for(var r in e)RJ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&ES)for(var r of ES(e))t.indexOf(r)<0&&NJ.call(e,r)&&(n[r]=e[r]);return n};const dxe={withBorder:!1,inheritPadding:!1},kJ=w.forwardRef((e,t)=>{const n=Ve("CardSection",dxe,e),{className:r,withBorder:i,inheritPadding:s,unstyled:o}=n,a=fxe(n,["className","withBorder","inheritPadding","unstyled"]),{classes:u,cx:l}=uxe({padding:oxe(),withBorder:i,inheritPadding:s},{name:"Card",unstyled:o});return N.createElement(it,cxe({className:l(u.cardSection,r),ref:t},a))});kJ.displayName="@mantine/core/CardSection";const DJ=kJ;var hxe=lt(e=>({root:{position:"relative",overflow:"hidden",backgroundColor:e.colorScheme==="dark"?e.colors.dark[6]:e.white}})),pxe=Object.defineProperty,SS=Object.getOwnPropertySymbols,$J=Object.prototype.hasOwnProperty,LJ=Object.prototype.propertyIsEnumerable,aB=(e,t,n)=>t in e?pxe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,mxe=(e,t)=>{for(var n in t||(t={}))$J.call(t,n)&&aB(e,n,t[n]);if(SS)for(var n of SS(t))LJ.call(t,n)&&aB(e,n,t[n]);return e},gxe=(e,t)=>{var n={};for(var r in e)$J.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&SS)for(var r of SS(e))t.indexOf(r)<0&&LJ.call(e,r)&&(n[r]=e[r]);return n};const yxe={p:"md"},Q$=w.forwardRef((e,t)=>{const n=Ve("Card",yxe,e),{className:r,p:i,radius:s,children:o,unstyled:a}=n,u=gxe(n,["className","p","radius","children","unstyled"]),{classes:l,cx:c}=hxe(null,{name:"Card",unstyled:a}),f=w.Children.toArray(o),d=f.map((h,p)=>typeof h=="object"&&h&&"type"in h&&h.type===DJ?w.cloneElement(h,{padding:i,"data-first":p===0||void 0,"data-last":p===f.length-1||void 0}):h);return N.createElement(sxe,{value:{padding:i}},N.createElement(wS,mxe({className:c(l.root,r),radius:s,p:i,ref:t},u),d))});Q$.Section=DJ;Q$.displayName="@mantine/core/Card";const vxe=Q$;var _xe=Object.defineProperty,TS=Object.getOwnPropertySymbols,MJ=Object.prototype.hasOwnProperty,FJ=Object.prototype.propertyIsEnumerable,uB=(e,t,n)=>t in e?_xe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,bxe=(e,t)=>{for(var n in t||(t={}))MJ.call(t,n)&&uB(e,n,t[n]);if(TS)for(var n of TS(t))FJ.call(t,n)&&uB(e,n,t[n]);return e},wxe=(e,t)=>{var n={};for(var r in e)MJ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&TS)for(var r of TS(e))t.indexOf(r)<0&&FJ.call(e,r)&&(n[r]=e[r]);return n};const BJ=w.forwardRef((e,t)=>{const n=Ve("Center",{},e),{inline:r,sx:i}=n,s=wxe(n,["inline","sx"]);return N.createElement(it,bxe({ref:t,sx:[{display:r?"inline-flex":"flex",alignItems:"center",justifyContent:"center"},...lh(i)]},s))});BJ.displayName="@mantine/core/Center";const ua=BJ,jJ=w.createContext(null),Exe=jJ.Provider,Sxe=()=>w.useContext(jJ);function Txe(e){return w.Children.toArray(e).filter(Boolean)}const Ixe={left:"flex-start",center:"center",right:"flex-end",apart:"space-between"};var xxe=lt((e,{spacing:t,position:n,noWrap:r,grow:i,align:s,count:o})=>({root:{boxSizing:"border-box",display:"flex",flexDirection:"row",alignItems:s||"center",flexWrap:r?"nowrap":"wrap",justifyContent:Ixe[n],gap:e.fn.size({size:t,sizes:e.spacing}),"& > *":{boxSizing:"border-box",maxWidth:i?`calc(${100/o}% - ${e.fn.size({size:t,sizes:e.spacing})-e.fn.size({size:t,sizes:e.spacing})/o}px)`:void 0,flexGrow:i?1:0}}}));const Cxe=xxe;var Axe=Object.defineProperty,IS=Object.getOwnPropertySymbols,UJ=Object.prototype.hasOwnProperty,VJ=Object.prototype.propertyIsEnumerable,lB=(e,t,n)=>t in e?Axe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Pxe=(e,t)=>{for(var n in t||(t={}))UJ.call(t,n)&&lB(e,n,t[n]);if(IS)for(var n of IS(t))VJ.call(t,n)&&lB(e,n,t[n]);return e},Oxe=(e,t)=>{var n={};for(var r in e)UJ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&IS)for(var r of IS(e))t.indexOf(r)<0&&VJ.call(e,r)&&(n[r]=e[r]);return n};const Rxe={position:"left",spacing:"md"},ei=w.forwardRef((e,t)=>{const n=Ve("Group",Rxe,e),{className:r,position:i,align:s,children:o,noWrap:a,grow:u,spacing:l,unstyled:c}=n,f=Oxe(n,["className","position","align","children","noWrap","grow","spacing","unstyled"]),d=Txe(o),{classes:h,cx:p}=Cxe({align:s,grow:u,noWrap:a,spacing:l,position:i,count:d.length},{unstyled:c,name:"Group"});return N.createElement(it,Pxe({className:p(h.root,r),ref:t},f),d)});ei.displayName="@mantine/core/Group";var Nxe=lt((e,{spacing:t,align:n,justify:r})=>({root:{display:"flex",flexDirection:"column",alignItems:n,justifyContent:r,gap:e.fn.size({size:t,sizes:e.spacing})}})),kxe=Object.defineProperty,xS=Object.getOwnPropertySymbols,zJ=Object.prototype.hasOwnProperty,HJ=Object.prototype.propertyIsEnumerable,cB=(e,t,n)=>t in e?kxe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Dxe=(e,t)=>{for(var n in t||(t={}))zJ.call(t,n)&&cB(e,n,t[n]);if(xS)for(var n of xS(t))HJ.call(t,n)&&cB(e,n,t[n]);return e},$xe=(e,t)=>{var n={};for(var r in e)zJ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&xS)for(var r of xS(e))t.indexOf(r)<0&&HJ.call(e,r)&&(n[r]=e[r]);return n};const Lxe={spacing:"md",align:"stretch",justify:"flex-start"},ys=w.forwardRef((e,t)=>{const n=Ve("Stack",Lxe,e),{spacing:r,className:i,align:s,justify:o,unstyled:a}=n,u=$xe(n,["spacing","className","align","justify","unstyled"]),{classes:l,cx:c}=Nxe({spacing:r,align:s,justify:o},{name:"Stack",unstyled:a});return N.createElement(it,Dxe({className:c(l.root,i),ref:t},u))});ys.displayName="@mantine/core/Stack";function WJ({spacing:e,offset:t,orientation:n,children:r,role:i,unstyled:s}){return n==="horizontal"?N.createElement(ei,{pt:t,spacing:e,role:i,unstyled:s},r):N.createElement(ys,{pt:t,spacing:e,role:i,unstyled:s},r)}var Mxe=Object.defineProperty,CS=Object.getOwnPropertySymbols,qJ=Object.prototype.hasOwnProperty,GJ=Object.prototype.propertyIsEnumerable,fB=(e,t,n)=>t in e?Mxe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,dB=(e,t)=>{for(var n in t||(t={}))qJ.call(t,n)&&fB(e,n,t[n]);if(CS)for(var n of CS(t))GJ.call(t,n)&&fB(e,n,t[n]);return e},Fxe=(e,t)=>{var n={};for(var r in e)qJ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&CS)for(var r of CS(e))t.indexOf(r)<0&&GJ.call(e,r)&&(n[r]=e[r]);return n};const Bxe={orientation:"horizontal",spacing:"lg",size:"sm",offset:"xs"},YJ=w.forwardRef((e,t)=>{const n=Ve("CheckboxGroup",Bxe,e),{children:r,value:i,defaultValue:s,onChange:o,orientation:a,spacing:u,size:l,wrapperProps:c,offset:f}=n,d=Fxe(n,["children","value","defaultValue","onChange","orientation","spacing","size","wrapperProps","offset"]),[h,p]=oa({value:i,defaultValue:s,finalValue:[],onChange:o}),m=y=>{const g=y.currentTarget.value;p(h.includes(g)?h.filter(v=>v!==g):[...h,g])};return N.createElement(Exe,{value:{value:h,onChange:m,size:l}},N.createElement(Zs.Wrapper,dB(dB({labelElement:"div",size:l,__staticSelector:"CheckboxGroup",ref:t},c),d),N.createElement(WJ,{spacing:u,orientation:a,offset:f},r)))});YJ.displayName="@mantine/core/CheckboxGroup";var jxe=Object.defineProperty,AS=Object.getOwnPropertySymbols,KJ=Object.prototype.hasOwnProperty,QJ=Object.prototype.propertyIsEnumerable,hB=(e,t,n)=>t in e?jxe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,XR=(e,t)=>{for(var n in t||(t={}))KJ.call(t,n)&&hB(e,n,t[n]);if(AS)for(var n of AS(t))QJ.call(t,n)&&hB(e,n,t[n]);return e},Uxe=(e,t)=>{var n={};for(var r in e)KJ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&AS)for(var r of AS(e))t.indexOf(r)<0&&QJ.call(e,r)&&(n[r]=e[r]);return n};function Vxe(e){return N.createElement("svg",XR({viewBox:"0 0 10 7",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e),N.createElement("path",{d:"M4 4.586L1.707 2.293A1 1 0 1 0 .293 3.707l3 3a.997.997 0 0 0 1.414 0l5-5A1 1 0 1 0 8.293.293L4 4.586z",fill:"currentColor",fillRule:"evenodd",clipRule:"evenodd"}))}function zxe(e){var t=e,{indeterminate:n}=t,r=Uxe(t,["indeterminate"]);return n?N.createElement("svg",XR({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 32 6"},r),N.createElement("rect",{width:"32",height:"6",fill:"currentColor",rx:"3"})):N.createElement(Vxe,XR({},r))}var Hxe=Object.defineProperty,Wxe=Object.defineProperties,qxe=Object.getOwnPropertyDescriptors,pB=Object.getOwnPropertySymbols,Gxe=Object.prototype.hasOwnProperty,Yxe=Object.prototype.propertyIsEnumerable,mB=(e,t,n)=>t in e?Hxe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Kxe=(e,t)=>{for(var n in t||(t={}))Gxe.call(t,n)&&mB(e,n,t[n]);if(pB)for(var n of pB(t))Yxe.call(t,n)&&mB(e,n,t[n]);return e},Qxe=(e,t)=>Wxe(e,qxe(t));const Xxe={xs:16,sm:20,md:24,lg:30,xl:36},Jxe={xs:8,sm:10,md:14,lg:16,xl:20};var Zxe=lt((e,{size:t,radius:n,color:r,transitionDuration:i,labelPosition:s,error:o,indeterminate:a},u)=>{const l=e.fn.size({size:t,sizes:Xxe}),c=e.fn.variant({variant:"filled",color:r}),f=e.fn.variant({variant:"filled",color:"red"}).background;return{icon:{ref:u("icon"),color:a?"inherit":e.white,transform:a?"none":"translateY(5px) scale(0.5)",opacity:a?1:0,transitionProperty:"opacity, transform",transitionTimingFunction:"ease",transitionDuration:`${i}ms`,pointerEvents:"none",width:e.fn.size({size:t,sizes:Jxe}),position:"absolute",zIndex:1,top:0,bottom:0,left:0,right:0,margin:"auto","@media (prefers-reduced-motion)":{transitionDuration:e.respectReducedMotion?"0ms":void 0}},inner:{position:"relative",width:l,height:l,order:s==="left"?2:1},input:Qxe(Kxe({},e.fn.focusStyles()),{appearance:"none",backgroundColor:e.colorScheme==="dark"?e.colors.dark[6]:e.white,border:`1px solid ${o?f:e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[4]}`,width:l,height:l,borderRadius:e.fn.radius(n),padding:0,display:"block",margin:0,transition:`border-color ${i}ms ease, background-color ${i}ms ease`,cursor:e.cursorType,"&:checked":{backgroundColor:c.background,borderColor:c.background,[`& + .${u("icon")}`]:{opacity:1,color:e.white,transform:"translateY(0) scale(1)"}},"&:disabled":{backgroundColor:e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[2],borderColor:e.colorScheme==="dark"?e.colors.dark[6]:e.colors.gray[3],cursor:"not-allowed",[`& + .${u("icon")}`]:{color:e.colorScheme==="dark"?e.colors.dark[6]:e.colors.gray[5]}}})}});const eCe=Zxe;var tCe=Object.defineProperty,nCe=Object.defineProperties,rCe=Object.getOwnPropertyDescriptors,gB=Object.getOwnPropertySymbols,iCe=Object.prototype.hasOwnProperty,sCe=Object.prototype.propertyIsEnumerable,yB=(e,t,n)=>t in e?tCe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,oCe=(e,t)=>{for(var n in t||(t={}))iCe.call(t,n)&&yB(e,n,t[n]);if(gB)for(var n of gB(t))sCe.call(t,n)&&yB(e,n,t[n]);return e},aCe=(e,t)=>nCe(e,rCe(t));const uCe={xs:16,sm:20,md:24,lg:30,xl:36};var lCe=lt((e,{labelPosition:t,size:n})=>({root:{},body:{display:"flex"},labelWrapper:aCe(oCe({},e.fn.fontStyles()),{display:"inline-flex",flexDirection:"column",WebkitTapHighlightColor:"transparent",fontSize:e.fn.size({size:n,sizes:e.fontSizes}),lineHeight:`${e.fn.size({size:n,sizes:uCe})}px`,color:e.colorScheme==="dark"?e.colors.dark[0]:e.black,cursor:e.cursorType,order:t==="left"?1:2}),description:{marginTop:`calc(${e.spacing.xs}px / 2)`,[t==="left"?"paddingRight":"paddingLeft"]:e.spacing.sm},error:{marginTop:`calc(${e.spacing.xs}px / 2)`,[t==="left"?"paddingRight":"paddingLeft"]:e.spacing.sm},label:{cursor:e.cursorType,[t==="left"?"paddingRight":"paddingLeft"]:e.spacing.sm,"&[data-disabled]":{color:e.colorScheme==="dark"?e.colors.dark[3]:e.colors.gray[5]}}})),cCe=Object.defineProperty,PS=Object.getOwnPropertySymbols,XJ=Object.prototype.hasOwnProperty,JJ=Object.prototype.propertyIsEnumerable,vB=(e,t,n)=>t in e?cCe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,fCe=(e,t)=>{for(var n in t||(t={}))XJ.call(t,n)&&vB(e,n,t[n]);if(PS)for(var n of PS(t))JJ.call(t,n)&&vB(e,n,t[n]);return e},dCe=(e,t)=>{var n={};for(var r in e)XJ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&PS)for(var r of PS(e))t.indexOf(r)<0&&JJ.call(e,r)&&(n[r]=e[r]);return n};function X$(e){var t=e,{__staticSelector:n,className:r,classNames:i,styles:s,unstyled:o,children:a,label:u,description:l,id:c,disabled:f,error:d,size:h,labelPosition:p}=t,m=dCe(t,["__staticSelector","className","classNames","styles","unstyled","children","label","description","id","disabled","error","size","labelPosition"]);const{classes:y,cx:g}=lCe({size:h,labelPosition:p},{name:n,styles:s,classNames:i,unstyled:o});return N.createElement(it,fCe({className:g(y.root,r)},m),N.createElement("div",{className:g(y.body)},a,N.createElement("div",{className:y.labelWrapper},u&&N.createElement("label",{className:y.label,"data-disabled":f||void 0,htmlFor:c},u),l&&N.createElement(Zs.Description,{className:y.description},l),d&&d!=="boolean"&&N.createElement(Zs.Error,{className:y.error},d))))}X$.displayName="@mantine/core/InlineInput";var hCe=Object.defineProperty,OS=Object.getOwnPropertySymbols,ZJ=Object.prototype.hasOwnProperty,eZ=Object.prototype.propertyIsEnumerable,_B=(e,t,n)=>t in e?hCe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,gb=(e,t)=>{for(var n in t||(t={}))ZJ.call(t,n)&&_B(e,n,t[n]);if(OS)for(var n of OS(t))eZ.call(t,n)&&_B(e,n,t[n]);return e},pCe=(e,t)=>{var n={};for(var r in e)ZJ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&OS)for(var r of OS(e))t.indexOf(r)<0&&eZ.call(e,r)&&(n[r]=e[r]);return n};const mCe={size:"sm",transitionDuration:100,icon:zxe,labelPosition:"right"},Mm=w.forwardRef((e,t)=>{const n=Ve("Checkbox",mCe,e),{className:r,style:i,sx:s,checked:o,disabled:a,color:u,label:l,indeterminate:c,id:f,size:d,radius:h,wrapperProps:p,children:m,classNames:y,styles:g,transitionDuration:v,icon:b,unstyled:S,labelPosition:T,description:E,error:I}=n,A=pCe(n,["className","style","sx","checked","disabled","color","label","indeterminate","id","size","radius","wrapperProps","children","classNames","styles","transitionDuration","icon","unstyled","labelPosition","description","error"]),R=Sxe(),F=tu(f),{systemStyles:L,rest:B}=Qf(A),{classes:J}=eCe({size:(R==null?void 0:R.size)||d,radius:h,color:u,transitionDuration:v,labelPosition:T,error:!!I,indeterminate:c},{name:"Checkbox",classNames:y,styles:g,unstyled:S}),V=R?{checked:R.value.includes(B.value),onChange:R.onChange}:{};return N.createElement(X$,gb(gb({className:r,sx:s,style:i,id:F,size:(R==null?void 0:R.size)||d,labelPosition:T,label:l,description:E,error:I,disabled:a,__staticSelector:"Checkbox",classNames:y,styles:g,unstyled:S,"data-checked":V.checked||void 0},L),p),N.createElement("div",{className:J.inner},N.createElement("input",gb(gb({id:F,ref:t,type:"checkbox",className:J.input,checked:o,disabled:a},B),V)),N.createElement(b,{indeterminate:c,className:J.icon})))});Mm.displayName="@mantine/core/Checkbox";Mm.Group=YJ;var gCe=lt((e,{fluid:t,size:n,sizes:r})=>({root:{paddingLeft:e.spacing.md,paddingRight:e.spacing.md,maxWidth:t?"100%":e.fn.size({size:n,sizes:r}),marginLeft:"auto",marginRight:"auto"}})),yCe=Object.defineProperty,RS=Object.getOwnPropertySymbols,tZ=Object.prototype.hasOwnProperty,nZ=Object.prototype.propertyIsEnumerable,bB=(e,t,n)=>t in e?yCe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,vCe=(e,t)=>{for(var n in t||(t={}))tZ.call(t,n)&&bB(e,n,t[n]);if(RS)for(var n of RS(t))nZ.call(t,n)&&bB(e,n,t[n]);return e},_Ce=(e,t)=>{var n={};for(var r in e)tZ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&RS)for(var r of RS(e))t.indexOf(r)<0&&nZ.call(e,r)&&(n[r]=e[r]);return n};const bCe={sizes:{xs:540,sm:720,md:960,lg:1140,xl:1320}},rZ=w.forwardRef((e,t)=>{const n=Ve("Container",bCe,e),{className:r,fluid:i,size:s,unstyled:o,sizes:a}=n,u=_Ce(n,["className","fluid","size","unstyled","sizes"]),{classes:l,cx:c}=gCe({fluid:i,size:s,sizes:a},{unstyled:o,name:"Container"});return N.createElement(it,vCe({className:c(l.root,r),ref:t},u))});rZ.displayName="@mantine/core/Container";function iZ({transitions:e,duration:t=250,exitDuration:n=t,mounted:r,children:i,timingFunction:s,onExit:o,onEntered:a,onEnter:u,onExited:l}){const{transitionDuration:c,transitionStatus:f,transitionTimingFunction:d}=VX({mounted:r,duration:t,exitDuration:n,timingFunction:s,onExit:o,onEntered:a,onEnter:u,onExited:l});if(c===0)return r?N.createElement(N.Fragment,null,i({})):null;if(f==="exited")return null;const h=Object.keys(e).reduce((p,m)=>(p[m]=UX({duration:e[m].duration,transition:e[m].transition,timingFunction:e[m].timingFunction||d,state:f}),p),{});return N.createElement(N.Fragment,null,i(h))}iZ.displayName="@mantine/core/GroupedTransition";var wCe=lt((e,{zIndex:t})=>({root:{position:"absolute",top:0,bottom:0,left:0,right:0,zIndex:t}})),ECe=Object.defineProperty,SCe=Object.defineProperties,TCe=Object.getOwnPropertyDescriptors,NS=Object.getOwnPropertySymbols,sZ=Object.prototype.hasOwnProperty,oZ=Object.prototype.propertyIsEnumerable,wB=(e,t,n)=>t in e?ECe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,UP=(e,t)=>{for(var n in t||(t={}))sZ.call(t,n)&&wB(e,n,t[n]);if(NS)for(var n of NS(t))oZ.call(t,n)&&wB(e,n,t[n]);return e},ICe=(e,t)=>SCe(e,TCe(t)),xCe=(e,t)=>{var n={};for(var r in e)sZ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&NS)for(var r of NS(e))t.indexOf(r)<0&&oZ.call(e,r)&&(n[r]=e[r]);return n};const CCe={opacity:.6,color:"#fff",zIndex:cc("modal"),radius:0,blur:0},aZ=w.forwardRef((e,t)=>{const n=Ve("Overlay",CCe,e),{opacity:r,blur:i,color:s,gradient:o,zIndex:a,radius:u,sx:l,unstyled:c,className:f}=n,d=xCe(n,["opacity","blur","color","gradient","zIndex","radius","sx","unstyled","className"]),{classes:h,cx:p}=wCe({zIndex:a},{name:"Overlay",unstyled:c}),m=o?{backgroundImage:o}:{backgroundColor:s},y=g=>N.createElement(it,UP({ref:t,className:p(h.root,f),sx:[v=>ICe(UP({},m),{opacity:r,borderRadius:v.fn.size({size:u,sizes:v.radius})}),...lh(l)]},g));return i?N.createElement(it,UP({className:p(h.root,f),sx:[{backdropFilter:`blur(${i}px)`},...lh(l)]},d),y()):y(d)});aZ.displayName="@mantine/core/Overlay";const ACe=aZ,PCe={gap:{type:"spacing",property:"gap"},rowGap:{type:"spacing",property:"rowGap"},columnGap:{type:"spacing",property:"columnGap"},align:{type:"default",property:"alignItems"},justify:{type:"default",property:"justifyContent"},wrap:{type:"default",property:"flexWrap"},direction:{type:"default",property:"flexDirection"}};var OCe=Object.defineProperty,RCe=Object.defineProperties,NCe=Object.getOwnPropertyDescriptors,kS=Object.getOwnPropertySymbols,uZ=Object.prototype.hasOwnProperty,lZ=Object.prototype.propertyIsEnumerable,EB=(e,t,n)=>t in e?OCe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,kCe=(e,t)=>{for(var n in t||(t={}))uZ.call(t,n)&&EB(e,n,t[n]);if(kS)for(var n of kS(t))lZ.call(t,n)&&EB(e,n,t[n]);return e},DCe=(e,t)=>RCe(e,NCe(t)),$Ce=(e,t)=>{var n={};for(var r in e)uZ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&kS)for(var r of kS(e))t.indexOf(r)<0&&lZ.call(e,r)&&(n[r]=e[r]);return n};const LCe={},Fm=w.forwardRef((e,t)=>{const n=Ve("Flex",LCe,e),{gap:r,rowGap:i,columnGap:s,align:o,justify:a,wrap:u,direction:l,sx:c}=n,f=$Ce(n,["gap","rowGap","columnGap","align","justify","wrap","direction","sx"]);return N.createElement(it,DCe(kCe({},f),{sx:[{display:"flex"},d=>VR({gap:r,rowGap:i,columnGap:s,align:o,justify:a,wrap:u,direction:l},d,PCe),...lh(c)],ref:t}))});Fm.displayName="@mantine/core/Flex";const[MCe,FCe]=N_("Grid component was not found in tree");var BCe=Object.defineProperty,SB=Object.getOwnPropertySymbols,jCe=Object.prototype.hasOwnProperty,UCe=Object.prototype.propertyIsEnumerable,TB=(e,t,n)=>t in e?BCe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,VCe=(e,t)=>{for(var n in t||(t={}))jCe.call(t,n)&&TB(e,n,t[n]);if(SB)for(var n of SB(t))UCe.call(t,n)&&TB(e,n,t[n]);return e};const J$=(e,t)=>e==="content"?"auto":e==="auto"?"0px":e?`${100/(t/e)}%`:void 0,cZ=(e,t,n)=>n||e==="auto"||e==="content"?"unset":J$(e,t),fZ=(e,t)=>{if(e)return e==="auto"||t?1:0},dZ=(e,t)=>e===0?0:e?`${100/(t/e)}%`:void 0,hZ=(e,t)=>typeof e<"u"?t.fn.size({size:e,sizes:t.spacing})/2:void 0;function zCe({sizes:e,offsets:t,orders:n,theme:r,columns:i,gutters:s,grow:o}){return hK.reduce((a,u)=>(a[`@media (min-width: ${r.breakpoints[u]}px)`]={order:n[u],flexBasis:J$(e[u],i),padding:hZ(s[u],r),flexShrink:0,width:e[u]==="content"?"auto":void 0,maxWidth:cZ(e[u],i,o),marginLeft:dZ(t[u],i),flexGrow:fZ(e[u],o)},a),{})}var HCe=lt((e,{gutter:t,gutterXs:n,gutterSm:r,gutterMd:i,gutterLg:s,gutterXl:o,grow:a,offset:u,offsetXs:l,offsetSm:c,offsetMd:f,offsetLg:d,offsetXl:h,columns:p,span:m,xs:y,sm:g,md:v,lg:b,xl:S,order:T,orderXs:E,orderSm:I,orderMd:A,orderLg:R,orderXl:F})=>({col:VCe({boxSizing:"border-box",flexGrow:fZ(m,a),order:T,padding:hZ(t,e),marginLeft:dZ(u,p),flexBasis:J$(m,p),flexShrink:0,width:m==="content"?"auto":void 0,maxWidth:cZ(m,p,a)},zCe({sizes:{xs:y,sm:g,md:v,lg:b,xl:S},offsets:{xs:l,sm:c,md:f,lg:d,xl:h},orders:{xs:E,sm:I,md:A,lg:R,xl:F},gutters:{xs:n,sm:r,md:i,lg:s,xl:o},theme:e,columns:p,grow:a}))}));const WCe=HCe;var qCe=Object.defineProperty,DS=Object.getOwnPropertySymbols,pZ=Object.prototype.hasOwnProperty,mZ=Object.prototype.propertyIsEnumerable,IB=(e,t,n)=>t in e?qCe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,GCe=(e,t)=>{for(var n in t||(t={}))pZ.call(t,n)&&IB(e,n,t[n]);if(DS)for(var n of DS(t))mZ.call(t,n)&&IB(e,n,t[n]);return e},YCe=(e,t)=>{var n={};for(var r in e)pZ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&DS)for(var r of DS(e))t.indexOf(r)<0&&mZ.call(e,r)&&(n[r]=e[r]);return n};const KCe={};function QCe(e){return e==="auto"||e==="content"?!0:typeof e=="number"&&e>0&&e%1===0}const gZ=w.forwardRef((e,t)=>{const n=Ve("GridCol",KCe,e),{children:r,span:i,offset:s,offsetXs:o,offsetSm:a,offsetMd:u,offsetLg:l,offsetXl:c,xs:f,sm:d,md:h,lg:p,xl:m,order:y,orderXs:g,orderSm:v,orderMd:b,orderLg:S,orderXl:T,className:E,id:I,unstyled:A}=n,R=YCe(n,["children","span","offset","offsetXs","offsetSm","offsetMd","offsetLg","offsetXl","xs","sm","md","lg","xl","order","orderXs","orderSm","orderMd","orderLg","orderXl","className","id","unstyled"]),F=FCe(),L=i||F.columns,{classes:B,cx:J}=WCe({gutter:F.gutter,gutterXs:F.gutterXs,gutterSm:F.gutterSm,gutterMd:F.gutterMd,gutterLg:F.gutterLg,gutterXl:F.gutterXl,offset:s,offsetXs:o,offsetSm:a,offsetMd:u,offsetLg:l,offsetXl:c,xs:f,sm:d,md:h,lg:p,xl:m,order:y,orderXs:g,orderSm:v,orderMd:b,orderLg:S,orderXl:T,grow:F.grow,columns:F.columns,span:L},{unstyled:A,name:"Grid"});return!QCe(L)||L>F.columns?null:N.createElement(it,GCe({className:J(B.col,E),ref:t},R),r)});gZ.displayName="@mantine/core/Col";var XCe=Object.defineProperty,xB=Object.getOwnPropertySymbols,JCe=Object.prototype.hasOwnProperty,ZCe=Object.prototype.propertyIsEnumerable,CB=(e,t,n)=>t in e?XCe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,eAe=(e,t)=>{for(var n in t||(t={}))JCe.call(t,n)&&CB(e,n,t[n]);if(xB)for(var n of xB(t))ZCe.call(t,n)&&CB(e,n,t[n]);return e};function tAe(e,t){return hK.reduce((n,r)=>(typeof e[r]<"u"&&(n[`@media (min-width: ${t.breakpoints[r]}px)`]={margin:-t.fn.size({size:e[r],sizes:t.spacing})/2}),n),{})}var nAe=lt((e,{justify:t,align:n,gutter:r,gutterXs:i,gutterSm:s,gutterMd:o,gutterLg:a,gutterXl:u})=>({root:eAe({margin:-e.fn.size({size:r,sizes:e.spacing})/2,display:"flex",flexWrap:"wrap",justifyContent:t,alignItems:n},tAe({xs:i,sm:s,md:o,lg:a,xl:u},e))})),rAe=Object.defineProperty,$S=Object.getOwnPropertySymbols,yZ=Object.prototype.hasOwnProperty,vZ=Object.prototype.propertyIsEnumerable,AB=(e,t,n)=>t in e?rAe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,iAe=(e,t)=>{for(var n in t||(t={}))yZ.call(t,n)&&AB(e,n,t[n]);if($S)for(var n of $S(t))vZ.call(t,n)&&AB(e,n,t[n]);return e},sAe=(e,t)=>{var n={};for(var r in e)yZ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&$S)for(var r of $S(e))t.indexOf(r)<0&&vZ.call(e,r)&&(n[r]=e[r]);return n};const oAe={gutter:"md",justify:"flex-start",align:"stretch",columns:12},Rl=w.forwardRef((e,t)=>{const n=Ve("Grid",oAe,e),{gutter:r,gutterXs:i,gutterSm:s,gutterMd:o,gutterLg:a,gutterXl:u,children:l,grow:c,justify:f,align:d,columns:h,className:p,id:m,unstyled:y}=n,g=sAe(n,["gutter","gutterXs","gutterSm","gutterMd","gutterLg","gutterXl","children","grow","justify","align","columns","className","id","unstyled"]),{classes:v,cx:b}=nAe({gutter:r,justify:f,align:d,gutterXs:i,gutterSm:s,gutterMd:o,gutterLg:a,gutterXl:u},{unstyled:y,name:"Grid"});return N.createElement(MCe,{value:{gutter:r,gutterXs:i,gutterSm:s,gutterMd:o,gutterLg:a,gutterXl:u,grow:c,columns:h}},N.createElement(it,iAe({className:b(v.root,p),ref:t},g),l))});Rl.Col=gZ;Rl.displayName="@mantine/core/Grid";var aAe=lt((e,{color:t})=>({root:{backgroundColor:e.fn.themeColor(t,e.colorScheme==="dark"?5:2),color:e.colorScheme==="dark"?e.colors.dark[9]:"inherit"}})),uAe=Object.defineProperty,LS=Object.getOwnPropertySymbols,_Z=Object.prototype.hasOwnProperty,bZ=Object.prototype.propertyIsEnumerable,PB=(e,t,n)=>t in e?uAe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,lAe=(e,t)=>{for(var n in t||(t={}))_Z.call(t,n)&&PB(e,n,t[n]);if(LS)for(var n of LS(t))bZ.call(t,n)&&PB(e,n,t[n]);return e},cAe=(e,t)=>{var n={};for(var r in e)_Z.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&LS)for(var r of LS(e))t.indexOf(r)<0&&bZ.call(e,r)&&(n[r]=e[r]);return n};const fAe={color:"yellow"},wZ=w.forwardRef((e,t)=>{const n=Ve("Mark",fAe,e),{color:r,className:i,unstyled:s}=n,o=cAe(n,["color","className","unstyled"]),{classes:a,cx:u}=aAe({color:r},{unstyled:s,name:"Mark"});return N.createElement(it,lAe({component:"mark",ref:t,className:u(a.root,i)},o))});wZ.displayName="@mantine/core/Mark";function OB(e){return e.replace(/[-[\]{}()*+?.,\\^$|#]/g,"\\$&")}function dAe(e,t){if(t==null)return[{chunk:e,highlighted:!1}];const n=Array.isArray(t)?t.map(OB):OB(t);if(!(Array.isArray(n)?n.filter(a=>a.trim().length>0).length>0:n.trim()!==""))return[{chunk:e,highlighted:!1}];const i=typeof n=="string"?n.trim():n.filter(a=>a.trim().length!==0).map(a=>a.trim()).join("|"),s=new RegExp(`(${i})`,"gi");return e.split(s).map(a=>({chunk:a,highlighted:s.test(a)})).filter(({chunk:a})=>a)}var hAe=Object.defineProperty,MS=Object.getOwnPropertySymbols,EZ=Object.prototype.hasOwnProperty,SZ=Object.prototype.propertyIsEnumerable,RB=(e,t,n)=>t in e?hAe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,pAe=(e,t)=>{for(var n in t||(t={}))EZ.call(t,n)&&RB(e,n,t[n]);if(MS)for(var n of MS(t))SZ.call(t,n)&&RB(e,n,t[n]);return e},mAe=(e,t)=>{var n={};for(var r in e)EZ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&MS)for(var r of MS(e))t.indexOf(r)<0&&SZ.call(e,r)&&(n[r]=e[r]);return n};const gAe={highlightColor:"yellow"},TZ=w.forwardRef((e,t)=>{const n=Ve("Highlight",gAe,e),{children:r,highlight:i,highlightColor:s,highlightStyles:o,unstyled:a}=n,u=mAe(n,["children","highlight","highlightColor","highlightStyles","unstyled"]),l=dAe(r,i);return N.createElement(rt,pAe({unstyled:a,ref:t},u),l.map(({chunk:c,highlighted:f},d)=>f?N.createElement(wZ,{unstyled:a,key:d,color:s,sx:o},c):N.createElement("span",{key:d},c)))});TZ.displayName="@mantine/core/Highlight";const yAe=TZ,IZ={context:"HoverCard component was not found in the tree",children:"HoverCard.Target component children should be an element or a component that accepts ref, fragments, strings, numbers and other primitive values are not supported"},[vAe,xZ]=N_(IZ.context);var _Ae=Object.defineProperty,FS=Object.getOwnPropertySymbols,CZ=Object.prototype.hasOwnProperty,AZ=Object.prototype.propertyIsEnumerable,NB=(e,t,n)=>t in e?_Ae(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,bAe=(e,t)=>{for(var n in t||(t={}))CZ.call(t,n)&&NB(e,n,t[n]);if(FS)for(var n of FS(t))AZ.call(t,n)&&NB(e,n,t[n]);return e},wAe=(e,t)=>{var n={};for(var r in e)CZ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&FS)for(var r of FS(e))t.indexOf(r)<0&&AZ.call(e,r)&&(n[r]=e[r]);return n};const EAe={};function PZ(e){const t=Ve("HoverCardDropdown",EAe,e),{children:n,onMouseEnter:r,onMouseLeave:i}=t,s=wAe(t,["children","onMouseEnter","onMouseLeave"]),o=xZ(),a=wo(r,o.openDropdown),u=wo(i,o.closeDropdown);return N.createElement(yi.Dropdown,bAe({onMouseEnter:a,onMouseLeave:u},s),n)}PZ.displayName="@mantine/core/HoverCardDropdown";var SAe=Object.defineProperty,BS=Object.getOwnPropertySymbols,OZ=Object.prototype.hasOwnProperty,RZ=Object.prototype.propertyIsEnumerable,kB=(e,t,n)=>t in e?SAe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,TAe=(e,t)=>{for(var n in t||(t={}))OZ.call(t,n)&&kB(e,n,t[n]);if(BS)for(var n of BS(t))RZ.call(t,n)&&kB(e,n,t[n]);return e},IAe=(e,t)=>{var n={};for(var r in e)OZ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&BS)for(var r of BS(e))t.indexOf(r)<0&&RZ.call(e,r)&&(n[r]=e[r]);return n};const xAe={refProp:"ref"},NZ=w.forwardRef((e,t)=>{const n=Ve("HoverCardTarget",xAe,e),{children:r,refProp:i}=n,s=IAe(n,["children","refProp"]);if(!_g(r))throw new Error(IZ.children);const o=xZ(),a=wo(r.props.onMouseEnter,o.openDropdown),u=wo(r.props.onMouseLeave,o.closeDropdown);return N.createElement(yi.Target,TAe({refProp:i,ref:t},s),w.cloneElement(r,{onMouseEnter:a,onMouseLeave:u}))});NZ.displayName="@mantine/core/HoverCardTarget";function kZ({open:e,close:t,openDelay:n,closeDelay:r}){const i=w.useRef(-1),s=w.useRef(-1),o=()=>{window.clearTimeout(i.current),window.clearTimeout(s.current)},a=()=>{o(),n===0?e():i.current=window.setTimeout(e,n)},u=()=>{o(),r===0?t():s.current=window.setTimeout(t,r)};return w.useEffect(()=>o,[]),{openDropdown:a,closeDropdown:u}}var CAe=Object.defineProperty,jS=Object.getOwnPropertySymbols,DZ=Object.prototype.hasOwnProperty,$Z=Object.prototype.propertyIsEnumerable,DB=(e,t,n)=>t in e?CAe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,AAe=(e,t)=>{for(var n in t||(t={}))DZ.call(t,n)&&DB(e,n,t[n]);if(jS)for(var n of jS(t))$Z.call(t,n)&&DB(e,n,t[n]);return e},PAe=(e,t)=>{var n={};for(var r in e)DZ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&jS)for(var r of jS(e))t.indexOf(r)<0&&$Z.call(e,r)&&(n[r]=e[r]);return n};const OAe={openDelay:0,closeDelay:150,initiallyOpened:!1};function em(e){const t=Ve("HoverCard",OAe,e),{children:n,onOpen:r,onClose:i,openDelay:s,closeDelay:o,initiallyOpened:a}=t,u=PAe(t,["children","onOpen","onClose","openDelay","closeDelay","initiallyOpened"]),[l,{open:c,close:f}]=x$(a,{onClose:i,onOpen:r}),{openDropdown:d,closeDropdown:h}=kZ({open:c,close:f,openDelay:s,closeDelay:o});return N.createElement(vAe,{value:{openDropdown:d,closeDropdown:h}},N.createElement(yi,AAe({opened:l,__staticSelector:"HoverCard"},u),n))}em.displayName="@mantine/core/HoverCard";em.Target=NZ;em.Dropdown=PZ;var RAe=Object.defineProperty,$B=Object.getOwnPropertySymbols,NAe=Object.prototype.hasOwnProperty,kAe=Object.prototype.propertyIsEnumerable,LB=(e,t,n)=>t in e?RAe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,DAe=(e,t)=>{for(var n in t||(t={}))NAe.call(t,n)&&LB(e,n,t[n]);if($B)for(var n of $B(t))kAe.call(t,n)&&LB(e,n,t[n]);return e};function $Ae(e){return N.createElement("svg",DAe({width:"15",height:"15",viewBox:"0 0 15 15",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e),N.createElement("path",{d:"M2.5 1H12.5C13.3284 1 14 1.67157 14 2.5V12.5C14 13.3284 13.3284 14 12.5 14H2.5C1.67157 14 1 13.3284 1 12.5V2.5C1 1.67157 1.67157 1 2.5 1ZM2.5 2C2.22386 2 2 2.22386 2 2.5V8.3636L3.6818 6.6818C3.76809 6.59551 3.88572 6.54797 4.00774 6.55007C4.12975 6.55216 4.24568 6.60372 4.32895 6.69293L7.87355 10.4901L10.6818 7.6818C10.8575 7.50607 11.1425 7.50607 11.3182 7.6818L13 9.3636V2.5C13 2.22386 12.7761 2 12.5 2H2.5ZM2 12.5V9.6364L3.98887 7.64753L7.5311 11.4421L8.94113 13H2.5C2.22386 13 2 12.7761 2 12.5ZM12.5 13H10.155L8.48336 11.153L11 8.6364L13 10.6364V12.5C13 12.7761 12.7761 13 12.5 13ZM6.64922 5.5C6.64922 5.03013 7.03013 4.64922 7.5 4.64922C7.96987 4.64922 8.35078 5.03013 8.35078 5.5C8.35078 5.96987 7.96987 6.35078 7.5 6.35078C7.03013 6.35078 6.64922 5.96987 6.64922 5.5ZM7.5 3.74922C6.53307 3.74922 5.74922 4.53307 5.74922 5.5C5.74922 6.46693 6.53307 7.25078 7.5 7.25078C8.46693 7.25078 9.25078 6.46693 9.25078 5.5C9.25078 4.53307 8.46693 3.74922 7.5 3.74922Z",fill:"currentColor",fillRule:"evenodd",clipRule:"evenodd"}))}var LAe=Object.defineProperty,MAe=Object.defineProperties,FAe=Object.getOwnPropertyDescriptors,MB=Object.getOwnPropertySymbols,BAe=Object.prototype.hasOwnProperty,jAe=Object.prototype.propertyIsEnumerable,FB=(e,t,n)=>t in e?LAe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,BB=(e,t)=>{for(var n in t||(t={}))BAe.call(t,n)&&FB(e,n,t[n]);if(MB)for(var n of MB(t))jAe.call(t,n)&&FB(e,n,t[n]);return e},jB=(e,t)=>MAe(e,FAe(t)),UAe=lt((e,{radius:t})=>({root:{},imageWrapper:{position:"relative"},figure:{margin:0},image:jB(BB({},e.fn.fontStyles()),{display:"block",width:"100%",height:"100%",border:0,borderRadius:e.fn.size({size:t,sizes:e.radius})}),caption:{color:e.colorScheme==="dark"?e.colors.dark[2]:e.colors.gray[7],marginTop:e.spacing.xs},placeholder:jB(BB({},e.fn.cover()),{display:"flex",alignItems:"center",justifyContent:"center",color:e.colorScheme==="dark"?e.colors.dark[2]:e.colors.gray[6],backgroundColor:e.colorScheme==="dark"?e.colors.dark[8]:e.colors.gray[0],borderRadius:e.fn.size({size:t,sizes:e.radius})})})),VAe=Object.defineProperty,US=Object.getOwnPropertySymbols,LZ=Object.prototype.hasOwnProperty,MZ=Object.prototype.propertyIsEnumerable,UB=(e,t,n)=>t in e?VAe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,VP=(e,t)=>{for(var n in t||(t={}))LZ.call(t,n)&&UB(e,n,t[n]);if(US)for(var n of US(t))MZ.call(t,n)&&UB(e,n,t[n]);return e},zAe=(e,t)=>{var n={};for(var r in e)LZ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&US)for(var r of US(e))t.indexOf(r)<0&&MZ.call(e,r)&&(n[r]=e[r]);return n};const HAe={fit:"cover",width:"100%",height:"auto",radius:0},B_=w.forwardRef((e,t)=>{const n=Ve("Image",HAe,e),{className:r,alt:i,src:s,fit:o,width:a,height:u,radius:l,imageProps:c,withPlaceholder:f,placeholder:d,imageRef:h,classNames:p,styles:m,caption:y,unstyled:g,style:v}=n,b=zAe(n,["className","alt","src","fit","width","height","radius","imageProps","withPlaceholder","placeholder","imageRef","classNames","styles","caption","unstyled","style"]),{classes:S,cx:T}=UAe({radius:l},{classNames:p,styles:m,unstyled:g,name:"Image"}),[E,I]=w.useState(!s),A=f&&E;return Js(()=>{I(!s)},[s]),N.createElement(it,VP({className:T(S.root,r),ref:t,style:VP({width:a},v)},b),N.createElement("figure",{className:S.figure},N.createElement("div",{className:S.imageWrapper},N.createElement("img",VP({className:S.image,src:s,alt:i,style:{objectFit:o,width:a,height:u},ref:h,onError:R=>{I(!0),typeof(c==null?void 0:c.onError)=="function"&&c.onError(R)}},c)),A&&N.createElement("div",{className:S.placeholder,title:i},d||N.createElement("div",null,N.createElement($Ae,{style:{width:40,height:40}})))),!!y&&N.createElement(rt,{component:"figcaption",size:"sm",align:"center",className:S.caption},y)))});B_.displayName="@mantine/core/Image";function WAe(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,s;for(s=0;s=0)&&(n[i]=e[i]);return n}var qAe=w.useLayoutEffect,GAe=function(t){var n=w.useRef(t);return qAe(function(){n.current=t}),n},VB=function(t,n){if(typeof t=="function"){t(n);return}t.current=n},YAe=function(t,n){var r=w.useRef();return w.useCallback(function(i){t.current=i,r.current&&VB(r.current,null),r.current=n,n&&VB(n,i)},[n])},zB={"min-height":"0","max-height":"none",height:"0",visibility:"hidden",overflow:"hidden",position:"absolute","z-index":"-1000",top:"0",right:"0"},HB=function(t){Object.keys(zB).forEach(function(n){t.style.setProperty(n,zB[n],"important")})},fo=null,KAe=function(t,n){var r=t.scrollHeight;return n.sizingStyle.boxSizing==="border-box"?r+n.borderSize:r-n.paddingSize};function QAe(e,t,n,r){n===void 0&&(n=1),r===void 0&&(r=1/0),fo||(fo=document.createElement("textarea"),fo.setAttribute("tabindex","-1"),fo.setAttribute("aria-hidden","true"),HB(fo)),fo.parentNode===null&&document.body.appendChild(fo);var i=e.paddingSize,s=e.borderSize,o=e.sizingStyle,a=o.boxSizing;Object.keys(o).forEach(function(d){var h=d;fo.style[h]=o[h]}),HB(fo),fo.value=t;var u=KAe(fo,e);fo.value="x";var l=fo.scrollHeight-i,c=l*n;a==="border-box"&&(c=c+i+s),u=Math.max(c,u);var f=l*r;return a==="border-box"&&(f=f+i+s),u=Math.min(f,u),[u,l]}var WB=function(){},XAe=function(t,n){return t.reduce(function(r,i){return r[i]=n[i],r},{})},JAe=["borderBottomWidth","borderLeftWidth","borderRightWidth","borderTopWidth","boxSizing","fontFamily","fontSize","fontStyle","fontWeight","letterSpacing","lineHeight","paddingBottom","paddingLeft","paddingRight","paddingTop","tabSize","textIndent","textRendering","textTransform","width","wordBreak"],ZAe=!!document.documentElement.currentStyle,ePe=function(t){var n=window.getComputedStyle(t);if(n===null)return null;var r=XAe(JAe,n),i=r.boxSizing;if(i==="")return null;ZAe&&i==="border-box"&&(r.width=parseFloat(r.width)+parseFloat(r.borderRightWidth)+parseFloat(r.borderLeftWidth)+parseFloat(r.paddingRight)+parseFloat(r.paddingLeft)+"px");var s=parseFloat(r.paddingBottom)+parseFloat(r.paddingTop),o=parseFloat(r.borderBottomWidth)+parseFloat(r.borderTopWidth);return{sizingStyle:r,paddingSize:s,borderSize:o}},tPe=function(t){var n=GAe(t);w.useLayoutEffect(function(){var r=function(s){n.current(s)};return window.addEventListener("resize",r),function(){window.removeEventListener("resize",r)}},[])},nPe=function(t,n){var r=t.cacheMeasurements,i=t.maxRows,s=t.minRows,o=t.onChange,a=o===void 0?WB:o,u=t.onHeightChange,l=u===void 0?WB:u,c=WAe(t,["cacheMeasurements","maxRows","minRows","onChange","onHeightChange"]),f=c.value!==void 0,d=w.useRef(null),h=YAe(d,n),p=w.useRef(0),m=w.useRef(),y=function(){var b=d.current,S=r&&m.current?m.current:ePe(b);if(S){m.current=S;var T=QAe(S,b.value||b.placeholder||"x",s,i),E=T[0],I=T[1];p.current!==E&&(p.current=E,b.style.setProperty("height",E+"px","important"),l(E,{rowHeight:I}))}},g=function(b){f||y(),a(b)};return w.useLayoutEffect(y),tPe(y),w.createElement("textarea",pr({},c,{onChange:g,ref:h}))},rPe=w.forwardRef(nPe);const iPe=rPe;var sPe=lt(e=>({input:{paddingTop:e.spacing.xs,paddingBottom:e.spacing.xs}})),oPe=Object.defineProperty,aPe=Object.defineProperties,uPe=Object.getOwnPropertyDescriptors,VS=Object.getOwnPropertySymbols,FZ=Object.prototype.hasOwnProperty,BZ=Object.prototype.propertyIsEnumerable,qB=(e,t,n)=>t in e?oPe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Jh=(e,t)=>{for(var n in t||(t={}))FZ.call(t,n)&&qB(e,n,t[n]);if(VS)for(var n of VS(t))BZ.call(t,n)&&qB(e,n,t[n]);return e},zP=(e,t)=>aPe(e,uPe(t)),lPe=(e,t)=>{var n={};for(var r in e)FZ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&VS)for(var r of VS(e))t.indexOf(r)<0&&BZ.call(e,r)&&(n[r]=e[r]);return n};const cPe={autosize:!1,size:"sm",__staticSelector:"Textarea"},jZ=w.forwardRef((e,t)=>{const n=Ve("Textarea",cPe,e),{autosize:r,maxRows:i,minRows:s,label:o,error:a,description:u,id:l,className:c,required:f,style:d,wrapperProps:h,classNames:p,styles:m,size:y,__staticSelector:g,sx:v,errorProps:b,descriptionProps:S,labelProps:T,inputWrapperOrder:E,inputContainer:I,unstyled:A,withAsterisk:R}=n,F=lPe(n,["autosize","maxRows","minRows","label","error","description","id","className","required","style","wrapperProps","classNames","styles","size","__staticSelector","sx","errorProps","descriptionProps","labelProps","inputWrapperOrder","inputContainer","unstyled","withAsterisk"]),L=tu(l),{classes:B,cx:J}=sPe(),{systemStyles:V,rest:re}=Qf(F),oe=Jh({required:f,ref:t,invalid:!!a,id:L,classNames:zP(Jh({},p),{input:J(B.input,p==null?void 0:p.input)}),styles:m,__staticSelector:g,size:y,multiline:!0,unstyled:A},re);return N.createElement(Zs.Wrapper,Jh(Jh({label:o,error:a,id:L,description:u,required:f,style:d,className:c,classNames:p,styles:m,size:y,__staticSelector:g,sx:v,errorProps:b,labelProps:T,descriptionProps:S,inputContainer:I,inputWrapperOrder:E,unstyled:A,withAsterisk:R},V),h),r?N.createElement(Zs,zP(Jh({},oe),{component:iPe,maxRows:i,minRows:s})):N.createElement(Zs,zP(Jh({},oe),{component:"textarea",rows:s})))});jZ.displayName="@mantine/core/Textarea";const[fPe,dPe]=N_("List component was not found in tree");var hPe=lt((e,{spacing:t,center:n},r)=>({itemWrapper:{ref:r("itemWrapper"),display:"inline-flex",flexDirection:"column",whiteSpace:"normal"},item:{whiteSpace:"nowrap",lineHeight:n?1:e.lineHeight,"&:not(:first-of-type)":{marginTop:e.fn.size({size:t,sizes:e.spacing})}},withIcon:{listStyle:"none",[`& .${r("itemWrapper")}`]:{display:"inline-flex",alignItems:n?"center":"flex-start",flexDirection:"row"}},itemIcon:{display:"inline-block",verticalAlign:"middle",marginRight:e.spacing.sm}})),pPe=Object.defineProperty,zS=Object.getOwnPropertySymbols,UZ=Object.prototype.hasOwnProperty,VZ=Object.prototype.propertyIsEnumerable,GB=(e,t,n)=>t in e?pPe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,mPe=(e,t)=>{for(var n in t||(t={}))UZ.call(t,n)&&GB(e,n,t[n]);if(zS)for(var n of zS(t))VZ.call(t,n)&&GB(e,n,t[n]);return e},gPe=(e,t)=>{var n={};for(var r in e)UZ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&zS)for(var r of zS(e))t.indexOf(r)<0&&VZ.call(e,r)&&(n[r]=e[r]);return n};const yPe={},zZ=w.forwardRef((e,t)=>{const n=Ve("ListItem",yPe,e),{className:r,children:i,icon:s}=n,o=gPe(n,["className","children","icon"]),{icon:a,spacing:u,center:l,listStyleType:c,size:f,withPadding:d,classNames:h,styles:p,unstyled:m}=dPe(),y=s||a,{classes:g,cx:v}=hPe({withPadding:d,size:f,listStyleType:c,center:l,spacing:u},{classNames:h,styles:p,unstyled:m,name:"List"});return N.createElement(it,mPe({component:"li",className:v(g.item,{[g.withIcon]:y},r),ref:t},o),N.createElement("div",{className:g.itemWrapper},y&&N.createElement("span",{className:g.itemIcon},y),N.createElement("span",null,i)))});zZ.displayName="@mantine/core/ListItem";var vPe=Object.defineProperty,_Pe=Object.defineProperties,bPe=Object.getOwnPropertyDescriptors,YB=Object.getOwnPropertySymbols,wPe=Object.prototype.hasOwnProperty,EPe=Object.prototype.propertyIsEnumerable,KB=(e,t,n)=>t in e?vPe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,SPe=(e,t)=>{for(var n in t||(t={}))wPe.call(t,n)&&KB(e,n,t[n]);if(YB)for(var n of YB(t))EPe.call(t,n)&&KB(e,n,t[n]);return e},TPe=(e,t)=>_Pe(e,bPe(t)),IPe=lt((e,{withPadding:t,size:n,listStyleType:r})=>({root:TPe(SPe({},e.fn.fontStyles()),{listStyleType:r,color:e.colorScheme==="dark"?e.colors.dark[0]:e.black,fontSize:e.fn.size({size:n,sizes:e.fontSizes}),lineHeight:e.lineHeight,margin:0,paddingLeft:t?e.spacing.xl:0,listStylePosition:"inside"})})),xPe=Object.defineProperty,HS=Object.getOwnPropertySymbols,HZ=Object.prototype.hasOwnProperty,WZ=Object.prototype.propertyIsEnumerable,QB=(e,t,n)=>t in e?xPe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,CPe=(e,t)=>{for(var n in t||(t={}))HZ.call(t,n)&&QB(e,n,t[n]);if(HS)for(var n of HS(t))WZ.call(t,n)&&QB(e,n,t[n]);return e},APe=(e,t)=>{var n={};for(var r in e)HZ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&HS)for(var r of HS(e))t.indexOf(r)<0&&WZ.call(e,r)&&(n[r]=e[r]);return n};const PPe={type:"unordered",size:"md",spacing:0},Bm=w.forwardRef((e,t)=>{const n=Ve("List",PPe,e),{children:r,type:i,size:s,listStyleType:o,withPadding:a,center:u,spacing:l,icon:c,className:f,styles:d,classNames:h,unstyled:p}=n,m=APe(n,["children","type","size","listStyleType","withPadding","center","spacing","icon","className","styles","classNames","unstyled"]),{classes:y,cx:g}=IPe({withPadding:a,size:s,listStyleType:o,center:u,spacing:l},{classNames:h,styles:d,name:"List",unstyled:p});return N.createElement(fPe,{value:{spacing:l,center:u,icon:c,listStyleType:o,size:s,withPadding:a,classNames:h,styles:d,unstyled:p}},N.createElement(it,CPe({component:i==="unordered"?"ul":"ol",className:g(y.root,f),ref:t},m),r))});Bm.Item=zZ;Bm.displayName="@mantine/core/List";const qZ={context:"Menu component was not found in the tree",children:"Menu.Target component children should be an element or a component that accepts ref, fragments, strings, numbers and other primitive values are not supported"},[OPe,j_]=N_(qZ.context);var RPe=lt(e=>({divider:{margin:`calc(${e.spacing.xs}px / 2) -5px`,borderTop:`1px solid ${e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[2]}`}})),NPe=Object.defineProperty,WS=Object.getOwnPropertySymbols,GZ=Object.prototype.hasOwnProperty,YZ=Object.prototype.propertyIsEnumerable,XB=(e,t,n)=>t in e?NPe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,kPe=(e,t)=>{for(var n in t||(t={}))GZ.call(t,n)&&XB(e,n,t[n]);if(WS)for(var n of WS(t))YZ.call(t,n)&&XB(e,n,t[n]);return e},DPe=(e,t)=>{var n={};for(var r in e)GZ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&WS)for(var r of WS(e))t.indexOf(r)<0&&YZ.call(e,r)&&(n[r]=e[r]);return n};const $Pe={},KZ=w.forwardRef((e,t)=>{const n=Ve("MenuDivider",$Pe,e),{children:r,className:i}=n,s=DPe(n,["children","className"]),{classNames:o,styles:a,unstyled:u}=j_(),{classes:l,cx:c}=RPe(null,{name:"Menu",classNames:o,styles:a,unstyled:u});return N.createElement(it,kPe({className:c(l.divider,i),ref:t},s))});KZ.displayName="@mantine/core/MenuDivider";var LPe=Object.defineProperty,qS=Object.getOwnPropertySymbols,QZ=Object.prototype.hasOwnProperty,XZ=Object.prototype.propertyIsEnumerable,JB=(e,t,n)=>t in e?LPe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,MPe=(e,t)=>{for(var n in t||(t={}))QZ.call(t,n)&&JB(e,n,t[n]);if(qS)for(var n of qS(t))XZ.call(t,n)&&JB(e,n,t[n]);return e},FPe=(e,t)=>{var n={};for(var r in e)QZ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&qS)for(var r of qS(e))t.indexOf(r)<0&&XZ.call(e,r)&&(n[r]=e[r]);return n};const BPe={};function JZ(e){const t=Ve("MenuDropdown",BPe,e),{children:n,onMouseEnter:r,onMouseLeave:i}=t,s=FPe(t,["children","onMouseEnter","onMouseLeave"]),o=w.useRef(),a=j_(),u=f=>{(f.key==="ArrowUp"||f.key==="ArrowDown")&&(f.preventDefault(),o.current.querySelectorAll("[data-menu-item]")[0].focus())},l=wo(r,()=>a.trigger==="hover"&&a.openDropdown()),c=wo(i,()=>a.trigger==="hover"&&a.closeDropdown());return N.createElement(yi.Dropdown,MPe({onMouseEnter:l,onMouseLeave:c,role:"menu","aria-orientation":"vertical"},s),N.createElement("div",{tabIndex:-1,"data-menu-dropdown":!0,"data-autofocus":!0,onKeyDown:u,ref:o,style:{outline:0}},n))}JZ.displayName="@mantine/core/MenuDropdown";var jPe=Object.defineProperty,UPe=Object.defineProperties,VPe=Object.getOwnPropertyDescriptors,ZB=Object.getOwnPropertySymbols,zPe=Object.prototype.hasOwnProperty,HPe=Object.prototype.propertyIsEnumerable,ej=(e,t,n)=>t in e?jPe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,WPe=(e,t)=>{for(var n in t||(t={}))zPe.call(t,n)&&ej(e,n,t[n]);if(ZB)for(var n of ZB(t))HPe.call(t,n)&&ej(e,n,t[n]);return e},qPe=(e,t)=>UPe(e,VPe(t)),GPe=lt((e,{color:t,radius:n})=>({item:qPe(WPe({},e.fn.fontStyles()),{WebkitTapHighlightColor:"transparent",fontSize:e.fontSizes.sm,border:0,backgroundColor:"transparent",outline:0,width:"100%",textAlign:"left",textDecoration:"none",boxSizing:"border-box",padding:`${e.spacing.xs}px ${e.spacing.sm}px`,cursor:"pointer",borderRadius:e.fn.radius(n),color:t?e.fn.variant({variant:"filled",primaryFallback:!1,color:t}).background:e.colorScheme==="dark"?e.colors.dark[0]:e.black,display:"flex",alignItems:"center","&:disabled":{color:e.colorScheme==="dark"?e.colors.dark[3]:e.colors.gray[5],pointerEvents:"none",userSelect:"none"},"&[data-hovered]":{backgroundColor:t?e.fn.variant({variant:"light",color:t}).background:e.colorScheme==="dark"?e.fn.rgba(e.colors.dark[3],.35):e.colors.gray[1]}}),itemLabel:{flex:1},itemIcon:{display:"flex",justifyContent:"center",alignItems:"center",marginRight:e.spacing.xs},itemRightSection:{}}));const YPe=GPe;var KPe=Object.defineProperty,QPe=Object.defineProperties,XPe=Object.getOwnPropertyDescriptors,GS=Object.getOwnPropertySymbols,ZZ=Object.prototype.hasOwnProperty,eee=Object.prototype.propertyIsEnumerable,tj=(e,t,n)=>t in e?KPe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,JPe=(e,t)=>{for(var n in t||(t={}))ZZ.call(t,n)&&tj(e,n,t[n]);if(GS)for(var n of GS(t))eee.call(t,n)&&tj(e,n,t[n]);return e},ZPe=(e,t)=>QPe(e,XPe(t)),eOe=(e,t)=>{var n={};for(var r in e)ZZ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&GS)for(var r of GS(e))t.indexOf(r)<0&&eee.call(e,r)&&(n[r]=e[r]);return n};const tOe={},tee=w.forwardRef((e,t)=>{const n=Ve("MenuItem",tOe,e),{children:r,className:i,color:s,closeMenuOnClick:o,icon:a,rightSection:u}=n,l=eOe(n,["children","className","color","closeMenuOnClick","icon","rightSection"]),c=j_(),{classes:f,cx:d,theme:h}=YPe({radius:c.radius,color:s},{name:"Menu",classNames:c.classNames,styles:c.styles,unstyled:c.unstyled}),p=w.useRef(),m=c.getItemIndex(p.current),y=l,g=wo(y.onMouseLeave,()=>c.setHovered(-1)),v=wo(y.onMouseEnter,()=>c.setHovered(c.getItemIndex(p.current))),b=wo(y.onClick,()=>{typeof o=="boolean"?o&&c.closeDropdownImmediately():c.closeOnItemClick&&c.closeDropdownImmediately()}),S=wo(y.onFocus,()=>c.setHovered(c.getItemIndex(p.current)));return N.createElement(it,ZPe(JPe({component:"button",type:"button"},l),{tabIndex:-1,onFocus:S,className:d(f.item,i),ref:fa(p,t),role:"menuitem","data-menu-item":!0,"data-hovered":c.hovered===m?!0:void 0,onMouseEnter:v,onMouseLeave:g,onClick:b,onKeyDown:w0e({siblingSelector:"[data-menu-item]",parentSelector:"[data-menu-dropdown]",activateOnFocus:!1,loop:c.loop,dir:h.dir,orientation:"vertical",onKeyDown:y.onKeydown})}),a&&N.createElement("div",{className:f.itemIcon},a),r&&N.createElement("div",{className:f.itemLabel},r),u&&N.createElement("div",{className:f.itemRightSection},u))});tee.displayName="@mantine/core/MenuItem";const nOe=tee;var rOe=lt(e=>({label:{color:e.colorScheme==="dark"?e.colors.dark[2]:e.colors.gray[6],fontWeight:500,fontSize:e.fontSizes.xs,padding:`calc(${e.spacing.xs}px / 2) ${e.spacing.sm}px`,cursor:"default"}})),iOe=Object.defineProperty,YS=Object.getOwnPropertySymbols,nee=Object.prototype.hasOwnProperty,ree=Object.prototype.propertyIsEnumerable,nj=(e,t,n)=>t in e?iOe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,sOe=(e,t)=>{for(var n in t||(t={}))nee.call(t,n)&&nj(e,n,t[n]);if(YS)for(var n of YS(t))ree.call(t,n)&&nj(e,n,t[n]);return e},oOe=(e,t)=>{var n={};for(var r in e)nee.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&YS)for(var r of YS(e))t.indexOf(r)<0&&ree.call(e,r)&&(n[r]=e[r]);return n};const aOe={},iee=w.forwardRef((e,t)=>{const n=Ve("MenuLabel",aOe,e),{children:r,className:i}=n,s=oOe(n,["children","className"]),{classNames:o,styles:a,unstyled:u}=j_(),{classes:l,cx:c}=rOe(null,{name:"Menu",classNames:o,styles:a,unstyled:u});return N.createElement(rt,sOe({className:c(l.label,i),ref:t},s),r)});iee.displayName="@mantine/core/MenuLabel";var uOe=Object.defineProperty,KS=Object.getOwnPropertySymbols,see=Object.prototype.hasOwnProperty,oee=Object.prototype.propertyIsEnumerable,rj=(e,t,n)=>t in e?uOe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,lOe=(e,t)=>{for(var n in t||(t={}))see.call(t,n)&&rj(e,n,t[n]);if(KS)for(var n of KS(t))oee.call(t,n)&&rj(e,n,t[n]);return e},cOe=(e,t)=>{var n={};for(var r in e)see.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&KS)for(var r of KS(e))t.indexOf(r)<0&&oee.call(e,r)&&(n[r]=e[r]);return n};const fOe={refProp:"ref"},aee=w.forwardRef((e,t)=>{const n=Ve("MenuTarget",fOe,e),{children:r,refProp:i}=n,s=cOe(n,["children","refProp"]);if(!_g(r))throw new Error(qZ.children);const o=j_(),a=wo(r.props.onClick,()=>o.trigger==="click"&&o.toggleDropdown()),u=wo(r.props.onMouseEnter,()=>o.trigger==="hover"&&o.openDropdown()),l=wo(r.props.onMouseLeave,()=>o.trigger==="hover"&&o.closeDropdown());return N.createElement(yi.Target,lOe({refProp:i,popupType:"menu",ref:t},s),w.cloneElement(r,{onClick:a,onMouseEnter:u,onMouseLeave:l,"data-expanded":o.opened?!0:void 0}))});aee.displayName="@mantine/core/MenuTarget";var dOe=lt({dropdown:{padding:4}}),hOe=Object.defineProperty,pOe=Object.defineProperties,mOe=Object.getOwnPropertyDescriptors,QS=Object.getOwnPropertySymbols,uee=Object.prototype.hasOwnProperty,lee=Object.prototype.propertyIsEnumerable,ij=(e,t,n)=>t in e?hOe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,sj=(e,t)=>{for(var n in t||(t={}))uee.call(t,n)&&ij(e,n,t[n]);if(QS)for(var n of QS(t))lee.call(t,n)&&ij(e,n,t[n]);return e},oj=(e,t)=>pOe(e,mOe(t)),gOe=(e,t)=>{var n={};for(var r in e)uee.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&QS)for(var r of QS(e))t.indexOf(r)<0&&lee.call(e,r)&&(n[r]=e[r]);return n};const yOe={closeOnItemClick:!0,loop:!0,trigger:"click",openDelay:0,closeDelay:100};function ts(e){const t=Ve("Menu",yOe,e),{children:n,onOpen:r,onClose:i,opened:s,defaultOpened:o,onChange:a,closeOnItemClick:u,loop:l,closeOnEscape:c,trigger:f,openDelay:d,closeDelay:h,classNames:p,styles:m,unstyled:y,radius:g}=t,v=gOe(t,["children","onOpen","onClose","opened","defaultOpened","onChange","closeOnItemClick","loop","closeOnEscape","trigger","openDelay","closeDelay","classNames","styles","unstyled","radius"]),{classes:b,cx:S}=dOe(),[T,{setHovered:E,resetHovered:I}]=x0e(),[A,R]=oa({value:s,defaultValue:o,finalValue:!1,onChange:a}),F=()=>{R(!1),A&&(i==null||i())},L=()=>{R(!0),!A&&(r==null||r())},B=()=>A?F():L(),{openDropdown:J,closeDropdown:V}=kZ({open:L,close:F,closeDelay:h,openDelay:d}),re=oe=>E0e("[data-menu-item]","[data-menu-dropdown]",oe);return Js(()=>{I()},[A]),N.createElement(OPe,{value:{opened:A,toggleDropdown:B,getItemIndex:re,hovered:T,setHovered:E,closeOnItemClick:u,closeDropdown:f==="click"?F:V,openDropdown:f==="click"?L:J,closeDropdownImmediately:F,loop:l,trigger:f,radius:g,classNames:p,styles:m,unstyled:y}},N.createElement(yi,oj(sj({},v),{radius:g,opened:A,onChange:R,defaultOpened:o,trapFocus:f==="click",closeOnEscape:c&&f==="click",__staticSelector:"Menu",classNames:oj(sj({},p),{dropdown:S(b.dropdown,p==null?void 0:p.dropdown)}),styles:m,unstyled:y,onClose:F,onOpen:L}),n))}ts.displayName="@mantine/core/Menu";ts.Item=nOe;ts.Label=iee;ts.Dropdown=JZ;ts.Target=aee;ts.Divider=KZ;var vOe=Object.defineProperty,aj=Object.getOwnPropertySymbols,_Oe=Object.prototype.hasOwnProperty,bOe=Object.prototype.propertyIsEnumerable,uj=(e,t,n)=>t in e?vOe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,wOe=(e,t)=>{for(var n in t||(t={}))_Oe.call(t,n)&&uj(e,n,t[n]);if(aj)for(var n of aj(t))bOe.call(t,n)&&uj(e,n,t[n]);return e};const EOe={xs:320,sm:380,md:440,lg:620,xl:780};function SOe(e){return e?{position:"absolute",top:0,left:0,right:0,bottom:0,maxHeight:"100vh",overflowY:"auto"}:{}}var TOe=lt((e,{overflow:t,size:n,centered:r,zIndex:i,fullScreen:s})=>({close:{},overlay:{display:s?"none":void 0},root:{position:"fixed",zIndex:i,top:0,left:0,right:0,bottom:0},inner:{position:"absolute",top:0,left:0,right:0,bottom:0,overflowY:"auto",padding:s?0:`${e.spacing.xl*2}px ${e.spacing.md}px`,display:"flex",justifyContent:"center",alignItems:r?"center":"flex-start"},title:{marginRight:e.spacing.md,textOverflow:"ellipsis",display:"block",wordBreak:"break-word"},modal:wOe({position:"relative",width:s?"100vw":e.fn.size({sizes:EOe,size:n}),borderRadius:s?0:void 0,outline:0,backgroundColor:e.colorScheme==="dark"?e.colors.dark[7]:e.white,marginTop:r?"auto":void 0,marginBottom:r?"auto":void 0,zIndex:1},SOe(s)),header:{display:"flex",alignItems:"center",justifyContent:"space-between",marginBottom:e.spacing.md,marginRight:-9},body:{maxHeight:t==="inside"?"calc(100vh - 185px)":null,overflowY:t==="inside"?"auto":null,wordBreak:"break-word"}})),IOe=Object.defineProperty,XS=Object.getOwnPropertySymbols,cee=Object.prototype.hasOwnProperty,fee=Object.prototype.propertyIsEnumerable,lj=(e,t,n)=>t in e?IOe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,xOe=(e,t)=>{for(var n in t||(t={}))cee.call(t,n)&&lj(e,n,t[n]);if(XS)for(var n of XS(t))fee.call(t,n)&&lj(e,n,t[n]);return e},COe=(e,t)=>{var n={};for(var r in e)cee.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&XS)for(var r of XS(e))t.indexOf(r)<0&&fee.call(e,r)&&(n[r]=e[r]);return n};const AOe={size:"md",transitionDuration:250,overflow:"outside",padding:"lg",shadow:"lg",closeOnClickOutside:!0,closeOnEscape:!0,trapFocus:!0,withCloseButton:!0,withinPortal:!0,lockScroll:!0,withFocusReturn:!0,overlayBlur:0,zIndex:cc("modal"),exitTransitionDuration:0};function zx(e){const t=Ve("Modal",AOe,e),{className:n,opened:r,title:i,onClose:s,children:o,withCloseButton:a,overlayOpacity:u,size:l,transitionDuration:c,exitTransitionDuration:f,closeButtonLabel:d,overlayColor:h,overflow:p,transition:m,padding:y,shadow:g,radius:v,id:b,classNames:S,styles:T,closeOnClickOutside:E,trapFocus:I,closeOnEscape:A,centered:R,target:F,withinPortal:L,zIndex:B,overlayBlur:J,transitionTimingFunction:V,fullScreen:re,unstyled:oe,lockScroll:ae,withFocusReturn:ee}=t,ue=COe(t,["className","opened","title","onClose","children","withCloseButton","overlayOpacity","size","transitionDuration","exitTransitionDuration","closeButtonLabel","overlayColor","overflow","transition","padding","shadow","radius","id","classNames","styles","closeOnClickOutside","trapFocus","closeOnEscape","centered","target","withinPortal","zIndex","overlayBlur","transitionTimingFunction","fullScreen","unstyled","lockScroll","withFocusReturn"]),P=tu(b),W=`${P}-title`,Q=`${P}-body`,{classes:x,cx:O,theme:$}=TOe({size:l,overflow:p,centered:R,zIndex:B,fullScreen:re},{unstyled:oe,classNames:S,styles:T,name:"Modal"}),q=jK(I&&r),ce=w.useRef(null),fe=fa(q,ce),de=typeof u=="number"?u:$.colorScheme==="dark"?.85:.75;Qve(ae&&r);const ve=nt=>{!I&&nt.key==="Escape"&&A&&s()};w.useEffect(()=>{if(!I)return window.addEventListener("keydown",ve),()=>window.removeEventListener("keydown",ve)},[I]),LK({opened:r,shouldReturnFocus:I&&ee});const Ee=w.useRef(null);UR("mousedown",nt=>{Ee.current=nt.target});const ge=()=>{Ee.current===ce.current&&E&&s()};return N.createElement($_,{withinPortal:L,target:F},N.createElement(iZ,{mounted:r,duration:c,exitDuration:f,timingFunction:V,transitions:{modal:{duration:c,transition:m||(re?"fade":"pop")},overlay:{duration:c/2,transition:"fade",timingFunction:"ease"}}},nt=>N.createElement(N.Fragment,null,N.createElement(it,xOe({id:P,className:O(x.root,n)},ue),N.createElement("div",{style:nt.overlay},N.createElement(ACe,{className:x.overlay,sx:{position:"fixed"},zIndex:0,blur:J,color:h||($.colorScheme==="dark"?$.colors.dark[9]:$.black),opacity:de,unstyled:oe})),N.createElement("div",{role:"presentation",className:x.inner,onClick:ge,onKeyDown:Je=>{var yt;((yt=Je.target)==null?void 0:yt.getAttribute("data-mantine-stop-propagation"))!=="true"&&Je.key==="Escape"&&A&&s()},ref:fe},N.createElement(wS,{className:x.modal,shadow:g,p:y,radius:v,role:"dialog","aria-labelledby":W,"aria-describedby":Q,"aria-modal":!0,tabIndex:-1,style:nt.modal,unstyled:oe,onClick:Je=>Je.stopPropagation()},(i||a)&&N.createElement("div",{className:x.header},N.createElement(rt,{id:W,className:x.title},i),a&&N.createElement(Dx,{iconSize:16,onClick:s,"aria-label":d,className:x.close})),N.createElement("div",{id:Q,className:x.body},o)))))))}zx.displayName="@mantine/core/Modal";const POe={xs:16,sm:22,md:26,lg:30,xl:36},OOe={xs:10,sm:12,md:14,lg:16,xl:18};var ROe=lt((e,{size:t,disabled:n,radius:r,readOnly:i,variant:s})=>({defaultValue:{display:"flex",alignItems:"center",backgroundColor:n?e.colorScheme==="dark"?e.colors.dark[5]:e.colors.gray[3]:e.colorScheme==="dark"?e.colors.dark[7]:s==="filled"?e.white:e.colors.gray[1],color:n?e.colorScheme==="dark"?e.colors.dark[1]:e.colors.gray[7]:e.colorScheme==="dark"?e.colors.dark[0]:e.colors.gray[7],height:e.fn.size({size:t,sizes:POe}),paddingLeft:e.fn.size({size:t,sizes:e.spacing}),paddingRight:n||i?e.fn.size({size:t,sizes:e.spacing}):0,fontWeight:500,fontSize:e.fn.size({size:t,sizes:OOe}),borderRadius:e.fn.size({size:r,sizes:e.radius}),cursor:n?"not-allowed":"default",userSelect:"none",maxWidth:"calc(100% - 20px)"},defaultValueRemove:{color:e.colorScheme==="dark"?e.colors.dark[0]:e.colors.gray[7],marginLeft:e.fn.size({size:t,sizes:e.spacing})/6},defaultValueLabel:{display:"block",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"}})),NOe=Object.defineProperty,JS=Object.getOwnPropertySymbols,dee=Object.prototype.hasOwnProperty,hee=Object.prototype.propertyIsEnumerable,cj=(e,t,n)=>t in e?NOe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,kOe=(e,t)=>{for(var n in t||(t={}))dee.call(t,n)&&cj(e,n,t[n]);if(JS)for(var n of JS(t))hee.call(t,n)&&cj(e,n,t[n]);return e},DOe=(e,t)=>{var n={};for(var r in e)dee.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&JS)for(var r of JS(e))t.indexOf(r)<0&&hee.call(e,r)&&(n[r]=e[r]);return n};const fj={xs:16,sm:22,md:24,lg:26,xl:30};function pee(e){var t=e,{label:n,classNames:r,styles:i,className:s,onRemove:o,disabled:a,readOnly:u,size:l,radius:c="sm",variant:f}=t,d=DOe(t,["label","classNames","styles","className","onRemove","disabled","readOnly","size","radius","variant"]);const{classes:h,cx:p}=ROe({size:l,disabled:a,readOnly:u,radius:c,variant:f},{classNames:r,styles:i,name:"MultiSelect"});return N.createElement("div",kOe({className:p(h.defaultValue,s)},d),N.createElement("span",{className:h.defaultValueLabel},n),!a&&!u&&N.createElement(Dx,{"aria-hidden":!0,onMouseDown:o,size:fj[l],radius:2,color:"blue",variant:"transparent",iconSize:fj[l]/2,className:h.defaultValueRemove,tabIndex:-1}))}pee.displayName="@mantine/core/MultiSelect/DefaultValue";function $Oe({data:e,searchable:t,limit:n,searchValue:r,filter:i,value:s,disableSelectedItemFiltering:o}){if(!t&&s.length===0)return e;if(!t){const u=[];for(let l=0;lc===e[l].value&&!e[l].disabled))&&u.push(e[l]);return u}const a=[];for(let u=0;ul===e[u].value&&!e[u].disabled),e[u])&&a.push(e[u]),!(a.length>=n));u+=1);return a}var LOe=Object.defineProperty,ZS=Object.getOwnPropertySymbols,mee=Object.prototype.hasOwnProperty,gee=Object.prototype.propertyIsEnumerable,dj=(e,t,n)=>t in e?LOe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,hj=(e,t)=>{for(var n in t||(t={}))mee.call(t,n)&&dj(e,n,t[n]);if(ZS)for(var n of ZS(t))gee.call(t,n)&&dj(e,n,t[n]);return e},MOe=(e,t)=>{var n={};for(var r in e)mee.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&ZS)for(var r of ZS(e))t.indexOf(r)<0&&gee.call(e,r)&&(n[r]=e[r]);return n};const FOe={xs:14,sm:18,md:20,lg:24,xl:28};function BOe(e){var t=e,{size:n,error:r,style:i}=t,s=MOe(t,["size","error","style"]);const o=ji(),a=o.fn.size({size:n,sizes:FOe});return N.createElement("svg",hj({width:a,height:a,viewBox:"0 0 15 15",fill:"none",xmlns:"http://www.w3.org/2000/svg",style:hj({color:r?o.colors.red[6]:o.colors.gray[6]},i),"data-chevron":!0},s),N.createElement("path",{d:"M4.93179 5.43179C4.75605 5.60753 4.75605 5.89245 4.93179 6.06819C5.10753 6.24392 5.39245 6.24392 5.56819 6.06819L7.49999 4.13638L9.43179 6.06819C9.60753 6.24392 9.89245 6.24392 10.0682 6.06819C10.2439 5.89245 10.2439 5.60753 10.0682 5.43179L7.81819 3.18179C7.73379 3.0974 7.61933 3.04999 7.49999 3.04999C7.38064 3.04999 7.26618 3.0974 7.18179 3.18179L4.93179 5.43179ZM10.0682 9.56819C10.2439 9.39245 10.2439 9.10753 10.0682 8.93179C9.89245 8.75606 9.60753 8.75606 9.43179 8.93179L7.49999 10.8636L5.56819 8.93179C5.39245 8.75606 5.10753 8.75606 4.93179 8.93179C4.75605 9.10753 4.75605 9.39245 4.93179 9.56819L7.18179 11.8182C7.35753 11.9939 7.64245 11.9939 7.81819 11.8182L10.0682 9.56819Z",fill:"currentColor",fillRule:"evenodd",clipRule:"evenodd"}))}function yee({shouldClear:e,clearButtonLabel:t,onClear:n,size:r,error:i,clearButtonTabIndex:s}){return e?N.createElement(Dx,{variant:"transparent","aria-label":t,onClick:n,size:r,tabIndex:s,onMouseDown:o=>o.preventDefault()}):N.createElement(BOe,{error:i,size:r})}yee.displayName="@mantine/core/SelectRightSection";var jOe=Object.defineProperty,UOe=Object.defineProperties,VOe=Object.getOwnPropertyDescriptors,eT=Object.getOwnPropertySymbols,vee=Object.prototype.hasOwnProperty,_ee=Object.prototype.propertyIsEnumerable,pj=(e,t,n)=>t in e?jOe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,HP=(e,t)=>{for(var n in t||(t={}))vee.call(t,n)&&pj(e,n,t[n]);if(eT)for(var n of eT(t))_ee.call(t,n)&&pj(e,n,t[n]);return e},mj=(e,t)=>UOe(e,VOe(t)),zOe=(e,t)=>{var n={};for(var r in e)vee.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&eT)for(var r of eT(e))t.indexOf(r)<0&&_ee.call(e,r)&&(n[r]=e[r]);return n};const HOe={xs:24,sm:30,md:34,lg:44,xl:54};function bee(e){var t=e,{styles:n,rightSection:r,rightSectionWidth:i,theme:s}=t,o=zOe(t,["styles","rightSection","rightSectionWidth","theme"]);if(r)return{rightSection:r,rightSectionWidth:i,styles:n};const a=typeof n=="function"?n(s):n;return{rightSectionWidth:s.fn.size({size:o.size,sizes:HOe}),rightSection:!o.readOnly&&!(o.disabled&&o.shouldClear)&&N.createElement(yee,HP({},o)),styles:mj(HP({},a),{rightSection:mj(HP({},a==null?void 0:a.rightSection),{pointerEvents:o.shouldClear?void 0:"none"})})}}var WOe=Object.defineProperty,qOe=Object.defineProperties,GOe=Object.getOwnPropertyDescriptors,gj=Object.getOwnPropertySymbols,YOe=Object.prototype.hasOwnProperty,KOe=Object.prototype.propertyIsEnumerable,yj=(e,t,n)=>t in e?WOe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,QOe=(e,t)=>{for(var n in t||(t={}))YOe.call(t,n)&&yj(e,n,t[n]);if(gj)for(var n of gj(t))KOe.call(t,n)&&yj(e,n,t[n]);return e},XOe=(e,t)=>qOe(e,GOe(t)),JOe=lt((e,{size:t,invalid:n})=>({wrapper:{position:"relative"},values:{minHeight:e.fn.size({size:t,sizes:$s})-2,display:"flex",alignItems:"center",flexWrap:"wrap",marginLeft:`calc(${-e.spacing.xs}px / 2)`,boxSizing:"border-box"},value:{margin:`calc(${e.spacing.xs}px / 2 - 2px) calc(${e.spacing.xs}px / 2)`},searchInput:XOe(QOe({},e.fn.fontStyles()),{flex:1,minWidth:60,backgroundColor:"transparent",border:0,outline:0,fontSize:e.fn.size({size:t,sizes:e.fontSizes}),padding:0,marginLeft:`calc(${e.spacing.xs}px / 2)`,appearance:"none",color:"inherit",lineHeight:`${e.fn.size({size:t,sizes:$s})-2}px`,"&::placeholder":{opacity:1,color:n?e.colors.red[e.colorScheme==="dark"?6:7]:e.colorScheme==="dark"?e.colors.dark[3]:e.colors.gray[5]},"&:disabled":{cursor:"not-allowed"}}),searchInputEmpty:{width:"100%"},searchInputInputHidden:{width:0,height:0,margin:0,overflow:"hidden"},searchInputPointer:{cursor:"pointer","&:disabled":{cursor:"not-allowed"}},input:{cursor:"pointer","&:disabled":{cursor:"not-allowed"}}})),ZOe=Object.defineProperty,e2e=Object.defineProperties,t2e=Object.getOwnPropertyDescriptors,tT=Object.getOwnPropertySymbols,wee=Object.prototype.hasOwnProperty,Eee=Object.prototype.propertyIsEnumerable,vj=(e,t,n)=>t in e?ZOe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Zh=(e,t)=>{for(var n in t||(t={}))wee.call(t,n)&&vj(e,n,t[n]);if(tT)for(var n of tT(t))Eee.call(t,n)&&vj(e,n,t[n]);return e},_j=(e,t)=>e2e(e,t2e(t)),n2e=(e,t)=>{var n={};for(var r in e)wee.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&tT)for(var r of tT(e))t.indexOf(r)<0&&Eee.call(e,r)&&(n[r]=e[r]);return n};function r2e(e,t,n){return t?!1:n.label.toLowerCase().trim().includes(e.toLowerCase().trim())}function i2e(e,t){return!!e&&!t.some(n=>n.value.toLowerCase()===e.toLowerCase())}function bj(e,t){if(!Array.isArray(e))return;if(t.length===0)return[];const n=t.map(r=>typeof r=="object"?r.value:r);return e.filter(r=>n.includes(r))}const s2e={size:"sm",valueComponent:pee,itemComponent:O$,transition:"pop-top-left",transitionDuration:0,maxDropdownHeight:220,shadow:"sm",searchable:!1,filter:r2e,limit:1/0,clearSearchOnChange:!0,clearable:!1,clearSearchOnBlur:!1,disabled:!1,initiallyOpened:!1,creatable:!1,shouldCreate:i2e,switchDirectionOnFlip:!1,zIndex:cc("popover"),selectOnBlur:!1,clearButtonTabIndex:0,positionDependencies:[],dropdownPosition:"flip"},See=w.forwardRef((e,t)=>{const n=Ve("MultiSelect",s2e,e),{className:r,style:i,required:s,label:o,description:a,size:u,error:l,classNames:c,styles:f,wrapperProps:d,value:h,defaultValue:p,data:m,onChange:y,valueComponent:g,itemComponent:v,id:b,transition:S,transitionDuration:T,transitionTimingFunction:E,maxDropdownHeight:I,shadow:A,nothingFound:R,onFocus:F,onBlur:L,searchable:B,placeholder:J,filter:V,limit:re,clearSearchOnChange:oe,clearable:ae,clearSearchOnBlur:ee,clearButtonLabel:ue,variant:P,onSearchChange:W,searchValue:Q,disabled:x,initiallyOpened:O,radius:$,icon:q,rightSection:ce,rightSectionWidth:fe,creatable:de,getCreateLabel:ve,shouldCreate:Ee,onCreate:ge,sx:nt,dropdownComponent:Je,onDropdownClose:yt,onDropdownOpen:ke,maxSelectedValues:at,withinPortal:St,switchDirectionOnFlip:cn,zIndex:bn,selectOnBlur:He,name:Fe,dropdownPosition:st,errorProps:dt,labelProps:At,descriptionProps:Kt,clearButtonTabIndex:me,form:Se,positionDependencies:Le,onKeyDown:Ke,unstyled:ct,inputContainer:In,inputWrapperOrder:Me,readOnly:Ze,withAsterisk:ot,hoverOnSearchChange:Gt,disableSelectedItemFiltering:pt}=n,_r=n2e(n,["className","style","required","label","description","size","error","classNames","styles","wrapperProps","value","defaultValue","data","onChange","valueComponent","itemComponent","id","transition","transitionDuration","transitionTimingFunction","maxDropdownHeight","shadow","nothingFound","onFocus","onBlur","searchable","placeholder","filter","limit","clearSearchOnChange","clearable","clearSearchOnBlur","clearButtonLabel","variant","onSearchChange","searchValue","disabled","initiallyOpened","radius","icon","rightSection","rightSectionWidth","creatable","getCreateLabel","shouldCreate","onCreate","sx","dropdownComponent","onDropdownClose","onDropdownOpen","maxSelectedValues","withinPortal","switchDirectionOnFlip","zIndex","selectOnBlur","name","dropdownPosition","errorProps","labelProps","descriptionProps","clearButtonTabIndex","form","positionDependencies","onKeyDown","unstyled","inputContainer","inputWrapperOrder","readOnly","withAsterisk","hoverOnSearchChange","disableSelectedItemFiltering"]),{classes:mn,cx:qn,theme:cs}=JOe({size:u,invalid:!!l},{classNames:c,styles:f,unstyled:ct,name:"MultiSelect"}),{systemStyles:xs,rest:ui}=Qf(_r),Nn=w.useRef(),ba=w.useRef({}),Nr=tu(b),[br,$n]=w.useState(O),[fn,Yn]=w.useState(-1),[fs,Kr]=w.useState("column"),[jr,X]=oa({value:Q,defaultValue:"",finalValue:void 0,onChange:W}),[z,Z]=w.useState(!1),{scrollIntoView:he,targetRef:pe,scrollableRef:Ye}=HK({duration:0,offset:5,cancelable:!1,isList:!0}),Qe=de&&typeof ve=="function";let xe=null;const et=m.map(We=>typeof We=="string"?{label:We,value:We}:We),Ft=uK({data:et}),[Be,Jt]=oa({value:bj(h,m),defaultValue:bj(p,m),finalValue:[],onChange:y}),Zt=w.useRef(!!at&&at{if(!Ze){const en=Be.filter(Hi=>Hi!==We);Jt(en),at&&en.length{X(We.currentTarget.value),!x&&!Zt.current&&B&&$n(!0)},Vn=We=>{typeof F=="function"&&F(We),!x&&!Zt.current&&B&&$n(!0)},Tt=$Oe({data:Ft,searchable:B,searchValue:jr,limit:re,filter:V,value:Be,disableSelectedItemFiltering:pt}),wr=(We,en,Hi)=>{let k=We;for(;Hi(k);)if(k=en(k),!Tt[k].disabled)return k;return We};Js(()=>{Yn(Gt&&jr?0:-1)},[jr,Gt]),Js(()=>{!x&&Be.length>m.length&&$n(!1),at&&Be.length=at&&(Zt.current=!0,$n(!1))},[Be]);const Er=We=>{if(!Ze)if(oe&&X(""),Be.includes(We.value))mt(We.value);else{if(We.creatable&&typeof ge=="function"){const en=ge(We.value);typeof en<"u"&&en!==null&&Jt(typeof en=="string"?[...Be,en]:[...Be,en.value])}else Jt([...Be,We.value]);Be.length===at-1&&(Zt.current=!0,$n(!1)),fn===Tt.length-1&&Yn(Tt.length-2),Tt.length===1&&$n(!1)}},kr=We=>{typeof L=="function"&&L(We),He&&Tt[fn]&&br&&Er(Tt[fn]),ee&&X(""),$n(!1)},ds=We=>{if(z||(Ke==null||Ke(We),Ze)||We.key!=="Backspace"&&at&&Zt.current)return;const en=fs==="column",Hi=()=>{Yn(K=>{var j;const te=wr(K,se=>se+1,se=>se{Yn(K=>{var j;const te=wr(K,se=>se-1,se=>se>0);return br&&(pe.current=ba.current[(j=Tt[te])==null?void 0:j.value],he({alignment:en?"start":"end"})),te})};switch(We.key){case"ArrowUp":{We.preventDefault(),$n(!0),en?k():Hi();break}case"ArrowDown":{We.preventDefault(),$n(!0),en?Hi():k();break}case"Enter":{We.preventDefault(),Tt[fn]&&br?Er(Tt[fn]):$n(!0);break}case" ":{B||(We.preventDefault(),Tt[fn]&&br?Er(Tt[fn]):$n(!0));break}case"Backspace":{Be.length>0&&jr.length===0&&(Jt(Be.slice(0,-1)),$n(!0),at&&(Zt.current=!1));break}case"Home":{if(!B){We.preventDefault(),br||$n(!0);const K=Tt.findIndex(j=>!j.disabled);Yn(K),he({alignment:en?"end":"start"})}break}case"End":{if(!B){We.preventDefault(),br||$n(!0);const K=Tt.map(j=>!!j.disabled).lastIndexOf(!1);Yn(K),he({alignment:en?"end":"start"})}break}case"Escape":$n(!1)}},Ei=Be.map(We=>{let en=Ft.find(Hi=>Hi.value===We&&!Hi.disabled);return!en&&Qe&&(en={value:We,label:We}),en}).filter(We=>!!We).map(We=>N.createElement(g,_j(Zh({},We),{variant:P,disabled:x,className:mn.value,readOnly:Ze,onRemove:en=>{en.preventDefault(),en.stopPropagation(),mt(We.value)},key:We.value,size:u,styles:f,classNames:c,radius:$}))),Ur=We=>Be.includes(We),Vi=()=>{var We;X(""),Jt([]),(We=Nn.current)==null||We.focus(),at&&(Zt.current=!1)};Qe&&Ee(jr,Ft)&&(xe=ve(jr),Tt.push({label:jr,value:jr,creatable:!0}));const zi=!Ze&&(Tt.length>0?br:br&&!!R);return Js(()=>{const We=zi?ke:yt;typeof We=="function"&&We()},[zi]),N.createElement(Zs.Wrapper,Zh(Zh({required:s,id:Nr,label:o,error:l,description:a,size:u,className:r,style:i,classNames:c,styles:f,__staticSelector:"MultiSelect",sx:nt,errorProps:dt,descriptionProps:Kt,labelProps:At,inputContainer:In,inputWrapperOrder:Me,unstyled:ct,withAsterisk:ot},xs),d),N.createElement(hf,{opened:zi,transition:S,transitionDuration:T,shadow:"sm",withinPortal:St,__staticSelector:"MultiSelect",onDirectionChange:Kr,switchDirectionOnFlip:cn,zIndex:bn,dropdownPosition:st,positionDependencies:[...Le,jr],classNames:c,styles:f,unstyled:ct},N.createElement(hf.Target,null,N.createElement("div",{className:mn.wrapper,role:"combobox","aria-haspopup":"listbox","aria-owns":br&&zi?`${Nr}-items`:null,"aria-controls":Nr,"aria-expanded":br,onMouseLeave:()=>Yn(-1),tabIndex:-1},N.createElement("input",{type:"hidden",name:Fe,value:Be.join(","),form:Se,disabled:x}),N.createElement(Zs,Zh({__staticSelector:"MultiSelect",style:{overflow:"hidden"},component:"div",multiline:!0,size:u,variant:P,disabled:x,invalid:!!l,required:s,radius:$,icon:q,unstyled:ct,onMouseDown:We=>{var en;We.preventDefault(),!x&&!Zt.current&&$n(!br),(en=Nn.current)==null||en.focus()},classNames:_j(Zh({},c),{input:qn({[mn.input]:!B},c==null?void 0:c.input)})},bee({theme:cs,rightSection:ce,rightSectionWidth:fe,styles:f,size:u,shouldClear:ae&&Be.length>0,clearButtonLabel:ue,onClear:Vi,error:l,disabled:x,clearButtonTabIndex:me,readOnly:Ze})),N.createElement("div",{className:mn.values},Ei,N.createElement("input",Zh({ref:fa(t,Nn),type:"search",id:Nr,className:qn(mn.searchInput,{[mn.searchInputPointer]:!B,[mn.searchInputInputHidden]:!br&&Be.length>0||!B&&Be.length>0,[mn.searchInputEmpty]:Be.length===0}),onKeyDown:ds,value:jr,onChange:kn,onFocus:Vn,onBlur:kr,readOnly:!B||Zt.current||Ze,placeholder:Be.length===0?J:void 0,disabled:x,"data-mantine-stop-propagation":br,autoComplete:"off",onCompositionStart:()=>Z(!0),onCompositionEnd:()=>Z(!1)},ui)))))),N.createElement(hf.Dropdown,{component:Je||Bx,maxHeight:I,direction:fs,id:Nr,innerRef:Ye,__staticSelector:"MultiSelect",classNames:c,styles:f},N.createElement(P$,{data:Tt,hovered:fn,classNames:c,styles:f,uuid:Nr,__staticSelector:"MultiSelect",onItemHover:Yn,onItemSelect:Er,itemsRefs:ba,itemComponent:v,size:u,nothingFound:R,isItemSelected:Ur,creatable:de&&!!xe,createLabel:xe,unstyled:ct}))))});See.displayName="@mantine/core/MultiSelect";var o2e=Object.defineProperty,a2e=Object.defineProperties,u2e=Object.getOwnPropertyDescriptors,wj=Object.getOwnPropertySymbols,l2e=Object.prototype.hasOwnProperty,c2e=Object.prototype.propertyIsEnumerable,Ej=(e,t,n)=>t in e?o2e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Sj=(e,t)=>{for(var n in t||(t={}))l2e.call(t,n)&&Ej(e,n,t[n]);if(wj)for(var n of wj(t))c2e.call(t,n)&&Ej(e,n,t[n]);return e},f2e=(e,t)=>a2e(e,u2e(t)),d2e=lt((e,{color:t,variant:n,noWrap:r,childrenOffset:i,alignIcon:s})=>{const o=e.fn.variant({variant:n,color:t});return{root:f2e(Sj({display:"flex",alignItems:"center",width:"100%",padding:`8px ${e.spacing.sm}px`,userSelect:"none"},e.fn.hover({backgroundColor:e.colorScheme==="dark"?e.colors.dark[6]:e.colors.gray[0]})),{"&[data-active]":Sj({backgroundColor:o.background,color:o.color},e.fn.hover({backgroundColor:o.hover})),"&[data-disabled]":{opacity:.4,pointerEvents:"none"}}),icon:{marginRight:e.spacing.sm,display:"flex",justifyContent:"center",alignItems:"center",alignSelf:s==="center"?"center":"flex-start",paddingTop:s==="center"?void 0:4},rightSection:{marginLeft:e.spacing.sm,display:"flex",justifyContent:"center",alignItems:"center",transition:`transform 150ms ${e.transitionTimingFunction}`,"&[data-rotate]":{transform:"rotate(90deg)"}},body:{flex:1,overflow:"hidden",textOverflow:"ellipsis",whiteSpace:r?"nowrap":void 0},label:{},description:{display:"block","&[data-active]":{color:"inherit"}},children:{paddingLeft:e.fn.size({size:i,sizes:e.spacing})}}}),h2e=Object.defineProperty,nT=Object.getOwnPropertySymbols,Tee=Object.prototype.hasOwnProperty,Iee=Object.prototype.propertyIsEnumerable,Tj=(e,t,n)=>t in e?h2e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,p2e=(e,t)=>{for(var n in t||(t={}))Tee.call(t,n)&&Tj(e,n,t[n]);if(nT)for(var n of nT(t))Iee.call(t,n)&&Tj(e,n,t[n]);return e},m2e=(e,t)=>{var n={};for(var r in e)Tee.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&nT)for(var r of nT(e))t.indexOf(r)<0&&Iee.call(e,r)&&(n[r]=e[r]);return n};const g2e={variant:"light",childrenOffset:"lg"},xee=w.forwardRef((e,t)=>{const n=Ve("NavLink",g2e,e),{label:r,description:i,icon:s,rightSection:o,className:a,classNames:u,styles:l,unstyled:c,active:f,color:d,variant:h,noWrap:p,children:m,opened:y,defaultOpened:g,onChange:v,disableRightSectionRotation:b,childrenOffset:S,disabled:T,onClick:E}=n,I=m2e(n,["label","description","icon","rightSection","className","classNames","styles","unstyled","active","color","variant","noWrap","children","opened","defaultOpened","onChange","disableRightSectionRotation","childrenOffset","disabled","onClick"]),{classes:A,cx:R}=d2e({color:d,variant:h,noWrap:p,childrenOffset:S,alignIcon:i?"top":"center"},{name:"NavLink",classNames:u,styles:l,unstyled:c}),[F,L]=oa({value:y,defaultValue:g,finalValue:!1,onChange:v}),B=!!m,J=V=>{B?(V.preventDefault(),E==null||E(V),L(!F)):E==null||E(V)};return N.createElement(N.Fragment,null,N.createElement(kx,p2e({ref:t,className:R(A.root,a),"data-active":f||void 0,onClick:J,unstyled:c,"data-expanded":F||void 0,"data-disabled":T||void 0,disabled:T},I),s&&N.createElement("span",{className:A.icon},s),N.createElement("span",{className:A.body},N.createElement(rt,{component:"span",size:"sm",className:A.label},r),N.createElement(rt,{component:"span",color:"dimmed",size:"xs","data-active":f||void 0,className:A.description},i)),(B||o)&&N.createElement("span",{className:A.rightSection,"data-rotate":F&&!b||void 0},B?o||N.createElement(H_e,{width:14,height:14,style:{transform:"rotate(-90deg)"}}):o)),N.createElement(tQ,{in:F},N.createElement("div",{className:A.children},m)))});xee.displayName="@mantine/core/NavLink";const Cee=xee,y2e=(e,t,n)=>Number.isInteger(e)&&e>=0&&t===0?"numeric":!Number.isInteger(e)&&e>=0&&t!==0?"decimal":Number.isInteger(e)&&e<0&&t===0||!Number.isInteger(e)&&e<0&&t!==0?n==="ios"?"text":"decimal":"numeric";function Ij({direction:e,size:t}){return N.createElement("svg",{style:{transform:e==="up"?"rotate(180deg)":void 0},width:t,height:t,viewBox:"0 0 15 15",fill:"none",xmlns:"http://www.w3.org/2000/svg"},N.createElement("path",{d:"M3.13523 6.15803C3.3241 5.95657 3.64052 5.94637 3.84197 6.13523L7.5 9.56464L11.158 6.13523C11.3595 5.94637 11.6759 5.95657 11.8648 6.15803C12.0536 6.35949 12.0434 6.67591 11.842 6.86477L7.84197 10.6148C7.64964 10.7951 7.35036 10.7951 7.15803 10.6148L3.15803 6.86477C2.95657 6.67591 2.94637 6.35949 3.13523 6.15803Z",fill:"currentColor",fillRule:"evenodd",clipRule:"evenodd"}))}const Aee={xs:20,sm:24,md:30,lg:34,xl:36};var v2e=lt((e,{radius:t,size:n})=>({rightSection:{display:"flex",flexDirection:"column",height:"calc(100% - 2px)",margin:1,marginRight:1,overflow:"hidden",borderTopRightRadius:e.fn.radius(t),borderBottomRightRadius:e.fn.radius(t)},control:{margin:0,position:"relative",flex:"0 0 50%",display:"flex",alignItems:"center",justifyContent:"center",boxSizing:"border-box",width:e.fn.size({size:n,sizes:Aee}),padding:0,WebkitTapHighlightColor:"transparent",borderBottom:`1px solid ${e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[4]}`,borderLeft:`1px solid ${e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[4]}`,borderTop:0,borderRight:0,backgroundColor:"transparent",marginRight:1,color:e.colorScheme==="dark"?e.colors.dark[0]:e.black,"&:not(:disabled):hover":{backgroundColor:e.colorScheme==="dark"?e.colors.dark[5]:e.colors.gray[0]},"&:disabled":{color:e.colorScheme==="dark"?e.colors.dark[3]:e.colors.gray[4]}},controlUp:{},controlDown:{borderBottom:0}})),_2e=Object.defineProperty,b2e=Object.defineProperties,w2e=Object.getOwnPropertyDescriptors,rT=Object.getOwnPropertySymbols,Pee=Object.prototype.hasOwnProperty,Oee=Object.prototype.propertyIsEnumerable,xj=(e,t,n)=>t in e?_2e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,WP=(e,t)=>{for(var n in t||(t={}))Pee.call(t,n)&&xj(e,n,t[n]);if(rT)for(var n of rT(t))Oee.call(t,n)&&xj(e,n,t[n]);return e},E2e=(e,t)=>b2e(e,w2e(t)),S2e=(e,t)=>{var n={};for(var r in e)Pee.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&rT)for(var r of rT(e))t.indexOf(r)<0&&Oee.call(e,r)&&(n[r]=e[r]);return n};const T2e={type:"text",size:"sm",__staticSelector:"TextInput"},Ev=w.forwardRef((e,t)=>{const n=eJ("TextInput",T2e,e),{inputProps:r,wrapperProps:i}=n,s=S2e(n,["inputProps","wrapperProps"]);return N.createElement(Zs.Wrapper,WP({},i),N.createElement(Zs,E2e(WP(WP({},r),s),{ref:t})))});Ev.displayName="@mantine/core/TextInput";var I2e=Object.defineProperty,x2e=Object.defineProperties,C2e=Object.getOwnPropertyDescriptors,iT=Object.getOwnPropertySymbols,Ree=Object.prototype.hasOwnProperty,Nee=Object.prototype.propertyIsEnumerable,Cj=(e,t,n)=>t in e?I2e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,A2e=(e,t)=>{for(var n in t||(t={}))Ree.call(t,n)&&Cj(e,n,t[n]);if(iT)for(var n of iT(t))Nee.call(t,n)&&Cj(e,n,t[n]);return e},P2e=(e,t)=>x2e(e,C2e(t)),O2e=(e,t)=>{var n={};for(var r in e)Ree.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&iT)for(var r of iT(e))t.indexOf(r)<0&&Nee.call(e,r)&&(n[r]=e[r]);return n};const R2e=e=>e||"",N2e=e=>{if(e==="-")return e;let t=e;t[0]==="."&&(t=`0${e}`);const n=parseFloat(t);if(!Number.isNaN(n))return e},Aj={xs:10,sm:14,md:16,lg:18,xl:20},k2e={step:1,hideControls:!1,size:"sm",precision:0,noClampOnBlur:!1,removeTrailingZeros:!1,formatter:R2e,parser:N2e,type:"text"},kee=w.forwardRef((e,t)=>{const n=Ve("NumberInput",k2e,e),{readOnly:r,disabled:i,value:s,onChange:o,decimalSeparator:a,min:u,max:l,startValue:c,step:f,stepHoldInterval:d,stepHoldDelay:h,onBlur:p,onFocus:m,onKeyDown:y,onKeyUp:g,hideControls:v,radius:b,variant:S,precision:T,removeTrailingZeros:E,defaultValue:I,noClampOnBlur:A,handlersRef:R,classNames:F,styles:L,size:B,rightSection:J,rightSectionWidth:V,formatter:re,parser:oe,inputMode:ae,unstyled:ee,type:ue}=n,P=O2e(n,["readOnly","disabled","value","onChange","decimalSeparator","min","max","startValue","step","stepHoldInterval","stepHoldDelay","onBlur","onFocus","onKeyDown","onKeyUp","hideControls","radius","variant","precision","removeTrailingZeros","defaultValue","noClampOnBlur","handlersRef","classNames","styles","size","rightSection","rightSectionWidth","formatter","parser","inputMode","unstyled","type"]),{classes:W,cx:Q,theme:x}=v2e({radius:b,size:B},{classNames:F,styles:L,unstyled:ee,name:"NumberInput"}),O=Me=>{if(Me===void 0)return;let Ze=Me.toFixed(T);return E&&T>0&&(Ze=Ze.replace(new RegExp(`[0]{0,${T}}$`),""),(Ze.endsWith(".")||Ze.endsWith(a))&&(Ze=Ze.slice(0,-1))),Ze},[$,q]=w.useState(!1),[ce,fe]=w.useState(typeof s=="number"?s:typeof I=="number"?I:void 0),de=typeof s=="number"?s:ce,[ve,Ee]=w.useState(typeof de=="number"?O(de):""),ge=w.useRef(),nt=Me=>{Me!==ce&&!Number.isNaN(Me)&&(typeof o=="function"&&o(Me),fe(Me))},Je=(Me="")=>{let Ze=typeof Me=="number"?String(Me):Me;return a&&(Ze=Ze.replace(/\./g,a)),re(Ze)},yt=Me=>{let Ze=Me;return a&&(Ze=Ze.replace(new RegExp(`\\${a}`,"g"),".")),oe(Ze)},ke=typeof u=="number"?u:-1/0,at=typeof l=="number"?l:1/0,St=w.useRef();St.current=()=>{var Me,Ze,ot;if(ce===void 0)nt((Me=c??u)!=null?Me:0),Ee((ot=(Ze=O(c))!=null?Ze:O(u))!=null?ot:"0");else{const Gt=O(ff(ce+f,ke,at));nt(parseFloat(Gt)),Ee(Gt)}};const cn=w.useRef();cn.current=()=>{var Me,Ze,ot;if(ce===void 0)nt((Me=c??u)!=null?Me:0),Ee((ot=(Ze=O(c))!=null?Ze:O(u))!=null?ot:"0");else{const Gt=O(ff(ce-f,ke,at));nt(parseFloat(Gt)),Ee(Gt)}},UK(R,{increment:St.current,decrement:cn.current}),w.useEffect(()=>{typeof s=="number"&&!$&&(fe(s),Ee(O(s))),I===void 0&&s===void 0&&!$&&(fe(s),Ee(""))},[s,T]);const bn=h!==void 0&&d!==void 0,He=w.useRef(null),Fe=w.useRef(0),st=()=>{He.current&&window.clearTimeout(He.current),He.current=null,Fe.current=0},dt=Me=>{Me?St.current():cn.current(),Fe.current+=1},At=Me=>{if(dt(Me),bn){const Ze=typeof d=="number"?d:d(Fe.current);He.current=window.setTimeout(()=>At(Me),Ze)}},Kt=(Me,Ze)=>{Me.preventDefault(),ge.current.focus(),dt(Ze),bn&&(He.current=window.setTimeout(()=>At(Ze),h))};w.useEffect(()=>(st(),st),[]);const me=N.createElement("div",{className:W.rightSection},N.createElement("button",{type:"button",tabIndex:-1,"aria-hidden":!0,disabled:de>=l,className:Q(W.control,W.controlUp),onPointerDown:Me=>{Kt(Me,!0)},onPointerUp:st,onPointerLeave:st},N.createElement(Ij,{size:x.fn.size({size:B,sizes:Aj}),direction:"up"})),N.createElement("button",{type:"button",tabIndex:-1,"aria-hidden":!0,disabled:de<=u,className:Q(W.control,W.controlDown),onPointerDown:Me=>{Kt(Me,!1)},onPointerUp:st,onPointerLeave:st},N.createElement(Ij,{size:x.fn.size({size:B,sizes:Aj}),direction:"down"}))),Se=Me=>{if(Me.nativeEvent.isComposing)return;const ot=Me.target.value,Gt=yt(ot);Ee(Gt),ot===""||ot==="-"?nt(void 0):ot.trim()!==""&&!Number.isNaN(Gt)&&nt(parseFloat(Gt))},Le=Me=>{var Ze;if(Me.target.value==="")Ee(""),nt(void 0);else{let ot=Me.target.value;(ot[0]===`${a}`||ot[0]===".")&&(ot=`0${ot}`);const Gt=yt(ot),pt=ff(parseFloat(Gt),ke,at);Number.isNaN(pt)?Ee((Ze=O(de))!=null?Ze:""):A||(Ee(O(pt)),nt(parseFloat(O(pt))))}q(!1),typeof p=="function"&&p(Me)},Ke=Me=>{q(!0),typeof m=="function"&&m(Me)},ct=Me=>{if(typeof y=="function"&&y(Me),Me.repeat&&bn&&(Me.key==="ArrowUp"||Me.key==="ArrowDown")){Me.preventDefault();return}r||(Me.key==="ArrowUp"?Kt(Me,!0):Me.key==="ArrowDown"&&Kt(Me,!1))},In=Me=>{typeof g=="function"&&g(Me),(Me.key==="ArrowUp"||Me.key==="ArrowDown")&&st()};return N.createElement(Ev,P2e(A2e({},P),{type:ue,variant:S,value:Je(ve),disabled:i,readOnly:r,ref:fa(ge,t),onChange:Se,onBlur:Le,onFocus:Ke,onKeyDown:ct,onKeyUp:In,rightSection:J||(i||r||v||S==="unstyled"?null:me),rightSectionWidth:V||x.fn.size({size:B,sizes:Aee})+1,radius:b,max:l,min:u,step:f,size:B,styles:L,classNames:F,inputMode:ae||y2e(f,T,Jve()),__staticSelector:"NumberInput",unstyled:ee}))});kee.displayName="@mantine/core/NumberInput";const Pj={xs:3,sm:5,md:8,lg:12,xl:16},D2e=Zye({from:{backgroundPosition:"0 0"},to:{backgroundPosition:"40px 0"}});var $2e=lt((e,{color:t,radius:n,size:r,striped:i,animate:s})=>({root:{position:"relative",height:e.fn.size({size:r,sizes:Pj}),backgroundColor:e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[2],borderRadius:e.fn.size({size:n,sizes:e.radius}),overflow:"hidden"},bar:{position:"absolute",top:0,bottom:0,left:0,height:"100%",display:"flex",justifyContent:"center",alignItems:"center",backgroundColor:e.fn.variant({variant:"filled",primaryFallback:!1,color:t||e.primaryColor}).background,transition:"width 100ms linear",animation:s?`${D2e} 1000ms linear infinite`:"none",backgroundSize:"20px 20px",backgroundImage:i?"linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent)":"none","&:last-of-type":{borderTopRightRadius:e.fn.size({size:n,sizes:e.radius}),borderBottomRightRadius:e.fn.size({size:n,sizes:e.radius})},"&:first-of-type":{borderTopLeftRadius:e.fn.size({size:n,sizes:e.radius}),borderBottomLeftRadius:e.fn.size({size:n,sizes:e.radius})},"@media (prefers-reduced-motion)":{transitionDuration:e.respectReducedMotion?"0ms":void 0}},label:{color:e.white,fontSize:e.fn.size({size:r,sizes:Pj})*.65,fontWeight:700,userSelect:"none",overflow:"hidden",whiteSpace:"nowrap"}}));const Dee=w.createContext(!1),L2e=Dee.Provider,M2e=()=>w.useContext(Dee);function $ee({children:e,openDelay:t=0,closeDelay:n=0}){return N.createElement(L2e,{value:!0},N.createElement(lSe,{delay:{open:t,close:n}},e))}$ee.displayName="@mantine/core/TooltipGroup";var F2e=Object.defineProperty,B2e=Object.defineProperties,j2e=Object.getOwnPropertyDescriptors,Oj=Object.getOwnPropertySymbols,U2e=Object.prototype.hasOwnProperty,V2e=Object.prototype.propertyIsEnumerable,Rj=(e,t,n)=>t in e?F2e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Nj=(e,t)=>{for(var n in t||(t={}))U2e.call(t,n)&&Rj(e,n,t[n]);if(Oj)for(var n of Oj(t))V2e.call(t,n)&&Rj(e,n,t[n]);return e},z2e=(e,t)=>B2e(e,j2e(t));function H2e(e,t){if(!t)return{backgroundColor:e.colorScheme==="dark"?e.colors.dark[6]:e.colors.gray[9],color:e.white};const n=e.fn.variant({variant:"filled",color:t,primaryFallback:!1});return{backgroundColor:n.background,color:n.color}}var Lee=lt((e,{color:t,radius:n,width:r,multiline:i})=>({tooltip:z2e(Nj(Nj({},e.fn.fontStyles()),H2e(e,t)),{lineHeight:e.lineHeight,fontSize:e.fontSizes.sm,borderRadius:e.fn.radius(n),padding:`calc(${e.spacing.xs}px / 2) ${e.spacing.xs}px`,position:"absolute",whiteSpace:i?"unset":"nowrap",pointerEvents:"none",width:r}),arrow:{backgroundColor:"inherit",border:0,zIndex:1}}));const Mee={children:"Tooltip component children should be an element or a component that accepts ref, fragments, strings, numbers and other primitive values are not supported"};function W2e({offset:e,position:t}){const[n,r]=w.useState(!1),i=w.useRef(),{x:s,y:o,reference:a,floating:u,refs:l,update:c,placement:f}=H$({placement:t,middleware:[U$({crossAxis:!0,padding:5,rootBoundary:"document"})]}),d=f.includes("right")?e:t.includes("left")?e*-1:0,h=f.includes("bottom")?e:t.includes("top")?e*-1:0,p=w.useCallback(({clientX:m,clientY:y})=>{a({getBoundingClientRect(){return{width:0,height:0,x:m,y,left:m+d,top:y+h,right:m,bottom:y}}})},[a]);return w.useEffect(()=>{if(l.floating.current){const m=i.current;m.addEventListener("mousemove",p);const y=Fl(l.floating.current);return y.forEach(g=>{g.addEventListener("scroll",c)}),()=>{m.removeEventListener("mousemove",p),y.forEach(g=>{g.removeEventListener("scroll",c)})}}},[a,l.floating.current,c,p,n]),{handleMouseMove:p,x:s,y:o,opened:n,setOpened:r,boundaryRef:i,floating:u}}var q2e=Object.defineProperty,G2e=Object.defineProperties,Y2e=Object.getOwnPropertyDescriptors,sT=Object.getOwnPropertySymbols,Fee=Object.prototype.hasOwnProperty,Bee=Object.prototype.propertyIsEnumerable,kj=(e,t,n)=>t in e?q2e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,qP=(e,t)=>{for(var n in t||(t={}))Fee.call(t,n)&&kj(e,n,t[n]);if(sT)for(var n of sT(t))Bee.call(t,n)&&kj(e,n,t[n]);return e},GP=(e,t)=>G2e(e,Y2e(t)),K2e=(e,t)=>{var n={};for(var r in e)Fee.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&sT)for(var r of sT(e))t.indexOf(r)<0&&Bee.call(e,r)&&(n[r]=e[r]);return n};const Q2e={refProp:"ref",withinPortal:!0,offset:10,position:"right",zIndex:cc("popover")};function jee(e){var t;const n=Ve("TooltipFloating",Q2e,e),{children:r,refProp:i,withinPortal:s,style:o,className:a,classNames:u,styles:l,unstyled:c,radius:f,color:d,label:h,offset:p,position:m,multiline:y,width:g,zIndex:v,disabled:b}=n,S=K2e(n,["children","refProp","withinPortal","style","className","classNames","styles","unstyled","radius","color","label","offset","position","multiline","width","zIndex","disabled"]),{handleMouseMove:T,x:E,y:I,opened:A,boundaryRef:R,floating:F,setOpened:L}=W2e({offset:p,position:m}),{classes:B,cx:J}=Lee({radius:f,color:d,multiline:y,width:g},{name:"TooltipFloating",classNames:u,styles:l,unstyled:c});if(!_g(r))throw new Error(Mee.children);const V=fa(R,r.ref),re=ae=>{var ee,ue;(ue=(ee=r.props).onMouseEnter)==null||ue.call(ee,ae),T(ae),L(!0)},oe=ae=>{var ee,ue;(ue=(ee=r.props).onMouseLeave)==null||ue.call(ee,ae),L(!1)};return N.createElement(N.Fragment,null,N.createElement($_,{withinPortal:s},N.createElement(it,GP(qP({},S),{ref:F,className:J(B.tooltip,a),style:GP(qP({},o),{zIndex:v,display:!b&&A?"block":"none",top:I??"",left:(t=Math.round(E))!=null?t:""})}),h)),w.cloneElement(r,GP(qP({},r.props),{[i]:V,onMouseEnter:re,onMouseLeave:oe})))}jee.displayName="@mantine/core/TooltipFloating";function X2e(e){const[t,n]=w.useState(!1),i=typeof e.opened=="boolean"?e.opened:t,s=M2e(),o=tu(),{delay:a,currentId:u,setCurrentId:l}=kX(),c=w.useCallback(A=>{n(A),A&&l(o)},[l,o]),{x:f,y:d,reference:h,floating:p,context:m,refs:y,update:g,placement:v,middlewareData:{arrow:{x:b,y:S}={}}}=H$({placement:e.position,open:i,onOpenChange:c,middleware:[yX(e.offset),U$({padding:8}),xX(),AX({element:e.arrowRef,padding:e.arrowOffset}),...e.inline?[CX()]:[]]}),{getReferenceProps:T,getFloatingProps:E}=wSe([uSe(m,{enabled:e.events.hover,delay:s?a:{open:e.openDelay,close:e.closeDelay},mouseOnly:!e.events.touch}),_Se(m,{enabled:e.events.focus,keyboardOnly:!0}),bSe(m,{role:"tooltip"}),vSe(m,{enabled:typeof e.opened===void 0}),cSe(m,{id:o})]);return $X({opened:i,positionDependencies:e.positionDependencies,floating:{refs:y,update:g}}),Js(()=>{var A;(A=e.onPositionChange)==null||A.call(e,v)},[v]),{x:f,y:d,arrowX:b,arrowY:S,reference:h,floating:p,getFloatingProps:E,getReferenceProps:T,isGroupPhase:i&&u&&u!==o,opened:i,placement:v}}var J2e=Object.defineProperty,Z2e=Object.defineProperties,eRe=Object.getOwnPropertyDescriptors,oT=Object.getOwnPropertySymbols,Uee=Object.prototype.hasOwnProperty,Vee=Object.prototype.propertyIsEnumerable,Dj=(e,t,n)=>t in e?J2e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,v0=(e,t)=>{for(var n in t||(t={}))Uee.call(t,n)&&Dj(e,n,t[n]);if(oT)for(var n of oT(t))Vee.call(t,n)&&Dj(e,n,t[n]);return e},tRe=(e,t)=>Z2e(e,eRe(t)),nRe=(e,t)=>{var n={};for(var r in e)Uee.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&oT)for(var r of oT(e))t.indexOf(r)<0&&Vee.call(e,r)&&(n[r]=e[r]);return n};const rRe={position:"top",refProp:"ref",withinPortal:!1,inline:!1,arrowSize:4,arrowOffset:5,arrowRadius:0,arrowPosition:"side",offset:5,transition:"fade",transitionDuration:100,width:"auto",events:{hover:!0,focus:!1,touch:!1},zIndex:cc("popover"),positionDependencies:[]},Hx=w.forwardRef((e,t)=>{const n=w.useRef(null),r=Ve("Tooltip",rRe,e),{children:i,position:s,refProp:o,label:a,openDelay:u,closeDelay:l,onPositionChange:c,opened:f,withinPortal:d,radius:h,color:p,classNames:m,styles:y,unstyled:g,style:v,className:b,withArrow:S,arrowSize:T,arrowOffset:E,arrowRadius:I,arrowPosition:A,offset:R,transition:F,transitionDuration:L,multiline:B,width:J,events:V,zIndex:re,disabled:oe,positionDependencies:ae,onClick:ee,onMouseEnter:ue,onMouseLeave:P,inline:W}=r,Q=nRe(r,["children","position","refProp","label","openDelay","closeDelay","onPositionChange","opened","withinPortal","radius","color","classNames","styles","unstyled","style","className","withArrow","arrowSize","arrowOffset","arrowRadius","arrowPosition","offset","transition","transitionDuration","multiline","width","events","zIndex","disabled","positionDependencies","onClick","onMouseEnter","onMouseLeave","inline"]),{classes:x,cx:O,theme:$}=Lee({radius:h,color:p,width:J,multiline:B},{name:"Tooltip",classNames:m,styles:y,unstyled:g}),q=X2e({position:KX($.dir,s),closeDelay:l,openDelay:u,onPositionChange:c,opened:f,events:V,arrowRef:n,arrowOffset:E,offset:R+(S?T/2:0),positionDependencies:[...ae,i],inline:W});if(!_g(i))throw new Error(Mee.children);const ce=fa(q.reference,i.ref,t);return N.createElement(N.Fragment,null,N.createElement($_,{withinPortal:d},N.createElement(Vx,{mounted:!oe&&q.opened,transition:F,duration:q.isGroupPhase?10:L},fe=>{var de,ve;return N.createElement(it,v0(v0({},Q),q.getFloatingProps({ref:q.floating,className:x.tooltip,style:tRe(v0(v0({},v),fe),{zIndex:re,top:(de=q.y)!=null?de:0,left:(ve=q.x)!=null?ve:0})})),a,N.createElement(W$,{ref:n,arrowX:q.arrowX,arrowY:q.arrowY,visible:S,withBorder:!1,position:q.placement,arrowSize:T,arrowOffset:E,arrowRadius:I,arrowPosition:A,className:x.arrow}))})),w.cloneElement(i,q.getReferenceProps(v0({onClick:ee,onMouseEnter:ue,onMouseLeave:P,onMouseMove:e.onMouseMove,onPointerDown:e.onPointerDown,onPointerEnter:e.onPointerEnter,[o]:ce,className:O(b,i.props.className)},i.props))))});Hx.Group=$ee;Hx.Floating=jee;Hx.displayName="@mantine/core/Tooltip";const Wx=Hx;var iRe=Object.defineProperty,sRe=Object.defineProperties,oRe=Object.getOwnPropertyDescriptors,aT=Object.getOwnPropertySymbols,zee=Object.prototype.hasOwnProperty,Hee=Object.prototype.propertyIsEnumerable,$j=(e,t,n)=>t in e?iRe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,JR=(e,t)=>{for(var n in t||(t={}))zee.call(t,n)&&$j(e,n,t[n]);if(aT)for(var n of aT(t))Hee.call(t,n)&&$j(e,n,t[n]);return e},Wee=(e,t)=>sRe(e,oRe(t)),Lj=(e,t)=>{var n={};for(var r in e)zee.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&aT)for(var r of aT(e))t.indexOf(r)<0&&Hee.call(e,r)&&(n[r]=e[r]);return n};function aRe(e){return e.reduce((t,n)=>(t.sections.push(Wee(JR({},n),{accumulated:t.accumulated})),t.accumulated+=n.value,t),{accumulated:0,sections:[]}).sections}const uRe={size:"md",radius:"sm",striped:!1,animate:!1,label:""},qee=w.forwardRef((e,t)=>{const n=Ve("Progress",uRe,e),{className:r,value:i,color:s,size:o,radius:a,striped:u,animate:l,label:c,"aria-label":f,classNames:d,styles:h,sections:p,unstyled:m}=n,y=Lj(n,["className","value","color","size","radius","striped","animate","label","aria-label","classNames","styles","sections","unstyled"]),{classes:g,cx:v,theme:b}=$2e({color:s,size:o,radius:a,striped:u||l,animate:l},{classNames:d,styles:h,unstyled:m,name:"Progress"}),S=Array.isArray(p)?aRe(p).map((T,E)=>{var I=T,{tooltip:A,accumulated:R,value:F,label:L,color:B}=I,J=Lj(I,["tooltip","accumulated","value","label","color"]);return N.createElement(Wx.Floating,{label:A,disabled:!A,key:E},N.createElement(it,Wee(JR({},J),{className:v(g.bar,J.className),sx:{width:`${F}%`,left:`${R}%`,backgroundColor:b.fn.variant({variant:"filled",primaryFallback:!1,color:B||b.primaryColor}).background}}),L&&N.createElement(rt,{className:g.label},L)))}):null;return N.createElement(it,JR({className:v(g.root,r),ref:t},y),S||N.createElement("div",{role:"progressbar","aria-valuemax":100,"aria-valuemin":0,"aria-valuenow":i,"aria-label":f,className:g.bar,style:{width:`${i}%`}},c?N.createElement(rt,{className:g.label},c):""))});qee.displayName="@mantine/core/Progress";var lRe=Object.defineProperty,Mj=Object.getOwnPropertySymbols,cRe=Object.prototype.hasOwnProperty,fRe=Object.prototype.propertyIsEnumerable,Fj=(e,t,n)=>t in e?lRe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,dRe=(e,t)=>{for(var n in t||(t={}))cRe.call(t,n)&&Fj(e,n,t[n]);if(Mj)for(var n of Mj(t))fRe.call(t,n)&&Fj(e,n,t[n]);return e};function hRe(e){return N.createElement("svg",dRe({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 5 5"},e),N.createElement("path",{fill:"currentColor",d:"M0 2.5a2.5 2.5 0 115 0 2.5 2.5 0 01-5 0z"}))}const Gee=w.createContext(null),pRe=Gee.Provider,mRe=()=>w.useContext(Gee);var gRe=Object.defineProperty,uT=Object.getOwnPropertySymbols,Yee=Object.prototype.hasOwnProperty,Kee=Object.prototype.propertyIsEnumerable,Bj=(e,t,n)=>t in e?gRe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,jj=(e,t)=>{for(var n in t||(t={}))Yee.call(t,n)&&Bj(e,n,t[n]);if(uT)for(var n of uT(t))Kee.call(t,n)&&Bj(e,n,t[n]);return e},yRe=(e,t)=>{var n={};for(var r in e)Yee.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&uT)for(var r of uT(e))t.indexOf(r)<0&&Kee.call(e,r)&&(n[r]=e[r]);return n};const vRe={orientation:"horizontal",spacing:"lg",offset:"xs",size:"sm"},Qee=w.forwardRef((e,t)=>{const n=Ve("RadioGroup",vRe,e),{children:r,value:i,defaultValue:s,onChange:o,orientation:a,spacing:u,size:l,wrapperProps:c,unstyled:f,offset:d,name:h}=n,p=yRe(n,["children","value","defaultValue","onChange","orientation","spacing","size","wrapperProps","unstyled","offset","name"]),m=tu(h),[y,g]=oa({value:i,defaultValue:s,finalValue:"",onChange:o}),v=b=>g(b.currentTarget.value);return N.createElement(pRe,{value:{value:y,onChange:v,size:l,name:m}},N.createElement(Zs.Wrapper,jj(jj({labelElement:"div",size:l,__staticSelector:"RadioGroup",ref:t,unstyled:f},c),p),N.createElement(WJ,{spacing:u,orientation:a,unstyled:f,role:"radiogroup",offset:d},r)))});Qee.displayName="@mantine/core/RadioGroup";var _Re=Object.defineProperty,bRe=Object.defineProperties,wRe=Object.getOwnPropertyDescriptors,Uj=Object.getOwnPropertySymbols,ERe=Object.prototype.hasOwnProperty,SRe=Object.prototype.propertyIsEnumerable,Vj=(e,t,n)=>t in e?_Re(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,TRe=(e,t)=>{for(var n in t||(t={}))ERe.call(t,n)&&Vj(e,n,t[n]);if(Uj)for(var n of Uj(t))SRe.call(t,n)&&Vj(e,n,t[n]);return e},IRe=(e,t)=>bRe(e,wRe(t));const YP={xs:16,sm:20,md:24,lg:30,xl:36},yb={xs:6,sm:8,md:10,lg:14,xl:16};var xRe=lt((e,{size:t,color:n,transitionDuration:r,labelPosition:i,error:s},o)=>{const a=e.fn.variant({variant:"filled",color:n}),u=e.fn.variant({variant:"filled",color:"red"}).background;return{inner:{order:i==="left"?2:1,position:"relative",alignSelf:"flex-start"},icon:{ref:o("icon"),color:e.white,opacity:0,transform:"scale(0.75) translateY(2px)",transition:`opacity ${r}ms ${e.transitionTimingFunction}`,pointerEvents:"none",width:e.fn.size({sizes:yb,size:t}),height:e.fn.size({sizes:yb,size:t}),position:"absolute",top:`calc(50% - ${e.fn.size({sizes:yb,size:t})/2}px)`,left:`calc(50% - ${e.fn.size({sizes:yb,size:t})/2}px)`},radio:IRe(TRe({},e.fn.focusStyles()),{backgroundColor:e.colorScheme==="dark"?e.colors.dark[6]:e.white,border:`1px solid ${s?u:e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[4]}`,position:"relative",appearance:"none",width:e.fn.size({sizes:YP,size:t}),height:e.fn.size({sizes:YP,size:t}),borderRadius:e.fn.size({sizes:YP,size:t}),margin:0,display:"flex",alignItems:"center",justifyContent:"center",transitionProperty:"background-color, border-color",transitionTimingFunction:e.transitionTimingFunction,transitionDuration:`${r}ms`,cursor:e.cursorType,"&:checked":{background:a.background,borderColor:a.background,[`& + .${o("icon")}`]:{opacity:1,transform:"scale(1)"}},"&:disabled":{borderColor:e.colorScheme==="dark"?e.colors.dark[5]:e.colors.gray[4],backgroundColor:e.colorScheme==="dark"?e.colors.dark[5]:e.colors.gray[1],[`& + .${o("icon")}`]:{color:e.colorScheme==="dark"?e.colors.dark[6]:e.colors.gray[4]}}})}}),CRe=Object.defineProperty,lT=Object.getOwnPropertySymbols,Xee=Object.prototype.hasOwnProperty,Jee=Object.prototype.propertyIsEnumerable,zj=(e,t,n)=>t in e?CRe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,vb=(e,t)=>{for(var n in t||(t={}))Xee.call(t,n)&&zj(e,n,t[n]);if(lT)for(var n of lT(t))Jee.call(t,n)&&zj(e,n,t[n]);return e},ARe=(e,t)=>{var n={};for(var r in e)Xee.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&lT)for(var r of lT(e))t.indexOf(r)<0&&Jee.call(e,r)&&(n[r]=e[r]);return n};const PRe={icon:hRe,transitionDuration:100,size:"sm",labelPosition:"right"},cT=w.forwardRef((e,t)=>{var n,r;const i=Ve("Radio",PRe,e),{className:s,style:o,id:a,label:u,size:l,title:c,disabled:f,color:d,classNames:h,styles:p,sx:m,icon:y,transitionDuration:g,wrapperProps:v,unstyled:b,labelPosition:S,description:T,error:E}=i,I=ARe(i,["className","style","id","label","size","title","disabled","color","classNames","styles","sx","icon","transitionDuration","wrapperProps","unstyled","labelPosition","description","error"]),A=mRe(),R=(n=A==null?void 0:A.size)!=null?n:l,F=e.size?l:R,{classes:L}=xRe({color:d,size:F,transitionDuration:g,labelPosition:S,error:!!E},{classNames:h,styles:p,unstyled:b,name:"Radio"}),{systemStyles:B,rest:J}=Qf(I),V=tu(a),re=A?{checked:A.value===J.value,name:(r=J.name)!=null?r:A.name,onChange:A.onChange}:{};return N.createElement(X$,vb(vb({className:s,sx:m,style:o,id:V,size:F,labelPosition:S,label:u,description:T,error:E,disabled:f,__staticSelector:"Radio",classNames:h,styles:p,unstyled:b,"data-checked":re.checked||void 0},B),v),N.createElement("div",{className:L.inner},N.createElement("input",vb(vb({ref:t,className:L.radio,type:"radio",id:V,disabled:f},J),re)),N.createElement(y,{className:L.icon,"aria-hidden":!0})))});cT.displayName="@mantine/core/Radio";cT.Group=Qee;var ORe=Object.defineProperty,RRe=Object.defineProperties,NRe=Object.getOwnPropertyDescriptors,Hj=Object.getOwnPropertySymbols,kRe=Object.prototype.hasOwnProperty,DRe=Object.prototype.propertyIsEnumerable,Wj=(e,t,n)=>t in e?ORe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,_b=(e,t)=>{for(var n in t||(t={}))kRe.call(t,n)&&Wj(e,n,t[n]);if(Hj)for(var n of Hj(t))DRe.call(t,n)&&Wj(e,n,t[n]);return e},$Re=(e,t)=>RRe(e,NRe(t));const Ow=4,qj={xs:"3px 6px",sm:"5px 10px",md:"7px 14px",lg:"9px 16px",xl:"12px 20px"};var LRe=lt((e,{fullWidth:t,color:n,radius:r,shouldAnimate:i,transitionDuration:s,transitionTimingFunction:o,size:a,orientation:u},l)=>{const c=u==="vertical",f=e.fn.variant({variant:"filled",color:n});return{label:$Re(_b(_b({ref:l("label")},e.fn.focusStyles()),e.fn.fontStyles()),{WebkitTapHighlightColor:"transparent",borderRadius:e.fn.radius(r),fontWeight:500,fontSize:a in e.fontSizes?e.fontSizes[a]:e.fontSizes.sm,cursor:"pointer",display:"block",textAlign:"center",padding:qj[a in qj?a:"sm"],whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis",userSelect:"none",color:e.colorScheme==="dark"?e.colors.dark[1]:e.colors.gray[7],transition:`color ${i?0:s}ms ${o||e.transitionTimingFunction}`,"&:hover":{color:e.colorScheme==="dark"?e.colors.dark[0]:e.black}}),control:{ref:l("control"),position:"relative",boxSizing:"border-box",flex:1,zIndex:2,transition:`border-left-color ${i?0:s}ms ${o||e.transitionTimingFunction}`,"&:not(:first-of-type)":{borderStyle:"solid",borderWidth:c?"1px 0 0 0":"0 0 0 1px",borderColor:e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[3]}},input:{height:0,width:0,position:"absolute",overflow:"hidden",whiteSpace:"nowrap",opacity:0,"&:focus":{outline:"none",[`& + .${l("label")}`]:_b({},e.focusRing==="always"||e.focusRing==="auto"?e.focusRingStyles.styles(e):e.focusRingStyles.resetStyles(e)),"&:focus:not(:focus-visible)":{[`& + .${l("label")}`]:_b({},e.focusRing==="auto"||e.focusRing==="never"?e.focusRingStyles.resetStyles(e):null)}}},root:{position:"relative",display:t||c?"flex":"inline-flex",width:c&&!t?"max-content":"auto",flexDirection:c?"column":"row",backgroundColor:e.colorScheme==="dark"?e.colors.dark[8]:e.colors.gray[1],borderRadius:e.fn.radius(r),overflow:"hidden",padding:Ow},controlActive:{borderLeftColor:"transparent !important",borderTopColor:"transparent !important",[`& + .${l("control")}`]:{borderLeftColor:"transparent !important",borderTopColor:"transparent !important"},borderRadius:e.fn.radius(r),boxShadow:i?n||e.colorScheme==="dark"?"none":e.shadows.xs:void 0,backgroundColor:i?n?f.background:e.colorScheme==="dark"?e.colors.dark[5]:e.white:void 0},labelActive:{"&, &:hover":{color:n||e.colorScheme==="dark"?e.white:e.black}},disabled:{"&, &:hover":{color:e.colorScheme==="dark"?e.colors.dark[3]:e.colors.gray[5],cursor:"not-allowed"}},active:{boxSizing:"border-box",borderRadius:e.fn.radius(r),position:"absolute",zIndex:1,boxShadow:n||e.colorScheme==="dark"?"none":e.shadows.xs,transition:`transform ${i?0:s}ms ${e.transitionTimingFunction}, width ${i?0:s/2}ms ${o||e.transitionTimingFunction}`,backgroundColor:n?f.background:e.colorScheme==="dark"?e.colors.dark[5]:e.white}}}),MRe=Object.defineProperty,fT=Object.getOwnPropertySymbols,Zee=Object.prototype.hasOwnProperty,ete=Object.prototype.propertyIsEnumerable,Gj=(e,t,n)=>t in e?MRe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,FRe=(e,t)=>{for(var n in t||(t={}))Zee.call(t,n)&&Gj(e,n,t[n]);if(fT)for(var n of fT(t))ete.call(t,n)&&Gj(e,n,t[n]);return e},BRe=(e,t)=>{var n={};for(var r in e)Zee.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&fT)for(var r of fT(e))t.indexOf(r)<0&&ete.call(e,r)&&(n[r]=e[r]);return n};const jRe={disabled:!1,size:"sm",transitionDuration:200},ZR=w.forwardRef((e,t)=>{var n,r,i,s;const o=Ve("SegmentedControl",jRe,e),{className:a,disabled:u,data:l,name:c,value:f,onChange:d,color:h,fullWidth:p,radius:m,size:y,transitionDuration:g,transitionTimingFunction:v,classNames:b,styles:S,defaultValue:T,orientation:E,unstyled:I}=o,A=BRe(o,["className","disabled","data","name","value","onChange","color","fullWidth","radius","size","transitionDuration","transitionTimingFunction","classNames","styles","defaultValue","orientation","unstyled"]),R=ji(),F=Rx(),L=R.respectReducedMotion?F:!1,B=l.map(fe=>typeof fe=="string"?{label:fe,value:fe}:fe),J=w.useRef(),[V,re]=w.useState(!1),[oe,ae]=oa({value:f,defaultValue:T,finalValue:Array.isArray(B)&&(s=(i=(n=B.find(fe=>!fe.disabled))==null?void 0:n.value)!=null?i:(r=B[0])==null?void 0:r.value)!=null?s:null,onChange:d}),{classes:ee,cx:ue}=LRe({size:y,fullWidth:p,color:h,radius:m,shouldAnimate:L||!V,transitionDuration:g,transitionTimingFunction:v,orientation:E},{classNames:b,styles:S,unstyled:I,name:"SegmentedControl"}),[P,W]=w.useState({width:0,height:0,translate:[0,0]}),Q=tu(c),x=w.useRef({}),[O,$]=Nx();I$(()=>{J.current?re(!0):(J.current=!0,re(!1))}),w.useEffect(()=>{if(oe in x.current&&O.current){const fe=x.current[oe],de=fe.getBoundingClientRect(),ve=fe.offsetWidth/de.width,Ee=de.width*ve||0,ge=de.height*ve||0,nt=$.width-fe.parentElement.offsetLeft+Ow-Ee,Je=fe.parentElement.offsetLeft-Ow;W({width:Ee,height:ge,translate:[R.dir==="rtl"?nt:Je,fe.parentElement.offsetTop-Ow]})}},[oe,$]);const q=B.map(fe=>N.createElement("div",{className:ue(ee.control,{[ee.controlActive]:oe===fe.value}),key:fe.value},N.createElement("input",{className:ee.input,disabled:u||fe.disabled,type:"radio",name:Q,value:fe.value,id:`${Q}-${fe.value}`,checked:oe===fe.value,onChange:()=>ae(fe.value)}),N.createElement("label",{className:ue(ee.label,{[ee.labelActive]:oe===fe.value,[ee.disabled]:u||fe.disabled}),htmlFor:`${Q}-${fe.value}`,ref:de=>{x.current[fe.value]=de}},fe.label))),ce=fa(O,t);return B.length===0?null:N.createElement(it,FRe({className:ue(ee.root,a),ref:ce},A),typeof oe=="string"&&V&&N.createElement(it,{component:"span",className:ee.active,sx:{width:P.width,height:P.height,transform:`translate(${P.translate[0]}px, ${P.translate[1]}px )`}}),q)});ZR.displayName="@mantine/core/SegmentedControl";function URe({data:e,searchable:t,limit:n,searchValue:r,filter:i,value:s,filterDataOnExactSearchMatch:o}){if(!t)return e;const a=s!=null&&e.find(l=>l.value===s)||null;if(a&&!o&&(a==null?void 0:a.label)===r){if(n){if(n>=e.length)return e;const l=e.indexOf(a),c=l+n,f=c-e.length;return f>0?e.slice(l-f):e.slice(l,c)}return e}const u=[];for(let l=0;l=n));l+=1);return u}var VRe=lt(()=>({input:{"&:not(:disabled)":{cursor:"pointer","&::selection":{backgroundColor:"transparent"}}}})),zRe=Object.defineProperty,HRe=Object.defineProperties,WRe=Object.getOwnPropertyDescriptors,dT=Object.getOwnPropertySymbols,tte=Object.prototype.hasOwnProperty,nte=Object.prototype.propertyIsEnumerable,Yj=(e,t,n)=>t in e?zRe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,_0=(e,t)=>{for(var n in t||(t={}))tte.call(t,n)&&Yj(e,n,t[n]);if(dT)for(var n of dT(t))nte.call(t,n)&&Yj(e,n,t[n]);return e},KP=(e,t)=>HRe(e,WRe(t)),qRe=(e,t)=>{var n={};for(var r in e)tte.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&dT)for(var r of dT(e))t.indexOf(r)<0&&nte.call(e,r)&&(n[r]=e[r]);return n};function GRe(e,t){return t.label.toLowerCase().trim().includes(e.toLowerCase().trim())}function YRe(e,t){return!!e&&!t.some(n=>n.label.toLowerCase()===e.toLowerCase())}const KRe={required:!1,size:"sm",shadow:"sm",itemComponent:O$,transition:"fade",transitionDuration:0,initiallyOpened:!1,filter:GRe,maxDropdownHeight:220,searchable:!1,clearable:!1,limit:1/0,disabled:!1,creatable:!1,shouldCreate:YRe,selectOnBlur:!1,switchDirectionOnFlip:!1,filterDataOnExactSearchMatch:!1,zIndex:cc("popover"),clearButtonTabIndex:0,positionDependencies:[],dropdownPosition:"flip"},rte=w.forwardRef((e,t)=>{const n=eJ("Select",KRe,e),{inputProps:r,wrapperProps:i,shadow:s,data:o,value:a,defaultValue:u,onChange:l,itemComponent:c,onKeyDown:f,onBlur:d,onFocus:h,transition:p,transitionDuration:m,initiallyOpened:y,transitionTimingFunction:g,unstyled:v,classNames:b,styles:S,filter:T,maxDropdownHeight:E,searchable:I,clearable:A,nothingFound:R,clearButtonLabel:F,limit:L,disabled:B,onSearchChange:J,searchValue:V,rightSection:re,rightSectionWidth:oe,creatable:ae,getCreateLabel:ee,shouldCreate:ue,selectOnBlur:P,onCreate:W,dropdownComponent:Q,onDropdownClose:x,onDropdownOpen:O,withinPortal:$,switchDirectionOnFlip:q,zIndex:ce,name:fe,dropdownPosition:de,allowDeselect:ve,placeholder:Ee,filterDataOnExactSearchMatch:ge,clearButtonTabIndex:nt,form:Je,positionDependencies:yt,readOnly:ke,hoverOnSearchChange:at}=n,St=qRe(n,["inputProps","wrapperProps","shadow","data","value","defaultValue","onChange","itemComponent","onKeyDown","onBlur","onFocus","transition","transitionDuration","initiallyOpened","transitionTimingFunction","unstyled","classNames","styles","filter","maxDropdownHeight","searchable","clearable","nothingFound","clearButtonLabel","limit","disabled","onSearchChange","searchValue","rightSection","rightSectionWidth","creatable","getCreateLabel","shouldCreate","selectOnBlur","onCreate","dropdownComponent","onDropdownClose","onDropdownOpen","withinPortal","switchDirectionOnFlip","zIndex","name","dropdownPosition","allowDeselect","placeholder","filterDataOnExactSearchMatch","clearButtonTabIndex","form","positionDependencies","readOnly","hoverOnSearchChange"]),{classes:cn,cx:bn,theme:He}=VRe(),[Fe,st]=w.useState(y),[dt,At]=w.useState(-1),Kt=w.useRef(),me=w.useRef({}),[Se,Le]=w.useState("column"),Ke=Se==="column",{scrollIntoView:ct,targetRef:In,scrollableRef:Me}=HK({duration:0,offset:5,cancelable:!1,isList:!0}),Ze=ve===void 0?A:ve,ot=xe=>{if(Fe!==xe){st(xe);const et=xe?O:x;typeof et=="function"&&et()}},Gt=ae&&typeof ee=="function";let pt=null;const _r=o.map(xe=>typeof xe=="string"?{label:xe,value:xe}:xe),mn=uK({data:_r}),[qn,cs,xs]=oa({value:a,defaultValue:u,finalValue:null,onChange:l}),ui=mn.find(xe=>xe.value===qn),[Nn,ba]=oa({value:V,defaultValue:(ui==null?void 0:ui.label)||"",finalValue:void 0,onChange:J}),Nr=xe=>{ba(xe),I&&typeof J=="function"&&J(xe)},br=()=>{var xe;ke||(cs(null),xs||Nr(""),(xe=Kt.current)==null||xe.focus())};w.useEffect(()=>{const xe=mn.find(et=>et.value===qn);xe?Nr(xe.label):(!Gt||!qn)&&Nr("")},[qn]),w.useEffect(()=>{ui&&(!I||!Fe)&&Nr(ui.label)},[ui==null?void 0:ui.label]);const $n=xe=>{if(!ke)if(Ze&&(ui==null?void 0:ui.value)===xe.value)cs(null),ot(!1);else{if(xe.creatable&&typeof W=="function"){const et=W(xe.value);typeof et<"u"&&et!==null&&cs(typeof et=="string"?et:et.value)}else cs(xe.value);xs||Nr(xe.label),At(-1),ot(!1),Kt.current.focus()}},fn=URe({data:mn,searchable:I,limit:L,searchValue:Nn,filter:T,filterDataOnExactSearchMatch:ge,value:qn});Gt&&ue(Nn,fn)&&(pt=ee(Nn),fn.push({label:Nn,value:Nn,creatable:!0}));const Yn=(xe,et,Ft)=>{let Be=xe;for(;Ft(Be);)if(Be=et(Be),!fn[Be].disabled)return Be;return xe};Js(()=>{At(at&&Nn?0:-1)},[Nn,at]);const fs=qn?fn.findIndex(xe=>xe.value===qn):0,Kr=!ke&&(fn.length>0?Fe:Fe&&!!R),jr=()=>{At(xe=>{var et;const Ft=Yn(xe,Be=>Be-1,Be=>Be>0);return In.current=me.current[(et=fn[Ft])==null?void 0:et.value],Kr&&ct({alignment:Ke?"start":"end"}),Ft})},X=()=>{At(xe=>{var et;const Ft=Yn(xe,Be=>Be+1,Be=>Bewindow.setTimeout(()=>{var xe;In.current=me.current[(xe=fn[fs])==null?void 0:xe.value],ct({alignment:Ke?"end":"start"})},0);Js(()=>{Kr&&z()},[Kr]);const Z=xe=>{switch(typeof f=="function"&&f(xe),xe.key){case"ArrowUp":{xe.preventDefault(),Fe?Ke?jr():X():(At(fs),ot(!0),z());break}case"ArrowDown":{xe.preventDefault(),Fe?Ke?X():jr():(At(fs),ot(!0),z());break}case"Home":{if(!I){xe.preventDefault(),Fe||ot(!0);const et=fn.findIndex(Ft=>!Ft.disabled);At(et),Kr&&ct({alignment:Ke?"end":"start"})}break}case"End":{if(!I){xe.preventDefault(),Fe||ot(!0);const et=fn.map(Ft=>!!Ft.disabled).lastIndexOf(!1);At(et),Kr&&ct({alignment:Ke?"end":"start"})}break}case"Escape":{xe.preventDefault(),ot(!1),At(-1);break}case" ":{I||(xe.preventDefault(),fn[dt]&&Fe?$n(fn[dt]):(ot(!0),At(fs),z()));break}case"Enter":I||xe.preventDefault(),fn[dt]&&Fe&&(xe.preventDefault(),$n(fn[dt]))}},he=xe=>{typeof d=="function"&&d(xe);const et=mn.find(Ft=>Ft.value===qn);P&&fn[dt]&&Fe&&$n(fn[dt]),Nr((et==null?void 0:et.label)||""),ot(!1)},pe=xe=>{typeof h=="function"&&h(xe),I&&ot(!0)},Ye=xe=>{ke||(Nr(xe.currentTarget.value),A&&xe.currentTarget.value===""&&cs(null),At(-1),ot(!0))},Qe=()=>{ke||(ot(!Fe),qn&&!Fe&&At(fs))};return N.createElement(Zs.Wrapper,KP(_0({},i),{__staticSelector:"Select"}),N.createElement(hf,{opened:Kr,transition:p,transitionDuration:m,shadow:"sm",withinPortal:$,__staticSelector:"Select",onDirectionChange:Le,switchDirectionOnFlip:q,zIndex:ce,dropdownPosition:de,positionDependencies:[...yt,Nn],classNames:b,styles:S,unstyled:v},N.createElement(hf.Target,null,N.createElement("div",{role:"combobox","aria-haspopup":"listbox","aria-owns":Kr?`${r.id}-items`:null,"aria-controls":r.id,"aria-expanded":Kr,onMouseLeave:()=>At(-1),tabIndex:-1},N.createElement("input",{type:"hidden",name:fe,value:qn||"",form:Je,disabled:B}),N.createElement(Zs,_0(KP(_0(_0({autoComplete:"off",type:"search"},r),St),{ref:fa(t,Kt),onKeyDown:Z,__staticSelector:"Select",value:Nn,placeholder:Ee,onChange:Ye,"aria-autocomplete":"list","aria-controls":Kr?`${r.id}-items`:null,"aria-activedescendant":dt>=0?`${r.id}-${dt}`:null,onMouseDown:Qe,onBlur:he,onFocus:pe,readOnly:!I||ke,disabled:B,"data-mantine-stop-propagation":Kr,name:null,classNames:KP(_0({},b),{input:bn({[cn.input]:!I},b==null?void 0:b.input)})}),bee({theme:He,rightSection:re,rightSectionWidth:oe,styles:S,size:r.size,shouldClear:A&&!!ui,clearButtonLabel:F,onClear:br,error:i.error,clearButtonTabIndex:nt,disabled:B,readOnly:ke}))))),N.createElement(hf.Dropdown,{component:Q||Bx,maxHeight:E,direction:Se,id:r.id,innerRef:Me,__staticSelector:"Select",classNames:b,styles:S},N.createElement(P$,{data:fn,hovered:dt,classNames:b,styles:S,isItemSelected:xe=>xe===qn,uuid:r.id,__staticSelector:"Select",onItemHover:At,onItemSelect:$n,itemsRefs:me,itemComponent:c,size:r.size,nothingFound:R,creatable:Gt&&!!pt,createLabel:pt,"aria-label":i.label,unstyled:v}))))});rte.displayName="@mantine/core/Select";function hT({value:e,min:t,max:n}){const r=(e-t)/(n-t)*100;return Math.min(Math.max(r,0),100)}function eN({value:e,containerWidth:t,min:n,max:r,step:i,precision:s}){const a=(t?Math.min(Math.max(e,0),t)/t:e)*(r-n),u=(a!==0?Math.round(a/i)*i:0)+n,l=Math.max(u,n);return s!==void 0?Number(l.toFixed(s)):l}var QRe=Object.defineProperty,XRe=Object.defineProperties,JRe=Object.getOwnPropertyDescriptors,Kj=Object.getOwnPropertySymbols,ZRe=Object.prototype.hasOwnProperty,eNe=Object.prototype.propertyIsEnumerable,Qj=(e,t,n)=>t in e?QRe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,tNe=(e,t)=>{for(var n in t||(t={}))ZRe.call(t,n)&&Qj(e,n,t[n]);if(Kj)for(var n of Kj(t))eNe.call(t,n)&&Qj(e,n,t[n]);return e},nNe=(e,t)=>XRe(e,JRe(t));const Vs={xs:4,sm:6,md:8,lg:10,xl:12};var rNe=lt((e,{size:t,disabled:n})=>({root:nNe(tNe({},e.fn.fontStyles()),{WebkitTapHighlightColor:"transparent",outline:0,height:e.fn.size({sizes:Vs,size:t})*2,display:"flex",alignItems:"center",cursor:n?"not-allowed":"pointer",touchAction:"none"})}));const iNe=rNe;var sNe=Object.defineProperty,oNe=Object.defineProperties,aNe=Object.getOwnPropertyDescriptors,Xj=Object.getOwnPropertySymbols,uNe=Object.prototype.hasOwnProperty,lNe=Object.prototype.propertyIsEnumerable,Jj=(e,t,n)=>t in e?sNe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,cNe=(e,t)=>{for(var n in t||(t={}))uNe.call(t,n)&&Jj(e,n,t[n]);if(Xj)for(var n of Xj(t))lNe.call(t,n)&&Jj(e,n,t[n]);return e},fNe=(e,t)=>oNe(e,aNe(t)),dNe=lt((e,{color:t,size:n,disabled:r,thumbSize:i})=>({label:{position:"absolute",top:-36,backgroundColor:e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[9],fontSize:e.fontSizes.xs,color:e.white,padding:`calc(${e.spacing.xs}px / 2)`,borderRadius:e.radius.sm,whiteSpace:"nowrap",pointerEvents:"none",userSelect:"none",touchAction:"none"},thumb:fNe(cNe({},e.fn.focusStyles()),{boxSizing:"border-box",position:"absolute",display:r?"none":"flex",height:i||e.fn.size({sizes:Vs,size:n})*2,width:i||e.fn.size({sizes:Vs,size:n})*2,backgroundColor:e.colorScheme==="dark"?e.fn.themeColor(t,e.fn.primaryShade()):e.white,border:`4px solid ${e.colorScheme==="dark"?e.white:e.fn.themeColor(t,e.fn.primaryShade())}`,color:e.colorScheme==="dark"?e.white:e.fn.themeColor(t,e.fn.primaryShade()),transform:"translate(-50%, -50%)",top:"50%",cursor:"pointer",borderRadius:1e3,alignItems:"center",justifyContent:"center",transitionDuration:"100ms",transitionProperty:"box-shadow, transform",transitionTimingFunction:e.transitionTimingFunction,zIndex:3,userSelect:"none",touchAction:"none"}),dragging:{transform:"translate(-50%, -50%) scale(1.05)",boxShadow:e.shadows.sm}}));const pT=w.forwardRef(({max:e,min:t,value:n,position:r,label:i,dragging:s,onMouseDown:o,color:a,classNames:u,styles:l,size:c,labelTransition:f,labelTransitionDuration:d,labelTransitionTimingFunction:h,labelAlwaysOn:p,thumbLabel:m,onFocus:y,onBlur:g,showLabelOnHover:v,children:b=null,disabled:S,unstyled:T,thumbSize:E},I)=>{const{classes:A,cx:R,theme:F}=dNe({color:a,size:c,disabled:S,thumbSize:E},{classNames:u,styles:l,unstyled:T,name:"Slider"}),[L,B]=w.useState(!1),J=p||s||L||v;return N.createElement(it,{tabIndex:0,role:"slider","aria-label":m,"aria-valuemax":e,"aria-valuemin":t,"aria-valuenow":n,ref:I,className:R(A.thumb,{[A.dragging]:s}),onFocus:()=>{B(!0),typeof y=="function"&&y()},onBlur:()=>{B(!1),typeof g=="function"&&g()},onTouchStart:o,onMouseDown:o,onClick:V=>V.stopPropagation(),style:{[F.dir==="rtl"?"right":"left"]:`${r}%`}},b,N.createElement(Vx,{mounted:i!=null&&J,duration:d,transition:f,timingFunction:h||F.transitionTimingFunction},V=>N.createElement("div",{style:V,className:A.label},i)))});pT.displayName="@mantine/core/SliderThumb";function hNe({mark:e,offset:t,value:n,inverted:r=!1}){return r?typeof t=="number"&&e.value<=t||e.value>=n:typeof t=="number"?e.value>=t&&e.value<=n:e.value<=n}var pNe=lt((e,{size:t,color:n,disabled:r})=>({markWrapper:{position:"absolute",top:0,zIndex:2},mark:{boxSizing:"border-box",border:`${e.fn.size({size:t,sizes:Vs})>=8?"2px":"1px"} solid ${e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[2]}`,height:e.fn.size({sizes:Vs,size:t}),width:e.fn.size({sizes:Vs,size:t}),borderRadius:1e3,transform:`translateX(-${e.fn.size({sizes:Vs,size:t})/2}px)`,backgroundColor:e.white},markFilled:{borderColor:r?e.colorScheme==="dark"?e.colors.dark[3]:e.colors.gray[4]:e.fn.variant({variant:"filled",color:n}).background},markLabel:{transform:"translate(-50%, 0)",fontSize:e.fontSizes.sm,color:e.colorScheme==="dark"?e.colors.dark[2]:e.colors.gray[6],marginTop:`calc(${e.spacing.xs}px / 2)`,whiteSpace:"nowrap"}}));function ite({marks:e,color:t,size:n,min:r,max:i,value:s,classNames:o,styles:a,offset:u,onChange:l,disabled:c,unstyled:f,inverted:d}){const{classes:h,cx:p}=pNe({size:n,color:t,disabled:c},{classNames:o,styles:a,unstyled:f,name:"Slider"}),m=e.map((y,g)=>N.createElement(it,{className:h.markWrapper,sx:{left:`${hT({value:y.value,min:r,max:i})}%`},key:g},N.createElement("div",{className:p(h.mark,{[h.markFilled]:hNe({mark:y,value:s,offset:u,inverted:d})})}),y.label&&N.createElement("div",{className:h.markLabel,onMouseDown:v=>{v.stopPropagation(),l(y.value)},onTouchStart:v=>{v.stopPropagation(),l(y.value)}},y.label)));return N.createElement("div",null,m)}ite.displayName="@mantine/core/SliderMarks";var mNe=lt((e,{radius:t,size:n,color:r,disabled:i,inverted:s})=>({track:{position:"relative",height:e.fn.size({sizes:Vs,size:n}),width:"100%",marginRight:e.fn.size({size:n,sizes:Vs}),marginLeft:e.fn.size({size:n,sizes:Vs}),"&::before":{content:'""',position:"absolute",top:0,bottom:0,borderRadius:e.fn.size({size:t,sizes:e.radius}),right:-e.fn.size({size:n,sizes:Vs}),left:-e.fn.size({size:n,sizes:Vs}),backgroundColor:s?i?e.colorScheme==="dark"?e.colors.dark[3]:e.colors.gray[4]:e.fn.variant({variant:"filled",color:r}).background:e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[2],zIndex:0}},bar:{position:"absolute",zIndex:1,top:0,bottom:0,backgroundColor:s?e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[2]:i?e.colorScheme==="dark"?e.colors.dark[3]:e.colors.gray[4]:e.fn.variant({variant:"filled",color:r}).background,borderRadius:e.fn.size({size:t,sizes:e.radius})}})),gNe=Object.defineProperty,yNe=Object.defineProperties,vNe=Object.getOwnPropertyDescriptors,mT=Object.getOwnPropertySymbols,ste=Object.prototype.hasOwnProperty,ote=Object.prototype.propertyIsEnumerable,Zj=(e,t,n)=>t in e?gNe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,_Ne=(e,t)=>{for(var n in t||(t={}))ste.call(t,n)&&Zj(e,n,t[n]);if(mT)for(var n of mT(t))ote.call(t,n)&&Zj(e,n,t[n]);return e},bNe=(e,t)=>yNe(e,vNe(t)),wNe=(e,t)=>{var n={};for(var r in e)ste.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&mT)for(var r of mT(e))t.indexOf(r)<0&&ote.call(e,r)&&(n[r]=e[r]);return n};function Z$(e){var t=e,{filled:n,size:r,color:i,classNames:s,styles:o,radius:a,children:u,offset:l,onMouseLeave:c,onMouseEnter:f,disabled:d,marksOffset:h,unstyled:p,inverted:m}=t,y=wNe(t,["filled","size","color","classNames","styles","radius","children","offset","onMouseLeave","onMouseEnter","disabled","marksOffset","unstyled","inverted"]);const{classes:g}=mNe({color:i,size:r,radius:a,disabled:d,inverted:m},{classNames:s,styles:o,unstyled:p,name:"Slider"});return N.createElement("div",{className:g.track,onMouseLeave:c,onMouseEnter:f},N.createElement(it,{className:g.bar,sx:v=>({left:`calc(${l}% - ${v.fn.size({size:r,sizes:Vs})}px)`,width:`calc(${n}% + ${v.fn.size({size:r,sizes:Vs})}px)`})}),u,N.createElement(ite,bNe(_Ne({},y),{size:r,color:i,offset:h,classNames:s,styles:o,disabled:d,unstyled:p,inverted:m})))}Z$.displayName="@mantine/core/SliderTrack";var ENe=Object.defineProperty,SNe=Object.defineProperties,TNe=Object.getOwnPropertyDescriptors,gT=Object.getOwnPropertySymbols,ate=Object.prototype.hasOwnProperty,ute=Object.prototype.propertyIsEnumerable,eU=(e,t,n)=>t in e?ENe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,INe=(e,t)=>{for(var n in t||(t={}))ate.call(t,n)&&eU(e,n,t[n]);if(gT)for(var n of gT(t))ute.call(t,n)&&eU(e,n,t[n]);return e},xNe=(e,t)=>SNe(e,TNe(t)),CNe=(e,t)=>{var n={};for(var r in e)ate.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&gT)for(var r of gT(e))t.indexOf(r)<0&&ute.call(e,r)&&(n[r]=e[r]);return n};const e3=w.forwardRef((e,t)=>{var n=e,{className:r,size:i,classNames:s,styles:o,disabled:a,unstyled:u}=n,l=CNe(n,["className","size","classNames","styles","disabled","unstyled"]);const{classes:c,cx:f}=iNe({size:i,disabled:a},{classNames:s,styles:o,unstyled:u,name:"Slider"});return N.createElement(it,xNe(INe({},l),{tabIndex:-1,className:f(c.root,r),ref:t}))});e3.displayName="@mantine/core/SliderRoot";var ANe=Object.defineProperty,PNe=Object.defineProperties,ONe=Object.getOwnPropertyDescriptors,yT=Object.getOwnPropertySymbols,lte=Object.prototype.hasOwnProperty,cte=Object.prototype.propertyIsEnumerable,tU=(e,t,n)=>t in e?ANe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,RNe=(e,t)=>{for(var n in t||(t={}))lte.call(t,n)&&tU(e,n,t[n]);if(yT)for(var n of yT(t))cte.call(t,n)&&tU(e,n,t[n]);return e},NNe=(e,t)=>PNe(e,ONe(t)),kNe=(e,t)=>{var n={};for(var r in e)lte.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&yT)for(var r of yT(e))t.indexOf(r)<0&&cte.call(e,r)&&(n[r]=e[r]);return n};const DNe={size:"md",radius:"xl",min:0,max:100,step:1,marks:[],label:e=>e,labelTransition:"skew-down",labelTransitionDuration:0,labelAlwaysOn:!1,thumbLabel:"",showLabelOnHover:!0,disabled:!1,scale:e=>e},fte=w.forwardRef((e,t)=>{const n=Ve("Slider",DNe,e),{classNames:r,styles:i,color:s,value:o,onChange:a,onChangeEnd:u,size:l,radius:c,min:f,max:d,step:h,precision:p,defaultValue:m,name:y,marks:g,label:v,labelTransition:b,labelTransitionDuration:S,labelTransitionTimingFunction:T,labelAlwaysOn:E,thumbLabel:I,showLabelOnHover:A,thumbChildren:R,disabled:F,unstyled:L,thumbSize:B,scale:J,inverted:V}=n,re=kNe(n,["classNames","styles","color","value","onChange","onChangeEnd","size","radius","min","max","step","precision","defaultValue","name","marks","label","labelTransition","labelTransitionDuration","labelTransitionTimingFunction","labelAlwaysOn","thumbLabel","showLabelOnHover","thumbChildren","disabled","unstyled","thumbSize","scale","inverted"]),oe=ji(),[ae,ee]=w.useState(!1),[ue,P]=oa({value:typeof o=="number"?ff(o,f,d):o,defaultValue:typeof m=="number"?ff(m,f,d):m,finalValue:ff(0,f,d),onChange:a}),W=w.useRef(ue),Q=w.useRef(),x=hT({value:ue,min:f,max:d}),O=J(ue),$=typeof v=="function"?v(O):v,q=w.useCallback(({x:Ee})=>{if(!F){const ge=eN({value:Ee,min:f,max:d,step:h,precision:p});P(ge),W.current=ge}},[F,f,d,h,p]),{ref:ce,active:fe}=zK(q,{onScrubEnd:()=>u==null?void 0:u(W.current)},oe.dir),de=Ee=>{Ee.stopPropagation()},ve=Ee=>{if(!F)switch(Ee.key){case"ArrowUp":{Ee.preventDefault(),Q.current.focus();const ge=Math.min(Math.max(ue+h,f),d);u==null||u(ge),P(ge);break}case"ArrowRight":{Ee.preventDefault(),Q.current.focus();const ge=Math.min(Math.max(oe.dir==="rtl"?ue-h:ue+h,f),d);u==null||u(ge),P(ge);break}case"ArrowDown":{Ee.preventDefault(),Q.current.focus();const ge=Math.min(Math.max(ue-h,f),d);u==null||u(ge),P(ge);break}case"ArrowLeft":{Ee.preventDefault(),Q.current.focus();const ge=Math.min(Math.max(oe.dir==="rtl"?ue+h:ue-h,f),d);u==null||u(ge),P(ge);break}case"Home":{Ee.preventDefault(),Q.current.focus(),u==null||u(f),P(f);break}case"End":{Ee.preventDefault(),Q.current.focus(),u==null||u(d),P(d);break}}};return N.createElement(e3,NNe(RNe({},re),{size:l,ref:fa(ce,t),onKeyDownCapture:ve,onMouseDownCapture:()=>{var Ee;return(Ee=ce.current)==null?void 0:Ee.focus()},classNames:r,styles:i,disabled:F,unstyled:L}),N.createElement(Z$,{inverted:V,offset:0,filled:x,marks:g,size:l,radius:c,color:s,min:f,max:d,value:O,onChange:P,onMouseEnter:A?()=>ee(!0):void 0,onMouseLeave:A?()=>ee(!1):void 0,classNames:r,styles:i,disabled:F,unstyled:L},N.createElement(pT,{max:d,min:f,value:O,position:x,dragging:fe,color:s,size:l,label:$,ref:Q,onMouseDown:de,labelTransition:b,labelTransitionDuration:S,labelTransitionTimingFunction:T,labelAlwaysOn:E,classNames:r,styles:i,thumbLabel:I,showLabelOnHover:A&&ae,disabled:F,unstyled:L,thumbSize:B},R)),N.createElement("input",{type:"hidden",name:y,value:O}))});fte.displayName="@mantine/core/Slider";function $Ne(e){return"TouchEvent"in window&&e instanceof window.TouchEvent?e.touches[0].clientX:e.clientX}var LNe=Object.defineProperty,MNe=Object.defineProperties,FNe=Object.getOwnPropertyDescriptors,vT=Object.getOwnPropertySymbols,dte=Object.prototype.hasOwnProperty,hte=Object.prototype.propertyIsEnumerable,nU=(e,t,n)=>t in e?LNe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,QP=(e,t)=>{for(var n in t||(t={}))dte.call(t,n)&&nU(e,n,t[n]);if(vT)for(var n of vT(t))hte.call(t,n)&&nU(e,n,t[n]);return e},XP=(e,t)=>MNe(e,FNe(t)),BNe=(e,t)=>{var n={};for(var r in e)dte.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&vT)for(var r of vT(e))t.indexOf(r)<0&&hte.call(e,r)&&(n[r]=e[r]);return n};const jNe={size:"md",radius:"xl",min:0,max:100,minRange:10,step:1,marks:[],label:e=>e,labelTransition:"skew-down",labelTransitionDuration:0,labelAlwaysOn:!1,thumbFromLabel:"",thumbToLabel:"",showLabelOnHover:!0,disabled:!1,scale:e=>e},pte=w.forwardRef((e,t)=>{const n=Ve("RangeSlider",jNe,e),{classNames:r,styles:i,color:s,value:o,onChange:a,onChangeEnd:u,size:l,radius:c,min:f,max:d,minRange:h,maxRange:p,step:m,precision:y,defaultValue:g,name:v,marks:b,label:S,labelTransition:T,labelTransitionDuration:E,labelTransitionTimingFunction:I,labelAlwaysOn:A,thumbFromLabel:R,thumbToLabel:F,showLabelOnHover:L,thumbChildren:B,disabled:J,unstyled:V,thumbSize:re,scale:oe,inverted:ae}=n,ee=BNe(n,["classNames","styles","color","value","onChange","onChangeEnd","size","radius","min","max","minRange","maxRange","step","precision","defaultValue","name","marks","label","labelTransition","labelTransitionDuration","labelTransitionTimingFunction","labelAlwaysOn","thumbFromLabel","thumbToLabel","showLabelOnHover","thumbChildren","disabled","unstyled","thumbSize","scale","inverted"]),ue=ji(),[P,W]=w.useState(-1),[Q,x]=w.useState(!1),[O,$]=oa({value:o,defaultValue:g,finalValue:[f,d],onChange:a}),q=w.useRef(O),ce=w.useRef([]),fe=w.useRef(void 0),de=[hT({value:O[0],min:f,max:d}),hT({value:O[1],min:f,max:d})],ve=He=>{$(He),q.current=He};w.useEffect(()=>{Array.isArray(o)&&(q.current=o)},Array.isArray(o)?[o[0],o[1]]:[null,null]);const Ee=(He,Fe,st)=>{const dt=[...q.current];dt[Fe]=He,Fe===0&&(He>dt[1]-(h-1e-9)&&(dt[1]=Math.min(He+h,d)),He>(d-(h-1e-9)||f)&&(dt[Fe]=q.current[Fe]),dt[1]-He>p&&(dt[1]=He+p)),Fe===1&&(Hep&&(dt[0]=He-p)),ve(dt),st&&(u==null||u(q.current))},ge=He=>{if(!J){const Fe=eN({value:He,min:f,max:d,step:m,precision:y});Ee(Fe,fe.current,!1)}},{ref:nt,active:Je}=zK(({x:He})=>ge(He),{onScrubEnd:()=>u==null?void 0:u(q.current)},ue.dir);function yt(He,Fe){He.stopPropagation(),fe.current=Fe}const ke=He=>{nt.current.focus();const Fe=nt.current.getBoundingClientRect(),st=$Ne(He.nativeEvent),dt=eN({value:st-Fe.left,max:d,min:f,step:m,containerWidth:Fe.width}),At=Math.abs(O[0]-dt)>Math.abs(O[1]-dt)?1:0,Kt=ue.dir==="ltr"?At:At===1?0:1;fe.current=Kt},at=()=>P!==1&&P!==0?(W(0),0):P,St=He=>{if(!J)switch(He.key){case"ArrowUp":{He.preventDefault();const Fe=at();ce.current[Fe].focus(),Ee(Math.min(Math.max(q.current[Fe]+m,f),d),Fe,!0);break}case"ArrowRight":{He.preventDefault();const Fe=at();ce.current[Fe].focus(),Ee(Math.min(Math.max(ue.dir==="rtl"?q.current[Fe]-m:q.current[Fe]+m,f),d),Fe,!0);break}case"ArrowDown":{He.preventDefault();const Fe=at();ce.current[Fe].focus(),Ee(Math.min(Math.max(q.current[Fe]-m,f),d),Fe,!0);break}case"ArrowLeft":{He.preventDefault();const Fe=at();ce.current[Fe].focus(),Ee(Math.min(Math.max(ue.dir==="rtl"?q.current[Fe]+m:q.current[Fe]-m,f),d),Fe,!0);break}}},cn={max:d,min:f,color:s,size:l,labelTransition:T,labelTransitionDuration:E,labelTransitionTimingFunction:I,labelAlwaysOn:A,onBlur:()=>W(-1),classNames:r,styles:i},bn=Array.isArray(B);return N.createElement(e3,XP(QP({},ee),{size:l,ref:fa(nt,t),onTouchStartCapture:ke,onTouchEndCapture:()=>{fe.current=-1},onMouseDownCapture:ke,onMouseUpCapture:()=>{fe.current=-1},onKeyDownCapture:St,styles:i,classNames:r,disabled:J,unstyled:V}),N.createElement(Z$,{offset:de[0],marksOffset:O[0],filled:de[1]-de[0],marks:b,inverted:ae,size:l,radius:c,color:s,min:f,max:d,value:O[1],styles:i,classNames:r,onMouseEnter:L?()=>x(!0):void 0,onMouseLeave:L?()=>x(!1):void 0,onChange:He=>{const Fe=Math.abs(O[0]-He)>Math.abs(O[1]-He)?1:0,st=[...O];st[Fe]=He,ve(st)},disabled:J,unstyled:V},N.createElement(pT,XP(QP({},cn),{value:oe(O[0]),position:de[0],dragging:Je,label:typeof S=="function"?S(oe(O[0])):S,ref:He=>{ce.current[0]=He},thumbLabel:R,onMouseDown:He=>yt(He,0),onFocus:()=>W(0),showLabelOnHover:L&&Q,disabled:J,unstyled:V,thumbSize:re}),bn?B[0]:B),N.createElement(pT,XP(QP({},cn),{thumbLabel:F,value:oe(O[1]),position:de[1],dragging:Je,label:typeof S=="function"?S(oe(O[1])):S,ref:He=>{ce.current[1]=He},onMouseDown:He=>yt(He,1),onFocus:()=>W(1),showLabelOnHover:L&&Q,disabled:J,unstyled:V,thumbSize:re}),bn?B[1]:B)),N.createElement("input",{type:"hidden",name:`${v}_from`,value:O[0]}),N.createElement("input",{type:"hidden",name:`${v}_to`,value:O[1]}))});pte.displayName="@mantine/core/RangeSlider";var UNe=Object.defineProperty,_T=Object.getOwnPropertySymbols,mte=Object.prototype.hasOwnProperty,gte=Object.prototype.propertyIsEnumerable,rU=(e,t,n)=>t in e?UNe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,VNe=(e,t)=>{for(var n in t||(t={}))mte.call(t,n)&&rU(e,n,t[n]);if(_T)for(var n of _T(t))gte.call(t,n)&&rU(e,n,t[n]);return e},zNe=(e,t)=>{var n={};for(var r in e)mte.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&_T)for(var r of _T(e))t.indexOf(r)<0&>e.call(e,r)&&(n[r]=e[r]);return n};const HNe={w:0,h:0},bT=w.forwardRef((e,t)=>{const n=Ve("Space",HNe,e),{w:r,h:i}=n,s=zNe(n,["w","h"]);return N.createElement(it,VNe({ref:t,w:r,miw:r,h:i,mih:i},s))});bT.displayName="@mantine/core/Space";var WNe=Object.defineProperty,qNe=Object.defineProperties,GNe=Object.getOwnPropertyDescriptors,iU=Object.getOwnPropertySymbols,YNe=Object.prototype.hasOwnProperty,KNe=Object.prototype.propertyIsEnumerable,sU=(e,t,n)=>t in e?WNe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,QNe=(e,t)=>{for(var n in t||(t={}))YNe.call(t,n)&&sU(e,n,t[n]);if(iU)for(var n of iU(t))KNe.call(t,n)&&sU(e,n,t[n]);return e},XNe=(e,t)=>qNe(e,GNe(t));function JNe(e,t,n){return typeof e<"u"?e in n.headings.sizes?n.headings.sizes[e].fontSize:e:n.headings.sizes[t].fontSize}function ZNe(e,t,n){return typeof e<"u"&&e in n.headings.sizes?n.headings.sizes[e].lineHeight:n.headings.sizes[t].lineHeight}var eke=lt((e,{element:t,weight:n,size:r,inline:i})=>({root:XNe(QNe({},e.fn.fontStyles()),{fontFamily:e.headings.fontFamily,fontWeight:n||e.headings.sizes[t].fontWeight||e.headings.fontWeight,fontSize:JNe(r,t,e),lineHeight:i?1:ZNe(r,t,e),margin:0})})),tke=Object.defineProperty,wT=Object.getOwnPropertySymbols,yte=Object.prototype.hasOwnProperty,vte=Object.prototype.propertyIsEnumerable,oU=(e,t,n)=>t in e?tke(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,nke=(e,t)=>{for(var n in t||(t={}))yte.call(t,n)&&oU(e,n,t[n]);if(wT)for(var n of wT(t))vte.call(t,n)&&oU(e,n,t[n]);return e},rke=(e,t)=>{var n={};for(var r in e)yte.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&wT)for(var r of wT(e))t.indexOf(r)<0&&vte.call(e,r)&&(n[r]=e[r]);return n};const ike={order:1},$c=w.forwardRef((e,t)=>{const n=Ve("Title",ike,e),{className:r,order:i,children:s,unstyled:o,size:a,weight:u,inline:l}=n,c=rke(n,["className","order","children","unstyled","size","weight","inline"]),{classes:f,cx:d}=eke({element:`h${i}`,weight:u,size:a,inline:l},{name:"Title",unstyled:o});return[1,2,3,4,5,6].includes(i)?N.createElement(rt,nke({component:`h${i}`,ref:t,className:d(f.root,r)},c),s):null});$c.displayName="@mantine/core/Title";var ske=Object.defineProperty,oke=Object.defineProperties,ake=Object.getOwnPropertyDescriptors,aU=Object.getOwnPropertySymbols,uke=Object.prototype.hasOwnProperty,lke=Object.prototype.propertyIsEnumerable,uU=(e,t,n)=>t in e?ske(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,bb=(e,t)=>{for(var n in t||(t={}))uke.call(t,n)&&uU(e,n,t[n]);if(aU)for(var n of aU(t))lke.call(t,n)&&uU(e,n,t[n]);return e},wb=(e,t)=>oke(e,ake(t)),cke=lt(e=>{const t=I0e(e.headings.sizes).reduce((n,r)=>{const i=e.headings.sizes[r];return n[`& ${r}`]=wb(bb({fontFamily:e.headings.fontFamily,fontWeight:i.fontWeight||e.headings.fontWeight,marginTop:typeof i.lineHeight=="number"?`calc(${e.spacing.xl}px * ${i.lineHeight})`:e.spacing.xl,marginBottom:e.spacing.sm},i),{"@media (max-width: 755px)":{fontSize:typeof i.fontSize=="number"&&i.fontSize/1.3}}),n},{});return{root:wb(bb(wb(bb({},e.fn.fontStyles()),{color:e.colorScheme==="dark"?e.colors.dark[0]:e.black,lineHeight:e.lineHeight,fontSize:e.fontSizes.md,"@media (max-width: 755px)":{fontSize:e.fontSizes.sm}}),t),{"& .ql-align-center":{textAlign:"center"},"& .ql-align-right":{textAlign:"right"},"& .ql-align-left":{textAlign:"left"},"& img":{maxWidth:"100%",marginBottom:e.spacing.xs},"& p":{marginTop:0,marginBottom:e.spacing.lg},"& mark":{backgroundColor:e.fn.themeColor("yellow",e.colorScheme==="dark"?5:2),color:e.colorScheme==="dark"?e.colors.dark[9]:"inherit"},"& hr":{marginTop:e.spacing.md,marginBottom:e.spacing.sm,borderBottom:0,borderLeft:0,borderRight:0,borderTop:`1px dashed ${e.colors.gray[e.colorScheme==="dark"?4:6]}`},"& a":wb(bb({},e.fn.focusStyles()),{color:e.colors[e.primaryColor][e.colorScheme==="dark"?4:6],textDecoration:"none","&:hover":{textDecoration:"underline"}}),"& pre":{padding:e.spacing.xs,lineHeight:e.lineHeight,margin:0,marginTop:e.spacing.md,marginBottom:e.spacing.md,overflowX:"auto",fontFamily:e.fontFamilyMonospace,fontSize:e.fontSizes.sm,borderRadius:e.radius.sm,backgroundColor:e.colorScheme==="dark"?e.colors.dark[8]:e.colors.gray[0],"& code":{backgroundColor:"transparent",padding:0,borderRadius:0,color:"inherit",border:0}},"& code":{lineHeight:e.lineHeight,padding:"1px 5px",borderRadius:e.radius.sm,color:e.colorScheme==="dark"?e.colors.dark[0]:e.black,backgroundColor:e.colorScheme==="dark"?e.colors.dark[9]:e.colors.gray[0],fontFamily:e.fontFamilyMonospace,fontSize:e.fontSizes.xs,border:`1px solid ${e.colorScheme==="dark"?e.colors.dark[9]:e.colors.gray[3]}`},"& ul, & ol":{marginBottom:e.spacing.md,paddingLeft:38,"& li":{marginTop:e.spacing.xs}},"& table":{width:"100%",borderCollapse:"collapse",captionSide:"bottom",marginBottom:e.spacing.md,"& caption":{marginTop:e.spacing.xs,fontSize:e.fontSizes.sm,color:e.colorScheme==="dark"?e.colors.dark[2]:e.colors.gray[6]},"& th":{textAlign:"left",fontWeight:"bold",color:e.colorScheme==="dark"?e.colors.dark[0]:e.colors.gray[7],fontSize:14,padding:"7px 10px"},"& thead th":{borderBottom:`1px solid ${e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[3]}`},"& tfoot th":{borderTop:`1px solid ${e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[3]}`},"& td":{padding:"7px 10px",borderBottom:`1px solid ${e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[3]}`,fontSize:14},"& tr:last-of-type td":{borderBottom:"none"}},"& blockquote":{fontSize:e.fontSizes.lg,lineHeight:e.lineHeight,margin:`${e.spacing.md}px 0`,borderTopRightRadius:e.radius.sm,borderBottomRightRadius:e.radius.sm,padding:`${e.spacing.md}px ${e.spacing.lg}px`,color:e.colorScheme==="dark"?e.colors.dark[0]:e.black,borderLeft:`6px solid ${e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[3]}`,"& cite":{display:"block",fontSize:e.fontSizes.sm,marginTop:e.spacing.xs,color:e.colorScheme==="dark"?e.colors.dark[2]:e.colors.gray[6],overflow:"hidden",textOverflow:"ellipsis"}}})}}),fke=Object.defineProperty,ET=Object.getOwnPropertySymbols,_te=Object.prototype.hasOwnProperty,bte=Object.prototype.propertyIsEnumerable,lU=(e,t,n)=>t in e?fke(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,dke=(e,t)=>{for(var n in t||(t={}))_te.call(t,n)&&lU(e,n,t[n]);if(ET)for(var n of ET(t))bte.call(t,n)&&lU(e,n,t[n]);return e},hke=(e,t)=>{var n={};for(var r in e)_te.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&ET)for(var r of ET(e))t.indexOf(r)<0&&bte.call(e,r)&&(n[r]=e[r]);return n};const Y0=w.forwardRef((e,t)=>{const n=Ve("TypographyStylesProvider",{},e),{className:r,unstyled:i}=n,s=hke(n,["className","unstyled"]),{classes:o,cx:a}=cke(null,{name:"TypographyStylesProvider",unstyled:i});return N.createElement(it,dke({className:a(o.root,r),ref:t},s))});Y0.displayName="@mantine/core/TypographyStylesProvider";function tN(e){const t=e.split("/")||[];return t[t.length-1].replace(/\.[^\.]+$/,"").replace(".","_").replace(" ","_").replace("/","_")}const fl="/viz-guardrails-study/";function pke({globalConfig:e,studyConfigs:t}){const{configsList:n}=e,r=Kf();return C.jsxs(rZ,{size:"xs",px:"xs",style:{marginTop:100,marginBottom:100},children:[C.jsx(B_,{maw:150,mx:"auto",mb:"xl",radius:"md",src:`${fl}assets/revisitLogoSquare.svg`,alt:"reVISit"}),C.jsx(rt,{children:"Select an experiment to launch:"}),n.map(i=>{const s=t[i];if(!s)return null;const o=tN(i);return C.jsx(kx,{onClick:()=>{r(`/${o}`)},my:"sm",style:{width:"100%"},children:C.jsxs(vxe,{shadow:"sm",radius:"md",withBorder:!0,children:[C.jsx(rt,{fw:"bold",children:s.studyMetadata.title}),C.jsxs(rt,{c:"dimmed",children:["Authors:",s.studyMetadata.authors]}),C.jsx(rt,{c:"dimmed",children:s.studyMetadata.description}),C.jsx(rt,{c:"dimmed",ta:"right",style:{paddingRight:5}})]})},i)})]})}var wte={exports:{}},Ete={};/** + `};function Gve(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function Yve(e){(document.head||document.getElementsByTagName("head")[0]).appendChild(e)}function Kve(){const e=document.createElement("style");return e.type="text/css",e.setAttribute("mantine-scroll-lock",""),e}function Qve(e,t={disableBodyPadding:!1}){const[n,r]=w.useState(e||!1),i=w.useRef(0),{disableBodyPadding:s}=t,o=w.useRef(null),a=()=>{i.current=window.scrollY;const l=qve({disableBodyPadding:s}),c=Kve();Gve(c,l),Yve(c),o.current=c},u=()=>{o!=null&&o.current&&(o.current.parentNode.removeChild(o.current),o.current=null)};return w.useEffect(()=>(n?a():u(),u),[n]),w.useEffect(()=>{e!==void 0&&r(e)},[e]),w.useEffect(()=>{e===void 0&&typeof window<"u"&&window.document.body.style.overflow==="hidden"&&r(!0)},[r]),[n,r]}function Xve(){const{userAgent:e}=window.navigator,t=/(Macintosh)|(MacIntel)|(MacPPC)|(Mac68K)/i,n=/(Win32)|(Win64)|(Windows)|(WinCE)/i,r=/(iPhone)|(iPad)|(iPod)/i;return t.test(e)?"macos":r.test(e)?"ios":n.test(e)?"windows":/Android/i.test(e)?"android":/Linux/i.test(e)?"linux":"undetermined"}function Jve(){return typeof window<"u"?Xve():"undetermined"}function Zve(e){return t=>{if(!t)e(t);else if(typeof t=="function")e(t);else if(typeof t=="object"&&"nativeEvent"in t){const{currentTarget:n}=t;n.type==="checkbox"?e(n.checked):e(n.value)}else e(t)}}function e_e(e){const[t,n]=w.useState(e);return[t,Zve(n)]}function I$(e=!1,t){const{onOpen:n,onClose:r}=t||{},[i,s]=w.useState(e),o=w.useCallback(()=>{s(l=>l||(n==null||n(),!0))},[n]),a=w.useCallback(()=>{s(l=>l&&(r==null||r(),!1))},[r]),u=w.useCallback(()=>{i?a():o()},[a,o,i]);return[i,{open:o,close:a,toggle:u}]}function t_e(){return`mantine-${Math.random().toString(36).slice(2,11)}`}var GF=Object.getOwnPropertySymbols,n_e=Object.prototype.hasOwnProperty,r_e=Object.prototype.propertyIsEnumerable,i_e=(e,t)=>{var n={};for(var r in e)n_e.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&GF)for(var r of GF(e))t.indexOf(r)<0&&r_e.call(e,r)&&(n[r]=e[r]);return n};function Qf(e){const t=e,{m:n,mx:r,my:i,mt:s,mb:o,ml:a,mr:u,p:l,px:c,py:f,pt:d,pb:h,pl:p,pr:m,bg:y,c:g,opacity:v,ff:b,fz:S,fw:T,lts:E,ta:I,lh:A,fs:R,tt:F,td:L,w:B,miw:J,maw:V,h:re,mih:oe,mah:ae,bgsz:ee,bgp:ue,bgr:P,bga:W,pos:Q,top:x,left:O,bottom:$,right:q,inset:ce,display:fe}=t,de=i_e(t,["m","mx","my","mt","mb","ml","mr","p","px","py","pt","pb","pl","pr","bg","c","opacity","ff","fz","fw","lts","ta","lh","fs","tt","td","w","miw","maw","h","mih","mah","bgsz","bgp","bgr","bga","pos","top","left","bottom","right","inset","display"]);return{systemStyles:RK({m:n,mx:r,my:i,mt:s,mb:o,ml:a,mr:u,p:l,px:c,py:f,pt:d,pb:h,pl:p,pr:m,bg:y,c:g,opacity:v,ff:b,fz:S,fw:T,lts:E,ta:I,lh:A,fs:R,tt:F,td:L,w:B,miw:J,maw:V,h:re,mih:oe,mah:ae,bgsz:ee,bgp:ue,bgr:P,bga:W,pos:Q,top:x,left:O,bottom:$,right:q,inset:ce,display:fe}),rest:de}}function s_e(e,t){const n=Object.keys(e).filter(r=>r!=="base").sort((r,i)=>t.fn.size({size:r,sizes:t.breakpoints})-t.fn.size({size:i,sizes:t.breakpoints}));return"base"in e?["base",...n]:n}function o_e({value:e,theme:t,getValue:n,property:r}){if(e==null)return;if(typeof e=="object")return s_e(e,t).reduce((o,a)=>{if(a==="base"&&e.base!==void 0){const l=n(e.base,t);return Array.isArray(r)?(r.forEach(c=>{o[c]=l}),o):(o[r]=l,o)}const u=n(e[a],t);return Array.isArray(r)?(o[t.fn.largerThan(a)]={},r.forEach(l=>{o[t.fn.largerThan(a)][l]=u}),o):(o[t.fn.largerThan(a)]={[r]:u},o)},{});const i=n(e,t);return Array.isArray(r)?r.reduce((s,o)=>(s[o]=i,s),{}):{[r]:i}}function a_e(e,t){return e==="dimmed"?t.colorScheme==="dark"?t.colors.dark[2]:t.colors.gray[6]:t.fn.variant({variant:"filled",color:e,primaryFallback:!1}).background}function u_e(e){return e}function l_e(e,t){return t.fn.size({size:e,sizes:t.fontSizes})}const c_e=["-xs","-sm","-md","-lg","-xl"];function f_e(e,t){return c_e.includes(e)?t.fn.size({size:e.replace("-",""),sizes:t.spacing})*-1:t.fn.size({size:e,sizes:t.spacing})}const d_e={color:a_e,default:u_e,fontSize:l_e,spacing:f_e},h_e={m:{type:"spacing",property:"margin"},mt:{type:"spacing",property:"marginTop"},mb:{type:"spacing",property:"marginBottom"},ml:{type:"spacing",property:"marginLeft"},mr:{type:"spacing",property:"marginRight"},mx:{type:"spacing",property:["marginRight","marginLeft"]},my:{type:"spacing",property:["marginTop","marginBottom"]},p:{type:"spacing",property:"padding"},pt:{type:"spacing",property:"paddingTop"},pb:{type:"spacing",property:"paddingBottom"},pl:{type:"spacing",property:"paddingLeft"},pr:{type:"spacing",property:"paddingRight"},px:{type:"spacing",property:["paddingRight","paddingLeft"]},py:{type:"spacing",property:["paddingTop","paddingBottom"]},bg:{type:"color",property:"background"},c:{type:"color",property:"color"},opacity:{type:"default",property:"opacity"},ff:{type:"default",property:"fontFamily"},fz:{type:"fontSize",property:"fontSize"},fw:{type:"default",property:"fontWeight"},lts:{type:"default",property:"letterSpacing"},ta:{type:"default",property:"textAlign"},lh:{type:"default",property:"lineHeight"},fs:{type:"default",property:"fontStyle"},tt:{type:"default",property:"textTransform"},td:{type:"default",property:"textDecoration"},w:{type:"spacing",property:"width"},miw:{type:"spacing",property:"minWidth"},maw:{type:"spacing",property:"maxWidth"},h:{type:"spacing",property:"height"},mih:{type:"spacing",property:"minHeight"},mah:{type:"spacing",property:"maxHeight"},bgsz:{type:"default",property:"background-size"},bgp:{type:"default",property:"background-position"},bgr:{type:"default",property:"background-repeat"},bga:{type:"default",property:"background-attachment"},pos:{type:"default",property:"position"},top:{type:"default",property:"top"},left:{type:"default",property:"left"},bottom:{type:"default",property:"bottom"},right:{type:"default",property:"right"},inset:{type:"default",property:"inset"},display:{type:"default",property:"display"}};var p_e=Object.defineProperty,YF=Object.getOwnPropertySymbols,m_e=Object.prototype.hasOwnProperty,g_e=Object.prototype.propertyIsEnumerable,KF=(e,t,n)=>t in e?p_e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,QF=(e,t)=>{for(var n in t||(t={}))m_e.call(t,n)&&KF(e,n,t[n]);if(YF)for(var n of YF(t))g_e.call(t,n)&&KF(e,n,t[n]);return e};function UR(e,t,n=h_e){return Object.keys(n).reduce((i,s)=>(s in e&&e[s]!==void 0&&i.push(o_e({value:e[s],getValue:d_e[n[s].type],property:n[s].property,theme:t})),i),[]).reduce((i,s)=>(Object.keys(s).forEach(o=>{typeof s[o]=="object"&&s[o]!==null&&o in i?i[o]=QF(QF({},i[o]),s[o]):i[o]=s[o]}),i),{})}function XF(e,t){return typeof e=="function"?e(t):e}function y_e(e,t,n){const r=ji(),{css:i,cx:s}=DK();return Array.isArray(e)?s(n,i(UR(t,r)),e.map(o=>i(XF(o,r)))):s(n,i(XF(e,r)),i(UR(t,r)))}var v_e=Object.defineProperty,kE=Object.getOwnPropertySymbols,WK=Object.prototype.hasOwnProperty,qK=Object.prototype.propertyIsEnumerable,JF=(e,t,n)=>t in e?v_e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,__e=(e,t)=>{for(var n in t||(t={}))WK.call(t,n)&&JF(e,n,t[n]);if(kE)for(var n of kE(t))qK.call(t,n)&&JF(e,n,t[n]);return e},b_e=(e,t)=>{var n={};for(var r in e)WK.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&kE)for(var r of kE(e))t.indexOf(r)<0&&qK.call(e,r)&&(n[r]=e[r]);return n};const GK=w.forwardRef((e,t)=>{var n=e,{className:r,component:i,style:s,sx:o}=n,a=b_e(n,["className","component","style","sx"]);const{systemStyles:u,rest:l}=Qf(a),c=i||"div";return N.createElement(c,__e({ref:t,className:y_e(o,u,r),style:s},l))});GK.displayName="@mantine/core/Box";const it=GK;var w_e=Object.defineProperty,E_e=Object.defineProperties,S_e=Object.getOwnPropertyDescriptors,ZF=Object.getOwnPropertySymbols,T_e=Object.prototype.hasOwnProperty,I_e=Object.prototype.propertyIsEnumerable,e8=(e,t,n)=>t in e?w_e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,t8=(e,t)=>{for(var n in t||(t={}))T_e.call(t,n)&&e8(e,n,t[n]);if(ZF)for(var n of ZF(t))I_e.call(t,n)&&e8(e,n,t[n]);return e},x_e=(e,t)=>E_e(e,S_e(t)),C_e=lt(e=>({root:x_e(t8(t8({},e.fn.focusStyles()),e.fn.fontStyles()),{cursor:"pointer",border:0,padding:0,appearance:"none",fontSize:e.fontSizes.md,backgroundColor:"transparent",textAlign:"left",color:e.colorScheme==="dark"?e.colors.dark[0]:e.black,textDecoration:"none",boxSizing:"border-box"})})),A_e=Object.defineProperty,DE=Object.getOwnPropertySymbols,YK=Object.prototype.hasOwnProperty,KK=Object.prototype.propertyIsEnumerable,n8=(e,t,n)=>t in e?A_e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,P_e=(e,t)=>{for(var n in t||(t={}))YK.call(t,n)&&n8(e,n,t[n]);if(DE)for(var n of DE(t))KK.call(t,n)&&n8(e,n,t[n]);return e},O_e=(e,t)=>{var n={};for(var r in e)YK.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&DE)for(var r of DE(e))t.indexOf(r)<0&&KK.call(e,r)&&(n[r]=e[r]);return n};const QK=w.forwardRef((e,t)=>{const n=Ve("UnstyledButton",{},e),{className:r,component:i="button",unstyled:s}=n,o=O_e(n,["className","component","unstyled"]),{classes:a,cx:u}=C_e(null,{name:"UnstyledButton",unstyled:s});return N.createElement(it,P_e({component:i,ref:t,className:u(a.root,r),type:i==="button"?"button":void 0},o))});QK.displayName="@mantine/core/UnstyledButton";const kx=QK;var R_e=Object.defineProperty,N_e=Object.defineProperties,k_e=Object.getOwnPropertyDescriptors,$E=Object.getOwnPropertySymbols,XK=Object.prototype.hasOwnProperty,JK=Object.prototype.propertyIsEnumerable,r8=(e,t,n)=>t in e?R_e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ud=(e,t)=>{for(var n in t||(t={}))XK.call(t,n)&&r8(e,n,t[n]);if($E)for(var n of $E(t))JK.call(t,n)&&r8(e,n,t[n]);return e},OP=(e,t)=>N_e(e,k_e(t)),D_e=(e,t)=>{var n={};for(var r in e)XK.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&$E)for(var r of $E(e))t.indexOf(r)<0&&JK.call(e,r)&&(n[r]=e[r]);return n};function $_e(e){if(!e||typeof e=="string")return 0;const t=e/36;return Math.round((4+15*t**.25+t/5)*10)}function RP(e){return e!=null&&e.current?e.current.scrollHeight:"auto"}const rb=typeof window<"u"&&window.requestAnimationFrame;function L_e({transitionDuration:e,transitionTimingFunction:t="ease",onTransitionEnd:n=()=>{},opened:r}){const i=w.useRef(null),s="0px",o={display:"none",height:"0px",overflow:"hidden"},[a,u]=w.useState(r?{}:o),l=p=>{lc.flushSync(()=>u(p))},c=p=>{l(m=>ud(ud({},m),p))};function f(p){return{transition:`height ${e||$_e(p)}ms ${t}`}}Js(()=>{rb(r?()=>{c({willChange:"height",display:"block",overflow:"hidden"}),rb(()=>{const p=RP(i);c(OP(ud({},f(p)),{height:p}))})}:()=>{const p=RP(i);c(OP(ud({},f(p)),{willChange:"height",height:p})),rb(()=>c({height:s,overflow:"hidden"}))})},[r]);const d=p=>{if(!(p.target!==i.current||p.propertyName!=="height"))if(r){const m=RP(i);m===a.height?l({}):c({height:m}),n()}else a.height===s&&(l(o),n())};function h(p={}){var m=p,{style:y={},refKey:g="ref"}=m,v=D_e(m,["style","refKey"]);const b=v[g];return OP(ud({"aria-hidden":!r},v),{[g]:VK(i,b),onTransitionEnd:d,style:ud(ud({boxSizing:"border-box"},y),a)})}return h}var M_e=Object.defineProperty,LE=Object.getOwnPropertySymbols,ZK=Object.prototype.hasOwnProperty,eQ=Object.prototype.propertyIsEnumerable,i8=(e,t,n)=>t in e?M_e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ib=(e,t)=>{for(var n in t||(t={}))ZK.call(t,n)&&i8(e,n,t[n]);if(LE)for(var n of LE(t))eQ.call(t,n)&&i8(e,n,t[n]);return e},F_e=(e,t)=>{var n={};for(var r in e)ZK.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&LE)for(var r of LE(e))t.indexOf(r)<0&&eQ.call(e,r)&&(n[r]=e[r]);return n};const B_e={transitionDuration:200,transitionTimingFunction:"ease",animateOpacity:!0},tQ=w.forwardRef((e,t)=>{const n=Ve("Collapse",B_e,e),{children:r,in:i,transitionDuration:s,transitionTimingFunction:o,style:a,onTransitionEnd:u,animateOpacity:l}=n,c=F_e(n,["children","in","transitionDuration","transitionTimingFunction","style","onTransitionEnd","animateOpacity"]),f=ji(),d=Rx(),p=(f.respectReducedMotion?d:!1)?0:s,{systemStyles:m,rest:y}=Qf(c),g=L_e({opened:i,transitionDuration:p,transitionTimingFunction:o,onTransitionEnd:u});return p===0?i?N.createElement(it,ib({},y),r):null:N.createElement(it,ib({},g(ib(ib({style:a,ref:t},y),m))),N.createElement("div",{style:{opacity:i||!l?1:0,transition:l?`opacity ${p}ms ${o}`:"none"}},r))});tQ.displayName="@mantine/core/Collapse";var j_e=Object.defineProperty,s8=Object.getOwnPropertySymbols,U_e=Object.prototype.hasOwnProperty,V_e=Object.prototype.propertyIsEnumerable,o8=(e,t,n)=>t in e?j_e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,z_e=(e,t)=>{for(var n in t||(t={}))U_e.call(t,n)&&o8(e,n,t[n]);if(s8)for(var n of s8(t))V_e.call(t,n)&&o8(e,n,t[n]);return e};function H_e(e){return N.createElement("svg",z_e({viewBox:"0 0 15 15",fill:"none",xmlns:"http://www.w3.org/2000/svg",width:16,height:16},e),N.createElement("path",{d:"M3.13523 6.15803C3.3241 5.95657 3.64052 5.94637 3.84197 6.13523L7.5 9.56464L11.158 6.13523C11.3595 5.94637 11.6759 5.95657 11.8648 6.15803C12.0536 6.35949 12.0434 6.67591 11.842 6.86477L7.84197 10.6148C7.64964 10.7951 7.35036 10.7951 7.15803 10.6148L3.15803 6.86477C2.95657 6.67591 2.94637 6.35949 3.13523 6.15803Z",fill:"currentColor",fillRule:"evenodd",clipRule:"evenodd"}))}var W_e=Object.defineProperty,q_e=Object.defineProperties,G_e=Object.getOwnPropertyDescriptors,a8=Object.getOwnPropertySymbols,Y_e=Object.prototype.hasOwnProperty,K_e=Object.prototype.propertyIsEnumerable,u8=(e,t,n)=>t in e?W_e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,nQ=(e,t)=>{for(var n in t||(t={}))Y_e.call(t,n)&&u8(e,n,t[n]);if(a8)for(var n of a8(t))K_e.call(t,n)&&u8(e,n,t[n]);return e},Q_e=(e,t)=>q_e(e,G_e(t));const G0={xs:18,sm:22,md:28,lg:34,xl:44};function X_e({variant:e,theme:t,color:n,gradient:r}){const i=t.fn.variant({color:n,variant:e,gradient:r});return e==="gradient"?{border:0,backgroundImage:i.background,color:i.color,"&:hover":t.fn.hover({backgroundSize:"200%"})}:nQ({border:`1px solid ${i.border}`,backgroundColor:i.background,color:i.color},t.fn.hover({backgroundColor:i.hover}))}var J_e=lt((e,{color:t,size:n,radius:r,variant:i,gradient:s})=>({root:Q_e(nQ({},X_e({variant:i,theme:e,color:t,gradient:s})),{position:"relative",height:e.fn.size({size:n,sizes:G0}),minHeight:e.fn.size({size:n,sizes:G0}),width:e.fn.size({size:n,sizes:G0}),minWidth:e.fn.size({size:n,sizes:G0}),borderRadius:e.fn.radius(r),padding:0,lineHeight:1,display:"flex",alignItems:"center",justifyContent:"center","&:active":e.activeStyles,"&:disabled, &[data-disabled]":{color:e.colors.gray[e.colorScheme==="dark"?6:4],cursor:"not-allowed",backgroundColor:i==="transparent"?void 0:e.fn.themeColor("gray",e.colorScheme==="dark"?8:1),borderColor:i==="transparent"?void 0:e.fn.themeColor("gray",e.colorScheme==="dark"?8:1),backgroundImage:"none",pointerEvents:"none","&:active":{transform:"none"}},"&[data-loading]":{pointerEvents:"none","&::before":{content:'""',position:"absolute",top:-1,left:-1,right:-1,bottom:-1,backgroundColor:e.colorScheme==="dark"?e.fn.rgba(e.colors.dark[7],.5):"rgba(255, 255, 255, .5)",borderRadius:e.fn.radius(r),cursor:"not-allowed"}}})})),Z_e=Object.defineProperty,ME=Object.getOwnPropertySymbols,rQ=Object.prototype.hasOwnProperty,iQ=Object.prototype.propertyIsEnumerable,l8=(e,t,n)=>t in e?Z_e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,e1e=(e,t)=>{for(var n in t||(t={}))rQ.call(t,n)&&l8(e,n,t[n]);if(ME)for(var n of ME(t))iQ.call(t,n)&&l8(e,n,t[n]);return e},t1e=(e,t)=>{var n={};for(var r in e)rQ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&ME)for(var r of ME(e))t.indexOf(r)<0&&iQ.call(e,r)&&(n[r]=e[r]);return n};function n1e(e){var t=e,{size:n,color:r}=t,i=t1e(t,["size","color"]);return N.createElement("svg",e1e({viewBox:"0 0 135 140",xmlns:"http://www.w3.org/2000/svg",fill:r,width:`${n}px`},i),N.createElement("rect",{y:"10",width:"15",height:"120",rx:"6"},N.createElement("animate",{attributeName:"height",begin:"0.5s",dur:"1s",values:"120;110;100;90;80;70;60;50;40;140;120",calcMode:"linear",repeatCount:"indefinite"}),N.createElement("animate",{attributeName:"y",begin:"0.5s",dur:"1s",values:"10;15;20;25;30;35;40;45;50;0;10",calcMode:"linear",repeatCount:"indefinite"})),N.createElement("rect",{x:"30",y:"10",width:"15",height:"120",rx:"6"},N.createElement("animate",{attributeName:"height",begin:"0.25s",dur:"1s",values:"120;110;100;90;80;70;60;50;40;140;120",calcMode:"linear",repeatCount:"indefinite"}),N.createElement("animate",{attributeName:"y",begin:"0.25s",dur:"1s",values:"10;15;20;25;30;35;40;45;50;0;10",calcMode:"linear",repeatCount:"indefinite"})),N.createElement("rect",{x:"60",width:"15",height:"140",rx:"6"},N.createElement("animate",{attributeName:"height",begin:"0s",dur:"1s",values:"120;110;100;90;80;70;60;50;40;140;120",calcMode:"linear",repeatCount:"indefinite"}),N.createElement("animate",{attributeName:"y",begin:"0s",dur:"1s",values:"10;15;20;25;30;35;40;45;50;0;10",calcMode:"linear",repeatCount:"indefinite"})),N.createElement("rect",{x:"90",y:"10",width:"15",height:"120",rx:"6"},N.createElement("animate",{attributeName:"height",begin:"0.25s",dur:"1s",values:"120;110;100;90;80;70;60;50;40;140;120",calcMode:"linear",repeatCount:"indefinite"}),N.createElement("animate",{attributeName:"y",begin:"0.25s",dur:"1s",values:"10;15;20;25;30;35;40;45;50;0;10",calcMode:"linear",repeatCount:"indefinite"})),N.createElement("rect",{x:"120",y:"10",width:"15",height:"120",rx:"6"},N.createElement("animate",{attributeName:"height",begin:"0.5s",dur:"1s",values:"120;110;100;90;80;70;60;50;40;140;120",calcMode:"linear",repeatCount:"indefinite"}),N.createElement("animate",{attributeName:"y",begin:"0.5s",dur:"1s",values:"10;15;20;25;30;35;40;45;50;0;10",calcMode:"linear",repeatCount:"indefinite"})))}var r1e=Object.defineProperty,FE=Object.getOwnPropertySymbols,sQ=Object.prototype.hasOwnProperty,oQ=Object.prototype.propertyIsEnumerable,c8=(e,t,n)=>t in e?r1e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,i1e=(e,t)=>{for(var n in t||(t={}))sQ.call(t,n)&&c8(e,n,t[n]);if(FE)for(var n of FE(t))oQ.call(t,n)&&c8(e,n,t[n]);return e},s1e=(e,t)=>{var n={};for(var r in e)sQ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&FE)for(var r of FE(e))t.indexOf(r)<0&&oQ.call(e,r)&&(n[r]=e[r]);return n};function o1e(e){var t=e,{size:n,color:r}=t,i=s1e(t,["size","color"]);return N.createElement("svg",i1e({width:`${n}px`,height:`${n}px`,viewBox:"0 0 38 38",xmlns:"http://www.w3.org/2000/svg",stroke:r},i),N.createElement("g",{fill:"none",fillRule:"evenodd"},N.createElement("g",{transform:"translate(2.5 2.5)",strokeWidth:"5"},N.createElement("circle",{strokeOpacity:".5",cx:"16",cy:"16",r:"16"}),N.createElement("path",{d:"M32 16c0-9.94-8.06-16-16-16"},N.createElement("animateTransform",{attributeName:"transform",type:"rotate",from:"0 16 16",to:"360 16 16",dur:"1s",repeatCount:"indefinite"})))))}var a1e=Object.defineProperty,BE=Object.getOwnPropertySymbols,aQ=Object.prototype.hasOwnProperty,uQ=Object.prototype.propertyIsEnumerable,f8=(e,t,n)=>t in e?a1e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,u1e=(e,t)=>{for(var n in t||(t={}))aQ.call(t,n)&&f8(e,n,t[n]);if(BE)for(var n of BE(t))uQ.call(t,n)&&f8(e,n,t[n]);return e},l1e=(e,t)=>{var n={};for(var r in e)aQ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&BE)for(var r of BE(e))t.indexOf(r)<0&&uQ.call(e,r)&&(n[r]=e[r]);return n};function c1e(e){var t=e,{size:n,color:r}=t,i=l1e(t,["size","color"]);return N.createElement("svg",u1e({width:`${n}px`,height:`${n/4}px`,viewBox:"0 0 120 30",xmlns:"http://www.w3.org/2000/svg",fill:r},i),N.createElement("circle",{cx:"15",cy:"15",r:"15"},N.createElement("animate",{attributeName:"r",from:"15",to:"15",begin:"0s",dur:"0.8s",values:"15;9;15",calcMode:"linear",repeatCount:"indefinite"}),N.createElement("animate",{attributeName:"fill-opacity",from:"1",to:"1",begin:"0s",dur:"0.8s",values:"1;.5;1",calcMode:"linear",repeatCount:"indefinite"})),N.createElement("circle",{cx:"60",cy:"15",r:"9",fillOpacity:"0.3"},N.createElement("animate",{attributeName:"r",from:"9",to:"9",begin:"0s",dur:"0.8s",values:"9;15;9",calcMode:"linear",repeatCount:"indefinite"}),N.createElement("animate",{attributeName:"fill-opacity",from:"0.5",to:"0.5",begin:"0s",dur:"0.8s",values:".5;1;.5",calcMode:"linear",repeatCount:"indefinite"})),N.createElement("circle",{cx:"105",cy:"15",r:"15"},N.createElement("animate",{attributeName:"r",from:"15",to:"15",begin:"0s",dur:"0.8s",values:"15;9;15",calcMode:"linear",repeatCount:"indefinite"}),N.createElement("animate",{attributeName:"fill-opacity",from:"1",to:"1",begin:"0s",dur:"0.8s",values:"1;.5;1",calcMode:"linear",repeatCount:"indefinite"})))}var f1e=Object.defineProperty,jE=Object.getOwnPropertySymbols,lQ=Object.prototype.hasOwnProperty,cQ=Object.prototype.propertyIsEnumerable,d8=(e,t,n)=>t in e?f1e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,d1e=(e,t)=>{for(var n in t||(t={}))lQ.call(t,n)&&d8(e,n,t[n]);if(jE)for(var n of jE(t))cQ.call(t,n)&&d8(e,n,t[n]);return e},h1e=(e,t)=>{var n={};for(var r in e)lQ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&jE)for(var r of jE(e))t.indexOf(r)<0&&cQ.call(e,r)&&(n[r]=e[r]);return n};const NP={bars:n1e,oval:o1e,dots:c1e},p1e={xs:18,sm:22,md:36,lg:44,xl:58},m1e={size:"md"};function Xf(e){const t=Ve("Loader",m1e,e),{size:n,color:r,variant:i}=t,s=h1e(t,["size","color","variant"]),o=ji(),a=i in NP?i:o.loader;return N.createElement(it,d1e({role:"presentation",component:NP[a]||NP.bars,size:o.fn.size({size:n,sizes:p1e}),color:o.fn.variant({variant:"filled",primaryFallback:!1,color:r||o.primaryColor}).background},s))}Xf.displayName="@mantine/core/Loader";var g1e=Object.defineProperty,UE=Object.getOwnPropertySymbols,fQ=Object.prototype.hasOwnProperty,dQ=Object.prototype.propertyIsEnumerable,h8=(e,t,n)=>t in e?g1e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,p8=(e,t)=>{for(var n in t||(t={}))fQ.call(t,n)&&h8(e,n,t[n]);if(UE)for(var n of UE(t))dQ.call(t,n)&&h8(e,n,t[n]);return e},y1e=(e,t)=>{var n={};for(var r in e)fQ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&UE)for(var r of UE(e))t.indexOf(r)<0&&dQ.call(e,r)&&(n[r]=e[r]);return n};const v1e={color:"gray",size:"md",variant:"subtle",loading:!1},hQ=w.forwardRef((e,t)=>{const n=Ve("ActionIcon",v1e,e),{className:r,color:i,children:s,radius:o,size:a,variant:u,gradient:l,disabled:c,loaderProps:f,loading:d,unstyled:h}=n,p=y1e(n,["className","color","children","radius","size","variant","gradient","disabled","loaderProps","loading","unstyled"]),{classes:m,cx:y,theme:g}=J_e({size:a,radius:o,color:i,variant:u,gradient:l},{name:"ActionIcon",unstyled:h}),v=g.fn.variant({color:i,variant:u}),b=N.createElement(Xf,p8({color:v.color,size:g.fn.size({size:a,sizes:G0})-12},f));return N.createElement(kx,p8({className:y(m.root,r),ref:t,disabled:c,"data-disabled":c||void 0,"data-loading":d||void 0,unstyled:h},p),d?b:s)});hQ.displayName="@mantine/core/ActionIcon";const pQ=hQ;function mQ(e){const{children:t,target:n,className:r}=Ve("Portal",{},e),i=ji(),[s,o]=w.useState(!1),a=w.useRef();return T$(()=>(o(!0),a.current=n?typeof n=="string"?document.querySelector(n):n:document.createElement("div"),n||document.body.appendChild(a.current),()=>{!n&&document.body.removeChild(a.current)}),[n]),s?lc.createPortal(N.createElement("div",{className:r,dir:i.dir},t),a.current):null}mQ.displayName="@mantine/core/Portal";var _1e=Object.defineProperty,VE=Object.getOwnPropertySymbols,gQ=Object.prototype.hasOwnProperty,yQ=Object.prototype.propertyIsEnumerable,m8=(e,t,n)=>t in e?_1e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,b1e=(e,t)=>{for(var n in t||(t={}))gQ.call(t,n)&&m8(e,n,t[n]);if(VE)for(var n of VE(t))yQ.call(t,n)&&m8(e,n,t[n]);return e},w1e=(e,t)=>{var n={};for(var r in e)gQ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&VE)for(var r of VE(e))t.indexOf(r)<0&&yQ.call(e,r)&&(n[r]=e[r]);return n};function $_(e){var t=e,{withinPortal:n=!0,children:r}=t,i=w1e(t,["withinPortal","children"]);return n?N.createElement(mQ,b1e({},i),r):N.createElement(N.Fragment,null,r)}$_.displayName="@mantine/core/OptionalPortal";var E1e=Object.defineProperty,S1e=Object.defineProperties,T1e=Object.getOwnPropertyDescriptors,g8=Object.getOwnPropertySymbols,I1e=Object.prototype.hasOwnProperty,x1e=Object.prototype.propertyIsEnumerable,y8=(e,t,n)=>t in e?E1e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,kP=(e,t)=>{for(var n in t||(t={}))I1e.call(t,n)&&y8(e,n,t[n]);if(g8)for(var n of g8(t))x1e.call(t,n)&&y8(e,n,t[n]);return e},v8=(e,t)=>S1e(e,T1e(t));function C1e({variant:e,color:t,theme:n}){if(e==="filled")return{backgroundColor:n.fn.variant({variant:"filled",color:t}).background,color:n.white};if(e==="outline"){const i=n.fn.variant({variant:"outline",color:t});return{color:i.color,borderColor:i.border,backgroundColor:n.colorScheme==="dark"?n.colors.dark[6]:n.white}}const r=n.fn.variant({variant:"light",color:t});return{backgroundColor:r.background,color:r.color}}var A1e=lt((e,{color:t,radius:n,variant:r})=>({root:kP(v8(kP({},e.fn.fontStyles()),{position:"relative",overflow:"hidden",padding:`${e.spacing.sm}px ${e.spacing.md}px`,borderRadius:e.fn.radius(n),border:"1px solid transparent"}),C1e({variant:r,color:t,theme:e})),wrapper:{display:"flex"},body:{flex:1},title:{boxSizing:"border-box",margin:0,marginBottom:7,display:"flex",alignItems:"center",justifyContent:"space-between",lineHeight:e.lineHeight,fontSize:e.fontSizes.sm,fontWeight:700,"&[data-with-close-button]":{paddingRight:e.spacing.md}},label:{display:"block",overflow:"hidden",textOverflow:"ellipsis"},icon:{lineHeight:1,width:20,height:20,display:"flex",alignItems:"center",justifyContent:"flex-start",marginRight:e.spacing.md,marginTop:1},message:v8(kP({},e.fn.fontStyles()),{lineHeight:e.lineHeight,textOverflow:"ellipsis",overflow:"hidden",fontSize:e.fontSizes.sm,color:r==="filled"?e.white:e.colorScheme==="dark"?r==="light"?e.white:e.colors.dark[0]:e.black}),closeButton:{position:"absolute",top:e.spacing.sm,right:e.spacing.sm,color:"inherit"}})),P1e=Object.defineProperty,_8=Object.getOwnPropertySymbols,O1e=Object.prototype.hasOwnProperty,R1e=Object.prototype.propertyIsEnumerable,b8=(e,t,n)=>t in e?P1e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,N1e=(e,t)=>{for(var n in t||(t={}))O1e.call(t,n)&&b8(e,n,t[n]);if(_8)for(var n of _8(t))R1e.call(t,n)&&b8(e,n,t[n]);return e};function vQ(e){return N.createElement("svg",N1e({viewBox:"0 0 15 15",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e),N.createElement("path",{d:"M11.7816 4.03157C12.0062 3.80702 12.0062 3.44295 11.7816 3.2184C11.5571 2.99385 11.193 2.99385 10.9685 3.2184L7.50005 6.68682L4.03164 3.2184C3.80708 2.99385 3.44301 2.99385 3.21846 3.2184C2.99391 3.44295 2.99391 3.80702 3.21846 4.03157L6.68688 7.49999L3.21846 10.9684C2.99391 11.193 2.99391 11.557 3.21846 11.7816C3.44301 12.0061 3.80708 12.0061 4.03164 11.7816L7.50005 8.31316L10.9685 11.7816C11.193 12.0061 11.5571 12.0061 11.7816 11.7816C12.0062 11.557 12.0062 11.193 11.7816 10.9684L8.31322 7.49999L11.7816 4.03157Z",fill:"currentColor",fillRule:"evenodd",clipRule:"evenodd"}))}vQ.displayName="@mantine/core/CloseIcon";var k1e=Object.defineProperty,zE=Object.getOwnPropertySymbols,_Q=Object.prototype.hasOwnProperty,bQ=Object.prototype.propertyIsEnumerable,w8=(e,t,n)=>t in e?k1e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,D1e=(e,t)=>{for(var n in t||(t={}))_Q.call(t,n)&&w8(e,n,t[n]);if(zE)for(var n of zE(t))bQ.call(t,n)&&w8(e,n,t[n]);return e},$1e=(e,t)=>{var n={};for(var r in e)_Q.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&zE)for(var r of zE(e))t.indexOf(r)<0&&bQ.call(e,r)&&(n[r]=e[r]);return n};const L1e={xs:12,sm:14,md:16,lg:20,xl:24},M1e={size:"md"},wQ=w.forwardRef((e,t)=>{const n=Ve("CloseButton",M1e,e),{iconSize:r,size:i="md"}=n,s=$1e(n,["iconSize","size"]),o=ji(),a=r||o.fn.size({size:i,sizes:L1e});return N.createElement(pQ,D1e({size:i,ref:t},s),N.createElement(vQ,{width:a,height:a}))});wQ.displayName="@mantine/core/CloseButton";const Dx=wQ;var F1e=Object.defineProperty,HE=Object.getOwnPropertySymbols,EQ=Object.prototype.hasOwnProperty,SQ=Object.prototype.propertyIsEnumerable,E8=(e,t,n)=>t in e?F1e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,B1e=(e,t)=>{for(var n in t||(t={}))EQ.call(t,n)&&E8(e,n,t[n]);if(HE)for(var n of HE(t))SQ.call(t,n)&&E8(e,n,t[n]);return e},j1e=(e,t)=>{var n={};for(var r in e)EQ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&HE)for(var r of HE(e))t.indexOf(r)<0&&SQ.call(e,r)&&(n[r]=e[r]);return n};const U1e={variant:"light"},TQ=w.forwardRef((e,t)=>{const n=Ve("Alert",U1e,e),{id:r,className:i,title:s,variant:o,children:a,color:u,classNames:l,icon:c,styles:f,onClose:d,radius:h,withCloseButton:p,closeButtonLabel:m,unstyled:y}=n,g=j1e(n,["id","className","title","variant","children","color","classNames","icon","styles","onClose","radius","withCloseButton","closeButtonLabel","unstyled"]),{classes:v,cx:b}=A1e({color:u,radius:h,variant:o},{classNames:l,styles:f,unstyled:y,name:"Alert"}),S=tu(r),T=s&&`${S}-title`,E=`${S}-body`;return N.createElement(it,B1e({id:S,role:"alert","aria-labelledby":T,"aria-describedby":E,className:b(v.root,v[o],i),ref:t},g),N.createElement("div",{className:v.wrapper},c&&N.createElement("div",{className:v.icon},c),N.createElement("div",{className:v.body},s&&N.createElement("div",{className:v.title,"data-with-close-button":p||void 0},N.createElement("span",{id:T,className:v.label},s)),p&&N.createElement(Dx,{className:v.closeButton,onClick:d,variant:"transparent",size:16,iconSize:16,"aria-label":m}),N.createElement("div",{id:E,className:v.message},a))))});TQ.displayName="@mantine/core/Alert";var V1e=Object.defineProperty,z1e=Object.defineProperties,H1e=Object.getOwnPropertyDescriptors,S8=Object.getOwnPropertySymbols,W1e=Object.prototype.hasOwnProperty,q1e=Object.prototype.propertyIsEnumerable,T8=(e,t,n)=>t in e?V1e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,y0=(e,t)=>{for(var n in t||(t={}))W1e.call(t,n)&&T8(e,n,t[n]);if(S8)for(var n of S8(t))q1e.call(t,n)&&T8(e,n,t[n]);return e},G1e=(e,t)=>z1e(e,H1e(t));function Y1e({underline:e,strikethrough:t}){const n=[];return e&&n.push("underline"),t&&n.push("line-through"),n.length>0?n.join(" "):"none"}function K1e({theme:e,color:t,variant:n}){return t==="dimmed"?e.colorScheme==="dark"?e.colors.dark[2]:e.colors.gray[6]:typeof t=="string"&&(t in e.colors||t.split(".")[0]in e.colors)?e.fn.variant({variant:"filled",color:t}).background:n==="link"?e.colors[e.primaryColor][e.colorScheme==="dark"?4:7]:t||"inherit"}function Q1e(e){return typeof e=="number"?{overflow:"hidden",textOverflow:"ellipsis",display:"-webkit-box",WebkitLineClamp:e,WebkitBoxOrient:"vertical"}:null}function X1e({theme:e,truncate:t}){return t==="start"?{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",direction:e.dir==="ltr"?"rtl":"ltr",textAlign:e.dir==="ltr"?"right":"left"}:t?{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"}:null}var J1e=lt((e,{color:t,variant:n,size:r,lineClamp:i,truncate:s,inline:o,inherit:a,underline:u,gradient:l,weight:c,transform:f,align:d,strikethrough:h,italic:p})=>{const m=e.fn.variant({variant:"gradient",gradient:l});return{root:y0(G1e(y0(y0(y0(y0({},e.fn.fontStyles()),e.fn.focusStyles()),Q1e(i)),X1e({theme:e,truncate:s})),{color:K1e({color:t,theme:e,variant:n}),fontFamily:a?"inherit":e.fontFamily,fontSize:a||r===void 0?"inherit":e.fn.size({size:r,sizes:e.fontSizes}),lineHeight:a?"inherit":o?1:e.lineHeight,textDecoration:Y1e({underline:u,strikethrough:h}),WebkitTapHighlightColor:"transparent",fontWeight:a?"inherit":c,textTransform:f,textAlign:d,fontStyle:p?"italic":void 0}),e.fn.hover(n==="link"&&u===void 0?{textDecoration:"underline"}:void 0)),gradient:{backgroundImage:m.background,WebkitBackgroundClip:"text",WebkitTextFillColor:"transparent"}}}),Z1e=Object.defineProperty,WE=Object.getOwnPropertySymbols,IQ=Object.prototype.hasOwnProperty,xQ=Object.prototype.propertyIsEnumerable,I8=(e,t,n)=>t in e?Z1e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ebe=(e,t)=>{for(var n in t||(t={}))IQ.call(t,n)&&I8(e,n,t[n]);if(WE)for(var n of WE(t))xQ.call(t,n)&&I8(e,n,t[n]);return e},tbe=(e,t)=>{var n={};for(var r in e)IQ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&WE)for(var r of WE(e))t.indexOf(r)<0&&xQ.call(e,r)&&(n[r]=e[r]);return n};const nbe={variant:"text"},CQ=w.forwardRef((e,t)=>{const n=Ve("Text",nbe,e),{className:r,size:i,weight:s,transform:o,color:a,align:u,variant:l,lineClamp:c,truncate:f,gradient:d,inline:h,inherit:p,underline:m,strikethrough:y,italic:g,classNames:v,styles:b,unstyled:S,span:T}=n,E=tbe(n,["className","size","weight","transform","color","align","variant","lineClamp","truncate","gradient","inline","inherit","underline","strikethrough","italic","classNames","styles","unstyled","span"]),{classes:I,cx:A}=J1e({variant:l,color:a,size:i,lineClamp:c,truncate:f,inline:h,inherit:p,underline:m,strikethrough:y,italic:g,weight:s,transform:o,align:u,gradient:d},{unstyled:S,name:"Text"});return N.createElement(it,ebe({ref:t,className:A(I.root,{[I.gradient]:l==="gradient"},r),component:T?"span":"div"},E))});CQ.displayName="@mantine/core/Text";const rt=CQ;var rbe=lt(()=>({root:{backgroundColor:"transparent",cursor:"pointer",padding:0,border:0}})),ibe=Object.defineProperty,qE=Object.getOwnPropertySymbols,AQ=Object.prototype.hasOwnProperty,PQ=Object.prototype.propertyIsEnumerable,x8=(e,t,n)=>t in e?ibe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,C8=(e,t)=>{for(var n in t||(t={}))AQ.call(t,n)&&x8(e,n,t[n]);if(qE)for(var n of qE(t))PQ.call(t,n)&&x8(e,n,t[n]);return e},sbe=(e,t)=>{var n={};for(var r in e)AQ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&qE)for(var r of qE(e))t.indexOf(r)<0&&PQ.call(e,r)&&(n[r]=e[r]);return n};const obe={},OQ=w.forwardRef((e,t)=>{const n=Ve("Anchor",obe,e),{component:r,className:i,unstyled:s}=n,o=sbe(n,["component","className","unstyled"]),{classes:a,cx:u}=rbe(null,{name:"Anchor",unstyled:s}),l=r==="button"?{type:"button"}:null;return N.createElement(rt,C8(C8({component:r||"a",variant:"link",ref:t,className:u(a.root,i)},l),o))});OQ.displayName="@mantine/core/Anchor";const RQ=OQ,NQ=w.createContext({zIndex:1e3,fixed:!1,layout:"default"}),abe=NQ.Provider;function kQ(){return w.useContext(NQ)}function $x(e,t){if(!e)return[];const n=Object.keys(e).filter(r=>r!=="base").map(r=>[t.fn.size({size:r,sizes:t.breakpoints}),e[r]]);return n.sort((r,i)=>r[0]-i[0]),n}var ube=Object.defineProperty,lbe=Object.defineProperties,cbe=Object.getOwnPropertyDescriptors,A8=Object.getOwnPropertySymbols,fbe=Object.prototype.hasOwnProperty,dbe=Object.prototype.propertyIsEnumerable,P8=(e,t,n)=>t in e?ube(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,sb=(e,t)=>{for(var n in t||(t={}))fbe.call(t,n)&&P8(e,n,t[n]);if(A8)for(var n of A8(t))dbe.call(t,n)&&P8(e,n,t[n]);return e},O8=(e,t)=>lbe(e,cbe(t)),hbe=lt((e,{height:t,width:n,fixed:r,position:i,hiddenBreakpoint:s,zIndex:o,section:a,withBorder:u,layout:l})=>{const c=typeof n=="object"&&n!==null?$x(n,e).reduce((d,[h,p])=>(d[`@media (min-width: ${h}px)`]={width:p,minWidth:p},d),{}):null,f=u?{[a==="navbar"?"borderRight":"borderLeft"]:`1px solid ${e.colorScheme==="dark"?e.colors.dark[5]:e.colors.gray[2]}`}:{};return{root:O8(sb(sb(O8(sb(sb({},e.fn.fontStyles()),i),{top:l==="alt"?0:(i==null?void 0:i.top)||"var(--mantine-header-height)",bottom:0,zIndex:o,height:t||(l==="alt"?"auto":"calc(100vh - var(--mantine-header-height, 0px) - var(--mantine-footer-height, 0px))"),width:(n==null?void 0:n.base)||"100%",position:r?"fixed":"static",boxSizing:"border-box",display:"flex",flexDirection:"column",backgroundColor:e.colorScheme==="dark"?e.colors.dark[7]:e.white}),f),c),{"&[data-hidden]":{[`@media (max-width: ${e.fn.size({size:s,sizes:e.breakpoints})-1}px)`]:{display:"none"}}})}});const pbe=hbe;var mbe=Object.defineProperty,GE=Object.getOwnPropertySymbols,DQ=Object.prototype.hasOwnProperty,$Q=Object.prototype.propertyIsEnumerable,R8=(e,t,n)=>t in e?mbe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,N8=(e,t)=>{for(var n in t||(t={}))DQ.call(t,n)&&R8(e,n,t[n]);if(GE)for(var n of GE(t))$Q.call(t,n)&&R8(e,n,t[n]);return e},gbe=(e,t)=>{var n={};for(var r in e)DQ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&GE)for(var r of GE(e))t.indexOf(r)<0&&$Q.call(e,r)&&(n[r]=e[r]);return n};const x$=w.forwardRef((e,t)=>{var n=e,{width:r,height:i,fixed:s=!1,position:o,zIndex:a,hiddenBreakpoint:u="md",hidden:l=!1,withBorder:c=!0,className:f,classNames:d,styles:h,children:p,section:m,__staticSelector:y,unstyled:g}=n,v=gbe(n,["width","height","fixed","position","zIndex","hiddenBreakpoint","hidden","withBorder","className","classNames","styles","children","section","__staticSelector","unstyled"]);const b=kQ(),{classes:S,cx:T,theme:E}=pbe({width:r,height:i,fixed:b.fixed||s,position:o,hiddenBreakpoint:u,zIndex:a||b.zIndex||cc("app"),section:m,withBorder:c,layout:b.layout},{classNames:d,styles:h,name:y,unstyled:g}),I=$x(r,E).reduce((A,[R,F])=>(A[`@media (min-width: ${R}px)`]={[`--mantine-${m}-width`]:`${F}px`},A),{});return N.createElement(it,N8({component:m==="navbar"?"nav":"aside",ref:t,"data-hidden":l||void 0,className:T(S.root,f)},v),p,N.createElement($K,{styles:()=>({":root":N8({[`--mantine-${m}-width`]:r!=null&&r.base?`${r.base}px`:"0px"},I)})}))});x$.displayName="@mantine/core/HorizontalSection";var ybe=Object.defineProperty,YE=Object.getOwnPropertySymbols,LQ=Object.prototype.hasOwnProperty,MQ=Object.prototype.propertyIsEnumerable,k8=(e,t,n)=>t in e?ybe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,vbe=(e,t)=>{for(var n in t||(t={}))LQ.call(t,n)&&k8(e,n,t[n]);if(YE)for(var n of YE(t))MQ.call(t,n)&&k8(e,n,t[n]);return e},_be=(e,t)=>{var n={};for(var r in e)LQ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&YE)for(var r of YE(e))t.indexOf(r)<0&&MQ.call(e,r)&&(n[r]=e[r]);return n};const FQ=w.forwardRef((e,t)=>{var n=e,{children:r,grow:i=!1,sx:s}=n,o=_be(n,["children","grow","sx"]);return N.createElement(it,vbe({ref:t,sx:[{flex:i?1:0,boxSizing:"border-box"},...lh(s)]},o),r)});FQ.displayName="@mantine/core/Section";const BQ=FQ;var bbe=Object.defineProperty,D8=Object.getOwnPropertySymbols,wbe=Object.prototype.hasOwnProperty,Ebe=Object.prototype.propertyIsEnumerable,$8=(e,t,n)=>t in e?bbe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Sbe=(e,t)=>{for(var n in t||(t={}))wbe.call(t,n)&&$8(e,n,t[n]);if(D8)for(var n of D8(t))Ebe.call(t,n)&&$8(e,n,t[n]);return e};const Tbe={fixed:!1,position:{top:0,left:0},hiddenBreakpoint:"md",hidden:!1},_y=w.forwardRef((e,t)=>{const n=Ve("Navbar",Tbe,e);return N.createElement(x$,Sbe({section:"navbar",__staticSelector:"Navbar",ref:t},n))});_y.Section=BQ;_y.displayName="@mantine/core/Navbar";var Ibe=Object.defineProperty,xbe=Object.defineProperties,Cbe=Object.getOwnPropertyDescriptors,L8=Object.getOwnPropertySymbols,Abe=Object.prototype.hasOwnProperty,Pbe=Object.prototype.propertyIsEnumerable,M8=(e,t,n)=>t in e?Ibe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,DP=(e,t)=>{for(var n in t||(t={}))Abe.call(t,n)&&M8(e,n,t[n]);if(L8)for(var n of L8(t))Pbe.call(t,n)&&M8(e,n,t[n]);return e},F8=(e,t)=>xbe(e,Cbe(t)),Obe=lt((e,{height:t,fixed:n,position:r,zIndex:i,borderPosition:s,layout:o})=>{const a=typeof t=="object"&&t!==null?$x(t,e).reduce((u,[l,c])=>(u[`@media (min-width: ${l}px)`]={height:c,minHeight:c},u),{}):null;return{root:F8(DP(F8(DP(DP({},e.fn.fontStyles()),r),{zIndex:i,left:o==="alt"?"var(--mantine-navbar-width, 0)":0,right:o==="alt"?"var(--mantine-aside-width, 0)":0,height:typeof t=="object"?(t==null?void 0:t.base)||"100%":t,maxHeight:typeof t=="object"?(t==null?void 0:t.base)||"100%":t,position:n?"fixed":"static",boxSizing:"border-box",backgroundColor:e.colorScheme==="dark"?e.colors.dark[7]:e.white}),a),{borderBottom:s==="bottom"?`1px solid ${e.colorScheme==="dark"?e.colors.dark[5]:e.colors.gray[2]}`:void 0,borderTop:s==="top"?`1px solid ${e.colorScheme==="dark"?e.colors.dark[5]:e.colors.gray[2]}`:void 0})}});const Rbe=Obe;var Nbe=Object.defineProperty,KE=Object.getOwnPropertySymbols,jQ=Object.prototype.hasOwnProperty,UQ=Object.prototype.propertyIsEnumerable,B8=(e,t,n)=>t in e?Nbe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,j8=(e,t)=>{for(var n in t||(t={}))jQ.call(t,n)&&B8(e,n,t[n]);if(KE)for(var n of KE(t))UQ.call(t,n)&&B8(e,n,t[n]);return e},kbe=(e,t)=>{var n={};for(var r in e)jQ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&KE)for(var r of KE(e))t.indexOf(r)<0&&UQ.call(e,r)&&(n[r]=e[r]);return n};const VQ=w.forwardRef((e,t)=>{var n=e,{children:r,className:i,classNames:s,styles:o,height:a,fixed:u=!1,withBorder:l=!0,position:c,zIndex:f,section:d,unstyled:h,__staticSelector:p}=n,m=kbe(n,["children","className","classNames","styles","height","fixed","withBorder","position","zIndex","section","unstyled","__staticSelector"]);const y=kQ(),g=f||y.zIndex||cc("app"),{classes:v,cx:b,theme:S}=Rbe({height:a,fixed:y.fixed||u,position:c,zIndex:typeof g=="number"&&y.layout==="default"?g+1:g,layout:y.layout,borderPosition:l?d==="header"?"bottom":"top":"none"},{name:p,classNames:s,styles:o,unstyled:h}),T=typeof a=="object"&&a!==null?$x(a,S).reduce((E,[I,A])=>(E[`@media (min-width: ${I}px)`]={[`--mantine-${d}-height`]:`${A}px`},E),{}):null;return N.createElement(it,j8({component:d==="header"?"header":"footer",className:b(v.root,i),ref:t},m),r,N.createElement($K,{styles:()=>({":root":j8({[`--mantine-${d}-height`]:typeof a=="object"?`${a==null?void 0:a.base}px`||"100%":`${a}px`},T)})}))});VQ.displayName="@mantine/core/VerticalSection";var Dbe=Object.defineProperty,$be=Object.defineProperties,Lbe=Object.getOwnPropertyDescriptors,U8=Object.getOwnPropertySymbols,Mbe=Object.prototype.hasOwnProperty,Fbe=Object.prototype.propertyIsEnumerable,V8=(e,t,n)=>t in e?Dbe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Bbe=(e,t)=>{for(var n in t||(t={}))Mbe.call(t,n)&&V8(e,n,t[n]);if(U8)for(var n of U8(t))Fbe.call(t,n)&&V8(e,n,t[n]);return e},jbe=(e,t)=>$be(e,Lbe(t));const Ube={fixed:!1,position:{top:0,left:0,right:0}},zQ=w.forwardRef((e,t)=>{const n=Ve("Header",Ube,e);return N.createElement(VQ,jbe(Bbe({section:"header",__staticSelector:"Header"},n),{ref:t}))});zQ.displayName="@mantine/core/Header";var Vbe=Object.defineProperty,z8=Object.getOwnPropertySymbols,zbe=Object.prototype.hasOwnProperty,Hbe=Object.prototype.propertyIsEnumerable,H8=(e,t,n)=>t in e?Vbe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Wbe=(e,t)=>{for(var n in t||(t={}))zbe.call(t,n)&&H8(e,n,t[n]);if(z8)for(var n of z8(t))Hbe.call(t,n)&&H8(e,n,t[n]);return e};const qbe={fixed:!1,position:{top:0,right:0},hiddenBreakpoint:"md",hidden:!1},C$=w.forwardRef((e,t)=>{const n=Ve("Aside",qbe,e);return N.createElement(x$,Wbe({section:"aside",__staticSelector:"Aside",ref:t},n))});C$.Section=BQ;C$.displayName="@mantine/core/Aside";var Gbe=Object.defineProperty,W8=Object.getOwnPropertySymbols,Ybe=Object.prototype.hasOwnProperty,Kbe=Object.prototype.propertyIsEnumerable,q8=(e,t,n)=>t in e?Gbe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Qbe=(e,t)=>{for(var n in t||(t={}))Ybe.call(t,n)&&q8(e,n,t[n]);if(W8)for(var n of W8(t))Kbe.call(t,n)&&q8(e,n,t[n]);return e};function Xbe(e,t){const n=t.fn.size({size:e.padding,sizes:t.spacing}),r=e.navbarOffsetBreakpoint?t.fn.size({size:e.navbarOffsetBreakpoint,sizes:t.breakpoints}):null,i=e.asideOffsetBreakpoint?t.fn.size({size:e.asideOffsetBreakpoint,sizes:t.breakpoints}):null;return e.fixed?{minHeight:"100vh",paddingTop:`calc(var(--mantine-header-height, 0px) + ${n}px)`,paddingBottom:`calc(var(--mantine-footer-height, 0px) + ${n}px)`,paddingLeft:`calc(var(--mantine-navbar-width, 0px) + ${n}px)`,paddingRight:`calc(var(--mantine-aside-width, 0px) + ${n}px)`,[`@media (max-width: ${r-1}px)`]:{paddingLeft:n},[`@media (max-width: ${i-1}px)`]:{paddingRight:n}}:{padding:n}}var Jbe=lt((e,t)=>({root:{boxSizing:"border-box"},body:{display:"flex",boxSizing:"border-box"},main:Qbe({flex:1,width:"100vw",boxSizing:"border-box"},Xbe(t,e))})),Zbe=Object.defineProperty,QE=Object.getOwnPropertySymbols,HQ=Object.prototype.hasOwnProperty,WQ=Object.prototype.propertyIsEnumerable,G8=(e,t,n)=>t in e?Zbe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ewe=(e,t)=>{for(var n in t||(t={}))HQ.call(t,n)&&G8(e,n,t[n]);if(QE)for(var n of QE(t))WQ.call(t,n)&&G8(e,n,t[n]);return e},twe=(e,t)=>{var n={};for(var r in e)HQ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&QE)for(var r of QE(e))t.indexOf(r)<0&&WQ.call(e,r)&&(n[r]=e[r]);return n};const nwe={fixed:!0,padding:"md"},qQ=w.forwardRef((e,t)=>{const n=Ve("AppShell",nwe,e),{children:r,navbar:i,header:s,footer:o,aside:a,fixed:u,zIndex:l,padding:c,navbarOffsetBreakpoint:f,asideOffsetBreakpoint:d,className:h,styles:p,classNames:m,unstyled:y,hidden:g,layout:v}=n,b=twe(n,["children","navbar","header","footer","aside","fixed","zIndex","padding","navbarOffsetBreakpoint","asideOffsetBreakpoint","className","styles","classNames","unstyled","hidden","layout"]),{classes:S,cx:T}=Jbe({padding:c,fixed:u,navbarOffsetBreakpoint:f,asideOffsetBreakpoint:d},{styles:p,classNames:m,unstyled:y,name:"AppShell"});return g?N.createElement(N.Fragment,null,r):N.createElement(abe,{value:{fixed:u,zIndex:l,layout:v}},N.createElement(it,ewe({className:T(S.root,h),ref:t},b),s,N.createElement("div",{className:S.body},i,N.createElement("main",{className:S.main},r),a),o))});qQ.displayName="@mantine/core/AppShell";const ob={xs:1,sm:2,md:3,lg:4,xl:5};function ab(e,t){const n=e.fn.variant({variant:"outline",color:t}).border;return typeof t=="string"&&(t in e.colors||t.split(".")[0]in e.colors)?n:t===void 0?e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[4]:t}var rwe=lt((e,{size:t,variant:n,color:r})=>({root:{},withLabel:{borderTop:"0 !important"},left:{"&::before":{display:"none"}},right:{"&::after":{display:"none"}},label:{display:"flex",alignItems:"center","&::before":{content:'""',flex:1,height:1,borderTop:`${e.fn.size({size:t,sizes:ob})}px ${n} ${ab(e,r)}`,marginRight:e.spacing.xs},"&::after":{content:'""',flex:1,borderTop:`${e.fn.size({size:t,sizes:ob})}px ${n} ${ab(e,r)}`,marginLeft:e.spacing.xs}},labelDefaultStyles:{color:r==="dark"?e.colors.dark[1]:e.fn.themeColor(r,e.colorScheme==="dark"?5:e.fn.primaryShade(),!1)},horizontal:{border:0,borderTopWidth:e.fn.size({size:t,sizes:ob}),borderTopColor:ab(e,r),borderTopStyle:n,margin:0},vertical:{border:0,alignSelf:"stretch",height:"auto",borderLeftWidth:e.fn.size({size:t,sizes:ob}),borderLeftColor:ab(e,r),borderLeftStyle:n}})),iwe=Object.defineProperty,swe=Object.defineProperties,owe=Object.getOwnPropertyDescriptors,XE=Object.getOwnPropertySymbols,GQ=Object.prototype.hasOwnProperty,YQ=Object.prototype.propertyIsEnumerable,Y8=(e,t,n)=>t in e?iwe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,K8=(e,t)=>{for(var n in t||(t={}))GQ.call(t,n)&&Y8(e,n,t[n]);if(XE)for(var n of XE(t))YQ.call(t,n)&&Y8(e,n,t[n]);return e},awe=(e,t)=>swe(e,owe(t)),uwe=(e,t)=>{var n={};for(var r in e)GQ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&XE)for(var r of XE(e))t.indexOf(r)<0&&YQ.call(e,r)&&(n[r]=e[r]);return n};const lwe={orientation:"horizontal",size:"xs",labelPosition:"left",variant:"solid"},df=w.forwardRef((e,t)=>{const n=Ve("Divider",lwe,e),{className:r,color:i,orientation:s,size:o,label:a,labelPosition:u,labelProps:l,variant:c,styles:f,classNames:d,unstyled:h}=n,p=uwe(n,["className","color","orientation","size","label","labelPosition","labelProps","variant","styles","classNames","unstyled"]),{classes:m,cx:y}=rwe({color:i,size:o,variant:c},{classNames:d,styles:f,unstyled:h,name:"Divider"}),g=s==="vertical",v=s==="horizontal",b=!!a&&v,S=!(l!=null&&l.color);return N.createElement(it,K8({ref:t,className:y(m.root,{[m.vertical]:g,[m.horizontal]:v,[m.withLabel]:b},r),role:"separator"},p),b&&N.createElement(rt,awe(K8({},l),{size:(l==null?void 0:l.size)||"xs",sx:{marginTop:2},className:y(m.label,m[u],{[m.labelDefaultStyles]:S})}),a))});df.displayName="@mantine/core/Divider";var cwe=Object.defineProperty,fwe=Object.defineProperties,dwe=Object.getOwnPropertyDescriptors,Q8=Object.getOwnPropertySymbols,hwe=Object.prototype.hasOwnProperty,pwe=Object.prototype.propertyIsEnumerable,X8=(e,t,n)=>t in e?cwe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,J8=(e,t)=>{for(var n in t||(t={}))hwe.call(t,n)&&X8(e,n,t[n]);if(Q8)for(var n of Q8(t))pwe.call(t,n)&&X8(e,n,t[n]);return e},mwe=(e,t)=>fwe(e,dwe(t)),gwe=lt((e,{size:t})=>({item:mwe(J8({},e.fn.fontStyles()),{boxSizing:"border-box",textAlign:"left",width:"100%",padding:`${e.fn.size({size:t,sizes:e.spacing})/1.5}px ${e.fn.size({size:t,sizes:e.spacing})}px`,cursor:"pointer",fontSize:e.fn.size({size:t,sizes:e.fontSizes}),color:e.colorScheme==="dark"?e.colors.dark[0]:e.black,borderRadius:e.fn.radius(),"&[data-hovered]":{backgroundColor:e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[1]},"&[data-selected]":J8({backgroundColor:e.fn.variant({variant:"filled"}).background,color:e.fn.variant({variant:"filled"}).color},e.fn.hover({backgroundColor:e.fn.variant({variant:"filled"}).hover})),"&[data-disabled]":{cursor:"default",color:e.colors.dark[2]}}),nothingFound:{boxSizing:"border-box",color:e.colors.gray[6],paddingTop:e.fn.size({size:t,sizes:e.spacing})/2,paddingBottom:e.fn.size({size:t,sizes:e.spacing})/2,textAlign:"center"},separator:{boxSizing:"border-box",textAlign:"left",width:"100%",padding:`${e.fn.size({size:t,sizes:e.spacing})/1.5}px ${e.fn.size({size:t,sizes:e.spacing})}px`},separatorLabel:{color:e.colorScheme==="dark"?e.colors.dark[3]:e.colors.gray[5]}})),ywe=Object.defineProperty,Z8=Object.getOwnPropertySymbols,vwe=Object.prototype.hasOwnProperty,_we=Object.prototype.propertyIsEnumerable,e9=(e,t,n)=>t in e?ywe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,bwe=(e,t)=>{for(var n in t||(t={}))vwe.call(t,n)&&e9(e,n,t[n]);if(Z8)for(var n of Z8(t))_we.call(t,n)&&e9(e,n,t[n]);return e};function A$({data:e,hovered:t,classNames:n,styles:r,isItemSelected:i,uuid:s,__staticSelector:o,onItemHover:a,onItemSelect:u,itemsRefs:l,itemComponent:c,size:f,nothingFound:d,creatable:h,createLabel:p,unstyled:m}){const{classes:y}=gwe({size:f},{classNames:n,styles:r,unstyled:m,name:o}),g=[],v=[];let b=null;const S=(E,I)=>{const A=typeof i=="function"?i(E.value):!1;return N.createElement(c,bwe({key:E.value,className:y.item,"data-disabled":E.disabled||void 0,"data-hovered":!E.disabled&&t===I||void 0,"data-selected":!E.disabled&&A||void 0,selected:A,onMouseEnter:()=>a(I),id:`${s}-${I}`,role:"option",tabIndex:-1,"aria-selected":t===I,ref:R=>{l&&l.current&&(l.current[E.value]=R)},onMouseDown:E.disabled?null:R=>{R.preventDefault(),u(E)},disabled:E.disabled},E))};let T=null;if(e.forEach((E,I)=>{E.creatable?b=I:E.group?(T!==E.group&&(T=E.group,v.push(N.createElement("div",{className:y.separator,key:`__mantine-divider-${I}`},N.createElement(df,{classNames:{label:y.separatorLabel},label:E.group})))),v.push(S(E,I))):g.push(S(E,I))}),h){const E=e[b];g.push(N.createElement("div",{key:t_e(),className:y.item,"data-hovered":t===b||void 0,onMouseEnter:()=>a(b),onMouseDown:I=>{I.preventDefault(),u(E)},tabIndex:-1,ref:I=>{l&&l.current&&(l.current[E.value]=I)}},p))}return v.length>0&&g.length>0&&g.unshift(N.createElement("div",{className:y.separator,key:"empty-group-separator"},N.createElement(df,null))),v.length>0||g.length>0?N.createElement(N.Fragment,null,v,g):N.createElement(rt,{size:f,unstyled:m,className:y.nothingFound},d)}A$.displayName="@mantine/core/SelectItems";var wwe=Object.defineProperty,JE=Object.getOwnPropertySymbols,KQ=Object.prototype.hasOwnProperty,QQ=Object.prototype.propertyIsEnumerable,t9=(e,t,n)=>t in e?wwe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Ewe=(e,t)=>{for(var n in t||(t={}))KQ.call(t,n)&&t9(e,n,t[n]);if(JE)for(var n of JE(t))QQ.call(t,n)&&t9(e,n,t[n]);return e},Swe=(e,t)=>{var n={};for(var r in e)KQ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&JE)for(var r of JE(e))t.indexOf(r)<0&&QQ.call(e,r)&&(n[r]=e[r]);return n};const P$=w.forwardRef((e,t)=>{var n=e,{label:r,value:i}=n,s=Swe(n,["label","value"]);return N.createElement("div",Ewe({ref:t},s),r||i)});P$.displayName="@mantine/core/DefaultItem";function Twe(e,t){typeof e=="function"?e(t):e!=null&&(e.current=t)}function XQ(...e){return t=>e.forEach(n=>Twe(n,t))}function kh(...e){return w.useCallback(XQ(...e),e)}const JQ=w.forwardRef((e,t)=>{const{children:n,...r}=e,i=w.Children.toArray(n),s=i.find(xwe);if(s){const o=s.props.children,a=i.map(u=>u===s?w.Children.count(o)>1?w.Children.only(null):w.isValidElement(o)?o.props.children:null:u);return w.createElement(VR,pr({},r,{ref:t}),w.isValidElement(o)?w.cloneElement(o,void 0,a):null)}return w.createElement(VR,pr({},r,{ref:t}),n)});JQ.displayName="Slot";const VR=w.forwardRef((e,t)=>{const{children:n,...r}=e;return w.isValidElement(n)?w.cloneElement(n,{...Cwe(r,n.props),ref:XQ(t,n.ref)}):w.Children.count(n)>1?w.Children.only(null):null});VR.displayName="SlotClone";const Iwe=({children:e})=>w.createElement(w.Fragment,null,e);function xwe(e){return w.isValidElement(e)&&e.type===Iwe}function Cwe(e,t){const n={...t};for(const r in t){const i=e[r],s=t[r];/^on[A-Z]/.test(r)?i&&s?n[r]=(...a)=>{s(...a),i(...a)}:i&&(n[r]=i):r==="style"?n[r]={...i,...s}:r==="className"&&(n[r]=[i,s].filter(Boolean).join(" "))}return{...e,...n}}const Awe=["a","button","div","h2","h3","img","label","li","nav","ol","p","span","svg","ul"],L_=Awe.reduce((e,t)=>{const n=w.forwardRef((r,i)=>{const{asChild:s,...o}=r,a=s?JQ:t;return w.useEffect(()=>{window[Symbol.for("radix-ui")]=!0},[]),w.createElement(a,pr({},o,{ref:i}))});return n.displayName=`Primitive.${t}`,{...e,[t]:n}},{}),zR=globalThis!=null&&globalThis.document?w.useLayoutEffect:()=>{};function Pwe(e,t){return w.useReducer((n,r)=>{const i=t[n][r];return i??n},e)}const M_=e=>{const{present:t,children:n}=e,r=Owe(t),i=typeof n=="function"?n({present:r.isPresent}):w.Children.only(n),s=kh(r.ref,i.ref);return typeof n=="function"||r.isPresent?w.cloneElement(i,{ref:s}):null};M_.displayName="Presence";function Owe(e){const[t,n]=w.useState(),r=w.useRef({}),i=w.useRef(e),s=w.useRef("none"),o=e?"mounted":"unmounted",[a,u]=Pwe(o,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return w.useEffect(()=>{const l=ub(r.current);s.current=a==="mounted"?l:"none"},[a]),zR(()=>{const l=r.current,c=i.current;if(c!==e){const d=s.current,h=ub(l);e?u("MOUNT"):h==="none"||(l==null?void 0:l.display)==="none"?u("UNMOUNT"):u(c&&d!==h?"ANIMATION_OUT":"UNMOUNT"),i.current=e}},[e,u]),zR(()=>{if(t){const l=f=>{const h=ub(r.current).includes(f.animationName);f.target===t&&h&&lc.flushSync(()=>u("ANIMATION_END"))},c=f=>{f.target===t&&(s.current=ub(r.current))};return t.addEventListener("animationstart",c),t.addEventListener("animationcancel",l),t.addEventListener("animationend",l),()=>{t.removeEventListener("animationstart",c),t.removeEventListener("animationcancel",l),t.removeEventListener("animationend",l)}}else u("ANIMATION_END")},[t,u]),{isPresent:["mounted","unmountSuspended"].includes(a),ref:w.useCallback(l=>{l&&(r.current=getComputedStyle(l)),n(l)},[])}}function ub(e){return(e==null?void 0:e.animationName)||"none"}function Rwe(e,t=[]){let n=[];function r(s,o){const a=w.createContext(o),u=n.length;n=[...n,o];function l(f){const{scope:d,children:h,...p}=f,m=(d==null?void 0:d[e][u])||a,y=w.useMemo(()=>p,Object.values(p));return w.createElement(m.Provider,{value:y},h)}function c(f,d){const h=(d==null?void 0:d[e][u])||a,p=w.useContext(h);if(p)return p;if(o!==void 0)return o;throw new Error(`\`${f}\` must be used within \`${s}\``)}return l.displayName=s+"Provider",[l,c]}const i=()=>{const s=n.map(o=>w.createContext(o));return function(a){const u=(a==null?void 0:a[e])||s;return w.useMemo(()=>({[`__scope${e}`]:{...a,[e]:u}}),[a,u])}};return i.scopeName=e,[r,Nwe(i,...t)]}function Nwe(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(i=>({useScope:i(),scopeName:i.scopeName}));return function(s){const o=r.reduce((a,{useScope:u,scopeName:l})=>{const f=u(s)[`__scope${l}`];return{...a,...f}},{});return w.useMemo(()=>({[`__scope${t.scopeName}`]:o}),[o])}};return n.scopeName=t.scopeName,n}function wd(e){const t=w.useRef(e);return w.useEffect(()=>{t.current=e}),w.useMemo(()=>(...n)=>{var r;return(r=t.current)===null||r===void 0?void 0:r.call(t,...n)},[])}const kwe=w.createContext(void 0);function Dwe(e){const t=w.useContext(kwe);return e||t||"ltr"}function $we(e,[t,n]){return Math.min(n,Math.max(t,e))}function Xd(e,t,{checkForDefaultPrevented:n=!0}={}){return function(i){if(e==null||e(i),n===!1||!i.defaultPrevented)return t==null?void 0:t(i)}}function Lwe(e,t){return w.useReducer((n,r)=>{const i=t[n][r];return i??n},e)}const ZQ="ScrollArea",[eX,sdt]=Rwe(ZQ),[Mwe,da]=eX(ZQ),Fwe=w.forwardRef((e,t)=>{const{__scopeScrollArea:n,type:r="hover",dir:i,scrollHideDelay:s=600,...o}=e,[a,u]=w.useState(null),[l,c]=w.useState(null),[f,d]=w.useState(null),[h,p]=w.useState(null),[m,y]=w.useState(null),[g,v]=w.useState(0),[b,S]=w.useState(0),[T,E]=w.useState(!1),[I,A]=w.useState(!1),R=kh(t,L=>u(L)),F=Dwe(i);return w.createElement(Mwe,{scope:n,type:r,dir:F,scrollHideDelay:s,scrollArea:a,viewport:l,onViewportChange:c,content:f,onContentChange:d,scrollbarX:h,onScrollbarXChange:p,scrollbarXEnabled:T,onScrollbarXEnabledChange:E,scrollbarY:m,onScrollbarYChange:y,scrollbarYEnabled:I,onScrollbarYEnabledChange:A,onCornerWidthChange:v,onCornerHeightChange:S},w.createElement(L_.div,pr({dir:F},o,{ref:R,style:{position:"relative","--radix-scroll-area-corner-width":g+"px","--radix-scroll-area-corner-height":b+"px",...e.style}})))}),Bwe="ScrollAreaViewport",jwe=w.forwardRef((e,t)=>{const{__scopeScrollArea:n,children:r,...i}=e,s=da(Bwe,n),o=w.useRef(null),a=kh(t,o,s.onViewportChange);return w.createElement(w.Fragment,null,w.createElement("style",{dangerouslySetInnerHTML:{__html:"[data-radix-scroll-area-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-scroll-area-viewport]::-webkit-scrollbar{display:none}"}}),w.createElement(L_.div,pr({"data-radix-scroll-area-viewport":""},i,{ref:a,style:{overflowX:s.scrollbarXEnabled?"scroll":"hidden",overflowY:s.scrollbarYEnabled?"scroll":"hidden",...e.style}}),w.createElement("div",{ref:s.onContentChange,style:{minWidth:"100%",display:"table"}},r)))}),fc="ScrollAreaScrollbar",Uwe=w.forwardRef((e,t)=>{const{forceMount:n,...r}=e,i=da(fc,e.__scopeScrollArea),{onScrollbarXEnabledChange:s,onScrollbarYEnabledChange:o}=i,a=e.orientation==="horizontal";return w.useEffect(()=>(a?s(!0):o(!0),()=>{a?s(!1):o(!1)}),[a,s,o]),i.type==="hover"?w.createElement(Vwe,pr({},r,{ref:t,forceMount:n})):i.type==="scroll"?w.createElement(zwe,pr({},r,{ref:t,forceMount:n})):i.type==="auto"?w.createElement(tX,pr({},r,{ref:t,forceMount:n})):i.type==="always"?w.createElement(O$,pr({},r,{ref:t})):null}),Vwe=w.forwardRef((e,t)=>{const{forceMount:n,...r}=e,i=da(fc,e.__scopeScrollArea),[s,o]=w.useState(!1);return w.useEffect(()=>{const a=i.scrollArea;let u=0;if(a){const l=()=>{window.clearTimeout(u),o(!0)},c=()=>{u=window.setTimeout(()=>o(!1),i.scrollHideDelay)};return a.addEventListener("pointerenter",l),a.addEventListener("pointerleave",c),()=>{window.clearTimeout(u),a.removeEventListener("pointerenter",l),a.removeEventListener("pointerleave",c)}}},[i.scrollArea,i.scrollHideDelay]),w.createElement(M_,{present:n||s},w.createElement(tX,pr({"data-state":s?"visible":"hidden"},r,{ref:t})))}),zwe=w.forwardRef((e,t)=>{const{forceMount:n,...r}=e,i=da(fc,e.__scopeScrollArea),s=e.orientation==="horizontal",o=Mx(()=>u("SCROLL_END"),100),[a,u]=Lwe("hidden",{hidden:{SCROLL:"scrolling"},scrolling:{SCROLL_END:"idle",POINTER_ENTER:"interacting"},interacting:{SCROLL:"interacting",POINTER_LEAVE:"idle"},idle:{HIDE:"hidden",SCROLL:"scrolling",POINTER_ENTER:"interacting"}});return w.useEffect(()=>{if(a==="idle"){const l=window.setTimeout(()=>u("HIDE"),i.scrollHideDelay);return()=>window.clearTimeout(l)}},[a,i.scrollHideDelay,u]),w.useEffect(()=>{const l=i.viewport,c=s?"scrollLeft":"scrollTop";if(l){let f=l[c];const d=()=>{const h=l[c];f!==h&&(u("SCROLL"),o()),f=h};return l.addEventListener("scroll",d),()=>l.removeEventListener("scroll",d)}},[i.viewport,s,u,o]),w.createElement(M_,{present:n||a!=="hidden"},w.createElement(O$,pr({"data-state":a==="hidden"?"hidden":"visible"},r,{ref:t,onPointerEnter:Xd(e.onPointerEnter,()=>u("POINTER_ENTER")),onPointerLeave:Xd(e.onPointerLeave,()=>u("POINTER_LEAVE"))})))}),tX=w.forwardRef((e,t)=>{const n=da(fc,e.__scopeScrollArea),{forceMount:r,...i}=e,[s,o]=w.useState(!1),a=e.orientation==="horizontal",u=Mx(()=>{if(n.viewport){const l=n.viewport.offsetWidth{const{orientation:n="vertical",...r}=e,i=da(fc,e.__scopeScrollArea),s=w.useRef(null),o=w.useRef(0),[a,u]=w.useState({content:0,viewport:0,scrollbar:{size:0,paddingStart:0,paddingEnd:0}}),l=sX(a.viewport,a.content),c={...r,sizes:a,onSizesChange:u,hasThumb:l>0&&l<1,onThumbChange:d=>s.current=d,onThumbPointerUp:()=>o.current=0,onThumbPointerDown:d=>o.current=d};function f(d,h){return Xwe(d,o.current,a,h)}return n==="horizontal"?w.createElement(Hwe,pr({},c,{ref:t,onThumbPositionChange:()=>{if(i.viewport&&s.current){const d=i.viewport.scrollLeft,h=n9(d,a,i.dir);s.current.style.transform=`translate3d(${h}px, 0, 0)`}},onWheelScroll:d=>{i.viewport&&(i.viewport.scrollLeft=d)},onDragScroll:d=>{i.viewport&&(i.viewport.scrollLeft=f(d,i.dir))}})):n==="vertical"?w.createElement(Wwe,pr({},c,{ref:t,onThumbPositionChange:()=>{if(i.viewport&&s.current){const d=i.viewport.scrollTop,h=n9(d,a);s.current.style.transform=`translate3d(0, ${h}px, 0)`}},onWheelScroll:d=>{i.viewport&&(i.viewport.scrollTop=d)},onDragScroll:d=>{i.viewport&&(i.viewport.scrollTop=f(d))}})):null}),Hwe=w.forwardRef((e,t)=>{const{sizes:n,onSizesChange:r,...i}=e,s=da(fc,e.__scopeScrollArea),[o,a]=w.useState(),u=w.useRef(null),l=kh(t,u,s.onScrollbarXChange);return w.useEffect(()=>{u.current&&a(getComputedStyle(u.current))},[u]),w.createElement(rX,pr({"data-orientation":"horizontal"},i,{ref:l,sizes:n,style:{bottom:0,left:s.dir==="rtl"?"var(--radix-scroll-area-corner-width)":0,right:s.dir==="ltr"?"var(--radix-scroll-area-corner-width)":0,"--radix-scroll-area-thumb-width":Lx(n)+"px",...e.style},onThumbPointerDown:c=>e.onThumbPointerDown(c.x),onDragScroll:c=>e.onDragScroll(c.x),onWheelScroll:(c,f)=>{if(s.viewport){const d=s.viewport.scrollLeft+c.deltaX;e.onWheelScroll(d),aX(d,f)&&c.preventDefault()}},onResize:()=>{u.current&&s.viewport&&o&&r({content:s.viewport.scrollWidth,viewport:s.viewport.offsetWidth,scrollbar:{size:u.current.clientWidth,paddingStart:ZE(o.paddingLeft),paddingEnd:ZE(o.paddingRight)}})}}))}),Wwe=w.forwardRef((e,t)=>{const{sizes:n,onSizesChange:r,...i}=e,s=da(fc,e.__scopeScrollArea),[o,a]=w.useState(),u=w.useRef(null),l=kh(t,u,s.onScrollbarYChange);return w.useEffect(()=>{u.current&&a(getComputedStyle(u.current))},[u]),w.createElement(rX,pr({"data-orientation":"vertical"},i,{ref:l,sizes:n,style:{top:0,right:s.dir==="ltr"?0:void 0,left:s.dir==="rtl"?0:void 0,bottom:"var(--radix-scroll-area-corner-height)","--radix-scroll-area-thumb-height":Lx(n)+"px",...e.style},onThumbPointerDown:c=>e.onThumbPointerDown(c.y),onDragScroll:c=>e.onDragScroll(c.y),onWheelScroll:(c,f)=>{if(s.viewport){const d=s.viewport.scrollTop+c.deltaY;e.onWheelScroll(d),aX(d,f)&&c.preventDefault()}},onResize:()=>{u.current&&s.viewport&&o&&r({content:s.viewport.scrollHeight,viewport:s.viewport.offsetHeight,scrollbar:{size:u.current.clientHeight,paddingStart:ZE(o.paddingTop),paddingEnd:ZE(o.paddingBottom)}})}}))}),[qwe,nX]=eX(fc),rX=w.forwardRef((e,t)=>{const{__scopeScrollArea:n,sizes:r,hasThumb:i,onThumbChange:s,onThumbPointerUp:o,onThumbPointerDown:a,onThumbPositionChange:u,onDragScroll:l,onWheelScroll:c,onResize:f,...d}=e,h=da(fc,n),[p,m]=w.useState(null),y=kh(t,R=>m(R)),g=w.useRef(null),v=w.useRef(""),b=h.viewport,S=r.content-r.viewport,T=wd(c),E=wd(u),I=Mx(f,10);function A(R){if(g.current){const F=R.clientX-g.current.left,L=R.clientY-g.current.top;l({x:F,y:L})}}return w.useEffect(()=>{const R=F=>{const L=F.target;(p==null?void 0:p.contains(L))&&T(F,S)};return document.addEventListener("wheel",R,{passive:!1}),()=>document.removeEventListener("wheel",R,{passive:!1})},[b,p,S,T]),w.useEffect(E,[r,E]),km(p,I),km(h.content,I),w.createElement(qwe,{scope:n,scrollbar:p,hasThumb:i,onThumbChange:wd(s),onThumbPointerUp:wd(o),onThumbPositionChange:E,onThumbPointerDown:wd(a)},w.createElement(L_.div,pr({},d,{ref:y,style:{position:"absolute",...d.style},onPointerDown:Xd(e.onPointerDown,R=>{R.button===0&&(R.target.setPointerCapture(R.pointerId),g.current=p.getBoundingClientRect(),v.current=document.body.style.webkitUserSelect,document.body.style.webkitUserSelect="none",A(R))}),onPointerMove:Xd(e.onPointerMove,A),onPointerUp:Xd(e.onPointerUp,R=>{const F=R.target;F.hasPointerCapture(R.pointerId)&&F.releasePointerCapture(R.pointerId),document.body.style.webkitUserSelect=v.current,g.current=null})})))}),HR="ScrollAreaThumb",Gwe=w.forwardRef((e,t)=>{const{forceMount:n,...r}=e,i=nX(HR,e.__scopeScrollArea);return w.createElement(M_,{present:n||i.hasThumb},w.createElement(Ywe,pr({ref:t},r)))}),Ywe=w.forwardRef((e,t)=>{const{__scopeScrollArea:n,style:r,...i}=e,s=da(HR,n),o=nX(HR,n),{onThumbPositionChange:a}=o,u=kh(t,f=>o.onThumbChange(f)),l=w.useRef(),c=Mx(()=>{l.current&&(l.current(),l.current=void 0)},100);return w.useEffect(()=>{const f=s.viewport;if(f){const d=()=>{if(c(),!l.current){const h=Jwe(f,a);l.current=h,a()}};return a(),f.addEventListener("scroll",d),()=>f.removeEventListener("scroll",d)}},[s.viewport,c,a]),w.createElement(L_.div,pr({"data-state":o.hasThumb?"visible":"hidden"},i,{ref:u,style:{width:"var(--radix-scroll-area-thumb-width)",height:"var(--radix-scroll-area-thumb-height)",...r},onPointerDownCapture:Xd(e.onPointerDownCapture,f=>{const h=f.target.getBoundingClientRect(),p=f.clientX-h.left,m=f.clientY-h.top;o.onThumbPointerDown({x:p,y:m})}),onPointerUp:Xd(e.onPointerUp,o.onThumbPointerUp)}))}),iX="ScrollAreaCorner",Kwe=w.forwardRef((e,t)=>{const n=da(iX,e.__scopeScrollArea),r=!!(n.scrollbarX&&n.scrollbarY);return n.type!=="scroll"&&r?w.createElement(Qwe,pr({},e,{ref:t})):null}),Qwe=w.forwardRef((e,t)=>{const{__scopeScrollArea:n,...r}=e,i=da(iX,n),[s,o]=w.useState(0),[a,u]=w.useState(0),l=!!(s&&a);return km(i.scrollbarX,()=>{var c;const f=((c=i.scrollbarX)===null||c===void 0?void 0:c.offsetHeight)||0;i.onCornerHeightChange(f),u(f)}),km(i.scrollbarY,()=>{var c;const f=((c=i.scrollbarY)===null||c===void 0?void 0:c.offsetWidth)||0;i.onCornerWidthChange(f),o(f)}),l?w.createElement(L_.div,pr({},r,{ref:t,style:{width:s,height:a,position:"absolute",right:i.dir==="ltr"?0:void 0,left:i.dir==="rtl"?0:void 0,bottom:0,...e.style}})):null});function ZE(e){return e?parseInt(e,10):0}function sX(e,t){const n=e/t;return isNaN(n)?0:n}function Lx(e){const t=sX(e.viewport,e.content),n=e.scrollbar.paddingStart+e.scrollbar.paddingEnd,r=(e.scrollbar.size-n)*t;return Math.max(r,18)}function Xwe(e,t,n,r="ltr"){const i=Lx(n),s=i/2,o=t||s,a=i-o,u=n.scrollbar.paddingStart+o,l=n.scrollbar.size-n.scrollbar.paddingEnd-a,c=n.content-n.viewport,f=r==="ltr"?[0,c]:[c*-1,0];return oX([u,l],f)(e)}function n9(e,t,n="ltr"){const r=Lx(t),i=t.scrollbar.paddingStart+t.scrollbar.paddingEnd,s=t.scrollbar.size-i,o=t.content-t.viewport,a=s-r,u=n==="ltr"?[0,o]:[o*-1,0],l=$we(e,u);return oX([0,o],[0,a])(l)}function oX(e,t){return n=>{if(e[0]===e[1]||t[0]===t[1])return t[0];const r=(t[1]-t[0])/(e[1]-e[0]);return t[0]+r*(n-e[0])}}function aX(e,t){return e>0&&e{})=>{let n={left:e.scrollLeft,top:e.scrollTop},r=0;return function i(){const s={left:e.scrollLeft,top:e.scrollTop},o=n.left!==s.left,a=n.top!==s.top;(o||a)&&t(),n=s,r=window.requestAnimationFrame(i)}(),()=>window.cancelAnimationFrame(r)};function Mx(e,t){const n=wd(e),r=w.useRef(0);return w.useEffect(()=>()=>window.clearTimeout(r.current),[]),w.useCallback(()=>{window.clearTimeout(r.current),r.current=window.setTimeout(n,t)},[n,t])}function km(e,t){const n=wd(t);zR(()=>{let r=0;if(e){const i=new ResizeObserver(()=>{cancelAnimationFrame(r),r=window.requestAnimationFrame(n)});return i.observe(e),()=>{window.cancelAnimationFrame(r),i.unobserve(e)}}},[e,n])}const Zwe=Fwe,eEe=jwe,r9=Uwe,i9=Gwe,tEe=Kwe;var nEe=lt((e,{scrollbarSize:t,offsetScrollbars:n,scrollbarHovered:r,hidden:i},s)=>({root:{overflow:"hidden"},viewport:{width:"100%",height:"100%",paddingRight:n?t:void 0,paddingBottom:n?t:void 0},scrollbar:{display:i?"none":"flex",userSelect:"none",touchAction:"none",boxSizing:"border-box",padding:t/5,transition:"background-color 150ms ease, opacity 150ms ease","&:hover":{backgroundColor:e.colorScheme==="dark"?e.colors.dark[8]:e.colors.gray[0],[`& .${s("thumb")}`]:{backgroundColor:e.colorScheme==="dark"?e.fn.rgba(e.white,.5):e.fn.rgba(e.black,.5)}},'&[data-orientation="vertical"]':{width:t},'&[data-orientation="horizontal"]':{flexDirection:"column",height:t},'&[data-state="hidden"]':{display:"none",opacity:0}},thumb:{ref:s("thumb"),flex:1,backgroundColor:e.colorScheme==="dark"?e.fn.rgba(e.white,.4):e.fn.rgba(e.black,.4),borderRadius:t,position:"relative",transition:"background-color 150ms ease",display:i?"none":void 0,overflow:"hidden","&::before":{content:'""',position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)",width:"100%",height:"100%",minWidth:44,minHeight:44}},corner:{backgroundColor:e.colorScheme==="dark"?e.colors.dark[6]:e.colors.gray[0],transition:"opacity 150ms ease",opacity:r?1:0,display:i?"none":void 0}})),rEe=Object.defineProperty,iEe=Object.defineProperties,sEe=Object.getOwnPropertyDescriptors,eS=Object.getOwnPropertySymbols,uX=Object.prototype.hasOwnProperty,lX=Object.prototype.propertyIsEnumerable,s9=(e,t,n)=>t in e?rEe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,WR=(e,t)=>{for(var n in t||(t={}))uX.call(t,n)&&s9(e,n,t[n]);if(eS)for(var n of eS(t))lX.call(t,n)&&s9(e,n,t[n]);return e},cX=(e,t)=>iEe(e,sEe(t)),fX=(e,t)=>{var n={};for(var r in e)uX.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&eS)for(var r of eS(e))t.indexOf(r)<0&&lX.call(e,r)&&(n[r]=e[r]);return n};const dX={scrollbarSize:12,scrollHideDelay:1e3,type:"hover",offsetScrollbars:!1},Fx=w.forwardRef((e,t)=>{const n=Ve("ScrollArea",dX,e),{children:r,className:i,classNames:s,styles:o,scrollbarSize:a,scrollHideDelay:u,type:l,dir:c,offsetScrollbars:f,viewportRef:d,onScrollPositionChange:h,unstyled:p,viewportProps:m}=n,y=fX(n,["children","className","classNames","styles","scrollbarSize","scrollHideDelay","type","dir","offsetScrollbars","viewportRef","onScrollPositionChange","unstyled","viewportProps"]),[g,v]=w.useState(!1),b=ji(),{classes:S,cx:T}=nEe({scrollbarSize:a,offsetScrollbars:f,scrollbarHovered:g,hidden:l==="never"},{name:"ScrollArea",classNames:s,styles:o,unstyled:p});return N.createElement(Zwe,{type:l==="never"?"always":l,scrollHideDelay:u,dir:c||b.dir,ref:t,asChild:!0},N.createElement(it,WR({className:T(S.root,i)},y),N.createElement(eEe,cX(WR({},m),{className:S.viewport,ref:d,onScroll:typeof h=="function"?({currentTarget:E})=>h({x:E.scrollLeft,y:E.scrollTop}):void 0}),r),N.createElement(r9,{orientation:"horizontal",className:S.scrollbar,forceMount:!0,onMouseEnter:()=>v(!0),onMouseLeave:()=>v(!1)},N.createElement(i9,{className:S.thumb})),N.createElement(r9,{orientation:"vertical",className:S.scrollbar,forceMount:!0,onMouseEnter:()=>v(!0),onMouseLeave:()=>v(!1)},N.createElement(i9,{className:S.thumb})),N.createElement(tEe,{className:S.corner})))}),hX=w.forwardRef((e,t)=>{const n=Ve("ScrollAreaAutosize",dX,e),{maxHeight:r,children:i,classNames:s,styles:o,scrollbarSize:a,scrollHideDelay:u,type:l,dir:c,offsetScrollbars:f,viewportRef:d,onScrollPositionChange:h,unstyled:p,sx:m}=n,y=fX(n,["maxHeight","children","classNames","styles","scrollbarSize","scrollHideDelay","type","dir","offsetScrollbars","viewportRef","onScrollPositionChange","unstyled","sx"]);return N.createElement(it,cX(WR({},y),{ref:t,sx:[{display:"flex",maxHeight:r},...lh(m)]}),N.createElement(it,{sx:{display:"flex",flexDirection:"column",flex:1}},N.createElement(Fx,{classNames:s,styles:o,scrollHideDelay:u,scrollbarSize:a,type:l,dir:c,offsetScrollbars:f,viewportRef:d,onScrollPositionChange:h,unstyled:p},i)))});hX.displayName="@mantine/core/ScrollAreaAutosize";Fx.displayName="@mantine/core/ScrollArea";Fx.Autosize=hX;const R$=Fx;var oEe=Object.defineProperty,aEe=Object.defineProperties,uEe=Object.getOwnPropertyDescriptors,tS=Object.getOwnPropertySymbols,pX=Object.prototype.hasOwnProperty,mX=Object.prototype.propertyIsEnumerable,o9=(e,t,n)=>t in e?oEe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,a9=(e,t)=>{for(var n in t||(t={}))pX.call(t,n)&&o9(e,n,t[n]);if(tS)for(var n of tS(t))mX.call(t,n)&&o9(e,n,t[n]);return e},lEe=(e,t)=>aEe(e,uEe(t)),cEe=(e,t)=>{var n={};for(var r in e)pX.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&tS)for(var r of tS(e))t.indexOf(r)<0&&mX.call(e,r)&&(n[r]=e[r]);return n};const Bx=w.forwardRef((e,t)=>{var n=e,{style:r}=n,i=cEe(n,["style"]);return N.createElement(R$,lEe(a9({},i),{style:a9({width:"100%"},r),viewportRef:t}),i.children)});Bx.displayName="@mantine/core/SelectScrollArea";var fEe=lt(()=>({dropdown:{},itemsWrapper:{padding:4,display:"flex",width:"100%",boxSizing:"border-box"}}));const qa=Math.min,es=Math.max,nS=Math.round,lb=Math.floor,If=e=>({x:e,y:e}),dEe={left:"right",right:"left",bottom:"top",top:"bottom"},hEe={start:"end",end:"start"};function qR(e,t,n){return es(e,qa(t,n))}function ql(e,t){return typeof e=="function"?e(t):e}function Ga(e){return e.split("-")[0]}function wg(e){return e.split("-")[1]}function N$(e){return e==="x"?"y":"x"}function k$(e){return e==="y"?"height":"width"}function Dh(e){return["top","bottom"].includes(Ga(e))?"y":"x"}function D$(e){return N$(Dh(e))}function pEe(e,t,n){n===void 0&&(n=!1);const r=wg(e),i=D$(e),s=k$(i);let o=i==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[s]>t.floating[s]&&(o=rS(o)),[o,rS(o)]}function mEe(e){const t=rS(e);return[GR(e),t,GR(t)]}function GR(e){return e.replace(/start|end/g,t=>hEe[t])}function gEe(e,t,n){const r=["left","right"],i=["right","left"],s=["top","bottom"],o=["bottom","top"];switch(e){case"top":case"bottom":return n?t?i:r:t?r:i;case"left":case"right":return t?s:o;default:return[]}}function yEe(e,t,n,r){const i=wg(e);let s=gEe(Ga(e),n==="start",r);return i&&(s=s.map(o=>o+"-"+i),t&&(s=s.concat(s.map(GR)))),s}function rS(e){return e.replace(/left|right|bottom|top/g,t=>dEe[t])}function vEe(e){return{top:0,right:0,bottom:0,left:0,...e}}function $$(e){return typeof e!="number"?vEe(e):{top:e,right:e,bottom:e,left:e}}function Dm(e){return{...e,top:e.y,left:e.x,right:e.x+e.width,bottom:e.y+e.height}}function u9(e,t,n){let{reference:r,floating:i}=e;const s=Dh(t),o=D$(t),a=k$(o),u=Ga(t),l=s==="y",c=r.x+r.width/2-i.width/2,f=r.y+r.height/2-i.height/2,d=r[a]/2-i[a]/2;let h;switch(u){case"top":h={x:c,y:r.y-i.height};break;case"bottom":h={x:c,y:r.y+r.height};break;case"right":h={x:r.x+r.width,y:f};break;case"left":h={x:r.x-i.width,y:f};break;default:h={x:r.x,y:r.y}}switch(wg(t)){case"start":h[o]-=d*(n&&l?-1:1);break;case"end":h[o]+=d*(n&&l?-1:1);break}return h}const _Ee=async(e,t,n)=>{const{placement:r="bottom",strategy:i="absolute",middleware:s=[],platform:o}=n,a=s.filter(Boolean),u=await(o.isRTL==null?void 0:o.isRTL(t));let l=await o.getElementRects({reference:e,floating:t,strategy:i}),{x:c,y:f}=u9(l,r,u),d=r,h={},p=0;for(let m=0;m({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:i,rects:s,platform:o,elements:a,middlewareData:u}=t,{element:l,padding:c=0}=ql(e,t)||{};if(l==null)return{};const f=$$(c),d={x:n,y:r},h=D$(i),p=k$(h),m=await o.getDimensions(l),y=h==="y",g=y?"top":"left",v=y?"bottom":"right",b=y?"clientHeight":"clientWidth",S=s.reference[p]+s.reference[h]-d[h]-s.floating[p],T=d[h]-s.reference[h],E=await(o.getOffsetParent==null?void 0:o.getOffsetParent(l));let I=E?E[b]:0;(!I||!await(o.isElement==null?void 0:o.isElement(E)))&&(I=a.floating[b]||s.floating[p]);const A=S/2-T/2,R=I/2-m[p]/2-1,F=qa(f[g],R),L=qa(f[v],R),B=F,J=I-m[p]-L,V=I/2-m[p]/2+A,re=qR(B,V,J),oe=!u.arrow&&wg(i)!=null&&V!==re&&s.reference[p]/2-(VB<=0)){var R,F;const B=(((R=s.flip)==null?void 0:R.index)||0)+1,J=T[B];if(J)return{data:{index:B,overflows:A},reset:{placement:J}};let V=(F=A.filter(re=>re.overflows[0]<=0).sort((re,oe)=>re.overflows[1]-oe.overflows[1])[0])==null?void 0:F.placement;if(!V)switch(h){case"bestFit":{var L;const re=(L=A.map(oe=>[oe.placement,oe.overflows.filter(ae=>ae>0).reduce((ae,ee)=>ae+ee,0)]).sort((oe,ae)=>oe[1]-ae[1])[0])==null?void 0:L[0];re&&(V=re);break}case"initialPlacement":V=a;break}if(i!==V)return{reset:{placement:V}}}return{}}}};function gX(e){const t=qa(...e.map(s=>s.left)),n=qa(...e.map(s=>s.top)),r=es(...e.map(s=>s.right)),i=es(...e.map(s=>s.bottom));return{x:t,y:n,width:r-t,height:i-n}}function EEe(e){const t=e.slice().sort((i,s)=>i.y-s.y),n=[];let r=null;for(let i=0;ir.height/2?n.push([s]):n[n.length-1].push(s),r=s}return n.map(i=>Dm(gX(i)))}const SEe=function(e){return e===void 0&&(e={}),{name:"inline",options:e,async fn(t){const{placement:n,elements:r,rects:i,platform:s,strategy:o}=t,{padding:a=2,x:u,y:l}=ql(e,t),c=Array.from(await(s.getClientRects==null?void 0:s.getClientRects(r.reference))||[]),f=EEe(c),d=Dm(gX(c)),h=$$(a);function p(){if(f.length===2&&f[0].left>f[1].right&&u!=null&&l!=null)return f.find(y=>u>y.left-h.left&&uy.top-h.top&&l=2){if(Dh(n)==="y"){const F=f[0],L=f[f.length-1],B=Ga(n)==="top",J=F.top,V=L.bottom,re=B?F.left:L.left,oe=B?F.right:L.right,ae=oe-re,ee=V-J;return{top:J,bottom:V,left:re,right:oe,width:ae,height:ee,x:re,y:J}}const y=Ga(n)==="left",g=es(...f.map(F=>F.right)),v=qa(...f.map(F=>F.left)),b=f.filter(F=>y?F.left===v:F.right===g),S=b[0].top,T=b[b.length-1].bottom,E=v,I=g,A=I-E,R=T-S;return{top:S,bottom:T,left:E,right:I,width:A,height:R,x:E,y:S}}return d}const m=await s.getElementRects({reference:{getBoundingClientRect:p},floating:r.floating,strategy:o});return i.reference.x!==m.reference.x||i.reference.y!==m.reference.y||i.reference.width!==m.reference.width||i.reference.height!==m.reference.height?{reset:{rects:m}}:{}}}};async function TEe(e,t){const{placement:n,platform:r,elements:i}=e,s=await(r.isRTL==null?void 0:r.isRTL(i.floating)),o=Ga(n),a=wg(n),u=Dh(n)==="y",l=["left","top"].includes(o)?-1:1,c=s&&u?-1:1,f=ql(t,e);let{mainAxis:d,crossAxis:h,alignmentAxis:p}=typeof f=="number"?{mainAxis:f,crossAxis:0,alignmentAxis:null}:{mainAxis:0,crossAxis:0,alignmentAxis:null,...f};return a&&typeof p=="number"&&(h=a==="end"?p*-1:p),u?{x:h*c,y:d*l}:{x:d*l,y:h*c}}const yX=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:i,y:s,placement:o,middlewareData:a}=t,u=await TEe(t,e);return o===((n=a.offset)==null?void 0:n.placement)&&(r=a.arrow)!=null&&r.alignmentOffset?{}:{x:i+u.x,y:s+u.y,data:{...u,placement:o}}}}},IEe=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:i}=t,{mainAxis:s=!0,crossAxis:o=!1,limiter:a={fn:y=>{let{x:g,y:v}=y;return{x:g,y:v}}},...u}=ql(e,t),l={x:n,y:r},c=await L$(t,u),f=Dh(Ga(i)),d=N$(f);let h=l[d],p=l[f];if(s){const y=d==="y"?"top":"left",g=d==="y"?"bottom":"right",v=h+c[y],b=h-c[g];h=qR(v,h,b)}if(o){const y=f==="y"?"top":"left",g=f==="y"?"bottom":"right",v=p+c[y],b=p-c[g];p=qR(v,p,b)}const m=a.fn({...t,[d]:h,[f]:p});return{...m,data:{x:m.x-n,y:m.y-r}}}}},xEe=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:i,rects:s,middlewareData:o}=t,{offset:a=0,mainAxis:u=!0,crossAxis:l=!0}=ql(e,t),c={x:n,y:r},f=Dh(i),d=N$(f);let h=c[d],p=c[f];const m=ql(a,t),y=typeof m=="number"?{mainAxis:m,crossAxis:0}:{mainAxis:0,crossAxis:0,...m};if(u){const b=d==="y"?"height":"width",S=s.reference[d]-s.floating[b]+y.mainAxis,T=s.reference[d]+s.reference[b]-y.mainAxis;hT&&(h=T)}if(l){var g,v;const b=d==="y"?"width":"height",S=["top","left"].includes(Ga(i)),T=s.reference[f]-s.floating[b]+(S&&((g=o.offset)==null?void 0:g[f])||0)+(S?0:y.crossAxis),E=s.reference[f]+s.reference[b]+(S?0:((v=o.offset)==null?void 0:v[f])||0)-(S?y.crossAxis:0);pE&&(p=E)}return{[d]:h,[f]:p}}}},CEe=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){const{placement:n,rects:r,platform:i,elements:s}=t,{apply:o=()=>{},...a}=ql(e,t),u=await L$(t,a),l=Ga(n),c=wg(n),f=Dh(n)==="y",{width:d,height:h}=r.floating;let p,m;l==="top"||l==="bottom"?(p=l,m=c===(await(i.isRTL==null?void 0:i.isRTL(s.floating))?"start":"end")?"left":"right"):(m=l,p=c==="end"?"top":"bottom");const y=h-u[p],g=d-u[m],v=!t.middlewareData.shift;let b=y,S=g;if(f){const E=d-u.left-u.right;S=c||v?qa(g,E):E}else{const E=h-u.top-u.bottom;b=c||v?qa(y,E):E}if(v&&!c){const E=es(u.left,0),I=es(u.right,0),A=es(u.top,0),R=es(u.bottom,0);f?S=d-2*(E!==0||I!==0?E+I:es(u.left,u.right)):b=h-2*(A!==0||R!==0?A+R:es(u.top,u.bottom))}await o({...t,availableWidth:S,availableHeight:b});const T=await i.getDimensions(s.floating);return d!==T.width||h!==T.height?{reset:{rects:!0}}:{}}}};function xf(e){return vX(e)?(e.nodeName||"").toLowerCase():"#document"}function Co(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function dc(e){var t;return(t=(vX(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function vX(e){return e instanceof Node||e instanceof Co(e).Node}function Gl(e){return e instanceof Element||e instanceof Co(e).Element}function Qu(e){return e instanceof HTMLElement||e instanceof Co(e).HTMLElement}function l9(e){return typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof Co(e).ShadowRoot}function F_(e){const{overflow:t,overflowX:n,overflowY:r,display:i}=aa(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!["inline","contents"].includes(i)}function AEe(e){return["table","td","th"].includes(xf(e))}function M$(e){const t=F$(),n=aa(e);return n.transform!=="none"||n.perspective!=="none"||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||["transform","perspective","filter"].some(r=>(n.willChange||"").includes(r))||["paint","layout","strict","content"].some(r=>(n.contain||"").includes(r))}function PEe(e){let t=$m(e);for(;Qu(t)&&!jx(t);){if(M$(t))return t;t=$m(t)}return null}function F$(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function jx(e){return["html","body","#document"].includes(xf(e))}function aa(e){return Co(e).getComputedStyle(e)}function Ux(e){return Gl(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.pageXOffset,scrollTop:e.pageYOffset}}function $m(e){if(xf(e)==="html")return e;const t=e.assignedSlot||e.parentNode||l9(e)&&e.host||dc(e);return l9(t)?t.host:t}function _X(e){const t=$m(e);return jx(t)?e.ownerDocument?e.ownerDocument.body:e.body:Qu(t)&&F_(t)?t:_X(t)}function Fl(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const i=_X(e),s=i===((r=e.ownerDocument)==null?void 0:r.body),o=Co(i);return s?t.concat(o,o.visualViewport||[],F_(i)?i:[],o.frameElement&&n?Fl(o.frameElement):[]):t.concat(i,Fl(i,[],n))}function bX(e){const t=aa(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const i=Qu(e),s=i?e.offsetWidth:n,o=i?e.offsetHeight:r,a=nS(n)!==s||nS(r)!==o;return a&&(n=s,r=o),{width:n,height:r,$:a}}function B$(e){return Gl(e)?e:e.contextElement}function Zp(e){const t=B$(e);if(!Qu(t))return If(1);const n=t.getBoundingClientRect(),{width:r,height:i,$:s}=bX(t);let o=(s?nS(n.width):n.width)/r,a=(s?nS(n.height):n.height)/i;return(!o||!Number.isFinite(o))&&(o=1),(!a||!Number.isFinite(a))&&(a=1),{x:o,y:a}}const OEe=If(0);function wX(e){const t=Co(e);return!F$()||!t.visualViewport?OEe:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function REe(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==Co(e)?!1:t}function ch(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const i=e.getBoundingClientRect(),s=B$(e);let o=If(1);t&&(r?Gl(r)&&(o=Zp(r)):o=Zp(e));const a=REe(s,n,r)?wX(s):If(0);let u=(i.left+a.x)/o.x,l=(i.top+a.y)/o.y,c=i.width/o.x,f=i.height/o.y;if(s){const d=Co(s),h=r&&Gl(r)?Co(r):r;let p=d,m=p.frameElement;for(;m&&r&&h!==p;){const y=Zp(m),g=m.getBoundingClientRect(),v=aa(m),b=g.left+(m.clientLeft+parseFloat(v.paddingLeft))*y.x,S=g.top+(m.clientTop+parseFloat(v.paddingTop))*y.y;u*=y.x,l*=y.y,c*=y.x,f*=y.y,u+=b,l+=S,p=Co(m),m=p.frameElement}}return Dm({width:c,height:f,x:u,y:l})}const NEe=[":popover-open",":modal"];function EX(e){return NEe.some(t=>{try{return e.matches(t)}catch{return!1}})}function kEe(e){let{elements:t,rect:n,offsetParent:r,strategy:i}=e;const s=i==="fixed",o=dc(r),a=t?EX(t.floating):!1;if(r===o||a&&s)return n;let u={scrollLeft:0,scrollTop:0},l=If(1);const c=If(0),f=Qu(r);if((f||!f&&!s)&&((xf(r)!=="body"||F_(o))&&(u=Ux(r)),Qu(r))){const d=ch(r);l=Zp(r),c.x=d.x+r.clientLeft,c.y=d.y+r.clientTop}return{width:n.width*l.x,height:n.height*l.y,x:n.x*l.x-u.scrollLeft*l.x+c.x,y:n.y*l.y-u.scrollTop*l.y+c.y}}function DEe(e){return Array.from(e.getClientRects())}function SX(e){return ch(dc(e)).left+Ux(e).scrollLeft}function $Ee(e){const t=dc(e),n=Ux(e),r=e.ownerDocument.body,i=es(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),s=es(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let o=-n.scrollLeft+SX(e);const a=-n.scrollTop;return aa(r).direction==="rtl"&&(o+=es(t.clientWidth,r.clientWidth)-i),{width:i,height:s,x:o,y:a}}function LEe(e,t){const n=Co(e),r=dc(e),i=n.visualViewport;let s=r.clientWidth,o=r.clientHeight,a=0,u=0;if(i){s=i.width,o=i.height;const l=F$();(!l||l&&t==="fixed")&&(a=i.offsetLeft,u=i.offsetTop)}return{width:s,height:o,x:a,y:u}}function MEe(e,t){const n=ch(e,!0,t==="fixed"),r=n.top+e.clientTop,i=n.left+e.clientLeft,s=Qu(e)?Zp(e):If(1),o=e.clientWidth*s.x,a=e.clientHeight*s.y,u=i*s.x,l=r*s.y;return{width:o,height:a,x:u,y:l}}function c9(e,t,n){let r;if(t==="viewport")r=LEe(e,n);else if(t==="document")r=$Ee(dc(e));else if(Gl(t))r=MEe(t,n);else{const i=wX(e);r={...t,x:t.x-i.x,y:t.y-i.y}}return Dm(r)}function TX(e,t){const n=$m(e);return n===t||!Gl(n)||jx(n)?!1:aa(n).position==="fixed"||TX(n,t)}function FEe(e,t){const n=t.get(e);if(n)return n;let r=Fl(e,[],!1).filter(a=>Gl(a)&&xf(a)!=="body"),i=null;const s=aa(e).position==="fixed";let o=s?$m(e):e;for(;Gl(o)&&!jx(o);){const a=aa(o),u=M$(o);!u&&a.position==="fixed"&&(i=null),(s?!u&&!i:!u&&a.position==="static"&&!!i&&["absolute","fixed"].includes(i.position)||F_(o)&&!u&&TX(e,o))?r=r.filter(c=>c!==o):i=a,o=$m(o)}return t.set(e,r),r}function BEe(e){let{element:t,boundary:n,rootBoundary:r,strategy:i}=e;const o=[...n==="clippingAncestors"?FEe(t,this._c):[].concat(n),r],a=o[0],u=o.reduce((l,c)=>{const f=c9(t,c,i);return l.top=es(f.top,l.top),l.right=qa(f.right,l.right),l.bottom=qa(f.bottom,l.bottom),l.left=es(f.left,l.left),l},c9(t,a,i));return{width:u.right-u.left,height:u.bottom-u.top,x:u.left,y:u.top}}function jEe(e){const{width:t,height:n}=bX(e);return{width:t,height:n}}function UEe(e,t,n){const r=Qu(t),i=dc(t),s=n==="fixed",o=ch(e,!0,s,t);let a={scrollLeft:0,scrollTop:0};const u=If(0);if(r||!r&&!s)if((xf(t)!=="body"||F_(i))&&(a=Ux(t)),r){const f=ch(t,!0,s,t);u.x=f.x+t.clientLeft,u.y=f.y+t.clientTop}else i&&(u.x=SX(i));const l=o.left+a.scrollLeft-u.x,c=o.top+a.scrollTop-u.y;return{x:l,y:c,width:o.width,height:o.height}}function f9(e,t){return!Qu(e)||aa(e).position==="fixed"?null:t?t(e):e.offsetParent}function IX(e,t){const n=Co(e);if(!Qu(e)||EX(e))return n;let r=f9(e,t);for(;r&&AEe(r)&&aa(r).position==="static";)r=f9(r,t);return r&&(xf(r)==="html"||xf(r)==="body"&&aa(r).position==="static"&&!M$(r))?n:r||PEe(e)||n}const VEe=async function(e){const t=this.getOffsetParent||IX,n=this.getDimensions;return{reference:UEe(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,...await n(e.floating)}}};function zEe(e){return aa(e).direction==="rtl"}const HEe={convertOffsetParentRelativeRectToViewportRelativeRect:kEe,getDocumentElement:dc,getClippingRect:BEe,getOffsetParent:IX,getElementRects:VEe,getClientRects:DEe,getDimensions:jEe,getScale:Zp,isElement:Gl,isRTL:zEe};function WEe(e,t){let n=null,r;const i=dc(e);function s(){var a;clearTimeout(r),(a=n)==null||a.disconnect(),n=null}function o(a,u){a===void 0&&(a=!1),u===void 0&&(u=1),s();const{left:l,top:c,width:f,height:d}=e.getBoundingClientRect();if(a||t(),!f||!d)return;const h=lb(c),p=lb(i.clientWidth-(l+f)),m=lb(i.clientHeight-(c+d)),y=lb(l),v={rootMargin:-h+"px "+-p+"px "+-m+"px "+-y+"px",threshold:es(0,qa(1,u))||1};let b=!0;function S(T){const E=T[0].intersectionRatio;if(E!==u){if(!b)return o();E?o(!1,E):r=setTimeout(()=>{o(!1,1e-7)},100)}b=!1}try{n=new IntersectionObserver(S,{...v,root:i.ownerDocument})}catch{n=new IntersectionObserver(S,v)}n.observe(e)}return o(!0),s}function qEe(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:i=!0,ancestorResize:s=!0,elementResize:o=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:u=!1}=r,l=B$(e),c=i||s?[...l?Fl(l):[],...Fl(t)]:[];c.forEach(g=>{i&&g.addEventListener("scroll",n,{passive:!0}),s&&g.addEventListener("resize",n)});const f=l&&a?WEe(l,n):null;let d=-1,h=null;o&&(h=new ResizeObserver(g=>{let[v]=g;v&&v.target===l&&h&&(h.unobserve(t),cancelAnimationFrame(d),d=requestAnimationFrame(()=>{var b;(b=h)==null||b.observe(t)})),n()}),l&&!u&&h.observe(l),h.observe(t));let p,m=u?ch(e):null;u&&y();function y(){const g=ch(e);m&&(g.x!==m.x||g.y!==m.y||g.width!==m.width||g.height!==m.height)&&n(),m=g,p=requestAnimationFrame(y)}return n(),()=>{var g;c.forEach(v=>{i&&v.removeEventListener("scroll",n),s&&v.removeEventListener("resize",n)}),f==null||f(),(g=h)==null||g.disconnect(),h=null,u&&cancelAnimationFrame(p)}}const j$=IEe,xX=wEe,GEe=CEe,d9=bEe,CX=SEe,YEe=xEe,KEe=(e,t,n)=>{const r=new Map,i={platform:HEe,...n},s={...i.platform,_c:r};return _Ee(e,t,{...i,platform:s})},AX=e=>{const{element:t,padding:n}=e;function r(i){return Object.prototype.hasOwnProperty.call(i,"current")}return{name:"arrow",options:e,fn(i){return r(t)?t.current!=null?d9({element:t.current,padding:n}).fn(i):{}:t?d9({element:t,padding:n}).fn(i):{}}}};var Cw=typeof document<"u"?w.useLayoutEffect:w.useEffect;function iS(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let n,r,i;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(n=e.length,n!=t.length)return!1;for(r=n;r--!==0;)if(!iS(e[r],t[r]))return!1;return!0}if(i=Object.keys(e),n=i.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!Object.prototype.hasOwnProperty.call(t,i[r]))return!1;for(r=n;r--!==0;){const s=i[r];if(!(s==="_owner"&&e.$$typeof)&&!iS(e[s],t[s]))return!1}return!0}return e!==e&&t!==t}function h9(e){const t=w.useRef(e);return Cw(()=>{t.current=e}),t}function QEe(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:i,whileElementsMounted:s,open:o}=e,[a,u]=w.useState({x:null,y:null,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[l,c]=w.useState(r);iS(l,r)||c(r);const f=w.useRef(null),d=w.useRef(null),h=w.useRef(a),p=h9(s),m=h9(i),[y,g]=w.useState(null),[v,b]=w.useState(null),S=w.useCallback(F=>{f.current!==F&&(f.current=F,g(F))},[]),T=w.useCallback(F=>{d.current!==F&&(d.current=F,b(F))},[]),E=w.useCallback(()=>{if(!f.current||!d.current)return;const F={placement:t,strategy:n,middleware:l};m.current&&(F.platform=m.current),KEe(f.current,d.current,F).then(L=>{const B={...L,isPositioned:!0};I.current&&!iS(h.current,B)&&(h.current=B,lc.flushSync(()=>{u(B)}))})},[l,t,n,m]);Cw(()=>{o===!1&&h.current.isPositioned&&(h.current.isPositioned=!1,u(F=>({...F,isPositioned:!1})))},[o]);const I=w.useRef(!1);Cw(()=>(I.current=!0,()=>{I.current=!1}),[]),Cw(()=>{if(y&&v){if(p.current)return p.current(y,v,E);E()}},[y,v,E,p]);const A=w.useMemo(()=>({reference:f,floating:d,setReference:S,setFloating:T}),[S,T]),R=w.useMemo(()=>({reference:y,floating:v}),[y,v]);return w.useMemo(()=>({...a,update:E,refs:A,elements:R,reference:S,floating:T}),[a,E,A,R,S,T])}var Lm=typeof document<"u"?w.useLayoutEffect:w.useEffect;let $P=!1,XEe=0;const p9=()=>"floating-ui-"+XEe++;function JEe(){const[e,t]=w.useState(()=>$P?p9():void 0);return Lm(()=>{e==null&&t(p9())},[]),w.useEffect(()=>{$P||($P=!0)},[]),e}const ZEe=Zy.useId,m9=ZEe||JEe;function eSe(){const e=new Map;return{emit(t,n){var r;(r=e.get(t))==null||r.forEach(i=>i(n))},on(t,n){e.set(t,[...e.get(t)||[],n])},off(t,n){e.set(t,(e.get(t)||[]).filter(r=>r!==n))}}}const tSe=w.createContext(null),nSe=w.createContext(null),PX=()=>{var e;return((e=w.useContext(tSe))==null?void 0:e.id)||null},U$=()=>w.useContext(nSe);function Kc(e){return(e==null?void 0:e.ownerDocument)||document}function rSe(){const e=navigator.userAgentData;return e!=null&&e.platform?e.platform:navigator.platform}function iSe(){const e=navigator.userAgentData;return e&&Array.isArray(e.brands)?e.brands.map(t=>{let{brand:n,version:r}=t;return n+"/"+r}).join(" "):navigator.userAgent}function V$(e){return Kc(e).defaultView||window}function Pu(e){return e?e instanceof V$(e).Element:!1}function OX(e){return e?e instanceof V$(e).HTMLElement:!1}function sSe(e){if(typeof ShadowRoot>"u")return!1;const t=V$(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function oSe(e){if(e.mozInputSource===0&&e.isTrusted)return!0;const t=/Android/i;return(t.test(rSe())||t.test(iSe()))&&e.pointerType?e.type==="click"&&e.buttons===1:e.detail===0&&!e.pointerType}function aSe(e){return e.width===0&&e.height===0||e.width===1&&e.height===1&&e.pressure===0&&e.detail===0&&e.pointerType!=="mouse"||e.width<1&&e.height<1&&e.pressure===0&&e.detail===0}function RX(e,t){const n=["mouse","pen"];return t||n.push("",void 0),n.includes(e)}function g9(e){const t=w.useRef(e);return Lm(()=>{t.current=e}),t}const y9="data-floating-ui-safe-polygon";function Aw(e,t,n){return n&&!RX(n)?0:typeof e=="number"?e:e==null?void 0:e[t]}const uSe=function(e,t){let{enabled:n=!0,delay:r=0,handleClose:i=null,mouseOnly:s=!1,restMs:o=0,move:a=!0}=t===void 0?{}:t;const{open:u,onOpenChange:l,dataRef:c,events:f,elements:{domReference:d,floating:h},refs:p}=e,m=U$(),y=PX(),g=g9(i),v=g9(r),b=w.useRef(),S=w.useRef(),T=w.useRef(),E=w.useRef(),I=w.useRef(!0),A=w.useRef(!1),R=w.useRef(()=>{}),F=w.useCallback(()=>{var V;const re=(V=c.current.openEvent)==null?void 0:V.type;return(re==null?void 0:re.includes("mouse"))&&re!=="mousedown"},[c]);w.useEffect(()=>{if(!n)return;function V(){clearTimeout(S.current),clearTimeout(E.current),I.current=!0}return f.on("dismiss",V),()=>{f.off("dismiss",V)}},[n,f]),w.useEffect(()=>{if(!n||!g.current||!u)return;function V(){F()&&l(!1)}const re=Kc(h).documentElement;return re.addEventListener("mouseleave",V),()=>{re.removeEventListener("mouseleave",V)}},[h,u,l,n,g,c,F]);const L=w.useCallback(function(V){V===void 0&&(V=!0);const re=Aw(v.current,"close",b.current);re&&!T.current?(clearTimeout(S.current),S.current=setTimeout(()=>l(!1),re)):V&&(clearTimeout(S.current),l(!1))},[v,l]),B=w.useCallback(()=>{R.current(),T.current=void 0},[]),J=w.useCallback(()=>{if(A.current){const V=Kc(p.floating.current).body;V.style.pointerEvents="",V.removeAttribute(y9),A.current=!1}},[p]);return w.useEffect(()=>{if(!n)return;function V(){return c.current.openEvent?["click","mousedown"].includes(c.current.openEvent.type):!1}function re(ee){if(clearTimeout(S.current),I.current=!1,s&&!RX(b.current)||o>0&&Aw(v.current,"open")===0)return;c.current.openEvent=ee;const ue=Aw(v.current,"open",b.current);ue?S.current=setTimeout(()=>{l(!0)},ue):l(!0)}function oe(ee){if(V())return;R.current();const ue=Kc(h);if(clearTimeout(E.current),g.current){u||clearTimeout(S.current),T.current=g.current({...e,tree:m,x:ee.clientX,y:ee.clientY,onClose(){J(),B(),L()}});const P=T.current;ue.addEventListener("mousemove",P),R.current=()=>{ue.removeEventListener("mousemove",P)};return}L()}function ae(ee){V()||g.current==null||g.current({...e,tree:m,x:ee.clientX,y:ee.clientY,onClose(){J(),B(),L()}})(ee)}if(Pu(d)){const ee=d;return u&&ee.addEventListener("mouseleave",ae),h==null||h.addEventListener("mouseleave",ae),a&&ee.addEventListener("mousemove",re,{once:!0}),ee.addEventListener("mouseenter",re),ee.addEventListener("mouseleave",oe),()=>{u&&ee.removeEventListener("mouseleave",ae),h==null||h.removeEventListener("mouseleave",ae),a&&ee.removeEventListener("mousemove",re),ee.removeEventListener("mouseenter",re),ee.removeEventListener("mouseleave",oe)}}},[d,h,n,e,s,o,a,L,B,J,l,u,m,v,g,c]),Lm(()=>{var V;if(n&&u&&(V=g.current)!=null&&V.__options.blockPointerEvents&&F()){const ae=Kc(h).body;if(ae.setAttribute(y9,""),ae.style.pointerEvents="none",A.current=!0,Pu(d)&&h){var re,oe;const ee=d,ue=m==null||(re=m.nodesRef.current.find(P=>P.id===y))==null||(oe=re.context)==null?void 0:oe.elements.floating;return ue&&(ue.style.pointerEvents=""),ee.style.pointerEvents="auto",h.style.pointerEvents="auto",()=>{ee.style.pointerEvents="",h.style.pointerEvents=""}}}},[n,u,y,h,d,m,g,c,F]),Lm(()=>{u||(b.current=void 0,B(),J())},[u,B,J]),w.useEffect(()=>()=>{B(),clearTimeout(S.current),clearTimeout(E.current),J()},[n,B,J]),w.useMemo(()=>{if(!n)return{};function V(re){b.current=re.pointerType}return{reference:{onPointerDown:V,onPointerEnter:V,onMouseMove(){u||o===0||(clearTimeout(E.current),E.current=setTimeout(()=>{I.current||l(!0)},o))}},floating:{onMouseEnter(){clearTimeout(S.current)},onMouseLeave(){f.emit("dismiss",{type:"mouseLeave",data:{returnFocus:!1}}),L(!1)}}}},[f,n,o,u,l,L])},NX=w.createContext({delay:0,initialDelay:0,timeoutMs:0,currentId:null,setCurrentId:()=>{},setState:()=>{},isInstantPhase:!1}),kX=()=>w.useContext(NX),lSe=e=>{let{children:t,delay:n,timeoutMs:r=0}=e;const[i,s]=w.useReducer((u,l)=>({...u,...l}),{delay:n,timeoutMs:r,initialDelay:n,currentId:null,isInstantPhase:!1}),o=w.useRef(null),a=w.useCallback(u=>{s({currentId:u})},[]);return Lm(()=>{i.currentId?o.current===null?o.current=i.currentId:s({isInstantPhase:!0}):(s({isInstantPhase:!1}),o.current=null)},[i.currentId]),w.createElement(NX.Provider,{value:w.useMemo(()=>({...i,setState:s,setCurrentId:a}),[i,s,a])},t)},cSe=(e,t)=>{let{open:n,onOpenChange:r}=e,{id:i}=t;const{currentId:s,setCurrentId:o,initialDelay:a,setState:u,timeoutMs:l}=kX();w.useEffect(()=>{s&&(u({delay:{open:1,close:Aw(a,"close")}}),s!==i&&r(!1))},[i,r,u,s,a]),w.useEffect(()=>{function c(){r(!1),u({delay:a,currentId:null})}if(!n&&s===i)if(l){const f=window.setTimeout(c,l);return()=>{clearTimeout(f)}}else c()},[n,u,s,i,r,a,l]),w.useEffect(()=>{n&&o(i)},[n,o,i])};function fSe(e){let t=e.activeElement;for(;((n=t)==null||(r=n.shadowRoot)==null?void 0:r.activeElement)!=null;){var n,r;t=t.shadowRoot.activeElement}return t}function v9(e,t){if(!e||!t)return!1;const n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&sSe(n)){let r=t;do{if(r&&e===r)return!0;r=r.parentNode||r.host}while(r)}return!1}function LP(e,t){let n=e.filter(i=>{var s;return i.parentId===t&&((s=i.context)==null?void 0:s.open)})||[],r=n;for(;r.length;)r=e.filter(i=>{var s;return(s=r)==null?void 0:s.some(o=>{var a;return i.parentId===o.id&&((a=i.context)==null?void 0:a.open)})})||[],n=n.concat(r);return n}function dSe(e){return"composedPath"in e?e.composedPath()[0]:e.target}const hSe=Zy.useInsertionEffect,pSe=hSe||(e=>e());function DX(e){const t=w.useRef(()=>{});return pSe(()=>{t.current=e}),w.useCallback(function(){for(var n=arguments.length,r=new Array(n),i=0;i!1),T=typeof d=="function"?S:d,E=w.useRef(!1),{escapeKeyBubbles:I,outsidePressBubbles:A}=ySe(g);return w.useEffect(()=>{if(!n||!c)return;l.current.__escapeKeyBubbles=I,l.current.__outsidePressBubbles=A;function R(V){if(V.key==="Escape"){const re=v?LP(v.nodesRef.current,s):[];if(re.length>0){let oe=!0;if(re.forEach(ae=>{var ee;if((ee=ae.context)!=null&&ee.open&&!ae.context.dataRef.current.__escapeKeyBubbles){oe=!1;return}}),!oe)return}i.emit("dismiss",{type:"escapeKey",data:{returnFocus:{preventScroll:!1}}}),r(!1)}}function F(V){const re=E.current;if(E.current=!1,re||typeof T=="function"&&!T(V))return;const oe=dSe(V);if(OX(oe)&&u){const ue=u.ownerDocument.defaultView||window,P=oe.scrollWidth>oe.clientWidth,W=oe.scrollHeight>oe.clientHeight;let Q=W&&V.offsetX>oe.clientWidth;if(W&&ue.getComputedStyle(oe).direction==="rtl"&&(Q=V.offsetX<=oe.offsetWidth-oe.clientWidth),Q||P&&V.offsetY>oe.clientHeight)return}const ae=v&&LP(v.nodesRef.current,s).some(ue=>{var P;return Pw(V,(P=ue.context)==null?void 0:P.elements.floating)});if(Pw(V,u)||Pw(V,a)||ae)return;const ee=v?LP(v.nodesRef.current,s):[];if(ee.length>0){let ue=!0;if(ee.forEach(P=>{var W;if((W=P.context)!=null&&W.open&&!P.context.dataRef.current.__outsidePressBubbles){ue=!1;return}}),!ue)return}i.emit("dismiss",{type:"outsidePress",data:{returnFocus:b?{preventScroll:!0}:oSe(V)||aSe(V)}}),r(!1)}function L(){r(!1)}const B=Kc(u);f&&B.addEventListener("keydown",R),T&&B.addEventListener(h,F);let J=[];return y&&(Pu(a)&&(J=Fl(a)),Pu(u)&&(J=J.concat(Fl(u))),!Pu(o)&&o&&o.contextElement&&(J=J.concat(Fl(o.contextElement)))),J=J.filter(V=>{var re;return V!==((re=B.defaultView)==null?void 0:re.visualViewport)}),J.forEach(V=>{V.addEventListener("scroll",L,{passive:!0})}),()=>{f&&B.removeEventListener("keydown",R),T&&B.removeEventListener(h,F),J.forEach(V=>{V.removeEventListener("scroll",L)})}},[l,u,a,o,f,T,h,i,v,s,n,r,y,c,I,A,b]),w.useEffect(()=>{E.current=!1},[T,h]),w.useMemo(()=>c?{reference:{[mSe[m]]:()=>{p&&(i.emit("dismiss",{type:"referencePress",data:{returnFocus:!1}}),r(!1))}},floating:{[gSe[h]]:()=>{E.current=!0}}}:{},[c,i,p,h,m,r])},_Se=function(e,t){let{open:n,onOpenChange:r,dataRef:i,events:s,refs:o,elements:{floating:a,domReference:u}}=e,{enabled:l=!0,keyboardOnly:c=!0}=t===void 0?{}:t;const f=w.useRef(""),d=w.useRef(!1),h=w.useRef();return w.useEffect(()=>{if(!l)return;const m=Kc(a).defaultView||window;function y(){!n&&OX(u)&&u===fSe(Kc(u))&&(d.current=!0)}return m.addEventListener("blur",y),()=>{m.removeEventListener("blur",y)}},[a,u,n,l]),w.useEffect(()=>{if(!l)return;function p(m){(m.type==="referencePress"||m.type==="escapeKey")&&(d.current=!0)}return s.on("dismiss",p),()=>{s.off("dismiss",p)}},[s,l]),w.useEffect(()=>()=>{clearTimeout(h.current)},[]),w.useMemo(()=>l?{reference:{onPointerDown(p){let{pointerType:m}=p;f.current=m,d.current=!!(m&&c)},onMouseLeave(){d.current=!1},onFocus(p){var m;d.current||p.type==="focus"&&((m=i.current.openEvent)==null?void 0:m.type)==="mousedown"&&i.current.openEvent&&Pw(i.current.openEvent,u)||(i.current.openEvent=p.nativeEvent,r(!0))},onBlur(p){d.current=!1;const m=p.relatedTarget,y=Pu(m)&&m.hasAttribute("data-floating-ui-focus-guard")&&m.getAttribute("data-type")==="outside";h.current=setTimeout(()=>{v9(o.floating.current,m)||v9(u,m)||y||r(!1)})}}}:{},[l,c,u,o,i,r])},bSe=function(e,t){let{open:n}=e,{enabled:r=!0,role:i="dialog"}=t===void 0?{}:t;const s=m9(),o=m9();return w.useMemo(()=>{const a={id:s,role:i};return r?i==="tooltip"?{reference:{"aria-describedby":n?s:void 0},floating:a}:{reference:{"aria-expanded":n?"true":"false","aria-haspopup":i==="alertdialog"?"dialog":i,"aria-controls":n?s:void 0,...i==="listbox"&&{role:"combobox"},...i==="menu"&&{id:o}},floating:{...a,...i==="menu"&&{"aria-labelledby":o}}}:{}},[r,i,n,s,o])};function z$(e){e===void 0&&(e={});const{open:t=!1,onOpenChange:n,nodeId:r}=e,i=QEe(e),s=U$(),o=w.useRef(null),a=w.useRef({}),u=w.useState(()=>eSe())[0],[l,c]=w.useState(null),f=w.useCallback(g=>{const v=Pu(g)?{getBoundingClientRect:()=>g.getBoundingClientRect(),contextElement:g}:g;i.refs.setReference(v)},[i.refs]),d=w.useCallback(g=>{(Pu(g)||g===null)&&(o.current=g,c(g)),(Pu(i.refs.reference.current)||i.refs.reference.current===null||g!==null&&!Pu(g))&&i.refs.setReference(g)},[i.refs]),h=w.useMemo(()=>({...i.refs,setReference:d,setPositionReference:f,domReference:o}),[i.refs,d,f]),p=w.useMemo(()=>({...i.elements,domReference:l}),[i.elements,l]),m=DX(n),y=w.useMemo(()=>({...i,refs:h,elements:p,dataRef:a,nodeId:r,events:u,open:t,onOpenChange:m}),[i,r,u,t,m,h,p]);return Lm(()=>{const g=s==null?void 0:s.nodesRef.current.find(v=>v.id===r);g&&(g.context=y)}),w.useMemo(()=>({...i,context:y,refs:h,reference:d,positionReference:f}),[i,h,y,d,f])}function MP(e,t,n){const r=new Map;return{...n==="floating"&&{tabIndex:-1},...e,...t.map(i=>i?i[n]:null).concat(e).reduce((i,s)=>(s&&Object.entries(s).forEach(o=>{let[a,u]=o;if(a.indexOf("on")===0){if(r.has(a)||r.set(a,[]),typeof u=="function"){var l;(l=r.get(a))==null||l.push(u),i[a]=function(){for(var c,f=arguments.length,d=new Array(f),h=0;hp(...d))}}}else i[a]=u}),i),{})}}const wSe=function(e){e===void 0&&(e=[]);const t=e,n=w.useCallback(s=>MP(s,e,"reference"),t),r=w.useCallback(s=>MP(s,e,"floating"),t),i=w.useCallback(s=>MP(s,e,"item"),e.map(s=>s==null?void 0:s.item));return w.useMemo(()=>({getReferenceProps:n,getFloatingProps:r,getItemProps:i}),[n,r,i])};function $X({opened:e,floating:t,positionDependencies:n}){const[r,i]=w.useState(0);w.useEffect(()=>{if(t.refs.reference.current&&t.refs.floating.current)return qEe(t.refs.reference.current,t.refs.floating.current,t.update)},[t.refs.reference.current,t.refs.floating.current,e,r]),Js(()=>{t.update()},n),Js(()=>{i(s=>s+1)},[e])}function ESe(e){const t=[yX(e.offset)];return e.middlewares.shift&&t.push(j$({limiter:YEe()})),e.middlewares.flip&&t.push(xX()),e.middlewares.inline&&t.push(CX()),t.push(AX({element:e.arrowRef,padding:e.arrowOffset})),t}function SSe(e){const[t,n]=oa({value:e.opened,defaultValue:e.defaultOpened,finalValue:!1,onChange:e.onChange}),r=()=>{var o;(o=e.onClose)==null||o.call(e),n(!1)},i=()=>{var o,a;t?((o=e.onClose)==null||o.call(e),n(!1)):((a=e.onOpen)==null||a.call(e),n(!0))},s=z$({placement:e.position,middleware:[...ESe(e),...e.width==="target"?[GEe({apply({rects:o}){var a,u;Object.assign((u=(a=s.refs.floating.current)==null?void 0:a.style)!=null?u:{},{width:`${o.reference.width}px`})}})]:[]]});return $X({opened:e.opened,positionDependencies:e.positionDependencies,floating:s}),Js(()=>{var o;(o=e.onPositionChange)==null||o.call(e,s.placement)},[s.placement]),{floating:s,controlled:typeof e.opened=="boolean",opened:t,onClose:r,onToggle:i}}const LX={context:"Popover component was not found in the tree",children:"Popover.Target component children should be an element or a component that accepts ref, fragments, strings, numbers and other primitive values are not supported"},[TSe,MX]=N_(LX.context);var ISe=Object.defineProperty,xSe=Object.defineProperties,CSe=Object.getOwnPropertyDescriptors,sS=Object.getOwnPropertySymbols,FX=Object.prototype.hasOwnProperty,BX=Object.prototype.propertyIsEnumerable,_9=(e,t,n)=>t in e?ISe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,cb=(e,t)=>{for(var n in t||(t={}))FX.call(t,n)&&_9(e,n,t[n]);if(sS)for(var n of sS(t))BX.call(t,n)&&_9(e,n,t[n]);return e},ASe=(e,t)=>xSe(e,CSe(t)),PSe=(e,t)=>{var n={};for(var r in e)FX.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&sS)for(var r of sS(e))t.indexOf(r)<0&&BX.call(e,r)&&(n[r]=e[r]);return n};const OSe={refProp:"ref",popupType:"dialog"},jX=w.forwardRef((e,t)=>{const n=Ve("PopoverTarget",OSe,e),{children:r,refProp:i,popupType:s}=n,o=PSe(n,["children","refProp","popupType"]);if(!_g(r))throw new Error(LX.children);const a=o,u=MX(),l=fa(u.reference,r.ref,t),c=u.withRoles?{"aria-haspopup":s,"aria-expanded":u.opened,"aria-controls":u.getDropdownId(),id:u.getTargetId()}:{};return w.cloneElement(r,cb(ASe(cb(cb(cb({},a),c),u.targetProps),{className:cK(u.targetProps.className,a.className,r.props.className),[i]:l}),u.controlled?null:{onClick:u.onToggle}))});jX.displayName="@mantine/core/PopoverTarget";var RSe=lt((e,{radius:t,shadow:n})=>({dropdown:{position:"absolute",backgroundColor:e.white,background:e.colorScheme==="dark"?e.colors.dark[6]:e.white,border:`1px solid ${e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[2]}`,padding:`${e.spacing.sm}px ${e.spacing.md}px`,boxShadow:e.shadows[n]||n||"none",borderRadius:e.fn.radius(t),"&:focus":{outline:0}},arrow:{backgroundColor:"inherit",border:`1px solid ${e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[2]}`,zIndex:1}}));const NSe=RSe;var kSe=Object.defineProperty,b9=Object.getOwnPropertySymbols,DSe=Object.prototype.hasOwnProperty,$Se=Object.prototype.propertyIsEnumerable,w9=(e,t,n)=>t in e?kSe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Xh=(e,t)=>{for(var n in t||(t={}))DSe.call(t,n)&&w9(e,n,t[n]);if(b9)for(var n of b9(t))$Se.call(t,n)&&w9(e,n,t[n]);return e};const E9={entering:"in",entered:"in",exiting:"out",exited:"out","pre-exiting":"out","pre-entering":"out"};function UX({transition:e,state:t,duration:n,timingFunction:r}){const i={transitionDuration:`${n}ms`,transitionTimingFunction:r};return typeof e=="string"?e in nb?Xh(Xh(Xh({transitionProperty:nb[e].transitionProperty},i),nb[e].common),nb[e][E9[t]]):null:Xh(Xh(Xh({transitionProperty:e.transitionProperty},i),e.common),e[E9[t]])}function VX({duration:e,exitDuration:t,timingFunction:n,mounted:r,onEnter:i,onExit:s,onEntered:o,onExited:a}){const u=ji(),l=Rx(),c=u.respectReducedMotion?l:!1,[f,d]=w.useState(r?"entered":"exited");let h=c?0:e;const p=w.useRef(-1),m=y=>{const g=y?i:s,v=y?o:a;if(d(y?"pre-entering":"pre-exiting"),window.clearTimeout(p.current),h=c?0:y?e:t,h===0)typeof g=="function"&&g(),typeof v=="function"&&v(),d(y?"entered":"exited");else{const b=window.setTimeout(()=>{typeof g=="function"&&g(),d(y?"entering":"exiting")},10);p.current=window.setTimeout(()=>{window.clearTimeout(b),typeof v=="function"&&v(),d(y?"entered":"exited")},h)}};return Js(()=>{m(r)},[r]),w.useEffect(()=>()=>window.clearTimeout(p.current),[]),{transitionDuration:h,transitionStatus:f,transitionTimingFunction:n||u.transitionTimingFunction}}function Vx({transition:e,duration:t=250,exitDuration:n=t,mounted:r,children:i,timingFunction:s,onExit:o,onEntered:a,onEnter:u,onExited:l}){const{transitionDuration:c,transitionStatus:f,transitionTimingFunction:d}=VX({mounted:r,exitDuration:n,duration:t,timingFunction:s,onExit:o,onEntered:a,onEnter:u,onExited:l});return c===0?r?N.createElement(N.Fragment,null,i({})):null:f==="exited"?null:N.createElement(N.Fragment,null,i(UX({transition:e,duration:c,state:f,timingFunction:d})))}Vx.displayName="@mantine/core/Transition";function zX({children:e,active:t=!0,refProp:n="ref"}){const r=jK(t),i=fa(r,e==null?void 0:e.ref);return _g(e)?w.cloneElement(e,{[n]:i}):e}zX.displayName="@mantine/core/FocusTrap";var LSe=Object.defineProperty,MSe=Object.defineProperties,FSe=Object.getOwnPropertyDescriptors,S9=Object.getOwnPropertySymbols,BSe=Object.prototype.hasOwnProperty,jSe=Object.prototype.propertyIsEnumerable,T9=(e,t,n)=>t in e?LSe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,bc=(e,t)=>{for(var n in t||(t={}))BSe.call(t,n)&&T9(e,n,t[n]);if(S9)for(var n of S9(t))jSe.call(t,n)&&T9(e,n,t[n]);return e},fb=(e,t)=>MSe(e,FSe(t));function I9(e,t,n,r){return e==="center"||r==="center"?{top:t}:e==="end"?{bottom:n}:e==="start"?{top:n}:{}}function x9(e,t,n,r,i){return e==="center"||r==="center"?{left:t}:e==="end"?{[i==="ltr"?"right":"left"]:n}:e==="start"?{[i==="ltr"?"left":"right"]:n}:{}}const USe={bottom:"borderTopLeftRadius",left:"borderTopRightRadius",right:"borderBottomLeftRadius",top:"borderBottomRightRadius"};function VSe({position:e,withBorder:t,arrowSize:n,arrowOffset:r,arrowRadius:i,arrowPosition:s,arrowX:o,arrowY:a,dir:u}){const[l,c="center"]=e.split("-"),f={width:n,height:n,transform:"rotate(45deg)",position:"absolute",[USe[l]]:i},d=t?-n/2-1:-n/2;return l==="left"?fb(bc(bc({},f),I9(c,a,r,s)),{right:d,borderLeft:0,borderBottom:0}):l==="right"?fb(bc(bc({},f),I9(c,a,r,s)),{left:d,borderRight:0,borderTop:0}):l==="top"?fb(bc(bc({},f),x9(c,o,r,s,u)),{bottom:d,borderTop:0,borderLeft:0}):l==="bottom"?fb(bc(bc({},f),x9(c,o,r,s,u)),{top:d,borderBottom:0,borderRight:0}):{}}var zSe=Object.defineProperty,HSe=Object.defineProperties,WSe=Object.getOwnPropertyDescriptors,oS=Object.getOwnPropertySymbols,HX=Object.prototype.hasOwnProperty,WX=Object.prototype.propertyIsEnumerable,C9=(e,t,n)=>t in e?zSe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,qSe=(e,t)=>{for(var n in t||(t={}))HX.call(t,n)&&C9(e,n,t[n]);if(oS)for(var n of oS(t))WX.call(t,n)&&C9(e,n,t[n]);return e},GSe=(e,t)=>HSe(e,WSe(t)),YSe=(e,t)=>{var n={};for(var r in e)HX.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&oS)for(var r of oS(e))t.indexOf(r)<0&&WX.call(e,r)&&(n[r]=e[r]);return n};const H$=w.forwardRef((e,t)=>{var n=e,{withBorder:r,position:i,arrowSize:s,arrowOffset:o,arrowRadius:a,arrowPosition:u,visible:l,arrowX:c,arrowY:f}=n,d=YSe(n,["withBorder","position","arrowSize","arrowOffset","arrowRadius","arrowPosition","visible","arrowX","arrowY"]);const h=ji();return l?N.createElement("div",GSe(qSe({},d),{ref:t,style:VSe({withBorder:r,position:i,arrowSize:s,arrowOffset:o,arrowRadius:a,arrowPosition:u,dir:h.dir,arrowX:c,arrowY:f})})):null});H$.displayName="@mantine/core/FloatingArrow";var KSe=Object.defineProperty,QSe=Object.defineProperties,XSe=Object.getOwnPropertyDescriptors,aS=Object.getOwnPropertySymbols,qX=Object.prototype.hasOwnProperty,GX=Object.prototype.propertyIsEnumerable,A9=(e,t,n)=>t in e?KSe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,db=(e,t)=>{for(var n in t||(t={}))qX.call(t,n)&&A9(e,n,t[n]);if(aS)for(var n of aS(t))GX.call(t,n)&&A9(e,n,t[n]);return e},P9=(e,t)=>QSe(e,XSe(t)),JSe=(e,t)=>{var n={};for(var r in e)qX.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&aS)for(var r of aS(e))t.indexOf(r)<0&&GX.call(e,r)&&(n[r]=e[r]);return n};const ZSe={};function YX(e){const t=Ve("PopoverDropdown",ZSe,e),{style:n,className:r,children:i,onKeyDownCapture:s}=t,o=JSe(t,["style","className","children","onKeyDownCapture"]),a=MX(),{classes:u,cx:l}=NSe({radius:a.radius,shadow:a.shadow},{name:a.__staticSelector,classNames:a.classNames,styles:a.styles,unstyled:a.unstyled}),c=LK({opened:a.opened,shouldReturnFocus:a.returnFocus}),f=a.withRoles?{"aria-labelledby":a.getTargetId(),id:a.getDropdownId(),role:"dialog"}:{};return a.disabled?null:N.createElement($_,{withinPortal:a.withinPortal},N.createElement(Vx,{mounted:a.opened,transition:a.transition,duration:a.transitionDuration,exitDuration:typeof a.exitTransitionDuration=="number"?a.exitTransitionDuration:a.transitionDuration},d=>{var h,p;return N.createElement(zX,{active:a.trapFocus},N.createElement(it,db(P9(db({},f),{tabIndex:-1,key:a.placement,ref:a.floating,style:P9(db(db({},n),d),{zIndex:a.zIndex,top:(h=a.y)!=null?h:0,left:(p=a.x)!=null?p:0,width:a.width==="target"?void 0:a.width}),className:l(u.dropdown,r),onKeyDownCapture:T0e(a.onClose,{active:a.closeOnEscape,onTrigger:c,onKeyDown:s}),"data-position":a.placement}),o),i,N.createElement(H$,{ref:a.arrowRef,arrowX:a.arrowX,arrowY:a.arrowY,visible:a.withArrow,withBorder:!0,position:a.placement,arrowSize:a.arrowSize,arrowRadius:a.arrowRadius,arrowOffset:a.arrowOffset,arrowPosition:a.arrowPosition,className:u.arrow})))}))}YX.displayName="@mantine/core/PopoverDropdown";function KX(e,t){if(e==="rtl"&&(t.includes("right")||t.includes("left"))){const[n,r]=t.split("-"),i=n==="right"?"left":"right";return r===void 0?i:`${i}-${r}`}return t}var O9=Object.getOwnPropertySymbols,eTe=Object.prototype.hasOwnProperty,tTe=Object.prototype.propertyIsEnumerable,nTe=(e,t)=>{var n={};for(var r in e)eTe.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&O9)for(var r of O9(e))t.indexOf(r)<0&&tTe.call(e,r)&&(n[r]=e[r]);return n};const rTe={position:"bottom",offset:8,positionDependencies:[],transition:"fade",transitionDuration:150,middlewares:{flip:!0,shift:!0,inline:!1},arrowSize:7,arrowOffset:5,arrowRadius:0,arrowPosition:"side",closeOnClickOutside:!0,withinPortal:!1,closeOnEscape:!0,trapFocus:!1,withRoles:!0,returnFocus:!1,clickOutsideEvents:["mousedown","touchstart"],zIndex:cc("popover"),__staticSelector:"Popover",width:"max-content"};function yi(e){var t,n,r,i,s,o;const a=w.useRef(null),u=Ve("Popover",rTe,e),{children:l,position:c,offset:f,onPositionChange:d,positionDependencies:h,opened:p,transition:m,transitionDuration:y,width:g,middlewares:v,withArrow:b,arrowSize:S,arrowOffset:T,arrowRadius:E,arrowPosition:I,unstyled:A,classNames:R,styles:F,closeOnClickOutside:L,withinPortal:B,closeOnEscape:J,clickOutsideEvents:V,trapFocus:re,onClose:oe,onOpen:ae,onChange:ee,zIndex:ue,radius:P,shadow:W,id:Q,defaultOpened:x,exitTransitionDuration:O,__staticSelector:$,withRoles:q,disabled:ce,returnFocus:fe}=u,de=nTe(u,["children","position","offset","onPositionChange","positionDependencies","opened","transition","transitionDuration","width","middlewares","withArrow","arrowSize","arrowOffset","arrowRadius","arrowPosition","unstyled","classNames","styles","closeOnClickOutside","withinPortal","closeOnEscape","clickOutsideEvents","trapFocus","onClose","onOpen","onChange","zIndex","radius","shadow","id","defaultOpened","exitTransitionDuration","__staticSelector","withRoles","disabled","returnFocus"]),[ve,Ee]=w.useState(null),[ge,nt]=w.useState(null),Je=tu(Q),yt=ji(),ke=SSe({middlewares:v,width:g,position:KX(yt.dir,c),offset:f+(b?S/2:0),arrowRef:a,arrowOffset:T,onPositionChange:d,positionDependencies:h,opened:p,defaultOpened:x,onChange:ee,onOpen:ae,onClose:oe});Tve(()=>L&&ke.onClose(),V,[ve,ge]);const at=w.useCallback(cn=>{Ee(cn),ke.floating.reference(cn)},[ke.floating.reference]),St=w.useCallback(cn=>{nt(cn),ke.floating.floating(cn)},[ke.floating.floating]);return N.createElement(TSe,{value:{returnFocus:fe,disabled:ce,controlled:ke.controlled,reference:at,floating:St,x:ke.floating.x,y:ke.floating.y,arrowX:(r=(n=(t=ke.floating)==null?void 0:t.middlewareData)==null?void 0:n.arrow)==null?void 0:r.x,arrowY:(o=(s=(i=ke.floating)==null?void 0:i.middlewareData)==null?void 0:s.arrow)==null?void 0:o.y,opened:ke.opened,arrowRef:a,transition:m,transitionDuration:y,exitTransitionDuration:O,width:g,withArrow:b,arrowSize:S,arrowOffset:T,arrowRadius:E,arrowPosition:I,placement:ke.floating.placement,trapFocus:re,withinPortal:B,zIndex:ue,radius:P,shadow:W,closeOnEscape:J,onClose:ke.onClose,onToggle:ke.onToggle,getTargetId:()=>`${Je}-target`,getDropdownId:()=>`${Je}-dropdown`,withRoles:q,targetProps:de,__staticSelector:$,classNames:R,styles:F,unstyled:A}},l)}yi.Target=jX;yi.Dropdown=YX;yi.displayName="@mantine/core/Popover";var iTe=Object.defineProperty,uS=Object.getOwnPropertySymbols,QX=Object.prototype.hasOwnProperty,XX=Object.prototype.propertyIsEnumerable,R9=(e,t,n)=>t in e?iTe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,sTe=(e,t)=>{for(var n in t||(t={}))QX.call(t,n)&&R9(e,n,t[n]);if(uS)for(var n of uS(t))XX.call(t,n)&&R9(e,n,t[n]);return e},oTe=(e,t)=>{var n={};for(var r in e)QX.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&uS)for(var r of uS(e))t.indexOf(r)<0&&XX.call(e,r)&&(n[r]=e[r]);return n};function aTe(e){var t=e,{children:n,component:r="div",maxHeight:i=220,direction:s="column",id:o,innerRef:a,__staticSelector:u,styles:l,classNames:c,unstyled:f}=t,d=oTe(t,["children","component","maxHeight","direction","id","innerRef","__staticSelector","styles","classNames","unstyled"]);const{classes:h}=fEe(null,{name:u,styles:l,classNames:c,unstyled:f});return N.createElement(yi.Dropdown,sTe({p:0,onMouseDown:p=>p.preventDefault()},d),N.createElement("div",{style:{maxHeight:i,display:"flex"}},N.createElement(it,{component:r||"div",id:`${o}-items`,"aria-labelledby":`${o}-label`,role:"listbox",onMouseDown:p=>p.preventDefault(),style:{flex:1,overflowY:r!==Bx?"auto":void 0},"data-combobox-popover":!0,ref:a},N.createElement("div",{className:h.itemsWrapper,style:{flexDirection:s}},n))))}function hf({opened:e,transition:t="fade",transitionDuration:n=0,shadow:r,withinPortal:i,children:s,__staticSelector:o,onDirectionChange:a,switchDirectionOnFlip:u,zIndex:l,dropdownPosition:c,positionDependencies:f=[],classNames:d,styles:h,unstyled:p,readOnly:m}){return N.createElement(yi,{unstyled:p,classNames:d,styles:h,width:"target",withRoles:!1,opened:e,middlewares:{flip:c==="flip",shift:!1},position:c==="flip"?"bottom":c,positionDependencies:f,zIndex:l,__staticSelector:o,withinPortal:i,transition:t,transitionDuration:n,shadow:r,disabled:m,onPositionChange:y=>u&&(a==null?void 0:a(y==="top"?"column-reverse":"column"))},s)}hf.Target=yi.Target;hf.Dropdown=aTe;var uTe=Object.defineProperty,lTe=Object.defineProperties,cTe=Object.getOwnPropertyDescriptors,lS=Object.getOwnPropertySymbols,JX=Object.prototype.hasOwnProperty,ZX=Object.prototype.propertyIsEnumerable,N9=(e,t,n)=>t in e?uTe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,hb=(e,t)=>{for(var n in t||(t={}))JX.call(t,n)&&N9(e,n,t[n]);if(lS)for(var n of lS(t))ZX.call(t,n)&&N9(e,n,t[n]);return e},fTe=(e,t)=>lTe(e,cTe(t)),dTe=(e,t)=>{var n={};for(var r in e)JX.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&lS)for(var r of lS(e))t.indexOf(r)<0&&ZX.call(e,r)&&(n[r]=e[r]);return n};function eJ(e,t,n){const r=Ve(e,t,n),{label:i,description:s,error:o,required:a,classNames:u,styles:l,className:c,unstyled:f,__staticSelector:d,sx:h,errorProps:p,labelProps:m,descriptionProps:y,wrapperProps:g,id:v,size:b,style:S,inputContainer:T,inputWrapperOrder:E,withAsterisk:I}=r,A=dTe(r,["label","description","error","required","classNames","styles","className","unstyled","__staticSelector","sx","errorProps","labelProps","descriptionProps","wrapperProps","id","size","style","inputContainer","inputWrapperOrder","withAsterisk"]),R=tu(v),{systemStyles:F,rest:L}=Qf(A),B=hb({label:i,description:s,error:o,required:a,classNames:u,className:c,__staticSelector:d,sx:h,errorProps:p,labelProps:m,descriptionProps:y,unstyled:f,styles:l,id:R,size:b,style:S,inputContainer:T,inputWrapperOrder:E,withAsterisk:I},g);return fTe(hb({},L),{classNames:u,styles:l,unstyled:f,wrapperProps:hb(hb({},B),F),inputProps:{required:a,classNames:u,styles:l,unstyled:f,id:R,size:b,__staticSelector:d,invalid:!!o}})}var hTe=lt((e,{size:t})=>({label:{display:"inline-block",fontSize:e.fn.size({size:t,sizes:e.fontSizes}),fontWeight:500,color:e.colorScheme==="dark"?e.colors.dark[0]:e.colors.gray[9],wordBreak:"break-word",cursor:"default",WebkitTapHighlightColor:"transparent"},required:{color:e.fn.variant({variant:"filled",color:"red"}).background}})),pTe=Object.defineProperty,cS=Object.getOwnPropertySymbols,tJ=Object.prototype.hasOwnProperty,nJ=Object.prototype.propertyIsEnumerable,k9=(e,t,n)=>t in e?pTe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,mTe=(e,t)=>{for(var n in t||(t={}))tJ.call(t,n)&&k9(e,n,t[n]);if(cS)for(var n of cS(t))nJ.call(t,n)&&k9(e,n,t[n]);return e},gTe=(e,t)=>{var n={};for(var r in e)tJ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&cS)for(var r of cS(e))t.indexOf(r)<0&&nJ.call(e,r)&&(n[r]=e[r]);return n};const yTe={labelElement:"label",size:"sm"},W$=w.forwardRef((e,t)=>{const n=Ve("InputLabel",yTe,e),{labelElement:r,children:i,required:s,size:o,classNames:a,styles:u,unstyled:l,className:c,htmlFor:f,__staticSelector:d}=n,h=gTe(n,["labelElement","children","required","size","classNames","styles","unstyled","className","htmlFor","__staticSelector"]),{classes:p,cx:m}=hTe({size:o},{name:["InputWrapper",d],classNames:a,styles:u,unstyled:l});return N.createElement(it,mTe({component:r,ref:t,className:m(p.label,c),htmlFor:r==="label"?f:void 0},h),i,s&&N.createElement("span",{className:p.required,"aria-hidden":!0}," *"))});W$.displayName="@mantine/core/InputLabel";var vTe=lt((e,{size:t})=>({error:{wordBreak:"break-word",color:e.fn.variant({variant:"filled",color:"red"}).background,fontSize:e.fn.size({size:t,sizes:e.fontSizes})-2,lineHeight:1.2,display:"block"}})),_Te=Object.defineProperty,fS=Object.getOwnPropertySymbols,rJ=Object.prototype.hasOwnProperty,iJ=Object.prototype.propertyIsEnumerable,D9=(e,t,n)=>t in e?_Te(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,bTe=(e,t)=>{for(var n in t||(t={}))rJ.call(t,n)&&D9(e,n,t[n]);if(fS)for(var n of fS(t))iJ.call(t,n)&&D9(e,n,t[n]);return e},wTe=(e,t)=>{var n={};for(var r in e)rJ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&fS)for(var r of fS(e))t.indexOf(r)<0&&iJ.call(e,r)&&(n[r]=e[r]);return n};const ETe={size:"sm"},q$=w.forwardRef((e,t)=>{const n=Ve("InputError",ETe,e),{children:r,className:i,classNames:s,styles:o,unstyled:a,size:u,__staticSelector:l}=n,c=wTe(n,["children","className","classNames","styles","unstyled","size","__staticSelector"]),{classes:f,cx:d}=vTe({size:u},{name:["InputWrapper",l],classNames:s,styles:o,unstyled:a});return N.createElement(rt,bTe({className:d(f.error,i),ref:t},c),r)});q$.displayName="@mantine/core/InputError";var STe=lt((e,{size:t})=>({description:{wordBreak:"break-word",color:e.colorScheme==="dark"?e.colors.dark[2]:e.colors.gray[6],fontSize:e.fn.size({size:t,sizes:e.fontSizes})-2,lineHeight:1.2,display:"block"}})),TTe=Object.defineProperty,dS=Object.getOwnPropertySymbols,sJ=Object.prototype.hasOwnProperty,oJ=Object.prototype.propertyIsEnumerable,$9=(e,t,n)=>t in e?TTe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ITe=(e,t)=>{for(var n in t||(t={}))sJ.call(t,n)&&$9(e,n,t[n]);if(dS)for(var n of dS(t))oJ.call(t,n)&&$9(e,n,t[n]);return e},xTe=(e,t)=>{var n={};for(var r in e)sJ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&dS)for(var r of dS(e))t.indexOf(r)<0&&oJ.call(e,r)&&(n[r]=e[r]);return n};const CTe={size:"sm"},G$=w.forwardRef((e,t)=>{const n=Ve("InputDescription",CTe,e),{children:r,className:i,classNames:s,styles:o,unstyled:a,size:u,__staticSelector:l}=n,c=xTe(n,["children","className","classNames","styles","unstyled","size","__staticSelector"]),{classes:f,cx:d}=STe({size:u},{name:["InputWrapper",l],classNames:s,styles:o,unstyled:a});return N.createElement(rt,ITe({color:"dimmed",className:d(f.description,i),ref:t,unstyled:a},c),r)});G$.displayName="@mantine/core/InputDescription";const aJ=w.createContext({offsetBottom:!1,offsetTop:!1,describedBy:void 0}),ATe=aJ.Provider,PTe=()=>w.useContext(aJ);function OTe(e,{hasDescription:t,hasError:n}){const r=e.findIndex(u=>u==="input"),i=e[r-1],s=e[r+1];return{offsetBottom:t&&s==="description"||n&&s==="error",offsetTop:t&&i==="description"||n&&i==="error"}}var RTe=Object.defineProperty,NTe=Object.defineProperties,kTe=Object.getOwnPropertyDescriptors,L9=Object.getOwnPropertySymbols,DTe=Object.prototype.hasOwnProperty,$Te=Object.prototype.propertyIsEnumerable,M9=(e,t,n)=>t in e?RTe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,LTe=(e,t)=>{for(var n in t||(t={}))DTe.call(t,n)&&M9(e,n,t[n]);if(L9)for(var n of L9(t))$Te.call(t,n)&&M9(e,n,t[n]);return e},MTe=(e,t)=>NTe(e,kTe(t)),FTe=lt(e=>({root:MTe(LTe({},e.fn.fontStyles()),{lineHeight:e.lineHeight})})),BTe=Object.defineProperty,jTe=Object.defineProperties,UTe=Object.getOwnPropertyDescriptors,hS=Object.getOwnPropertySymbols,uJ=Object.prototype.hasOwnProperty,lJ=Object.prototype.propertyIsEnumerable,F9=(e,t,n)=>t in e?BTe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,wc=(e,t)=>{for(var n in t||(t={}))uJ.call(t,n)&&F9(e,n,t[n]);if(hS)for(var n of hS(t))lJ.call(t,n)&&F9(e,n,t[n]);return e},B9=(e,t)=>jTe(e,UTe(t)),VTe=(e,t)=>{var n={};for(var r in e)uJ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&hS)for(var r of hS(e))t.indexOf(r)<0&&lJ.call(e,r)&&(n[r]=e[r]);return n};const zTe={labelElement:"label",size:"sm",inputContainer:e=>e,inputWrapperOrder:["label","description","input","error"]},cJ=w.forwardRef((e,t)=>{const n=Ve("InputWrapper",zTe,e),{className:r,label:i,children:s,required:o,id:a,error:u,description:l,labelElement:c,labelProps:f,descriptionProps:d,errorProps:h,classNames:p,styles:m,size:y,inputContainer:g,__staticSelector:v,unstyled:b,inputWrapperOrder:S,withAsterisk:T}=n,E=VTe(n,["className","label","children","required","id","error","description","labelElement","labelProps","descriptionProps","errorProps","classNames","styles","size","inputContainer","__staticSelector","unstyled","inputWrapperOrder","withAsterisk"]),{classes:I,cx:A}=FTe(null,{classNames:p,styles:m,name:["InputWrapper",v],unstyled:b}),R={classNames:p,styles:m,unstyled:b,size:y,__staticSelector:v},F=typeof T=="boolean"?T:o,L=a?`${a}-error`:h==null?void 0:h.id,B=a?`${a}-description`:d==null?void 0:d.id,V=`${!!u&&typeof u!="boolean"?L:""} ${l?B:""}`,re=V.trim().length>0?V.trim():void 0,oe=i&&N.createElement(W$,wc(wc({key:"label",labelElement:c,id:a?`${a}-label`:void 0,htmlFor:a,required:F},R),f),i),ae=l&&N.createElement(G$,B9(wc(wc({key:"description"},d),R),{size:(d==null?void 0:d.size)||R.size,id:(d==null?void 0:d.id)||B}),l),ee=N.createElement(w.Fragment,{key:"input"},g(s)),ue=typeof u!="boolean"&&u&&N.createElement(q$,B9(wc(wc({},h),R),{size:(h==null?void 0:h.size)||R.size,key:"error",id:(h==null?void 0:h.id)||L}),u),P=S.map(W=>{switch(W){case"label":return oe;case"input":return ee;case"description":return ae;case"error":return ue;default:return null}});return N.createElement(ATe,{value:wc({describedBy:re},OTe(S,{hasDescription:!!ae,hasError:!!ue}))},N.createElement(it,wc({className:A(I.root,r),ref:t},E),P))});cJ.displayName="@mantine/core/InputWrapper";var HTe=Object.defineProperty,pS=Object.getOwnPropertySymbols,fJ=Object.prototype.hasOwnProperty,dJ=Object.prototype.propertyIsEnumerable,j9=(e,t,n)=>t in e?HTe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,WTe=(e,t)=>{for(var n in t||(t={}))fJ.call(t,n)&&j9(e,n,t[n]);if(pS)for(var n of pS(t))dJ.call(t,n)&&j9(e,n,t[n]);return e},qTe=(e,t)=>{var n={};for(var r in e)fJ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&pS)for(var r of pS(e))t.indexOf(r)<0&&dJ.call(e,r)&&(n[r]=e[r]);return n};const GTe={},hJ=w.forwardRef((e,t)=>{const n=Ve("InputPlaceholder",GTe,e),{sx:r}=n,i=qTe(n,["sx"]);return N.createElement(it,WTe({component:"span",sx:[s=>s.fn.placeholderStyles(),...lh(r)],ref:t},i))});hJ.displayName="@mantine/core/InputPlaceholder";var YTe=Object.defineProperty,KTe=Object.defineProperties,QTe=Object.getOwnPropertyDescriptors,U9=Object.getOwnPropertySymbols,XTe=Object.prototype.hasOwnProperty,JTe=Object.prototype.propertyIsEnumerable,V9=(e,t,n)=>t in e?YTe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,pb=(e,t)=>{for(var n in t||(t={}))XTe.call(t,n)&&V9(e,n,t[n]);if(U9)for(var n of U9(t))JTe.call(t,n)&&V9(e,n,t[n]);return e},FP=(e,t)=>KTe(e,QTe(t));const $s={xs:30,sm:36,md:42,lg:50,xl:60};function ZTe({theme:e,variant:t}){return t==="default"?{border:`1px solid ${e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[4]}`,backgroundColor:e.colorScheme==="dark"?e.colors.dark[6]:e.white,transition:"border-color 100ms ease","&:focus, &:focus-within":e.focusRingStyles.inputStyles(e)}:t==="filled"?{border:"1px solid transparent",backgroundColor:e.colorScheme==="dark"?e.colors.dark[5]:e.colors.gray[1],"&:focus, &:focus-within":e.focusRingStyles.inputStyles(e)}:{borderWidth:0,color:e.colorScheme==="dark"?e.colors.dark[0]:e.black,backgroundColor:"transparent",minHeight:28,outline:0,"&:focus, &:focus-within":{outline:"none",borderColor:"transparent"},"&:disabled":{backgroundColor:"transparent","&:focus, &:focus-within":{outline:"none",borderColor:"transparent"}}}}var eIe=lt((e,{size:t,multiline:n,radius:r,variant:i,invalid:s,rightSectionWidth:o,withRightSection:a,iconWidth:u,offsetBottom:l,offsetTop:c,pointer:f})=>{const d=e.fn.variant({variant:"filled",color:"red"}).background,h=i==="default"||i==="filled"?{minHeight:e.fn.size({size:t,sizes:$s}),paddingLeft:e.fn.size({size:t,sizes:$s})/3,paddingRight:a?o:e.fn.size({size:t,sizes:$s})/3,borderRadius:e.fn.radius(r)}:null;return{wrapper:{position:"relative",marginTop:c?`calc(${e.spacing.xs}px / 2)`:void 0,marginBottom:l?`calc(${e.spacing.xs}px / 2)`:void 0},input:pb(FP(pb(FP(pb({},e.fn.fontStyles()),{height:n?i==="unstyled"?void 0:"auto":e.fn.size({size:t,sizes:$s}),WebkitTapHighlightColor:"transparent",lineHeight:n?e.lineHeight:`${e.fn.size({size:t,sizes:$s})-2}px`,appearance:"none",resize:"none",boxSizing:"border-box",fontSize:e.fn.size({size:t,sizes:e.fontSizes}),width:"100%",color:e.colorScheme==="dark"?e.colors.dark[0]:e.black,display:"block",textAlign:"left",cursor:f?"pointer":void 0}),h),{"&:disabled":{backgroundColor:e.colorScheme==="dark"?e.colors.dark[6]:e.colors.gray[1],color:e.colors.dark[2],opacity:.6,cursor:"not-allowed","&::placeholder":{color:e.colors.dark[2]}},"&::placeholder":FP(pb({},e.fn.placeholderStyles()),{opacity:1}),"&::-webkit-inner-spin-button, &::-webkit-outer-spin-button, &::-webkit-search-decoration, &::-webkit-search-cancel-button, &::-webkit-search-results-button, &::-webkit-search-results-decoration":{appearance:"none"},"&[type=number]":{MozAppearance:"textfield"}}),ZTe({theme:e,variant:i})),withIcon:{paddingLeft:typeof u=="number"?u:e.fn.size({size:t,sizes:$s})},invalid:{color:d,borderColor:d,"&::placeholder":{opacity:1,color:d}},disabled:{backgroundColor:e.colorScheme==="dark"?e.colors.dark[6]:e.colors.gray[1],color:e.colors.dark[2],opacity:.6,cursor:"not-allowed","&::placeholder":{color:e.colors.dark[2]}},icon:{pointerEvents:"none",position:"absolute",zIndex:1,left:0,top:0,bottom:0,display:"flex",alignItems:"center",justifyContent:"center",width:typeof u=="number"?u:e.fn.size({size:t,sizes:$s}),color:s?e.colors.red[e.colorScheme==="dark"?6:7]:e.colorScheme==="dark"?e.colors.dark[2]:e.colors.gray[5]},rightSection:{position:"absolute",top:0,bottom:0,right:0,display:"flex",alignItems:"center",justifyContent:"center",width:o}}}),tIe=Object.defineProperty,nIe=Object.defineProperties,rIe=Object.getOwnPropertyDescriptors,mS=Object.getOwnPropertySymbols,pJ=Object.prototype.hasOwnProperty,mJ=Object.prototype.propertyIsEnumerable,z9=(e,t,n)=>t in e?tIe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,mb=(e,t)=>{for(var n in t||(t={}))pJ.call(t,n)&&z9(e,n,t[n]);if(mS)for(var n of mS(t))mJ.call(t,n)&&z9(e,n,t[n]);return e},H9=(e,t)=>nIe(e,rIe(t)),iIe=(e,t)=>{var n={};for(var r in e)pJ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&mS)for(var r of mS(e))t.indexOf(r)<0&&mJ.call(e,r)&&(n[r]=e[r]);return n};const sIe={rightSectionWidth:36,size:"sm",variant:"default"},$h=w.forwardRef((e,t)=>{const n=Ve("Input",sIe,e),{className:r,invalid:i,required:s,disabled:o,variant:a,icon:u,style:l,rightSectionWidth:c,iconWidth:f,rightSection:d,rightSectionProps:h,radius:p,size:m,wrapperProps:y,classNames:g,styles:v,__staticSelector:b,multiline:S,sx:T,unstyled:E,pointer:I}=n,A=iIe(n,["className","invalid","required","disabled","variant","icon","style","rightSectionWidth","iconWidth","rightSection","rightSectionProps","radius","size","wrapperProps","classNames","styles","__staticSelector","multiline","sx","unstyled","pointer"]),{offsetBottom:R,offsetTop:F,describedBy:L}=PTe(),{classes:B,cx:J}=eIe({radius:p,size:m,multiline:S,variant:a,invalid:i,rightSectionWidth:c,iconWidth:f,withRightSection:!!d,offsetBottom:R,offsetTop:F,pointer:I},{classNames:g,styles:v,name:["Input",b],unstyled:E}),{systemStyles:V,rest:re}=Qf(A);return N.createElement(it,mb(mb({className:J(B.wrapper,r),sx:T,style:l},V),y),u&&N.createElement("div",{className:B.icon},u),N.createElement(it,H9(mb({component:"input"},re),{ref:t,required:s,"aria-invalid":i,"aria-describedby":L,disabled:o,className:J(B[`${a}Variant`],B.input,{[B.withIcon]:u,[B.invalid]:i,[B.disabled]:o})})),d&&N.createElement("div",H9(mb({},h),{className:B.rightSection}),d))});$h.displayName="@mantine/core/Input";$h.Wrapper=cJ;$h.Label=W$;$h.Description=G$;$h.Error=q$;$h.Placeholder=hJ;const Zs=$h;var oIe=Object.defineProperty,aIe=Object.defineProperties,uIe=Object.getOwnPropertyDescriptors,W9=Object.getOwnPropertySymbols,lIe=Object.prototype.hasOwnProperty,cIe=Object.prototype.propertyIsEnumerable,q9=(e,t,n)=>t in e?oIe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,BP=(e,t)=>{for(var n in t||(t={}))lIe.call(t,n)&&q9(e,n,t[n]);if(W9)for(var n of W9(t))cIe.call(t,n)&&q9(e,n,t[n]);return e},fIe=(e,t)=>aIe(e,uIe(t));const jP={xs:{fontSize:9,height:16},sm:{fontSize:10,height:18},md:{fontSize:11,height:20},lg:{fontSize:13,height:26},xl:{fontSize:16,height:32}},dIe={xs:4,sm:4,md:6,lg:8,xl:10};function hIe({theme:e,variant:t,color:n,size:r,gradient:i}){if(t==="dot"){const o=e.fn.size({size:r,sizes:dIe});return{backgroundColor:"transparent",color:e.colorScheme==="dark"?e.colors.dark[0]:e.colors.gray[7],border:`1px solid ${e.colorScheme==="dark"?e.colors.dark[3]:e.colors.gray[3]}`,paddingLeft:e.fn.size({size:r,sizes:e.spacing})/1.5-o/2,"&::before":{content:'""',display:"block",width:o,height:o,borderRadius:o,backgroundColor:e.fn.themeColor(n,e.colorScheme==="dark"?4:e.fn.primaryShade("light"),!0),marginRight:o}}}const s=e.fn.variant({color:n,variant:t,gradient:i});return{background:s.background,color:s.color,border:`${t==="gradient"?0:1}px solid ${s.border}`}}var pIe=lt((e,{color:t,size:n,radius:r,gradient:i,fullWidth:s,variant:o})=>{const{fontSize:a,height:u}=n in jP?jP[n]:jP.md;return{leftSection:{marginRight:`calc(${e.spacing.xs}px / 2)`},rightSection:{marginLeft:`calc(${e.spacing.xs}px / 2)`},inner:{whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis"},root:BP(fIe(BP(BP({},e.fn.focusStyles()),e.fn.fontStyles()),{fontSize:a,height:u,WebkitTapHighlightColor:"transparent",lineHeight:`${u-2}px`,textDecoration:"none",padding:`0 ${e.fn.size({size:n,sizes:e.spacing})/1.5}px`,boxSizing:"border-box",display:s?"flex":"inline-flex",alignItems:"center",justifyContent:"center",width:s?"100%":"auto",textTransform:"uppercase",borderRadius:e.fn.radius(r),fontWeight:700,letterSpacing:.25,cursor:"inherit",textOverflow:"ellipsis",overflow:"hidden"}),hIe({theme:e,variant:o,color:t,size:n,gradient:i}))}}),mIe=Object.defineProperty,gS=Object.getOwnPropertySymbols,gJ=Object.prototype.hasOwnProperty,yJ=Object.prototype.propertyIsEnumerable,G9=(e,t,n)=>t in e?mIe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,gIe=(e,t)=>{for(var n in t||(t={}))gJ.call(t,n)&&G9(e,n,t[n]);if(gS)for(var n of gS(t))yJ.call(t,n)&&G9(e,n,t[n]);return e},yIe=(e,t)=>{var n={};for(var r in e)gJ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&gS)for(var r of gS(e))t.indexOf(r)<0&&yJ.call(e,r)&&(n[r]=e[r]);return n};const vIe={variant:"light",size:"md",radius:"xl"},vJ=w.forwardRef((e,t)=>{const n=Ve("Badge",vIe,e),{className:r,color:i,variant:s,fullWidth:o,children:a,size:u,leftSection:l,rightSection:c,radius:f,gradient:d,classNames:h,styles:p,unstyled:m}=n,y=yIe(n,["className","color","variant","fullWidth","children","size","leftSection","rightSection","radius","gradient","classNames","styles","unstyled"]),{classes:g,cx:v}=pIe({size:u,fullWidth:o,color:i,radius:f,variant:s,gradient:d},{classNames:h,styles:p,name:"Badge",unstyled:m});return N.createElement(it,gIe({className:v(g.root,r),ref:t},y),l&&N.createElement("span",{className:g.leftSection},l),N.createElement("span",{className:g.inner},a),c&&N.createElement("span",{className:g.rightSection},c))});vJ.displayName="@mantine/core/Badge";const _Ie=vJ;var bIe=Object.defineProperty,Y9=Object.getOwnPropertySymbols,wIe=Object.prototype.hasOwnProperty,EIe=Object.prototype.propertyIsEnumerable,K9=(e,t,n)=>t in e?bIe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,SIe=(e,t)=>{for(var n in t||(t={}))wIe.call(t,n)&&K9(e,n,t[n]);if(Y9)for(var n of Y9(t))EIe.call(t,n)&&K9(e,n,t[n]);return e};function TIe(e){return N.createElement("svg",SIe({width:"20",height:"20",viewBox:"0 0 409.294 409.294",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg"},e),N.createElement("path",{d:"M0 204.647v175.412h175.412V204.647H58.471c0-64.48 52.461-116.941 116.941-116.941V29.235C78.684 29.235 0 107.919 0 204.647zM409.294 87.706V29.235c-96.728 0-175.412 78.684-175.412 175.412v175.412h175.412V204.647H292.353c0-64.48 52.461-116.941 116.941-116.941z"}))}var IIe=Object.defineProperty,xIe=Object.defineProperties,CIe=Object.getOwnPropertyDescriptors,Q9=Object.getOwnPropertySymbols,AIe=Object.prototype.hasOwnProperty,PIe=Object.prototype.propertyIsEnumerable,X9=(e,t,n)=>t in e?IIe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,OIe=(e,t)=>{for(var n in t||(t={}))AIe.call(t,n)&&X9(e,n,t[n]);if(Q9)for(var n of Q9(t))PIe.call(t,n)&&X9(e,n,t[n]);return e},RIe=(e,t)=>xIe(e,CIe(t)),NIe=lt((e,{color:t})=>({root:RIe(OIe({},e.fn.fontStyles()),{fontSize:e.fontSizes.lg,lineHeight:e.lineHeight,color:e.colorScheme==="dark"?e.colors.dark[0]:e.black,margin:0,borderTopRightRadius:e.radius.sm,borderBottomRightRadius:e.radius.sm,padding:`${e.spacing.md}px ${e.spacing.lg}px`}),inner:{display:"flex"},body:{flex:1,overflow:"hidden",textOverflow:"ellipsis"},icon:{color:e.fn.variant({variant:"filled",color:t}).background,marginRight:e.spacing.lg,marginTop:2,width:22},cite:{display:"block",fontSize:e.fontSizes.sm,marginTop:e.spacing.xs,color:e.colorScheme==="dark"?e.colors.dark[2]:e.colors.gray[6],overflow:"hidden",textOverflow:"ellipsis"}})),kIe=Object.defineProperty,yS=Object.getOwnPropertySymbols,_J=Object.prototype.hasOwnProperty,bJ=Object.prototype.propertyIsEnumerable,J9=(e,t,n)=>t in e?kIe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,DIe=(e,t)=>{for(var n in t||(t={}))_J.call(t,n)&&J9(e,n,t[n]);if(yS)for(var n of yS(t))bJ.call(t,n)&&J9(e,n,t[n]);return e},$Ie=(e,t)=>{var n={};for(var r in e)_J.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&yS)for(var r of yS(e))t.indexOf(r)<0&&bJ.call(e,r)&&(n[r]=e[r]);return n};const LIe={color:"gray",icon:N.createElement(TIe,null)},wJ=w.forwardRef((e,t)=>{const n=Ve("Blockquote",LIe,e),{className:r,color:i,icon:s,cite:o,children:a,classNames:u,styles:l,unstyled:c}=n,f=$Ie(n,["className","color","icon","cite","children","classNames","styles","unstyled"]),{classes:d,cx:h}=NIe({color:i},{classNames:u,styles:l,unstyled:c,name:"Blockquote"});return N.createElement(it,DIe({component:"blockquote",className:h(d.root,r),ref:t},f),N.createElement("div",{className:d.inner},s&&N.createElement("div",{className:d.icon},s),N.createElement("div",{className:d.body},a,o&&N.createElement("cite",{className:d.cite},o))))});wJ.displayName="@mantine/core/Blockquote";var MIe=lt((e,{orientation:t,buttonBorderWidth:n})=>({root:{display:"flex",flexDirection:t==="vertical"?"column":"row","& [data-button]":{"&:first-of-type":{borderBottomRightRadius:0,[t==="vertical"?"borderBottomLeftRadius":"borderTopRightRadius"]:0,[t==="vertical"?"borderBottomWidth":"borderRightWidth"]:n/2},"&:last-of-type":{borderTopLeftRadius:0,[t==="vertical"?"borderTopRightRadius":"borderBottomLeftRadius"]:0,[t==="vertical"?"borderTopWidth":"borderLeftWidth"]:n/2},"&:not(:first-of-type):not(:last-of-type)":{borderRadius:0,[t==="vertical"?"borderTopWidth":"borderLeftWidth"]:n/2,[t==="vertical"?"borderBottomWidth":"borderRightWidth"]:n/2},"& + [data-button]":{[t==="vertical"?"marginTop":"marginLeft"]:-n,"@media (min-resolution: 192dpi)":{[t==="vertical"?"marginTop":"marginLeft"]:0}}}}})),FIe=Object.defineProperty,vS=Object.getOwnPropertySymbols,EJ=Object.prototype.hasOwnProperty,SJ=Object.prototype.propertyIsEnumerable,Z9=(e,t,n)=>t in e?FIe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,BIe=(e,t)=>{for(var n in t||(t={}))EJ.call(t,n)&&Z9(e,n,t[n]);if(vS)for(var n of vS(t))SJ.call(t,n)&&Z9(e,n,t[n]);return e},jIe=(e,t)=>{var n={};for(var r in e)EJ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&vS)for(var r of vS(e))t.indexOf(r)<0&&SJ.call(e,r)&&(n[r]=e[r]);return n};const UIe={orientation:"horizontal",buttonBorderWidth:1},TJ=w.forwardRef((e,t)=>{const n=Ve("ButtonGroup",UIe,e),{className:r,orientation:i,buttonBorderWidth:s,unstyled:o}=n,a=jIe(n,["className","orientation","buttonBorderWidth","unstyled"]),{classes:u,cx:l}=MIe({orientation:i,buttonBorderWidth:s},{name:"ButtonGroup",unstyled:o});return N.createElement(it,BIe({className:l(u.root,r),ref:t},a))});TJ.displayName="@mantine/core/ButtonGroup";var VIe=Object.defineProperty,zIe=Object.defineProperties,HIe=Object.getOwnPropertyDescriptors,eB=Object.getOwnPropertySymbols,WIe=Object.prototype.hasOwnProperty,qIe=Object.prototype.propertyIsEnumerable,tB=(e,t,n)=>t in e?VIe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Ed=(e,t)=>{for(var n in t||(t={}))WIe.call(t,n)&&tB(e,n,t[n]);if(eB)for(var n of eB(t))qIe.call(t,n)&&tB(e,n,t[n]);return e},YR=(e,t)=>zIe(e,HIe(t));const KR={xs:{height:$s.xs,paddingLeft:14,paddingRight:14},sm:{height:$s.sm,paddingLeft:18,paddingRight:18},md:{height:$s.md,paddingLeft:22,paddingRight:22},lg:{height:$s.lg,paddingLeft:26,paddingRight:26},xl:{height:$s.xl,paddingLeft:32,paddingRight:32},"compact-xs":{height:22,paddingLeft:7,paddingRight:7},"compact-sm":{height:26,paddingLeft:8,paddingRight:8},"compact-md":{height:30,paddingLeft:10,paddingRight:10},"compact-lg":{height:34,paddingLeft:12,paddingRight:12},"compact-xl":{height:40,paddingLeft:14,paddingRight:14}};function GIe({compact:e,size:t,withLeftIcon:n,withRightIcon:r}){if(e)return KR[`compact-${t}`];const i=KR[t];return YR(Ed({},i),{paddingLeft:n?i.paddingLeft/1.5:i.paddingLeft,paddingRight:r?i.paddingRight/1.5:i.paddingRight})}const YIe=e=>({display:e?"block":"inline-block",width:e?"100%":"auto"});function KIe({variant:e,theme:t,color:n,gradient:r}){const i=t.fn.variant({color:n,variant:e,gradient:r});return e==="gradient"?{border:0,backgroundImage:i.background,color:i.color,"&:hover":t.fn.hover({backgroundSize:"200%"})}:Ed({border:`1px solid ${i.border}`,backgroundColor:i.background,color:i.color},t.fn.hover({backgroundColor:i.hover}))}var QIe=lt((e,{color:t,size:n,radius:r,fullWidth:i,compact:s,gradient:o,variant:a,withLeftIcon:u,withRightIcon:l})=>({root:YR(Ed(YR(Ed(Ed(Ed(Ed({},GIe({compact:s,size:n,withLeftIcon:u,withRightIcon:l})),e.fn.fontStyles()),e.fn.focusStyles()),YIe(i)),{borderRadius:e.fn.radius(r),fontWeight:600,position:"relative",lineHeight:1,fontSize:e.fn.size({size:n,sizes:e.fontSizes}),userSelect:"none",cursor:"pointer"}),KIe({variant:a,theme:e,color:t,gradient:o})),{"&:active":e.activeStyles,"&:disabled, &[data-disabled]":{borderColor:"transparent",backgroundColor:e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[2],color:e.colorScheme==="dark"?e.colors.dark[6]:e.colors.gray[5],cursor:"not-allowed",backgroundImage:"none",pointerEvents:"none","&:active":{transform:"none"}},"&[data-loading]":{pointerEvents:"none","&::before":{content:'""',position:"absolute",top:-1,left:-1,right:-1,bottom:-1,backgroundColor:e.colorScheme==="dark"?e.fn.rgba(e.colors.dark[7],.5):"rgba(255, 255, 255, .5)",borderRadius:e.fn.radius(r),cursor:"not-allowed"}}}),icon:{display:"flex",alignItems:"center"},leftIcon:{marginRight:10},rightIcon:{marginLeft:10},centerLoader:{position:"absolute",left:"50%",transform:"translateX(-50%)",opacity:.5},inner:{display:"flex",alignItems:"center",justifyContent:"center",height:"100%",overflow:"visible"},label:{whiteSpace:"nowrap",height:"100%",overflow:"hidden",display:"flex",alignItems:"center"}})),XIe=Object.defineProperty,_S=Object.getOwnPropertySymbols,IJ=Object.prototype.hasOwnProperty,xJ=Object.prototype.propertyIsEnumerable,nB=(e,t,n)=>t in e?XIe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,rB=(e,t)=>{for(var n in t||(t={}))IJ.call(t,n)&&nB(e,n,t[n]);if(_S)for(var n of _S(t))xJ.call(t,n)&&nB(e,n,t[n]);return e},JIe=(e,t)=>{var n={};for(var r in e)IJ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&_S)for(var r of _S(e))t.indexOf(r)<0&&xJ.call(e,r)&&(n[r]=e[r]);return n};const ZIe={size:"sm",type:"button",variant:"filled",loaderPosition:"left"},Y$=w.forwardRef((e,t)=>{const n=Ve("Button",ZIe,e),{className:r,size:i,color:s,type:o,disabled:a,children:u,leftIcon:l,rightIcon:c,fullWidth:f,variant:d,radius:h,uppercase:p,compact:m,loading:y,loaderPosition:g,loaderProps:v,gradient:b,classNames:S,styles:T,unstyled:E}=n,I=JIe(n,["className","size","color","type","disabled","children","leftIcon","rightIcon","fullWidth","variant","radius","uppercase","compact","loading","loaderPosition","loaderProps","gradient","classNames","styles","unstyled"]),{classes:A,cx:R,theme:F}=QIe({radius:h,color:s,size:i,fullWidth:f,compact:m,gradient:b,variant:d,withLeftIcon:!!l,withRightIcon:!!c},{name:"Button",unstyled:E,classNames:S,styles:T}),L=F.fn.variant({color:s,variant:d}),B=N.createElement(Xf,rB({color:L.color,size:F.fn.size({size:i,sizes:KR}).height/2},v));return N.createElement(kx,rB({className:R(A.root,r),type:o,disabled:a,"data-button":!0,"data-disabled":a||void 0,"data-loading":y||void 0,ref:t,unstyled:E},I),N.createElement("div",{className:A.inner},(l||y&&g==="left")&&N.createElement("span",{className:R(A.icon,A.leftIcon)},y&&g==="left"?B:l),y&&g==="center"&&N.createElement("span",{className:A.centerLoader},B),N.createElement("span",{className:A.label,style:{textTransform:p?"uppercase":void 0}},u),(c||y&&g==="right")&&N.createElement("span",{className:R(A.icon,A.rightIcon)},y&&g==="right"?B:c)))});Y$.displayName="@mantine/core/Button";Y$.Group=TJ;const Ws=Y$;var exe=lt((e,{radius:t,shadow:n,withBorder:r})=>({root:{outline:0,WebkitTapHighlightColor:"transparent",display:"block",textDecoration:"none",color:e.colorScheme==="dark"?e.colors.dark[0]:e.black,backgroundColor:e.colorScheme==="dark"?e.colors.dark[7]:e.white,boxSizing:"border-box",borderRadius:e.fn.radius(t),boxShadow:e.shadows[n]||n||"none",border:r?`1px solid ${e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[3]}`:void 0}})),txe=Object.defineProperty,bS=Object.getOwnPropertySymbols,CJ=Object.prototype.hasOwnProperty,AJ=Object.prototype.propertyIsEnumerable,iB=(e,t,n)=>t in e?txe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,nxe=(e,t)=>{for(var n in t||(t={}))CJ.call(t,n)&&iB(e,n,t[n]);if(bS)for(var n of bS(t))AJ.call(t,n)&&iB(e,n,t[n]);return e},rxe=(e,t)=>{var n={};for(var r in e)CJ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&bS)for(var r of bS(e))t.indexOf(r)<0&&AJ.call(e,r)&&(n[r]=e[r]);return n};const ixe={},PJ=w.forwardRef((e,t)=>{const n=Ve("Paper",ixe,e),{className:r,children:i,radius:s,withBorder:o,shadow:a,unstyled:u}=n,l=rxe(n,["className","children","radius","withBorder","shadow","unstyled"]),{classes:c,cx:f}=exe({radius:s,shadow:a,withBorder:o},{name:"Paper",unstyled:u});return N.createElement(it,nxe({className:f(c.root,r),ref:t},l),i)});PJ.displayName="@mantine/core/Paper";const wS=PJ,OJ=w.createContext({padding:0}),sxe=OJ.Provider,oxe=()=>w.useContext(OJ).padding;var axe=lt((e,{padding:t,withBorder:n,inheritPadding:r})=>{const i=e.fn.size({size:t,sizes:e.spacing}),s=-1*i,o=e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[3];return{cardSection:{display:"block",marginLeft:s,marginRight:s,paddingLeft:r?i:void 0,paddingRight:r?i:void 0,borderTop:n&&`1px solid ${o}`,borderBottom:n&&`1px solid ${o}`,"& + &":{borderTop:0},"&[data-first]":{marginTop:s,borderTop:0,borderBottom:n&&`1px solid ${o}`},"&[data-last]":{marginBottom:s,borderBottom:0}}}});const uxe=axe;var lxe=Object.defineProperty,ES=Object.getOwnPropertySymbols,RJ=Object.prototype.hasOwnProperty,NJ=Object.prototype.propertyIsEnumerable,sB=(e,t,n)=>t in e?lxe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,cxe=(e,t)=>{for(var n in t||(t={}))RJ.call(t,n)&&sB(e,n,t[n]);if(ES)for(var n of ES(t))NJ.call(t,n)&&sB(e,n,t[n]);return e},fxe=(e,t)=>{var n={};for(var r in e)RJ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&ES)for(var r of ES(e))t.indexOf(r)<0&&NJ.call(e,r)&&(n[r]=e[r]);return n};const dxe={withBorder:!1,inheritPadding:!1},kJ=w.forwardRef((e,t)=>{const n=Ve("CardSection",dxe,e),{className:r,withBorder:i,inheritPadding:s,unstyled:o}=n,a=fxe(n,["className","withBorder","inheritPadding","unstyled"]),{classes:u,cx:l}=uxe({padding:oxe(),withBorder:i,inheritPadding:s},{name:"Card",unstyled:o});return N.createElement(it,cxe({className:l(u.cardSection,r),ref:t},a))});kJ.displayName="@mantine/core/CardSection";const DJ=kJ;var hxe=lt(e=>({root:{position:"relative",overflow:"hidden",backgroundColor:e.colorScheme==="dark"?e.colors.dark[6]:e.white}})),pxe=Object.defineProperty,SS=Object.getOwnPropertySymbols,$J=Object.prototype.hasOwnProperty,LJ=Object.prototype.propertyIsEnumerable,oB=(e,t,n)=>t in e?pxe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,mxe=(e,t)=>{for(var n in t||(t={}))$J.call(t,n)&&oB(e,n,t[n]);if(SS)for(var n of SS(t))LJ.call(t,n)&&oB(e,n,t[n]);return e},gxe=(e,t)=>{var n={};for(var r in e)$J.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&SS)for(var r of SS(e))t.indexOf(r)<0&&LJ.call(e,r)&&(n[r]=e[r]);return n};const yxe={p:"md"},K$=w.forwardRef((e,t)=>{const n=Ve("Card",yxe,e),{className:r,p:i,radius:s,children:o,unstyled:a}=n,u=gxe(n,["className","p","radius","children","unstyled"]),{classes:l,cx:c}=hxe(null,{name:"Card",unstyled:a}),f=w.Children.toArray(o),d=f.map((h,p)=>typeof h=="object"&&h&&"type"in h&&h.type===DJ?w.cloneElement(h,{padding:i,"data-first":p===0||void 0,"data-last":p===f.length-1||void 0}):h);return N.createElement(sxe,{value:{padding:i}},N.createElement(wS,mxe({className:c(l.root,r),radius:s,p:i,ref:t},u),d))});K$.Section=DJ;K$.displayName="@mantine/core/Card";const vxe=K$;var _xe=Object.defineProperty,TS=Object.getOwnPropertySymbols,MJ=Object.prototype.hasOwnProperty,FJ=Object.prototype.propertyIsEnumerable,aB=(e,t,n)=>t in e?_xe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,bxe=(e,t)=>{for(var n in t||(t={}))MJ.call(t,n)&&aB(e,n,t[n]);if(TS)for(var n of TS(t))FJ.call(t,n)&&aB(e,n,t[n]);return e},wxe=(e,t)=>{var n={};for(var r in e)MJ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&TS)for(var r of TS(e))t.indexOf(r)<0&&FJ.call(e,r)&&(n[r]=e[r]);return n};const BJ=w.forwardRef((e,t)=>{const n=Ve("Center",{},e),{inline:r,sx:i}=n,s=wxe(n,["inline","sx"]);return N.createElement(it,bxe({ref:t,sx:[{display:r?"inline-flex":"flex",alignItems:"center",justifyContent:"center"},...lh(i)]},s))});BJ.displayName="@mantine/core/Center";const ua=BJ,jJ=w.createContext(null),Exe=jJ.Provider,Sxe=()=>w.useContext(jJ);function Txe(e){return w.Children.toArray(e).filter(Boolean)}const Ixe={left:"flex-start",center:"center",right:"flex-end",apart:"space-between"};var xxe=lt((e,{spacing:t,position:n,noWrap:r,grow:i,align:s,count:o})=>({root:{boxSizing:"border-box",display:"flex",flexDirection:"row",alignItems:s||"center",flexWrap:r?"nowrap":"wrap",justifyContent:Ixe[n],gap:e.fn.size({size:t,sizes:e.spacing}),"& > *":{boxSizing:"border-box",maxWidth:i?`calc(${100/o}% - ${e.fn.size({size:t,sizes:e.spacing})-e.fn.size({size:t,sizes:e.spacing})/o}px)`:void 0,flexGrow:i?1:0}}}));const Cxe=xxe;var Axe=Object.defineProperty,IS=Object.getOwnPropertySymbols,UJ=Object.prototype.hasOwnProperty,VJ=Object.prototype.propertyIsEnumerable,uB=(e,t,n)=>t in e?Axe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Pxe=(e,t)=>{for(var n in t||(t={}))UJ.call(t,n)&&uB(e,n,t[n]);if(IS)for(var n of IS(t))VJ.call(t,n)&&uB(e,n,t[n]);return e},Oxe=(e,t)=>{var n={};for(var r in e)UJ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&IS)for(var r of IS(e))t.indexOf(r)<0&&VJ.call(e,r)&&(n[r]=e[r]);return n};const Rxe={position:"left",spacing:"md"},ei=w.forwardRef((e,t)=>{const n=Ve("Group",Rxe,e),{className:r,position:i,align:s,children:o,noWrap:a,grow:u,spacing:l,unstyled:c}=n,f=Oxe(n,["className","position","align","children","noWrap","grow","spacing","unstyled"]),d=Txe(o),{classes:h,cx:p}=Cxe({align:s,grow:u,noWrap:a,spacing:l,position:i,count:d.length},{unstyled:c,name:"Group"});return N.createElement(it,Pxe({className:p(h.root,r),ref:t},f),d)});ei.displayName="@mantine/core/Group";var Nxe=lt((e,{spacing:t,align:n,justify:r})=>({root:{display:"flex",flexDirection:"column",alignItems:n,justifyContent:r,gap:e.fn.size({size:t,sizes:e.spacing})}})),kxe=Object.defineProperty,xS=Object.getOwnPropertySymbols,zJ=Object.prototype.hasOwnProperty,HJ=Object.prototype.propertyIsEnumerable,lB=(e,t,n)=>t in e?kxe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Dxe=(e,t)=>{for(var n in t||(t={}))zJ.call(t,n)&&lB(e,n,t[n]);if(xS)for(var n of xS(t))HJ.call(t,n)&&lB(e,n,t[n]);return e},$xe=(e,t)=>{var n={};for(var r in e)zJ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&xS)for(var r of xS(e))t.indexOf(r)<0&&HJ.call(e,r)&&(n[r]=e[r]);return n};const Lxe={spacing:"md",align:"stretch",justify:"flex-start"},ys=w.forwardRef((e,t)=>{const n=Ve("Stack",Lxe,e),{spacing:r,className:i,align:s,justify:o,unstyled:a}=n,u=$xe(n,["spacing","className","align","justify","unstyled"]),{classes:l,cx:c}=Nxe({spacing:r,align:s,justify:o},{name:"Stack",unstyled:a});return N.createElement(it,Dxe({className:c(l.root,i),ref:t},u))});ys.displayName="@mantine/core/Stack";function WJ({spacing:e,offset:t,orientation:n,children:r,role:i,unstyled:s}){return n==="horizontal"?N.createElement(ei,{pt:t,spacing:e,role:i,unstyled:s},r):N.createElement(ys,{pt:t,spacing:e,role:i,unstyled:s},r)}var Mxe=Object.defineProperty,CS=Object.getOwnPropertySymbols,qJ=Object.prototype.hasOwnProperty,GJ=Object.prototype.propertyIsEnumerable,cB=(e,t,n)=>t in e?Mxe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,fB=(e,t)=>{for(var n in t||(t={}))qJ.call(t,n)&&cB(e,n,t[n]);if(CS)for(var n of CS(t))GJ.call(t,n)&&cB(e,n,t[n]);return e},Fxe=(e,t)=>{var n={};for(var r in e)qJ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&CS)for(var r of CS(e))t.indexOf(r)<0&&GJ.call(e,r)&&(n[r]=e[r]);return n};const Bxe={orientation:"horizontal",spacing:"lg",size:"sm",offset:"xs"},YJ=w.forwardRef((e,t)=>{const n=Ve("CheckboxGroup",Bxe,e),{children:r,value:i,defaultValue:s,onChange:o,orientation:a,spacing:u,size:l,wrapperProps:c,offset:f}=n,d=Fxe(n,["children","value","defaultValue","onChange","orientation","spacing","size","wrapperProps","offset"]),[h,p]=oa({value:i,defaultValue:s,finalValue:[],onChange:o}),m=y=>{const g=y.currentTarget.value;p(h.includes(g)?h.filter(v=>v!==g):[...h,g])};return N.createElement(Exe,{value:{value:h,onChange:m,size:l}},N.createElement(Zs.Wrapper,fB(fB({labelElement:"div",size:l,__staticSelector:"CheckboxGroup",ref:t},c),d),N.createElement(WJ,{spacing:u,orientation:a,offset:f},r)))});YJ.displayName="@mantine/core/CheckboxGroup";var jxe=Object.defineProperty,AS=Object.getOwnPropertySymbols,KJ=Object.prototype.hasOwnProperty,QJ=Object.prototype.propertyIsEnumerable,dB=(e,t,n)=>t in e?jxe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,QR=(e,t)=>{for(var n in t||(t={}))KJ.call(t,n)&&dB(e,n,t[n]);if(AS)for(var n of AS(t))QJ.call(t,n)&&dB(e,n,t[n]);return e},Uxe=(e,t)=>{var n={};for(var r in e)KJ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&AS)for(var r of AS(e))t.indexOf(r)<0&&QJ.call(e,r)&&(n[r]=e[r]);return n};function Vxe(e){return N.createElement("svg",QR({viewBox:"0 0 10 7",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e),N.createElement("path",{d:"M4 4.586L1.707 2.293A1 1 0 1 0 .293 3.707l3 3a.997.997 0 0 0 1.414 0l5-5A1 1 0 1 0 8.293.293L4 4.586z",fill:"currentColor",fillRule:"evenodd",clipRule:"evenodd"}))}function zxe(e){var t=e,{indeterminate:n}=t,r=Uxe(t,["indeterminate"]);return n?N.createElement("svg",QR({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 32 6"},r),N.createElement("rect",{width:"32",height:"6",fill:"currentColor",rx:"3"})):N.createElement(Vxe,QR({},r))}var Hxe=Object.defineProperty,Wxe=Object.defineProperties,qxe=Object.getOwnPropertyDescriptors,hB=Object.getOwnPropertySymbols,Gxe=Object.prototype.hasOwnProperty,Yxe=Object.prototype.propertyIsEnumerable,pB=(e,t,n)=>t in e?Hxe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Kxe=(e,t)=>{for(var n in t||(t={}))Gxe.call(t,n)&&pB(e,n,t[n]);if(hB)for(var n of hB(t))Yxe.call(t,n)&&pB(e,n,t[n]);return e},Qxe=(e,t)=>Wxe(e,qxe(t));const Xxe={xs:16,sm:20,md:24,lg:30,xl:36},Jxe={xs:8,sm:10,md:14,lg:16,xl:20};var Zxe=lt((e,{size:t,radius:n,color:r,transitionDuration:i,labelPosition:s,error:o,indeterminate:a},u)=>{const l=e.fn.size({size:t,sizes:Xxe}),c=e.fn.variant({variant:"filled",color:r}),f=e.fn.variant({variant:"filled",color:"red"}).background;return{icon:{ref:u("icon"),color:a?"inherit":e.white,transform:a?"none":"translateY(5px) scale(0.5)",opacity:a?1:0,transitionProperty:"opacity, transform",transitionTimingFunction:"ease",transitionDuration:`${i}ms`,pointerEvents:"none",width:e.fn.size({size:t,sizes:Jxe}),position:"absolute",zIndex:1,top:0,bottom:0,left:0,right:0,margin:"auto","@media (prefers-reduced-motion)":{transitionDuration:e.respectReducedMotion?"0ms":void 0}},inner:{position:"relative",width:l,height:l,order:s==="left"?2:1},input:Qxe(Kxe({},e.fn.focusStyles()),{appearance:"none",backgroundColor:e.colorScheme==="dark"?e.colors.dark[6]:e.white,border:`1px solid ${o?f:e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[4]}`,width:l,height:l,borderRadius:e.fn.radius(n),padding:0,display:"block",margin:0,transition:`border-color ${i}ms ease, background-color ${i}ms ease`,cursor:e.cursorType,"&:checked":{backgroundColor:c.background,borderColor:c.background,[`& + .${u("icon")}`]:{opacity:1,color:e.white,transform:"translateY(0) scale(1)"}},"&:disabled":{backgroundColor:e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[2],borderColor:e.colorScheme==="dark"?e.colors.dark[6]:e.colors.gray[3],cursor:"not-allowed",[`& + .${u("icon")}`]:{color:e.colorScheme==="dark"?e.colors.dark[6]:e.colors.gray[5]}}})}});const eCe=Zxe;var tCe=Object.defineProperty,nCe=Object.defineProperties,rCe=Object.getOwnPropertyDescriptors,mB=Object.getOwnPropertySymbols,iCe=Object.prototype.hasOwnProperty,sCe=Object.prototype.propertyIsEnumerable,gB=(e,t,n)=>t in e?tCe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,oCe=(e,t)=>{for(var n in t||(t={}))iCe.call(t,n)&&gB(e,n,t[n]);if(mB)for(var n of mB(t))sCe.call(t,n)&&gB(e,n,t[n]);return e},aCe=(e,t)=>nCe(e,rCe(t));const uCe={xs:16,sm:20,md:24,lg:30,xl:36};var lCe=lt((e,{labelPosition:t,size:n})=>({root:{},body:{display:"flex"},labelWrapper:aCe(oCe({},e.fn.fontStyles()),{display:"inline-flex",flexDirection:"column",WebkitTapHighlightColor:"transparent",fontSize:e.fn.size({size:n,sizes:e.fontSizes}),lineHeight:`${e.fn.size({size:n,sizes:uCe})}px`,color:e.colorScheme==="dark"?e.colors.dark[0]:e.black,cursor:e.cursorType,order:t==="left"?1:2}),description:{marginTop:`calc(${e.spacing.xs}px / 2)`,[t==="left"?"paddingRight":"paddingLeft"]:e.spacing.sm},error:{marginTop:`calc(${e.spacing.xs}px / 2)`,[t==="left"?"paddingRight":"paddingLeft"]:e.spacing.sm},label:{cursor:e.cursorType,[t==="left"?"paddingRight":"paddingLeft"]:e.spacing.sm,"&[data-disabled]":{color:e.colorScheme==="dark"?e.colors.dark[3]:e.colors.gray[5]}}})),cCe=Object.defineProperty,PS=Object.getOwnPropertySymbols,XJ=Object.prototype.hasOwnProperty,JJ=Object.prototype.propertyIsEnumerable,yB=(e,t,n)=>t in e?cCe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,fCe=(e,t)=>{for(var n in t||(t={}))XJ.call(t,n)&&yB(e,n,t[n]);if(PS)for(var n of PS(t))JJ.call(t,n)&&yB(e,n,t[n]);return e},dCe=(e,t)=>{var n={};for(var r in e)XJ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&PS)for(var r of PS(e))t.indexOf(r)<0&&JJ.call(e,r)&&(n[r]=e[r]);return n};function Q$(e){var t=e,{__staticSelector:n,className:r,classNames:i,styles:s,unstyled:o,children:a,label:u,description:l,id:c,disabled:f,error:d,size:h,labelPosition:p}=t,m=dCe(t,["__staticSelector","className","classNames","styles","unstyled","children","label","description","id","disabled","error","size","labelPosition"]);const{classes:y,cx:g}=lCe({size:h,labelPosition:p},{name:n,styles:s,classNames:i,unstyled:o});return N.createElement(it,fCe({className:g(y.root,r)},m),N.createElement("div",{className:g(y.body)},a,N.createElement("div",{className:y.labelWrapper},u&&N.createElement("label",{className:y.label,"data-disabled":f||void 0,htmlFor:c},u),l&&N.createElement(Zs.Description,{className:y.description},l),d&&d!=="boolean"&&N.createElement(Zs.Error,{className:y.error},d))))}Q$.displayName="@mantine/core/InlineInput";var hCe=Object.defineProperty,OS=Object.getOwnPropertySymbols,ZJ=Object.prototype.hasOwnProperty,eZ=Object.prototype.propertyIsEnumerable,vB=(e,t,n)=>t in e?hCe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,gb=(e,t)=>{for(var n in t||(t={}))ZJ.call(t,n)&&vB(e,n,t[n]);if(OS)for(var n of OS(t))eZ.call(t,n)&&vB(e,n,t[n]);return e},pCe=(e,t)=>{var n={};for(var r in e)ZJ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&OS)for(var r of OS(e))t.indexOf(r)<0&&eZ.call(e,r)&&(n[r]=e[r]);return n};const mCe={size:"sm",transitionDuration:100,icon:zxe,labelPosition:"right"},Mm=w.forwardRef((e,t)=>{const n=Ve("Checkbox",mCe,e),{className:r,style:i,sx:s,checked:o,disabled:a,color:u,label:l,indeterminate:c,id:f,size:d,radius:h,wrapperProps:p,children:m,classNames:y,styles:g,transitionDuration:v,icon:b,unstyled:S,labelPosition:T,description:E,error:I}=n,A=pCe(n,["className","style","sx","checked","disabled","color","label","indeterminate","id","size","radius","wrapperProps","children","classNames","styles","transitionDuration","icon","unstyled","labelPosition","description","error"]),R=Sxe(),F=tu(f),{systemStyles:L,rest:B}=Qf(A),{classes:J}=eCe({size:(R==null?void 0:R.size)||d,radius:h,color:u,transitionDuration:v,labelPosition:T,error:!!I,indeterminate:c},{name:"Checkbox",classNames:y,styles:g,unstyled:S}),V=R?{checked:R.value.includes(B.value),onChange:R.onChange}:{};return N.createElement(Q$,gb(gb({className:r,sx:s,style:i,id:F,size:(R==null?void 0:R.size)||d,labelPosition:T,label:l,description:E,error:I,disabled:a,__staticSelector:"Checkbox",classNames:y,styles:g,unstyled:S,"data-checked":V.checked||void 0},L),p),N.createElement("div",{className:J.inner},N.createElement("input",gb(gb({id:F,ref:t,type:"checkbox",className:J.input,checked:o,disabled:a},B),V)),N.createElement(b,{indeterminate:c,className:J.icon})))});Mm.displayName="@mantine/core/Checkbox";Mm.Group=YJ;var gCe=lt((e,{fluid:t,size:n,sizes:r})=>({root:{paddingLeft:e.spacing.md,paddingRight:e.spacing.md,maxWidth:t?"100%":e.fn.size({size:n,sizes:r}),marginLeft:"auto",marginRight:"auto"}})),yCe=Object.defineProperty,RS=Object.getOwnPropertySymbols,tZ=Object.prototype.hasOwnProperty,nZ=Object.prototype.propertyIsEnumerable,_B=(e,t,n)=>t in e?yCe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,vCe=(e,t)=>{for(var n in t||(t={}))tZ.call(t,n)&&_B(e,n,t[n]);if(RS)for(var n of RS(t))nZ.call(t,n)&&_B(e,n,t[n]);return e},_Ce=(e,t)=>{var n={};for(var r in e)tZ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&RS)for(var r of RS(e))t.indexOf(r)<0&&nZ.call(e,r)&&(n[r]=e[r]);return n};const bCe={sizes:{xs:540,sm:720,md:960,lg:1140,xl:1320}},rZ=w.forwardRef((e,t)=>{const n=Ve("Container",bCe,e),{className:r,fluid:i,size:s,unstyled:o,sizes:a}=n,u=_Ce(n,["className","fluid","size","unstyled","sizes"]),{classes:l,cx:c}=gCe({fluid:i,size:s,sizes:a},{unstyled:o,name:"Container"});return N.createElement(it,vCe({className:c(l.root,r),ref:t},u))});rZ.displayName="@mantine/core/Container";function iZ({transitions:e,duration:t=250,exitDuration:n=t,mounted:r,children:i,timingFunction:s,onExit:o,onEntered:a,onEnter:u,onExited:l}){const{transitionDuration:c,transitionStatus:f,transitionTimingFunction:d}=VX({mounted:r,duration:t,exitDuration:n,timingFunction:s,onExit:o,onEntered:a,onEnter:u,onExited:l});if(c===0)return r?N.createElement(N.Fragment,null,i({})):null;if(f==="exited")return null;const h=Object.keys(e).reduce((p,m)=>(p[m]=UX({duration:e[m].duration,transition:e[m].transition,timingFunction:e[m].timingFunction||d,state:f}),p),{});return N.createElement(N.Fragment,null,i(h))}iZ.displayName="@mantine/core/GroupedTransition";var wCe=lt((e,{zIndex:t})=>({root:{position:"absolute",top:0,bottom:0,left:0,right:0,zIndex:t}})),ECe=Object.defineProperty,SCe=Object.defineProperties,TCe=Object.getOwnPropertyDescriptors,NS=Object.getOwnPropertySymbols,sZ=Object.prototype.hasOwnProperty,oZ=Object.prototype.propertyIsEnumerable,bB=(e,t,n)=>t in e?ECe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,UP=(e,t)=>{for(var n in t||(t={}))sZ.call(t,n)&&bB(e,n,t[n]);if(NS)for(var n of NS(t))oZ.call(t,n)&&bB(e,n,t[n]);return e},ICe=(e,t)=>SCe(e,TCe(t)),xCe=(e,t)=>{var n={};for(var r in e)sZ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&NS)for(var r of NS(e))t.indexOf(r)<0&&oZ.call(e,r)&&(n[r]=e[r]);return n};const CCe={opacity:.6,color:"#fff",zIndex:cc("modal"),radius:0,blur:0},aZ=w.forwardRef((e,t)=>{const n=Ve("Overlay",CCe,e),{opacity:r,blur:i,color:s,gradient:o,zIndex:a,radius:u,sx:l,unstyled:c,className:f}=n,d=xCe(n,["opacity","blur","color","gradient","zIndex","radius","sx","unstyled","className"]),{classes:h,cx:p}=wCe({zIndex:a},{name:"Overlay",unstyled:c}),m=o?{backgroundImage:o}:{backgroundColor:s},y=g=>N.createElement(it,UP({ref:t,className:p(h.root,f),sx:[v=>ICe(UP({},m),{opacity:r,borderRadius:v.fn.size({size:u,sizes:v.radius})}),...lh(l)]},g));return i?N.createElement(it,UP({className:p(h.root,f),sx:[{backdropFilter:`blur(${i}px)`},...lh(l)]},d),y()):y(d)});aZ.displayName="@mantine/core/Overlay";const ACe=aZ,PCe={gap:{type:"spacing",property:"gap"},rowGap:{type:"spacing",property:"rowGap"},columnGap:{type:"spacing",property:"columnGap"},align:{type:"default",property:"alignItems"},justify:{type:"default",property:"justifyContent"},wrap:{type:"default",property:"flexWrap"},direction:{type:"default",property:"flexDirection"}};var OCe=Object.defineProperty,RCe=Object.defineProperties,NCe=Object.getOwnPropertyDescriptors,kS=Object.getOwnPropertySymbols,uZ=Object.prototype.hasOwnProperty,lZ=Object.prototype.propertyIsEnumerable,wB=(e,t,n)=>t in e?OCe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,kCe=(e,t)=>{for(var n in t||(t={}))uZ.call(t,n)&&wB(e,n,t[n]);if(kS)for(var n of kS(t))lZ.call(t,n)&&wB(e,n,t[n]);return e},DCe=(e,t)=>RCe(e,NCe(t)),$Ce=(e,t)=>{var n={};for(var r in e)uZ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&kS)for(var r of kS(e))t.indexOf(r)<0&&lZ.call(e,r)&&(n[r]=e[r]);return n};const LCe={},Fm=w.forwardRef((e,t)=>{const n=Ve("Flex",LCe,e),{gap:r,rowGap:i,columnGap:s,align:o,justify:a,wrap:u,direction:l,sx:c}=n,f=$Ce(n,["gap","rowGap","columnGap","align","justify","wrap","direction","sx"]);return N.createElement(it,DCe(kCe({},f),{sx:[{display:"flex"},d=>UR({gap:r,rowGap:i,columnGap:s,align:o,justify:a,wrap:u,direction:l},d,PCe),...lh(c)],ref:t}))});Fm.displayName="@mantine/core/Flex";const[MCe,FCe]=N_("Grid component was not found in tree");var BCe=Object.defineProperty,EB=Object.getOwnPropertySymbols,jCe=Object.prototype.hasOwnProperty,UCe=Object.prototype.propertyIsEnumerable,SB=(e,t,n)=>t in e?BCe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,VCe=(e,t)=>{for(var n in t||(t={}))jCe.call(t,n)&&SB(e,n,t[n]);if(EB)for(var n of EB(t))UCe.call(t,n)&&SB(e,n,t[n]);return e};const X$=(e,t)=>e==="content"?"auto":e==="auto"?"0px":e?`${100/(t/e)}%`:void 0,cZ=(e,t,n)=>n||e==="auto"||e==="content"?"unset":X$(e,t),fZ=(e,t)=>{if(e)return e==="auto"||t?1:0},dZ=(e,t)=>e===0?0:e?`${100/(t/e)}%`:void 0,hZ=(e,t)=>typeof e<"u"?t.fn.size({size:e,sizes:t.spacing})/2:void 0;function zCe({sizes:e,offsets:t,orders:n,theme:r,columns:i,gutters:s,grow:o}){return hK.reduce((a,u)=>(a[`@media (min-width: ${r.breakpoints[u]}px)`]={order:n[u],flexBasis:X$(e[u],i),padding:hZ(s[u],r),flexShrink:0,width:e[u]==="content"?"auto":void 0,maxWidth:cZ(e[u],i,o),marginLeft:dZ(t[u],i),flexGrow:fZ(e[u],o)},a),{})}var HCe=lt((e,{gutter:t,gutterXs:n,gutterSm:r,gutterMd:i,gutterLg:s,gutterXl:o,grow:a,offset:u,offsetXs:l,offsetSm:c,offsetMd:f,offsetLg:d,offsetXl:h,columns:p,span:m,xs:y,sm:g,md:v,lg:b,xl:S,order:T,orderXs:E,orderSm:I,orderMd:A,orderLg:R,orderXl:F})=>({col:VCe({boxSizing:"border-box",flexGrow:fZ(m,a),order:T,padding:hZ(t,e),marginLeft:dZ(u,p),flexBasis:X$(m,p),flexShrink:0,width:m==="content"?"auto":void 0,maxWidth:cZ(m,p,a)},zCe({sizes:{xs:y,sm:g,md:v,lg:b,xl:S},offsets:{xs:l,sm:c,md:f,lg:d,xl:h},orders:{xs:E,sm:I,md:A,lg:R,xl:F},gutters:{xs:n,sm:r,md:i,lg:s,xl:o},theme:e,columns:p,grow:a}))}));const WCe=HCe;var qCe=Object.defineProperty,DS=Object.getOwnPropertySymbols,pZ=Object.prototype.hasOwnProperty,mZ=Object.prototype.propertyIsEnumerable,TB=(e,t,n)=>t in e?qCe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,GCe=(e,t)=>{for(var n in t||(t={}))pZ.call(t,n)&&TB(e,n,t[n]);if(DS)for(var n of DS(t))mZ.call(t,n)&&TB(e,n,t[n]);return e},YCe=(e,t)=>{var n={};for(var r in e)pZ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&DS)for(var r of DS(e))t.indexOf(r)<0&&mZ.call(e,r)&&(n[r]=e[r]);return n};const KCe={};function QCe(e){return e==="auto"||e==="content"?!0:typeof e=="number"&&e>0&&e%1===0}const gZ=w.forwardRef((e,t)=>{const n=Ve("GridCol",KCe,e),{children:r,span:i,offset:s,offsetXs:o,offsetSm:a,offsetMd:u,offsetLg:l,offsetXl:c,xs:f,sm:d,md:h,lg:p,xl:m,order:y,orderXs:g,orderSm:v,orderMd:b,orderLg:S,orderXl:T,className:E,id:I,unstyled:A}=n,R=YCe(n,["children","span","offset","offsetXs","offsetSm","offsetMd","offsetLg","offsetXl","xs","sm","md","lg","xl","order","orderXs","orderSm","orderMd","orderLg","orderXl","className","id","unstyled"]),F=FCe(),L=i||F.columns,{classes:B,cx:J}=WCe({gutter:F.gutter,gutterXs:F.gutterXs,gutterSm:F.gutterSm,gutterMd:F.gutterMd,gutterLg:F.gutterLg,gutterXl:F.gutterXl,offset:s,offsetXs:o,offsetSm:a,offsetMd:u,offsetLg:l,offsetXl:c,xs:f,sm:d,md:h,lg:p,xl:m,order:y,orderXs:g,orderSm:v,orderMd:b,orderLg:S,orderXl:T,grow:F.grow,columns:F.columns,span:L},{unstyled:A,name:"Grid"});return!QCe(L)||L>F.columns?null:N.createElement(it,GCe({className:J(B.col,E),ref:t},R),r)});gZ.displayName="@mantine/core/Col";var XCe=Object.defineProperty,IB=Object.getOwnPropertySymbols,JCe=Object.prototype.hasOwnProperty,ZCe=Object.prototype.propertyIsEnumerable,xB=(e,t,n)=>t in e?XCe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,eAe=(e,t)=>{for(var n in t||(t={}))JCe.call(t,n)&&xB(e,n,t[n]);if(IB)for(var n of IB(t))ZCe.call(t,n)&&xB(e,n,t[n]);return e};function tAe(e,t){return hK.reduce((n,r)=>(typeof e[r]<"u"&&(n[`@media (min-width: ${t.breakpoints[r]}px)`]={margin:-t.fn.size({size:e[r],sizes:t.spacing})/2}),n),{})}var nAe=lt((e,{justify:t,align:n,gutter:r,gutterXs:i,gutterSm:s,gutterMd:o,gutterLg:a,gutterXl:u})=>({root:eAe({margin:-e.fn.size({size:r,sizes:e.spacing})/2,display:"flex",flexWrap:"wrap",justifyContent:t,alignItems:n},tAe({xs:i,sm:s,md:o,lg:a,xl:u},e))})),rAe=Object.defineProperty,$S=Object.getOwnPropertySymbols,yZ=Object.prototype.hasOwnProperty,vZ=Object.prototype.propertyIsEnumerable,CB=(e,t,n)=>t in e?rAe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,iAe=(e,t)=>{for(var n in t||(t={}))yZ.call(t,n)&&CB(e,n,t[n]);if($S)for(var n of $S(t))vZ.call(t,n)&&CB(e,n,t[n]);return e},sAe=(e,t)=>{var n={};for(var r in e)yZ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&$S)for(var r of $S(e))t.indexOf(r)<0&&vZ.call(e,r)&&(n[r]=e[r]);return n};const oAe={gutter:"md",justify:"flex-start",align:"stretch",columns:12},Rl=w.forwardRef((e,t)=>{const n=Ve("Grid",oAe,e),{gutter:r,gutterXs:i,gutterSm:s,gutterMd:o,gutterLg:a,gutterXl:u,children:l,grow:c,justify:f,align:d,columns:h,className:p,id:m,unstyled:y}=n,g=sAe(n,["gutter","gutterXs","gutterSm","gutterMd","gutterLg","gutterXl","children","grow","justify","align","columns","className","id","unstyled"]),{classes:v,cx:b}=nAe({gutter:r,justify:f,align:d,gutterXs:i,gutterSm:s,gutterMd:o,gutterLg:a,gutterXl:u},{unstyled:y,name:"Grid"});return N.createElement(MCe,{value:{gutter:r,gutterXs:i,gutterSm:s,gutterMd:o,gutterLg:a,gutterXl:u,grow:c,columns:h}},N.createElement(it,iAe({className:b(v.root,p),ref:t},g),l))});Rl.Col=gZ;Rl.displayName="@mantine/core/Grid";var aAe=lt((e,{color:t})=>({root:{backgroundColor:e.fn.themeColor(t,e.colorScheme==="dark"?5:2),color:e.colorScheme==="dark"?e.colors.dark[9]:"inherit"}})),uAe=Object.defineProperty,LS=Object.getOwnPropertySymbols,_Z=Object.prototype.hasOwnProperty,bZ=Object.prototype.propertyIsEnumerable,AB=(e,t,n)=>t in e?uAe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,lAe=(e,t)=>{for(var n in t||(t={}))_Z.call(t,n)&&AB(e,n,t[n]);if(LS)for(var n of LS(t))bZ.call(t,n)&&AB(e,n,t[n]);return e},cAe=(e,t)=>{var n={};for(var r in e)_Z.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&LS)for(var r of LS(e))t.indexOf(r)<0&&bZ.call(e,r)&&(n[r]=e[r]);return n};const fAe={color:"yellow"},wZ=w.forwardRef((e,t)=>{const n=Ve("Mark",fAe,e),{color:r,className:i,unstyled:s}=n,o=cAe(n,["color","className","unstyled"]),{classes:a,cx:u}=aAe({color:r},{unstyled:s,name:"Mark"});return N.createElement(it,lAe({component:"mark",ref:t,className:u(a.root,i)},o))});wZ.displayName="@mantine/core/Mark";function PB(e){return e.replace(/[-[\]{}()*+?.,\\^$|#]/g,"\\$&")}function dAe(e,t){if(t==null)return[{chunk:e,highlighted:!1}];const n=Array.isArray(t)?t.map(PB):PB(t);if(!(Array.isArray(n)?n.filter(a=>a.trim().length>0).length>0:n.trim()!==""))return[{chunk:e,highlighted:!1}];const i=typeof n=="string"?n.trim():n.filter(a=>a.trim().length!==0).map(a=>a.trim()).join("|"),s=new RegExp(`(${i})`,"gi");return e.split(s).map(a=>({chunk:a,highlighted:s.test(a)})).filter(({chunk:a})=>a)}var hAe=Object.defineProperty,MS=Object.getOwnPropertySymbols,EZ=Object.prototype.hasOwnProperty,SZ=Object.prototype.propertyIsEnumerable,OB=(e,t,n)=>t in e?hAe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,pAe=(e,t)=>{for(var n in t||(t={}))EZ.call(t,n)&&OB(e,n,t[n]);if(MS)for(var n of MS(t))SZ.call(t,n)&&OB(e,n,t[n]);return e},mAe=(e,t)=>{var n={};for(var r in e)EZ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&MS)for(var r of MS(e))t.indexOf(r)<0&&SZ.call(e,r)&&(n[r]=e[r]);return n};const gAe={highlightColor:"yellow"},TZ=w.forwardRef((e,t)=>{const n=Ve("Highlight",gAe,e),{children:r,highlight:i,highlightColor:s,highlightStyles:o,unstyled:a}=n,u=mAe(n,["children","highlight","highlightColor","highlightStyles","unstyled"]),l=dAe(r,i);return N.createElement(rt,pAe({unstyled:a,ref:t},u),l.map(({chunk:c,highlighted:f},d)=>f?N.createElement(wZ,{unstyled:a,key:d,color:s,sx:o},c):N.createElement("span",{key:d},c)))});TZ.displayName="@mantine/core/Highlight";const yAe=TZ,IZ={context:"HoverCard component was not found in the tree",children:"HoverCard.Target component children should be an element or a component that accepts ref, fragments, strings, numbers and other primitive values are not supported"},[vAe,xZ]=N_(IZ.context);var _Ae=Object.defineProperty,FS=Object.getOwnPropertySymbols,CZ=Object.prototype.hasOwnProperty,AZ=Object.prototype.propertyIsEnumerable,RB=(e,t,n)=>t in e?_Ae(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,bAe=(e,t)=>{for(var n in t||(t={}))CZ.call(t,n)&&RB(e,n,t[n]);if(FS)for(var n of FS(t))AZ.call(t,n)&&RB(e,n,t[n]);return e},wAe=(e,t)=>{var n={};for(var r in e)CZ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&FS)for(var r of FS(e))t.indexOf(r)<0&&AZ.call(e,r)&&(n[r]=e[r]);return n};const EAe={};function PZ(e){const t=Ve("HoverCardDropdown",EAe,e),{children:n,onMouseEnter:r,onMouseLeave:i}=t,s=wAe(t,["children","onMouseEnter","onMouseLeave"]),o=xZ(),a=wo(r,o.openDropdown),u=wo(i,o.closeDropdown);return N.createElement(yi.Dropdown,bAe({onMouseEnter:a,onMouseLeave:u},s),n)}PZ.displayName="@mantine/core/HoverCardDropdown";var SAe=Object.defineProperty,BS=Object.getOwnPropertySymbols,OZ=Object.prototype.hasOwnProperty,RZ=Object.prototype.propertyIsEnumerable,NB=(e,t,n)=>t in e?SAe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,TAe=(e,t)=>{for(var n in t||(t={}))OZ.call(t,n)&&NB(e,n,t[n]);if(BS)for(var n of BS(t))RZ.call(t,n)&&NB(e,n,t[n]);return e},IAe=(e,t)=>{var n={};for(var r in e)OZ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&BS)for(var r of BS(e))t.indexOf(r)<0&&RZ.call(e,r)&&(n[r]=e[r]);return n};const xAe={refProp:"ref"},NZ=w.forwardRef((e,t)=>{const n=Ve("HoverCardTarget",xAe,e),{children:r,refProp:i}=n,s=IAe(n,["children","refProp"]);if(!_g(r))throw new Error(IZ.children);const o=xZ(),a=wo(r.props.onMouseEnter,o.openDropdown),u=wo(r.props.onMouseLeave,o.closeDropdown);return N.createElement(yi.Target,TAe({refProp:i,ref:t},s),w.cloneElement(r,{onMouseEnter:a,onMouseLeave:u}))});NZ.displayName="@mantine/core/HoverCardTarget";function kZ({open:e,close:t,openDelay:n,closeDelay:r}){const i=w.useRef(-1),s=w.useRef(-1),o=()=>{window.clearTimeout(i.current),window.clearTimeout(s.current)},a=()=>{o(),n===0?e():i.current=window.setTimeout(e,n)},u=()=>{o(),r===0?t():s.current=window.setTimeout(t,r)};return w.useEffect(()=>o,[]),{openDropdown:a,closeDropdown:u}}var CAe=Object.defineProperty,jS=Object.getOwnPropertySymbols,DZ=Object.prototype.hasOwnProperty,$Z=Object.prototype.propertyIsEnumerable,kB=(e,t,n)=>t in e?CAe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,AAe=(e,t)=>{for(var n in t||(t={}))DZ.call(t,n)&&kB(e,n,t[n]);if(jS)for(var n of jS(t))$Z.call(t,n)&&kB(e,n,t[n]);return e},PAe=(e,t)=>{var n={};for(var r in e)DZ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&jS)for(var r of jS(e))t.indexOf(r)<0&&$Z.call(e,r)&&(n[r]=e[r]);return n};const OAe={openDelay:0,closeDelay:150,initiallyOpened:!1};function em(e){const t=Ve("HoverCard",OAe,e),{children:n,onOpen:r,onClose:i,openDelay:s,closeDelay:o,initiallyOpened:a}=t,u=PAe(t,["children","onOpen","onClose","openDelay","closeDelay","initiallyOpened"]),[l,{open:c,close:f}]=I$(a,{onClose:i,onOpen:r}),{openDropdown:d,closeDropdown:h}=kZ({open:c,close:f,openDelay:s,closeDelay:o});return N.createElement(vAe,{value:{openDropdown:d,closeDropdown:h}},N.createElement(yi,AAe({opened:l,__staticSelector:"HoverCard"},u),n))}em.displayName="@mantine/core/HoverCard";em.Target=NZ;em.Dropdown=PZ;var RAe=Object.defineProperty,DB=Object.getOwnPropertySymbols,NAe=Object.prototype.hasOwnProperty,kAe=Object.prototype.propertyIsEnumerable,$B=(e,t,n)=>t in e?RAe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,DAe=(e,t)=>{for(var n in t||(t={}))NAe.call(t,n)&&$B(e,n,t[n]);if(DB)for(var n of DB(t))kAe.call(t,n)&&$B(e,n,t[n]);return e};function $Ae(e){return N.createElement("svg",DAe({width:"15",height:"15",viewBox:"0 0 15 15",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e),N.createElement("path",{d:"M2.5 1H12.5C13.3284 1 14 1.67157 14 2.5V12.5C14 13.3284 13.3284 14 12.5 14H2.5C1.67157 14 1 13.3284 1 12.5V2.5C1 1.67157 1.67157 1 2.5 1ZM2.5 2C2.22386 2 2 2.22386 2 2.5V8.3636L3.6818 6.6818C3.76809 6.59551 3.88572 6.54797 4.00774 6.55007C4.12975 6.55216 4.24568 6.60372 4.32895 6.69293L7.87355 10.4901L10.6818 7.6818C10.8575 7.50607 11.1425 7.50607 11.3182 7.6818L13 9.3636V2.5C13 2.22386 12.7761 2 12.5 2H2.5ZM2 12.5V9.6364L3.98887 7.64753L7.5311 11.4421L8.94113 13H2.5C2.22386 13 2 12.7761 2 12.5ZM12.5 13H10.155L8.48336 11.153L11 8.6364L13 10.6364V12.5C13 12.7761 12.7761 13 12.5 13ZM6.64922 5.5C6.64922 5.03013 7.03013 4.64922 7.5 4.64922C7.96987 4.64922 8.35078 5.03013 8.35078 5.5C8.35078 5.96987 7.96987 6.35078 7.5 6.35078C7.03013 6.35078 6.64922 5.96987 6.64922 5.5ZM7.5 3.74922C6.53307 3.74922 5.74922 4.53307 5.74922 5.5C5.74922 6.46693 6.53307 7.25078 7.5 7.25078C8.46693 7.25078 9.25078 6.46693 9.25078 5.5C9.25078 4.53307 8.46693 3.74922 7.5 3.74922Z",fill:"currentColor",fillRule:"evenodd",clipRule:"evenodd"}))}var LAe=Object.defineProperty,MAe=Object.defineProperties,FAe=Object.getOwnPropertyDescriptors,LB=Object.getOwnPropertySymbols,BAe=Object.prototype.hasOwnProperty,jAe=Object.prototype.propertyIsEnumerable,MB=(e,t,n)=>t in e?LAe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,FB=(e,t)=>{for(var n in t||(t={}))BAe.call(t,n)&&MB(e,n,t[n]);if(LB)for(var n of LB(t))jAe.call(t,n)&&MB(e,n,t[n]);return e},BB=(e,t)=>MAe(e,FAe(t)),UAe=lt((e,{radius:t})=>({root:{},imageWrapper:{position:"relative"},figure:{margin:0},image:BB(FB({},e.fn.fontStyles()),{display:"block",width:"100%",height:"100%",border:0,borderRadius:e.fn.size({size:t,sizes:e.radius})}),caption:{color:e.colorScheme==="dark"?e.colors.dark[2]:e.colors.gray[7],marginTop:e.spacing.xs},placeholder:BB(FB({},e.fn.cover()),{display:"flex",alignItems:"center",justifyContent:"center",color:e.colorScheme==="dark"?e.colors.dark[2]:e.colors.gray[6],backgroundColor:e.colorScheme==="dark"?e.colors.dark[8]:e.colors.gray[0],borderRadius:e.fn.size({size:t,sizes:e.radius})})})),VAe=Object.defineProperty,US=Object.getOwnPropertySymbols,LZ=Object.prototype.hasOwnProperty,MZ=Object.prototype.propertyIsEnumerable,jB=(e,t,n)=>t in e?VAe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,VP=(e,t)=>{for(var n in t||(t={}))LZ.call(t,n)&&jB(e,n,t[n]);if(US)for(var n of US(t))MZ.call(t,n)&&jB(e,n,t[n]);return e},zAe=(e,t)=>{var n={};for(var r in e)LZ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&US)for(var r of US(e))t.indexOf(r)<0&&MZ.call(e,r)&&(n[r]=e[r]);return n};const HAe={fit:"cover",width:"100%",height:"auto",radius:0},B_=w.forwardRef((e,t)=>{const n=Ve("Image",HAe,e),{className:r,alt:i,src:s,fit:o,width:a,height:u,radius:l,imageProps:c,withPlaceholder:f,placeholder:d,imageRef:h,classNames:p,styles:m,caption:y,unstyled:g,style:v}=n,b=zAe(n,["className","alt","src","fit","width","height","radius","imageProps","withPlaceholder","placeholder","imageRef","classNames","styles","caption","unstyled","style"]),{classes:S,cx:T}=UAe({radius:l},{classNames:p,styles:m,unstyled:g,name:"Image"}),[E,I]=w.useState(!s),A=f&&E;return Js(()=>{I(!s)},[s]),N.createElement(it,VP({className:T(S.root,r),ref:t,style:VP({width:a},v)},b),N.createElement("figure",{className:S.figure},N.createElement("div",{className:S.imageWrapper},N.createElement("img",VP({className:S.image,src:s,alt:i,style:{objectFit:o,width:a,height:u},ref:h,onError:R=>{I(!0),typeof(c==null?void 0:c.onError)=="function"&&c.onError(R)}},c)),A&&N.createElement("div",{className:S.placeholder,title:i},d||N.createElement("div",null,N.createElement($Ae,{style:{width:40,height:40}})))),!!y&&N.createElement(rt,{component:"figcaption",size:"sm",align:"center",className:S.caption},y)))});B_.displayName="@mantine/core/Image";function WAe(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,s;for(s=0;s=0)&&(n[i]=e[i]);return n}var qAe=w.useLayoutEffect,GAe=function(t){var n=w.useRef(t);return qAe(function(){n.current=t}),n},UB=function(t,n){if(typeof t=="function"){t(n);return}t.current=n},YAe=function(t,n){var r=w.useRef();return w.useCallback(function(i){t.current=i,r.current&&UB(r.current,null),r.current=n,n&&UB(n,i)},[n])},VB={"min-height":"0","max-height":"none",height:"0",visibility:"hidden",overflow:"hidden",position:"absolute","z-index":"-1000",top:"0",right:"0"},zB=function(t){Object.keys(VB).forEach(function(n){t.style.setProperty(n,VB[n],"important")})},fo=null,KAe=function(t,n){var r=t.scrollHeight;return n.sizingStyle.boxSizing==="border-box"?r+n.borderSize:r-n.paddingSize};function QAe(e,t,n,r){n===void 0&&(n=1),r===void 0&&(r=1/0),fo||(fo=document.createElement("textarea"),fo.setAttribute("tabindex","-1"),fo.setAttribute("aria-hidden","true"),zB(fo)),fo.parentNode===null&&document.body.appendChild(fo);var i=e.paddingSize,s=e.borderSize,o=e.sizingStyle,a=o.boxSizing;Object.keys(o).forEach(function(d){var h=d;fo.style[h]=o[h]}),zB(fo),fo.value=t;var u=KAe(fo,e);fo.value="x";var l=fo.scrollHeight-i,c=l*n;a==="border-box"&&(c=c+i+s),u=Math.max(c,u);var f=l*r;return a==="border-box"&&(f=f+i+s),u=Math.min(f,u),[u,l]}var HB=function(){},XAe=function(t,n){return t.reduce(function(r,i){return r[i]=n[i],r},{})},JAe=["borderBottomWidth","borderLeftWidth","borderRightWidth","borderTopWidth","boxSizing","fontFamily","fontSize","fontStyle","fontWeight","letterSpacing","lineHeight","paddingBottom","paddingLeft","paddingRight","paddingTop","tabSize","textIndent","textRendering","textTransform","width","wordBreak"],ZAe=!!document.documentElement.currentStyle,ePe=function(t){var n=window.getComputedStyle(t);if(n===null)return null;var r=XAe(JAe,n),i=r.boxSizing;if(i==="")return null;ZAe&&i==="border-box"&&(r.width=parseFloat(r.width)+parseFloat(r.borderRightWidth)+parseFloat(r.borderLeftWidth)+parseFloat(r.paddingRight)+parseFloat(r.paddingLeft)+"px");var s=parseFloat(r.paddingBottom)+parseFloat(r.paddingTop),o=parseFloat(r.borderBottomWidth)+parseFloat(r.borderTopWidth);return{sizingStyle:r,paddingSize:s,borderSize:o}},tPe=function(t){var n=GAe(t);w.useLayoutEffect(function(){var r=function(s){n.current(s)};return window.addEventListener("resize",r),function(){window.removeEventListener("resize",r)}},[])},nPe=function(t,n){var r=t.cacheMeasurements,i=t.maxRows,s=t.minRows,o=t.onChange,a=o===void 0?HB:o,u=t.onHeightChange,l=u===void 0?HB:u,c=WAe(t,["cacheMeasurements","maxRows","minRows","onChange","onHeightChange"]),f=c.value!==void 0,d=w.useRef(null),h=YAe(d,n),p=w.useRef(0),m=w.useRef(),y=function(){var b=d.current,S=r&&m.current?m.current:ePe(b);if(S){m.current=S;var T=QAe(S,b.value||b.placeholder||"x",s,i),E=T[0],I=T[1];p.current!==E&&(p.current=E,b.style.setProperty("height",E+"px","important"),l(E,{rowHeight:I}))}},g=function(b){f||y(),a(b)};return w.useLayoutEffect(y),tPe(y),w.createElement("textarea",pr({},c,{onChange:g,ref:h}))},rPe=w.forwardRef(nPe);const iPe=rPe;var sPe=lt(e=>({input:{paddingTop:e.spacing.xs,paddingBottom:e.spacing.xs}})),oPe=Object.defineProperty,aPe=Object.defineProperties,uPe=Object.getOwnPropertyDescriptors,VS=Object.getOwnPropertySymbols,FZ=Object.prototype.hasOwnProperty,BZ=Object.prototype.propertyIsEnumerable,WB=(e,t,n)=>t in e?oPe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Jh=(e,t)=>{for(var n in t||(t={}))FZ.call(t,n)&&WB(e,n,t[n]);if(VS)for(var n of VS(t))BZ.call(t,n)&&WB(e,n,t[n]);return e},zP=(e,t)=>aPe(e,uPe(t)),lPe=(e,t)=>{var n={};for(var r in e)FZ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&VS)for(var r of VS(e))t.indexOf(r)<0&&BZ.call(e,r)&&(n[r]=e[r]);return n};const cPe={autosize:!1,size:"sm",__staticSelector:"Textarea"},jZ=w.forwardRef((e,t)=>{const n=Ve("Textarea",cPe,e),{autosize:r,maxRows:i,minRows:s,label:o,error:a,description:u,id:l,className:c,required:f,style:d,wrapperProps:h,classNames:p,styles:m,size:y,__staticSelector:g,sx:v,errorProps:b,descriptionProps:S,labelProps:T,inputWrapperOrder:E,inputContainer:I,unstyled:A,withAsterisk:R}=n,F=lPe(n,["autosize","maxRows","minRows","label","error","description","id","className","required","style","wrapperProps","classNames","styles","size","__staticSelector","sx","errorProps","descriptionProps","labelProps","inputWrapperOrder","inputContainer","unstyled","withAsterisk"]),L=tu(l),{classes:B,cx:J}=sPe(),{systemStyles:V,rest:re}=Qf(F),oe=Jh({required:f,ref:t,invalid:!!a,id:L,classNames:zP(Jh({},p),{input:J(B.input,p==null?void 0:p.input)}),styles:m,__staticSelector:g,size:y,multiline:!0,unstyled:A},re);return N.createElement(Zs.Wrapper,Jh(Jh({label:o,error:a,id:L,description:u,required:f,style:d,className:c,classNames:p,styles:m,size:y,__staticSelector:g,sx:v,errorProps:b,labelProps:T,descriptionProps:S,inputContainer:I,inputWrapperOrder:E,unstyled:A,withAsterisk:R},V),h),r?N.createElement(Zs,zP(Jh({},oe),{component:iPe,maxRows:i,minRows:s})):N.createElement(Zs,zP(Jh({},oe),{component:"textarea",rows:s})))});jZ.displayName="@mantine/core/Textarea";const[fPe,dPe]=N_("List component was not found in tree");var hPe=lt((e,{spacing:t,center:n},r)=>({itemWrapper:{ref:r("itemWrapper"),display:"inline-flex",flexDirection:"column",whiteSpace:"normal"},item:{whiteSpace:"nowrap",lineHeight:n?1:e.lineHeight,"&:not(:first-of-type)":{marginTop:e.fn.size({size:t,sizes:e.spacing})}},withIcon:{listStyle:"none",[`& .${r("itemWrapper")}`]:{display:"inline-flex",alignItems:n?"center":"flex-start",flexDirection:"row"}},itemIcon:{display:"inline-block",verticalAlign:"middle",marginRight:e.spacing.sm}})),pPe=Object.defineProperty,zS=Object.getOwnPropertySymbols,UZ=Object.prototype.hasOwnProperty,VZ=Object.prototype.propertyIsEnumerable,qB=(e,t,n)=>t in e?pPe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,mPe=(e,t)=>{for(var n in t||(t={}))UZ.call(t,n)&&qB(e,n,t[n]);if(zS)for(var n of zS(t))VZ.call(t,n)&&qB(e,n,t[n]);return e},gPe=(e,t)=>{var n={};for(var r in e)UZ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&zS)for(var r of zS(e))t.indexOf(r)<0&&VZ.call(e,r)&&(n[r]=e[r]);return n};const yPe={},zZ=w.forwardRef((e,t)=>{const n=Ve("ListItem",yPe,e),{className:r,children:i,icon:s}=n,o=gPe(n,["className","children","icon"]),{icon:a,spacing:u,center:l,listStyleType:c,size:f,withPadding:d,classNames:h,styles:p,unstyled:m}=dPe(),y=s||a,{classes:g,cx:v}=hPe({withPadding:d,size:f,listStyleType:c,center:l,spacing:u},{classNames:h,styles:p,unstyled:m,name:"List"});return N.createElement(it,mPe({component:"li",className:v(g.item,{[g.withIcon]:y},r),ref:t},o),N.createElement("div",{className:g.itemWrapper},y&&N.createElement("span",{className:g.itemIcon},y),N.createElement("span",null,i)))});zZ.displayName="@mantine/core/ListItem";var vPe=Object.defineProperty,_Pe=Object.defineProperties,bPe=Object.getOwnPropertyDescriptors,GB=Object.getOwnPropertySymbols,wPe=Object.prototype.hasOwnProperty,EPe=Object.prototype.propertyIsEnumerable,YB=(e,t,n)=>t in e?vPe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,SPe=(e,t)=>{for(var n in t||(t={}))wPe.call(t,n)&&YB(e,n,t[n]);if(GB)for(var n of GB(t))EPe.call(t,n)&&YB(e,n,t[n]);return e},TPe=(e,t)=>_Pe(e,bPe(t)),IPe=lt((e,{withPadding:t,size:n,listStyleType:r})=>({root:TPe(SPe({},e.fn.fontStyles()),{listStyleType:r,color:e.colorScheme==="dark"?e.colors.dark[0]:e.black,fontSize:e.fn.size({size:n,sizes:e.fontSizes}),lineHeight:e.lineHeight,margin:0,paddingLeft:t?e.spacing.xl:0,listStylePosition:"inside"})})),xPe=Object.defineProperty,HS=Object.getOwnPropertySymbols,HZ=Object.prototype.hasOwnProperty,WZ=Object.prototype.propertyIsEnumerable,KB=(e,t,n)=>t in e?xPe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,CPe=(e,t)=>{for(var n in t||(t={}))HZ.call(t,n)&&KB(e,n,t[n]);if(HS)for(var n of HS(t))WZ.call(t,n)&&KB(e,n,t[n]);return e},APe=(e,t)=>{var n={};for(var r in e)HZ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&HS)for(var r of HS(e))t.indexOf(r)<0&&WZ.call(e,r)&&(n[r]=e[r]);return n};const PPe={type:"unordered",size:"md",spacing:0},Bm=w.forwardRef((e,t)=>{const n=Ve("List",PPe,e),{children:r,type:i,size:s,listStyleType:o,withPadding:a,center:u,spacing:l,icon:c,className:f,styles:d,classNames:h,unstyled:p}=n,m=APe(n,["children","type","size","listStyleType","withPadding","center","spacing","icon","className","styles","classNames","unstyled"]),{classes:y,cx:g}=IPe({withPadding:a,size:s,listStyleType:o,center:u,spacing:l},{classNames:h,styles:d,name:"List",unstyled:p});return N.createElement(fPe,{value:{spacing:l,center:u,icon:c,listStyleType:o,size:s,withPadding:a,classNames:h,styles:d,unstyled:p}},N.createElement(it,CPe({component:i==="unordered"?"ul":"ol",className:g(y.root,f),ref:t},m),r))});Bm.Item=zZ;Bm.displayName="@mantine/core/List";const qZ={context:"Menu component was not found in the tree",children:"Menu.Target component children should be an element or a component that accepts ref, fragments, strings, numbers and other primitive values are not supported"},[OPe,j_]=N_(qZ.context);var RPe=lt(e=>({divider:{margin:`calc(${e.spacing.xs}px / 2) -5px`,borderTop:`1px solid ${e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[2]}`}})),NPe=Object.defineProperty,WS=Object.getOwnPropertySymbols,GZ=Object.prototype.hasOwnProperty,YZ=Object.prototype.propertyIsEnumerable,QB=(e,t,n)=>t in e?NPe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,kPe=(e,t)=>{for(var n in t||(t={}))GZ.call(t,n)&&QB(e,n,t[n]);if(WS)for(var n of WS(t))YZ.call(t,n)&&QB(e,n,t[n]);return e},DPe=(e,t)=>{var n={};for(var r in e)GZ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&WS)for(var r of WS(e))t.indexOf(r)<0&&YZ.call(e,r)&&(n[r]=e[r]);return n};const $Pe={},KZ=w.forwardRef((e,t)=>{const n=Ve("MenuDivider",$Pe,e),{children:r,className:i}=n,s=DPe(n,["children","className"]),{classNames:o,styles:a,unstyled:u}=j_(),{classes:l,cx:c}=RPe(null,{name:"Menu",classNames:o,styles:a,unstyled:u});return N.createElement(it,kPe({className:c(l.divider,i),ref:t},s))});KZ.displayName="@mantine/core/MenuDivider";var LPe=Object.defineProperty,qS=Object.getOwnPropertySymbols,QZ=Object.prototype.hasOwnProperty,XZ=Object.prototype.propertyIsEnumerable,XB=(e,t,n)=>t in e?LPe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,MPe=(e,t)=>{for(var n in t||(t={}))QZ.call(t,n)&&XB(e,n,t[n]);if(qS)for(var n of qS(t))XZ.call(t,n)&&XB(e,n,t[n]);return e},FPe=(e,t)=>{var n={};for(var r in e)QZ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&qS)for(var r of qS(e))t.indexOf(r)<0&&XZ.call(e,r)&&(n[r]=e[r]);return n};const BPe={};function JZ(e){const t=Ve("MenuDropdown",BPe,e),{children:n,onMouseEnter:r,onMouseLeave:i}=t,s=FPe(t,["children","onMouseEnter","onMouseLeave"]),o=w.useRef(),a=j_(),u=f=>{(f.key==="ArrowUp"||f.key==="ArrowDown")&&(f.preventDefault(),o.current.querySelectorAll("[data-menu-item]")[0].focus())},l=wo(r,()=>a.trigger==="hover"&&a.openDropdown()),c=wo(i,()=>a.trigger==="hover"&&a.closeDropdown());return N.createElement(yi.Dropdown,MPe({onMouseEnter:l,onMouseLeave:c,role:"menu","aria-orientation":"vertical"},s),N.createElement("div",{tabIndex:-1,"data-menu-dropdown":!0,"data-autofocus":!0,onKeyDown:u,ref:o,style:{outline:0}},n))}JZ.displayName="@mantine/core/MenuDropdown";var jPe=Object.defineProperty,UPe=Object.defineProperties,VPe=Object.getOwnPropertyDescriptors,JB=Object.getOwnPropertySymbols,zPe=Object.prototype.hasOwnProperty,HPe=Object.prototype.propertyIsEnumerable,ZB=(e,t,n)=>t in e?jPe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,WPe=(e,t)=>{for(var n in t||(t={}))zPe.call(t,n)&&ZB(e,n,t[n]);if(JB)for(var n of JB(t))HPe.call(t,n)&&ZB(e,n,t[n]);return e},qPe=(e,t)=>UPe(e,VPe(t)),GPe=lt((e,{color:t,radius:n})=>({item:qPe(WPe({},e.fn.fontStyles()),{WebkitTapHighlightColor:"transparent",fontSize:e.fontSizes.sm,border:0,backgroundColor:"transparent",outline:0,width:"100%",textAlign:"left",textDecoration:"none",boxSizing:"border-box",padding:`${e.spacing.xs}px ${e.spacing.sm}px`,cursor:"pointer",borderRadius:e.fn.radius(n),color:t?e.fn.variant({variant:"filled",primaryFallback:!1,color:t}).background:e.colorScheme==="dark"?e.colors.dark[0]:e.black,display:"flex",alignItems:"center","&:disabled":{color:e.colorScheme==="dark"?e.colors.dark[3]:e.colors.gray[5],pointerEvents:"none",userSelect:"none"},"&[data-hovered]":{backgroundColor:t?e.fn.variant({variant:"light",color:t}).background:e.colorScheme==="dark"?e.fn.rgba(e.colors.dark[3],.35):e.colors.gray[1]}}),itemLabel:{flex:1},itemIcon:{display:"flex",justifyContent:"center",alignItems:"center",marginRight:e.spacing.xs},itemRightSection:{}}));const YPe=GPe;var KPe=Object.defineProperty,QPe=Object.defineProperties,XPe=Object.getOwnPropertyDescriptors,GS=Object.getOwnPropertySymbols,ZZ=Object.prototype.hasOwnProperty,eee=Object.prototype.propertyIsEnumerable,ej=(e,t,n)=>t in e?KPe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,JPe=(e,t)=>{for(var n in t||(t={}))ZZ.call(t,n)&&ej(e,n,t[n]);if(GS)for(var n of GS(t))eee.call(t,n)&&ej(e,n,t[n]);return e},ZPe=(e,t)=>QPe(e,XPe(t)),eOe=(e,t)=>{var n={};for(var r in e)ZZ.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&GS)for(var r of GS(e))t.indexOf(r)<0&&eee.call(e,r)&&(n[r]=e[r]);return n};const tOe={},tee=w.forwardRef((e,t)=>{const n=Ve("MenuItem",tOe,e),{children:r,className:i,color:s,closeMenuOnClick:o,icon:a,rightSection:u}=n,l=eOe(n,["children","className","color","closeMenuOnClick","icon","rightSection"]),c=j_(),{classes:f,cx:d,theme:h}=YPe({radius:c.radius,color:s},{name:"Menu",classNames:c.classNames,styles:c.styles,unstyled:c.unstyled}),p=w.useRef(),m=c.getItemIndex(p.current),y=l,g=wo(y.onMouseLeave,()=>c.setHovered(-1)),v=wo(y.onMouseEnter,()=>c.setHovered(c.getItemIndex(p.current))),b=wo(y.onClick,()=>{typeof o=="boolean"?o&&c.closeDropdownImmediately():c.closeOnItemClick&&c.closeDropdownImmediately()}),S=wo(y.onFocus,()=>c.setHovered(c.getItemIndex(p.current)));return N.createElement(it,ZPe(JPe({component:"button",type:"button"},l),{tabIndex:-1,onFocus:S,className:d(f.item,i),ref:fa(p,t),role:"menuitem","data-menu-item":!0,"data-hovered":c.hovered===m?!0:void 0,onMouseEnter:v,onMouseLeave:g,onClick:b,onKeyDown:w0e({siblingSelector:"[data-menu-item]",parentSelector:"[data-menu-dropdown]",activateOnFocus:!1,loop:c.loop,dir:h.dir,orientation:"vertical",onKeyDown:y.onKeydown})}),a&&N.createElement("div",{className:f.itemIcon},a),r&&N.createElement("div",{className:f.itemLabel},r),u&&N.createElement("div",{className:f.itemRightSection},u))});tee.displayName="@mantine/core/MenuItem";const nOe=tee;var rOe=lt(e=>({label:{color:e.colorScheme==="dark"?e.colors.dark[2]:e.colors.gray[6],fontWeight:500,fontSize:e.fontSizes.xs,padding:`calc(${e.spacing.xs}px / 2) ${e.spacing.sm}px`,cursor:"default"}})),iOe=Object.defineProperty,YS=Object.getOwnPropertySymbols,nee=Object.prototype.hasOwnProperty,ree=Object.prototype.propertyIsEnumerable,tj=(e,t,n)=>t in e?iOe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,sOe=(e,t)=>{for(var n in t||(t={}))nee.call(t,n)&&tj(e,n,t[n]);if(YS)for(var n of YS(t))ree.call(t,n)&&tj(e,n,t[n]);return e},oOe=(e,t)=>{var n={};for(var r in e)nee.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&YS)for(var r of YS(e))t.indexOf(r)<0&&ree.call(e,r)&&(n[r]=e[r]);return n};const aOe={},iee=w.forwardRef((e,t)=>{const n=Ve("MenuLabel",aOe,e),{children:r,className:i}=n,s=oOe(n,["children","className"]),{classNames:o,styles:a,unstyled:u}=j_(),{classes:l,cx:c}=rOe(null,{name:"Menu",classNames:o,styles:a,unstyled:u});return N.createElement(rt,sOe({className:c(l.label,i),ref:t},s),r)});iee.displayName="@mantine/core/MenuLabel";var uOe=Object.defineProperty,KS=Object.getOwnPropertySymbols,see=Object.prototype.hasOwnProperty,oee=Object.prototype.propertyIsEnumerable,nj=(e,t,n)=>t in e?uOe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,lOe=(e,t)=>{for(var n in t||(t={}))see.call(t,n)&&nj(e,n,t[n]);if(KS)for(var n of KS(t))oee.call(t,n)&&nj(e,n,t[n]);return e},cOe=(e,t)=>{var n={};for(var r in e)see.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&KS)for(var r of KS(e))t.indexOf(r)<0&&oee.call(e,r)&&(n[r]=e[r]);return n};const fOe={refProp:"ref"},aee=w.forwardRef((e,t)=>{const n=Ve("MenuTarget",fOe,e),{children:r,refProp:i}=n,s=cOe(n,["children","refProp"]);if(!_g(r))throw new Error(qZ.children);const o=j_(),a=wo(r.props.onClick,()=>o.trigger==="click"&&o.toggleDropdown()),u=wo(r.props.onMouseEnter,()=>o.trigger==="hover"&&o.openDropdown()),l=wo(r.props.onMouseLeave,()=>o.trigger==="hover"&&o.closeDropdown());return N.createElement(yi.Target,lOe({refProp:i,popupType:"menu",ref:t},s),w.cloneElement(r,{onClick:a,onMouseEnter:u,onMouseLeave:l,"data-expanded":o.opened?!0:void 0}))});aee.displayName="@mantine/core/MenuTarget";var dOe=lt({dropdown:{padding:4}}),hOe=Object.defineProperty,pOe=Object.defineProperties,mOe=Object.getOwnPropertyDescriptors,QS=Object.getOwnPropertySymbols,uee=Object.prototype.hasOwnProperty,lee=Object.prototype.propertyIsEnumerable,rj=(e,t,n)=>t in e?hOe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ij=(e,t)=>{for(var n in t||(t={}))uee.call(t,n)&&rj(e,n,t[n]);if(QS)for(var n of QS(t))lee.call(t,n)&&rj(e,n,t[n]);return e},sj=(e,t)=>pOe(e,mOe(t)),gOe=(e,t)=>{var n={};for(var r in e)uee.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&QS)for(var r of QS(e))t.indexOf(r)<0&&lee.call(e,r)&&(n[r]=e[r]);return n};const yOe={closeOnItemClick:!0,loop:!0,trigger:"click",openDelay:0,closeDelay:100};function ts(e){const t=Ve("Menu",yOe,e),{children:n,onOpen:r,onClose:i,opened:s,defaultOpened:o,onChange:a,closeOnItemClick:u,loop:l,closeOnEscape:c,trigger:f,openDelay:d,closeDelay:h,classNames:p,styles:m,unstyled:y,radius:g}=t,v=gOe(t,["children","onOpen","onClose","opened","defaultOpened","onChange","closeOnItemClick","loop","closeOnEscape","trigger","openDelay","closeDelay","classNames","styles","unstyled","radius"]),{classes:b,cx:S}=dOe(),[T,{setHovered:E,resetHovered:I}]=x0e(),[A,R]=oa({value:s,defaultValue:o,finalValue:!1,onChange:a}),F=()=>{R(!1),A&&(i==null||i())},L=()=>{R(!0),!A&&(r==null||r())},B=()=>A?F():L(),{openDropdown:J,closeDropdown:V}=kZ({open:L,close:F,closeDelay:h,openDelay:d}),re=oe=>E0e("[data-menu-item]","[data-menu-dropdown]",oe);return Js(()=>{I()},[A]),N.createElement(OPe,{value:{opened:A,toggleDropdown:B,getItemIndex:re,hovered:T,setHovered:E,closeOnItemClick:u,closeDropdown:f==="click"?F:V,openDropdown:f==="click"?L:J,closeDropdownImmediately:F,loop:l,trigger:f,radius:g,classNames:p,styles:m,unstyled:y}},N.createElement(yi,sj(ij({},v),{radius:g,opened:A,onChange:R,defaultOpened:o,trapFocus:f==="click",closeOnEscape:c&&f==="click",__staticSelector:"Menu",classNames:sj(ij({},p),{dropdown:S(b.dropdown,p==null?void 0:p.dropdown)}),styles:m,unstyled:y,onClose:F,onOpen:L}),n))}ts.displayName="@mantine/core/Menu";ts.Item=nOe;ts.Label=iee;ts.Dropdown=JZ;ts.Target=aee;ts.Divider=KZ;var vOe=Object.defineProperty,oj=Object.getOwnPropertySymbols,_Oe=Object.prototype.hasOwnProperty,bOe=Object.prototype.propertyIsEnumerable,aj=(e,t,n)=>t in e?vOe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,wOe=(e,t)=>{for(var n in t||(t={}))_Oe.call(t,n)&&aj(e,n,t[n]);if(oj)for(var n of oj(t))bOe.call(t,n)&&aj(e,n,t[n]);return e};const EOe={xs:320,sm:380,md:440,lg:620,xl:780};function SOe(e){return e?{position:"absolute",top:0,left:0,right:0,bottom:0,maxHeight:"100vh",overflowY:"auto"}:{}}var TOe=lt((e,{overflow:t,size:n,centered:r,zIndex:i,fullScreen:s})=>({close:{},overlay:{display:s?"none":void 0},root:{position:"fixed",zIndex:i,top:0,left:0,right:0,bottom:0},inner:{position:"absolute",top:0,left:0,right:0,bottom:0,overflowY:"auto",padding:s?0:`${e.spacing.xl*2}px ${e.spacing.md}px`,display:"flex",justifyContent:"center",alignItems:r?"center":"flex-start"},title:{marginRight:e.spacing.md,textOverflow:"ellipsis",display:"block",wordBreak:"break-word"},modal:wOe({position:"relative",width:s?"100vw":e.fn.size({sizes:EOe,size:n}),borderRadius:s?0:void 0,outline:0,backgroundColor:e.colorScheme==="dark"?e.colors.dark[7]:e.white,marginTop:r?"auto":void 0,marginBottom:r?"auto":void 0,zIndex:1},SOe(s)),header:{display:"flex",alignItems:"center",justifyContent:"space-between",marginBottom:e.spacing.md,marginRight:-9},body:{maxHeight:t==="inside"?"calc(100vh - 185px)":null,overflowY:t==="inside"?"auto":null,wordBreak:"break-word"}})),IOe=Object.defineProperty,XS=Object.getOwnPropertySymbols,cee=Object.prototype.hasOwnProperty,fee=Object.prototype.propertyIsEnumerable,uj=(e,t,n)=>t in e?IOe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,xOe=(e,t)=>{for(var n in t||(t={}))cee.call(t,n)&&uj(e,n,t[n]);if(XS)for(var n of XS(t))fee.call(t,n)&&uj(e,n,t[n]);return e},COe=(e,t)=>{var n={};for(var r in e)cee.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&XS)for(var r of XS(e))t.indexOf(r)<0&&fee.call(e,r)&&(n[r]=e[r]);return n};const AOe={size:"md",transitionDuration:250,overflow:"outside",padding:"lg",shadow:"lg",closeOnClickOutside:!0,closeOnEscape:!0,trapFocus:!0,withCloseButton:!0,withinPortal:!0,lockScroll:!0,withFocusReturn:!0,overlayBlur:0,zIndex:cc("modal"),exitTransitionDuration:0};function zx(e){const t=Ve("Modal",AOe,e),{className:n,opened:r,title:i,onClose:s,children:o,withCloseButton:a,overlayOpacity:u,size:l,transitionDuration:c,exitTransitionDuration:f,closeButtonLabel:d,overlayColor:h,overflow:p,transition:m,padding:y,shadow:g,radius:v,id:b,classNames:S,styles:T,closeOnClickOutside:E,trapFocus:I,closeOnEscape:A,centered:R,target:F,withinPortal:L,zIndex:B,overlayBlur:J,transitionTimingFunction:V,fullScreen:re,unstyled:oe,lockScroll:ae,withFocusReturn:ee}=t,ue=COe(t,["className","opened","title","onClose","children","withCloseButton","overlayOpacity","size","transitionDuration","exitTransitionDuration","closeButtonLabel","overlayColor","overflow","transition","padding","shadow","radius","id","classNames","styles","closeOnClickOutside","trapFocus","closeOnEscape","centered","target","withinPortal","zIndex","overlayBlur","transitionTimingFunction","fullScreen","unstyled","lockScroll","withFocusReturn"]),P=tu(b),W=`${P}-title`,Q=`${P}-body`,{classes:x,cx:O,theme:$}=TOe({size:l,overflow:p,centered:R,zIndex:B,fullScreen:re},{unstyled:oe,classNames:S,styles:T,name:"Modal"}),q=jK(I&&r),ce=w.useRef(null),fe=fa(q,ce),de=typeof u=="number"?u:$.colorScheme==="dark"?.85:.75;Qve(ae&&r);const ve=nt=>{!I&&nt.key==="Escape"&&A&&s()};w.useEffect(()=>{if(!I)return window.addEventListener("keydown",ve),()=>window.removeEventListener("keydown",ve)},[I]),LK({opened:r,shouldReturnFocus:I&&ee});const Ee=w.useRef(null);jR("mousedown",nt=>{Ee.current=nt.target});const ge=()=>{Ee.current===ce.current&&E&&s()};return N.createElement($_,{withinPortal:L,target:F},N.createElement(iZ,{mounted:r,duration:c,exitDuration:f,timingFunction:V,transitions:{modal:{duration:c,transition:m||(re?"fade":"pop")},overlay:{duration:c/2,transition:"fade",timingFunction:"ease"}}},nt=>N.createElement(N.Fragment,null,N.createElement(it,xOe({id:P,className:O(x.root,n)},ue),N.createElement("div",{style:nt.overlay},N.createElement(ACe,{className:x.overlay,sx:{position:"fixed"},zIndex:0,blur:J,color:h||($.colorScheme==="dark"?$.colors.dark[9]:$.black),opacity:de,unstyled:oe})),N.createElement("div",{role:"presentation",className:x.inner,onClick:ge,onKeyDown:Je=>{var yt;((yt=Je.target)==null?void 0:yt.getAttribute("data-mantine-stop-propagation"))!=="true"&&Je.key==="Escape"&&A&&s()},ref:fe},N.createElement(wS,{className:x.modal,shadow:g,p:y,radius:v,role:"dialog","aria-labelledby":W,"aria-describedby":Q,"aria-modal":!0,tabIndex:-1,style:nt.modal,unstyled:oe,onClick:Je=>Je.stopPropagation()},(i||a)&&N.createElement("div",{className:x.header},N.createElement(rt,{id:W,className:x.title},i),a&&N.createElement(Dx,{iconSize:16,onClick:s,"aria-label":d,className:x.close})),N.createElement("div",{id:Q,className:x.body},o)))))))}zx.displayName="@mantine/core/Modal";const POe={xs:16,sm:22,md:26,lg:30,xl:36},OOe={xs:10,sm:12,md:14,lg:16,xl:18};var ROe=lt((e,{size:t,disabled:n,radius:r,readOnly:i,variant:s})=>({defaultValue:{display:"flex",alignItems:"center",backgroundColor:n?e.colorScheme==="dark"?e.colors.dark[5]:e.colors.gray[3]:e.colorScheme==="dark"?e.colors.dark[7]:s==="filled"?e.white:e.colors.gray[1],color:n?e.colorScheme==="dark"?e.colors.dark[1]:e.colors.gray[7]:e.colorScheme==="dark"?e.colors.dark[0]:e.colors.gray[7],height:e.fn.size({size:t,sizes:POe}),paddingLeft:e.fn.size({size:t,sizes:e.spacing}),paddingRight:n||i?e.fn.size({size:t,sizes:e.spacing}):0,fontWeight:500,fontSize:e.fn.size({size:t,sizes:OOe}),borderRadius:e.fn.size({size:r,sizes:e.radius}),cursor:n?"not-allowed":"default",userSelect:"none",maxWidth:"calc(100% - 20px)"},defaultValueRemove:{color:e.colorScheme==="dark"?e.colors.dark[0]:e.colors.gray[7],marginLeft:e.fn.size({size:t,sizes:e.spacing})/6},defaultValueLabel:{display:"block",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"}})),NOe=Object.defineProperty,JS=Object.getOwnPropertySymbols,dee=Object.prototype.hasOwnProperty,hee=Object.prototype.propertyIsEnumerable,lj=(e,t,n)=>t in e?NOe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,kOe=(e,t)=>{for(var n in t||(t={}))dee.call(t,n)&&lj(e,n,t[n]);if(JS)for(var n of JS(t))hee.call(t,n)&&lj(e,n,t[n]);return e},DOe=(e,t)=>{var n={};for(var r in e)dee.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&JS)for(var r of JS(e))t.indexOf(r)<0&&hee.call(e,r)&&(n[r]=e[r]);return n};const cj={xs:16,sm:22,md:24,lg:26,xl:30};function pee(e){var t=e,{label:n,classNames:r,styles:i,className:s,onRemove:o,disabled:a,readOnly:u,size:l,radius:c="sm",variant:f}=t,d=DOe(t,["label","classNames","styles","className","onRemove","disabled","readOnly","size","radius","variant"]);const{classes:h,cx:p}=ROe({size:l,disabled:a,readOnly:u,radius:c,variant:f},{classNames:r,styles:i,name:"MultiSelect"});return N.createElement("div",kOe({className:p(h.defaultValue,s)},d),N.createElement("span",{className:h.defaultValueLabel},n),!a&&!u&&N.createElement(Dx,{"aria-hidden":!0,onMouseDown:o,size:cj[l],radius:2,color:"blue",variant:"transparent",iconSize:cj[l]/2,className:h.defaultValueRemove,tabIndex:-1}))}pee.displayName="@mantine/core/MultiSelect/DefaultValue";function $Oe({data:e,searchable:t,limit:n,searchValue:r,filter:i,value:s,disableSelectedItemFiltering:o}){if(!t&&s.length===0)return e;if(!t){const u=[];for(let l=0;lc===e[l].value&&!e[l].disabled))&&u.push(e[l]);return u}const a=[];for(let u=0;ul===e[u].value&&!e[u].disabled),e[u])&&a.push(e[u]),!(a.length>=n));u+=1);return a}var LOe=Object.defineProperty,ZS=Object.getOwnPropertySymbols,mee=Object.prototype.hasOwnProperty,gee=Object.prototype.propertyIsEnumerable,fj=(e,t,n)=>t in e?LOe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,dj=(e,t)=>{for(var n in t||(t={}))mee.call(t,n)&&fj(e,n,t[n]);if(ZS)for(var n of ZS(t))gee.call(t,n)&&fj(e,n,t[n]);return e},MOe=(e,t)=>{var n={};for(var r in e)mee.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&ZS)for(var r of ZS(e))t.indexOf(r)<0&&gee.call(e,r)&&(n[r]=e[r]);return n};const FOe={xs:14,sm:18,md:20,lg:24,xl:28};function BOe(e){var t=e,{size:n,error:r,style:i}=t,s=MOe(t,["size","error","style"]);const o=ji(),a=o.fn.size({size:n,sizes:FOe});return N.createElement("svg",dj({width:a,height:a,viewBox:"0 0 15 15",fill:"none",xmlns:"http://www.w3.org/2000/svg",style:dj({color:r?o.colors.red[6]:o.colors.gray[6]},i),"data-chevron":!0},s),N.createElement("path",{d:"M4.93179 5.43179C4.75605 5.60753 4.75605 5.89245 4.93179 6.06819C5.10753 6.24392 5.39245 6.24392 5.56819 6.06819L7.49999 4.13638L9.43179 6.06819C9.60753 6.24392 9.89245 6.24392 10.0682 6.06819C10.2439 5.89245 10.2439 5.60753 10.0682 5.43179L7.81819 3.18179C7.73379 3.0974 7.61933 3.04999 7.49999 3.04999C7.38064 3.04999 7.26618 3.0974 7.18179 3.18179L4.93179 5.43179ZM10.0682 9.56819C10.2439 9.39245 10.2439 9.10753 10.0682 8.93179C9.89245 8.75606 9.60753 8.75606 9.43179 8.93179L7.49999 10.8636L5.56819 8.93179C5.39245 8.75606 5.10753 8.75606 4.93179 8.93179C4.75605 9.10753 4.75605 9.39245 4.93179 9.56819L7.18179 11.8182C7.35753 11.9939 7.64245 11.9939 7.81819 11.8182L10.0682 9.56819Z",fill:"currentColor",fillRule:"evenodd",clipRule:"evenodd"}))}function yee({shouldClear:e,clearButtonLabel:t,onClear:n,size:r,error:i,clearButtonTabIndex:s}){return e?N.createElement(Dx,{variant:"transparent","aria-label":t,onClick:n,size:r,tabIndex:s,onMouseDown:o=>o.preventDefault()}):N.createElement(BOe,{error:i,size:r})}yee.displayName="@mantine/core/SelectRightSection";var jOe=Object.defineProperty,UOe=Object.defineProperties,VOe=Object.getOwnPropertyDescriptors,eT=Object.getOwnPropertySymbols,vee=Object.prototype.hasOwnProperty,_ee=Object.prototype.propertyIsEnumerable,hj=(e,t,n)=>t in e?jOe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,HP=(e,t)=>{for(var n in t||(t={}))vee.call(t,n)&&hj(e,n,t[n]);if(eT)for(var n of eT(t))_ee.call(t,n)&&hj(e,n,t[n]);return e},pj=(e,t)=>UOe(e,VOe(t)),zOe=(e,t)=>{var n={};for(var r in e)vee.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&eT)for(var r of eT(e))t.indexOf(r)<0&&_ee.call(e,r)&&(n[r]=e[r]);return n};const HOe={xs:24,sm:30,md:34,lg:44,xl:54};function bee(e){var t=e,{styles:n,rightSection:r,rightSectionWidth:i,theme:s}=t,o=zOe(t,["styles","rightSection","rightSectionWidth","theme"]);if(r)return{rightSection:r,rightSectionWidth:i,styles:n};const a=typeof n=="function"?n(s):n;return{rightSectionWidth:s.fn.size({size:o.size,sizes:HOe}),rightSection:!o.readOnly&&!(o.disabled&&o.shouldClear)&&N.createElement(yee,HP({},o)),styles:pj(HP({},a),{rightSection:pj(HP({},a==null?void 0:a.rightSection),{pointerEvents:o.shouldClear?void 0:"none"})})}}var WOe=Object.defineProperty,qOe=Object.defineProperties,GOe=Object.getOwnPropertyDescriptors,mj=Object.getOwnPropertySymbols,YOe=Object.prototype.hasOwnProperty,KOe=Object.prototype.propertyIsEnumerable,gj=(e,t,n)=>t in e?WOe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,QOe=(e,t)=>{for(var n in t||(t={}))YOe.call(t,n)&&gj(e,n,t[n]);if(mj)for(var n of mj(t))KOe.call(t,n)&&gj(e,n,t[n]);return e},XOe=(e,t)=>qOe(e,GOe(t)),JOe=lt((e,{size:t,invalid:n})=>({wrapper:{position:"relative"},values:{minHeight:e.fn.size({size:t,sizes:$s})-2,display:"flex",alignItems:"center",flexWrap:"wrap",marginLeft:`calc(${-e.spacing.xs}px / 2)`,boxSizing:"border-box"},value:{margin:`calc(${e.spacing.xs}px / 2 - 2px) calc(${e.spacing.xs}px / 2)`},searchInput:XOe(QOe({},e.fn.fontStyles()),{flex:1,minWidth:60,backgroundColor:"transparent",border:0,outline:0,fontSize:e.fn.size({size:t,sizes:e.fontSizes}),padding:0,marginLeft:`calc(${e.spacing.xs}px / 2)`,appearance:"none",color:"inherit",lineHeight:`${e.fn.size({size:t,sizes:$s})-2}px`,"&::placeholder":{opacity:1,color:n?e.colors.red[e.colorScheme==="dark"?6:7]:e.colorScheme==="dark"?e.colors.dark[3]:e.colors.gray[5]},"&:disabled":{cursor:"not-allowed"}}),searchInputEmpty:{width:"100%"},searchInputInputHidden:{width:0,height:0,margin:0,overflow:"hidden"},searchInputPointer:{cursor:"pointer","&:disabled":{cursor:"not-allowed"}},input:{cursor:"pointer","&:disabled":{cursor:"not-allowed"}}})),ZOe=Object.defineProperty,e2e=Object.defineProperties,t2e=Object.getOwnPropertyDescriptors,tT=Object.getOwnPropertySymbols,wee=Object.prototype.hasOwnProperty,Eee=Object.prototype.propertyIsEnumerable,yj=(e,t,n)=>t in e?ZOe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Zh=(e,t)=>{for(var n in t||(t={}))wee.call(t,n)&&yj(e,n,t[n]);if(tT)for(var n of tT(t))Eee.call(t,n)&&yj(e,n,t[n]);return e},vj=(e,t)=>e2e(e,t2e(t)),n2e=(e,t)=>{var n={};for(var r in e)wee.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&tT)for(var r of tT(e))t.indexOf(r)<0&&Eee.call(e,r)&&(n[r]=e[r]);return n};function r2e(e,t,n){return t?!1:n.label.toLowerCase().trim().includes(e.toLowerCase().trim())}function i2e(e,t){return!!e&&!t.some(n=>n.value.toLowerCase()===e.toLowerCase())}function _j(e,t){if(!Array.isArray(e))return;if(t.length===0)return[];const n=t.map(r=>typeof r=="object"?r.value:r);return e.filter(r=>n.includes(r))}const s2e={size:"sm",valueComponent:pee,itemComponent:P$,transition:"pop-top-left",transitionDuration:0,maxDropdownHeight:220,shadow:"sm",searchable:!1,filter:r2e,limit:1/0,clearSearchOnChange:!0,clearable:!1,clearSearchOnBlur:!1,disabled:!1,initiallyOpened:!1,creatable:!1,shouldCreate:i2e,switchDirectionOnFlip:!1,zIndex:cc("popover"),selectOnBlur:!1,clearButtonTabIndex:0,positionDependencies:[],dropdownPosition:"flip"},See=w.forwardRef((e,t)=>{const n=Ve("MultiSelect",s2e,e),{className:r,style:i,required:s,label:o,description:a,size:u,error:l,classNames:c,styles:f,wrapperProps:d,value:h,defaultValue:p,data:m,onChange:y,valueComponent:g,itemComponent:v,id:b,transition:S,transitionDuration:T,transitionTimingFunction:E,maxDropdownHeight:I,shadow:A,nothingFound:R,onFocus:F,onBlur:L,searchable:B,placeholder:J,filter:V,limit:re,clearSearchOnChange:oe,clearable:ae,clearSearchOnBlur:ee,clearButtonLabel:ue,variant:P,onSearchChange:W,searchValue:Q,disabled:x,initiallyOpened:O,radius:$,icon:q,rightSection:ce,rightSectionWidth:fe,creatable:de,getCreateLabel:ve,shouldCreate:Ee,onCreate:ge,sx:nt,dropdownComponent:Je,onDropdownClose:yt,onDropdownOpen:ke,maxSelectedValues:at,withinPortal:St,switchDirectionOnFlip:cn,zIndex:bn,selectOnBlur:He,name:Fe,dropdownPosition:st,errorProps:dt,labelProps:At,descriptionProps:Kt,clearButtonTabIndex:me,form:Se,positionDependencies:Le,onKeyDown:Ke,unstyled:ct,inputContainer:In,inputWrapperOrder:Me,readOnly:Ze,withAsterisk:ot,hoverOnSearchChange:Gt,disableSelectedItemFiltering:pt}=n,_r=n2e(n,["className","style","required","label","description","size","error","classNames","styles","wrapperProps","value","defaultValue","data","onChange","valueComponent","itemComponent","id","transition","transitionDuration","transitionTimingFunction","maxDropdownHeight","shadow","nothingFound","onFocus","onBlur","searchable","placeholder","filter","limit","clearSearchOnChange","clearable","clearSearchOnBlur","clearButtonLabel","variant","onSearchChange","searchValue","disabled","initiallyOpened","radius","icon","rightSection","rightSectionWidth","creatable","getCreateLabel","shouldCreate","onCreate","sx","dropdownComponent","onDropdownClose","onDropdownOpen","maxSelectedValues","withinPortal","switchDirectionOnFlip","zIndex","selectOnBlur","name","dropdownPosition","errorProps","labelProps","descriptionProps","clearButtonTabIndex","form","positionDependencies","onKeyDown","unstyled","inputContainer","inputWrapperOrder","readOnly","withAsterisk","hoverOnSearchChange","disableSelectedItemFiltering"]),{classes:mn,cx:qn,theme:cs}=JOe({size:u,invalid:!!l},{classNames:c,styles:f,unstyled:ct,name:"MultiSelect"}),{systemStyles:xs,rest:ui}=Qf(_r),Nn=w.useRef(),ba=w.useRef({}),Nr=tu(b),[br,$n]=w.useState(O),[fn,Yn]=w.useState(-1),[fs,Kr]=w.useState("column"),[jr,X]=oa({value:Q,defaultValue:"",finalValue:void 0,onChange:W}),[z,Z]=w.useState(!1),{scrollIntoView:he,targetRef:pe,scrollableRef:Ye}=HK({duration:0,offset:5,cancelable:!1,isList:!0}),Qe=de&&typeof ve=="function";let xe=null;const et=m.map(We=>typeof We=="string"?{label:We,value:We}:We),Ft=uK({data:et}),[Be,Jt]=oa({value:_j(h,m),defaultValue:_j(p,m),finalValue:[],onChange:y}),Zt=w.useRef(!!at&&at{if(!Ze){const en=Be.filter(Hi=>Hi!==We);Jt(en),at&&en.length{X(We.currentTarget.value),!x&&!Zt.current&&B&&$n(!0)},Vn=We=>{typeof F=="function"&&F(We),!x&&!Zt.current&&B&&$n(!0)},Tt=$Oe({data:Ft,searchable:B,searchValue:jr,limit:re,filter:V,value:Be,disableSelectedItemFiltering:pt}),wr=(We,en,Hi)=>{let k=We;for(;Hi(k);)if(k=en(k),!Tt[k].disabled)return k;return We};Js(()=>{Yn(Gt&&jr?0:-1)},[jr,Gt]),Js(()=>{!x&&Be.length>m.length&&$n(!1),at&&Be.length=at&&(Zt.current=!0,$n(!1))},[Be]);const Er=We=>{if(!Ze)if(oe&&X(""),Be.includes(We.value))mt(We.value);else{if(We.creatable&&typeof ge=="function"){const en=ge(We.value);typeof en<"u"&&en!==null&&Jt(typeof en=="string"?[...Be,en]:[...Be,en.value])}else Jt([...Be,We.value]);Be.length===at-1&&(Zt.current=!0,$n(!1)),fn===Tt.length-1&&Yn(Tt.length-2),Tt.length===1&&$n(!1)}},kr=We=>{typeof L=="function"&&L(We),He&&Tt[fn]&&br&&Er(Tt[fn]),ee&&X(""),$n(!1)},ds=We=>{if(z||(Ke==null||Ke(We),Ze)||We.key!=="Backspace"&&at&&Zt.current)return;const en=fs==="column",Hi=()=>{Yn(K=>{var j;const te=wr(K,se=>se+1,se=>se{Yn(K=>{var j;const te=wr(K,se=>se-1,se=>se>0);return br&&(pe.current=ba.current[(j=Tt[te])==null?void 0:j.value],he({alignment:en?"start":"end"})),te})};switch(We.key){case"ArrowUp":{We.preventDefault(),$n(!0),en?k():Hi();break}case"ArrowDown":{We.preventDefault(),$n(!0),en?Hi():k();break}case"Enter":{We.preventDefault(),Tt[fn]&&br?Er(Tt[fn]):$n(!0);break}case" ":{B||(We.preventDefault(),Tt[fn]&&br?Er(Tt[fn]):$n(!0));break}case"Backspace":{Be.length>0&&jr.length===0&&(Jt(Be.slice(0,-1)),$n(!0),at&&(Zt.current=!1));break}case"Home":{if(!B){We.preventDefault(),br||$n(!0);const K=Tt.findIndex(j=>!j.disabled);Yn(K),he({alignment:en?"end":"start"})}break}case"End":{if(!B){We.preventDefault(),br||$n(!0);const K=Tt.map(j=>!!j.disabled).lastIndexOf(!1);Yn(K),he({alignment:en?"end":"start"})}break}case"Escape":$n(!1)}},Ei=Be.map(We=>{let en=Ft.find(Hi=>Hi.value===We&&!Hi.disabled);return!en&&Qe&&(en={value:We,label:We}),en}).filter(We=>!!We).map(We=>N.createElement(g,vj(Zh({},We),{variant:P,disabled:x,className:mn.value,readOnly:Ze,onRemove:en=>{en.preventDefault(),en.stopPropagation(),mt(We.value)},key:We.value,size:u,styles:f,classNames:c,radius:$}))),Ur=We=>Be.includes(We),Vi=()=>{var We;X(""),Jt([]),(We=Nn.current)==null||We.focus(),at&&(Zt.current=!1)};Qe&&Ee(jr,Ft)&&(xe=ve(jr),Tt.push({label:jr,value:jr,creatable:!0}));const zi=!Ze&&(Tt.length>0?br:br&&!!R);return Js(()=>{const We=zi?ke:yt;typeof We=="function"&&We()},[zi]),N.createElement(Zs.Wrapper,Zh(Zh({required:s,id:Nr,label:o,error:l,description:a,size:u,className:r,style:i,classNames:c,styles:f,__staticSelector:"MultiSelect",sx:nt,errorProps:dt,descriptionProps:Kt,labelProps:At,inputContainer:In,inputWrapperOrder:Me,unstyled:ct,withAsterisk:ot},xs),d),N.createElement(hf,{opened:zi,transition:S,transitionDuration:T,shadow:"sm",withinPortal:St,__staticSelector:"MultiSelect",onDirectionChange:Kr,switchDirectionOnFlip:cn,zIndex:bn,dropdownPosition:st,positionDependencies:[...Le,jr],classNames:c,styles:f,unstyled:ct},N.createElement(hf.Target,null,N.createElement("div",{className:mn.wrapper,role:"combobox","aria-haspopup":"listbox","aria-owns":br&&zi?`${Nr}-items`:null,"aria-controls":Nr,"aria-expanded":br,onMouseLeave:()=>Yn(-1),tabIndex:-1},N.createElement("input",{type:"hidden",name:Fe,value:Be.join(","),form:Se,disabled:x}),N.createElement(Zs,Zh({__staticSelector:"MultiSelect",style:{overflow:"hidden"},component:"div",multiline:!0,size:u,variant:P,disabled:x,invalid:!!l,required:s,radius:$,icon:q,unstyled:ct,onMouseDown:We=>{var en;We.preventDefault(),!x&&!Zt.current&&$n(!br),(en=Nn.current)==null||en.focus()},classNames:vj(Zh({},c),{input:qn({[mn.input]:!B},c==null?void 0:c.input)})},bee({theme:cs,rightSection:ce,rightSectionWidth:fe,styles:f,size:u,shouldClear:ae&&Be.length>0,clearButtonLabel:ue,onClear:Vi,error:l,disabled:x,clearButtonTabIndex:me,readOnly:Ze})),N.createElement("div",{className:mn.values},Ei,N.createElement("input",Zh({ref:fa(t,Nn),type:"search",id:Nr,className:qn(mn.searchInput,{[mn.searchInputPointer]:!B,[mn.searchInputInputHidden]:!br&&Be.length>0||!B&&Be.length>0,[mn.searchInputEmpty]:Be.length===0}),onKeyDown:ds,value:jr,onChange:kn,onFocus:Vn,onBlur:kr,readOnly:!B||Zt.current||Ze,placeholder:Be.length===0?J:void 0,disabled:x,"data-mantine-stop-propagation":br,autoComplete:"off",onCompositionStart:()=>Z(!0),onCompositionEnd:()=>Z(!1)},ui)))))),N.createElement(hf.Dropdown,{component:Je||Bx,maxHeight:I,direction:fs,id:Nr,innerRef:Ye,__staticSelector:"MultiSelect",classNames:c,styles:f},N.createElement(A$,{data:Tt,hovered:fn,classNames:c,styles:f,uuid:Nr,__staticSelector:"MultiSelect",onItemHover:Yn,onItemSelect:Er,itemsRefs:ba,itemComponent:v,size:u,nothingFound:R,isItemSelected:Ur,creatable:de&&!!xe,createLabel:xe,unstyled:ct}))))});See.displayName="@mantine/core/MultiSelect";var o2e=Object.defineProperty,a2e=Object.defineProperties,u2e=Object.getOwnPropertyDescriptors,bj=Object.getOwnPropertySymbols,l2e=Object.prototype.hasOwnProperty,c2e=Object.prototype.propertyIsEnumerable,wj=(e,t,n)=>t in e?o2e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Ej=(e,t)=>{for(var n in t||(t={}))l2e.call(t,n)&&wj(e,n,t[n]);if(bj)for(var n of bj(t))c2e.call(t,n)&&wj(e,n,t[n]);return e},f2e=(e,t)=>a2e(e,u2e(t)),d2e=lt((e,{color:t,variant:n,noWrap:r,childrenOffset:i,alignIcon:s})=>{const o=e.fn.variant({variant:n,color:t});return{root:f2e(Ej({display:"flex",alignItems:"center",width:"100%",padding:`8px ${e.spacing.sm}px`,userSelect:"none"},e.fn.hover({backgroundColor:e.colorScheme==="dark"?e.colors.dark[6]:e.colors.gray[0]})),{"&[data-active]":Ej({backgroundColor:o.background,color:o.color},e.fn.hover({backgroundColor:o.hover})),"&[data-disabled]":{opacity:.4,pointerEvents:"none"}}),icon:{marginRight:e.spacing.sm,display:"flex",justifyContent:"center",alignItems:"center",alignSelf:s==="center"?"center":"flex-start",paddingTop:s==="center"?void 0:4},rightSection:{marginLeft:e.spacing.sm,display:"flex",justifyContent:"center",alignItems:"center",transition:`transform 150ms ${e.transitionTimingFunction}`,"&[data-rotate]":{transform:"rotate(90deg)"}},body:{flex:1,overflow:"hidden",textOverflow:"ellipsis",whiteSpace:r?"nowrap":void 0},label:{},description:{display:"block","&[data-active]":{color:"inherit"}},children:{paddingLeft:e.fn.size({size:i,sizes:e.spacing})}}}),h2e=Object.defineProperty,nT=Object.getOwnPropertySymbols,Tee=Object.prototype.hasOwnProperty,Iee=Object.prototype.propertyIsEnumerable,Sj=(e,t,n)=>t in e?h2e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,p2e=(e,t)=>{for(var n in t||(t={}))Tee.call(t,n)&&Sj(e,n,t[n]);if(nT)for(var n of nT(t))Iee.call(t,n)&&Sj(e,n,t[n]);return e},m2e=(e,t)=>{var n={};for(var r in e)Tee.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&nT)for(var r of nT(e))t.indexOf(r)<0&&Iee.call(e,r)&&(n[r]=e[r]);return n};const g2e={variant:"light",childrenOffset:"lg"},xee=w.forwardRef((e,t)=>{const n=Ve("NavLink",g2e,e),{label:r,description:i,icon:s,rightSection:o,className:a,classNames:u,styles:l,unstyled:c,active:f,color:d,variant:h,noWrap:p,children:m,opened:y,defaultOpened:g,onChange:v,disableRightSectionRotation:b,childrenOffset:S,disabled:T,onClick:E}=n,I=m2e(n,["label","description","icon","rightSection","className","classNames","styles","unstyled","active","color","variant","noWrap","children","opened","defaultOpened","onChange","disableRightSectionRotation","childrenOffset","disabled","onClick"]),{classes:A,cx:R}=d2e({color:d,variant:h,noWrap:p,childrenOffset:S,alignIcon:i?"top":"center"},{name:"NavLink",classNames:u,styles:l,unstyled:c}),[F,L]=oa({value:y,defaultValue:g,finalValue:!1,onChange:v}),B=!!m,J=V=>{B?(V.preventDefault(),E==null||E(V),L(!F)):E==null||E(V)};return N.createElement(N.Fragment,null,N.createElement(kx,p2e({ref:t,className:R(A.root,a),"data-active":f||void 0,onClick:J,unstyled:c,"data-expanded":F||void 0,"data-disabled":T||void 0,disabled:T},I),s&&N.createElement("span",{className:A.icon},s),N.createElement("span",{className:A.body},N.createElement(rt,{component:"span",size:"sm",className:A.label},r),N.createElement(rt,{component:"span",color:"dimmed",size:"xs","data-active":f||void 0,className:A.description},i)),(B||o)&&N.createElement("span",{className:A.rightSection,"data-rotate":F&&!b||void 0},B?o||N.createElement(H_e,{width:14,height:14,style:{transform:"rotate(-90deg)"}}):o)),N.createElement(tQ,{in:F},N.createElement("div",{className:A.children},m)))});xee.displayName="@mantine/core/NavLink";const Cee=xee,y2e=(e,t,n)=>Number.isInteger(e)&&e>=0&&t===0?"numeric":!Number.isInteger(e)&&e>=0&&t!==0?"decimal":Number.isInteger(e)&&e<0&&t===0||!Number.isInteger(e)&&e<0&&t!==0?n==="ios"?"text":"decimal":"numeric";function Tj({direction:e,size:t}){return N.createElement("svg",{style:{transform:e==="up"?"rotate(180deg)":void 0},width:t,height:t,viewBox:"0 0 15 15",fill:"none",xmlns:"http://www.w3.org/2000/svg"},N.createElement("path",{d:"M3.13523 6.15803C3.3241 5.95657 3.64052 5.94637 3.84197 6.13523L7.5 9.56464L11.158 6.13523C11.3595 5.94637 11.6759 5.95657 11.8648 6.15803C12.0536 6.35949 12.0434 6.67591 11.842 6.86477L7.84197 10.6148C7.64964 10.7951 7.35036 10.7951 7.15803 10.6148L3.15803 6.86477C2.95657 6.67591 2.94637 6.35949 3.13523 6.15803Z",fill:"currentColor",fillRule:"evenodd",clipRule:"evenodd"}))}const Aee={xs:20,sm:24,md:30,lg:34,xl:36};var v2e=lt((e,{radius:t,size:n})=>({rightSection:{display:"flex",flexDirection:"column",height:"calc(100% - 2px)",margin:1,marginRight:1,overflow:"hidden",borderTopRightRadius:e.fn.radius(t),borderBottomRightRadius:e.fn.radius(t)},control:{margin:0,position:"relative",flex:"0 0 50%",display:"flex",alignItems:"center",justifyContent:"center",boxSizing:"border-box",width:e.fn.size({size:n,sizes:Aee}),padding:0,WebkitTapHighlightColor:"transparent",borderBottom:`1px solid ${e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[4]}`,borderLeft:`1px solid ${e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[4]}`,borderTop:0,borderRight:0,backgroundColor:"transparent",marginRight:1,color:e.colorScheme==="dark"?e.colors.dark[0]:e.black,"&:not(:disabled):hover":{backgroundColor:e.colorScheme==="dark"?e.colors.dark[5]:e.colors.gray[0]},"&:disabled":{color:e.colorScheme==="dark"?e.colors.dark[3]:e.colors.gray[4]}},controlUp:{},controlDown:{borderBottom:0}})),_2e=Object.defineProperty,b2e=Object.defineProperties,w2e=Object.getOwnPropertyDescriptors,rT=Object.getOwnPropertySymbols,Pee=Object.prototype.hasOwnProperty,Oee=Object.prototype.propertyIsEnumerable,Ij=(e,t,n)=>t in e?_2e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,WP=(e,t)=>{for(var n in t||(t={}))Pee.call(t,n)&&Ij(e,n,t[n]);if(rT)for(var n of rT(t))Oee.call(t,n)&&Ij(e,n,t[n]);return e},E2e=(e,t)=>b2e(e,w2e(t)),S2e=(e,t)=>{var n={};for(var r in e)Pee.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&rT)for(var r of rT(e))t.indexOf(r)<0&&Oee.call(e,r)&&(n[r]=e[r]);return n};const T2e={type:"text",size:"sm",__staticSelector:"TextInput"},Ev=w.forwardRef((e,t)=>{const n=eJ("TextInput",T2e,e),{inputProps:r,wrapperProps:i}=n,s=S2e(n,["inputProps","wrapperProps"]);return N.createElement(Zs.Wrapper,WP({},i),N.createElement(Zs,E2e(WP(WP({},r),s),{ref:t})))});Ev.displayName="@mantine/core/TextInput";var I2e=Object.defineProperty,x2e=Object.defineProperties,C2e=Object.getOwnPropertyDescriptors,iT=Object.getOwnPropertySymbols,Ree=Object.prototype.hasOwnProperty,Nee=Object.prototype.propertyIsEnumerable,xj=(e,t,n)=>t in e?I2e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,A2e=(e,t)=>{for(var n in t||(t={}))Ree.call(t,n)&&xj(e,n,t[n]);if(iT)for(var n of iT(t))Nee.call(t,n)&&xj(e,n,t[n]);return e},P2e=(e,t)=>x2e(e,C2e(t)),O2e=(e,t)=>{var n={};for(var r in e)Ree.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&iT)for(var r of iT(e))t.indexOf(r)<0&&Nee.call(e,r)&&(n[r]=e[r]);return n};const R2e=e=>e||"",N2e=e=>{if(e==="-")return e;let t=e;t[0]==="."&&(t=`0${e}`);const n=parseFloat(t);if(!Number.isNaN(n))return e},Cj={xs:10,sm:14,md:16,lg:18,xl:20},k2e={step:1,hideControls:!1,size:"sm",precision:0,noClampOnBlur:!1,removeTrailingZeros:!1,formatter:R2e,parser:N2e,type:"text"},kee=w.forwardRef((e,t)=>{const n=Ve("NumberInput",k2e,e),{readOnly:r,disabled:i,value:s,onChange:o,decimalSeparator:a,min:u,max:l,startValue:c,step:f,stepHoldInterval:d,stepHoldDelay:h,onBlur:p,onFocus:m,onKeyDown:y,onKeyUp:g,hideControls:v,radius:b,variant:S,precision:T,removeTrailingZeros:E,defaultValue:I,noClampOnBlur:A,handlersRef:R,classNames:F,styles:L,size:B,rightSection:J,rightSectionWidth:V,formatter:re,parser:oe,inputMode:ae,unstyled:ee,type:ue}=n,P=O2e(n,["readOnly","disabled","value","onChange","decimalSeparator","min","max","startValue","step","stepHoldInterval","stepHoldDelay","onBlur","onFocus","onKeyDown","onKeyUp","hideControls","radius","variant","precision","removeTrailingZeros","defaultValue","noClampOnBlur","handlersRef","classNames","styles","size","rightSection","rightSectionWidth","formatter","parser","inputMode","unstyled","type"]),{classes:W,cx:Q,theme:x}=v2e({radius:b,size:B},{classNames:F,styles:L,unstyled:ee,name:"NumberInput"}),O=Me=>{if(Me===void 0)return;let Ze=Me.toFixed(T);return E&&T>0&&(Ze=Ze.replace(new RegExp(`[0]{0,${T}}$`),""),(Ze.endsWith(".")||Ze.endsWith(a))&&(Ze=Ze.slice(0,-1))),Ze},[$,q]=w.useState(!1),[ce,fe]=w.useState(typeof s=="number"?s:typeof I=="number"?I:void 0),de=typeof s=="number"?s:ce,[ve,Ee]=w.useState(typeof de=="number"?O(de):""),ge=w.useRef(),nt=Me=>{Me!==ce&&!Number.isNaN(Me)&&(typeof o=="function"&&o(Me),fe(Me))},Je=(Me="")=>{let Ze=typeof Me=="number"?String(Me):Me;return a&&(Ze=Ze.replace(/\./g,a)),re(Ze)},yt=Me=>{let Ze=Me;return a&&(Ze=Ze.replace(new RegExp(`\\${a}`,"g"),".")),oe(Ze)},ke=typeof u=="number"?u:-1/0,at=typeof l=="number"?l:1/0,St=w.useRef();St.current=()=>{var Me,Ze,ot;if(ce===void 0)nt((Me=c??u)!=null?Me:0),Ee((ot=(Ze=O(c))!=null?Ze:O(u))!=null?ot:"0");else{const Gt=O(ff(ce+f,ke,at));nt(parseFloat(Gt)),Ee(Gt)}};const cn=w.useRef();cn.current=()=>{var Me,Ze,ot;if(ce===void 0)nt((Me=c??u)!=null?Me:0),Ee((ot=(Ze=O(c))!=null?Ze:O(u))!=null?ot:"0");else{const Gt=O(ff(ce-f,ke,at));nt(parseFloat(Gt)),Ee(Gt)}},UK(R,{increment:St.current,decrement:cn.current}),w.useEffect(()=>{typeof s=="number"&&!$&&(fe(s),Ee(O(s))),I===void 0&&s===void 0&&!$&&(fe(s),Ee(""))},[s,T]);const bn=h!==void 0&&d!==void 0,He=w.useRef(null),Fe=w.useRef(0),st=()=>{He.current&&window.clearTimeout(He.current),He.current=null,Fe.current=0},dt=Me=>{Me?St.current():cn.current(),Fe.current+=1},At=Me=>{if(dt(Me),bn){const Ze=typeof d=="number"?d:d(Fe.current);He.current=window.setTimeout(()=>At(Me),Ze)}},Kt=(Me,Ze)=>{Me.preventDefault(),ge.current.focus(),dt(Ze),bn&&(He.current=window.setTimeout(()=>At(Ze),h))};w.useEffect(()=>(st(),st),[]);const me=N.createElement("div",{className:W.rightSection},N.createElement("button",{type:"button",tabIndex:-1,"aria-hidden":!0,disabled:de>=l,className:Q(W.control,W.controlUp),onPointerDown:Me=>{Kt(Me,!0)},onPointerUp:st,onPointerLeave:st},N.createElement(Tj,{size:x.fn.size({size:B,sizes:Cj}),direction:"up"})),N.createElement("button",{type:"button",tabIndex:-1,"aria-hidden":!0,disabled:de<=u,className:Q(W.control,W.controlDown),onPointerDown:Me=>{Kt(Me,!1)},onPointerUp:st,onPointerLeave:st},N.createElement(Tj,{size:x.fn.size({size:B,sizes:Cj}),direction:"down"}))),Se=Me=>{if(Me.nativeEvent.isComposing)return;const ot=Me.target.value,Gt=yt(ot);Ee(Gt),ot===""||ot==="-"?nt(void 0):ot.trim()!==""&&!Number.isNaN(Gt)&&nt(parseFloat(Gt))},Le=Me=>{var Ze;if(Me.target.value==="")Ee(""),nt(void 0);else{let ot=Me.target.value;(ot[0]===`${a}`||ot[0]===".")&&(ot=`0${ot}`);const Gt=yt(ot),pt=ff(parseFloat(Gt),ke,at);Number.isNaN(pt)?Ee((Ze=O(de))!=null?Ze:""):A||(Ee(O(pt)),nt(parseFloat(O(pt))))}q(!1),typeof p=="function"&&p(Me)},Ke=Me=>{q(!0),typeof m=="function"&&m(Me)},ct=Me=>{if(typeof y=="function"&&y(Me),Me.repeat&&bn&&(Me.key==="ArrowUp"||Me.key==="ArrowDown")){Me.preventDefault();return}r||(Me.key==="ArrowUp"?Kt(Me,!0):Me.key==="ArrowDown"&&Kt(Me,!1))},In=Me=>{typeof g=="function"&&g(Me),(Me.key==="ArrowUp"||Me.key==="ArrowDown")&&st()};return N.createElement(Ev,P2e(A2e({},P),{type:ue,variant:S,value:Je(ve),disabled:i,readOnly:r,ref:fa(ge,t),onChange:Se,onBlur:Le,onFocus:Ke,onKeyDown:ct,onKeyUp:In,rightSection:J||(i||r||v||S==="unstyled"?null:me),rightSectionWidth:V||x.fn.size({size:B,sizes:Aee})+1,radius:b,max:l,min:u,step:f,size:B,styles:L,classNames:F,inputMode:ae||y2e(f,T,Jve()),__staticSelector:"NumberInput",unstyled:ee}))});kee.displayName="@mantine/core/NumberInput";const Aj={xs:3,sm:5,md:8,lg:12,xl:16},D2e=Zye({from:{backgroundPosition:"0 0"},to:{backgroundPosition:"40px 0"}});var $2e=lt((e,{color:t,radius:n,size:r,striped:i,animate:s})=>({root:{position:"relative",height:e.fn.size({size:r,sizes:Aj}),backgroundColor:e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[2],borderRadius:e.fn.size({size:n,sizes:e.radius}),overflow:"hidden"},bar:{position:"absolute",top:0,bottom:0,left:0,height:"100%",display:"flex",justifyContent:"center",alignItems:"center",backgroundColor:e.fn.variant({variant:"filled",primaryFallback:!1,color:t||e.primaryColor}).background,transition:"width 100ms linear",animation:s?`${D2e} 1000ms linear infinite`:"none",backgroundSize:"20px 20px",backgroundImage:i?"linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent)":"none","&:last-of-type":{borderTopRightRadius:e.fn.size({size:n,sizes:e.radius}),borderBottomRightRadius:e.fn.size({size:n,sizes:e.radius})},"&:first-of-type":{borderTopLeftRadius:e.fn.size({size:n,sizes:e.radius}),borderBottomLeftRadius:e.fn.size({size:n,sizes:e.radius})},"@media (prefers-reduced-motion)":{transitionDuration:e.respectReducedMotion?"0ms":void 0}},label:{color:e.white,fontSize:e.fn.size({size:r,sizes:Aj})*.65,fontWeight:700,userSelect:"none",overflow:"hidden",whiteSpace:"nowrap"}}));const Dee=w.createContext(!1),L2e=Dee.Provider,M2e=()=>w.useContext(Dee);function $ee({children:e,openDelay:t=0,closeDelay:n=0}){return N.createElement(L2e,{value:!0},N.createElement(lSe,{delay:{open:t,close:n}},e))}$ee.displayName="@mantine/core/TooltipGroup";var F2e=Object.defineProperty,B2e=Object.defineProperties,j2e=Object.getOwnPropertyDescriptors,Pj=Object.getOwnPropertySymbols,U2e=Object.prototype.hasOwnProperty,V2e=Object.prototype.propertyIsEnumerable,Oj=(e,t,n)=>t in e?F2e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Rj=(e,t)=>{for(var n in t||(t={}))U2e.call(t,n)&&Oj(e,n,t[n]);if(Pj)for(var n of Pj(t))V2e.call(t,n)&&Oj(e,n,t[n]);return e},z2e=(e,t)=>B2e(e,j2e(t));function H2e(e,t){if(!t)return{backgroundColor:e.colorScheme==="dark"?e.colors.dark[6]:e.colors.gray[9],color:e.white};const n=e.fn.variant({variant:"filled",color:t,primaryFallback:!1});return{backgroundColor:n.background,color:n.color}}var Lee=lt((e,{color:t,radius:n,width:r,multiline:i})=>({tooltip:z2e(Rj(Rj({},e.fn.fontStyles()),H2e(e,t)),{lineHeight:e.lineHeight,fontSize:e.fontSizes.sm,borderRadius:e.fn.radius(n),padding:`calc(${e.spacing.xs}px / 2) ${e.spacing.xs}px`,position:"absolute",whiteSpace:i?"unset":"nowrap",pointerEvents:"none",width:r}),arrow:{backgroundColor:"inherit",border:0,zIndex:1}}));const Mee={children:"Tooltip component children should be an element or a component that accepts ref, fragments, strings, numbers and other primitive values are not supported"};function W2e({offset:e,position:t}){const[n,r]=w.useState(!1),i=w.useRef(),{x:s,y:o,reference:a,floating:u,refs:l,update:c,placement:f}=z$({placement:t,middleware:[j$({crossAxis:!0,padding:5,rootBoundary:"document"})]}),d=f.includes("right")?e:t.includes("left")?e*-1:0,h=f.includes("bottom")?e:t.includes("top")?e*-1:0,p=w.useCallback(({clientX:m,clientY:y})=>{a({getBoundingClientRect(){return{width:0,height:0,x:m,y,left:m+d,top:y+h,right:m,bottom:y}}})},[a]);return w.useEffect(()=>{if(l.floating.current){const m=i.current;m.addEventListener("mousemove",p);const y=Fl(l.floating.current);return y.forEach(g=>{g.addEventListener("scroll",c)}),()=>{m.removeEventListener("mousemove",p),y.forEach(g=>{g.removeEventListener("scroll",c)})}}},[a,l.floating.current,c,p,n]),{handleMouseMove:p,x:s,y:o,opened:n,setOpened:r,boundaryRef:i,floating:u}}var q2e=Object.defineProperty,G2e=Object.defineProperties,Y2e=Object.getOwnPropertyDescriptors,sT=Object.getOwnPropertySymbols,Fee=Object.prototype.hasOwnProperty,Bee=Object.prototype.propertyIsEnumerable,Nj=(e,t,n)=>t in e?q2e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,qP=(e,t)=>{for(var n in t||(t={}))Fee.call(t,n)&&Nj(e,n,t[n]);if(sT)for(var n of sT(t))Bee.call(t,n)&&Nj(e,n,t[n]);return e},GP=(e,t)=>G2e(e,Y2e(t)),K2e=(e,t)=>{var n={};for(var r in e)Fee.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&sT)for(var r of sT(e))t.indexOf(r)<0&&Bee.call(e,r)&&(n[r]=e[r]);return n};const Q2e={refProp:"ref",withinPortal:!0,offset:10,position:"right",zIndex:cc("popover")};function jee(e){var t;const n=Ve("TooltipFloating",Q2e,e),{children:r,refProp:i,withinPortal:s,style:o,className:a,classNames:u,styles:l,unstyled:c,radius:f,color:d,label:h,offset:p,position:m,multiline:y,width:g,zIndex:v,disabled:b}=n,S=K2e(n,["children","refProp","withinPortal","style","className","classNames","styles","unstyled","radius","color","label","offset","position","multiline","width","zIndex","disabled"]),{handleMouseMove:T,x:E,y:I,opened:A,boundaryRef:R,floating:F,setOpened:L}=W2e({offset:p,position:m}),{classes:B,cx:J}=Lee({radius:f,color:d,multiline:y,width:g},{name:"TooltipFloating",classNames:u,styles:l,unstyled:c});if(!_g(r))throw new Error(Mee.children);const V=fa(R,r.ref),re=ae=>{var ee,ue;(ue=(ee=r.props).onMouseEnter)==null||ue.call(ee,ae),T(ae),L(!0)},oe=ae=>{var ee,ue;(ue=(ee=r.props).onMouseLeave)==null||ue.call(ee,ae),L(!1)};return N.createElement(N.Fragment,null,N.createElement($_,{withinPortal:s},N.createElement(it,GP(qP({},S),{ref:F,className:J(B.tooltip,a),style:GP(qP({},o),{zIndex:v,display:!b&&A?"block":"none",top:I??"",left:(t=Math.round(E))!=null?t:""})}),h)),w.cloneElement(r,GP(qP({},r.props),{[i]:V,onMouseEnter:re,onMouseLeave:oe})))}jee.displayName="@mantine/core/TooltipFloating";function X2e(e){const[t,n]=w.useState(!1),i=typeof e.opened=="boolean"?e.opened:t,s=M2e(),o=tu(),{delay:a,currentId:u,setCurrentId:l}=kX(),c=w.useCallback(A=>{n(A),A&&l(o)},[l,o]),{x:f,y:d,reference:h,floating:p,context:m,refs:y,update:g,placement:v,middlewareData:{arrow:{x:b,y:S}={}}}=z$({placement:e.position,open:i,onOpenChange:c,middleware:[yX(e.offset),j$({padding:8}),xX(),AX({element:e.arrowRef,padding:e.arrowOffset}),...e.inline?[CX()]:[]]}),{getReferenceProps:T,getFloatingProps:E}=wSe([uSe(m,{enabled:e.events.hover,delay:s?a:{open:e.openDelay,close:e.closeDelay},mouseOnly:!e.events.touch}),_Se(m,{enabled:e.events.focus,keyboardOnly:!0}),bSe(m,{role:"tooltip"}),vSe(m,{enabled:typeof e.opened===void 0}),cSe(m,{id:o})]);return $X({opened:i,positionDependencies:e.positionDependencies,floating:{refs:y,update:g}}),Js(()=>{var A;(A=e.onPositionChange)==null||A.call(e,v)},[v]),{x:f,y:d,arrowX:b,arrowY:S,reference:h,floating:p,getFloatingProps:E,getReferenceProps:T,isGroupPhase:i&&u&&u!==o,opened:i,placement:v}}var J2e=Object.defineProperty,Z2e=Object.defineProperties,eRe=Object.getOwnPropertyDescriptors,oT=Object.getOwnPropertySymbols,Uee=Object.prototype.hasOwnProperty,Vee=Object.prototype.propertyIsEnumerable,kj=(e,t,n)=>t in e?J2e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,v0=(e,t)=>{for(var n in t||(t={}))Uee.call(t,n)&&kj(e,n,t[n]);if(oT)for(var n of oT(t))Vee.call(t,n)&&kj(e,n,t[n]);return e},tRe=(e,t)=>Z2e(e,eRe(t)),nRe=(e,t)=>{var n={};for(var r in e)Uee.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&oT)for(var r of oT(e))t.indexOf(r)<0&&Vee.call(e,r)&&(n[r]=e[r]);return n};const rRe={position:"top",refProp:"ref",withinPortal:!1,inline:!1,arrowSize:4,arrowOffset:5,arrowRadius:0,arrowPosition:"side",offset:5,transition:"fade",transitionDuration:100,width:"auto",events:{hover:!0,focus:!1,touch:!1},zIndex:cc("popover"),positionDependencies:[]},Hx=w.forwardRef((e,t)=>{const n=w.useRef(null),r=Ve("Tooltip",rRe,e),{children:i,position:s,refProp:o,label:a,openDelay:u,closeDelay:l,onPositionChange:c,opened:f,withinPortal:d,radius:h,color:p,classNames:m,styles:y,unstyled:g,style:v,className:b,withArrow:S,arrowSize:T,arrowOffset:E,arrowRadius:I,arrowPosition:A,offset:R,transition:F,transitionDuration:L,multiline:B,width:J,events:V,zIndex:re,disabled:oe,positionDependencies:ae,onClick:ee,onMouseEnter:ue,onMouseLeave:P,inline:W}=r,Q=nRe(r,["children","position","refProp","label","openDelay","closeDelay","onPositionChange","opened","withinPortal","radius","color","classNames","styles","unstyled","style","className","withArrow","arrowSize","arrowOffset","arrowRadius","arrowPosition","offset","transition","transitionDuration","multiline","width","events","zIndex","disabled","positionDependencies","onClick","onMouseEnter","onMouseLeave","inline"]),{classes:x,cx:O,theme:$}=Lee({radius:h,color:p,width:J,multiline:B},{name:"Tooltip",classNames:m,styles:y,unstyled:g}),q=X2e({position:KX($.dir,s),closeDelay:l,openDelay:u,onPositionChange:c,opened:f,events:V,arrowRef:n,arrowOffset:E,offset:R+(S?T/2:0),positionDependencies:[...ae,i],inline:W});if(!_g(i))throw new Error(Mee.children);const ce=fa(q.reference,i.ref,t);return N.createElement(N.Fragment,null,N.createElement($_,{withinPortal:d},N.createElement(Vx,{mounted:!oe&&q.opened,transition:F,duration:q.isGroupPhase?10:L},fe=>{var de,ve;return N.createElement(it,v0(v0({},Q),q.getFloatingProps({ref:q.floating,className:x.tooltip,style:tRe(v0(v0({},v),fe),{zIndex:re,top:(de=q.y)!=null?de:0,left:(ve=q.x)!=null?ve:0})})),a,N.createElement(H$,{ref:n,arrowX:q.arrowX,arrowY:q.arrowY,visible:S,withBorder:!1,position:q.placement,arrowSize:T,arrowOffset:E,arrowRadius:I,arrowPosition:A,className:x.arrow}))})),w.cloneElement(i,q.getReferenceProps(v0({onClick:ee,onMouseEnter:ue,onMouseLeave:P,onMouseMove:e.onMouseMove,onPointerDown:e.onPointerDown,onPointerEnter:e.onPointerEnter,[o]:ce,className:O(b,i.props.className)},i.props))))});Hx.Group=$ee;Hx.Floating=jee;Hx.displayName="@mantine/core/Tooltip";const Wx=Hx;var iRe=Object.defineProperty,sRe=Object.defineProperties,oRe=Object.getOwnPropertyDescriptors,aT=Object.getOwnPropertySymbols,zee=Object.prototype.hasOwnProperty,Hee=Object.prototype.propertyIsEnumerable,Dj=(e,t,n)=>t in e?iRe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,XR=(e,t)=>{for(var n in t||(t={}))zee.call(t,n)&&Dj(e,n,t[n]);if(aT)for(var n of aT(t))Hee.call(t,n)&&Dj(e,n,t[n]);return e},Wee=(e,t)=>sRe(e,oRe(t)),$j=(e,t)=>{var n={};for(var r in e)zee.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&aT)for(var r of aT(e))t.indexOf(r)<0&&Hee.call(e,r)&&(n[r]=e[r]);return n};function aRe(e){return e.reduce((t,n)=>(t.sections.push(Wee(XR({},n),{accumulated:t.accumulated})),t.accumulated+=n.value,t),{accumulated:0,sections:[]}).sections}const uRe={size:"md",radius:"sm",striped:!1,animate:!1,label:""},qee=w.forwardRef((e,t)=>{const n=Ve("Progress",uRe,e),{className:r,value:i,color:s,size:o,radius:a,striped:u,animate:l,label:c,"aria-label":f,classNames:d,styles:h,sections:p,unstyled:m}=n,y=$j(n,["className","value","color","size","radius","striped","animate","label","aria-label","classNames","styles","sections","unstyled"]),{classes:g,cx:v,theme:b}=$2e({color:s,size:o,radius:a,striped:u||l,animate:l},{classNames:d,styles:h,unstyled:m,name:"Progress"}),S=Array.isArray(p)?aRe(p).map((T,E)=>{var I=T,{tooltip:A,accumulated:R,value:F,label:L,color:B}=I,J=$j(I,["tooltip","accumulated","value","label","color"]);return N.createElement(Wx.Floating,{label:A,disabled:!A,key:E},N.createElement(it,Wee(XR({},J),{className:v(g.bar,J.className),sx:{width:`${F}%`,left:`${R}%`,backgroundColor:b.fn.variant({variant:"filled",primaryFallback:!1,color:B||b.primaryColor}).background}}),L&&N.createElement(rt,{className:g.label},L)))}):null;return N.createElement(it,XR({className:v(g.root,r),ref:t},y),S||N.createElement("div",{role:"progressbar","aria-valuemax":100,"aria-valuemin":0,"aria-valuenow":i,"aria-label":f,className:g.bar,style:{width:`${i}%`}},c?N.createElement(rt,{className:g.label},c):""))});qee.displayName="@mantine/core/Progress";var lRe=Object.defineProperty,Lj=Object.getOwnPropertySymbols,cRe=Object.prototype.hasOwnProperty,fRe=Object.prototype.propertyIsEnumerable,Mj=(e,t,n)=>t in e?lRe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,dRe=(e,t)=>{for(var n in t||(t={}))cRe.call(t,n)&&Mj(e,n,t[n]);if(Lj)for(var n of Lj(t))fRe.call(t,n)&&Mj(e,n,t[n]);return e};function hRe(e){return N.createElement("svg",dRe({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 5 5"},e),N.createElement("path",{fill:"currentColor",d:"M0 2.5a2.5 2.5 0 115 0 2.5 2.5 0 01-5 0z"}))}const Gee=w.createContext(null),pRe=Gee.Provider,mRe=()=>w.useContext(Gee);var gRe=Object.defineProperty,uT=Object.getOwnPropertySymbols,Yee=Object.prototype.hasOwnProperty,Kee=Object.prototype.propertyIsEnumerable,Fj=(e,t,n)=>t in e?gRe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Bj=(e,t)=>{for(var n in t||(t={}))Yee.call(t,n)&&Fj(e,n,t[n]);if(uT)for(var n of uT(t))Kee.call(t,n)&&Fj(e,n,t[n]);return e},yRe=(e,t)=>{var n={};for(var r in e)Yee.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&uT)for(var r of uT(e))t.indexOf(r)<0&&Kee.call(e,r)&&(n[r]=e[r]);return n};const vRe={orientation:"horizontal",spacing:"lg",offset:"xs",size:"sm"},Qee=w.forwardRef((e,t)=>{const n=Ve("RadioGroup",vRe,e),{children:r,value:i,defaultValue:s,onChange:o,orientation:a,spacing:u,size:l,wrapperProps:c,unstyled:f,offset:d,name:h}=n,p=yRe(n,["children","value","defaultValue","onChange","orientation","spacing","size","wrapperProps","unstyled","offset","name"]),m=tu(h),[y,g]=oa({value:i,defaultValue:s,finalValue:"",onChange:o}),v=b=>g(b.currentTarget.value);return N.createElement(pRe,{value:{value:y,onChange:v,size:l,name:m}},N.createElement(Zs.Wrapper,Bj(Bj({labelElement:"div",size:l,__staticSelector:"RadioGroup",ref:t,unstyled:f},c),p),N.createElement(WJ,{spacing:u,orientation:a,unstyled:f,role:"radiogroup",offset:d},r)))});Qee.displayName="@mantine/core/RadioGroup";var _Re=Object.defineProperty,bRe=Object.defineProperties,wRe=Object.getOwnPropertyDescriptors,jj=Object.getOwnPropertySymbols,ERe=Object.prototype.hasOwnProperty,SRe=Object.prototype.propertyIsEnumerable,Uj=(e,t,n)=>t in e?_Re(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,TRe=(e,t)=>{for(var n in t||(t={}))ERe.call(t,n)&&Uj(e,n,t[n]);if(jj)for(var n of jj(t))SRe.call(t,n)&&Uj(e,n,t[n]);return e},IRe=(e,t)=>bRe(e,wRe(t));const YP={xs:16,sm:20,md:24,lg:30,xl:36},yb={xs:6,sm:8,md:10,lg:14,xl:16};var xRe=lt((e,{size:t,color:n,transitionDuration:r,labelPosition:i,error:s},o)=>{const a=e.fn.variant({variant:"filled",color:n}),u=e.fn.variant({variant:"filled",color:"red"}).background;return{inner:{order:i==="left"?2:1,position:"relative",alignSelf:"flex-start"},icon:{ref:o("icon"),color:e.white,opacity:0,transform:"scale(0.75) translateY(2px)",transition:`opacity ${r}ms ${e.transitionTimingFunction}`,pointerEvents:"none",width:e.fn.size({sizes:yb,size:t}),height:e.fn.size({sizes:yb,size:t}),position:"absolute",top:`calc(50% - ${e.fn.size({sizes:yb,size:t})/2}px)`,left:`calc(50% - ${e.fn.size({sizes:yb,size:t})/2}px)`},radio:IRe(TRe({},e.fn.focusStyles()),{backgroundColor:e.colorScheme==="dark"?e.colors.dark[6]:e.white,border:`1px solid ${s?u:e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[4]}`,position:"relative",appearance:"none",width:e.fn.size({sizes:YP,size:t}),height:e.fn.size({sizes:YP,size:t}),borderRadius:e.fn.size({sizes:YP,size:t}),margin:0,display:"flex",alignItems:"center",justifyContent:"center",transitionProperty:"background-color, border-color",transitionTimingFunction:e.transitionTimingFunction,transitionDuration:`${r}ms`,cursor:e.cursorType,"&:checked":{background:a.background,borderColor:a.background,[`& + .${o("icon")}`]:{opacity:1,transform:"scale(1)"}},"&:disabled":{borderColor:e.colorScheme==="dark"?e.colors.dark[5]:e.colors.gray[4],backgroundColor:e.colorScheme==="dark"?e.colors.dark[5]:e.colors.gray[1],[`& + .${o("icon")}`]:{color:e.colorScheme==="dark"?e.colors.dark[6]:e.colors.gray[4]}}})}}),CRe=Object.defineProperty,lT=Object.getOwnPropertySymbols,Xee=Object.prototype.hasOwnProperty,Jee=Object.prototype.propertyIsEnumerable,Vj=(e,t,n)=>t in e?CRe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,vb=(e,t)=>{for(var n in t||(t={}))Xee.call(t,n)&&Vj(e,n,t[n]);if(lT)for(var n of lT(t))Jee.call(t,n)&&Vj(e,n,t[n]);return e},ARe=(e,t)=>{var n={};for(var r in e)Xee.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&lT)for(var r of lT(e))t.indexOf(r)<0&&Jee.call(e,r)&&(n[r]=e[r]);return n};const PRe={icon:hRe,transitionDuration:100,size:"sm",labelPosition:"right"},cT=w.forwardRef((e,t)=>{var n,r;const i=Ve("Radio",PRe,e),{className:s,style:o,id:a,label:u,size:l,title:c,disabled:f,color:d,classNames:h,styles:p,sx:m,icon:y,transitionDuration:g,wrapperProps:v,unstyled:b,labelPosition:S,description:T,error:E}=i,I=ARe(i,["className","style","id","label","size","title","disabled","color","classNames","styles","sx","icon","transitionDuration","wrapperProps","unstyled","labelPosition","description","error"]),A=mRe(),R=(n=A==null?void 0:A.size)!=null?n:l,F=e.size?l:R,{classes:L}=xRe({color:d,size:F,transitionDuration:g,labelPosition:S,error:!!E},{classNames:h,styles:p,unstyled:b,name:"Radio"}),{systemStyles:B,rest:J}=Qf(I),V=tu(a),re=A?{checked:A.value===J.value,name:(r=J.name)!=null?r:A.name,onChange:A.onChange}:{};return N.createElement(Q$,vb(vb({className:s,sx:m,style:o,id:V,size:F,labelPosition:S,label:u,description:T,error:E,disabled:f,__staticSelector:"Radio",classNames:h,styles:p,unstyled:b,"data-checked":re.checked||void 0},B),v),N.createElement("div",{className:L.inner},N.createElement("input",vb(vb({ref:t,className:L.radio,type:"radio",id:V,disabled:f},J),re)),N.createElement(y,{className:L.icon,"aria-hidden":!0})))});cT.displayName="@mantine/core/Radio";cT.Group=Qee;var ORe=Object.defineProperty,RRe=Object.defineProperties,NRe=Object.getOwnPropertyDescriptors,zj=Object.getOwnPropertySymbols,kRe=Object.prototype.hasOwnProperty,DRe=Object.prototype.propertyIsEnumerable,Hj=(e,t,n)=>t in e?ORe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,_b=(e,t)=>{for(var n in t||(t={}))kRe.call(t,n)&&Hj(e,n,t[n]);if(zj)for(var n of zj(t))DRe.call(t,n)&&Hj(e,n,t[n]);return e},$Re=(e,t)=>RRe(e,NRe(t));const Ow=4,Wj={xs:"3px 6px",sm:"5px 10px",md:"7px 14px",lg:"9px 16px",xl:"12px 20px"};var LRe=lt((e,{fullWidth:t,color:n,radius:r,shouldAnimate:i,transitionDuration:s,transitionTimingFunction:o,size:a,orientation:u},l)=>{const c=u==="vertical",f=e.fn.variant({variant:"filled",color:n});return{label:$Re(_b(_b({ref:l("label")},e.fn.focusStyles()),e.fn.fontStyles()),{WebkitTapHighlightColor:"transparent",borderRadius:e.fn.radius(r),fontWeight:500,fontSize:a in e.fontSizes?e.fontSizes[a]:e.fontSizes.sm,cursor:"pointer",display:"block",textAlign:"center",padding:Wj[a in Wj?a:"sm"],whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis",userSelect:"none",color:e.colorScheme==="dark"?e.colors.dark[1]:e.colors.gray[7],transition:`color ${i?0:s}ms ${o||e.transitionTimingFunction}`,"&:hover":{color:e.colorScheme==="dark"?e.colors.dark[0]:e.black}}),control:{ref:l("control"),position:"relative",boxSizing:"border-box",flex:1,zIndex:2,transition:`border-left-color ${i?0:s}ms ${o||e.transitionTimingFunction}`,"&:not(:first-of-type)":{borderStyle:"solid",borderWidth:c?"1px 0 0 0":"0 0 0 1px",borderColor:e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[3]}},input:{height:0,width:0,position:"absolute",overflow:"hidden",whiteSpace:"nowrap",opacity:0,"&:focus":{outline:"none",[`& + .${l("label")}`]:_b({},e.focusRing==="always"||e.focusRing==="auto"?e.focusRingStyles.styles(e):e.focusRingStyles.resetStyles(e)),"&:focus:not(:focus-visible)":{[`& + .${l("label")}`]:_b({},e.focusRing==="auto"||e.focusRing==="never"?e.focusRingStyles.resetStyles(e):null)}}},root:{position:"relative",display:t||c?"flex":"inline-flex",width:c&&!t?"max-content":"auto",flexDirection:c?"column":"row",backgroundColor:e.colorScheme==="dark"?e.colors.dark[8]:e.colors.gray[1],borderRadius:e.fn.radius(r),overflow:"hidden",padding:Ow},controlActive:{borderLeftColor:"transparent !important",borderTopColor:"transparent !important",[`& + .${l("control")}`]:{borderLeftColor:"transparent !important",borderTopColor:"transparent !important"},borderRadius:e.fn.radius(r),boxShadow:i?n||e.colorScheme==="dark"?"none":e.shadows.xs:void 0,backgroundColor:i?n?f.background:e.colorScheme==="dark"?e.colors.dark[5]:e.white:void 0},labelActive:{"&, &:hover":{color:n||e.colorScheme==="dark"?e.white:e.black}},disabled:{"&, &:hover":{color:e.colorScheme==="dark"?e.colors.dark[3]:e.colors.gray[5],cursor:"not-allowed"}},active:{boxSizing:"border-box",borderRadius:e.fn.radius(r),position:"absolute",zIndex:1,boxShadow:n||e.colorScheme==="dark"?"none":e.shadows.xs,transition:`transform ${i?0:s}ms ${e.transitionTimingFunction}, width ${i?0:s/2}ms ${o||e.transitionTimingFunction}`,backgroundColor:n?f.background:e.colorScheme==="dark"?e.colors.dark[5]:e.white}}}),MRe=Object.defineProperty,fT=Object.getOwnPropertySymbols,Zee=Object.prototype.hasOwnProperty,ete=Object.prototype.propertyIsEnumerable,qj=(e,t,n)=>t in e?MRe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,FRe=(e,t)=>{for(var n in t||(t={}))Zee.call(t,n)&&qj(e,n,t[n]);if(fT)for(var n of fT(t))ete.call(t,n)&&qj(e,n,t[n]);return e},BRe=(e,t)=>{var n={};for(var r in e)Zee.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&fT)for(var r of fT(e))t.indexOf(r)<0&&ete.call(e,r)&&(n[r]=e[r]);return n};const jRe={disabled:!1,size:"sm",transitionDuration:200},JR=w.forwardRef((e,t)=>{var n,r,i,s;const o=Ve("SegmentedControl",jRe,e),{className:a,disabled:u,data:l,name:c,value:f,onChange:d,color:h,fullWidth:p,radius:m,size:y,transitionDuration:g,transitionTimingFunction:v,classNames:b,styles:S,defaultValue:T,orientation:E,unstyled:I}=o,A=BRe(o,["className","disabled","data","name","value","onChange","color","fullWidth","radius","size","transitionDuration","transitionTimingFunction","classNames","styles","defaultValue","orientation","unstyled"]),R=ji(),F=Rx(),L=R.respectReducedMotion?F:!1,B=l.map(fe=>typeof fe=="string"?{label:fe,value:fe}:fe),J=w.useRef(),[V,re]=w.useState(!1),[oe,ae]=oa({value:f,defaultValue:T,finalValue:Array.isArray(B)&&(s=(i=(n=B.find(fe=>!fe.disabled))==null?void 0:n.value)!=null?i:(r=B[0])==null?void 0:r.value)!=null?s:null,onChange:d}),{classes:ee,cx:ue}=LRe({size:y,fullWidth:p,color:h,radius:m,shouldAnimate:L||!V,transitionDuration:g,transitionTimingFunction:v,orientation:E},{classNames:b,styles:S,unstyled:I,name:"SegmentedControl"}),[P,W]=w.useState({width:0,height:0,translate:[0,0]}),Q=tu(c),x=w.useRef({}),[O,$]=Nx();T$(()=>{J.current?re(!0):(J.current=!0,re(!1))}),w.useEffect(()=>{if(oe in x.current&&O.current){const fe=x.current[oe],de=fe.getBoundingClientRect(),ve=fe.offsetWidth/de.width,Ee=de.width*ve||0,ge=de.height*ve||0,nt=$.width-fe.parentElement.offsetLeft+Ow-Ee,Je=fe.parentElement.offsetLeft-Ow;W({width:Ee,height:ge,translate:[R.dir==="rtl"?nt:Je,fe.parentElement.offsetTop-Ow]})}},[oe,$]);const q=B.map(fe=>N.createElement("div",{className:ue(ee.control,{[ee.controlActive]:oe===fe.value}),key:fe.value},N.createElement("input",{className:ee.input,disabled:u||fe.disabled,type:"radio",name:Q,value:fe.value,id:`${Q}-${fe.value}`,checked:oe===fe.value,onChange:()=>ae(fe.value)}),N.createElement("label",{className:ue(ee.label,{[ee.labelActive]:oe===fe.value,[ee.disabled]:u||fe.disabled}),htmlFor:`${Q}-${fe.value}`,ref:de=>{x.current[fe.value]=de}},fe.label))),ce=fa(O,t);return B.length===0?null:N.createElement(it,FRe({className:ue(ee.root,a),ref:ce},A),typeof oe=="string"&&V&&N.createElement(it,{component:"span",className:ee.active,sx:{width:P.width,height:P.height,transform:`translate(${P.translate[0]}px, ${P.translate[1]}px )`}}),q)});JR.displayName="@mantine/core/SegmentedControl";function URe({data:e,searchable:t,limit:n,searchValue:r,filter:i,value:s,filterDataOnExactSearchMatch:o}){if(!t)return e;const a=s!=null&&e.find(l=>l.value===s)||null;if(a&&!o&&(a==null?void 0:a.label)===r){if(n){if(n>=e.length)return e;const l=e.indexOf(a),c=l+n,f=c-e.length;return f>0?e.slice(l-f):e.slice(l,c)}return e}const u=[];for(let l=0;l=n));l+=1);return u}var VRe=lt(()=>({input:{"&:not(:disabled)":{cursor:"pointer","&::selection":{backgroundColor:"transparent"}}}})),zRe=Object.defineProperty,HRe=Object.defineProperties,WRe=Object.getOwnPropertyDescriptors,dT=Object.getOwnPropertySymbols,tte=Object.prototype.hasOwnProperty,nte=Object.prototype.propertyIsEnumerable,Gj=(e,t,n)=>t in e?zRe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,_0=(e,t)=>{for(var n in t||(t={}))tte.call(t,n)&&Gj(e,n,t[n]);if(dT)for(var n of dT(t))nte.call(t,n)&&Gj(e,n,t[n]);return e},KP=(e,t)=>HRe(e,WRe(t)),qRe=(e,t)=>{var n={};for(var r in e)tte.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&dT)for(var r of dT(e))t.indexOf(r)<0&&nte.call(e,r)&&(n[r]=e[r]);return n};function GRe(e,t){return t.label.toLowerCase().trim().includes(e.toLowerCase().trim())}function YRe(e,t){return!!e&&!t.some(n=>n.label.toLowerCase()===e.toLowerCase())}const KRe={required:!1,size:"sm",shadow:"sm",itemComponent:P$,transition:"fade",transitionDuration:0,initiallyOpened:!1,filter:GRe,maxDropdownHeight:220,searchable:!1,clearable:!1,limit:1/0,disabled:!1,creatable:!1,shouldCreate:YRe,selectOnBlur:!1,switchDirectionOnFlip:!1,filterDataOnExactSearchMatch:!1,zIndex:cc("popover"),clearButtonTabIndex:0,positionDependencies:[],dropdownPosition:"flip"},rte=w.forwardRef((e,t)=>{const n=eJ("Select",KRe,e),{inputProps:r,wrapperProps:i,shadow:s,data:o,value:a,defaultValue:u,onChange:l,itemComponent:c,onKeyDown:f,onBlur:d,onFocus:h,transition:p,transitionDuration:m,initiallyOpened:y,transitionTimingFunction:g,unstyled:v,classNames:b,styles:S,filter:T,maxDropdownHeight:E,searchable:I,clearable:A,nothingFound:R,clearButtonLabel:F,limit:L,disabled:B,onSearchChange:J,searchValue:V,rightSection:re,rightSectionWidth:oe,creatable:ae,getCreateLabel:ee,shouldCreate:ue,selectOnBlur:P,onCreate:W,dropdownComponent:Q,onDropdownClose:x,onDropdownOpen:O,withinPortal:$,switchDirectionOnFlip:q,zIndex:ce,name:fe,dropdownPosition:de,allowDeselect:ve,placeholder:Ee,filterDataOnExactSearchMatch:ge,clearButtonTabIndex:nt,form:Je,positionDependencies:yt,readOnly:ke,hoverOnSearchChange:at}=n,St=qRe(n,["inputProps","wrapperProps","shadow","data","value","defaultValue","onChange","itemComponent","onKeyDown","onBlur","onFocus","transition","transitionDuration","initiallyOpened","transitionTimingFunction","unstyled","classNames","styles","filter","maxDropdownHeight","searchable","clearable","nothingFound","clearButtonLabel","limit","disabled","onSearchChange","searchValue","rightSection","rightSectionWidth","creatable","getCreateLabel","shouldCreate","selectOnBlur","onCreate","dropdownComponent","onDropdownClose","onDropdownOpen","withinPortal","switchDirectionOnFlip","zIndex","name","dropdownPosition","allowDeselect","placeholder","filterDataOnExactSearchMatch","clearButtonTabIndex","form","positionDependencies","readOnly","hoverOnSearchChange"]),{classes:cn,cx:bn,theme:He}=VRe(),[Fe,st]=w.useState(y),[dt,At]=w.useState(-1),Kt=w.useRef(),me=w.useRef({}),[Se,Le]=w.useState("column"),Ke=Se==="column",{scrollIntoView:ct,targetRef:In,scrollableRef:Me}=HK({duration:0,offset:5,cancelable:!1,isList:!0}),Ze=ve===void 0?A:ve,ot=xe=>{if(Fe!==xe){st(xe);const et=xe?O:x;typeof et=="function"&&et()}},Gt=ae&&typeof ee=="function";let pt=null;const _r=o.map(xe=>typeof xe=="string"?{label:xe,value:xe}:xe),mn=uK({data:_r}),[qn,cs,xs]=oa({value:a,defaultValue:u,finalValue:null,onChange:l}),ui=mn.find(xe=>xe.value===qn),[Nn,ba]=oa({value:V,defaultValue:(ui==null?void 0:ui.label)||"",finalValue:void 0,onChange:J}),Nr=xe=>{ba(xe),I&&typeof J=="function"&&J(xe)},br=()=>{var xe;ke||(cs(null),xs||Nr(""),(xe=Kt.current)==null||xe.focus())};w.useEffect(()=>{const xe=mn.find(et=>et.value===qn);xe?Nr(xe.label):(!Gt||!qn)&&Nr("")},[qn]),w.useEffect(()=>{ui&&(!I||!Fe)&&Nr(ui.label)},[ui==null?void 0:ui.label]);const $n=xe=>{if(!ke)if(Ze&&(ui==null?void 0:ui.value)===xe.value)cs(null),ot(!1);else{if(xe.creatable&&typeof W=="function"){const et=W(xe.value);typeof et<"u"&&et!==null&&cs(typeof et=="string"?et:et.value)}else cs(xe.value);xs||Nr(xe.label),At(-1),ot(!1),Kt.current.focus()}},fn=URe({data:mn,searchable:I,limit:L,searchValue:Nn,filter:T,filterDataOnExactSearchMatch:ge,value:qn});Gt&&ue(Nn,fn)&&(pt=ee(Nn),fn.push({label:Nn,value:Nn,creatable:!0}));const Yn=(xe,et,Ft)=>{let Be=xe;for(;Ft(Be);)if(Be=et(Be),!fn[Be].disabled)return Be;return xe};Js(()=>{At(at&&Nn?0:-1)},[Nn,at]);const fs=qn?fn.findIndex(xe=>xe.value===qn):0,Kr=!ke&&(fn.length>0?Fe:Fe&&!!R),jr=()=>{At(xe=>{var et;const Ft=Yn(xe,Be=>Be-1,Be=>Be>0);return In.current=me.current[(et=fn[Ft])==null?void 0:et.value],Kr&&ct({alignment:Ke?"start":"end"}),Ft})},X=()=>{At(xe=>{var et;const Ft=Yn(xe,Be=>Be+1,Be=>Bewindow.setTimeout(()=>{var xe;In.current=me.current[(xe=fn[fs])==null?void 0:xe.value],ct({alignment:Ke?"end":"start"})},0);Js(()=>{Kr&&z()},[Kr]);const Z=xe=>{switch(typeof f=="function"&&f(xe),xe.key){case"ArrowUp":{xe.preventDefault(),Fe?Ke?jr():X():(At(fs),ot(!0),z());break}case"ArrowDown":{xe.preventDefault(),Fe?Ke?X():jr():(At(fs),ot(!0),z());break}case"Home":{if(!I){xe.preventDefault(),Fe||ot(!0);const et=fn.findIndex(Ft=>!Ft.disabled);At(et),Kr&&ct({alignment:Ke?"end":"start"})}break}case"End":{if(!I){xe.preventDefault(),Fe||ot(!0);const et=fn.map(Ft=>!!Ft.disabled).lastIndexOf(!1);At(et),Kr&&ct({alignment:Ke?"end":"start"})}break}case"Escape":{xe.preventDefault(),ot(!1),At(-1);break}case" ":{I||(xe.preventDefault(),fn[dt]&&Fe?$n(fn[dt]):(ot(!0),At(fs),z()));break}case"Enter":I||xe.preventDefault(),fn[dt]&&Fe&&(xe.preventDefault(),$n(fn[dt]))}},he=xe=>{typeof d=="function"&&d(xe);const et=mn.find(Ft=>Ft.value===qn);P&&fn[dt]&&Fe&&$n(fn[dt]),Nr((et==null?void 0:et.label)||""),ot(!1)},pe=xe=>{typeof h=="function"&&h(xe),I&&ot(!0)},Ye=xe=>{ke||(Nr(xe.currentTarget.value),A&&xe.currentTarget.value===""&&cs(null),At(-1),ot(!0))},Qe=()=>{ke||(ot(!Fe),qn&&!Fe&&At(fs))};return N.createElement(Zs.Wrapper,KP(_0({},i),{__staticSelector:"Select"}),N.createElement(hf,{opened:Kr,transition:p,transitionDuration:m,shadow:"sm",withinPortal:$,__staticSelector:"Select",onDirectionChange:Le,switchDirectionOnFlip:q,zIndex:ce,dropdownPosition:de,positionDependencies:[...yt,Nn],classNames:b,styles:S,unstyled:v},N.createElement(hf.Target,null,N.createElement("div",{role:"combobox","aria-haspopup":"listbox","aria-owns":Kr?`${r.id}-items`:null,"aria-controls":r.id,"aria-expanded":Kr,onMouseLeave:()=>At(-1),tabIndex:-1},N.createElement("input",{type:"hidden",name:fe,value:qn||"",form:Je,disabled:B}),N.createElement(Zs,_0(KP(_0(_0({autoComplete:"off",type:"search"},r),St),{ref:fa(t,Kt),onKeyDown:Z,__staticSelector:"Select",value:Nn,placeholder:Ee,onChange:Ye,"aria-autocomplete":"list","aria-controls":Kr?`${r.id}-items`:null,"aria-activedescendant":dt>=0?`${r.id}-${dt}`:null,onMouseDown:Qe,onBlur:he,onFocus:pe,readOnly:!I||ke,disabled:B,"data-mantine-stop-propagation":Kr,name:null,classNames:KP(_0({},b),{input:bn({[cn.input]:!I},b==null?void 0:b.input)})}),bee({theme:He,rightSection:re,rightSectionWidth:oe,styles:S,size:r.size,shouldClear:A&&!!ui,clearButtonLabel:F,onClear:br,error:i.error,clearButtonTabIndex:nt,disabled:B,readOnly:ke}))))),N.createElement(hf.Dropdown,{component:Q||Bx,maxHeight:E,direction:Se,id:r.id,innerRef:Me,__staticSelector:"Select",classNames:b,styles:S},N.createElement(A$,{data:fn,hovered:dt,classNames:b,styles:S,isItemSelected:xe=>xe===qn,uuid:r.id,__staticSelector:"Select",onItemHover:At,onItemSelect:$n,itemsRefs:me,itemComponent:c,size:r.size,nothingFound:R,creatable:Gt&&!!pt,createLabel:pt,"aria-label":i.label,unstyled:v}))))});rte.displayName="@mantine/core/Select";function hT({value:e,min:t,max:n}){const r=(e-t)/(n-t)*100;return Math.min(Math.max(r,0),100)}function ZR({value:e,containerWidth:t,min:n,max:r,step:i,precision:s}){const a=(t?Math.min(Math.max(e,0),t)/t:e)*(r-n),u=(a!==0?Math.round(a/i)*i:0)+n,l=Math.max(u,n);return s!==void 0?Number(l.toFixed(s)):l}var QRe=Object.defineProperty,XRe=Object.defineProperties,JRe=Object.getOwnPropertyDescriptors,Yj=Object.getOwnPropertySymbols,ZRe=Object.prototype.hasOwnProperty,eNe=Object.prototype.propertyIsEnumerable,Kj=(e,t,n)=>t in e?QRe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,tNe=(e,t)=>{for(var n in t||(t={}))ZRe.call(t,n)&&Kj(e,n,t[n]);if(Yj)for(var n of Yj(t))eNe.call(t,n)&&Kj(e,n,t[n]);return e},nNe=(e,t)=>XRe(e,JRe(t));const Vs={xs:4,sm:6,md:8,lg:10,xl:12};var rNe=lt((e,{size:t,disabled:n})=>({root:nNe(tNe({},e.fn.fontStyles()),{WebkitTapHighlightColor:"transparent",outline:0,height:e.fn.size({sizes:Vs,size:t})*2,display:"flex",alignItems:"center",cursor:n?"not-allowed":"pointer",touchAction:"none"})}));const iNe=rNe;var sNe=Object.defineProperty,oNe=Object.defineProperties,aNe=Object.getOwnPropertyDescriptors,Qj=Object.getOwnPropertySymbols,uNe=Object.prototype.hasOwnProperty,lNe=Object.prototype.propertyIsEnumerable,Xj=(e,t,n)=>t in e?sNe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,cNe=(e,t)=>{for(var n in t||(t={}))uNe.call(t,n)&&Xj(e,n,t[n]);if(Qj)for(var n of Qj(t))lNe.call(t,n)&&Xj(e,n,t[n]);return e},fNe=(e,t)=>oNe(e,aNe(t)),dNe=lt((e,{color:t,size:n,disabled:r,thumbSize:i})=>({label:{position:"absolute",top:-36,backgroundColor:e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[9],fontSize:e.fontSizes.xs,color:e.white,padding:`calc(${e.spacing.xs}px / 2)`,borderRadius:e.radius.sm,whiteSpace:"nowrap",pointerEvents:"none",userSelect:"none",touchAction:"none"},thumb:fNe(cNe({},e.fn.focusStyles()),{boxSizing:"border-box",position:"absolute",display:r?"none":"flex",height:i||e.fn.size({sizes:Vs,size:n})*2,width:i||e.fn.size({sizes:Vs,size:n})*2,backgroundColor:e.colorScheme==="dark"?e.fn.themeColor(t,e.fn.primaryShade()):e.white,border:`4px solid ${e.colorScheme==="dark"?e.white:e.fn.themeColor(t,e.fn.primaryShade())}`,color:e.colorScheme==="dark"?e.white:e.fn.themeColor(t,e.fn.primaryShade()),transform:"translate(-50%, -50%)",top:"50%",cursor:"pointer",borderRadius:1e3,alignItems:"center",justifyContent:"center",transitionDuration:"100ms",transitionProperty:"box-shadow, transform",transitionTimingFunction:e.transitionTimingFunction,zIndex:3,userSelect:"none",touchAction:"none"}),dragging:{transform:"translate(-50%, -50%) scale(1.05)",boxShadow:e.shadows.sm}}));const pT=w.forwardRef(({max:e,min:t,value:n,position:r,label:i,dragging:s,onMouseDown:o,color:a,classNames:u,styles:l,size:c,labelTransition:f,labelTransitionDuration:d,labelTransitionTimingFunction:h,labelAlwaysOn:p,thumbLabel:m,onFocus:y,onBlur:g,showLabelOnHover:v,children:b=null,disabled:S,unstyled:T,thumbSize:E},I)=>{const{classes:A,cx:R,theme:F}=dNe({color:a,size:c,disabled:S,thumbSize:E},{classNames:u,styles:l,unstyled:T,name:"Slider"}),[L,B]=w.useState(!1),J=p||s||L||v;return N.createElement(it,{tabIndex:0,role:"slider","aria-label":m,"aria-valuemax":e,"aria-valuemin":t,"aria-valuenow":n,ref:I,className:R(A.thumb,{[A.dragging]:s}),onFocus:()=>{B(!0),typeof y=="function"&&y()},onBlur:()=>{B(!1),typeof g=="function"&&g()},onTouchStart:o,onMouseDown:o,onClick:V=>V.stopPropagation(),style:{[F.dir==="rtl"?"right":"left"]:`${r}%`}},b,N.createElement(Vx,{mounted:i!=null&&J,duration:d,transition:f,timingFunction:h||F.transitionTimingFunction},V=>N.createElement("div",{style:V,className:A.label},i)))});pT.displayName="@mantine/core/SliderThumb";function hNe({mark:e,offset:t,value:n,inverted:r=!1}){return r?typeof t=="number"&&e.value<=t||e.value>=n:typeof t=="number"?e.value>=t&&e.value<=n:e.value<=n}var pNe=lt((e,{size:t,color:n,disabled:r})=>({markWrapper:{position:"absolute",top:0,zIndex:2},mark:{boxSizing:"border-box",border:`${e.fn.size({size:t,sizes:Vs})>=8?"2px":"1px"} solid ${e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[2]}`,height:e.fn.size({sizes:Vs,size:t}),width:e.fn.size({sizes:Vs,size:t}),borderRadius:1e3,transform:`translateX(-${e.fn.size({sizes:Vs,size:t})/2}px)`,backgroundColor:e.white},markFilled:{borderColor:r?e.colorScheme==="dark"?e.colors.dark[3]:e.colors.gray[4]:e.fn.variant({variant:"filled",color:n}).background},markLabel:{transform:"translate(-50%, 0)",fontSize:e.fontSizes.sm,color:e.colorScheme==="dark"?e.colors.dark[2]:e.colors.gray[6],marginTop:`calc(${e.spacing.xs}px / 2)`,whiteSpace:"nowrap"}}));function ite({marks:e,color:t,size:n,min:r,max:i,value:s,classNames:o,styles:a,offset:u,onChange:l,disabled:c,unstyled:f,inverted:d}){const{classes:h,cx:p}=pNe({size:n,color:t,disabled:c},{classNames:o,styles:a,unstyled:f,name:"Slider"}),m=e.map((y,g)=>N.createElement(it,{className:h.markWrapper,sx:{left:`${hT({value:y.value,min:r,max:i})}%`},key:g},N.createElement("div",{className:p(h.mark,{[h.markFilled]:hNe({mark:y,value:s,offset:u,inverted:d})})}),y.label&&N.createElement("div",{className:h.markLabel,onMouseDown:v=>{v.stopPropagation(),l(y.value)},onTouchStart:v=>{v.stopPropagation(),l(y.value)}},y.label)));return N.createElement("div",null,m)}ite.displayName="@mantine/core/SliderMarks";var mNe=lt((e,{radius:t,size:n,color:r,disabled:i,inverted:s})=>({track:{position:"relative",height:e.fn.size({sizes:Vs,size:n}),width:"100%",marginRight:e.fn.size({size:n,sizes:Vs}),marginLeft:e.fn.size({size:n,sizes:Vs}),"&::before":{content:'""',position:"absolute",top:0,bottom:0,borderRadius:e.fn.size({size:t,sizes:e.radius}),right:-e.fn.size({size:n,sizes:Vs}),left:-e.fn.size({size:n,sizes:Vs}),backgroundColor:s?i?e.colorScheme==="dark"?e.colors.dark[3]:e.colors.gray[4]:e.fn.variant({variant:"filled",color:r}).background:e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[2],zIndex:0}},bar:{position:"absolute",zIndex:1,top:0,bottom:0,backgroundColor:s?e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[2]:i?e.colorScheme==="dark"?e.colors.dark[3]:e.colors.gray[4]:e.fn.variant({variant:"filled",color:r}).background,borderRadius:e.fn.size({size:t,sizes:e.radius})}})),gNe=Object.defineProperty,yNe=Object.defineProperties,vNe=Object.getOwnPropertyDescriptors,mT=Object.getOwnPropertySymbols,ste=Object.prototype.hasOwnProperty,ote=Object.prototype.propertyIsEnumerable,Jj=(e,t,n)=>t in e?gNe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,_Ne=(e,t)=>{for(var n in t||(t={}))ste.call(t,n)&&Jj(e,n,t[n]);if(mT)for(var n of mT(t))ote.call(t,n)&&Jj(e,n,t[n]);return e},bNe=(e,t)=>yNe(e,vNe(t)),wNe=(e,t)=>{var n={};for(var r in e)ste.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&mT)for(var r of mT(e))t.indexOf(r)<0&&ote.call(e,r)&&(n[r]=e[r]);return n};function J$(e){var t=e,{filled:n,size:r,color:i,classNames:s,styles:o,radius:a,children:u,offset:l,onMouseLeave:c,onMouseEnter:f,disabled:d,marksOffset:h,unstyled:p,inverted:m}=t,y=wNe(t,["filled","size","color","classNames","styles","radius","children","offset","onMouseLeave","onMouseEnter","disabled","marksOffset","unstyled","inverted"]);const{classes:g}=mNe({color:i,size:r,radius:a,disabled:d,inverted:m},{classNames:s,styles:o,unstyled:p,name:"Slider"});return N.createElement("div",{className:g.track,onMouseLeave:c,onMouseEnter:f},N.createElement(it,{className:g.bar,sx:v=>({left:`calc(${l}% - ${v.fn.size({size:r,sizes:Vs})}px)`,width:`calc(${n}% + ${v.fn.size({size:r,sizes:Vs})}px)`})}),u,N.createElement(ite,bNe(_Ne({},y),{size:r,color:i,offset:h,classNames:s,styles:o,disabled:d,unstyled:p,inverted:m})))}J$.displayName="@mantine/core/SliderTrack";var ENe=Object.defineProperty,SNe=Object.defineProperties,TNe=Object.getOwnPropertyDescriptors,gT=Object.getOwnPropertySymbols,ate=Object.prototype.hasOwnProperty,ute=Object.prototype.propertyIsEnumerable,Zj=(e,t,n)=>t in e?ENe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,INe=(e,t)=>{for(var n in t||(t={}))ate.call(t,n)&&Zj(e,n,t[n]);if(gT)for(var n of gT(t))ute.call(t,n)&&Zj(e,n,t[n]);return e},xNe=(e,t)=>SNe(e,TNe(t)),CNe=(e,t)=>{var n={};for(var r in e)ate.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&gT)for(var r of gT(e))t.indexOf(r)<0&&ute.call(e,r)&&(n[r]=e[r]);return n};const Z$=w.forwardRef((e,t)=>{var n=e,{className:r,size:i,classNames:s,styles:o,disabled:a,unstyled:u}=n,l=CNe(n,["className","size","classNames","styles","disabled","unstyled"]);const{classes:c,cx:f}=iNe({size:i,disabled:a},{classNames:s,styles:o,unstyled:u,name:"Slider"});return N.createElement(it,xNe(INe({},l),{tabIndex:-1,className:f(c.root,r),ref:t}))});Z$.displayName="@mantine/core/SliderRoot";var ANe=Object.defineProperty,PNe=Object.defineProperties,ONe=Object.getOwnPropertyDescriptors,yT=Object.getOwnPropertySymbols,lte=Object.prototype.hasOwnProperty,cte=Object.prototype.propertyIsEnumerable,eU=(e,t,n)=>t in e?ANe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,RNe=(e,t)=>{for(var n in t||(t={}))lte.call(t,n)&&eU(e,n,t[n]);if(yT)for(var n of yT(t))cte.call(t,n)&&eU(e,n,t[n]);return e},NNe=(e,t)=>PNe(e,ONe(t)),kNe=(e,t)=>{var n={};for(var r in e)lte.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&yT)for(var r of yT(e))t.indexOf(r)<0&&cte.call(e,r)&&(n[r]=e[r]);return n};const DNe={size:"md",radius:"xl",min:0,max:100,step:1,marks:[],label:e=>e,labelTransition:"skew-down",labelTransitionDuration:0,labelAlwaysOn:!1,thumbLabel:"",showLabelOnHover:!0,disabled:!1,scale:e=>e},fte=w.forwardRef((e,t)=>{const n=Ve("Slider",DNe,e),{classNames:r,styles:i,color:s,value:o,onChange:a,onChangeEnd:u,size:l,radius:c,min:f,max:d,step:h,precision:p,defaultValue:m,name:y,marks:g,label:v,labelTransition:b,labelTransitionDuration:S,labelTransitionTimingFunction:T,labelAlwaysOn:E,thumbLabel:I,showLabelOnHover:A,thumbChildren:R,disabled:F,unstyled:L,thumbSize:B,scale:J,inverted:V}=n,re=kNe(n,["classNames","styles","color","value","onChange","onChangeEnd","size","radius","min","max","step","precision","defaultValue","name","marks","label","labelTransition","labelTransitionDuration","labelTransitionTimingFunction","labelAlwaysOn","thumbLabel","showLabelOnHover","thumbChildren","disabled","unstyled","thumbSize","scale","inverted"]),oe=ji(),[ae,ee]=w.useState(!1),[ue,P]=oa({value:typeof o=="number"?ff(o,f,d):o,defaultValue:typeof m=="number"?ff(m,f,d):m,finalValue:ff(0,f,d),onChange:a}),W=w.useRef(ue),Q=w.useRef(),x=hT({value:ue,min:f,max:d}),O=J(ue),$=typeof v=="function"?v(O):v,q=w.useCallback(({x:Ee})=>{if(!F){const ge=ZR({value:Ee,min:f,max:d,step:h,precision:p});P(ge),W.current=ge}},[F,f,d,h,p]),{ref:ce,active:fe}=zK(q,{onScrubEnd:()=>u==null?void 0:u(W.current)},oe.dir),de=Ee=>{Ee.stopPropagation()},ve=Ee=>{if(!F)switch(Ee.key){case"ArrowUp":{Ee.preventDefault(),Q.current.focus();const ge=Math.min(Math.max(ue+h,f),d);u==null||u(ge),P(ge);break}case"ArrowRight":{Ee.preventDefault(),Q.current.focus();const ge=Math.min(Math.max(oe.dir==="rtl"?ue-h:ue+h,f),d);u==null||u(ge),P(ge);break}case"ArrowDown":{Ee.preventDefault(),Q.current.focus();const ge=Math.min(Math.max(ue-h,f),d);u==null||u(ge),P(ge);break}case"ArrowLeft":{Ee.preventDefault(),Q.current.focus();const ge=Math.min(Math.max(oe.dir==="rtl"?ue+h:ue-h,f),d);u==null||u(ge),P(ge);break}case"Home":{Ee.preventDefault(),Q.current.focus(),u==null||u(f),P(f);break}case"End":{Ee.preventDefault(),Q.current.focus(),u==null||u(d),P(d);break}}};return N.createElement(Z$,NNe(RNe({},re),{size:l,ref:fa(ce,t),onKeyDownCapture:ve,onMouseDownCapture:()=>{var Ee;return(Ee=ce.current)==null?void 0:Ee.focus()},classNames:r,styles:i,disabled:F,unstyled:L}),N.createElement(J$,{inverted:V,offset:0,filled:x,marks:g,size:l,radius:c,color:s,min:f,max:d,value:O,onChange:P,onMouseEnter:A?()=>ee(!0):void 0,onMouseLeave:A?()=>ee(!1):void 0,classNames:r,styles:i,disabled:F,unstyled:L},N.createElement(pT,{max:d,min:f,value:O,position:x,dragging:fe,color:s,size:l,label:$,ref:Q,onMouseDown:de,labelTransition:b,labelTransitionDuration:S,labelTransitionTimingFunction:T,labelAlwaysOn:E,classNames:r,styles:i,thumbLabel:I,showLabelOnHover:A&&ae,disabled:F,unstyled:L,thumbSize:B},R)),N.createElement("input",{type:"hidden",name:y,value:O}))});fte.displayName="@mantine/core/Slider";function $Ne(e){return"TouchEvent"in window&&e instanceof window.TouchEvent?e.touches[0].clientX:e.clientX}var LNe=Object.defineProperty,MNe=Object.defineProperties,FNe=Object.getOwnPropertyDescriptors,vT=Object.getOwnPropertySymbols,dte=Object.prototype.hasOwnProperty,hte=Object.prototype.propertyIsEnumerable,tU=(e,t,n)=>t in e?LNe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,QP=(e,t)=>{for(var n in t||(t={}))dte.call(t,n)&&tU(e,n,t[n]);if(vT)for(var n of vT(t))hte.call(t,n)&&tU(e,n,t[n]);return e},XP=(e,t)=>MNe(e,FNe(t)),BNe=(e,t)=>{var n={};for(var r in e)dte.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&vT)for(var r of vT(e))t.indexOf(r)<0&&hte.call(e,r)&&(n[r]=e[r]);return n};const jNe={size:"md",radius:"xl",min:0,max:100,minRange:10,step:1,marks:[],label:e=>e,labelTransition:"skew-down",labelTransitionDuration:0,labelAlwaysOn:!1,thumbFromLabel:"",thumbToLabel:"",showLabelOnHover:!0,disabled:!1,scale:e=>e},pte=w.forwardRef((e,t)=>{const n=Ve("RangeSlider",jNe,e),{classNames:r,styles:i,color:s,value:o,onChange:a,onChangeEnd:u,size:l,radius:c,min:f,max:d,minRange:h,maxRange:p,step:m,precision:y,defaultValue:g,name:v,marks:b,label:S,labelTransition:T,labelTransitionDuration:E,labelTransitionTimingFunction:I,labelAlwaysOn:A,thumbFromLabel:R,thumbToLabel:F,showLabelOnHover:L,thumbChildren:B,disabled:J,unstyled:V,thumbSize:re,scale:oe,inverted:ae}=n,ee=BNe(n,["classNames","styles","color","value","onChange","onChangeEnd","size","radius","min","max","minRange","maxRange","step","precision","defaultValue","name","marks","label","labelTransition","labelTransitionDuration","labelTransitionTimingFunction","labelAlwaysOn","thumbFromLabel","thumbToLabel","showLabelOnHover","thumbChildren","disabled","unstyled","thumbSize","scale","inverted"]),ue=ji(),[P,W]=w.useState(-1),[Q,x]=w.useState(!1),[O,$]=oa({value:o,defaultValue:g,finalValue:[f,d],onChange:a}),q=w.useRef(O),ce=w.useRef([]),fe=w.useRef(void 0),de=[hT({value:O[0],min:f,max:d}),hT({value:O[1],min:f,max:d})],ve=He=>{$(He),q.current=He};w.useEffect(()=>{Array.isArray(o)&&(q.current=o)},Array.isArray(o)?[o[0],o[1]]:[null,null]);const Ee=(He,Fe,st)=>{const dt=[...q.current];dt[Fe]=He,Fe===0&&(He>dt[1]-(h-1e-9)&&(dt[1]=Math.min(He+h,d)),He>(d-(h-1e-9)||f)&&(dt[Fe]=q.current[Fe]),dt[1]-He>p&&(dt[1]=He+p)),Fe===1&&(Hep&&(dt[0]=He-p)),ve(dt),st&&(u==null||u(q.current))},ge=He=>{if(!J){const Fe=ZR({value:He,min:f,max:d,step:m,precision:y});Ee(Fe,fe.current,!1)}},{ref:nt,active:Je}=zK(({x:He})=>ge(He),{onScrubEnd:()=>u==null?void 0:u(q.current)},ue.dir);function yt(He,Fe){He.stopPropagation(),fe.current=Fe}const ke=He=>{nt.current.focus();const Fe=nt.current.getBoundingClientRect(),st=$Ne(He.nativeEvent),dt=ZR({value:st-Fe.left,max:d,min:f,step:m,containerWidth:Fe.width}),At=Math.abs(O[0]-dt)>Math.abs(O[1]-dt)?1:0,Kt=ue.dir==="ltr"?At:At===1?0:1;fe.current=Kt},at=()=>P!==1&&P!==0?(W(0),0):P,St=He=>{if(!J)switch(He.key){case"ArrowUp":{He.preventDefault();const Fe=at();ce.current[Fe].focus(),Ee(Math.min(Math.max(q.current[Fe]+m,f),d),Fe,!0);break}case"ArrowRight":{He.preventDefault();const Fe=at();ce.current[Fe].focus(),Ee(Math.min(Math.max(ue.dir==="rtl"?q.current[Fe]-m:q.current[Fe]+m,f),d),Fe,!0);break}case"ArrowDown":{He.preventDefault();const Fe=at();ce.current[Fe].focus(),Ee(Math.min(Math.max(q.current[Fe]-m,f),d),Fe,!0);break}case"ArrowLeft":{He.preventDefault();const Fe=at();ce.current[Fe].focus(),Ee(Math.min(Math.max(ue.dir==="rtl"?q.current[Fe]+m:q.current[Fe]-m,f),d),Fe,!0);break}}},cn={max:d,min:f,color:s,size:l,labelTransition:T,labelTransitionDuration:E,labelTransitionTimingFunction:I,labelAlwaysOn:A,onBlur:()=>W(-1),classNames:r,styles:i},bn=Array.isArray(B);return N.createElement(Z$,XP(QP({},ee),{size:l,ref:fa(nt,t),onTouchStartCapture:ke,onTouchEndCapture:()=>{fe.current=-1},onMouseDownCapture:ke,onMouseUpCapture:()=>{fe.current=-1},onKeyDownCapture:St,styles:i,classNames:r,disabled:J,unstyled:V}),N.createElement(J$,{offset:de[0],marksOffset:O[0],filled:de[1]-de[0],marks:b,inverted:ae,size:l,radius:c,color:s,min:f,max:d,value:O[1],styles:i,classNames:r,onMouseEnter:L?()=>x(!0):void 0,onMouseLeave:L?()=>x(!1):void 0,onChange:He=>{const Fe=Math.abs(O[0]-He)>Math.abs(O[1]-He)?1:0,st=[...O];st[Fe]=He,ve(st)},disabled:J,unstyled:V},N.createElement(pT,XP(QP({},cn),{value:oe(O[0]),position:de[0],dragging:Je,label:typeof S=="function"?S(oe(O[0])):S,ref:He=>{ce.current[0]=He},thumbLabel:R,onMouseDown:He=>yt(He,0),onFocus:()=>W(0),showLabelOnHover:L&&Q,disabled:J,unstyled:V,thumbSize:re}),bn?B[0]:B),N.createElement(pT,XP(QP({},cn),{thumbLabel:F,value:oe(O[1]),position:de[1],dragging:Je,label:typeof S=="function"?S(oe(O[1])):S,ref:He=>{ce.current[1]=He},onMouseDown:He=>yt(He,1),onFocus:()=>W(1),showLabelOnHover:L&&Q,disabled:J,unstyled:V,thumbSize:re}),bn?B[1]:B)),N.createElement("input",{type:"hidden",name:`${v}_from`,value:O[0]}),N.createElement("input",{type:"hidden",name:`${v}_to`,value:O[1]}))});pte.displayName="@mantine/core/RangeSlider";var UNe=Object.defineProperty,_T=Object.getOwnPropertySymbols,mte=Object.prototype.hasOwnProperty,gte=Object.prototype.propertyIsEnumerable,nU=(e,t,n)=>t in e?UNe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,VNe=(e,t)=>{for(var n in t||(t={}))mte.call(t,n)&&nU(e,n,t[n]);if(_T)for(var n of _T(t))gte.call(t,n)&&nU(e,n,t[n]);return e},zNe=(e,t)=>{var n={};for(var r in e)mte.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&_T)for(var r of _T(e))t.indexOf(r)<0&>e.call(e,r)&&(n[r]=e[r]);return n};const HNe={w:0,h:0},bT=w.forwardRef((e,t)=>{const n=Ve("Space",HNe,e),{w:r,h:i}=n,s=zNe(n,["w","h"]);return N.createElement(it,VNe({ref:t,w:r,miw:r,h:i,mih:i},s))});bT.displayName="@mantine/core/Space";var WNe=Object.defineProperty,qNe=Object.defineProperties,GNe=Object.getOwnPropertyDescriptors,rU=Object.getOwnPropertySymbols,YNe=Object.prototype.hasOwnProperty,KNe=Object.prototype.propertyIsEnumerable,iU=(e,t,n)=>t in e?WNe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,QNe=(e,t)=>{for(var n in t||(t={}))YNe.call(t,n)&&iU(e,n,t[n]);if(rU)for(var n of rU(t))KNe.call(t,n)&&iU(e,n,t[n]);return e},XNe=(e,t)=>qNe(e,GNe(t));function JNe(e,t,n){return typeof e<"u"?e in n.headings.sizes?n.headings.sizes[e].fontSize:e:n.headings.sizes[t].fontSize}function ZNe(e,t,n){return typeof e<"u"&&e in n.headings.sizes?n.headings.sizes[e].lineHeight:n.headings.sizes[t].lineHeight}var eke=lt((e,{element:t,weight:n,size:r,inline:i})=>({root:XNe(QNe({},e.fn.fontStyles()),{fontFamily:e.headings.fontFamily,fontWeight:n||e.headings.sizes[t].fontWeight||e.headings.fontWeight,fontSize:JNe(r,t,e),lineHeight:i?1:ZNe(r,t,e),margin:0})})),tke=Object.defineProperty,wT=Object.getOwnPropertySymbols,yte=Object.prototype.hasOwnProperty,vte=Object.prototype.propertyIsEnumerable,sU=(e,t,n)=>t in e?tke(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,nke=(e,t)=>{for(var n in t||(t={}))yte.call(t,n)&&sU(e,n,t[n]);if(wT)for(var n of wT(t))vte.call(t,n)&&sU(e,n,t[n]);return e},rke=(e,t)=>{var n={};for(var r in e)yte.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&wT)for(var r of wT(e))t.indexOf(r)<0&&vte.call(e,r)&&(n[r]=e[r]);return n};const ike={order:1},$c=w.forwardRef((e,t)=>{const n=Ve("Title",ike,e),{className:r,order:i,children:s,unstyled:o,size:a,weight:u,inline:l}=n,c=rke(n,["className","order","children","unstyled","size","weight","inline"]),{classes:f,cx:d}=eke({element:`h${i}`,weight:u,size:a,inline:l},{name:"Title",unstyled:o});return[1,2,3,4,5,6].includes(i)?N.createElement(rt,nke({component:`h${i}`,ref:t,className:d(f.root,r)},c),s):null});$c.displayName="@mantine/core/Title";var ske=Object.defineProperty,oke=Object.defineProperties,ake=Object.getOwnPropertyDescriptors,oU=Object.getOwnPropertySymbols,uke=Object.prototype.hasOwnProperty,lke=Object.prototype.propertyIsEnumerable,aU=(e,t,n)=>t in e?ske(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,bb=(e,t)=>{for(var n in t||(t={}))uke.call(t,n)&&aU(e,n,t[n]);if(oU)for(var n of oU(t))lke.call(t,n)&&aU(e,n,t[n]);return e},wb=(e,t)=>oke(e,ake(t)),cke=lt(e=>{const t=I0e(e.headings.sizes).reduce((n,r)=>{const i=e.headings.sizes[r];return n[`& ${r}`]=wb(bb({fontFamily:e.headings.fontFamily,fontWeight:i.fontWeight||e.headings.fontWeight,marginTop:typeof i.lineHeight=="number"?`calc(${e.spacing.xl}px * ${i.lineHeight})`:e.spacing.xl,marginBottom:e.spacing.sm},i),{"@media (max-width: 755px)":{fontSize:typeof i.fontSize=="number"&&i.fontSize/1.3}}),n},{});return{root:wb(bb(wb(bb({},e.fn.fontStyles()),{color:e.colorScheme==="dark"?e.colors.dark[0]:e.black,lineHeight:e.lineHeight,fontSize:e.fontSizes.md,"@media (max-width: 755px)":{fontSize:e.fontSizes.sm}}),t),{"& .ql-align-center":{textAlign:"center"},"& .ql-align-right":{textAlign:"right"},"& .ql-align-left":{textAlign:"left"},"& img":{maxWidth:"100%",marginBottom:e.spacing.xs},"& p":{marginTop:0,marginBottom:e.spacing.lg},"& mark":{backgroundColor:e.fn.themeColor("yellow",e.colorScheme==="dark"?5:2),color:e.colorScheme==="dark"?e.colors.dark[9]:"inherit"},"& hr":{marginTop:e.spacing.md,marginBottom:e.spacing.sm,borderBottom:0,borderLeft:0,borderRight:0,borderTop:`1px dashed ${e.colors.gray[e.colorScheme==="dark"?4:6]}`},"& a":wb(bb({},e.fn.focusStyles()),{color:e.colors[e.primaryColor][e.colorScheme==="dark"?4:6],textDecoration:"none","&:hover":{textDecoration:"underline"}}),"& pre":{padding:e.spacing.xs,lineHeight:e.lineHeight,margin:0,marginTop:e.spacing.md,marginBottom:e.spacing.md,overflowX:"auto",fontFamily:e.fontFamilyMonospace,fontSize:e.fontSizes.sm,borderRadius:e.radius.sm,backgroundColor:e.colorScheme==="dark"?e.colors.dark[8]:e.colors.gray[0],"& code":{backgroundColor:"transparent",padding:0,borderRadius:0,color:"inherit",border:0}},"& code":{lineHeight:e.lineHeight,padding:"1px 5px",borderRadius:e.radius.sm,color:e.colorScheme==="dark"?e.colors.dark[0]:e.black,backgroundColor:e.colorScheme==="dark"?e.colors.dark[9]:e.colors.gray[0],fontFamily:e.fontFamilyMonospace,fontSize:e.fontSizes.xs,border:`1px solid ${e.colorScheme==="dark"?e.colors.dark[9]:e.colors.gray[3]}`},"& ul, & ol":{marginBottom:e.spacing.md,paddingLeft:38,"& li":{marginTop:e.spacing.xs}},"& table":{width:"100%",borderCollapse:"collapse",captionSide:"bottom",marginBottom:e.spacing.md,"& caption":{marginTop:e.spacing.xs,fontSize:e.fontSizes.sm,color:e.colorScheme==="dark"?e.colors.dark[2]:e.colors.gray[6]},"& th":{textAlign:"left",fontWeight:"bold",color:e.colorScheme==="dark"?e.colors.dark[0]:e.colors.gray[7],fontSize:14,padding:"7px 10px"},"& thead th":{borderBottom:`1px solid ${e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[3]}`},"& tfoot th":{borderTop:`1px solid ${e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[3]}`},"& td":{padding:"7px 10px",borderBottom:`1px solid ${e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[3]}`,fontSize:14},"& tr:last-of-type td":{borderBottom:"none"}},"& blockquote":{fontSize:e.fontSizes.lg,lineHeight:e.lineHeight,margin:`${e.spacing.md}px 0`,borderTopRightRadius:e.radius.sm,borderBottomRightRadius:e.radius.sm,padding:`${e.spacing.md}px ${e.spacing.lg}px`,color:e.colorScheme==="dark"?e.colors.dark[0]:e.black,borderLeft:`6px solid ${e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[3]}`,"& cite":{display:"block",fontSize:e.fontSizes.sm,marginTop:e.spacing.xs,color:e.colorScheme==="dark"?e.colors.dark[2]:e.colors.gray[6],overflow:"hidden",textOverflow:"ellipsis"}}})}}),fke=Object.defineProperty,ET=Object.getOwnPropertySymbols,_te=Object.prototype.hasOwnProperty,bte=Object.prototype.propertyIsEnumerable,uU=(e,t,n)=>t in e?fke(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,dke=(e,t)=>{for(var n in t||(t={}))_te.call(t,n)&&uU(e,n,t[n]);if(ET)for(var n of ET(t))bte.call(t,n)&&uU(e,n,t[n]);return e},hke=(e,t)=>{var n={};for(var r in e)_te.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&ET)for(var r of ET(e))t.indexOf(r)<0&&bte.call(e,r)&&(n[r]=e[r]);return n};const Y0=w.forwardRef((e,t)=>{const n=Ve("TypographyStylesProvider",{},e),{className:r,unstyled:i}=n,s=hke(n,["className","unstyled"]),{classes:o,cx:a}=cke(null,{name:"TypographyStylesProvider",unstyled:i});return N.createElement(it,dke({className:a(o.root,r),ref:t},s))});Y0.displayName="@mantine/core/TypographyStylesProvider";function eN(e){const t=e.split("/")||[];return t[t.length-1].replace(/\.[^\.]+$/,"").replace(".","_").replace(" ","_").replace("/","_")}const fl="/viz-guardrails-study/";function pke({globalConfig:e,studyConfigs:t}){const{configsList:n}=e,r=Kf();return C.jsxs(rZ,{size:"xs",px:"xs",style:{marginTop:100,marginBottom:100},children:[C.jsx(B_,{maw:150,mx:"auto",mb:"xl",radius:"md",src:`${fl}assets/revisitLogoSquare.svg`,alt:"reVISit"}),C.jsx(rt,{children:"Select an experiment to launch:"}),n.map(i=>{const s=t[i];if(!s)return null;const o=eN(i);return C.jsx(kx,{onClick:()=>{r(`/${o}`)},my:"sm",style:{width:"100%"},children:C.jsxs(vxe,{shadow:"sm",radius:"md",withBorder:!0,children:[C.jsx(rt,{fw:"bold",children:s.studyMetadata.title}),C.jsxs(rt,{c:"dimmed",children:["Authors:",s.studyMetadata.authors]}),C.jsx(rt,{c:"dimmed",children:s.studyMetadata.description}),C.jsx(rt,{c:"dimmed",ta:"right",style:{paddingRight:5}})]})},i)})]})}var wte={exports:{}},Ete={};/** * @license React * use-sync-external-store-shim.production.min.js * @@ -93,7 +93,7 @@ Error generating stack: `+s.message+` * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var qx=w,Ike=Tke;function xke(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var Cke=typeof Object.is=="function"?Object.is:xke,Ake=Ike.useSyncExternalStore,Pke=qx.useRef,Oke=qx.useEffect,Rke=qx.useMemo,Nke=qx.useDebugValue;Tte.useSyncExternalStoreWithSelector=function(e,t,n,r,i){var s=Pke(null);if(s.current===null){var o={hasValue:!1,value:null};s.current=o}else o=s.current;s=Rke(function(){function u(h){if(!l){if(l=!0,c=h,h=r(h),i!==void 0&&o.hasValue){var p=o.value;if(i(p,h))return f=p}return f=h}if(p=f,Cke(c,h))return p;var m=r(h);return i!==void 0&&i(p,m)?p:(c=h,f=m)}var l=!1,c,f,d=n===void 0?null:n;return[function(){return u(t())},d===null?void 0:function(){return u(d())}]},[t,n,r,i]);var a=Ake(e,s[0],s[1]);return Oke(function(){o.hasValue=!0,o.value=a},[a]),Nke(a),a};Ste.exports=Tte;var kke=Ste.exports;function Dke(e){e()}let Ite=Dke;const $ke=e=>Ite=e,Lke=()=>Ite,cU=Symbol.for("react-redux-context"),fU=typeof globalThis<"u"?globalThis:{};function Mke(){var e;if(!w.createContext)return{};const t=(e=fU[cU])!=null?e:fU[cU]=new Map;let n=t.get(w.createContext);return n||(n=w.createContext(null),t.set(w.createContext,n)),n}const Cf=Mke();function t3(e=Cf){return function(){return w.useContext(e)}}const xte=t3(),Fke=()=>{throw new Error("uSES not initialized!")};let Cte=Fke;const Bke=e=>{Cte=e},jke=(e,t)=>e===t;function Uke(e=Cf){const t=e===Cf?xte:t3(e);return function(r,i={}){const{equalityFn:s=jke,stabilityCheck:o=void 0,noopCheck:a=void 0}=typeof i=="function"?{equalityFn:i}:i,{store:u,subscription:l,getServerState:c,stabilityCheck:f,noopCheck:d}=t();w.useRef(!0);const h=w.useCallback({[r.name](m){return r(m)}}[r.name],[r,f,o]),p=Cte(l.addNestedSub,u.getState,c||u.getState,h,s);return w.useDebugValue(p),p}}const Vke=Uke();var Hn={};/** + */var qx=w,Ike=Tke;function xke(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var Cke=typeof Object.is=="function"?Object.is:xke,Ake=Ike.useSyncExternalStore,Pke=qx.useRef,Oke=qx.useEffect,Rke=qx.useMemo,Nke=qx.useDebugValue;Tte.useSyncExternalStoreWithSelector=function(e,t,n,r,i){var s=Pke(null);if(s.current===null){var o={hasValue:!1,value:null};s.current=o}else o=s.current;s=Rke(function(){function u(h){if(!l){if(l=!0,c=h,h=r(h),i!==void 0&&o.hasValue){var p=o.value;if(i(p,h))return f=p}return f=h}if(p=f,Cke(c,h))return p;var m=r(h);return i!==void 0&&i(p,m)?p:(c=h,f=m)}var l=!1,c,f,d=n===void 0?null:n;return[function(){return u(t())},d===null?void 0:function(){return u(d())}]},[t,n,r,i]);var a=Ake(e,s[0],s[1]);return Oke(function(){o.hasValue=!0,o.value=a},[a]),Nke(a),a};Ste.exports=Tte;var kke=Ste.exports;function Dke(e){e()}let Ite=Dke;const $ke=e=>Ite=e,Lke=()=>Ite,lU=Symbol.for("react-redux-context"),cU=typeof globalThis<"u"?globalThis:{};function Mke(){var e;if(!w.createContext)return{};const t=(e=cU[lU])!=null?e:cU[lU]=new Map;let n=t.get(w.createContext);return n||(n=w.createContext(null),t.set(w.createContext,n)),n}const Cf=Mke();function e3(e=Cf){return function(){return w.useContext(e)}}const xte=e3(),Fke=()=>{throw new Error("uSES not initialized!")};let Cte=Fke;const Bke=e=>{Cte=e},jke=(e,t)=>e===t;function Uke(e=Cf){const t=e===Cf?xte:e3(e);return function(r,i={}){const{equalityFn:s=jke,stabilityCheck:o=void 0,noopCheck:a=void 0}=typeof i=="function"?{equalityFn:i}:i,{store:u,subscription:l,getServerState:c,stabilityCheck:f,noopCheck:d}=t();w.useRef(!0);const h=w.useCallback({[r.name](m){return r(m)}}[r.name],[r,f,o]),p=Cte(l.addNestedSub,u.getState,c||u.getState,h,s);return w.useDebugValue(p),p}}const Vke=Uke();var Hn={};/** * @license React * react-is.production.min.js * @@ -101,10 +101,10 @@ Error generating stack: `+s.message+` * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var n3=Symbol.for("react.element"),r3=Symbol.for("react.portal"),Gx=Symbol.for("react.fragment"),Yx=Symbol.for("react.strict_mode"),Kx=Symbol.for("react.profiler"),Qx=Symbol.for("react.provider"),Xx=Symbol.for("react.context"),zke=Symbol.for("react.server_context"),Jx=Symbol.for("react.forward_ref"),Zx=Symbol.for("react.suspense"),eC=Symbol.for("react.suspense_list"),tC=Symbol.for("react.memo"),nC=Symbol.for("react.lazy"),Hke=Symbol.for("react.offscreen"),Ate;Ate=Symbol.for("react.module.reference");function ha(e){if(typeof e=="object"&&e!==null){var t=e.$$typeof;switch(t){case n3:switch(e=e.type,e){case Gx:case Kx:case Yx:case Zx:case eC:return e;default:switch(e=e&&e.$$typeof,e){case zke:case Xx:case Jx:case nC:case tC:case Qx:return e;default:return t}}case r3:return t}}}Hn.ContextConsumer=Xx;Hn.ContextProvider=Qx;Hn.Element=n3;Hn.ForwardRef=Jx;Hn.Fragment=Gx;Hn.Lazy=nC;Hn.Memo=tC;Hn.Portal=r3;Hn.Profiler=Kx;Hn.StrictMode=Yx;Hn.Suspense=Zx;Hn.SuspenseList=eC;Hn.isAsyncMode=function(){return!1};Hn.isConcurrentMode=function(){return!1};Hn.isContextConsumer=function(e){return ha(e)===Xx};Hn.isContextProvider=function(e){return ha(e)===Qx};Hn.isElement=function(e){return typeof e=="object"&&e!==null&&e.$$typeof===n3};Hn.isForwardRef=function(e){return ha(e)===Jx};Hn.isFragment=function(e){return ha(e)===Gx};Hn.isLazy=function(e){return ha(e)===nC};Hn.isMemo=function(e){return ha(e)===tC};Hn.isPortal=function(e){return ha(e)===r3};Hn.isProfiler=function(e){return ha(e)===Kx};Hn.isStrictMode=function(e){return ha(e)===Yx};Hn.isSuspense=function(e){return ha(e)===Zx};Hn.isSuspenseList=function(e){return ha(e)===eC};Hn.isValidElementType=function(e){return typeof e=="string"||typeof e=="function"||e===Gx||e===Kx||e===Yx||e===Zx||e===eC||e===Hke||typeof e=="object"&&e!==null&&(e.$$typeof===nC||e.$$typeof===tC||e.$$typeof===Qx||e.$$typeof===Xx||e.$$typeof===Jx||e.$$typeof===Ate||e.getModuleId!==void 0)};Hn.typeOf=ha;function Wke(){const e=Lke();let t=null,n=null;return{clear(){t=null,n=null},notify(){e(()=>{let r=t;for(;r;)r.callback(),r=r.next})},get(){let r=[],i=t;for(;i;)r.push(i),i=i.next;return r},subscribe(r){let i=!0,s=n={callback:r,next:null,prev:n};return s.prev?s.prev.next=s:t=s,function(){!i||t===null||(i=!1,s.next?s.next.prev=s.prev:n=s.prev,s.prev?s.prev.next=s.next:t=s.next)}}}}const dU={notify(){},get:()=>[]};function qke(e,t){let n,r=dU,i=0,s=!1;function o(m){c();const y=r.subscribe(m);let g=!1;return()=>{g||(g=!0,y(),f())}}function a(){r.notify()}function u(){p.onStateChange&&p.onStateChange()}function l(){return s}function c(){i++,n||(n=t?t.addNestedSub(u):e.subscribe(u),r=Wke())}function f(){i--,n&&i===0&&(n(),n=void 0,r.clear(),r=dU)}function d(){s||(s=!0,c())}function h(){s&&(s=!1,f())}const p={addNestedSub:o,notifyNestedSubs:a,handleChangeWrapper:u,isSubscribed:l,trySubscribe:d,tryUnsubscribe:h,getListeners:()=>r};return p}const Gke=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",Yke=Gke?w.useLayoutEffect:w.useEffect;function Kke({store:e,context:t,children:n,serverState:r,stabilityCheck:i="once",noopCheck:s="once"}){const o=w.useMemo(()=>{const l=qke(e);return{store:e,subscription:l,getServerState:r?()=>r:void 0,stabilityCheck:i,noopCheck:s}},[e,r,i,s]),a=w.useMemo(()=>e.getState(),[e]);Yke(()=>{const{subscription:l}=o;return l.onStateChange=l.notifyNestedSubs,l.trySubscribe(),a!==e.getState()&&l.notifyNestedSubs(),()=>{l.tryUnsubscribe(),l.onStateChange=void 0}},[o,a]);const u=t||Cf;return w.createElement(u.Provider,{value:o},n)}function Pte(e=Cf){const t=e===Cf?xte:t3(e);return function(){const{store:r}=t();return r}}const Qke=Pte();function Xke(e=Cf){const t=e===Cf?Qke:Pte(e);return function(){return t().dispatch}}const Ote=Xke();Bke(kke.useSyncExternalStoreWithSelector);$ke(lc.unstable_batchedUpdates);const Jke={},Zke=Object.freeze(Object.defineProperty({__proto__:null,default:Jke},Symbol.toStringTag,{value:"Module"})),eDe=Khe(Zke);var tDe=eDe;function nDe(e,t){var n,r="",i=0,s=!0,o=0,a;function u(){return a=e.charAt(o),o++,a}for(u(),a==="-"&&(r="-",u());a>="0"&&a<="9";)s&&(a=="0"?i++:s=!1),r+=a,u();if(s&&i--,a===".")for(r+=".";u()&&a>="0"&&a<="9";)r+=a;if(a==="e"||a==="E")for(r+=a,u(),(a==="-"||a==="+")&&(r+=a,u());a>="0"&&a<="9";)r+=a,u();for(;a&&a<=" ";)u();if(t&&(a===","||a==="}"||a==="]"||a==="#"||a==="/"&&(e[o]==="/"||e[o]==="*"))&&(a=0),n=+r,!(a||i||!isFinite(n)))return n}function rDe(e,t){return Object.defineProperty&&Object.defineProperty(e,"__COMMENTS__",{enumerable:!1,writable:!0}),e.__COMMENTS__=t||{}}function iDe(e){Object.defineProperty(e,"__COMMENTS__",{value:void 0})}function sDe(e){return e.__COMMENTS__}function oDe(e){if(!e)return"";var t=e.split(` + */var t3=Symbol.for("react.element"),n3=Symbol.for("react.portal"),Gx=Symbol.for("react.fragment"),Yx=Symbol.for("react.strict_mode"),Kx=Symbol.for("react.profiler"),Qx=Symbol.for("react.provider"),Xx=Symbol.for("react.context"),zke=Symbol.for("react.server_context"),Jx=Symbol.for("react.forward_ref"),Zx=Symbol.for("react.suspense"),eC=Symbol.for("react.suspense_list"),tC=Symbol.for("react.memo"),nC=Symbol.for("react.lazy"),Hke=Symbol.for("react.offscreen"),Ate;Ate=Symbol.for("react.module.reference");function ha(e){if(typeof e=="object"&&e!==null){var t=e.$$typeof;switch(t){case t3:switch(e=e.type,e){case Gx:case Kx:case Yx:case Zx:case eC:return e;default:switch(e=e&&e.$$typeof,e){case zke:case Xx:case Jx:case nC:case tC:case Qx:return e;default:return t}}case n3:return t}}}Hn.ContextConsumer=Xx;Hn.ContextProvider=Qx;Hn.Element=t3;Hn.ForwardRef=Jx;Hn.Fragment=Gx;Hn.Lazy=nC;Hn.Memo=tC;Hn.Portal=n3;Hn.Profiler=Kx;Hn.StrictMode=Yx;Hn.Suspense=Zx;Hn.SuspenseList=eC;Hn.isAsyncMode=function(){return!1};Hn.isConcurrentMode=function(){return!1};Hn.isContextConsumer=function(e){return ha(e)===Xx};Hn.isContextProvider=function(e){return ha(e)===Qx};Hn.isElement=function(e){return typeof e=="object"&&e!==null&&e.$$typeof===t3};Hn.isForwardRef=function(e){return ha(e)===Jx};Hn.isFragment=function(e){return ha(e)===Gx};Hn.isLazy=function(e){return ha(e)===nC};Hn.isMemo=function(e){return ha(e)===tC};Hn.isPortal=function(e){return ha(e)===n3};Hn.isProfiler=function(e){return ha(e)===Kx};Hn.isStrictMode=function(e){return ha(e)===Yx};Hn.isSuspense=function(e){return ha(e)===Zx};Hn.isSuspenseList=function(e){return ha(e)===eC};Hn.isValidElementType=function(e){return typeof e=="string"||typeof e=="function"||e===Gx||e===Kx||e===Yx||e===Zx||e===eC||e===Hke||typeof e=="object"&&e!==null&&(e.$$typeof===nC||e.$$typeof===tC||e.$$typeof===Qx||e.$$typeof===Xx||e.$$typeof===Jx||e.$$typeof===Ate||e.getModuleId!==void 0)};Hn.typeOf=ha;function Wke(){const e=Lke();let t=null,n=null;return{clear(){t=null,n=null},notify(){e(()=>{let r=t;for(;r;)r.callback(),r=r.next})},get(){let r=[],i=t;for(;i;)r.push(i),i=i.next;return r},subscribe(r){let i=!0,s=n={callback:r,next:null,prev:n};return s.prev?s.prev.next=s:t=s,function(){!i||t===null||(i=!1,s.next?s.next.prev=s.prev:n=s.prev,s.prev?s.prev.next=s.next:t=s.next)}}}}const fU={notify(){},get:()=>[]};function qke(e,t){let n,r=fU,i=0,s=!1;function o(m){c();const y=r.subscribe(m);let g=!1;return()=>{g||(g=!0,y(),f())}}function a(){r.notify()}function u(){p.onStateChange&&p.onStateChange()}function l(){return s}function c(){i++,n||(n=t?t.addNestedSub(u):e.subscribe(u),r=Wke())}function f(){i--,n&&i===0&&(n(),n=void 0,r.clear(),r=fU)}function d(){s||(s=!0,c())}function h(){s&&(s=!1,f())}const p={addNestedSub:o,notifyNestedSubs:a,handleChangeWrapper:u,isSubscribed:l,trySubscribe:d,tryUnsubscribe:h,getListeners:()=>r};return p}const Gke=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",Yke=Gke?w.useLayoutEffect:w.useEffect;function Kke({store:e,context:t,children:n,serverState:r,stabilityCheck:i="once",noopCheck:s="once"}){const o=w.useMemo(()=>{const l=qke(e);return{store:e,subscription:l,getServerState:r?()=>r:void 0,stabilityCheck:i,noopCheck:s}},[e,r,i,s]),a=w.useMemo(()=>e.getState(),[e]);Yke(()=>{const{subscription:l}=o;return l.onStateChange=l.notifyNestedSubs,l.trySubscribe(),a!==e.getState()&&l.notifyNestedSubs(),()=>{l.tryUnsubscribe(),l.onStateChange=void 0}},[o,a]);const u=t||Cf;return w.createElement(u.Provider,{value:o},n)}function Pte(e=Cf){const t=e===Cf?xte:e3(e);return function(){const{store:r}=t();return r}}const Qke=Pte();function Xke(e=Cf){const t=e===Cf?Qke:Pte(e);return function(){return t().dispatch}}const Ote=Xke();Bke(kke.useSyncExternalStoreWithSelector);$ke(lc.unstable_batchedUpdates);const Jke={},Zke=Object.freeze(Object.defineProperty({__proto__:null,default:Jke},Symbol.toStringTag,{value:"Module"})),eDe=Khe(Zke);var tDe=eDe;function nDe(e,t){var n,r="",i=0,s=!0,o=0,a;function u(){return a=e.charAt(o),o++,a}for(u(),a==="-"&&(r="-",u());a>="0"&&a<="9";)s&&(a=="0"?i++:s=!1),r+=a,u();if(s&&i--,a===".")for(r+=".";u()&&a>="0"&&a<="9";)r+=a;if(a==="e"||a==="E")for(r+=a,u(),(a==="-"||a==="+")&&(r+=a,u());a>="0"&&a<="9";)r+=a,u();for(;a&&a<=" ";)u();if(t&&(a===","||a==="}"||a==="]"||a==="#"||a==="/"&&(e[o]==="/"||e[o]==="*"))&&(a=0),n=+r,!(a||i||!isFinite(n)))return n}function rDe(e,t){return Object.defineProperty&&Object.defineProperty(e,"__COMMENTS__",{enumerable:!1,writable:!0}),e.__COMMENTS__=t||{}}function iDe(e){Object.defineProperty(e,"__COMMENTS__",{value:void 0})}function sDe(e){return e.__COMMENTS__}function oDe(e){if(!e)return"";var t=e.split(` `),n,r,i,s;for(i=0;i" "){t[i]="# "+n;break}}return t.join(` `)}var rC={EOL:tDe.EOL||` -`,tryParseNumber:nDe,createComment:rDe,removeComment:iDe,getComment:sDe,forceComment:oDe},aDe="3.2.1";function uDe(e,t){if(Object.prototype.toString.apply(e)!=="[object Array]"){if(e)throw new Error("dsf option must contain an array!");return hU}else if(e.length===0)return hU;var n=[];function r(i){return{}.toString.call(i)==="[object Function]"}return e.forEach(function(i){if(!i.name||!r(i.parse)||!r(i.stringify))throw new Error("extension does not match the DSF interface");n.push(function(){try{if(t=="parse")return i.parse.apply(null,arguments);if(t=="stringify"){var s=i.stringify.apply(null,arguments);if(s!==void 0&&(typeof s!="string"||s.length===0||s[0]==='"'||[].some.call(s,function(o){return cDe(o)})))throw new Error("value may not be empty, start with a quote or contain a punctuator character except colon: "+s);return s}else throw new Error("Invalid type")}catch(o){throw new Error("DSF-"+i.name+" failed; "+o.message)}})}),lDe.bind(null,n)}function lDe(e,t){if(e)for(var n=0;n0&&i[re]!==` `;re--,oe++);for(;re>0;re--)i[re]===` `&&ae++;throw new Error(V+" at line "+ae+","+oe+" >>>"+i.substr(s-oe,20)+" ...")}function h(){return o=i.charAt(s),s++,o}function p(V){return i.charAt(s+V)}function m(V){for(var re="",oe=o;h();){if(o===oe)return h(),V&&oe==="'"&&o==="'"&&re.length===0?(h(),y()):re;if(o==="\\")if(h(),o==="u"){for(var ae=0,ee=0;ee<4;ee++){h();var ue=o.charCodeAt(0),P;o>="0"&&o<="9"?P=ue-48:o>="a"&&o<="f"?P=ue-97+10:o>="A"&&o<="F"?P=ue-65+10:d("Bad \\u char "+o),ae=ae*16+P}re+=String.fromCharCode(ae)}else if(typeof a[o]=="string")re+=a[o];else break;else o===` @@ -126,7 +126,7 @@ Error generating stack: `+s.message+` `)),o==="]")return h(),re&&(re.e=[ae]),V;for(;o;){if(V.push(A()),oe=s,v(),o===","&&(h(),oe=s,v()),re){var ee=S(oe);re.a.push([ae||"",ee[0]||""]),ae=ee[1]}if(o==="]")return h(),re&&(re.a[re.a.length-1][1]+=ae||""),V;v()}d("End of input while parsing an array (missing ']')")}catch(ue){throw ue.hint=ue.hint||T(V),ue}}function I(V){var re="",oe={},ae,ee,ue;try{if(u&&(ae=n.createComment(oe,{c:{},o:[]})),V?ee=1:(h(),ee=s),v(),ae&&(ue=S(ee,!0).join(` `)),o==="}"&&!V)return ae&&(ae.e=[ue]),h(),oe;for(;o;){if(re=g(),v(),o!==":"&&d("Expected ':' instead of '"+o+"'"),h(),oe[re]=A(),ee=s,v(),o===","&&(h(),ee=s,v()),ae){var P=S(ee);ae.c[re]=[ue||"",P[0]||""],ue=P[1],ae.o.push(re)}if(o==="}"&&!V)return h(),ae&&(ae.c[re][1]+=ue||""),oe;v()}if(V)return oe;d("End of input while parsing an object (missing '}')")}catch(W){throw W.hint=W.hint||T(oe),W}}function A(){switch(v(),o){case"{":return I();case"[":return E();case"'":case'"':return m(!0);default:return b()}}function R(V,re){var oe=s;if(v(),o&&d("Syntax error, found trailing characters"),u){var ae=re.join(` `),ee=S(oe).join(` -`);if(ee||ae){var ue=n.createComment(V,n.getComment(V));ue.r=[ae,ee]}}return V}function F(){v();var V=u?S(1):null;switch(o){case"{":return R(I(),V);case"[":return R(E(),V);default:return R(A(),V)}}function L(){v();var V=u?S(1):null;switch(o){case"{":return R(I(),V);case"[":return R(E(),V)}try{return R(I(!0),V)}catch(re){c();try{return R(A(),V)}catch{throw re}}}if(typeof e!="string")throw new Error("source is not a string");var B=null,J=!0;return t&&typeof t=="object"&&(u=t.keepWsc,B=t.dsf,J=t.legacyRoot!==!1),l=r.loadDsf(B,"parse"),i=e,c(),J?L():F()},dDe=function(e,t){var n=rC,r=i3,i={obj:["{","}"],arr:["[","]"],key:["",""],qkey:['"','"'],col:[":",""],com:[",",""],str:["",""],qstr:['"','"'],mstr:["'''","'''"],num:["",""],lit:["",""],dsf:["",""],esc:["\\",""],uni:["\\u",""],rem:["",""]},s=n.EOL,o=" ",a=!1,u=!1,l=!1,c=!1,f=0,d=1,h="",p=null,m=!1,y=i;if(t&&typeof t=="object"){t.quotes=t.quotes==="always"?"strings":t.quotes,(t.eol===` +`);if(ee||ae){var ue=n.createComment(V,n.getComment(V));ue.r=[ae,ee]}}return V}function F(){v();var V=u?S(1):null;switch(o){case"{":return R(I(),V);case"[":return R(E(),V);default:return R(A(),V)}}function L(){v();var V=u?S(1):null;switch(o){case"{":return R(I(),V);case"[":return R(E(),V)}try{return R(I(!0),V)}catch(re){c();try{return R(A(),V)}catch{throw re}}}if(typeof e!="string")throw new Error("source is not a string");var B=null,J=!0;return t&&typeof t=="object"&&(u=t.keepWsc,B=t.dsf,J=t.legacyRoot!==!1),l=r.loadDsf(B,"parse"),i=e,c(),J?L():F()},dDe=function(e,t){var n=rC,r=r3,i={obj:["{","}"],arr:["[","]"],key:["",""],qkey:['"','"'],col:[":",""],com:[",",""],str:["",""],qstr:['"','"'],mstr:["'''","'''"],num:["",""],lit:["",""],dsf:["",""],esc:["\\",""],uni:["\\u",""],rem:["",""]},s=n.EOL,o=" ",a=!1,u=!1,l=!1,c=!1,f=0,d=1,h="",p=null,m=!1,y=i;if(t&&typeof t=="object"){t.quotes=t.quotes==="always"?"strings":t.quotes,(t.eol===` `||t.eol===`\r `)&&(s=t.eol),a=t.keepWsc,f=t.condense||0,u=t.bracesSameLine,l=t.quotes==="all"||t.quotes==="keys",c=t.quotes==="all"||t.quotes==="strings"||t.separator===!0,c||t.multiline=="off"?d=0:d=t.multiline=="no-tabs"?2:1,h=t.separator===!0?y.com[0]:"",p=t.dsf,m=t.sortProps,typeof t.space=="number"?o=new Array(t.space+1).join(" "):typeof t.space=="string"&&(o=t.space),t.colors===!0&&(y={obj:["\x1B[37m{\x1B[0m","\x1B[37m}\x1B[0m"],arr:["\x1B[37m[\x1B[0m","\x1B[37m]\x1B[0m"],key:["\x1B[33m","\x1B[0m"],qkey:['\x1B[33m"','"\x1B[0m'],col:["\x1B[37m:\x1B[0m",""],com:["\x1B[37m,\x1B[0m",""],str:["\x1B[37;1m","\x1B[0m"],qstr:['\x1B[37;1m"','"\x1B[0m'],mstr:["\x1B[37;1m'''","'''\x1B[0m"],num:["\x1B[36;1m","\x1B[0m"],lit:["\x1B[36m","\x1B[0m"],dsf:["\x1B[37m","\x1B[0m"],esc:["\x1B[31m\\","\x1B[0m"],uni:["\x1B[31m\\u","\x1B[0m"],rem:["\x1B[35m","\x1B[0m"]});var g,v=Object.keys(i);for(g=v.length-1;g>=0;g--){var b=v[g];y[b].push(i[b][0].length,i[b][1].length)}}var S,T="-Ÿ­؀-؄܏឴឵‌-‏\u2028- ⁠-\uFEFF￰-￿",E=new RegExp('[\\\\\\"\0-'+T+"]","g"),I=new RegExp(`^\\s|^"|^'|^#|^\\/\\*|^\\/\\/|^\\{|^\\}|^\\[|^\\]|^:|^,|\\s$|[\0-`+T+"]","g"),A=new RegExp("'''|^[\\s]+$|[\0-"+(d===2?" ":"\b")+"\v\f-"+T+"]","g"),R=new RegExp("^(true|false|null)\\s*((,|\\]|\\}|#|//|/\\*).*)?$"),F={"\b":"b"," ":"t","\n":"n","\f":"f","\r":"r",'"':'"',"\\":"\\"},L=/[,\{\[\}\]\s:#"']|\/\/|\/\*/,B="",J=0;function V(Q,x){return J+=Q[0].length+Q[1].length-Q[2]-Q[3],Q[0]+x+Q[1]}function re(Q){return Q.replace(E,function(x){var O=F[x];return typeof O=="string"?V(y.esc,O):V(y.uni,("0000"+x.charCodeAt(0).toString(16)).slice(-4))})}function oe(Q,x,O,$){return Q?(I.lastIndex=0,R.lastIndex=0,c||O||I.test(Q)||n.tryParseNumber(Q,!0)!==void 0||R.test(Q)?(E.lastIndex=0,A.lastIndex=0,E.test(Q)?!A.test(Q)&&!$&&d?ae(Q,x):V(y.qstr,re(Q)):V(y.qstr,Q)):V(y.str,Q)):V(y.qstr,"")}function ae(Q,x){var O,$=Q.replace(/\r/g,"").split(` `);if(x+=o,$.length===1)return V(y.mstr,$[0]);var q=s+x+y.mstr[0];for(O=0;O<$.length;O++)q+=s,$[O]&&(q+=x+$[O]);return q+s+x+y.mstr[1]}function ee(Q){return Q?l||L.test(Q)?(E.lastIndex=0,V(y.qkey,E.test(Q)?re(Q):Q)):V(y.key,Q):'""'}function ue(Q,x,O,$){function q(ot){return ot&&ot[ot[0]==="\r"?1:0]===` @@ -137,11 +137,11 @@ Error generating stack: `+s.message+` `)+Je),St&&(Se[0]||Se[1]||Le)&&(St=null)):ke.push(Je),J=0,Kt=Q[At],me=ue(Kt,ve&&Le),ke.push(ee(At)+y.col[0]+(q(me)?"":" ")+me+(at?h:"")),ve&&Se[1]&&ke.push(fe(Se[1],Le?" ":` `,Le)),St){switch(typeof Kt){case"string":J=0,c=!0,d=0,me=ue(Kt,!1),c=cn,d=bn,St.push(ee(At)+y.col[0]+" "+me+(at?y.com[0]:""));break;case"object":if(Kt){St=null;break}default:St.push(ke[ke.length-1]+(at?He:""));break}J+=y.col[0].length-y.col[2],at&&(J+=y.com[0].length-y.com[2]),Fe+=J}dt===0?ve&&ve.e&&ke.push(fe(ve.e[0],` `)+nt):ke.push(nt),ke.length===0?Ke=V(y.obj,""):(Ke=yt+V(y.obj,ke.join("")),St&&(ct=St.join(" "),ct.length-Fe<=f&&(Ke=V(y.obj,ct))))}return B=ge,Ke}}S=r.loadDsf(p,"stringify");var P="",W=a?W=(n.getComment(e)||{}).r:null;return W&&W[0]&&(P=W[0]+` -`),P+=ue(e,null,!0,!0),W&&(P+=W[1]||""),P},tm=rC;function by(e,t,n){var r;return e&&(r={b:e}),t&&((r=r||{}).a=t),n&&((r=r||{}).x=n),r}function nN(e,t){if(!(e===null||typeof e!="object")){var n=tm.getComment(e);n&&tm.removeComment(e);var r,i,s,o;if(Object.prototype.toString.apply(e)==="[object Array]"){for(o={a:{}},r=0,i=e.length;r0){var r=ST(t,null,1);r+=` +`),P+=ue(e,null,!0,!0),W&&(P+=W[1]||""),P},tm=rC;function by(e,t,n){var r;return e&&(r={b:e}),t&&((r=r||{}).a=t),n&&((r=r||{}).x=n),r}function tN(e,t){if(!(e===null||typeof e!="object")){var n=tm.getComment(e);n&&tm.removeComment(e);var r,i,s,o;if(Object.prototype.toString.apply(e)==="[object Array]"){for(o={a:{}},r=0,i=e.length;r0){var r=ST(t,null,1);r+=` # Orphaned comments: `,n.forEach(function(i){r+=("# "+i.path.join("/")+": "+hDe(i.b,i.a,i.e)).replace(` `,"\\n ")+` -`}),ST(t,r,1)}}function pU(e,t,n,r){var i=by(n?n[0]:void 0,n?n[1]:void 0,r);return i&&(e[t]=i),i}function wy(e,t){var n=by(t.b,t.a);return n.path=e,n}function Ey(e,t,n){if(e){var r,i;if(e.a)for(r=0,i=e.a.length;r1)return!1;const v=this._items[0];return v===""||v==='""'}get str(){var v;return(v=this._str)!==null&&v!==void 0?v:this._str=this._items.reduce((b,S)=>`${b}${S}`,"")}get names(){var v;return(v=this._names)!==null&&v!==void 0?v:this._names=this._items.reduce((b,S)=>(S instanceof n&&(b[S.str]=(b[S.str]||0)+1),b),{})}}e._Code=r,e.nil=new r("");function i(g,...v){const b=[g[0]];let S=0;for(;S{if(f.scopePath===void 0)throw new Error(`CodeGen: name "${f}" has no value`);return(0,t._)`${l}${f.scopePath}`})}scopeCode(l=this._values,c,f){return this._reduceValues(l,d=>{if(d.value===void 0)throw new Error(`CodeGen: name "${d}" has no value`);return d.value.code},c,f)}_reduceValues(l,c,f={},d){let h=t.nil;for(const p in l){const m=l[p];if(!m)continue;const y=f[p]=f[p]||new Map;m.forEach(g=>{if(y.has(g))return;y.set(g,r.Started);let v=c(g);if(v){const b=this.opts.es5?e.varKinds.var:e.varKinds.const;h=(0,t._)`${h}${b} ${g} = ${v};${this.opts._n}`}else if(v=d==null?void 0:d(g))h=(0,t._)`${h}${v}${this.opts._n}`;else throw new n(g);y.set(g,r.Completed)})}return h}}e.ValueScope=a})(sN);(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.or=e.and=e.not=e.CodeGen=e.operators=e.varKinds=e.ValueScopeName=e.ValueScope=e.Scope=e.Name=e.regexpCode=e.stringify=e.getProperty=e.nil=e.strConcat=e.str=e._=void 0;const t=Sv,n=sN;var r=Sv;Object.defineProperty(e,"_",{enumerable:!0,get:function(){return r._}}),Object.defineProperty(e,"str",{enumerable:!0,get:function(){return r.str}}),Object.defineProperty(e,"strConcat",{enumerable:!0,get:function(){return r.strConcat}}),Object.defineProperty(e,"nil",{enumerable:!0,get:function(){return r.nil}}),Object.defineProperty(e,"getProperty",{enumerable:!0,get:function(){return r.getProperty}}),Object.defineProperty(e,"stringify",{enumerable:!0,get:function(){return r.stringify}}),Object.defineProperty(e,"regexpCode",{enumerable:!0,get:function(){return r.regexpCode}}),Object.defineProperty(e,"Name",{enumerable:!0,get:function(){return r.Name}});var i=sN;Object.defineProperty(e,"Scope",{enumerable:!0,get:function(){return i.Scope}}),Object.defineProperty(e,"ValueScope",{enumerable:!0,get:function(){return i.ValueScope}}),Object.defineProperty(e,"ValueScopeName",{enumerable:!0,get:function(){return i.ValueScopeName}}),Object.defineProperty(e,"varKinds",{enumerable:!0,get:function(){return i.varKinds}}),e.operators={GT:new t._Code(">"),GTE:new t._Code(">="),LT:new t._Code("<"),LTE:new t._Code("<="),EQ:new t._Code("==="),NEQ:new t._Code("!=="),NOT:new t._Code("!"),OR:new t._Code("||"),AND:new t._Code("&&"),ADD:new t._Code("+")};class s{optimizeNodes(){return this}optimizeNames(O,$){return this}}class o extends s{constructor(O,$,q){super(),this.varKind=O,this.name=$,this.rhs=q}render({es5:O,_n:$}){const q=O?n.varKinds.var:this.varKind,ce=this.rhs===void 0?"":` = ${this.rhs}`;return`${q} ${this.name}${ce};`+$}optimizeNames(O,$){if(O[this.name.str])return this.rhs&&(this.rhs=V(this.rhs,O,$)),this}get names(){return this.rhs instanceof t._CodeOrName?this.rhs.names:{}}}class a extends s{constructor(O,$,q){super(),this.lhs=O,this.rhs=$,this.sideEffects=q}render({_n:O}){return`${this.lhs} = ${this.rhs};`+O}optimizeNames(O,$){if(!(this.lhs instanceof t.Name&&!O[this.lhs.str]&&!this.sideEffects))return this.rhs=V(this.rhs,O,$),this}get names(){const O=this.lhs instanceof t.Name?{}:{...this.lhs.names};return J(O,this.rhs)}}class u extends a{constructor(O,$,q,ce){super(O,q,ce),this.op=$}render({_n:O}){return`${this.lhs} ${this.op}= ${this.rhs};`+O}}class l extends s{constructor(O){super(),this.label=O,this.names={}}render({_n:O}){return`${this.label}:`+O}}class c extends s{constructor(O){super(),this.label=O,this.names={}}render({_n:O}){return`break${this.label?` ${this.label}`:""};`+O}}class f extends s{constructor(O){super(),this.error=O}render({_n:O}){return`throw ${this.error};`+O}get names(){return this.error.names}}class d extends s{constructor(O){super(),this.code=O}render({_n:O}){return`${this.code};`+O}optimizeNodes(){return`${this.code}`?this:void 0}optimizeNames(O,$){return this.code=V(this.code,O,$),this}get names(){return this.code instanceof t._CodeOrName?this.code.names:{}}}class h extends s{constructor(O=[]){super(),this.nodes=O}render(O){return this.nodes.reduce(($,q)=>$+q.render(O),"")}optimizeNodes(){const{nodes:O}=this;let $=O.length;for(;$--;){const q=O[$].optimizeNodes();Array.isArray(q)?O.splice($,1,...q):q?O[$]=q:O.splice($,1)}return O.length>0?this:void 0}optimizeNames(O,$){const{nodes:q}=this;let ce=q.length;for(;ce--;){const fe=q[ce];fe.optimizeNames(O,$)||(re(O,fe.names),q.splice(ce,1))}return q.length>0?this:void 0}get names(){return this.nodes.reduce((O,$)=>B(O,$.names),{})}}class p extends h{render(O){return"{"+O._n+super.render(O)+"}"+O._n}}class m extends h{}class y extends p{}y.kind="else";class g extends p{constructor(O,$){super($),this.condition=O}render(O){let $=`if(${this.condition})`+super.render(O);return this.else&&($+="else "+this.else.render(O)),$}optimizeNodes(){super.optimizeNodes();const O=this.condition;if(O===!0)return this.nodes;let $=this.else;if($){const q=$.optimizeNodes();$=this.else=Array.isArray(q)?new y(q):q}if($)return O===!1?$ instanceof g?$:$.nodes:this.nodes.length?this:new g(oe(O),$ instanceof g?[$]:$.nodes);if(!(O===!1||!this.nodes.length))return this}optimizeNames(O,$){var q;if(this.else=(q=this.else)===null||q===void 0?void 0:q.optimizeNames(O,$),!!(super.optimizeNames(O,$)||this.else))return this.condition=V(this.condition,O,$),this}get names(){const O=super.names;return J(O,this.condition),this.else&&B(O,this.else.names),O}}g.kind="if";class v extends p{}v.kind="for";class b extends v{constructor(O){super(),this.iteration=O}render(O){return`for(${this.iteration})`+super.render(O)}optimizeNames(O,$){if(super.optimizeNames(O,$))return this.iteration=V(this.iteration,O,$),this}get names(){return B(super.names,this.iteration.names)}}class S extends v{constructor(O,$,q,ce){super(),this.varKind=O,this.name=$,this.from=q,this.to=ce}render(O){const $=O.es5?n.varKinds.var:this.varKind,{name:q,from:ce,to:fe}=this;return`for(${$} ${q}=${ce}; ${q}<${fe}; ${q}++)`+super.render(O)}get names(){const O=J(super.names,this.from);return J(O,this.to)}}class T extends v{constructor(O,$,q,ce){super(),this.loop=O,this.varKind=$,this.name=q,this.iterable=ce}render(O){return`for(${this.varKind} ${this.name} ${this.loop} ${this.iterable})`+super.render(O)}optimizeNames(O,$){if(super.optimizeNames(O,$))return this.iterable=V(this.iterable,O,$),this}get names(){return B(super.names,this.iterable.names)}}class E extends p{constructor(O,$,q){super(),this.name=O,this.args=$,this.async=q}render(O){return`${this.async?"async ":""}function ${this.name}(${this.args})`+super.render(O)}}E.kind="func";class I extends h{render(O){return"return "+super.render(O)}}I.kind="return";class A extends p{render(O){let $="try"+super.render(O);return this.catch&&($+=this.catch.render(O)),this.finally&&($+=this.finally.render(O)),$}optimizeNodes(){var O,$;return super.optimizeNodes(),(O=this.catch)===null||O===void 0||O.optimizeNodes(),($=this.finally)===null||$===void 0||$.optimizeNodes(),this}optimizeNames(O,$){var q,ce;return super.optimizeNames(O,$),(q=this.catch)===null||q===void 0||q.optimizeNames(O,$),(ce=this.finally)===null||ce===void 0||ce.optimizeNames(O,$),this}get names(){const O=super.names;return this.catch&&B(O,this.catch.names),this.finally&&B(O,this.finally.names),O}}class R extends p{constructor(O){super(),this.error=O}render(O){return`catch(${this.error})`+super.render(O)}}R.kind="catch";class F extends p{render(O){return"finally"+super.render(O)}}F.kind="finally";class L{constructor(O,$={}){this._values={},this._blockStarts=[],this._constants={},this.opts={...$,_n:$.lines?` +`)&&(pU.EOL=e)},version:gDe,rt:{parse:function(e,t){return(t=t||{}).keepWsc=!0,mU(e,t)},stringify:function(e,t){return(t=t||{}).keepWsc=!0,gU(e,t)}},comments:yDe,dsf:vDe.std},rN={exports:{}},Dte={},Va={},Um={},U_={},Xt={},Sv={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.regexpCode=e.getEsmExportName=e.getProperty=e.safeStringify=e.stringify=e.strConcat=e.addCodeArg=e.str=e._=e.nil=e._Code=e.Name=e.IDENTIFIER=e._CodeOrName=void 0;class t{}e._CodeOrName=t,e.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;class n extends t{constructor(v){if(super(),!e.IDENTIFIER.test(v))throw new Error("CodeGen: name must be a valid identifier");this.str=v}toString(){return this.str}emptyStr(){return!1}get names(){return{[this.str]:1}}}e.Name=n;class r extends t{constructor(v){super(),this._items=typeof v=="string"?[v]:v}toString(){return this.str}emptyStr(){if(this._items.length>1)return!1;const v=this._items[0];return v===""||v==='""'}get str(){var v;return(v=this._str)!==null&&v!==void 0?v:this._str=this._items.reduce((b,S)=>`${b}${S}`,"")}get names(){var v;return(v=this._names)!==null&&v!==void 0?v:this._names=this._items.reduce((b,S)=>(S instanceof n&&(b[S.str]=(b[S.str]||0)+1),b),{})}}e._Code=r,e.nil=new r("");function i(g,...v){const b=[g[0]];let S=0;for(;S{if(f.scopePath===void 0)throw new Error(`CodeGen: name "${f}" has no value`);return(0,t._)`${l}${f.scopePath}`})}scopeCode(l=this._values,c,f){return this._reduceValues(l,d=>{if(d.value===void 0)throw new Error(`CodeGen: name "${d}" has no value`);return d.value.code},c,f)}_reduceValues(l,c,f={},d){let h=t.nil;for(const p in l){const m=l[p];if(!m)continue;const y=f[p]=f[p]||new Map;m.forEach(g=>{if(y.has(g))return;y.set(g,r.Started);let v=c(g);if(v){const b=this.opts.es5?e.varKinds.var:e.varKinds.const;h=(0,t._)`${h}${b} ${g} = ${v};${this.opts._n}`}else if(v=d==null?void 0:d(g))h=(0,t._)`${h}${v}${this.opts._n}`;else throw new n(g);y.set(g,r.Completed)})}return h}}e.ValueScope=a})(iN);(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.or=e.and=e.not=e.CodeGen=e.operators=e.varKinds=e.ValueScopeName=e.ValueScope=e.Scope=e.Name=e.regexpCode=e.stringify=e.getProperty=e.nil=e.strConcat=e.str=e._=void 0;const t=Sv,n=iN;var r=Sv;Object.defineProperty(e,"_",{enumerable:!0,get:function(){return r._}}),Object.defineProperty(e,"str",{enumerable:!0,get:function(){return r.str}}),Object.defineProperty(e,"strConcat",{enumerable:!0,get:function(){return r.strConcat}}),Object.defineProperty(e,"nil",{enumerable:!0,get:function(){return r.nil}}),Object.defineProperty(e,"getProperty",{enumerable:!0,get:function(){return r.getProperty}}),Object.defineProperty(e,"stringify",{enumerable:!0,get:function(){return r.stringify}}),Object.defineProperty(e,"regexpCode",{enumerable:!0,get:function(){return r.regexpCode}}),Object.defineProperty(e,"Name",{enumerable:!0,get:function(){return r.Name}});var i=iN;Object.defineProperty(e,"Scope",{enumerable:!0,get:function(){return i.Scope}}),Object.defineProperty(e,"ValueScope",{enumerable:!0,get:function(){return i.ValueScope}}),Object.defineProperty(e,"ValueScopeName",{enumerable:!0,get:function(){return i.ValueScopeName}}),Object.defineProperty(e,"varKinds",{enumerable:!0,get:function(){return i.varKinds}}),e.operators={GT:new t._Code(">"),GTE:new t._Code(">="),LT:new t._Code("<"),LTE:new t._Code("<="),EQ:new t._Code("==="),NEQ:new t._Code("!=="),NOT:new t._Code("!"),OR:new t._Code("||"),AND:new t._Code("&&"),ADD:new t._Code("+")};class s{optimizeNodes(){return this}optimizeNames(O,$){return this}}class o extends s{constructor(O,$,q){super(),this.varKind=O,this.name=$,this.rhs=q}render({es5:O,_n:$}){const q=O?n.varKinds.var:this.varKind,ce=this.rhs===void 0?"":` = ${this.rhs}`;return`${q} ${this.name}${ce};`+$}optimizeNames(O,$){if(O[this.name.str])return this.rhs&&(this.rhs=V(this.rhs,O,$)),this}get names(){return this.rhs instanceof t._CodeOrName?this.rhs.names:{}}}class a extends s{constructor(O,$,q){super(),this.lhs=O,this.rhs=$,this.sideEffects=q}render({_n:O}){return`${this.lhs} = ${this.rhs};`+O}optimizeNames(O,$){if(!(this.lhs instanceof t.Name&&!O[this.lhs.str]&&!this.sideEffects))return this.rhs=V(this.rhs,O,$),this}get names(){const O=this.lhs instanceof t.Name?{}:{...this.lhs.names};return J(O,this.rhs)}}class u extends a{constructor(O,$,q,ce){super(O,q,ce),this.op=$}render({_n:O}){return`${this.lhs} ${this.op}= ${this.rhs};`+O}}class l extends s{constructor(O){super(),this.label=O,this.names={}}render({_n:O}){return`${this.label}:`+O}}class c extends s{constructor(O){super(),this.label=O,this.names={}}render({_n:O}){return`break${this.label?` ${this.label}`:""};`+O}}class f extends s{constructor(O){super(),this.error=O}render({_n:O}){return`throw ${this.error};`+O}get names(){return this.error.names}}class d extends s{constructor(O){super(),this.code=O}render({_n:O}){return`${this.code};`+O}optimizeNodes(){return`${this.code}`?this:void 0}optimizeNames(O,$){return this.code=V(this.code,O,$),this}get names(){return this.code instanceof t._CodeOrName?this.code.names:{}}}class h extends s{constructor(O=[]){super(),this.nodes=O}render(O){return this.nodes.reduce(($,q)=>$+q.render(O),"")}optimizeNodes(){const{nodes:O}=this;let $=O.length;for(;$--;){const q=O[$].optimizeNodes();Array.isArray(q)?O.splice($,1,...q):q?O[$]=q:O.splice($,1)}return O.length>0?this:void 0}optimizeNames(O,$){const{nodes:q}=this;let ce=q.length;for(;ce--;){const fe=q[ce];fe.optimizeNames(O,$)||(re(O,fe.names),q.splice(ce,1))}return q.length>0?this:void 0}get names(){return this.nodes.reduce((O,$)=>B(O,$.names),{})}}class p extends h{render(O){return"{"+O._n+super.render(O)+"}"+O._n}}class m extends h{}class y extends p{}y.kind="else";class g extends p{constructor(O,$){super($),this.condition=O}render(O){let $=`if(${this.condition})`+super.render(O);return this.else&&($+="else "+this.else.render(O)),$}optimizeNodes(){super.optimizeNodes();const O=this.condition;if(O===!0)return this.nodes;let $=this.else;if($){const q=$.optimizeNodes();$=this.else=Array.isArray(q)?new y(q):q}if($)return O===!1?$ instanceof g?$:$.nodes:this.nodes.length?this:new g(oe(O),$ instanceof g?[$]:$.nodes);if(!(O===!1||!this.nodes.length))return this}optimizeNames(O,$){var q;if(this.else=(q=this.else)===null||q===void 0?void 0:q.optimizeNames(O,$),!!(super.optimizeNames(O,$)||this.else))return this.condition=V(this.condition,O,$),this}get names(){const O=super.names;return J(O,this.condition),this.else&&B(O,this.else.names),O}}g.kind="if";class v extends p{}v.kind="for";class b extends v{constructor(O){super(),this.iteration=O}render(O){return`for(${this.iteration})`+super.render(O)}optimizeNames(O,$){if(super.optimizeNames(O,$))return this.iteration=V(this.iteration,O,$),this}get names(){return B(super.names,this.iteration.names)}}class S extends v{constructor(O,$,q,ce){super(),this.varKind=O,this.name=$,this.from=q,this.to=ce}render(O){const $=O.es5?n.varKinds.var:this.varKind,{name:q,from:ce,to:fe}=this;return`for(${$} ${q}=${ce}; ${q}<${fe}; ${q}++)`+super.render(O)}get names(){const O=J(super.names,this.from);return J(O,this.to)}}class T extends v{constructor(O,$,q,ce){super(),this.loop=O,this.varKind=$,this.name=q,this.iterable=ce}render(O){return`for(${this.varKind} ${this.name} ${this.loop} ${this.iterable})`+super.render(O)}optimizeNames(O,$){if(super.optimizeNames(O,$))return this.iterable=V(this.iterable,O,$),this}get names(){return B(super.names,this.iterable.names)}}class E extends p{constructor(O,$,q){super(),this.name=O,this.args=$,this.async=q}render(O){return`${this.async?"async ":""}function ${this.name}(${this.args})`+super.render(O)}}E.kind="func";class I extends h{render(O){return"return "+super.render(O)}}I.kind="return";class A extends p{render(O){let $="try"+super.render(O);return this.catch&&($+=this.catch.render(O)),this.finally&&($+=this.finally.render(O)),$}optimizeNodes(){var O,$;return super.optimizeNodes(),(O=this.catch)===null||O===void 0||O.optimizeNodes(),($=this.finally)===null||$===void 0||$.optimizeNodes(),this}optimizeNames(O,$){var q,ce;return super.optimizeNames(O,$),(q=this.catch)===null||q===void 0||q.optimizeNames(O,$),(ce=this.finally)===null||ce===void 0||ce.optimizeNames(O,$),this}get names(){const O=super.names;return this.catch&&B(O,this.catch.names),this.finally&&B(O,this.finally.names),O}}class R extends p{constructor(O){super(),this.error=O}render(O){return`catch(${this.error})`+super.render(O)}}R.kind="catch";class F extends p{render(O){return"finally"+super.render(O)}}F.kind="finally";class L{constructor(O,$={}){this._values={},this._blockStarts=[],this._constants={},this.opts={...$,_n:$.lines?` `:""},this._extScope=O,this._scope=new n.Scope({parent:O}),this._nodes=[new m]}toString(){return this._root.render(this.opts)}name(O){return this._scope.name(O)}scopeName(O){return this._extScope.name(O)}scopeValue(O,$){const q=this._extScope.value(O,$);return(this._values[q.prefix]||(this._values[q.prefix]=new Set)).add(q),q}getScopeValue(O,$){return this._extScope.getValue(O,$)}scopeRefs(O){return this._extScope.scopeRefs(O,this._values)}scopeCode(){return this._extScope.scopeCode(this._values)}_def(O,$,q,ce){const fe=this._scope.toName($);return q!==void 0&&ce&&(this._constants[fe.str]=q),this._leafNode(new o(O,fe,q)),fe}const(O,$,q){return this._def(n.varKinds.const,O,$,q)}let(O,$,q){return this._def(n.varKinds.let,O,$,q)}var(O,$,q){return this._def(n.varKinds.var,O,$,q)}assign(O,$,q){return this._leafNode(new a(O,$,q))}add(O,$){return this._leafNode(new u(O,e.operators.ADD,$))}code(O){return typeof O=="function"?O():O!==t.nil&&this._leafNode(new d(O)),this}object(...O){const $=["{"];for(const[q,ce]of O)$.length>1&&$.push(","),$.push(q),(q!==ce||this.opts.es5)&&($.push(":"),(0,t.addCodeArg)($,ce));return $.push("}"),new t._Code($)}if(O,$,q){if(this._blockNode(new g(O)),$&&q)this.code($).else().code(q).endIf();else if($)this.code($).endIf();else if(q)throw new Error('CodeGen: "else" body without "then" body');return this}elseIf(O){return this._elseNode(new g(O))}else(){return this._elseNode(new y)}endIf(){return this._endBlockNode(g,y)}_for(O,$){return this._blockNode(O),$&&this.code($).endFor(),this}for(O,$){return this._for(new b(O),$)}forRange(O,$,q,ce,fe=this.opts.es5?n.varKinds.var:n.varKinds.let){const de=this._scope.toName(O);return this._for(new S(fe,de,$,q),()=>ce(de))}forOf(O,$,q,ce=n.varKinds.const){const fe=this._scope.toName(O);if(this.opts.es5){const de=$ instanceof t.Name?$:this.var("_arr",$);return this.forRange("_i",0,(0,t._)`${de}.length`,ve=>{this.var(fe,(0,t._)`${de}[${ve}]`),q(fe)})}return this._for(new T("of",ce,fe,$),()=>q(fe))}forIn(O,$,q,ce=this.opts.es5?n.varKinds.var:n.varKinds.const){if(this.opts.ownProperties)return this.forOf(O,(0,t._)`Object.keys(${$})`,q);const fe=this._scope.toName(O);return this._for(new T("in",ce,fe,$),()=>q(fe))}endFor(){return this._endBlockNode(v)}label(O){return this._leafNode(new l(O))}break(O){return this._leafNode(new c(O))}return(O){const $=new I;if(this._blockNode($),this.code(O),$.nodes.length!==1)throw new Error('CodeGen: "return" should have one node');return this._endBlockNode(I)}try(O,$,q){if(!$&&!q)throw new Error('CodeGen: "try" without "catch" and "finally"');const ce=new A;if(this._blockNode(ce),this.code(O),$){const fe=this.name("e");this._currNode=ce.catch=new R(fe),$(fe)}return q&&(this._currNode=ce.finally=new F,this.code(q)),this._endBlockNode(R,F)}throw(O){return this._leafNode(new f(O))}block(O,$){return this._blockStarts.push(this._nodes.length),O&&this.code(O).endBlock($),this}endBlock(O){const $=this._blockStarts.pop();if($===void 0)throw new Error("CodeGen: not in self-balancing block");const q=this._nodes.length-$;if(q<0||O!==void 0&&q!==O)throw new Error(`CodeGen: wrong number of nodes: ${q} vs ${O} expected`);return this._nodes.length=$,this}func(O,$=t.nil,q,ce){return this._blockNode(new E(O,$,q)),ce&&this.code(ce).endFunc(),this}endFunc(){return this._endBlockNode(E)}optimize(O=1){for(;O-- >0;)this._root.optimizeNodes(),this._root.optimizeNames(this._root.names,this._constants)}_leafNode(O){return this._currNode.nodes.push(O),this}_blockNode(O){this._currNode.nodes.push(O),this._nodes.push(O)}_endBlockNode(O,$){const q=this._currNode;if(q instanceof O||$&&q instanceof $)return this._nodes.pop(),this;throw new Error(`CodeGen: not in block "${$?`${O.kind}/${$.kind}`:O.kind}"`)}_elseNode(O){const $=this._currNode;if(!($ instanceof g))throw new Error('CodeGen: "else" without "if"');return this._currNode=$.else=O,this}get _root(){return this._nodes[0]}get _currNode(){const O=this._nodes;return O[O.length-1]}set _currNode(O){const $=this._nodes;$[$.length-1]=O}}e.CodeGen=L;function B(x,O){for(const $ in O)x[$]=(x[$]||0)+(O[$]||0);return x}function J(x,O){return O instanceof t._CodeOrName?B(x,O.names):x}function V(x,O,$){if(x instanceof t.Name)return q(x);if(!ce(x))return x;return new t._Code(x._items.reduce((fe,de)=>(de instanceof t.Name&&(de=q(de)),de instanceof t._Code?fe.push(...de._items):fe.push(de),fe),[]));function q(fe){const de=$[fe.str];return de===void 0||O[fe.str]!==1?fe:(delete O[fe.str],de)}function ce(fe){return fe instanceof t._Code&&fe._items.some(de=>de instanceof t.Name&&O[de.str]===1&&$[de.str]!==void 0)}}function re(x,O){for(const $ in O)x[$]=(x[$]||0)-(O[$]||0)}function oe(x){return typeof x=="boolean"||typeof x=="number"||x===null?!x:(0,t._)`!${Q(x)}`}e.not=oe;const ae=W(e.operators.AND);function ee(...x){return x.reduce(ae)}e.and=ee;const ue=W(e.operators.OR);function P(...x){return x.reduce(ue)}e.or=P;function W(x){return(O,$)=>O===t.nil?$:$===t.nil?O:(0,t._)`${Q(O)} ${x} ${Q($)}`}function Q(x){return x instanceof t.Name?x:(0,t._)`(${x})`}})(Xt);var _n={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.checkStrictMode=e.getErrorPath=e.Type=e.useFunc=e.setEvaluated=e.evaluatedPropsToName=e.mergeEvaluated=e.eachItem=e.unescapeJsonPointer=e.escapeJsonPointer=e.escapeFragment=e.unescapeFragment=e.schemaRefOrVal=e.schemaHasRulesButRef=e.schemaHasRules=e.checkUnknownRules=e.alwaysValidSchema=e.toHash=void 0;const t=Xt,n=Sv;function r(E){const I={};for(const A of E)I[A]=!0;return I}e.toHash=r;function i(E,I){return typeof I=="boolean"?I:Object.keys(I).length===0?!0:(s(E,I),!o(I,E.self.RULES.all))}e.alwaysValidSchema=i;function s(E,I=E.schema){const{opts:A,self:R}=E;if(!A.strictSchema||typeof I=="boolean")return;const F=R.RULES.keywords;for(const L in I)F[L]||T(E,`unknown keyword: "${L}"`)}e.checkUnknownRules=s;function o(E,I){if(typeof E=="boolean")return!E;for(const A in E)if(I[A])return!0;return!1}e.schemaHasRules=o;function a(E,I){if(typeof E=="boolean")return!E;for(const A in E)if(A!=="$ref"&&I.all[A])return!0;return!1}e.schemaHasRulesButRef=a;function u({topSchemaRef:E,schemaPath:I},A,R,F){if(!F){if(typeof A=="number"||typeof A=="boolean")return A;if(typeof A=="string")return(0,t._)`${A}`}return(0,t._)`${E}${I}${(0,t.getProperty)(R)}`}e.schemaRefOrVal=u;function l(E){return d(decodeURIComponent(E))}e.unescapeFragment=l;function c(E){return encodeURIComponent(f(E))}e.escapeFragment=c;function f(E){return typeof E=="number"?`${E}`:E.replace(/~/g,"~0").replace(/\//g,"~1")}e.escapeJsonPointer=f;function d(E){return E.replace(/~1/g,"/").replace(/~0/g,"~")}e.unescapeJsonPointer=d;function h(E,I){if(Array.isArray(E))for(const A of E)I(A);else I(E)}e.eachItem=h;function p({mergeNames:E,mergeToName:I,mergeValues:A,resultToName:R}){return(F,L,B,J)=>{const V=B===void 0?L:B instanceof t.Name?(L instanceof t.Name?E(F,L,B):I(F,L,B),B):L instanceof t.Name?(I(F,B,L),L):A(L,B);return J===t.Name&&!(V instanceof t.Name)?R(F,V):V}}e.mergeEvaluated={props:p({mergeNames:(E,I,A)=>E.if((0,t._)`${A} !== true && ${I} !== undefined`,()=>{E.if((0,t._)`${I} === true`,()=>E.assign(A,!0),()=>E.assign(A,(0,t._)`${A} || {}`).code((0,t._)`Object.assign(${A}, ${I})`))}),mergeToName:(E,I,A)=>E.if((0,t._)`${A} !== true`,()=>{I===!0?E.assign(A,!0):(E.assign(A,(0,t._)`${A} || {}`),y(E,A,I))}),mergeValues:(E,I)=>E===!0?!0:{...E,...I},resultToName:m}),items:p({mergeNames:(E,I,A)=>E.if((0,t._)`${A} !== true && ${I} !== undefined`,()=>E.assign(A,(0,t._)`${I} === true ? true : ${A} > ${I} ? ${A} : ${I}`)),mergeToName:(E,I,A)=>E.if((0,t._)`${A} !== true`,()=>E.assign(A,I===!0?!0:(0,t._)`${A} > ${I} ? ${A} : ${I}`)),mergeValues:(E,I)=>E===!0?!0:Math.max(E,I),resultToName:(E,I)=>E.var("items",I)})};function m(E,I){if(I===!0)return E.var("props",!0);const A=E.var("props",(0,t._)`{}`);return I!==void 0&&y(E,A,I),A}e.evaluatedPropsToName=m;function y(E,I,A){Object.keys(A).forEach(R=>E.assign((0,t._)`${I}${(0,t.getProperty)(R)}`,!0))}e.setEvaluated=y;const g={};function v(E,I){return E.scopeValue("func",{ref:I,code:g[I.code]||(g[I.code]=new n._Code(I.code))})}e.useFunc=v;var b;(function(E){E[E.Num=0]="Num",E[E.Str=1]="Str"})(b=e.Type||(e.Type={}));function S(E,I,A){if(E instanceof t.Name){const R=I===b.Num;return A?R?(0,t._)`"[" + ${E} + "]"`:(0,t._)`"['" + ${E} + "']"`:R?(0,t._)`"/" + ${E}`:(0,t._)`"/" + ${E}.replace(/~/g, "~0").replace(/\\//g, "~1")`}return A?(0,t.getProperty)(E).toString():"/"+f(E)}e.getErrorPath=S;function T(E,I,A=E.opts.strictSchema){if(A){if(I=`strict mode: ${I}`,A===!0)throw new Error(I);E.self.logger.warn(I)}}e.checkStrictMode=T})(_n);var dl={};Object.defineProperty(dl,"__esModule",{value:!0});const Gi=Xt,_De={data:new Gi.Name("data"),valCxt:new Gi.Name("valCxt"),instancePath:new Gi.Name("instancePath"),parentData:new Gi.Name("parentData"),parentDataProperty:new Gi.Name("parentDataProperty"),rootData:new Gi.Name("rootData"),dynamicAnchors:new Gi.Name("dynamicAnchors"),vErrors:new Gi.Name("vErrors"),errors:new Gi.Name("errors"),this:new Gi.Name("this"),self:new Gi.Name("self"),scope:new Gi.Name("scope"),json:new Gi.Name("json"),jsonPos:new Gi.Name("jsonPos"),jsonLen:new Gi.Name("jsonLen"),jsonPart:new Gi.Name("jsonPart")};dl.default=_De;(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.extendErrors=e.resetErrorsCount=e.reportExtraError=e.reportError=e.keyword$DataError=e.keywordError=void 0;const t=Xt,n=_n,r=dl;e.keywordError={message:({keyword:y})=>(0,t.str)`must pass "${y}" keyword validation`},e.keyword$DataError={message:({keyword:y,schemaType:g})=>g?(0,t.str)`"${y}" keyword must be ${g} ($data)`:(0,t.str)`"${y}" keyword is invalid ($data)`};function i(y,g=e.keywordError,v,b){const{it:S}=y,{gen:T,compositeRule:E,allErrors:I}=S,A=f(y,g,v);b??(E||I)?u(T,A):l(S,(0,t._)`[${A}]`)}e.reportError=i;function s(y,g=e.keywordError,v){const{it:b}=y,{gen:S,compositeRule:T,allErrors:E}=b,I=f(y,g,v);u(S,I),T||E||l(b,r.default.vErrors)}e.reportExtraError=s;function o(y,g){y.assign(r.default.errors,g),y.if((0,t._)`${r.default.vErrors} !== null`,()=>y.if(g,()=>y.assign((0,t._)`${r.default.vErrors}.length`,g),()=>y.assign(r.default.vErrors,null)))}e.resetErrorsCount=o;function a({gen:y,keyword:g,schemaValue:v,data:b,errsCount:S,it:T}){if(S===void 0)throw new Error("ajv implementation error");const E=y.name("err");y.forRange("i",S,r.default.errors,I=>{y.const(E,(0,t._)`${r.default.vErrors}[${I}]`),y.if((0,t._)`${E}.instancePath === undefined`,()=>y.assign((0,t._)`${E}.instancePath`,(0,t.strConcat)(r.default.instancePath,T.errorPath))),y.assign((0,t._)`${E}.schemaPath`,(0,t.str)`${T.errSchemaPath}/${g}`),T.opts.verbose&&(y.assign((0,t._)`${E}.schema`,v),y.assign((0,t._)`${E}.data`,b))})}e.extendErrors=a;function u(y,g){const v=y.const("err",g);y.if((0,t._)`${r.default.vErrors} === null`,()=>y.assign(r.default.vErrors,(0,t._)`[${v}]`),(0,t._)`${r.default.vErrors}.push(${v})`),y.code((0,t._)`${r.default.errors}++`)}function l(y,g){const{gen:v,validateName:b,schemaEnv:S}=y;S.$async?v.throw((0,t._)`new ${y.ValidationError}(${g})`):(v.assign((0,t._)`${b}.errors`,g),v.return(!1))}const c={keyword:new t.Name("keyword"),schemaPath:new t.Name("schemaPath"),params:new t.Name("params"),propertyName:new t.Name("propertyName"),message:new t.Name("message"),schema:new t.Name("schema"),parentSchema:new t.Name("parentSchema")};function f(y,g,v){const{createErrors:b}=y.it;return b===!1?(0,t._)`{}`:d(y,g,v)}function d(y,g,v={}){const{gen:b,it:S}=y,T=[h(S,v),p(y,v)];return m(y,g,T),b.object(...T)}function h({errorPath:y},{instancePath:g}){const v=g?(0,t.str)`${y}${(0,n.getErrorPath)(g,n.Type.Str)}`:y;return[r.default.instancePath,(0,t.strConcat)(r.default.instancePath,v)]}function p({keyword:y,it:{errSchemaPath:g}},{schemaPath:v,parentSchema:b}){let S=b?g:(0,t.str)`${g}/${y}`;return v&&(S=(0,t.str)`${S}${(0,n.getErrorPath)(v,n.Type.Str)}`),[c.schemaPath,S]}function m(y,{params:g,message:v},b){const{keyword:S,data:T,schemaValue:E,it:I}=y,{opts:A,propertyName:R,topSchemaRef:F,schemaPath:L}=I;b.push([c.keyword,S],[c.params,typeof g=="function"?g(y):g||(0,t._)`{}`]),A.messages&&b.push([c.message,typeof v=="function"?v(y):v]),A.verbose&&b.push([c.schema,E],[c.parentSchema,(0,t._)`${F}${L}`],[r.default.data,T]),R&&b.push([c.propertyName,R])}})(U_);Object.defineProperty(Um,"__esModule",{value:!0});Um.boolOrEmptySchema=Um.topBoolOrEmptySchema=void 0;const bDe=U_,wDe=Xt,EDe=dl,SDe={message:"boolean schema is false"};function TDe(e){const{gen:t,schema:n,validateName:r}=e;n===!1?$te(e,!1):typeof n=="object"&&n.$async===!0?t.return(EDe.default.data):(t.assign((0,wDe._)`${r}.errors`,null),t.return(!0))}Um.topBoolOrEmptySchema=TDe;function IDe(e,t){const{gen:n,schema:r}=e;r===!1?(n.var(t,!1),$te(e)):n.var(t,!0)}Um.boolOrEmptySchema=IDe;function $te(e,t){const{gen:n,data:r}=e,i={gen:n,keyword:"false schema",data:r,schema:!1,schemaCode:!1,schemaValue:!1,params:{},it:e};(0,bDe.reportError)(i,SDe,void 0,t)}var V_={},fh={};Object.defineProperty(fh,"__esModule",{value:!0});fh.getRules=fh.isJSONType=void 0;const xDe=["string","number","integer","boolean","null","object","array"],CDe=new Set(xDe);function ADe(e){return typeof e=="string"&&CDe.has(e)}fh.isJSONType=ADe;function PDe(){const e={number:{type:"number",rules:[]},string:{type:"string",rules:[]},array:{type:"array",rules:[]},object:{type:"object",rules:[]}};return{types:{...e,integer:!0,boolean:!0,null:!0},rules:[{rules:[]},e.number,e.string,e.array,e.object],post:{rules:[]},all:{},keywords:{}}}fh.getRules=PDe;var Bl={};Object.defineProperty(Bl,"__esModule",{value:!0});Bl.shouldUseRule=Bl.shouldUseGroup=Bl.schemaHasRulesForType=void 0;function ODe({schema:e,self:t},n){const r=t.RULES.types[n];return r&&r!==!0&&Lte(e,r)}Bl.schemaHasRulesForType=ODe;function Lte(e,t){return t.rules.some(n=>Mte(e,n))}Bl.shouldUseGroup=Lte;function Mte(e,t){var n;return e[t.keyword]!==void 0||((n=t.definition.implements)===null||n===void 0?void 0:n.some(r=>e[r]!==void 0))}Bl.shouldUseRule=Mte;(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.reportTypeError=e.checkDataTypes=e.checkDataType=e.coerceAndCheckDataType=e.getJSONTypes=e.getSchemaTypes=e.DataType=void 0;const t=fh,n=Bl,r=U_,i=Xt,s=_n;var o;(function(b){b[b.Correct=0]="Correct",b[b.Wrong=1]="Wrong"})(o=e.DataType||(e.DataType={}));function a(b){const S=u(b.type);if(S.includes("null")){if(b.nullable===!1)throw new Error("type: null contradicts nullable: false")}else{if(!S.length&&b.nullable!==void 0)throw new Error('"nullable" cannot be used without "type"');b.nullable===!0&&S.push("null")}return S}e.getSchemaTypes=a;function u(b){const S=Array.isArray(b)?b:b?[b]:[];if(S.every(t.isJSONType))return S;throw new Error("type must be JSONType or JSONType[]: "+S.join(","))}e.getJSONTypes=u;function l(b,S){const{gen:T,data:E,opts:I}=b,A=f(S,I.coerceTypes),R=S.length>0&&!(A.length===0&&S.length===1&&(0,n.schemaHasRulesForType)(b,S[0]));if(R){const F=m(S,E,I.strictNumbers,o.Wrong);T.if(F,()=>{A.length?d(b,S,A):g(b)})}return R}e.coerceAndCheckDataType=l;const c=new Set(["string","number","integer","boolean","null"]);function f(b,S){return S?b.filter(T=>c.has(T)||S==="array"&&T==="array"):[]}function d(b,S,T){const{gen:E,data:I,opts:A}=b,R=E.let("dataType",(0,i._)`typeof ${I}`),F=E.let("coerced",(0,i._)`undefined`);A.coerceTypes==="array"&&E.if((0,i._)`${R} == 'object' && Array.isArray(${I}) && ${I}.length == 1`,()=>E.assign(I,(0,i._)`${I}[0]`).assign(R,(0,i._)`typeof ${I}`).if(m(S,I,A.strictNumbers),()=>E.assign(F,I))),E.if((0,i._)`${F} !== undefined`);for(const B of T)(c.has(B)||B==="array"&&A.coerceTypes==="array")&&L(B);E.else(),g(b),E.endIf(),E.if((0,i._)`${F} !== undefined`,()=>{E.assign(I,F),h(b,F)});function L(B){switch(B){case"string":E.elseIf((0,i._)`${R} == "number" || ${R} == "boolean"`).assign(F,(0,i._)`"" + ${I}`).elseIf((0,i._)`${I} === null`).assign(F,(0,i._)`""`);return;case"number":E.elseIf((0,i._)`${R} == "boolean" || ${I} === null || (${R} == "string" && ${I} && ${I} == +${I})`).assign(F,(0,i._)`+${I}`);return;case"integer":E.elseIf((0,i._)`${R} === "boolean" || ${I} === null || (${R} === "string" && ${I} && ${I} == +${I} && !(${I} % 1))`).assign(F,(0,i._)`+${I}`);return;case"boolean":E.elseIf((0,i._)`${I} === "false" || ${I} === 0 || ${I} === null`).assign(F,!1).elseIf((0,i._)`${I} === "true" || ${I} === 1`).assign(F,!0);return;case"null":E.elseIf((0,i._)`${I} === "" || ${I} === 0 || ${I} === false`),E.assign(F,null);return;case"array":E.elseIf((0,i._)`${R} === "string" || ${R} === "number" - || ${R} === "boolean" || ${I} === null`).assign(F,(0,i._)`[${I}]`)}}}function h({gen:b,parentData:S,parentDataProperty:T},E){b.if((0,i._)`${S} !== undefined`,()=>b.assign((0,i._)`${S}[${T}]`,E))}function p(b,S,T,E=o.Correct){const I=E===o.Correct?i.operators.EQ:i.operators.NEQ;let A;switch(b){case"null":return(0,i._)`${S} ${I} null`;case"array":A=(0,i._)`Array.isArray(${S})`;break;case"object":A=(0,i._)`${S} && typeof ${S} == "object" && !Array.isArray(${S})`;break;case"integer":A=R((0,i._)`!(${S} % 1) && !isNaN(${S})`);break;case"number":A=R();break;default:return(0,i._)`typeof ${S} ${I} ${b}`}return E===o.Correct?A:(0,i.not)(A);function R(F=i.nil){return(0,i.and)((0,i._)`typeof ${S} == "number"`,F,T?(0,i._)`isFinite(${S})`:i.nil)}}e.checkDataType=p;function m(b,S,T,E){if(b.length===1)return p(b[0],S,T,E);let I;const A=(0,s.toHash)(b);if(A.array&&A.object){const R=(0,i._)`typeof ${S} != "object"`;I=A.null?R:(0,i._)`!${S} || ${R}`,delete A.null,delete A.array,delete A.object}else I=i.nil;A.number&&delete A.integer;for(const R in A)I=(0,i.and)(I,p(R,S,T,E));return I}e.checkDataTypes=m;const y={message:({schema:b})=>`must be ${b}`,params:({schema:b,schemaValue:S})=>typeof b=="string"?(0,i._)`{type: ${b}}`:(0,i._)`{type: ${S}}`};function g(b){const S=v(b);(0,r.reportError)(S,y)}e.reportTypeError=g;function v(b){const{gen:S,data:T,schema:E}=b,I=(0,s.schemaRefOrVal)(b,E,"type");return{gen:S,keyword:"type",data:T,schema:E.type,schemaCode:I,schemaValue:I,parentSchema:E,params:{},it:b}}})(V_);var iC={};Object.defineProperty(iC,"__esModule",{value:!0});iC.assignDefaults=void 0;const ep=Xt,RDe=_n;function NDe(e,t){const{properties:n,items:r}=e.schema;if(t==="object"&&n)for(const i in n)vU(e,i,n[i].default);else t==="array"&&Array.isArray(r)&&r.forEach((i,s)=>vU(e,s,i.default))}iC.assignDefaults=NDe;function vU(e,t,n){const{gen:r,compositeRule:i,data:s,opts:o}=e;if(n===void 0)return;const a=(0,ep._)`${s}${(0,ep.getProperty)(t)}`;if(i){(0,RDe.checkStrictMode)(e,`default is ignored for: ${a}`);return}let u=(0,ep._)`${a} === undefined`;o.useDefaults==="empty"&&(u=(0,ep._)`${u} || ${a} === null || ${a} === ""`),r.if(u,(0,ep._)`${a} = ${(0,ep.stringify)(n)}`)}var Ou={},Qt={};Object.defineProperty(Qt,"__esModule",{value:!0});Qt.validateUnion=Qt.validateArray=Qt.usePattern=Qt.callValidateCode=Qt.schemaProperties=Qt.allSchemaProperties=Qt.noPropertyInData=Qt.propertyInData=Qt.isOwnProperty=Qt.hasPropFunc=Qt.reportMissingProp=Qt.checkMissingProp=Qt.checkReportMissingProp=void 0;const tr=Xt,o3=_n,Ec=dl,kDe=_n;function DDe(e,t){const{gen:n,data:r,it:i}=e;n.if(u3(n,r,t,i.opts.ownProperties),()=>{e.setParams({missingProperty:(0,tr._)`${t}`},!0),e.error()})}Qt.checkReportMissingProp=DDe;function $De({gen:e,data:t,it:{opts:n}},r,i){return(0,tr.or)(...r.map(s=>(0,tr.and)(u3(e,t,s,n.ownProperties),(0,tr._)`${i} = ${s}`)))}Qt.checkMissingProp=$De;function LDe(e,t){e.setParams({missingProperty:t},!0),e.error()}Qt.reportMissingProp=LDe;function Fte(e){return e.scopeValue("func",{ref:Object.prototype.hasOwnProperty,code:(0,tr._)`Object.prototype.hasOwnProperty`})}Qt.hasPropFunc=Fte;function a3(e,t,n){return(0,tr._)`${Fte(e)}.call(${t}, ${n})`}Qt.isOwnProperty=a3;function MDe(e,t,n,r){const i=(0,tr._)`${t}${(0,tr.getProperty)(n)} !== undefined`;return r?(0,tr._)`${i} && ${a3(e,t,n)}`:i}Qt.propertyInData=MDe;function u3(e,t,n,r){const i=(0,tr._)`${t}${(0,tr.getProperty)(n)} === undefined`;return r?(0,tr.or)(i,(0,tr.not)(a3(e,t,n))):i}Qt.noPropertyInData=u3;function Bte(e){return e?Object.keys(e).filter(t=>t!=="__proto__"):[]}Qt.allSchemaProperties=Bte;function FDe(e,t){return Bte(t).filter(n=>!(0,o3.alwaysValidSchema)(e,t[n]))}Qt.schemaProperties=FDe;function BDe({schemaCode:e,data:t,it:{gen:n,topSchemaRef:r,schemaPath:i,errorPath:s},it:o},a,u,l){const c=l?(0,tr._)`${e}, ${t}, ${r}${i}`:t,f=[[Ec.default.instancePath,(0,tr.strConcat)(Ec.default.instancePath,s)],[Ec.default.parentData,o.parentData],[Ec.default.parentDataProperty,o.parentDataProperty],[Ec.default.rootData,Ec.default.rootData]];o.opts.dynamicRef&&f.push([Ec.default.dynamicAnchors,Ec.default.dynamicAnchors]);const d=(0,tr._)`${c}, ${n.object(...f)}`;return u!==tr.nil?(0,tr._)`${a}.call(${u}, ${d})`:(0,tr._)`${a}(${d})`}Qt.callValidateCode=BDe;const jDe=(0,tr._)`new RegExp`;function UDe({gen:e,it:{opts:t}},n){const r=t.unicodeRegExp?"u":"",{regExp:i}=t.code,s=i(n,r);return e.scopeValue("pattern",{key:s.toString(),ref:s,code:(0,tr._)`${i.code==="new RegExp"?jDe:(0,kDe.useFunc)(e,i)}(${n}, ${r})`})}Qt.usePattern=UDe;function VDe(e){const{gen:t,data:n,keyword:r,it:i}=e,s=t.name("valid");if(i.allErrors){const a=t.let("valid",!0);return o(()=>t.assign(a,!1)),a}return t.var(s,!0),o(()=>t.break()),s;function o(a){const u=t.const("len",(0,tr._)`${n}.length`);t.forRange("i",0,u,l=>{e.subschema({keyword:r,dataProp:l,dataPropType:o3.Type.Num},s),t.if((0,tr.not)(s),a)})}}Qt.validateArray=VDe;function zDe(e){const{gen:t,schema:n,keyword:r,it:i}=e;if(!Array.isArray(n))throw new Error("ajv implementation error");if(n.some(u=>(0,o3.alwaysValidSchema)(i,u))&&!i.opts.unevaluated)return;const o=t.let("valid",!1),a=t.name("_valid");t.block(()=>n.forEach((u,l)=>{const c=e.subschema({keyword:r,schemaProp:l,compositeRule:!0},a);t.assign(o,(0,tr._)`${o} || ${a}`),e.mergeValidEvaluated(c,a)||t.if((0,tr.not)(o))})),e.result(o,()=>e.reset(),()=>e.error(!0))}Qt.validateUnion=zDe;Object.defineProperty(Ou,"__esModule",{value:!0});Ou.validateKeywordUsage=Ou.validSchemaType=Ou.funcKeywordCode=Ou.macroKeywordCode=void 0;const ms=Xt,Sd=dl,HDe=Qt,WDe=U_;function qDe(e,t){const{gen:n,keyword:r,schema:i,parentSchema:s,it:o}=e,a=t.macro.call(o.self,i,s,o),u=jte(n,r,a);o.opts.validateSchema!==!1&&o.self.validateSchema(a,!0);const l=n.name("valid");e.subschema({schema:a,schemaPath:ms.nil,errSchemaPath:`${o.errSchemaPath}/${r}`,topSchemaRef:u,compositeRule:!0},l),e.pass(l,()=>e.error(!0))}Ou.macroKeywordCode=qDe;function GDe(e,t){var n;const{gen:r,keyword:i,schema:s,parentSchema:o,$data:a,it:u}=e;KDe(u,t);const l=!a&&t.compile?t.compile.call(u.self,s,o,u):t.validate,c=jte(r,i,l),f=r.let("valid");e.block$data(f,d),e.ok((n=t.valid)!==null&&n!==void 0?n:f);function d(){if(t.errors===!1)m(),t.modifying&&_U(e),y(()=>e.error());else{const g=t.async?h():p();t.modifying&&_U(e),y(()=>YDe(e,g))}}function h(){const g=r.let("ruleErrs",null);return r.try(()=>m((0,ms._)`await `),v=>r.assign(f,!1).if((0,ms._)`${v} instanceof ${u.ValidationError}`,()=>r.assign(g,(0,ms._)`${v}.errors`),()=>r.throw(v))),g}function p(){const g=(0,ms._)`${c}.errors`;return r.assign(g,null),m(ms.nil),g}function m(g=t.async?(0,ms._)`await `:ms.nil){const v=u.opts.passContext?Sd.default.this:Sd.default.self,b=!("compile"in t&&!a||t.schema===!1);r.assign(f,(0,ms._)`${g}${(0,HDe.callValidateCode)(e,c,v,b)}`,t.modifying)}function y(g){var v;r.if((0,ms.not)((v=t.valid)!==null&&v!==void 0?v:f),g)}}Ou.funcKeywordCode=GDe;function _U(e){const{gen:t,data:n,it:r}=e;t.if(r.parentData,()=>t.assign(n,(0,ms._)`${r.parentData}[${r.parentDataProperty}]`))}function YDe(e,t){const{gen:n}=e;n.if((0,ms._)`Array.isArray(${t})`,()=>{n.assign(Sd.default.vErrors,(0,ms._)`${Sd.default.vErrors} === null ? ${t} : ${Sd.default.vErrors}.concat(${t})`).assign(Sd.default.errors,(0,ms._)`${Sd.default.vErrors}.length`),(0,WDe.extendErrors)(e)},()=>e.error())}function KDe({schemaEnv:e},t){if(t.async&&!e.$async)throw new Error("async keyword in sync schema")}function jte(e,t,n){if(n===void 0)throw new Error(`keyword "${t}" failed to compile`);return e.scopeValue("keyword",typeof n=="function"?{ref:n}:{ref:n,code:(0,ms.stringify)(n)})}function QDe(e,t,n=!1){return!t.length||t.some(r=>r==="array"?Array.isArray(e):r==="object"?e&&typeof e=="object"&&!Array.isArray(e):typeof e==r||n&&typeof e>"u")}Ou.validSchemaType=QDe;function XDe({schema:e,opts:t,self:n,errSchemaPath:r},i,s){if(Array.isArray(i.keyword)?!i.keyword.includes(s):i.keyword!==s)throw new Error("ajv implementation error");const o=i.dependencies;if(o!=null&&o.some(a=>!Object.prototype.hasOwnProperty.call(e,a)))throw new Error(`parent schema must have dependencies of ${s}: ${o.join(",")}`);if(i.validateSchema&&!i.validateSchema(e[s])){const u=`keyword "${s}" value is invalid at path "${r}": `+n.errorsText(i.validateSchema.errors);if(t.validateSchema==="log")n.logger.error(u);else throw new Error(u)}}Ou.validateKeywordUsage=XDe;var pf={};Object.defineProperty(pf,"__esModule",{value:!0});pf.extendSubschemaMode=pf.extendSubschemaData=pf.getSubschema=void 0;const _u=Xt,Ute=_n;function JDe(e,{keyword:t,schemaProp:n,schema:r,schemaPath:i,errSchemaPath:s,topSchemaRef:o}){if(t!==void 0&&r!==void 0)throw new Error('both "keyword" and "schema" passed, only one allowed');if(t!==void 0){const a=e.schema[t];return n===void 0?{schema:a,schemaPath:(0,_u._)`${e.schemaPath}${(0,_u.getProperty)(t)}`,errSchemaPath:`${e.errSchemaPath}/${t}`}:{schema:a[n],schemaPath:(0,_u._)`${e.schemaPath}${(0,_u.getProperty)(t)}${(0,_u.getProperty)(n)}`,errSchemaPath:`${e.errSchemaPath}/${t}/${(0,Ute.escapeFragment)(n)}`}}if(r!==void 0){if(i===void 0||s===void 0||o===void 0)throw new Error('"schemaPath", "errSchemaPath" and "topSchemaRef" are required with "schema"');return{schema:r,schemaPath:i,topSchemaRef:o,errSchemaPath:s}}throw new Error('either "keyword" or "schema" must be passed')}pf.getSubschema=JDe;function ZDe(e,t,{dataProp:n,dataPropType:r,data:i,dataTypes:s,propertyName:o}){if(i!==void 0&&n!==void 0)throw new Error('both "data" and "dataProp" passed, only one allowed');const{gen:a}=t;if(n!==void 0){const{errorPath:l,dataPathArr:c,opts:f}=t,d=a.let("data",(0,_u._)`${t.data}${(0,_u.getProperty)(n)}`,!0);u(d),e.errorPath=(0,_u.str)`${l}${(0,Ute.getErrorPath)(n,r,f.jsPropertySyntax)}`,e.parentDataProperty=(0,_u._)`${n}`,e.dataPathArr=[...c,e.parentDataProperty]}if(i!==void 0){const l=i instanceof _u.Name?i:a.let("data",i,!0);u(l),o!==void 0&&(e.propertyName=o)}s&&(e.dataTypes=s);function u(l){e.data=l,e.dataLevel=t.dataLevel+1,e.dataTypes=[],t.definedProperties=new Set,e.parentData=t.data,e.dataNames=[...t.dataNames,l]}}pf.extendSubschemaData=ZDe;function e$e(e,{jtdDiscriminator:t,jtdMetadata:n,compositeRule:r,createErrors:i,allErrors:s}){r!==void 0&&(e.compositeRule=r),i!==void 0&&(e.createErrors=i),s!==void 0&&(e.allErrors=s),e.jtdDiscriminator=t,e.jtdMetadata=n}pf.extendSubschemaMode=e$e;var Ri={},l3=function e(t,n){if(t===n)return!0;if(t&&n&&typeof t=="object"&&typeof n=="object"){if(t.constructor!==n.constructor)return!1;var r,i,s;if(Array.isArray(t)){if(r=t.length,r!=n.length)return!1;for(i=r;i--!==0;)if(!e(t[i],n[i]))return!1;return!0}if(t.constructor===RegExp)return t.source===n.source&&t.flags===n.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===n.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===n.toString();if(s=Object.keys(t),r=s.length,r!==Object.keys(n).length)return!1;for(i=r;i--!==0;)if(!Object.prototype.hasOwnProperty.call(n,s[i]))return!1;for(i=r;i--!==0;){var o=s[i];if(!e(t[o],n[o]))return!1}return!0}return t!==t&&n!==n};const bU=eu(l3);var Vte={exports:{}},Qc=Vte.exports=function(e,t,n){typeof t=="function"&&(n=t,t={}),n=t.cb||n;var r=typeof n=="function"?n:n.pre||function(){},i=n.post||function(){};Rw(t,r,i,e,"",e)};Qc.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0,if:!0,then:!0,else:!0};Qc.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0};Qc.propsKeywords={$defs:!0,definitions:!0,properties:!0,patternProperties:!0,dependencies:!0};Qc.skipKeywords={default:!0,enum:!0,const:!0,required:!0,maximum:!0,minimum:!0,exclusiveMaximum:!0,exclusiveMinimum:!0,multipleOf:!0,maxLength:!0,minLength:!0,pattern:!0,format:!0,maxItems:!0,minItems:!0,uniqueItems:!0,maxProperties:!0,minProperties:!0};function Rw(e,t,n,r,i,s,o,a,u,l){if(r&&typeof r=="object"&&!Array.isArray(r)){t(r,i,s,o,a,u,l);for(var c in r){var f=r[c];if(Array.isArray(f)){if(c in Qc.arrayKeywords)for(var d=0;dt+=zte(r)),t===1/0))return 1/0}return t}function Hte(e,t="",n){n!==!1&&(t=nm(t));const r=e.parse(t);return Wte(e,r)}Ri.getFullPath=Hte;function Wte(e,t){return e.serialize(t).split("#")[0]+"#"}Ri._getFullPath=Wte;const l$e=/#\/?$/;function nm(e){return e?e.replace(l$e,""):""}Ri.normalizeId=nm;function c$e(e,t,n){return n=nm(n),e.resolve(t,n)}Ri.resolveUrl=c$e;const f$e=/^[a-z_][-a-z0-9._]*$/i;function d$e(e,t){if(typeof e=="boolean")return{};const{schemaId:n,uriResolver:r}=this.opts,i=nm(e[n]||t),s={"":i},o=Hte(r,i,!1),a={},u=new Set;return s$e(e,{allKeys:!0},(f,d,h,p)=>{if(p===void 0)return;const m=o+d;let y=s[p];typeof f[n]=="string"&&(y=g.call(this,f[n])),v.call(this,f.$anchor),v.call(this,f.$dynamicAnchor),s[d]=y;function g(b){const S=this.opts.uriResolver.resolve;if(b=nm(y?S(y,b):b),u.has(b))throw c(b);u.add(b);let T=this.refs[b];return typeof T=="string"&&(T=this.refs[T]),typeof T=="object"?l(f,T.schema,b):b!==nm(m)&&(b[0]==="#"?(l(f,a[b],b),a[b]=f):this.refs[b]=m),b}function v(b){if(typeof b=="string"){if(!f$e.test(b))throw new Error(`invalid anchor "${b}"`);g.call(this,`#${b}`)}}}),a;function l(f,d,h){if(d!==void 0&&!i$e(f,d))throw c(h)}function c(f){return new Error(`reference "${f}" resolves to more than one schema`)}}Ri.getSchemaRefs=d$e;Object.defineProperty(Va,"__esModule",{value:!0});Va.getData=Va.KeywordCxt=Va.validateFunctionCode=void 0;const qte=Um,wU=V_,c3=Bl,TT=V_,h$e=iC,Sy=Ou,ZP=pf,ut=Xt,Rt=dl,p$e=Ri,jl=_n,b0=U_;function m$e(e){if(Kte(e)&&(Qte(e),Yte(e))){v$e(e);return}Gte(e,()=>(0,qte.topBoolOrEmptySchema)(e))}Va.validateFunctionCode=m$e;function Gte({gen:e,validateName:t,schema:n,schemaEnv:r,opts:i},s){i.code.es5?e.func(t,(0,ut._)`${Rt.default.data}, ${Rt.default.valCxt}`,r.$async,()=>{e.code((0,ut._)`"use strict"; ${EU(n,i)}`),y$e(e,i),e.code(s)}):e.func(t,(0,ut._)`${Rt.default.data}, ${g$e(i)}`,r.$async,()=>e.code(EU(n,i)).code(s))}function g$e(e){return(0,ut._)`{${Rt.default.instancePath}="", ${Rt.default.parentData}, ${Rt.default.parentDataProperty}, ${Rt.default.rootData}=${Rt.default.data}${e.dynamicRef?(0,ut._)`, ${Rt.default.dynamicAnchors}={}`:ut.nil}}={}`}function y$e(e,t){e.if(Rt.default.valCxt,()=>{e.var(Rt.default.instancePath,(0,ut._)`${Rt.default.valCxt}.${Rt.default.instancePath}`),e.var(Rt.default.parentData,(0,ut._)`${Rt.default.valCxt}.${Rt.default.parentData}`),e.var(Rt.default.parentDataProperty,(0,ut._)`${Rt.default.valCxt}.${Rt.default.parentDataProperty}`),e.var(Rt.default.rootData,(0,ut._)`${Rt.default.valCxt}.${Rt.default.rootData}`),t.dynamicRef&&e.var(Rt.default.dynamicAnchors,(0,ut._)`${Rt.default.valCxt}.${Rt.default.dynamicAnchors}`)},()=>{e.var(Rt.default.instancePath,(0,ut._)`""`),e.var(Rt.default.parentData,(0,ut._)`undefined`),e.var(Rt.default.parentDataProperty,(0,ut._)`undefined`),e.var(Rt.default.rootData,Rt.default.data),t.dynamicRef&&e.var(Rt.default.dynamicAnchors,(0,ut._)`{}`)})}function v$e(e){const{schema:t,opts:n,gen:r}=e;Gte(e,()=>{n.$comment&&t.$comment&&Jte(e),S$e(e),r.let(Rt.default.vErrors,null),r.let(Rt.default.errors,0),n.unevaluated&&_$e(e),Xte(e),x$e(e)})}function _$e(e){const{gen:t,validateName:n}=e;e.evaluated=t.const("evaluated",(0,ut._)`${n}.evaluated`),t.if((0,ut._)`${e.evaluated}.dynamicProps`,()=>t.assign((0,ut._)`${e.evaluated}.props`,(0,ut._)`undefined`)),t.if((0,ut._)`${e.evaluated}.dynamicItems`,()=>t.assign((0,ut._)`${e.evaluated}.items`,(0,ut._)`undefined`))}function EU(e,t){const n=typeof e=="object"&&e[t.schemaId];return n&&(t.code.source||t.code.process)?(0,ut._)`/*# sourceURL=${n} */`:ut.nil}function b$e(e,t){if(Kte(e)&&(Qte(e),Yte(e))){w$e(e,t);return}(0,qte.boolOrEmptySchema)(e,t)}function Yte({schema:e,self:t}){if(typeof e=="boolean")return!e;for(const n in e)if(t.RULES.all[n])return!0;return!1}function Kte(e){return typeof e.schema!="boolean"}function w$e(e,t){const{schema:n,gen:r,opts:i}=e;i.$comment&&n.$comment&&Jte(e),T$e(e),I$e(e);const s=r.const("_errs",Rt.default.errors);Xte(e,s),r.var(t,(0,ut._)`${s} === ${Rt.default.errors}`)}function Qte(e){(0,jl.checkUnknownRules)(e),E$e(e)}function Xte(e,t){if(e.opts.jtd)return SU(e,[],!1,t);const n=(0,wU.getSchemaTypes)(e.schema),r=(0,wU.coerceAndCheckDataType)(e,n);SU(e,n,!r,t)}function E$e(e){const{schema:t,errSchemaPath:n,opts:r,self:i}=e;t.$ref&&r.ignoreKeywordsWithRef&&(0,jl.schemaHasRulesButRef)(t,i.RULES)&&i.logger.warn(`$ref: keywords ignored in schema at path "${n}"`)}function S$e(e){const{schema:t,opts:n}=e;t.default!==void 0&&n.useDefaults&&n.strictSchema&&(0,jl.checkStrictMode)(e,"default is ignored in the schema root")}function T$e(e){const t=e.schema[e.opts.schemaId];t&&(e.baseId=(0,p$e.resolveUrl)(e.opts.uriResolver,e.baseId,t))}function I$e(e){if(e.schema.$async&&!e.schemaEnv.$async)throw new Error("async schema in sync schema")}function Jte({gen:e,schemaEnv:t,schema:n,errSchemaPath:r,opts:i}){const s=n.$comment;if(i.$comment===!0)e.code((0,ut._)`${Rt.default.self}.logger.log(${s})`);else if(typeof i.$comment=="function"){const o=(0,ut.str)`${r}/$comment`,a=e.scopeValue("root",{ref:t.root});e.code((0,ut._)`${Rt.default.self}.opts.$comment(${s}, ${o}, ${a}.schema)`)}}function x$e(e){const{gen:t,schemaEnv:n,validateName:r,ValidationError:i,opts:s}=e;n.$async?t.if((0,ut._)`${Rt.default.errors} === 0`,()=>t.return(Rt.default.data),()=>t.throw((0,ut._)`new ${i}(${Rt.default.vErrors})`)):(t.assign((0,ut._)`${r}.errors`,Rt.default.vErrors),s.unevaluated&&C$e(e),t.return((0,ut._)`${Rt.default.errors} === 0`))}function C$e({gen:e,evaluated:t,props:n,items:r}){n instanceof ut.Name&&e.assign((0,ut._)`${t}.props`,n),r instanceof ut.Name&&e.assign((0,ut._)`${t}.items`,r)}function SU(e,t,n,r){const{gen:i,schema:s,data:o,allErrors:a,opts:u,self:l}=e,{RULES:c}=l;if(s.$ref&&(u.ignoreKeywordsWithRef||!(0,jl.schemaHasRulesButRef)(s,c))){i.block(()=>tne(e,"$ref",c.all.$ref.definition));return}u.jtd||A$e(e,t),i.block(()=>{for(const d of c.rules)f(d);f(c.post)});function f(d){(0,c3.shouldUseGroup)(s,d)&&(d.type?(i.if((0,TT.checkDataType)(d.type,o,u.strictNumbers)),TU(e,d),t.length===1&&t[0]===d.type&&n&&(i.else(),(0,TT.reportTypeError)(e)),i.endIf()):TU(e,d),a||i.if((0,ut._)`${Rt.default.errors} === ${r||0}`))}}function TU(e,t){const{gen:n,schema:r,opts:{useDefaults:i}}=e;i&&(0,h$e.assignDefaults)(e,t.type),n.block(()=>{for(const s of t.rules)(0,c3.shouldUseRule)(r,s)&&tne(e,s.keyword,s.definition,t.type)})}function A$e(e,t){e.schemaEnv.meta||!e.opts.strictTypes||(P$e(e,t),e.opts.allowUnionTypes||O$e(e,t),R$e(e,e.dataTypes))}function P$e(e,t){if(t.length){if(!e.dataTypes.length){e.dataTypes=t;return}t.forEach(n=>{Zte(e.dataTypes,n)||f3(e,`type "${n}" not allowed by context "${e.dataTypes.join(",")}"`)}),k$e(e,t)}}function O$e(e,t){t.length>1&&!(t.length===2&&t.includes("null"))&&f3(e,"use allowUnionTypes to allow union type keyword")}function R$e(e,t){const n=e.self.RULES.all;for(const r in n){const i=n[r];if(typeof i=="object"&&(0,c3.shouldUseRule)(e.schema,i)){const{type:s}=i.definition;s.length&&!s.some(o=>N$e(t,o))&&f3(e,`missing type "${s.join(",")}" for keyword "${r}"`)}}}function N$e(e,t){return e.includes(t)||t==="number"&&e.includes("integer")}function Zte(e,t){return e.includes(t)||t==="integer"&&e.includes("number")}function k$e(e,t){const n=[];for(const r of e.dataTypes)Zte(t,r)?n.push(r):t.includes("integer")&&r==="number"&&n.push("integer");e.dataTypes=n}function f3(e,t){const n=e.schemaEnv.baseId+e.errSchemaPath;t+=` at "${n}" (strictTypes)`,(0,jl.checkStrictMode)(e,t,e.opts.strictTypes)}class ene{constructor(t,n,r){if((0,Sy.validateKeywordUsage)(t,n,r),this.gen=t.gen,this.allErrors=t.allErrors,this.keyword=r,this.data=t.data,this.schema=t.schema[r],this.$data=n.$data&&t.opts.$data&&this.schema&&this.schema.$data,this.schemaValue=(0,jl.schemaRefOrVal)(t,this.schema,r,this.$data),this.schemaType=n.schemaType,this.parentSchema=t.schema,this.params={},this.it=t,this.def=n,this.$data)this.schemaCode=t.gen.const("vSchema",nne(this.$data,t));else if(this.schemaCode=this.schemaValue,!(0,Sy.validSchemaType)(this.schema,n.schemaType,n.allowUndefined))throw new Error(`${r} value must be ${JSON.stringify(n.schemaType)}`);("code"in n?n.trackErrors:n.errors!==!1)&&(this.errsCount=t.gen.const("_errs",Rt.default.errors))}result(t,n,r){this.failResult((0,ut.not)(t),n,r)}failResult(t,n,r){this.gen.if(t),r?r():this.error(),n?(this.gen.else(),n(),this.allErrors&&this.gen.endIf()):this.allErrors?this.gen.endIf():this.gen.else()}pass(t,n){this.failResult((0,ut.not)(t),void 0,n)}fail(t){if(t===void 0){this.error(),this.allErrors||this.gen.if(!1);return}this.gen.if(t),this.error(),this.allErrors?this.gen.endIf():this.gen.else()}fail$data(t){if(!this.$data)return this.fail(t);const{schemaCode:n}=this;this.fail((0,ut._)`${n} !== undefined && (${(0,ut.or)(this.invalid$data(),t)})`)}error(t,n,r){if(n){this.setParams(n),this._error(t,r),this.setParams({});return}this._error(t,r)}_error(t,n){(t?b0.reportExtraError:b0.reportError)(this,this.def.error,n)}$dataError(){(0,b0.reportError)(this,this.def.$dataError||b0.keyword$DataError)}reset(){if(this.errsCount===void 0)throw new Error('add "trackErrors" to keyword definition');(0,b0.resetErrorsCount)(this.gen,this.errsCount)}ok(t){this.allErrors||this.gen.if(t)}setParams(t,n){n?Object.assign(this.params,t):this.params=t}block$data(t,n,r=ut.nil){this.gen.block(()=>{this.check$data(t,r),n()})}check$data(t=ut.nil,n=ut.nil){if(!this.$data)return;const{gen:r,schemaCode:i,schemaType:s,def:o}=this;r.if((0,ut.or)((0,ut._)`${i} === undefined`,n)),t!==ut.nil&&r.assign(t,!0),(s.length||o.validateSchema)&&(r.elseIf(this.invalid$data()),this.$dataError(),t!==ut.nil&&r.assign(t,!1)),r.else()}invalid$data(){const{gen:t,schemaCode:n,schemaType:r,def:i,it:s}=this;return(0,ut.or)(o(),a());function o(){if(r.length){if(!(n instanceof ut.Name))throw new Error("ajv implementation error");const u=Array.isArray(r)?r:[r];return(0,ut._)`${(0,TT.checkDataTypes)(u,n,s.opts.strictNumbers,TT.DataType.Wrong)}`}return ut.nil}function a(){if(i.validateSchema){const u=t.scopeValue("validate$data",{ref:i.validateSchema});return(0,ut._)`!${u}(${n})`}return ut.nil}}subschema(t,n){const r=(0,ZP.getSubschema)(this.it,t);(0,ZP.extendSubschemaData)(r,this.it,t),(0,ZP.extendSubschemaMode)(r,t);const i={...this.it,...r,items:void 0,props:void 0};return b$e(i,n),i}mergeEvaluated(t,n){const{it:r,gen:i}=this;r.opts.unevaluated&&(r.props!==!0&&t.props!==void 0&&(r.props=jl.mergeEvaluated.props(i,t.props,r.props,n)),r.items!==!0&&t.items!==void 0&&(r.items=jl.mergeEvaluated.items(i,t.items,r.items,n)))}mergeValidEvaluated(t,n){const{it:r,gen:i}=this;if(r.opts.unevaluated&&(r.props!==!0||r.items!==!0))return i.if(n,()=>this.mergeEvaluated(t,ut.Name)),!0}}Va.KeywordCxt=ene;function tne(e,t,n,r){const i=new ene(e,n,t);"code"in n?n.code(i,r):i.$data&&n.validate?(0,Sy.funcKeywordCode)(i,n):"macro"in n?(0,Sy.macroKeywordCode)(i,n):(n.compile||n.validate)&&(0,Sy.funcKeywordCode)(i,n)}const D$e=/^\/(?:[^~]|~0|~1)*$/,$$e=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function nne(e,{dataLevel:t,dataNames:n,dataPathArr:r}){let i,s;if(e==="")return Rt.default.rootData;if(e[0]==="/"){if(!D$e.test(e))throw new Error(`Invalid JSON-pointer: ${e}`);i=e,s=Rt.default.rootData}else{const l=$$e.exec(e);if(!l)throw new Error(`Invalid JSON-pointer: ${e}`);const c=+l[1];if(i=l[2],i==="#"){if(c>=t)throw new Error(u("property/index",c));return r[t-c]}if(c>t)throw new Error(u("data",c));if(s=n[t-c],!i)return s}let o=s;const a=i.split("/");for(const l of a)l&&(s=(0,ut._)`${s}${(0,ut.getProperty)((0,jl.unescapeJsonPointer)(l))}`,o=(0,ut._)`${o} && ${s}`);return o;function u(l,c){return`Cannot access ${l} ${c} levels up, current level is ${t}`}}Va.getData=nne;var z_={};Object.defineProperty(z_,"__esModule",{value:!0});class L$e extends Error{constructor(t){super("validation failed"),this.errors=t,this.ajv=this.validation=!0}}z_.default=L$e;var H_={};Object.defineProperty(H_,"__esModule",{value:!0});const eO=Ri;class M$e extends Error{constructor(t,n,r,i){super(i||`can't resolve reference ${r} from id ${n}`),this.missingRef=(0,eO.resolveUrl)(t,n,r),this.missingSchema=(0,eO.normalizeId)((0,eO.getFullPath)(t,this.missingRef))}}H_.default=M$e;var zs={};Object.defineProperty(zs,"__esModule",{value:!0});zs.resolveSchema=zs.getCompilingSchema=zs.resolveRef=zs.compileSchema=zs.SchemaEnv=void 0;const Ea=Xt,F$e=z_,ld=dl,ka=Ri,IU=_n,B$e=Va;class sC{constructor(t){var n;this.refs={},this.dynamicAnchors={};let r;typeof t.schema=="object"&&(r=t.schema),this.schema=t.schema,this.schemaId=t.schemaId,this.root=t.root||this,this.baseId=(n=t.baseId)!==null&&n!==void 0?n:(0,ka.normalizeId)(r==null?void 0:r[t.schemaId||"$id"]),this.schemaPath=t.schemaPath,this.localRefs=t.localRefs,this.meta=t.meta,this.$async=r==null?void 0:r.$async,this.refs={}}}zs.SchemaEnv=sC;function d3(e){const t=rne.call(this,e);if(t)return t;const n=(0,ka.getFullPath)(this.opts.uriResolver,e.root.baseId),{es5:r,lines:i}=this.opts.code,{ownProperties:s}=this.opts,o=new Ea.CodeGen(this.scope,{es5:r,lines:i,ownProperties:s});let a;e.$async&&(a=o.scopeValue("Error",{ref:F$e.default,code:(0,Ea._)`require("ajv/dist/runtime/validation_error").default`}));const u=o.scopeName("validate");e.validateName=u;const l={gen:o,allErrors:this.opts.allErrors,data:ld.default.data,parentData:ld.default.parentData,parentDataProperty:ld.default.parentDataProperty,dataNames:[ld.default.data],dataPathArr:[Ea.nil],dataLevel:0,dataTypes:[],definedProperties:new Set,topSchemaRef:o.scopeValue("schema",this.opts.code.source===!0?{ref:e.schema,code:(0,Ea.stringify)(e.schema)}:{ref:e.schema}),validateName:u,ValidationError:a,schema:e.schema,schemaEnv:e,rootId:n,baseId:e.baseId||n,schemaPath:Ea.nil,errSchemaPath:e.schemaPath||(this.opts.jtd?"":"#"),errorPath:(0,Ea._)`""`,opts:this.opts,self:this};let c;try{this._compilations.add(e),(0,B$e.validateFunctionCode)(l),o.optimize(this.opts.code.optimize);const f=o.toString();c=`${o.scopeRefs(ld.default.scope)}return ${f}`,this.opts.code.process&&(c=this.opts.code.process(c,e));const h=new Function(`${ld.default.self}`,`${ld.default.scope}`,c)(this,this.scope.get());if(this.scope.value(u,{ref:h}),h.errors=null,h.schema=e.schema,h.schemaEnv=e,e.$async&&(h.$async=!0),this.opts.code.source===!0&&(h.source={validateName:u,validateCode:f,scopeValues:o._values}),this.opts.unevaluated){const{props:p,items:m}=l;h.evaluated={props:p instanceof Ea.Name?void 0:p,items:m instanceof Ea.Name?void 0:m,dynamicProps:p instanceof Ea.Name,dynamicItems:m instanceof Ea.Name},h.source&&(h.source.evaluated=(0,Ea.stringify)(h.evaluated))}return e.validate=h,e}catch(f){throw delete e.validate,delete e.validateName,c&&this.logger.error("Error compiling schema, function code:",c),f}finally{this._compilations.delete(e)}}zs.compileSchema=d3;function j$e(e,t,n){var r;n=(0,ka.resolveUrl)(this.opts.uriResolver,t,n);const i=e.refs[n];if(i)return i;let s=z$e.call(this,e,n);if(s===void 0){const o=(r=e.localRefs)===null||r===void 0?void 0:r[n],{schemaId:a}=this.opts;o&&(s=new sC({schema:o,schemaId:a,root:e,baseId:t}))}if(s!==void 0)return e.refs[n]=U$e.call(this,s)}zs.resolveRef=j$e;function U$e(e){return(0,ka.inlineRef)(e.schema,this.opts.inlineRefs)?e.schema:e.validate?e:d3.call(this,e)}function rne(e){for(const t of this._compilations)if(V$e(t,e))return t}zs.getCompilingSchema=rne;function V$e(e,t){return e.schema===t.schema&&e.root===t.root&&e.baseId===t.baseId}function z$e(e,t){let n;for(;typeof(n=this.refs[t])=="string";)t=n;return n||this.schemas[t]||oC.call(this,e,t)}function oC(e,t){const n=this.opts.uriResolver.parse(t),r=(0,ka._getFullPath)(this.opts.uriResolver,n);let i=(0,ka.getFullPath)(this.opts.uriResolver,e.baseId,void 0);if(Object.keys(e.schema).length>0&&r===i)return tO.call(this,n,e);const s=(0,ka.normalizeId)(r),o=this.refs[s]||this.schemas[s];if(typeof o=="string"){const a=oC.call(this,e,o);return typeof(a==null?void 0:a.schema)!="object"?void 0:tO.call(this,n,a)}if(typeof(o==null?void 0:o.schema)=="object"){if(o.validate||d3.call(this,o),s===(0,ka.normalizeId)(t)){const{schema:a}=o,{schemaId:u}=this.opts,l=a[u];return l&&(i=(0,ka.resolveUrl)(this.opts.uriResolver,i,l)),new sC({schema:a,schemaId:u,root:e,baseId:i})}return tO.call(this,n,o)}}zs.resolveSchema=oC;const H$e=new Set(["properties","patternProperties","enum","dependencies","definitions"]);function tO(e,{baseId:t,schema:n,root:r}){var i;if(((i=e.fragment)===null||i===void 0?void 0:i[0])!=="/")return;for(const a of e.fragment.slice(1).split("/")){if(typeof n=="boolean")return;const u=n[(0,IU.unescapeFragment)(a)];if(u===void 0)return;n=u;const l=typeof n=="object"&&n[this.opts.schemaId];!H$e.has(a)&&l&&(t=(0,ka.resolveUrl)(this.opts.uriResolver,t,l))}let s;if(typeof n!="boolean"&&n.$ref&&!(0,IU.schemaHasRulesButRef)(n,this.RULES)){const a=(0,ka.resolveUrl)(this.opts.uriResolver,t,n.$ref);s=oC.call(this,r,a)}const{schemaId:o}=this.opts;if(s=s||new sC({schema:n,schemaId:o,root:r,baseId:t}),s.schema!==s.root.schema)return s}const W$e="https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#",q$e="Meta-schema for $data reference (JSON AnySchema extension proposal)",G$e="object",Y$e=["$data"],K$e={$data:{type:"string",anyOf:[{format:"relative-json-pointer"},{format:"json-pointer"}]}},Q$e=!1,X$e={$id:W$e,description:q$e,type:G$e,required:Y$e,properties:K$e,additionalProperties:Q$e};var h3={},aN={exports:{}};/** @license URI.js v4.4.1 (c) 2011 Gary Court. License: http://github.com/garycourt/uri-js */(function(e,t){(function(n,r){r(t)})(_o,function(n){function r(){for(var X=arguments.length,z=Array(X),Z=0;Z1){z[0]=z[0].slice(0,-1);for(var he=z.length-1,pe=1;pe= 0x80 (not a basic code point)","invalid-input":"Invalid input"},L=m-y,B=Math.floor,J=String.fromCharCode;function V(X){throw new RangeError(F[X])}function re(X,z){for(var Z=[],he=X.length;he--;)Z[he]=z(X[he]);return Z}function oe(X,z){var Z=X.split("@"),he="";Z.length>1&&(he=Z[0]+"@",X=Z[1]),X=X.replace(R,".");var pe=X.split("."),Ye=re(pe,z).join(".");return he+Ye}function ae(X){for(var z=[],Z=0,he=X.length;Z=55296&&pe<=56319&&Z>1,z+=B(z/Z);z>L*g>>1;pe+=m)z=B(z/L);return B(pe+(L+1)*z/(z+v))},Q=function(z){var Z=[],he=z.length,pe=0,Ye=T,Qe=S,xe=z.lastIndexOf(E);xe<0&&(xe=0);for(var et=0;et=128&&V("not-basic"),Z.push(z.charCodeAt(et));for(var Ft=xe>0?xe+1:0;Ft=he&&V("invalid-input");var mt=ue(z.charCodeAt(Ft++));(mt>=m||mt>B((p-pe)/Jt))&&V("overflow"),pe+=mt*Jt;var kn=Zt<=Qe?y:Zt>=Qe+g?g:Zt-Qe;if(mtB(p/Vn)&&V("overflow"),Jt*=Vn}var Tt=Z.length+1;Qe=W(pe-Be,Tt,Be==0),B(pe/Tt)>p-Ye&&V("overflow"),Ye+=B(pe/Tt),pe%=Tt,Z.splice(pe++,0,Ye)}return String.fromCodePoint.apply(String,Z)},x=function(z){var Z=[];z=ae(z);var he=z.length,pe=T,Ye=0,Qe=S,xe=!0,et=!1,Ft=void 0;try{for(var Be=z[Symbol.iterator](),Jt;!(xe=(Jt=Be.next()).done);xe=!0){var Zt=Jt.value;Zt<128&&Z.push(J(Zt))}}catch(be){et=!0,Ft=be}finally{try{!xe&&Be.return&&Be.return()}finally{if(et)throw Ft}}var mt=Z.length,kn=mt;for(mt&&Z.push(E);kn=pe&&EiB((p-Ye)/Ur)&&V("overflow"),Ye+=(Vn-pe)*Ur,pe=Vn;var Vi=!0,zi=!1,We=void 0;try{for(var en=z[Symbol.iterator](),Hi;!(Vi=(Hi=en.next()).done);Vi=!0){var k=Hi.value;if(kp&&V("overflow"),k==pe){for(var K=Ye,j=m;;j+=m){var te=j<=Qe?y:j>=Qe+g?g:j-Qe;if(K>6|192).toString(16).toUpperCase()+"%"+(z&63|128).toString(16).toUpperCase():Z="%"+(z>>12|224).toString(16).toUpperCase()+"%"+(z>>6&63|128).toString(16).toUpperCase()+"%"+(z&63|128).toString(16).toUpperCase(),Z}function de(X){for(var z="",Z=0,he=X.length;Z=194&&pe<224){if(he-Z>=6){var Ye=parseInt(X.substr(Z+4,2),16);z+=String.fromCharCode((pe&31)<<6|Ye&63)}else z+=X.substr(Z,6);Z+=6}else if(pe>=224){if(he-Z>=9){var Qe=parseInt(X.substr(Z+4,2),16),xe=parseInt(X.substr(Z+7,2),16);z+=String.fromCharCode((pe&15)<<12|(Qe&63)<<6|xe&63)}else z+=X.substr(Z,9);Z+=9}else z+=X.substr(Z,3),Z+=3}return z}function ve(X,z){function Z(he){var pe=de(he);return pe.match(z.UNRESERVED)?pe:he}return X.scheme&&(X.scheme=String(X.scheme).replace(z.PCT_ENCODED,Z).toLowerCase().replace(z.NOT_SCHEME,"")),X.userinfo!==void 0&&(X.userinfo=String(X.userinfo).replace(z.PCT_ENCODED,Z).replace(z.NOT_USERINFO,fe).replace(z.PCT_ENCODED,o)),X.host!==void 0&&(X.host=String(X.host).replace(z.PCT_ENCODED,Z).toLowerCase().replace(z.NOT_HOST,fe).replace(z.PCT_ENCODED,o)),X.path!==void 0&&(X.path=String(X.path).replace(z.PCT_ENCODED,Z).replace(X.scheme?z.NOT_PATH:z.NOT_PATH_NOSCHEME,fe).replace(z.PCT_ENCODED,o)),X.query!==void 0&&(X.query=String(X.query).replace(z.PCT_ENCODED,Z).replace(z.NOT_QUERY,fe).replace(z.PCT_ENCODED,o)),X.fragment!==void 0&&(X.fragment=String(X.fragment).replace(z.PCT_ENCODED,Z).replace(z.NOT_FRAGMENT,fe).replace(z.PCT_ENCODED,o)),X}function Ee(X){return X.replace(/^0*(.*)/,"$1")||"0"}function ge(X,z){var Z=X.match(z.IPV4ADDRESS)||[],he=d(Z,2),pe=he[1];return pe?pe.split(".").map(Ee).join("."):X}function nt(X,z){var Z=X.match(z.IPV6ADDRESS)||[],he=d(Z,3),pe=he[1],Ye=he[2];if(pe){for(var Qe=pe.toLowerCase().split("::").reverse(),xe=d(Qe,2),et=xe[0],Ft=xe[1],Be=Ft?Ft.split(":").map(Ee):[],Jt=et.split(":").map(Ee),Zt=z.IPV4ADDRESS.test(Jt[Jt.length-1]),mt=Zt?7:8,kn=Jt.length-mt,Vn=Array(mt),Tt=0;Tt1){var ds=Vn.slice(0,Er.index),Ei=Vn.slice(Er.index+Er.length);kr=ds.join(":")+"::"+Ei.join(":")}else kr=Vn.join(":");return Ye&&(kr+="%"+Ye),kr}else return X}var Je=/^(?:([^:\/?#]+):)?(?:\/\/((?:([^\/?#@]*)@)?(\[[^\/?#\]]+\]|[^\/?#:]*)(?:\:(\d*))?))?([^?#]*)(?:\?([^#]*))?(?:#((?:.|\n|\r)*))?/i,yt="".match(/(){0}/)[1]===void 0;function ke(X){var z=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},Z={},he=z.iri!==!1?f:c;z.reference==="suffix"&&(X=(z.scheme?z.scheme+":":"")+"//"+X);var pe=X.match(Je);if(pe){yt?(Z.scheme=pe[1],Z.userinfo=pe[3],Z.host=pe[4],Z.port=parseInt(pe[5],10),Z.path=pe[6]||"",Z.query=pe[7],Z.fragment=pe[8],isNaN(Z.port)&&(Z.port=pe[5])):(Z.scheme=pe[1]||void 0,Z.userinfo=X.indexOf("@")!==-1?pe[3]:void 0,Z.host=X.indexOf("//")!==-1?pe[4]:void 0,Z.port=parseInt(pe[5],10),Z.path=pe[6]||"",Z.query=X.indexOf("?")!==-1?pe[7]:void 0,Z.fragment=X.indexOf("#")!==-1?pe[8]:void 0,isNaN(Z.port)&&(Z.port=X.match(/\/\/(?:.|\n)*\:(?:\/|\?|\#|$)/)?pe[4]:void 0)),Z.host&&(Z.host=nt(ge(Z.host,he),he)),Z.scheme===void 0&&Z.userinfo===void 0&&Z.host===void 0&&Z.port===void 0&&!Z.path&&Z.query===void 0?Z.reference="same-document":Z.scheme===void 0?Z.reference="relative":Z.fragment===void 0?Z.reference="absolute":Z.reference="uri",z.reference&&z.reference!=="suffix"&&z.reference!==Z.reference&&(Z.error=Z.error||"URI is not a "+z.reference+" reference.");var Ye=ce[(z.scheme||Z.scheme||"").toLowerCase()];if(!z.unicodeSupport&&(!Ye||!Ye.unicodeSupport)){if(Z.host&&(z.domainHost||Ye&&Ye.domainHost))try{Z.host=q.toASCII(Z.host.replace(he.PCT_ENCODED,de).toLowerCase())}catch(Qe){Z.error=Z.error||"Host's domain name can not be converted to ASCII via punycode: "+Qe}ve(Z,c)}else ve(Z,he);Ye&&Ye.parse&&Ye.parse(Z,z)}else Z.error=Z.error||"URI can not be parsed.";return Z}function at(X,z){var Z=z.iri!==!1?f:c,he=[];return X.userinfo!==void 0&&(he.push(X.userinfo),he.push("@")),X.host!==void 0&&he.push(nt(ge(String(X.host),Z),Z).replace(Z.IPV6ADDRESS,function(pe,Ye,Qe){return"["+Ye+(Qe?"%25"+Qe:"")+"]"})),(typeof X.port=="number"||typeof X.port=="string")&&(he.push(":"),he.push(String(X.port))),he.length?he.join(""):void 0}var St=/^\.\.?\//,cn=/^\/\.(\/|$)/,bn=/^\/\.\.(\/|$)/,He=/^\/?(?:.|\n)*?(?=\/|$)/;function Fe(X){for(var z=[];X.length;)if(X.match(St))X=X.replace(St,"");else if(X.match(cn))X=X.replace(cn,"/");else if(X.match(bn))X=X.replace(bn,"/"),z.pop();else if(X==="."||X==="..")X="";else{var Z=X.match(He);if(Z){var he=Z[0];X=X.slice(he.length),z.push(he)}else throw new Error("Unexpected dot segment condition")}return z.join("")}function st(X){var z=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},Z=z.iri?f:c,he=[],pe=ce[(z.scheme||X.scheme||"").toLowerCase()];if(pe&&pe.serialize&&pe.serialize(X,z),X.host&&!Z.IPV6ADDRESS.test(X.host)){if(z.domainHost||pe&&pe.domainHost)try{X.host=z.iri?q.toUnicode(X.host):q.toASCII(X.host.replace(Z.PCT_ENCODED,de).toLowerCase())}catch(xe){X.error=X.error||"Host's domain name can not be converted to "+(z.iri?"Unicode":"ASCII")+" via punycode: "+xe}}ve(X,Z),z.reference!=="suffix"&&X.scheme&&(he.push(X.scheme),he.push(":"));var Ye=at(X,z);if(Ye!==void 0&&(z.reference!=="suffix"&&he.push("//"),he.push(Ye),X.path&&X.path.charAt(0)!=="/"&&he.push("/")),X.path!==void 0){var Qe=X.path;!z.absolutePath&&(!pe||!pe.absolutePath)&&(Qe=Fe(Qe)),Ye===void 0&&(Qe=Qe.replace(/^\/\//,"/%2F")),he.push(Qe)}return X.query!==void 0&&(he.push("?"),he.push(X.query)),X.fragment!==void 0&&(he.push("#"),he.push(X.fragment)),he.join("")}function dt(X,z){var Z=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},he=arguments[3],pe={};return he||(X=ke(st(X,Z),Z),z=ke(st(z,Z),Z)),Z=Z||{},!Z.tolerant&&z.scheme?(pe.scheme=z.scheme,pe.userinfo=z.userinfo,pe.host=z.host,pe.port=z.port,pe.path=Fe(z.path||""),pe.query=z.query):(z.userinfo!==void 0||z.host!==void 0||z.port!==void 0?(pe.userinfo=z.userinfo,pe.host=z.host,pe.port=z.port,pe.path=Fe(z.path||""),pe.query=z.query):(z.path?(z.path.charAt(0)==="/"?pe.path=Fe(z.path):((X.userinfo!==void 0||X.host!==void 0||X.port!==void 0)&&!X.path?pe.path="/"+z.path:X.path?pe.path=X.path.slice(0,X.path.lastIndexOf("/")+1)+z.path:pe.path=z.path,pe.path=Fe(pe.path)),pe.query=z.query):(pe.path=X.path,z.query!==void 0?pe.query=z.query:pe.query=X.query),pe.userinfo=X.userinfo,pe.host=X.host,pe.port=X.port),pe.scheme=X.scheme),pe.fragment=z.fragment,pe}function At(X,z,Z){var he=u({scheme:"null"},Z);return st(dt(ke(X,he),ke(z,he),he,!0),he)}function Kt(X,z){return typeof X=="string"?X=st(ke(X,z),z):s(X)==="object"&&(X=ke(st(X,z),z)),X}function me(X,z,Z){return typeof X=="string"?X=st(ke(X,Z),Z):s(X)==="object"&&(X=st(X,Z)),typeof z=="string"?z=st(ke(z,Z),Z):s(z)==="object"&&(z=st(z,Z)),X===z}function Se(X,z){return X&&X.toString().replace(!z||!z.iri?c.ESCAPE:f.ESCAPE,fe)}function Le(X,z){return X&&X.toString().replace(!z||!z.iri?c.PCT_ENCODED:f.PCT_ENCODED,de)}var Ke={scheme:"http",domainHost:!0,parse:function(z,Z){return z.host||(z.error=z.error||"HTTP URIs must have a host."),z},serialize:function(z,Z){var he=String(z.scheme).toLowerCase()==="https";return(z.port===(he?443:80)||z.port==="")&&(z.port=void 0),z.path||(z.path="/"),z}},ct={scheme:"https",domainHost:Ke.domainHost,parse:Ke.parse,serialize:Ke.serialize};function In(X){return typeof X.secure=="boolean"?X.secure:String(X.scheme).toLowerCase()==="wss"}var Me={scheme:"ws",domainHost:!0,parse:function(z,Z){var he=z;return he.secure=In(he),he.resourceName=(he.path||"/")+(he.query?"?"+he.query:""),he.path=void 0,he.query=void 0,he},serialize:function(z,Z){if((z.port===(In(z)?443:80)||z.port==="")&&(z.port=void 0),typeof z.secure=="boolean"&&(z.scheme=z.secure?"wss":"ws",z.secure=void 0),z.resourceName){var he=z.resourceName.split("?"),pe=d(he,2),Ye=pe[0],Qe=pe[1];z.path=Ye&&Ye!=="/"?Ye:void 0,z.query=Qe,z.resourceName=void 0}return z.fragment=void 0,z}},Ze={scheme:"wss",domainHost:Me.domainHost,parse:Me.parse,serialize:Me.serialize},ot={},Gt="[A-Za-z0-9\\-\\.\\_\\~\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF]",pt="[0-9A-Fa-f]",_r=i(i("%[EFef]"+pt+"%"+pt+pt+"%"+pt+pt)+"|"+i("%[89A-Fa-f]"+pt+"%"+pt+pt)+"|"+i("%"+pt+pt)),mn="[A-Za-z0-9\\!\\$\\%\\'\\*\\+\\-\\^\\_\\`\\{\\|\\}\\~]",qn="[\\!\\$\\%\\'\\(\\)\\*\\+\\,\\-\\.0-9\\<\\>A-Z\\x5E-\\x7E]",cs=r(qn,'[\\"\\\\]'),xs="[\\!\\$\\'\\(\\)\\*\\+\\,\\;\\:\\@]",ui=new RegExp(Gt,"g"),Nn=new RegExp(_r,"g"),ba=new RegExp(r("[^]",mn,"[\\.]",'[\\"]',cs),"g"),Nr=new RegExp(r("[^]",Gt,xs),"g"),br=Nr;function $n(X){var z=de(X);return z.match(ui)?z:X}var fn={scheme:"mailto",parse:function(z,Z){var he=z,pe=he.to=he.path?he.path.split(","):[];if(he.path=void 0,he.query){for(var Ye=!1,Qe={},xe=he.query.split("&"),et=0,Ft=xe.length;etnew RegExp(P,W);h.code="new RegExp";const p=["removeAdditional","useDefaults","coerceTypes"],m=new Set(["validate","serialize","parse","wrapper","root","schema","keyword","pattern","formats","validate$data","func","obj","Error"]),y={errorDataPath:"",format:"`validateFormats: false` can be used instead.",nullable:'"nullable" keyword is supported by default.',jsonPointers:"Deprecated jsPropertySyntax can be used instead.",extendRefs:"Deprecated ignoreKeywordsWithRef can be used instead.",missingRefs:"Pass empty schema with $id that should be ignored to ajv.addSchema.",processCode:"Use option `code: {process: (code, schemaEnv: object) => string}`",sourceCode:"Use option `code: {source: true}`",strictDefaults:"It is default now, see option `strict`.",strictKeywords:"It is default now, see option `strict`.",uniqueItems:'"uniqueItems" keyword is always validated.',unknownFormats:"Disable strict mode or pass `true` to `ajv.addFormat` (or `formats` option).",cache:"Map is used as cache, schema object as key.",serialize:"Map is used as cache, schema object as key.",ajvErrors:"It is default now."},g={ignoreKeywordsWithRef:"",jsPropertySyntax:"",unicode:'"minLength"/"maxLength" account for unicode characters by default.'},v=200;function b(P){var W,Q,x,O,$,q,ce,fe,de,ve,Ee,ge,nt,Je,yt,ke,at,St,cn,bn,He,Fe,st,dt,At;const Kt=P.strict,me=(W=P.code)===null||W===void 0?void 0:W.optimize,Se=me===!0||me===void 0?1:me||0,Le=(x=(Q=P.code)===null||Q===void 0?void 0:Q.regExp)!==null&&x!==void 0?x:h,Ke=(O=P.uriResolver)!==null&&O!==void 0?O:d.default;return{strictSchema:(q=($=P.strictSchema)!==null&&$!==void 0?$:Kt)!==null&&q!==void 0?q:!0,strictNumbers:(fe=(ce=P.strictNumbers)!==null&&ce!==void 0?ce:Kt)!==null&&fe!==void 0?fe:!0,strictTypes:(ve=(de=P.strictTypes)!==null&&de!==void 0?de:Kt)!==null&&ve!==void 0?ve:"log",strictTuples:(ge=(Ee=P.strictTuples)!==null&&Ee!==void 0?Ee:Kt)!==null&&ge!==void 0?ge:"log",strictRequired:(Je=(nt=P.strictRequired)!==null&&nt!==void 0?nt:Kt)!==null&&Je!==void 0?Je:!1,code:P.code?{...P.code,optimize:Se,regExp:Le}:{optimize:Se,regExp:Le},loopRequired:(yt=P.loopRequired)!==null&&yt!==void 0?yt:v,loopEnum:(ke=P.loopEnum)!==null&&ke!==void 0?ke:v,meta:(at=P.meta)!==null&&at!==void 0?at:!0,messages:(St=P.messages)!==null&&St!==void 0?St:!0,inlineRefs:(cn=P.inlineRefs)!==null&&cn!==void 0?cn:!0,schemaId:(bn=P.schemaId)!==null&&bn!==void 0?bn:"$id",addUsedSchema:(He=P.addUsedSchema)!==null&&He!==void 0?He:!0,validateSchema:(Fe=P.validateSchema)!==null&&Fe!==void 0?Fe:!0,validateFormats:(st=P.validateFormats)!==null&&st!==void 0?st:!0,unicodeRegExp:(dt=P.unicodeRegExp)!==null&&dt!==void 0?dt:!0,int32range:(At=P.int32range)!==null&&At!==void 0?At:!0,uriResolver:Ke}}class S{constructor(W={}){this.schemas={},this.refs={},this.formats={},this._compilations=new Set,this._loading={},this._cache=new Map,W=this.opts={...W,...b(W)};const{es5:Q,lines:x}=this.opts.code;this.scope=new a.ValueScope({scope:{},prefixes:m,es5:Q,lines:x}),this.logger=B(W.logger);const O=W.validateFormats;W.validateFormats=!1,this.RULES=(0,s.getRules)(),T.call(this,y,W,"NOT SUPPORTED"),T.call(this,g,W,"DEPRECATED","warn"),this._metaOpts=F.call(this),W.formats&&A.call(this),this._addVocabularies(),this._addDefaultMetaSchema(),W.keywords&&R.call(this,W.keywords),typeof W.meta=="object"&&this.addMetaSchema(W.meta),I.call(this),W.validateFormats=O}_addVocabularies(){this.addKeyword("$async")}_addDefaultMetaSchema(){const{$data:W,meta:Q,schemaId:x}=this.opts;let O=f;x==="id"&&(O={...f},O.id=O.$id,delete O.$id),Q&&W&&this.addMetaSchema(O,O[x],!1)}defaultMeta(){const{meta:W,schemaId:Q}=this.opts;return this.opts.defaultMeta=typeof W=="object"?W[Q]||W:void 0}validate(W,Q){let x;if(typeof W=="string"){if(x=this.getSchema(W),!x)throw new Error(`no schema with key or ref "${W}"`)}else x=this.compile(W);const O=x(Q);return"$async"in x||(this.errors=x.errors),O}compile(W,Q){const x=this._addSchema(W,Q);return x.validate||this._compileSchemaEnv(x)}compileAsync(W,Q){if(typeof this.opts.loadSchema!="function")throw new Error("options.loadSchema should be a function");const{loadSchema:x}=this.opts;return O.call(this,W,Q);async function O(ve,Ee){await $.call(this,ve.$schema);const ge=this._addSchema(ve,Ee);return ge.validate||q.call(this,ge)}async function $(ve){ve&&!this.getSchema(ve)&&await O.call(this,{$ref:ve},!0)}async function q(ve){try{return this._compileSchemaEnv(ve)}catch(Ee){if(!(Ee instanceof i.default))throw Ee;return ce.call(this,Ee),await fe.call(this,Ee.missingSchema),q.call(this,ve)}}function ce({missingSchema:ve,missingRef:Ee}){if(this.refs[ve])throw new Error(`AnySchema ${ve} is loaded but ${Ee} cannot be resolved`)}async function fe(ve){const Ee=await de.call(this,ve);this.refs[ve]||await $.call(this,Ee.$schema),this.refs[ve]||this.addSchema(Ee,ve,Q)}async function de(ve){const Ee=this._loading[ve];if(Ee)return Ee;try{return await(this._loading[ve]=x(ve))}finally{delete this._loading[ve]}}}addSchema(W,Q,x,O=this.opts.validateSchema){if(Array.isArray(W)){for(const q of W)this.addSchema(q,void 0,x,O);return this}let $;if(typeof W=="object"){const{schemaId:q}=this.opts;if($=W[q],$!==void 0&&typeof $!="string")throw new Error(`schema ${q} must be string`)}return Q=(0,u.normalizeId)(Q||$),this._checkUnique(Q),this.schemas[Q]=this._addSchema(W,x,Q,O,!0),this}addMetaSchema(W,Q,x=this.opts.validateSchema){return this.addSchema(W,Q,!0,x),this}validateSchema(W,Q){if(typeof W=="boolean")return!0;let x;if(x=W.$schema,x!==void 0&&typeof x!="string")throw new Error("$schema must be a string");if(x=x||this.opts.defaultMeta||this.defaultMeta(),!x)return this.logger.warn("meta-schema not available"),this.errors=null,!0;const O=this.validate(x,W);if(!O&&Q){const $="schema is invalid: "+this.errorsText();if(this.opts.validateSchema==="log")this.logger.error($);else throw new Error($)}return O}getSchema(W){let Q;for(;typeof(Q=E.call(this,W))=="string";)W=Q;if(Q===void 0){const{schemaId:x}=this.opts,O=new o.SchemaEnv({schema:{},schemaId:x});if(Q=o.resolveSchema.call(this,O,W),!Q)return;this.refs[W]=Q}return Q.validate||this._compileSchemaEnv(Q)}removeSchema(W){if(W instanceof RegExp)return this._removeAllSchemas(this.schemas,W),this._removeAllSchemas(this.refs,W),this;switch(typeof W){case"undefined":return this._removeAllSchemas(this.schemas),this._removeAllSchemas(this.refs),this._cache.clear(),this;case"string":{const Q=E.call(this,W);return typeof Q=="object"&&this._cache.delete(Q.schema),delete this.schemas[W],delete this.refs[W],this}case"object":{const Q=W;this._cache.delete(Q);let x=W[this.opts.schemaId];return x&&(x=(0,u.normalizeId)(x),delete this.schemas[x],delete this.refs[x]),this}default:throw new Error("ajv.removeSchema: invalid parameter")}}addVocabulary(W){for(const Q of W)this.addKeyword(Q);return this}addKeyword(W,Q){let x;if(typeof W=="string")x=W,typeof Q=="object"&&(this.logger.warn("these parameters are deprecated, see docs for addKeyword"),Q.keyword=x);else if(typeof W=="object"&&Q===void 0){if(Q=W,x=Q.keyword,Array.isArray(x)&&!x.length)throw new Error("addKeywords: keyword must be string or non-empty array")}else throw new Error("invalid addKeywords parameters");if(V.call(this,x,Q),!Q)return(0,c.eachItem)(x,$=>re.call(this,$)),this;ae.call(this,Q);const O={...Q,type:(0,l.getJSONTypes)(Q.type),schemaType:(0,l.getJSONTypes)(Q.schemaType)};return(0,c.eachItem)(x,O.type.length===0?$=>re.call(this,$,O):$=>O.type.forEach(q=>re.call(this,$,O,q))),this}getKeyword(W){const Q=this.RULES.all[W];return typeof Q=="object"?Q.definition:!!Q}removeKeyword(W){const{RULES:Q}=this;delete Q.keywords[W],delete Q.all[W];for(const x of Q.rules){const O=x.rules.findIndex($=>$.keyword===W);O>=0&&x.rules.splice(O,1)}return this}addFormat(W,Q){return typeof Q=="string"&&(Q=new RegExp(Q)),this.formats[W]=Q,this}errorsText(W=this.errors,{separator:Q=", ",dataVar:x="data"}={}){return!W||W.length===0?"No errors":W.map(O=>`${x}${O.instancePath} ${O.message}`).reduce((O,$)=>O+Q+$)}$dataMetaSchema(W,Q){const x=this.RULES.all;W=JSON.parse(JSON.stringify(W));for(const O of Q){const $=O.split("/").slice(1);let q=W;for(const ce of $)q=q[ce];for(const ce in x){const fe=x[ce];if(typeof fe!="object")continue;const{$data:de}=fe.definition,ve=q[ce];de&&ve&&(q[ce]=ue(ve))}}return W}_removeAllSchemas(W,Q){for(const x in W){const O=W[x];(!Q||Q.test(x))&&(typeof O=="string"?delete W[x]:O&&!O.meta&&(this._cache.delete(O.schema),delete W[x]))}}_addSchema(W,Q,x,O=this.opts.validateSchema,$=this.opts.addUsedSchema){let q;const{schemaId:ce}=this.opts;if(typeof W=="object")q=W[ce];else{if(this.opts.jtd)throw new Error("schema must be object");if(typeof W!="boolean")throw new Error("schema must be object or boolean")}let fe=this._cache.get(W);if(fe!==void 0)return fe;x=(0,u.normalizeId)(q||x);const de=u.getSchemaRefs.call(this,W,x);return fe=new o.SchemaEnv({schema:W,schemaId:ce,meta:Q,baseId:x,localRefs:de}),this._cache.set(fe.schema,fe),$&&!x.startsWith("#")&&(x&&this._checkUnique(x),this.refs[x]=fe),O&&this.validateSchema(W,!0),fe}_checkUnique(W){if(this.schemas[W]||this.refs[W])throw new Error(`schema with key or id "${W}" already exists`)}_compileSchemaEnv(W){if(W.meta?this._compileMetaSchema(W):o.compileSchema.call(this,W),!W.validate)throw new Error("ajv implementation error");return W.validate}_compileMetaSchema(W){const Q=this.opts;this.opts=this._metaOpts;try{o.compileSchema.call(this,W)}finally{this.opts=Q}}}e.default=S,S.ValidationError=r.default,S.MissingRefError=i.default;function T(P,W,Q,x="error"){for(const O in P){const $=O;$ in W&&this.logger[x](`${Q}: option ${O}. ${P[$]}`)}}function E(P){return P=(0,u.normalizeId)(P),this.schemas[P]||this.refs[P]}function I(){const P=this.opts.schemas;if(P)if(Array.isArray(P))this.addSchema(P);else for(const W in P)this.addSchema(P[W],W)}function A(){for(const P in this.opts.formats){const W=this.opts.formats[P];W&&this.addFormat(P,W)}}function R(P){if(Array.isArray(P)){this.addVocabulary(P);return}this.logger.warn("keywords option as map is deprecated, pass array");for(const W in P){const Q=P[W];Q.keyword||(Q.keyword=W),this.addKeyword(Q)}}function F(){const P={...this.opts};for(const W of p)delete P[W];return P}const L={log(){},warn(){},error(){}};function B(P){if(P===!1)return L;if(P===void 0)return console;if(P.log&&P.warn&&P.error)return P;throw new Error("logger must implement log, warn and error methods")}const J=/^[a-z_$][a-z0-9_$:-]*$/i;function V(P,W){const{RULES:Q}=this;if((0,c.eachItem)(P,x=>{if(Q.keywords[x])throw new Error(`Keyword ${x} is already defined`);if(!J.test(x))throw new Error(`Keyword ${x} has invalid name`)}),!!W&&W.$data&&!("code"in W||"validate"in W))throw new Error('$data keyword must have "code" or "validate" function')}function re(P,W,Q){var x;const O=W==null?void 0:W.post;if(Q&&O)throw new Error('keyword with "post" flag cannot have "type"');const{RULES:$}=this;let q=O?$.post:$.rules.find(({type:fe})=>fe===Q);if(q||(q={type:Q,rules:[]},$.rules.push(q)),$.keywords[P]=!0,!W)return;const ce={keyword:P,definition:{...W,type:(0,l.getJSONTypes)(W.type),schemaType:(0,l.getJSONTypes)(W.schemaType)}};W.before?oe.call(this,q,ce,W.before):q.rules.push(ce),$.all[P]=ce,(x=W.implements)===null||x===void 0||x.forEach(fe=>this.addKeyword(fe))}function oe(P,W,Q){const x=P.rules.findIndex(O=>O.keyword===Q);x>=0?P.rules.splice(x,0,W):(P.rules.push(W),this.logger.warn(`rule ${Q} is not defined`))}function ae(P){let{metaSchema:W}=P;W!==void 0&&(P.$data&&this.opts.$data&&(W=ue(W)),P.validateSchema=this.compile(W,!0))}const ee={$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"};function ue(P){return{anyOf:[P,ee]}}})(Dte);var p3={},m3={},g3={};Object.defineProperty(g3,"__esModule",{value:!0});const Z$e={keyword:"id",code(){throw new Error('NOT SUPPORTED: keyword "id", use "$id" for schema ID')}};g3.default=Z$e;var dh={};Object.defineProperty(dh,"__esModule",{value:!0});dh.callRef=dh.getValidate=void 0;const e3e=H_,xU=Qt,ks=Xt,tp=dl,CU=zs,Eb=_n,t3e={keyword:"$ref",schemaType:"string",code(e){const{gen:t,schema:n,it:r}=e,{baseId:i,schemaEnv:s,validateName:o,opts:a,self:u}=r,{root:l}=s;if((n==="#"||n==="#/")&&i===l.baseId)return f();const c=CU.resolveRef.call(u,l,i,n);if(c===void 0)throw new e3e.default(r.opts.uriResolver,i,n);if(c instanceof CU.SchemaEnv)return d(c);return h(c);function f(){if(s===l)return Nw(e,o,s,s.$async);const p=t.scopeValue("root",{ref:l});return Nw(e,(0,ks._)`${p}.validate`,l,l.$async)}function d(p){const m=sne(e,p);Nw(e,m,p,p.$async)}function h(p){const m=t.scopeValue("schema",a.code.source===!0?{ref:p,code:(0,ks.stringify)(p)}:{ref:p}),y=t.name("valid"),g=e.subschema({schema:p,dataTypes:[],schemaPath:ks.nil,topSchemaRef:m,errSchemaPath:n},y);e.mergeEvaluated(g),e.ok(y)}}};function sne(e,t){const{gen:n}=e;return t.validate?n.scopeValue("validate",{ref:t.validate}):(0,ks._)`${n.scopeValue("wrapper",{ref:t})}.validate`}dh.getValidate=sne;function Nw(e,t,n,r){const{gen:i,it:s}=e,{allErrors:o,schemaEnv:a,opts:u}=s,l=u.passContext?tp.default.this:ks.nil;r?c():f();function c(){if(!a.$async)throw new Error("async schema referenced by sync schema");const p=i.let("valid");i.try(()=>{i.code((0,ks._)`await ${(0,xU.callValidateCode)(e,t,l)}`),h(t),o||i.assign(p,!0)},m=>{i.if((0,ks._)`!(${m} instanceof ${s.ValidationError})`,()=>i.throw(m)),d(m),o||i.assign(p,!1)}),e.ok(p)}function f(){e.result((0,xU.callValidateCode)(e,t,l),()=>h(t),()=>d(t))}function d(p){const m=(0,ks._)`${p}.errors`;i.assign(tp.default.vErrors,(0,ks._)`${tp.default.vErrors} === null ? ${m} : ${tp.default.vErrors}.concat(${m})`),i.assign(tp.default.errors,(0,ks._)`${tp.default.vErrors}.length`)}function h(p){var m;if(!s.opts.unevaluated)return;const y=(m=n==null?void 0:n.validate)===null||m===void 0?void 0:m.evaluated;if(s.props!==!0)if(y&&!y.dynamicProps)y.props!==void 0&&(s.props=Eb.mergeEvaluated.props(i,y.props,s.props));else{const g=i.var("props",(0,ks._)`${p}.evaluated.props`);s.props=Eb.mergeEvaluated.props(i,g,s.props,ks.Name)}if(s.items!==!0)if(y&&!y.dynamicItems)y.items!==void 0&&(s.items=Eb.mergeEvaluated.items(i,y.items,s.items));else{const g=i.var("items",(0,ks._)`${p}.evaluated.items`);s.items=Eb.mergeEvaluated.items(i,g,s.items,ks.Name)}}}dh.callRef=Nw;dh.default=t3e;Object.defineProperty(m3,"__esModule",{value:!0});const n3e=g3,r3e=dh,i3e=["$schema","$id","$defs","$vocabulary",{keyword:"$comment"},"definitions",n3e.default,r3e.default];m3.default=i3e;var y3={},v3={};Object.defineProperty(v3,"__esModule",{value:!0});const IT=Xt,Sc=IT.operators,xT={maximum:{okStr:"<=",ok:Sc.LTE,fail:Sc.GT},minimum:{okStr:">=",ok:Sc.GTE,fail:Sc.LT},exclusiveMaximum:{okStr:"<",ok:Sc.LT,fail:Sc.GTE},exclusiveMinimum:{okStr:">",ok:Sc.GT,fail:Sc.LTE}},s3e={message:({keyword:e,schemaCode:t})=>(0,IT.str)`must be ${xT[e].okStr} ${t}`,params:({keyword:e,schemaCode:t})=>(0,IT._)`{comparison: ${xT[e].okStr}, limit: ${t}}`},o3e={keyword:Object.keys(xT),type:"number",schemaType:"number",$data:!0,error:s3e,code(e){const{keyword:t,data:n,schemaCode:r}=e;e.fail$data((0,IT._)`${n} ${xT[t].fail} ${r} || isNaN(${n})`)}};v3.default=o3e;var _3={};Object.defineProperty(_3,"__esModule",{value:!0});const Ty=Xt,a3e={message:({schemaCode:e})=>(0,Ty.str)`must be multiple of ${e}`,params:({schemaCode:e})=>(0,Ty._)`{multipleOf: ${e}}`},u3e={keyword:"multipleOf",type:"number",schemaType:"number",$data:!0,error:a3e,code(e){const{gen:t,data:n,schemaCode:r,it:i}=e,s=i.opts.multipleOfPrecision,o=t.let("res"),a=s?(0,Ty._)`Math.abs(Math.round(${o}) - ${o}) > 1e-${s}`:(0,Ty._)`${o} !== parseInt(${o})`;e.fail$data((0,Ty._)`(${r} === 0 || (${o} = ${n}/${r}, ${a}))`)}};_3.default=u3e;var b3={},w3={};Object.defineProperty(w3,"__esModule",{value:!0});function one(e){const t=e.length;let n=0,r=0,i;for(;r=55296&&i<=56319&&r(0,Td._)`{limit: ${e}}`},d3e={keyword:["maxLength","minLength"],type:"string",schemaType:"number",$data:!0,error:f3e,code(e){const{keyword:t,data:n,schemaCode:r,it:i}=e,s=t==="maxLength"?Td.operators.GT:Td.operators.LT,o=i.opts.unicode===!1?(0,Td._)`${n}.length`:(0,Td._)`${(0,l3e.useFunc)(e.gen,c3e.default)}(${n})`;e.fail$data((0,Td._)`${o} ${s} ${r}`)}};b3.default=d3e;var E3={};Object.defineProperty(E3,"__esModule",{value:!0});const h3e=Qt,CT=Xt,p3e={message:({schemaCode:e})=>(0,CT.str)`must match pattern "${e}"`,params:({schemaCode:e})=>(0,CT._)`{pattern: ${e}}`},m3e={keyword:"pattern",type:"string",schemaType:"string",$data:!0,error:p3e,code(e){const{data:t,$data:n,schema:r,schemaCode:i,it:s}=e,o=s.opts.unicodeRegExp?"u":"",a=n?(0,CT._)`(new RegExp(${i}, ${o}))`:(0,h3e.usePattern)(e,r);e.fail$data((0,CT._)`!${a}.test(${t})`)}};E3.default=m3e;var S3={};Object.defineProperty(S3,"__esModule",{value:!0});const Iy=Xt,g3e={message({keyword:e,schemaCode:t}){const n=e==="maxProperties"?"more":"fewer";return(0,Iy.str)`must NOT have ${n} than ${t} properties`},params:({schemaCode:e})=>(0,Iy._)`{limit: ${e}}`},y3e={keyword:["maxProperties","minProperties"],type:"object",schemaType:"number",$data:!0,error:g3e,code(e){const{keyword:t,data:n,schemaCode:r}=e,i=t==="maxProperties"?Iy.operators.GT:Iy.operators.LT;e.fail$data((0,Iy._)`Object.keys(${n}).length ${i} ${r}`)}};S3.default=y3e;var T3={};Object.defineProperty(T3,"__esModule",{value:!0});const w0=Qt,xy=Xt,v3e=_n,_3e={message:({params:{missingProperty:e}})=>(0,xy.str)`must have required property '${e}'`,params:({params:{missingProperty:e}})=>(0,xy._)`{missingProperty: ${e}}`},b3e={keyword:"required",type:"object",schemaType:"array",$data:!0,error:_3e,code(e){const{gen:t,schema:n,schemaCode:r,data:i,$data:s,it:o}=e,{opts:a}=o;if(!s&&n.length===0)return;const u=n.length>=a.loopRequired;if(o.allErrors?l():c(),a.strictRequired){const h=e.parentSchema.properties,{definedProperties:p}=e.it;for(const m of n)if((h==null?void 0:h[m])===void 0&&!p.has(m)){const y=o.schemaEnv.baseId+o.errSchemaPath,g=`required property "${m}" is not defined at "${y}" (strictRequired)`;(0,v3e.checkStrictMode)(o,g,o.opts.strictRequired)}}function l(){if(u||s)e.block$data(xy.nil,f);else for(const h of n)(0,w0.checkReportMissingProp)(e,h)}function c(){const h=t.let("missing");if(u||s){const p=t.let("valid",!0);e.block$data(p,()=>d(h,p)),e.ok(p)}else t.if((0,w0.checkMissingProp)(e,n,h)),(0,w0.reportMissingProp)(e,h),t.else()}function f(){t.forOf("prop",r,h=>{e.setParams({missingProperty:h}),t.if((0,w0.noPropertyInData)(t,i,h,a.ownProperties),()=>e.error())})}function d(h,p){e.setParams({missingProperty:h}),t.forOf(h,r,()=>{t.assign(p,(0,w0.propertyInData)(t,i,h,a.ownProperties)),t.if((0,xy.not)(p),()=>{e.error(),t.break()})},xy.nil)}}};T3.default=b3e;var I3={};Object.defineProperty(I3,"__esModule",{value:!0});const Cy=Xt,w3e={message({keyword:e,schemaCode:t}){const n=e==="maxItems"?"more":"fewer";return(0,Cy.str)`must NOT have ${n} than ${t} items`},params:({schemaCode:e})=>(0,Cy._)`{limit: ${e}}`},E3e={keyword:["maxItems","minItems"],type:"array",schemaType:"number",$data:!0,error:w3e,code(e){const{keyword:t,data:n,schemaCode:r}=e,i=t==="maxItems"?Cy.operators.GT:Cy.operators.LT;e.fail$data((0,Cy._)`${n}.length ${i} ${r}`)}};I3.default=E3e;var x3={},W_={};Object.defineProperty(W_,"__esModule",{value:!0});const ane=l3;ane.code='require("ajv/dist/runtime/equal").default';W_.default=ane;Object.defineProperty(x3,"__esModule",{value:!0});const nO=V_,xi=Xt,S3e=_n,T3e=W_,I3e={message:({params:{i:e,j:t}})=>(0,xi.str)`must NOT have duplicate items (items ## ${t} and ${e} are identical)`,params:({params:{i:e,j:t}})=>(0,xi._)`{i: ${e}, j: ${t}}`},x3e={keyword:"uniqueItems",type:"array",schemaType:"boolean",$data:!0,error:I3e,code(e){const{gen:t,data:n,$data:r,schema:i,parentSchema:s,schemaCode:o,it:a}=e;if(!r&&!i)return;const u=t.let("valid"),l=s.items?(0,nO.getSchemaTypes)(s.items):[];e.block$data(u,c,(0,xi._)`${o} === false`),e.ok(u);function c(){const p=t.let("i",(0,xi._)`${n}.length`),m=t.let("j");e.setParams({i:p,j:m}),t.assign(u,!0),t.if((0,xi._)`${p} > 1`,()=>(f()?d:h)(p,m))}function f(){return l.length>0&&!l.some(p=>p==="object"||p==="array")}function d(p,m){const y=t.name("item"),g=(0,nO.checkDataTypes)(l,y,a.opts.strictNumbers,nO.DataType.Wrong),v=t.const("indices",(0,xi._)`{}`);t.for((0,xi._)`;${p}--;`,()=>{t.let(y,(0,xi._)`${n}[${p}]`),t.if(g,(0,xi._)`continue`),l.length>1&&t.if((0,xi._)`typeof ${y} == "string"`,(0,xi._)`${y} += "_"`),t.if((0,xi._)`typeof ${v}[${y}] == "number"`,()=>{t.assign(m,(0,xi._)`${v}[${y}]`),e.error(),t.assign(u,!1).break()}).code((0,xi._)`${v}[${y}] = ${p}`)})}function h(p,m){const y=(0,S3e.useFunc)(t,T3e.default),g=t.name("outer");t.label(g).for((0,xi._)`;${p}--;`,()=>t.for((0,xi._)`${m} = ${p}; ${m}--;`,()=>t.if((0,xi._)`${y}(${n}[${p}], ${n}[${m}])`,()=>{e.error(),t.assign(u,!1).break(g)})))}}};x3.default=x3e;var C3={};Object.defineProperty(C3,"__esModule",{value:!0});const uN=Xt,C3e=_n,A3e=W_,P3e={message:"must be equal to constant",params:({schemaCode:e})=>(0,uN._)`{allowedValue: ${e}}`},O3e={keyword:"const",$data:!0,error:P3e,code(e){const{gen:t,data:n,$data:r,schemaCode:i,schema:s}=e;r||s&&typeof s=="object"?e.fail$data((0,uN._)`!${(0,C3e.useFunc)(t,A3e.default)}(${n}, ${i})`):e.fail((0,uN._)`${s} !== ${n}`)}};C3.default=O3e;var A3={};Object.defineProperty(A3,"__esModule",{value:!0});const K0=Xt,R3e=_n,N3e=W_,k3e={message:"must be equal to one of the allowed values",params:({schemaCode:e})=>(0,K0._)`{allowedValues: ${e}}`},D3e={keyword:"enum",schemaType:"array",$data:!0,error:k3e,code(e){const{gen:t,data:n,$data:r,schema:i,schemaCode:s,it:o}=e;if(!r&&i.length===0)throw new Error("enum must have non-empty array");const a=i.length>=o.opts.loopEnum;let u;const l=()=>u??(u=(0,R3e.useFunc)(t,N3e.default));let c;if(a||r)c=t.let("valid"),e.block$data(c,f);else{if(!Array.isArray(i))throw new Error("ajv implementation error");const h=t.const("vSchema",s);c=(0,K0.or)(...i.map((p,m)=>d(h,m)))}e.pass(c);function f(){t.assign(c,!1),t.forOf("v",s,h=>t.if((0,K0._)`${l()}(${n}, ${h})`,()=>t.assign(c,!0).break()))}function d(h,p){const m=i[p];return typeof m=="object"&&m!==null?(0,K0._)`${l()}(${n}, ${h}[${p}])`:(0,K0._)`${n} === ${m}`}}};A3.default=D3e;Object.defineProperty(y3,"__esModule",{value:!0});const $3e=v3,L3e=_3,M3e=b3,F3e=E3,B3e=S3,j3e=T3,U3e=I3,V3e=x3,z3e=C3,H3e=A3,W3e=[$3e.default,L3e.default,M3e.default,F3e.default,B3e.default,j3e.default,U3e.default,V3e.default,{keyword:"type",schemaType:["string","array"]},{keyword:"nullable",schemaType:"boolean"},z3e.default,H3e.default];y3.default=W3e;var P3={},Eg={};Object.defineProperty(Eg,"__esModule",{value:!0});Eg.validateAdditionalItems=void 0;const Id=Xt,lN=_n,q3e={message:({params:{len:e}})=>(0,Id.str)`must NOT have more than ${e} items`,params:({params:{len:e}})=>(0,Id._)`{limit: ${e}}`},G3e={keyword:"additionalItems",type:"array",schemaType:["boolean","object"],before:"uniqueItems",error:q3e,code(e){const{parentSchema:t,it:n}=e,{items:r}=t;if(!Array.isArray(r)){(0,lN.checkStrictMode)(n,'"additionalItems" is ignored when "items" is not an array of schemas');return}une(e,r)}};function une(e,t){const{gen:n,schema:r,data:i,keyword:s,it:o}=e;o.items=!0;const a=n.const("len",(0,Id._)`${i}.length`);if(r===!1)e.setParams({len:t.length}),e.pass((0,Id._)`${a} <= ${t.length}`);else if(typeof r=="object"&&!(0,lN.alwaysValidSchema)(o,r)){const l=n.var("valid",(0,Id._)`${a} <= ${t.length}`);n.if((0,Id.not)(l),()=>u(l)),e.ok(l)}function u(l){n.forRange("i",t.length,a,c=>{e.subschema({keyword:s,dataProp:c,dataPropType:lN.Type.Num},l),o.allErrors||n.if((0,Id.not)(l),()=>n.break())})}}Eg.validateAdditionalItems=une;Eg.default=G3e;var O3={},Sg={};Object.defineProperty(Sg,"__esModule",{value:!0});Sg.validateTuple=void 0;const AU=Xt,kw=_n,Y3e=Qt,K3e={keyword:"items",type:"array",schemaType:["object","array","boolean"],before:"uniqueItems",code(e){const{schema:t,it:n}=e;if(Array.isArray(t))return lne(e,"additionalItems",t);n.items=!0,!(0,kw.alwaysValidSchema)(n,t)&&e.ok((0,Y3e.validateArray)(e))}};function lne(e,t,n=e.schema){const{gen:r,parentSchema:i,data:s,keyword:o,it:a}=e;c(i),a.opts.unevaluated&&n.length&&a.items!==!0&&(a.items=kw.mergeEvaluated.items(r,n.length,a.items));const u=r.name("valid"),l=r.const("len",(0,AU._)`${s}.length`);n.forEach((f,d)=>{(0,kw.alwaysValidSchema)(a,f)||(r.if((0,AU._)`${l} > ${d}`,()=>e.subschema({keyword:o,schemaProp:d,dataProp:d},u)),e.ok(u))});function c(f){const{opts:d,errSchemaPath:h}=a,p=n.length,m=p===f.minItems&&(p===f.maxItems||f[t]===!1);if(d.strictTuples&&!m){const y=`"${o}" is ${p}-tuple, but minItems or maxItems/${t} are not specified or different at path "${h}"`;(0,kw.checkStrictMode)(a,y,d.strictTuples)}}}Sg.validateTuple=lne;Sg.default=K3e;Object.defineProperty(O3,"__esModule",{value:!0});const Q3e=Sg,X3e={keyword:"prefixItems",type:"array",schemaType:["array"],before:"uniqueItems",code:e=>(0,Q3e.validateTuple)(e,"items")};O3.default=X3e;var R3={};Object.defineProperty(R3,"__esModule",{value:!0});const PU=Xt,J3e=_n,Z3e=Qt,e6e=Eg,t6e={message:({params:{len:e}})=>(0,PU.str)`must NOT have more than ${e} items`,params:({params:{len:e}})=>(0,PU._)`{limit: ${e}}`},n6e={keyword:"items",type:"array",schemaType:["object","boolean"],before:"uniqueItems",error:t6e,code(e){const{schema:t,parentSchema:n,it:r}=e,{prefixItems:i}=n;r.items=!0,!(0,J3e.alwaysValidSchema)(r,t)&&(i?(0,e6e.validateAdditionalItems)(e,i):e.ok((0,Z3e.validateArray)(e)))}};R3.default=n6e;var N3={};Object.defineProperty(N3,"__esModule",{value:!0});const zo=Xt,Sb=_n,r6e={message:({params:{min:e,max:t}})=>t===void 0?(0,zo.str)`must contain at least ${e} valid item(s)`:(0,zo.str)`must contain at least ${e} and no more than ${t} valid item(s)`,params:({params:{min:e,max:t}})=>t===void 0?(0,zo._)`{minContains: ${e}}`:(0,zo._)`{minContains: ${e}, maxContains: ${t}}`},i6e={keyword:"contains",type:"array",schemaType:["object","boolean"],before:"uniqueItems",trackErrors:!0,error:r6e,code(e){const{gen:t,schema:n,parentSchema:r,data:i,it:s}=e;let o,a;const{minContains:u,maxContains:l}=r;s.opts.next?(o=u===void 0?1:u,a=l):o=1;const c=t.const("len",(0,zo._)`${i}.length`);if(e.setParams({min:o,max:a}),a===void 0&&o===0){(0,Sb.checkStrictMode)(s,'"minContains" == 0 without "maxContains": "contains" keyword ignored');return}if(a!==void 0&&o>a){(0,Sb.checkStrictMode)(s,'"minContains" > "maxContains" is always invalid'),e.fail();return}if((0,Sb.alwaysValidSchema)(s,n)){let m=(0,zo._)`${c} >= ${o}`;a!==void 0&&(m=(0,zo._)`${m} && ${c} <= ${a}`),e.pass(m);return}s.items=!0;const f=t.name("valid");a===void 0&&o===1?h(f,()=>t.if(f,()=>t.break())):o===0?(t.let(f,!0),a!==void 0&&t.if((0,zo._)`${i}.length > 0`,d)):(t.let(f,!1),d()),e.result(f,()=>e.reset());function d(){const m=t.name("_valid"),y=t.let("count",0);h(m,()=>t.if(m,()=>p(y)))}function h(m,y){t.forRange("i",0,c,g=>{e.subschema({keyword:"contains",dataProp:g,dataPropType:Sb.Type.Num,compositeRule:!0},m),y()})}function p(m){t.code((0,zo._)`${m}++`),a===void 0?t.if((0,zo._)`${m} >= ${o}`,()=>t.assign(f,!0).break()):(t.if((0,zo._)`${m} > ${a}`,()=>t.assign(f,!1).break()),o===1?t.assign(f,!0):t.if((0,zo._)`${m} >= ${o}`,()=>t.assign(f,!0)))}}};N3.default=i6e;var cne={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.validateSchemaDeps=e.validatePropertyDeps=e.error=void 0;const t=Xt,n=_n,r=Qt;e.error={message:({params:{property:u,depsCount:l,deps:c}})=>{const f=l===1?"property":"properties";return(0,t.str)`must have ${f} ${c} when property ${u} is present`},params:({params:{property:u,depsCount:l,deps:c,missingProperty:f}})=>(0,t._)`{property: ${u}, + || ${R} === "boolean" || ${I} === null`).assign(F,(0,i._)`[${I}]`)}}}function h({gen:b,parentData:S,parentDataProperty:T},E){b.if((0,i._)`${S} !== undefined`,()=>b.assign((0,i._)`${S}[${T}]`,E))}function p(b,S,T,E=o.Correct){const I=E===o.Correct?i.operators.EQ:i.operators.NEQ;let A;switch(b){case"null":return(0,i._)`${S} ${I} null`;case"array":A=(0,i._)`Array.isArray(${S})`;break;case"object":A=(0,i._)`${S} && typeof ${S} == "object" && !Array.isArray(${S})`;break;case"integer":A=R((0,i._)`!(${S} % 1) && !isNaN(${S})`);break;case"number":A=R();break;default:return(0,i._)`typeof ${S} ${I} ${b}`}return E===o.Correct?A:(0,i.not)(A);function R(F=i.nil){return(0,i.and)((0,i._)`typeof ${S} == "number"`,F,T?(0,i._)`isFinite(${S})`:i.nil)}}e.checkDataType=p;function m(b,S,T,E){if(b.length===1)return p(b[0],S,T,E);let I;const A=(0,s.toHash)(b);if(A.array&&A.object){const R=(0,i._)`typeof ${S} != "object"`;I=A.null?R:(0,i._)`!${S} || ${R}`,delete A.null,delete A.array,delete A.object}else I=i.nil;A.number&&delete A.integer;for(const R in A)I=(0,i.and)(I,p(R,S,T,E));return I}e.checkDataTypes=m;const y={message:({schema:b})=>`must be ${b}`,params:({schema:b,schemaValue:S})=>typeof b=="string"?(0,i._)`{type: ${b}}`:(0,i._)`{type: ${S}}`};function g(b){const S=v(b);(0,r.reportError)(S,y)}e.reportTypeError=g;function v(b){const{gen:S,data:T,schema:E}=b,I=(0,s.schemaRefOrVal)(b,E,"type");return{gen:S,keyword:"type",data:T,schema:E.type,schemaCode:I,schemaValue:I,parentSchema:E,params:{},it:b}}})(V_);var iC={};Object.defineProperty(iC,"__esModule",{value:!0});iC.assignDefaults=void 0;const ep=Xt,RDe=_n;function NDe(e,t){const{properties:n,items:r}=e.schema;if(t==="object"&&n)for(const i in n)yU(e,i,n[i].default);else t==="array"&&Array.isArray(r)&&r.forEach((i,s)=>yU(e,s,i.default))}iC.assignDefaults=NDe;function yU(e,t,n){const{gen:r,compositeRule:i,data:s,opts:o}=e;if(n===void 0)return;const a=(0,ep._)`${s}${(0,ep.getProperty)(t)}`;if(i){(0,RDe.checkStrictMode)(e,`default is ignored for: ${a}`);return}let u=(0,ep._)`${a} === undefined`;o.useDefaults==="empty"&&(u=(0,ep._)`${u} || ${a} === null || ${a} === ""`),r.if(u,(0,ep._)`${a} = ${(0,ep.stringify)(n)}`)}var Ou={},Qt={};Object.defineProperty(Qt,"__esModule",{value:!0});Qt.validateUnion=Qt.validateArray=Qt.usePattern=Qt.callValidateCode=Qt.schemaProperties=Qt.allSchemaProperties=Qt.noPropertyInData=Qt.propertyInData=Qt.isOwnProperty=Qt.hasPropFunc=Qt.reportMissingProp=Qt.checkMissingProp=Qt.checkReportMissingProp=void 0;const tr=Xt,s3=_n,Ec=dl,kDe=_n;function DDe(e,t){const{gen:n,data:r,it:i}=e;n.if(a3(n,r,t,i.opts.ownProperties),()=>{e.setParams({missingProperty:(0,tr._)`${t}`},!0),e.error()})}Qt.checkReportMissingProp=DDe;function $De({gen:e,data:t,it:{opts:n}},r,i){return(0,tr.or)(...r.map(s=>(0,tr.and)(a3(e,t,s,n.ownProperties),(0,tr._)`${i} = ${s}`)))}Qt.checkMissingProp=$De;function LDe(e,t){e.setParams({missingProperty:t},!0),e.error()}Qt.reportMissingProp=LDe;function Fte(e){return e.scopeValue("func",{ref:Object.prototype.hasOwnProperty,code:(0,tr._)`Object.prototype.hasOwnProperty`})}Qt.hasPropFunc=Fte;function o3(e,t,n){return(0,tr._)`${Fte(e)}.call(${t}, ${n})`}Qt.isOwnProperty=o3;function MDe(e,t,n,r){const i=(0,tr._)`${t}${(0,tr.getProperty)(n)} !== undefined`;return r?(0,tr._)`${i} && ${o3(e,t,n)}`:i}Qt.propertyInData=MDe;function a3(e,t,n,r){const i=(0,tr._)`${t}${(0,tr.getProperty)(n)} === undefined`;return r?(0,tr.or)(i,(0,tr.not)(o3(e,t,n))):i}Qt.noPropertyInData=a3;function Bte(e){return e?Object.keys(e).filter(t=>t!=="__proto__"):[]}Qt.allSchemaProperties=Bte;function FDe(e,t){return Bte(t).filter(n=>!(0,s3.alwaysValidSchema)(e,t[n]))}Qt.schemaProperties=FDe;function BDe({schemaCode:e,data:t,it:{gen:n,topSchemaRef:r,schemaPath:i,errorPath:s},it:o},a,u,l){const c=l?(0,tr._)`${e}, ${t}, ${r}${i}`:t,f=[[Ec.default.instancePath,(0,tr.strConcat)(Ec.default.instancePath,s)],[Ec.default.parentData,o.parentData],[Ec.default.parentDataProperty,o.parentDataProperty],[Ec.default.rootData,Ec.default.rootData]];o.opts.dynamicRef&&f.push([Ec.default.dynamicAnchors,Ec.default.dynamicAnchors]);const d=(0,tr._)`${c}, ${n.object(...f)}`;return u!==tr.nil?(0,tr._)`${a}.call(${u}, ${d})`:(0,tr._)`${a}(${d})`}Qt.callValidateCode=BDe;const jDe=(0,tr._)`new RegExp`;function UDe({gen:e,it:{opts:t}},n){const r=t.unicodeRegExp?"u":"",{regExp:i}=t.code,s=i(n,r);return e.scopeValue("pattern",{key:s.toString(),ref:s,code:(0,tr._)`${i.code==="new RegExp"?jDe:(0,kDe.useFunc)(e,i)}(${n}, ${r})`})}Qt.usePattern=UDe;function VDe(e){const{gen:t,data:n,keyword:r,it:i}=e,s=t.name("valid");if(i.allErrors){const a=t.let("valid",!0);return o(()=>t.assign(a,!1)),a}return t.var(s,!0),o(()=>t.break()),s;function o(a){const u=t.const("len",(0,tr._)`${n}.length`);t.forRange("i",0,u,l=>{e.subschema({keyword:r,dataProp:l,dataPropType:s3.Type.Num},s),t.if((0,tr.not)(s),a)})}}Qt.validateArray=VDe;function zDe(e){const{gen:t,schema:n,keyword:r,it:i}=e;if(!Array.isArray(n))throw new Error("ajv implementation error");if(n.some(u=>(0,s3.alwaysValidSchema)(i,u))&&!i.opts.unevaluated)return;const o=t.let("valid",!1),a=t.name("_valid");t.block(()=>n.forEach((u,l)=>{const c=e.subschema({keyword:r,schemaProp:l,compositeRule:!0},a);t.assign(o,(0,tr._)`${o} || ${a}`),e.mergeValidEvaluated(c,a)||t.if((0,tr.not)(o))})),e.result(o,()=>e.reset(),()=>e.error(!0))}Qt.validateUnion=zDe;Object.defineProperty(Ou,"__esModule",{value:!0});Ou.validateKeywordUsage=Ou.validSchemaType=Ou.funcKeywordCode=Ou.macroKeywordCode=void 0;const ms=Xt,Sd=dl,HDe=Qt,WDe=U_;function qDe(e,t){const{gen:n,keyword:r,schema:i,parentSchema:s,it:o}=e,a=t.macro.call(o.self,i,s,o),u=jte(n,r,a);o.opts.validateSchema!==!1&&o.self.validateSchema(a,!0);const l=n.name("valid");e.subschema({schema:a,schemaPath:ms.nil,errSchemaPath:`${o.errSchemaPath}/${r}`,topSchemaRef:u,compositeRule:!0},l),e.pass(l,()=>e.error(!0))}Ou.macroKeywordCode=qDe;function GDe(e,t){var n;const{gen:r,keyword:i,schema:s,parentSchema:o,$data:a,it:u}=e;KDe(u,t);const l=!a&&t.compile?t.compile.call(u.self,s,o,u):t.validate,c=jte(r,i,l),f=r.let("valid");e.block$data(f,d),e.ok((n=t.valid)!==null&&n!==void 0?n:f);function d(){if(t.errors===!1)m(),t.modifying&&vU(e),y(()=>e.error());else{const g=t.async?h():p();t.modifying&&vU(e),y(()=>YDe(e,g))}}function h(){const g=r.let("ruleErrs",null);return r.try(()=>m((0,ms._)`await `),v=>r.assign(f,!1).if((0,ms._)`${v} instanceof ${u.ValidationError}`,()=>r.assign(g,(0,ms._)`${v}.errors`),()=>r.throw(v))),g}function p(){const g=(0,ms._)`${c}.errors`;return r.assign(g,null),m(ms.nil),g}function m(g=t.async?(0,ms._)`await `:ms.nil){const v=u.opts.passContext?Sd.default.this:Sd.default.self,b=!("compile"in t&&!a||t.schema===!1);r.assign(f,(0,ms._)`${g}${(0,HDe.callValidateCode)(e,c,v,b)}`,t.modifying)}function y(g){var v;r.if((0,ms.not)((v=t.valid)!==null&&v!==void 0?v:f),g)}}Ou.funcKeywordCode=GDe;function vU(e){const{gen:t,data:n,it:r}=e;t.if(r.parentData,()=>t.assign(n,(0,ms._)`${r.parentData}[${r.parentDataProperty}]`))}function YDe(e,t){const{gen:n}=e;n.if((0,ms._)`Array.isArray(${t})`,()=>{n.assign(Sd.default.vErrors,(0,ms._)`${Sd.default.vErrors} === null ? ${t} : ${Sd.default.vErrors}.concat(${t})`).assign(Sd.default.errors,(0,ms._)`${Sd.default.vErrors}.length`),(0,WDe.extendErrors)(e)},()=>e.error())}function KDe({schemaEnv:e},t){if(t.async&&!e.$async)throw new Error("async keyword in sync schema")}function jte(e,t,n){if(n===void 0)throw new Error(`keyword "${t}" failed to compile`);return e.scopeValue("keyword",typeof n=="function"?{ref:n}:{ref:n,code:(0,ms.stringify)(n)})}function QDe(e,t,n=!1){return!t.length||t.some(r=>r==="array"?Array.isArray(e):r==="object"?e&&typeof e=="object"&&!Array.isArray(e):typeof e==r||n&&typeof e>"u")}Ou.validSchemaType=QDe;function XDe({schema:e,opts:t,self:n,errSchemaPath:r},i,s){if(Array.isArray(i.keyword)?!i.keyword.includes(s):i.keyword!==s)throw new Error("ajv implementation error");const o=i.dependencies;if(o!=null&&o.some(a=>!Object.prototype.hasOwnProperty.call(e,a)))throw new Error(`parent schema must have dependencies of ${s}: ${o.join(",")}`);if(i.validateSchema&&!i.validateSchema(e[s])){const u=`keyword "${s}" value is invalid at path "${r}": `+n.errorsText(i.validateSchema.errors);if(t.validateSchema==="log")n.logger.error(u);else throw new Error(u)}}Ou.validateKeywordUsage=XDe;var pf={};Object.defineProperty(pf,"__esModule",{value:!0});pf.extendSubschemaMode=pf.extendSubschemaData=pf.getSubschema=void 0;const _u=Xt,Ute=_n;function JDe(e,{keyword:t,schemaProp:n,schema:r,schemaPath:i,errSchemaPath:s,topSchemaRef:o}){if(t!==void 0&&r!==void 0)throw new Error('both "keyword" and "schema" passed, only one allowed');if(t!==void 0){const a=e.schema[t];return n===void 0?{schema:a,schemaPath:(0,_u._)`${e.schemaPath}${(0,_u.getProperty)(t)}`,errSchemaPath:`${e.errSchemaPath}/${t}`}:{schema:a[n],schemaPath:(0,_u._)`${e.schemaPath}${(0,_u.getProperty)(t)}${(0,_u.getProperty)(n)}`,errSchemaPath:`${e.errSchemaPath}/${t}/${(0,Ute.escapeFragment)(n)}`}}if(r!==void 0){if(i===void 0||s===void 0||o===void 0)throw new Error('"schemaPath", "errSchemaPath" and "topSchemaRef" are required with "schema"');return{schema:r,schemaPath:i,topSchemaRef:o,errSchemaPath:s}}throw new Error('either "keyword" or "schema" must be passed')}pf.getSubschema=JDe;function ZDe(e,t,{dataProp:n,dataPropType:r,data:i,dataTypes:s,propertyName:o}){if(i!==void 0&&n!==void 0)throw new Error('both "data" and "dataProp" passed, only one allowed');const{gen:a}=t;if(n!==void 0){const{errorPath:l,dataPathArr:c,opts:f}=t,d=a.let("data",(0,_u._)`${t.data}${(0,_u.getProperty)(n)}`,!0);u(d),e.errorPath=(0,_u.str)`${l}${(0,Ute.getErrorPath)(n,r,f.jsPropertySyntax)}`,e.parentDataProperty=(0,_u._)`${n}`,e.dataPathArr=[...c,e.parentDataProperty]}if(i!==void 0){const l=i instanceof _u.Name?i:a.let("data",i,!0);u(l),o!==void 0&&(e.propertyName=o)}s&&(e.dataTypes=s);function u(l){e.data=l,e.dataLevel=t.dataLevel+1,e.dataTypes=[],t.definedProperties=new Set,e.parentData=t.data,e.dataNames=[...t.dataNames,l]}}pf.extendSubschemaData=ZDe;function e$e(e,{jtdDiscriminator:t,jtdMetadata:n,compositeRule:r,createErrors:i,allErrors:s}){r!==void 0&&(e.compositeRule=r),i!==void 0&&(e.createErrors=i),s!==void 0&&(e.allErrors=s),e.jtdDiscriminator=t,e.jtdMetadata=n}pf.extendSubschemaMode=e$e;var Ri={},u3=function e(t,n){if(t===n)return!0;if(t&&n&&typeof t=="object"&&typeof n=="object"){if(t.constructor!==n.constructor)return!1;var r,i,s;if(Array.isArray(t)){if(r=t.length,r!=n.length)return!1;for(i=r;i--!==0;)if(!e(t[i],n[i]))return!1;return!0}if(t.constructor===RegExp)return t.source===n.source&&t.flags===n.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===n.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===n.toString();if(s=Object.keys(t),r=s.length,r!==Object.keys(n).length)return!1;for(i=r;i--!==0;)if(!Object.prototype.hasOwnProperty.call(n,s[i]))return!1;for(i=r;i--!==0;){var o=s[i];if(!e(t[o],n[o]))return!1}return!0}return t!==t&&n!==n};const _U=eu(u3);var Vte={exports:{}},Qc=Vte.exports=function(e,t,n){typeof t=="function"&&(n=t,t={}),n=t.cb||n;var r=typeof n=="function"?n:n.pre||function(){},i=n.post||function(){};Rw(t,r,i,e,"",e)};Qc.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0,if:!0,then:!0,else:!0};Qc.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0};Qc.propsKeywords={$defs:!0,definitions:!0,properties:!0,patternProperties:!0,dependencies:!0};Qc.skipKeywords={default:!0,enum:!0,const:!0,required:!0,maximum:!0,minimum:!0,exclusiveMaximum:!0,exclusiveMinimum:!0,multipleOf:!0,maxLength:!0,minLength:!0,pattern:!0,format:!0,maxItems:!0,minItems:!0,uniqueItems:!0,maxProperties:!0,minProperties:!0};function Rw(e,t,n,r,i,s,o,a,u,l){if(r&&typeof r=="object"&&!Array.isArray(r)){t(r,i,s,o,a,u,l);for(var c in r){var f=r[c];if(Array.isArray(f)){if(c in Qc.arrayKeywords)for(var d=0;dt+=zte(r)),t===1/0))return 1/0}return t}function Hte(e,t="",n){n!==!1&&(t=nm(t));const r=e.parse(t);return Wte(e,r)}Ri.getFullPath=Hte;function Wte(e,t){return e.serialize(t).split("#")[0]+"#"}Ri._getFullPath=Wte;const l$e=/#\/?$/;function nm(e){return e?e.replace(l$e,""):""}Ri.normalizeId=nm;function c$e(e,t,n){return n=nm(n),e.resolve(t,n)}Ri.resolveUrl=c$e;const f$e=/^[a-z_][-a-z0-9._]*$/i;function d$e(e,t){if(typeof e=="boolean")return{};const{schemaId:n,uriResolver:r}=this.opts,i=nm(e[n]||t),s={"":i},o=Hte(r,i,!1),a={},u=new Set;return s$e(e,{allKeys:!0},(f,d,h,p)=>{if(p===void 0)return;const m=o+d;let y=s[p];typeof f[n]=="string"&&(y=g.call(this,f[n])),v.call(this,f.$anchor),v.call(this,f.$dynamicAnchor),s[d]=y;function g(b){const S=this.opts.uriResolver.resolve;if(b=nm(y?S(y,b):b),u.has(b))throw c(b);u.add(b);let T=this.refs[b];return typeof T=="string"&&(T=this.refs[T]),typeof T=="object"?l(f,T.schema,b):b!==nm(m)&&(b[0]==="#"?(l(f,a[b],b),a[b]=f):this.refs[b]=m),b}function v(b){if(typeof b=="string"){if(!f$e.test(b))throw new Error(`invalid anchor "${b}"`);g.call(this,`#${b}`)}}}),a;function l(f,d,h){if(d!==void 0&&!i$e(f,d))throw c(h)}function c(f){return new Error(`reference "${f}" resolves to more than one schema`)}}Ri.getSchemaRefs=d$e;Object.defineProperty(Va,"__esModule",{value:!0});Va.getData=Va.KeywordCxt=Va.validateFunctionCode=void 0;const qte=Um,bU=V_,l3=Bl,TT=V_,h$e=iC,Sy=Ou,ZP=pf,ut=Xt,Rt=dl,p$e=Ri,jl=_n,b0=U_;function m$e(e){if(Kte(e)&&(Qte(e),Yte(e))){v$e(e);return}Gte(e,()=>(0,qte.topBoolOrEmptySchema)(e))}Va.validateFunctionCode=m$e;function Gte({gen:e,validateName:t,schema:n,schemaEnv:r,opts:i},s){i.code.es5?e.func(t,(0,ut._)`${Rt.default.data}, ${Rt.default.valCxt}`,r.$async,()=>{e.code((0,ut._)`"use strict"; ${wU(n,i)}`),y$e(e,i),e.code(s)}):e.func(t,(0,ut._)`${Rt.default.data}, ${g$e(i)}`,r.$async,()=>e.code(wU(n,i)).code(s))}function g$e(e){return(0,ut._)`{${Rt.default.instancePath}="", ${Rt.default.parentData}, ${Rt.default.parentDataProperty}, ${Rt.default.rootData}=${Rt.default.data}${e.dynamicRef?(0,ut._)`, ${Rt.default.dynamicAnchors}={}`:ut.nil}}={}`}function y$e(e,t){e.if(Rt.default.valCxt,()=>{e.var(Rt.default.instancePath,(0,ut._)`${Rt.default.valCxt}.${Rt.default.instancePath}`),e.var(Rt.default.parentData,(0,ut._)`${Rt.default.valCxt}.${Rt.default.parentData}`),e.var(Rt.default.parentDataProperty,(0,ut._)`${Rt.default.valCxt}.${Rt.default.parentDataProperty}`),e.var(Rt.default.rootData,(0,ut._)`${Rt.default.valCxt}.${Rt.default.rootData}`),t.dynamicRef&&e.var(Rt.default.dynamicAnchors,(0,ut._)`${Rt.default.valCxt}.${Rt.default.dynamicAnchors}`)},()=>{e.var(Rt.default.instancePath,(0,ut._)`""`),e.var(Rt.default.parentData,(0,ut._)`undefined`),e.var(Rt.default.parentDataProperty,(0,ut._)`undefined`),e.var(Rt.default.rootData,Rt.default.data),t.dynamicRef&&e.var(Rt.default.dynamicAnchors,(0,ut._)`{}`)})}function v$e(e){const{schema:t,opts:n,gen:r}=e;Gte(e,()=>{n.$comment&&t.$comment&&Jte(e),S$e(e),r.let(Rt.default.vErrors,null),r.let(Rt.default.errors,0),n.unevaluated&&_$e(e),Xte(e),x$e(e)})}function _$e(e){const{gen:t,validateName:n}=e;e.evaluated=t.const("evaluated",(0,ut._)`${n}.evaluated`),t.if((0,ut._)`${e.evaluated}.dynamicProps`,()=>t.assign((0,ut._)`${e.evaluated}.props`,(0,ut._)`undefined`)),t.if((0,ut._)`${e.evaluated}.dynamicItems`,()=>t.assign((0,ut._)`${e.evaluated}.items`,(0,ut._)`undefined`))}function wU(e,t){const n=typeof e=="object"&&e[t.schemaId];return n&&(t.code.source||t.code.process)?(0,ut._)`/*# sourceURL=${n} */`:ut.nil}function b$e(e,t){if(Kte(e)&&(Qte(e),Yte(e))){w$e(e,t);return}(0,qte.boolOrEmptySchema)(e,t)}function Yte({schema:e,self:t}){if(typeof e=="boolean")return!e;for(const n in e)if(t.RULES.all[n])return!0;return!1}function Kte(e){return typeof e.schema!="boolean"}function w$e(e,t){const{schema:n,gen:r,opts:i}=e;i.$comment&&n.$comment&&Jte(e),T$e(e),I$e(e);const s=r.const("_errs",Rt.default.errors);Xte(e,s),r.var(t,(0,ut._)`${s} === ${Rt.default.errors}`)}function Qte(e){(0,jl.checkUnknownRules)(e),E$e(e)}function Xte(e,t){if(e.opts.jtd)return EU(e,[],!1,t);const n=(0,bU.getSchemaTypes)(e.schema),r=(0,bU.coerceAndCheckDataType)(e,n);EU(e,n,!r,t)}function E$e(e){const{schema:t,errSchemaPath:n,opts:r,self:i}=e;t.$ref&&r.ignoreKeywordsWithRef&&(0,jl.schemaHasRulesButRef)(t,i.RULES)&&i.logger.warn(`$ref: keywords ignored in schema at path "${n}"`)}function S$e(e){const{schema:t,opts:n}=e;t.default!==void 0&&n.useDefaults&&n.strictSchema&&(0,jl.checkStrictMode)(e,"default is ignored in the schema root")}function T$e(e){const t=e.schema[e.opts.schemaId];t&&(e.baseId=(0,p$e.resolveUrl)(e.opts.uriResolver,e.baseId,t))}function I$e(e){if(e.schema.$async&&!e.schemaEnv.$async)throw new Error("async schema in sync schema")}function Jte({gen:e,schemaEnv:t,schema:n,errSchemaPath:r,opts:i}){const s=n.$comment;if(i.$comment===!0)e.code((0,ut._)`${Rt.default.self}.logger.log(${s})`);else if(typeof i.$comment=="function"){const o=(0,ut.str)`${r}/$comment`,a=e.scopeValue("root",{ref:t.root});e.code((0,ut._)`${Rt.default.self}.opts.$comment(${s}, ${o}, ${a}.schema)`)}}function x$e(e){const{gen:t,schemaEnv:n,validateName:r,ValidationError:i,opts:s}=e;n.$async?t.if((0,ut._)`${Rt.default.errors} === 0`,()=>t.return(Rt.default.data),()=>t.throw((0,ut._)`new ${i}(${Rt.default.vErrors})`)):(t.assign((0,ut._)`${r}.errors`,Rt.default.vErrors),s.unevaluated&&C$e(e),t.return((0,ut._)`${Rt.default.errors} === 0`))}function C$e({gen:e,evaluated:t,props:n,items:r}){n instanceof ut.Name&&e.assign((0,ut._)`${t}.props`,n),r instanceof ut.Name&&e.assign((0,ut._)`${t}.items`,r)}function EU(e,t,n,r){const{gen:i,schema:s,data:o,allErrors:a,opts:u,self:l}=e,{RULES:c}=l;if(s.$ref&&(u.ignoreKeywordsWithRef||!(0,jl.schemaHasRulesButRef)(s,c))){i.block(()=>tne(e,"$ref",c.all.$ref.definition));return}u.jtd||A$e(e,t),i.block(()=>{for(const d of c.rules)f(d);f(c.post)});function f(d){(0,l3.shouldUseGroup)(s,d)&&(d.type?(i.if((0,TT.checkDataType)(d.type,o,u.strictNumbers)),SU(e,d),t.length===1&&t[0]===d.type&&n&&(i.else(),(0,TT.reportTypeError)(e)),i.endIf()):SU(e,d),a||i.if((0,ut._)`${Rt.default.errors} === ${r||0}`))}}function SU(e,t){const{gen:n,schema:r,opts:{useDefaults:i}}=e;i&&(0,h$e.assignDefaults)(e,t.type),n.block(()=>{for(const s of t.rules)(0,l3.shouldUseRule)(r,s)&&tne(e,s.keyword,s.definition,t.type)})}function A$e(e,t){e.schemaEnv.meta||!e.opts.strictTypes||(P$e(e,t),e.opts.allowUnionTypes||O$e(e,t),R$e(e,e.dataTypes))}function P$e(e,t){if(t.length){if(!e.dataTypes.length){e.dataTypes=t;return}t.forEach(n=>{Zte(e.dataTypes,n)||c3(e,`type "${n}" not allowed by context "${e.dataTypes.join(",")}"`)}),k$e(e,t)}}function O$e(e,t){t.length>1&&!(t.length===2&&t.includes("null"))&&c3(e,"use allowUnionTypes to allow union type keyword")}function R$e(e,t){const n=e.self.RULES.all;for(const r in n){const i=n[r];if(typeof i=="object"&&(0,l3.shouldUseRule)(e.schema,i)){const{type:s}=i.definition;s.length&&!s.some(o=>N$e(t,o))&&c3(e,`missing type "${s.join(",")}" for keyword "${r}"`)}}}function N$e(e,t){return e.includes(t)||t==="number"&&e.includes("integer")}function Zte(e,t){return e.includes(t)||t==="integer"&&e.includes("number")}function k$e(e,t){const n=[];for(const r of e.dataTypes)Zte(t,r)?n.push(r):t.includes("integer")&&r==="number"&&n.push("integer");e.dataTypes=n}function c3(e,t){const n=e.schemaEnv.baseId+e.errSchemaPath;t+=` at "${n}" (strictTypes)`,(0,jl.checkStrictMode)(e,t,e.opts.strictTypes)}class ene{constructor(t,n,r){if((0,Sy.validateKeywordUsage)(t,n,r),this.gen=t.gen,this.allErrors=t.allErrors,this.keyword=r,this.data=t.data,this.schema=t.schema[r],this.$data=n.$data&&t.opts.$data&&this.schema&&this.schema.$data,this.schemaValue=(0,jl.schemaRefOrVal)(t,this.schema,r,this.$data),this.schemaType=n.schemaType,this.parentSchema=t.schema,this.params={},this.it=t,this.def=n,this.$data)this.schemaCode=t.gen.const("vSchema",nne(this.$data,t));else if(this.schemaCode=this.schemaValue,!(0,Sy.validSchemaType)(this.schema,n.schemaType,n.allowUndefined))throw new Error(`${r} value must be ${JSON.stringify(n.schemaType)}`);("code"in n?n.trackErrors:n.errors!==!1)&&(this.errsCount=t.gen.const("_errs",Rt.default.errors))}result(t,n,r){this.failResult((0,ut.not)(t),n,r)}failResult(t,n,r){this.gen.if(t),r?r():this.error(),n?(this.gen.else(),n(),this.allErrors&&this.gen.endIf()):this.allErrors?this.gen.endIf():this.gen.else()}pass(t,n){this.failResult((0,ut.not)(t),void 0,n)}fail(t){if(t===void 0){this.error(),this.allErrors||this.gen.if(!1);return}this.gen.if(t),this.error(),this.allErrors?this.gen.endIf():this.gen.else()}fail$data(t){if(!this.$data)return this.fail(t);const{schemaCode:n}=this;this.fail((0,ut._)`${n} !== undefined && (${(0,ut.or)(this.invalid$data(),t)})`)}error(t,n,r){if(n){this.setParams(n),this._error(t,r),this.setParams({});return}this._error(t,r)}_error(t,n){(t?b0.reportExtraError:b0.reportError)(this,this.def.error,n)}$dataError(){(0,b0.reportError)(this,this.def.$dataError||b0.keyword$DataError)}reset(){if(this.errsCount===void 0)throw new Error('add "trackErrors" to keyword definition');(0,b0.resetErrorsCount)(this.gen,this.errsCount)}ok(t){this.allErrors||this.gen.if(t)}setParams(t,n){n?Object.assign(this.params,t):this.params=t}block$data(t,n,r=ut.nil){this.gen.block(()=>{this.check$data(t,r),n()})}check$data(t=ut.nil,n=ut.nil){if(!this.$data)return;const{gen:r,schemaCode:i,schemaType:s,def:o}=this;r.if((0,ut.or)((0,ut._)`${i} === undefined`,n)),t!==ut.nil&&r.assign(t,!0),(s.length||o.validateSchema)&&(r.elseIf(this.invalid$data()),this.$dataError(),t!==ut.nil&&r.assign(t,!1)),r.else()}invalid$data(){const{gen:t,schemaCode:n,schemaType:r,def:i,it:s}=this;return(0,ut.or)(o(),a());function o(){if(r.length){if(!(n instanceof ut.Name))throw new Error("ajv implementation error");const u=Array.isArray(r)?r:[r];return(0,ut._)`${(0,TT.checkDataTypes)(u,n,s.opts.strictNumbers,TT.DataType.Wrong)}`}return ut.nil}function a(){if(i.validateSchema){const u=t.scopeValue("validate$data",{ref:i.validateSchema});return(0,ut._)`!${u}(${n})`}return ut.nil}}subschema(t,n){const r=(0,ZP.getSubschema)(this.it,t);(0,ZP.extendSubschemaData)(r,this.it,t),(0,ZP.extendSubschemaMode)(r,t);const i={...this.it,...r,items:void 0,props:void 0};return b$e(i,n),i}mergeEvaluated(t,n){const{it:r,gen:i}=this;r.opts.unevaluated&&(r.props!==!0&&t.props!==void 0&&(r.props=jl.mergeEvaluated.props(i,t.props,r.props,n)),r.items!==!0&&t.items!==void 0&&(r.items=jl.mergeEvaluated.items(i,t.items,r.items,n)))}mergeValidEvaluated(t,n){const{it:r,gen:i}=this;if(r.opts.unevaluated&&(r.props!==!0||r.items!==!0))return i.if(n,()=>this.mergeEvaluated(t,ut.Name)),!0}}Va.KeywordCxt=ene;function tne(e,t,n,r){const i=new ene(e,n,t);"code"in n?n.code(i,r):i.$data&&n.validate?(0,Sy.funcKeywordCode)(i,n):"macro"in n?(0,Sy.macroKeywordCode)(i,n):(n.compile||n.validate)&&(0,Sy.funcKeywordCode)(i,n)}const D$e=/^\/(?:[^~]|~0|~1)*$/,$$e=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function nne(e,{dataLevel:t,dataNames:n,dataPathArr:r}){let i,s;if(e==="")return Rt.default.rootData;if(e[0]==="/"){if(!D$e.test(e))throw new Error(`Invalid JSON-pointer: ${e}`);i=e,s=Rt.default.rootData}else{const l=$$e.exec(e);if(!l)throw new Error(`Invalid JSON-pointer: ${e}`);const c=+l[1];if(i=l[2],i==="#"){if(c>=t)throw new Error(u("property/index",c));return r[t-c]}if(c>t)throw new Error(u("data",c));if(s=n[t-c],!i)return s}let o=s;const a=i.split("/");for(const l of a)l&&(s=(0,ut._)`${s}${(0,ut.getProperty)((0,jl.unescapeJsonPointer)(l))}`,o=(0,ut._)`${o} && ${s}`);return o;function u(l,c){return`Cannot access ${l} ${c} levels up, current level is ${t}`}}Va.getData=nne;var z_={};Object.defineProperty(z_,"__esModule",{value:!0});class L$e extends Error{constructor(t){super("validation failed"),this.errors=t,this.ajv=this.validation=!0}}z_.default=L$e;var H_={};Object.defineProperty(H_,"__esModule",{value:!0});const eO=Ri;class M$e extends Error{constructor(t,n,r,i){super(i||`can't resolve reference ${r} from id ${n}`),this.missingRef=(0,eO.resolveUrl)(t,n,r),this.missingSchema=(0,eO.normalizeId)((0,eO.getFullPath)(t,this.missingRef))}}H_.default=M$e;var zs={};Object.defineProperty(zs,"__esModule",{value:!0});zs.resolveSchema=zs.getCompilingSchema=zs.resolveRef=zs.compileSchema=zs.SchemaEnv=void 0;const Ea=Xt,F$e=z_,ld=dl,ka=Ri,TU=_n,B$e=Va;class sC{constructor(t){var n;this.refs={},this.dynamicAnchors={};let r;typeof t.schema=="object"&&(r=t.schema),this.schema=t.schema,this.schemaId=t.schemaId,this.root=t.root||this,this.baseId=(n=t.baseId)!==null&&n!==void 0?n:(0,ka.normalizeId)(r==null?void 0:r[t.schemaId||"$id"]),this.schemaPath=t.schemaPath,this.localRefs=t.localRefs,this.meta=t.meta,this.$async=r==null?void 0:r.$async,this.refs={}}}zs.SchemaEnv=sC;function f3(e){const t=rne.call(this,e);if(t)return t;const n=(0,ka.getFullPath)(this.opts.uriResolver,e.root.baseId),{es5:r,lines:i}=this.opts.code,{ownProperties:s}=this.opts,o=new Ea.CodeGen(this.scope,{es5:r,lines:i,ownProperties:s});let a;e.$async&&(a=o.scopeValue("Error",{ref:F$e.default,code:(0,Ea._)`require("ajv/dist/runtime/validation_error").default`}));const u=o.scopeName("validate");e.validateName=u;const l={gen:o,allErrors:this.opts.allErrors,data:ld.default.data,parentData:ld.default.parentData,parentDataProperty:ld.default.parentDataProperty,dataNames:[ld.default.data],dataPathArr:[Ea.nil],dataLevel:0,dataTypes:[],definedProperties:new Set,topSchemaRef:o.scopeValue("schema",this.opts.code.source===!0?{ref:e.schema,code:(0,Ea.stringify)(e.schema)}:{ref:e.schema}),validateName:u,ValidationError:a,schema:e.schema,schemaEnv:e,rootId:n,baseId:e.baseId||n,schemaPath:Ea.nil,errSchemaPath:e.schemaPath||(this.opts.jtd?"":"#"),errorPath:(0,Ea._)`""`,opts:this.opts,self:this};let c;try{this._compilations.add(e),(0,B$e.validateFunctionCode)(l),o.optimize(this.opts.code.optimize);const f=o.toString();c=`${o.scopeRefs(ld.default.scope)}return ${f}`,this.opts.code.process&&(c=this.opts.code.process(c,e));const h=new Function(`${ld.default.self}`,`${ld.default.scope}`,c)(this,this.scope.get());if(this.scope.value(u,{ref:h}),h.errors=null,h.schema=e.schema,h.schemaEnv=e,e.$async&&(h.$async=!0),this.opts.code.source===!0&&(h.source={validateName:u,validateCode:f,scopeValues:o._values}),this.opts.unevaluated){const{props:p,items:m}=l;h.evaluated={props:p instanceof Ea.Name?void 0:p,items:m instanceof Ea.Name?void 0:m,dynamicProps:p instanceof Ea.Name,dynamicItems:m instanceof Ea.Name},h.source&&(h.source.evaluated=(0,Ea.stringify)(h.evaluated))}return e.validate=h,e}catch(f){throw delete e.validate,delete e.validateName,c&&this.logger.error("Error compiling schema, function code:",c),f}finally{this._compilations.delete(e)}}zs.compileSchema=f3;function j$e(e,t,n){var r;n=(0,ka.resolveUrl)(this.opts.uriResolver,t,n);const i=e.refs[n];if(i)return i;let s=z$e.call(this,e,n);if(s===void 0){const o=(r=e.localRefs)===null||r===void 0?void 0:r[n],{schemaId:a}=this.opts;o&&(s=new sC({schema:o,schemaId:a,root:e,baseId:t}))}if(s!==void 0)return e.refs[n]=U$e.call(this,s)}zs.resolveRef=j$e;function U$e(e){return(0,ka.inlineRef)(e.schema,this.opts.inlineRefs)?e.schema:e.validate?e:f3.call(this,e)}function rne(e){for(const t of this._compilations)if(V$e(t,e))return t}zs.getCompilingSchema=rne;function V$e(e,t){return e.schema===t.schema&&e.root===t.root&&e.baseId===t.baseId}function z$e(e,t){let n;for(;typeof(n=this.refs[t])=="string";)t=n;return n||this.schemas[t]||oC.call(this,e,t)}function oC(e,t){const n=this.opts.uriResolver.parse(t),r=(0,ka._getFullPath)(this.opts.uriResolver,n);let i=(0,ka.getFullPath)(this.opts.uriResolver,e.baseId,void 0);if(Object.keys(e.schema).length>0&&r===i)return tO.call(this,n,e);const s=(0,ka.normalizeId)(r),o=this.refs[s]||this.schemas[s];if(typeof o=="string"){const a=oC.call(this,e,o);return typeof(a==null?void 0:a.schema)!="object"?void 0:tO.call(this,n,a)}if(typeof(o==null?void 0:o.schema)=="object"){if(o.validate||f3.call(this,o),s===(0,ka.normalizeId)(t)){const{schema:a}=o,{schemaId:u}=this.opts,l=a[u];return l&&(i=(0,ka.resolveUrl)(this.opts.uriResolver,i,l)),new sC({schema:a,schemaId:u,root:e,baseId:i})}return tO.call(this,n,o)}}zs.resolveSchema=oC;const H$e=new Set(["properties","patternProperties","enum","dependencies","definitions"]);function tO(e,{baseId:t,schema:n,root:r}){var i;if(((i=e.fragment)===null||i===void 0?void 0:i[0])!=="/")return;for(const a of e.fragment.slice(1).split("/")){if(typeof n=="boolean")return;const u=n[(0,TU.unescapeFragment)(a)];if(u===void 0)return;n=u;const l=typeof n=="object"&&n[this.opts.schemaId];!H$e.has(a)&&l&&(t=(0,ka.resolveUrl)(this.opts.uriResolver,t,l))}let s;if(typeof n!="boolean"&&n.$ref&&!(0,TU.schemaHasRulesButRef)(n,this.RULES)){const a=(0,ka.resolveUrl)(this.opts.uriResolver,t,n.$ref);s=oC.call(this,r,a)}const{schemaId:o}=this.opts;if(s=s||new sC({schema:n,schemaId:o,root:r,baseId:t}),s.schema!==s.root.schema)return s}const W$e="https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#",q$e="Meta-schema for $data reference (JSON AnySchema extension proposal)",G$e="object",Y$e=["$data"],K$e={$data:{type:"string",anyOf:[{format:"relative-json-pointer"},{format:"json-pointer"}]}},Q$e=!1,X$e={$id:W$e,description:q$e,type:G$e,required:Y$e,properties:K$e,additionalProperties:Q$e};var d3={},oN={exports:{}};/** @license URI.js v4.4.1 (c) 2011 Gary Court. License: http://github.com/garycourt/uri-js */(function(e,t){(function(n,r){r(t)})(_o,function(n){function r(){for(var X=arguments.length,z=Array(X),Z=0;Z1){z[0]=z[0].slice(0,-1);for(var he=z.length-1,pe=1;pe= 0x80 (not a basic code point)","invalid-input":"Invalid input"},L=m-y,B=Math.floor,J=String.fromCharCode;function V(X){throw new RangeError(F[X])}function re(X,z){for(var Z=[],he=X.length;he--;)Z[he]=z(X[he]);return Z}function oe(X,z){var Z=X.split("@"),he="";Z.length>1&&(he=Z[0]+"@",X=Z[1]),X=X.replace(R,".");var pe=X.split("."),Ye=re(pe,z).join(".");return he+Ye}function ae(X){for(var z=[],Z=0,he=X.length;Z=55296&&pe<=56319&&Z>1,z+=B(z/Z);z>L*g>>1;pe+=m)z=B(z/L);return B(pe+(L+1)*z/(z+v))},Q=function(z){var Z=[],he=z.length,pe=0,Ye=T,Qe=S,xe=z.lastIndexOf(E);xe<0&&(xe=0);for(var et=0;et=128&&V("not-basic"),Z.push(z.charCodeAt(et));for(var Ft=xe>0?xe+1:0;Ft=he&&V("invalid-input");var mt=ue(z.charCodeAt(Ft++));(mt>=m||mt>B((p-pe)/Jt))&&V("overflow"),pe+=mt*Jt;var kn=Zt<=Qe?y:Zt>=Qe+g?g:Zt-Qe;if(mtB(p/Vn)&&V("overflow"),Jt*=Vn}var Tt=Z.length+1;Qe=W(pe-Be,Tt,Be==0),B(pe/Tt)>p-Ye&&V("overflow"),Ye+=B(pe/Tt),pe%=Tt,Z.splice(pe++,0,Ye)}return String.fromCodePoint.apply(String,Z)},x=function(z){var Z=[];z=ae(z);var he=z.length,pe=T,Ye=0,Qe=S,xe=!0,et=!1,Ft=void 0;try{for(var Be=z[Symbol.iterator](),Jt;!(xe=(Jt=Be.next()).done);xe=!0){var Zt=Jt.value;Zt<128&&Z.push(J(Zt))}}catch(be){et=!0,Ft=be}finally{try{!xe&&Be.return&&Be.return()}finally{if(et)throw Ft}}var mt=Z.length,kn=mt;for(mt&&Z.push(E);kn=pe&&EiB((p-Ye)/Ur)&&V("overflow"),Ye+=(Vn-pe)*Ur,pe=Vn;var Vi=!0,zi=!1,We=void 0;try{for(var en=z[Symbol.iterator](),Hi;!(Vi=(Hi=en.next()).done);Vi=!0){var k=Hi.value;if(kp&&V("overflow"),k==pe){for(var K=Ye,j=m;;j+=m){var te=j<=Qe?y:j>=Qe+g?g:j-Qe;if(K>6|192).toString(16).toUpperCase()+"%"+(z&63|128).toString(16).toUpperCase():Z="%"+(z>>12|224).toString(16).toUpperCase()+"%"+(z>>6&63|128).toString(16).toUpperCase()+"%"+(z&63|128).toString(16).toUpperCase(),Z}function de(X){for(var z="",Z=0,he=X.length;Z=194&&pe<224){if(he-Z>=6){var Ye=parseInt(X.substr(Z+4,2),16);z+=String.fromCharCode((pe&31)<<6|Ye&63)}else z+=X.substr(Z,6);Z+=6}else if(pe>=224){if(he-Z>=9){var Qe=parseInt(X.substr(Z+4,2),16),xe=parseInt(X.substr(Z+7,2),16);z+=String.fromCharCode((pe&15)<<12|(Qe&63)<<6|xe&63)}else z+=X.substr(Z,9);Z+=9}else z+=X.substr(Z,3),Z+=3}return z}function ve(X,z){function Z(he){var pe=de(he);return pe.match(z.UNRESERVED)?pe:he}return X.scheme&&(X.scheme=String(X.scheme).replace(z.PCT_ENCODED,Z).toLowerCase().replace(z.NOT_SCHEME,"")),X.userinfo!==void 0&&(X.userinfo=String(X.userinfo).replace(z.PCT_ENCODED,Z).replace(z.NOT_USERINFO,fe).replace(z.PCT_ENCODED,o)),X.host!==void 0&&(X.host=String(X.host).replace(z.PCT_ENCODED,Z).toLowerCase().replace(z.NOT_HOST,fe).replace(z.PCT_ENCODED,o)),X.path!==void 0&&(X.path=String(X.path).replace(z.PCT_ENCODED,Z).replace(X.scheme?z.NOT_PATH:z.NOT_PATH_NOSCHEME,fe).replace(z.PCT_ENCODED,o)),X.query!==void 0&&(X.query=String(X.query).replace(z.PCT_ENCODED,Z).replace(z.NOT_QUERY,fe).replace(z.PCT_ENCODED,o)),X.fragment!==void 0&&(X.fragment=String(X.fragment).replace(z.PCT_ENCODED,Z).replace(z.NOT_FRAGMENT,fe).replace(z.PCT_ENCODED,o)),X}function Ee(X){return X.replace(/^0*(.*)/,"$1")||"0"}function ge(X,z){var Z=X.match(z.IPV4ADDRESS)||[],he=d(Z,2),pe=he[1];return pe?pe.split(".").map(Ee).join("."):X}function nt(X,z){var Z=X.match(z.IPV6ADDRESS)||[],he=d(Z,3),pe=he[1],Ye=he[2];if(pe){for(var Qe=pe.toLowerCase().split("::").reverse(),xe=d(Qe,2),et=xe[0],Ft=xe[1],Be=Ft?Ft.split(":").map(Ee):[],Jt=et.split(":").map(Ee),Zt=z.IPV4ADDRESS.test(Jt[Jt.length-1]),mt=Zt?7:8,kn=Jt.length-mt,Vn=Array(mt),Tt=0;Tt1){var ds=Vn.slice(0,Er.index),Ei=Vn.slice(Er.index+Er.length);kr=ds.join(":")+"::"+Ei.join(":")}else kr=Vn.join(":");return Ye&&(kr+="%"+Ye),kr}else return X}var Je=/^(?:([^:\/?#]+):)?(?:\/\/((?:([^\/?#@]*)@)?(\[[^\/?#\]]+\]|[^\/?#:]*)(?:\:(\d*))?))?([^?#]*)(?:\?([^#]*))?(?:#((?:.|\n|\r)*))?/i,yt="".match(/(){0}/)[1]===void 0;function ke(X){var z=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},Z={},he=z.iri!==!1?f:c;z.reference==="suffix"&&(X=(z.scheme?z.scheme+":":"")+"//"+X);var pe=X.match(Je);if(pe){yt?(Z.scheme=pe[1],Z.userinfo=pe[3],Z.host=pe[4],Z.port=parseInt(pe[5],10),Z.path=pe[6]||"",Z.query=pe[7],Z.fragment=pe[8],isNaN(Z.port)&&(Z.port=pe[5])):(Z.scheme=pe[1]||void 0,Z.userinfo=X.indexOf("@")!==-1?pe[3]:void 0,Z.host=X.indexOf("//")!==-1?pe[4]:void 0,Z.port=parseInt(pe[5],10),Z.path=pe[6]||"",Z.query=X.indexOf("?")!==-1?pe[7]:void 0,Z.fragment=X.indexOf("#")!==-1?pe[8]:void 0,isNaN(Z.port)&&(Z.port=X.match(/\/\/(?:.|\n)*\:(?:\/|\?|\#|$)/)?pe[4]:void 0)),Z.host&&(Z.host=nt(ge(Z.host,he),he)),Z.scheme===void 0&&Z.userinfo===void 0&&Z.host===void 0&&Z.port===void 0&&!Z.path&&Z.query===void 0?Z.reference="same-document":Z.scheme===void 0?Z.reference="relative":Z.fragment===void 0?Z.reference="absolute":Z.reference="uri",z.reference&&z.reference!=="suffix"&&z.reference!==Z.reference&&(Z.error=Z.error||"URI is not a "+z.reference+" reference.");var Ye=ce[(z.scheme||Z.scheme||"").toLowerCase()];if(!z.unicodeSupport&&(!Ye||!Ye.unicodeSupport)){if(Z.host&&(z.domainHost||Ye&&Ye.domainHost))try{Z.host=q.toASCII(Z.host.replace(he.PCT_ENCODED,de).toLowerCase())}catch(Qe){Z.error=Z.error||"Host's domain name can not be converted to ASCII via punycode: "+Qe}ve(Z,c)}else ve(Z,he);Ye&&Ye.parse&&Ye.parse(Z,z)}else Z.error=Z.error||"URI can not be parsed.";return Z}function at(X,z){var Z=z.iri!==!1?f:c,he=[];return X.userinfo!==void 0&&(he.push(X.userinfo),he.push("@")),X.host!==void 0&&he.push(nt(ge(String(X.host),Z),Z).replace(Z.IPV6ADDRESS,function(pe,Ye,Qe){return"["+Ye+(Qe?"%25"+Qe:"")+"]"})),(typeof X.port=="number"||typeof X.port=="string")&&(he.push(":"),he.push(String(X.port))),he.length?he.join(""):void 0}var St=/^\.\.?\//,cn=/^\/\.(\/|$)/,bn=/^\/\.\.(\/|$)/,He=/^\/?(?:.|\n)*?(?=\/|$)/;function Fe(X){for(var z=[];X.length;)if(X.match(St))X=X.replace(St,"");else if(X.match(cn))X=X.replace(cn,"/");else if(X.match(bn))X=X.replace(bn,"/"),z.pop();else if(X==="."||X==="..")X="";else{var Z=X.match(He);if(Z){var he=Z[0];X=X.slice(he.length),z.push(he)}else throw new Error("Unexpected dot segment condition")}return z.join("")}function st(X){var z=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},Z=z.iri?f:c,he=[],pe=ce[(z.scheme||X.scheme||"").toLowerCase()];if(pe&&pe.serialize&&pe.serialize(X,z),X.host&&!Z.IPV6ADDRESS.test(X.host)){if(z.domainHost||pe&&pe.domainHost)try{X.host=z.iri?q.toUnicode(X.host):q.toASCII(X.host.replace(Z.PCT_ENCODED,de).toLowerCase())}catch(xe){X.error=X.error||"Host's domain name can not be converted to "+(z.iri?"Unicode":"ASCII")+" via punycode: "+xe}}ve(X,Z),z.reference!=="suffix"&&X.scheme&&(he.push(X.scheme),he.push(":"));var Ye=at(X,z);if(Ye!==void 0&&(z.reference!=="suffix"&&he.push("//"),he.push(Ye),X.path&&X.path.charAt(0)!=="/"&&he.push("/")),X.path!==void 0){var Qe=X.path;!z.absolutePath&&(!pe||!pe.absolutePath)&&(Qe=Fe(Qe)),Ye===void 0&&(Qe=Qe.replace(/^\/\//,"/%2F")),he.push(Qe)}return X.query!==void 0&&(he.push("?"),he.push(X.query)),X.fragment!==void 0&&(he.push("#"),he.push(X.fragment)),he.join("")}function dt(X,z){var Z=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},he=arguments[3],pe={};return he||(X=ke(st(X,Z),Z),z=ke(st(z,Z),Z)),Z=Z||{},!Z.tolerant&&z.scheme?(pe.scheme=z.scheme,pe.userinfo=z.userinfo,pe.host=z.host,pe.port=z.port,pe.path=Fe(z.path||""),pe.query=z.query):(z.userinfo!==void 0||z.host!==void 0||z.port!==void 0?(pe.userinfo=z.userinfo,pe.host=z.host,pe.port=z.port,pe.path=Fe(z.path||""),pe.query=z.query):(z.path?(z.path.charAt(0)==="/"?pe.path=Fe(z.path):((X.userinfo!==void 0||X.host!==void 0||X.port!==void 0)&&!X.path?pe.path="/"+z.path:X.path?pe.path=X.path.slice(0,X.path.lastIndexOf("/")+1)+z.path:pe.path=z.path,pe.path=Fe(pe.path)),pe.query=z.query):(pe.path=X.path,z.query!==void 0?pe.query=z.query:pe.query=X.query),pe.userinfo=X.userinfo,pe.host=X.host,pe.port=X.port),pe.scheme=X.scheme),pe.fragment=z.fragment,pe}function At(X,z,Z){var he=u({scheme:"null"},Z);return st(dt(ke(X,he),ke(z,he),he,!0),he)}function Kt(X,z){return typeof X=="string"?X=st(ke(X,z),z):s(X)==="object"&&(X=ke(st(X,z),z)),X}function me(X,z,Z){return typeof X=="string"?X=st(ke(X,Z),Z):s(X)==="object"&&(X=st(X,Z)),typeof z=="string"?z=st(ke(z,Z),Z):s(z)==="object"&&(z=st(z,Z)),X===z}function Se(X,z){return X&&X.toString().replace(!z||!z.iri?c.ESCAPE:f.ESCAPE,fe)}function Le(X,z){return X&&X.toString().replace(!z||!z.iri?c.PCT_ENCODED:f.PCT_ENCODED,de)}var Ke={scheme:"http",domainHost:!0,parse:function(z,Z){return z.host||(z.error=z.error||"HTTP URIs must have a host."),z},serialize:function(z,Z){var he=String(z.scheme).toLowerCase()==="https";return(z.port===(he?443:80)||z.port==="")&&(z.port=void 0),z.path||(z.path="/"),z}},ct={scheme:"https",domainHost:Ke.domainHost,parse:Ke.parse,serialize:Ke.serialize};function In(X){return typeof X.secure=="boolean"?X.secure:String(X.scheme).toLowerCase()==="wss"}var Me={scheme:"ws",domainHost:!0,parse:function(z,Z){var he=z;return he.secure=In(he),he.resourceName=(he.path||"/")+(he.query?"?"+he.query:""),he.path=void 0,he.query=void 0,he},serialize:function(z,Z){if((z.port===(In(z)?443:80)||z.port==="")&&(z.port=void 0),typeof z.secure=="boolean"&&(z.scheme=z.secure?"wss":"ws",z.secure=void 0),z.resourceName){var he=z.resourceName.split("?"),pe=d(he,2),Ye=pe[0],Qe=pe[1];z.path=Ye&&Ye!=="/"?Ye:void 0,z.query=Qe,z.resourceName=void 0}return z.fragment=void 0,z}},Ze={scheme:"wss",domainHost:Me.domainHost,parse:Me.parse,serialize:Me.serialize},ot={},Gt="[A-Za-z0-9\\-\\.\\_\\~\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF]",pt="[0-9A-Fa-f]",_r=i(i("%[EFef]"+pt+"%"+pt+pt+"%"+pt+pt)+"|"+i("%[89A-Fa-f]"+pt+"%"+pt+pt)+"|"+i("%"+pt+pt)),mn="[A-Za-z0-9\\!\\$\\%\\'\\*\\+\\-\\^\\_\\`\\{\\|\\}\\~]",qn="[\\!\\$\\%\\'\\(\\)\\*\\+\\,\\-\\.0-9\\<\\>A-Z\\x5E-\\x7E]",cs=r(qn,'[\\"\\\\]'),xs="[\\!\\$\\'\\(\\)\\*\\+\\,\\;\\:\\@]",ui=new RegExp(Gt,"g"),Nn=new RegExp(_r,"g"),ba=new RegExp(r("[^]",mn,"[\\.]",'[\\"]',cs),"g"),Nr=new RegExp(r("[^]",Gt,xs),"g"),br=Nr;function $n(X){var z=de(X);return z.match(ui)?z:X}var fn={scheme:"mailto",parse:function(z,Z){var he=z,pe=he.to=he.path?he.path.split(","):[];if(he.path=void 0,he.query){for(var Ye=!1,Qe={},xe=he.query.split("&"),et=0,Ft=xe.length;etnew RegExp(P,W);h.code="new RegExp";const p=["removeAdditional","useDefaults","coerceTypes"],m=new Set(["validate","serialize","parse","wrapper","root","schema","keyword","pattern","formats","validate$data","func","obj","Error"]),y={errorDataPath:"",format:"`validateFormats: false` can be used instead.",nullable:'"nullable" keyword is supported by default.',jsonPointers:"Deprecated jsPropertySyntax can be used instead.",extendRefs:"Deprecated ignoreKeywordsWithRef can be used instead.",missingRefs:"Pass empty schema with $id that should be ignored to ajv.addSchema.",processCode:"Use option `code: {process: (code, schemaEnv: object) => string}`",sourceCode:"Use option `code: {source: true}`",strictDefaults:"It is default now, see option `strict`.",strictKeywords:"It is default now, see option `strict`.",uniqueItems:'"uniqueItems" keyword is always validated.',unknownFormats:"Disable strict mode or pass `true` to `ajv.addFormat` (or `formats` option).",cache:"Map is used as cache, schema object as key.",serialize:"Map is used as cache, schema object as key.",ajvErrors:"It is default now."},g={ignoreKeywordsWithRef:"",jsPropertySyntax:"",unicode:'"minLength"/"maxLength" account for unicode characters by default.'},v=200;function b(P){var W,Q,x,O,$,q,ce,fe,de,ve,Ee,ge,nt,Je,yt,ke,at,St,cn,bn,He,Fe,st,dt,At;const Kt=P.strict,me=(W=P.code)===null||W===void 0?void 0:W.optimize,Se=me===!0||me===void 0?1:me||0,Le=(x=(Q=P.code)===null||Q===void 0?void 0:Q.regExp)!==null&&x!==void 0?x:h,Ke=(O=P.uriResolver)!==null&&O!==void 0?O:d.default;return{strictSchema:(q=($=P.strictSchema)!==null&&$!==void 0?$:Kt)!==null&&q!==void 0?q:!0,strictNumbers:(fe=(ce=P.strictNumbers)!==null&&ce!==void 0?ce:Kt)!==null&&fe!==void 0?fe:!0,strictTypes:(ve=(de=P.strictTypes)!==null&&de!==void 0?de:Kt)!==null&&ve!==void 0?ve:"log",strictTuples:(ge=(Ee=P.strictTuples)!==null&&Ee!==void 0?Ee:Kt)!==null&&ge!==void 0?ge:"log",strictRequired:(Je=(nt=P.strictRequired)!==null&&nt!==void 0?nt:Kt)!==null&&Je!==void 0?Je:!1,code:P.code?{...P.code,optimize:Se,regExp:Le}:{optimize:Se,regExp:Le},loopRequired:(yt=P.loopRequired)!==null&&yt!==void 0?yt:v,loopEnum:(ke=P.loopEnum)!==null&&ke!==void 0?ke:v,meta:(at=P.meta)!==null&&at!==void 0?at:!0,messages:(St=P.messages)!==null&&St!==void 0?St:!0,inlineRefs:(cn=P.inlineRefs)!==null&&cn!==void 0?cn:!0,schemaId:(bn=P.schemaId)!==null&&bn!==void 0?bn:"$id",addUsedSchema:(He=P.addUsedSchema)!==null&&He!==void 0?He:!0,validateSchema:(Fe=P.validateSchema)!==null&&Fe!==void 0?Fe:!0,validateFormats:(st=P.validateFormats)!==null&&st!==void 0?st:!0,unicodeRegExp:(dt=P.unicodeRegExp)!==null&&dt!==void 0?dt:!0,int32range:(At=P.int32range)!==null&&At!==void 0?At:!0,uriResolver:Ke}}class S{constructor(W={}){this.schemas={},this.refs={},this.formats={},this._compilations=new Set,this._loading={},this._cache=new Map,W=this.opts={...W,...b(W)};const{es5:Q,lines:x}=this.opts.code;this.scope=new a.ValueScope({scope:{},prefixes:m,es5:Q,lines:x}),this.logger=B(W.logger);const O=W.validateFormats;W.validateFormats=!1,this.RULES=(0,s.getRules)(),T.call(this,y,W,"NOT SUPPORTED"),T.call(this,g,W,"DEPRECATED","warn"),this._metaOpts=F.call(this),W.formats&&A.call(this),this._addVocabularies(),this._addDefaultMetaSchema(),W.keywords&&R.call(this,W.keywords),typeof W.meta=="object"&&this.addMetaSchema(W.meta),I.call(this),W.validateFormats=O}_addVocabularies(){this.addKeyword("$async")}_addDefaultMetaSchema(){const{$data:W,meta:Q,schemaId:x}=this.opts;let O=f;x==="id"&&(O={...f},O.id=O.$id,delete O.$id),Q&&W&&this.addMetaSchema(O,O[x],!1)}defaultMeta(){const{meta:W,schemaId:Q}=this.opts;return this.opts.defaultMeta=typeof W=="object"?W[Q]||W:void 0}validate(W,Q){let x;if(typeof W=="string"){if(x=this.getSchema(W),!x)throw new Error(`no schema with key or ref "${W}"`)}else x=this.compile(W);const O=x(Q);return"$async"in x||(this.errors=x.errors),O}compile(W,Q){const x=this._addSchema(W,Q);return x.validate||this._compileSchemaEnv(x)}compileAsync(W,Q){if(typeof this.opts.loadSchema!="function")throw new Error("options.loadSchema should be a function");const{loadSchema:x}=this.opts;return O.call(this,W,Q);async function O(ve,Ee){await $.call(this,ve.$schema);const ge=this._addSchema(ve,Ee);return ge.validate||q.call(this,ge)}async function $(ve){ve&&!this.getSchema(ve)&&await O.call(this,{$ref:ve},!0)}async function q(ve){try{return this._compileSchemaEnv(ve)}catch(Ee){if(!(Ee instanceof i.default))throw Ee;return ce.call(this,Ee),await fe.call(this,Ee.missingSchema),q.call(this,ve)}}function ce({missingSchema:ve,missingRef:Ee}){if(this.refs[ve])throw new Error(`AnySchema ${ve} is loaded but ${Ee} cannot be resolved`)}async function fe(ve){const Ee=await de.call(this,ve);this.refs[ve]||await $.call(this,Ee.$schema),this.refs[ve]||this.addSchema(Ee,ve,Q)}async function de(ve){const Ee=this._loading[ve];if(Ee)return Ee;try{return await(this._loading[ve]=x(ve))}finally{delete this._loading[ve]}}}addSchema(W,Q,x,O=this.opts.validateSchema){if(Array.isArray(W)){for(const q of W)this.addSchema(q,void 0,x,O);return this}let $;if(typeof W=="object"){const{schemaId:q}=this.opts;if($=W[q],$!==void 0&&typeof $!="string")throw new Error(`schema ${q} must be string`)}return Q=(0,u.normalizeId)(Q||$),this._checkUnique(Q),this.schemas[Q]=this._addSchema(W,x,Q,O,!0),this}addMetaSchema(W,Q,x=this.opts.validateSchema){return this.addSchema(W,Q,!0,x),this}validateSchema(W,Q){if(typeof W=="boolean")return!0;let x;if(x=W.$schema,x!==void 0&&typeof x!="string")throw new Error("$schema must be a string");if(x=x||this.opts.defaultMeta||this.defaultMeta(),!x)return this.logger.warn("meta-schema not available"),this.errors=null,!0;const O=this.validate(x,W);if(!O&&Q){const $="schema is invalid: "+this.errorsText();if(this.opts.validateSchema==="log")this.logger.error($);else throw new Error($)}return O}getSchema(W){let Q;for(;typeof(Q=E.call(this,W))=="string";)W=Q;if(Q===void 0){const{schemaId:x}=this.opts,O=new o.SchemaEnv({schema:{},schemaId:x});if(Q=o.resolveSchema.call(this,O,W),!Q)return;this.refs[W]=Q}return Q.validate||this._compileSchemaEnv(Q)}removeSchema(W){if(W instanceof RegExp)return this._removeAllSchemas(this.schemas,W),this._removeAllSchemas(this.refs,W),this;switch(typeof W){case"undefined":return this._removeAllSchemas(this.schemas),this._removeAllSchemas(this.refs),this._cache.clear(),this;case"string":{const Q=E.call(this,W);return typeof Q=="object"&&this._cache.delete(Q.schema),delete this.schemas[W],delete this.refs[W],this}case"object":{const Q=W;this._cache.delete(Q);let x=W[this.opts.schemaId];return x&&(x=(0,u.normalizeId)(x),delete this.schemas[x],delete this.refs[x]),this}default:throw new Error("ajv.removeSchema: invalid parameter")}}addVocabulary(W){for(const Q of W)this.addKeyword(Q);return this}addKeyword(W,Q){let x;if(typeof W=="string")x=W,typeof Q=="object"&&(this.logger.warn("these parameters are deprecated, see docs for addKeyword"),Q.keyword=x);else if(typeof W=="object"&&Q===void 0){if(Q=W,x=Q.keyword,Array.isArray(x)&&!x.length)throw new Error("addKeywords: keyword must be string or non-empty array")}else throw new Error("invalid addKeywords parameters");if(V.call(this,x,Q),!Q)return(0,c.eachItem)(x,$=>re.call(this,$)),this;ae.call(this,Q);const O={...Q,type:(0,l.getJSONTypes)(Q.type),schemaType:(0,l.getJSONTypes)(Q.schemaType)};return(0,c.eachItem)(x,O.type.length===0?$=>re.call(this,$,O):$=>O.type.forEach(q=>re.call(this,$,O,q))),this}getKeyword(W){const Q=this.RULES.all[W];return typeof Q=="object"?Q.definition:!!Q}removeKeyword(W){const{RULES:Q}=this;delete Q.keywords[W],delete Q.all[W];for(const x of Q.rules){const O=x.rules.findIndex($=>$.keyword===W);O>=0&&x.rules.splice(O,1)}return this}addFormat(W,Q){return typeof Q=="string"&&(Q=new RegExp(Q)),this.formats[W]=Q,this}errorsText(W=this.errors,{separator:Q=", ",dataVar:x="data"}={}){return!W||W.length===0?"No errors":W.map(O=>`${x}${O.instancePath} ${O.message}`).reduce((O,$)=>O+Q+$)}$dataMetaSchema(W,Q){const x=this.RULES.all;W=JSON.parse(JSON.stringify(W));for(const O of Q){const $=O.split("/").slice(1);let q=W;for(const ce of $)q=q[ce];for(const ce in x){const fe=x[ce];if(typeof fe!="object")continue;const{$data:de}=fe.definition,ve=q[ce];de&&ve&&(q[ce]=ue(ve))}}return W}_removeAllSchemas(W,Q){for(const x in W){const O=W[x];(!Q||Q.test(x))&&(typeof O=="string"?delete W[x]:O&&!O.meta&&(this._cache.delete(O.schema),delete W[x]))}}_addSchema(W,Q,x,O=this.opts.validateSchema,$=this.opts.addUsedSchema){let q;const{schemaId:ce}=this.opts;if(typeof W=="object")q=W[ce];else{if(this.opts.jtd)throw new Error("schema must be object");if(typeof W!="boolean")throw new Error("schema must be object or boolean")}let fe=this._cache.get(W);if(fe!==void 0)return fe;x=(0,u.normalizeId)(q||x);const de=u.getSchemaRefs.call(this,W,x);return fe=new o.SchemaEnv({schema:W,schemaId:ce,meta:Q,baseId:x,localRefs:de}),this._cache.set(fe.schema,fe),$&&!x.startsWith("#")&&(x&&this._checkUnique(x),this.refs[x]=fe),O&&this.validateSchema(W,!0),fe}_checkUnique(W){if(this.schemas[W]||this.refs[W])throw new Error(`schema with key or id "${W}" already exists`)}_compileSchemaEnv(W){if(W.meta?this._compileMetaSchema(W):o.compileSchema.call(this,W),!W.validate)throw new Error("ajv implementation error");return W.validate}_compileMetaSchema(W){const Q=this.opts;this.opts=this._metaOpts;try{o.compileSchema.call(this,W)}finally{this.opts=Q}}}e.default=S,S.ValidationError=r.default,S.MissingRefError=i.default;function T(P,W,Q,x="error"){for(const O in P){const $=O;$ in W&&this.logger[x](`${Q}: option ${O}. ${P[$]}`)}}function E(P){return P=(0,u.normalizeId)(P),this.schemas[P]||this.refs[P]}function I(){const P=this.opts.schemas;if(P)if(Array.isArray(P))this.addSchema(P);else for(const W in P)this.addSchema(P[W],W)}function A(){for(const P in this.opts.formats){const W=this.opts.formats[P];W&&this.addFormat(P,W)}}function R(P){if(Array.isArray(P)){this.addVocabulary(P);return}this.logger.warn("keywords option as map is deprecated, pass array");for(const W in P){const Q=P[W];Q.keyword||(Q.keyword=W),this.addKeyword(Q)}}function F(){const P={...this.opts};for(const W of p)delete P[W];return P}const L={log(){},warn(){},error(){}};function B(P){if(P===!1)return L;if(P===void 0)return console;if(P.log&&P.warn&&P.error)return P;throw new Error("logger must implement log, warn and error methods")}const J=/^[a-z_$][a-z0-9_$:-]*$/i;function V(P,W){const{RULES:Q}=this;if((0,c.eachItem)(P,x=>{if(Q.keywords[x])throw new Error(`Keyword ${x} is already defined`);if(!J.test(x))throw new Error(`Keyword ${x} has invalid name`)}),!!W&&W.$data&&!("code"in W||"validate"in W))throw new Error('$data keyword must have "code" or "validate" function')}function re(P,W,Q){var x;const O=W==null?void 0:W.post;if(Q&&O)throw new Error('keyword with "post" flag cannot have "type"');const{RULES:$}=this;let q=O?$.post:$.rules.find(({type:fe})=>fe===Q);if(q||(q={type:Q,rules:[]},$.rules.push(q)),$.keywords[P]=!0,!W)return;const ce={keyword:P,definition:{...W,type:(0,l.getJSONTypes)(W.type),schemaType:(0,l.getJSONTypes)(W.schemaType)}};W.before?oe.call(this,q,ce,W.before):q.rules.push(ce),$.all[P]=ce,(x=W.implements)===null||x===void 0||x.forEach(fe=>this.addKeyword(fe))}function oe(P,W,Q){const x=P.rules.findIndex(O=>O.keyword===Q);x>=0?P.rules.splice(x,0,W):(P.rules.push(W),this.logger.warn(`rule ${Q} is not defined`))}function ae(P){let{metaSchema:W}=P;W!==void 0&&(P.$data&&this.opts.$data&&(W=ue(W)),P.validateSchema=this.compile(W,!0))}const ee={$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"};function ue(P){return{anyOf:[P,ee]}}})(Dte);var h3={},p3={},m3={};Object.defineProperty(m3,"__esModule",{value:!0});const Z$e={keyword:"id",code(){throw new Error('NOT SUPPORTED: keyword "id", use "$id" for schema ID')}};m3.default=Z$e;var dh={};Object.defineProperty(dh,"__esModule",{value:!0});dh.callRef=dh.getValidate=void 0;const e3e=H_,IU=Qt,ks=Xt,tp=dl,xU=zs,Eb=_n,t3e={keyword:"$ref",schemaType:"string",code(e){const{gen:t,schema:n,it:r}=e,{baseId:i,schemaEnv:s,validateName:o,opts:a,self:u}=r,{root:l}=s;if((n==="#"||n==="#/")&&i===l.baseId)return f();const c=xU.resolveRef.call(u,l,i,n);if(c===void 0)throw new e3e.default(r.opts.uriResolver,i,n);if(c instanceof xU.SchemaEnv)return d(c);return h(c);function f(){if(s===l)return Nw(e,o,s,s.$async);const p=t.scopeValue("root",{ref:l});return Nw(e,(0,ks._)`${p}.validate`,l,l.$async)}function d(p){const m=sne(e,p);Nw(e,m,p,p.$async)}function h(p){const m=t.scopeValue("schema",a.code.source===!0?{ref:p,code:(0,ks.stringify)(p)}:{ref:p}),y=t.name("valid"),g=e.subschema({schema:p,dataTypes:[],schemaPath:ks.nil,topSchemaRef:m,errSchemaPath:n},y);e.mergeEvaluated(g),e.ok(y)}}};function sne(e,t){const{gen:n}=e;return t.validate?n.scopeValue("validate",{ref:t.validate}):(0,ks._)`${n.scopeValue("wrapper",{ref:t})}.validate`}dh.getValidate=sne;function Nw(e,t,n,r){const{gen:i,it:s}=e,{allErrors:o,schemaEnv:a,opts:u}=s,l=u.passContext?tp.default.this:ks.nil;r?c():f();function c(){if(!a.$async)throw new Error("async schema referenced by sync schema");const p=i.let("valid");i.try(()=>{i.code((0,ks._)`await ${(0,IU.callValidateCode)(e,t,l)}`),h(t),o||i.assign(p,!0)},m=>{i.if((0,ks._)`!(${m} instanceof ${s.ValidationError})`,()=>i.throw(m)),d(m),o||i.assign(p,!1)}),e.ok(p)}function f(){e.result((0,IU.callValidateCode)(e,t,l),()=>h(t),()=>d(t))}function d(p){const m=(0,ks._)`${p}.errors`;i.assign(tp.default.vErrors,(0,ks._)`${tp.default.vErrors} === null ? ${m} : ${tp.default.vErrors}.concat(${m})`),i.assign(tp.default.errors,(0,ks._)`${tp.default.vErrors}.length`)}function h(p){var m;if(!s.opts.unevaluated)return;const y=(m=n==null?void 0:n.validate)===null||m===void 0?void 0:m.evaluated;if(s.props!==!0)if(y&&!y.dynamicProps)y.props!==void 0&&(s.props=Eb.mergeEvaluated.props(i,y.props,s.props));else{const g=i.var("props",(0,ks._)`${p}.evaluated.props`);s.props=Eb.mergeEvaluated.props(i,g,s.props,ks.Name)}if(s.items!==!0)if(y&&!y.dynamicItems)y.items!==void 0&&(s.items=Eb.mergeEvaluated.items(i,y.items,s.items));else{const g=i.var("items",(0,ks._)`${p}.evaluated.items`);s.items=Eb.mergeEvaluated.items(i,g,s.items,ks.Name)}}}dh.callRef=Nw;dh.default=t3e;Object.defineProperty(p3,"__esModule",{value:!0});const n3e=m3,r3e=dh,i3e=["$schema","$id","$defs","$vocabulary",{keyword:"$comment"},"definitions",n3e.default,r3e.default];p3.default=i3e;var g3={},y3={};Object.defineProperty(y3,"__esModule",{value:!0});const IT=Xt,Sc=IT.operators,xT={maximum:{okStr:"<=",ok:Sc.LTE,fail:Sc.GT},minimum:{okStr:">=",ok:Sc.GTE,fail:Sc.LT},exclusiveMaximum:{okStr:"<",ok:Sc.LT,fail:Sc.GTE},exclusiveMinimum:{okStr:">",ok:Sc.GT,fail:Sc.LTE}},s3e={message:({keyword:e,schemaCode:t})=>(0,IT.str)`must be ${xT[e].okStr} ${t}`,params:({keyword:e,schemaCode:t})=>(0,IT._)`{comparison: ${xT[e].okStr}, limit: ${t}}`},o3e={keyword:Object.keys(xT),type:"number",schemaType:"number",$data:!0,error:s3e,code(e){const{keyword:t,data:n,schemaCode:r}=e;e.fail$data((0,IT._)`${n} ${xT[t].fail} ${r} || isNaN(${n})`)}};y3.default=o3e;var v3={};Object.defineProperty(v3,"__esModule",{value:!0});const Ty=Xt,a3e={message:({schemaCode:e})=>(0,Ty.str)`must be multiple of ${e}`,params:({schemaCode:e})=>(0,Ty._)`{multipleOf: ${e}}`},u3e={keyword:"multipleOf",type:"number",schemaType:"number",$data:!0,error:a3e,code(e){const{gen:t,data:n,schemaCode:r,it:i}=e,s=i.opts.multipleOfPrecision,o=t.let("res"),a=s?(0,Ty._)`Math.abs(Math.round(${o}) - ${o}) > 1e-${s}`:(0,Ty._)`${o} !== parseInt(${o})`;e.fail$data((0,Ty._)`(${r} === 0 || (${o} = ${n}/${r}, ${a}))`)}};v3.default=u3e;var _3={},b3={};Object.defineProperty(b3,"__esModule",{value:!0});function one(e){const t=e.length;let n=0,r=0,i;for(;r=55296&&i<=56319&&r(0,Td._)`{limit: ${e}}`},d3e={keyword:["maxLength","minLength"],type:"string",schemaType:"number",$data:!0,error:f3e,code(e){const{keyword:t,data:n,schemaCode:r,it:i}=e,s=t==="maxLength"?Td.operators.GT:Td.operators.LT,o=i.opts.unicode===!1?(0,Td._)`${n}.length`:(0,Td._)`${(0,l3e.useFunc)(e.gen,c3e.default)}(${n})`;e.fail$data((0,Td._)`${o} ${s} ${r}`)}};_3.default=d3e;var w3={};Object.defineProperty(w3,"__esModule",{value:!0});const h3e=Qt,CT=Xt,p3e={message:({schemaCode:e})=>(0,CT.str)`must match pattern "${e}"`,params:({schemaCode:e})=>(0,CT._)`{pattern: ${e}}`},m3e={keyword:"pattern",type:"string",schemaType:"string",$data:!0,error:p3e,code(e){const{data:t,$data:n,schema:r,schemaCode:i,it:s}=e,o=s.opts.unicodeRegExp?"u":"",a=n?(0,CT._)`(new RegExp(${i}, ${o}))`:(0,h3e.usePattern)(e,r);e.fail$data((0,CT._)`!${a}.test(${t})`)}};w3.default=m3e;var E3={};Object.defineProperty(E3,"__esModule",{value:!0});const Iy=Xt,g3e={message({keyword:e,schemaCode:t}){const n=e==="maxProperties"?"more":"fewer";return(0,Iy.str)`must NOT have ${n} than ${t} properties`},params:({schemaCode:e})=>(0,Iy._)`{limit: ${e}}`},y3e={keyword:["maxProperties","minProperties"],type:"object",schemaType:"number",$data:!0,error:g3e,code(e){const{keyword:t,data:n,schemaCode:r}=e,i=t==="maxProperties"?Iy.operators.GT:Iy.operators.LT;e.fail$data((0,Iy._)`Object.keys(${n}).length ${i} ${r}`)}};E3.default=y3e;var S3={};Object.defineProperty(S3,"__esModule",{value:!0});const w0=Qt,xy=Xt,v3e=_n,_3e={message:({params:{missingProperty:e}})=>(0,xy.str)`must have required property '${e}'`,params:({params:{missingProperty:e}})=>(0,xy._)`{missingProperty: ${e}}`},b3e={keyword:"required",type:"object",schemaType:"array",$data:!0,error:_3e,code(e){const{gen:t,schema:n,schemaCode:r,data:i,$data:s,it:o}=e,{opts:a}=o;if(!s&&n.length===0)return;const u=n.length>=a.loopRequired;if(o.allErrors?l():c(),a.strictRequired){const h=e.parentSchema.properties,{definedProperties:p}=e.it;for(const m of n)if((h==null?void 0:h[m])===void 0&&!p.has(m)){const y=o.schemaEnv.baseId+o.errSchemaPath,g=`required property "${m}" is not defined at "${y}" (strictRequired)`;(0,v3e.checkStrictMode)(o,g,o.opts.strictRequired)}}function l(){if(u||s)e.block$data(xy.nil,f);else for(const h of n)(0,w0.checkReportMissingProp)(e,h)}function c(){const h=t.let("missing");if(u||s){const p=t.let("valid",!0);e.block$data(p,()=>d(h,p)),e.ok(p)}else t.if((0,w0.checkMissingProp)(e,n,h)),(0,w0.reportMissingProp)(e,h),t.else()}function f(){t.forOf("prop",r,h=>{e.setParams({missingProperty:h}),t.if((0,w0.noPropertyInData)(t,i,h,a.ownProperties),()=>e.error())})}function d(h,p){e.setParams({missingProperty:h}),t.forOf(h,r,()=>{t.assign(p,(0,w0.propertyInData)(t,i,h,a.ownProperties)),t.if((0,xy.not)(p),()=>{e.error(),t.break()})},xy.nil)}}};S3.default=b3e;var T3={};Object.defineProperty(T3,"__esModule",{value:!0});const Cy=Xt,w3e={message({keyword:e,schemaCode:t}){const n=e==="maxItems"?"more":"fewer";return(0,Cy.str)`must NOT have ${n} than ${t} items`},params:({schemaCode:e})=>(0,Cy._)`{limit: ${e}}`},E3e={keyword:["maxItems","minItems"],type:"array",schemaType:"number",$data:!0,error:w3e,code(e){const{keyword:t,data:n,schemaCode:r}=e,i=t==="maxItems"?Cy.operators.GT:Cy.operators.LT;e.fail$data((0,Cy._)`${n}.length ${i} ${r}`)}};T3.default=E3e;var I3={},W_={};Object.defineProperty(W_,"__esModule",{value:!0});const ane=u3;ane.code='require("ajv/dist/runtime/equal").default';W_.default=ane;Object.defineProperty(I3,"__esModule",{value:!0});const nO=V_,xi=Xt,S3e=_n,T3e=W_,I3e={message:({params:{i:e,j:t}})=>(0,xi.str)`must NOT have duplicate items (items ## ${t} and ${e} are identical)`,params:({params:{i:e,j:t}})=>(0,xi._)`{i: ${e}, j: ${t}}`},x3e={keyword:"uniqueItems",type:"array",schemaType:"boolean",$data:!0,error:I3e,code(e){const{gen:t,data:n,$data:r,schema:i,parentSchema:s,schemaCode:o,it:a}=e;if(!r&&!i)return;const u=t.let("valid"),l=s.items?(0,nO.getSchemaTypes)(s.items):[];e.block$data(u,c,(0,xi._)`${o} === false`),e.ok(u);function c(){const p=t.let("i",(0,xi._)`${n}.length`),m=t.let("j");e.setParams({i:p,j:m}),t.assign(u,!0),t.if((0,xi._)`${p} > 1`,()=>(f()?d:h)(p,m))}function f(){return l.length>0&&!l.some(p=>p==="object"||p==="array")}function d(p,m){const y=t.name("item"),g=(0,nO.checkDataTypes)(l,y,a.opts.strictNumbers,nO.DataType.Wrong),v=t.const("indices",(0,xi._)`{}`);t.for((0,xi._)`;${p}--;`,()=>{t.let(y,(0,xi._)`${n}[${p}]`),t.if(g,(0,xi._)`continue`),l.length>1&&t.if((0,xi._)`typeof ${y} == "string"`,(0,xi._)`${y} += "_"`),t.if((0,xi._)`typeof ${v}[${y}] == "number"`,()=>{t.assign(m,(0,xi._)`${v}[${y}]`),e.error(),t.assign(u,!1).break()}).code((0,xi._)`${v}[${y}] = ${p}`)})}function h(p,m){const y=(0,S3e.useFunc)(t,T3e.default),g=t.name("outer");t.label(g).for((0,xi._)`;${p}--;`,()=>t.for((0,xi._)`${m} = ${p}; ${m}--;`,()=>t.if((0,xi._)`${y}(${n}[${p}], ${n}[${m}])`,()=>{e.error(),t.assign(u,!1).break(g)})))}}};I3.default=x3e;var x3={};Object.defineProperty(x3,"__esModule",{value:!0});const aN=Xt,C3e=_n,A3e=W_,P3e={message:"must be equal to constant",params:({schemaCode:e})=>(0,aN._)`{allowedValue: ${e}}`},O3e={keyword:"const",$data:!0,error:P3e,code(e){const{gen:t,data:n,$data:r,schemaCode:i,schema:s}=e;r||s&&typeof s=="object"?e.fail$data((0,aN._)`!${(0,C3e.useFunc)(t,A3e.default)}(${n}, ${i})`):e.fail((0,aN._)`${s} !== ${n}`)}};x3.default=O3e;var C3={};Object.defineProperty(C3,"__esModule",{value:!0});const K0=Xt,R3e=_n,N3e=W_,k3e={message:"must be equal to one of the allowed values",params:({schemaCode:e})=>(0,K0._)`{allowedValues: ${e}}`},D3e={keyword:"enum",schemaType:"array",$data:!0,error:k3e,code(e){const{gen:t,data:n,$data:r,schema:i,schemaCode:s,it:o}=e;if(!r&&i.length===0)throw new Error("enum must have non-empty array");const a=i.length>=o.opts.loopEnum;let u;const l=()=>u??(u=(0,R3e.useFunc)(t,N3e.default));let c;if(a||r)c=t.let("valid"),e.block$data(c,f);else{if(!Array.isArray(i))throw new Error("ajv implementation error");const h=t.const("vSchema",s);c=(0,K0.or)(...i.map((p,m)=>d(h,m)))}e.pass(c);function f(){t.assign(c,!1),t.forOf("v",s,h=>t.if((0,K0._)`${l()}(${n}, ${h})`,()=>t.assign(c,!0).break()))}function d(h,p){const m=i[p];return typeof m=="object"&&m!==null?(0,K0._)`${l()}(${n}, ${h}[${p}])`:(0,K0._)`${n} === ${m}`}}};C3.default=D3e;Object.defineProperty(g3,"__esModule",{value:!0});const $3e=y3,L3e=v3,M3e=_3,F3e=w3,B3e=E3,j3e=S3,U3e=T3,V3e=I3,z3e=x3,H3e=C3,W3e=[$3e.default,L3e.default,M3e.default,F3e.default,B3e.default,j3e.default,U3e.default,V3e.default,{keyword:"type",schemaType:["string","array"]},{keyword:"nullable",schemaType:"boolean"},z3e.default,H3e.default];g3.default=W3e;var A3={},Eg={};Object.defineProperty(Eg,"__esModule",{value:!0});Eg.validateAdditionalItems=void 0;const Id=Xt,uN=_n,q3e={message:({params:{len:e}})=>(0,Id.str)`must NOT have more than ${e} items`,params:({params:{len:e}})=>(0,Id._)`{limit: ${e}}`},G3e={keyword:"additionalItems",type:"array",schemaType:["boolean","object"],before:"uniqueItems",error:q3e,code(e){const{parentSchema:t,it:n}=e,{items:r}=t;if(!Array.isArray(r)){(0,uN.checkStrictMode)(n,'"additionalItems" is ignored when "items" is not an array of schemas');return}une(e,r)}};function une(e,t){const{gen:n,schema:r,data:i,keyword:s,it:o}=e;o.items=!0;const a=n.const("len",(0,Id._)`${i}.length`);if(r===!1)e.setParams({len:t.length}),e.pass((0,Id._)`${a} <= ${t.length}`);else if(typeof r=="object"&&!(0,uN.alwaysValidSchema)(o,r)){const l=n.var("valid",(0,Id._)`${a} <= ${t.length}`);n.if((0,Id.not)(l),()=>u(l)),e.ok(l)}function u(l){n.forRange("i",t.length,a,c=>{e.subschema({keyword:s,dataProp:c,dataPropType:uN.Type.Num},l),o.allErrors||n.if((0,Id.not)(l),()=>n.break())})}}Eg.validateAdditionalItems=une;Eg.default=G3e;var P3={},Sg={};Object.defineProperty(Sg,"__esModule",{value:!0});Sg.validateTuple=void 0;const CU=Xt,kw=_n,Y3e=Qt,K3e={keyword:"items",type:"array",schemaType:["object","array","boolean"],before:"uniqueItems",code(e){const{schema:t,it:n}=e;if(Array.isArray(t))return lne(e,"additionalItems",t);n.items=!0,!(0,kw.alwaysValidSchema)(n,t)&&e.ok((0,Y3e.validateArray)(e))}};function lne(e,t,n=e.schema){const{gen:r,parentSchema:i,data:s,keyword:o,it:a}=e;c(i),a.opts.unevaluated&&n.length&&a.items!==!0&&(a.items=kw.mergeEvaluated.items(r,n.length,a.items));const u=r.name("valid"),l=r.const("len",(0,CU._)`${s}.length`);n.forEach((f,d)=>{(0,kw.alwaysValidSchema)(a,f)||(r.if((0,CU._)`${l} > ${d}`,()=>e.subschema({keyword:o,schemaProp:d,dataProp:d},u)),e.ok(u))});function c(f){const{opts:d,errSchemaPath:h}=a,p=n.length,m=p===f.minItems&&(p===f.maxItems||f[t]===!1);if(d.strictTuples&&!m){const y=`"${o}" is ${p}-tuple, but minItems or maxItems/${t} are not specified or different at path "${h}"`;(0,kw.checkStrictMode)(a,y,d.strictTuples)}}}Sg.validateTuple=lne;Sg.default=K3e;Object.defineProperty(P3,"__esModule",{value:!0});const Q3e=Sg,X3e={keyword:"prefixItems",type:"array",schemaType:["array"],before:"uniqueItems",code:e=>(0,Q3e.validateTuple)(e,"items")};P3.default=X3e;var O3={};Object.defineProperty(O3,"__esModule",{value:!0});const AU=Xt,J3e=_n,Z3e=Qt,e6e=Eg,t6e={message:({params:{len:e}})=>(0,AU.str)`must NOT have more than ${e} items`,params:({params:{len:e}})=>(0,AU._)`{limit: ${e}}`},n6e={keyword:"items",type:"array",schemaType:["object","boolean"],before:"uniqueItems",error:t6e,code(e){const{schema:t,parentSchema:n,it:r}=e,{prefixItems:i}=n;r.items=!0,!(0,J3e.alwaysValidSchema)(r,t)&&(i?(0,e6e.validateAdditionalItems)(e,i):e.ok((0,Z3e.validateArray)(e)))}};O3.default=n6e;var R3={};Object.defineProperty(R3,"__esModule",{value:!0});const zo=Xt,Sb=_n,r6e={message:({params:{min:e,max:t}})=>t===void 0?(0,zo.str)`must contain at least ${e} valid item(s)`:(0,zo.str)`must contain at least ${e} and no more than ${t} valid item(s)`,params:({params:{min:e,max:t}})=>t===void 0?(0,zo._)`{minContains: ${e}}`:(0,zo._)`{minContains: ${e}, maxContains: ${t}}`},i6e={keyword:"contains",type:"array",schemaType:["object","boolean"],before:"uniqueItems",trackErrors:!0,error:r6e,code(e){const{gen:t,schema:n,parentSchema:r,data:i,it:s}=e;let o,a;const{minContains:u,maxContains:l}=r;s.opts.next?(o=u===void 0?1:u,a=l):o=1;const c=t.const("len",(0,zo._)`${i}.length`);if(e.setParams({min:o,max:a}),a===void 0&&o===0){(0,Sb.checkStrictMode)(s,'"minContains" == 0 without "maxContains": "contains" keyword ignored');return}if(a!==void 0&&o>a){(0,Sb.checkStrictMode)(s,'"minContains" > "maxContains" is always invalid'),e.fail();return}if((0,Sb.alwaysValidSchema)(s,n)){let m=(0,zo._)`${c} >= ${o}`;a!==void 0&&(m=(0,zo._)`${m} && ${c} <= ${a}`),e.pass(m);return}s.items=!0;const f=t.name("valid");a===void 0&&o===1?h(f,()=>t.if(f,()=>t.break())):o===0?(t.let(f,!0),a!==void 0&&t.if((0,zo._)`${i}.length > 0`,d)):(t.let(f,!1),d()),e.result(f,()=>e.reset());function d(){const m=t.name("_valid"),y=t.let("count",0);h(m,()=>t.if(m,()=>p(y)))}function h(m,y){t.forRange("i",0,c,g=>{e.subschema({keyword:"contains",dataProp:g,dataPropType:Sb.Type.Num,compositeRule:!0},m),y()})}function p(m){t.code((0,zo._)`${m}++`),a===void 0?t.if((0,zo._)`${m} >= ${o}`,()=>t.assign(f,!0).break()):(t.if((0,zo._)`${m} > ${a}`,()=>t.assign(f,!1).break()),o===1?t.assign(f,!0):t.if((0,zo._)`${m} >= ${o}`,()=>t.assign(f,!0)))}}};R3.default=i6e;var cne={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.validateSchemaDeps=e.validatePropertyDeps=e.error=void 0;const t=Xt,n=_n,r=Qt;e.error={message:({params:{property:u,depsCount:l,deps:c}})=>{const f=l===1?"property":"properties";return(0,t.str)`must have ${f} ${c} when property ${u} is present`},params:({params:{property:u,depsCount:l,deps:c,missingProperty:f}})=>(0,t._)`{property: ${u}, missingProperty: ${f}, depsCount: ${l}, - deps: ${c}}`};const i={keyword:"dependencies",type:"object",schemaType:"object",error:e.error,code(u){const[l,c]=s(u);o(u,l),a(u,c)}};function s({schema:u}){const l={},c={};for(const f in u){if(f==="__proto__")continue;const d=Array.isArray(u[f])?l:c;d[f]=u[f]}return[l,c]}function o(u,l=u.schema){const{gen:c,data:f,it:d}=u;if(Object.keys(l).length===0)return;const h=c.let("missing");for(const p in l){const m=l[p];if(m.length===0)continue;const y=(0,r.propertyInData)(c,f,p,d.opts.ownProperties);u.setParams({property:p,depsCount:m.length,deps:m.join(", ")}),d.allErrors?c.if(y,()=>{for(const g of m)(0,r.checkReportMissingProp)(u,g)}):(c.if((0,t._)`${y} && (${(0,r.checkMissingProp)(u,m,h)})`),(0,r.reportMissingProp)(u,h),c.else())}}e.validatePropertyDeps=o;function a(u,l=u.schema){const{gen:c,data:f,keyword:d,it:h}=u,p=c.name("valid");for(const m in l)(0,n.alwaysValidSchema)(h,l[m])||(c.if((0,r.propertyInData)(c,f,m,h.opts.ownProperties),()=>{const y=u.subschema({keyword:d,schemaProp:m},p);u.mergeValidEvaluated(y,p)},()=>c.var(p,!0)),u.ok(p))}e.validateSchemaDeps=a,e.default=i})(cne);var k3={};Object.defineProperty(k3,"__esModule",{value:!0});const fne=Xt,s6e=_n,o6e={message:"property name must be valid",params:({params:e})=>(0,fne._)`{propertyName: ${e.propertyName}}`},a6e={keyword:"propertyNames",type:"object",schemaType:["object","boolean"],error:o6e,code(e){const{gen:t,schema:n,data:r,it:i}=e;if((0,s6e.alwaysValidSchema)(i,n))return;const s=t.name("valid");t.forIn("key",r,o=>{e.setParams({propertyName:o}),e.subschema({keyword:"propertyNames",data:o,dataTypes:["string"],propertyName:o,compositeRule:!0},s),t.if((0,fne.not)(s),()=>{e.error(!0),i.allErrors||t.break()})}),e.ok(s)}};k3.default=a6e;var aC={};Object.defineProperty(aC,"__esModule",{value:!0});const Tb=Qt,Ta=Xt,u6e=dl,Ib=_n,l6e={message:"must NOT have additional properties",params:({params:e})=>(0,Ta._)`{additionalProperty: ${e.additionalProperty}}`},c6e={keyword:"additionalProperties",type:["object"],schemaType:["boolean","object"],allowUndefined:!0,trackErrors:!0,error:l6e,code(e){const{gen:t,schema:n,parentSchema:r,data:i,errsCount:s,it:o}=e;if(!s)throw new Error("ajv implementation error");const{allErrors:a,opts:u}=o;if(o.props=!0,u.removeAdditional!=="all"&&(0,Ib.alwaysValidSchema)(o,n))return;const l=(0,Tb.allSchemaProperties)(r.properties),c=(0,Tb.allSchemaProperties)(r.patternProperties);f(),e.ok((0,Ta._)`${s} === ${u6e.default.errors}`);function f(){t.forIn("key",i,y=>{!l.length&&!c.length?p(y):t.if(d(y),()=>p(y))})}function d(y){let g;if(l.length>8){const v=(0,Ib.schemaRefOrVal)(o,r.properties,"properties");g=(0,Tb.isOwnProperty)(t,v,y)}else l.length?g=(0,Ta.or)(...l.map(v=>(0,Ta._)`${y} === ${v}`)):g=Ta.nil;return c.length&&(g=(0,Ta.or)(g,...c.map(v=>(0,Ta._)`${(0,Tb.usePattern)(e,v)}.test(${y})`))),(0,Ta.not)(g)}function h(y){t.code((0,Ta._)`delete ${i}[${y}]`)}function p(y){if(u.removeAdditional==="all"||u.removeAdditional&&n===!1){h(y);return}if(n===!1){e.setParams({additionalProperty:y}),e.error(),a||t.break();return}if(typeof n=="object"&&!(0,Ib.alwaysValidSchema)(o,n)){const g=t.name("valid");u.removeAdditional==="failing"?(m(y,g,!1),t.if((0,Ta.not)(g),()=>{e.reset(),h(y)})):(m(y,g),a||t.if((0,Ta.not)(g),()=>t.break()))}}function m(y,g,v){const b={keyword:"additionalProperties",dataProp:y,dataPropType:Ib.Type.Str};v===!1&&Object.assign(b,{compositeRule:!0,createErrors:!1,allErrors:!1}),e.subschema(b,g)}}};aC.default=c6e;var D3={};Object.defineProperty(D3,"__esModule",{value:!0});const f6e=Va,OU=Qt,rO=_n,RU=aC,d6e={keyword:"properties",type:"object",schemaType:"object",code(e){const{gen:t,schema:n,parentSchema:r,data:i,it:s}=e;s.opts.removeAdditional==="all"&&r.additionalProperties===void 0&&RU.default.code(new f6e.KeywordCxt(s,RU.default,"additionalProperties"));const o=(0,OU.allSchemaProperties)(n);for(const f of o)s.definedProperties.add(f);s.opts.unevaluated&&o.length&&s.props!==!0&&(s.props=rO.mergeEvaluated.props(t,(0,rO.toHash)(o),s.props));const a=o.filter(f=>!(0,rO.alwaysValidSchema)(s,n[f]));if(a.length===0)return;const u=t.name("valid");for(const f of a)l(f)?c(f):(t.if((0,OU.propertyInData)(t,i,f,s.opts.ownProperties)),c(f),s.allErrors||t.else().var(u,!0),t.endIf()),e.it.definedProperties.add(f),e.ok(u);function l(f){return s.opts.useDefaults&&!s.compositeRule&&n[f].default!==void 0}function c(f){e.subschema({keyword:"properties",schemaProp:f,dataProp:f},u)}}};D3.default=d6e;var $3={};Object.defineProperty($3,"__esModule",{value:!0});const NU=Qt,xb=Xt,kU=_n,DU=_n,h6e={keyword:"patternProperties",type:"object",schemaType:"object",code(e){const{gen:t,schema:n,data:r,parentSchema:i,it:s}=e,{opts:o}=s,a=(0,NU.allSchemaProperties)(n),u=a.filter(m=>(0,kU.alwaysValidSchema)(s,n[m]));if(a.length===0||u.length===a.length&&(!s.opts.unevaluated||s.props===!0))return;const l=o.strictSchema&&!o.allowMatchingProperties&&i.properties,c=t.name("valid");s.props!==!0&&!(s.props instanceof xb.Name)&&(s.props=(0,DU.evaluatedPropsToName)(t,s.props));const{props:f}=s;d();function d(){for(const m of a)l&&h(m),s.allErrors?p(m):(t.var(c,!0),p(m),t.if(c))}function h(m){for(const y in l)new RegExp(m).test(y)&&(0,kU.checkStrictMode)(s,`property ${y} matches pattern ${m} (use allowMatchingProperties)`)}function p(m){t.forIn("key",r,y=>{t.if((0,xb._)`${(0,NU.usePattern)(e,m)}.test(${y})`,()=>{const g=u.includes(m);g||e.subschema({keyword:"patternProperties",schemaProp:m,dataProp:y,dataPropType:DU.Type.Str},c),s.opts.unevaluated&&f!==!0?t.assign((0,xb._)`${f}[${y}]`,!0):!g&&!s.allErrors&&t.if((0,xb.not)(c),()=>t.break())})})}}};$3.default=h6e;var L3={};Object.defineProperty(L3,"__esModule",{value:!0});const p6e=_n,m6e={keyword:"not",schemaType:["object","boolean"],trackErrors:!0,code(e){const{gen:t,schema:n,it:r}=e;if((0,p6e.alwaysValidSchema)(r,n)){e.fail();return}const i=t.name("valid");e.subschema({keyword:"not",compositeRule:!0,createErrors:!1,allErrors:!1},i),e.failResult(i,()=>e.reset(),()=>e.error())},error:{message:"must NOT be valid"}};L3.default=m6e;var M3={};Object.defineProperty(M3,"__esModule",{value:!0});const g6e=Qt,y6e={keyword:"anyOf",schemaType:"array",trackErrors:!0,code:g6e.validateUnion,error:{message:"must match a schema in anyOf"}};M3.default=y6e;var F3={};Object.defineProperty(F3,"__esModule",{value:!0});const Dw=Xt,v6e=_n,_6e={message:"must match exactly one schema in oneOf",params:({params:e})=>(0,Dw._)`{passingSchemas: ${e.passing}}`},b6e={keyword:"oneOf",schemaType:"array",trackErrors:!0,error:_6e,code(e){const{gen:t,schema:n,parentSchema:r,it:i}=e;if(!Array.isArray(n))throw new Error("ajv implementation error");if(i.opts.discriminator&&r.discriminator)return;const s=n,o=t.let("valid",!1),a=t.let("passing",null),u=t.name("_valid");e.setParams({passing:a}),t.block(l),e.result(o,()=>e.reset(),()=>e.error(!0));function l(){s.forEach((c,f)=>{let d;(0,v6e.alwaysValidSchema)(i,c)?t.var(u,!0):d=e.subschema({keyword:"oneOf",schemaProp:f,compositeRule:!0},u),f>0&&t.if((0,Dw._)`${u} && ${o}`).assign(o,!1).assign(a,(0,Dw._)`[${a}, ${f}]`).else(),t.if(u,()=>{t.assign(o,!0),t.assign(a,f),d&&e.mergeEvaluated(d,Dw.Name)})})}}};F3.default=b6e;var B3={};Object.defineProperty(B3,"__esModule",{value:!0});const w6e=_n,E6e={keyword:"allOf",schemaType:"array",code(e){const{gen:t,schema:n,it:r}=e;if(!Array.isArray(n))throw new Error("ajv implementation error");const i=t.name("valid");n.forEach((s,o)=>{if((0,w6e.alwaysValidSchema)(r,s))return;const a=e.subschema({keyword:"allOf",schemaProp:o},i);e.ok(i),e.mergeEvaluated(a)})}};B3.default=E6e;var j3={};Object.defineProperty(j3,"__esModule",{value:!0});const AT=Xt,dne=_n,S6e={message:({params:e})=>(0,AT.str)`must match "${e.ifClause}" schema`,params:({params:e})=>(0,AT._)`{failingKeyword: ${e.ifClause}}`},T6e={keyword:"if",schemaType:["object","boolean"],trackErrors:!0,error:S6e,code(e){const{gen:t,parentSchema:n,it:r}=e;n.then===void 0&&n.else===void 0&&(0,dne.checkStrictMode)(r,'"if" without "then" and "else" is ignored');const i=$U(r,"then"),s=$U(r,"else");if(!i&&!s)return;const o=t.let("valid",!0),a=t.name("_valid");if(u(),e.reset(),i&&s){const c=t.let("ifClause");e.setParams({ifClause:c}),t.if(a,l("then",c),l("else",c))}else i?t.if(a,l("then")):t.if((0,AT.not)(a),l("else"));e.pass(o,()=>e.error(!0));function u(){const c=e.subschema({keyword:"if",compositeRule:!0,createErrors:!1,allErrors:!1},a);e.mergeEvaluated(c)}function l(c,f){return()=>{const d=e.subschema({keyword:c},a);t.assign(o,a),e.mergeValidEvaluated(d,o),f?t.assign(f,(0,AT._)`${c}`):e.setParams({ifClause:c})}}}};function $U(e,t){const n=e.schema[t];return n!==void 0&&!(0,dne.alwaysValidSchema)(e,n)}j3.default=T6e;var U3={};Object.defineProperty(U3,"__esModule",{value:!0});const I6e=_n,x6e={keyword:["then","else"],schemaType:["object","boolean"],code({keyword:e,parentSchema:t,it:n}){t.if===void 0&&(0,I6e.checkStrictMode)(n,`"${e}" without "if" is ignored`)}};U3.default=x6e;Object.defineProperty(P3,"__esModule",{value:!0});const C6e=Eg,A6e=O3,P6e=Sg,O6e=R3,R6e=N3,N6e=cne,k6e=k3,D6e=aC,$6e=D3,L6e=$3,M6e=L3,F6e=M3,B6e=F3,j6e=B3,U6e=j3,V6e=U3;function z6e(e=!1){const t=[M6e.default,F6e.default,B6e.default,j6e.default,U6e.default,V6e.default,k6e.default,D6e.default,N6e.default,$6e.default,L6e.default];return e?t.push(A6e.default,O6e.default):t.push(C6e.default,P6e.default),t.push(R6e.default),t}P3.default=z6e;var V3={},z3={};Object.defineProperty(z3,"__esModule",{value:!0});const $r=Xt,H6e={message:({schemaCode:e})=>(0,$r.str)`must match format "${e}"`,params:({schemaCode:e})=>(0,$r._)`{format: ${e}}`},W6e={keyword:"format",type:["number","string"],schemaType:"string",$data:!0,error:H6e,code(e,t){const{gen:n,data:r,$data:i,schema:s,schemaCode:o,it:a}=e,{opts:u,errSchemaPath:l,schemaEnv:c,self:f}=a;if(!u.validateFormats)return;i?d():h();function d(){const p=n.scopeValue("formats",{ref:f.formats,code:u.code.formats}),m=n.const("fDef",(0,$r._)`${p}[${o}]`),y=n.let("fType"),g=n.let("format");n.if((0,$r._)`typeof ${m} == "object" && !(${m} instanceof RegExp)`,()=>n.assign(y,(0,$r._)`${m}.type || "string"`).assign(g,(0,$r._)`${m}.validate`),()=>n.assign(y,(0,$r._)`"string"`).assign(g,m)),e.fail$data((0,$r.or)(v(),b()));function v(){return u.strictSchema===!1?$r.nil:(0,$r._)`${o} && !${g}`}function b(){const S=c.$async?(0,$r._)`(${m}.async ? await ${g}(${r}) : ${g}(${r}))`:(0,$r._)`${g}(${r})`,T=(0,$r._)`(typeof ${g} == "function" ? ${S} : ${g}.test(${r}))`;return(0,$r._)`${g} && ${g} !== true && ${y} === ${t} && !${T}`}}function h(){const p=f.formats[s];if(!p){v();return}if(p===!0)return;const[m,y,g]=b(p);m===t&&e.pass(S());function v(){if(u.strictSchema===!1){f.logger.warn(T());return}throw new Error(T());function T(){return`unknown format "${s}" ignored in schema at path "${l}"`}}function b(T){const E=T instanceof RegExp?(0,$r.regexpCode)(T):u.code.formats?(0,$r._)`${u.code.formats}${(0,$r.getProperty)(s)}`:void 0,I=n.scopeValue("formats",{key:s,ref:T,code:E});return typeof T=="object"&&!(T instanceof RegExp)?[T.type||"string",T.validate,(0,$r._)`${I}.validate`]:["string",T,I]}function S(){if(typeof p=="object"&&!(p instanceof RegExp)&&p.async){if(!c.$async)throw new Error("async format in sync schema");return(0,$r._)`await ${g}(${r})`}return typeof y=="function"?(0,$r._)`${g}(${r})`:(0,$r._)`${g}.test(${r})`}}}};z3.default=W6e;Object.defineProperty(V3,"__esModule",{value:!0});const q6e=z3,G6e=[q6e.default];V3.default=G6e;var Vm={};Object.defineProperty(Vm,"__esModule",{value:!0});Vm.contentVocabulary=Vm.metadataVocabulary=void 0;Vm.metadataVocabulary=["title","description","default","deprecated","readOnly","writeOnly","examples"];Vm.contentVocabulary=["contentMediaType","contentEncoding","contentSchema"];Object.defineProperty(p3,"__esModule",{value:!0});const Y6e=m3,K6e=y3,Q6e=P3,X6e=V3,LU=Vm,J6e=[Y6e.default,K6e.default,(0,Q6e.default)(),X6e.default,LU.metadataVocabulary,LU.contentVocabulary];p3.default=J6e;var H3={},hne={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.DiscrError=void 0,function(t){t.Tag="tag",t.Mapping="mapping"}(e.DiscrError||(e.DiscrError={}))})(hne);Object.defineProperty(H3,"__esModule",{value:!0});const dp=Xt,cN=hne,MU=zs,Z6e=_n,eLe={message:({params:{discrError:e,tagName:t}})=>e===cN.DiscrError.Tag?`tag "${t}" must be string`:`value of tag "${t}" must be in oneOf`,params:({params:{discrError:e,tag:t,tagName:n}})=>(0,dp._)`{error: ${e}, tag: ${n}, tagValue: ${t}}`},tLe={keyword:"discriminator",type:"object",schemaType:"object",error:eLe,code(e){const{gen:t,data:n,schema:r,parentSchema:i,it:s}=e,{oneOf:o}=i;if(!s.opts.discriminator)throw new Error("discriminator: requires discriminator option");const a=r.propertyName;if(typeof a!="string")throw new Error("discriminator: requires propertyName");if(r.mapping)throw new Error("discriminator: mapping is not supported");if(!o)throw new Error("discriminator: requires oneOf keyword");const u=t.let("valid",!1),l=t.const("tag",(0,dp._)`${n}${(0,dp.getProperty)(a)}`);t.if((0,dp._)`typeof ${l} == "string"`,()=>c(),()=>e.error(!1,{discrError:cN.DiscrError.Tag,tag:l,tagName:a})),e.ok(u);function c(){const h=d();t.if(!1);for(const p in h)t.elseIf((0,dp._)`${l} === ${p}`),t.assign(u,f(h[p]));t.else(),e.error(!1,{discrError:cN.DiscrError.Mapping,tag:l,tagName:a}),t.endIf()}function f(h){const p=t.name("valid"),m=e.subschema({keyword:"oneOf",schemaProp:h},p);return e.mergeEvaluated(m,dp.Name),p}function d(){var h;const p={},m=g(i);let y=!0;for(let S=0;Sthis.addVocabulary(p)),this.opts.discriminator&&this.addKeyword(i.default)}_addDefaultMetaSchema(){if(super._addDefaultMetaSchema(),!this.opts.meta)return;const p=this.opts.$data?this.$dataMetaSchema(s,o):s;this.addMetaSchema(p,a,!1),this.refs["http://json-schema.org/schema"]=a}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(a)?a:void 0)}}e.exports=t=u,Object.defineProperty(t,"__esModule",{value:!0}),t.default=u;var l=Va;Object.defineProperty(t,"KeywordCxt",{enumerable:!0,get:function(){return l.KeywordCxt}});var c=Xt;Object.defineProperty(t,"_",{enumerable:!0,get:function(){return c._}}),Object.defineProperty(t,"str",{enumerable:!0,get:function(){return c.str}}),Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return c.stringify}}),Object.defineProperty(t,"nil",{enumerable:!0,get:function(){return c.nil}}),Object.defineProperty(t,"Name",{enumerable:!0,get:function(){return c.Name}}),Object.defineProperty(t,"CodeGen",{enumerable:!0,get:function(){return c.CodeGen}});var f=z_;Object.defineProperty(t,"ValidationError",{enumerable:!0,get:function(){return f.default}});var d=H_;Object.defineProperty(t,"MissingRefError",{enumerable:!0,get:function(){return d.default}})})(iN,iN.exports);var lLe=iN.exports;const pne=eu(lLe),cLe="#/definitions/StudyConfig",fLe="http://json-schema.org/draft-07/schema#",dLe={Answer:{additionalProperties:!1,description:"The Answer interface is used to define the properties of an answer. Answers are used to define the correct answer for a task. These are generally used in training tasks.",properties:{acceptableHigh:{description:"The acceptable high value for the answer. This is used to define a range of acceptable answers.",type:"number"},acceptableLow:{description:"The acceptable low value for the answer. This is used to define a range of acceptable answers.",type:"number"},answer:{description:"The correct answer to the question."},id:{description:"The id of the answer. This is used to identify the answer in the data file.",type:"string"}},required:["id","answer"],type:"object"},CheckboxResponse:{additionalProperties:!1,description:"The CheckboxResponse interface is used to define the properties of a checkbox response. CheckboxResponses render as a checkbox input with user specified options.",properties:{correctAnswer:{description:"The correct answer to the response. This is used in the data download and can be shown in the admin panel."},hidden:{description:"Controls whether the response is hidden.",type:"boolean"},id:{description:"The id of the response. This is used to identify the response in the data file.",type:"string"},location:{$ref:"#/definitions/ResponseBlockLocation",description:"Controls the response location. These might be the same for all responses, or differ across responses."},options:{description:"The options that are displayed as checkboxes.",items:{$ref:"#/definitions/Option"},type:"array"},paramCapture:{description:"Use to capture querystring parameters in answers such as participant_name. See the examples for how this is used, but prefer uiConfig.urlParticipantIdParam if you are capturing a participant ID.",type:"string"},prompt:{description:"The prompt that is displayed to the participant. You can use markdown here to render images, links, etc.",type:"string"},required:{description:"Controls whether the response is required to be answered.",type:"boolean"},requiredLabel:{description:"You can provide a required label, which makes it so a participant has to answer with a response that matches label.",type:"string"},requiredValue:{description:"You can provide a required value, which makes it so a participant has to answer with that value."},type:{const:"checkbox",type:"string"}},required:["id","location","options","prompt","required","type"],type:"object"},DropdownResponse:{additionalProperties:!1,description:"The DropdownResponse interface is used to define the properties of a dropdown response. DropdownResponses render as a select input with user specified options.",properties:{correctAnswer:{description:"The correct answer to the response. This is used in the data download and can be shown in the admin panel."},hidden:{description:"Controls whether the response is hidden.",type:"boolean"},id:{description:"The id of the response. This is used to identify the response in the data file.",type:"string"},location:{$ref:"#/definitions/ResponseBlockLocation",description:"Controls the response location. These might be the same for all responses, or differ across responses."},options:{description:"The options that are displayed in the dropdown.",items:{$ref:"#/definitions/Option"},type:"array"},paramCapture:{description:"Use to capture querystring parameters in answers such as participant_name. See the examples for how this is used, but prefer uiConfig.urlParticipantIdParam if you are capturing a participant ID.",type:"string"},placeholder:{description:"The placeholder text that is displayed in the input.",type:"string"},prompt:{description:"The prompt that is displayed to the participant. You can use markdown here to render images, links, etc.",type:"string"},required:{description:"Controls whether the response is required to be answered.",type:"boolean"},requiredLabel:{description:"You can provide a required label, which makes it so a participant has to answer with a response that matches label.",type:"string"},requiredValue:{description:"You can provide a required value, which makes it so a participant has to answer with that value."},type:{const:"dropdown",type:"string"}},required:["id","location","options","prompt","required","type"],type:"object"},IFrameResponse:{additionalProperties:!1,description:"The IFrameResponse interface is used to define the properties of an iframe response. IFrameResponses render as a list, that is connected to a WebsiteComponent. When data is sent from the WebsiteComponent, it is displayed in the list.",properties:{correctAnswer:{description:"The correct answer to the response. This is used in the data download and can be shown in the admin panel."},hidden:{description:"Controls whether the response is hidden.",type:"boolean"},id:{description:"The id of the response. This is used to identify the response in the data file.",type:"string"},location:{$ref:"#/definitions/ResponseBlockLocation",description:"Controls the response location. These might be the same for all responses, or differ across responses."},paramCapture:{description:"Use to capture querystring parameters in answers such as participant_name. See the examples for how this is used, but prefer uiConfig.urlParticipantIdParam if you are capturing a participant ID.",type:"string"},prompt:{description:"The prompt that is displayed to the participant. You can use markdown here to render images, links, etc.",type:"string"},required:{description:"Controls whether the response is required to be answered.",type:"boolean"},requiredLabel:{description:"You can provide a required label, which makes it so a participant has to answer with a response that matches label.",type:"string"},requiredValue:{description:"You can provide a required value, which makes it so a participant has to answer with that value."},type:{const:"iframe",type:"string"}},required:["id","location","prompt","required","type"],type:"object"},ImageComponent:{additionalProperties:!1,description:"The ImageComponent interface is used to define the properties of an image component. This component is used to render an image with optional styling.",properties:{correctAnswer:{description:"The correct answer to the component. This is used for training trials where the user is shown the correct answer after a guess.",items:{$ref:"#/definitions/Answer"},type:"array"},description:{description:"The description of the component. This is used to identify and provide additional information for the component in the admin panel.",type:"string"},instruction:{description:"The instruction of the component. This is used to identify and provide additional information for the component in the admin panel.",type:"string"},instructionLocation:{$ref:"#/definitions/ResponseBlockLocation",description:"The location of the instructions."},meta:{additionalProperties:{},description:"The meta data for the component. This is used to identify and provide additional information for the component in the admin panel.",type:"object"},nextButtonLocation:{$ref:"#/definitions/ResponseBlockLocation",description:"The location of the next button."},nextButtonText:{description:"The text that is displayed on the next button.",type:"string"},path:{description:"The path to the image. This should be a relative path from the public folder.",type:"string"},response:{description:"The responses to the component",items:{$ref:"#/definitions/Response"},type:"array"},style:{additionalProperties:{type:"string"},description:"The style of the image. This is an object with css properties as keys and css values as values.",type:"object"},type:{const:"image",type:"string"}},required:["path","response","type"],type:"object"},IndividualComponent:{anyOf:[{$ref:"#/definitions/MarkdownComponent"},{$ref:"#/definitions/ReactComponent"},{$ref:"#/definitions/ImageComponent"},{$ref:"#/definitions/WebsiteComponent"},{$ref:"#/definitions/QuestionnaireComponent"}]},InheritedComponent:{additionalProperties:!1,description:"An InheritedComponent is a component that inherits properties from a baseComponent. This is used to avoid repeating properties in components. This also means that components in the baseComponents object can be partially defined, while components in the components object can inherit from them and must be fully defined and include all properties (after potentially merging with a base component).",properties:{baseComponent:{type:"string"},correctAnswer:{description:"The correct answer to the component. This is used for training trials where the user is shown the correct answer after a guess.",items:{$ref:"#/definitions/Answer"},type:"array"},description:{description:"The description of the component. This is used to identify and provide additional information for the component in the admin panel.",type:"string"},instruction:{description:"The instruction of the component. This is used to identify and provide additional information for the component in the admin panel.",type:"string"},instructionLocation:{$ref:"#/definitions/ResponseBlockLocation",description:"The location of the instructions."},meta:{additionalProperties:{},description:"The meta data for the component. This is used to identify and provide additional information for the component in the admin panel.",type:"object"},nextButtonLocation:{$ref:"#/definitions/ResponseBlockLocation",description:"The location of the next button."},nextButtonText:{description:"The text that is displayed on the next button.",type:"string"},parameters:{anyOf:[{additionalProperties:{},description:"The parameters that are passed to the react component. These can be used within your react component to render different things.",type:"object"},{additionalProperties:{},description:"The parameters that are passed to the website (iframe). These can be used within your website to render different things.",type:"object"}],description:"The parameters that are passed to the react component. These can be used within your react component to render different things."},path:{description:"The path to the markdown file. This should be a relative path from the public folder.",type:"string"},response:{description:"The responses to the component",items:{$ref:"#/definitions/Response"},type:"array"},style:{additionalProperties:{type:"string"},description:"The style of the image. This is an object with css properties as keys and css values as values.",type:"object"},type:{enum:["markdown","react-component","image","website","questionnaire"],type:"string"}},required:["baseComponent"],type:"object"},LikertResponse:{additionalProperties:!1,description:"The LikertResponse interface is used to define the properties of a likert response. LikertResponses render as radio buttons with a user specified number of options, which can be controlled through the preset. For example, preset: 5 will render 5 radio buttons, and preset: 7 will render 7 radio buttons. LikertResponses can also have a description, and left and right labels. The left and right labels are used to label the left and right ends of the likert scale with values such as 'Strongly Disagree' and 'Strongly Agree'.",properties:{correctAnswer:{description:"The correct answer to the response. This is used in the data download and can be shown in the admin panel."},desc:{description:"The description of the likert scale.",type:"string"},hidden:{description:"Controls whether the response is hidden.",type:"boolean"},id:{description:"The id of the response. This is used to identify the response in the data file.",type:"string"},leftLabel:{description:"The left label of the likert scale. E.g Strongly Disagree",type:"string"},location:{$ref:"#/definitions/ResponseBlockLocation",description:"Controls the response location. These might be the same for all responses, or differ across responses."},paramCapture:{description:"Use to capture querystring parameters in answers such as participant_name. See the examples for how this is used, but prefer uiConfig.urlParticipantIdParam if you are capturing a participant ID.",type:"string"},preset:{description:"The number of options to render.",type:"number"},prompt:{description:"The prompt that is displayed to the participant. You can use markdown here to render images, links, etc.",type:"string"},required:{description:"Controls whether the response is required to be answered.",type:"boolean"},requiredLabel:{description:"You can provide a required label, which makes it so a participant has to answer with a response that matches label.",type:"string"},requiredValue:{description:"You can provide a required value, which makes it so a participant has to answer with that value."},rightLabel:{description:"The right label of the likert scale. E.g Strongly Agree",type:"string"},type:{const:"likert",type:"string"}},required:["id","location","preset","prompt","required","type"],type:"object"},LongTextResponse:{additionalProperties:!1,description:"The LongTextResponse interface is used to define the properties of a long text response. LongTextResponses render as a text area that accepts any text and can optionally have a placeholder.",properties:{correctAnswer:{description:"The correct answer to the response. This is used in the data download and can be shown in the admin panel."},hidden:{description:"Controls whether the response is hidden.",type:"boolean"},id:{description:"The id of the response. This is used to identify the response in the data file.",type:"string"},location:{$ref:"#/definitions/ResponseBlockLocation",description:"Controls the response location. These might be the same for all responses, or differ across responses."},paramCapture:{description:"Use to capture querystring parameters in answers such as participant_name. See the examples for how this is used, but prefer uiConfig.urlParticipantIdParam if you are capturing a participant ID.",type:"string"},placeholder:{description:"The placeholder text that is displayed in the input.",type:"string"},prompt:{description:"The prompt that is displayed to the participant. You can use markdown here to render images, links, etc.",type:"string"},required:{description:"Controls whether the response is required to be answered.",type:"boolean"},requiredLabel:{description:"You can provide a required label, which makes it so a participant has to answer with a response that matches label.",type:"string"},requiredValue:{description:"You can provide a required value, which makes it so a participant has to answer with that value."},type:{const:"longText",type:"string"}},required:["id","location","prompt","required","type"],type:"object"},MarkdownComponent:{additionalProperties:!1,description:"The MarkdownComponent interface is used to define the properties of a markdown component. The components can be used to render many different things, such as consent forms, instructions, and debriefs. Additionally, you can use the markdown component to render images, videos, and other media, with supporting text.",properties:{correctAnswer:{description:"The correct answer to the component. This is used for training trials where the user is shown the correct answer after a guess.",items:{$ref:"#/definitions/Answer"},type:"array"},description:{description:"The description of the component. This is used to identify and provide additional information for the component in the admin panel.",type:"string"},instruction:{description:"The instruction of the component. This is used to identify and provide additional information for the component in the admin panel.",type:"string"},instructionLocation:{$ref:"#/definitions/ResponseBlockLocation",description:"The location of the instructions."},meta:{additionalProperties:{},description:"The meta data for the component. This is used to identify and provide additional information for the component in the admin panel.",type:"object"},nextButtonLocation:{$ref:"#/definitions/ResponseBlockLocation",description:"The location of the next button."},nextButtonText:{description:"The text that is displayed on the next button.",type:"string"},path:{description:"The path to the markdown file. This should be a relative path from the public folder.",type:"string"},response:{description:"The responses to the component",items:{$ref:"#/definitions/Response"},type:"array"},type:{const:"markdown",type:"string"}},required:["path","response","type"],type:"object"},NumericalResponse:{additionalProperties:!1,description:"The NumericalResponse interface is used to define the properties of a numerical response. NumericalResponses render as a text input that only accepts numbers, and can optionally have a min and max value, or a placeholder.",properties:{correctAnswer:{description:"The correct answer to the response. This is used in the data download and can be shown in the admin panel."},hidden:{description:"Controls whether the response is hidden.",type:"boolean"},id:{description:"The id of the response. This is used to identify the response in the data file.",type:"string"},location:{$ref:"#/definitions/ResponseBlockLocation",description:"Controls the response location. These might be the same for all responses, or differ across responses."},max:{description:"The maximum value that is accepted in the input.",type:"number"},min:{description:"The minimum value that is accepted in the input.",type:"number"},paramCapture:{description:"Use to capture querystring parameters in answers such as participant_name. See the examples for how this is used, but prefer uiConfig.urlParticipantIdParam if you are capturing a participant ID.",type:"string"},placeholder:{description:"The placeholder text that is displayed in the input.",type:"string"},prompt:{description:"The prompt that is displayed to the participant. You can use markdown here to render images, links, etc.",type:"string"},required:{description:"Controls whether the response is required to be answered.",type:"boolean"},requiredLabel:{description:"You can provide a required label, which makes it so a participant has to answer with a response that matches label.",type:"string"},requiredValue:{description:"You can provide a required value, which makes it so a participant has to answer with that value."},type:{const:"numerical",type:"string"}},required:["id","location","prompt","required","type"],type:"object"},Option:{additionalProperties:!1,description:"The Option interface is used to define the options for a dropdown, slider, radio, or checkbox response. The label is the text that is displayed to the user, and the value is the value that is stored in the data file. The Option interface is used in the Response interface.",properties:{label:{description:"The label displayed to participants.",type:"string"},value:{description:"The value stored in the participant's data.",type:["string","number"]}},required:["label","value"],type:"object"},OrderObject:{additionalProperties:!1,description:"The OrderObject interface is used to define the properties of an order object. This is used to define the order of components in a study. It supports random assignment of trials using a pure random assignment and a latin square.",properties:{components:{description:"The components that are included in the order.",items:{anyOf:[{type:"string"},{$ref:"#/definitions/OrderObject"}]},type:"array"},numSamples:{description:"The number of samples to use for the random assignments. This means you can randomize across 3 components while only showing a participant 2 at a time.",type:"number"},order:{description:"The type of order. This can be random (pure random), latinSquare (random with some guarantees), or fixed.",enum:["random","latinSquare","fixed"],type:"string"}},required:["order","components"],type:"object"},QuestionnaireComponent:{additionalProperties:!1,description:"The QuestionnaireComponent interface is used to define the properties of a questionnaire component. A QuestionnaireComponent is used to render questions with different response types. The response types are also defined with these documentation. The main use case of this component type is to ask participants questions, without using markdown, websites, images, etc.",properties:{correctAnswer:{description:"The correct answer to the component. This is used for training trials where the user is shown the correct answer after a guess.",items:{$ref:"#/definitions/Answer"},type:"array"},description:{description:"The description of the component. This is used to identify and provide additional information for the component in the admin panel.",type:"string"},instruction:{description:"The instruction of the component. This is used to identify and provide additional information for the component in the admin panel.",type:"string"},instructionLocation:{$ref:"#/definitions/ResponseBlockLocation",description:"The location of the instructions."},meta:{additionalProperties:{},description:"The meta data for the component. This is used to identify and provide additional information for the component in the admin panel.",type:"object"},nextButtonLocation:{$ref:"#/definitions/ResponseBlockLocation",description:"The location of the next button."},nextButtonText:{description:"The text that is displayed on the next button.",type:"string"},response:{description:"The responses to the component",items:{$ref:"#/definitions/Response"},type:"array"},type:{const:"questionnaire",type:"string"}},required:["response","type"],type:"object"},RadioResponse:{additionalProperties:!1,description:"The RadioResponse interface is used to define the properties of a radio response. RadioResponses render as a radio input with user specified options, and optionally left and right labels.",properties:{correctAnswer:{description:"The correct answer to the response. This is used in the data download and can be shown in the admin panel."},hidden:{description:"Controls whether the response is hidden.",type:"boolean"},id:{description:"The id of the response. This is used to identify the response in the data file.",type:"string"},leftLabel:{type:"string"},location:{$ref:"#/definitions/ResponseBlockLocation",description:"Controls the response location. These might be the same for all responses, or differ across responses."},options:{items:{$ref:"#/definitions/Option"},type:"array"},paramCapture:{description:"Use to capture querystring parameters in answers such as participant_name. See the examples for how this is used, but prefer uiConfig.urlParticipantIdParam if you are capturing a participant ID.",type:"string"},prompt:{description:"The prompt that is displayed to the participant. You can use markdown here to render images, links, etc.",type:"string"},required:{description:"Controls whether the response is required to be answered.",type:"boolean"},requiredLabel:{description:"You can provide a required label, which makes it so a participant has to answer with a response that matches label.",type:"string"},requiredValue:{description:"You can provide a required value, which makes it so a participant has to answer with that value."},rightLabel:{type:"string"},type:{const:"radio",type:"string"}},required:["id","location","options","prompt","required","type"],type:"object"},ReactComponent:{additionalProperties:!1,description:"The ReactComponent interface is used to define the properties of a react component. This component is used to render react code with certain parameters. These parameters can be used within your react code to render different things.",properties:{correctAnswer:{description:"The correct answer to the component. This is used for training trials where the user is shown the correct answer after a guess.",items:{$ref:"#/definitions/Answer"},type:"array"},description:{description:"The description of the component. This is used to identify and provide additional information for the component in the admin panel.",type:"string"},instruction:{description:"The instruction of the component. This is used to identify and provide additional information for the component in the admin panel.",type:"string"},instructionLocation:{$ref:"#/definitions/ResponseBlockLocation",description:"The location of the instructions."},meta:{additionalProperties:{},description:"The meta data for the component. This is used to identify and provide additional information for the component in the admin panel.",type:"object"},nextButtonLocation:{$ref:"#/definitions/ResponseBlockLocation",description:"The location of the next button."},nextButtonText:{description:"The text that is displayed on the next button.",type:"string"},parameters:{additionalProperties:{},description:"The parameters that are passed to the react component. These can be used within your react component to render different things.",type:"object"},path:{description:"The path to the react component. This should be a relative path from the src/public folder.",type:"string"},response:{description:"The responses to the component",items:{$ref:"#/definitions/Response"},type:"array"},type:{const:"react-component",type:"string"}},required:["path","response","type"],type:"object"},Response:{anyOf:[{$ref:"#/definitions/NumericalResponse"},{$ref:"#/definitions/ShortTextResponse"},{$ref:"#/definitions/LongTextResponse"},{$ref:"#/definitions/LikertResponse"},{$ref:"#/definitions/DropdownResponse"},{$ref:"#/definitions/SliderResponse"},{$ref:"#/definitions/RadioResponse"},{$ref:"#/definitions/CheckboxResponse"},{$ref:"#/definitions/IFrameResponse"}]},ResponseBlockLocation:{enum:["sidebar","aboveStimulus","belowStimulus"],type:"string"},ShortTextResponse:{additionalProperties:!1,description:"The ShortTextResponse interface is used to define the properties of a short text response. ShortTextResponses render as a text input that accepts any text and can optionally have a placeholder.",properties:{correctAnswer:{description:"The correct answer to the response. This is used in the data download and can be shown in the admin panel."},hidden:{description:"Controls whether the response is hidden.",type:"boolean"},id:{description:"The id of the response. This is used to identify the response in the data file.",type:"string"},location:{$ref:"#/definitions/ResponseBlockLocation",description:"Controls the response location. These might be the same for all responses, or differ across responses."},paramCapture:{description:"Use to capture querystring parameters in answers such as participant_name. See the examples for how this is used, but prefer uiConfig.urlParticipantIdParam if you are capturing a participant ID.",type:"string"},placeholder:{description:"The placeholder text that is displayed in the input.",type:"string"},prompt:{description:"The prompt that is displayed to the participant. You can use markdown here to render images, links, etc.",type:"string"},required:{description:"Controls whether the response is required to be answered.",type:"boolean"},requiredLabel:{description:"You can provide a required label, which makes it so a participant has to answer with a response that matches label.",type:"string"},requiredValue:{description:"You can provide a required value, which makes it so a participant has to answer with that value."},type:{const:"shortText",type:"string"}},required:["id","location","prompt","required","type"],type:"object"},SliderResponse:{additionalProperties:!1,description:"The SliderResponse interface is used to define the properties of a slider response. SliderResponses render as a slider input with user specified steps. For example, you could have steps of 0, 50, and 100.",properties:{correctAnswer:{description:"The correct answer to the response. This is used in the data download and can be shown in the admin panel."},hidden:{description:"Controls whether the response is hidden.",type:"boolean"},id:{description:"The id of the response. This is used to identify the response in the data file.",type:"string"},leftLabel:{description:"The left label of the likert scale. E.g Strongly Disagree",type:"string"},location:{$ref:"#/definitions/ResponseBlockLocation",description:"Controls the response location. These might be the same for all responses, or differ across responses."},options:{description:"This define the steps in the slider and the extent of the slider.",items:{$ref:"#/definitions/Option"},type:"array"},paramCapture:{description:"Use to capture querystring parameters in answers such as participant_name. See the examples for how this is used, but prefer uiConfig.urlParticipantIdParam if you are capturing a participant ID.",type:"string"},prompt:{description:"The prompt that is displayed to the participant. You can use markdown here to render images, links, etc.",type:"string"},required:{description:"Controls whether the response is required to be answered.",type:"boolean"},requiredLabel:{description:"You can provide a required label, which makes it so a participant has to answer with a response that matches label.",type:"string"},requiredValue:{description:"You can provide a required value, which makes it so a participant has to answer with that value."},rightLabel:{description:"The right label of the likert scale. E.g Strongly Agree",type:"string"},type:{const:"slider",type:"string"}},required:["id","location","options","prompt","required","type"],type:"object"},StudyConfig:{additionalProperties:!1,description:"The StudyConfig interface is used to define the properties of a study configuration. These are the hjson files that live in the public folder. In our repo, one example of this would be public/cleveland/config-cleveland.json.",properties:{$schema:{description:"A required json schema property. This should point to the github link for the version of the schema you would like. See examples for more information",type:"string"},baseComponents:{additionalProperties:{anyOf:[{$ref:"#/definitions/IndividualComponent"},{additionalProperties:!1,properties:{correctAnswer:{description:"The correct answer to the component. This is used for training trials where the user is shown the correct answer after a guess.",items:{$ref:"#/definitions/Answer"},type:"array"},description:{description:"The description of the component. This is used to identify and provide additional information for the component in the admin panel.",type:"string"},instruction:{description:"The instruction of the component. This is used to identify and provide additional information for the component in the admin panel.",type:"string"},instructionLocation:{$ref:"#/definitions/ResponseBlockLocation",description:"The location of the instructions."},meta:{additionalProperties:{},description:"The meta data for the component. This is used to identify and provide additional information for the component in the admin panel.",type:"object"},nextButtonLocation:{$ref:"#/definitions/ResponseBlockLocation",description:"The location of the next button."},nextButtonText:{description:"The text that is displayed on the next button.",type:"string"},parameters:{anyOf:[{additionalProperties:{},description:"The parameters that are passed to the react component. These can be used within your react component to render different things.",type:"object"},{additionalProperties:{},description:"The parameters that are passed to the website (iframe). These can be used within your website to render different things.",type:"object"}],description:"The parameters that are passed to the react component. These can be used within your react component to render different things."},path:{description:"The path to the markdown file. This should be a relative path from the public folder.",type:"string"},response:{description:"The responses to the component",items:{$ref:"#/definitions/Response"},type:"array"},style:{additionalProperties:{type:"string"},description:"The style of the image. This is an object with css properties as keys and css values as values.",type:"object"},type:{enum:["markdown","react-component","image","website","questionnaire"],type:"string"}},type:"object"}]},description:"The components that are used in the study (baseComponents allow PartialComponents which allows for inheriting from them in components).",type:"object"},components:{additionalProperties:{anyOf:[{$ref:"#/definitions/IndividualComponent"},{$ref:"#/definitions/InheritedComponent"}]},description:"The components that are used in the study. They must be fully defined here with all properties. Some properties may be inherited from baseComponents.",type:"object"},recordStudyAudio:{type:"boolean"},sequence:{$ref:"#/definitions/OrderObject",description:"The order of the components in the study. This might include some randomness."},studyMetadata:{$ref:"#/definitions/StudyMetadata",description:"The metadata for the study. This is used to identify the study and version in the data file."},tasksToNotRecordAudio:{items:{type:"string"},type:"array"},uiConfig:{$ref:"#/definitions/UIConfig",description:"The UI configuration for the study. This is used to configure the UI of the app."}},required:["$schema","studyMetadata","uiConfig","components","sequence"],type:"object"},StudyMetadata:{additionalProperties:!1,description:"The StudyMetadata is used to describe certain properties of a study. Some of this data is displayed on the landing page when running the app, such as the title and description. This data is also included in the data file that is downloaded at the end of the study, to help identify the study and version.",properties:{authors:{description:"The authors of your study.",items:{type:"string"},type:"array"},date:{description:"The date of your study, may be useful for the researcher.",type:"string"},description:{description:"The description of your study, shown on the landing page.",type:"string"},organizations:{description:"The organizations that are associated with your study.",items:{type:"string"},type:"array"},title:{description:"The title of your study, shown on the landing page.",type:"string"},version:{description:"The version of your study, shown on the landing page and attached to participant data. This might be useful for seeing which version of the study a participant saw.",type:"string"}},required:["title","version","authors","date","description","organizations"],type:"object"},UIConfig:{additionalProperties:!1,description:"The UIConfig is used to configure the UI of the app. This includes the logo, contact email, and whether to show a progress bar. The UIConfig is also used to configure the sidebar, which can be used to display the task instructions and capture responses.",properties:{autoDownloadStudy:{description:"Controls whether the study data is automatically downloaded at the end of the study.",type:"boolean"},autoDownloadTime:{description:"The time in milliseconds to wait before automatically downloading the study data.",type:"number"},contactEmail:{description:"The email address that used during the study if a participant clicks contact.",type:"string"},helpTextPath:{description:"The path to the help text file. This is displayed when a participant clicks help. Markdown is supported.",type:"string"},logoPath:{description:"The path to the logo image. This is displayed on the landing page and the header.",type:"string"},numSequences:{description:"The number of sequences to generate for the study. This is used to generate the random sequences for the study. The default is 1000.",type:"number"},sidebar:{description:"Controls whether the left sidebar is rendered at all. Required to be true if your response's location is set to sidebar for any question.",type:"boolean"},studyEndMsg:{description:"The message to display when the study ends.",type:"string"},urlParticipantIdParam:{description:"If the participant ID is passed in the URL, this is the name of the querystring parameter that is used to capture the participant ID (e.g. PROLIFIC_ID). This will allow a user to continue a study on different devices and browsers.",type:"string"},windowEventDebounceTime:{description:"Debounce time in milliseconds for automatically tracked window events. Defaults to 100. E.g 100 here means 1000ms / 100ms = 10 times a second, 200 here means 1000ms / 200ms = 5 times per second",type:"number"},withProgressBar:{description:"Controls whether the progress bar is rendered in the study.",type:"boolean"}},required:["contactEmail","logoPath","withProgressBar","sidebar"],type:"object"},WebsiteComponent:{additionalProperties:!1,description:"The WebsiteComponent interface is used to define the properties of a website component. A WebsiteComponent is used to render an iframe with a website inside of it. This can be used to display an external website or an html file that is located in the public folder.",properties:{correctAnswer:{description:"The correct answer to the component. This is used for training trials where the user is shown the correct answer after a guess.",items:{$ref:"#/definitions/Answer"},type:"array"},description:{description:"The description of the component. This is used to identify and provide additional information for the component in the admin panel.",type:"string"},instruction:{description:"The instruction of the component. This is used to identify and provide additional information for the component in the admin panel.",type:"string"},instructionLocation:{$ref:"#/definitions/ResponseBlockLocation",description:"The location of the instructions."},meta:{additionalProperties:{},description:"The meta data for the component. This is used to identify and provide additional information for the component in the admin panel.",type:"object"},nextButtonLocation:{$ref:"#/definitions/ResponseBlockLocation",description:"The location of the next button."},nextButtonText:{description:"The text that is displayed on the next button.",type:"string"},parameters:{additionalProperties:{},description:"The parameters that are passed to the website (iframe). These can be used within your website to render different things.",type:"object"},path:{description:"The path to the website. This should be a relative path from the public folder or could be an external website.",type:"string"},response:{description:"The responses to the component",items:{$ref:"#/definitions/Response"},type:"array"},type:{const:"website",type:"string"}},required:["path","response","type"],type:"object"}},hLe={$ref:cLe,$schema:fLe,definitions:dLe},pLe="#/definitions/GlobalConfig",mLe="http://json-schema.org/draft-07/schema#",gLe={GlobalConfig:{additionalProperties:!1,description:"The GlobalConfig is used to generate the list of available studies in the UI. This list is displayed on the landing page when running the app.",properties:{$schema:{description:"A required json schema property. This should point to the github link for the version of the schema you would like. See examples for more information",type:"string"},configs:{additionalProperties:{additionalProperties:!1,description:"The key is used to identify the study config file. This key is used in the configList property.",properties:{path:{description:"The path to the study config file. This should be a relative path from the public folder.",type:"string"}},required:["path"],type:"object"},description:"A required property that specifies the options for the configList property.",type:"object"},configsList:{description:"A required property that is used to generate the list of available studies in the UI. This list is displayed on the landing page when running the app.",items:{type:"string"},type:"array"}},required:["$schema","configs","configsList"],type:"object"}},yLe={$ref:pLe,$schema:mLe,definitions:gLe},mne=new pne;mne.addSchema(yLe);const FU=mne.getSchema("#/definitions/GlobalConfig"),gne=new pne;gne.addSchema(hLe);const BU=gne.getSchema("#/definitions/StudyConfig");function vLe(e){const t=[];return[e.configsList.every(r=>e.configs[r]===void 0?(t.push({message:`Config ${r} is not defined in configs object, but is present in configsList`}),!1):!0),t]}function uC(e){return e.baseComponent!==void 0}function _Le(e){const t=s3.parse(e),n=FU(t),r=vLe(t);if(n&&r[0])return t;throw console.error("Global config parsing errors",[...FU.errors||[],...r[1]]),Error("There was an issue validating your file global.json")}function bLe(e){const t=[];return[Object.values(e.components).every(r=>{var i;return uC(r)?!!((i=e.baseComponents)!=null&&i[r.baseComponent]):!0}),t]}function yne(e,t){const n=s3.parse(e),r=BU(n),i=bLe(n);if(r&&i[0])return n;throw console.error(`${t} parsing errors`,[...BU.errors||[],...i[1]]),Error(`There was an issue validating your file ${t}`)}function Da(e){for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;r3?t.i-4:t.i:Array.isArray(e)?1:W3(e)?2:q3(e)?3:0}function rm(e,t){return Tg(e)===2?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function wLe(e,t){return Tg(e)===2?e.get(t):e[t]}function vne(e,t,n){var r=Tg(e);r===2?e.set(t,n):r===3?e.add(n):e[t]=n}function _ne(e,t){return e===t?e!==0||1/e==1/t:e!=e&&t!=t}function W3(e){return CLe&&e instanceof Map}function q3(e){return ALe&&e instanceof Set}function md(e){return e.o||e.t}function G3(e){if(Array.isArray(e))return Array.prototype.slice.call(e);var t=wne(e);delete t[fr];for(var n=im(t),r=0;r1&&(e.set=e.add=e.clear=e.delete=ELe),Object.freeze(e),t&&hh(e,function(n,r){return Y3(r,!0)},!0)),e}function ELe(){Da(2)}function K3(e){return e==null||typeof e!="object"||Object.isFrozen(e)}function Bu(e){var t=pN[e];return t||Da(18,e),t}function SLe(e,t){pN[e]||(pN[e]=t)}function fN(){return Tv}function iO(e,t){t&&(Bu("Patches"),e.u=[],e.s=[],e.v=t)}function PT(e){dN(e),e.p.forEach(TLe),e.p=null}function dN(e){e===Tv&&(Tv=e.l)}function jU(e){return Tv={p:[],l:Tv,h:e,m:!0,_:0}}function TLe(e){var t=e[fr];t.i===0||t.i===1?t.j():t.g=!0}function sO(e,t){t._=t.p.length;var n=t.p[0],r=e!==void 0&&e!==n;return t.h.O||Bu("ES5").S(t,e,r),r?(n[fr].P&&(PT(t),Da(4)),Yl(e)&&(e=OT(t,e),t.l||RT(t,e)),t.u&&Bu("Patches").M(n[fr].t,e,t.u,t.s)):e=OT(t,n,[]),PT(t),t.u&&t.v(t.u,t.s),e!==bne?e:void 0}function OT(e,t,n){if(K3(t))return t;var r=t[fr];if(!r)return hh(t,function(a,u){return UU(e,r,t,a,u,n)},!0),t;if(r.A!==e)return t;if(!r.P)return RT(e,r.t,!0),r.t;if(!r.I){r.I=!0,r.A._--;var i=r.i===4||r.i===5?r.o=G3(r.k):r.o,s=i,o=!1;r.i===3&&(s=new Set(i),i.clear(),o=!0),hh(s,function(a,u){return UU(e,r,i,a,u,n,o)}),RT(e,i,!1),n&&e.u&&Bu("Patches").N(r,n,e.u,e.s)}return r.o}function UU(e,t,n,r,i,s,o){if(Af(i)){var a=OT(e,i,s&&t&&t.i!==3&&!rm(t.R,r)?s.concat(r):void 0);if(vne(n,r,a),!Af(a))return;e.m=!1}else o&&n.add(i);if(Yl(i)&&!K3(i)){if(!e.h.D&&e._<1)return;OT(e,i),t&&t.A.l||RT(e,i)}}function RT(e,t,n){n===void 0&&(n=!1),!e.l&&e.h.D&&e.m&&Y3(t,n)}function oO(e,t){var n=e[fr];return(n?md(n):e)[t]}function VU(e,t){if(t in e)for(var n=Object.getPrototypeOf(e);n;){var r=Object.getOwnPropertyDescriptor(n,t);if(r)return r;n=Object.getPrototypeOf(n)}}function jc(e){e.P||(e.P=!0,e.l&&jc(e.l))}function aO(e){e.o||(e.o=G3(e.t))}function hN(e,t,n){var r=W3(t)?Bu("MapSet").F(t,n):q3(t)?Bu("MapSet").T(t,n):e.O?function(i,s){var o=Array.isArray(i),a={i:o?1:0,A:s?s.A:fN(),P:!1,I:!1,R:{},l:s,t:i,k:null,o:null,j:null,C:!1},u=a,l=Iv;o&&(u=[a],l=Q0);var c=Proxy.revocable(u,l),f=c.revoke,d=c.proxy;return a.k=d,a.j=f,d}(t,n):Bu("ES5").J(t,n);return(n?n.A:fN()).p.push(r),r}function ILe(e){return Af(e)||Da(22,e),function t(n){if(!Yl(n))return n;var r,i=n[fr],s=Tg(n);if(i){if(!i.P&&(i.i<4||!Bu("ES5").K(i)))return i.t;i.I=!0,r=zU(n,s),i.I=!1}else r=zU(n,s);return hh(r,function(o,a){i&&wLe(i.t,o)===a||vne(r,o,t(a))}),s===3?new Set(r):r}(e)}function zU(e,t){switch(t){case 2:return new Map(e);case 3:return Array.from(e)}return G3(e)}function xLe(){function e(s,o){var a=i[s];return a?a.enumerable=o:i[s]=a={configurable:!0,enumerable:o,get:function(){var u=this[fr];return Iv.get(u,s)},set:function(u){var l=this[fr];Iv.set(l,s,u)}},a}function t(s){for(var o=s.length-1;o>=0;o--){var a=s[o][fr];if(!a.P)switch(a.i){case 5:r(a)&&jc(a);break;case 4:n(a)&&jc(a)}}}function n(s){for(var o=s.t,a=s.k,u=im(a),l=u.length-1;l>=0;l--){var c=u[l];if(c!==fr){var f=o[c];if(f===void 0&&!rm(o,c))return!0;var d=a[c],h=d&&d[fr];if(h?h.t!==f:!_ne(d,f))return!0}}var p=!!o[fr];return u.length!==im(o).length+(p?0:1)}function r(s){var o=s.k;if(o.length!==s.t.length)return!0;var a=Object.getOwnPropertyDescriptor(o,o.length-1);if(a&&!a.get)return!0;for(var u=0;u1?g-1:0),b=1;b1?c-1:0),d=1;d=0;i--){var s=r[i];if(s.path.length===0&&s.op==="replace"){n=s.value;break}}i>-1&&(r=r.slice(i+1));var o=Bu("Patches").$;return Af(n)?o(n,r):this.produce(n,function(a){return o(a,r)})},e}(),Po=new OLe,Ene=Po.produce;Po.produceWithPatches.bind(Po);Po.setAutoFreeze.bind(Po);Po.setUseProxies.bind(Po);Po.applyPatches.bind(Po);Po.createDraft.bind(Po);Po.finishDraft.bind(Po);function xv(e){"@babel/helpers - typeof";return xv=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},xv(e)}function RLe(e,t){if(xv(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(xv(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function NLe(e){var t=RLe(e,"string");return xv(t)=="symbol"?t:String(t)}function kLe(e,t,n){return t=NLe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function GU(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function YU(e){for(var t=1;t"u"&&(n=t,t=void 0),typeof n<"u"){if(typeof n!="function")throw new Error(Xi(1));return n(Sne)(e,t)}if(typeof e!="function")throw new Error(Xi(2));var i=e,s=t,o=[],a=o,u=!1;function l(){a===o&&(a=o.slice())}function c(){if(u)throw new Error(Xi(3));return s}function f(m){if(typeof m!="function")throw new Error(Xi(4));if(u)throw new Error(Xi(5));var y=!0;return l(),a.push(m),function(){if(y){if(u)throw new Error(Xi(6));y=!1,l();var v=a.indexOf(m);a.splice(v,1),o=null}}}function d(m){if(!DLe(m))throw new Error(Xi(7));if(typeof m.type>"u")throw new Error(Xi(8));if(u)throw new Error(Xi(9));try{u=!0,s=i(s,m)}finally{u=!1}for(var y=o=a,g=0;g"u")throw new Error(Xi(12));if(typeof n(void 0,{type:NT.PROBE_UNKNOWN_ACTION()})>"u")throw new Error(Xi(13))})}function LLe(e){for(var t=Object.keys(e),n={},r=0;r"u")throw l&&l.type,new Error(Xi(14));f[h]=y,c=c||y!==m}return c=c||s.length!==Object.keys(u).length,c?f:u}}function kT(){for(var e=arguments.length,t=new Array(e),n=0;n0&&s[s.length-1])&&(l[0]===6||l[0]===2)){n=0;continue}if(l[0]===3&&(!s||l[1]>s[0]&&l[1]0)for(var b=h.getState(),S=Array.from(n.values()),T=0,E=S;T({[c]:{}}))},s=Object.assign({},...n.map(c=>({[c]:{aboveStimulus:{valid:!1,values:{}},belowStimulus:{valid:!1,values:{}},sidebar:{valid:!1,values:{}}}}))),o=Object.assign({},...n.map(c=>({[c]:{aboveStimulus:!0,belowStimulus:!0,sidebar:!0,values:{}}}))),a={studyId:e,answers:r||i,isRecording:!1,sequence:n,config:t,showAdmin:!1,showHelpText:!1,alertModal:{show:!1,message:""},trialValidation:r?o:s,iframeAnswers:[]},u=One({name:"storeSlice",initialState:a,reducers:{setConfig(c,f){c.config=f.payload},setIsRecording(c,f){c.isRecording=f.payload},toggleShowAdmin:c=>{c.showAdmin=!c.showAdmin},toggleShowHelpText:c=>{c.showHelpText=!c.showHelpText},setAlertModal:(c,f)=>{c.alertModal=f.payload},setIframeAnswers:(c,f)=>{c.iframeAnswers=f.payload},updateResponseBlockValidation:(c,{payload:f})=>{!f.currentStep||f.currentStep.length===0||(c.trialValidation[f.currentStep]||(c.trialValidation[f.currentStep]={aboveStimulus:{valid:!1,values:{}},belowStimulus:{valid:!1,values:{}},sidebar:{valid:!1,values:{}},provenanceGraph:void 0}),c.trialValidation[f.currentStep][f.location]={valid:f.status,values:f.values},f.provenanceGraph&&(c.trialValidation[f.currentStep].provenanceGraph=f.provenanceGraph))},saveTrialAnswer(c,{payload:f}){const{currentStep:d,answer:h,startTime:p,endTime:m,provenanceGraph:y,windowEvents:g}=f;c.answers[d]={answer:h,startTime:p,endTime:m,provenanceGraph:y,windowEvents:g}}}});return{store:Ane({reducer:u.reducer,preloadedState:a}),actions:u.actions}}const jne=w.createContext(null);function Xu(){return w.useContext(jne).actions}const Ju=Ote,la=Vke;function SMe(e){return la(t=>{if(e===void 0||e.length===0)return!0;const n=Object.values(t.trialValidation[e]).every(r=>typeof r=="object"&&"valid"in r?r.valid:!0);return n?Object.values(n).every(r=>r):!1})}var $T={exports:{}};$T.exports;(function(e,t){var n=200,r="__lodash_hash_undefined__",i=800,s=16,o=9007199254740991,a="[object Arguments]",u="[object Array]",l="[object AsyncFunction]",c="[object Boolean]",f="[object Date]",d="[object Error]",h="[object Function]",p="[object GeneratorFunction]",m="[object Map]",y="[object Number]",g="[object Null]",v="[object Object]",b="[object Proxy]",S="[object RegExp]",T="[object Set]",E="[object String]",I="[object Undefined]",A="[object WeakMap]",R="[object ArrayBuffer]",F="[object DataView]",L="[object Float32Array]",B="[object Float64Array]",J="[object Int8Array]",V="[object Int16Array]",re="[object Int32Array]",oe="[object Uint8Array]",ae="[object Uint8ClampedArray]",ee="[object Uint16Array]",ue="[object Uint32Array]",P=/[\\^$.*+?()[\]{}|]/g,W=/^\[object .+?Constructor\]$/,Q=/^(?:0|[1-9]\d*)$/,x={};x[L]=x[B]=x[J]=x[V]=x[re]=x[oe]=x[ae]=x[ee]=x[ue]=!0,x[a]=x[u]=x[R]=x[c]=x[F]=x[f]=x[d]=x[h]=x[m]=x[y]=x[v]=x[S]=x[T]=x[E]=x[A]=!1;var O=typeof _o=="object"&&_o&&_o.Object===Object&&_o,$=typeof self=="object"&&self&&self.Object===Object&&self,q=O||$||Function("return this")(),ce=t&&!t.nodeType&&t,fe=ce&&!0&&e&&!e.nodeType&&e,de=fe&&fe.exports===ce,ve=de&&O.process,Ee=function(){try{var H=fe&&fe.require&&fe.require("util").types;return H||ve&&ve.binding&&ve.binding("util")}catch{}}(),ge=Ee&&Ee.isTypedArray;function nt(H,ie,ye){switch(ye.length){case 0:return H.call(ie);case 1:return H.call(ie,ye[0]);case 2:return H.call(ie,ye[0],ye[1]);case 3:return H.call(ie,ye[0],ye[1],ye[2])}return H.apply(ie,ye)}function Je(H,ie){for(var ye=-1,Ge=Array(H);++ye-1}function z(H,ie){var ye=this.__data__,Ge=wr(ye,H);return Ge<0?(++this.size,ye.push([H,ie])):ye[Ge][1]=ie,this}Yn.prototype.clear=fs,Yn.prototype.delete=Kr,Yn.prototype.get=jr,Yn.prototype.has=X,Yn.prototype.set=z;function Z(H){var ie=-1,ye=H==null?0:H.length;for(this.clear();++ie1?ye[dn-1]:void 0,ar=dn>2?ye[2]:void 0;for(Gn=H.length>3&&typeof Gn=="function"?(dn--,Gn):void 0,ar&&wn(ye[0],ye[1],ar)&&(Gn=dn<3?void 0:Gn,dn=1),ie=Object(ie);++Ge-1&&H%1==0&&H0){if(++ie>=i)return arguments[0]}else ie=0;return H.apply(void 0,arguments)}}function GA(H){if(H!=null){try{return Fe.call(H)}catch{}try{return H+""}catch{}}return""}function Yh(H,ie){return H===ie||H!==H&&ie!==ie}var Kh=Ei(function(){return arguments}())?Ei:function(H){return r0(H)&&st.call(H,"callee")&&!Ze.call(H,"callee")},YA=Array.isArray;function KA(H){return H!=null&&i5(H.length)&&!QA(H)}function jhe(H){return r0(H)&&KA(H)}var r5=_r||Whe;function QA(H){if(!ad(H))return!1;var ie=ds(H);return ie==h||ie==p||ie==l||ie==b}function i5(H){return typeof H=="number"&&H>-1&&H%1==0&&H<=o}function ad(H){var ie=typeof H;return H!=null&&(ie=="object"||ie=="function")}function r0(H){return H!=null&&typeof H=="object"}function Uhe(H){if(!r0(H)||ds(H)!=v)return!1;var ie=In(H);if(ie===null)return!0;var ye=st.call(ie,"constructor")&&ie.constructor;return typeof ye=="function"&&ye instanceof ye&&Fe.call(ye)==Kt}var s5=ge?yt(ge):Vi;function Vhe(H){return ne(H,o5(H))}function o5(H){return KA(H)?kn(H,!0):zi(H)}var zhe=be(function(H,ie,ye){We(H,ie,ye)});function Hhe(H){return function(){return H}}function a5(H){return H}function Whe(){return!1}e.exports=zhe})($T,$T.exports);var TMe=$T.exports;const Z3=eu(TMe);function Une(){return Nh().pathname.split("/")[1]}function hl(){const{trialName:e}=uh();return e||""}function Ig(e){return structuredClone(e)}function e6(){const{answers:e}=la(n=>n),t=hl();return e[t]}const Vne=w.createContext(null);function IMe(){const e=w.useContext(Vne);if(!e)throw new Error("useWindowEvents must be used within a WindowEventsProvider");return e}function xMe(){const e=hl(),{sequence:t,trialValidation:n}=la(g=>g),r=e6(),i=Ju(),{saveTrialAnswer:s,setIframeAnswers:o}=Xu(),{storageEngine:a}=sa(),l=!SMe(e),c=r==null?void 0:r.answer,f=Kf(),d=w.useMemo(()=>{const g=t.indexOf(e);return t[g+1]||"end"},[e,t]),h=`/${Une()}/${d}`,p=w.useMemo(()=>Date.now(),[]),m=IMe(),y=w.useCallback(()=>{const g=Ig(n[e]),v=Object.values(g).reduce((E,I)=>Object.hasOwn(I,"values")?{...E,...I.values}:E,{}),{provenanceGraph:b}=g,S=Date.now(),T=m&&"current"in m&&m.current?m.current.splice(0,m.current.length):[];Object.keys(c||{}).length===0&&(i(s({currentStep:e,answer:v,startTime:p,endTime:S,provenanceGraph:b,windowEvents:T})),a&&a.saveAnswer(e,{answer:v,startTime:p,endTime:S,provenanceGraph:b,windowEvents:T}),i(o([]))),f(`${h}${window.location.search}`)},[o,a,i,c,n,f,p,e,s,h,m]);return{nextStep:d,isNextDisabled:l,goToNextStep:y}}function CMe({label:e="Next",disabled:t=!1,setCheckClicked:n=()=>null,onClick:r}){const{isNextDisabled:i,goToNextStep:s}=xMe(),o=w.useCallback(()=>{n(!1),r&&r(),s()},[s,r,n]);return C.jsx(Ws,{type:"submit",disabled:t||i,onClick:o,children:e})}function vN(e){return e===null||typeof e!="object"?{}:Object.keys(e).reduce((t,n)=>{const r=e[n];return r!=null&&r!==!1&&(t[n]=r),t},{})}var AMe=Object.defineProperty,iV=Object.getOwnPropertySymbols,PMe=Object.prototype.hasOwnProperty,OMe=Object.prototype.propertyIsEnumerable,sV=(e,t,n)=>t in e?AMe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,RMe=(e,t)=>{for(var n in t||(t={}))PMe.call(t,n)&&sV(e,n,t[n]);if(iV)for(var n of iV(t))OMe.call(t,n)&&sV(e,n,t[n]);return e};function zne(e,t){if(t===null||typeof t!="object")return{};const n=RMe({},t);return Object.keys(t).forEach(r=>{r.includes(`${String(e)}.`)&&delete n[r]}),n}const NMe="__MANTINE_FORM_INDEX__";function oV(e,t){return t?typeof t=="boolean"?t:Array.isArray(t)?t.includes(e.replace(/[.][0-9]/g,`.${NMe}`)):!1:!1}function aV(e,t,n){typeof n.value=="object"&&(n.value=kp(n.value)),!n.enumerable||n.get||n.set||!n.configurable||!n.writable||t==="__proto__"?Object.defineProperty(e,t,n):e[t]=n.value}function kp(e){if(typeof e!="object")return e;var t=0,n,r,i,s=Object.prototype.toString.call(e);if(s==="[object Object]"?i=Object.create(e.__proto__||null):s==="[object Array]"?i=Array(e.length):s==="[object Set]"?(i=new Set,e.forEach(function(o){i.add(kp(o))})):s==="[object Map]"?(i=new Map,e.forEach(function(o,a){i.set(kp(a),kp(o))})):s==="[object Date]"?i=new Date(+e):s==="[object RegExp]"?i=new RegExp(e.source,e.flags):s==="[object DataView]"?i=new e.constructor(kp(e.buffer)):s==="[object ArrayBuffer]"?i=e.slice(0):s.slice(-6)==="Array]"&&(i=new e.constructor(e)),i){for(r=Object.getOwnPropertySymbols(e);t0,errors:t}}function _N(e,t,n="",r={}){return typeof e!="object"||e===null?r:Object.keys(e).reduce((i,s)=>{const o=e[s],a=`${n===""?"":`${n}.`}${s}`,u=Tl(a,t);let l=!1;return typeof o=="function"&&(i[a]=o(u,t,a)),typeof o=="object"&&Array.isArray(u)&&(l=!0,u.forEach((c,f)=>_N(o,t,`${a}.${f}`,i))),typeof o=="object"&&typeof u=="object"&&u!==null&&(l||_N(o,t,a,i)),i},r)}function bN(e,t){return uV(typeof e=="function"?e(t):_N(e,t))}function Cb(e,t,n){if(typeof e!="string")return{hasError:!1,error:null};const r=bN(t,n),i=Object.keys(r.errors).find(s=>e.split(".").every((o,a)=>o===s.split(".")[a]));return{hasError:!!i,error:i?r.errors[i]:null}}function kMe(e,{from:t,to:n},r){const i=Tl(e,r);if(!Array.isArray(i))return r;const s=[...i],o=i[t];return s.splice(t,1),s.splice(n,0,o),cC(e,s,r)}var DMe=Object.defineProperty,lV=Object.getOwnPropertySymbols,$Me=Object.prototype.hasOwnProperty,LMe=Object.prototype.propertyIsEnumerable,cV=(e,t,n)=>t in e?DMe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,MMe=(e,t)=>{for(var n in t||(t={}))$Me.call(t,n)&&cV(e,n,t[n]);if(lV)for(var n of lV(t))LMe.call(t,n)&&cV(e,n,t[n]);return e};function FMe(e,{from:t,to:n},r){const i=`${e}.${t}`,s=`${e}.${n}`,o=MMe({},r);return Object.keys(r).every(a=>{let u,l;if(a.startsWith(i)&&(u=a,l=a.replace(i,s)),a.startsWith(s)&&(u=a.replace(s,i),l=a),u&&l){const c=o[u],f=o[l];return f===void 0?delete o[u]:o[u]=f,c===void 0?delete o[l]:o[l]=c,!1}return!0}),o}function BMe(e,t,n){const r=Tl(e,n);return Array.isArray(r)?cC(e,r.filter((i,s)=>s!==t),n):n}var jMe=Object.defineProperty,fV=Object.getOwnPropertySymbols,UMe=Object.prototype.hasOwnProperty,VMe=Object.prototype.propertyIsEnumerable,dV=(e,t,n)=>t in e?jMe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,zMe=(e,t)=>{for(var n in t||(t={}))UMe.call(t,n)&&dV(e,n,t[n]);if(fV)for(var n of fV(t))VMe.call(t,n)&&dV(e,n,t[n]);return e};function hV(e,t){const n=e.substring(t.length+1).split(".")[0];return parseInt(n,10)}function pV(e,t,n,r){if(t===void 0)return n;const i=`${String(e)}`;let s=n;r===-1&&(s=zne(`${i}.${t}`,s));const o=zMe({},s),a=new Set;return Object.entries(s).filter(([u])=>{if(!u.startsWith(`${i}.`))return!1;const l=hV(u,i);return Number.isNaN(l)?!1:l>=t}).forEach(([u,l])=>{const c=hV(u,i),f=u.replace(`${i}.${c}`,`${i}.${c+r}`);o[f]=l,a.add(f),a.has(u)||delete o[u]}),o}function HMe(e,t,n,r){const i=Tl(e,r);if(!Array.isArray(i))return r;const s=[...i];return s.splice(typeof n=="number"?n:s.length,0,t),cC(e,s,r)}function mV(e,t){const n=Object.keys(e);if(typeof t=="string"){const r=n.filter(i=>i.startsWith(`${t}.`));return e[t]||r.some(i=>e[i])||!1}return n.some(r=>e[r])}function WMe(e){return t=>{if(!t)e(t);else if(typeof t=="function")e(t);else if(typeof t=="object"&&"nativeEvent"in t){const{currentTarget:n}=t;n instanceof HTMLInputElement?n.type==="checkbox"?e(n.checked):e(n.value):(n instanceof HTMLTextAreaElement||n instanceof HTMLSelectElement)&&e(n.value)}else e(t)}}var qMe=Object.defineProperty,GMe=Object.defineProperties,YMe=Object.getOwnPropertyDescriptors,gV=Object.getOwnPropertySymbols,KMe=Object.prototype.hasOwnProperty,QMe=Object.prototype.propertyIsEnumerable,yV=(e,t,n)=>t in e?qMe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Tc=(e,t)=>{for(var n in t||(t={}))KMe.call(t,n)&&yV(e,n,t[n]);if(gV)for(var n of gV(t))QMe.call(t,n)&&yV(e,n,t[n]);return e},fO=(e,t)=>GMe(e,YMe(t));function XMe({initialValues:e={},initialErrors:t={},initialDirty:n={},initialTouched:r={},clearInputErrorOnChange:i=!0,validateInputOnChange:s=!1,validateInputOnBlur:o=!1,transformValues:a=l=>l,validate:u}={}){const[l,c]=w.useState(r),[f,d]=w.useState(n),[h,p]=w.useState(e),[m,y]=w.useState(vN(t)),g=w.useRef(e),v=$=>{g.current=$},b=w.useCallback(()=>c({}),[]),S=$=>{const q=$?Tc(Tc({},h),$):h;v(q),d({})},T=w.useCallback($=>y(q=>vN(typeof $=="function"?$(q):$)),[]),E=w.useCallback(()=>y({}),[]),I=w.useCallback(()=>{p(e),E(),v(e),d({}),b()},[]),A=w.useCallback(($,q)=>T(ce=>fO(Tc({},ce),{[$]:q})),[]),R=w.useCallback($=>T(q=>{if(typeof $!="string")return q;const ce=Tc({},q);return delete ce[$],ce}),[]),F=w.useCallback($=>d(q=>{if(typeof $!="string")return q;const ce=zne($,q);return delete ce[$],ce}),[]),L=w.useCallback(($,q)=>{const ce=oV($,s);F($),c(fe=>fO(Tc({},fe),{[$]:!0})),p(fe=>{const de=cC($,q,fe);if(ce){const ve=Cb($,u,de);ve.hasError?A($,ve.error):R($)}return de}),!ce&&i&&A($,null)},[]),B=w.useCallback($=>{p(q=>{const ce=typeof $=="function"?$(q):$;return Tc(Tc({},q),ce)}),i&&E()},[]),J=w.useCallback(($,q)=>{F($),p(ce=>kMe($,q,ce)),y(ce=>FMe($,q,ce))},[]),V=w.useCallback(($,q)=>{F($),p(ce=>BMe($,q,ce)),y(ce=>pV($,q,ce,-1))},[]),re=w.useCallback(($,q,ce)=>{F($),p(fe=>HMe($,q,ce,fe)),y(fe=>pV($,ce,fe,1))},[]),oe=w.useCallback(()=>{const $=bN(u,h);return y($.errors),$},[h,u]),ae=w.useCallback($=>{const q=Cb($,u,h);return q.hasError?A($,q.error):R($),q},[h,u]),ee=($,{type:q="input",withError:ce=!0,withFocus:fe=!0}={})=>{const ve={onChange:WMe(Ee=>L($,Ee))};return ce&&(ve.error=m[$]),q==="checkbox"?ve.checked=Tl($,h):ve.value=Tl($,h),fe&&(ve.onFocus=()=>c(Ee=>fO(Tc({},Ee),{[$]:!0})),ve.onBlur=()=>{if(oV($,o)){const Ee=Cb($,u,h);Ee.hasError?A($,Ee.error):R($)}}),ve},ue=($,q)=>ce=>{ce==null||ce.preventDefault();const fe=oe();fe.hasErrors?q==null||q(fe.errors,h,ce):$==null||$(a(h),ce)},P=$=>a($||h),W=w.useCallback($=>{$.preventDefault(),I()},[]),Q=$=>{if($){const ce=Tl($,f);if(typeof ce=="boolean")return ce;const fe=Tl($,h),de=Tl($,g.current);return!bU(fe,de)}return Object.keys(f).length>0?mV(f):!bU(h,g.current)},x=w.useCallback($=>mV(l,$),[l]),O=w.useCallback($=>$?!Cb($,u,h).hasError:!bN(u,h).hasErrors,[h,u]);return{values:h,errors:m,setValues:B,setErrors:T,setFieldValue:L,setFieldError:A,clearFieldError:R,clearErrors:E,reset:I,validate:oe,validateField:ae,reorderListItem:J,removeListItem:V,insertListItem:re,getInputProps:ee,onSubmit:ue,onReset:W,isDirty:Q,isTouched:x,setTouched:c,setDirty:d,resetTouched:b,resetDirty:S,isValid:O,getTransformedValues:P}}const JMe=new URLSearchParams(window.location.search),ZMe=(e,t)=>{let n={};return e.forEach(r=>{const i=t?t[r.id]:{};if(i)n={...n,[r.id]:i};else{const s=r.paramCapture?JMe.get(r.paramCapture):"";n={...n,[r.id]:r.type==="iframe"?[]:s}}}),{...n}},e4e=e=>{let t={};return e.forEach(n=>{n.required&&(t={...t,[n.id]:r=>{if(Array.isArray(r)){if(n.requiredValue!=null&&!Array.isArray(n.requiredValue))return"Incorrect required value";if(n.requiredValue!=null&&Array.isArray(n.requiredValue)){if(n.requiredValue.length!==r.length)return"Incorrect input";const i=[...n.requiredValue].sort(),s=[...r].sort();return i.every((o,a)=>o===s[a])?null:"Incorrect input"}return r.length===0?"Empty input":null}return n.required&&n.requiredValue!=null&&r!=null?r.toString()!==n.requiredValue.toString()?"Incorrect input":null:n.required?r==null||r===""?"Empty input":null:r===null?"Empty input":null}})}),t};function t4e(e,t,n){const[r,i]=w.useState(null),s=XMe({initialValues:ZMe(e,n),validate:e4e(e)});return w.useEffect(()=>{r!==t&&(i(t),s.reset())},[r,s,t]),s}function Lh(e,t,n){var o;const{requiredValue:r,requiredLabel:i}=e;let s="";return t.checked&&Array.isArray(r)?s=r&&[...r].sort().toString()!==[...t.checked].sort().toString()?`Please ${n?"select":"enter"} ${i||r.toString()} to continue.`:null:s=t.value&&r&&r.toString()!==t.value.toString()?`Please ${n?"select":"enter"} ${i||(n?(o=n.find(a=>a.value===r))==null?void 0:o.label:r.toString())} to continue.`:null,s}const vV=["http","https","mailto","tel"];function n4e(e){const t=(e||"").trim(),n=t.charAt(0);if(n==="#"||n==="/")return t;const r=t.indexOf(":");if(r===-1)return t;let i=-1;for(;++ii||(i=t.indexOf("#"),i!==-1&&r>i)?t:"javascript:void(0)"}/*! + deps: ${c}}`};const i={keyword:"dependencies",type:"object",schemaType:"object",error:e.error,code(u){const[l,c]=s(u);o(u,l),a(u,c)}};function s({schema:u}){const l={},c={};for(const f in u){if(f==="__proto__")continue;const d=Array.isArray(u[f])?l:c;d[f]=u[f]}return[l,c]}function o(u,l=u.schema){const{gen:c,data:f,it:d}=u;if(Object.keys(l).length===0)return;const h=c.let("missing");for(const p in l){const m=l[p];if(m.length===0)continue;const y=(0,r.propertyInData)(c,f,p,d.opts.ownProperties);u.setParams({property:p,depsCount:m.length,deps:m.join(", ")}),d.allErrors?c.if(y,()=>{for(const g of m)(0,r.checkReportMissingProp)(u,g)}):(c.if((0,t._)`${y} && (${(0,r.checkMissingProp)(u,m,h)})`),(0,r.reportMissingProp)(u,h),c.else())}}e.validatePropertyDeps=o;function a(u,l=u.schema){const{gen:c,data:f,keyword:d,it:h}=u,p=c.name("valid");for(const m in l)(0,n.alwaysValidSchema)(h,l[m])||(c.if((0,r.propertyInData)(c,f,m,h.opts.ownProperties),()=>{const y=u.subschema({keyword:d,schemaProp:m},p);u.mergeValidEvaluated(y,p)},()=>c.var(p,!0)),u.ok(p))}e.validateSchemaDeps=a,e.default=i})(cne);var N3={};Object.defineProperty(N3,"__esModule",{value:!0});const fne=Xt,s6e=_n,o6e={message:"property name must be valid",params:({params:e})=>(0,fne._)`{propertyName: ${e.propertyName}}`},a6e={keyword:"propertyNames",type:"object",schemaType:["object","boolean"],error:o6e,code(e){const{gen:t,schema:n,data:r,it:i}=e;if((0,s6e.alwaysValidSchema)(i,n))return;const s=t.name("valid");t.forIn("key",r,o=>{e.setParams({propertyName:o}),e.subschema({keyword:"propertyNames",data:o,dataTypes:["string"],propertyName:o,compositeRule:!0},s),t.if((0,fne.not)(s),()=>{e.error(!0),i.allErrors||t.break()})}),e.ok(s)}};N3.default=a6e;var aC={};Object.defineProperty(aC,"__esModule",{value:!0});const Tb=Qt,Ta=Xt,u6e=dl,Ib=_n,l6e={message:"must NOT have additional properties",params:({params:e})=>(0,Ta._)`{additionalProperty: ${e.additionalProperty}}`},c6e={keyword:"additionalProperties",type:["object"],schemaType:["boolean","object"],allowUndefined:!0,trackErrors:!0,error:l6e,code(e){const{gen:t,schema:n,parentSchema:r,data:i,errsCount:s,it:o}=e;if(!s)throw new Error("ajv implementation error");const{allErrors:a,opts:u}=o;if(o.props=!0,u.removeAdditional!=="all"&&(0,Ib.alwaysValidSchema)(o,n))return;const l=(0,Tb.allSchemaProperties)(r.properties),c=(0,Tb.allSchemaProperties)(r.patternProperties);f(),e.ok((0,Ta._)`${s} === ${u6e.default.errors}`);function f(){t.forIn("key",i,y=>{!l.length&&!c.length?p(y):t.if(d(y),()=>p(y))})}function d(y){let g;if(l.length>8){const v=(0,Ib.schemaRefOrVal)(o,r.properties,"properties");g=(0,Tb.isOwnProperty)(t,v,y)}else l.length?g=(0,Ta.or)(...l.map(v=>(0,Ta._)`${y} === ${v}`)):g=Ta.nil;return c.length&&(g=(0,Ta.or)(g,...c.map(v=>(0,Ta._)`${(0,Tb.usePattern)(e,v)}.test(${y})`))),(0,Ta.not)(g)}function h(y){t.code((0,Ta._)`delete ${i}[${y}]`)}function p(y){if(u.removeAdditional==="all"||u.removeAdditional&&n===!1){h(y);return}if(n===!1){e.setParams({additionalProperty:y}),e.error(),a||t.break();return}if(typeof n=="object"&&!(0,Ib.alwaysValidSchema)(o,n)){const g=t.name("valid");u.removeAdditional==="failing"?(m(y,g,!1),t.if((0,Ta.not)(g),()=>{e.reset(),h(y)})):(m(y,g),a||t.if((0,Ta.not)(g),()=>t.break()))}}function m(y,g,v){const b={keyword:"additionalProperties",dataProp:y,dataPropType:Ib.Type.Str};v===!1&&Object.assign(b,{compositeRule:!0,createErrors:!1,allErrors:!1}),e.subschema(b,g)}}};aC.default=c6e;var k3={};Object.defineProperty(k3,"__esModule",{value:!0});const f6e=Va,PU=Qt,rO=_n,OU=aC,d6e={keyword:"properties",type:"object",schemaType:"object",code(e){const{gen:t,schema:n,parentSchema:r,data:i,it:s}=e;s.opts.removeAdditional==="all"&&r.additionalProperties===void 0&&OU.default.code(new f6e.KeywordCxt(s,OU.default,"additionalProperties"));const o=(0,PU.allSchemaProperties)(n);for(const f of o)s.definedProperties.add(f);s.opts.unevaluated&&o.length&&s.props!==!0&&(s.props=rO.mergeEvaluated.props(t,(0,rO.toHash)(o),s.props));const a=o.filter(f=>!(0,rO.alwaysValidSchema)(s,n[f]));if(a.length===0)return;const u=t.name("valid");for(const f of a)l(f)?c(f):(t.if((0,PU.propertyInData)(t,i,f,s.opts.ownProperties)),c(f),s.allErrors||t.else().var(u,!0),t.endIf()),e.it.definedProperties.add(f),e.ok(u);function l(f){return s.opts.useDefaults&&!s.compositeRule&&n[f].default!==void 0}function c(f){e.subschema({keyword:"properties",schemaProp:f,dataProp:f},u)}}};k3.default=d6e;var D3={};Object.defineProperty(D3,"__esModule",{value:!0});const RU=Qt,xb=Xt,NU=_n,kU=_n,h6e={keyword:"patternProperties",type:"object",schemaType:"object",code(e){const{gen:t,schema:n,data:r,parentSchema:i,it:s}=e,{opts:o}=s,a=(0,RU.allSchemaProperties)(n),u=a.filter(m=>(0,NU.alwaysValidSchema)(s,n[m]));if(a.length===0||u.length===a.length&&(!s.opts.unevaluated||s.props===!0))return;const l=o.strictSchema&&!o.allowMatchingProperties&&i.properties,c=t.name("valid");s.props!==!0&&!(s.props instanceof xb.Name)&&(s.props=(0,kU.evaluatedPropsToName)(t,s.props));const{props:f}=s;d();function d(){for(const m of a)l&&h(m),s.allErrors?p(m):(t.var(c,!0),p(m),t.if(c))}function h(m){for(const y in l)new RegExp(m).test(y)&&(0,NU.checkStrictMode)(s,`property ${y} matches pattern ${m} (use allowMatchingProperties)`)}function p(m){t.forIn("key",r,y=>{t.if((0,xb._)`${(0,RU.usePattern)(e,m)}.test(${y})`,()=>{const g=u.includes(m);g||e.subschema({keyword:"patternProperties",schemaProp:m,dataProp:y,dataPropType:kU.Type.Str},c),s.opts.unevaluated&&f!==!0?t.assign((0,xb._)`${f}[${y}]`,!0):!g&&!s.allErrors&&t.if((0,xb.not)(c),()=>t.break())})})}}};D3.default=h6e;var $3={};Object.defineProperty($3,"__esModule",{value:!0});const p6e=_n,m6e={keyword:"not",schemaType:["object","boolean"],trackErrors:!0,code(e){const{gen:t,schema:n,it:r}=e;if((0,p6e.alwaysValidSchema)(r,n)){e.fail();return}const i=t.name("valid");e.subschema({keyword:"not",compositeRule:!0,createErrors:!1,allErrors:!1},i),e.failResult(i,()=>e.reset(),()=>e.error())},error:{message:"must NOT be valid"}};$3.default=m6e;var L3={};Object.defineProperty(L3,"__esModule",{value:!0});const g6e=Qt,y6e={keyword:"anyOf",schemaType:"array",trackErrors:!0,code:g6e.validateUnion,error:{message:"must match a schema in anyOf"}};L3.default=y6e;var M3={};Object.defineProperty(M3,"__esModule",{value:!0});const Dw=Xt,v6e=_n,_6e={message:"must match exactly one schema in oneOf",params:({params:e})=>(0,Dw._)`{passingSchemas: ${e.passing}}`},b6e={keyword:"oneOf",schemaType:"array",trackErrors:!0,error:_6e,code(e){const{gen:t,schema:n,parentSchema:r,it:i}=e;if(!Array.isArray(n))throw new Error("ajv implementation error");if(i.opts.discriminator&&r.discriminator)return;const s=n,o=t.let("valid",!1),a=t.let("passing",null),u=t.name("_valid");e.setParams({passing:a}),t.block(l),e.result(o,()=>e.reset(),()=>e.error(!0));function l(){s.forEach((c,f)=>{let d;(0,v6e.alwaysValidSchema)(i,c)?t.var(u,!0):d=e.subschema({keyword:"oneOf",schemaProp:f,compositeRule:!0},u),f>0&&t.if((0,Dw._)`${u} && ${o}`).assign(o,!1).assign(a,(0,Dw._)`[${a}, ${f}]`).else(),t.if(u,()=>{t.assign(o,!0),t.assign(a,f),d&&e.mergeEvaluated(d,Dw.Name)})})}}};M3.default=b6e;var F3={};Object.defineProperty(F3,"__esModule",{value:!0});const w6e=_n,E6e={keyword:"allOf",schemaType:"array",code(e){const{gen:t,schema:n,it:r}=e;if(!Array.isArray(n))throw new Error("ajv implementation error");const i=t.name("valid");n.forEach((s,o)=>{if((0,w6e.alwaysValidSchema)(r,s))return;const a=e.subschema({keyword:"allOf",schemaProp:o},i);e.ok(i),e.mergeEvaluated(a)})}};F3.default=E6e;var B3={};Object.defineProperty(B3,"__esModule",{value:!0});const AT=Xt,dne=_n,S6e={message:({params:e})=>(0,AT.str)`must match "${e.ifClause}" schema`,params:({params:e})=>(0,AT._)`{failingKeyword: ${e.ifClause}}`},T6e={keyword:"if",schemaType:["object","boolean"],trackErrors:!0,error:S6e,code(e){const{gen:t,parentSchema:n,it:r}=e;n.then===void 0&&n.else===void 0&&(0,dne.checkStrictMode)(r,'"if" without "then" and "else" is ignored');const i=DU(r,"then"),s=DU(r,"else");if(!i&&!s)return;const o=t.let("valid",!0),a=t.name("_valid");if(u(),e.reset(),i&&s){const c=t.let("ifClause");e.setParams({ifClause:c}),t.if(a,l("then",c),l("else",c))}else i?t.if(a,l("then")):t.if((0,AT.not)(a),l("else"));e.pass(o,()=>e.error(!0));function u(){const c=e.subschema({keyword:"if",compositeRule:!0,createErrors:!1,allErrors:!1},a);e.mergeEvaluated(c)}function l(c,f){return()=>{const d=e.subschema({keyword:c},a);t.assign(o,a),e.mergeValidEvaluated(d,o),f?t.assign(f,(0,AT._)`${c}`):e.setParams({ifClause:c})}}}};function DU(e,t){const n=e.schema[t];return n!==void 0&&!(0,dne.alwaysValidSchema)(e,n)}B3.default=T6e;var j3={};Object.defineProperty(j3,"__esModule",{value:!0});const I6e=_n,x6e={keyword:["then","else"],schemaType:["object","boolean"],code({keyword:e,parentSchema:t,it:n}){t.if===void 0&&(0,I6e.checkStrictMode)(n,`"${e}" without "if" is ignored`)}};j3.default=x6e;Object.defineProperty(A3,"__esModule",{value:!0});const C6e=Eg,A6e=P3,P6e=Sg,O6e=O3,R6e=R3,N6e=cne,k6e=N3,D6e=aC,$6e=k3,L6e=D3,M6e=$3,F6e=L3,B6e=M3,j6e=F3,U6e=B3,V6e=j3;function z6e(e=!1){const t=[M6e.default,F6e.default,B6e.default,j6e.default,U6e.default,V6e.default,k6e.default,D6e.default,N6e.default,$6e.default,L6e.default];return e?t.push(A6e.default,O6e.default):t.push(C6e.default,P6e.default),t.push(R6e.default),t}A3.default=z6e;var U3={},V3={};Object.defineProperty(V3,"__esModule",{value:!0});const $r=Xt,H6e={message:({schemaCode:e})=>(0,$r.str)`must match format "${e}"`,params:({schemaCode:e})=>(0,$r._)`{format: ${e}}`},W6e={keyword:"format",type:["number","string"],schemaType:"string",$data:!0,error:H6e,code(e,t){const{gen:n,data:r,$data:i,schema:s,schemaCode:o,it:a}=e,{opts:u,errSchemaPath:l,schemaEnv:c,self:f}=a;if(!u.validateFormats)return;i?d():h();function d(){const p=n.scopeValue("formats",{ref:f.formats,code:u.code.formats}),m=n.const("fDef",(0,$r._)`${p}[${o}]`),y=n.let("fType"),g=n.let("format");n.if((0,$r._)`typeof ${m} == "object" && !(${m} instanceof RegExp)`,()=>n.assign(y,(0,$r._)`${m}.type || "string"`).assign(g,(0,$r._)`${m}.validate`),()=>n.assign(y,(0,$r._)`"string"`).assign(g,m)),e.fail$data((0,$r.or)(v(),b()));function v(){return u.strictSchema===!1?$r.nil:(0,$r._)`${o} && !${g}`}function b(){const S=c.$async?(0,$r._)`(${m}.async ? await ${g}(${r}) : ${g}(${r}))`:(0,$r._)`${g}(${r})`,T=(0,$r._)`(typeof ${g} == "function" ? ${S} : ${g}.test(${r}))`;return(0,$r._)`${g} && ${g} !== true && ${y} === ${t} && !${T}`}}function h(){const p=f.formats[s];if(!p){v();return}if(p===!0)return;const[m,y,g]=b(p);m===t&&e.pass(S());function v(){if(u.strictSchema===!1){f.logger.warn(T());return}throw new Error(T());function T(){return`unknown format "${s}" ignored in schema at path "${l}"`}}function b(T){const E=T instanceof RegExp?(0,$r.regexpCode)(T):u.code.formats?(0,$r._)`${u.code.formats}${(0,$r.getProperty)(s)}`:void 0,I=n.scopeValue("formats",{key:s,ref:T,code:E});return typeof T=="object"&&!(T instanceof RegExp)?[T.type||"string",T.validate,(0,$r._)`${I}.validate`]:["string",T,I]}function S(){if(typeof p=="object"&&!(p instanceof RegExp)&&p.async){if(!c.$async)throw new Error("async format in sync schema");return(0,$r._)`await ${g}(${r})`}return typeof y=="function"?(0,$r._)`${g}(${r})`:(0,$r._)`${g}.test(${r})`}}}};V3.default=W6e;Object.defineProperty(U3,"__esModule",{value:!0});const q6e=V3,G6e=[q6e.default];U3.default=G6e;var Vm={};Object.defineProperty(Vm,"__esModule",{value:!0});Vm.contentVocabulary=Vm.metadataVocabulary=void 0;Vm.metadataVocabulary=["title","description","default","deprecated","readOnly","writeOnly","examples"];Vm.contentVocabulary=["contentMediaType","contentEncoding","contentSchema"];Object.defineProperty(h3,"__esModule",{value:!0});const Y6e=p3,K6e=g3,Q6e=A3,X6e=U3,$U=Vm,J6e=[Y6e.default,K6e.default,(0,Q6e.default)(),X6e.default,$U.metadataVocabulary,$U.contentVocabulary];h3.default=J6e;var z3={},hne={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.DiscrError=void 0,function(t){t.Tag="tag",t.Mapping="mapping"}(e.DiscrError||(e.DiscrError={}))})(hne);Object.defineProperty(z3,"__esModule",{value:!0});const dp=Xt,lN=hne,LU=zs,Z6e=_n,eLe={message:({params:{discrError:e,tagName:t}})=>e===lN.DiscrError.Tag?`tag "${t}" must be string`:`value of tag "${t}" must be in oneOf`,params:({params:{discrError:e,tag:t,tagName:n}})=>(0,dp._)`{error: ${e}, tag: ${n}, tagValue: ${t}}`},tLe={keyword:"discriminator",type:"object",schemaType:"object",error:eLe,code(e){const{gen:t,data:n,schema:r,parentSchema:i,it:s}=e,{oneOf:o}=i;if(!s.opts.discriminator)throw new Error("discriminator: requires discriminator option");const a=r.propertyName;if(typeof a!="string")throw new Error("discriminator: requires propertyName");if(r.mapping)throw new Error("discriminator: mapping is not supported");if(!o)throw new Error("discriminator: requires oneOf keyword");const u=t.let("valid",!1),l=t.const("tag",(0,dp._)`${n}${(0,dp.getProperty)(a)}`);t.if((0,dp._)`typeof ${l} == "string"`,()=>c(),()=>e.error(!1,{discrError:lN.DiscrError.Tag,tag:l,tagName:a})),e.ok(u);function c(){const h=d();t.if(!1);for(const p in h)t.elseIf((0,dp._)`${l} === ${p}`),t.assign(u,f(h[p]));t.else(),e.error(!1,{discrError:lN.DiscrError.Mapping,tag:l,tagName:a}),t.endIf()}function f(h){const p=t.name("valid"),m=e.subschema({keyword:"oneOf",schemaProp:h},p);return e.mergeEvaluated(m,dp.Name),p}function d(){var h;const p={},m=g(i);let y=!0;for(let S=0;Sthis.addVocabulary(p)),this.opts.discriminator&&this.addKeyword(i.default)}_addDefaultMetaSchema(){if(super._addDefaultMetaSchema(),!this.opts.meta)return;const p=this.opts.$data?this.$dataMetaSchema(s,o):s;this.addMetaSchema(p,a,!1),this.refs["http://json-schema.org/schema"]=a}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(a)?a:void 0)}}e.exports=t=u,Object.defineProperty(t,"__esModule",{value:!0}),t.default=u;var l=Va;Object.defineProperty(t,"KeywordCxt",{enumerable:!0,get:function(){return l.KeywordCxt}});var c=Xt;Object.defineProperty(t,"_",{enumerable:!0,get:function(){return c._}}),Object.defineProperty(t,"str",{enumerable:!0,get:function(){return c.str}}),Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return c.stringify}}),Object.defineProperty(t,"nil",{enumerable:!0,get:function(){return c.nil}}),Object.defineProperty(t,"Name",{enumerable:!0,get:function(){return c.Name}}),Object.defineProperty(t,"CodeGen",{enumerable:!0,get:function(){return c.CodeGen}});var f=z_;Object.defineProperty(t,"ValidationError",{enumerable:!0,get:function(){return f.default}});var d=H_;Object.defineProperty(t,"MissingRefError",{enumerable:!0,get:function(){return d.default}})})(rN,rN.exports);var lLe=rN.exports;const pne=eu(lLe),cLe="#/definitions/StudyConfig",fLe="http://json-schema.org/draft-07/schema#",dLe={Answer:{additionalProperties:!1,description:"The Answer interface is used to define the properties of an answer. Answers are used to define the correct answer for a task. These are generally used in training tasks.",properties:{acceptableHigh:{description:"The acceptable high value for the answer. This is used to define a range of acceptable answers.",type:"number"},acceptableLow:{description:"The acceptable low value for the answer. This is used to define a range of acceptable answers.",type:"number"},answer:{description:"The correct answer to the question."},id:{description:"The id of the answer. This is used to identify the answer in the data file.",type:"string"}},required:["id","answer"],type:"object"},CheckboxResponse:{additionalProperties:!1,description:"The CheckboxResponse interface is used to define the properties of a checkbox response. CheckboxResponses render as a checkbox input with user specified options.",properties:{correctAnswer:{description:"The correct answer to the response. This is used in the data download and can be shown in the admin panel."},hidden:{description:"Controls whether the response is hidden.",type:"boolean"},id:{description:"The id of the response. This is used to identify the response in the data file.",type:"string"},location:{$ref:"#/definitions/ResponseBlockLocation",description:"Controls the response location. These might be the same for all responses, or differ across responses."},options:{description:"The options that are displayed as checkboxes.",items:{$ref:"#/definitions/Option"},type:"array"},paramCapture:{description:"Use to capture querystring parameters in answers such as participant_name. See the examples for how this is used, but prefer uiConfig.urlParticipantIdParam if you are capturing a participant ID.",type:"string"},prompt:{description:"The prompt that is displayed to the participant. You can use markdown here to render images, links, etc.",type:"string"},required:{description:"Controls whether the response is required to be answered.",type:"boolean"},requiredLabel:{description:"You can provide a required label, which makes it so a participant has to answer with a response that matches label.",type:"string"},requiredValue:{description:"You can provide a required value, which makes it so a participant has to answer with that value."},type:{const:"checkbox",type:"string"}},required:["id","location","options","prompt","required","type"],type:"object"},DropdownResponse:{additionalProperties:!1,description:"The DropdownResponse interface is used to define the properties of a dropdown response. DropdownResponses render as a select input with user specified options.",properties:{correctAnswer:{description:"The correct answer to the response. This is used in the data download and can be shown in the admin panel."},hidden:{description:"Controls whether the response is hidden.",type:"boolean"},id:{description:"The id of the response. This is used to identify the response in the data file.",type:"string"},location:{$ref:"#/definitions/ResponseBlockLocation",description:"Controls the response location. These might be the same for all responses, or differ across responses."},options:{description:"The options that are displayed in the dropdown.",items:{$ref:"#/definitions/Option"},type:"array"},paramCapture:{description:"Use to capture querystring parameters in answers such as participant_name. See the examples for how this is used, but prefer uiConfig.urlParticipantIdParam if you are capturing a participant ID.",type:"string"},placeholder:{description:"The placeholder text that is displayed in the input.",type:"string"},prompt:{description:"The prompt that is displayed to the participant. You can use markdown here to render images, links, etc.",type:"string"},required:{description:"Controls whether the response is required to be answered.",type:"boolean"},requiredLabel:{description:"You can provide a required label, which makes it so a participant has to answer with a response that matches label.",type:"string"},requiredValue:{description:"You can provide a required value, which makes it so a participant has to answer with that value."},type:{const:"dropdown",type:"string"}},required:["id","location","options","prompt","required","type"],type:"object"},IFrameResponse:{additionalProperties:!1,description:"The IFrameResponse interface is used to define the properties of an iframe response. IFrameResponses render as a list, that is connected to a WebsiteComponent. When data is sent from the WebsiteComponent, it is displayed in the list.",properties:{correctAnswer:{description:"The correct answer to the response. This is used in the data download and can be shown in the admin panel."},hidden:{description:"Controls whether the response is hidden.",type:"boolean"},id:{description:"The id of the response. This is used to identify the response in the data file.",type:"string"},location:{$ref:"#/definitions/ResponseBlockLocation",description:"Controls the response location. These might be the same for all responses, or differ across responses."},paramCapture:{description:"Use to capture querystring parameters in answers such as participant_name. See the examples for how this is used, but prefer uiConfig.urlParticipantIdParam if you are capturing a participant ID.",type:"string"},prompt:{description:"The prompt that is displayed to the participant. You can use markdown here to render images, links, etc.",type:"string"},required:{description:"Controls whether the response is required to be answered.",type:"boolean"},requiredLabel:{description:"You can provide a required label, which makes it so a participant has to answer with a response that matches label.",type:"string"},requiredValue:{description:"You can provide a required value, which makes it so a participant has to answer with that value."},type:{const:"iframe",type:"string"}},required:["id","location","prompt","required","type"],type:"object"},ImageComponent:{additionalProperties:!1,description:"The ImageComponent interface is used to define the properties of an image component. This component is used to render an image with optional styling.",properties:{correctAnswer:{description:"The correct answer to the component. This is used for training trials where the user is shown the correct answer after a guess.",items:{$ref:"#/definitions/Answer"},type:"array"},description:{description:"The description of the component. This is used to identify and provide additional information for the component in the admin panel.",type:"string"},instruction:{description:"The instruction of the component. This is used to identify and provide additional information for the component in the admin panel.",type:"string"},instructionLocation:{$ref:"#/definitions/ResponseBlockLocation",description:"The location of the instructions."},meta:{additionalProperties:{},description:"The meta data for the component. This is used to identify and provide additional information for the component in the admin panel.",type:"object"},nextButtonLocation:{$ref:"#/definitions/ResponseBlockLocation",description:"The location of the next button."},nextButtonText:{description:"The text that is displayed on the next button.",type:"string"},path:{description:"The path to the image. This should be a relative path from the public folder.",type:"string"},response:{description:"The responses to the component",items:{$ref:"#/definitions/Response"},type:"array"},style:{additionalProperties:{type:"string"},description:"The style of the image. This is an object with css properties as keys and css values as values.",type:"object"},type:{const:"image",type:"string"}},required:["path","response","type"],type:"object"},IndividualComponent:{anyOf:[{$ref:"#/definitions/MarkdownComponent"},{$ref:"#/definitions/ReactComponent"},{$ref:"#/definitions/ImageComponent"},{$ref:"#/definitions/WebsiteComponent"},{$ref:"#/definitions/QuestionnaireComponent"}]},InheritedComponent:{additionalProperties:!1,description:"An InheritedComponent is a component that inherits properties from a baseComponent. This is used to avoid repeating properties in components. This also means that components in the baseComponents object can be partially defined, while components in the components object can inherit from them and must be fully defined and include all properties (after potentially merging with a base component).",properties:{baseComponent:{type:"string"},correctAnswer:{description:"The correct answer to the component. This is used for training trials where the user is shown the correct answer after a guess.",items:{$ref:"#/definitions/Answer"},type:"array"},description:{description:"The description of the component. This is used to identify and provide additional information for the component in the admin panel.",type:"string"},instruction:{description:"The instruction of the component. This is used to identify and provide additional information for the component in the admin panel.",type:"string"},instructionLocation:{$ref:"#/definitions/ResponseBlockLocation",description:"The location of the instructions."},meta:{additionalProperties:{},description:"The meta data for the component. This is used to identify and provide additional information for the component in the admin panel.",type:"object"},nextButtonLocation:{$ref:"#/definitions/ResponseBlockLocation",description:"The location of the next button."},nextButtonText:{description:"The text that is displayed on the next button.",type:"string"},parameters:{anyOf:[{additionalProperties:{},description:"The parameters that are passed to the react component. These can be used within your react component to render different things.",type:"object"},{additionalProperties:{},description:"The parameters that are passed to the website (iframe). These can be used within your website to render different things.",type:"object"}],description:"The parameters that are passed to the react component. These can be used within your react component to render different things."},path:{description:"The path to the markdown file. This should be a relative path from the public folder.",type:"string"},response:{description:"The responses to the component",items:{$ref:"#/definitions/Response"},type:"array"},style:{additionalProperties:{type:"string"},description:"The style of the image. This is an object with css properties as keys and css values as values.",type:"object"},type:{enum:["markdown","react-component","image","website","questionnaire"],type:"string"}},required:["baseComponent"],type:"object"},LikertResponse:{additionalProperties:!1,description:"The LikertResponse interface is used to define the properties of a likert response. LikertResponses render as radio buttons with a user specified number of options, which can be controlled through the preset. For example, preset: 5 will render 5 radio buttons, and preset: 7 will render 7 radio buttons. LikertResponses can also have a description, and left and right labels. The left and right labels are used to label the left and right ends of the likert scale with values such as 'Strongly Disagree' and 'Strongly Agree'.",properties:{correctAnswer:{description:"The correct answer to the response. This is used in the data download and can be shown in the admin panel."},desc:{description:"The description of the likert scale.",type:"string"},hidden:{description:"Controls whether the response is hidden.",type:"boolean"},id:{description:"The id of the response. This is used to identify the response in the data file.",type:"string"},leftLabel:{description:"The left label of the likert scale. E.g Strongly Disagree",type:"string"},location:{$ref:"#/definitions/ResponseBlockLocation",description:"Controls the response location. These might be the same for all responses, or differ across responses."},paramCapture:{description:"Use to capture querystring parameters in answers such as participant_name. See the examples for how this is used, but prefer uiConfig.urlParticipantIdParam if you are capturing a participant ID.",type:"string"},preset:{description:"The number of options to render.",type:"number"},prompt:{description:"The prompt that is displayed to the participant. You can use markdown here to render images, links, etc.",type:"string"},required:{description:"Controls whether the response is required to be answered.",type:"boolean"},requiredLabel:{description:"You can provide a required label, which makes it so a participant has to answer with a response that matches label.",type:"string"},requiredValue:{description:"You can provide a required value, which makes it so a participant has to answer with that value."},rightLabel:{description:"The right label of the likert scale. E.g Strongly Agree",type:"string"},type:{const:"likert",type:"string"}},required:["id","location","preset","prompt","required","type"],type:"object"},LongTextResponse:{additionalProperties:!1,description:"The LongTextResponse interface is used to define the properties of a long text response. LongTextResponses render as a text area that accepts any text and can optionally have a placeholder.",properties:{correctAnswer:{description:"The correct answer to the response. This is used in the data download and can be shown in the admin panel."},hidden:{description:"Controls whether the response is hidden.",type:"boolean"},id:{description:"The id of the response. This is used to identify the response in the data file.",type:"string"},location:{$ref:"#/definitions/ResponseBlockLocation",description:"Controls the response location. These might be the same for all responses, or differ across responses."},paramCapture:{description:"Use to capture querystring parameters in answers such as participant_name. See the examples for how this is used, but prefer uiConfig.urlParticipantIdParam if you are capturing a participant ID.",type:"string"},placeholder:{description:"The placeholder text that is displayed in the input.",type:"string"},prompt:{description:"The prompt that is displayed to the participant. You can use markdown here to render images, links, etc.",type:"string"},required:{description:"Controls whether the response is required to be answered.",type:"boolean"},requiredLabel:{description:"You can provide a required label, which makes it so a participant has to answer with a response that matches label.",type:"string"},requiredValue:{description:"You can provide a required value, which makes it so a participant has to answer with that value."},type:{const:"longText",type:"string"}},required:["id","location","prompt","required","type"],type:"object"},MarkdownComponent:{additionalProperties:!1,description:"The MarkdownComponent interface is used to define the properties of a markdown component. The components can be used to render many different things, such as consent forms, instructions, and debriefs. Additionally, you can use the markdown component to render images, videos, and other media, with supporting text.",properties:{correctAnswer:{description:"The correct answer to the component. This is used for training trials where the user is shown the correct answer after a guess.",items:{$ref:"#/definitions/Answer"},type:"array"},description:{description:"The description of the component. This is used to identify and provide additional information for the component in the admin panel.",type:"string"},instruction:{description:"The instruction of the component. This is used to identify and provide additional information for the component in the admin panel.",type:"string"},instructionLocation:{$ref:"#/definitions/ResponseBlockLocation",description:"The location of the instructions."},meta:{additionalProperties:{},description:"The meta data for the component. This is used to identify and provide additional information for the component in the admin panel.",type:"object"},nextButtonLocation:{$ref:"#/definitions/ResponseBlockLocation",description:"The location of the next button."},nextButtonText:{description:"The text that is displayed on the next button.",type:"string"},path:{description:"The path to the markdown file. This should be a relative path from the public folder.",type:"string"},response:{description:"The responses to the component",items:{$ref:"#/definitions/Response"},type:"array"},type:{const:"markdown",type:"string"}},required:["path","response","type"],type:"object"},NumericalResponse:{additionalProperties:!1,description:"The NumericalResponse interface is used to define the properties of a numerical response. NumericalResponses render as a text input that only accepts numbers, and can optionally have a min and max value, or a placeholder.",properties:{correctAnswer:{description:"The correct answer to the response. This is used in the data download and can be shown in the admin panel."},hidden:{description:"Controls whether the response is hidden.",type:"boolean"},id:{description:"The id of the response. This is used to identify the response in the data file.",type:"string"},location:{$ref:"#/definitions/ResponseBlockLocation",description:"Controls the response location. These might be the same for all responses, or differ across responses."},max:{description:"The maximum value that is accepted in the input.",type:"number"},min:{description:"The minimum value that is accepted in the input.",type:"number"},paramCapture:{description:"Use to capture querystring parameters in answers such as participant_name. See the examples for how this is used, but prefer uiConfig.urlParticipantIdParam if you are capturing a participant ID.",type:"string"},placeholder:{description:"The placeholder text that is displayed in the input.",type:"string"},prompt:{description:"The prompt that is displayed to the participant. You can use markdown here to render images, links, etc.",type:"string"},required:{description:"Controls whether the response is required to be answered.",type:"boolean"},requiredLabel:{description:"You can provide a required label, which makes it so a participant has to answer with a response that matches label.",type:"string"},requiredValue:{description:"You can provide a required value, which makes it so a participant has to answer with that value."},type:{const:"numerical",type:"string"}},required:["id","location","prompt","required","type"],type:"object"},Option:{additionalProperties:!1,description:"The Option interface is used to define the options for a dropdown, slider, radio, or checkbox response. The label is the text that is displayed to the user, and the value is the value that is stored in the data file. The Option interface is used in the Response interface.",properties:{label:{description:"The label displayed to participants.",type:"string"},value:{description:"The value stored in the participant's data.",type:["string","number"]}},required:["label","value"],type:"object"},OrderObject:{additionalProperties:!1,description:"The OrderObject interface is used to define the properties of an order object. This is used to define the order of components in a study. It supports random assignment of trials using a pure random assignment and a latin square.",properties:{components:{description:"The components that are included in the order.",items:{anyOf:[{type:"string"},{$ref:"#/definitions/OrderObject"}]},type:"array"},numSamples:{description:"The number of samples to use for the random assignments. This means you can randomize across 3 components while only showing a participant 2 at a time.",type:"number"},order:{description:"The type of order. This can be random (pure random), latinSquare (random with some guarantees), or fixed.",enum:["random","latinSquare","fixed"],type:"string"}},required:["order","components"],type:"object"},QuestionnaireComponent:{additionalProperties:!1,description:"The QuestionnaireComponent interface is used to define the properties of a questionnaire component. A QuestionnaireComponent is used to render questions with different response types. The response types are also defined with these documentation. The main use case of this component type is to ask participants questions, without using markdown, websites, images, etc.",properties:{correctAnswer:{description:"The correct answer to the component. This is used for training trials where the user is shown the correct answer after a guess.",items:{$ref:"#/definitions/Answer"},type:"array"},description:{description:"The description of the component. This is used to identify and provide additional information for the component in the admin panel.",type:"string"},instruction:{description:"The instruction of the component. This is used to identify and provide additional information for the component in the admin panel.",type:"string"},instructionLocation:{$ref:"#/definitions/ResponseBlockLocation",description:"The location of the instructions."},meta:{additionalProperties:{},description:"The meta data for the component. This is used to identify and provide additional information for the component in the admin panel.",type:"object"},nextButtonLocation:{$ref:"#/definitions/ResponseBlockLocation",description:"The location of the next button."},nextButtonText:{description:"The text that is displayed on the next button.",type:"string"},response:{description:"The responses to the component",items:{$ref:"#/definitions/Response"},type:"array"},type:{const:"questionnaire",type:"string"}},required:["response","type"],type:"object"},RadioResponse:{additionalProperties:!1,description:"The RadioResponse interface is used to define the properties of a radio response. RadioResponses render as a radio input with user specified options, and optionally left and right labels.",properties:{correctAnswer:{description:"The correct answer to the response. This is used in the data download and can be shown in the admin panel."},hidden:{description:"Controls whether the response is hidden.",type:"boolean"},id:{description:"The id of the response. This is used to identify the response in the data file.",type:"string"},leftLabel:{type:"string"},location:{$ref:"#/definitions/ResponseBlockLocation",description:"Controls the response location. These might be the same for all responses, or differ across responses."},options:{items:{$ref:"#/definitions/Option"},type:"array"},paramCapture:{description:"Use to capture querystring parameters in answers such as participant_name. See the examples for how this is used, but prefer uiConfig.urlParticipantIdParam if you are capturing a participant ID.",type:"string"},prompt:{description:"The prompt that is displayed to the participant. You can use markdown here to render images, links, etc.",type:"string"},required:{description:"Controls whether the response is required to be answered.",type:"boolean"},requiredLabel:{description:"You can provide a required label, which makes it so a participant has to answer with a response that matches label.",type:"string"},requiredValue:{description:"You can provide a required value, which makes it so a participant has to answer with that value."},rightLabel:{type:"string"},type:{const:"radio",type:"string"}},required:["id","location","options","prompt","required","type"],type:"object"},ReactComponent:{additionalProperties:!1,description:"The ReactComponent interface is used to define the properties of a react component. This component is used to render react code with certain parameters. These parameters can be used within your react code to render different things.",properties:{correctAnswer:{description:"The correct answer to the component. This is used for training trials where the user is shown the correct answer after a guess.",items:{$ref:"#/definitions/Answer"},type:"array"},description:{description:"The description of the component. This is used to identify and provide additional information for the component in the admin panel.",type:"string"},instruction:{description:"The instruction of the component. This is used to identify and provide additional information for the component in the admin panel.",type:"string"},instructionLocation:{$ref:"#/definitions/ResponseBlockLocation",description:"The location of the instructions."},meta:{additionalProperties:{},description:"The meta data for the component. This is used to identify and provide additional information for the component in the admin panel.",type:"object"},nextButtonLocation:{$ref:"#/definitions/ResponseBlockLocation",description:"The location of the next button."},nextButtonText:{description:"The text that is displayed on the next button.",type:"string"},parameters:{additionalProperties:{},description:"The parameters that are passed to the react component. These can be used within your react component to render different things.",type:"object"},path:{description:"The path to the react component. This should be a relative path from the src/public folder.",type:"string"},response:{description:"The responses to the component",items:{$ref:"#/definitions/Response"},type:"array"},type:{const:"react-component",type:"string"}},required:["path","response","type"],type:"object"},Response:{anyOf:[{$ref:"#/definitions/NumericalResponse"},{$ref:"#/definitions/ShortTextResponse"},{$ref:"#/definitions/LongTextResponse"},{$ref:"#/definitions/LikertResponse"},{$ref:"#/definitions/DropdownResponse"},{$ref:"#/definitions/SliderResponse"},{$ref:"#/definitions/RadioResponse"},{$ref:"#/definitions/CheckboxResponse"},{$ref:"#/definitions/IFrameResponse"}]},ResponseBlockLocation:{enum:["sidebar","aboveStimulus","belowStimulus"],type:"string"},ShortTextResponse:{additionalProperties:!1,description:"The ShortTextResponse interface is used to define the properties of a short text response. ShortTextResponses render as a text input that accepts any text and can optionally have a placeholder.",properties:{correctAnswer:{description:"The correct answer to the response. This is used in the data download and can be shown in the admin panel."},hidden:{description:"Controls whether the response is hidden.",type:"boolean"},id:{description:"The id of the response. This is used to identify the response in the data file.",type:"string"},location:{$ref:"#/definitions/ResponseBlockLocation",description:"Controls the response location. These might be the same for all responses, or differ across responses."},paramCapture:{description:"Use to capture querystring parameters in answers such as participant_name. See the examples for how this is used, but prefer uiConfig.urlParticipantIdParam if you are capturing a participant ID.",type:"string"},placeholder:{description:"The placeholder text that is displayed in the input.",type:"string"},prompt:{description:"The prompt that is displayed to the participant. You can use markdown here to render images, links, etc.",type:"string"},required:{description:"Controls whether the response is required to be answered.",type:"boolean"},requiredLabel:{description:"You can provide a required label, which makes it so a participant has to answer with a response that matches label.",type:"string"},requiredValue:{description:"You can provide a required value, which makes it so a participant has to answer with that value."},type:{const:"shortText",type:"string"}},required:["id","location","prompt","required","type"],type:"object"},SliderResponse:{additionalProperties:!1,description:"The SliderResponse interface is used to define the properties of a slider response. SliderResponses render as a slider input with user specified steps. For example, you could have steps of 0, 50, and 100.",properties:{correctAnswer:{description:"The correct answer to the response. This is used in the data download and can be shown in the admin panel."},hidden:{description:"Controls whether the response is hidden.",type:"boolean"},id:{description:"The id of the response. This is used to identify the response in the data file.",type:"string"},leftLabel:{description:"The left label of the likert scale. E.g Strongly Disagree",type:"string"},location:{$ref:"#/definitions/ResponseBlockLocation",description:"Controls the response location. These might be the same for all responses, or differ across responses."},options:{description:"This define the steps in the slider and the extent of the slider.",items:{$ref:"#/definitions/Option"},type:"array"},paramCapture:{description:"Use to capture querystring parameters in answers such as participant_name. See the examples for how this is used, but prefer uiConfig.urlParticipantIdParam if you are capturing a participant ID.",type:"string"},prompt:{description:"The prompt that is displayed to the participant. You can use markdown here to render images, links, etc.",type:"string"},required:{description:"Controls whether the response is required to be answered.",type:"boolean"},requiredLabel:{description:"You can provide a required label, which makes it so a participant has to answer with a response that matches label.",type:"string"},requiredValue:{description:"You can provide a required value, which makes it so a participant has to answer with that value."},rightLabel:{description:"The right label of the likert scale. E.g Strongly Agree",type:"string"},type:{const:"slider",type:"string"}},required:["id","location","options","prompt","required","type"],type:"object"},StudyConfig:{additionalProperties:!1,description:"The StudyConfig interface is used to define the properties of a study configuration. These are the hjson files that live in the public folder. In our repo, one example of this would be public/cleveland/config-cleveland.json.",properties:{$schema:{description:"A required json schema property. This should point to the github link for the version of the schema you would like. See examples for more information",type:"string"},baseComponents:{additionalProperties:{anyOf:[{$ref:"#/definitions/IndividualComponent"},{additionalProperties:!1,properties:{correctAnswer:{description:"The correct answer to the component. This is used for training trials where the user is shown the correct answer after a guess.",items:{$ref:"#/definitions/Answer"},type:"array"},description:{description:"The description of the component. This is used to identify and provide additional information for the component in the admin panel.",type:"string"},instruction:{description:"The instruction of the component. This is used to identify and provide additional information for the component in the admin panel.",type:"string"},instructionLocation:{$ref:"#/definitions/ResponseBlockLocation",description:"The location of the instructions."},meta:{additionalProperties:{},description:"The meta data for the component. This is used to identify and provide additional information for the component in the admin panel.",type:"object"},nextButtonLocation:{$ref:"#/definitions/ResponseBlockLocation",description:"The location of the next button."},nextButtonText:{description:"The text that is displayed on the next button.",type:"string"},parameters:{anyOf:[{additionalProperties:{},description:"The parameters that are passed to the react component. These can be used within your react component to render different things.",type:"object"},{additionalProperties:{},description:"The parameters that are passed to the website (iframe). These can be used within your website to render different things.",type:"object"}],description:"The parameters that are passed to the react component. These can be used within your react component to render different things."},path:{description:"The path to the markdown file. This should be a relative path from the public folder.",type:"string"},response:{description:"The responses to the component",items:{$ref:"#/definitions/Response"},type:"array"},style:{additionalProperties:{type:"string"},description:"The style of the image. This is an object with css properties as keys and css values as values.",type:"object"},type:{enum:["markdown","react-component","image","website","questionnaire"],type:"string"}},type:"object"}]},description:"The components that are used in the study (baseComponents allow PartialComponents which allows for inheriting from them in components).",type:"object"},components:{additionalProperties:{anyOf:[{$ref:"#/definitions/IndividualComponent"},{$ref:"#/definitions/InheritedComponent"}]},description:"The components that are used in the study. They must be fully defined here with all properties. Some properties may be inherited from baseComponents.",type:"object"},recordStudyAudio:{type:"boolean"},sequence:{$ref:"#/definitions/OrderObject",description:"The order of the components in the study. This might include some randomness."},studyMetadata:{$ref:"#/definitions/StudyMetadata",description:"The metadata for the study. This is used to identify the study and version in the data file."},tasksToNotRecordAudio:{items:{type:"string"},type:"array"},uiConfig:{$ref:"#/definitions/UIConfig",description:"The UI configuration for the study. This is used to configure the UI of the app."}},required:["$schema","studyMetadata","uiConfig","components","sequence"],type:"object"},StudyMetadata:{additionalProperties:!1,description:"The StudyMetadata is used to describe certain properties of a study. Some of this data is displayed on the landing page when running the app, such as the title and description. This data is also included in the data file that is downloaded at the end of the study, to help identify the study and version.",properties:{authors:{description:"The authors of your study.",items:{type:"string"},type:"array"},date:{description:"The date of your study, may be useful for the researcher.",type:"string"},description:{description:"The description of your study, shown on the landing page.",type:"string"},organizations:{description:"The organizations that are associated with your study.",items:{type:"string"},type:"array"},title:{description:"The title of your study, shown on the landing page.",type:"string"},version:{description:"The version of your study, shown on the landing page and attached to participant data. This might be useful for seeing which version of the study a participant saw.",type:"string"}},required:["title","version","authors","date","description","organizations"],type:"object"},UIConfig:{additionalProperties:!1,description:"The UIConfig is used to configure the UI of the app. This includes the logo, contact email, and whether to show a progress bar. The UIConfig is also used to configure the sidebar, which can be used to display the task instructions and capture responses.",properties:{autoDownloadStudy:{description:"Controls whether the study data is automatically downloaded at the end of the study.",type:"boolean"},autoDownloadTime:{description:"The time in milliseconds to wait before automatically downloading the study data.",type:"number"},contactEmail:{description:"The email address that used during the study if a participant clicks contact.",type:"string"},helpTextPath:{description:"The path to the help text file. This is displayed when a participant clicks help. Markdown is supported.",type:"string"},logoPath:{description:"The path to the logo image. This is displayed on the landing page and the header.",type:"string"},numSequences:{description:"The number of sequences to generate for the study. This is used to generate the random sequences for the study. The default is 1000.",type:"number"},sidebar:{description:"Controls whether the left sidebar is rendered at all. Required to be true if your response's location is set to sidebar for any question.",type:"boolean"},studyEndMsg:{description:"The message to display when the study ends.",type:"string"},urlParticipantIdParam:{description:"If the participant ID is passed in the URL, this is the name of the querystring parameter that is used to capture the participant ID (e.g. PROLIFIC_ID). This will allow a user to continue a study on different devices and browsers.",type:"string"},windowEventDebounceTime:{description:"Debounce time in milliseconds for automatically tracked window events. Defaults to 100. E.g 100 here means 1000ms / 100ms = 10 times a second, 200 here means 1000ms / 200ms = 5 times per second",type:"number"},withProgressBar:{description:"Controls whether the progress bar is rendered in the study.",type:"boolean"}},required:["contactEmail","logoPath","withProgressBar","sidebar"],type:"object"},WebsiteComponent:{additionalProperties:!1,description:"The WebsiteComponent interface is used to define the properties of a website component. A WebsiteComponent is used to render an iframe with a website inside of it. This can be used to display an external website or an html file that is located in the public folder.",properties:{correctAnswer:{description:"The correct answer to the component. This is used for training trials where the user is shown the correct answer after a guess.",items:{$ref:"#/definitions/Answer"},type:"array"},description:{description:"The description of the component. This is used to identify and provide additional information for the component in the admin panel.",type:"string"},instruction:{description:"The instruction of the component. This is used to identify and provide additional information for the component in the admin panel.",type:"string"},instructionLocation:{$ref:"#/definitions/ResponseBlockLocation",description:"The location of the instructions."},meta:{additionalProperties:{},description:"The meta data for the component. This is used to identify and provide additional information for the component in the admin panel.",type:"object"},nextButtonLocation:{$ref:"#/definitions/ResponseBlockLocation",description:"The location of the next button."},nextButtonText:{description:"The text that is displayed on the next button.",type:"string"},parameters:{additionalProperties:{},description:"The parameters that are passed to the website (iframe). These can be used within your website to render different things.",type:"object"},path:{description:"The path to the website. This should be a relative path from the public folder or could be an external website.",type:"string"},response:{description:"The responses to the component",items:{$ref:"#/definitions/Response"},type:"array"},type:{const:"website",type:"string"}},required:["path","response","type"],type:"object"}},hLe={$ref:cLe,$schema:fLe,definitions:dLe},pLe="#/definitions/GlobalConfig",mLe="http://json-schema.org/draft-07/schema#",gLe={GlobalConfig:{additionalProperties:!1,description:"The GlobalConfig is used to generate the list of available studies in the UI. This list is displayed on the landing page when running the app.",properties:{$schema:{description:"A required json schema property. This should point to the github link for the version of the schema you would like. See examples for more information",type:"string"},configs:{additionalProperties:{additionalProperties:!1,description:"The key is used to identify the study config file. This key is used in the configList property.",properties:{path:{description:"The path to the study config file. This should be a relative path from the public folder.",type:"string"}},required:["path"],type:"object"},description:"A required property that specifies the options for the configList property.",type:"object"},configsList:{description:"A required property that is used to generate the list of available studies in the UI. This list is displayed on the landing page when running the app.",items:{type:"string"},type:"array"}},required:["$schema","configs","configsList"],type:"object"}},yLe={$ref:pLe,$schema:mLe,definitions:gLe},mne=new pne;mne.addSchema(yLe);const MU=mne.getSchema("#/definitions/GlobalConfig"),gne=new pne;gne.addSchema(hLe);const FU=gne.getSchema("#/definitions/StudyConfig");function vLe(e){const t=[];return[e.configsList.every(r=>e.configs[r]===void 0?(t.push({message:`Config ${r} is not defined in configs object, but is present in configsList`}),!1):!0),t]}function uC(e){return e.baseComponent!==void 0}function _Le(e){const t=i3.parse(e),n=MU(t),r=vLe(t);if(n&&r[0])return t;throw console.error("Global config parsing errors",[...MU.errors||[],...r[1]]),Error("There was an issue validating your file global.json")}function bLe(e){const t=[];return[Object.values(e.components).every(r=>{var i;return uC(r)?!!((i=e.baseComponents)!=null&&i[r.baseComponent]):!0}),t]}function yne(e,t){const n=i3.parse(e),r=FU(n),i=bLe(n);if(r&&i[0])return n;throw console.error(`${t} parsing errors`,[...FU.errors||[],...i[1]]),Error(`There was an issue validating your file ${t}`)}function Da(e){for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;r3?t.i-4:t.i:Array.isArray(e)?1:H3(e)?2:W3(e)?3:0}function rm(e,t){return Tg(e)===2?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function wLe(e,t){return Tg(e)===2?e.get(t):e[t]}function vne(e,t,n){var r=Tg(e);r===2?e.set(t,n):r===3?e.add(n):e[t]=n}function _ne(e,t){return e===t?e!==0||1/e==1/t:e!=e&&t!=t}function H3(e){return CLe&&e instanceof Map}function W3(e){return ALe&&e instanceof Set}function md(e){return e.o||e.t}function q3(e){if(Array.isArray(e))return Array.prototype.slice.call(e);var t=wne(e);delete t[fr];for(var n=im(t),r=0;r1&&(e.set=e.add=e.clear=e.delete=ELe),Object.freeze(e),t&&hh(e,function(n,r){return G3(r,!0)},!0)),e}function ELe(){Da(2)}function Y3(e){return e==null||typeof e!="object"||Object.isFrozen(e)}function Bu(e){var t=hN[e];return t||Da(18,e),t}function SLe(e,t){hN[e]||(hN[e]=t)}function cN(){return Tv}function iO(e,t){t&&(Bu("Patches"),e.u=[],e.s=[],e.v=t)}function PT(e){fN(e),e.p.forEach(TLe),e.p=null}function fN(e){e===Tv&&(Tv=e.l)}function BU(e){return Tv={p:[],l:Tv,h:e,m:!0,_:0}}function TLe(e){var t=e[fr];t.i===0||t.i===1?t.j():t.g=!0}function sO(e,t){t._=t.p.length;var n=t.p[0],r=e!==void 0&&e!==n;return t.h.O||Bu("ES5").S(t,e,r),r?(n[fr].P&&(PT(t),Da(4)),Yl(e)&&(e=OT(t,e),t.l||RT(t,e)),t.u&&Bu("Patches").M(n[fr].t,e,t.u,t.s)):e=OT(t,n,[]),PT(t),t.u&&t.v(t.u,t.s),e!==bne?e:void 0}function OT(e,t,n){if(Y3(t))return t;var r=t[fr];if(!r)return hh(t,function(a,u){return jU(e,r,t,a,u,n)},!0),t;if(r.A!==e)return t;if(!r.P)return RT(e,r.t,!0),r.t;if(!r.I){r.I=!0,r.A._--;var i=r.i===4||r.i===5?r.o=q3(r.k):r.o,s=i,o=!1;r.i===3&&(s=new Set(i),i.clear(),o=!0),hh(s,function(a,u){return jU(e,r,i,a,u,n,o)}),RT(e,i,!1),n&&e.u&&Bu("Patches").N(r,n,e.u,e.s)}return r.o}function jU(e,t,n,r,i,s,o){if(Af(i)){var a=OT(e,i,s&&t&&t.i!==3&&!rm(t.R,r)?s.concat(r):void 0);if(vne(n,r,a),!Af(a))return;e.m=!1}else o&&n.add(i);if(Yl(i)&&!Y3(i)){if(!e.h.D&&e._<1)return;OT(e,i),t&&t.A.l||RT(e,i)}}function RT(e,t,n){n===void 0&&(n=!1),!e.l&&e.h.D&&e.m&&G3(t,n)}function oO(e,t){var n=e[fr];return(n?md(n):e)[t]}function UU(e,t){if(t in e)for(var n=Object.getPrototypeOf(e);n;){var r=Object.getOwnPropertyDescriptor(n,t);if(r)return r;n=Object.getPrototypeOf(n)}}function jc(e){e.P||(e.P=!0,e.l&&jc(e.l))}function aO(e){e.o||(e.o=q3(e.t))}function dN(e,t,n){var r=H3(t)?Bu("MapSet").F(t,n):W3(t)?Bu("MapSet").T(t,n):e.O?function(i,s){var o=Array.isArray(i),a={i:o?1:0,A:s?s.A:cN(),P:!1,I:!1,R:{},l:s,t:i,k:null,o:null,j:null,C:!1},u=a,l=Iv;o&&(u=[a],l=Q0);var c=Proxy.revocable(u,l),f=c.revoke,d=c.proxy;return a.k=d,a.j=f,d}(t,n):Bu("ES5").J(t,n);return(n?n.A:cN()).p.push(r),r}function ILe(e){return Af(e)||Da(22,e),function t(n){if(!Yl(n))return n;var r,i=n[fr],s=Tg(n);if(i){if(!i.P&&(i.i<4||!Bu("ES5").K(i)))return i.t;i.I=!0,r=VU(n,s),i.I=!1}else r=VU(n,s);return hh(r,function(o,a){i&&wLe(i.t,o)===a||vne(r,o,t(a))}),s===3?new Set(r):r}(e)}function VU(e,t){switch(t){case 2:return new Map(e);case 3:return Array.from(e)}return q3(e)}function xLe(){function e(s,o){var a=i[s];return a?a.enumerable=o:i[s]=a={configurable:!0,enumerable:o,get:function(){var u=this[fr];return Iv.get(u,s)},set:function(u){var l=this[fr];Iv.set(l,s,u)}},a}function t(s){for(var o=s.length-1;o>=0;o--){var a=s[o][fr];if(!a.P)switch(a.i){case 5:r(a)&&jc(a);break;case 4:n(a)&&jc(a)}}}function n(s){for(var o=s.t,a=s.k,u=im(a),l=u.length-1;l>=0;l--){var c=u[l];if(c!==fr){var f=o[c];if(f===void 0&&!rm(o,c))return!0;var d=a[c],h=d&&d[fr];if(h?h.t!==f:!_ne(d,f))return!0}}var p=!!o[fr];return u.length!==im(o).length+(p?0:1)}function r(s){var o=s.k;if(o.length!==s.t.length)return!0;var a=Object.getOwnPropertyDescriptor(o,o.length-1);if(a&&!a.get)return!0;for(var u=0;u1?g-1:0),b=1;b1?c-1:0),d=1;d=0;i--){var s=r[i];if(s.path.length===0&&s.op==="replace"){n=s.value;break}}i>-1&&(r=r.slice(i+1));var o=Bu("Patches").$;return Af(n)?o(n,r):this.produce(n,function(a){return o(a,r)})},e}(),Po=new OLe,Ene=Po.produce;Po.produceWithPatches.bind(Po);Po.setAutoFreeze.bind(Po);Po.setUseProxies.bind(Po);Po.applyPatches.bind(Po);Po.createDraft.bind(Po);Po.finishDraft.bind(Po);function xv(e){"@babel/helpers - typeof";return xv=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},xv(e)}function RLe(e,t){if(xv(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(xv(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function NLe(e){var t=RLe(e,"string");return xv(t)=="symbol"?t:String(t)}function kLe(e,t,n){return t=NLe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function qU(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function GU(e){for(var t=1;t"u"&&(n=t,t=void 0),typeof n<"u"){if(typeof n!="function")throw new Error(Xi(1));return n(Sne)(e,t)}if(typeof e!="function")throw new Error(Xi(2));var i=e,s=t,o=[],a=o,u=!1;function l(){a===o&&(a=o.slice())}function c(){if(u)throw new Error(Xi(3));return s}function f(m){if(typeof m!="function")throw new Error(Xi(4));if(u)throw new Error(Xi(5));var y=!0;return l(),a.push(m),function(){if(y){if(u)throw new Error(Xi(6));y=!1,l();var v=a.indexOf(m);a.splice(v,1),o=null}}}function d(m){if(!DLe(m))throw new Error(Xi(7));if(typeof m.type>"u")throw new Error(Xi(8));if(u)throw new Error(Xi(9));try{u=!0,s=i(s,m)}finally{u=!1}for(var y=o=a,g=0;g"u")throw new Error(Xi(12));if(typeof n(void 0,{type:NT.PROBE_UNKNOWN_ACTION()})>"u")throw new Error(Xi(13))})}function LLe(e){for(var t=Object.keys(e),n={},r=0;r"u")throw l&&l.type,new Error(Xi(14));f[h]=y,c=c||y!==m}return c=c||s.length!==Object.keys(u).length,c?f:u}}function kT(){for(var e=arguments.length,t=new Array(e),n=0;n0&&s[s.length-1])&&(l[0]===6||l[0]===2)){n=0;continue}if(l[0]===3&&(!s||l[1]>s[0]&&l[1]0)for(var b=h.getState(),S=Array.from(n.values()),T=0,E=S;T({[c]:{}}))},s=Object.assign({},...n.map(c=>({[c]:{aboveStimulus:{valid:!1,values:{}},belowStimulus:{valid:!1,values:{}},sidebar:{valid:!1,values:{}}}}))),o=Object.assign({},...n.map(c=>({[c]:{aboveStimulus:!0,belowStimulus:!0,sidebar:!0,values:{}}}))),a={studyId:e,answers:r||i,isRecording:!1,sequence:n,config:t,showAdmin:!1,showHelpText:!1,alertModal:{show:!1,message:""},trialValidation:r?o:s,iframeAnswers:[]},u=One({name:"storeSlice",initialState:a,reducers:{setConfig(c,f){c.config=f.payload},setIsRecording(c,f){c.isRecording=f.payload},toggleShowAdmin:c=>{c.showAdmin=!c.showAdmin},toggleShowHelpText:c=>{c.showHelpText=!c.showHelpText},setAlertModal:(c,f)=>{c.alertModal=f.payload},setIframeAnswers:(c,f)=>{c.iframeAnswers=f.payload},updateResponseBlockValidation:(c,{payload:f})=>{!f.currentStep||f.currentStep.length===0||(c.trialValidation[f.currentStep]||(c.trialValidation[f.currentStep]={aboveStimulus:{valid:!1,values:{}},belowStimulus:{valid:!1,values:{}},sidebar:{valid:!1,values:{}},provenanceGraph:void 0}),c.trialValidation[f.currentStep][f.location]={valid:f.status,values:f.values},f.provenanceGraph&&(c.trialValidation[f.currentStep].provenanceGraph=f.provenanceGraph))},saveTrialAnswer(c,{payload:f}){const{currentStep:d,answer:h,startTime:p,endTime:m,provenanceGraph:y,windowEvents:g}=f;c.answers[d]={answer:h,startTime:p,endTime:m,provenanceGraph:y,windowEvents:g}}}});return{store:Ane({reducer:u.reducer,preloadedState:a}),actions:u.actions}}const jne=w.createContext(null);function Xu(){return w.useContext(jne).actions}const Ju=Ote,la=Vke;function SMe(e){return la(t=>{if(e===void 0||e.length===0)return!0;const n=Object.values(t.trialValidation[e]).every(r=>typeof r=="object"&&"valid"in r?r.valid:!0);return n?Object.values(n).every(r=>r):!1})}var $T={exports:{}};$T.exports;(function(e,t){var n=200,r="__lodash_hash_undefined__",i=800,s=16,o=9007199254740991,a="[object Arguments]",u="[object Array]",l="[object AsyncFunction]",c="[object Boolean]",f="[object Date]",d="[object Error]",h="[object Function]",p="[object GeneratorFunction]",m="[object Map]",y="[object Number]",g="[object Null]",v="[object Object]",b="[object Proxy]",S="[object RegExp]",T="[object Set]",E="[object String]",I="[object Undefined]",A="[object WeakMap]",R="[object ArrayBuffer]",F="[object DataView]",L="[object Float32Array]",B="[object Float64Array]",J="[object Int8Array]",V="[object Int16Array]",re="[object Int32Array]",oe="[object Uint8Array]",ae="[object Uint8ClampedArray]",ee="[object Uint16Array]",ue="[object Uint32Array]",P=/[\\^$.*+?()[\]{}|]/g,W=/^\[object .+?Constructor\]$/,Q=/^(?:0|[1-9]\d*)$/,x={};x[L]=x[B]=x[J]=x[V]=x[re]=x[oe]=x[ae]=x[ee]=x[ue]=!0,x[a]=x[u]=x[R]=x[c]=x[F]=x[f]=x[d]=x[h]=x[m]=x[y]=x[v]=x[S]=x[T]=x[E]=x[A]=!1;var O=typeof _o=="object"&&_o&&_o.Object===Object&&_o,$=typeof self=="object"&&self&&self.Object===Object&&self,q=O||$||Function("return this")(),ce=t&&!t.nodeType&&t,fe=ce&&!0&&e&&!e.nodeType&&e,de=fe&&fe.exports===ce,ve=de&&O.process,Ee=function(){try{var H=fe&&fe.require&&fe.require("util").types;return H||ve&&ve.binding&&ve.binding("util")}catch{}}(),ge=Ee&&Ee.isTypedArray;function nt(H,ie,ye){switch(ye.length){case 0:return H.call(ie);case 1:return H.call(ie,ye[0]);case 2:return H.call(ie,ye[0],ye[1]);case 3:return H.call(ie,ye[0],ye[1],ye[2])}return H.apply(ie,ye)}function Je(H,ie){for(var ye=-1,Ge=Array(H);++ye-1}function z(H,ie){var ye=this.__data__,Ge=wr(ye,H);return Ge<0?(++this.size,ye.push([H,ie])):ye[Ge][1]=ie,this}Yn.prototype.clear=fs,Yn.prototype.delete=Kr,Yn.prototype.get=jr,Yn.prototype.has=X,Yn.prototype.set=z;function Z(H){var ie=-1,ye=H==null?0:H.length;for(this.clear();++ie1?ye[dn-1]:void 0,ar=dn>2?ye[2]:void 0;for(Gn=H.length>3&&typeof Gn=="function"?(dn--,Gn):void 0,ar&&wn(ye[0],ye[1],ar)&&(Gn=dn<3?void 0:Gn,dn=1),ie=Object(ie);++Ge-1&&H%1==0&&H0){if(++ie>=i)return arguments[0]}else ie=0;return H.apply(void 0,arguments)}}function GA(H){if(H!=null){try{return Fe.call(H)}catch{}try{return H+""}catch{}}return""}function Yh(H,ie){return H===ie||H!==H&&ie!==ie}var Kh=Ei(function(){return arguments}())?Ei:function(H){return r0(H)&&st.call(H,"callee")&&!Ze.call(H,"callee")},YA=Array.isArray;function KA(H){return H!=null&&r5(H.length)&&!QA(H)}function jhe(H){return r0(H)&&KA(H)}var n5=_r||Whe;function QA(H){if(!ad(H))return!1;var ie=ds(H);return ie==h||ie==p||ie==l||ie==b}function r5(H){return typeof H=="number"&&H>-1&&H%1==0&&H<=o}function ad(H){var ie=typeof H;return H!=null&&(ie=="object"||ie=="function")}function r0(H){return H!=null&&typeof H=="object"}function Uhe(H){if(!r0(H)||ds(H)!=v)return!1;var ie=In(H);if(ie===null)return!0;var ye=st.call(ie,"constructor")&&ie.constructor;return typeof ye=="function"&&ye instanceof ye&&Fe.call(ye)==Kt}var i5=ge?yt(ge):Vi;function Vhe(H){return ne(H,s5(H))}function s5(H){return KA(H)?kn(H,!0):zi(H)}var zhe=be(function(H,ie,ye){We(H,ie,ye)});function Hhe(H){return function(){return H}}function o5(H){return H}function Whe(){return!1}e.exports=zhe})($T,$T.exports);var TMe=$T.exports;const J3=eu(TMe);function Une(){return Nh().pathname.split("/")[1]}function hl(){const{trialName:e}=uh();return e||""}function Ig(e){return structuredClone(e)}function Z3(){const{answers:e}=la(n=>n),t=hl();return e[t]}const Vne=w.createContext(null);function IMe(){const e=w.useContext(Vne);if(!e)throw new Error("useWindowEvents must be used within a WindowEventsProvider");return e}function xMe(){const e=hl(),{sequence:t,trialValidation:n}=la(g=>g),r=Z3(),i=Ju(),{saveTrialAnswer:s,setIframeAnswers:o}=Xu(),{storageEngine:a}=sa(),l=!SMe(e),c=r==null?void 0:r.answer,f=Kf(),d=w.useMemo(()=>{const g=t.indexOf(e);return t[g+1]||"end"},[e,t]),h=`/${Une()}/${d}`,p=w.useMemo(()=>Date.now(),[]),m=IMe(),y=w.useCallback(()=>{const g=Ig(n[e]),v=Object.values(g).reduce((E,I)=>Object.hasOwn(I,"values")?{...E,...I.values}:E,{}),{provenanceGraph:b}=g,S=Date.now(),T=m&&"current"in m&&m.current?m.current.splice(0,m.current.length):[];Object.keys(c||{}).length===0&&(i(s({currentStep:e,answer:v,startTime:p,endTime:S,provenanceGraph:b,windowEvents:T})),a&&a.saveAnswer(e,{answer:v,startTime:p,endTime:S,provenanceGraph:b,windowEvents:T}),i(o([]))),f(`${h}${window.location.search}`)},[o,a,i,c,n,f,p,e,s,h,m]);return{nextStep:d,isNextDisabled:l,goToNextStep:y}}function CMe({label:e="Next",disabled:t=!1,setCheckClicked:n=()=>null,onClick:r}){const{isNextDisabled:i,goToNextStep:s}=xMe(),o=w.useCallback(()=>{n(!1),r&&r(),s()},[s,r,n]);return C.jsx(Ws,{type:"submit",disabled:t||i,onClick:o,children:e})}function yN(e){return e===null||typeof e!="object"?{}:Object.keys(e).reduce((t,n)=>{const r=e[n];return r!=null&&r!==!1&&(t[n]=r),t},{})}var AMe=Object.defineProperty,rV=Object.getOwnPropertySymbols,PMe=Object.prototype.hasOwnProperty,OMe=Object.prototype.propertyIsEnumerable,iV=(e,t,n)=>t in e?AMe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,RMe=(e,t)=>{for(var n in t||(t={}))PMe.call(t,n)&&iV(e,n,t[n]);if(rV)for(var n of rV(t))OMe.call(t,n)&&iV(e,n,t[n]);return e};function zne(e,t){if(t===null||typeof t!="object")return{};const n=RMe({},t);return Object.keys(t).forEach(r=>{r.includes(`${String(e)}.`)&&delete n[r]}),n}const NMe="__MANTINE_FORM_INDEX__";function sV(e,t){return t?typeof t=="boolean"?t:Array.isArray(t)?t.includes(e.replace(/[.][0-9]/g,`.${NMe}`)):!1:!1}function oV(e,t,n){typeof n.value=="object"&&(n.value=kp(n.value)),!n.enumerable||n.get||n.set||!n.configurable||!n.writable||t==="__proto__"?Object.defineProperty(e,t,n):e[t]=n.value}function kp(e){if(typeof e!="object")return e;var t=0,n,r,i,s=Object.prototype.toString.call(e);if(s==="[object Object]"?i=Object.create(e.__proto__||null):s==="[object Array]"?i=Array(e.length):s==="[object Set]"?(i=new Set,e.forEach(function(o){i.add(kp(o))})):s==="[object Map]"?(i=new Map,e.forEach(function(o,a){i.set(kp(a),kp(o))})):s==="[object Date]"?i=new Date(+e):s==="[object RegExp]"?i=new RegExp(e.source,e.flags):s==="[object DataView]"?i=new e.constructor(kp(e.buffer)):s==="[object ArrayBuffer]"?i=e.slice(0):s.slice(-6)==="Array]"&&(i=new e.constructor(e)),i){for(r=Object.getOwnPropertySymbols(e);t0,errors:t}}function vN(e,t,n="",r={}){return typeof e!="object"||e===null?r:Object.keys(e).reduce((i,s)=>{const o=e[s],a=`${n===""?"":`${n}.`}${s}`,u=Tl(a,t);let l=!1;return typeof o=="function"&&(i[a]=o(u,t,a)),typeof o=="object"&&Array.isArray(u)&&(l=!0,u.forEach((c,f)=>vN(o,t,`${a}.${f}`,i))),typeof o=="object"&&typeof u=="object"&&u!==null&&(l||vN(o,t,a,i)),i},r)}function _N(e,t){return aV(typeof e=="function"?e(t):vN(e,t))}function Cb(e,t,n){if(typeof e!="string")return{hasError:!1,error:null};const r=_N(t,n),i=Object.keys(r.errors).find(s=>e.split(".").every((o,a)=>o===s.split(".")[a]));return{hasError:!!i,error:i?r.errors[i]:null}}function kMe(e,{from:t,to:n},r){const i=Tl(e,r);if(!Array.isArray(i))return r;const s=[...i],o=i[t];return s.splice(t,1),s.splice(n,0,o),cC(e,s,r)}var DMe=Object.defineProperty,uV=Object.getOwnPropertySymbols,$Me=Object.prototype.hasOwnProperty,LMe=Object.prototype.propertyIsEnumerable,lV=(e,t,n)=>t in e?DMe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,MMe=(e,t)=>{for(var n in t||(t={}))$Me.call(t,n)&&lV(e,n,t[n]);if(uV)for(var n of uV(t))LMe.call(t,n)&&lV(e,n,t[n]);return e};function FMe(e,{from:t,to:n},r){const i=`${e}.${t}`,s=`${e}.${n}`,o=MMe({},r);return Object.keys(r).every(a=>{let u,l;if(a.startsWith(i)&&(u=a,l=a.replace(i,s)),a.startsWith(s)&&(u=a.replace(s,i),l=a),u&&l){const c=o[u],f=o[l];return f===void 0?delete o[u]:o[u]=f,c===void 0?delete o[l]:o[l]=c,!1}return!0}),o}function BMe(e,t,n){const r=Tl(e,n);return Array.isArray(r)?cC(e,r.filter((i,s)=>s!==t),n):n}var jMe=Object.defineProperty,cV=Object.getOwnPropertySymbols,UMe=Object.prototype.hasOwnProperty,VMe=Object.prototype.propertyIsEnumerable,fV=(e,t,n)=>t in e?jMe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,zMe=(e,t)=>{for(var n in t||(t={}))UMe.call(t,n)&&fV(e,n,t[n]);if(cV)for(var n of cV(t))VMe.call(t,n)&&fV(e,n,t[n]);return e};function dV(e,t){const n=e.substring(t.length+1).split(".")[0];return parseInt(n,10)}function hV(e,t,n,r){if(t===void 0)return n;const i=`${String(e)}`;let s=n;r===-1&&(s=zne(`${i}.${t}`,s));const o=zMe({},s),a=new Set;return Object.entries(s).filter(([u])=>{if(!u.startsWith(`${i}.`))return!1;const l=dV(u,i);return Number.isNaN(l)?!1:l>=t}).forEach(([u,l])=>{const c=dV(u,i),f=u.replace(`${i}.${c}`,`${i}.${c+r}`);o[f]=l,a.add(f),a.has(u)||delete o[u]}),o}function HMe(e,t,n,r){const i=Tl(e,r);if(!Array.isArray(i))return r;const s=[...i];return s.splice(typeof n=="number"?n:s.length,0,t),cC(e,s,r)}function pV(e,t){const n=Object.keys(e);if(typeof t=="string"){const r=n.filter(i=>i.startsWith(`${t}.`));return e[t]||r.some(i=>e[i])||!1}return n.some(r=>e[r])}function WMe(e){return t=>{if(!t)e(t);else if(typeof t=="function")e(t);else if(typeof t=="object"&&"nativeEvent"in t){const{currentTarget:n}=t;n instanceof HTMLInputElement?n.type==="checkbox"?e(n.checked):e(n.value):(n instanceof HTMLTextAreaElement||n instanceof HTMLSelectElement)&&e(n.value)}else e(t)}}var qMe=Object.defineProperty,GMe=Object.defineProperties,YMe=Object.getOwnPropertyDescriptors,mV=Object.getOwnPropertySymbols,KMe=Object.prototype.hasOwnProperty,QMe=Object.prototype.propertyIsEnumerable,gV=(e,t,n)=>t in e?qMe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Tc=(e,t)=>{for(var n in t||(t={}))KMe.call(t,n)&&gV(e,n,t[n]);if(mV)for(var n of mV(t))QMe.call(t,n)&&gV(e,n,t[n]);return e},fO=(e,t)=>GMe(e,YMe(t));function XMe({initialValues:e={},initialErrors:t={},initialDirty:n={},initialTouched:r={},clearInputErrorOnChange:i=!0,validateInputOnChange:s=!1,validateInputOnBlur:o=!1,transformValues:a=l=>l,validate:u}={}){const[l,c]=w.useState(r),[f,d]=w.useState(n),[h,p]=w.useState(e),[m,y]=w.useState(yN(t)),g=w.useRef(e),v=$=>{g.current=$},b=w.useCallback(()=>c({}),[]),S=$=>{const q=$?Tc(Tc({},h),$):h;v(q),d({})},T=w.useCallback($=>y(q=>yN(typeof $=="function"?$(q):$)),[]),E=w.useCallback(()=>y({}),[]),I=w.useCallback(()=>{p(e),E(),v(e),d({}),b()},[]),A=w.useCallback(($,q)=>T(ce=>fO(Tc({},ce),{[$]:q})),[]),R=w.useCallback($=>T(q=>{if(typeof $!="string")return q;const ce=Tc({},q);return delete ce[$],ce}),[]),F=w.useCallback($=>d(q=>{if(typeof $!="string")return q;const ce=zne($,q);return delete ce[$],ce}),[]),L=w.useCallback(($,q)=>{const ce=sV($,s);F($),c(fe=>fO(Tc({},fe),{[$]:!0})),p(fe=>{const de=cC($,q,fe);if(ce){const ve=Cb($,u,de);ve.hasError?A($,ve.error):R($)}return de}),!ce&&i&&A($,null)},[]),B=w.useCallback($=>{p(q=>{const ce=typeof $=="function"?$(q):$;return Tc(Tc({},q),ce)}),i&&E()},[]),J=w.useCallback(($,q)=>{F($),p(ce=>kMe($,q,ce)),y(ce=>FMe($,q,ce))},[]),V=w.useCallback(($,q)=>{F($),p(ce=>BMe($,q,ce)),y(ce=>hV($,q,ce,-1))},[]),re=w.useCallback(($,q,ce)=>{F($),p(fe=>HMe($,q,ce,fe)),y(fe=>hV($,ce,fe,1))},[]),oe=w.useCallback(()=>{const $=_N(u,h);return y($.errors),$},[h,u]),ae=w.useCallback($=>{const q=Cb($,u,h);return q.hasError?A($,q.error):R($),q},[h,u]),ee=($,{type:q="input",withError:ce=!0,withFocus:fe=!0}={})=>{const ve={onChange:WMe(Ee=>L($,Ee))};return ce&&(ve.error=m[$]),q==="checkbox"?ve.checked=Tl($,h):ve.value=Tl($,h),fe&&(ve.onFocus=()=>c(Ee=>fO(Tc({},Ee),{[$]:!0})),ve.onBlur=()=>{if(sV($,o)){const Ee=Cb($,u,h);Ee.hasError?A($,Ee.error):R($)}}),ve},ue=($,q)=>ce=>{ce==null||ce.preventDefault();const fe=oe();fe.hasErrors?q==null||q(fe.errors,h,ce):$==null||$(a(h),ce)},P=$=>a($||h),W=w.useCallback($=>{$.preventDefault(),I()},[]),Q=$=>{if($){const ce=Tl($,f);if(typeof ce=="boolean")return ce;const fe=Tl($,h),de=Tl($,g.current);return!_U(fe,de)}return Object.keys(f).length>0?pV(f):!_U(h,g.current)},x=w.useCallback($=>pV(l,$),[l]),O=w.useCallback($=>$?!Cb($,u,h).hasError:!_N(u,h).hasErrors,[h,u]);return{values:h,errors:m,setValues:B,setErrors:T,setFieldValue:L,setFieldError:A,clearFieldError:R,clearErrors:E,reset:I,validate:oe,validateField:ae,reorderListItem:J,removeListItem:V,insertListItem:re,getInputProps:ee,onSubmit:ue,onReset:W,isDirty:Q,isTouched:x,setTouched:c,setDirty:d,resetTouched:b,resetDirty:S,isValid:O,getTransformedValues:P}}const JMe=new URLSearchParams(window.location.search),ZMe=(e,t)=>{let n={};return e.forEach(r=>{const i=t?t[r.id]:{};if(i)n={...n,[r.id]:i};else{const s=r.paramCapture?JMe.get(r.paramCapture):"";n={...n,[r.id]:r.type==="iframe"?[]:s}}}),{...n}},e4e=e=>{let t={};return e.forEach(n=>{n.required&&(t={...t,[n.id]:r=>{if(Array.isArray(r)){if(n.requiredValue!=null&&!Array.isArray(n.requiredValue))return"Incorrect required value";if(n.requiredValue!=null&&Array.isArray(n.requiredValue)){if(n.requiredValue.length!==r.length)return"Incorrect input";const i=[...n.requiredValue].sort(),s=[...r].sort();return i.every((o,a)=>o===s[a])?null:"Incorrect input"}return r.length===0?"Empty input":null}return n.required&&n.requiredValue!=null&&r!=null?r.toString()!==n.requiredValue.toString()?"Incorrect input":null:n.required?r==null||r===""?"Empty input":null:r===null?"Empty input":null}})}),t};function t4e(e,t,n){const[r,i]=w.useState(null),s=XMe({initialValues:ZMe(e,n),validate:e4e(e)});return w.useEffect(()=>{r!==t&&(i(t),s.reset())},[r,s,t]),s}function Lh(e,t,n){var o;const{requiredValue:r,requiredLabel:i}=e;let s="";return t.checked&&Array.isArray(r)?s=r&&[...r].sort().toString()!==[...t.checked].sort().toString()?`Please ${n?"select":"enter"} ${i||r.toString()} to continue.`:null:s=t.value&&r&&r.toString()!==t.value.toString()?`Please ${n?"select":"enter"} ${i||(n?(o=n.find(a=>a.value===r))==null?void 0:o.label:r.toString())} to continue.`:null,s}const yV=["http","https","mailto","tel"];function n4e(e){const t=(e||"").trim(),n=t.charAt(0);if(n==="#"||n==="/")return t;const r=t.indexOf(":");if(r===-1)return t;let i=-1;for(;++ii||(i=t.indexOf("#"),i!==-1&&r>i)?t:"javascript:void(0)"}/*! * Determine if an object is a Buffer * * @author Feross Aboukhadijeh * @license MIT - */var r4e=function(t){return t!=null&&t.constructor!=null&&typeof t.constructor.isBuffer=="function"&&t.constructor.isBuffer(t)};const t6=eu(r4e);function am(e){return!e||typeof e!="object"?"":"position"in e||"type"in e?_V(e.position):"start"in e||"end"in e?_V(e):"line"in e||"column"in e?wN(e):""}function wN(e){return bV(e&&e.line)+":"+bV(e&&e.column)}function _V(e){return wN(e&&e.start)+"-"+wN(e&&e.end)}function bV(e){return e&&typeof e=="number"?e:1}let pa=class extends Error{constructor(t,n,r){const i=[null,null];let s={start:{line:null,column:null},end:{line:null,column:null}};if(super(),typeof n=="string"&&(r=n,n=void 0),typeof r=="string"){const o=r.indexOf(":");o===-1?i[1]=r:(i[0]=r.slice(0,o),i[1]=r.slice(o+1))}n&&("type"in n||"position"in n?n.position&&(s=n.position):"start"in n||"end"in n?s=n:("line"in n||"column"in n)&&(s.start=n)),this.name=am(n)||"1:1",this.message=typeof t=="object"?t.message:t,this.stack="",typeof t=="object"&&t.stack&&(this.stack=t.stack),this.reason=this.message,this.fatal,this.line=s.start.line,this.column=s.start.column,this.position=s,this.source=i[0],this.ruleId=i[1],this.file,this.actual,this.expected,this.url,this.note}};pa.prototype.file="";pa.prototype.name="";pa.prototype.reason="";pa.prototype.message="";pa.prototype.stack="";pa.prototype.fatal=null;pa.prototype.column=null;pa.prototype.line=null;pa.prototype.source=null;pa.prototype.ruleId=null;pa.prototype.position=null;const lu={basename:i4e,dirname:s4e,extname:o4e,join:a4e,sep:"/"};function i4e(e,t){if(t!==void 0&&typeof t!="string")throw new TypeError('"ext" argument must be a string');K_(e);let n=0,r=-1,i=e.length,s;if(t===void 0||t.length===0||t.length>e.length){for(;i--;)if(e.charCodeAt(i)===47){if(s){n=i+1;break}}else r<0&&(s=!0,r=i+1);return r<0?"":e.slice(n,r)}if(t===e)return"";let o=-1,a=t.length-1;for(;i--;)if(e.charCodeAt(i)===47){if(s){n=i+1;break}}else o<0&&(s=!0,o=i+1),a>-1&&(e.charCodeAt(i)===t.charCodeAt(a--)?a<0&&(r=i):(a=-1,r=o));return n===r?r=o:r<0&&(r=e.length),e.slice(n,r)}function s4e(e){if(K_(e),e.length===0)return".";let t=-1,n=e.length,r;for(;--n;)if(e.charCodeAt(n)===47){if(r){t=n;break}}else r||(r=!0);return t<0?e.charCodeAt(0)===47?"/":".":t===1&&e.charCodeAt(0)===47?"//":e.slice(0,t)}function o4e(e){K_(e);let t=e.length,n=-1,r=0,i=-1,s=0,o;for(;t--;){const a=e.charCodeAt(t);if(a===47){if(o){r=t+1;break}continue}n<0&&(o=!0,n=t+1),a===46?i<0?i=t:s!==1&&(s=1):i>-1&&(s=-1)}return i<0||n<0||s===0||s===1&&i===n-1&&i===r+1?"":e.slice(i,n)}function a4e(...e){let t=-1,n;for(;++t0&&e.charCodeAt(e.length-1)===47&&(n+="/"),t?"/"+n:n}function l4e(e,t){let n="",r=0,i=-1,s=0,o=-1,a,u;for(;++o<=e.length;){if(o2){if(u=n.lastIndexOf("/"),u!==n.length-1){u<0?(n="",r=0):(n=n.slice(0,u),r=n.length-1-n.lastIndexOf("/")),i=o,s=0;continue}}else if(n.length>0){n="",r=0,i=o,s=0;continue}}t&&(n=n.length>0?n+"/..":"..",r=2)}else n.length>0?n+="/"+e.slice(i+1,o):n=e.slice(i+1,o),r=o-i-1;i=o,s=0}else a===46&&s>-1?s++:s=-1}return n}function K_(e){if(typeof e!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}const c4e={cwd:f4e};function f4e(){return"/"}function EN(e){return e!==null&&typeof e=="object"&&e.href&&e.origin}function d4e(e){if(typeof e=="string")e=new URL(e);else if(!EN(e)){const t=new TypeError('The "path" argument must be of type string or an instance of URL. Received `'+e+"`");throw t.code="ERR_INVALID_ARG_TYPE",t}if(e.protocol!=="file:"){const t=new TypeError("The URL must be of scheme file");throw t.code="ERR_INVALID_URL_SCHEME",t}return h4e(e)}function h4e(e){if(e.hostname!==""){const r=new TypeError('File URL host must be "localhost" or empty on darwin');throw r.code="ERR_INVALID_FILE_URL_HOST",r}const t=e.pathname;let n=-1;for(;++n"u"||$w.call(t,i)},CV=function(t,n){SV&&n.name==="__proto__"?SV(t,n.name,{enumerable:!0,configurable:!0,value:n.newValue,writable:!0}):t[n.name]=n.newValue},AV=function(t,n){if(n==="__proto__")if($w.call(t,n)){if(TV)return TV(t,n).value}else return;return t[n]},g4e=function e(){var t,n,r,i,s,o,a=arguments[0],u=1,l=arguments.length,c=!1;for(typeof a=="boolean"&&(c=a,a=arguments[1]||{},u=2),(a==null||typeof a!="object"&&typeof a!="function")&&(a={});uo.length;let u;a&&o.push(i);try{u=e.apply(this,o)}catch(l){const c=l;if(a&&n)throw c;return i(c)}a||(u&&u.then&&typeof u.then=="function"?u.then(s,i):u instanceof Error?i(u):s(u))}function i(o,...a){n||(n=!0,t(o,...a))}function s(o){i(null,o)}}class ma extends Error{constructor(t,n,r){const i=[null,null];let s={start:{line:null,column:null},end:{line:null,column:null}};if(super(),typeof n=="string"&&(r=n,n=void 0),typeof r=="string"){const o=r.indexOf(":");o===-1?i[1]=r:(i[0]=r.slice(0,o),i[1]=r.slice(o+1))}n&&("type"in n||"position"in n?n.position&&(s=n.position):"start"in n||"end"in n?s=n:("line"in n||"column"in n)&&(s.start=n)),this.name=am(n)||"1:1",this.message=typeof t=="object"?t.message:t,this.stack="",typeof t=="object"&&t.stack&&(this.stack=t.stack),this.reason=this.message,this.fatal,this.line=s.start.line,this.column=s.start.column,this.position=s,this.source=i[0],this.ruleId=i[1],this.file,this.actual,this.expected,this.url,this.note}}ma.prototype.file="";ma.prototype.name="";ma.prototype.reason="";ma.prototype.message="";ma.prototype.stack="";ma.prototype.fatal=null;ma.prototype.column=null;ma.prototype.line=null;ma.prototype.source=null;ma.prototype.ruleId=null;ma.prototype.position=null;const cu={basename:_4e,dirname:b4e,extname:w4e,join:E4e,sep:"/"};function _4e(e,t){if(t!==void 0&&typeof t!="string")throw new TypeError('"ext" argument must be a string');Q_(e);let n=0,r=-1,i=e.length,s;if(t===void 0||t.length===0||t.length>e.length){for(;i--;)if(e.charCodeAt(i)===47){if(s){n=i+1;break}}else r<0&&(s=!0,r=i+1);return r<0?"":e.slice(n,r)}if(t===e)return"";let o=-1,a=t.length-1;for(;i--;)if(e.charCodeAt(i)===47){if(s){n=i+1;break}}else o<0&&(s=!0,o=i+1),a>-1&&(e.charCodeAt(i)===t.charCodeAt(a--)?a<0&&(r=i):(a=-1,r=o));return n===r?r=o:r<0&&(r=e.length),e.slice(n,r)}function b4e(e){if(Q_(e),e.length===0)return".";let t=-1,n=e.length,r;for(;--n;)if(e.charCodeAt(n)===47){if(r){t=n;break}}else r||(r=!0);return t<0?e.charCodeAt(0)===47?"/":".":t===1&&e.charCodeAt(0)===47?"//":e.slice(0,t)}function w4e(e){Q_(e);let t=e.length,n=-1,r=0,i=-1,s=0,o;for(;t--;){const a=e.charCodeAt(t);if(a===47){if(o){r=t+1;break}continue}n<0&&(o=!0,n=t+1),a===46?i<0?i=t:s!==1&&(s=1):i>-1&&(s=-1)}return i<0||n<0||s===0||s===1&&i===n-1&&i===r+1?"":e.slice(i,n)}function E4e(...e){let t=-1,n;for(;++t0&&e.charCodeAt(e.length-1)===47&&(n+="/"),t?"/"+n:n}function T4e(e,t){let n="",r=0,i=-1,s=0,o=-1,a,u;for(;++o<=e.length;){if(o2){if(u=n.lastIndexOf("/"),u!==n.length-1){u<0?(n="",r=0):(n=n.slice(0,u),r=n.length-1-n.lastIndexOf("/")),i=o,s=0;continue}}else if(n.length>0){n="",r=0,i=o,s=0;continue}}t&&(n=n.length>0?n+"/..":"..",r=2)}else n.length>0?n+="/"+e.slice(i+1,o):n=e.slice(i+1,o),r=o-i-1;i=o,s=0}else a===46&&s>-1?s++:s=-1}return n}function Q_(e){if(typeof e!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}const I4e={cwd:x4e};function x4e(){return"/"}function TN(e){return e!==null&&typeof e=="object"&&e.href&&e.origin}function C4e(e){if(typeof e=="string")e=new URL(e);else if(!TN(e)){const t=new TypeError('The "path" argument must be of type string or an instance of URL. Received `'+e+"`");throw t.code="ERR_INVALID_ARG_TYPE",t}if(e.protocol!=="file:"){const t=new TypeError("The URL must be of scheme file");throw t.code="ERR_INVALID_URL_SCHEME",t}return A4e(e)}function A4e(e){if(e.hostname!==""){const r=new TypeError('File URL host must be "localhost" or empty on darwin');throw r.code="ERR_INVALID_FILE_URL_HOST",r}const t=e.pathname;let n=-1;for(;++n{if(E||!I||!A)T(E);else{const R=s.stringify(I,A);R==null||(D4e(R)?A.value=R:A.result=R),T(E,A)}});function T(E,I){E||!I?b(E):v?v(I):y(null,I)}}}function p(m){let y;s.freeze(),vO("processSync",s.Parser),_O("processSync",s.Compiler);const g=E0(m);return s.process(g,v),kV("processSync","process",y),g;function v(b){y=!0,EV(b)}}}function RV(e,t){return typeof e=="function"&&e.prototype&&(N4e(e.prototype)||t in e.prototype)}function N4e(e){let t;for(t in e)if(qne.call(e,t))return!0;return!1}function vO(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `Parser`")}function _O(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `Compiler`")}function bO(e,t){if(t)throw new Error("Cannot call `"+e+"` on a frozen processor.\nCreate a new processor first, by calling it: use `processor()` instead of `processor`.")}function NV(e){if(!SN(e)||typeof e.type!="string")throw new TypeError("Expected node, got `"+e+"`")}function kV(e,t,n){if(!n)throw new Error("`"+e+"` finished async. Use `"+t+"` instead")}function E0(e){return k4e(e)?e:new P4e(e)}function k4e(e){return!!(e&&typeof e=="object"&&"message"in e&&"messages"in e)}function D4e(e){return typeof e=="string"||t6(e)}const $4e={};function L4e(e,t){const n=t||$4e,r=typeof n.includeImageAlt=="boolean"?n.includeImageAlt:!0,i=typeof n.includeHtml=="boolean"?n.includeHtml:!0;return Yne(e,r,i)}function Yne(e,t,n){if(M4e(e)){if("value"in e)return e.type==="html"&&!n?"":e.value;if(t&&"alt"in e&&e.alt)return e.alt;if("children"in e)return DV(e.children,t,n)}return Array.isArray(e)?DV(e,t,n):""}function DV(e,t,n){const r=[];let i=-1;for(;++ii?0:i+t:t=t>i?i:t,n=n>0?n:0,r.length<1e4)o=Array.from(r),o.unshift(t,n),e.splice(...o);else for(n&&e.splice(t,n);s0?(Zu(e,e.length,0,t),e):t}const $V={}.hasOwnProperty;function F4e(e){const t={};let n=-1;for(;++no))return;const I=t.events.length;let A=I,R,F;for(;A--;)if(t.events[A][0]==="exit"&&t.events[A][1].type==="chunkFlow"){if(R){F=t.events[A][1].end;break}R=!0}for(g(r),E=I;Eb;){const T=n[S];t.containerState=T[1],T[0].exit.call(t,e)}n.length=b}function v(){i.write([null]),s=void 0,i=void 0,t.containerState._closeFlow=void 0}}function X4e(e,t,n){return Jn(e,e.attempt(this.parser.constructs.document,t,n),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}function MV(e){if(e===null||eo(e)||q4e(e))return 1;if(W4e(e))return 2}function n6(e,t,n){const r=[];let i=-1;for(;++i1&&e[n][1].end.offset-e[n][1].start.offset>1?2:1;const f=Object.assign({},e[r][1].end),d=Object.assign({},e[n][1].start);FV(f,-u),FV(d,u),o={type:u>1?"strongSequence":"emphasisSequence",start:f,end:Object.assign({},e[r][1].end)},a={type:u>1?"strongSequence":"emphasisSequence",start:Object.assign({},e[n][1].start),end:d},s={type:u>1?"strongText":"emphasisText",start:Object.assign({},e[r][1].end),end:Object.assign({},e[n][1].start)},i={type:u>1?"strong":"emphasis",start:Object.assign({},o.start),end:Object.assign({},a.end)},e[r][1].end=Object.assign({},o.start),e[n][1].start=Object.assign({},a.end),l=[],e[r][1].end.offset-e[r][1].start.offset&&(l=qo(l,[["enter",e[r][1],t],["exit",e[r][1],t]])),l=qo(l,[["enter",i,t],["enter",o,t],["exit",o,t],["enter",s,t]]),l=qo(l,n6(t.parser.constructs.insideSpan.null,e.slice(r+1,n),t)),l=qo(l,[["exit",s,t],["enter",a,t],["exit",a,t],["exit",i,t]]),e[n][1].end.offset-e[n][1].start.offset?(c=2,l=qo(l,[["enter",e[n][1],t],["exit",e[n][1],t]])):c=0,Zu(e,r-1,n-r+3,l),n=r+l.length-c-2;break}}for(n=-1;++n0&&On(E)?Jn(e,v,"linePrefix",s+1)(E):v(E)}function v(E){return E===null||Pt(E)?e.check(jV,m,S)(E):(e.enter("codeFlowValue"),b(E))}function b(E){return E===null||Pt(E)?(e.exit("codeFlowValue"),v(E)):(e.consume(E),b)}function S(E){return e.exit("codeFenced"),t(E)}function T(E,I,A){let R=0;return F;function F(re){return E.enter("lineEnding"),E.consume(re),E.exit("lineEnding"),L}function L(re){return E.enter("codeFencedFence"),On(re)?Jn(E,B,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(re):B(re)}function B(re){return re===a?(E.enter("codeFencedFenceSequence"),J(re)):A(re)}function J(re){return re===a?(R++,E.consume(re),J):R>=o?(E.exit("codeFencedFenceSequence"),On(re)?Jn(E,V,"whitespace")(re):V(re)):A(re)}function V(re){return re===null||Pt(re)?(E.exit("codeFencedFence"),I(re)):A(re)}}}function l5e(e,t,n){const r=this;return i;function i(o){return o===null?n(o):(e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),s)}function s(o){return r.parser.lazy[r.now().line]?n(o):t(o)}}const wO={name:"codeIndented",tokenize:f5e},c5e={tokenize:d5e,partial:!0};function f5e(e,t,n){const r=this;return i;function i(l){return e.enter("codeIndented"),Jn(e,s,"linePrefix",5)(l)}function s(l){const c=r.events[r.events.length-1];return c&&c[1].type==="linePrefix"&&c[2].sliceSerialize(c[1],!0).length>=4?o(l):n(l)}function o(l){return l===null?u(l):Pt(l)?e.attempt(c5e,o,u)(l):(e.enter("codeFlowValue"),a(l))}function a(l){return l===null||Pt(l)?(e.exit("codeFlowValue"),o(l)):(e.consume(l),a)}function u(l){return e.exit("codeIndented"),t(l)}}function d5e(e,t,n){const r=this;return i;function i(o){return r.parser.lazy[r.now().line]?n(o):Pt(o)?(e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),i):Jn(e,s,"linePrefix",5)(o)}function s(o){const a=r.events[r.events.length-1];return a&&a[1].type==="linePrefix"&&a[2].sliceSerialize(a[1],!0).length>=4?t(o):Pt(o)?i(o):n(o)}}const h5e={name:"codeText",tokenize:g5e,resolve:p5e,previous:m5e};function p5e(e){let t=e.length-4,n=3,r,i;if((e[n][1].type==="lineEnding"||e[n][1].type==="space")&&(e[t][1].type==="lineEnding"||e[t][1].type==="space")){for(r=n;++r=4?t(o):e.interrupt(r.parser.constructs.flow,n,t)(o)}}function Zne(e,t,n,r,i,s,o,a,u){const l=u||Number.POSITIVE_INFINITY;let c=0;return f;function f(g){return g===60?(e.enter(r),e.enter(i),e.enter(s),e.consume(g),e.exit(s),d):g===null||g===32||g===41||IN(g)?n(g):(e.enter(r),e.enter(o),e.enter(a),e.enter("chunkString",{contentType:"string"}),m(g))}function d(g){return g===62?(e.enter(s),e.consume(g),e.exit(s),e.exit(i),e.exit(r),t):(e.enter(a),e.enter("chunkString",{contentType:"string"}),h(g))}function h(g){return g===62?(e.exit("chunkString"),e.exit(a),d(g)):g===null||g===60||Pt(g)?n(g):(e.consume(g),g===92?p:h)}function p(g){return g===60||g===62||g===92?(e.consume(g),h):h(g)}function m(g){return!c&&(g===null||g===41||eo(g))?(e.exit("chunkString"),e.exit(a),e.exit(o),e.exit(r),t(g)):c999||h===null||h===91||h===93&&!u||h===94&&!a&&"_hiddenFootnoteSupport"in o.parser.constructs?n(h):h===93?(e.exit(s),e.enter(i),e.consume(h),e.exit(i),e.exit(r),t):Pt(h)?(e.enter("lineEnding"),e.consume(h),e.exit("lineEnding"),c):(e.enter("chunkString",{contentType:"string"}),f(h))}function f(h){return h===null||h===91||h===93||Pt(h)||a++>999?(e.exit("chunkString"),c(h)):(e.consume(h),u||(u=!On(h)),h===92?d:f)}function d(h){return h===91||h===92||h===93?(e.consume(h),a++,f):f(h)}}function tre(e,t,n,r,i,s){let o;return a;function a(d){return d===34||d===39||d===40?(e.enter(r),e.enter(i),e.consume(d),e.exit(i),o=d===40?41:d,u):n(d)}function u(d){return d===o?(e.enter(i),e.consume(d),e.exit(i),e.exit(r),t):(e.enter(s),l(d))}function l(d){return d===o?(e.exit(s),u(o)):d===null?n(d):Pt(d)?(e.enter("lineEnding"),e.consume(d),e.exit("lineEnding"),Jn(e,l,"linePrefix")):(e.enter("chunkString",{contentType:"string"}),c(d))}function c(d){return d===o||d===null||Pt(d)?(e.exit("chunkString"),l(d)):(e.consume(d),d===92?f:c)}function f(d){return d===o||d===92?(e.consume(d),c):c(d)}}function Ay(e,t){let n;return r;function r(i){return Pt(i)?(e.enter("lineEnding"),e.consume(i),e.exit("lineEnding"),n=!0,r):On(i)?Jn(e,r,n?"linePrefix":"lineSuffix")(i):t(i)}}function um(e){return e.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}const S5e={name:"definition",tokenize:I5e},T5e={tokenize:x5e,partial:!0};function I5e(e,t,n){const r=this;let i;return s;function s(h){return e.enter("definition"),o(h)}function o(h){return ere.call(r,e,a,n,"definitionLabel","definitionLabelMarker","definitionLabelString")(h)}function a(h){return i=um(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)),h===58?(e.enter("definitionMarker"),e.consume(h),e.exit("definitionMarker"),u):n(h)}function u(h){return eo(h)?Ay(e,l)(h):l(h)}function l(h){return Zne(e,c,n,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(h)}function c(h){return e.attempt(T5e,f,f)(h)}function f(h){return On(h)?Jn(e,d,"whitespace")(h):d(h)}function d(h){return h===null||Pt(h)?(e.exit("definition"),r.parser.defined.push(i),t(h)):n(h)}}function x5e(e,t,n){return r;function r(a){return eo(a)?Ay(e,i)(a):n(a)}function i(a){return tre(e,s,n,"definitionTitle","definitionTitleMarker","definitionTitleString")(a)}function s(a){return On(a)?Jn(e,o,"whitespace")(a):o(a)}function o(a){return a===null||Pt(a)?t(a):n(a)}}const C5e={name:"hardBreakEscape",tokenize:A5e};function A5e(e,t,n){return r;function r(s){return e.enter("hardBreakEscape"),e.consume(s),i}function i(s){return Pt(s)?(e.exit("hardBreakEscape"),t(s)):n(s)}}const P5e={name:"headingAtx",tokenize:R5e,resolve:O5e};function O5e(e,t){let n=e.length-2,r=3,i,s;return e[r][1].type==="whitespace"&&(r+=2),n-2>r&&e[n][1].type==="whitespace"&&(n-=2),e[n][1].type==="atxHeadingSequence"&&(r===n-1||n-4>r&&e[n-2][1].type==="whitespace")&&(n-=r+1===n?2:4),n>r&&(i={type:"atxHeadingText",start:e[r][1].start,end:e[n][1].end},s={type:"chunkText",start:e[r][1].start,end:e[n][1].end,contentType:"text"},Zu(e,r,n-r+1,[["enter",i,t],["enter",s,t],["exit",s,t],["exit",i,t]])),e}function R5e(e,t,n){let r=0;return i;function i(c){return e.enter("atxHeading"),s(c)}function s(c){return e.enter("atxHeadingSequence"),o(c)}function o(c){return c===35&&r++<6?(e.consume(c),o):c===null||eo(c)?(e.exit("atxHeadingSequence"),a(c)):n(c)}function a(c){return c===35?(e.enter("atxHeadingSequence"),u(c)):c===null||Pt(c)?(e.exit("atxHeading"),t(c)):On(c)?Jn(e,a,"whitespace")(c):(e.enter("atxHeadingText"),l(c))}function u(c){return c===35?(e.consume(c),u):(e.exit("atxHeadingSequence"),a(c))}function l(c){return c===null||c===35||eo(c)?(e.exit("atxHeadingText"),a(c)):(e.consume(c),l)}}const N5e=["address","article","aside","base","basefont","blockquote","body","caption","center","col","colgroup","dd","details","dialog","dir","div","dl","dt","fieldset","figcaption","figure","footer","form","frame","frameset","h1","h2","h3","h4","h5","h6","head","header","hr","html","iframe","legend","li","link","main","menu","menuitem","nav","noframes","ol","optgroup","option","p","param","search","section","summary","table","tbody","td","tfoot","th","thead","title","tr","track","ul"],VV=["pre","script","style","textarea"],k5e={name:"htmlFlow",tokenize:M5e,resolveTo:L5e,concrete:!0},D5e={tokenize:B5e,partial:!0},$5e={tokenize:F5e,partial:!0};function L5e(e){let t=e.length;for(;t--&&!(e[t][0]==="enter"&&e[t][1].type==="htmlFlow"););return t>1&&e[t-2][1].type==="linePrefix"&&(e[t][1].start=e[t-2][1].start,e[t+1][1].start=e[t-2][1].start,e.splice(t-2,2)),e}function M5e(e,t,n){const r=this;let i,s,o,a,u;return l;function l(x){return c(x)}function c(x){return e.enter("htmlFlow"),e.enter("htmlFlowData"),e.consume(x),f}function f(x){return x===33?(e.consume(x),d):x===47?(e.consume(x),s=!0,m):x===63?(e.consume(x),i=3,r.interrupt?t:P):bu(x)?(e.consume(x),o=String.fromCharCode(x),y):n(x)}function d(x){return x===45?(e.consume(x),i=2,h):x===91?(e.consume(x),i=5,a=0,p):bu(x)?(e.consume(x),i=4,r.interrupt?t:P):n(x)}function h(x){return x===45?(e.consume(x),r.interrupt?t:P):n(x)}function p(x){const O="CDATA[";return x===O.charCodeAt(a++)?(e.consume(x),a===O.length?r.interrupt?t:B:p):n(x)}function m(x){return bu(x)?(e.consume(x),o=String.fromCharCode(x),y):n(x)}function y(x){if(x===null||x===47||x===62||eo(x)){const O=x===47,$=o.toLowerCase();return!O&&!s&&VV.includes($)?(i=1,r.interrupt?t(x):B(x)):N5e.includes(o.toLowerCase())?(i=6,O?(e.consume(x),g):r.interrupt?t(x):B(x)):(i=7,r.interrupt&&!r.parser.lazy[r.now().line]?n(x):s?v(x):b(x))}return x===45||Eo(x)?(e.consume(x),o+=String.fromCharCode(x),y):n(x)}function g(x){return x===62?(e.consume(x),r.interrupt?t:B):n(x)}function v(x){return On(x)?(e.consume(x),v):F(x)}function b(x){return x===47?(e.consume(x),F):x===58||x===95||bu(x)?(e.consume(x),S):On(x)?(e.consume(x),b):F(x)}function S(x){return x===45||x===46||x===58||x===95||Eo(x)?(e.consume(x),S):T(x)}function T(x){return x===61?(e.consume(x),E):On(x)?(e.consume(x),T):b(x)}function E(x){return x===null||x===60||x===61||x===62||x===96?n(x):x===34||x===39?(e.consume(x),u=x,I):On(x)?(e.consume(x),E):A(x)}function I(x){return x===u?(e.consume(x),u=null,R):x===null||Pt(x)?n(x):(e.consume(x),I)}function A(x){return x===null||x===34||x===39||x===47||x===60||x===61||x===62||x===96||eo(x)?T(x):(e.consume(x),A)}function R(x){return x===47||x===62||On(x)?b(x):n(x)}function F(x){return x===62?(e.consume(x),L):n(x)}function L(x){return x===null||Pt(x)?B(x):On(x)?(e.consume(x),L):n(x)}function B(x){return x===45&&i===2?(e.consume(x),oe):x===60&&i===1?(e.consume(x),ae):x===62&&i===4?(e.consume(x),W):x===63&&i===3?(e.consume(x),P):x===93&&i===5?(e.consume(x),ue):Pt(x)&&(i===6||i===7)?(e.exit("htmlFlowData"),e.check(D5e,Q,J)(x)):x===null||Pt(x)?(e.exit("htmlFlowData"),J(x)):(e.consume(x),B)}function J(x){return e.check($5e,V,Q)(x)}function V(x){return e.enter("lineEnding"),e.consume(x),e.exit("lineEnding"),re}function re(x){return x===null||Pt(x)?J(x):(e.enter("htmlFlowData"),B(x))}function oe(x){return x===45?(e.consume(x),P):B(x)}function ae(x){return x===47?(e.consume(x),o="",ee):B(x)}function ee(x){if(x===62){const O=o.toLowerCase();return VV.includes(O)?(e.consume(x),W):B(x)}return bu(x)&&o.length<8?(e.consume(x),o+=String.fromCharCode(x),ee):B(x)}function ue(x){return x===93?(e.consume(x),P):B(x)}function P(x){return x===62?(e.consume(x),W):x===45&&i===2?(e.consume(x),P):B(x)}function W(x){return x===null||Pt(x)?(e.exit("htmlFlowData"),Q(x)):(e.consume(x),W)}function Q(x){return e.exit("htmlFlow"),t(x)}}function F5e(e,t,n){const r=this;return i;function i(o){return Pt(o)?(e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),s):n(o)}function s(o){return r.parser.lazy[r.now().line]?n(o):t(o)}}function B5e(e,t,n){return r;function r(i){return e.enter("lineEnding"),e.consume(i),e.exit("lineEnding"),e.attempt(fC,t,n)}}const j5e={name:"htmlText",tokenize:U5e};function U5e(e,t,n){const r=this;let i,s,o;return a;function a(P){return e.enter("htmlText"),e.enter("htmlTextData"),e.consume(P),u}function u(P){return P===33?(e.consume(P),l):P===47?(e.consume(P),T):P===63?(e.consume(P),b):bu(P)?(e.consume(P),A):n(P)}function l(P){return P===45?(e.consume(P),c):P===91?(e.consume(P),s=0,p):bu(P)?(e.consume(P),v):n(P)}function c(P){return P===45?(e.consume(P),h):n(P)}function f(P){return P===null?n(P):P===45?(e.consume(P),d):Pt(P)?(o=f,ae(P)):(e.consume(P),f)}function d(P){return P===45?(e.consume(P),h):f(P)}function h(P){return P===62?oe(P):P===45?d(P):f(P)}function p(P){const W="CDATA[";return P===W.charCodeAt(s++)?(e.consume(P),s===W.length?m:p):n(P)}function m(P){return P===null?n(P):P===93?(e.consume(P),y):Pt(P)?(o=m,ae(P)):(e.consume(P),m)}function y(P){return P===93?(e.consume(P),g):m(P)}function g(P){return P===62?oe(P):P===93?(e.consume(P),g):m(P)}function v(P){return P===null||P===62?oe(P):Pt(P)?(o=v,ae(P)):(e.consume(P),v)}function b(P){return P===null?n(P):P===63?(e.consume(P),S):Pt(P)?(o=b,ae(P)):(e.consume(P),b)}function S(P){return P===62?oe(P):b(P)}function T(P){return bu(P)?(e.consume(P),E):n(P)}function E(P){return P===45||Eo(P)?(e.consume(P),E):I(P)}function I(P){return Pt(P)?(o=I,ae(P)):On(P)?(e.consume(P),I):oe(P)}function A(P){return P===45||Eo(P)?(e.consume(P),A):P===47||P===62||eo(P)?R(P):n(P)}function R(P){return P===47?(e.consume(P),oe):P===58||P===95||bu(P)?(e.consume(P),F):Pt(P)?(o=R,ae(P)):On(P)?(e.consume(P),R):oe(P)}function F(P){return P===45||P===46||P===58||P===95||Eo(P)?(e.consume(P),F):L(P)}function L(P){return P===61?(e.consume(P),B):Pt(P)?(o=L,ae(P)):On(P)?(e.consume(P),L):R(P)}function B(P){return P===null||P===60||P===61||P===62||P===96?n(P):P===34||P===39?(e.consume(P),i=P,J):Pt(P)?(o=B,ae(P)):On(P)?(e.consume(P),B):(e.consume(P),V)}function J(P){return P===i?(e.consume(P),i=void 0,re):P===null?n(P):Pt(P)?(o=J,ae(P)):(e.consume(P),J)}function V(P){return P===null||P===34||P===39||P===60||P===61||P===96?n(P):P===47||P===62||eo(P)?R(P):(e.consume(P),V)}function re(P){return P===47||P===62||eo(P)?R(P):n(P)}function oe(P){return P===62?(e.consume(P),e.exit("htmlTextData"),e.exit("htmlText"),t):n(P)}function ae(P){return e.exit("htmlTextData"),e.enter("lineEnding"),e.consume(P),e.exit("lineEnding"),ee}function ee(P){return On(P)?Jn(e,ue,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(P):ue(P)}function ue(P){return e.enter("htmlTextData"),o(P)}}const i6={name:"labelEnd",tokenize:G5e,resolveTo:q5e,resolveAll:W5e},V5e={tokenize:Y5e},z5e={tokenize:K5e},H5e={tokenize:Q5e};function W5e(e){let t=-1;for(;++t=3&&(l===null||Pt(l))?(e.exit("thematicBreak"),t(l)):n(l)}function u(l){return l===i?(e.consume(l),r++,u):(e.exit("thematicBreakSequence"),On(l)?Jn(e,a,"whitespace")(l):a(l))}}const Rs={name:"list",tokenize:sFe,continuation:{tokenize:oFe},exit:uFe},rFe={tokenize:lFe,partial:!0},iFe={tokenize:aFe,partial:!0};function sFe(e,t,n){const r=this,i=r.events[r.events.length-1];let s=i&&i[1].type==="linePrefix"?i[2].sliceSerialize(i[1],!0).length:0,o=0;return a;function a(h){const p=r.containerState.type||(h===42||h===43||h===45?"listUnordered":"listOrdered");if(p==="listUnordered"?!r.containerState.marker||h===r.containerState.marker:xN(h)){if(r.containerState.type||(r.containerState.type=p,e.enter(p,{_container:!0})),p==="listUnordered")return e.enter("listItemPrefix"),h===42||h===45?e.check(Lw,n,l)(h):l(h);if(!r.interrupt||h===49)return e.enter("listItemPrefix"),e.enter("listItemValue"),u(h)}return n(h)}function u(h){return xN(h)&&++o<10?(e.consume(h),u):(!r.interrupt||o<2)&&(r.containerState.marker?h===r.containerState.marker:h===41||h===46)?(e.exit("listItemValue"),l(h)):n(h)}function l(h){return e.enter("listItemMarker"),e.consume(h),e.exit("listItemMarker"),r.containerState.marker=r.containerState.marker||h,e.check(fC,r.interrupt?n:c,e.attempt(rFe,d,f))}function c(h){return r.containerState.initialBlankLine=!0,s++,d(h)}function f(h){return On(h)?(e.enter("listItemPrefixWhitespace"),e.consume(h),e.exit("listItemPrefixWhitespace"),d):n(h)}function d(h){return r.containerState.size=s+r.sliceSerialize(e.exit("listItemPrefix"),!0).length,t(h)}}function oFe(e,t,n){const r=this;return r.containerState._closeFlow=void 0,e.check(fC,i,s);function i(a){return r.containerState.furtherBlankLines=r.containerState.furtherBlankLines||r.containerState.initialBlankLine,Jn(e,t,"listItemIndent",r.containerState.size+1)(a)}function s(a){return r.containerState.furtherBlankLines||!On(a)?(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,o(a)):(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,e.attempt(iFe,t,o)(a))}function o(a){return r.containerState._closeFlow=!0,r.interrupt=void 0,Jn(e,e.attempt(Rs,t,n),"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(a)}}function aFe(e,t,n){const r=this;return Jn(e,i,"listItemIndent",r.containerState.size+1);function i(s){const o=r.events[r.events.length-1];return o&&o[1].type==="listItemIndent"&&o[2].sliceSerialize(o[1],!0).length===r.containerState.size?t(s):n(s)}}function uFe(e){e.exit(this.containerState.type)}function lFe(e,t,n){const r=this;return Jn(e,i,"listItemPrefixWhitespace",r.parser.constructs.disable.null.includes("codeIndented")?void 0:5);function i(s){const o=r.events[r.events.length-1];return!On(s)&&o&&o[1].type==="listItemPrefixWhitespace"?t(s):n(s)}}const zV={name:"setextUnderline",tokenize:fFe,resolveTo:cFe};function cFe(e,t){let n=e.length,r,i,s;for(;n--;)if(e[n][0]==="enter"){if(e[n][1].type==="content"){r=n;break}e[n][1].type==="paragraph"&&(i=n)}else e[n][1].type==="content"&&e.splice(n,1),!s&&e[n][1].type==="definition"&&(s=n);const o={type:"setextHeading",start:Object.assign({},e[i][1].start),end:Object.assign({},e[e.length-1][1].end)};return e[i][1].type="setextHeadingText",s?(e.splice(i,0,["enter",o,t]),e.splice(s+1,0,["exit",e[r][1],t]),e[r][1].end=Object.assign({},e[s][1].end)):e[r][1]=o,e.push(["exit",o,t]),e}function fFe(e,t,n){const r=this;let i;return s;function s(l){let c=r.events.length,f;for(;c--;)if(r.events[c][1].type!=="lineEnding"&&r.events[c][1].type!=="linePrefix"&&r.events[c][1].type!=="content"){f=r.events[c][1].type==="paragraph";break}return!r.parser.lazy[r.now().line]&&(r.interrupt||f)?(e.enter("setextHeadingLine"),i=l,o(l)):n(l)}function o(l){return e.enter("setextHeadingLineSequence"),a(l)}function a(l){return l===i?(e.consume(l),a):(e.exit("setextHeadingLineSequence"),On(l)?Jn(e,u,"lineSuffix")(l):u(l))}function u(l){return l===null||Pt(l)?(e.exit("setextHeadingLine"),t(l)):n(l)}}const dFe={tokenize:hFe};function hFe(e){const t=this,n=e.attempt(fC,r,e.attempt(this.parser.constructs.flowInitial,i,Jn(e,e.attempt(this.parser.constructs.flow,i,e.attempt(v5e,i)),"linePrefix")));return n;function r(s){if(s===null){e.consume(s);return}return e.enter("lineEndingBlank"),e.consume(s),e.exit("lineEndingBlank"),t.currentConstruct=void 0,n}function i(s){if(s===null){e.consume(s);return}return e.enter("lineEnding"),e.consume(s),e.exit("lineEnding"),t.currentConstruct=void 0,n}}const pFe={resolveAll:rre()},mFe=nre("string"),gFe=nre("text");function nre(e){return{tokenize:t,resolveAll:rre(e==="text"?yFe:void 0)};function t(n){const r=this,i=this.parser.constructs[e],s=n.attempt(i,o,a);return o;function o(c){return l(c)?s(c):a(c)}function a(c){if(c===null){n.consume(c);return}return n.enter("data"),n.consume(c),u}function u(c){return l(c)?(n.exit("data"),s(c)):(n.consume(c),u)}function l(c){if(c===null)return!0;const f=i[c];let d=-1;if(f)for(;++d-1){const a=o[0];typeof a=="string"?o[0]=a.slice(r):o.shift()}s>0&&o.push(e[i].slice(0,s))}return o}function bFe(e,t){let n=-1;const r=[];let i;for(;++ne.length){for(;i--;)if(e.charCodeAt(i)===47){if(s){n=i+1;break}}else r<0&&(s=!0,r=i+1);return r<0?"":e.slice(n,r)}if(t===e)return"";let o=-1,a=t.length-1;for(;i--;)if(e.charCodeAt(i)===47){if(s){n=i+1;break}}else o<0&&(s=!0,o=i+1),a>-1&&(e.charCodeAt(i)===t.charCodeAt(a--)?a<0&&(r=i):(a=-1,r=o));return n===r?r=o:r<0&&(r=e.length),e.slice(n,r)}function s4e(e){if(K_(e),e.length===0)return".";let t=-1,n=e.length,r;for(;--n;)if(e.charCodeAt(n)===47){if(r){t=n;break}}else r||(r=!0);return t<0?e.charCodeAt(0)===47?"/":".":t===1&&e.charCodeAt(0)===47?"//":e.slice(0,t)}function o4e(e){K_(e);let t=e.length,n=-1,r=0,i=-1,s=0,o;for(;t--;){const a=e.charCodeAt(t);if(a===47){if(o){r=t+1;break}continue}n<0&&(o=!0,n=t+1),a===46?i<0?i=t:s!==1&&(s=1):i>-1&&(s=-1)}return i<0||n<0||s===0||s===1&&i===n-1&&i===r+1?"":e.slice(i,n)}function a4e(...e){let t=-1,n;for(;++t0&&e.charCodeAt(e.length-1)===47&&(n+="/"),t?"/"+n:n}function l4e(e,t){let n="",r=0,i=-1,s=0,o=-1,a,u;for(;++o<=e.length;){if(o2){if(u=n.lastIndexOf("/"),u!==n.length-1){u<0?(n="",r=0):(n=n.slice(0,u),r=n.length-1-n.lastIndexOf("/")),i=o,s=0;continue}}else if(n.length>0){n="",r=0,i=o,s=0;continue}}t&&(n=n.length>0?n+"/..":"..",r=2)}else n.length>0?n+="/"+e.slice(i+1,o):n=e.slice(i+1,o),r=o-i-1;i=o,s=0}else a===46&&s>-1?s++:s=-1}return n}function K_(e){if(typeof e!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}const c4e={cwd:f4e};function f4e(){return"/"}function wN(e){return e!==null&&typeof e=="object"&&e.href&&e.origin}function d4e(e){if(typeof e=="string")e=new URL(e);else if(!wN(e)){const t=new TypeError('The "path" argument must be of type string or an instance of URL. Received `'+e+"`");throw t.code="ERR_INVALID_ARG_TYPE",t}if(e.protocol!=="file:"){const t=new TypeError("The URL must be of scheme file");throw t.code="ERR_INVALID_URL_SCHEME",t}return h4e(e)}function h4e(e){if(e.hostname!==""){const r=new TypeError('File URL host must be "localhost" or empty on darwin');throw r.code="ERR_INVALID_FILE_URL_HOST",r}const t=e.pathname;let n=-1;for(;++n"u"||$w.call(t,i)},xV=function(t,n){EV&&n.name==="__proto__"?EV(t,n.name,{enumerable:!0,configurable:!0,value:n.newValue,writable:!0}):t[n.name]=n.newValue},CV=function(t,n){if(n==="__proto__")if($w.call(t,n)){if(SV)return SV(t,n).value}else return;return t[n]},g4e=function e(){var t,n,r,i,s,o,a=arguments[0],u=1,l=arguments.length,c=!1;for(typeof a=="boolean"&&(c=a,a=arguments[1]||{},u=2),(a==null||typeof a!="object"&&typeof a!="function")&&(a={});uo.length;let u;a&&o.push(i);try{u=e.apply(this,o)}catch(l){const c=l;if(a&&n)throw c;return i(c)}a||(u&&u.then&&typeof u.then=="function"?u.then(s,i):u instanceof Error?i(u):s(u))}function i(o,...a){n||(n=!0,t(o,...a))}function s(o){i(null,o)}}class ma extends Error{constructor(t,n,r){const i=[null,null];let s={start:{line:null,column:null},end:{line:null,column:null}};if(super(),typeof n=="string"&&(r=n,n=void 0),typeof r=="string"){const o=r.indexOf(":");o===-1?i[1]=r:(i[0]=r.slice(0,o),i[1]=r.slice(o+1))}n&&("type"in n||"position"in n?n.position&&(s=n.position):"start"in n||"end"in n?s=n:("line"in n||"column"in n)&&(s.start=n)),this.name=am(n)||"1:1",this.message=typeof t=="object"?t.message:t,this.stack="",typeof t=="object"&&t.stack&&(this.stack=t.stack),this.reason=this.message,this.fatal,this.line=s.start.line,this.column=s.start.column,this.position=s,this.source=i[0],this.ruleId=i[1],this.file,this.actual,this.expected,this.url,this.note}}ma.prototype.file="";ma.prototype.name="";ma.prototype.reason="";ma.prototype.message="";ma.prototype.stack="";ma.prototype.fatal=null;ma.prototype.column=null;ma.prototype.line=null;ma.prototype.source=null;ma.prototype.ruleId=null;ma.prototype.position=null;const cu={basename:_4e,dirname:b4e,extname:w4e,join:E4e,sep:"/"};function _4e(e,t){if(t!==void 0&&typeof t!="string")throw new TypeError('"ext" argument must be a string');Q_(e);let n=0,r=-1,i=e.length,s;if(t===void 0||t.length===0||t.length>e.length){for(;i--;)if(e.charCodeAt(i)===47){if(s){n=i+1;break}}else r<0&&(s=!0,r=i+1);return r<0?"":e.slice(n,r)}if(t===e)return"";let o=-1,a=t.length-1;for(;i--;)if(e.charCodeAt(i)===47){if(s){n=i+1;break}}else o<0&&(s=!0,o=i+1),a>-1&&(e.charCodeAt(i)===t.charCodeAt(a--)?a<0&&(r=i):(a=-1,r=o));return n===r?r=o:r<0&&(r=e.length),e.slice(n,r)}function b4e(e){if(Q_(e),e.length===0)return".";let t=-1,n=e.length,r;for(;--n;)if(e.charCodeAt(n)===47){if(r){t=n;break}}else r||(r=!0);return t<0?e.charCodeAt(0)===47?"/":".":t===1&&e.charCodeAt(0)===47?"//":e.slice(0,t)}function w4e(e){Q_(e);let t=e.length,n=-1,r=0,i=-1,s=0,o;for(;t--;){const a=e.charCodeAt(t);if(a===47){if(o){r=t+1;break}continue}n<0&&(o=!0,n=t+1),a===46?i<0?i=t:s!==1&&(s=1):i>-1&&(s=-1)}return i<0||n<0||s===0||s===1&&i===n-1&&i===r+1?"":e.slice(i,n)}function E4e(...e){let t=-1,n;for(;++t0&&e.charCodeAt(e.length-1)===47&&(n+="/"),t?"/"+n:n}function T4e(e,t){let n="",r=0,i=-1,s=0,o=-1,a,u;for(;++o<=e.length;){if(o2){if(u=n.lastIndexOf("/"),u!==n.length-1){u<0?(n="",r=0):(n=n.slice(0,u),r=n.length-1-n.lastIndexOf("/")),i=o,s=0;continue}}else if(n.length>0){n="",r=0,i=o,s=0;continue}}t&&(n=n.length>0?n+"/..":"..",r=2)}else n.length>0?n+="/"+e.slice(i+1,o):n=e.slice(i+1,o),r=o-i-1;i=o,s=0}else a===46&&s>-1?s++:s=-1}return n}function Q_(e){if(typeof e!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}const I4e={cwd:x4e};function x4e(){return"/"}function SN(e){return e!==null&&typeof e=="object"&&e.href&&e.origin}function C4e(e){if(typeof e=="string")e=new URL(e);else if(!SN(e)){const t=new TypeError('The "path" argument must be of type string or an instance of URL. Received `'+e+"`");throw t.code="ERR_INVALID_ARG_TYPE",t}if(e.protocol!=="file:"){const t=new TypeError("The URL must be of scheme file");throw t.code="ERR_INVALID_URL_SCHEME",t}return A4e(e)}function A4e(e){if(e.hostname!==""){const r=new TypeError('File URL host must be "localhost" or empty on darwin');throw r.code="ERR_INVALID_FILE_URL_HOST",r}const t=e.pathname;let n=-1;for(;++n{if(E||!I||!A)T(E);else{const R=s.stringify(I,A);R==null||(D4e(R)?A.value=R:A.result=R),T(E,A)}});function T(E,I){E||!I?b(E):v?v(I):y(null,I)}}}function p(m){let y;s.freeze(),vO("processSync",s.Parser),_O("processSync",s.Compiler);const g=E0(m);return s.process(g,v),NV("processSync","process",y),g;function v(b){y=!0,wV(b)}}}function OV(e,t){return typeof e=="function"&&e.prototype&&(N4e(e.prototype)||t in e.prototype)}function N4e(e){let t;for(t in e)if(qne.call(e,t))return!0;return!1}function vO(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `Parser`")}function _O(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `Compiler`")}function bO(e,t){if(t)throw new Error("Cannot call `"+e+"` on a frozen processor.\nCreate a new processor first, by calling it: use `processor()` instead of `processor`.")}function RV(e){if(!EN(e)||typeof e.type!="string")throw new TypeError("Expected node, got `"+e+"`")}function NV(e,t,n){if(!n)throw new Error("`"+e+"` finished async. Use `"+t+"` instead")}function E0(e){return k4e(e)?e:new P4e(e)}function k4e(e){return!!(e&&typeof e=="object"&&"message"in e&&"messages"in e)}function D4e(e){return typeof e=="string"||e6(e)}const $4e={};function L4e(e,t){const n=t||$4e,r=typeof n.includeImageAlt=="boolean"?n.includeImageAlt:!0,i=typeof n.includeHtml=="boolean"?n.includeHtml:!0;return Yne(e,r,i)}function Yne(e,t,n){if(M4e(e)){if("value"in e)return e.type==="html"&&!n?"":e.value;if(t&&"alt"in e&&e.alt)return e.alt;if("children"in e)return kV(e.children,t,n)}return Array.isArray(e)?kV(e,t,n):""}function kV(e,t,n){const r=[];let i=-1;for(;++ii?0:i+t:t=t>i?i:t,n=n>0?n:0,r.length<1e4)o=Array.from(r),o.unshift(t,n),e.splice(...o);else for(n&&e.splice(t,n);s0?(Zu(e,e.length,0,t),e):t}const DV={}.hasOwnProperty;function F4e(e){const t={};let n=-1;for(;++no))return;const I=t.events.length;let A=I,R,F;for(;A--;)if(t.events[A][0]==="exit"&&t.events[A][1].type==="chunkFlow"){if(R){F=t.events[A][1].end;break}R=!0}for(g(r),E=I;Eb;){const T=n[S];t.containerState=T[1],T[0].exit.call(t,e)}n.length=b}function v(){i.write([null]),s=void 0,i=void 0,t.containerState._closeFlow=void 0}}function X4e(e,t,n){return Jn(e,e.attempt(this.parser.constructs.document,t,n),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}function LV(e){if(e===null||eo(e)||q4e(e))return 1;if(W4e(e))return 2}function t6(e,t,n){const r=[];let i=-1;for(;++i1&&e[n][1].end.offset-e[n][1].start.offset>1?2:1;const f=Object.assign({},e[r][1].end),d=Object.assign({},e[n][1].start);MV(f,-u),MV(d,u),o={type:u>1?"strongSequence":"emphasisSequence",start:f,end:Object.assign({},e[r][1].end)},a={type:u>1?"strongSequence":"emphasisSequence",start:Object.assign({},e[n][1].start),end:d},s={type:u>1?"strongText":"emphasisText",start:Object.assign({},e[r][1].end),end:Object.assign({},e[n][1].start)},i={type:u>1?"strong":"emphasis",start:Object.assign({},o.start),end:Object.assign({},a.end)},e[r][1].end=Object.assign({},o.start),e[n][1].start=Object.assign({},a.end),l=[],e[r][1].end.offset-e[r][1].start.offset&&(l=qo(l,[["enter",e[r][1],t],["exit",e[r][1],t]])),l=qo(l,[["enter",i,t],["enter",o,t],["exit",o,t],["enter",s,t]]),l=qo(l,t6(t.parser.constructs.insideSpan.null,e.slice(r+1,n),t)),l=qo(l,[["exit",s,t],["enter",a,t],["exit",a,t],["exit",i,t]]),e[n][1].end.offset-e[n][1].start.offset?(c=2,l=qo(l,[["enter",e[n][1],t],["exit",e[n][1],t]])):c=0,Zu(e,r-1,n-r+3,l),n=r+l.length-c-2;break}}for(n=-1;++n0&&On(E)?Jn(e,v,"linePrefix",s+1)(E):v(E)}function v(E){return E===null||Pt(E)?e.check(BV,m,S)(E):(e.enter("codeFlowValue"),b(E))}function b(E){return E===null||Pt(E)?(e.exit("codeFlowValue"),v(E)):(e.consume(E),b)}function S(E){return e.exit("codeFenced"),t(E)}function T(E,I,A){let R=0;return F;function F(re){return E.enter("lineEnding"),E.consume(re),E.exit("lineEnding"),L}function L(re){return E.enter("codeFencedFence"),On(re)?Jn(E,B,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(re):B(re)}function B(re){return re===a?(E.enter("codeFencedFenceSequence"),J(re)):A(re)}function J(re){return re===a?(R++,E.consume(re),J):R>=o?(E.exit("codeFencedFenceSequence"),On(re)?Jn(E,V,"whitespace")(re):V(re)):A(re)}function V(re){return re===null||Pt(re)?(E.exit("codeFencedFence"),I(re)):A(re)}}}function l5e(e,t,n){const r=this;return i;function i(o){return o===null?n(o):(e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),s)}function s(o){return r.parser.lazy[r.now().line]?n(o):t(o)}}const wO={name:"codeIndented",tokenize:f5e},c5e={tokenize:d5e,partial:!0};function f5e(e,t,n){const r=this;return i;function i(l){return e.enter("codeIndented"),Jn(e,s,"linePrefix",5)(l)}function s(l){const c=r.events[r.events.length-1];return c&&c[1].type==="linePrefix"&&c[2].sliceSerialize(c[1],!0).length>=4?o(l):n(l)}function o(l){return l===null?u(l):Pt(l)?e.attempt(c5e,o,u)(l):(e.enter("codeFlowValue"),a(l))}function a(l){return l===null||Pt(l)?(e.exit("codeFlowValue"),o(l)):(e.consume(l),a)}function u(l){return e.exit("codeIndented"),t(l)}}function d5e(e,t,n){const r=this;return i;function i(o){return r.parser.lazy[r.now().line]?n(o):Pt(o)?(e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),i):Jn(e,s,"linePrefix",5)(o)}function s(o){const a=r.events[r.events.length-1];return a&&a[1].type==="linePrefix"&&a[2].sliceSerialize(a[1],!0).length>=4?t(o):Pt(o)?i(o):n(o)}}const h5e={name:"codeText",tokenize:g5e,resolve:p5e,previous:m5e};function p5e(e){let t=e.length-4,n=3,r,i;if((e[n][1].type==="lineEnding"||e[n][1].type==="space")&&(e[t][1].type==="lineEnding"||e[t][1].type==="space")){for(r=n;++r=4?t(o):e.interrupt(r.parser.constructs.flow,n,t)(o)}}function Zne(e,t,n,r,i,s,o,a,u){const l=u||Number.POSITIVE_INFINITY;let c=0;return f;function f(g){return g===60?(e.enter(r),e.enter(i),e.enter(s),e.consume(g),e.exit(s),d):g===null||g===32||g===41||TN(g)?n(g):(e.enter(r),e.enter(o),e.enter(a),e.enter("chunkString",{contentType:"string"}),m(g))}function d(g){return g===62?(e.enter(s),e.consume(g),e.exit(s),e.exit(i),e.exit(r),t):(e.enter(a),e.enter("chunkString",{contentType:"string"}),h(g))}function h(g){return g===62?(e.exit("chunkString"),e.exit(a),d(g)):g===null||g===60||Pt(g)?n(g):(e.consume(g),g===92?p:h)}function p(g){return g===60||g===62||g===92?(e.consume(g),h):h(g)}function m(g){return!c&&(g===null||g===41||eo(g))?(e.exit("chunkString"),e.exit(a),e.exit(o),e.exit(r),t(g)):c999||h===null||h===91||h===93&&!u||h===94&&!a&&"_hiddenFootnoteSupport"in o.parser.constructs?n(h):h===93?(e.exit(s),e.enter(i),e.consume(h),e.exit(i),e.exit(r),t):Pt(h)?(e.enter("lineEnding"),e.consume(h),e.exit("lineEnding"),c):(e.enter("chunkString",{contentType:"string"}),f(h))}function f(h){return h===null||h===91||h===93||Pt(h)||a++>999?(e.exit("chunkString"),c(h)):(e.consume(h),u||(u=!On(h)),h===92?d:f)}function d(h){return h===91||h===92||h===93?(e.consume(h),a++,f):f(h)}}function tre(e,t,n,r,i,s){let o;return a;function a(d){return d===34||d===39||d===40?(e.enter(r),e.enter(i),e.consume(d),e.exit(i),o=d===40?41:d,u):n(d)}function u(d){return d===o?(e.enter(i),e.consume(d),e.exit(i),e.exit(r),t):(e.enter(s),l(d))}function l(d){return d===o?(e.exit(s),u(o)):d===null?n(d):Pt(d)?(e.enter("lineEnding"),e.consume(d),e.exit("lineEnding"),Jn(e,l,"linePrefix")):(e.enter("chunkString",{contentType:"string"}),c(d))}function c(d){return d===o||d===null||Pt(d)?(e.exit("chunkString"),l(d)):(e.consume(d),d===92?f:c)}function f(d){return d===o||d===92?(e.consume(d),c):c(d)}}function Ay(e,t){let n;return r;function r(i){return Pt(i)?(e.enter("lineEnding"),e.consume(i),e.exit("lineEnding"),n=!0,r):On(i)?Jn(e,r,n?"linePrefix":"lineSuffix")(i):t(i)}}function um(e){return e.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}const S5e={name:"definition",tokenize:I5e},T5e={tokenize:x5e,partial:!0};function I5e(e,t,n){const r=this;let i;return s;function s(h){return e.enter("definition"),o(h)}function o(h){return ere.call(r,e,a,n,"definitionLabel","definitionLabelMarker","definitionLabelString")(h)}function a(h){return i=um(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)),h===58?(e.enter("definitionMarker"),e.consume(h),e.exit("definitionMarker"),u):n(h)}function u(h){return eo(h)?Ay(e,l)(h):l(h)}function l(h){return Zne(e,c,n,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(h)}function c(h){return e.attempt(T5e,f,f)(h)}function f(h){return On(h)?Jn(e,d,"whitespace")(h):d(h)}function d(h){return h===null||Pt(h)?(e.exit("definition"),r.parser.defined.push(i),t(h)):n(h)}}function x5e(e,t,n){return r;function r(a){return eo(a)?Ay(e,i)(a):n(a)}function i(a){return tre(e,s,n,"definitionTitle","definitionTitleMarker","definitionTitleString")(a)}function s(a){return On(a)?Jn(e,o,"whitespace")(a):o(a)}function o(a){return a===null||Pt(a)?t(a):n(a)}}const C5e={name:"hardBreakEscape",tokenize:A5e};function A5e(e,t,n){return r;function r(s){return e.enter("hardBreakEscape"),e.consume(s),i}function i(s){return Pt(s)?(e.exit("hardBreakEscape"),t(s)):n(s)}}const P5e={name:"headingAtx",tokenize:R5e,resolve:O5e};function O5e(e,t){let n=e.length-2,r=3,i,s;return e[r][1].type==="whitespace"&&(r+=2),n-2>r&&e[n][1].type==="whitespace"&&(n-=2),e[n][1].type==="atxHeadingSequence"&&(r===n-1||n-4>r&&e[n-2][1].type==="whitespace")&&(n-=r+1===n?2:4),n>r&&(i={type:"atxHeadingText",start:e[r][1].start,end:e[n][1].end},s={type:"chunkText",start:e[r][1].start,end:e[n][1].end,contentType:"text"},Zu(e,r,n-r+1,[["enter",i,t],["enter",s,t],["exit",s,t],["exit",i,t]])),e}function R5e(e,t,n){let r=0;return i;function i(c){return e.enter("atxHeading"),s(c)}function s(c){return e.enter("atxHeadingSequence"),o(c)}function o(c){return c===35&&r++<6?(e.consume(c),o):c===null||eo(c)?(e.exit("atxHeadingSequence"),a(c)):n(c)}function a(c){return c===35?(e.enter("atxHeadingSequence"),u(c)):c===null||Pt(c)?(e.exit("atxHeading"),t(c)):On(c)?Jn(e,a,"whitespace")(c):(e.enter("atxHeadingText"),l(c))}function u(c){return c===35?(e.consume(c),u):(e.exit("atxHeadingSequence"),a(c))}function l(c){return c===null||c===35||eo(c)?(e.exit("atxHeadingText"),a(c)):(e.consume(c),l)}}const N5e=["address","article","aside","base","basefont","blockquote","body","caption","center","col","colgroup","dd","details","dialog","dir","div","dl","dt","fieldset","figcaption","figure","footer","form","frame","frameset","h1","h2","h3","h4","h5","h6","head","header","hr","html","iframe","legend","li","link","main","menu","menuitem","nav","noframes","ol","optgroup","option","p","param","search","section","summary","table","tbody","td","tfoot","th","thead","title","tr","track","ul"],UV=["pre","script","style","textarea"],k5e={name:"htmlFlow",tokenize:M5e,resolveTo:L5e,concrete:!0},D5e={tokenize:B5e,partial:!0},$5e={tokenize:F5e,partial:!0};function L5e(e){let t=e.length;for(;t--&&!(e[t][0]==="enter"&&e[t][1].type==="htmlFlow"););return t>1&&e[t-2][1].type==="linePrefix"&&(e[t][1].start=e[t-2][1].start,e[t+1][1].start=e[t-2][1].start,e.splice(t-2,2)),e}function M5e(e,t,n){const r=this;let i,s,o,a,u;return l;function l(x){return c(x)}function c(x){return e.enter("htmlFlow"),e.enter("htmlFlowData"),e.consume(x),f}function f(x){return x===33?(e.consume(x),d):x===47?(e.consume(x),s=!0,m):x===63?(e.consume(x),i=3,r.interrupt?t:P):bu(x)?(e.consume(x),o=String.fromCharCode(x),y):n(x)}function d(x){return x===45?(e.consume(x),i=2,h):x===91?(e.consume(x),i=5,a=0,p):bu(x)?(e.consume(x),i=4,r.interrupt?t:P):n(x)}function h(x){return x===45?(e.consume(x),r.interrupt?t:P):n(x)}function p(x){const O="CDATA[";return x===O.charCodeAt(a++)?(e.consume(x),a===O.length?r.interrupt?t:B:p):n(x)}function m(x){return bu(x)?(e.consume(x),o=String.fromCharCode(x),y):n(x)}function y(x){if(x===null||x===47||x===62||eo(x)){const O=x===47,$=o.toLowerCase();return!O&&!s&&UV.includes($)?(i=1,r.interrupt?t(x):B(x)):N5e.includes(o.toLowerCase())?(i=6,O?(e.consume(x),g):r.interrupt?t(x):B(x)):(i=7,r.interrupt&&!r.parser.lazy[r.now().line]?n(x):s?v(x):b(x))}return x===45||Eo(x)?(e.consume(x),o+=String.fromCharCode(x),y):n(x)}function g(x){return x===62?(e.consume(x),r.interrupt?t:B):n(x)}function v(x){return On(x)?(e.consume(x),v):F(x)}function b(x){return x===47?(e.consume(x),F):x===58||x===95||bu(x)?(e.consume(x),S):On(x)?(e.consume(x),b):F(x)}function S(x){return x===45||x===46||x===58||x===95||Eo(x)?(e.consume(x),S):T(x)}function T(x){return x===61?(e.consume(x),E):On(x)?(e.consume(x),T):b(x)}function E(x){return x===null||x===60||x===61||x===62||x===96?n(x):x===34||x===39?(e.consume(x),u=x,I):On(x)?(e.consume(x),E):A(x)}function I(x){return x===u?(e.consume(x),u=null,R):x===null||Pt(x)?n(x):(e.consume(x),I)}function A(x){return x===null||x===34||x===39||x===47||x===60||x===61||x===62||x===96||eo(x)?T(x):(e.consume(x),A)}function R(x){return x===47||x===62||On(x)?b(x):n(x)}function F(x){return x===62?(e.consume(x),L):n(x)}function L(x){return x===null||Pt(x)?B(x):On(x)?(e.consume(x),L):n(x)}function B(x){return x===45&&i===2?(e.consume(x),oe):x===60&&i===1?(e.consume(x),ae):x===62&&i===4?(e.consume(x),W):x===63&&i===3?(e.consume(x),P):x===93&&i===5?(e.consume(x),ue):Pt(x)&&(i===6||i===7)?(e.exit("htmlFlowData"),e.check(D5e,Q,J)(x)):x===null||Pt(x)?(e.exit("htmlFlowData"),J(x)):(e.consume(x),B)}function J(x){return e.check($5e,V,Q)(x)}function V(x){return e.enter("lineEnding"),e.consume(x),e.exit("lineEnding"),re}function re(x){return x===null||Pt(x)?J(x):(e.enter("htmlFlowData"),B(x))}function oe(x){return x===45?(e.consume(x),P):B(x)}function ae(x){return x===47?(e.consume(x),o="",ee):B(x)}function ee(x){if(x===62){const O=o.toLowerCase();return UV.includes(O)?(e.consume(x),W):B(x)}return bu(x)&&o.length<8?(e.consume(x),o+=String.fromCharCode(x),ee):B(x)}function ue(x){return x===93?(e.consume(x),P):B(x)}function P(x){return x===62?(e.consume(x),W):x===45&&i===2?(e.consume(x),P):B(x)}function W(x){return x===null||Pt(x)?(e.exit("htmlFlowData"),Q(x)):(e.consume(x),W)}function Q(x){return e.exit("htmlFlow"),t(x)}}function F5e(e,t,n){const r=this;return i;function i(o){return Pt(o)?(e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),s):n(o)}function s(o){return r.parser.lazy[r.now().line]?n(o):t(o)}}function B5e(e,t,n){return r;function r(i){return e.enter("lineEnding"),e.consume(i),e.exit("lineEnding"),e.attempt(fC,t,n)}}const j5e={name:"htmlText",tokenize:U5e};function U5e(e,t,n){const r=this;let i,s,o;return a;function a(P){return e.enter("htmlText"),e.enter("htmlTextData"),e.consume(P),u}function u(P){return P===33?(e.consume(P),l):P===47?(e.consume(P),T):P===63?(e.consume(P),b):bu(P)?(e.consume(P),A):n(P)}function l(P){return P===45?(e.consume(P),c):P===91?(e.consume(P),s=0,p):bu(P)?(e.consume(P),v):n(P)}function c(P){return P===45?(e.consume(P),h):n(P)}function f(P){return P===null?n(P):P===45?(e.consume(P),d):Pt(P)?(o=f,ae(P)):(e.consume(P),f)}function d(P){return P===45?(e.consume(P),h):f(P)}function h(P){return P===62?oe(P):P===45?d(P):f(P)}function p(P){const W="CDATA[";return P===W.charCodeAt(s++)?(e.consume(P),s===W.length?m:p):n(P)}function m(P){return P===null?n(P):P===93?(e.consume(P),y):Pt(P)?(o=m,ae(P)):(e.consume(P),m)}function y(P){return P===93?(e.consume(P),g):m(P)}function g(P){return P===62?oe(P):P===93?(e.consume(P),g):m(P)}function v(P){return P===null||P===62?oe(P):Pt(P)?(o=v,ae(P)):(e.consume(P),v)}function b(P){return P===null?n(P):P===63?(e.consume(P),S):Pt(P)?(o=b,ae(P)):(e.consume(P),b)}function S(P){return P===62?oe(P):b(P)}function T(P){return bu(P)?(e.consume(P),E):n(P)}function E(P){return P===45||Eo(P)?(e.consume(P),E):I(P)}function I(P){return Pt(P)?(o=I,ae(P)):On(P)?(e.consume(P),I):oe(P)}function A(P){return P===45||Eo(P)?(e.consume(P),A):P===47||P===62||eo(P)?R(P):n(P)}function R(P){return P===47?(e.consume(P),oe):P===58||P===95||bu(P)?(e.consume(P),F):Pt(P)?(o=R,ae(P)):On(P)?(e.consume(P),R):oe(P)}function F(P){return P===45||P===46||P===58||P===95||Eo(P)?(e.consume(P),F):L(P)}function L(P){return P===61?(e.consume(P),B):Pt(P)?(o=L,ae(P)):On(P)?(e.consume(P),L):R(P)}function B(P){return P===null||P===60||P===61||P===62||P===96?n(P):P===34||P===39?(e.consume(P),i=P,J):Pt(P)?(o=B,ae(P)):On(P)?(e.consume(P),B):(e.consume(P),V)}function J(P){return P===i?(e.consume(P),i=void 0,re):P===null?n(P):Pt(P)?(o=J,ae(P)):(e.consume(P),J)}function V(P){return P===null||P===34||P===39||P===60||P===61||P===96?n(P):P===47||P===62||eo(P)?R(P):(e.consume(P),V)}function re(P){return P===47||P===62||eo(P)?R(P):n(P)}function oe(P){return P===62?(e.consume(P),e.exit("htmlTextData"),e.exit("htmlText"),t):n(P)}function ae(P){return e.exit("htmlTextData"),e.enter("lineEnding"),e.consume(P),e.exit("lineEnding"),ee}function ee(P){return On(P)?Jn(e,ue,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(P):ue(P)}function ue(P){return e.enter("htmlTextData"),o(P)}}const r6={name:"labelEnd",tokenize:G5e,resolveTo:q5e,resolveAll:W5e},V5e={tokenize:Y5e},z5e={tokenize:K5e},H5e={tokenize:Q5e};function W5e(e){let t=-1;for(;++t=3&&(l===null||Pt(l))?(e.exit("thematicBreak"),t(l)):n(l)}function u(l){return l===i?(e.consume(l),r++,u):(e.exit("thematicBreakSequence"),On(l)?Jn(e,a,"whitespace")(l):a(l))}}const Rs={name:"list",tokenize:sFe,continuation:{tokenize:oFe},exit:uFe},rFe={tokenize:lFe,partial:!0},iFe={tokenize:aFe,partial:!0};function sFe(e,t,n){const r=this,i=r.events[r.events.length-1];let s=i&&i[1].type==="linePrefix"?i[2].sliceSerialize(i[1],!0).length:0,o=0;return a;function a(h){const p=r.containerState.type||(h===42||h===43||h===45?"listUnordered":"listOrdered");if(p==="listUnordered"?!r.containerState.marker||h===r.containerState.marker:IN(h)){if(r.containerState.type||(r.containerState.type=p,e.enter(p,{_container:!0})),p==="listUnordered")return e.enter("listItemPrefix"),h===42||h===45?e.check(Lw,n,l)(h):l(h);if(!r.interrupt||h===49)return e.enter("listItemPrefix"),e.enter("listItemValue"),u(h)}return n(h)}function u(h){return IN(h)&&++o<10?(e.consume(h),u):(!r.interrupt||o<2)&&(r.containerState.marker?h===r.containerState.marker:h===41||h===46)?(e.exit("listItemValue"),l(h)):n(h)}function l(h){return e.enter("listItemMarker"),e.consume(h),e.exit("listItemMarker"),r.containerState.marker=r.containerState.marker||h,e.check(fC,r.interrupt?n:c,e.attempt(rFe,d,f))}function c(h){return r.containerState.initialBlankLine=!0,s++,d(h)}function f(h){return On(h)?(e.enter("listItemPrefixWhitespace"),e.consume(h),e.exit("listItemPrefixWhitespace"),d):n(h)}function d(h){return r.containerState.size=s+r.sliceSerialize(e.exit("listItemPrefix"),!0).length,t(h)}}function oFe(e,t,n){const r=this;return r.containerState._closeFlow=void 0,e.check(fC,i,s);function i(a){return r.containerState.furtherBlankLines=r.containerState.furtherBlankLines||r.containerState.initialBlankLine,Jn(e,t,"listItemIndent",r.containerState.size+1)(a)}function s(a){return r.containerState.furtherBlankLines||!On(a)?(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,o(a)):(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,e.attempt(iFe,t,o)(a))}function o(a){return r.containerState._closeFlow=!0,r.interrupt=void 0,Jn(e,e.attempt(Rs,t,n),"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(a)}}function aFe(e,t,n){const r=this;return Jn(e,i,"listItemIndent",r.containerState.size+1);function i(s){const o=r.events[r.events.length-1];return o&&o[1].type==="listItemIndent"&&o[2].sliceSerialize(o[1],!0).length===r.containerState.size?t(s):n(s)}}function uFe(e){e.exit(this.containerState.type)}function lFe(e,t,n){const r=this;return Jn(e,i,"listItemPrefixWhitespace",r.parser.constructs.disable.null.includes("codeIndented")?void 0:5);function i(s){const o=r.events[r.events.length-1];return!On(s)&&o&&o[1].type==="listItemPrefixWhitespace"?t(s):n(s)}}const VV={name:"setextUnderline",tokenize:fFe,resolveTo:cFe};function cFe(e,t){let n=e.length,r,i,s;for(;n--;)if(e[n][0]==="enter"){if(e[n][1].type==="content"){r=n;break}e[n][1].type==="paragraph"&&(i=n)}else e[n][1].type==="content"&&e.splice(n,1),!s&&e[n][1].type==="definition"&&(s=n);const o={type:"setextHeading",start:Object.assign({},e[i][1].start),end:Object.assign({},e[e.length-1][1].end)};return e[i][1].type="setextHeadingText",s?(e.splice(i,0,["enter",o,t]),e.splice(s+1,0,["exit",e[r][1],t]),e[r][1].end=Object.assign({},e[s][1].end)):e[r][1]=o,e.push(["exit",o,t]),e}function fFe(e,t,n){const r=this;let i;return s;function s(l){let c=r.events.length,f;for(;c--;)if(r.events[c][1].type!=="lineEnding"&&r.events[c][1].type!=="linePrefix"&&r.events[c][1].type!=="content"){f=r.events[c][1].type==="paragraph";break}return!r.parser.lazy[r.now().line]&&(r.interrupt||f)?(e.enter("setextHeadingLine"),i=l,o(l)):n(l)}function o(l){return e.enter("setextHeadingLineSequence"),a(l)}function a(l){return l===i?(e.consume(l),a):(e.exit("setextHeadingLineSequence"),On(l)?Jn(e,u,"lineSuffix")(l):u(l))}function u(l){return l===null||Pt(l)?(e.exit("setextHeadingLine"),t(l)):n(l)}}const dFe={tokenize:hFe};function hFe(e){const t=this,n=e.attempt(fC,r,e.attempt(this.parser.constructs.flowInitial,i,Jn(e,e.attempt(this.parser.constructs.flow,i,e.attempt(v5e,i)),"linePrefix")));return n;function r(s){if(s===null){e.consume(s);return}return e.enter("lineEndingBlank"),e.consume(s),e.exit("lineEndingBlank"),t.currentConstruct=void 0,n}function i(s){if(s===null){e.consume(s);return}return e.enter("lineEnding"),e.consume(s),e.exit("lineEnding"),t.currentConstruct=void 0,n}}const pFe={resolveAll:rre()},mFe=nre("string"),gFe=nre("text");function nre(e){return{tokenize:t,resolveAll:rre(e==="text"?yFe:void 0)};function t(n){const r=this,i=this.parser.constructs[e],s=n.attempt(i,o,a);return o;function o(c){return l(c)?s(c):a(c)}function a(c){if(c===null){n.consume(c);return}return n.enter("data"),n.consume(c),u}function u(c){return l(c)?(n.exit("data"),s(c)):(n.consume(c),u)}function l(c){if(c===null)return!0;const f=i[c];let d=-1;if(f)for(;++d-1){const a=o[0];typeof a=="string"?o[0]=a.slice(r):o.shift()}s>0&&o.push(e[i].slice(0,s))}return o}function bFe(e,t){let n=-1;const r=[];let i;for(;++n13&&n<32||n>126&&n<160||n>55295&&n<57344||n>64975&&n<65008||(n&65535)===65535||(n&65535)===65534||n>1114111?"�":String.fromCharCode(n)}const DFe=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function $Fe(e){return e.replace(DFe,LFe)}function LFe(e,t,n){if(t)return t;if(n.charCodeAt(0)===35){const i=n.charCodeAt(1),s=i===120||i===88;return ire(n.slice(s?2:1),s?16:10)}return r6(n)||e}const sre={}.hasOwnProperty,MFe=function(e,t,n){return typeof t!="string"&&(n=t,t=void 0),FFe(n)(kFe(RFe(n).document().write(NFe()(e,t,!0))))};function FFe(e){const t={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:a(bn),autolinkProtocol:L,autolinkEmail:L,atxHeading:a(ke),blockQuote:a(Ee),characterEscape:L,characterReference:L,codeFenced:a(ge),codeFencedFenceInfo:u,codeFencedFenceMeta:u,codeIndented:a(ge,u),codeText:a(nt,u),codeTextData:L,data:L,codeFlowValue:L,definition:a(Je),definitionDestinationString:u,definitionLabelString:u,definitionTitleString:u,emphasis:a(yt),hardBreakEscape:a(at),hardBreakTrailing:a(at),htmlFlow:a(St,u),htmlFlowData:L,htmlText:a(St,u),htmlTextData:L,image:a(cn),label:u,link:a(bn),listItem:a(Fe),listItemValue:p,listOrdered:a(He,h),listUnordered:a(He),paragraph:a(st),reference:$,referenceString:u,resourceDestinationString:u,resourceTitleString:u,setextHeading:a(ke),strong:a(dt),thematicBreak:a(Kt)},exit:{atxHeading:c(),atxHeadingSequence:I,autolink:c(),autolinkEmail:ve,autolinkProtocol:de,blockQuote:c(),characterEscapeValue:B,characterReferenceMarkerHexadecimal:ce,characterReferenceMarkerNumeric:ce,characterReferenceValue:fe,codeFenced:c(v),codeFencedFence:g,codeFencedFenceInfo:m,codeFencedFenceMeta:y,codeFlowValue:B,codeIndented:c(b),codeText:c(ae),codeTextData:B,data:B,definition:c(),definitionDestinationString:E,definitionLabelString:S,definitionTitleString:T,emphasis:c(),hardBreakEscape:c(V),hardBreakTrailing:c(V),htmlFlow:c(re),htmlFlowData:B,htmlText:c(oe),htmlTextData:B,image:c(ue),label:W,labelText:P,lineEnding:J,link:c(ee),listItem:c(),listOrdered:c(),listUnordered:c(),paragraph:c(),referenceString:q,resourceDestinationString:Q,resourceTitleString:x,resource:O,setextHeading:c(F),setextHeadingLineSequence:R,setextHeadingText:A,strong:c(),thematicBreak:c()}};ore(t,(e||{}).mdastExtensions||[]);const n={};return r;function r(me){let Se={type:"root",children:[]};const Le={stack:[Se],tokenStack:[],config:t,enter:l,exit:f,buffer:u,resume:d,setData:s,getData:o},Ke=[];let ct=-1;for(;++ct0){const In=Le.tokenStack[Le.tokenStack.length-1];(In[1]||WV).call(Le,void 0,In[0])}for(Se.position={start:Ic(me.length>0?me[0][1].start:{line:1,column:1,offset:0}),end:Ic(me.length>0?me[me.length-2][1].end:{line:1,column:1,offset:0})},ct=-1;++ct{const r=this.data("settings");return MFe(n,Object.assign({},r,e,{extensions:this.data("micromarkExtensions")||[],mdastExtensions:this.data("fromMarkdownExtensions")||[]}))}})}function UFe(e,t){const n={type:"element",tagName:"blockquote",properties:{},children:e.wrap(e.all(t),!0)};return e.patch(t,n),e.applyData(t,n)}function VFe(e,t){const n={type:"element",tagName:"br",properties:{},children:[]};return e.patch(t,n),[e.applyData(t,n),{type:"text",value:` +`;break}case-2:{o=t?" ":" ";break}case-1:{if(!t&&i)continue;o=" ";break}default:o=String.fromCharCode(s)}i=s===-2,r.push(o)}return r.join("")}const wFe={42:Rs,43:Rs,45:Rs,48:Rs,49:Rs,50:Rs,51:Rs,52:Rs,53:Rs,54:Rs,55:Rs,56:Rs,57:Rs,62:Kne},EFe={91:S5e},SFe={[-2]:wO,[-1]:wO,32:wO},TFe={35:P5e,42:Lw,45:[VV,Lw],60:k5e,61:VV,95:Lw,96:jV,126:jV},IFe={38:Xne,92:Qne},xFe={[-5]:EO,[-4]:EO,[-3]:EO,33:X5e,38:Xne,42:xN,60:[e5e,j5e],91:Z5e,92:[C5e,Qne],93:r6,95:xN,96:h5e},CFe={null:[xN,pFe]},AFe={null:[42,95]},PFe={null:[]},OFe=Object.freeze(Object.defineProperty({__proto__:null,attentionMarkers:AFe,contentInitial:EFe,disable:PFe,document:wFe,flow:TFe,flowInitial:SFe,insideSpan:CFe,string:IFe,text:xFe},Symbol.toStringTag,{value:"Module"}));function RFe(e){const n=F4e([OFe,...(e||{}).extensions||[]]),r={defined:[],lazy:{},constructs:n,content:i(G4e),document:i(K4e),flow:i(dFe),string:i(mFe),text:i(gFe)};return r;function i(s){return o;function o(a){return vFe(r,s,a)}}}const zV=/[\0\t\n\r]/g;function NFe(){let e=1,t="",n=!0,r;return i;function i(s,o,a){const u=[];let l,c,f,d,h;for(s=t+s.toString(o),f=0,t="",n&&(s.charCodeAt(0)===65279&&f++,n=void 0);f13&&n<32||n>126&&n<160||n>55295&&n<57344||n>64975&&n<65008||(n&65535)===65535||(n&65535)===65534||n>1114111?"�":String.fromCharCode(n)}const DFe=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function $Fe(e){return e.replace(DFe,LFe)}function LFe(e,t,n){if(t)return t;if(n.charCodeAt(0)===35){const i=n.charCodeAt(1),s=i===120||i===88;return ire(n.slice(s?2:1),s?16:10)}return n6(n)||e}const sre={}.hasOwnProperty,MFe=function(e,t,n){return typeof t!="string"&&(n=t,t=void 0),FFe(n)(kFe(RFe(n).document().write(NFe()(e,t,!0))))};function FFe(e){const t={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:a(bn),autolinkProtocol:L,autolinkEmail:L,atxHeading:a(ke),blockQuote:a(Ee),characterEscape:L,characterReference:L,codeFenced:a(ge),codeFencedFenceInfo:u,codeFencedFenceMeta:u,codeIndented:a(ge,u),codeText:a(nt,u),codeTextData:L,data:L,codeFlowValue:L,definition:a(Je),definitionDestinationString:u,definitionLabelString:u,definitionTitleString:u,emphasis:a(yt),hardBreakEscape:a(at),hardBreakTrailing:a(at),htmlFlow:a(St,u),htmlFlowData:L,htmlText:a(St,u),htmlTextData:L,image:a(cn),label:u,link:a(bn),listItem:a(Fe),listItemValue:p,listOrdered:a(He,h),listUnordered:a(He),paragraph:a(st),reference:$,referenceString:u,resourceDestinationString:u,resourceTitleString:u,setextHeading:a(ke),strong:a(dt),thematicBreak:a(Kt)},exit:{atxHeading:c(),atxHeadingSequence:I,autolink:c(),autolinkEmail:ve,autolinkProtocol:de,blockQuote:c(),characterEscapeValue:B,characterReferenceMarkerHexadecimal:ce,characterReferenceMarkerNumeric:ce,characterReferenceValue:fe,codeFenced:c(v),codeFencedFence:g,codeFencedFenceInfo:m,codeFencedFenceMeta:y,codeFlowValue:B,codeIndented:c(b),codeText:c(ae),codeTextData:B,data:B,definition:c(),definitionDestinationString:E,definitionLabelString:S,definitionTitleString:T,emphasis:c(),hardBreakEscape:c(V),hardBreakTrailing:c(V),htmlFlow:c(re),htmlFlowData:B,htmlText:c(oe),htmlTextData:B,image:c(ue),label:W,labelText:P,lineEnding:J,link:c(ee),listItem:c(),listOrdered:c(),listUnordered:c(),paragraph:c(),referenceString:q,resourceDestinationString:Q,resourceTitleString:x,resource:O,setextHeading:c(F),setextHeadingLineSequence:R,setextHeadingText:A,strong:c(),thematicBreak:c()}};ore(t,(e||{}).mdastExtensions||[]);const n={};return r;function r(me){let Se={type:"root",children:[]};const Le={stack:[Se],tokenStack:[],config:t,enter:l,exit:f,buffer:u,resume:d,setData:s,getData:o},Ke=[];let ct=-1;for(;++ct0){const In=Le.tokenStack[Le.tokenStack.length-1];(In[1]||HV).call(Le,void 0,In[0])}for(Se.position={start:Ic(me.length>0?me[0][1].start:{line:1,column:1,offset:0}),end:Ic(me.length>0?me[me.length-2][1].end:{line:1,column:1,offset:0})},ct=-1;++ct{const r=this.data("settings");return MFe(n,Object.assign({},r,e,{extensions:this.data("micromarkExtensions")||[],mdastExtensions:this.data("fromMarkdownExtensions")||[]}))}})}function UFe(e,t){const n={type:"element",tagName:"blockquote",properties:{},children:e.wrap(e.all(t),!0)};return e.patch(t,n),e.applyData(t,n)}function VFe(e,t){const n={type:"element",tagName:"br",properties:{},children:[]};return e.patch(t,n),[e.applyData(t,n),{type:"text",value:` `}]}function zFe(e,t){const n=t.value?t.value+` `:"",r=t.lang?t.lang.match(/^[^ \t]+(?=[ \t]|$)/):null,i={};r&&(i.className=["language-"+r]);let s={type:"element",tagName:"code",properties:i,children:[{type:"text",value:n}]};return t.meta&&(s.data={meta:t.meta}),e.patch(t,s),s=e.applyData(t,s),s={type:"element",tagName:"pre",properties:{},children:[s]},e.patch(t,s),s}function HFe(e,t){const n={type:"element",tagName:"del",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function WFe(e,t){const n={type:"element",tagName:"em",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function xg(e){const t=[];let n=-1,r=0,i=0;for(;++n55295&&s<57344){const a=e.charCodeAt(n+1);s<56320&&a>56319&&a<57344?(o=String.fromCharCode(s,a),i=1):o="�"}else o=String.fromCharCode(s);o&&(t.push(e.slice(r,n),encodeURIComponent(o)),r=n+i+1,o=""),i&&(n+=i,i=0)}return t.join("")+e.slice(r)}function are(e,t){const n=String(t.identifier).toUpperCase(),r=xg(n.toLowerCase()),i=e.footnoteOrder.indexOf(n);let s;i===-1?(e.footnoteOrder.push(n),e.footnoteCounts[n]=1,s=e.footnoteOrder.length):(e.footnoteCounts[n]++,s=i+1);const o=e.footnoteCounts[n],a={type:"element",tagName:"a",properties:{href:"#"+e.clobberPrefix+"fn-"+r,id:e.clobberPrefix+"fnref-"+r+(o>1?"-"+o:""),dataFootnoteRef:!0,ariaDescribedBy:["footnote-label"]},children:[{type:"text",value:String(s)}]};e.patch(t,a);const u={type:"element",tagName:"sup",properties:{},children:[a]};return e.patch(t,u),e.applyData(t,u)}function qFe(e,t){const n=e.footnoteById;let r=1;for(;r in n;)r++;const i=String(r);return n[i]={type:"footnoteDefinition",identifier:i,children:[{type:"paragraph",children:t.children}],position:t.position},are(e,{type:"footnoteReference",identifier:i,position:t.position})}function GFe(e,t){const n={type:"element",tagName:"h"+t.depth,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function YFe(e,t){if(e.dangerous){const n={type:"raw",value:t.value};return e.patch(t,n),e.applyData(t,n)}return null}function ure(e,t){const n=t.referenceType;let r="]";if(n==="collapsed"?r+="[]":n==="full"&&(r+="["+(t.label||t.identifier)+"]"),t.type==="imageReference")return{type:"text",value:"!["+t.alt+r};const i=e.all(t),s=i[0];s&&s.type==="text"?s.value="["+s.value:i.unshift({type:"text",value:"["});const o=i[i.length-1];return o&&o.type==="text"?o.value+=r:i.push({type:"text",value:r}),i}function KFe(e,t){const n=e.definition(t.identifier);if(!n)return ure(e,t);const r={src:xg(n.url||""),alt:t.alt};n.title!==null&&n.title!==void 0&&(r.title=n.title);const i={type:"element",tagName:"img",properties:r,children:[]};return e.patch(t,i),e.applyData(t,i)}function QFe(e,t){const n={src:xg(t.url)};t.alt!==null&&t.alt!==void 0&&(n.alt=t.alt),t.title!==null&&t.title!==void 0&&(n.title=t.title);const r={type:"element",tagName:"img",properties:n,children:[]};return e.patch(t,r),e.applyData(t,r)}function XFe(e,t){const n={type:"text",value:t.value.replace(/\r?\n|\r/g," ")};e.patch(t,n);const r={type:"element",tagName:"code",properties:{},children:[n]};return e.patch(t,r),e.applyData(t,r)}function JFe(e,t){const n=e.definition(t.identifier);if(!n)return ure(e,t);const r={href:xg(n.url||"")};n.title!==null&&n.title!==void 0&&(r.title=n.title);const i={type:"element",tagName:"a",properties:r,children:e.all(t)};return e.patch(t,i),e.applyData(t,i)}function ZFe(e,t){const n={href:xg(t.url)};t.title!==null&&t.title!==void 0&&(n.title=t.title);const r={type:"element",tagName:"a",properties:n,children:e.all(t)};return e.patch(t,r),e.applyData(t,r)}function e8e(e,t,n){const r=e.all(t),i=n?t8e(n):lre(t),s={},o=[];if(typeof t.checked=="boolean"){const c=r[0];let f;c&&c.type==="element"&&c.tagName==="p"?f=c:(f={type:"element",tagName:"p",properties:{},children:[]},r.unshift(f)),f.children.length>0&&f.children.unshift({type:"text",value:" "}),f.children.unshift({type:"element",tagName:"input",properties:{type:"checkbox",checked:t.checked,disabled:!0},children:[]}),s.className=["task-list-item"]}let a=-1;for(;++a1}function n8e(e,t){const n={},r=e.all(t);let i=-1;for(typeof t.start=="number"&&t.start!==1&&(n.start=t.start);++i-1?r.offset:null}}}function a8e(e,t){const n=e.all(t),r=n.shift(),i=[];if(r){const o={type:"element",tagName:"thead",properties:{},children:e.wrap([r],!0)};e.patch(t.children[0],o),i.push(o)}if(n.length>0){const o={type:"element",tagName:"tbody",properties:{},children:e.wrap(n,!0)},a=s6(t.children[1]),u=o6(t.children[t.children.length-1]);a.line&&u.line&&(o.position={start:a,end:u}),i.push(o)}const s={type:"element",tagName:"table",properties:{},children:e.wrap(i,!0)};return e.patch(t,s),e.applyData(t,s)}function u8e(e,t,n){const r=n?n.children:void 0,s=(r?r.indexOf(t):1)===0?"th":"td",o=n&&n.type==="table"?n.align:void 0,a=o?o.length:t.children.length;let u=-1;const l=[];for(;++u0,!0),r[0]),i=r.index+r[0].length,r=n.exec(t);return s.push(YV(t.slice(i),i>0,!1)),s.join("")}function YV(e,t,n){let r=0,i=e.length;if(t){let s=e.codePointAt(r);for(;s===qV||s===GV;)r++,s=e.codePointAt(r)}if(n){let s=e.codePointAt(i-1);for(;s===qV||s===GV;)i--,s=e.codePointAt(i-1)}return i>r?e.slice(r,i):""}function f8e(e,t){const n={type:"text",value:c8e(String(t.value))};return e.patch(t,n),e.applyData(t,n)}function d8e(e,t){const n={type:"element",tagName:"hr",properties:{},children:[]};return e.patch(t,n),e.applyData(t,n)}const h8e={blockquote:UFe,break:VFe,code:zFe,delete:HFe,emphasis:WFe,footnoteReference:are,footnote:qFe,heading:GFe,html:YFe,imageReference:KFe,image:QFe,inlineCode:XFe,linkReference:JFe,link:ZFe,listItem:e8e,list:n8e,paragraph:r8e,root:i8e,strong:s8e,table:a8e,tableCell:l8e,tableRow:u8e,text:f8e,thematicBreak:d8e,toml:Ab,yaml:Ab,definition:Ab,footnoteDefinition:Ab};function Ab(){return null}const fre=function(e){if(e==null)return y8e;if(typeof e=="string")return g8e(e);if(typeof e=="object")return Array.isArray(e)?p8e(e):m8e(e);if(typeof e=="function")return dC(e);throw new Error("Expected function, string, or object as test")};function p8e(e){const t=[];let n=-1;for(;++n":""))+")"})}return f;function f(){let d=[],h,p,m;if((!t||i(a,u,l[l.length-1]||null))&&(d=w8e(n(a,l)),d[0]===KV))return d;if(a.children&&d[0]!==_8e)for(p=(r?a.children.length:-1)+s,m=l.concat(a);p>-1&&p{const i=XV(r.identifier);i&&!QV.call(t,i)&&(t[i]=r)}),n;function n(r){const i=XV(r);return i&&QV.call(t,i)?t[i]:null}}function XV(e){return String(e||"").toUpperCase()}const LT={}.hasOwnProperty;function T8e(e,t){const n=t||{},r=n.allowDangerousHtml||!1,i={};return o.dangerous=r,o.clobberPrefix=n.clobberPrefix===void 0||n.clobberPrefix===null?"user-content-":n.clobberPrefix,o.footnoteLabel=n.footnoteLabel||"Footnotes",o.footnoteLabelTagName=n.footnoteLabelTagName||"h2",o.footnoteLabelProperties=n.footnoteLabelProperties||{className:["sr-only"]},o.footnoteBackLabel=n.footnoteBackLabel||"Back to content",o.unknownHandler=n.unknownHandler,o.passThrough=n.passThrough,o.handlers={...h8e,...n.handlers},o.definition=S8e(e),o.footnoteById=i,o.footnoteOrder=[],o.footnoteCounts={},o.patch=I8e,o.applyData=x8e,o.one=a,o.all=u,o.wrap=A8e,o.augment=s,a6(e,"footnoteDefinition",l=>{const c=String(l.identifier).toUpperCase();LT.call(i,c)||(i[c]=l)}),o;function s(l,c){if(l&&"data"in l&&l.data){const f=l.data;f.hName&&(c.type!=="element"&&(c={type:"element",tagName:"",properties:{},children:[]}),c.tagName=f.hName),c.type==="element"&&f.hProperties&&(c.properties={...c.properties,...f.hProperties}),"children"in c&&c.children&&f.hChildren&&(c.children=f.hChildren)}if(l){const f="type"in l?l:{position:l};E8e(f)||(c.position={start:s6(f),end:o6(f)})}return c}function o(l,c,f,d){return Array.isArray(f)&&(d=f,f={}),s(l,{type:"element",tagName:c,properties:f||{},children:d||[]})}function a(l,c){return dre(o,l,c)}function u(l){return u6(o,l)}}function I8e(e,t){e.position&&(t.position=o8e(e))}function x8e(e,t){let n=t;if(e&&e.data){const r=e.data.hName,i=e.data.hChildren,s=e.data.hProperties;typeof r=="string"&&(n.type==="element"?n.tagName=r:n={type:"element",tagName:r,properties:{},children:[]}),n.type==="element"&&s&&(n.properties={...n.properties,...s}),"children"in n&&n.children&&i!==null&&i!==void 0&&(n.children=i)}return n}function dre(e,t,n){const r=t&&t.type;if(!r)throw new Error("Expected node, got `"+t+"`");return LT.call(e.handlers,r)?e.handlers[r](e,t,n):e.passThrough&&e.passThrough.includes(r)?"children"in t?{...t,children:u6(e,t)}:t:e.unknownHandler?e.unknownHandler(e,t,n):C8e(e,t)}function u6(e,t){const n=[];if("children"in t){const r=t.children;let i=-1;for(;++i1}function n8e(e,t){const n={},r=e.all(t);let i=-1;for(typeof t.start=="number"&&t.start!==1&&(n.start=t.start);++i-1?r.offset:null}}}function a8e(e,t){const n=e.all(t),r=n.shift(),i=[];if(r){const o={type:"element",tagName:"thead",properties:{},children:e.wrap([r],!0)};e.patch(t.children[0],o),i.push(o)}if(n.length>0){const o={type:"element",tagName:"tbody",properties:{},children:e.wrap(n,!0)},a=i6(t.children[1]),u=s6(t.children[t.children.length-1]);a.line&&u.line&&(o.position={start:a,end:u}),i.push(o)}const s={type:"element",tagName:"table",properties:{},children:e.wrap(i,!0)};return e.patch(t,s),e.applyData(t,s)}function u8e(e,t,n){const r=n?n.children:void 0,s=(r?r.indexOf(t):1)===0?"th":"td",o=n&&n.type==="table"?n.align:void 0,a=o?o.length:t.children.length;let u=-1;const l=[];for(;++u0,!0),r[0]),i=r.index+r[0].length,r=n.exec(t);return s.push(GV(t.slice(i),i>0,!1)),s.join("")}function GV(e,t,n){let r=0,i=e.length;if(t){let s=e.codePointAt(r);for(;s===WV||s===qV;)r++,s=e.codePointAt(r)}if(n){let s=e.codePointAt(i-1);for(;s===WV||s===qV;)i--,s=e.codePointAt(i-1)}return i>r?e.slice(r,i):""}function f8e(e,t){const n={type:"text",value:c8e(String(t.value))};return e.patch(t,n),e.applyData(t,n)}function d8e(e,t){const n={type:"element",tagName:"hr",properties:{},children:[]};return e.patch(t,n),e.applyData(t,n)}const h8e={blockquote:UFe,break:VFe,code:zFe,delete:HFe,emphasis:WFe,footnoteReference:are,footnote:qFe,heading:GFe,html:YFe,imageReference:KFe,image:QFe,inlineCode:XFe,linkReference:JFe,link:ZFe,listItem:e8e,list:n8e,paragraph:r8e,root:i8e,strong:s8e,table:a8e,tableCell:l8e,tableRow:u8e,text:f8e,thematicBreak:d8e,toml:Ab,yaml:Ab,definition:Ab,footnoteDefinition:Ab};function Ab(){return null}const fre=function(e){if(e==null)return y8e;if(typeof e=="string")return g8e(e);if(typeof e=="object")return Array.isArray(e)?p8e(e):m8e(e);if(typeof e=="function")return dC(e);throw new Error("Expected function, string, or object as test")};function p8e(e){const t=[];let n=-1;for(;++n":""))+")"})}return f;function f(){let d=[],h,p,m;if((!t||i(a,u,l[l.length-1]||null))&&(d=w8e(n(a,l)),d[0]===YV))return d;if(a.children&&d[0]!==_8e)for(p=(r?a.children.length:-1)+s,m=l.concat(a);p>-1&&p{const i=QV(r.identifier);i&&!KV.call(t,i)&&(t[i]=r)}),n;function n(r){const i=QV(r);return i&&KV.call(t,i)?t[i]:null}}function QV(e){return String(e||"").toUpperCase()}const LT={}.hasOwnProperty;function T8e(e,t){const n=t||{},r=n.allowDangerousHtml||!1,i={};return o.dangerous=r,o.clobberPrefix=n.clobberPrefix===void 0||n.clobberPrefix===null?"user-content-":n.clobberPrefix,o.footnoteLabel=n.footnoteLabel||"Footnotes",o.footnoteLabelTagName=n.footnoteLabelTagName||"h2",o.footnoteLabelProperties=n.footnoteLabelProperties||{className:["sr-only"]},o.footnoteBackLabel=n.footnoteBackLabel||"Back to content",o.unknownHandler=n.unknownHandler,o.passThrough=n.passThrough,o.handlers={...h8e,...n.handlers},o.definition=S8e(e),o.footnoteById=i,o.footnoteOrder=[],o.footnoteCounts={},o.patch=I8e,o.applyData=x8e,o.one=a,o.all=u,o.wrap=A8e,o.augment=s,o6(e,"footnoteDefinition",l=>{const c=String(l.identifier).toUpperCase();LT.call(i,c)||(i[c]=l)}),o;function s(l,c){if(l&&"data"in l&&l.data){const f=l.data;f.hName&&(c.type!=="element"&&(c={type:"element",tagName:"",properties:{},children:[]}),c.tagName=f.hName),c.type==="element"&&f.hProperties&&(c.properties={...c.properties,...f.hProperties}),"children"in c&&c.children&&f.hChildren&&(c.children=f.hChildren)}if(l){const f="type"in l?l:{position:l};E8e(f)||(c.position={start:i6(f),end:s6(f)})}return c}function o(l,c,f,d){return Array.isArray(f)&&(d=f,f={}),s(l,{type:"element",tagName:c,properties:f||{},children:d||[]})}function a(l,c){return dre(o,l,c)}function u(l){return a6(o,l)}}function I8e(e,t){e.position&&(t.position=o8e(e))}function x8e(e,t){let n=t;if(e&&e.data){const r=e.data.hName,i=e.data.hChildren,s=e.data.hProperties;typeof r=="string"&&(n.type==="element"?n.tagName=r:n={type:"element",tagName:r,properties:{},children:[]}),n.type==="element"&&s&&(n.properties={...n.properties,...s}),"children"in n&&n.children&&i!==null&&i!==void 0&&(n.children=i)}return n}function dre(e,t,n){const r=t&&t.type;if(!r)throw new Error("Expected node, got `"+t+"`");return LT.call(e.handlers,r)?e.handlers[r](e,t,n):e.passThrough&&e.passThrough.includes(r)?"children"in t?{...t,children:a6(e,t)}:t:e.unknownHandler?e.unknownHandler(e,t,n):C8e(e,t)}function a6(e,t){const n=[];if("children"in t){const r=t.children;let i=-1;for(;++i0&&n.push({type:"text",value:` `}),n}function P8e(e){const t=[];let n=-1;for(;++n1?"-"+a:""),dataFootnoteBackref:!0,className:["data-footnote-backref"],ariaLabel:e.footnoteBackLabel},children:[{type:"text",value:"↩"}]};a>1&&f.children.push({type:"element",tagName:"sup",children:[{type:"text",value:String(a)}]}),u.length>0&&u.push({type:"text",value:" "}),u.push(f)}const l=i[i.length-1];if(l&&l.type==="element"&&l.tagName==="p"){const f=l.children[l.children.length-1];f&&f.type==="text"?f.value+=" ":l.children.push({type:"text",value:" "}),l.children.push(...u)}else i.push(...u);const c={type:"element",tagName:"li",properties:{id:e.clobberPrefix+"fn-"+o},children:e.wrap(i,!0)};e.patch(r,c),t.push(c)}if(t.length!==0)return{type:"element",tagName:"section",properties:{dataFootnotes:!0,className:["footnotes"]},children:[{type:"element",tagName:e.footnoteLabelTagName,properties:{...JSON.parse(JSON.stringify(e.footnoteLabelProperties)),id:"footnote-label"},children:[{type:"text",value:e.footnoteLabel}]},{type:"text",value:` `},{type:"element",tagName:"ol",properties:{},children:e.wrap(t,!0)},{type:"text",value:` `}]}}function hre(e,t){const n=T8e(e,t),r=n.one(e,null),i=P8e(n);return i&&r.children.push({type:"text",value:` -`},i),Array.isArray(r)?{type:"root",children:r}:r}const O8e=function(e,t){return e&&"run"in e?N8e(e,t):k8e(e||t)},R8e=O8e;function N8e(e,t){return(n,r,i)=>{e.run(hre(n,t),r,s=>{i(s)})}}function k8e(e){return t=>hre(t,e)}var pre={exports:{}},D8e="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED",$8e=D8e,L8e=$8e;function mre(){}function gre(){}gre.resetWarningCache=mre;var M8e=function(){function e(r,i,s,o,a,u){if(u!==L8e){var l=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw l.name="Invariant Violation",l}}e.isRequired=e;function t(){return e}var n={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:gre,resetWarningCache:mre};return n.PropTypes=n,n};pre.exports=M8e();var F8e=pre.exports;const gt=eu(F8e);let X_=class{constructor(t,n,r){this.property=t,this.normal=n,r&&(this.space=r)}};X_.prototype.property={};X_.prototype.normal={};X_.prototype.space=null;function yre(e,t){const n={},r={};let i=-1;for(;++i4&&n.slice(0,4)==="data"&&z8e.test(t)){if(t.charAt(4)==="-"){const s=t.slice(5).replace(ZV,q8e);r="data"+s.charAt(0).toUpperCase()+s.slice(1)}else{const s=t.slice(4);if(!ZV.test(s)){let o=s.replace(H8e,W8e);o.charAt(0)!=="-"&&(o="-"+o),t="data"+o}}i=l6}return new i(r,t)}function W8e(e){return"-"+e.toLowerCase()}function q8e(e){return e.charAt(1).toUpperCase()}const e7={classId:"classID",dataType:"datatype",itemId:"itemID",strokeDashArray:"strokeDasharray",strokeDashOffset:"strokeDashoffset",strokeLineCap:"strokeLinecap",strokeLineJoin:"strokeLinejoin",strokeMiterLimit:"strokeMiterlimit",typeOf:"typeof",xLinkActuate:"xlinkActuate",xLinkArcRole:"xlinkArcrole",xLinkHref:"xlinkHref",xLinkRole:"xlinkRole",xLinkShow:"xlinkShow",xLinkTitle:"xlinkTitle",xLinkType:"xlinkType",xmlnsXLink:"xmlnsXlink"},J_=yre([bre,_re,Sre,Tre,U8e],"html"),Ag=yre([bre,_re,Sre,Tre,V8e],"svg");function G8e(e){if(e.allowedElements&&e.disallowedElements)throw new TypeError("Only one of `allowedElements` and `disallowedElements` should be defined");if(e.allowedElements||e.disallowedElements||e.allowElement)return t=>{a6(t,"element",(n,r,i)=>{const s=i;let o;if(e.allowedElements?o=!e.allowedElements.includes(n.tagName):e.disallowedElements&&(o=e.disallowedElements.includes(n.tagName)),!o&&e.allowElement&&typeof r=="number"&&(o=!e.allowElement(n,r,s)),o&&typeof r=="number")return e.unwrapDisallowed&&n.children?s.children.splice(r,1,...n.children):s.children.splice(r,1),r})}}var Ire={exports:{}},Un={};/** +`},i),Array.isArray(r)?{type:"root",children:r}:r}const O8e=function(e,t){return e&&"run"in e?N8e(e,t):k8e(e||t)},R8e=O8e;function N8e(e,t){return(n,r,i)=>{e.run(hre(n,t),r,s=>{i(s)})}}function k8e(e){return t=>hre(t,e)}var pre={exports:{}},D8e="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED",$8e=D8e,L8e=$8e;function mre(){}function gre(){}gre.resetWarningCache=mre;var M8e=function(){function e(r,i,s,o,a,u){if(u!==L8e){var l=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw l.name="Invariant Violation",l}}e.isRequired=e;function t(){return e}var n={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:gre,resetWarningCache:mre};return n.PropTypes=n,n};pre.exports=M8e();var F8e=pre.exports;const gt=eu(F8e);let X_=class{constructor(t,n,r){this.property=t,this.normal=n,r&&(this.space=r)}};X_.prototype.property={};X_.prototype.normal={};X_.prototype.space=null;function yre(e,t){const n={},r={};let i=-1;for(;++i4&&n.slice(0,4)==="data"&&z8e.test(t)){if(t.charAt(4)==="-"){const s=t.slice(5).replace(JV,q8e);r="data"+s.charAt(0).toUpperCase()+s.slice(1)}else{const s=t.slice(4);if(!JV.test(s)){let o=s.replace(H8e,W8e);o.charAt(0)!=="-"&&(o="-"+o),t="data"+o}}i=u6}return new i(r,t)}function W8e(e){return"-"+e.toLowerCase()}function q8e(e){return e.charAt(1).toUpperCase()}const ZV={classId:"classID",dataType:"datatype",itemId:"itemID",strokeDashArray:"strokeDasharray",strokeDashOffset:"strokeDashoffset",strokeLineCap:"strokeLinecap",strokeLineJoin:"strokeLinejoin",strokeMiterLimit:"strokeMiterlimit",typeOf:"typeof",xLinkActuate:"xlinkActuate",xLinkArcRole:"xlinkArcrole",xLinkHref:"xlinkHref",xLinkRole:"xlinkRole",xLinkShow:"xlinkShow",xLinkTitle:"xlinkTitle",xLinkType:"xlinkType",xmlnsXLink:"xmlnsXlink"},J_=yre([bre,_re,Sre,Tre,U8e],"html"),Ag=yre([bre,_re,Sre,Tre,V8e],"svg");function G8e(e){if(e.allowedElements&&e.disallowedElements)throw new TypeError("Only one of `allowedElements` and `disallowedElements` should be defined");if(e.allowedElements||e.disallowedElements||e.allowElement)return t=>{o6(t,"element",(n,r,i)=>{const s=i;let o;if(e.allowedElements?o=!e.allowedElements.includes(n.tagName):e.disallowedElements&&(o=e.disallowedElements.includes(n.tagName)),!o&&e.allowElement&&typeof r=="number"&&(o=!e.allowElement(n,r,s)),o&&typeof r=="number")return e.unwrapDisallowed&&n.children?s.children.splice(r,1,...n.children):s.children.splice(r,1),r})}}var Ire={exports:{}},Un={};/** * @license React * react-is.production.min.js * @@ -185,46 +185,46 @@ Error generating stack: `+s.message+` * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var c6=Symbol.for("react.element"),f6=Symbol.for("react.portal"),pC=Symbol.for("react.fragment"),mC=Symbol.for("react.strict_mode"),gC=Symbol.for("react.profiler"),yC=Symbol.for("react.provider"),vC=Symbol.for("react.context"),Y8e=Symbol.for("react.server_context"),_C=Symbol.for("react.forward_ref"),bC=Symbol.for("react.suspense"),wC=Symbol.for("react.suspense_list"),EC=Symbol.for("react.memo"),SC=Symbol.for("react.lazy"),K8e=Symbol.for("react.offscreen"),xre;xre=Symbol.for("react.module.reference");function ya(e){if(typeof e=="object"&&e!==null){var t=e.$$typeof;switch(t){case c6:switch(e=e.type,e){case pC:case gC:case mC:case bC:case wC:return e;default:switch(e=e&&e.$$typeof,e){case Y8e:case vC:case _C:case SC:case EC:case yC:return e;default:return t}}case f6:return t}}}Un.ContextConsumer=vC;Un.ContextProvider=yC;Un.Element=c6;Un.ForwardRef=_C;Un.Fragment=pC;Un.Lazy=SC;Un.Memo=EC;Un.Portal=f6;Un.Profiler=gC;Un.StrictMode=mC;Un.Suspense=bC;Un.SuspenseList=wC;Un.isAsyncMode=function(){return!1};Un.isConcurrentMode=function(){return!1};Un.isContextConsumer=function(e){return ya(e)===vC};Un.isContextProvider=function(e){return ya(e)===yC};Un.isElement=function(e){return typeof e=="object"&&e!==null&&e.$$typeof===c6};Un.isForwardRef=function(e){return ya(e)===_C};Un.isFragment=function(e){return ya(e)===pC};Un.isLazy=function(e){return ya(e)===SC};Un.isMemo=function(e){return ya(e)===EC};Un.isPortal=function(e){return ya(e)===f6};Un.isProfiler=function(e){return ya(e)===gC};Un.isStrictMode=function(e){return ya(e)===mC};Un.isSuspense=function(e){return ya(e)===bC};Un.isSuspenseList=function(e){return ya(e)===wC};Un.isValidElementType=function(e){return typeof e=="string"||typeof e=="function"||e===pC||e===gC||e===mC||e===bC||e===wC||e===K8e||typeof e=="object"&&e!==null&&(e.$$typeof===SC||e.$$typeof===EC||e.$$typeof===yC||e.$$typeof===vC||e.$$typeof===_C||e.$$typeof===xre||e.getModuleId!==void 0)};Un.typeOf=ya;Ire.exports=Un;var Q8e=Ire.exports;const X8e=eu(Q8e);function J8e(e){const t=e&&typeof e=="object"&&e.type==="text"?e.value||"":e;return typeof t=="string"&&t.replace(/[ \t\n\f\r]/g,"")===""}function t7(e){const t=String(e||"").trim();return t?t.split(/[ \t\n\r\f]+/g):[]}function Cre(e){return e.join(" ").trim()}function n7(e){const t=[],n=String(e||"");let r=n.indexOf(","),i=0,s=!1;for(;!s;){r===-1&&(r=n.length,s=!0);const o=n.slice(i,r).trim();(o||!s)&&t.push(o),i=r+1,r=n.indexOf(",",i)}return t}function Are(e,t){const n=t||{};return(e[e.length-1]===""?[...e,""]:e).join((n.padRight?" ":"")+","+(n.padLeft===!1?"":" ")).trim()}var d6={exports:{}},r7=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,Z8e=/\n/g,e9e=/^\s*/,t9e=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,n9e=/^:\s*/,r9e=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,i9e=/^[;\s]*/,s9e=/^\s+|\s+$/g,o9e=` -`,i7="/",s7="*",xd="",a9e="comment",u9e="declaration",l9e=function(e,t){if(typeof e!="string")throw new TypeError("First argument must be a string");if(!e)return[];t=t||{};var n=1,r=1;function i(p){var m=p.match(Z8e);m&&(n+=m.length);var y=p.lastIndexOf(o9e);r=~y?p.length-y:r+p.length}function s(){var p={line:n,column:r};return function(m){return m.position=new o(p),l(),m}}function o(p){this.start=p,this.end={line:n,column:r},this.source=t.source}o.prototype.content=e;function a(p){var m=new Error(t.source+":"+n+":"+r+": "+p);if(m.reason=p,m.filename=t.source,m.line=n,m.column=r,m.source=e,!t.silent)throw m}function u(p){var m=p.exec(e);if(m){var y=m[0];return i(y),e=e.slice(y.length),m}}function l(){u(e9e)}function c(p){var m;for(p=p||[];m=f();)m!==!1&&p.push(m);return p}function f(){var p=s();if(!(i7!=e.charAt(0)||s7!=e.charAt(1))){for(var m=2;xd!=e.charAt(m)&&(s7!=e.charAt(m)||i7!=e.charAt(m+1));)++m;if(m+=2,xd===e.charAt(m-1))return a("End of comment missing");var y=e.slice(2,m-2);return r+=2,i(y),e=e.slice(m),r+=2,p({type:a9e,comment:y})}}function d(){var p=s(),m=u(t9e);if(m){if(f(),!u(n9e))return a("property missing ':'");var y=u(r9e),g=p({type:u9e,property:o7(m[0].replace(r7,xd)),value:y?o7(y[0].replace(r7,xd)):xd});return u(i9e),g}}function h(){var p=[];c(p);for(var m;m=d();)m!==!1&&(p.push(m),c(p));return p}return l(),h()};function o7(e){return e?e.replace(s9e,xd):xd}var c9e=l9e;function Pre(e,t){var n=null;if(!e||typeof e!="string")return n;for(var r,i=c9e(e),s=typeof t=="function",o,a,u=0,l=i.length;u0?N.createElement(h,u,f):N.createElement(h,u)}function m9e(e){let t=-1;for(;++t for more info)`),delete Pb[s]}const t=R4e().use(jFe).use(e.remarkPlugins||[]).use(R8e,{...e.remarkRehypeOptions,allowDangerousHtml:!0}).use(e.rehypePlugins||[]).use(G8e,e),n=new p4e;typeof e.children=="string"?n.value=e.children:e.children!==void 0&&e.children!==null&&console.warn(`[react-markdown] Warning: please pass a string as \`children\` (not: \`${e.children}\`)`);const r=t.runSync(t.parse(n),n);if(r.type!=="root")throw new TypeError("Expected a `root` node");let i=N.createElement(N.Fragment,{},Ore({options:e,schema:J_,listDepth:0},r));return e.className&&(i=N.createElement("div",{className:e.className},i)),i}Rre.propTypes={children:gt.string,className:gt.string,allowElement:gt.func,allowedElements:gt.arrayOf(gt.string),disallowedElements:gt.arrayOf(gt.string),unwrapDisallowed:gt.bool,remarkPlugins:gt.arrayOf(gt.oneOfType([gt.object,gt.func,gt.arrayOf(gt.oneOfType([gt.bool,gt.string,gt.object,gt.func,gt.arrayOf(gt.any)]))])),rehypePlugins:gt.arrayOf(gt.oneOfType([gt.object,gt.func,gt.arrayOf(gt.oneOfType([gt.bool,gt.string,gt.object,gt.func,gt.arrayOf(gt.any)]))])),sourcePos:gt.bool,rawSourcePos:gt.bool,skipHtml:gt.bool,includeElementIndex:gt.bool,transformLinkUri:gt.oneOfType([gt.func,gt.bool]),linkTarget:gt.oneOfType([gt.func,gt.string]),transformImageUri:gt.func,components:gt.object};const Nre=-1,TC=0,MT=1,FT=2,h6=3,p6=4,m6=5,g6=6,kre=7,Dre=8,u7=typeof self=="object"?self:globalThis,w9e=(e,t)=>{const n=(i,s)=>(e.set(s,i),i),r=i=>{if(e.has(i))return e.get(i);const[s,o]=t[i];switch(s){case TC:case Nre:return n(o,i);case MT:{const a=n([],i);for(const u of o)a.push(r(u));return a}case FT:{const a=n({},i);for(const[u,l]of o)a[r(u)]=r(l);return a}case h6:return n(new Date(o),i);case p6:{const{source:a,flags:u}=o;return n(new RegExp(a,u),i)}case m6:{const a=n(new Map,i);for(const[u,l]of o)a.set(r(u),r(l));return a}case g6:{const a=n(new Set,i);for(const u of o)a.add(r(u));return a}case kre:{const{name:a,message:u}=o;return n(new u7[a](u),i)}case Dre:return n(BigInt(o),i);case"BigInt":return n(Object(BigInt(o)),i)}return n(new u7[s](o),i)};return r},l7=e=>w9e(new Map,e)(0),np="",{toString:E9e}={},{keys:S9e}=Object,S0=e=>{const t=typeof e;if(t!=="object"||!e)return[TC,t];const n=E9e.call(e).slice(8,-1);switch(n){case"Array":return[MT,np];case"Object":return[FT,np];case"Date":return[h6,np];case"RegExp":return[p6,np];case"Map":return[m6,np];case"Set":return[g6,np]}return n.includes("Array")?[MT,n]:n.includes("Error")?[kre,n]:[FT,n]},Ob=([e,t])=>e===TC&&(t==="function"||t==="symbol"),T9e=(e,t,n,r)=>{const i=(o,a)=>{const u=r.push(o)-1;return n.set(a,u),u},s=o=>{if(n.has(o))return n.get(o);let[a,u]=S0(o);switch(a){case TC:{let c=o;switch(u){case"bigint":a=Dre,c=o.toString();break;case"function":case"symbol":if(e)throw new TypeError("unable to serialize "+u);c=null;break;case"undefined":return i([Nre],o)}return i([a,c],o)}case MT:{if(u)return i([u,[...o]],o);const c=[],f=i([a,c],o);for(const d of o)c.push(s(d));return f}case FT:{if(u)switch(u){case"BigInt":return i([u,o.toString()],o);case"Boolean":case"Number":case"String":return i([u,o.valueOf()],o)}if(t&&"toJSON"in o)return s(o.toJSON());const c=[],f=i([a,c],o);for(const d of S9e(o))(e||!Ob(S0(o[d])))&&c.push([s(d),s(o[d])]);return f}case h6:return i([a,o.toISOString()],o);case p6:{const{source:c,flags:f}=o;return i([a,{source:c,flags:f}],o)}case m6:{const c=[],f=i([a,c],o);for(const[d,h]of o)(e||!(Ob(S0(d))||Ob(S0(h))))&&c.push([s(d),s(h)]);return f}case g6:{const c=[],f=i([a,c],o);for(const d of o)(e||!Ob(S0(d)))&&c.push(s(d));return f}}const{message:l}=o;return i([a,{name:u,message:l}],o)};return s},c7=(e,{json:t,lossy:n}={})=>{const r=[];return T9e(!(t||n),!!t,new Map,r)(e),r},f7=typeof structuredClone=="function"?(e,t)=>t&&("json"in t||"lossy"in t)?l7(c7(e,t)):structuredClone(e):(e,t)=>l7(c7(e,t));const d7=/[#.]/g;function I9e(e,t){const n=e||"",r={};let i=0,s,o;for(;i-1&&ss)return{line:o+1,column:s-(o>0?n[o-1]:0)+1,offset:s}}}function i(s){const o=s&&s.line,a=s&&s.column;if(typeof o=="number"&&typeof a=="number"&&!Number.isNaN(o)&&!Number.isNaN(a)&&o-1 in n){const u=(n[o-2]||0)+a-1||0;if(u>-1&&u=55296&&e<=57343}function X9e(e){return e>=56320&&e<=57343}function J9e(e,t){return(e-55296)*1024+9216+t}function Ure(e){return e!==32&&e!==10&&e!==13&&e!==9&&e!==12&&e>=1&&e<=31||e>=127&&e<=159}function Vre(e){return e>=64976&&e<=65007||Q9e.has(e)}var _e;(function(e){e.controlCharacterInInputStream="control-character-in-input-stream",e.noncharacterInInputStream="noncharacter-in-input-stream",e.surrogateInInputStream="surrogate-in-input-stream",e.nonVoidHtmlElementStartTagWithTrailingSolidus="non-void-html-element-start-tag-with-trailing-solidus",e.endTagWithAttributes="end-tag-with-attributes",e.endTagWithTrailingSolidus="end-tag-with-trailing-solidus",e.unexpectedSolidusInTag="unexpected-solidus-in-tag",e.unexpectedNullCharacter="unexpected-null-character",e.unexpectedQuestionMarkInsteadOfTagName="unexpected-question-mark-instead-of-tag-name",e.invalidFirstCharacterOfTagName="invalid-first-character-of-tag-name",e.unexpectedEqualsSignBeforeAttributeName="unexpected-equals-sign-before-attribute-name",e.missingEndTagName="missing-end-tag-name",e.unexpectedCharacterInAttributeName="unexpected-character-in-attribute-name",e.unknownNamedCharacterReference="unknown-named-character-reference",e.missingSemicolonAfterCharacterReference="missing-semicolon-after-character-reference",e.unexpectedCharacterAfterDoctypeSystemIdentifier="unexpected-character-after-doctype-system-identifier",e.unexpectedCharacterInUnquotedAttributeValue="unexpected-character-in-unquoted-attribute-value",e.eofBeforeTagName="eof-before-tag-name",e.eofInTag="eof-in-tag",e.missingAttributeValue="missing-attribute-value",e.missingWhitespaceBetweenAttributes="missing-whitespace-between-attributes",e.missingWhitespaceAfterDoctypePublicKeyword="missing-whitespace-after-doctype-public-keyword",e.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers="missing-whitespace-between-doctype-public-and-system-identifiers",e.missingWhitespaceAfterDoctypeSystemKeyword="missing-whitespace-after-doctype-system-keyword",e.missingQuoteBeforeDoctypePublicIdentifier="missing-quote-before-doctype-public-identifier",e.missingQuoteBeforeDoctypeSystemIdentifier="missing-quote-before-doctype-system-identifier",e.missingDoctypePublicIdentifier="missing-doctype-public-identifier",e.missingDoctypeSystemIdentifier="missing-doctype-system-identifier",e.abruptDoctypePublicIdentifier="abrupt-doctype-public-identifier",e.abruptDoctypeSystemIdentifier="abrupt-doctype-system-identifier",e.cdataInHtmlContent="cdata-in-html-content",e.incorrectlyOpenedComment="incorrectly-opened-comment",e.eofInScriptHtmlCommentLikeText="eof-in-script-html-comment-like-text",e.eofInDoctype="eof-in-doctype",e.nestedComment="nested-comment",e.abruptClosingOfEmptyComment="abrupt-closing-of-empty-comment",e.eofInComment="eof-in-comment",e.incorrectlyClosedComment="incorrectly-closed-comment",e.eofInCdata="eof-in-cdata",e.absenceOfDigitsInNumericCharacterReference="absence-of-digits-in-numeric-character-reference",e.nullCharacterReference="null-character-reference",e.surrogateCharacterReference="surrogate-character-reference",e.characterReferenceOutsideUnicodeRange="character-reference-outside-unicode-range",e.controlCharacterReference="control-character-reference",e.noncharacterCharacterReference="noncharacter-character-reference",e.missingWhitespaceBeforeDoctypeName="missing-whitespace-before-doctype-name",e.missingDoctypeName="missing-doctype-name",e.invalidCharacterSequenceAfterDoctypeName="invalid-character-sequence-after-doctype-name",e.duplicateAttribute="duplicate-attribute",e.nonConformingDoctype="non-conforming-doctype",e.missingDoctype="missing-doctype",e.misplacedDoctype="misplaced-doctype",e.endTagWithoutMatchingOpenElement="end-tag-without-matching-open-element",e.closingOfElementWithOpenChildElements="closing-of-element-with-open-child-elements",e.disallowedContentInNoscriptInHead="disallowed-content-in-noscript-in-head",e.openElementsLeftAfterEof="open-elements-left-after-eof",e.abandonedHeadElementChild="abandoned-head-element-child",e.misplacedStartTagForHeadElement="misplaced-start-tag-for-head-element",e.nestedNoscriptInHead="nested-noscript-in-head",e.eofInElementThatCanContainOnlyText="eof-in-element-that-can-contain-only-text"})(_e=_e||(_e={}));const Z9e=65536;class eBe{constructor(t){this.handler=t,this.html="",this.pos=-1,this.lastGapPos=-2,this.gapStack=[],this.skipNextNewLine=!1,this.lastChunkWritten=!1,this.endOfChunkHit=!1,this.bufferWaterline=Z9e,this.isEol=!1,this.lineStartPos=0,this.droppedBufferSize=0,this.line=1,this.lastErrOffset=-1}get col(){return this.pos-this.lineStartPos+ +(this.lastGapPos!==this.pos)}get offset(){return this.droppedBufferSize+this.pos}getError(t){const{line:n,col:r,offset:i}=this;return{code:t,startLine:n,endLine:n,startCol:r,endCol:r,startOffset:i,endOffset:i}}_err(t){this.handler.onParseError&&this.lastErrOffset!==this.offset&&(this.lastErrOffset=this.offset,this.handler.onParseError(this.getError(t)))}_addGap(){this.gapStack.push(this.lastGapPos),this.lastGapPos=this.pos}_processSurrogate(t){if(this.pos!==this.html.length-1){const n=this.html.charCodeAt(this.pos+1);if(X9e(n))return this.pos++,this._addGap(),J9e(t,n)}else if(!this.lastChunkWritten)return this.endOfChunkHit=!0,M.EOF;return this._err(_e.surrogateInInputStream),t}willDropParsedChunk(){return this.pos>this.bufferWaterline}dropParsedChunk(){this.willDropParsedChunk()&&(this.html=this.html.substring(this.pos),this.lineStartPos-=this.pos,this.droppedBufferSize+=this.pos,this.pos=0,this.lastGapPos=-2,this.gapStack.length=0)}write(t,n){this.html.length>0?this.html+=t:this.html=t,this.endOfChunkHit=!1,this.lastChunkWritten=n}insertHtmlAtCurrentPos(t){this.html=this.html.substring(0,this.pos+1)+t+this.html.substring(this.pos+1),this.endOfChunkHit=!1}startsWith(t,n){if(this.pos+t.length>this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,!1;if(n)return this.html.startsWith(t,this.pos);for(let r=0;r=this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,M.EOF;const r=this.html.charCodeAt(n);return r===M.CARRIAGE_RETURN?M.LINE_FEED:r}advance(){if(this.pos++,this.isEol&&(this.isEol=!1,this.line++,this.lineStartPos=this.pos),this.pos>=this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,M.EOF;let t=this.html.charCodeAt(this.pos);return t===M.CARRIAGE_RETURN?(this.isEol=!0,this.skipNextNewLine=!0,M.LINE_FEED):t===M.LINE_FEED&&(this.isEol=!0,this.skipNextNewLine)?(this.line--,this.skipNextNewLine=!1,this._addGap(),this.advance()):(this.skipNextNewLine=!1,jre(t)&&(t=this._processSurrogate(t)),this.handler.onParseError===null||t>31&&t<127||t===M.LINE_FEED||t===M.CARRIAGE_RETURN||t>159&&t<64976||this._checkForProblematicCharacters(t),t)}_checkForProblematicCharacters(t){Ure(t)?this._err(_e.controlCharacterInInputStream):Vre(t)&&this._err(_e.noncharacterInInputStream)}retreat(t){for(this.pos-=t;this.pos=0;n--)if(e.attrs[n].name===t)return e.attrs[n].value;return null}const Oc=new Uint16Array('ᵁ<Õıʊҝջאٵ۞ޢߖࠏ੊ઑඡ๭༉༦჊ረዡᐕᒝᓃᓟᔥ\0\0\0\0\0\0ᕫᛍᦍᰒᷝ὾⁠↰⊍⏀⏻⑂⠤⤒ⴈ⹈⿎〖㊺㘹㞬㣾㨨㩱㫠㬮ࠀEMabcfglmnoprstu\\bfms„‹•˜¦³¹ÈÏlig耻Æ䃆P耻&䀦cute耻Á䃁reve;䄂Āiyx}rc耻Â䃂;䐐r;쀀𝔄rave耻À䃀pha;䎑acr;䄀d;橓Āgp¡on;䄄f;쀀𝔸plyFunction;恡ing耻Å䃅Ācs¾Ãr;쀀𝒜ign;扔ilde耻Ã䃃ml耻Ä䃄ЀaceforsuåûþėĜĢħĪĀcrêòkslash;或Ŷöø;櫧ed;挆y;䐑ƀcrtąċĔause;戵noullis;愬a;䎒r;쀀𝔅pf;쀀𝔹eve;䋘còēmpeq;扎܀HOacdefhilorsuōőŖƀƞƢƵƷƺǜȕɳɸɾcy;䐧PY耻©䂩ƀcpyŝŢźute;䄆Ā;iŧŨ拒talDifferentialD;慅leys;愭ȀaeioƉƎƔƘron;䄌dil耻Ç䃇rc;䄈nint;戰ot;䄊ĀdnƧƭilla;䂸terDot;䂷òſi;䎧rcleȀDMPTLJNjǑǖot;抙inus;抖lus;投imes;抗oĀcsǢǸkwiseContourIntegral;戲eCurlyĀDQȃȏoubleQuote;思uote;怙ȀlnpuȞȨɇɕonĀ;eȥȦ户;橴ƀgitȯȶȺruent;扡nt;戯ourIntegral;戮ĀfrɌɎ;愂oduct;成nterClockwiseContourIntegral;戳oss;樯cr;쀀𝒞pĀ;Cʄʅ拓ap;才րDJSZacefiosʠʬʰʴʸˋ˗ˡ˦̳ҍĀ;oŹʥtrahd;椑cy;䐂cy;䐅cy;䐏ƀgrsʿ˄ˇger;怡r;憡hv;櫤Āayː˕ron;䄎;䐔lĀ;t˝˞戇a;䎔r;쀀𝔇Āaf˫̧Ācm˰̢riticalȀADGT̖̜̀̆cute;䂴oŴ̋̍;䋙bleAcute;䋝rave;䁠ilde;䋜ond;拄ferentialD;慆Ѱ̽\0\0\0͔͂\0Ѕf;쀀𝔻ƀ;DE͈͉͍䂨ot;惜qual;扐blèCDLRUVͣͲ΂ϏϢϸontourIntegraìȹoɴ͹\0\0ͻ»͉nArrow;懓Āeo·ΤftƀARTΐΖΡrrow;懐ightArrow;懔eåˊngĀLRΫτeftĀARγιrrow;柸ightArrow;柺ightArrow;柹ightĀATϘϞrrow;懒ee;抨pɁϩ\0\0ϯrrow;懑ownArrow;懕erticalBar;戥ǹABLRTaВЪаўѿͼrrowƀ;BUНОТ憓ar;椓pArrow;懵reve;䌑eft˒к\0ц\0ѐightVector;楐eeVector;楞ectorĀ;Bљњ憽ar;楖ightǔѧ\0ѱeeVector;楟ectorĀ;BѺѻ懁ar;楗eeĀ;A҆҇护rrow;憧ĀctҒҗr;쀀𝒟rok;䄐ࠀNTacdfglmopqstuxҽӀӄӋӞӢӧӮӵԡԯԶՒ՝ՠեG;䅊H耻Ð䃐cute耻É䃉ƀaiyӒӗӜron;䄚rc耻Ê䃊;䐭ot;䄖r;쀀𝔈rave耻È䃈ement;戈ĀapӺӾcr;䄒tyɓԆ\0\0ԒmallSquare;旻erySmallSquare;斫ĀgpԦԪon;䄘f;쀀𝔼silon;䎕uĀaiԼՉlĀ;TՂՃ橵ilde;扂librium;懌Āci՗՚r;愰m;橳a;䎗ml耻Ë䃋Āipժկsts;戃onentialE;慇ʀcfiosօֈ֍ֲ׌y;䐤r;쀀𝔉lledɓ֗\0\0֣mallSquare;旼erySmallSquare;斪Ͱֺ\0ֿ\0\0ׄf;쀀𝔽All;戀riertrf;愱cò׋؀JTabcdfgorstר׬ׯ׺؀ؒؖ؛؝أ٬ٲcy;䐃耻>䀾mmaĀ;d׷׸䎓;䏜reve;䄞ƀeiy؇،ؐdil;䄢rc;䄜;䐓ot;䄠r;쀀𝔊;拙pf;쀀𝔾eater̀EFGLSTصلَٖٛ٦qualĀ;Lؾؿ扥ess;招ullEqual;执reater;檢ess;扷lantEqual;橾ilde;扳cr;쀀𝒢;扫ЀAacfiosuڅڋږڛڞڪھۊRDcy;䐪Āctڐڔek;䋇;䁞irc;䄤r;愌lbertSpace;愋ǰگ\0ڲf;愍izontalLine;攀Āctۃۅòکrok;䄦mpńېۘownHumðįqual;扏܀EJOacdfgmnostuۺ۾܃܇܎ܚܞܡܨ݄ݸދޏޕcy;䐕lig;䄲cy;䐁cute耻Í䃍Āiyܓܘrc耻Î䃎;䐘ot;䄰r;愑rave耻Ì䃌ƀ;apܠܯܿĀcgܴܷr;䄪inaryI;慈lieóϝǴ݉\0ݢĀ;eݍݎ戬Āgrݓݘral;戫section;拂isibleĀCTݬݲomma;恣imes;恢ƀgptݿރވon;䄮f;쀀𝕀a;䎙cr;愐ilde;䄨ǫޚ\0ޞcy;䐆l耻Ï䃏ʀcfosuެ޷޼߂ߐĀiyޱ޵rc;䄴;䐙r;쀀𝔍pf;쀀𝕁ǣ߇\0ߌr;쀀𝒥rcy;䐈kcy;䐄΀HJacfosߤߨ߽߬߱ࠂࠈcy;䐥cy;䐌ppa;䎚Āey߶߻dil;䄶;䐚r;쀀𝔎pf;쀀𝕂cr;쀀𝒦րJTaceflmostࠥࠩࠬࡐࡣ঳সে্਷ੇcy;䐉耻<䀼ʀcmnpr࠷࠼ࡁࡄࡍute;䄹bda;䎛g;柪lacetrf;愒r;憞ƀaeyࡗ࡜ࡡron;䄽dil;䄻;䐛Āfsࡨ॰tԀACDFRTUVarࡾࢩࢱࣦ࣠ࣼयज़ΐ४Ānrࢃ࢏gleBracket;柨rowƀ;BR࢙࢚࢞憐ar;懤ightArrow;懆eiling;挈oǵࢷ\0ࣃbleBracket;柦nǔࣈ\0࣒eeVector;楡ectorĀ;Bࣛࣜ懃ar;楙loor;挊ightĀAV࣯ࣵrrow;憔ector;楎Āerँगeƀ;AVउऊऐ抣rrow;憤ector;楚iangleƀ;BEतथऩ抲ar;槏qual;抴pƀDTVषूौownVector;楑eeVector;楠ectorĀ;Bॖॗ憿ar;楘ectorĀ;B॥०憼ar;楒ightáΜs̀EFGLSTॾঋকঝঢভqualGreater;拚ullEqual;扦reater;扶ess;檡lantEqual;橽ilde;扲r;쀀𝔏Ā;eঽা拘ftarrow;懚idot;䄿ƀnpw৔ਖਛgȀLRlr৞৷ਂਐeftĀAR০৬rrow;柵ightArrow;柷ightArrow;柶eftĀarγਊightáοightáϊf;쀀𝕃erĀLRਢਬeftArrow;憙ightArrow;憘ƀchtਾੀੂòࡌ;憰rok;䅁;扪Ѐacefiosuਗ਼੝੠੷੼અઋ઎p;椅y;䐜Ādl੥੯iumSpace;恟lintrf;愳r;쀀𝔐nusPlus;戓pf;쀀𝕄cò੶;䎜ҀJacefostuણધભીଔଙඑ඗ඞcy;䐊cute;䅃ƀaey઴હાron;䅇dil;䅅;䐝ƀgswે૰଎ativeƀMTV૓૟૨ediumSpace;怋hiĀcn૦૘ë૙eryThiî૙tedĀGL૸ଆreaterGreateòٳessLesóੈLine;䀊r;쀀𝔑ȀBnptଢନଷ଺reak;恠BreakingSpace;䂠f;愕ڀ;CDEGHLNPRSTV୕ୖ୪୼஡௫ఄ౞಄ದ೘ൡඅ櫬Āou୛୤ngruent;扢pCap;扭oubleVerticalBar;戦ƀlqxஃஊ஛ement;戉ualĀ;Tஒஓ扠ilde;쀀≂̸ists;戄reater΀;EFGLSTஶஷ஽௉௓௘௥扯qual;扱ullEqual;쀀≧̸reater;쀀≫̸ess;批lantEqual;쀀⩾̸ilde;扵umpń௲௽ownHump;쀀≎̸qual;쀀≏̸eĀfsఊధtTriangleƀ;BEచఛడ拪ar;쀀⧏̸qual;括s̀;EGLSTవశ఼ౄోౘ扮qual;扰reater;扸ess;쀀≪̸lantEqual;쀀⩽̸ilde;扴estedĀGL౨౹reaterGreater;쀀⪢̸essLess;쀀⪡̸recedesƀ;ESಒಓಛ技qual;쀀⪯̸lantEqual;拠ĀeiಫಹverseElement;戌ghtTriangleƀ;BEೋೌ೒拫ar;쀀⧐̸qual;拭ĀquೝഌuareSuĀbp೨೹setĀ;E೰ೳ쀀⊏̸qual;拢ersetĀ;Eഃആ쀀⊐̸qual;拣ƀbcpഓതൎsetĀ;Eഛഞ쀀⊂⃒qual;抈ceedsȀ;ESTലള഻െ抁qual;쀀⪰̸lantEqual;拡ilde;쀀≿̸ersetĀ;E൘൛쀀⊃⃒qual;抉ildeȀ;EFT൮൯൵ൿ扁qual;扄ullEqual;扇ilde;扉erticalBar;戤cr;쀀𝒩ilde耻Ñ䃑;䎝܀Eacdfgmoprstuvලෂ෉෕ෛ෠෧෼ขภยา฿ไlig;䅒cute耻Ó䃓Āiy෎ීrc耻Ô䃔;䐞blac;䅐r;쀀𝔒rave耻Ò䃒ƀaei෮ෲ෶cr;䅌ga;䎩cron;䎟pf;쀀𝕆enCurlyĀDQฎบoubleQuote;怜uote;怘;橔Āclวฬr;쀀𝒪ash耻Ø䃘iŬื฼de耻Õ䃕es;樷ml耻Ö䃖erĀBP๋๠Āar๐๓r;怾acĀek๚๜;揞et;掴arenthesis;揜Ҁacfhilors๿ງຊຏຒດຝະ໼rtialD;戂y;䐟r;쀀𝔓i;䎦;䎠usMinus;䂱Āipຢອncareplanåڝf;愙Ȁ;eio຺ູ໠໤檻cedesȀ;EST່້໏໚扺qual;檯lantEqual;扼ilde;找me;怳Ādp໩໮uct;戏ortionĀ;aȥ໹l;戝Āci༁༆r;쀀𝒫;䎨ȀUfos༑༖༛༟OT耻"䀢r;쀀𝔔pf;愚cr;쀀𝒬؀BEacefhiorsu༾གྷཇའཱིྦྷྪྭ႖ႩႴႾarr;椐G耻®䂮ƀcnrཎནབute;䅔g;柫rĀ;tཛྷཝ憠l;椖ƀaeyཧཬཱron;䅘dil;䅖;䐠Ā;vླྀཹ愜erseĀEUྂྙĀlq྇ྎement;戋uilibrium;懋pEquilibrium;楯r»ཹo;䎡ghtЀACDFTUVa࿁࿫࿳ဢဨၛႇϘĀnr࿆࿒gleBracket;柩rowƀ;BL࿜࿝࿡憒ar;懥eftArrow;懄eiling;按oǵ࿹\0စbleBracket;柧nǔည\0နeeVector;楝ectorĀ;Bဝသ懂ar;楕loor;挋Āerိ၃eƀ;AVဵံြ抢rrow;憦ector;楛iangleƀ;BEၐၑၕ抳ar;槐qual;抵pƀDTVၣၮၸownVector;楏eeVector;楜ectorĀ;Bႂႃ憾ar;楔ectorĀ;B႑႒懀ar;楓Āpuႛ႞f;愝ndImplies;楰ightarrow;懛ĀchႹႼr;愛;憱leDelayed;槴ڀHOacfhimoqstuფჱჷჽᄙᄞᅑᅖᅡᅧᆵᆻᆿĀCcჩხHcy;䐩y;䐨FTcy;䐬cute;䅚ʀ;aeiyᄈᄉᄎᄓᄗ檼ron;䅠dil;䅞rc;䅜;䐡r;쀀𝔖ortȀDLRUᄪᄴᄾᅉownArrow»ОeftArrow»࢚ightArrow»࿝pArrow;憑gma;䎣allCircle;战pf;쀀𝕊ɲᅭ\0\0ᅰt;戚areȀ;ISUᅻᅼᆉᆯ斡ntersection;抓uĀbpᆏᆞsetĀ;Eᆗᆘ抏qual;抑ersetĀ;Eᆨᆩ抐qual;抒nion;抔cr;쀀𝒮ar;拆ȀbcmpᇈᇛሉላĀ;sᇍᇎ拐etĀ;Eᇍᇕqual;抆ĀchᇠህeedsȀ;ESTᇭᇮᇴᇿ扻qual;檰lantEqual;扽ilde;承Tháྌ;我ƀ;esሒሓሣ拑rsetĀ;Eሜም抃qual;抇et»ሓրHRSacfhiorsሾቄ቉ቕ቞ቱቶኟዂወዑORN耻Þ䃞ADE;愢ĀHc቎ቒcy;䐋y;䐦Ābuቚቜ;䀉;䎤ƀaeyብቪቯron;䅤dil;䅢;䐢r;쀀𝔗Āeiቻ኉Dzኀ\0ኇefore;戴a;䎘Ācn኎ኘkSpace;쀀  Space;怉ldeȀ;EFTካኬኲኼ戼qual;扃ullEqual;扅ilde;扈pf;쀀𝕋ipleDot;惛Āctዖዛr;쀀𝒯rok;䅦ૡዷጎጚጦ\0ጬጱ\0\0\0\0\0ጸጽ፷ᎅ\0᏿ᐄᐊᐐĀcrዻጁute耻Ú䃚rĀ;oጇገ憟cir;楉rǣጓ\0጖y;䐎ve;䅬Āiyጞጣrc耻Û䃛;䐣blac;䅰r;쀀𝔘rave耻Ù䃙acr;䅪Ādiፁ፩erĀBPፈ፝Āarፍፐr;䁟acĀekፗፙ;揟et;掵arenthesis;揝onĀ;P፰፱拃lus;抎Āgp፻፿on;䅲f;쀀𝕌ЀADETadps᎕ᎮᎸᏄϨᏒᏗᏳrrowƀ;BDᅐᎠᎤar;椒ownArrow;懅ownArrow;憕quilibrium;楮eeĀ;AᏋᏌ报rrow;憥ownáϳerĀLRᏞᏨeftArrow;憖ightArrow;憗iĀ;lᏹᏺ䏒on;䎥ing;䅮cr;쀀𝒰ilde;䅨ml耻Ü䃜ҀDbcdefosvᐧᐬᐰᐳᐾᒅᒊᒐᒖash;披ar;櫫y;䐒ashĀ;lᐻᐼ抩;櫦Āerᑃᑅ;拁ƀbtyᑌᑐᑺar;怖Ā;iᑏᑕcalȀBLSTᑡᑥᑪᑴar;戣ine;䁼eparator;杘ilde;所ThinSpace;怊r;쀀𝔙pf;쀀𝕍cr;쀀𝒱dash;抪ʀcefosᒧᒬᒱᒶᒼirc;䅴dge;拀r;쀀𝔚pf;쀀𝕎cr;쀀𝒲Ȁfiosᓋᓐᓒᓘr;쀀𝔛;䎞pf;쀀𝕏cr;쀀𝒳ҀAIUacfosuᓱᓵᓹᓽᔄᔏᔔᔚᔠcy;䐯cy;䐇cy;䐮cute耻Ý䃝Āiyᔉᔍrc;䅶;䐫r;쀀𝔜pf;쀀𝕐cr;쀀𝒴ml;䅸ЀHacdefosᔵᔹᔿᕋᕏᕝᕠᕤcy;䐖cute;䅹Āayᕄᕉron;䅽;䐗ot;䅻Dzᕔ\0ᕛoWidtè૙a;䎖r;愨pf;愤cr;쀀𝒵௡ᖃᖊᖐ\0ᖰᖶᖿ\0\0\0\0ᗆᗛᗫᙟ᙭\0ᚕ᚛ᚲᚹ\0ᚾcute耻á䃡reve;䄃̀;Ediuyᖜᖝᖡᖣᖨᖭ戾;쀀∾̳;房rc耻â䃢te肻´̆;䐰lig耻æ䃦Ā;r²ᖺ;쀀𝔞rave耻à䃠ĀepᗊᗖĀfpᗏᗔsym;愵èᗓha;䎱ĀapᗟcĀclᗤᗧr;䄁g;樿ɤᗰ\0\0ᘊʀ;adsvᗺᗻᗿᘁᘇ戧nd;橕;橜lope;橘;橚΀;elmrszᘘᘙᘛᘞᘿᙏᙙ戠;榤e»ᘙsdĀ;aᘥᘦ戡ѡᘰᘲᘴᘶᘸᘺᘼᘾ;榨;榩;榪;榫;榬;榭;榮;榯tĀ;vᙅᙆ戟bĀ;dᙌᙍ抾;榝Āptᙔᙗh;戢»¹arr;捼Āgpᙣᙧon;䄅f;쀀𝕒΀;Eaeiop዁ᙻᙽᚂᚄᚇᚊ;橰cir;橯;扊d;手s;䀧roxĀ;e዁ᚒñᚃing耻å䃥ƀctyᚡᚦᚨr;쀀𝒶;䀪mpĀ;e዁ᚯñʈilde耻ã䃣ml耻ä䃤Āciᛂᛈoninôɲnt;樑ࠀNabcdefiklnoprsu᛭ᛱᜰ᜼ᝃᝈ᝸᝽០៦ᠹᡐᜍ᤽᥈ᥰot;櫭Ācrᛶ᜞kȀcepsᜀᜅᜍᜓong;扌psilon;䏶rime;怵imĀ;e᜚᜛戽q;拍Ŷᜢᜦee;抽edĀ;gᜬᜭ挅e»ᜭrkĀ;t፜᜷brk;掶Āoyᜁᝁ;䐱quo;怞ʀcmprtᝓ᝛ᝡᝤᝨausĀ;eĊĉptyv;榰séᜌnoõēƀahwᝯ᝱ᝳ;䎲;愶een;扬r;쀀𝔟g΀costuvwឍឝឳេ៕៛៞ƀaiuបពរðݠrc;旯p»፱ƀdptឤឨឭot;樀lus;樁imes;樂ɱឹ\0\0ើcup;樆ar;昅riangleĀdu៍្own;施p;斳plus;樄eåᑄåᒭarow;植ƀako៭ᠦᠵĀcn៲ᠣkƀlst៺֫᠂ozenge;槫riangleȀ;dlr᠒᠓᠘᠝斴own;斾eft;旂ight;斸k;搣Ʊᠫ\0ᠳƲᠯ\0ᠱ;斒;斑4;斓ck;斈ĀeoᠾᡍĀ;qᡃᡆ쀀=⃥uiv;쀀≡⃥t;挐Ȁptwxᡙᡞᡧᡬf;쀀𝕓Ā;tᏋᡣom»Ꮜtie;拈؀DHUVbdhmptuvᢅᢖᢪᢻᣗᣛᣬ᣿ᤅᤊᤐᤡȀLRlrᢎᢐᢒᢔ;敗;敔;敖;敓ʀ;DUduᢡᢢᢤᢦᢨ敐;敦;敩;敤;敧ȀLRlrᢳᢵᢷᢹ;敝;敚;敜;教΀;HLRhlrᣊᣋᣍᣏᣑᣓᣕ救;敬;散;敠;敫;敢;敟ox;槉ȀLRlrᣤᣦᣨᣪ;敕;敒;攐;攌ʀ;DUduڽ᣷᣹᣻᣽;敥;敨;攬;攴inus;抟lus;択imes;抠ȀLRlrᤙᤛᤝ᤟;敛;敘;攘;攔΀;HLRhlrᤰᤱᤳᤵᤷ᤻᤹攂;敪;敡;敞;攼;攤;攜Āevģ᥂bar耻¦䂦Ȁceioᥑᥖᥚᥠr;쀀𝒷mi;恏mĀ;e᜚᜜lƀ;bhᥨᥩᥫ䁜;槅sub;柈Ŭᥴ᥾lĀ;e᥹᥺怢t»᥺pƀ;Eeįᦅᦇ;檮Ā;qۜۛೡᦧ\0᧨ᨑᨕᨲ\0ᨷᩐ\0\0᪴\0\0᫁\0\0ᬡᬮ᭍᭒\0᯽\0ᰌƀcpr᦭ᦲ᧝ute;䄇̀;abcdsᦿᧀᧄ᧊᧕᧙戩nd;橄rcup;橉Āau᧏᧒p;橋p;橇ot;橀;쀀∩︀Āeo᧢᧥t;恁îړȀaeiu᧰᧻ᨁᨅǰ᧵\0᧸s;橍on;䄍dil耻ç䃧rc;䄉psĀ;sᨌᨍ橌m;橐ot;䄋ƀdmnᨛᨠᨦil肻¸ƭptyv;榲t脀¢;eᨭᨮ䂢räƲr;쀀𝔠ƀceiᨽᩀᩍy;䑇ckĀ;mᩇᩈ朓ark»ᩈ;䏇r΀;Ecefms᩟᩠ᩢᩫ᪤᪪᪮旋;槃ƀ;elᩩᩪᩭ䋆q;扗eɡᩴ\0\0᪈rrowĀlr᩼᪁eft;憺ight;憻ʀRSacd᪒᪔᪖᪚᪟»ཇ;擈st;抛irc;抚ash;抝nint;樐id;櫯cir;槂ubsĀ;u᪻᪼晣it»᪼ˬ᫇᫔᫺\0ᬊonĀ;eᫍᫎ䀺Ā;qÇÆɭ᫙\0\0᫢aĀ;t᫞᫟䀬;䁀ƀ;fl᫨᫩᫫戁îᅠeĀmx᫱᫶ent»᫩eóɍǧ᫾\0ᬇĀ;dኻᬂot;橭nôɆƀfryᬐᬔᬗ;쀀𝕔oäɔ脀©;sŕᬝr;愗Āaoᬥᬩrr;憵ss;朗Ācuᬲᬷr;쀀𝒸Ābpᬼ᭄Ā;eᭁᭂ櫏;櫑Ā;eᭉᭊ櫐;櫒dot;拯΀delprvw᭠᭬᭷ᮂᮬᯔ᯹arrĀlr᭨᭪;椸;椵ɰ᭲\0\0᭵r;拞c;拟arrĀ;p᭿ᮀ憶;椽̀;bcdosᮏᮐᮖᮡᮥᮨ截rcap;橈Āauᮛᮞp;橆p;橊ot;抍r;橅;쀀∪︀Ȁalrv᮵ᮿᯞᯣrrĀ;mᮼᮽ憷;椼yƀevwᯇᯔᯘqɰᯎ\0\0ᯒreã᭳uã᭵ee;拎edge;拏en耻¤䂤earrowĀlrᯮ᯳eft»ᮀight»ᮽeäᯝĀciᰁᰇoninôǷnt;戱lcty;挭ঀAHabcdefhijlorstuwz᰸᰻᰿ᱝᱩᱵᲊᲞᲬᲷ᳻᳿ᴍᵻᶑᶫᶻ᷆᷍rò΁ar;楥Ȁglrs᱈ᱍ᱒᱔ger;怠eth;愸òᄳhĀ;vᱚᱛ怐»ऊūᱡᱧarow;椏aã̕Āayᱮᱳron;䄏;䐴ƀ;ao̲ᱼᲄĀgrʿᲁr;懊tseq;橷ƀglmᲑᲔᲘ耻°䂰ta;䎴ptyv;榱ĀirᲣᲨsht;楿;쀀𝔡arĀlrᲳᲵ»ࣜ»သʀaegsv᳂͸᳖᳜᳠mƀ;oș᳊᳔ndĀ;ș᳑uit;晦amma;䏝in;拲ƀ;io᳧᳨᳸䃷de脀÷;o᳧ᳰntimes;拇nø᳷cy;䑒cɯᴆ\0\0ᴊrn;挞op;挍ʀlptuwᴘᴝᴢᵉᵕlar;䀤f;쀀𝕕ʀ;emps̋ᴭᴷᴽᵂqĀ;d͒ᴳot;扑inus;戸lus;戔quare;抡blebarwedgåúnƀadhᄮᵝᵧownarrowóᲃarpoonĀlrᵲᵶefôᲴighôᲶŢᵿᶅkaro÷གɯᶊ\0\0ᶎrn;挟op;挌ƀcotᶘᶣᶦĀryᶝᶡ;쀀𝒹;䑕l;槶rok;䄑Ādrᶰᶴot;拱iĀ;fᶺ᠖斿Āah᷀᷃ròЩaòྦangle;榦Āci᷒ᷕy;䑟grarr;柿ऀDacdefglmnopqrstuxḁḉḙḸոḼṉṡṾấắẽỡἪἷὄ὎὚ĀDoḆᴴoôᲉĀcsḎḔute耻é䃩ter;橮ȀaioyḢḧḱḶron;䄛rĀ;cḭḮ扖耻ê䃪lon;払;䑍ot;䄗ĀDrṁṅot;扒;쀀𝔢ƀ;rsṐṑṗ檚ave耻è䃨Ā;dṜṝ檖ot;檘Ȁ;ilsṪṫṲṴ檙nters;揧;愓Ā;dṹṺ檕ot;檗ƀapsẅẉẗcr;䄓tyƀ;svẒẓẕ戅et»ẓpĀ1;ẝẤijạả;怄;怅怃ĀgsẪẬ;䅋p;怂ĀgpẴẸon;䄙f;쀀𝕖ƀalsỄỎỒrĀ;sỊị拕l;槣us;橱iƀ;lvỚớở䎵on»ớ;䏵ȀcsuvỪỳἋἣĀioữḱrc»Ḯɩỹ\0\0ỻíՈantĀglἂἆtr»ṝess»Ṻƀaeiἒ἖Ἒls;䀽st;扟vĀ;DȵἠD;橸parsl;槥ĀDaἯἳot;打rr;楱ƀcdiἾὁỸr;愯oô͒ĀahὉὋ;䎷耻ð䃰Āmrὓὗl耻ë䃫o;悬ƀcipὡὤὧl;䀡sôծĀeoὬὴctatioîՙnentialåչৡᾒ\0ᾞ\0ᾡᾧ\0\0ῆῌ\0ΐ\0ῦῪ \0 ⁚llingdotseñṄy;䑄male;晀ƀilrᾭᾳ῁lig;耀ffiɩᾹ\0\0᾽g;耀ffig;耀ffl;쀀𝔣lig;耀filig;쀀fjƀaltῙ῜ῡt;晭ig;耀flns;斱of;䆒ǰ΅\0ῳf;쀀𝕗ĀakֿῷĀ;vῼ´拔;櫙artint;樍Āao‌⁕Ācs‑⁒ႉ‸⁅⁈\0⁐β•‥‧‪‬\0‮耻½䂽;慓耻¼䂼;慕;慙;慛Ƴ‴\0‶;慔;慖ʴ‾⁁\0\0⁃耻¾䂾;慗;慜5;慘ƶ⁌\0⁎;慚;慝8;慞l;恄wn;挢cr;쀀𝒻ࢀEabcdefgijlnorstv₂₉₟₥₰₴⃰⃵⃺⃿℃ℒℸ̗ℾ⅒↞Ā;lٍ₇;檌ƀcmpₐₕ₝ute;䇵maĀ;dₜ᳚䎳;檆reve;䄟Āiy₪₮rc;䄝;䐳ot;䄡Ȁ;lqsؾق₽⃉ƀ;qsؾٌ⃄lanô٥Ȁ;cdl٥⃒⃥⃕c;檩otĀ;o⃜⃝檀Ā;l⃢⃣檂;檄Ā;e⃪⃭쀀⋛︀s;檔r;쀀𝔤Ā;gٳ؛mel;愷cy;䑓Ȁ;Eajٚℌℎℐ;檒;檥;檤ȀEaesℛℝ℩ℴ;扩pĀ;p℣ℤ檊rox»ℤĀ;q℮ℯ檈Ā;q℮ℛim;拧pf;쀀𝕘Āci⅃ⅆr;愊mƀ;el٫ⅎ⅐;檎;檐茀>;cdlqr׮ⅠⅪⅮⅳⅹĀciⅥⅧ;檧r;橺ot;拗Par;榕uest;橼ʀadelsↄⅪ←ٖ↛ǰ↉\0↎proø₞r;楸qĀlqؿ↖lesó₈ií٫Āen↣↭rtneqq;쀀≩︀Å↪ԀAabcefkosy⇄⇇⇱⇵⇺∘∝∯≨≽ròΠȀilmr⇐⇔⇗⇛rsðᒄf»․ilôکĀdr⇠⇤cy;䑊ƀ;cwࣴ⇫⇯ir;楈;憭ar;意irc;䄥ƀalr∁∎∓rtsĀ;u∉∊晥it»∊lip;怦con;抹r;쀀𝔥sĀew∣∩arow;椥arow;椦ʀamopr∺∾≃≞≣rr;懿tht;戻kĀlr≉≓eftarrow;憩ightarrow;憪f;쀀𝕙bar;怕ƀclt≯≴≸r;쀀𝒽asè⇴rok;䄧Ābp⊂⊇ull;恃hen»ᱛૡ⊣\0⊪\0⊸⋅⋎\0⋕⋳\0\0⋸⌢⍧⍢⍿\0⎆⎪⎴cute耻í䃭ƀ;iyݱ⊰⊵rc耻î䃮;䐸Ācx⊼⊿y;䐵cl耻¡䂡ĀfrΟ⋉;쀀𝔦rave耻ì䃬Ȁ;inoܾ⋝⋩⋮Āin⋢⋦nt;樌t;戭fin;槜ta;愩lig;䄳ƀaop⋾⌚⌝ƀcgt⌅⌈⌗r;䄫ƀelpܟ⌏⌓inåގarôܠh;䄱f;抷ed;䆵ʀ;cfotӴ⌬⌱⌽⍁are;愅inĀ;t⌸⌹戞ie;槝doô⌙ʀ;celpݗ⍌⍐⍛⍡al;抺Āgr⍕⍙eróᕣã⍍arhk;樗rod;樼Ȁcgpt⍯⍲⍶⍻y;䑑on;䄯f;쀀𝕚a;䎹uest耻¿䂿Āci⎊⎏r;쀀𝒾nʀ;EdsvӴ⎛⎝⎡ӳ;拹ot;拵Ā;v⎦⎧拴;拳Ā;iݷ⎮lde;䄩ǫ⎸\0⎼cy;䑖l耻ï䃯̀cfmosu⏌⏗⏜⏡⏧⏵Āiy⏑⏕rc;䄵;䐹r;쀀𝔧ath;䈷pf;쀀𝕛ǣ⏬\0⏱r;쀀𝒿rcy;䑘kcy;䑔Ѐacfghjos␋␖␢␧␭␱␵␻ppaĀ;v␓␔䎺;䏰Āey␛␠dil;䄷;䐺r;쀀𝔨reen;䄸cy;䑅cy;䑜pf;쀀𝕜cr;쀀𝓀஀ABEHabcdefghjlmnoprstuv⑰⒁⒆⒍⒑┎┽╚▀♎♞♥♹♽⚚⚲⛘❝❨➋⟀⠁⠒ƀart⑷⑺⑼rò৆òΕail;椛arr;椎Ā;gঔ⒋;檋ar;楢ॣ⒥\0⒪\0⒱\0\0\0\0\0⒵Ⓔ\0ⓆⓈⓍ\0⓹ute;䄺mptyv;榴raîࡌbda;䎻gƀ;dlࢎⓁⓃ;榑åࢎ;檅uo耻«䂫rЀ;bfhlpst࢙ⓞⓦⓩ⓫⓮⓱⓵Ā;f࢝ⓣs;椟s;椝ë≒p;憫l;椹im;楳l;憢ƀ;ae⓿─┄檫il;椙Ā;s┉┊檭;쀀⪭︀ƀabr┕┙┝rr;椌rk;杲Āak┢┬cĀek┨┪;䁻;䁛Āes┱┳;榋lĀdu┹┻;榏;榍Ȁaeuy╆╋╖╘ron;䄾Ādi═╔il;䄼ìࢰâ┩;䐻Ȁcqrs╣╦╭╽a;椶uoĀ;rนᝆĀdu╲╷har;楧shar;楋h;憲ʀ;fgqs▋▌উ◳◿扤tʀahlrt▘▤▷◂◨rrowĀ;t࢙□aé⓶arpoonĀdu▯▴own»њp»०eftarrows;懇ightƀahs◍◖◞rrowĀ;sࣴࢧarpoonó྘quigarro÷⇰hreetimes;拋ƀ;qs▋ও◺lanôবʀ;cdgsব☊☍☝☨c;檨otĀ;o☔☕橿Ā;r☚☛檁;檃Ā;e☢☥쀀⋚︀s;檓ʀadegs☳☹☽♉♋pproøⓆot;拖qĀgq♃♅ôউgtò⒌ôছiíলƀilr♕࣡♚sht;楼;쀀𝔩Ā;Eজ♣;檑š♩♶rĀdu▲♮Ā;l॥♳;楪lk;斄cy;䑙ʀ;achtੈ⚈⚋⚑⚖rò◁orneòᴈard;楫ri;旺Āio⚟⚤dot;䅀ustĀ;a⚬⚭掰che»⚭ȀEaes⚻⚽⛉⛔;扨pĀ;p⛃⛄檉rox»⛄Ā;q⛎⛏檇Ā;q⛎⚻im;拦Ѐabnoptwz⛩⛴⛷✚✯❁❇❐Ānr⛮⛱g;柬r;懽rëࣁgƀlmr⛿✍✔eftĀar০✇ightá৲apsto;柼ightá৽parrowĀlr✥✩efô⓭ight;憬ƀafl✶✹✽r;榅;쀀𝕝us;樭imes;樴š❋❏st;戗áፎƀ;ef❗❘᠀旊nge»❘arĀ;l❤❥䀨t;榓ʀachmt❳❶❼➅➇ròࢨorneòᶌarĀ;d྘➃;業;怎ri;抿̀achiqt➘➝ੀ➢➮➻quo;怹r;쀀𝓁mƀ;egল➪➬;檍;檏Ābu┪➳oĀ;rฟ➹;怚rok;䅂萀<;cdhilqrࠫ⟒☹⟜⟠⟥⟪⟰Āci⟗⟙;檦r;橹reå◲mes;拉arr;楶uest;橻ĀPi⟵⟹ar;榖ƀ;ef⠀भ᠛旃rĀdu⠇⠍shar;楊har;楦Āen⠗⠡rtneqq;쀀≨︀Å⠞܀Dacdefhilnopsu⡀⡅⢂⢎⢓⢠⢥⢨⣚⣢⣤ઃ⣳⤂Dot;戺Ȁclpr⡎⡒⡣⡽r耻¯䂯Āet⡗⡙;時Ā;e⡞⡟朠se»⡟Ā;sျ⡨toȀ;dluျ⡳⡷⡻owîҌefôएðᏑker;斮Āoy⢇⢌mma;権;䐼ash;怔asuredangle»ᘦr;쀀𝔪o;愧ƀcdn⢯⢴⣉ro耻µ䂵Ȁ;acdᑤ⢽⣀⣄sôᚧir;櫰ot肻·Ƶusƀ;bd⣒ᤃ⣓戒Ā;uᴼ⣘;横ţ⣞⣡p;櫛ò−ðઁĀdp⣩⣮els;抧f;쀀𝕞Āct⣸⣽r;쀀𝓂pos»ᖝƀ;lm⤉⤊⤍䎼timap;抸ఀGLRVabcdefghijlmoprstuvw⥂⥓⥾⦉⦘⧚⧩⨕⨚⩘⩝⪃⪕⪤⪨⬄⬇⭄⭿⮮ⰴⱧⱼ⳩Āgt⥇⥋;쀀⋙̸Ā;v⥐௏쀀≫⃒ƀelt⥚⥲⥶ftĀar⥡⥧rrow;懍ightarrow;懎;쀀⋘̸Ā;v⥻ే쀀≪⃒ightarrow;懏ĀDd⦎⦓ash;抯ash;抮ʀbcnpt⦣⦧⦬⦱⧌la»˞ute;䅄g;쀀∠⃒ʀ;Eiop඄⦼⧀⧅⧈;쀀⩰̸d;쀀≋̸s;䅉roø඄urĀ;a⧓⧔普lĀ;s⧓ସdz⧟\0⧣p肻 ଷmpĀ;e௹ఀʀaeouy⧴⧾⨃⨐⨓ǰ⧹\0⧻;橃on;䅈dil;䅆ngĀ;dൾ⨊ot;쀀⩭̸p;橂;䐽ash;怓΀;Aadqsxஒ⨩⨭⨻⩁⩅⩐rr;懗rĀhr⨳⨶k;椤Ā;oᏲᏰot;쀀≐̸uiöୣĀei⩊⩎ar;椨í஘istĀ;s஠டr;쀀𝔫ȀEest௅⩦⩹⩼ƀ;qs஼⩭௡ƀ;qs஼௅⩴lanô௢ií௪Ā;rஶ⪁»ஷƀAap⪊⪍⪑rò⥱rr;憮ar;櫲ƀ;svྍ⪜ྌĀ;d⪡⪢拼;拺cy;䑚΀AEadest⪷⪺⪾⫂⫅⫶⫹rò⥦;쀀≦̸rr;憚r;急Ȁ;fqs఻⫎⫣⫯tĀar⫔⫙rro÷⫁ightarro÷⪐ƀ;qs఻⪺⫪lanôౕĀ;sౕ⫴»శiíౝĀ;rవ⫾iĀ;eచథiäඐĀpt⬌⬑f;쀀𝕟膀¬;in⬙⬚⬶䂬nȀ;Edvஉ⬤⬨⬮;쀀⋹̸ot;쀀⋵̸ǡஉ⬳⬵;拷;拶iĀ;vಸ⬼ǡಸ⭁⭃;拾;拽ƀaor⭋⭣⭩rȀ;ast୻⭕⭚⭟lleì୻l;쀀⫽⃥;쀀∂̸lint;樔ƀ;ceಒ⭰⭳uåಥĀ;cಘ⭸Ā;eಒ⭽ñಘȀAait⮈⮋⮝⮧rò⦈rrƀ;cw⮔⮕⮙憛;쀀⤳̸;쀀↝̸ghtarrow»⮕riĀ;eೋೖ΀chimpqu⮽⯍⯙⬄୸⯤⯯Ȁ;cerല⯆ഷ⯉uå൅;쀀𝓃ortɭ⬅\0\0⯖ará⭖mĀ;e൮⯟Ā;q൴൳suĀbp⯫⯭å೸åഋƀbcp⯶ⰑⰙȀ;Ees⯿ⰀഢⰄ抄;쀀⫅̸etĀ;eഛⰋqĀ;qണⰀcĀ;eലⰗñസȀ;EesⰢⰣൟⰧ抅;쀀⫆̸etĀ;e൘ⰮqĀ;qൠⰣȀgilrⰽⰿⱅⱇìௗlde耻ñ䃱çృiangleĀlrⱒⱜeftĀ;eచⱚñదightĀ;eೋⱥñ೗Ā;mⱬⱭ䎽ƀ;esⱴⱵⱹ䀣ro;愖p;怇ҀDHadgilrsⲏⲔⲙⲞⲣⲰⲶⳓⳣash;抭arr;椄p;쀀≍⃒ash;抬ĀetⲨⲬ;쀀≥⃒;쀀>⃒nfin;槞ƀAetⲽⳁⳅrr;椂;쀀≤⃒Ā;rⳊⳍ쀀<⃒ie;쀀⊴⃒ĀAtⳘⳜrr;椃rie;쀀⊵⃒im;쀀∼⃒ƀAan⳰⳴ⴂrr;懖rĀhr⳺⳽k;椣Ā;oᏧᏥear;椧ቓ᪕\0\0\0\0\0\0\0\0\0\0\0\0\0ⴭ\0ⴸⵈⵠⵥ⵲ⶄᬇ\0\0ⶍⶫ\0ⷈⷎ\0ⷜ⸙⸫⸾⹃Ācsⴱ᪗ute耻ó䃳ĀiyⴼⵅrĀ;c᪞ⵂ耻ô䃴;䐾ʀabios᪠ⵒⵗLjⵚlac;䅑v;樸old;榼lig;䅓Ācr⵩⵭ir;榿;쀀𝔬ͯ⵹\0\0⵼\0ⶂn;䋛ave耻ò䃲;槁Ābmⶈ෴ar;榵Ȁacitⶕ⶘ⶥⶨrò᪀Āir⶝ⶠr;榾oss;榻nå๒;槀ƀaeiⶱⶵⶹcr;䅍ga;䏉ƀcdnⷀⷅǍron;䎿;榶pf;쀀𝕠ƀaelⷔ⷗ǒr;榷rp;榹΀;adiosvⷪⷫⷮ⸈⸍⸐⸖戨rò᪆Ȁ;efmⷷⷸ⸂⸅橝rĀ;oⷾⷿ愴f»ⷿ耻ª䂪耻º䂺gof;抶r;橖lope;橗;橛ƀclo⸟⸡⸧ò⸁ash耻ø䃸l;折iŬⸯ⸴de耻õ䃵esĀ;aǛ⸺s;樶ml耻ö䃶bar;挽ૡ⹞\0⹽\0⺀⺝\0⺢⺹\0\0⻋ຜ\0⼓\0\0⼫⾼\0⿈rȀ;astЃ⹧⹲຅脀¶;l⹭⹮䂶leìЃɩ⹸\0\0⹻m;櫳;櫽y;䐿rʀcimpt⺋⺏⺓ᡥ⺗nt;䀥od;䀮il;怰enk;怱r;쀀𝔭ƀimo⺨⺰⺴Ā;v⺭⺮䏆;䏕maô੶ne;明ƀ;tv⺿⻀⻈䏀chfork»´;䏖Āau⻏⻟nĀck⻕⻝kĀ;h⇴⻛;愎ö⇴sҀ;abcdemst⻳⻴ᤈ⻹⻽⼄⼆⼊⼎䀫cir;樣ir;樢Āouᵀ⼂;樥;橲n肻±ຝim;樦wo;樧ƀipu⼙⼠⼥ntint;樕f;쀀𝕡nd耻£䂣Ԁ;Eaceinosu່⼿⽁⽄⽇⾁⾉⾒⽾⾶;檳p;檷uå໙Ā;c໎⽌̀;acens່⽙⽟⽦⽨⽾pproø⽃urlyeñ໙ñ໎ƀaes⽯⽶⽺pprox;檹qq;檵im;拨iíໟmeĀ;s⾈ຮ怲ƀEas⽸⾐⽺ð⽵ƀdfp໬⾙⾯ƀals⾠⾥⾪lar;挮ine;挒urf;挓Ā;t໻⾴ï໻rel;抰Āci⿀⿅r;쀀𝓅;䏈ncsp;怈̀fiopsu⿚⋢⿟⿥⿫⿱r;쀀𝔮pf;쀀𝕢rime;恗cr;쀀𝓆ƀaeo⿸〉〓tĀei⿾々rnionóڰnt;樖stĀ;e【】䀿ñἙô༔઀ABHabcdefhilmnoprstux぀けさすムㄎㄫㅇㅢㅲㆎ㈆㈕㈤㈩㉘㉮㉲㊐㊰㊷ƀartぇおがròႳòϝail;検aròᱥar;楤΀cdenqrtとふへみわゔヌĀeuねぱ;쀀∽̱te;䅕iãᅮmptyv;榳gȀ;del࿑らるろ;榒;榥å࿑uo耻»䂻rր;abcfhlpstw࿜ガクシスゼゾダッデナp;極Ā;f࿠ゴs;椠;椳s;椞ë≝ð✮l;楅im;楴l;憣;憝Āaiパフil;椚oĀ;nホボ戶aló༞ƀabrョリヮrò៥rk;杳ĀakンヽcĀekヹ・;䁽;䁝Āes㄂㄄;榌lĀduㄊㄌ;榎;榐Ȁaeuyㄗㄜㄧㄩron;䅙Ādiㄡㄥil;䅗ì࿲âヺ;䑀Ȁclqsㄴㄷㄽㅄa;椷dhar;楩uoĀ;rȎȍh;憳ƀacgㅎㅟངlȀ;ipsླྀㅘㅛႜnåႻarôྩt;断ƀilrㅩဣㅮsht;楽;쀀𝔯ĀaoㅷㆆrĀduㅽㅿ»ѻĀ;l႑ㆄ;楬Ā;vㆋㆌ䏁;䏱ƀgns㆕ㇹㇼht̀ahlrstㆤㆰ㇂㇘㇤㇮rrowĀ;t࿜ㆭaéトarpoonĀduㆻㆿowîㅾp»႒eftĀah㇊㇐rrowó࿪arpoonóՑightarrows;應quigarro÷ニhreetimes;拌g;䋚ingdotseñἲƀahm㈍㈐㈓rò࿪aòՑ;怏oustĀ;a㈞㈟掱che»㈟mid;櫮Ȁabpt㈲㈽㉀㉒Ānr㈷㈺g;柭r;懾rëဃƀafl㉇㉊㉎r;榆;쀀𝕣us;樮imes;樵Āap㉝㉧rĀ;g㉣㉤䀩t;榔olint;樒arò㇣Ȁachq㉻㊀Ⴜ㊅quo;怺r;쀀𝓇Ābu・㊊oĀ;rȔȓƀhir㊗㊛㊠reåㇸmes;拊iȀ;efl㊪ၙᠡ㊫方tri;槎luhar;楨;愞ൡ㋕㋛㋟㌬㌸㍱\0㍺㎤\0\0㏬㏰\0㐨㑈㑚㒭㒱㓊㓱\0㘖\0\0㘳cute;䅛quï➺Ԁ;Eaceinpsyᇭ㋳㋵㋿㌂㌋㌏㌟㌦㌩;檴ǰ㋺\0㋼;檸on;䅡uåᇾĀ;dᇳ㌇il;䅟rc;䅝ƀEas㌖㌘㌛;檶p;檺im;择olint;樓iíሄ;䑁otƀ;be㌴ᵇ㌵担;橦΀Aacmstx㍆㍊㍗㍛㍞㍣㍭rr;懘rĀhr㍐㍒ë∨Ā;oਸ਼਴t耻§䂧i;䀻war;椩mĀin㍩ðnuóñt;朶rĀ;o㍶⁕쀀𝔰Ȁacoy㎂㎆㎑㎠rp;景Āhy㎋㎏cy;䑉;䑈rtɭ㎙\0\0㎜iäᑤaraì⹯耻­䂭Āgm㎨㎴maƀ;fv㎱㎲㎲䏃;䏂Ѐ;deglnprካ㏅㏉㏎㏖㏞㏡㏦ot;橪Ā;q኱ኰĀ;E㏓㏔檞;檠Ā;E㏛㏜檝;檟e;扆lus;樤arr;楲aròᄽȀaeit㏸㐈㐏㐗Āls㏽㐄lsetmé㍪hp;樳parsl;槤Ādlᑣ㐔e;挣Ā;e㐜㐝檪Ā;s㐢㐣檬;쀀⪬︀ƀflp㐮㐳㑂tcy;䑌Ā;b㐸㐹䀯Ā;a㐾㐿槄r;挿f;쀀𝕤aĀdr㑍ЂesĀ;u㑔㑕晠it»㑕ƀcsu㑠㑹㒟Āau㑥㑯pĀ;sᆈ㑫;쀀⊓︀pĀ;sᆴ㑵;쀀⊔︀uĀbp㑿㒏ƀ;esᆗᆜ㒆etĀ;eᆗ㒍ñᆝƀ;esᆨᆭ㒖etĀ;eᆨ㒝ñᆮƀ;afᅻ㒦ְrť㒫ֱ»ᅼaròᅈȀcemt㒹㒾㓂㓅r;쀀𝓈tmîñiì㐕aræᆾĀar㓎㓕rĀ;f㓔ឿ昆Āan㓚㓭ightĀep㓣㓪psiloîỠhé⺯s»⡒ʀbcmnp㓻㕞ሉ㖋㖎Ҁ;Edemnprs㔎㔏㔑㔕㔞㔣㔬㔱㔶抂;櫅ot;檽Ā;dᇚ㔚ot;櫃ult;櫁ĀEe㔨㔪;櫋;把lus;檿arr;楹ƀeiu㔽㕒㕕tƀ;en㔎㕅㕋qĀ;qᇚ㔏eqĀ;q㔫㔨m;櫇Ābp㕚㕜;櫕;櫓c̀;acensᇭ㕬㕲㕹㕻㌦pproø㋺urlyeñᇾñᇳƀaes㖂㖈㌛pproø㌚qñ㌗g;晪ڀ123;Edehlmnps㖩㖬㖯ሜ㖲㖴㗀㗉㗕㗚㗟㗨㗭耻¹䂹耻²䂲耻³䂳;櫆Āos㖹㖼t;檾ub;櫘Ā;dሢ㗅ot;櫄sĀou㗏㗒l;柉b;櫗arr;楻ult;櫂ĀEe㗤㗦;櫌;抋lus;櫀ƀeiu㗴㘉㘌tƀ;enሜ㗼㘂qĀ;qሢ㖲eqĀ;q㗧㗤m;櫈Ābp㘑㘓;櫔;櫖ƀAan㘜㘠㘭rr;懙rĀhr㘦㘨ë∮Ā;oਫ਩war;椪lig耻ß䃟௡㙑㙝㙠ዎ㙳㙹\0㙾㛂\0\0\0\0\0㛛㜃\0㜉㝬\0\0\0㞇ɲ㙖\0\0㙛get;挖;䏄rë๟ƀaey㙦㙫㙰ron;䅥dil;䅣;䑂lrec;挕r;쀀𝔱Ȁeiko㚆㚝㚵㚼Dz㚋\0㚑eĀ4fኄኁaƀ;sv㚘㚙㚛䎸ym;䏑Ācn㚢㚲kĀas㚨㚮pproø዁im»ኬsðኞĀas㚺㚮ð዁rn耻þ䃾Ǭ̟㛆⋧es膀×;bd㛏㛐㛘䃗Ā;aᤏ㛕r;樱;樰ƀeps㛡㛣㜀á⩍Ȁ;bcf҆㛬㛰㛴ot;挶ir;櫱Ā;o㛹㛼쀀𝕥rk;櫚á㍢rime;怴ƀaip㜏㜒㝤dåቈ΀adempst㜡㝍㝀㝑㝗㝜㝟ngleʀ;dlqr㜰㜱㜶㝀㝂斵own»ᶻeftĀ;e⠀㜾ñम;扜ightĀ;e㊪㝋ñၚot;旬inus;樺lus;樹b;槍ime;樻ezium;揢ƀcht㝲㝽㞁Āry㝷㝻;쀀𝓉;䑆cy;䑛rok;䅧Āio㞋㞎xô᝷headĀlr㞗㞠eftarro÷ࡏightarrow»ཝऀAHabcdfghlmoprstuw㟐㟓㟗㟤㟰㟼㠎㠜㠣㠴㡑㡝㡫㢩㣌㣒㣪㣶ròϭar;楣Ācr㟜㟢ute耻ú䃺òᅐrǣ㟪\0㟭y;䑞ve;䅭Āiy㟵㟺rc耻û䃻;䑃ƀabh㠃㠆㠋ròᎭlac;䅱aòᏃĀir㠓㠘sht;楾;쀀𝔲rave耻ù䃹š㠧㠱rĀlr㠬㠮»ॗ»ႃlk;斀Āct㠹㡍ɯ㠿\0\0㡊rnĀ;e㡅㡆挜r»㡆op;挏ri;旸Āal㡖㡚cr;䅫肻¨͉Āgp㡢㡦on;䅳f;쀀𝕦̀adhlsuᅋ㡸㡽፲㢑㢠ownáᎳarpoonĀlr㢈㢌efô㠭ighô㠯iƀ;hl㢙㢚㢜䏅»ᏺon»㢚parrows;懈ƀcit㢰㣄㣈ɯ㢶\0\0㣁rnĀ;e㢼㢽挝r»㢽op;挎ng;䅯ri;旹cr;쀀𝓊ƀdir㣙㣝㣢ot;拰lde;䅩iĀ;f㜰㣨»᠓Āam㣯㣲rò㢨l耻ü䃼angle;榧ހABDacdeflnoprsz㤜㤟㤩㤭㦵㦸㦽㧟㧤㧨㧳㧹㧽㨁㨠ròϷarĀ;v㤦㤧櫨;櫩asèϡĀnr㤲㤷grt;榜΀eknprst㓣㥆㥋㥒㥝㥤㦖appá␕othinçẖƀhir㓫⻈㥙opô⾵Ā;hᎷ㥢ïㆍĀiu㥩㥭gmá㎳Ābp㥲㦄setneqĀ;q㥽㦀쀀⊊︀;쀀⫋︀setneqĀ;q㦏㦒쀀⊋︀;쀀⫌︀Āhr㦛㦟etá㚜iangleĀlr㦪㦯eft»थight»ၑy;䐲ash»ံƀelr㧄㧒㧗ƀ;beⷪ㧋㧏ar;抻q;扚lip;拮Ābt㧜ᑨaòᑩr;쀀𝔳tré㦮suĀbp㧯㧱»ജ»൙pf;쀀𝕧roð໻tré㦴Ācu㨆㨋r;쀀𝓋Ābp㨐㨘nĀEe㦀㨖»㥾nĀEe㦒㨞»㦐igzag;榚΀cefoprs㨶㨻㩖㩛㩔㩡㩪irc;䅵Ādi㩀㩑Ābg㩅㩉ar;機eĀ;qᗺ㩏;扙erp;愘r;쀀𝔴pf;쀀𝕨Ā;eᑹ㩦atèᑹcr;쀀𝓌ૣណ㪇\0㪋\0㪐㪛\0\0㪝㪨㪫㪯\0\0㫃㫎\0㫘ៜ៟tré៑r;쀀𝔵ĀAa㪔㪗ròσrò৶;䎾ĀAa㪡㪤ròθrò৫að✓is;拻ƀdptឤ㪵㪾Āfl㪺ឩ;쀀𝕩imåឲĀAa㫇㫊ròώròਁĀcq㫒ីr;쀀𝓍Āpt៖㫜ré។Ѐacefiosu㫰㫽㬈㬌㬑㬕㬛㬡cĀuy㫶㫻te耻ý䃽;䑏Āiy㬂㬆rc;䅷;䑋n耻¥䂥r;쀀𝔶cy;䑗pf;쀀𝕪cr;쀀𝓎Ācm㬦㬩y;䑎l耻ÿ䃿Ԁacdefhiosw㭂㭈㭔㭘㭤㭩㭭㭴㭺㮀cute;䅺Āay㭍㭒ron;䅾;䐷ot;䅼Āet㭝㭡træᕟa;䎶r;쀀𝔷cy;䐶grarr;懝pf;쀀𝕫cr;쀀𝓏Ājn㮅㮇;怍j;怌'.split("").map(e=>e.charCodeAt(0))),tBe=new Uint16Array("Ȁaglq \x1Bɭ\0\0p;䀦os;䀧t;䀾t;䀼uot;䀢".split("").map(e=>e.charCodeAt(0)));var xO;const nBe=new Map([[0,65533],[128,8364],[130,8218],[131,402],[132,8222],[133,8230],[134,8224],[135,8225],[136,710],[137,8240],[138,352],[139,8249],[140,338],[142,381],[145,8216],[146,8217],[147,8220],[148,8221],[149,8226],[150,8211],[151,8212],[152,732],[153,8482],[154,353],[155,8250],[156,339],[158,382],[159,376]]),rBe=(xO=String.fromCodePoint)!==null&&xO!==void 0?xO:function(e){let t="";return e>65535&&(e-=65536,t+=String.fromCharCode(e>>>10&1023|55296),e=56320|e&1023),t+=String.fromCharCode(e),t};function iBe(e){var t;return e>=55296&&e<=57343||e>1114111?65533:(t=nBe.get(e))!==null&&t!==void 0?t:e}var mi;(function(e){e[e.NUM=35]="NUM",e[e.SEMI=59]="SEMI",e[e.EQUALS=61]="EQUALS",e[e.ZERO=48]="ZERO",e[e.NINE=57]="NINE",e[e.LOWER_A=97]="LOWER_A",e[e.LOWER_F=102]="LOWER_F",e[e.LOWER_X=120]="LOWER_X",e[e.LOWER_Z=122]="LOWER_Z",e[e.UPPER_A=65]="UPPER_A",e[e.UPPER_F=70]="UPPER_F",e[e.UPPER_Z=90]="UPPER_Z"})(mi||(mi={}));const sBe=32;var Ru;(function(e){e[e.VALUE_LENGTH=49152]="VALUE_LENGTH",e[e.BRANCH_LENGTH=16256]="BRANCH_LENGTH",e[e.JUMP_TABLE=127]="JUMP_TABLE"})(Ru||(Ru={}));function NN(e){return e>=mi.ZERO&&e<=mi.NINE}function oBe(e){return e>=mi.UPPER_A&&e<=mi.UPPER_F||e>=mi.LOWER_A&&e<=mi.LOWER_F}function aBe(e){return e>=mi.UPPER_A&&e<=mi.UPPER_Z||e>=mi.LOWER_A&&e<=mi.LOWER_Z||NN(e)}function uBe(e){return e===mi.EQUALS||aBe(e)}var li;(function(e){e[e.EntityStart=0]="EntityStart",e[e.NumericStart=1]="NumericStart",e[e.NumericDecimal=2]="NumericDecimal",e[e.NumericHex=3]="NumericHex",e[e.NamedEntity=4]="NamedEntity"})(li||(li={}));var Cd;(function(e){e[e.Legacy=0]="Legacy",e[e.Strict=1]="Strict",e[e.Attribute=2]="Attribute"})(Cd||(Cd={}));class lBe{constructor(t,n,r){this.decodeTree=t,this.emitCodePoint=n,this.errors=r,this.state=li.EntityStart,this.consumed=1,this.result=0,this.treeIndex=0,this.excess=1,this.decodeMode=Cd.Strict}startEntity(t){this.decodeMode=t,this.state=li.EntityStart,this.result=0,this.treeIndex=0,this.excess=1,this.consumed=1}write(t,n){switch(this.state){case li.EntityStart:return t.charCodeAt(n)===mi.NUM?(this.state=li.NumericStart,this.consumed+=1,this.stateNumericStart(t,n+1)):(this.state=li.NamedEntity,this.stateNamedEntity(t,n));case li.NumericStart:return this.stateNumericStart(t,n);case li.NumericDecimal:return this.stateNumericDecimal(t,n);case li.NumericHex:return this.stateNumericHex(t,n);case li.NamedEntity:return this.stateNamedEntity(t,n)}}stateNumericStart(t,n){return n>=t.length?-1:(t.charCodeAt(n)|sBe)===mi.LOWER_X?(this.state=li.NumericHex,this.consumed+=1,this.stateNumericHex(t,n+1)):(this.state=li.NumericDecimal,this.stateNumericDecimal(t,n))}addToNumericResult(t,n,r,i){if(n!==r){const s=r-n;this.result=this.result*Math.pow(i,s)+parseInt(t.substr(n,s),i),this.consumed+=s}}stateNumericHex(t,n){const r=n;for(;n>14;for(;n>14,s!==0){if(o===mi.SEMI)return this.emitNamedEntityData(this.treeIndex,s,this.consumed+this.excess);this.decodeMode!==Cd.Strict&&(this.result=this.treeIndex,this.consumed+=this.excess,this.excess=0)}}return-1}emitNotTerminatedNamedEntity(){var t;const{result:n,decodeTree:r}=this,i=(r[n]&Ru.VALUE_LENGTH)>>14;return this.emitNamedEntityData(n,i,this.consumed),(t=this.errors)===null||t===void 0||t.missingSemicolonAfterCharacterReference(),this.consumed}emitNamedEntityData(t,n,r){const{decodeTree:i}=this;return this.emitCodePoint(n===1?i[t]&~Ru.VALUE_LENGTH:i[t+1],r),n===3&&this.emitCodePoint(i[t+2],r),r}end(){var t;switch(this.state){case li.NamedEntity:return this.result!==0&&(this.decodeMode!==Cd.Attribute||this.result===this.treeIndex)?this.emitNotTerminatedNamedEntity():0;case li.NumericDecimal:return this.emitNumericEntity(0,2);case li.NumericHex:return this.emitNumericEntity(0,3);case li.NumericStart:return(t=this.errors)===null||t===void 0||t.absenceOfDigitsInNumericCharacterReference(this.consumed),0;case li.EntityStart:return 0}}}function Hre(e){let t="";const n=new lBe(e,r=>t+=rBe(r));return function(i,s){let o=0,a=0;for(;(a=i.indexOf("&",a))>=0;){t+=i.slice(o,a),n.startEntity(s);const l=n.write(i,a+1);if(l<0){o=a+n.end();break}o=a+l,a=l===0?o+1:o}const u=t+i.slice(o);return t="",u}}function Wre(e,t,n,r){const i=(t&Ru.BRANCH_LENGTH)>>7,s=t&Ru.JUMP_TABLE;if(i===0)return s!==0&&r===s?n:-1;if(s){const u=r-s;return u<0||u>=i?-1:e[n+u]-1}let o=n,a=o+i-1;for(;o<=a;){const u=o+a>>>1,l=e[u];if(lr)a=u-1;else return e[u+i]}return-1}Hre(Oc);Hre(tBe);var we;(function(e){e.HTML="http://www.w3.org/1999/xhtml",e.MATHML="http://www.w3.org/1998/Math/MathML",e.SVG="http://www.w3.org/2000/svg",e.XLINK="http://www.w3.org/1999/xlink",e.XML="http://www.w3.org/XML/1998/namespace",e.XMLNS="http://www.w3.org/2000/xmlns/"})(we=we||(we={}));var gf;(function(e){e.TYPE="type",e.ACTION="action",e.ENCODING="encoding",e.PROMPT="prompt",e.NAME="name",e.COLOR="color",e.FACE="face",e.SIZE="size"})(gf=gf||(gf={}));var go;(function(e){e.NO_QUIRKS="no-quirks",e.QUIRKS="quirks",e.LIMITED_QUIRKS="limited-quirks"})(go=go||(go={}));var le;(function(e){e.A="a",e.ADDRESS="address",e.ANNOTATION_XML="annotation-xml",e.APPLET="applet",e.AREA="area",e.ARTICLE="article",e.ASIDE="aside",e.B="b",e.BASE="base",e.BASEFONT="basefont",e.BGSOUND="bgsound",e.BIG="big",e.BLOCKQUOTE="blockquote",e.BODY="body",e.BR="br",e.BUTTON="button",e.CAPTION="caption",e.CENTER="center",e.CODE="code",e.COL="col",e.COLGROUP="colgroup",e.DD="dd",e.DESC="desc",e.DETAILS="details",e.DIALOG="dialog",e.DIR="dir",e.DIV="div",e.DL="dl",e.DT="dt",e.EM="em",e.EMBED="embed",e.FIELDSET="fieldset",e.FIGCAPTION="figcaption",e.FIGURE="figure",e.FONT="font",e.FOOTER="footer",e.FOREIGN_OBJECT="foreignObject",e.FORM="form",e.FRAME="frame",e.FRAMESET="frameset",e.H1="h1",e.H2="h2",e.H3="h3",e.H4="h4",e.H5="h5",e.H6="h6",e.HEAD="head",e.HEADER="header",e.HGROUP="hgroup",e.HR="hr",e.HTML="html",e.I="i",e.IMG="img",e.IMAGE="image",e.INPUT="input",e.IFRAME="iframe",e.KEYGEN="keygen",e.LABEL="label",e.LI="li",e.LINK="link",e.LISTING="listing",e.MAIN="main",e.MALIGNMARK="malignmark",e.MARQUEE="marquee",e.MATH="math",e.MENU="menu",e.META="meta",e.MGLYPH="mglyph",e.MI="mi",e.MO="mo",e.MN="mn",e.MS="ms",e.MTEXT="mtext",e.NAV="nav",e.NOBR="nobr",e.NOFRAMES="noframes",e.NOEMBED="noembed",e.NOSCRIPT="noscript",e.OBJECT="object",e.OL="ol",e.OPTGROUP="optgroup",e.OPTION="option",e.P="p",e.PARAM="param",e.PLAINTEXT="plaintext",e.PRE="pre",e.RB="rb",e.RP="rp",e.RT="rt",e.RTC="rtc",e.RUBY="ruby",e.S="s",e.SCRIPT="script",e.SECTION="section",e.SELECT="select",e.SOURCE="source",e.SMALL="small",e.SPAN="span",e.STRIKE="strike",e.STRONG="strong",e.STYLE="style",e.SUB="sub",e.SUMMARY="summary",e.SUP="sup",e.TABLE="table",e.TBODY="tbody",e.TEMPLATE="template",e.TEXTAREA="textarea",e.TFOOT="tfoot",e.TD="td",e.TH="th",e.THEAD="thead",e.TITLE="title",e.TR="tr",e.TRACK="track",e.TT="tt",e.U="u",e.UL="ul",e.SVG="svg",e.VAR="var",e.WBR="wbr",e.XMP="xmp"})(le=le||(le={}));var _;(function(e){e[e.UNKNOWN=0]="UNKNOWN",e[e.A=1]="A",e[e.ADDRESS=2]="ADDRESS",e[e.ANNOTATION_XML=3]="ANNOTATION_XML",e[e.APPLET=4]="APPLET",e[e.AREA=5]="AREA",e[e.ARTICLE=6]="ARTICLE",e[e.ASIDE=7]="ASIDE",e[e.B=8]="B",e[e.BASE=9]="BASE",e[e.BASEFONT=10]="BASEFONT",e[e.BGSOUND=11]="BGSOUND",e[e.BIG=12]="BIG",e[e.BLOCKQUOTE=13]="BLOCKQUOTE",e[e.BODY=14]="BODY",e[e.BR=15]="BR",e[e.BUTTON=16]="BUTTON",e[e.CAPTION=17]="CAPTION",e[e.CENTER=18]="CENTER",e[e.CODE=19]="CODE",e[e.COL=20]="COL",e[e.COLGROUP=21]="COLGROUP",e[e.DD=22]="DD",e[e.DESC=23]="DESC",e[e.DETAILS=24]="DETAILS",e[e.DIALOG=25]="DIALOG",e[e.DIR=26]="DIR",e[e.DIV=27]="DIV",e[e.DL=28]="DL",e[e.DT=29]="DT",e[e.EM=30]="EM",e[e.EMBED=31]="EMBED",e[e.FIELDSET=32]="FIELDSET",e[e.FIGCAPTION=33]="FIGCAPTION",e[e.FIGURE=34]="FIGURE",e[e.FONT=35]="FONT",e[e.FOOTER=36]="FOOTER",e[e.FOREIGN_OBJECT=37]="FOREIGN_OBJECT",e[e.FORM=38]="FORM",e[e.FRAME=39]="FRAME",e[e.FRAMESET=40]="FRAMESET",e[e.H1=41]="H1",e[e.H2=42]="H2",e[e.H3=43]="H3",e[e.H4=44]="H4",e[e.H5=45]="H5",e[e.H6=46]="H6",e[e.HEAD=47]="HEAD",e[e.HEADER=48]="HEADER",e[e.HGROUP=49]="HGROUP",e[e.HR=50]="HR",e[e.HTML=51]="HTML",e[e.I=52]="I",e[e.IMG=53]="IMG",e[e.IMAGE=54]="IMAGE",e[e.INPUT=55]="INPUT",e[e.IFRAME=56]="IFRAME",e[e.KEYGEN=57]="KEYGEN",e[e.LABEL=58]="LABEL",e[e.LI=59]="LI",e[e.LINK=60]="LINK",e[e.LISTING=61]="LISTING",e[e.MAIN=62]="MAIN",e[e.MALIGNMARK=63]="MALIGNMARK",e[e.MARQUEE=64]="MARQUEE",e[e.MATH=65]="MATH",e[e.MENU=66]="MENU",e[e.META=67]="META",e[e.MGLYPH=68]="MGLYPH",e[e.MI=69]="MI",e[e.MO=70]="MO",e[e.MN=71]="MN",e[e.MS=72]="MS",e[e.MTEXT=73]="MTEXT",e[e.NAV=74]="NAV",e[e.NOBR=75]="NOBR",e[e.NOFRAMES=76]="NOFRAMES",e[e.NOEMBED=77]="NOEMBED",e[e.NOSCRIPT=78]="NOSCRIPT",e[e.OBJECT=79]="OBJECT",e[e.OL=80]="OL",e[e.OPTGROUP=81]="OPTGROUP",e[e.OPTION=82]="OPTION",e[e.P=83]="P",e[e.PARAM=84]="PARAM",e[e.PLAINTEXT=85]="PLAINTEXT",e[e.PRE=86]="PRE",e[e.RB=87]="RB",e[e.RP=88]="RP",e[e.RT=89]="RT",e[e.RTC=90]="RTC",e[e.RUBY=91]="RUBY",e[e.S=92]="S",e[e.SCRIPT=93]="SCRIPT",e[e.SECTION=94]="SECTION",e[e.SELECT=95]="SELECT",e[e.SOURCE=96]="SOURCE",e[e.SMALL=97]="SMALL",e[e.SPAN=98]="SPAN",e[e.STRIKE=99]="STRIKE",e[e.STRONG=100]="STRONG",e[e.STYLE=101]="STYLE",e[e.SUB=102]="SUB",e[e.SUMMARY=103]="SUMMARY",e[e.SUP=104]="SUP",e[e.TABLE=105]="TABLE",e[e.TBODY=106]="TBODY",e[e.TEMPLATE=107]="TEMPLATE",e[e.TEXTAREA=108]="TEXTAREA",e[e.TFOOT=109]="TFOOT",e[e.TD=110]="TD",e[e.TH=111]="TH",e[e.THEAD=112]="THEAD",e[e.TITLE=113]="TITLE",e[e.TR=114]="TR",e[e.TRACK=115]="TRACK",e[e.TT=116]="TT",e[e.U=117]="U",e[e.UL=118]="UL",e[e.SVG=119]="SVG",e[e.VAR=120]="VAR",e[e.WBR=121]="WBR",e[e.XMP=122]="XMP"})(_=_||(_={}));const cBe=new Map([[le.A,_.A],[le.ADDRESS,_.ADDRESS],[le.ANNOTATION_XML,_.ANNOTATION_XML],[le.APPLET,_.APPLET],[le.AREA,_.AREA],[le.ARTICLE,_.ARTICLE],[le.ASIDE,_.ASIDE],[le.B,_.B],[le.BASE,_.BASE],[le.BASEFONT,_.BASEFONT],[le.BGSOUND,_.BGSOUND],[le.BIG,_.BIG],[le.BLOCKQUOTE,_.BLOCKQUOTE],[le.BODY,_.BODY],[le.BR,_.BR],[le.BUTTON,_.BUTTON],[le.CAPTION,_.CAPTION],[le.CENTER,_.CENTER],[le.CODE,_.CODE],[le.COL,_.COL],[le.COLGROUP,_.COLGROUP],[le.DD,_.DD],[le.DESC,_.DESC],[le.DETAILS,_.DETAILS],[le.DIALOG,_.DIALOG],[le.DIR,_.DIR],[le.DIV,_.DIV],[le.DL,_.DL],[le.DT,_.DT],[le.EM,_.EM],[le.EMBED,_.EMBED],[le.FIELDSET,_.FIELDSET],[le.FIGCAPTION,_.FIGCAPTION],[le.FIGURE,_.FIGURE],[le.FONT,_.FONT],[le.FOOTER,_.FOOTER],[le.FOREIGN_OBJECT,_.FOREIGN_OBJECT],[le.FORM,_.FORM],[le.FRAME,_.FRAME],[le.FRAMESET,_.FRAMESET],[le.H1,_.H1],[le.H2,_.H2],[le.H3,_.H3],[le.H4,_.H4],[le.H5,_.H5],[le.H6,_.H6],[le.HEAD,_.HEAD],[le.HEADER,_.HEADER],[le.HGROUP,_.HGROUP],[le.HR,_.HR],[le.HTML,_.HTML],[le.I,_.I],[le.IMG,_.IMG],[le.IMAGE,_.IMAGE],[le.INPUT,_.INPUT],[le.IFRAME,_.IFRAME],[le.KEYGEN,_.KEYGEN],[le.LABEL,_.LABEL],[le.LI,_.LI],[le.LINK,_.LINK],[le.LISTING,_.LISTING],[le.MAIN,_.MAIN],[le.MALIGNMARK,_.MALIGNMARK],[le.MARQUEE,_.MARQUEE],[le.MATH,_.MATH],[le.MENU,_.MENU],[le.META,_.META],[le.MGLYPH,_.MGLYPH],[le.MI,_.MI],[le.MO,_.MO],[le.MN,_.MN],[le.MS,_.MS],[le.MTEXT,_.MTEXT],[le.NAV,_.NAV],[le.NOBR,_.NOBR],[le.NOFRAMES,_.NOFRAMES],[le.NOEMBED,_.NOEMBED],[le.NOSCRIPT,_.NOSCRIPT],[le.OBJECT,_.OBJECT],[le.OL,_.OL],[le.OPTGROUP,_.OPTGROUP],[le.OPTION,_.OPTION],[le.P,_.P],[le.PARAM,_.PARAM],[le.PLAINTEXT,_.PLAINTEXT],[le.PRE,_.PRE],[le.RB,_.RB],[le.RP,_.RP],[le.RT,_.RT],[le.RTC,_.RTC],[le.RUBY,_.RUBY],[le.S,_.S],[le.SCRIPT,_.SCRIPT],[le.SECTION,_.SECTION],[le.SELECT,_.SELECT],[le.SOURCE,_.SOURCE],[le.SMALL,_.SMALL],[le.SPAN,_.SPAN],[le.STRIKE,_.STRIKE],[le.STRONG,_.STRONG],[le.STYLE,_.STYLE],[le.SUB,_.SUB],[le.SUMMARY,_.SUMMARY],[le.SUP,_.SUP],[le.TABLE,_.TABLE],[le.TBODY,_.TBODY],[le.TEMPLATE,_.TEMPLATE],[le.TEXTAREA,_.TEXTAREA],[le.TFOOT,_.TFOOT],[le.TD,_.TD],[le.TH,_.TH],[le.THEAD,_.THEAD],[le.TITLE,_.TITLE],[le.TR,_.TR],[le.TRACK,_.TRACK],[le.TT,_.TT],[le.U,_.U],[le.UL,_.UL],[le.SVG,_.SVG],[le.VAR,_.VAR],[le.WBR,_.WBR],[le.XMP,_.XMP]]);function Og(e){var t;return(t=cBe.get(e))!==null&&t!==void 0?t:_.UNKNOWN}const Ae=_,fBe={[we.HTML]:new Set([Ae.ADDRESS,Ae.APPLET,Ae.AREA,Ae.ARTICLE,Ae.ASIDE,Ae.BASE,Ae.BASEFONT,Ae.BGSOUND,Ae.BLOCKQUOTE,Ae.BODY,Ae.BR,Ae.BUTTON,Ae.CAPTION,Ae.CENTER,Ae.COL,Ae.COLGROUP,Ae.DD,Ae.DETAILS,Ae.DIR,Ae.DIV,Ae.DL,Ae.DT,Ae.EMBED,Ae.FIELDSET,Ae.FIGCAPTION,Ae.FIGURE,Ae.FOOTER,Ae.FORM,Ae.FRAME,Ae.FRAMESET,Ae.H1,Ae.H2,Ae.H3,Ae.H4,Ae.H5,Ae.H6,Ae.HEAD,Ae.HEADER,Ae.HGROUP,Ae.HR,Ae.HTML,Ae.IFRAME,Ae.IMG,Ae.INPUT,Ae.LI,Ae.LINK,Ae.LISTING,Ae.MAIN,Ae.MARQUEE,Ae.MENU,Ae.META,Ae.NAV,Ae.NOEMBED,Ae.NOFRAMES,Ae.NOSCRIPT,Ae.OBJECT,Ae.OL,Ae.P,Ae.PARAM,Ae.PLAINTEXT,Ae.PRE,Ae.SCRIPT,Ae.SECTION,Ae.SELECT,Ae.SOURCE,Ae.STYLE,Ae.SUMMARY,Ae.TABLE,Ae.TBODY,Ae.TD,Ae.TEMPLATE,Ae.TEXTAREA,Ae.TFOOT,Ae.TH,Ae.THEAD,Ae.TITLE,Ae.TR,Ae.TRACK,Ae.UL,Ae.WBR,Ae.XMP]),[we.MATHML]:new Set([Ae.MI,Ae.MO,Ae.MN,Ae.MS,Ae.MTEXT,Ae.ANNOTATION_XML]),[we.SVG]:new Set([Ae.TITLE,Ae.FOREIGN_OBJECT,Ae.DESC]),[we.XLINK]:new Set,[we.XML]:new Set,[we.XMLNS]:new Set};function qre(e){return e===Ae.H1||e===Ae.H2||e===Ae.H3||e===Ae.H4||e===Ae.H5||e===Ae.H6}le.STYLE,le.SCRIPT,le.XMP,le.IFRAME,le.NOEMBED,le.NOFRAMES,le.PLAINTEXT;const dBe=new Map([[128,8364],[130,8218],[131,402],[132,8222],[133,8230],[134,8224],[135,8225],[136,710],[137,8240],[138,352],[139,8249],[140,338],[142,381],[145,8216],[146,8217],[147,8220],[148,8221],[149,8226],[150,8211],[151,8212],[152,732],[153,8482],[154,353],[155,8250],[156,339],[158,382],[159,376]]);var U;(function(e){e[e.DATA=0]="DATA",e[e.RCDATA=1]="RCDATA",e[e.RAWTEXT=2]="RAWTEXT",e[e.SCRIPT_DATA=3]="SCRIPT_DATA",e[e.PLAINTEXT=4]="PLAINTEXT",e[e.TAG_OPEN=5]="TAG_OPEN",e[e.END_TAG_OPEN=6]="END_TAG_OPEN",e[e.TAG_NAME=7]="TAG_NAME",e[e.RCDATA_LESS_THAN_SIGN=8]="RCDATA_LESS_THAN_SIGN",e[e.RCDATA_END_TAG_OPEN=9]="RCDATA_END_TAG_OPEN",e[e.RCDATA_END_TAG_NAME=10]="RCDATA_END_TAG_NAME",e[e.RAWTEXT_LESS_THAN_SIGN=11]="RAWTEXT_LESS_THAN_SIGN",e[e.RAWTEXT_END_TAG_OPEN=12]="RAWTEXT_END_TAG_OPEN",e[e.RAWTEXT_END_TAG_NAME=13]="RAWTEXT_END_TAG_NAME",e[e.SCRIPT_DATA_LESS_THAN_SIGN=14]="SCRIPT_DATA_LESS_THAN_SIGN",e[e.SCRIPT_DATA_END_TAG_OPEN=15]="SCRIPT_DATA_END_TAG_OPEN",e[e.SCRIPT_DATA_END_TAG_NAME=16]="SCRIPT_DATA_END_TAG_NAME",e[e.SCRIPT_DATA_ESCAPE_START=17]="SCRIPT_DATA_ESCAPE_START",e[e.SCRIPT_DATA_ESCAPE_START_DASH=18]="SCRIPT_DATA_ESCAPE_START_DASH",e[e.SCRIPT_DATA_ESCAPED=19]="SCRIPT_DATA_ESCAPED",e[e.SCRIPT_DATA_ESCAPED_DASH=20]="SCRIPT_DATA_ESCAPED_DASH",e[e.SCRIPT_DATA_ESCAPED_DASH_DASH=21]="SCRIPT_DATA_ESCAPED_DASH_DASH",e[e.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN=22]="SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN",e[e.SCRIPT_DATA_ESCAPED_END_TAG_OPEN=23]="SCRIPT_DATA_ESCAPED_END_TAG_OPEN",e[e.SCRIPT_DATA_ESCAPED_END_TAG_NAME=24]="SCRIPT_DATA_ESCAPED_END_TAG_NAME",e[e.SCRIPT_DATA_DOUBLE_ESCAPE_START=25]="SCRIPT_DATA_DOUBLE_ESCAPE_START",e[e.SCRIPT_DATA_DOUBLE_ESCAPED=26]="SCRIPT_DATA_DOUBLE_ESCAPED",e[e.SCRIPT_DATA_DOUBLE_ESCAPED_DASH=27]="SCRIPT_DATA_DOUBLE_ESCAPED_DASH",e[e.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH=28]="SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH",e[e.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN=29]="SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN",e[e.SCRIPT_DATA_DOUBLE_ESCAPE_END=30]="SCRIPT_DATA_DOUBLE_ESCAPE_END",e[e.BEFORE_ATTRIBUTE_NAME=31]="BEFORE_ATTRIBUTE_NAME",e[e.ATTRIBUTE_NAME=32]="ATTRIBUTE_NAME",e[e.AFTER_ATTRIBUTE_NAME=33]="AFTER_ATTRIBUTE_NAME",e[e.BEFORE_ATTRIBUTE_VALUE=34]="BEFORE_ATTRIBUTE_VALUE",e[e.ATTRIBUTE_VALUE_DOUBLE_QUOTED=35]="ATTRIBUTE_VALUE_DOUBLE_QUOTED",e[e.ATTRIBUTE_VALUE_SINGLE_QUOTED=36]="ATTRIBUTE_VALUE_SINGLE_QUOTED",e[e.ATTRIBUTE_VALUE_UNQUOTED=37]="ATTRIBUTE_VALUE_UNQUOTED",e[e.AFTER_ATTRIBUTE_VALUE_QUOTED=38]="AFTER_ATTRIBUTE_VALUE_QUOTED",e[e.SELF_CLOSING_START_TAG=39]="SELF_CLOSING_START_TAG",e[e.BOGUS_COMMENT=40]="BOGUS_COMMENT",e[e.MARKUP_DECLARATION_OPEN=41]="MARKUP_DECLARATION_OPEN",e[e.COMMENT_START=42]="COMMENT_START",e[e.COMMENT_START_DASH=43]="COMMENT_START_DASH",e[e.COMMENT=44]="COMMENT",e[e.COMMENT_LESS_THAN_SIGN=45]="COMMENT_LESS_THAN_SIGN",e[e.COMMENT_LESS_THAN_SIGN_BANG=46]="COMMENT_LESS_THAN_SIGN_BANG",e[e.COMMENT_LESS_THAN_SIGN_BANG_DASH=47]="COMMENT_LESS_THAN_SIGN_BANG_DASH",e[e.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH=48]="COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH",e[e.COMMENT_END_DASH=49]="COMMENT_END_DASH",e[e.COMMENT_END=50]="COMMENT_END",e[e.COMMENT_END_BANG=51]="COMMENT_END_BANG",e[e.DOCTYPE=52]="DOCTYPE",e[e.BEFORE_DOCTYPE_NAME=53]="BEFORE_DOCTYPE_NAME",e[e.DOCTYPE_NAME=54]="DOCTYPE_NAME",e[e.AFTER_DOCTYPE_NAME=55]="AFTER_DOCTYPE_NAME",e[e.AFTER_DOCTYPE_PUBLIC_KEYWORD=56]="AFTER_DOCTYPE_PUBLIC_KEYWORD",e[e.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER=57]="BEFORE_DOCTYPE_PUBLIC_IDENTIFIER",e[e.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED=58]="DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED",e[e.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED=59]="DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED",e[e.AFTER_DOCTYPE_PUBLIC_IDENTIFIER=60]="AFTER_DOCTYPE_PUBLIC_IDENTIFIER",e[e.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS=61]="BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS",e[e.AFTER_DOCTYPE_SYSTEM_KEYWORD=62]="AFTER_DOCTYPE_SYSTEM_KEYWORD",e[e.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER=63]="BEFORE_DOCTYPE_SYSTEM_IDENTIFIER",e[e.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED=64]="DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED",e[e.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED=65]="DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED",e[e.AFTER_DOCTYPE_SYSTEM_IDENTIFIER=66]="AFTER_DOCTYPE_SYSTEM_IDENTIFIER",e[e.BOGUS_DOCTYPE=67]="BOGUS_DOCTYPE",e[e.CDATA_SECTION=68]="CDATA_SECTION",e[e.CDATA_SECTION_BRACKET=69]="CDATA_SECTION_BRACKET",e[e.CDATA_SECTION_END=70]="CDATA_SECTION_END",e[e.CHARACTER_REFERENCE=71]="CHARACTER_REFERENCE",e[e.NAMED_CHARACTER_REFERENCE=72]="NAMED_CHARACTER_REFERENCE",e[e.AMBIGUOUS_AMPERSAND=73]="AMBIGUOUS_AMPERSAND",e[e.NUMERIC_CHARACTER_REFERENCE=74]="NUMERIC_CHARACTER_REFERENCE",e[e.HEXADEMICAL_CHARACTER_REFERENCE_START=75]="HEXADEMICAL_CHARACTER_REFERENCE_START",e[e.HEXADEMICAL_CHARACTER_REFERENCE=76]="HEXADEMICAL_CHARACTER_REFERENCE",e[e.DECIMAL_CHARACTER_REFERENCE=77]="DECIMAL_CHARACTER_REFERENCE",e[e.NUMERIC_CHARACTER_REFERENCE_END=78]="NUMERIC_CHARACTER_REFERENCE_END"})(U||(U={}));const Mr={DATA:U.DATA,RCDATA:U.RCDATA,RAWTEXT:U.RAWTEXT,SCRIPT_DATA:U.SCRIPT_DATA,PLAINTEXT:U.PLAINTEXT,CDATA_SECTION:U.CDATA_SECTION};function Py(e){return e>=M.DIGIT_0&&e<=M.DIGIT_9}function X0(e){return e>=M.LATIN_CAPITAL_A&&e<=M.LATIN_CAPITAL_Z}function hBe(e){return e>=M.LATIN_SMALL_A&&e<=M.LATIN_SMALL_Z}function Rc(e){return hBe(e)||X0(e)}function kN(e){return Rc(e)||Py(e)}function Gre(e){return e>=M.LATIN_CAPITAL_A&&e<=M.LATIN_CAPITAL_F}function Yre(e){return e>=M.LATIN_SMALL_A&&e<=M.LATIN_SMALL_F}function pBe(e){return Py(e)||Gre(e)||Yre(e)}function Rb(e){return e+32}function Kre(e){return e===M.SPACE||e===M.LINE_FEED||e===M.TABULATION||e===M.FORM_FEED}function mBe(e){return e===M.EQUALS_SIGN||kN(e)}function g7(e){return Kre(e)||e===M.SOLIDUS||e===M.GREATER_THAN_SIGN}class gBe{constructor(t,n){this.options=t,this.handler=n,this.paused=!1,this.inLoop=!1,this.inForeignNode=!1,this.lastStartTagName="",this.active=!1,this.state=U.DATA,this.returnState=U.DATA,this.charRefCode=-1,this.consumedAfterSnapshot=-1,this.currentCharacterToken=null,this.currentToken=null,this.currentAttr={name:"",value:""},this.preprocessor=new eBe(n),this.currentLocation=this.getCurrentLocation(-1)}_err(t){var n,r;(r=(n=this.handler).onParseError)===null||r===void 0||r.call(n,this.preprocessor.getError(t))}getCurrentLocation(t){return this.options.sourceCodeLocationInfo?{startLine:this.preprocessor.line,startCol:this.preprocessor.col-t,startOffset:this.preprocessor.offset-t,endLine:-1,endCol:-1,endOffset:-1}:null}_runParsingLoop(){if(!this.inLoop){for(this.inLoop=!0;this.active&&!this.paused;){this.consumedAfterSnapshot=0;const t=this._consume();this._ensureHibernation()||this._callState(t)}this.inLoop=!1}}pause(){this.paused=!0}resume(t){if(!this.paused)throw new Error("Parser was already resumed");this.paused=!1,!this.inLoop&&(this._runParsingLoop(),this.paused||t==null||t())}write(t,n,r){this.active=!0,this.preprocessor.write(t,n),this._runParsingLoop(),this.paused||r==null||r()}insertHtmlAtCurrentPos(t){this.active=!0,this.preprocessor.insertHtmlAtCurrentPos(t),this._runParsingLoop()}_ensureHibernation(){return this.preprocessor.endOfChunkHit?(this._unconsume(this.consumedAfterSnapshot),this.active=!1,!0):!1}_consume(){return this.consumedAfterSnapshot++,this.preprocessor.advance()}_unconsume(t){this.consumedAfterSnapshot-=t,this.preprocessor.retreat(t)}_reconsumeInState(t,n){this.state=t,this._callState(n)}_advanceBy(t){this.consumedAfterSnapshot+=t;for(let n=0;n0&&this._err(_e.endTagWithAttributes),t.selfClosing&&this._err(_e.endTagWithTrailingSolidus),this.handler.onEndTag(t)),this.preprocessor.dropParsedChunk()}emitCurrentComment(t){this.prepareToken(t),this.handler.onComment(t),this.preprocessor.dropParsedChunk()}emitCurrentDoctype(t){this.prepareToken(t),this.handler.onDoctype(t),this.preprocessor.dropParsedChunk()}_emitCurrentCharacterToken(t){if(this.currentCharacterToken){switch(t&&this.currentCharacterToken.location&&(this.currentCharacterToken.location.endLine=t.startLine,this.currentCharacterToken.location.endCol=t.startCol,this.currentCharacterToken.location.endOffset=t.startOffset),this.currentCharacterToken.type){case Yt.CHARACTER:{this.handler.onCharacter(this.currentCharacterToken);break}case Yt.NULL_CHARACTER:{this.handler.onNullCharacter(this.currentCharacterToken);break}case Yt.WHITESPACE_CHARACTER:{this.handler.onWhitespaceCharacter(this.currentCharacterToken);break}}this.currentCharacterToken=null}}_emitEOFToken(){const t=this.getCurrentLocation(0);t&&(t.endLine=t.startLine,t.endCol=t.startCol,t.endOffset=t.startOffset),this._emitCurrentCharacterToken(t),this.handler.onEof({type:Yt.EOF,location:t}),this.active=!1}_appendCharToCurrentCharacterToken(t,n){if(this.currentCharacterToken)if(this.currentCharacterToken.type!==t)this.currentLocation=this.getCurrentLocation(0),this._emitCurrentCharacterToken(this.currentLocation),this.preprocessor.dropParsedChunk();else{this.currentCharacterToken.chars+=n;return}this._createCharacterToken(t,n)}_emitCodePoint(t){const n=Kre(t)?Yt.WHITESPACE_CHARACTER:t===M.NULL?Yt.NULL_CHARACTER:Yt.CHARACTER;this._appendCharToCurrentCharacterToken(n,String.fromCodePoint(t))}_emitChars(t){this._appendCharToCurrentCharacterToken(Yt.CHARACTER,t)}_matchNamedCharacterReference(t){let n=null,r=0,i=!1;for(let s=0,o=Oc[0];s>=0&&(s=Wre(Oc,o,s+1,t),!(s<0));t=this._consume()){r+=1,o=Oc[s];const a=o&Ru.VALUE_LENGTH;if(a){const u=(a>>14)-1;if(t!==M.SEMICOLON&&this._isCharacterReferenceInAttribute()&&mBe(this.preprocessor.peek(1))?(n=[M.AMPERSAND],s+=u):(n=u===0?[Oc[s]&~Ru.VALUE_LENGTH]:u===1?[Oc[++s]]:[Oc[++s],Oc[++s]],r=0,i=t!==M.SEMICOLON),u===0){this._consume();break}}}return this._unconsume(r),i&&!this.preprocessor.endOfChunkHit&&this._err(_e.missingSemicolonAfterCharacterReference),this._unconsume(1),n}_isCharacterReferenceInAttribute(){return this.returnState===U.ATTRIBUTE_VALUE_DOUBLE_QUOTED||this.returnState===U.ATTRIBUTE_VALUE_SINGLE_QUOTED||this.returnState===U.ATTRIBUTE_VALUE_UNQUOTED}_flushCodePointConsumedAsCharacterReference(t){this._isCharacterReferenceInAttribute()?this.currentAttr.value+=String.fromCodePoint(t):this._emitCodePoint(t)}_callState(t){switch(this.state){case U.DATA:{this._stateData(t);break}case U.RCDATA:{this._stateRcdata(t);break}case U.RAWTEXT:{this._stateRawtext(t);break}case U.SCRIPT_DATA:{this._stateScriptData(t);break}case U.PLAINTEXT:{this._statePlaintext(t);break}case U.TAG_OPEN:{this._stateTagOpen(t);break}case U.END_TAG_OPEN:{this._stateEndTagOpen(t);break}case U.TAG_NAME:{this._stateTagName(t);break}case U.RCDATA_LESS_THAN_SIGN:{this._stateRcdataLessThanSign(t);break}case U.RCDATA_END_TAG_OPEN:{this._stateRcdataEndTagOpen(t);break}case U.RCDATA_END_TAG_NAME:{this._stateRcdataEndTagName(t);break}case U.RAWTEXT_LESS_THAN_SIGN:{this._stateRawtextLessThanSign(t);break}case U.RAWTEXT_END_TAG_OPEN:{this._stateRawtextEndTagOpen(t);break}case U.RAWTEXT_END_TAG_NAME:{this._stateRawtextEndTagName(t);break}case U.SCRIPT_DATA_LESS_THAN_SIGN:{this._stateScriptDataLessThanSign(t);break}case U.SCRIPT_DATA_END_TAG_OPEN:{this._stateScriptDataEndTagOpen(t);break}case U.SCRIPT_DATA_END_TAG_NAME:{this._stateScriptDataEndTagName(t);break}case U.SCRIPT_DATA_ESCAPE_START:{this._stateScriptDataEscapeStart(t);break}case U.SCRIPT_DATA_ESCAPE_START_DASH:{this._stateScriptDataEscapeStartDash(t);break}case U.SCRIPT_DATA_ESCAPED:{this._stateScriptDataEscaped(t);break}case U.SCRIPT_DATA_ESCAPED_DASH:{this._stateScriptDataEscapedDash(t);break}case U.SCRIPT_DATA_ESCAPED_DASH_DASH:{this._stateScriptDataEscapedDashDash(t);break}case U.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataEscapedLessThanSign(t);break}case U.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:{this._stateScriptDataEscapedEndTagOpen(t);break}case U.SCRIPT_DATA_ESCAPED_END_TAG_NAME:{this._stateScriptDataEscapedEndTagName(t);break}case U.SCRIPT_DATA_DOUBLE_ESCAPE_START:{this._stateScriptDataDoubleEscapeStart(t);break}case U.SCRIPT_DATA_DOUBLE_ESCAPED:{this._stateScriptDataDoubleEscaped(t);break}case U.SCRIPT_DATA_DOUBLE_ESCAPED_DASH:{this._stateScriptDataDoubleEscapedDash(t);break}case U.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH:{this._stateScriptDataDoubleEscapedDashDash(t);break}case U.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataDoubleEscapedLessThanSign(t);break}case U.SCRIPT_DATA_DOUBLE_ESCAPE_END:{this._stateScriptDataDoubleEscapeEnd(t);break}case U.BEFORE_ATTRIBUTE_NAME:{this._stateBeforeAttributeName(t);break}case U.ATTRIBUTE_NAME:{this._stateAttributeName(t);break}case U.AFTER_ATTRIBUTE_NAME:{this._stateAfterAttributeName(t);break}case U.BEFORE_ATTRIBUTE_VALUE:{this._stateBeforeAttributeValue(t);break}case U.ATTRIBUTE_VALUE_DOUBLE_QUOTED:{this._stateAttributeValueDoubleQuoted(t);break}case U.ATTRIBUTE_VALUE_SINGLE_QUOTED:{this._stateAttributeValueSingleQuoted(t);break}case U.ATTRIBUTE_VALUE_UNQUOTED:{this._stateAttributeValueUnquoted(t);break}case U.AFTER_ATTRIBUTE_VALUE_QUOTED:{this._stateAfterAttributeValueQuoted(t);break}case U.SELF_CLOSING_START_TAG:{this._stateSelfClosingStartTag(t);break}case U.BOGUS_COMMENT:{this._stateBogusComment(t);break}case U.MARKUP_DECLARATION_OPEN:{this._stateMarkupDeclarationOpen(t);break}case U.COMMENT_START:{this._stateCommentStart(t);break}case U.COMMENT_START_DASH:{this._stateCommentStartDash(t);break}case U.COMMENT:{this._stateComment(t);break}case U.COMMENT_LESS_THAN_SIGN:{this._stateCommentLessThanSign(t);break}case U.COMMENT_LESS_THAN_SIGN_BANG:{this._stateCommentLessThanSignBang(t);break}case U.COMMENT_LESS_THAN_SIGN_BANG_DASH:{this._stateCommentLessThanSignBangDash(t);break}case U.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:{this._stateCommentLessThanSignBangDashDash(t);break}case U.COMMENT_END_DASH:{this._stateCommentEndDash(t);break}case U.COMMENT_END:{this._stateCommentEnd(t);break}case U.COMMENT_END_BANG:{this._stateCommentEndBang(t);break}case U.DOCTYPE:{this._stateDoctype(t);break}case U.BEFORE_DOCTYPE_NAME:{this._stateBeforeDoctypeName(t);break}case U.DOCTYPE_NAME:{this._stateDoctypeName(t);break}case U.AFTER_DOCTYPE_NAME:{this._stateAfterDoctypeName(t);break}case U.AFTER_DOCTYPE_PUBLIC_KEYWORD:{this._stateAfterDoctypePublicKeyword(t);break}case U.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateBeforeDoctypePublicIdentifier(t);break}case U.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypePublicIdentifierDoubleQuoted(t);break}case U.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypePublicIdentifierSingleQuoted(t);break}case U.AFTER_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateAfterDoctypePublicIdentifier(t);break}case U.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS:{this._stateBetweenDoctypePublicAndSystemIdentifiers(t);break}case U.AFTER_DOCTYPE_SYSTEM_KEYWORD:{this._stateAfterDoctypeSystemKeyword(t);break}case U.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateBeforeDoctypeSystemIdentifier(t);break}case U.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypeSystemIdentifierDoubleQuoted(t);break}case U.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypeSystemIdentifierSingleQuoted(t);break}case U.AFTER_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateAfterDoctypeSystemIdentifier(t);break}case U.BOGUS_DOCTYPE:{this._stateBogusDoctype(t);break}case U.CDATA_SECTION:{this._stateCdataSection(t);break}case U.CDATA_SECTION_BRACKET:{this._stateCdataSectionBracket(t);break}case U.CDATA_SECTION_END:{this._stateCdataSectionEnd(t);break}case U.CHARACTER_REFERENCE:{this._stateCharacterReference(t);break}case U.NAMED_CHARACTER_REFERENCE:{this._stateNamedCharacterReference(t);break}case U.AMBIGUOUS_AMPERSAND:{this._stateAmbiguousAmpersand(t);break}case U.NUMERIC_CHARACTER_REFERENCE:{this._stateNumericCharacterReference(t);break}case U.HEXADEMICAL_CHARACTER_REFERENCE_START:{this._stateHexademicalCharacterReferenceStart(t);break}case U.HEXADEMICAL_CHARACTER_REFERENCE:{this._stateHexademicalCharacterReference(t);break}case U.DECIMAL_CHARACTER_REFERENCE:{this._stateDecimalCharacterReference(t);break}case U.NUMERIC_CHARACTER_REFERENCE_END:{this._stateNumericCharacterReferenceEnd(t);break}default:throw new Error("Unknown state")}}_stateData(t){switch(t){case M.LESS_THAN_SIGN:{this.state=U.TAG_OPEN;break}case M.AMPERSAND:{this.returnState=U.DATA,this.state=U.CHARACTER_REFERENCE;break}case M.NULL:{this._err(_e.unexpectedNullCharacter),this._emitCodePoint(t);break}case M.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateRcdata(t){switch(t){case M.AMPERSAND:{this.returnState=U.RCDATA,this.state=U.CHARACTER_REFERENCE;break}case M.LESS_THAN_SIGN:{this.state=U.RCDATA_LESS_THAN_SIGN;break}case M.NULL:{this._err(_e.unexpectedNullCharacter),this._emitChars(lr);break}case M.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateRawtext(t){switch(t){case M.LESS_THAN_SIGN:{this.state=U.RAWTEXT_LESS_THAN_SIGN;break}case M.NULL:{this._err(_e.unexpectedNullCharacter),this._emitChars(lr);break}case M.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptData(t){switch(t){case M.LESS_THAN_SIGN:{this.state=U.SCRIPT_DATA_LESS_THAN_SIGN;break}case M.NULL:{this._err(_e.unexpectedNullCharacter),this._emitChars(lr);break}case M.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_statePlaintext(t){switch(t){case M.NULL:{this._err(_e.unexpectedNullCharacter),this._emitChars(lr);break}case M.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateTagOpen(t){if(Rc(t))this._createStartTagToken(),this.state=U.TAG_NAME,this._stateTagName(t);else switch(t){case M.EXCLAMATION_MARK:{this.state=U.MARKUP_DECLARATION_OPEN;break}case M.SOLIDUS:{this.state=U.END_TAG_OPEN;break}case M.QUESTION_MARK:{this._err(_e.unexpectedQuestionMarkInsteadOfTagName),this._createCommentToken(1),this.state=U.BOGUS_COMMENT,this._stateBogusComment(t);break}case M.EOF:{this._err(_e.eofBeforeTagName),this._emitChars("<"),this._emitEOFToken();break}default:this._err(_e.invalidFirstCharacterOfTagName),this._emitChars("<"),this.state=U.DATA,this._stateData(t)}}_stateEndTagOpen(t){if(Rc(t))this._createEndTagToken(),this.state=U.TAG_NAME,this._stateTagName(t);else switch(t){case M.GREATER_THAN_SIGN:{this._err(_e.missingEndTagName),this.state=U.DATA;break}case M.EOF:{this._err(_e.eofBeforeTagName),this._emitChars("");break}case M.NULL:{this._err(_e.unexpectedNullCharacter),this.state=U.SCRIPT_DATA_ESCAPED,this._emitChars(lr);break}case M.EOF:{this._err(_e.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=U.SCRIPT_DATA_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataEscapedLessThanSign(t){t===M.SOLIDUS?this.state=U.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:Rc(t)?(this._emitChars("<"),this.state=U.SCRIPT_DATA_DOUBLE_ESCAPE_START,this._stateScriptDataDoubleEscapeStart(t)):(this._emitChars("<"),this.state=U.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataEscapedEndTagOpen(t){Rc(t)?(this.state=U.SCRIPT_DATA_ESCAPED_END_TAG_NAME,this._stateScriptDataEscapedEndTagName(t)):(this._emitChars("");break}case M.NULL:{this._err(_e.unexpectedNullCharacter),this.state=U.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(lr);break}case M.EOF:{this._err(_e.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=U.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedLessThanSign(t){t===M.SOLIDUS?(this.state=U.SCRIPT_DATA_DOUBLE_ESCAPE_END,this._emitChars("/")):(this.state=U.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(t))}_stateScriptDataDoubleEscapeEnd(t){if(this.preprocessor.startsWith(As.SCRIPT,!1)&&g7(this.preprocessor.peek(As.SCRIPT.length))){this._emitCodePoint(t);for(let n=0;n1114111)this._err(_e.characterReferenceOutsideUnicodeRange),this.charRefCode=M.REPLACEMENT_CHARACTER;else if(jre(this.charRefCode))this._err(_e.surrogateCharacterReference),this.charRefCode=M.REPLACEMENT_CHARACTER;else if(Vre(this.charRefCode))this._err(_e.noncharacterCharacterReference);else if(Ure(this.charRefCode)||this.charRefCode===M.CARRIAGE_RETURN){this._err(_e.controlCharacterReference);const n=dBe.get(this.charRefCode);n!==void 0&&(this.charRefCode=n)}this._flushCodePointConsumedAsCharacterReference(this.charRefCode),this._reconsumeInState(this.returnState,t)}}const Qre=new Set([_.DD,_.DT,_.LI,_.OPTGROUP,_.OPTION,_.P,_.RB,_.RP,_.RT,_.RTC]),y7=new Set([...Qre,_.CAPTION,_.COLGROUP,_.TBODY,_.TD,_.TFOOT,_.TH,_.THEAD,_.TR]),Nb=new Map([[_.APPLET,we.HTML],[_.CAPTION,we.HTML],[_.HTML,we.HTML],[_.MARQUEE,we.HTML],[_.OBJECT,we.HTML],[_.TABLE,we.HTML],[_.TD,we.HTML],[_.TEMPLATE,we.HTML],[_.TH,we.HTML],[_.ANNOTATION_XML,we.MATHML],[_.MI,we.MATHML],[_.MN,we.MATHML],[_.MO,we.MATHML],[_.MS,we.MATHML],[_.MTEXT,we.MATHML],[_.DESC,we.SVG],[_.FOREIGN_OBJECT,we.SVG],[_.TITLE,we.SVG]]),yBe=[_.H1,_.H2,_.H3,_.H4,_.H5,_.H6],vBe=[_.TR,_.TEMPLATE,_.HTML],_Be=[_.TBODY,_.TFOOT,_.THEAD,_.TEMPLATE,_.HTML],bBe=[_.TABLE,_.TEMPLATE,_.HTML],wBe=[_.TD,_.TH];class EBe{get currentTmplContentOrNode(){return this._isInTemplate()?this.treeAdapter.getTemplateContent(this.current):this.current}constructor(t,n,r){this.treeAdapter=n,this.handler=r,this.items=[],this.tagIDs=[],this.stackTop=-1,this.tmplCount=0,this.currentTagId=_.UNKNOWN,this.current=t}_indexOf(t){return this.items.lastIndexOf(t,this.stackTop)}_isInTemplate(){return this.currentTagId===_.TEMPLATE&&this.treeAdapter.getNamespaceURI(this.current)===we.HTML}_updateCurrentElement(){this.current=this.items[this.stackTop],this.currentTagId=this.tagIDs[this.stackTop]}push(t,n){this.stackTop++,this.items[this.stackTop]=t,this.current=t,this.tagIDs[this.stackTop]=n,this.currentTagId=n,this._isInTemplate()&&this.tmplCount++,this.handler.onItemPush(t,n,!0)}pop(){const t=this.current;this.tmplCount>0&&this._isInTemplate()&&this.tmplCount--,this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(t,!0)}replace(t,n){const r=this._indexOf(t);this.items[r]=n,r===this.stackTop&&(this.current=n)}insertAfter(t,n,r){const i=this._indexOf(t)+1;this.items.splice(i,0,n),this.tagIDs.splice(i,0,r),this.stackTop++,i===this.stackTop&&this._updateCurrentElement(),this.handler.onItemPush(this.current,this.currentTagId,i===this.stackTop)}popUntilTagNamePopped(t){let n=this.stackTop+1;do n=this.tagIDs.lastIndexOf(t,n-1);while(n>0&&this.treeAdapter.getNamespaceURI(this.items[n])!==we.HTML);this.shortenToLength(n<0?0:n)}shortenToLength(t){for(;this.stackTop>=t;){const n=this.current;this.tmplCount>0&&this._isInTemplate()&&(this.tmplCount-=1),this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(n,this.stackTop=0;r--)if(t.includes(this.tagIDs[r])&&this.treeAdapter.getNamespaceURI(this.items[r])===n)return r;return-1}clearBackTo(t,n){const r=this._indexOfTagNames(t,n);this.shortenToLength(r+1)}clearBackToTableContext(){this.clearBackTo(bBe,we.HTML)}clearBackToTableBodyContext(){this.clearBackTo(_Be,we.HTML)}clearBackToTableRowContext(){this.clearBackTo(vBe,we.HTML)}remove(t){const n=this._indexOf(t);n>=0&&(n===this.stackTop?this.pop():(this.items.splice(n,1),this.tagIDs.splice(n,1),this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(t,!1)))}tryPeekProperlyNestedBodyElement(){return this.stackTop>=1&&this.tagIDs[1]===_.BODY?this.items[1]:null}contains(t){return this._indexOf(t)>-1}getCommonAncestor(t){const n=this._indexOf(t)-1;return n>=0?this.items[n]:null}isRootHtmlElementCurrent(){return this.stackTop===0&&this.tagIDs[0]===_.HTML}hasInScope(t){for(let n=this.stackTop;n>=0;n--){const r=this.tagIDs[n],i=this.treeAdapter.getNamespaceURI(this.items[n]);if(r===t&&i===we.HTML)return!0;if(Nb.get(r)===i)return!1}return!0}hasNumberedHeaderInScope(){for(let t=this.stackTop;t>=0;t--){const n=this.tagIDs[t],r=this.treeAdapter.getNamespaceURI(this.items[t]);if(qre(n)&&r===we.HTML)return!0;if(Nb.get(n)===r)return!1}return!0}hasInListItemScope(t){for(let n=this.stackTop;n>=0;n--){const r=this.tagIDs[n],i=this.treeAdapter.getNamespaceURI(this.items[n]);if(r===t&&i===we.HTML)return!0;if((r===_.UL||r===_.OL)&&i===we.HTML||Nb.get(r)===i)return!1}return!0}hasInButtonScope(t){for(let n=this.stackTop;n>=0;n--){const r=this.tagIDs[n],i=this.treeAdapter.getNamespaceURI(this.items[n]);if(r===t&&i===we.HTML)return!0;if(r===_.BUTTON&&i===we.HTML||Nb.get(r)===i)return!1}return!0}hasInTableScope(t){for(let n=this.stackTop;n>=0;n--){const r=this.tagIDs[n];if(this.treeAdapter.getNamespaceURI(this.items[n])===we.HTML){if(r===t)return!0;if(r===_.TABLE||r===_.TEMPLATE||r===_.HTML)return!1}}return!0}hasTableBodyContextInTableScope(){for(let t=this.stackTop;t>=0;t--){const n=this.tagIDs[t];if(this.treeAdapter.getNamespaceURI(this.items[t])===we.HTML){if(n===_.TBODY||n===_.THEAD||n===_.TFOOT)return!0;if(n===_.TABLE||n===_.HTML)return!1}}return!0}hasInSelectScope(t){for(let n=this.stackTop;n>=0;n--){const r=this.tagIDs[n];if(this.treeAdapter.getNamespaceURI(this.items[n])===we.HTML){if(r===t)return!0;if(r!==_.OPTION&&r!==_.OPTGROUP)return!1}}return!0}generateImpliedEndTags(){for(;Qre.has(this.currentTagId);)this.pop()}generateImpliedEndTagsThoroughly(){for(;y7.has(this.currentTagId);)this.pop()}generateImpliedEndTagsWithExclusion(t){for(;this.currentTagId!==t&&y7.has(this.currentTagId);)this.pop()}}const CO=3;var Ra;(function(e){e[e.Marker=0]="Marker",e[e.Element=1]="Element"})(Ra=Ra||(Ra={}));const v7={type:Ra.Marker};class SBe{constructor(t){this.treeAdapter=t,this.entries=[],this.bookmark=null}_getNoahArkConditionCandidates(t,n){const r=[],i=n.length,s=this.treeAdapter.getTagName(t),o=this.treeAdapter.getNamespaceURI(t);for(let a=0;a[o.name,o.value]));let s=0;for(let o=0;oi.get(u.name)===u.value)&&(s+=1,s>=CO&&this.entries.splice(a.idx,1))}}insertMarker(){this.entries.unshift(v7)}pushElement(t,n){this._ensureNoahArkCondition(t),this.entries.unshift({type:Ra.Element,element:t,token:n})}insertElementAfterBookmark(t,n){const r=this.entries.indexOf(this.bookmark);this.entries.splice(r,0,{type:Ra.Element,element:t,token:n})}removeEntry(t){const n=this.entries.indexOf(t);n>=0&&this.entries.splice(n,1)}clearToLastMarker(){const t=this.entries.indexOf(v7);t>=0?this.entries.splice(0,t+1):this.entries.length=0}getElementEntryInScopeWithTagName(t){const n=this.entries.find(r=>r.type===Ra.Marker||this.treeAdapter.getTagName(r.element)===t);return n&&n.type===Ra.Element?n:null}getElementEntry(t){return this.entries.find(n=>n.type===Ra.Element&&n.element===t)}}function _7(e){return{nodeName:"#text",value:e,parentNode:null}}const hp={createDocument(){return{nodeName:"#document",mode:go.NO_QUIRKS,childNodes:[]}},createDocumentFragment(){return{nodeName:"#document-fragment",childNodes:[]}},createElement(e,t,n){return{nodeName:e,tagName:e,attrs:n,namespaceURI:t,childNodes:[],parentNode:null}},createCommentNode(e){return{nodeName:"#comment",data:e,parentNode:null}},appendChild(e,t){e.childNodes.push(t),t.parentNode=e},insertBefore(e,t,n){const r=e.childNodes.indexOf(n);e.childNodes.splice(r,0,t),t.parentNode=e},setTemplateContent(e,t){e.content=t},getTemplateContent(e){return e.content},setDocumentType(e,t,n,r){const i=e.childNodes.find(s=>s.nodeName==="#documentType");if(i)i.name=t,i.publicId=n,i.systemId=r;else{const s={nodeName:"#documentType",name:t,publicId:n,systemId:r,parentNode:null};hp.appendChild(e,s)}},setDocumentMode(e,t){e.mode=t},getDocumentMode(e){return e.mode},detachNode(e){if(e.parentNode){const t=e.parentNode.childNodes.indexOf(e);e.parentNode.childNodes.splice(t,1),e.parentNode=null}},insertText(e,t){if(e.childNodes.length>0){const n=e.childNodes[e.childNodes.length-1];if(hp.isTextNode(n)){n.value+=t;return}}hp.appendChild(e,_7(t))},insertTextBefore(e,t,n){const r=e.childNodes[e.childNodes.indexOf(n)-1];r&&hp.isTextNode(r)?r.value+=t:hp.insertBefore(e,_7(t),n)},adoptAttributes(e,t){const n=new Set(e.attrs.map(r=>r.name));for(let r=0;re.startsWith(n))}function PBe(e){return e.name===Xre&&e.publicId===null&&(e.systemId===null||e.systemId===TBe)}function OBe(e){if(e.name!==Xre)return go.QUIRKS;const{systemId:t}=e;if(t&&t.toLowerCase()===IBe)return go.QUIRKS;let{publicId:n}=e;if(n!==null){if(n=n.toLowerCase(),CBe.has(n))return go.QUIRKS;let r=t===null?xBe:Jre;if(b7(n,r))return go.QUIRKS;if(r=t===null?Zre:ABe,b7(n,r))return go.LIMITED_QUIRKS}return go.NO_QUIRKS}const w7={TEXT_HTML:"text/html",APPLICATION_XML:"application/xhtml+xml"},RBe="definitionurl",NBe="definitionURL",kBe=new Map(["attributeName","attributeType","baseFrequency","baseProfile","calcMode","clipPathUnits","diffuseConstant","edgeMode","filterUnits","glyphRef","gradientTransform","gradientUnits","kernelMatrix","kernelUnitLength","keyPoints","keySplines","keyTimes","lengthAdjust","limitingConeAngle","markerHeight","markerUnits","markerWidth","maskContentUnits","maskUnits","numOctaves","pathLength","patternContentUnits","patternTransform","patternUnits","pointsAtX","pointsAtY","pointsAtZ","preserveAlpha","preserveAspectRatio","primitiveUnits","refX","refY","repeatCount","repeatDur","requiredExtensions","requiredFeatures","specularConstant","specularExponent","spreadMethod","startOffset","stdDeviation","stitchTiles","surfaceScale","systemLanguage","tableValues","targetX","targetY","textLength","viewBox","viewTarget","xChannelSelector","yChannelSelector","zoomAndPan"].map(e=>[e.toLowerCase(),e])),DBe=new Map([["xlink:actuate",{prefix:"xlink",name:"actuate",namespace:we.XLINK}],["xlink:arcrole",{prefix:"xlink",name:"arcrole",namespace:we.XLINK}],["xlink:href",{prefix:"xlink",name:"href",namespace:we.XLINK}],["xlink:role",{prefix:"xlink",name:"role",namespace:we.XLINK}],["xlink:show",{prefix:"xlink",name:"show",namespace:we.XLINK}],["xlink:title",{prefix:"xlink",name:"title",namespace:we.XLINK}],["xlink:type",{prefix:"xlink",name:"type",namespace:we.XLINK}],["xml:base",{prefix:"xml",name:"base",namespace:we.XML}],["xml:lang",{prefix:"xml",name:"lang",namespace:we.XML}],["xml:space",{prefix:"xml",name:"space",namespace:we.XML}],["xmlns",{prefix:"",name:"xmlns",namespace:we.XMLNS}],["xmlns:xlink",{prefix:"xmlns",name:"xlink",namespace:we.XMLNS}]]),$Be=new Map(["altGlyph","altGlyphDef","altGlyphItem","animateColor","animateMotion","animateTransform","clipPath","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","foreignObject","glyphRef","linearGradient","radialGradient","textPath"].map(e=>[e.toLowerCase(),e])),LBe=new Set([_.B,_.BIG,_.BLOCKQUOTE,_.BODY,_.BR,_.CENTER,_.CODE,_.DD,_.DIV,_.DL,_.DT,_.EM,_.EMBED,_.H1,_.H2,_.H3,_.H4,_.H5,_.H6,_.HEAD,_.HR,_.I,_.IMG,_.LI,_.LISTING,_.MENU,_.META,_.NOBR,_.OL,_.P,_.PRE,_.RUBY,_.S,_.SMALL,_.SPAN,_.STRONG,_.STRIKE,_.SUB,_.SUP,_.TABLE,_.TT,_.U,_.UL,_.VAR]);function MBe(e){const t=e.tagID;return t===_.FONT&&e.attrs.some(({name:r})=>r===gf.COLOR||r===gf.SIZE||r===gf.FACE)||LBe.has(t)}function eie(e){for(let t=0;t0&&this._setContextModes(t,n)}onItemPop(t,n){var r,i;if(this.options.sourceCodeLocationInfo&&this._setEndLocation(t,this.currentToken),(i=(r=this.treeAdapter).onItemPop)===null||i===void 0||i.call(r,t,this.openElements.current),n){let s,o;this.openElements.stackTop===0&&this.fragmentContext?(s=this.fragmentContext,o=this.fragmentContextID):{current:s,currentTagId:o}=this.openElements,this._setContextModes(s,o)}}_setContextModes(t,n){const r=t===this.document||this.treeAdapter.getNamespaceURI(t)===we.HTML;this.currentNotInHTML=!r,this.tokenizer.inForeignNode=!r&&!this._isIntegrationPoint(n,t)}_switchToTextParsing(t,n){this._insertElement(t,we.HTML),this.tokenizer.state=n,this.originalInsertionMode=this.insertionMode,this.insertionMode=Y.TEXT}switchToPlaintextParsing(){this.insertionMode=Y.TEXT,this.originalInsertionMode=Y.IN_BODY,this.tokenizer.state=Mr.PLAINTEXT}_getAdjustedCurrentElement(){return this.openElements.stackTop===0&&this.fragmentContext?this.fragmentContext:this.openElements.current}_findFormInFragmentContext(){let t=this.fragmentContext;for(;t;){if(this.treeAdapter.getTagName(t)===le.FORM){this.formElement=t;break}t=this.treeAdapter.getParentNode(t)}}_initTokenizerForFragmentParsing(){if(!(!this.fragmentContext||this.treeAdapter.getNamespaceURI(this.fragmentContext)!==we.HTML))switch(this.fragmentContextID){case _.TITLE:case _.TEXTAREA:{this.tokenizer.state=Mr.RCDATA;break}case _.STYLE:case _.XMP:case _.IFRAME:case _.NOEMBED:case _.NOFRAMES:case _.NOSCRIPT:{this.tokenizer.state=Mr.RAWTEXT;break}case _.SCRIPT:{this.tokenizer.state=Mr.SCRIPT_DATA;break}case _.PLAINTEXT:{this.tokenizer.state=Mr.PLAINTEXT;break}}}_setDocumentType(t){const n=t.name||"",r=t.publicId||"",i=t.systemId||"";if(this.treeAdapter.setDocumentType(this.document,n,r,i),t.location){const o=this.treeAdapter.getChildNodes(this.document).find(a=>this.treeAdapter.isDocumentTypeNode(a));o&&this.treeAdapter.setNodeSourceCodeLocation(o,t.location)}}_attachElementToTree(t,n){if(this.options.sourceCodeLocationInfo){const r=n&&{...n,startTag:n};this.treeAdapter.setNodeSourceCodeLocation(t,r)}if(this._shouldFosterParentOnInsertion())this._fosterParentElement(t);else{const r=this.openElements.currentTmplContentOrNode;this.treeAdapter.appendChild(r,t)}}_appendElement(t,n){const r=this.treeAdapter.createElement(t.tagName,n,t.attrs);this._attachElementToTree(r,t.location)}_insertElement(t,n){const r=this.treeAdapter.createElement(t.tagName,n,t.attrs);this._attachElementToTree(r,t.location),this.openElements.push(r,t.tagID)}_insertFakeElement(t,n){const r=this.treeAdapter.createElement(t,we.HTML,[]);this._attachElementToTree(r,null),this.openElements.push(r,n)}_insertTemplate(t){const n=this.treeAdapter.createElement(t.tagName,we.HTML,t.attrs),r=this.treeAdapter.createDocumentFragment();this.treeAdapter.setTemplateContent(n,r),this._attachElementToTree(n,t.location),this.openElements.push(n,t.tagID),this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(r,null)}_insertFakeRootElement(){const t=this.treeAdapter.createElement(le.HTML,we.HTML,[]);this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(t,null),this.treeAdapter.appendChild(this.openElements.current,t),this.openElements.push(t,_.HTML)}_appendCommentNode(t,n){const r=this.treeAdapter.createCommentNode(t.data);this.treeAdapter.appendChild(n,r),this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(r,t.location)}_insertCharacters(t){let n,r;if(this._shouldFosterParentOnInsertion()?({parent:n,beforeElement:r}=this._findFosterParentingLocation(),r?this.treeAdapter.insertTextBefore(n,t.chars,r):this.treeAdapter.insertText(n,t.chars)):(n=this.openElements.currentTmplContentOrNode,this.treeAdapter.insertText(n,t.chars)),!t.location)return;const i=this.treeAdapter.getChildNodes(n),s=r?i.lastIndexOf(r):i.length,o=i[s-1];if(this.treeAdapter.getNodeSourceCodeLocation(o)){const{endLine:u,endCol:l,endOffset:c}=t.location;this.treeAdapter.updateNodeSourceCodeLocation(o,{endLine:u,endCol:l,endOffset:c})}else this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(o,t.location)}_adoptNodes(t,n){for(let r=this.treeAdapter.getFirstChild(t);r;r=this.treeAdapter.getFirstChild(t))this.treeAdapter.detachNode(r),this.treeAdapter.appendChild(n,r)}_setEndLocation(t,n){if(this.treeAdapter.getNodeSourceCodeLocation(t)&&n.location){const r=n.location,i=this.treeAdapter.getTagName(t),s=n.type===Yt.END_TAG&&i===n.tagName?{endTag:{...r},endLine:r.endLine,endCol:r.endCol,endOffset:r.endOffset}:{endLine:r.startLine,endCol:r.startCol,endOffset:r.startOffset};this.treeAdapter.updateNodeSourceCodeLocation(t,s)}}shouldProcessStartTagTokenInForeignContent(t){if(!this.currentNotInHTML)return!1;let n,r;return this.openElements.stackTop===0&&this.fragmentContext?(n=this.fragmentContext,r=this.fragmentContextID):{current:n,currentTagId:r}=this.openElements,t.tagID===_.SVG&&this.treeAdapter.getTagName(n)===le.ANNOTATION_XML&&this.treeAdapter.getNamespaceURI(n)===we.MATHML?!1:this.tokenizer.inForeignNode||(t.tagID===_.MGLYPH||t.tagID===_.MALIGNMARK)&&!this._isIntegrationPoint(r,n,we.HTML)}_processToken(t){switch(t.type){case Yt.CHARACTER:{this.onCharacter(t);break}case Yt.NULL_CHARACTER:{this.onNullCharacter(t);break}case Yt.COMMENT:{this.onComment(t);break}case Yt.DOCTYPE:{this.onDoctype(t);break}case Yt.START_TAG:{this._processStartTag(t);break}case Yt.END_TAG:{this.onEndTag(t);break}case Yt.EOF:{this.onEof(t);break}case Yt.WHITESPACE_CHARACTER:{this.onWhitespaceCharacter(t);break}}}_isIntegrationPoint(t,n,r){const i=this.treeAdapter.getNamespaceURI(n),s=this.treeAdapter.getAttrList(n);return UBe(t,i,s,r)}_reconstructActiveFormattingElements(){const t=this.activeFormattingElements.entries.length;if(t){const n=this.activeFormattingElements.entries.findIndex(i=>i.type===Ra.Marker||this.openElements.contains(i.element)),r=n<0?t-1:n-1;for(let i=r;i>=0;i--){const s=this.activeFormattingElements.entries[i];this._insertElement(s.token,this.treeAdapter.getNamespaceURI(s.element)),s.element=this.openElements.current}}}_closeTableCell(){this.openElements.generateImpliedEndTags(),this.openElements.popUntilTableCellPopped(),this.activeFormattingElements.clearToLastMarker(),this.insertionMode=Y.IN_ROW}_closePElement(){this.openElements.generateImpliedEndTagsWithExclusion(_.P),this.openElements.popUntilTagNamePopped(_.P)}_resetInsertionMode(){for(let t=this.openElements.stackTop;t>=0;t--)switch(t===0&&this.fragmentContext?this.fragmentContextID:this.openElements.tagIDs[t]){case _.TR:{this.insertionMode=Y.IN_ROW;return}case _.TBODY:case _.THEAD:case _.TFOOT:{this.insertionMode=Y.IN_TABLE_BODY;return}case _.CAPTION:{this.insertionMode=Y.IN_CAPTION;return}case _.COLGROUP:{this.insertionMode=Y.IN_COLUMN_GROUP;return}case _.TABLE:{this.insertionMode=Y.IN_TABLE;return}case _.BODY:{this.insertionMode=Y.IN_BODY;return}case _.FRAMESET:{this.insertionMode=Y.IN_FRAMESET;return}case _.SELECT:{this._resetInsertionModeForSelect(t);return}case _.TEMPLATE:{this.insertionMode=this.tmplInsertionModeStack[0];return}case _.HTML:{this.insertionMode=this.headElement?Y.AFTER_HEAD:Y.BEFORE_HEAD;return}case _.TD:case _.TH:{if(t>0){this.insertionMode=Y.IN_CELL;return}break}case _.HEAD:{if(t>0){this.insertionMode=Y.IN_HEAD;return}break}}this.insertionMode=Y.IN_BODY}_resetInsertionModeForSelect(t){if(t>0)for(let n=t-1;n>0;n--){const r=this.openElements.tagIDs[n];if(r===_.TEMPLATE)break;if(r===_.TABLE){this.insertionMode=Y.IN_SELECT_IN_TABLE;return}}this.insertionMode=Y.IN_SELECT}_isElementCausesFosterParenting(t){return nie.has(t)}_shouldFosterParentOnInsertion(){return this.fosterParentingEnabled&&this._isElementCausesFosterParenting(this.openElements.currentTagId)}_findFosterParentingLocation(){for(let t=this.openElements.stackTop;t>=0;t--){const n=this.openElements.items[t];switch(this.openElements.tagIDs[t]){case _.TEMPLATE:{if(this.treeAdapter.getNamespaceURI(n)===we.HTML)return{parent:this.treeAdapter.getTemplateContent(n),beforeElement:null};break}case _.TABLE:{const r=this.treeAdapter.getParentNode(n);return r?{parent:r,beforeElement:n}:{parent:this.openElements.items[t-1],beforeElement:null}}}}return{parent:this.openElements.items[0],beforeElement:null}}_fosterParentElement(t){const n=this._findFosterParentingLocation();n.beforeElement?this.treeAdapter.insertBefore(n.parent,t,n.beforeElement):this.treeAdapter.appendChild(n.parent,t)}_isSpecialElement(t,n){const r=this.treeAdapter.getNamespaceURI(t);return fBe[r].has(n)}onCharacter(t){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){wUe(this,t);return}switch(this.insertionMode){case Y.INITIAL:{T0(this,t);break}case Y.BEFORE_HTML:{Oy(this,t);break}case Y.BEFORE_HEAD:{Ry(this,t);break}case Y.IN_HEAD:{Ny(this,t);break}case Y.IN_HEAD_NO_SCRIPT:{ky(this,t);break}case Y.AFTER_HEAD:{Dy(this,t);break}case Y.IN_BODY:case Y.IN_CAPTION:case Y.IN_CELL:case Y.IN_TEMPLATE:{iie(this,t);break}case Y.TEXT:case Y.IN_SELECT:case Y.IN_SELECT_IN_TABLE:{this._insertCharacters(t);break}case Y.IN_TABLE:case Y.IN_TABLE_BODY:case Y.IN_ROW:{AO(this,t);break}case Y.IN_TABLE_TEXT:{cie(this,t);break}case Y.IN_COLUMN_GROUP:{BT(this,t);break}case Y.AFTER_BODY:{jT(this,t);break}case Y.AFTER_AFTER_BODY:{Fw(this,t);break}}}onNullCharacter(t){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){bUe(this,t);return}switch(this.insertionMode){case Y.INITIAL:{T0(this,t);break}case Y.BEFORE_HTML:{Oy(this,t);break}case Y.BEFORE_HEAD:{Ry(this,t);break}case Y.IN_HEAD:{Ny(this,t);break}case Y.IN_HEAD_NO_SCRIPT:{ky(this,t);break}case Y.AFTER_HEAD:{Dy(this,t);break}case Y.TEXT:{this._insertCharacters(t);break}case Y.IN_TABLE:case Y.IN_TABLE_BODY:case Y.IN_ROW:{AO(this,t);break}case Y.IN_COLUMN_GROUP:{BT(this,t);break}case Y.AFTER_BODY:{jT(this,t);break}case Y.AFTER_AFTER_BODY:{Fw(this,t);break}}}onComment(t){if(this.skipNextNewLine=!1,this.currentNotInHTML){DN(this,t);return}switch(this.insertionMode){case Y.INITIAL:case Y.BEFORE_HTML:case Y.BEFORE_HEAD:case Y.IN_HEAD:case Y.IN_HEAD_NO_SCRIPT:case Y.AFTER_HEAD:case Y.IN_BODY:case Y.IN_TABLE:case Y.IN_CAPTION:case Y.IN_COLUMN_GROUP:case Y.IN_TABLE_BODY:case Y.IN_ROW:case Y.IN_CELL:case Y.IN_SELECT:case Y.IN_SELECT_IN_TABLE:case Y.IN_TEMPLATE:case Y.IN_FRAMESET:case Y.AFTER_FRAMESET:{DN(this,t);break}case Y.IN_TABLE_TEXT:{I0(this,t);break}case Y.AFTER_BODY:{JBe(this,t);break}case Y.AFTER_AFTER_BODY:case Y.AFTER_AFTER_FRAMESET:{ZBe(this,t);break}}}onDoctype(t){switch(this.skipNextNewLine=!1,this.insertionMode){case Y.INITIAL:{eje(this,t);break}case Y.BEFORE_HEAD:case Y.IN_HEAD:case Y.IN_HEAD_NO_SCRIPT:case Y.AFTER_HEAD:{this._err(t,_e.misplacedDoctype);break}case Y.IN_TABLE_TEXT:{I0(this,t);break}}}onStartTag(t){this.skipNextNewLine=!1,this.currentToken=t,this._processStartTag(t),t.selfClosing&&!t.ackSelfClosing&&this._err(t,_e.nonVoidHtmlElementStartTagWithTrailingSolidus)}_processStartTag(t){this.shouldProcessStartTagTokenInForeignContent(t)?EUe(this,t):this._startTagOutsideForeignContent(t)}_startTagOutsideForeignContent(t){switch(this.insertionMode){case Y.INITIAL:{T0(this,t);break}case Y.BEFORE_HTML:{tje(this,t);break}case Y.BEFORE_HEAD:{rje(this,t);break}case Y.IN_HEAD:{nu(this,t);break}case Y.IN_HEAD_NO_SCRIPT:{oje(this,t);break}case Y.AFTER_HEAD:{uje(this,t);break}case Y.IN_BODY:{ls(this,t);break}case Y.IN_TABLE:{zm(this,t);break}case Y.IN_TABLE_TEXT:{I0(this,t);break}case Y.IN_CAPTION:{iUe(this,t);break}case Y.IN_COLUMN_GROUP:{E6(this,t);break}case Y.IN_TABLE_BODY:{CC(this,t);break}case Y.IN_ROW:{AC(this,t);break}case Y.IN_CELL:{aUe(this,t);break}case Y.IN_SELECT:{hie(this,t);break}case Y.IN_SELECT_IN_TABLE:{lUe(this,t);break}case Y.IN_TEMPLATE:{fUe(this,t);break}case Y.AFTER_BODY:{hUe(this,t);break}case Y.IN_FRAMESET:{pUe(this,t);break}case Y.AFTER_FRAMESET:{gUe(this,t);break}case Y.AFTER_AFTER_BODY:{vUe(this,t);break}case Y.AFTER_AFTER_FRAMESET:{_Ue(this,t);break}}}onEndTag(t){this.skipNextNewLine=!1,this.currentToken=t,this.currentNotInHTML?SUe(this,t):this._endTagOutsideForeignContent(t)}_endTagOutsideForeignContent(t){switch(this.insertionMode){case Y.INITIAL:{T0(this,t);break}case Y.BEFORE_HTML:{nje(this,t);break}case Y.BEFORE_HEAD:{ije(this,t);break}case Y.IN_HEAD:{sje(this,t);break}case Y.IN_HEAD_NO_SCRIPT:{aje(this,t);break}case Y.AFTER_HEAD:{lje(this,t);break}case Y.IN_BODY:{xC(this,t);break}case Y.TEXT:{Yje(this,t);break}case Y.IN_TABLE:{Av(this,t);break}case Y.IN_TABLE_TEXT:{I0(this,t);break}case Y.IN_CAPTION:{sUe(this,t);break}case Y.IN_COLUMN_GROUP:{oUe(this,t);break}case Y.IN_TABLE_BODY:{$N(this,t);break}case Y.IN_ROW:{die(this,t);break}case Y.IN_CELL:{uUe(this,t);break}case Y.IN_SELECT:{pie(this,t);break}case Y.IN_SELECT_IN_TABLE:{cUe(this,t);break}case Y.IN_TEMPLATE:{dUe(this,t);break}case Y.AFTER_BODY:{gie(this,t);break}case Y.IN_FRAMESET:{mUe(this,t);break}case Y.AFTER_FRAMESET:{yUe(this,t);break}case Y.AFTER_AFTER_BODY:{Fw(this,t);break}}}onEof(t){switch(this.insertionMode){case Y.INITIAL:{T0(this,t);break}case Y.BEFORE_HTML:{Oy(this,t);break}case Y.BEFORE_HEAD:{Ry(this,t);break}case Y.IN_HEAD:{Ny(this,t);break}case Y.IN_HEAD_NO_SCRIPT:{ky(this,t);break}case Y.AFTER_HEAD:{Dy(this,t);break}case Y.IN_BODY:case Y.IN_TABLE:case Y.IN_CAPTION:case Y.IN_COLUMN_GROUP:case Y.IN_TABLE_BODY:case Y.IN_ROW:case Y.IN_CELL:case Y.IN_SELECT:case Y.IN_SELECT_IN_TABLE:{uie(this,t);break}case Y.TEXT:{Kje(this,t);break}case Y.IN_TABLE_TEXT:{I0(this,t);break}case Y.IN_TEMPLATE:{mie(this,t);break}case Y.AFTER_BODY:case Y.IN_FRAMESET:case Y.AFTER_FRAMESET:case Y.AFTER_AFTER_BODY:case Y.AFTER_AFTER_FRAMESET:{w6(this,t);break}}}onWhitespaceCharacter(t){if(this.skipNextNewLine&&(this.skipNextNewLine=!1,t.chars.charCodeAt(0)===M.LINE_FEED)){if(t.chars.length===1)return;t.chars=t.chars.substr(1)}if(this.tokenizer.inForeignNode){this._insertCharacters(t);return}switch(this.insertionMode){case Y.IN_HEAD:case Y.IN_HEAD_NO_SCRIPT:case Y.AFTER_HEAD:case Y.TEXT:case Y.IN_COLUMN_GROUP:case Y.IN_SELECT:case Y.IN_SELECT_IN_TABLE:case Y.IN_FRAMESET:case Y.AFTER_FRAMESET:{this._insertCharacters(t);break}case Y.IN_BODY:case Y.IN_CAPTION:case Y.IN_CELL:case Y.IN_TEMPLATE:case Y.AFTER_BODY:case Y.AFTER_AFTER_BODY:case Y.AFTER_AFTER_FRAMESET:{rie(this,t);break}case Y.IN_TABLE:case Y.IN_TABLE_BODY:case Y.IN_ROW:{AO(this,t);break}case Y.IN_TABLE_TEXT:{lie(this,t);break}}}};function qBe(e,t){let n=e.activeFormattingElements.getElementEntryInScopeWithTagName(t.tagName);return n?e.openElements.contains(n.element)?e.openElements.hasInScope(t.tagID)||(n=null):(e.activeFormattingElements.removeEntry(n),n=null):aie(e,t),n}function GBe(e,t){let n=null,r=e.openElements.stackTop;for(;r>=0;r--){const i=e.openElements.items[r];if(i===t.element)break;e._isSpecialElement(i,e.openElements.tagIDs[r])&&(n=i)}return n||(e.openElements.shortenToLength(r<0?0:r),e.activeFormattingElements.removeEntry(t)),n}function YBe(e,t,n){let r=t,i=e.openElements.getCommonAncestor(t);for(let s=0,o=i;o!==n;s++,o=i){i=e.openElements.getCommonAncestor(o);const a=e.activeFormattingElements.getElementEntry(o),u=a&&s>=HBe;!a||u?(u&&e.activeFormattingElements.removeEntry(a),e.openElements.remove(o)):(o=KBe(e,a),r===t&&(e.activeFormattingElements.bookmark=a),e.treeAdapter.detachNode(r),e.treeAdapter.appendChild(o,r),r=o)}return r}function KBe(e,t){const n=e.treeAdapter.getNamespaceURI(t.element),r=e.treeAdapter.createElement(t.token.tagName,n,t.token.attrs);return e.openElements.replace(t.element,r),t.element=r,r}function QBe(e,t,n){const r=e.treeAdapter.getTagName(t),i=Og(r);if(e._isElementCausesFosterParenting(i))e._fosterParentElement(n);else{const s=e.treeAdapter.getNamespaceURI(t);i===_.TEMPLATE&&s===we.HTML&&(t=e.treeAdapter.getTemplateContent(t)),e.treeAdapter.appendChild(t,n)}}function XBe(e,t,n){const r=e.treeAdapter.getNamespaceURI(n.element),{token:i}=n,s=e.treeAdapter.createElement(i.tagName,r,i.attrs);e._adoptNodes(t,s),e.treeAdapter.appendChild(t,s),e.activeFormattingElements.insertElementAfterBookmark(s,i),e.activeFormattingElements.removeEntry(n),e.openElements.remove(n.element),e.openElements.insertAfter(t,s,i.tagID)}function b6(e,t){for(let n=0;n=n;r--)e._setEndLocation(e.openElements.items[r],t);if(!e.fragmentContext&&e.openElements.stackTop>=0){const r=e.openElements.items[0],i=e.treeAdapter.getNodeSourceCodeLocation(r);if(i&&!i.endTag&&(e._setEndLocation(r,t),e.openElements.stackTop>=1)){const s=e.openElements.items[1],o=e.treeAdapter.getNodeSourceCodeLocation(s);o&&!o.endTag&&e._setEndLocation(s,t)}}}}function eje(e,t){e._setDocumentType(t);const n=t.forceQuirks?go.QUIRKS:OBe(t);PBe(t)||e._err(t,_e.nonConformingDoctype),e.treeAdapter.setDocumentMode(e.document,n),e.insertionMode=Y.BEFORE_HTML}function T0(e,t){e._err(t,_e.missingDoctype,!0),e.treeAdapter.setDocumentMode(e.document,go.QUIRKS),e.insertionMode=Y.BEFORE_HTML,e._processToken(t)}function tje(e,t){t.tagID===_.HTML?(e._insertElement(t,we.HTML),e.insertionMode=Y.BEFORE_HEAD):Oy(e,t)}function nje(e,t){const n=t.tagID;(n===_.HTML||n===_.HEAD||n===_.BODY||n===_.BR)&&Oy(e,t)}function Oy(e,t){e._insertFakeRootElement(),e.insertionMode=Y.BEFORE_HEAD,e._processToken(t)}function rje(e,t){switch(t.tagID){case _.HTML:{ls(e,t);break}case _.HEAD:{e._insertElement(t,we.HTML),e.headElement=e.openElements.current,e.insertionMode=Y.IN_HEAD;break}default:Ry(e,t)}}function ije(e,t){const n=t.tagID;n===_.HEAD||n===_.BODY||n===_.HTML||n===_.BR?Ry(e,t):e._err(t,_e.endTagWithoutMatchingOpenElement)}function Ry(e,t){e._insertFakeElement(le.HEAD,_.HEAD),e.headElement=e.openElements.current,e.insertionMode=Y.IN_HEAD,e._processToken(t)}function nu(e,t){switch(t.tagID){case _.HTML:{ls(e,t);break}case _.BASE:case _.BASEFONT:case _.BGSOUND:case _.LINK:case _.META:{e._appendElement(t,we.HTML),t.ackSelfClosing=!0;break}case _.TITLE:{e._switchToTextParsing(t,Mr.RCDATA);break}case _.NOSCRIPT:{e.options.scriptingEnabled?e._switchToTextParsing(t,Mr.RAWTEXT):(e._insertElement(t,we.HTML),e.insertionMode=Y.IN_HEAD_NO_SCRIPT);break}case _.NOFRAMES:case _.STYLE:{e._switchToTextParsing(t,Mr.RAWTEXT);break}case _.SCRIPT:{e._switchToTextParsing(t,Mr.SCRIPT_DATA);break}case _.TEMPLATE:{e._insertTemplate(t),e.activeFormattingElements.insertMarker(),e.framesetOk=!1,e.insertionMode=Y.IN_TEMPLATE,e.tmplInsertionModeStack.unshift(Y.IN_TEMPLATE);break}case _.HEAD:{e._err(t,_e.misplacedStartTagForHeadElement);break}default:Ny(e,t)}}function sje(e,t){switch(t.tagID){case _.HEAD:{e.openElements.pop(),e.insertionMode=Y.AFTER_HEAD;break}case _.BODY:case _.BR:case _.HTML:{Ny(e,t);break}case _.TEMPLATE:{Fh(e,t);break}default:e._err(t,_e.endTagWithoutMatchingOpenElement)}}function Fh(e,t){e.openElements.tmplCount>0?(e.openElements.generateImpliedEndTagsThoroughly(),e.openElements.currentTagId!==_.TEMPLATE&&e._err(t,_e.closingOfElementWithOpenChildElements),e.openElements.popUntilTagNamePopped(_.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode()):e._err(t,_e.endTagWithoutMatchingOpenElement)}function Ny(e,t){e.openElements.pop(),e.insertionMode=Y.AFTER_HEAD,e._processToken(t)}function oje(e,t){switch(t.tagID){case _.HTML:{ls(e,t);break}case _.BASEFONT:case _.BGSOUND:case _.HEAD:case _.LINK:case _.META:case _.NOFRAMES:case _.STYLE:{nu(e,t);break}case _.NOSCRIPT:{e._err(t,_e.nestedNoscriptInHead);break}default:ky(e,t)}}function aje(e,t){switch(t.tagID){case _.NOSCRIPT:{e.openElements.pop(),e.insertionMode=Y.IN_HEAD;break}case _.BR:{ky(e,t);break}default:e._err(t,_e.endTagWithoutMatchingOpenElement)}}function ky(e,t){const n=t.type===Yt.EOF?_e.openElementsLeftAfterEof:_e.disallowedContentInNoscriptInHead;e._err(t,n),e.openElements.pop(),e.insertionMode=Y.IN_HEAD,e._processToken(t)}function uje(e,t){switch(t.tagID){case _.HTML:{ls(e,t);break}case _.BODY:{e._insertElement(t,we.HTML),e.framesetOk=!1,e.insertionMode=Y.IN_BODY;break}case _.FRAMESET:{e._insertElement(t,we.HTML),e.insertionMode=Y.IN_FRAMESET;break}case _.BASE:case _.BASEFONT:case _.BGSOUND:case _.LINK:case _.META:case _.NOFRAMES:case _.SCRIPT:case _.STYLE:case _.TEMPLATE:case _.TITLE:{e._err(t,_e.abandonedHeadElementChild),e.openElements.push(e.headElement,_.HEAD),nu(e,t),e.openElements.remove(e.headElement);break}case _.HEAD:{e._err(t,_e.misplacedStartTagForHeadElement);break}default:Dy(e,t)}}function lje(e,t){switch(t.tagID){case _.BODY:case _.HTML:case _.BR:{Dy(e,t);break}case _.TEMPLATE:{Fh(e,t);break}default:e._err(t,_e.endTagWithoutMatchingOpenElement)}}function Dy(e,t){e._insertFakeElement(le.BODY,_.BODY),e.insertionMode=Y.IN_BODY,IC(e,t)}function IC(e,t){switch(t.type){case Yt.CHARACTER:{iie(e,t);break}case Yt.WHITESPACE_CHARACTER:{rie(e,t);break}case Yt.COMMENT:{DN(e,t);break}case Yt.START_TAG:{ls(e,t);break}case Yt.END_TAG:{xC(e,t);break}case Yt.EOF:{uie(e,t);break}}}function rie(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t)}function iie(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t),e.framesetOk=!1}function cje(e,t){e.openElements.tmplCount===0&&e.treeAdapter.adoptAttributes(e.openElements.items[0],t.attrs)}function fje(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e.openElements.tmplCount===0&&(e.framesetOk=!1,e.treeAdapter.adoptAttributes(n,t.attrs))}function dje(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();e.framesetOk&&n&&(e.treeAdapter.detachNode(n),e.openElements.popAllUpToHtmlElement(),e._insertElement(t,we.HTML),e.insertionMode=Y.IN_FRAMESET)}function hje(e,t){e.openElements.hasInButtonScope(_.P)&&e._closePElement(),e._insertElement(t,we.HTML)}function pje(e,t){e.openElements.hasInButtonScope(_.P)&&e._closePElement(),qre(e.openElements.currentTagId)&&e.openElements.pop(),e._insertElement(t,we.HTML)}function mje(e,t){e.openElements.hasInButtonScope(_.P)&&e._closePElement(),e._insertElement(t,we.HTML),e.skipNextNewLine=!0,e.framesetOk=!1}function gje(e,t){const n=e.openElements.tmplCount>0;(!e.formElement||n)&&(e.openElements.hasInButtonScope(_.P)&&e._closePElement(),e._insertElement(t,we.HTML),n||(e.formElement=e.openElements.current))}function yje(e,t){e.framesetOk=!1;const n=t.tagID;for(let r=e.openElements.stackTop;r>=0;r--){const i=e.openElements.tagIDs[r];if(n===_.LI&&i===_.LI||(n===_.DD||n===_.DT)&&(i===_.DD||i===_.DT)){e.openElements.generateImpliedEndTagsWithExclusion(i),e.openElements.popUntilTagNamePopped(i);break}if(i!==_.ADDRESS&&i!==_.DIV&&i!==_.P&&e._isSpecialElement(e.openElements.items[r],i))break}e.openElements.hasInButtonScope(_.P)&&e._closePElement(),e._insertElement(t,we.HTML)}function vje(e,t){e.openElements.hasInButtonScope(_.P)&&e._closePElement(),e._insertElement(t,we.HTML),e.tokenizer.state=Mr.PLAINTEXT}function _je(e,t){e.openElements.hasInScope(_.BUTTON)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(_.BUTTON)),e._reconstructActiveFormattingElements(),e._insertElement(t,we.HTML),e.framesetOk=!1}function bje(e,t){const n=e.activeFormattingElements.getElementEntryInScopeWithTagName(le.A);n&&(b6(e,t),e.openElements.remove(n.element),e.activeFormattingElements.removeEntry(n)),e._reconstructActiveFormattingElements(),e._insertElement(t,we.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function wje(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,we.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function Eje(e,t){e._reconstructActiveFormattingElements(),e.openElements.hasInScope(_.NOBR)&&(b6(e,t),e._reconstructActiveFormattingElements()),e._insertElement(t,we.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function Sje(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,we.HTML),e.activeFormattingElements.insertMarker(),e.framesetOk=!1}function Tje(e,t){e.treeAdapter.getDocumentMode(e.document)!==go.QUIRKS&&e.openElements.hasInButtonScope(_.P)&&e._closePElement(),e._insertElement(t,we.HTML),e.framesetOk=!1,e.insertionMode=Y.IN_TABLE}function sie(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,we.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function oie(e){const t=zre(e,gf.TYPE);return t!=null&&t.toLowerCase()===VBe}function Ije(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,we.HTML),oie(t)||(e.framesetOk=!1),t.ackSelfClosing=!0}function xje(e,t){e._appendElement(t,we.HTML),t.ackSelfClosing=!0}function Cje(e,t){e.openElements.hasInButtonScope(_.P)&&e._closePElement(),e._appendElement(t,we.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function Aje(e,t){t.tagName=le.IMG,t.tagID=_.IMG,sie(e,t)}function Pje(e,t){e._insertElement(t,we.HTML),e.skipNextNewLine=!0,e.tokenizer.state=Mr.RCDATA,e.originalInsertionMode=e.insertionMode,e.framesetOk=!1,e.insertionMode=Y.TEXT}function Oje(e,t){e.openElements.hasInButtonScope(_.P)&&e._closePElement(),e._reconstructActiveFormattingElements(),e.framesetOk=!1,e._switchToTextParsing(t,Mr.RAWTEXT)}function Rje(e,t){e.framesetOk=!1,e._switchToTextParsing(t,Mr.RAWTEXT)}function T7(e,t){e._switchToTextParsing(t,Mr.RAWTEXT)}function Nje(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,we.HTML),e.framesetOk=!1,e.insertionMode=e.insertionMode===Y.IN_TABLE||e.insertionMode===Y.IN_CAPTION||e.insertionMode===Y.IN_TABLE_BODY||e.insertionMode===Y.IN_ROW||e.insertionMode===Y.IN_CELL?Y.IN_SELECT_IN_TABLE:Y.IN_SELECT}function kje(e,t){e.openElements.currentTagId===_.OPTION&&e.openElements.pop(),e._reconstructActiveFormattingElements(),e._insertElement(t,we.HTML)}function Dje(e,t){e.openElements.hasInScope(_.RUBY)&&e.openElements.generateImpliedEndTags(),e._insertElement(t,we.HTML)}function $je(e,t){e.openElements.hasInScope(_.RUBY)&&e.openElements.generateImpliedEndTagsWithExclusion(_.RTC),e._insertElement(t,we.HTML)}function Lje(e,t){e._reconstructActiveFormattingElements(),eie(t),_6(t),t.selfClosing?e._appendElement(t,we.MATHML):e._insertElement(t,we.MATHML),t.ackSelfClosing=!0}function Mje(e,t){e._reconstructActiveFormattingElements(),tie(t),_6(t),t.selfClosing?e._appendElement(t,we.SVG):e._insertElement(t,we.SVG),t.ackSelfClosing=!0}function I7(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,we.HTML)}function ls(e,t){switch(t.tagID){case _.I:case _.S:case _.B:case _.U:case _.EM:case _.TT:case _.BIG:case _.CODE:case _.FONT:case _.SMALL:case _.STRIKE:case _.STRONG:{wje(e,t);break}case _.A:{bje(e,t);break}case _.H1:case _.H2:case _.H3:case _.H4:case _.H5:case _.H6:{pje(e,t);break}case _.P:case _.DL:case _.OL:case _.UL:case _.DIV:case _.DIR:case _.NAV:case _.MAIN:case _.MENU:case _.ASIDE:case _.CENTER:case _.FIGURE:case _.FOOTER:case _.HEADER:case _.HGROUP:case _.DIALOG:case _.DETAILS:case _.ADDRESS:case _.ARTICLE:case _.SECTION:case _.SUMMARY:case _.FIELDSET:case _.BLOCKQUOTE:case _.FIGCAPTION:{hje(e,t);break}case _.LI:case _.DD:case _.DT:{yje(e,t);break}case _.BR:case _.IMG:case _.WBR:case _.AREA:case _.EMBED:case _.KEYGEN:{sie(e,t);break}case _.HR:{Cje(e,t);break}case _.RB:case _.RTC:{Dje(e,t);break}case _.RT:case _.RP:{$je(e,t);break}case _.PRE:case _.LISTING:{mje(e,t);break}case _.XMP:{Oje(e,t);break}case _.SVG:{Mje(e,t);break}case _.HTML:{cje(e,t);break}case _.BASE:case _.LINK:case _.META:case _.STYLE:case _.TITLE:case _.SCRIPT:case _.BGSOUND:case _.BASEFONT:case _.TEMPLATE:{nu(e,t);break}case _.BODY:{fje(e,t);break}case _.FORM:{gje(e,t);break}case _.NOBR:{Eje(e,t);break}case _.MATH:{Lje(e,t);break}case _.TABLE:{Tje(e,t);break}case _.INPUT:{Ije(e,t);break}case _.PARAM:case _.TRACK:case _.SOURCE:{xje(e,t);break}case _.IMAGE:{Aje(e,t);break}case _.BUTTON:{_je(e,t);break}case _.APPLET:case _.OBJECT:case _.MARQUEE:{Sje(e,t);break}case _.IFRAME:{Rje(e,t);break}case _.SELECT:{Nje(e,t);break}case _.OPTION:case _.OPTGROUP:{kje(e,t);break}case _.NOEMBED:{T7(e,t);break}case _.FRAMESET:{dje(e,t);break}case _.TEXTAREA:{Pje(e,t);break}case _.NOSCRIPT:{e.options.scriptingEnabled?T7(e,t):I7(e,t);break}case _.PLAINTEXT:{vje(e,t);break}case _.COL:case _.TH:case _.TD:case _.TR:case _.HEAD:case _.FRAME:case _.TBODY:case _.TFOOT:case _.THEAD:case _.CAPTION:case _.COLGROUP:break;default:I7(e,t)}}function Fje(e,t){if(e.openElements.hasInScope(_.BODY)&&(e.insertionMode=Y.AFTER_BODY,e.options.sourceCodeLocationInfo)){const n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e._setEndLocation(n,t)}}function Bje(e,t){e.openElements.hasInScope(_.BODY)&&(e.insertionMode=Y.AFTER_BODY,gie(e,t))}function jje(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n))}function Uje(e){const t=e.openElements.tmplCount>0,{formElement:n}=e;t||(e.formElement=null),(n||t)&&e.openElements.hasInScope(_.FORM)&&(e.openElements.generateImpliedEndTags(),t?e.openElements.popUntilTagNamePopped(_.FORM):n&&e.openElements.remove(n))}function Vje(e){e.openElements.hasInButtonScope(_.P)||e._insertFakeElement(le.P,_.P),e._closePElement()}function zje(e){e.openElements.hasInListItemScope(_.LI)&&(e.openElements.generateImpliedEndTagsWithExclusion(_.LI),e.openElements.popUntilTagNamePopped(_.LI))}function Hje(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTagsWithExclusion(n),e.openElements.popUntilTagNamePopped(n))}function Wje(e){e.openElements.hasNumberedHeaderInScope()&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilNumberedHeaderPopped())}function qje(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker())}function Gje(e){e._reconstructActiveFormattingElements(),e._insertFakeElement(le.BR,_.BR),e.openElements.pop(),e.framesetOk=!1}function aie(e,t){const n=t.tagName,r=t.tagID;for(let i=e.openElements.stackTop;i>0;i--){const s=e.openElements.items[i],o=e.openElements.tagIDs[i];if(r===o&&(r!==_.UNKNOWN||e.treeAdapter.getTagName(s)===n)){e.openElements.generateImpliedEndTagsWithExclusion(r),e.openElements.stackTop>=i&&e.openElements.shortenToLength(i);break}if(e._isSpecialElement(s,o))break}}function xC(e,t){switch(t.tagID){case _.A:case _.B:case _.I:case _.S:case _.U:case _.EM:case _.TT:case _.BIG:case _.CODE:case _.FONT:case _.NOBR:case _.SMALL:case _.STRIKE:case _.STRONG:{b6(e,t);break}case _.P:{Vje(e);break}case _.DL:case _.UL:case _.OL:case _.DIR:case _.DIV:case _.NAV:case _.PRE:case _.MAIN:case _.MENU:case _.ASIDE:case _.BUTTON:case _.CENTER:case _.FIGURE:case _.FOOTER:case _.HEADER:case _.HGROUP:case _.DIALOG:case _.ADDRESS:case _.ARTICLE:case _.DETAILS:case _.SECTION:case _.SUMMARY:case _.LISTING:case _.FIELDSET:case _.BLOCKQUOTE:case _.FIGCAPTION:{jje(e,t);break}case _.LI:{zje(e);break}case _.DD:case _.DT:{Hje(e,t);break}case _.H1:case _.H2:case _.H3:case _.H4:case _.H5:case _.H6:{Wje(e);break}case _.BR:{Gje(e);break}case _.BODY:{Fje(e,t);break}case _.HTML:{Bje(e,t);break}case _.FORM:{Uje(e);break}case _.APPLET:case _.OBJECT:case _.MARQUEE:{qje(e,t);break}case _.TEMPLATE:{Fh(e,t);break}default:aie(e,t)}}function uie(e,t){e.tmplInsertionModeStack.length>0?mie(e,t):w6(e,t)}function Yje(e,t){var n;t.tagID===_.SCRIPT&&((n=e.scriptHandler)===null||n===void 0||n.call(e,e.openElements.current)),e.openElements.pop(),e.insertionMode=e.originalInsertionMode}function Kje(e,t){e._err(t,_e.eofInElementThatCanContainOnlyText),e.openElements.pop(),e.insertionMode=e.originalInsertionMode,e.onEof(t)}function AO(e,t){if(nie.has(e.openElements.currentTagId))switch(e.pendingCharacterTokens.length=0,e.hasNonWhitespacePendingCharacterToken=!1,e.originalInsertionMode=e.insertionMode,e.insertionMode=Y.IN_TABLE_TEXT,t.type){case Yt.CHARACTER:{cie(e,t);break}case Yt.WHITESPACE_CHARACTER:{lie(e,t);break}}else Z_(e,t)}function Qje(e,t){e.openElements.clearBackToTableContext(),e.activeFormattingElements.insertMarker(),e._insertElement(t,we.HTML),e.insertionMode=Y.IN_CAPTION}function Xje(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,we.HTML),e.insertionMode=Y.IN_COLUMN_GROUP}function Jje(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(le.COLGROUP,_.COLGROUP),e.insertionMode=Y.IN_COLUMN_GROUP,E6(e,t)}function Zje(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,we.HTML),e.insertionMode=Y.IN_TABLE_BODY}function eUe(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(le.TBODY,_.TBODY),e.insertionMode=Y.IN_TABLE_BODY,CC(e,t)}function tUe(e,t){e.openElements.hasInTableScope(_.TABLE)&&(e.openElements.popUntilTagNamePopped(_.TABLE),e._resetInsertionMode(),e._processStartTag(t))}function nUe(e,t){oie(t)?e._appendElement(t,we.HTML):Z_(e,t),t.ackSelfClosing=!0}function rUe(e,t){!e.formElement&&e.openElements.tmplCount===0&&(e._insertElement(t,we.HTML),e.formElement=e.openElements.current,e.openElements.pop())}function zm(e,t){switch(t.tagID){case _.TD:case _.TH:case _.TR:{eUe(e,t);break}case _.STYLE:case _.SCRIPT:case _.TEMPLATE:{nu(e,t);break}case _.COL:{Jje(e,t);break}case _.FORM:{rUe(e,t);break}case _.TABLE:{tUe(e,t);break}case _.TBODY:case _.TFOOT:case _.THEAD:{Zje(e,t);break}case _.INPUT:{nUe(e,t);break}case _.CAPTION:{Qje(e,t);break}case _.COLGROUP:{Xje(e,t);break}default:Z_(e,t)}}function Av(e,t){switch(t.tagID){case _.TABLE:{e.openElements.hasInTableScope(_.TABLE)&&(e.openElements.popUntilTagNamePopped(_.TABLE),e._resetInsertionMode());break}case _.TEMPLATE:{Fh(e,t);break}case _.BODY:case _.CAPTION:case _.COL:case _.COLGROUP:case _.HTML:case _.TBODY:case _.TD:case _.TFOOT:case _.TH:case _.THEAD:case _.TR:break;default:Z_(e,t)}}function Z_(e,t){const n=e.fosterParentingEnabled;e.fosterParentingEnabled=!0,IC(e,t),e.fosterParentingEnabled=n}function lie(e,t){e.pendingCharacterTokens.push(t)}function cie(e,t){e.pendingCharacterTokens.push(t),e.hasNonWhitespacePendingCharacterToken=!0}function I0(e,t){let n=0;if(e.hasNonWhitespacePendingCharacterToken)for(;n0&&e.openElements.currentTagId===_.OPTION&&e.openElements.tagIDs[e.openElements.stackTop-1]===_.OPTGROUP&&e.openElements.pop(),e.openElements.currentTagId===_.OPTGROUP&&e.openElements.pop();break}case _.OPTION:{e.openElements.currentTagId===_.OPTION&&e.openElements.pop();break}case _.SELECT:{e.openElements.hasInSelectScope(_.SELECT)&&(e.openElements.popUntilTagNamePopped(_.SELECT),e._resetInsertionMode());break}case _.TEMPLATE:{Fh(e,t);break}}}function lUe(e,t){const n=t.tagID;n===_.CAPTION||n===_.TABLE||n===_.TBODY||n===_.TFOOT||n===_.THEAD||n===_.TR||n===_.TD||n===_.TH?(e.openElements.popUntilTagNamePopped(_.SELECT),e._resetInsertionMode(),e._processStartTag(t)):hie(e,t)}function cUe(e,t){const n=t.tagID;n===_.CAPTION||n===_.TABLE||n===_.TBODY||n===_.TFOOT||n===_.THEAD||n===_.TR||n===_.TD||n===_.TH?e.openElements.hasInTableScope(n)&&(e.openElements.popUntilTagNamePopped(_.SELECT),e._resetInsertionMode(),e.onEndTag(t)):pie(e,t)}function fUe(e,t){switch(t.tagID){case _.BASE:case _.BASEFONT:case _.BGSOUND:case _.LINK:case _.META:case _.NOFRAMES:case _.SCRIPT:case _.STYLE:case _.TEMPLATE:case _.TITLE:{nu(e,t);break}case _.CAPTION:case _.COLGROUP:case _.TBODY:case _.TFOOT:case _.THEAD:{e.tmplInsertionModeStack[0]=Y.IN_TABLE,e.insertionMode=Y.IN_TABLE,zm(e,t);break}case _.COL:{e.tmplInsertionModeStack[0]=Y.IN_COLUMN_GROUP,e.insertionMode=Y.IN_COLUMN_GROUP,E6(e,t);break}case _.TR:{e.tmplInsertionModeStack[0]=Y.IN_TABLE_BODY,e.insertionMode=Y.IN_TABLE_BODY,CC(e,t);break}case _.TD:case _.TH:{e.tmplInsertionModeStack[0]=Y.IN_ROW,e.insertionMode=Y.IN_ROW,AC(e,t);break}default:e.tmplInsertionModeStack[0]=Y.IN_BODY,e.insertionMode=Y.IN_BODY,ls(e,t)}}function dUe(e,t){t.tagID===_.TEMPLATE&&Fh(e,t)}function mie(e,t){e.openElements.tmplCount>0?(e.openElements.popUntilTagNamePopped(_.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode(),e.onEof(t)):w6(e,t)}function hUe(e,t){t.tagID===_.HTML?ls(e,t):jT(e,t)}function gie(e,t){var n;if(t.tagID===_.HTML){if(e.fragmentContext||(e.insertionMode=Y.AFTER_AFTER_BODY),e.options.sourceCodeLocationInfo&&e.openElements.tagIDs[0]===_.HTML){e._setEndLocation(e.openElements.items[0],t);const r=e.openElements.items[1];r&&!(!((n=e.treeAdapter.getNodeSourceCodeLocation(r))===null||n===void 0)&&n.endTag)&&e._setEndLocation(r,t)}}else jT(e,t)}function jT(e,t){e.insertionMode=Y.IN_BODY,IC(e,t)}function pUe(e,t){switch(t.tagID){case _.HTML:{ls(e,t);break}case _.FRAMESET:{e._insertElement(t,we.HTML);break}case _.FRAME:{e._appendElement(t,we.HTML),t.ackSelfClosing=!0;break}case _.NOFRAMES:{nu(e,t);break}}}function mUe(e,t){t.tagID===_.FRAMESET&&!e.openElements.isRootHtmlElementCurrent()&&(e.openElements.pop(),!e.fragmentContext&&e.openElements.currentTagId!==_.FRAMESET&&(e.insertionMode=Y.AFTER_FRAMESET))}function gUe(e,t){switch(t.tagID){case _.HTML:{ls(e,t);break}case _.NOFRAMES:{nu(e,t);break}}}function yUe(e,t){t.tagID===_.HTML&&(e.insertionMode=Y.AFTER_AFTER_FRAMESET)}function vUe(e,t){t.tagID===_.HTML?ls(e,t):Fw(e,t)}function Fw(e,t){e.insertionMode=Y.IN_BODY,IC(e,t)}function _Ue(e,t){switch(t.tagID){case _.HTML:{ls(e,t);break}case _.NOFRAMES:{nu(e,t);break}}}function bUe(e,t){t.chars=lr,e._insertCharacters(t)}function wUe(e,t){e._insertCharacters(t),e.framesetOk=!1}function yie(e){for(;e.treeAdapter.getNamespaceURI(e.openElements.current)!==we.HTML&&!e._isIntegrationPoint(e.openElements.currentTagId,e.openElements.current);)e.openElements.pop()}function EUe(e,t){if(MBe(t))yie(e),e._startTagOutsideForeignContent(t);else{const n=e._getAdjustedCurrentElement(),r=e.treeAdapter.getNamespaceURI(n);r===we.MATHML?eie(t):r===we.SVG&&(FBe(t),tie(t)),_6(t),t.selfClosing?e._appendElement(t,r):e._insertElement(t,r),t.ackSelfClosing=!0}}function SUe(e,t){if(t.tagID===_.P||t.tagID===_.BR){yie(e),e._endTagOutsideForeignContent(t);return}for(let n=e.openElements.stackTop;n>0;n--){const r=e.openElements.items[n];if(e.treeAdapter.getNamespaceURI(r)===we.HTML){e._endTagOutsideForeignContent(t);break}const i=e.treeAdapter.getTagName(r);if(i.toLowerCase()===t.tagName){t.tagName=i,e.openElements.shortenToLength(n);break}}}le.AREA,le.BASE,le.BASEFONT,le.BGSOUND,le.BR,le.COL,le.EMBED,le.FRAME,le.HR,le.IMG,le.INPUT,le.KEYGEN,le.LINK,le.META,le.PARAM,le.SOURCE,le.TRACK,le.WBR;const vie=_ie("end"),Bh=_ie("start");function _ie(e){return t;function t(n){const r=n&&n.position&&n.position[e]||{};if(typeof r.line=="number"&&r.line>0&&typeof r.column=="number"&&r.column>0)return{line:r.line,column:r.column,offset:typeof r.offset=="number"&&r.offset>-1?r.offset:void 0}}}const bie=function(e){if(e==null)return CUe;if(typeof e=="function")return PC(e);if(typeof e=="object")return Array.isArray(e)?TUe(e):IUe(e);if(typeof e=="string")return xUe(e);throw new Error("Expected function, string, or object as test")};function TUe(e){const t=[];let n=-1;for(;++n":""))+")"})}return d;function d(){let h=wie,p,m,y;if((!t||s(u,l,c[c.length-1]||void 0))&&(h=NUe(n(u,c)),h[0]===x7))return h;if("children"in u&&u.children){const g=u;if(g.children&&h[0]!==OUe)for(m=(r?g.children.length:-1)+o,y=c.concat(g);m>-1&&mC.jsx(B_,{...r}),p:({node:n,...r})=>C.jsx(rt,{...r,pb:8}),h1:({node:n,...r})=>C.jsx($c,{order:1,...r,pb:12}),h2:({node:n,...r})=>C.jsx($c,{order:2,...r,pb:12}),h3:({node:n,...r})=>C.jsx($c,{order:3,...r,pb:12}),h4:({node:n,...r})=>C.jsx($c,{order:4,...r,pb:12}),h5:({node:n,...r})=>C.jsx($c,{order:5,...r,pb:12}),h6:({node:n,...r})=>C.jsx($c,{order:6,...r,pb:12}),a:({node:n,...r})=>C.jsx(RQ,{...r}),ul:({node:n,...r})=>C.jsx(Bm,{withPadding:!0,...r,pb:8}),ol:({node:n,...r})=>C.jsx(Bm,{type:"ordered",withPadding:!0,...r,pb:8})};return C.jsx("div",{style:{display:"inherit"},children:C.jsx(Rre,{components:t,rehypePlugins:[qUe],children:e})})}function GUe({response:e,disabled:t,answer:n}){const{prompt:r,required:i,options:s}=e;return C.jsx(Mm.Group,{label:C.jsx(ro,{text:r}),withAsterisk:i,...n,error:Lh(e,n,s),size:"md",children:C.jsx(ei,{mt:"md",children:s.map(o=>C.jsx(Mm,{disabled:t,value:o.value,label:o.label},o.value))})})}function YUe({response:e,disabled:t,answer:n}){const{placeholder:r,prompt:i,required:s,options:o}=e;return C.jsx(rte,{disabled:t,label:C.jsx(ro,{text:i}),placeholder:r,data:o,withAsterisk:s,radius:"md",size:"md",...n,error:Lh(e,n,o)})}function KUe({response:e,answer:t}){const{prompt:n}=e;return C.jsxs(C.Fragment,{children:[C.jsx(rt,{fz:"md",fw:500,children:C.jsx(ro,{text:n})}),C.jsx(Bm,{children:Array.isArray(t.value)&&t.value.map(r=>C.jsx(Bm.Item,{children:r},r))})]})}function xie({response:e,disabled:t,answer:n}){const{prompt:r,required:i,options:s,leftLabel:o,rightLabel:a}=e;return C.jsxs(cT.Group,{name:`radioInput${e.id}`,label:C.jsx(ro,{text:r}),withAsterisk:i,size:"md",...n,error:Lh(e,n,s),children:[o?C.jsx(rt,{children:o}):null,C.jsx(ei,{mt:"xs",noWrap:!0,children:s.map(u=>C.jsx(cT,{disabled:t,value:u.value,label:u.label},u.label))}),C.jsx(rt,{children:a})]},e.id)}function QUe({response:e,disabled:t,answer:n}){const{preset:r}=e,i=[];for(let o=1;o<=+r;o+=1)i.push({label:`${o}`,value:`${o}`});const s={...e,type:"radio",options:i};return C.jsx(xie,{disabled:t,response:s,answer:n})}function XUe({response:e,disabled:t,answer:n}){const{prompt:r,required:i,min:s,max:o,placeholder:a}=e;return C.jsx(kee,{disabled:t,placeholder:a,label:C.jsx(ro,{text:r}),withAsterisk:i,radius:"md",size:"md",min:s,max:o,...n,error:Lh(e,n)})}function JUe({response:e,disabled:t,answer:n}){const{prompt:r,options:i,leftLabel:s,rightLabel:o,required:a}=e,u=Lh(e,n);return C.jsx(Zs.Wrapper,{withAsterisk:a,label:C.jsx(ro,{text:r}),error:u,size:"md",children:C.jsxs(ei,{children:[s?C.jsx(ua,{children:C.jsx(rt,{children:s})}):null,C.jsx(fte,{disabled:t,labelAlwaysOn:n.value!=="",label:l=>`$${l}`,sx:{marginTop:"15px",marginBottom:"15px",width:"400px"},marks:i,...n,defaultValue:50,thumbSize:n.value===""?.1:17,color:n.value===""?"gray.2":"blue",min:0,max:100,showLabelOnHover:!1,styles:l=>({markFilled:{borderColor:"#E9ECEF",backgroundColor:"white"},bar:{backgroundColor:"#E9ECEF"},markLabel:{fontSize:l.fontSizes.sm,marginBottom:5,marginTop:0}})}),o?C.jsx(ua,{children:C.jsx(rt,{children:o})}):null]})})}function ZUe({response:e,disabled:t,answer:n}){const{placeholder:r,prompt:i,required:s}=e;return C.jsx(Ev,{disabled:t,placeholder:r,label:C.jsx(ro,{text:i}),radius:"md",size:"md",withAsterisk:s,...n,value:n.value||"",error:Lh(e,n)})}function eVe({response:e,disabled:t,answer:n}){const{placeholder:r,prompt:i,required:s}=e;return C.jsx(jZ,{disabled:t,placeholder:r,label:C.jsx(ro,{text:i}),radius:"md",size:"md",withAsterisk:s,...n,value:n.value||"",error:Lh(e,n)})}function tVe({response:e,answer:t,storedAnswer:n}){const r=(n?{value:n}:t)||{value:void 0},i=!!n,[s]=p$(),o=w.useMemo(()=>{if(e.paramCapture){const a=s.get(e.paramCapture);return i||!!a}return i},[i,e.paramCapture,s]);return C.jsxs(it,{sx:{margin:10,padding:5},children:[e.type==="numerical"&&C.jsx(XUe,{response:e,disabled:o,answer:r}),e.type==="shortText"&&C.jsx(ZUe,{response:e,disabled:o,answer:r}),e.type==="longText"&&C.jsx(eVe,{response:e,disabled:o,answer:r}),e.type==="likert"&&C.jsx(QUe,{response:e,disabled:o,answer:r}),e.type==="dropdown"&&C.jsx(YUe,{response:e,disabled:o,answer:r}),e.type==="slider"&&C.jsx(JUe,{response:e,disabled:o,answer:r}),e.type==="radio"&&C.jsx(xie,{response:e,disabled:o,answer:r}),e.type==="checkbox"&&C.jsx(GUe,{response:e,disabled:o,answer:r}),e.type==="iframe"&&C.jsx(KUe,{response:e,answer:r})]})}function UT({config:e,location:t,status:n,style:r}){var y,g;const i=hl(),s=n==null?void 0:n.answer,o=e,a=((y=o==null?void 0:o.response)==null?void 0:y.filter(v=>v.location?v.location===t:t==="belowStimulus"))||[],u=Ju(),{updateResponseBlockValidation:l}=Xu(),c=t4e(a,i,s||{}),[f,d]=w.useState(!1),{iframeAnswers:h}=la(v=>v),p=(((g=o==null?void 0:o.correctAnswer)==null?void 0:g.length)||0)>0,m=t===((o==null?void 0:o.nextButtonLocation)||"belowStimulus");return w.useEffect(()=>{const v=a.find(b=>b.type==="iframe");if(v){const b=v.id;c.setValues({...c.values,[b]:h})}},[h]),w.useEffect(()=>{u(l({location:t,currentStep:i,status:c.isValid(),values:Ig(c.values)}))},[c.values,i,t]),C.jsxs("div",{style:r,children:[a.map(v=>{var b,S;return C.jsx(N.Fragment,{children:v.hidden?"":C.jsxs(C.Fragment,{children:[C.jsx(tVe,{storedAnswer:s?s[v.id]:void 0,answer:{...c.getInputProps(v.id,{type:v.type==="checkbox"?"checkbox":"input"})},response:v}),p&&f&&C.jsx(rt,{children:`The correct answer is: ${(S=(b=o.correctAnswer)==null?void 0:b.find(T=>T.id===v.id))==null?void 0:S.answer}`})]})},`${v.id}-${i}`)}),C.jsxs(ei,{position:"right",spacing:"xs",mt:"xl",children:[p&&m&&C.jsx(Ws,{onClick:()=>d(!0),disabled:!c.isValid(),children:"Check Answer"}),m&&C.jsx(CMe,{disabled:p&&!f,setCheckClicked:d,label:o.nextButtonText||"Next"})]})]})}const kb="@REVISIT_COMMS",nVe={minHeight:"500px",width:"100%",border:0,marginTop:"-50px"};function rVe({currentConfig:e}){const{setIframeAnswers:t}=Xu(),n=Ju(),r=Ote(),i=w.useRef(null),s=w.useMemo(()=>crypto.randomUUID?crypto.randomUUID():`testID-${Date.now()}`,[]),o=hl(),a=Kf(),u=w.useCallback((l,c)=>{var f,d;(d=(f=i.current)==null?void 0:f.contentWindow)==null||d.postMessage({error:!1,type:`${kb}/${l}`,iframeId:s,message:c},"*")},[i,s]);return w.useEffect(()=>{const l=c=>{const{data:f}=c;if(typeof f=="object"&&s===f.iframeId)switch(f.type){case`${kb}/WINDOW_READY`:e.parameters&&u("STUDY_DATA",e.parameters);break;case`${kb}/READY`:i.current&&(i.current.style.height=`${f.message.documentHeight}px`);break;case`${kb}/ANSWERS`:n(t(f.message.answer));break}};return window.addEventListener("message",l),()=>window.removeEventListener("message",l)},[n,o,r,s,a,e,u,t]),C.jsx("div",{children:C.jsx("iframe",{ref:i,src:`${fl}${e.path}?trialid=${o}&id=${s}`,style:nVe})})}const iVe={maxWidth:"100%"};function sVe({currentConfig:e}){const t={...iVe,...e.style};return C.jsx(B_,{mx:"auto",src:`${fl}${e.path}`,style:t})}function A7({parameters:e,setAnswer:t}){return w.useEffect(()=>{navigator.mediaDevices.getUserMedia({audio:!0}).then(r=>{new MediaRecorder(r).start();const s=new AudioContext,o=s.createMediaStreamSource(r),a=s.createAnalyser();a.minDecibels=-45,o.connect(a);const u=a.frequencyBinCount,l=new Uint8Array(u);let c=!1;const f=()=>{if(!c){a.getByteFrequencyData(l);for(let d=0;d0&&(c=!0,t({status:!0,provenanceGraph:void 0,answers:{audioTest:!0}}));window.requestAnimationFrame(f)}};window.requestAnimationFrame(f)})},[t]),C.jsx(ua,{style:{height:"70%",width:"100%"},children:C.jsxs(ys,{children:[C.jsx(rt,{ta:"center",children:"Please allow us to access your microphone. There may be a popup in your browser window asking for access, click accept."}),C.jsx(rt,{ta:"center",children:"Once we can confirm that your microphone is on and we hear you say something, the continue button will become available."}),C.jsx(rt,{ta:"center",weight:700,children:"If you are not comfortable or able to speak English during this study, please close it now."})]})})}const oVe=Object.freeze(Object.defineProperty({__proto__:null,AudioTest:A7,default:A7},Symbol.toStringTag,{value:"Module"})),Si={Purple:"#6D3E91",DarkOrange:"#C05917",LightTeal:"#58AC8C",Blue:"#286BBB",Maroon:"#883039",Camel:"#BC8E5A",MidnightBlue:"#00295B",DustyCoral:"#C15065",DarkOliveGreen:"#18470F",DarkCopper:"#9A5129",Peach:"#E56E5A",Mauve:"#A2559C",Turquoise:"#38AABA",OliveGreen:"#578145",Cherry:"#970046",Teal:"#00847E",RustyOrange:"#B13507",Denim:"#4C6A9C",Fuchsia:"#CF0A66",TealishGreen:"#00875E",Copper:"#B16214",DarkMauve:"#8C4569",Lime:"#3B8E1D",Coral:"#D73C50"},rp={DarkOrangeDarker:"#BE5915",PeachDarker:"#C4523E",LightTealDarker:"#2C8465",TurquoiseDarker:"#008291",CamelDarker:"#996D39",LimeDarker:"#338711"},S6=[Si.DustyCoral,rp.LightTealDarker,rp.DarkOrangeDarker,Si.Purple,Si.DarkOliveGreen,Si.Blue,Si.Maroon,rp.CamelDarker,Si.MidnightBlue,Si.DarkCopper,rp.PeachDarker,Si.Mauve,rp.TurquoiseDarker,Si.OliveGreen,Si.Cherry,Si.Teal,Si.RustyOrange,Si.Denim,Si.TealishGreen,Si.Copper,Si.DarkMauve,rp.LimeDarker,Si.Coral],aVe=Object.freeze(Object.defineProperty({__proto__:null,OwidDistinctLinesPalette:S6},Symbol.toStringTag,{value:"Module"}));function cm(e,t){return e==null||t==null?NaN:et?1:e>=t?0:NaN}function uVe(e,t){return e==null||t==null?NaN:te?1:t>=e?0:NaN}function T6(e){let t,n,r;e.length!==2?(t=cm,n=(a,u)=>cm(e(a),u),r=(a,u)=>e(a)-u):(t=e===cm||e===uVe?e:lVe,n=e,r=e);function i(a,u,l=0,c=a.length){if(l>>1;n(a[f],u)<0?l=f+1:c=f}while(l>>1;n(a[f],u)<=0?l=f+1:c=f}while(ll&&r(a[f-1],u)>-r(a[f],u)?f-1:f}return{left:i,center:o,right:s}}function lVe(){return 0}function cVe(e){return e===null?NaN:+e}function*fVe(e,t){if(t===void 0)for(let n of e)n!=null&&(n=+n)>=n&&(yield n);else{let n=-1;for(let r of e)(r=t(r,++n,e))!=null&&(r=+r)>=r&&(yield r)}}const dVe=T6(cm),hVe=dVe.right;T6(cVe).center;function Pf(e,t){let n,r;if(t===void 0)for(const i of e)i!=null&&(n===void 0?i>=i&&(n=r=i):(n>i&&(n=i),r=s&&(n=r=s):(n>s&&(n=s),r=r.length)return n(s);const a=new LN,u=r[o++];let l=-1;for(const c of s){const f=u(c,++l,s),d=a.get(f);d?d.push(c):a.set(f,[c])}for(const[c,f]of a)a.set(c,i(f,o));return t(a)}(e,0)}function bVe(e=cm){if(e===cm)return Cie;if(typeof e!="function")throw new TypeError("compare is not a function");return(t,n)=>{const r=e(t,n);return r||r===0?r:(e(n,n)===0)-(e(t,t)===0)}}function Cie(e,t){return(e==null||!(e>=e))-(t==null||!(t>=t))||(et?1:0)}const wVe=Math.sqrt(50),EVe=Math.sqrt(10),SVe=Math.sqrt(2);function VT(e,t,n){const r=(t-e)/Math.max(0,n),i=Math.floor(Math.log10(r)),s=r/Math.pow(10,i),o=s>=wVe?10:s>=EVe?5:s>=SVe?2:1;let a,u,l;return i<0?(l=Math.pow(10,-i)/o,a=Math.round(e*l),u=Math.round(t*l),a/lt&&--u,l=-l):(l=Math.pow(10,i)*o,a=Math.round(e/l),u=Math.round(t/l),a*lt&&--u),u0))return[];if(e===t)return[e];const r=t=i))return[];const a=s-i+1,u=new Array(a);if(r)if(o<0)for(let l=0;l=r)&&(n=r);else{let r=-1;for(let i of e)(i=t(i,++r,e))!=null&&(n=i)&&(n=i)}return n}function zT(e,t){let n;if(t===void 0)for(const r of e)r!=null&&(n>r||n===void 0&&r>=r)&&(n=r);else{let r=-1;for(let i of e)(i=t(i,++r,e))!=null&&(n>i||n===void 0&&i>=i)&&(n=i)}return n}function Aie(e,t,n=0,r=1/0,i){if(t=Math.floor(t),n=Math.floor(Math.max(0,n)),r=Math.floor(Math.min(e.length-1,r)),!(n<=t&&t<=r))return e;for(i=i===void 0?Cie:bVe(i);r>n;){if(r-n>600){const u=r-n+1,l=t-n+1,c=Math.log(u),f=.5*Math.exp(2*c/3),d=.5*Math.sqrt(c*f*(u-f)/u)*(l-u/2<0?-1:1),h=Math.max(n,Math.floor(t-l*f/u+d)),p=Math.min(r,Math.floor(t+(u-l)*f/u+d));Aie(e,t,h,p,i)}const s=e[t];let o=n,a=r;for(x0(e,n,t),i(e[r],s)>0&&x0(e,n,r);o0;)--a}i(e[n],s)===0?x0(e,n,a):(++a,x0(e,a,r)),a<=t&&(n=a+1),t<=a&&(r=a-1)}return e}function x0(e,t,n){const r=e[t];e[t]=e[n],e[n]=r}function PO(e,t,n){if(e=Float64Array.from(fVe(e,n)),!(!(r=e.length)||isNaN(t=+t))){if(t<=0||r<2)return zT(e);if(t>=1)return Pv(e);var r,i=(r-1)*t,s=Math.floor(i),o=Pv(Aie(e,s).subarray(0,s+1)),a=zT(e.subarray(s+1));return o+(a-o)*(i-s)}}function I6(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function Pie(e,t){var n=Object.create(e.prototype);for(var r in t)n[r]=t[r];return n}function t1(){}var Ov=.7,HT=1/Ov,fm="\\s*([+-]?\\d+)\\s*",Rv="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",Uu="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",IVe=/^#([0-9a-f]{3,8})$/,xVe=new RegExp(`^rgb\\(${fm},${fm},${fm}\\)$`),CVe=new RegExp(`^rgb\\(${Uu},${Uu},${Uu}\\)$`),AVe=new RegExp(`^rgba\\(${fm},${fm},${fm},${Rv}\\)$`),PVe=new RegExp(`^rgba\\(${Uu},${Uu},${Uu},${Rv}\\)$`),OVe=new RegExp(`^hsl\\(${Rv},${Uu},${Uu}\\)$`),RVe=new RegExp(`^hsla\\(${Rv},${Uu},${Uu},${Rv}\\)$`),O7={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};I6(t1,Nv,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:R7,formatHex:R7,formatHex8:NVe,formatHsl:kVe,formatRgb:N7,toString:N7});function R7(){return this.rgb().formatHex()}function NVe(){return this.rgb().formatHex8()}function kVe(){return Oie(this).formatHsl()}function N7(){return this.rgb().formatRgb()}function Nv(e){var t,n;return e=(e+"").trim().toLowerCase(),(t=IVe.exec(e))?(n=t[1].length,t=parseInt(t[1],16),n===6?k7(t):n===3?new qs(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):n===8?Db(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):n===4?Db(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|t&240,((t&15)<<4|t&15)/255):null):(t=xVe.exec(e))?new qs(t[1],t[2],t[3],1):(t=CVe.exec(e))?new qs(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=AVe.exec(e))?Db(t[1],t[2],t[3],t[4]):(t=PVe.exec(e))?Db(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=OVe.exec(e))?L7(t[1],t[2]/100,t[3]/100,1):(t=RVe.exec(e))?L7(t[1],t[2]/100,t[3]/100,t[4]):O7.hasOwnProperty(e)?k7(O7[e]):e==="transparent"?new qs(NaN,NaN,NaN,0):null}function k7(e){return new qs(e>>16&255,e>>8&255,e&255,1)}function Db(e,t,n,r){return r<=0&&(e=t=n=NaN),new qs(e,t,n,r)}function DVe(e){return e instanceof t1||(e=Nv(e)),e?(e=e.rgb(),new qs(e.r,e.g,e.b,e.opacity)):new qs}function BN(e,t,n,r){return arguments.length===1?DVe(e):new qs(e,t,n,r??1)}function qs(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}I6(qs,BN,Pie(t1,{brighter(e){return e=e==null?HT:Math.pow(HT,e),new qs(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?Ov:Math.pow(Ov,e),new qs(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new qs(Jd(this.r),Jd(this.g),Jd(this.b),WT(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:D7,formatHex:D7,formatHex8:$Ve,formatRgb:$7,toString:$7}));function D7(){return`#${$d(this.r)}${$d(this.g)}${$d(this.b)}`}function $Ve(){return`#${$d(this.r)}${$d(this.g)}${$d(this.b)}${$d((isNaN(this.opacity)?1:this.opacity)*255)}`}function $7(){const e=WT(this.opacity);return`${e===1?"rgb(":"rgba("}${Jd(this.r)}, ${Jd(this.g)}, ${Jd(this.b)}${e===1?")":`, ${e})`}`}function WT(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function Jd(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function $d(e){return e=Jd(e),(e<16?"0":"")+e.toString(16)}function L7(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new $a(e,t,n,r)}function Oie(e){if(e instanceof $a)return new $a(e.h,e.s,e.l,e.opacity);if(e instanceof t1||(e=Nv(e)),!e)return new $a;if(e instanceof $a)return e;e=e.rgb();var t=e.r/255,n=e.g/255,r=e.b/255,i=Math.min(t,n,r),s=Math.max(t,n,r),o=NaN,a=s-i,u=(s+i)/2;return a?(t===s?o=(n-r)/a+(n0&&u<1?0:o,new $a(o,a,u,e.opacity)}function LVe(e,t,n,r){return arguments.length===1?Oie(e):new $a(e,t,n,r??1)}function $a(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}I6($a,LVe,Pie(t1,{brighter(e){return e=e==null?HT:Math.pow(HT,e),new $a(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?Ov:Math.pow(Ov,e),new $a(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+(this.h<0)*360,t=isNaN(e)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*t,i=2*n-r;return new qs(OO(e>=240?e-240:e+120,i,r),OO(e,i,r),OO(e<120?e+240:e-120,i,r),this.opacity)},clamp(){return new $a(M7(this.h),$b(this.s),$b(this.l),WT(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=WT(this.opacity);return`${e===1?"hsl(":"hsla("}${M7(this.h)}, ${$b(this.s)*100}%, ${$b(this.l)*100}%${e===1?")":`, ${e})`}`}}));function M7(e){return e=(e||0)%360,e<0?e+360:e}function $b(e){return Math.max(0,Math.min(1,e||0))}function OO(e,t,n){return(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)*255}const x6=e=>()=>e;function MVe(e,t){return function(n){return e+n*t}}function FVe(e,t,n){return e=Math.pow(e,n),t=Math.pow(t,n)-e,n=1/n,function(r){return Math.pow(e+r*t,n)}}function BVe(e){return(e=+e)==1?Rie:function(t,n){return n-t?FVe(t,n,e):x6(isNaN(t)?n:t)}}function Rie(e,t){var n=t-e;return n?MVe(e,n):x6(isNaN(e)?t:e)}const F7=function e(t){var n=BVe(t);function r(i,s){var o=n((i=BN(i)).r,(s=BN(s)).r),a=n(i.g,s.g),u=n(i.b,s.b),l=Rie(i.opacity,s.opacity);return function(c){return i.r=o(c),i.g=a(c),i.b=u(c),i.opacity=l(c),i+""}}return r.gamma=e,r}(1);function jVe(e,t){t||(t=[]);var n=e?Math.min(t.length,e.length):0,r=t.slice(),i;return function(s){for(i=0;in&&(s=t.slice(n,s),a[o]?a[o]+=s:a[++o]=s),(r=r[0])===(i=i[0])?a[o]?a[o]+=i:a[++o]=i:(a[++o]=null,u.push({i:o,x:qT(r,i)})),n=RO.lastIndex;return n=0))throw new Error(`invalid digits: ${e}`);if(t>15)return Nie;const n=10**t;return function(r){this._+=r[0];for(let i=1,s=r.length;igd)if(!(Math.abs(f*u-l*c)>gd)||!s)this._append`L${this._x1=t},${this._y1=n}`;else{let h=r-o,p=i-a,m=u*u+l*l,y=h*h+p*p,g=Math.sqrt(m),v=Math.sqrt(d),b=s*Math.tan((UN-Math.acos((m+d-y)/(2*g*v)))/2),S=b/v,T=b/g;Math.abs(S-1)>gd&&this._append`L${t+S*c},${n+S*f}`,this._append`A${s},${s},0,0,${+(f*h>c*p)},${this._x1=t+T*u},${this._y1=n+T*l}`}}arc(t,n,r,i,s,o){if(t=+t,n=+n,r=+r,o=!!o,r<0)throw new Error(`negative radius: ${r}`);let a=r*Math.cos(i),u=r*Math.sin(i),l=t+a,c=n+u,f=1^o,d=o?i-s:s-i;this._x1===null?this._append`M${l},${c}`:(Math.abs(this._x1-l)>gd||Math.abs(this._y1-c)>gd)&&this._append`L${l},${c}`,r&&(d<0&&(d=d%VN+VN),d>KVe?this._append`A${r},${r},0,1,${f},${t-a},${n-u}A${r},${r},0,1,${f},${this._x1=l},${this._y1=c}`:d>gd&&this._append`A${r},${r},0,${+(d>=UN)},${f},${this._x1=t+r*Math.cos(s)},${this._y1=n+r*Math.sin(s)}`)}rect(t,n,r,i){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+n}h${r=+r}v${+i}h${-r}Z`}toString(){return this._}}var B7={},NO={},kO=34,C0=10,DO=13;function kie(e){return new Function("d","return {"+e.map(function(t,n){return JSON.stringify(t)+": d["+n+'] || ""'}).join(",")+"}")}function JVe(e,t){var n=kie(e);return function(r,i){return t(n(r),i,e)}}function j7(e){var t=Object.create(null),n=[];return e.forEach(function(r){for(var i in r)i in t||n.push(t[i]=i)}),n}function Ns(e,t){var n=e+"",r=n.length;return r9999?"+"+Ns(e,6):Ns(e,4)}function e7e(e){var t=e.getUTCHours(),n=e.getUTCMinutes(),r=e.getUTCSeconds(),i=e.getUTCMilliseconds();return isNaN(e)?"Invalid Date":ZVe(e.getUTCFullYear())+"-"+Ns(e.getUTCMonth()+1,2)+"-"+Ns(e.getUTCDate(),2)+(i?"T"+Ns(t,2)+":"+Ns(n,2)+":"+Ns(r,2)+"."+Ns(i,3)+"Z":r?"T"+Ns(t,2)+":"+Ns(n,2)+":"+Ns(r,2)+"Z":n||t?"T"+Ns(t,2)+":"+Ns(n,2)+"Z":"")}function t7e(e){var t=new RegExp('["'+e+` -\r]`),n=e.charCodeAt(0);function r(f,d){var h,p,m=i(f,function(y,g){if(h)return h(y,g-1);p=y,h=d?JVe(y,d):kie(y)});return m.columns=p||[],m}function i(f,d){var h=[],p=f.length,m=0,y=0,g,v=p<=0,b=!1;f.charCodeAt(p-1)===C0&&--p,f.charCodeAt(p-1)===DO&&--p;function S(){if(v)return NO;if(b)return b=!1,B7;var E,I=m,A;if(f.charCodeAt(I)===kO){for(;m++=p?v=!0:(A=f.charCodeAt(m++))===C0?b=!0:A===DO&&(b=!0,f.charCodeAt(m)===C0&&++m),f.slice(I+1,E-1).replace(/""/g,'"')}for(;m0?N.createElement(h,u,f):N.createElement(h,u)}function m9e(e){let t=-1;for(;++t for more info)`),delete Pb[s]}const t=R4e().use(jFe).use(e.remarkPlugins||[]).use(R8e,{...e.remarkRehypeOptions,allowDangerousHtml:!0}).use(e.rehypePlugins||[]).use(G8e,e),n=new p4e;typeof e.children=="string"?n.value=e.children:e.children!==void 0&&e.children!==null&&console.warn(`[react-markdown] Warning: please pass a string as \`children\` (not: \`${e.children}\`)`);const r=t.runSync(t.parse(n),n);if(r.type!=="root")throw new TypeError("Expected a `root` node");let i=N.createElement(N.Fragment,{},Ore({options:e,schema:J_,listDepth:0},r));return e.className&&(i=N.createElement("div",{className:e.className},i)),i}Rre.propTypes={children:gt.string,className:gt.string,allowElement:gt.func,allowedElements:gt.arrayOf(gt.string),disallowedElements:gt.arrayOf(gt.string),unwrapDisallowed:gt.bool,remarkPlugins:gt.arrayOf(gt.oneOfType([gt.object,gt.func,gt.arrayOf(gt.oneOfType([gt.bool,gt.string,gt.object,gt.func,gt.arrayOf(gt.any)]))])),rehypePlugins:gt.arrayOf(gt.oneOfType([gt.object,gt.func,gt.arrayOf(gt.oneOfType([gt.bool,gt.string,gt.object,gt.func,gt.arrayOf(gt.any)]))])),sourcePos:gt.bool,rawSourcePos:gt.bool,skipHtml:gt.bool,includeElementIndex:gt.bool,transformLinkUri:gt.oneOfType([gt.func,gt.bool]),linkTarget:gt.oneOfType([gt.func,gt.string]),transformImageUri:gt.func,components:gt.object};const Nre=-1,TC=0,MT=1,FT=2,d6=3,h6=4,p6=5,m6=6,kre=7,Dre=8,a7=typeof self=="object"?self:globalThis,w9e=(e,t)=>{const n=(i,s)=>(e.set(s,i),i),r=i=>{if(e.has(i))return e.get(i);const[s,o]=t[i];switch(s){case TC:case Nre:return n(o,i);case MT:{const a=n([],i);for(const u of o)a.push(r(u));return a}case FT:{const a=n({},i);for(const[u,l]of o)a[r(u)]=r(l);return a}case d6:return n(new Date(o),i);case h6:{const{source:a,flags:u}=o;return n(new RegExp(a,u),i)}case p6:{const a=n(new Map,i);for(const[u,l]of o)a.set(r(u),r(l));return a}case m6:{const a=n(new Set,i);for(const u of o)a.add(r(u));return a}case kre:{const{name:a,message:u}=o;return n(new a7[a](u),i)}case Dre:return n(BigInt(o),i);case"BigInt":return n(Object(BigInt(o)),i)}return n(new a7[s](o),i)};return r},u7=e=>w9e(new Map,e)(0),np="",{toString:E9e}={},{keys:S9e}=Object,S0=e=>{const t=typeof e;if(t!=="object"||!e)return[TC,t];const n=E9e.call(e).slice(8,-1);switch(n){case"Array":return[MT,np];case"Object":return[FT,np];case"Date":return[d6,np];case"RegExp":return[h6,np];case"Map":return[p6,np];case"Set":return[m6,np]}return n.includes("Array")?[MT,n]:n.includes("Error")?[kre,n]:[FT,n]},Ob=([e,t])=>e===TC&&(t==="function"||t==="symbol"),T9e=(e,t,n,r)=>{const i=(o,a)=>{const u=r.push(o)-1;return n.set(a,u),u},s=o=>{if(n.has(o))return n.get(o);let[a,u]=S0(o);switch(a){case TC:{let c=o;switch(u){case"bigint":a=Dre,c=o.toString();break;case"function":case"symbol":if(e)throw new TypeError("unable to serialize "+u);c=null;break;case"undefined":return i([Nre],o)}return i([a,c],o)}case MT:{if(u)return i([u,[...o]],o);const c=[],f=i([a,c],o);for(const d of o)c.push(s(d));return f}case FT:{if(u)switch(u){case"BigInt":return i([u,o.toString()],o);case"Boolean":case"Number":case"String":return i([u,o.valueOf()],o)}if(t&&"toJSON"in o)return s(o.toJSON());const c=[],f=i([a,c],o);for(const d of S9e(o))(e||!Ob(S0(o[d])))&&c.push([s(d),s(o[d])]);return f}case d6:return i([a,o.toISOString()],o);case h6:{const{source:c,flags:f}=o;return i([a,{source:c,flags:f}],o)}case p6:{const c=[],f=i([a,c],o);for(const[d,h]of o)(e||!(Ob(S0(d))||Ob(S0(h))))&&c.push([s(d),s(h)]);return f}case m6:{const c=[],f=i([a,c],o);for(const d of o)(e||!Ob(S0(d)))&&c.push(s(d));return f}}const{message:l}=o;return i([a,{name:u,message:l}],o)};return s},l7=(e,{json:t,lossy:n}={})=>{const r=[];return T9e(!(t||n),!!t,new Map,r)(e),r},c7=typeof structuredClone=="function"?(e,t)=>t&&("json"in t||"lossy"in t)?u7(l7(e,t)):structuredClone(e):(e,t)=>u7(l7(e,t));const f7=/[#.]/g;function I9e(e,t){const n=e||"",r={};let i=0,s,o;for(;i-1&&ss)return{line:o+1,column:s-(o>0?n[o-1]:0)+1,offset:s}}}function i(s){const o=s&&s.line,a=s&&s.column;if(typeof o=="number"&&typeof a=="number"&&!Number.isNaN(o)&&!Number.isNaN(a)&&o-1 in n){const u=(n[o-2]||0)+a-1||0;if(u>-1&&u=55296&&e<=57343}function X9e(e){return e>=56320&&e<=57343}function J9e(e,t){return(e-55296)*1024+9216+t}function Ure(e){return e!==32&&e!==10&&e!==13&&e!==9&&e!==12&&e>=1&&e<=31||e>=127&&e<=159}function Vre(e){return e>=64976&&e<=65007||Q9e.has(e)}var _e;(function(e){e.controlCharacterInInputStream="control-character-in-input-stream",e.noncharacterInInputStream="noncharacter-in-input-stream",e.surrogateInInputStream="surrogate-in-input-stream",e.nonVoidHtmlElementStartTagWithTrailingSolidus="non-void-html-element-start-tag-with-trailing-solidus",e.endTagWithAttributes="end-tag-with-attributes",e.endTagWithTrailingSolidus="end-tag-with-trailing-solidus",e.unexpectedSolidusInTag="unexpected-solidus-in-tag",e.unexpectedNullCharacter="unexpected-null-character",e.unexpectedQuestionMarkInsteadOfTagName="unexpected-question-mark-instead-of-tag-name",e.invalidFirstCharacterOfTagName="invalid-first-character-of-tag-name",e.unexpectedEqualsSignBeforeAttributeName="unexpected-equals-sign-before-attribute-name",e.missingEndTagName="missing-end-tag-name",e.unexpectedCharacterInAttributeName="unexpected-character-in-attribute-name",e.unknownNamedCharacterReference="unknown-named-character-reference",e.missingSemicolonAfterCharacterReference="missing-semicolon-after-character-reference",e.unexpectedCharacterAfterDoctypeSystemIdentifier="unexpected-character-after-doctype-system-identifier",e.unexpectedCharacterInUnquotedAttributeValue="unexpected-character-in-unquoted-attribute-value",e.eofBeforeTagName="eof-before-tag-name",e.eofInTag="eof-in-tag",e.missingAttributeValue="missing-attribute-value",e.missingWhitespaceBetweenAttributes="missing-whitespace-between-attributes",e.missingWhitespaceAfterDoctypePublicKeyword="missing-whitespace-after-doctype-public-keyword",e.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers="missing-whitespace-between-doctype-public-and-system-identifiers",e.missingWhitespaceAfterDoctypeSystemKeyword="missing-whitespace-after-doctype-system-keyword",e.missingQuoteBeforeDoctypePublicIdentifier="missing-quote-before-doctype-public-identifier",e.missingQuoteBeforeDoctypeSystemIdentifier="missing-quote-before-doctype-system-identifier",e.missingDoctypePublicIdentifier="missing-doctype-public-identifier",e.missingDoctypeSystemIdentifier="missing-doctype-system-identifier",e.abruptDoctypePublicIdentifier="abrupt-doctype-public-identifier",e.abruptDoctypeSystemIdentifier="abrupt-doctype-system-identifier",e.cdataInHtmlContent="cdata-in-html-content",e.incorrectlyOpenedComment="incorrectly-opened-comment",e.eofInScriptHtmlCommentLikeText="eof-in-script-html-comment-like-text",e.eofInDoctype="eof-in-doctype",e.nestedComment="nested-comment",e.abruptClosingOfEmptyComment="abrupt-closing-of-empty-comment",e.eofInComment="eof-in-comment",e.incorrectlyClosedComment="incorrectly-closed-comment",e.eofInCdata="eof-in-cdata",e.absenceOfDigitsInNumericCharacterReference="absence-of-digits-in-numeric-character-reference",e.nullCharacterReference="null-character-reference",e.surrogateCharacterReference="surrogate-character-reference",e.characterReferenceOutsideUnicodeRange="character-reference-outside-unicode-range",e.controlCharacterReference="control-character-reference",e.noncharacterCharacterReference="noncharacter-character-reference",e.missingWhitespaceBeforeDoctypeName="missing-whitespace-before-doctype-name",e.missingDoctypeName="missing-doctype-name",e.invalidCharacterSequenceAfterDoctypeName="invalid-character-sequence-after-doctype-name",e.duplicateAttribute="duplicate-attribute",e.nonConformingDoctype="non-conforming-doctype",e.missingDoctype="missing-doctype",e.misplacedDoctype="misplaced-doctype",e.endTagWithoutMatchingOpenElement="end-tag-without-matching-open-element",e.closingOfElementWithOpenChildElements="closing-of-element-with-open-child-elements",e.disallowedContentInNoscriptInHead="disallowed-content-in-noscript-in-head",e.openElementsLeftAfterEof="open-elements-left-after-eof",e.abandonedHeadElementChild="abandoned-head-element-child",e.misplacedStartTagForHeadElement="misplaced-start-tag-for-head-element",e.nestedNoscriptInHead="nested-noscript-in-head",e.eofInElementThatCanContainOnlyText="eof-in-element-that-can-contain-only-text"})(_e=_e||(_e={}));const Z9e=65536;class eBe{constructor(t){this.handler=t,this.html="",this.pos=-1,this.lastGapPos=-2,this.gapStack=[],this.skipNextNewLine=!1,this.lastChunkWritten=!1,this.endOfChunkHit=!1,this.bufferWaterline=Z9e,this.isEol=!1,this.lineStartPos=0,this.droppedBufferSize=0,this.line=1,this.lastErrOffset=-1}get col(){return this.pos-this.lineStartPos+ +(this.lastGapPos!==this.pos)}get offset(){return this.droppedBufferSize+this.pos}getError(t){const{line:n,col:r,offset:i}=this;return{code:t,startLine:n,endLine:n,startCol:r,endCol:r,startOffset:i,endOffset:i}}_err(t){this.handler.onParseError&&this.lastErrOffset!==this.offset&&(this.lastErrOffset=this.offset,this.handler.onParseError(this.getError(t)))}_addGap(){this.gapStack.push(this.lastGapPos),this.lastGapPos=this.pos}_processSurrogate(t){if(this.pos!==this.html.length-1){const n=this.html.charCodeAt(this.pos+1);if(X9e(n))return this.pos++,this._addGap(),J9e(t,n)}else if(!this.lastChunkWritten)return this.endOfChunkHit=!0,M.EOF;return this._err(_e.surrogateInInputStream),t}willDropParsedChunk(){return this.pos>this.bufferWaterline}dropParsedChunk(){this.willDropParsedChunk()&&(this.html=this.html.substring(this.pos),this.lineStartPos-=this.pos,this.droppedBufferSize+=this.pos,this.pos=0,this.lastGapPos=-2,this.gapStack.length=0)}write(t,n){this.html.length>0?this.html+=t:this.html=t,this.endOfChunkHit=!1,this.lastChunkWritten=n}insertHtmlAtCurrentPos(t){this.html=this.html.substring(0,this.pos+1)+t+this.html.substring(this.pos+1),this.endOfChunkHit=!1}startsWith(t,n){if(this.pos+t.length>this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,!1;if(n)return this.html.startsWith(t,this.pos);for(let r=0;r=this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,M.EOF;const r=this.html.charCodeAt(n);return r===M.CARRIAGE_RETURN?M.LINE_FEED:r}advance(){if(this.pos++,this.isEol&&(this.isEol=!1,this.line++,this.lineStartPos=this.pos),this.pos>=this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,M.EOF;let t=this.html.charCodeAt(this.pos);return t===M.CARRIAGE_RETURN?(this.isEol=!0,this.skipNextNewLine=!0,M.LINE_FEED):t===M.LINE_FEED&&(this.isEol=!0,this.skipNextNewLine)?(this.line--,this.skipNextNewLine=!1,this._addGap(),this.advance()):(this.skipNextNewLine=!1,jre(t)&&(t=this._processSurrogate(t)),this.handler.onParseError===null||t>31&&t<127||t===M.LINE_FEED||t===M.CARRIAGE_RETURN||t>159&&t<64976||this._checkForProblematicCharacters(t),t)}_checkForProblematicCharacters(t){Ure(t)?this._err(_e.controlCharacterInInputStream):Vre(t)&&this._err(_e.noncharacterInInputStream)}retreat(t){for(this.pos-=t;this.pos=0;n--)if(e.attrs[n].name===t)return e.attrs[n].value;return null}const Oc=new Uint16Array('ᵁ<Õıʊҝջאٵ۞ޢߖࠏ੊ઑඡ๭༉༦჊ረዡᐕᒝᓃᓟᔥ\0\0\0\0\0\0ᕫᛍᦍᰒᷝ὾⁠↰⊍⏀⏻⑂⠤⤒ⴈ⹈⿎〖㊺㘹㞬㣾㨨㩱㫠㬮ࠀEMabcfglmnoprstu\\bfms„‹•˜¦³¹ÈÏlig耻Æ䃆P耻&䀦cute耻Á䃁reve;䄂Āiyx}rc耻Â䃂;䐐r;쀀𝔄rave耻À䃀pha;䎑acr;䄀d;橓Āgp¡on;䄄f;쀀𝔸plyFunction;恡ing耻Å䃅Ācs¾Ãr;쀀𝒜ign;扔ilde耻Ã䃃ml耻Ä䃄ЀaceforsuåûþėĜĢħĪĀcrêòkslash;或Ŷöø;櫧ed;挆y;䐑ƀcrtąċĔause;戵noullis;愬a;䎒r;쀀𝔅pf;쀀𝔹eve;䋘còēmpeq;扎܀HOacdefhilorsuōőŖƀƞƢƵƷƺǜȕɳɸɾcy;䐧PY耻©䂩ƀcpyŝŢźute;䄆Ā;iŧŨ拒talDifferentialD;慅leys;愭ȀaeioƉƎƔƘron;䄌dil耻Ç䃇rc;䄈nint;戰ot;䄊ĀdnƧƭilla;䂸terDot;䂷òſi;䎧rcleȀDMPTLJNjǑǖot;抙inus;抖lus;投imes;抗oĀcsǢǸkwiseContourIntegral;戲eCurlyĀDQȃȏoubleQuote;思uote;怙ȀlnpuȞȨɇɕonĀ;eȥȦ户;橴ƀgitȯȶȺruent;扡nt;戯ourIntegral;戮ĀfrɌɎ;愂oduct;成nterClockwiseContourIntegral;戳oss;樯cr;쀀𝒞pĀ;Cʄʅ拓ap;才րDJSZacefiosʠʬʰʴʸˋ˗ˡ˦̳ҍĀ;oŹʥtrahd;椑cy;䐂cy;䐅cy;䐏ƀgrsʿ˄ˇger;怡r;憡hv;櫤Āayː˕ron;䄎;䐔lĀ;t˝˞戇a;䎔r;쀀𝔇Āaf˫̧Ācm˰̢riticalȀADGT̖̜̀̆cute;䂴oŴ̋̍;䋙bleAcute;䋝rave;䁠ilde;䋜ond;拄ferentialD;慆Ѱ̽\0\0\0͔͂\0Ѕf;쀀𝔻ƀ;DE͈͉͍䂨ot;惜qual;扐blèCDLRUVͣͲ΂ϏϢϸontourIntegraìȹoɴ͹\0\0ͻ»͉nArrow;懓Āeo·ΤftƀARTΐΖΡrrow;懐ightArrow;懔eåˊngĀLRΫτeftĀARγιrrow;柸ightArrow;柺ightArrow;柹ightĀATϘϞrrow;懒ee;抨pɁϩ\0\0ϯrrow;懑ownArrow;懕erticalBar;戥ǹABLRTaВЪаўѿͼrrowƀ;BUНОТ憓ar;椓pArrow;懵reve;䌑eft˒к\0ц\0ѐightVector;楐eeVector;楞ectorĀ;Bљњ憽ar;楖ightǔѧ\0ѱeeVector;楟ectorĀ;BѺѻ懁ar;楗eeĀ;A҆҇护rrow;憧ĀctҒҗr;쀀𝒟rok;䄐ࠀNTacdfglmopqstuxҽӀӄӋӞӢӧӮӵԡԯԶՒ՝ՠեG;䅊H耻Ð䃐cute耻É䃉ƀaiyӒӗӜron;䄚rc耻Ê䃊;䐭ot;䄖r;쀀𝔈rave耻È䃈ement;戈ĀapӺӾcr;䄒tyɓԆ\0\0ԒmallSquare;旻erySmallSquare;斫ĀgpԦԪon;䄘f;쀀𝔼silon;䎕uĀaiԼՉlĀ;TՂՃ橵ilde;扂librium;懌Āci՗՚r;愰m;橳a;䎗ml耻Ë䃋Āipժկsts;戃onentialE;慇ʀcfiosօֈ֍ֲ׌y;䐤r;쀀𝔉lledɓ֗\0\0֣mallSquare;旼erySmallSquare;斪Ͱֺ\0ֿ\0\0ׄf;쀀𝔽All;戀riertrf;愱cò׋؀JTabcdfgorstר׬ׯ׺؀ؒؖ؛؝أ٬ٲcy;䐃耻>䀾mmaĀ;d׷׸䎓;䏜reve;䄞ƀeiy؇،ؐdil;䄢rc;䄜;䐓ot;䄠r;쀀𝔊;拙pf;쀀𝔾eater̀EFGLSTصلَٖٛ٦qualĀ;Lؾؿ扥ess;招ullEqual;执reater;檢ess;扷lantEqual;橾ilde;扳cr;쀀𝒢;扫ЀAacfiosuڅڋږڛڞڪھۊRDcy;䐪Āctڐڔek;䋇;䁞irc;䄤r;愌lbertSpace;愋ǰگ\0ڲf;愍izontalLine;攀Āctۃۅòکrok;䄦mpńېۘownHumðįqual;扏܀EJOacdfgmnostuۺ۾܃܇܎ܚܞܡܨ݄ݸދޏޕcy;䐕lig;䄲cy;䐁cute耻Í䃍Āiyܓܘrc耻Î䃎;䐘ot;䄰r;愑rave耻Ì䃌ƀ;apܠܯܿĀcgܴܷr;䄪inaryI;慈lieóϝǴ݉\0ݢĀ;eݍݎ戬Āgrݓݘral;戫section;拂isibleĀCTݬݲomma;恣imes;恢ƀgptݿރވon;䄮f;쀀𝕀a;䎙cr;愐ilde;䄨ǫޚ\0ޞcy;䐆l耻Ï䃏ʀcfosuެ޷޼߂ߐĀiyޱ޵rc;䄴;䐙r;쀀𝔍pf;쀀𝕁ǣ߇\0ߌr;쀀𝒥rcy;䐈kcy;䐄΀HJacfosߤߨ߽߬߱ࠂࠈcy;䐥cy;䐌ppa;䎚Āey߶߻dil;䄶;䐚r;쀀𝔎pf;쀀𝕂cr;쀀𝒦րJTaceflmostࠥࠩࠬࡐࡣ঳সে্਷ੇcy;䐉耻<䀼ʀcmnpr࠷࠼ࡁࡄࡍute;䄹bda;䎛g;柪lacetrf;愒r;憞ƀaeyࡗ࡜ࡡron;䄽dil;䄻;䐛Āfsࡨ॰tԀACDFRTUVarࡾࢩࢱࣦ࣠ࣼयज़ΐ४Ānrࢃ࢏gleBracket;柨rowƀ;BR࢙࢚࢞憐ar;懤ightArrow;懆eiling;挈oǵࢷ\0ࣃbleBracket;柦nǔࣈ\0࣒eeVector;楡ectorĀ;Bࣛࣜ懃ar;楙loor;挊ightĀAV࣯ࣵrrow;憔ector;楎Āerँगeƀ;AVउऊऐ抣rrow;憤ector;楚iangleƀ;BEतथऩ抲ar;槏qual;抴pƀDTVषूौownVector;楑eeVector;楠ectorĀ;Bॖॗ憿ar;楘ectorĀ;B॥०憼ar;楒ightáΜs̀EFGLSTॾঋকঝঢভqualGreater;拚ullEqual;扦reater;扶ess;檡lantEqual;橽ilde;扲r;쀀𝔏Ā;eঽা拘ftarrow;懚idot;䄿ƀnpw৔ਖਛgȀLRlr৞৷ਂਐeftĀAR০৬rrow;柵ightArrow;柷ightArrow;柶eftĀarγਊightáοightáϊf;쀀𝕃erĀLRਢਬeftArrow;憙ightArrow;憘ƀchtਾੀੂòࡌ;憰rok;䅁;扪Ѐacefiosuਗ਼੝੠੷੼અઋ઎p;椅y;䐜Ādl੥੯iumSpace;恟lintrf;愳r;쀀𝔐nusPlus;戓pf;쀀𝕄cò੶;䎜ҀJacefostuણધભીଔଙඑ඗ඞcy;䐊cute;䅃ƀaey઴હાron;䅇dil;䅅;䐝ƀgswે૰଎ativeƀMTV૓૟૨ediumSpace;怋hiĀcn૦૘ë૙eryThiî૙tedĀGL૸ଆreaterGreateòٳessLesóੈLine;䀊r;쀀𝔑ȀBnptଢନଷ଺reak;恠BreakingSpace;䂠f;愕ڀ;CDEGHLNPRSTV୕ୖ୪୼஡௫ఄ౞಄ದ೘ൡඅ櫬Āou୛୤ngruent;扢pCap;扭oubleVerticalBar;戦ƀlqxஃஊ஛ement;戉ualĀ;Tஒஓ扠ilde;쀀≂̸ists;戄reater΀;EFGLSTஶஷ஽௉௓௘௥扯qual;扱ullEqual;쀀≧̸reater;쀀≫̸ess;批lantEqual;쀀⩾̸ilde;扵umpń௲௽ownHump;쀀≎̸qual;쀀≏̸eĀfsఊధtTriangleƀ;BEచఛడ拪ar;쀀⧏̸qual;括s̀;EGLSTవశ఼ౄోౘ扮qual;扰reater;扸ess;쀀≪̸lantEqual;쀀⩽̸ilde;扴estedĀGL౨౹reaterGreater;쀀⪢̸essLess;쀀⪡̸recedesƀ;ESಒಓಛ技qual;쀀⪯̸lantEqual;拠ĀeiಫಹverseElement;戌ghtTriangleƀ;BEೋೌ೒拫ar;쀀⧐̸qual;拭ĀquೝഌuareSuĀbp೨೹setĀ;E೰ೳ쀀⊏̸qual;拢ersetĀ;Eഃആ쀀⊐̸qual;拣ƀbcpഓതൎsetĀ;Eഛഞ쀀⊂⃒qual;抈ceedsȀ;ESTലള഻െ抁qual;쀀⪰̸lantEqual;拡ilde;쀀≿̸ersetĀ;E൘൛쀀⊃⃒qual;抉ildeȀ;EFT൮൯൵ൿ扁qual;扄ullEqual;扇ilde;扉erticalBar;戤cr;쀀𝒩ilde耻Ñ䃑;䎝܀Eacdfgmoprstuvලෂ෉෕ෛ෠෧෼ขภยา฿ไlig;䅒cute耻Ó䃓Āiy෎ීrc耻Ô䃔;䐞blac;䅐r;쀀𝔒rave耻Ò䃒ƀaei෮ෲ෶cr;䅌ga;䎩cron;䎟pf;쀀𝕆enCurlyĀDQฎบoubleQuote;怜uote;怘;橔Āclวฬr;쀀𝒪ash耻Ø䃘iŬื฼de耻Õ䃕es;樷ml耻Ö䃖erĀBP๋๠Āar๐๓r;怾acĀek๚๜;揞et;掴arenthesis;揜Ҁacfhilors๿ງຊຏຒດຝະ໼rtialD;戂y;䐟r;쀀𝔓i;䎦;䎠usMinus;䂱Āipຢອncareplanåڝf;愙Ȁ;eio຺ູ໠໤檻cedesȀ;EST່້໏໚扺qual;檯lantEqual;扼ilde;找me;怳Ādp໩໮uct;戏ortionĀ;aȥ໹l;戝Āci༁༆r;쀀𝒫;䎨ȀUfos༑༖༛༟OT耻"䀢r;쀀𝔔pf;愚cr;쀀𝒬؀BEacefhiorsu༾གྷཇའཱིྦྷྪྭ႖ႩႴႾarr;椐G耻®䂮ƀcnrཎནབute;䅔g;柫rĀ;tཛྷཝ憠l;椖ƀaeyཧཬཱron;䅘dil;䅖;䐠Ā;vླྀཹ愜erseĀEUྂྙĀlq྇ྎement;戋uilibrium;懋pEquilibrium;楯r»ཹo;䎡ghtЀACDFTUVa࿁࿫࿳ဢဨၛႇϘĀnr࿆࿒gleBracket;柩rowƀ;BL࿜࿝࿡憒ar;懥eftArrow;懄eiling;按oǵ࿹\0စbleBracket;柧nǔည\0နeeVector;楝ectorĀ;Bဝသ懂ar;楕loor;挋Āerိ၃eƀ;AVဵံြ抢rrow;憦ector;楛iangleƀ;BEၐၑၕ抳ar;槐qual;抵pƀDTVၣၮၸownVector;楏eeVector;楜ectorĀ;Bႂႃ憾ar;楔ectorĀ;B႑႒懀ar;楓Āpuႛ႞f;愝ndImplies;楰ightarrow;懛ĀchႹႼr;愛;憱leDelayed;槴ڀHOacfhimoqstuფჱჷჽᄙᄞᅑᅖᅡᅧᆵᆻᆿĀCcჩხHcy;䐩y;䐨FTcy;䐬cute;䅚ʀ;aeiyᄈᄉᄎᄓᄗ檼ron;䅠dil;䅞rc;䅜;䐡r;쀀𝔖ortȀDLRUᄪᄴᄾᅉownArrow»ОeftArrow»࢚ightArrow»࿝pArrow;憑gma;䎣allCircle;战pf;쀀𝕊ɲᅭ\0\0ᅰt;戚areȀ;ISUᅻᅼᆉᆯ斡ntersection;抓uĀbpᆏᆞsetĀ;Eᆗᆘ抏qual;抑ersetĀ;Eᆨᆩ抐qual;抒nion;抔cr;쀀𝒮ar;拆ȀbcmpᇈᇛሉላĀ;sᇍᇎ拐etĀ;Eᇍᇕqual;抆ĀchᇠህeedsȀ;ESTᇭᇮᇴᇿ扻qual;檰lantEqual;扽ilde;承Tháྌ;我ƀ;esሒሓሣ拑rsetĀ;Eሜም抃qual;抇et»ሓրHRSacfhiorsሾቄ቉ቕ቞ቱቶኟዂወዑORN耻Þ䃞ADE;愢ĀHc቎ቒcy;䐋y;䐦Ābuቚቜ;䀉;䎤ƀaeyብቪቯron;䅤dil;䅢;䐢r;쀀𝔗Āeiቻ኉Dzኀ\0ኇefore;戴a;䎘Ācn኎ኘkSpace;쀀  Space;怉ldeȀ;EFTካኬኲኼ戼qual;扃ullEqual;扅ilde;扈pf;쀀𝕋ipleDot;惛Āctዖዛr;쀀𝒯rok;䅦ૡዷጎጚጦ\0ጬጱ\0\0\0\0\0ጸጽ፷ᎅ\0᏿ᐄᐊᐐĀcrዻጁute耻Ú䃚rĀ;oጇገ憟cir;楉rǣጓ\0጖y;䐎ve;䅬Āiyጞጣrc耻Û䃛;䐣blac;䅰r;쀀𝔘rave耻Ù䃙acr;䅪Ādiፁ፩erĀBPፈ፝Āarፍፐr;䁟acĀekፗፙ;揟et;掵arenthesis;揝onĀ;P፰፱拃lus;抎Āgp፻፿on;䅲f;쀀𝕌ЀADETadps᎕ᎮᎸᏄϨᏒᏗᏳrrowƀ;BDᅐᎠᎤar;椒ownArrow;懅ownArrow;憕quilibrium;楮eeĀ;AᏋᏌ报rrow;憥ownáϳerĀLRᏞᏨeftArrow;憖ightArrow;憗iĀ;lᏹᏺ䏒on;䎥ing;䅮cr;쀀𝒰ilde;䅨ml耻Ü䃜ҀDbcdefosvᐧᐬᐰᐳᐾᒅᒊᒐᒖash;披ar;櫫y;䐒ashĀ;lᐻᐼ抩;櫦Āerᑃᑅ;拁ƀbtyᑌᑐᑺar;怖Ā;iᑏᑕcalȀBLSTᑡᑥᑪᑴar;戣ine;䁼eparator;杘ilde;所ThinSpace;怊r;쀀𝔙pf;쀀𝕍cr;쀀𝒱dash;抪ʀcefosᒧᒬᒱᒶᒼirc;䅴dge;拀r;쀀𝔚pf;쀀𝕎cr;쀀𝒲Ȁfiosᓋᓐᓒᓘr;쀀𝔛;䎞pf;쀀𝕏cr;쀀𝒳ҀAIUacfosuᓱᓵᓹᓽᔄᔏᔔᔚᔠcy;䐯cy;䐇cy;䐮cute耻Ý䃝Āiyᔉᔍrc;䅶;䐫r;쀀𝔜pf;쀀𝕐cr;쀀𝒴ml;䅸ЀHacdefosᔵᔹᔿᕋᕏᕝᕠᕤcy;䐖cute;䅹Āayᕄᕉron;䅽;䐗ot;䅻Dzᕔ\0ᕛoWidtè૙a;䎖r;愨pf;愤cr;쀀𝒵௡ᖃᖊᖐ\0ᖰᖶᖿ\0\0\0\0ᗆᗛᗫᙟ᙭\0ᚕ᚛ᚲᚹ\0ᚾcute耻á䃡reve;䄃̀;Ediuyᖜᖝᖡᖣᖨᖭ戾;쀀∾̳;房rc耻â䃢te肻´̆;䐰lig耻æ䃦Ā;r²ᖺ;쀀𝔞rave耻à䃠ĀepᗊᗖĀfpᗏᗔsym;愵èᗓha;䎱ĀapᗟcĀclᗤᗧr;䄁g;樿ɤᗰ\0\0ᘊʀ;adsvᗺᗻᗿᘁᘇ戧nd;橕;橜lope;橘;橚΀;elmrszᘘᘙᘛᘞᘿᙏᙙ戠;榤e»ᘙsdĀ;aᘥᘦ戡ѡᘰᘲᘴᘶᘸᘺᘼᘾ;榨;榩;榪;榫;榬;榭;榮;榯tĀ;vᙅᙆ戟bĀ;dᙌᙍ抾;榝Āptᙔᙗh;戢»¹arr;捼Āgpᙣᙧon;䄅f;쀀𝕒΀;Eaeiop዁ᙻᙽᚂᚄᚇᚊ;橰cir;橯;扊d;手s;䀧roxĀ;e዁ᚒñᚃing耻å䃥ƀctyᚡᚦᚨr;쀀𝒶;䀪mpĀ;e዁ᚯñʈilde耻ã䃣ml耻ä䃤Āciᛂᛈoninôɲnt;樑ࠀNabcdefiklnoprsu᛭ᛱᜰ᜼ᝃᝈ᝸᝽០៦ᠹᡐᜍ᤽᥈ᥰot;櫭Ācrᛶ᜞kȀcepsᜀᜅᜍᜓong;扌psilon;䏶rime;怵imĀ;e᜚᜛戽q;拍Ŷᜢᜦee;抽edĀ;gᜬᜭ挅e»ᜭrkĀ;t፜᜷brk;掶Āoyᜁᝁ;䐱quo;怞ʀcmprtᝓ᝛ᝡᝤᝨausĀ;eĊĉptyv;榰séᜌnoõēƀahwᝯ᝱ᝳ;䎲;愶een;扬r;쀀𝔟g΀costuvwឍឝឳេ៕៛៞ƀaiuបពរðݠrc;旯p»፱ƀdptឤឨឭot;樀lus;樁imes;樂ɱឹ\0\0ើcup;樆ar;昅riangleĀdu៍្own;施p;斳plus;樄eåᑄåᒭarow;植ƀako៭ᠦᠵĀcn៲ᠣkƀlst៺֫᠂ozenge;槫riangleȀ;dlr᠒᠓᠘᠝斴own;斾eft;旂ight;斸k;搣Ʊᠫ\0ᠳƲᠯ\0ᠱ;斒;斑4;斓ck;斈ĀeoᠾᡍĀ;qᡃᡆ쀀=⃥uiv;쀀≡⃥t;挐Ȁptwxᡙᡞᡧᡬf;쀀𝕓Ā;tᏋᡣom»Ꮜtie;拈؀DHUVbdhmptuvᢅᢖᢪᢻᣗᣛᣬ᣿ᤅᤊᤐᤡȀLRlrᢎᢐᢒᢔ;敗;敔;敖;敓ʀ;DUduᢡᢢᢤᢦᢨ敐;敦;敩;敤;敧ȀLRlrᢳᢵᢷᢹ;敝;敚;敜;教΀;HLRhlrᣊᣋᣍᣏᣑᣓᣕ救;敬;散;敠;敫;敢;敟ox;槉ȀLRlrᣤᣦᣨᣪ;敕;敒;攐;攌ʀ;DUduڽ᣷᣹᣻᣽;敥;敨;攬;攴inus;抟lus;択imes;抠ȀLRlrᤙᤛᤝ᤟;敛;敘;攘;攔΀;HLRhlrᤰᤱᤳᤵᤷ᤻᤹攂;敪;敡;敞;攼;攤;攜Āevģ᥂bar耻¦䂦Ȁceioᥑᥖᥚᥠr;쀀𝒷mi;恏mĀ;e᜚᜜lƀ;bhᥨᥩᥫ䁜;槅sub;柈Ŭᥴ᥾lĀ;e᥹᥺怢t»᥺pƀ;Eeįᦅᦇ;檮Ā;qۜۛೡᦧ\0᧨ᨑᨕᨲ\0ᨷᩐ\0\0᪴\0\0᫁\0\0ᬡᬮ᭍᭒\0᯽\0ᰌƀcpr᦭ᦲ᧝ute;䄇̀;abcdsᦿᧀᧄ᧊᧕᧙戩nd;橄rcup;橉Āau᧏᧒p;橋p;橇ot;橀;쀀∩︀Āeo᧢᧥t;恁îړȀaeiu᧰᧻ᨁᨅǰ᧵\0᧸s;橍on;䄍dil耻ç䃧rc;䄉psĀ;sᨌᨍ橌m;橐ot;䄋ƀdmnᨛᨠᨦil肻¸ƭptyv;榲t脀¢;eᨭᨮ䂢räƲr;쀀𝔠ƀceiᨽᩀᩍy;䑇ckĀ;mᩇᩈ朓ark»ᩈ;䏇r΀;Ecefms᩟᩠ᩢᩫ᪤᪪᪮旋;槃ƀ;elᩩᩪᩭ䋆q;扗eɡᩴ\0\0᪈rrowĀlr᩼᪁eft;憺ight;憻ʀRSacd᪒᪔᪖᪚᪟»ཇ;擈st;抛irc;抚ash;抝nint;樐id;櫯cir;槂ubsĀ;u᪻᪼晣it»᪼ˬ᫇᫔᫺\0ᬊonĀ;eᫍᫎ䀺Ā;qÇÆɭ᫙\0\0᫢aĀ;t᫞᫟䀬;䁀ƀ;fl᫨᫩᫫戁îᅠeĀmx᫱᫶ent»᫩eóɍǧ᫾\0ᬇĀ;dኻᬂot;橭nôɆƀfryᬐᬔᬗ;쀀𝕔oäɔ脀©;sŕᬝr;愗Āaoᬥᬩrr;憵ss;朗Ācuᬲᬷr;쀀𝒸Ābpᬼ᭄Ā;eᭁᭂ櫏;櫑Ā;eᭉᭊ櫐;櫒dot;拯΀delprvw᭠᭬᭷ᮂᮬᯔ᯹arrĀlr᭨᭪;椸;椵ɰ᭲\0\0᭵r;拞c;拟arrĀ;p᭿ᮀ憶;椽̀;bcdosᮏᮐᮖᮡᮥᮨ截rcap;橈Āauᮛᮞp;橆p;橊ot;抍r;橅;쀀∪︀Ȁalrv᮵ᮿᯞᯣrrĀ;mᮼᮽ憷;椼yƀevwᯇᯔᯘqɰᯎ\0\0ᯒreã᭳uã᭵ee;拎edge;拏en耻¤䂤earrowĀlrᯮ᯳eft»ᮀight»ᮽeäᯝĀciᰁᰇoninôǷnt;戱lcty;挭ঀAHabcdefhijlorstuwz᰸᰻᰿ᱝᱩᱵᲊᲞᲬᲷ᳻᳿ᴍᵻᶑᶫᶻ᷆᷍rò΁ar;楥Ȁglrs᱈ᱍ᱒᱔ger;怠eth;愸òᄳhĀ;vᱚᱛ怐»ऊūᱡᱧarow;椏aã̕Āayᱮᱳron;䄏;䐴ƀ;ao̲ᱼᲄĀgrʿᲁr;懊tseq;橷ƀglmᲑᲔᲘ耻°䂰ta;䎴ptyv;榱ĀirᲣᲨsht;楿;쀀𝔡arĀlrᲳᲵ»ࣜ»သʀaegsv᳂͸᳖᳜᳠mƀ;oș᳊᳔ndĀ;ș᳑uit;晦amma;䏝in;拲ƀ;io᳧᳨᳸䃷de脀÷;o᳧ᳰntimes;拇nø᳷cy;䑒cɯᴆ\0\0ᴊrn;挞op;挍ʀlptuwᴘᴝᴢᵉᵕlar;䀤f;쀀𝕕ʀ;emps̋ᴭᴷᴽᵂqĀ;d͒ᴳot;扑inus;戸lus;戔quare;抡blebarwedgåúnƀadhᄮᵝᵧownarrowóᲃarpoonĀlrᵲᵶefôᲴighôᲶŢᵿᶅkaro÷གɯᶊ\0\0ᶎrn;挟op;挌ƀcotᶘᶣᶦĀryᶝᶡ;쀀𝒹;䑕l;槶rok;䄑Ādrᶰᶴot;拱iĀ;fᶺ᠖斿Āah᷀᷃ròЩaòྦangle;榦Āci᷒ᷕy;䑟grarr;柿ऀDacdefglmnopqrstuxḁḉḙḸոḼṉṡṾấắẽỡἪἷὄ὎὚ĀDoḆᴴoôᲉĀcsḎḔute耻é䃩ter;橮ȀaioyḢḧḱḶron;䄛rĀ;cḭḮ扖耻ê䃪lon;払;䑍ot;䄗ĀDrṁṅot;扒;쀀𝔢ƀ;rsṐṑṗ檚ave耻è䃨Ā;dṜṝ檖ot;檘Ȁ;ilsṪṫṲṴ檙nters;揧;愓Ā;dṹṺ檕ot;檗ƀapsẅẉẗcr;䄓tyƀ;svẒẓẕ戅et»ẓpĀ1;ẝẤijạả;怄;怅怃ĀgsẪẬ;䅋p;怂ĀgpẴẸon;䄙f;쀀𝕖ƀalsỄỎỒrĀ;sỊị拕l;槣us;橱iƀ;lvỚớở䎵on»ớ;䏵ȀcsuvỪỳἋἣĀioữḱrc»Ḯɩỹ\0\0ỻíՈantĀglἂἆtr»ṝess»Ṻƀaeiἒ἖Ἒls;䀽st;扟vĀ;DȵἠD;橸parsl;槥ĀDaἯἳot;打rr;楱ƀcdiἾὁỸr;愯oô͒ĀahὉὋ;䎷耻ð䃰Āmrὓὗl耻ë䃫o;悬ƀcipὡὤὧl;䀡sôծĀeoὬὴctatioîՙnentialåչৡᾒ\0ᾞ\0ᾡᾧ\0\0ῆῌ\0ΐ\0ῦῪ \0 ⁚llingdotseñṄy;䑄male;晀ƀilrᾭᾳ῁lig;耀ffiɩᾹ\0\0᾽g;耀ffig;耀ffl;쀀𝔣lig;耀filig;쀀fjƀaltῙ῜ῡt;晭ig;耀flns;斱of;䆒ǰ΅\0ῳf;쀀𝕗ĀakֿῷĀ;vῼ´拔;櫙artint;樍Āao‌⁕Ācs‑⁒ႉ‸⁅⁈\0⁐β•‥‧‪‬\0‮耻½䂽;慓耻¼䂼;慕;慙;慛Ƴ‴\0‶;慔;慖ʴ‾⁁\0\0⁃耻¾䂾;慗;慜5;慘ƶ⁌\0⁎;慚;慝8;慞l;恄wn;挢cr;쀀𝒻ࢀEabcdefgijlnorstv₂₉₟₥₰₴⃰⃵⃺⃿℃ℒℸ̗ℾ⅒↞Ā;lٍ₇;檌ƀcmpₐₕ₝ute;䇵maĀ;dₜ᳚䎳;檆reve;䄟Āiy₪₮rc;䄝;䐳ot;䄡Ȁ;lqsؾق₽⃉ƀ;qsؾٌ⃄lanô٥Ȁ;cdl٥⃒⃥⃕c;檩otĀ;o⃜⃝檀Ā;l⃢⃣檂;檄Ā;e⃪⃭쀀⋛︀s;檔r;쀀𝔤Ā;gٳ؛mel;愷cy;䑓Ȁ;Eajٚℌℎℐ;檒;檥;檤ȀEaesℛℝ℩ℴ;扩pĀ;p℣ℤ檊rox»ℤĀ;q℮ℯ檈Ā;q℮ℛim;拧pf;쀀𝕘Āci⅃ⅆr;愊mƀ;el٫ⅎ⅐;檎;檐茀>;cdlqr׮ⅠⅪⅮⅳⅹĀciⅥⅧ;檧r;橺ot;拗Par;榕uest;橼ʀadelsↄⅪ←ٖ↛ǰ↉\0↎proø₞r;楸qĀlqؿ↖lesó₈ií٫Āen↣↭rtneqq;쀀≩︀Å↪ԀAabcefkosy⇄⇇⇱⇵⇺∘∝∯≨≽ròΠȀilmr⇐⇔⇗⇛rsðᒄf»․ilôکĀdr⇠⇤cy;䑊ƀ;cwࣴ⇫⇯ir;楈;憭ar;意irc;䄥ƀalr∁∎∓rtsĀ;u∉∊晥it»∊lip;怦con;抹r;쀀𝔥sĀew∣∩arow;椥arow;椦ʀamopr∺∾≃≞≣rr;懿tht;戻kĀlr≉≓eftarrow;憩ightarrow;憪f;쀀𝕙bar;怕ƀclt≯≴≸r;쀀𝒽asè⇴rok;䄧Ābp⊂⊇ull;恃hen»ᱛૡ⊣\0⊪\0⊸⋅⋎\0⋕⋳\0\0⋸⌢⍧⍢⍿\0⎆⎪⎴cute耻í䃭ƀ;iyݱ⊰⊵rc耻î䃮;䐸Ācx⊼⊿y;䐵cl耻¡䂡ĀfrΟ⋉;쀀𝔦rave耻ì䃬Ȁ;inoܾ⋝⋩⋮Āin⋢⋦nt;樌t;戭fin;槜ta;愩lig;䄳ƀaop⋾⌚⌝ƀcgt⌅⌈⌗r;䄫ƀelpܟ⌏⌓inåގarôܠh;䄱f;抷ed;䆵ʀ;cfotӴ⌬⌱⌽⍁are;愅inĀ;t⌸⌹戞ie;槝doô⌙ʀ;celpݗ⍌⍐⍛⍡al;抺Āgr⍕⍙eróᕣã⍍arhk;樗rod;樼Ȁcgpt⍯⍲⍶⍻y;䑑on;䄯f;쀀𝕚a;䎹uest耻¿䂿Āci⎊⎏r;쀀𝒾nʀ;EdsvӴ⎛⎝⎡ӳ;拹ot;拵Ā;v⎦⎧拴;拳Ā;iݷ⎮lde;䄩ǫ⎸\0⎼cy;䑖l耻ï䃯̀cfmosu⏌⏗⏜⏡⏧⏵Āiy⏑⏕rc;䄵;䐹r;쀀𝔧ath;䈷pf;쀀𝕛ǣ⏬\0⏱r;쀀𝒿rcy;䑘kcy;䑔Ѐacfghjos␋␖␢␧␭␱␵␻ppaĀ;v␓␔䎺;䏰Āey␛␠dil;䄷;䐺r;쀀𝔨reen;䄸cy;䑅cy;䑜pf;쀀𝕜cr;쀀𝓀஀ABEHabcdefghjlmnoprstuv⑰⒁⒆⒍⒑┎┽╚▀♎♞♥♹♽⚚⚲⛘❝❨➋⟀⠁⠒ƀart⑷⑺⑼rò৆òΕail;椛arr;椎Ā;gঔ⒋;檋ar;楢ॣ⒥\0⒪\0⒱\0\0\0\0\0⒵Ⓔ\0ⓆⓈⓍ\0⓹ute;䄺mptyv;榴raîࡌbda;䎻gƀ;dlࢎⓁⓃ;榑åࢎ;檅uo耻«䂫rЀ;bfhlpst࢙ⓞⓦⓩ⓫⓮⓱⓵Ā;f࢝ⓣs;椟s;椝ë≒p;憫l;椹im;楳l;憢ƀ;ae⓿─┄檫il;椙Ā;s┉┊檭;쀀⪭︀ƀabr┕┙┝rr;椌rk;杲Āak┢┬cĀek┨┪;䁻;䁛Āes┱┳;榋lĀdu┹┻;榏;榍Ȁaeuy╆╋╖╘ron;䄾Ādi═╔il;䄼ìࢰâ┩;䐻Ȁcqrs╣╦╭╽a;椶uoĀ;rนᝆĀdu╲╷har;楧shar;楋h;憲ʀ;fgqs▋▌উ◳◿扤tʀahlrt▘▤▷◂◨rrowĀ;t࢙□aé⓶arpoonĀdu▯▴own»њp»०eftarrows;懇ightƀahs◍◖◞rrowĀ;sࣴࢧarpoonó྘quigarro÷⇰hreetimes;拋ƀ;qs▋ও◺lanôবʀ;cdgsব☊☍☝☨c;檨otĀ;o☔☕橿Ā;r☚☛檁;檃Ā;e☢☥쀀⋚︀s;檓ʀadegs☳☹☽♉♋pproøⓆot;拖qĀgq♃♅ôউgtò⒌ôছiíলƀilr♕࣡♚sht;楼;쀀𝔩Ā;Eজ♣;檑š♩♶rĀdu▲♮Ā;l॥♳;楪lk;斄cy;䑙ʀ;achtੈ⚈⚋⚑⚖rò◁orneòᴈard;楫ri;旺Āio⚟⚤dot;䅀ustĀ;a⚬⚭掰che»⚭ȀEaes⚻⚽⛉⛔;扨pĀ;p⛃⛄檉rox»⛄Ā;q⛎⛏檇Ā;q⛎⚻im;拦Ѐabnoptwz⛩⛴⛷✚✯❁❇❐Ānr⛮⛱g;柬r;懽rëࣁgƀlmr⛿✍✔eftĀar০✇ightá৲apsto;柼ightá৽parrowĀlr✥✩efô⓭ight;憬ƀafl✶✹✽r;榅;쀀𝕝us;樭imes;樴š❋❏st;戗áፎƀ;ef❗❘᠀旊nge»❘arĀ;l❤❥䀨t;榓ʀachmt❳❶❼➅➇ròࢨorneòᶌarĀ;d྘➃;業;怎ri;抿̀achiqt➘➝ੀ➢➮➻quo;怹r;쀀𝓁mƀ;egল➪➬;檍;檏Ābu┪➳oĀ;rฟ➹;怚rok;䅂萀<;cdhilqrࠫ⟒☹⟜⟠⟥⟪⟰Āci⟗⟙;檦r;橹reå◲mes;拉arr;楶uest;橻ĀPi⟵⟹ar;榖ƀ;ef⠀भ᠛旃rĀdu⠇⠍shar;楊har;楦Āen⠗⠡rtneqq;쀀≨︀Å⠞܀Dacdefhilnopsu⡀⡅⢂⢎⢓⢠⢥⢨⣚⣢⣤ઃ⣳⤂Dot;戺Ȁclpr⡎⡒⡣⡽r耻¯䂯Āet⡗⡙;時Ā;e⡞⡟朠se»⡟Ā;sျ⡨toȀ;dluျ⡳⡷⡻owîҌefôएðᏑker;斮Āoy⢇⢌mma;権;䐼ash;怔asuredangle»ᘦr;쀀𝔪o;愧ƀcdn⢯⢴⣉ro耻µ䂵Ȁ;acdᑤ⢽⣀⣄sôᚧir;櫰ot肻·Ƶusƀ;bd⣒ᤃ⣓戒Ā;uᴼ⣘;横ţ⣞⣡p;櫛ò−ðઁĀdp⣩⣮els;抧f;쀀𝕞Āct⣸⣽r;쀀𝓂pos»ᖝƀ;lm⤉⤊⤍䎼timap;抸ఀGLRVabcdefghijlmoprstuvw⥂⥓⥾⦉⦘⧚⧩⨕⨚⩘⩝⪃⪕⪤⪨⬄⬇⭄⭿⮮ⰴⱧⱼ⳩Āgt⥇⥋;쀀⋙̸Ā;v⥐௏쀀≫⃒ƀelt⥚⥲⥶ftĀar⥡⥧rrow;懍ightarrow;懎;쀀⋘̸Ā;v⥻ే쀀≪⃒ightarrow;懏ĀDd⦎⦓ash;抯ash;抮ʀbcnpt⦣⦧⦬⦱⧌la»˞ute;䅄g;쀀∠⃒ʀ;Eiop඄⦼⧀⧅⧈;쀀⩰̸d;쀀≋̸s;䅉roø඄urĀ;a⧓⧔普lĀ;s⧓ସdz⧟\0⧣p肻 ଷmpĀ;e௹ఀʀaeouy⧴⧾⨃⨐⨓ǰ⧹\0⧻;橃on;䅈dil;䅆ngĀ;dൾ⨊ot;쀀⩭̸p;橂;䐽ash;怓΀;Aadqsxஒ⨩⨭⨻⩁⩅⩐rr;懗rĀhr⨳⨶k;椤Ā;oᏲᏰot;쀀≐̸uiöୣĀei⩊⩎ar;椨í஘istĀ;s஠டr;쀀𝔫ȀEest௅⩦⩹⩼ƀ;qs஼⩭௡ƀ;qs஼௅⩴lanô௢ií௪Ā;rஶ⪁»ஷƀAap⪊⪍⪑rò⥱rr;憮ar;櫲ƀ;svྍ⪜ྌĀ;d⪡⪢拼;拺cy;䑚΀AEadest⪷⪺⪾⫂⫅⫶⫹rò⥦;쀀≦̸rr;憚r;急Ȁ;fqs఻⫎⫣⫯tĀar⫔⫙rro÷⫁ightarro÷⪐ƀ;qs఻⪺⫪lanôౕĀ;sౕ⫴»శiíౝĀ;rవ⫾iĀ;eచథiäඐĀpt⬌⬑f;쀀𝕟膀¬;in⬙⬚⬶䂬nȀ;Edvஉ⬤⬨⬮;쀀⋹̸ot;쀀⋵̸ǡஉ⬳⬵;拷;拶iĀ;vಸ⬼ǡಸ⭁⭃;拾;拽ƀaor⭋⭣⭩rȀ;ast୻⭕⭚⭟lleì୻l;쀀⫽⃥;쀀∂̸lint;樔ƀ;ceಒ⭰⭳uåಥĀ;cಘ⭸Ā;eಒ⭽ñಘȀAait⮈⮋⮝⮧rò⦈rrƀ;cw⮔⮕⮙憛;쀀⤳̸;쀀↝̸ghtarrow»⮕riĀ;eೋೖ΀chimpqu⮽⯍⯙⬄୸⯤⯯Ȁ;cerല⯆ഷ⯉uå൅;쀀𝓃ortɭ⬅\0\0⯖ará⭖mĀ;e൮⯟Ā;q൴൳suĀbp⯫⯭å೸åഋƀbcp⯶ⰑⰙȀ;Ees⯿ⰀഢⰄ抄;쀀⫅̸etĀ;eഛⰋqĀ;qണⰀcĀ;eലⰗñസȀ;EesⰢⰣൟⰧ抅;쀀⫆̸etĀ;e൘ⰮqĀ;qൠⰣȀgilrⰽⰿⱅⱇìௗlde耻ñ䃱çృiangleĀlrⱒⱜeftĀ;eచⱚñదightĀ;eೋⱥñ೗Ā;mⱬⱭ䎽ƀ;esⱴⱵⱹ䀣ro;愖p;怇ҀDHadgilrsⲏⲔⲙⲞⲣⲰⲶⳓⳣash;抭arr;椄p;쀀≍⃒ash;抬ĀetⲨⲬ;쀀≥⃒;쀀>⃒nfin;槞ƀAetⲽⳁⳅrr;椂;쀀≤⃒Ā;rⳊⳍ쀀<⃒ie;쀀⊴⃒ĀAtⳘⳜrr;椃rie;쀀⊵⃒im;쀀∼⃒ƀAan⳰⳴ⴂrr;懖rĀhr⳺⳽k;椣Ā;oᏧᏥear;椧ቓ᪕\0\0\0\0\0\0\0\0\0\0\0\0\0ⴭ\0ⴸⵈⵠⵥ⵲ⶄᬇ\0\0ⶍⶫ\0ⷈⷎ\0ⷜ⸙⸫⸾⹃Ācsⴱ᪗ute耻ó䃳ĀiyⴼⵅrĀ;c᪞ⵂ耻ô䃴;䐾ʀabios᪠ⵒⵗLjⵚlac;䅑v;樸old;榼lig;䅓Ācr⵩⵭ir;榿;쀀𝔬ͯ⵹\0\0⵼\0ⶂn;䋛ave耻ò䃲;槁Ābmⶈ෴ar;榵Ȁacitⶕ⶘ⶥⶨrò᪀Āir⶝ⶠr;榾oss;榻nå๒;槀ƀaeiⶱⶵⶹcr;䅍ga;䏉ƀcdnⷀⷅǍron;䎿;榶pf;쀀𝕠ƀaelⷔ⷗ǒr;榷rp;榹΀;adiosvⷪⷫⷮ⸈⸍⸐⸖戨rò᪆Ȁ;efmⷷⷸ⸂⸅橝rĀ;oⷾⷿ愴f»ⷿ耻ª䂪耻º䂺gof;抶r;橖lope;橗;橛ƀclo⸟⸡⸧ò⸁ash耻ø䃸l;折iŬⸯ⸴de耻õ䃵esĀ;aǛ⸺s;樶ml耻ö䃶bar;挽ૡ⹞\0⹽\0⺀⺝\0⺢⺹\0\0⻋ຜ\0⼓\0\0⼫⾼\0⿈rȀ;astЃ⹧⹲຅脀¶;l⹭⹮䂶leìЃɩ⹸\0\0⹻m;櫳;櫽y;䐿rʀcimpt⺋⺏⺓ᡥ⺗nt;䀥od;䀮il;怰enk;怱r;쀀𝔭ƀimo⺨⺰⺴Ā;v⺭⺮䏆;䏕maô੶ne;明ƀ;tv⺿⻀⻈䏀chfork»´;䏖Āau⻏⻟nĀck⻕⻝kĀ;h⇴⻛;愎ö⇴sҀ;abcdemst⻳⻴ᤈ⻹⻽⼄⼆⼊⼎䀫cir;樣ir;樢Āouᵀ⼂;樥;橲n肻±ຝim;樦wo;樧ƀipu⼙⼠⼥ntint;樕f;쀀𝕡nd耻£䂣Ԁ;Eaceinosu່⼿⽁⽄⽇⾁⾉⾒⽾⾶;檳p;檷uå໙Ā;c໎⽌̀;acens່⽙⽟⽦⽨⽾pproø⽃urlyeñ໙ñ໎ƀaes⽯⽶⽺pprox;檹qq;檵im;拨iíໟmeĀ;s⾈ຮ怲ƀEas⽸⾐⽺ð⽵ƀdfp໬⾙⾯ƀals⾠⾥⾪lar;挮ine;挒urf;挓Ā;t໻⾴ï໻rel;抰Āci⿀⿅r;쀀𝓅;䏈ncsp;怈̀fiopsu⿚⋢⿟⿥⿫⿱r;쀀𝔮pf;쀀𝕢rime;恗cr;쀀𝓆ƀaeo⿸〉〓tĀei⿾々rnionóڰnt;樖stĀ;e【】䀿ñἙô༔઀ABHabcdefhilmnoprstux぀けさすムㄎㄫㅇㅢㅲㆎ㈆㈕㈤㈩㉘㉮㉲㊐㊰㊷ƀartぇおがròႳòϝail;検aròᱥar;楤΀cdenqrtとふへみわゔヌĀeuねぱ;쀀∽̱te;䅕iãᅮmptyv;榳gȀ;del࿑らるろ;榒;榥å࿑uo耻»䂻rր;abcfhlpstw࿜ガクシスゼゾダッデナp;極Ā;f࿠ゴs;椠;椳s;椞ë≝ð✮l;楅im;楴l;憣;憝Āaiパフil;椚oĀ;nホボ戶aló༞ƀabrョリヮrò៥rk;杳ĀakンヽcĀekヹ・;䁽;䁝Āes㄂㄄;榌lĀduㄊㄌ;榎;榐Ȁaeuyㄗㄜㄧㄩron;䅙Ādiㄡㄥil;䅗ì࿲âヺ;䑀Ȁclqsㄴㄷㄽㅄa;椷dhar;楩uoĀ;rȎȍh;憳ƀacgㅎㅟངlȀ;ipsླྀㅘㅛႜnåႻarôྩt;断ƀilrㅩဣㅮsht;楽;쀀𝔯ĀaoㅷㆆrĀduㅽㅿ»ѻĀ;l႑ㆄ;楬Ā;vㆋㆌ䏁;䏱ƀgns㆕ㇹㇼht̀ahlrstㆤㆰ㇂㇘㇤㇮rrowĀ;t࿜ㆭaéトarpoonĀduㆻㆿowîㅾp»႒eftĀah㇊㇐rrowó࿪arpoonóՑightarrows;應quigarro÷ニhreetimes;拌g;䋚ingdotseñἲƀahm㈍㈐㈓rò࿪aòՑ;怏oustĀ;a㈞㈟掱che»㈟mid;櫮Ȁabpt㈲㈽㉀㉒Ānr㈷㈺g;柭r;懾rëဃƀafl㉇㉊㉎r;榆;쀀𝕣us;樮imes;樵Āap㉝㉧rĀ;g㉣㉤䀩t;榔olint;樒arò㇣Ȁachq㉻㊀Ⴜ㊅quo;怺r;쀀𝓇Ābu・㊊oĀ;rȔȓƀhir㊗㊛㊠reåㇸmes;拊iȀ;efl㊪ၙᠡ㊫方tri;槎luhar;楨;愞ൡ㋕㋛㋟㌬㌸㍱\0㍺㎤\0\0㏬㏰\0㐨㑈㑚㒭㒱㓊㓱\0㘖\0\0㘳cute;䅛quï➺Ԁ;Eaceinpsyᇭ㋳㋵㋿㌂㌋㌏㌟㌦㌩;檴ǰ㋺\0㋼;檸on;䅡uåᇾĀ;dᇳ㌇il;䅟rc;䅝ƀEas㌖㌘㌛;檶p;檺im;择olint;樓iíሄ;䑁otƀ;be㌴ᵇ㌵担;橦΀Aacmstx㍆㍊㍗㍛㍞㍣㍭rr;懘rĀhr㍐㍒ë∨Ā;oਸ਼਴t耻§䂧i;䀻war;椩mĀin㍩ðnuóñt;朶rĀ;o㍶⁕쀀𝔰Ȁacoy㎂㎆㎑㎠rp;景Āhy㎋㎏cy;䑉;䑈rtɭ㎙\0\0㎜iäᑤaraì⹯耻­䂭Āgm㎨㎴maƀ;fv㎱㎲㎲䏃;䏂Ѐ;deglnprካ㏅㏉㏎㏖㏞㏡㏦ot;橪Ā;q኱ኰĀ;E㏓㏔檞;檠Ā;E㏛㏜檝;檟e;扆lus;樤arr;楲aròᄽȀaeit㏸㐈㐏㐗Āls㏽㐄lsetmé㍪hp;樳parsl;槤Ādlᑣ㐔e;挣Ā;e㐜㐝檪Ā;s㐢㐣檬;쀀⪬︀ƀflp㐮㐳㑂tcy;䑌Ā;b㐸㐹䀯Ā;a㐾㐿槄r;挿f;쀀𝕤aĀdr㑍ЂesĀ;u㑔㑕晠it»㑕ƀcsu㑠㑹㒟Āau㑥㑯pĀ;sᆈ㑫;쀀⊓︀pĀ;sᆴ㑵;쀀⊔︀uĀbp㑿㒏ƀ;esᆗᆜ㒆etĀ;eᆗ㒍ñᆝƀ;esᆨᆭ㒖etĀ;eᆨ㒝ñᆮƀ;afᅻ㒦ְrť㒫ֱ»ᅼaròᅈȀcemt㒹㒾㓂㓅r;쀀𝓈tmîñiì㐕aræᆾĀar㓎㓕rĀ;f㓔ឿ昆Āan㓚㓭ightĀep㓣㓪psiloîỠhé⺯s»⡒ʀbcmnp㓻㕞ሉ㖋㖎Ҁ;Edemnprs㔎㔏㔑㔕㔞㔣㔬㔱㔶抂;櫅ot;檽Ā;dᇚ㔚ot;櫃ult;櫁ĀEe㔨㔪;櫋;把lus;檿arr;楹ƀeiu㔽㕒㕕tƀ;en㔎㕅㕋qĀ;qᇚ㔏eqĀ;q㔫㔨m;櫇Ābp㕚㕜;櫕;櫓c̀;acensᇭ㕬㕲㕹㕻㌦pproø㋺urlyeñᇾñᇳƀaes㖂㖈㌛pproø㌚qñ㌗g;晪ڀ123;Edehlmnps㖩㖬㖯ሜ㖲㖴㗀㗉㗕㗚㗟㗨㗭耻¹䂹耻²䂲耻³䂳;櫆Āos㖹㖼t;檾ub;櫘Ā;dሢ㗅ot;櫄sĀou㗏㗒l;柉b;櫗arr;楻ult;櫂ĀEe㗤㗦;櫌;抋lus;櫀ƀeiu㗴㘉㘌tƀ;enሜ㗼㘂qĀ;qሢ㖲eqĀ;q㗧㗤m;櫈Ābp㘑㘓;櫔;櫖ƀAan㘜㘠㘭rr;懙rĀhr㘦㘨ë∮Ā;oਫ਩war;椪lig耻ß䃟௡㙑㙝㙠ዎ㙳㙹\0㙾㛂\0\0\0\0\0㛛㜃\0㜉㝬\0\0\0㞇ɲ㙖\0\0㙛get;挖;䏄rë๟ƀaey㙦㙫㙰ron;䅥dil;䅣;䑂lrec;挕r;쀀𝔱Ȁeiko㚆㚝㚵㚼Dz㚋\0㚑eĀ4fኄኁaƀ;sv㚘㚙㚛䎸ym;䏑Ācn㚢㚲kĀas㚨㚮pproø዁im»ኬsðኞĀas㚺㚮ð዁rn耻þ䃾Ǭ̟㛆⋧es膀×;bd㛏㛐㛘䃗Ā;aᤏ㛕r;樱;樰ƀeps㛡㛣㜀á⩍Ȁ;bcf҆㛬㛰㛴ot;挶ir;櫱Ā;o㛹㛼쀀𝕥rk;櫚á㍢rime;怴ƀaip㜏㜒㝤dåቈ΀adempst㜡㝍㝀㝑㝗㝜㝟ngleʀ;dlqr㜰㜱㜶㝀㝂斵own»ᶻeftĀ;e⠀㜾ñम;扜ightĀ;e㊪㝋ñၚot;旬inus;樺lus;樹b;槍ime;樻ezium;揢ƀcht㝲㝽㞁Āry㝷㝻;쀀𝓉;䑆cy;䑛rok;䅧Āio㞋㞎xô᝷headĀlr㞗㞠eftarro÷ࡏightarrow»ཝऀAHabcdfghlmoprstuw㟐㟓㟗㟤㟰㟼㠎㠜㠣㠴㡑㡝㡫㢩㣌㣒㣪㣶ròϭar;楣Ācr㟜㟢ute耻ú䃺òᅐrǣ㟪\0㟭y;䑞ve;䅭Āiy㟵㟺rc耻û䃻;䑃ƀabh㠃㠆㠋ròᎭlac;䅱aòᏃĀir㠓㠘sht;楾;쀀𝔲rave耻ù䃹š㠧㠱rĀlr㠬㠮»ॗ»ႃlk;斀Āct㠹㡍ɯ㠿\0\0㡊rnĀ;e㡅㡆挜r»㡆op;挏ri;旸Āal㡖㡚cr;䅫肻¨͉Āgp㡢㡦on;䅳f;쀀𝕦̀adhlsuᅋ㡸㡽፲㢑㢠ownáᎳarpoonĀlr㢈㢌efô㠭ighô㠯iƀ;hl㢙㢚㢜䏅»ᏺon»㢚parrows;懈ƀcit㢰㣄㣈ɯ㢶\0\0㣁rnĀ;e㢼㢽挝r»㢽op;挎ng;䅯ri;旹cr;쀀𝓊ƀdir㣙㣝㣢ot;拰lde;䅩iĀ;f㜰㣨»᠓Āam㣯㣲rò㢨l耻ü䃼angle;榧ހABDacdeflnoprsz㤜㤟㤩㤭㦵㦸㦽㧟㧤㧨㧳㧹㧽㨁㨠ròϷarĀ;v㤦㤧櫨;櫩asèϡĀnr㤲㤷grt;榜΀eknprst㓣㥆㥋㥒㥝㥤㦖appá␕othinçẖƀhir㓫⻈㥙opô⾵Ā;hᎷ㥢ïㆍĀiu㥩㥭gmá㎳Ābp㥲㦄setneqĀ;q㥽㦀쀀⊊︀;쀀⫋︀setneqĀ;q㦏㦒쀀⊋︀;쀀⫌︀Āhr㦛㦟etá㚜iangleĀlr㦪㦯eft»थight»ၑy;䐲ash»ံƀelr㧄㧒㧗ƀ;beⷪ㧋㧏ar;抻q;扚lip;拮Ābt㧜ᑨaòᑩr;쀀𝔳tré㦮suĀbp㧯㧱»ജ»൙pf;쀀𝕧roð໻tré㦴Ācu㨆㨋r;쀀𝓋Ābp㨐㨘nĀEe㦀㨖»㥾nĀEe㦒㨞»㦐igzag;榚΀cefoprs㨶㨻㩖㩛㩔㩡㩪irc;䅵Ādi㩀㩑Ābg㩅㩉ar;機eĀ;qᗺ㩏;扙erp;愘r;쀀𝔴pf;쀀𝕨Ā;eᑹ㩦atèᑹcr;쀀𝓌ૣណ㪇\0㪋\0㪐㪛\0\0㪝㪨㪫㪯\0\0㫃㫎\0㫘ៜ៟tré៑r;쀀𝔵ĀAa㪔㪗ròσrò৶;䎾ĀAa㪡㪤ròθrò৫að✓is;拻ƀdptឤ㪵㪾Āfl㪺ឩ;쀀𝕩imåឲĀAa㫇㫊ròώròਁĀcq㫒ីr;쀀𝓍Āpt៖㫜ré។Ѐacefiosu㫰㫽㬈㬌㬑㬕㬛㬡cĀuy㫶㫻te耻ý䃽;䑏Āiy㬂㬆rc;䅷;䑋n耻¥䂥r;쀀𝔶cy;䑗pf;쀀𝕪cr;쀀𝓎Ācm㬦㬩y;䑎l耻ÿ䃿Ԁacdefhiosw㭂㭈㭔㭘㭤㭩㭭㭴㭺㮀cute;䅺Āay㭍㭒ron;䅾;䐷ot;䅼Āet㭝㭡træᕟa;䎶r;쀀𝔷cy;䐶grarr;懝pf;쀀𝕫cr;쀀𝓏Ājn㮅㮇;怍j;怌'.split("").map(e=>e.charCodeAt(0))),tBe=new Uint16Array("Ȁaglq \x1Bɭ\0\0p;䀦os;䀧t;䀾t;䀼uot;䀢".split("").map(e=>e.charCodeAt(0)));var xO;const nBe=new Map([[0,65533],[128,8364],[130,8218],[131,402],[132,8222],[133,8230],[134,8224],[135,8225],[136,710],[137,8240],[138,352],[139,8249],[140,338],[142,381],[145,8216],[146,8217],[147,8220],[148,8221],[149,8226],[150,8211],[151,8212],[152,732],[153,8482],[154,353],[155,8250],[156,339],[158,382],[159,376]]),rBe=(xO=String.fromCodePoint)!==null&&xO!==void 0?xO:function(e){let t="";return e>65535&&(e-=65536,t+=String.fromCharCode(e>>>10&1023|55296),e=56320|e&1023),t+=String.fromCharCode(e),t};function iBe(e){var t;return e>=55296&&e<=57343||e>1114111?65533:(t=nBe.get(e))!==null&&t!==void 0?t:e}var mi;(function(e){e[e.NUM=35]="NUM",e[e.SEMI=59]="SEMI",e[e.EQUALS=61]="EQUALS",e[e.ZERO=48]="ZERO",e[e.NINE=57]="NINE",e[e.LOWER_A=97]="LOWER_A",e[e.LOWER_F=102]="LOWER_F",e[e.LOWER_X=120]="LOWER_X",e[e.LOWER_Z=122]="LOWER_Z",e[e.UPPER_A=65]="UPPER_A",e[e.UPPER_F=70]="UPPER_F",e[e.UPPER_Z=90]="UPPER_Z"})(mi||(mi={}));const sBe=32;var Ru;(function(e){e[e.VALUE_LENGTH=49152]="VALUE_LENGTH",e[e.BRANCH_LENGTH=16256]="BRANCH_LENGTH",e[e.JUMP_TABLE=127]="JUMP_TABLE"})(Ru||(Ru={}));function RN(e){return e>=mi.ZERO&&e<=mi.NINE}function oBe(e){return e>=mi.UPPER_A&&e<=mi.UPPER_F||e>=mi.LOWER_A&&e<=mi.LOWER_F}function aBe(e){return e>=mi.UPPER_A&&e<=mi.UPPER_Z||e>=mi.LOWER_A&&e<=mi.LOWER_Z||RN(e)}function uBe(e){return e===mi.EQUALS||aBe(e)}var li;(function(e){e[e.EntityStart=0]="EntityStart",e[e.NumericStart=1]="NumericStart",e[e.NumericDecimal=2]="NumericDecimal",e[e.NumericHex=3]="NumericHex",e[e.NamedEntity=4]="NamedEntity"})(li||(li={}));var Cd;(function(e){e[e.Legacy=0]="Legacy",e[e.Strict=1]="Strict",e[e.Attribute=2]="Attribute"})(Cd||(Cd={}));class lBe{constructor(t,n,r){this.decodeTree=t,this.emitCodePoint=n,this.errors=r,this.state=li.EntityStart,this.consumed=1,this.result=0,this.treeIndex=0,this.excess=1,this.decodeMode=Cd.Strict}startEntity(t){this.decodeMode=t,this.state=li.EntityStart,this.result=0,this.treeIndex=0,this.excess=1,this.consumed=1}write(t,n){switch(this.state){case li.EntityStart:return t.charCodeAt(n)===mi.NUM?(this.state=li.NumericStart,this.consumed+=1,this.stateNumericStart(t,n+1)):(this.state=li.NamedEntity,this.stateNamedEntity(t,n));case li.NumericStart:return this.stateNumericStart(t,n);case li.NumericDecimal:return this.stateNumericDecimal(t,n);case li.NumericHex:return this.stateNumericHex(t,n);case li.NamedEntity:return this.stateNamedEntity(t,n)}}stateNumericStart(t,n){return n>=t.length?-1:(t.charCodeAt(n)|sBe)===mi.LOWER_X?(this.state=li.NumericHex,this.consumed+=1,this.stateNumericHex(t,n+1)):(this.state=li.NumericDecimal,this.stateNumericDecimal(t,n))}addToNumericResult(t,n,r,i){if(n!==r){const s=r-n;this.result=this.result*Math.pow(i,s)+parseInt(t.substr(n,s),i),this.consumed+=s}}stateNumericHex(t,n){const r=n;for(;n>14;for(;n>14,s!==0){if(o===mi.SEMI)return this.emitNamedEntityData(this.treeIndex,s,this.consumed+this.excess);this.decodeMode!==Cd.Strict&&(this.result=this.treeIndex,this.consumed+=this.excess,this.excess=0)}}return-1}emitNotTerminatedNamedEntity(){var t;const{result:n,decodeTree:r}=this,i=(r[n]&Ru.VALUE_LENGTH)>>14;return this.emitNamedEntityData(n,i,this.consumed),(t=this.errors)===null||t===void 0||t.missingSemicolonAfterCharacterReference(),this.consumed}emitNamedEntityData(t,n,r){const{decodeTree:i}=this;return this.emitCodePoint(n===1?i[t]&~Ru.VALUE_LENGTH:i[t+1],r),n===3&&this.emitCodePoint(i[t+2],r),r}end(){var t;switch(this.state){case li.NamedEntity:return this.result!==0&&(this.decodeMode!==Cd.Attribute||this.result===this.treeIndex)?this.emitNotTerminatedNamedEntity():0;case li.NumericDecimal:return this.emitNumericEntity(0,2);case li.NumericHex:return this.emitNumericEntity(0,3);case li.NumericStart:return(t=this.errors)===null||t===void 0||t.absenceOfDigitsInNumericCharacterReference(this.consumed),0;case li.EntityStart:return 0}}}function Hre(e){let t="";const n=new lBe(e,r=>t+=rBe(r));return function(i,s){let o=0,a=0;for(;(a=i.indexOf("&",a))>=0;){t+=i.slice(o,a),n.startEntity(s);const l=n.write(i,a+1);if(l<0){o=a+n.end();break}o=a+l,a=l===0?o+1:o}const u=t+i.slice(o);return t="",u}}function Wre(e,t,n,r){const i=(t&Ru.BRANCH_LENGTH)>>7,s=t&Ru.JUMP_TABLE;if(i===0)return s!==0&&r===s?n:-1;if(s){const u=r-s;return u<0||u>=i?-1:e[n+u]-1}let o=n,a=o+i-1;for(;o<=a;){const u=o+a>>>1,l=e[u];if(lr)a=u-1;else return e[u+i]}return-1}Hre(Oc);Hre(tBe);var we;(function(e){e.HTML="http://www.w3.org/1999/xhtml",e.MATHML="http://www.w3.org/1998/Math/MathML",e.SVG="http://www.w3.org/2000/svg",e.XLINK="http://www.w3.org/1999/xlink",e.XML="http://www.w3.org/XML/1998/namespace",e.XMLNS="http://www.w3.org/2000/xmlns/"})(we=we||(we={}));var gf;(function(e){e.TYPE="type",e.ACTION="action",e.ENCODING="encoding",e.PROMPT="prompt",e.NAME="name",e.COLOR="color",e.FACE="face",e.SIZE="size"})(gf=gf||(gf={}));var go;(function(e){e.NO_QUIRKS="no-quirks",e.QUIRKS="quirks",e.LIMITED_QUIRKS="limited-quirks"})(go=go||(go={}));var le;(function(e){e.A="a",e.ADDRESS="address",e.ANNOTATION_XML="annotation-xml",e.APPLET="applet",e.AREA="area",e.ARTICLE="article",e.ASIDE="aside",e.B="b",e.BASE="base",e.BASEFONT="basefont",e.BGSOUND="bgsound",e.BIG="big",e.BLOCKQUOTE="blockquote",e.BODY="body",e.BR="br",e.BUTTON="button",e.CAPTION="caption",e.CENTER="center",e.CODE="code",e.COL="col",e.COLGROUP="colgroup",e.DD="dd",e.DESC="desc",e.DETAILS="details",e.DIALOG="dialog",e.DIR="dir",e.DIV="div",e.DL="dl",e.DT="dt",e.EM="em",e.EMBED="embed",e.FIELDSET="fieldset",e.FIGCAPTION="figcaption",e.FIGURE="figure",e.FONT="font",e.FOOTER="footer",e.FOREIGN_OBJECT="foreignObject",e.FORM="form",e.FRAME="frame",e.FRAMESET="frameset",e.H1="h1",e.H2="h2",e.H3="h3",e.H4="h4",e.H5="h5",e.H6="h6",e.HEAD="head",e.HEADER="header",e.HGROUP="hgroup",e.HR="hr",e.HTML="html",e.I="i",e.IMG="img",e.IMAGE="image",e.INPUT="input",e.IFRAME="iframe",e.KEYGEN="keygen",e.LABEL="label",e.LI="li",e.LINK="link",e.LISTING="listing",e.MAIN="main",e.MALIGNMARK="malignmark",e.MARQUEE="marquee",e.MATH="math",e.MENU="menu",e.META="meta",e.MGLYPH="mglyph",e.MI="mi",e.MO="mo",e.MN="mn",e.MS="ms",e.MTEXT="mtext",e.NAV="nav",e.NOBR="nobr",e.NOFRAMES="noframes",e.NOEMBED="noembed",e.NOSCRIPT="noscript",e.OBJECT="object",e.OL="ol",e.OPTGROUP="optgroup",e.OPTION="option",e.P="p",e.PARAM="param",e.PLAINTEXT="plaintext",e.PRE="pre",e.RB="rb",e.RP="rp",e.RT="rt",e.RTC="rtc",e.RUBY="ruby",e.S="s",e.SCRIPT="script",e.SECTION="section",e.SELECT="select",e.SOURCE="source",e.SMALL="small",e.SPAN="span",e.STRIKE="strike",e.STRONG="strong",e.STYLE="style",e.SUB="sub",e.SUMMARY="summary",e.SUP="sup",e.TABLE="table",e.TBODY="tbody",e.TEMPLATE="template",e.TEXTAREA="textarea",e.TFOOT="tfoot",e.TD="td",e.TH="th",e.THEAD="thead",e.TITLE="title",e.TR="tr",e.TRACK="track",e.TT="tt",e.U="u",e.UL="ul",e.SVG="svg",e.VAR="var",e.WBR="wbr",e.XMP="xmp"})(le=le||(le={}));var _;(function(e){e[e.UNKNOWN=0]="UNKNOWN",e[e.A=1]="A",e[e.ADDRESS=2]="ADDRESS",e[e.ANNOTATION_XML=3]="ANNOTATION_XML",e[e.APPLET=4]="APPLET",e[e.AREA=5]="AREA",e[e.ARTICLE=6]="ARTICLE",e[e.ASIDE=7]="ASIDE",e[e.B=8]="B",e[e.BASE=9]="BASE",e[e.BASEFONT=10]="BASEFONT",e[e.BGSOUND=11]="BGSOUND",e[e.BIG=12]="BIG",e[e.BLOCKQUOTE=13]="BLOCKQUOTE",e[e.BODY=14]="BODY",e[e.BR=15]="BR",e[e.BUTTON=16]="BUTTON",e[e.CAPTION=17]="CAPTION",e[e.CENTER=18]="CENTER",e[e.CODE=19]="CODE",e[e.COL=20]="COL",e[e.COLGROUP=21]="COLGROUP",e[e.DD=22]="DD",e[e.DESC=23]="DESC",e[e.DETAILS=24]="DETAILS",e[e.DIALOG=25]="DIALOG",e[e.DIR=26]="DIR",e[e.DIV=27]="DIV",e[e.DL=28]="DL",e[e.DT=29]="DT",e[e.EM=30]="EM",e[e.EMBED=31]="EMBED",e[e.FIELDSET=32]="FIELDSET",e[e.FIGCAPTION=33]="FIGCAPTION",e[e.FIGURE=34]="FIGURE",e[e.FONT=35]="FONT",e[e.FOOTER=36]="FOOTER",e[e.FOREIGN_OBJECT=37]="FOREIGN_OBJECT",e[e.FORM=38]="FORM",e[e.FRAME=39]="FRAME",e[e.FRAMESET=40]="FRAMESET",e[e.H1=41]="H1",e[e.H2=42]="H2",e[e.H3=43]="H3",e[e.H4=44]="H4",e[e.H5=45]="H5",e[e.H6=46]="H6",e[e.HEAD=47]="HEAD",e[e.HEADER=48]="HEADER",e[e.HGROUP=49]="HGROUP",e[e.HR=50]="HR",e[e.HTML=51]="HTML",e[e.I=52]="I",e[e.IMG=53]="IMG",e[e.IMAGE=54]="IMAGE",e[e.INPUT=55]="INPUT",e[e.IFRAME=56]="IFRAME",e[e.KEYGEN=57]="KEYGEN",e[e.LABEL=58]="LABEL",e[e.LI=59]="LI",e[e.LINK=60]="LINK",e[e.LISTING=61]="LISTING",e[e.MAIN=62]="MAIN",e[e.MALIGNMARK=63]="MALIGNMARK",e[e.MARQUEE=64]="MARQUEE",e[e.MATH=65]="MATH",e[e.MENU=66]="MENU",e[e.META=67]="META",e[e.MGLYPH=68]="MGLYPH",e[e.MI=69]="MI",e[e.MO=70]="MO",e[e.MN=71]="MN",e[e.MS=72]="MS",e[e.MTEXT=73]="MTEXT",e[e.NAV=74]="NAV",e[e.NOBR=75]="NOBR",e[e.NOFRAMES=76]="NOFRAMES",e[e.NOEMBED=77]="NOEMBED",e[e.NOSCRIPT=78]="NOSCRIPT",e[e.OBJECT=79]="OBJECT",e[e.OL=80]="OL",e[e.OPTGROUP=81]="OPTGROUP",e[e.OPTION=82]="OPTION",e[e.P=83]="P",e[e.PARAM=84]="PARAM",e[e.PLAINTEXT=85]="PLAINTEXT",e[e.PRE=86]="PRE",e[e.RB=87]="RB",e[e.RP=88]="RP",e[e.RT=89]="RT",e[e.RTC=90]="RTC",e[e.RUBY=91]="RUBY",e[e.S=92]="S",e[e.SCRIPT=93]="SCRIPT",e[e.SECTION=94]="SECTION",e[e.SELECT=95]="SELECT",e[e.SOURCE=96]="SOURCE",e[e.SMALL=97]="SMALL",e[e.SPAN=98]="SPAN",e[e.STRIKE=99]="STRIKE",e[e.STRONG=100]="STRONG",e[e.STYLE=101]="STYLE",e[e.SUB=102]="SUB",e[e.SUMMARY=103]="SUMMARY",e[e.SUP=104]="SUP",e[e.TABLE=105]="TABLE",e[e.TBODY=106]="TBODY",e[e.TEMPLATE=107]="TEMPLATE",e[e.TEXTAREA=108]="TEXTAREA",e[e.TFOOT=109]="TFOOT",e[e.TD=110]="TD",e[e.TH=111]="TH",e[e.THEAD=112]="THEAD",e[e.TITLE=113]="TITLE",e[e.TR=114]="TR",e[e.TRACK=115]="TRACK",e[e.TT=116]="TT",e[e.U=117]="U",e[e.UL=118]="UL",e[e.SVG=119]="SVG",e[e.VAR=120]="VAR",e[e.WBR=121]="WBR",e[e.XMP=122]="XMP"})(_=_||(_={}));const cBe=new Map([[le.A,_.A],[le.ADDRESS,_.ADDRESS],[le.ANNOTATION_XML,_.ANNOTATION_XML],[le.APPLET,_.APPLET],[le.AREA,_.AREA],[le.ARTICLE,_.ARTICLE],[le.ASIDE,_.ASIDE],[le.B,_.B],[le.BASE,_.BASE],[le.BASEFONT,_.BASEFONT],[le.BGSOUND,_.BGSOUND],[le.BIG,_.BIG],[le.BLOCKQUOTE,_.BLOCKQUOTE],[le.BODY,_.BODY],[le.BR,_.BR],[le.BUTTON,_.BUTTON],[le.CAPTION,_.CAPTION],[le.CENTER,_.CENTER],[le.CODE,_.CODE],[le.COL,_.COL],[le.COLGROUP,_.COLGROUP],[le.DD,_.DD],[le.DESC,_.DESC],[le.DETAILS,_.DETAILS],[le.DIALOG,_.DIALOG],[le.DIR,_.DIR],[le.DIV,_.DIV],[le.DL,_.DL],[le.DT,_.DT],[le.EM,_.EM],[le.EMBED,_.EMBED],[le.FIELDSET,_.FIELDSET],[le.FIGCAPTION,_.FIGCAPTION],[le.FIGURE,_.FIGURE],[le.FONT,_.FONT],[le.FOOTER,_.FOOTER],[le.FOREIGN_OBJECT,_.FOREIGN_OBJECT],[le.FORM,_.FORM],[le.FRAME,_.FRAME],[le.FRAMESET,_.FRAMESET],[le.H1,_.H1],[le.H2,_.H2],[le.H3,_.H3],[le.H4,_.H4],[le.H5,_.H5],[le.H6,_.H6],[le.HEAD,_.HEAD],[le.HEADER,_.HEADER],[le.HGROUP,_.HGROUP],[le.HR,_.HR],[le.HTML,_.HTML],[le.I,_.I],[le.IMG,_.IMG],[le.IMAGE,_.IMAGE],[le.INPUT,_.INPUT],[le.IFRAME,_.IFRAME],[le.KEYGEN,_.KEYGEN],[le.LABEL,_.LABEL],[le.LI,_.LI],[le.LINK,_.LINK],[le.LISTING,_.LISTING],[le.MAIN,_.MAIN],[le.MALIGNMARK,_.MALIGNMARK],[le.MARQUEE,_.MARQUEE],[le.MATH,_.MATH],[le.MENU,_.MENU],[le.META,_.META],[le.MGLYPH,_.MGLYPH],[le.MI,_.MI],[le.MO,_.MO],[le.MN,_.MN],[le.MS,_.MS],[le.MTEXT,_.MTEXT],[le.NAV,_.NAV],[le.NOBR,_.NOBR],[le.NOFRAMES,_.NOFRAMES],[le.NOEMBED,_.NOEMBED],[le.NOSCRIPT,_.NOSCRIPT],[le.OBJECT,_.OBJECT],[le.OL,_.OL],[le.OPTGROUP,_.OPTGROUP],[le.OPTION,_.OPTION],[le.P,_.P],[le.PARAM,_.PARAM],[le.PLAINTEXT,_.PLAINTEXT],[le.PRE,_.PRE],[le.RB,_.RB],[le.RP,_.RP],[le.RT,_.RT],[le.RTC,_.RTC],[le.RUBY,_.RUBY],[le.S,_.S],[le.SCRIPT,_.SCRIPT],[le.SECTION,_.SECTION],[le.SELECT,_.SELECT],[le.SOURCE,_.SOURCE],[le.SMALL,_.SMALL],[le.SPAN,_.SPAN],[le.STRIKE,_.STRIKE],[le.STRONG,_.STRONG],[le.STYLE,_.STYLE],[le.SUB,_.SUB],[le.SUMMARY,_.SUMMARY],[le.SUP,_.SUP],[le.TABLE,_.TABLE],[le.TBODY,_.TBODY],[le.TEMPLATE,_.TEMPLATE],[le.TEXTAREA,_.TEXTAREA],[le.TFOOT,_.TFOOT],[le.TD,_.TD],[le.TH,_.TH],[le.THEAD,_.THEAD],[le.TITLE,_.TITLE],[le.TR,_.TR],[le.TRACK,_.TRACK],[le.TT,_.TT],[le.U,_.U],[le.UL,_.UL],[le.SVG,_.SVG],[le.VAR,_.VAR],[le.WBR,_.WBR],[le.XMP,_.XMP]]);function Og(e){var t;return(t=cBe.get(e))!==null&&t!==void 0?t:_.UNKNOWN}const Ae=_,fBe={[we.HTML]:new Set([Ae.ADDRESS,Ae.APPLET,Ae.AREA,Ae.ARTICLE,Ae.ASIDE,Ae.BASE,Ae.BASEFONT,Ae.BGSOUND,Ae.BLOCKQUOTE,Ae.BODY,Ae.BR,Ae.BUTTON,Ae.CAPTION,Ae.CENTER,Ae.COL,Ae.COLGROUP,Ae.DD,Ae.DETAILS,Ae.DIR,Ae.DIV,Ae.DL,Ae.DT,Ae.EMBED,Ae.FIELDSET,Ae.FIGCAPTION,Ae.FIGURE,Ae.FOOTER,Ae.FORM,Ae.FRAME,Ae.FRAMESET,Ae.H1,Ae.H2,Ae.H3,Ae.H4,Ae.H5,Ae.H6,Ae.HEAD,Ae.HEADER,Ae.HGROUP,Ae.HR,Ae.HTML,Ae.IFRAME,Ae.IMG,Ae.INPUT,Ae.LI,Ae.LINK,Ae.LISTING,Ae.MAIN,Ae.MARQUEE,Ae.MENU,Ae.META,Ae.NAV,Ae.NOEMBED,Ae.NOFRAMES,Ae.NOSCRIPT,Ae.OBJECT,Ae.OL,Ae.P,Ae.PARAM,Ae.PLAINTEXT,Ae.PRE,Ae.SCRIPT,Ae.SECTION,Ae.SELECT,Ae.SOURCE,Ae.STYLE,Ae.SUMMARY,Ae.TABLE,Ae.TBODY,Ae.TD,Ae.TEMPLATE,Ae.TEXTAREA,Ae.TFOOT,Ae.TH,Ae.THEAD,Ae.TITLE,Ae.TR,Ae.TRACK,Ae.UL,Ae.WBR,Ae.XMP]),[we.MATHML]:new Set([Ae.MI,Ae.MO,Ae.MN,Ae.MS,Ae.MTEXT,Ae.ANNOTATION_XML]),[we.SVG]:new Set([Ae.TITLE,Ae.FOREIGN_OBJECT,Ae.DESC]),[we.XLINK]:new Set,[we.XML]:new Set,[we.XMLNS]:new Set};function qre(e){return e===Ae.H1||e===Ae.H2||e===Ae.H3||e===Ae.H4||e===Ae.H5||e===Ae.H6}le.STYLE,le.SCRIPT,le.XMP,le.IFRAME,le.NOEMBED,le.NOFRAMES,le.PLAINTEXT;const dBe=new Map([[128,8364],[130,8218],[131,402],[132,8222],[133,8230],[134,8224],[135,8225],[136,710],[137,8240],[138,352],[139,8249],[140,338],[142,381],[145,8216],[146,8217],[147,8220],[148,8221],[149,8226],[150,8211],[151,8212],[152,732],[153,8482],[154,353],[155,8250],[156,339],[158,382],[159,376]]);var U;(function(e){e[e.DATA=0]="DATA",e[e.RCDATA=1]="RCDATA",e[e.RAWTEXT=2]="RAWTEXT",e[e.SCRIPT_DATA=3]="SCRIPT_DATA",e[e.PLAINTEXT=4]="PLAINTEXT",e[e.TAG_OPEN=5]="TAG_OPEN",e[e.END_TAG_OPEN=6]="END_TAG_OPEN",e[e.TAG_NAME=7]="TAG_NAME",e[e.RCDATA_LESS_THAN_SIGN=8]="RCDATA_LESS_THAN_SIGN",e[e.RCDATA_END_TAG_OPEN=9]="RCDATA_END_TAG_OPEN",e[e.RCDATA_END_TAG_NAME=10]="RCDATA_END_TAG_NAME",e[e.RAWTEXT_LESS_THAN_SIGN=11]="RAWTEXT_LESS_THAN_SIGN",e[e.RAWTEXT_END_TAG_OPEN=12]="RAWTEXT_END_TAG_OPEN",e[e.RAWTEXT_END_TAG_NAME=13]="RAWTEXT_END_TAG_NAME",e[e.SCRIPT_DATA_LESS_THAN_SIGN=14]="SCRIPT_DATA_LESS_THAN_SIGN",e[e.SCRIPT_DATA_END_TAG_OPEN=15]="SCRIPT_DATA_END_TAG_OPEN",e[e.SCRIPT_DATA_END_TAG_NAME=16]="SCRIPT_DATA_END_TAG_NAME",e[e.SCRIPT_DATA_ESCAPE_START=17]="SCRIPT_DATA_ESCAPE_START",e[e.SCRIPT_DATA_ESCAPE_START_DASH=18]="SCRIPT_DATA_ESCAPE_START_DASH",e[e.SCRIPT_DATA_ESCAPED=19]="SCRIPT_DATA_ESCAPED",e[e.SCRIPT_DATA_ESCAPED_DASH=20]="SCRIPT_DATA_ESCAPED_DASH",e[e.SCRIPT_DATA_ESCAPED_DASH_DASH=21]="SCRIPT_DATA_ESCAPED_DASH_DASH",e[e.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN=22]="SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN",e[e.SCRIPT_DATA_ESCAPED_END_TAG_OPEN=23]="SCRIPT_DATA_ESCAPED_END_TAG_OPEN",e[e.SCRIPT_DATA_ESCAPED_END_TAG_NAME=24]="SCRIPT_DATA_ESCAPED_END_TAG_NAME",e[e.SCRIPT_DATA_DOUBLE_ESCAPE_START=25]="SCRIPT_DATA_DOUBLE_ESCAPE_START",e[e.SCRIPT_DATA_DOUBLE_ESCAPED=26]="SCRIPT_DATA_DOUBLE_ESCAPED",e[e.SCRIPT_DATA_DOUBLE_ESCAPED_DASH=27]="SCRIPT_DATA_DOUBLE_ESCAPED_DASH",e[e.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH=28]="SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH",e[e.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN=29]="SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN",e[e.SCRIPT_DATA_DOUBLE_ESCAPE_END=30]="SCRIPT_DATA_DOUBLE_ESCAPE_END",e[e.BEFORE_ATTRIBUTE_NAME=31]="BEFORE_ATTRIBUTE_NAME",e[e.ATTRIBUTE_NAME=32]="ATTRIBUTE_NAME",e[e.AFTER_ATTRIBUTE_NAME=33]="AFTER_ATTRIBUTE_NAME",e[e.BEFORE_ATTRIBUTE_VALUE=34]="BEFORE_ATTRIBUTE_VALUE",e[e.ATTRIBUTE_VALUE_DOUBLE_QUOTED=35]="ATTRIBUTE_VALUE_DOUBLE_QUOTED",e[e.ATTRIBUTE_VALUE_SINGLE_QUOTED=36]="ATTRIBUTE_VALUE_SINGLE_QUOTED",e[e.ATTRIBUTE_VALUE_UNQUOTED=37]="ATTRIBUTE_VALUE_UNQUOTED",e[e.AFTER_ATTRIBUTE_VALUE_QUOTED=38]="AFTER_ATTRIBUTE_VALUE_QUOTED",e[e.SELF_CLOSING_START_TAG=39]="SELF_CLOSING_START_TAG",e[e.BOGUS_COMMENT=40]="BOGUS_COMMENT",e[e.MARKUP_DECLARATION_OPEN=41]="MARKUP_DECLARATION_OPEN",e[e.COMMENT_START=42]="COMMENT_START",e[e.COMMENT_START_DASH=43]="COMMENT_START_DASH",e[e.COMMENT=44]="COMMENT",e[e.COMMENT_LESS_THAN_SIGN=45]="COMMENT_LESS_THAN_SIGN",e[e.COMMENT_LESS_THAN_SIGN_BANG=46]="COMMENT_LESS_THAN_SIGN_BANG",e[e.COMMENT_LESS_THAN_SIGN_BANG_DASH=47]="COMMENT_LESS_THAN_SIGN_BANG_DASH",e[e.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH=48]="COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH",e[e.COMMENT_END_DASH=49]="COMMENT_END_DASH",e[e.COMMENT_END=50]="COMMENT_END",e[e.COMMENT_END_BANG=51]="COMMENT_END_BANG",e[e.DOCTYPE=52]="DOCTYPE",e[e.BEFORE_DOCTYPE_NAME=53]="BEFORE_DOCTYPE_NAME",e[e.DOCTYPE_NAME=54]="DOCTYPE_NAME",e[e.AFTER_DOCTYPE_NAME=55]="AFTER_DOCTYPE_NAME",e[e.AFTER_DOCTYPE_PUBLIC_KEYWORD=56]="AFTER_DOCTYPE_PUBLIC_KEYWORD",e[e.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER=57]="BEFORE_DOCTYPE_PUBLIC_IDENTIFIER",e[e.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED=58]="DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED",e[e.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED=59]="DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED",e[e.AFTER_DOCTYPE_PUBLIC_IDENTIFIER=60]="AFTER_DOCTYPE_PUBLIC_IDENTIFIER",e[e.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS=61]="BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS",e[e.AFTER_DOCTYPE_SYSTEM_KEYWORD=62]="AFTER_DOCTYPE_SYSTEM_KEYWORD",e[e.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER=63]="BEFORE_DOCTYPE_SYSTEM_IDENTIFIER",e[e.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED=64]="DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED",e[e.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED=65]="DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED",e[e.AFTER_DOCTYPE_SYSTEM_IDENTIFIER=66]="AFTER_DOCTYPE_SYSTEM_IDENTIFIER",e[e.BOGUS_DOCTYPE=67]="BOGUS_DOCTYPE",e[e.CDATA_SECTION=68]="CDATA_SECTION",e[e.CDATA_SECTION_BRACKET=69]="CDATA_SECTION_BRACKET",e[e.CDATA_SECTION_END=70]="CDATA_SECTION_END",e[e.CHARACTER_REFERENCE=71]="CHARACTER_REFERENCE",e[e.NAMED_CHARACTER_REFERENCE=72]="NAMED_CHARACTER_REFERENCE",e[e.AMBIGUOUS_AMPERSAND=73]="AMBIGUOUS_AMPERSAND",e[e.NUMERIC_CHARACTER_REFERENCE=74]="NUMERIC_CHARACTER_REFERENCE",e[e.HEXADEMICAL_CHARACTER_REFERENCE_START=75]="HEXADEMICAL_CHARACTER_REFERENCE_START",e[e.HEXADEMICAL_CHARACTER_REFERENCE=76]="HEXADEMICAL_CHARACTER_REFERENCE",e[e.DECIMAL_CHARACTER_REFERENCE=77]="DECIMAL_CHARACTER_REFERENCE",e[e.NUMERIC_CHARACTER_REFERENCE_END=78]="NUMERIC_CHARACTER_REFERENCE_END"})(U||(U={}));const Mr={DATA:U.DATA,RCDATA:U.RCDATA,RAWTEXT:U.RAWTEXT,SCRIPT_DATA:U.SCRIPT_DATA,PLAINTEXT:U.PLAINTEXT,CDATA_SECTION:U.CDATA_SECTION};function Py(e){return e>=M.DIGIT_0&&e<=M.DIGIT_9}function X0(e){return e>=M.LATIN_CAPITAL_A&&e<=M.LATIN_CAPITAL_Z}function hBe(e){return e>=M.LATIN_SMALL_A&&e<=M.LATIN_SMALL_Z}function Rc(e){return hBe(e)||X0(e)}function NN(e){return Rc(e)||Py(e)}function Gre(e){return e>=M.LATIN_CAPITAL_A&&e<=M.LATIN_CAPITAL_F}function Yre(e){return e>=M.LATIN_SMALL_A&&e<=M.LATIN_SMALL_F}function pBe(e){return Py(e)||Gre(e)||Yre(e)}function Rb(e){return e+32}function Kre(e){return e===M.SPACE||e===M.LINE_FEED||e===M.TABULATION||e===M.FORM_FEED}function mBe(e){return e===M.EQUALS_SIGN||NN(e)}function m7(e){return Kre(e)||e===M.SOLIDUS||e===M.GREATER_THAN_SIGN}class gBe{constructor(t,n){this.options=t,this.handler=n,this.paused=!1,this.inLoop=!1,this.inForeignNode=!1,this.lastStartTagName="",this.active=!1,this.state=U.DATA,this.returnState=U.DATA,this.charRefCode=-1,this.consumedAfterSnapshot=-1,this.currentCharacterToken=null,this.currentToken=null,this.currentAttr={name:"",value:""},this.preprocessor=new eBe(n),this.currentLocation=this.getCurrentLocation(-1)}_err(t){var n,r;(r=(n=this.handler).onParseError)===null||r===void 0||r.call(n,this.preprocessor.getError(t))}getCurrentLocation(t){return this.options.sourceCodeLocationInfo?{startLine:this.preprocessor.line,startCol:this.preprocessor.col-t,startOffset:this.preprocessor.offset-t,endLine:-1,endCol:-1,endOffset:-1}:null}_runParsingLoop(){if(!this.inLoop){for(this.inLoop=!0;this.active&&!this.paused;){this.consumedAfterSnapshot=0;const t=this._consume();this._ensureHibernation()||this._callState(t)}this.inLoop=!1}}pause(){this.paused=!0}resume(t){if(!this.paused)throw new Error("Parser was already resumed");this.paused=!1,!this.inLoop&&(this._runParsingLoop(),this.paused||t==null||t())}write(t,n,r){this.active=!0,this.preprocessor.write(t,n),this._runParsingLoop(),this.paused||r==null||r()}insertHtmlAtCurrentPos(t){this.active=!0,this.preprocessor.insertHtmlAtCurrentPos(t),this._runParsingLoop()}_ensureHibernation(){return this.preprocessor.endOfChunkHit?(this._unconsume(this.consumedAfterSnapshot),this.active=!1,!0):!1}_consume(){return this.consumedAfterSnapshot++,this.preprocessor.advance()}_unconsume(t){this.consumedAfterSnapshot-=t,this.preprocessor.retreat(t)}_reconsumeInState(t,n){this.state=t,this._callState(n)}_advanceBy(t){this.consumedAfterSnapshot+=t;for(let n=0;n0&&this._err(_e.endTagWithAttributes),t.selfClosing&&this._err(_e.endTagWithTrailingSolidus),this.handler.onEndTag(t)),this.preprocessor.dropParsedChunk()}emitCurrentComment(t){this.prepareToken(t),this.handler.onComment(t),this.preprocessor.dropParsedChunk()}emitCurrentDoctype(t){this.prepareToken(t),this.handler.onDoctype(t),this.preprocessor.dropParsedChunk()}_emitCurrentCharacterToken(t){if(this.currentCharacterToken){switch(t&&this.currentCharacterToken.location&&(this.currentCharacterToken.location.endLine=t.startLine,this.currentCharacterToken.location.endCol=t.startCol,this.currentCharacterToken.location.endOffset=t.startOffset),this.currentCharacterToken.type){case Yt.CHARACTER:{this.handler.onCharacter(this.currentCharacterToken);break}case Yt.NULL_CHARACTER:{this.handler.onNullCharacter(this.currentCharacterToken);break}case Yt.WHITESPACE_CHARACTER:{this.handler.onWhitespaceCharacter(this.currentCharacterToken);break}}this.currentCharacterToken=null}}_emitEOFToken(){const t=this.getCurrentLocation(0);t&&(t.endLine=t.startLine,t.endCol=t.startCol,t.endOffset=t.startOffset),this._emitCurrentCharacterToken(t),this.handler.onEof({type:Yt.EOF,location:t}),this.active=!1}_appendCharToCurrentCharacterToken(t,n){if(this.currentCharacterToken)if(this.currentCharacterToken.type!==t)this.currentLocation=this.getCurrentLocation(0),this._emitCurrentCharacterToken(this.currentLocation),this.preprocessor.dropParsedChunk();else{this.currentCharacterToken.chars+=n;return}this._createCharacterToken(t,n)}_emitCodePoint(t){const n=Kre(t)?Yt.WHITESPACE_CHARACTER:t===M.NULL?Yt.NULL_CHARACTER:Yt.CHARACTER;this._appendCharToCurrentCharacterToken(n,String.fromCodePoint(t))}_emitChars(t){this._appendCharToCurrentCharacterToken(Yt.CHARACTER,t)}_matchNamedCharacterReference(t){let n=null,r=0,i=!1;for(let s=0,o=Oc[0];s>=0&&(s=Wre(Oc,o,s+1,t),!(s<0));t=this._consume()){r+=1,o=Oc[s];const a=o&Ru.VALUE_LENGTH;if(a){const u=(a>>14)-1;if(t!==M.SEMICOLON&&this._isCharacterReferenceInAttribute()&&mBe(this.preprocessor.peek(1))?(n=[M.AMPERSAND],s+=u):(n=u===0?[Oc[s]&~Ru.VALUE_LENGTH]:u===1?[Oc[++s]]:[Oc[++s],Oc[++s]],r=0,i=t!==M.SEMICOLON),u===0){this._consume();break}}}return this._unconsume(r),i&&!this.preprocessor.endOfChunkHit&&this._err(_e.missingSemicolonAfterCharacterReference),this._unconsume(1),n}_isCharacterReferenceInAttribute(){return this.returnState===U.ATTRIBUTE_VALUE_DOUBLE_QUOTED||this.returnState===U.ATTRIBUTE_VALUE_SINGLE_QUOTED||this.returnState===U.ATTRIBUTE_VALUE_UNQUOTED}_flushCodePointConsumedAsCharacterReference(t){this._isCharacterReferenceInAttribute()?this.currentAttr.value+=String.fromCodePoint(t):this._emitCodePoint(t)}_callState(t){switch(this.state){case U.DATA:{this._stateData(t);break}case U.RCDATA:{this._stateRcdata(t);break}case U.RAWTEXT:{this._stateRawtext(t);break}case U.SCRIPT_DATA:{this._stateScriptData(t);break}case U.PLAINTEXT:{this._statePlaintext(t);break}case U.TAG_OPEN:{this._stateTagOpen(t);break}case U.END_TAG_OPEN:{this._stateEndTagOpen(t);break}case U.TAG_NAME:{this._stateTagName(t);break}case U.RCDATA_LESS_THAN_SIGN:{this._stateRcdataLessThanSign(t);break}case U.RCDATA_END_TAG_OPEN:{this._stateRcdataEndTagOpen(t);break}case U.RCDATA_END_TAG_NAME:{this._stateRcdataEndTagName(t);break}case U.RAWTEXT_LESS_THAN_SIGN:{this._stateRawtextLessThanSign(t);break}case U.RAWTEXT_END_TAG_OPEN:{this._stateRawtextEndTagOpen(t);break}case U.RAWTEXT_END_TAG_NAME:{this._stateRawtextEndTagName(t);break}case U.SCRIPT_DATA_LESS_THAN_SIGN:{this._stateScriptDataLessThanSign(t);break}case U.SCRIPT_DATA_END_TAG_OPEN:{this._stateScriptDataEndTagOpen(t);break}case U.SCRIPT_DATA_END_TAG_NAME:{this._stateScriptDataEndTagName(t);break}case U.SCRIPT_DATA_ESCAPE_START:{this._stateScriptDataEscapeStart(t);break}case U.SCRIPT_DATA_ESCAPE_START_DASH:{this._stateScriptDataEscapeStartDash(t);break}case U.SCRIPT_DATA_ESCAPED:{this._stateScriptDataEscaped(t);break}case U.SCRIPT_DATA_ESCAPED_DASH:{this._stateScriptDataEscapedDash(t);break}case U.SCRIPT_DATA_ESCAPED_DASH_DASH:{this._stateScriptDataEscapedDashDash(t);break}case U.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataEscapedLessThanSign(t);break}case U.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:{this._stateScriptDataEscapedEndTagOpen(t);break}case U.SCRIPT_DATA_ESCAPED_END_TAG_NAME:{this._stateScriptDataEscapedEndTagName(t);break}case U.SCRIPT_DATA_DOUBLE_ESCAPE_START:{this._stateScriptDataDoubleEscapeStart(t);break}case U.SCRIPT_DATA_DOUBLE_ESCAPED:{this._stateScriptDataDoubleEscaped(t);break}case U.SCRIPT_DATA_DOUBLE_ESCAPED_DASH:{this._stateScriptDataDoubleEscapedDash(t);break}case U.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH:{this._stateScriptDataDoubleEscapedDashDash(t);break}case U.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataDoubleEscapedLessThanSign(t);break}case U.SCRIPT_DATA_DOUBLE_ESCAPE_END:{this._stateScriptDataDoubleEscapeEnd(t);break}case U.BEFORE_ATTRIBUTE_NAME:{this._stateBeforeAttributeName(t);break}case U.ATTRIBUTE_NAME:{this._stateAttributeName(t);break}case U.AFTER_ATTRIBUTE_NAME:{this._stateAfterAttributeName(t);break}case U.BEFORE_ATTRIBUTE_VALUE:{this._stateBeforeAttributeValue(t);break}case U.ATTRIBUTE_VALUE_DOUBLE_QUOTED:{this._stateAttributeValueDoubleQuoted(t);break}case U.ATTRIBUTE_VALUE_SINGLE_QUOTED:{this._stateAttributeValueSingleQuoted(t);break}case U.ATTRIBUTE_VALUE_UNQUOTED:{this._stateAttributeValueUnquoted(t);break}case U.AFTER_ATTRIBUTE_VALUE_QUOTED:{this._stateAfterAttributeValueQuoted(t);break}case U.SELF_CLOSING_START_TAG:{this._stateSelfClosingStartTag(t);break}case U.BOGUS_COMMENT:{this._stateBogusComment(t);break}case U.MARKUP_DECLARATION_OPEN:{this._stateMarkupDeclarationOpen(t);break}case U.COMMENT_START:{this._stateCommentStart(t);break}case U.COMMENT_START_DASH:{this._stateCommentStartDash(t);break}case U.COMMENT:{this._stateComment(t);break}case U.COMMENT_LESS_THAN_SIGN:{this._stateCommentLessThanSign(t);break}case U.COMMENT_LESS_THAN_SIGN_BANG:{this._stateCommentLessThanSignBang(t);break}case U.COMMENT_LESS_THAN_SIGN_BANG_DASH:{this._stateCommentLessThanSignBangDash(t);break}case U.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:{this._stateCommentLessThanSignBangDashDash(t);break}case U.COMMENT_END_DASH:{this._stateCommentEndDash(t);break}case U.COMMENT_END:{this._stateCommentEnd(t);break}case U.COMMENT_END_BANG:{this._stateCommentEndBang(t);break}case U.DOCTYPE:{this._stateDoctype(t);break}case U.BEFORE_DOCTYPE_NAME:{this._stateBeforeDoctypeName(t);break}case U.DOCTYPE_NAME:{this._stateDoctypeName(t);break}case U.AFTER_DOCTYPE_NAME:{this._stateAfterDoctypeName(t);break}case U.AFTER_DOCTYPE_PUBLIC_KEYWORD:{this._stateAfterDoctypePublicKeyword(t);break}case U.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateBeforeDoctypePublicIdentifier(t);break}case U.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypePublicIdentifierDoubleQuoted(t);break}case U.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypePublicIdentifierSingleQuoted(t);break}case U.AFTER_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateAfterDoctypePublicIdentifier(t);break}case U.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS:{this._stateBetweenDoctypePublicAndSystemIdentifiers(t);break}case U.AFTER_DOCTYPE_SYSTEM_KEYWORD:{this._stateAfterDoctypeSystemKeyword(t);break}case U.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateBeforeDoctypeSystemIdentifier(t);break}case U.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypeSystemIdentifierDoubleQuoted(t);break}case U.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypeSystemIdentifierSingleQuoted(t);break}case U.AFTER_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateAfterDoctypeSystemIdentifier(t);break}case U.BOGUS_DOCTYPE:{this._stateBogusDoctype(t);break}case U.CDATA_SECTION:{this._stateCdataSection(t);break}case U.CDATA_SECTION_BRACKET:{this._stateCdataSectionBracket(t);break}case U.CDATA_SECTION_END:{this._stateCdataSectionEnd(t);break}case U.CHARACTER_REFERENCE:{this._stateCharacterReference(t);break}case U.NAMED_CHARACTER_REFERENCE:{this._stateNamedCharacterReference(t);break}case U.AMBIGUOUS_AMPERSAND:{this._stateAmbiguousAmpersand(t);break}case U.NUMERIC_CHARACTER_REFERENCE:{this._stateNumericCharacterReference(t);break}case U.HEXADEMICAL_CHARACTER_REFERENCE_START:{this._stateHexademicalCharacterReferenceStart(t);break}case U.HEXADEMICAL_CHARACTER_REFERENCE:{this._stateHexademicalCharacterReference(t);break}case U.DECIMAL_CHARACTER_REFERENCE:{this._stateDecimalCharacterReference(t);break}case U.NUMERIC_CHARACTER_REFERENCE_END:{this._stateNumericCharacterReferenceEnd(t);break}default:throw new Error("Unknown state")}}_stateData(t){switch(t){case M.LESS_THAN_SIGN:{this.state=U.TAG_OPEN;break}case M.AMPERSAND:{this.returnState=U.DATA,this.state=U.CHARACTER_REFERENCE;break}case M.NULL:{this._err(_e.unexpectedNullCharacter),this._emitCodePoint(t);break}case M.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateRcdata(t){switch(t){case M.AMPERSAND:{this.returnState=U.RCDATA,this.state=U.CHARACTER_REFERENCE;break}case M.LESS_THAN_SIGN:{this.state=U.RCDATA_LESS_THAN_SIGN;break}case M.NULL:{this._err(_e.unexpectedNullCharacter),this._emitChars(lr);break}case M.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateRawtext(t){switch(t){case M.LESS_THAN_SIGN:{this.state=U.RAWTEXT_LESS_THAN_SIGN;break}case M.NULL:{this._err(_e.unexpectedNullCharacter),this._emitChars(lr);break}case M.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptData(t){switch(t){case M.LESS_THAN_SIGN:{this.state=U.SCRIPT_DATA_LESS_THAN_SIGN;break}case M.NULL:{this._err(_e.unexpectedNullCharacter),this._emitChars(lr);break}case M.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_statePlaintext(t){switch(t){case M.NULL:{this._err(_e.unexpectedNullCharacter),this._emitChars(lr);break}case M.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateTagOpen(t){if(Rc(t))this._createStartTagToken(),this.state=U.TAG_NAME,this._stateTagName(t);else switch(t){case M.EXCLAMATION_MARK:{this.state=U.MARKUP_DECLARATION_OPEN;break}case M.SOLIDUS:{this.state=U.END_TAG_OPEN;break}case M.QUESTION_MARK:{this._err(_e.unexpectedQuestionMarkInsteadOfTagName),this._createCommentToken(1),this.state=U.BOGUS_COMMENT,this._stateBogusComment(t);break}case M.EOF:{this._err(_e.eofBeforeTagName),this._emitChars("<"),this._emitEOFToken();break}default:this._err(_e.invalidFirstCharacterOfTagName),this._emitChars("<"),this.state=U.DATA,this._stateData(t)}}_stateEndTagOpen(t){if(Rc(t))this._createEndTagToken(),this.state=U.TAG_NAME,this._stateTagName(t);else switch(t){case M.GREATER_THAN_SIGN:{this._err(_e.missingEndTagName),this.state=U.DATA;break}case M.EOF:{this._err(_e.eofBeforeTagName),this._emitChars("");break}case M.NULL:{this._err(_e.unexpectedNullCharacter),this.state=U.SCRIPT_DATA_ESCAPED,this._emitChars(lr);break}case M.EOF:{this._err(_e.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=U.SCRIPT_DATA_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataEscapedLessThanSign(t){t===M.SOLIDUS?this.state=U.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:Rc(t)?(this._emitChars("<"),this.state=U.SCRIPT_DATA_DOUBLE_ESCAPE_START,this._stateScriptDataDoubleEscapeStart(t)):(this._emitChars("<"),this.state=U.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataEscapedEndTagOpen(t){Rc(t)?(this.state=U.SCRIPT_DATA_ESCAPED_END_TAG_NAME,this._stateScriptDataEscapedEndTagName(t)):(this._emitChars("");break}case M.NULL:{this._err(_e.unexpectedNullCharacter),this.state=U.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(lr);break}case M.EOF:{this._err(_e.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=U.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedLessThanSign(t){t===M.SOLIDUS?(this.state=U.SCRIPT_DATA_DOUBLE_ESCAPE_END,this._emitChars("/")):(this.state=U.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(t))}_stateScriptDataDoubleEscapeEnd(t){if(this.preprocessor.startsWith(As.SCRIPT,!1)&&m7(this.preprocessor.peek(As.SCRIPT.length))){this._emitCodePoint(t);for(let n=0;n1114111)this._err(_e.characterReferenceOutsideUnicodeRange),this.charRefCode=M.REPLACEMENT_CHARACTER;else if(jre(this.charRefCode))this._err(_e.surrogateCharacterReference),this.charRefCode=M.REPLACEMENT_CHARACTER;else if(Vre(this.charRefCode))this._err(_e.noncharacterCharacterReference);else if(Ure(this.charRefCode)||this.charRefCode===M.CARRIAGE_RETURN){this._err(_e.controlCharacterReference);const n=dBe.get(this.charRefCode);n!==void 0&&(this.charRefCode=n)}this._flushCodePointConsumedAsCharacterReference(this.charRefCode),this._reconsumeInState(this.returnState,t)}}const Qre=new Set([_.DD,_.DT,_.LI,_.OPTGROUP,_.OPTION,_.P,_.RB,_.RP,_.RT,_.RTC]),g7=new Set([...Qre,_.CAPTION,_.COLGROUP,_.TBODY,_.TD,_.TFOOT,_.TH,_.THEAD,_.TR]),Nb=new Map([[_.APPLET,we.HTML],[_.CAPTION,we.HTML],[_.HTML,we.HTML],[_.MARQUEE,we.HTML],[_.OBJECT,we.HTML],[_.TABLE,we.HTML],[_.TD,we.HTML],[_.TEMPLATE,we.HTML],[_.TH,we.HTML],[_.ANNOTATION_XML,we.MATHML],[_.MI,we.MATHML],[_.MN,we.MATHML],[_.MO,we.MATHML],[_.MS,we.MATHML],[_.MTEXT,we.MATHML],[_.DESC,we.SVG],[_.FOREIGN_OBJECT,we.SVG],[_.TITLE,we.SVG]]),yBe=[_.H1,_.H2,_.H3,_.H4,_.H5,_.H6],vBe=[_.TR,_.TEMPLATE,_.HTML],_Be=[_.TBODY,_.TFOOT,_.THEAD,_.TEMPLATE,_.HTML],bBe=[_.TABLE,_.TEMPLATE,_.HTML],wBe=[_.TD,_.TH];class EBe{get currentTmplContentOrNode(){return this._isInTemplate()?this.treeAdapter.getTemplateContent(this.current):this.current}constructor(t,n,r){this.treeAdapter=n,this.handler=r,this.items=[],this.tagIDs=[],this.stackTop=-1,this.tmplCount=0,this.currentTagId=_.UNKNOWN,this.current=t}_indexOf(t){return this.items.lastIndexOf(t,this.stackTop)}_isInTemplate(){return this.currentTagId===_.TEMPLATE&&this.treeAdapter.getNamespaceURI(this.current)===we.HTML}_updateCurrentElement(){this.current=this.items[this.stackTop],this.currentTagId=this.tagIDs[this.stackTop]}push(t,n){this.stackTop++,this.items[this.stackTop]=t,this.current=t,this.tagIDs[this.stackTop]=n,this.currentTagId=n,this._isInTemplate()&&this.tmplCount++,this.handler.onItemPush(t,n,!0)}pop(){const t=this.current;this.tmplCount>0&&this._isInTemplate()&&this.tmplCount--,this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(t,!0)}replace(t,n){const r=this._indexOf(t);this.items[r]=n,r===this.stackTop&&(this.current=n)}insertAfter(t,n,r){const i=this._indexOf(t)+1;this.items.splice(i,0,n),this.tagIDs.splice(i,0,r),this.stackTop++,i===this.stackTop&&this._updateCurrentElement(),this.handler.onItemPush(this.current,this.currentTagId,i===this.stackTop)}popUntilTagNamePopped(t){let n=this.stackTop+1;do n=this.tagIDs.lastIndexOf(t,n-1);while(n>0&&this.treeAdapter.getNamespaceURI(this.items[n])!==we.HTML);this.shortenToLength(n<0?0:n)}shortenToLength(t){for(;this.stackTop>=t;){const n=this.current;this.tmplCount>0&&this._isInTemplate()&&(this.tmplCount-=1),this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(n,this.stackTop=0;r--)if(t.includes(this.tagIDs[r])&&this.treeAdapter.getNamespaceURI(this.items[r])===n)return r;return-1}clearBackTo(t,n){const r=this._indexOfTagNames(t,n);this.shortenToLength(r+1)}clearBackToTableContext(){this.clearBackTo(bBe,we.HTML)}clearBackToTableBodyContext(){this.clearBackTo(_Be,we.HTML)}clearBackToTableRowContext(){this.clearBackTo(vBe,we.HTML)}remove(t){const n=this._indexOf(t);n>=0&&(n===this.stackTop?this.pop():(this.items.splice(n,1),this.tagIDs.splice(n,1),this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(t,!1)))}tryPeekProperlyNestedBodyElement(){return this.stackTop>=1&&this.tagIDs[1]===_.BODY?this.items[1]:null}contains(t){return this._indexOf(t)>-1}getCommonAncestor(t){const n=this._indexOf(t)-1;return n>=0?this.items[n]:null}isRootHtmlElementCurrent(){return this.stackTop===0&&this.tagIDs[0]===_.HTML}hasInScope(t){for(let n=this.stackTop;n>=0;n--){const r=this.tagIDs[n],i=this.treeAdapter.getNamespaceURI(this.items[n]);if(r===t&&i===we.HTML)return!0;if(Nb.get(r)===i)return!1}return!0}hasNumberedHeaderInScope(){for(let t=this.stackTop;t>=0;t--){const n=this.tagIDs[t],r=this.treeAdapter.getNamespaceURI(this.items[t]);if(qre(n)&&r===we.HTML)return!0;if(Nb.get(n)===r)return!1}return!0}hasInListItemScope(t){for(let n=this.stackTop;n>=0;n--){const r=this.tagIDs[n],i=this.treeAdapter.getNamespaceURI(this.items[n]);if(r===t&&i===we.HTML)return!0;if((r===_.UL||r===_.OL)&&i===we.HTML||Nb.get(r)===i)return!1}return!0}hasInButtonScope(t){for(let n=this.stackTop;n>=0;n--){const r=this.tagIDs[n],i=this.treeAdapter.getNamespaceURI(this.items[n]);if(r===t&&i===we.HTML)return!0;if(r===_.BUTTON&&i===we.HTML||Nb.get(r)===i)return!1}return!0}hasInTableScope(t){for(let n=this.stackTop;n>=0;n--){const r=this.tagIDs[n];if(this.treeAdapter.getNamespaceURI(this.items[n])===we.HTML){if(r===t)return!0;if(r===_.TABLE||r===_.TEMPLATE||r===_.HTML)return!1}}return!0}hasTableBodyContextInTableScope(){for(let t=this.stackTop;t>=0;t--){const n=this.tagIDs[t];if(this.treeAdapter.getNamespaceURI(this.items[t])===we.HTML){if(n===_.TBODY||n===_.THEAD||n===_.TFOOT)return!0;if(n===_.TABLE||n===_.HTML)return!1}}return!0}hasInSelectScope(t){for(let n=this.stackTop;n>=0;n--){const r=this.tagIDs[n];if(this.treeAdapter.getNamespaceURI(this.items[n])===we.HTML){if(r===t)return!0;if(r!==_.OPTION&&r!==_.OPTGROUP)return!1}}return!0}generateImpliedEndTags(){for(;Qre.has(this.currentTagId);)this.pop()}generateImpliedEndTagsThoroughly(){for(;g7.has(this.currentTagId);)this.pop()}generateImpliedEndTagsWithExclusion(t){for(;this.currentTagId!==t&&g7.has(this.currentTagId);)this.pop()}}const CO=3;var Ra;(function(e){e[e.Marker=0]="Marker",e[e.Element=1]="Element"})(Ra=Ra||(Ra={}));const y7={type:Ra.Marker};class SBe{constructor(t){this.treeAdapter=t,this.entries=[],this.bookmark=null}_getNoahArkConditionCandidates(t,n){const r=[],i=n.length,s=this.treeAdapter.getTagName(t),o=this.treeAdapter.getNamespaceURI(t);for(let a=0;a[o.name,o.value]));let s=0;for(let o=0;oi.get(u.name)===u.value)&&(s+=1,s>=CO&&this.entries.splice(a.idx,1))}}insertMarker(){this.entries.unshift(y7)}pushElement(t,n){this._ensureNoahArkCondition(t),this.entries.unshift({type:Ra.Element,element:t,token:n})}insertElementAfterBookmark(t,n){const r=this.entries.indexOf(this.bookmark);this.entries.splice(r,0,{type:Ra.Element,element:t,token:n})}removeEntry(t){const n=this.entries.indexOf(t);n>=0&&this.entries.splice(n,1)}clearToLastMarker(){const t=this.entries.indexOf(y7);t>=0?this.entries.splice(0,t+1):this.entries.length=0}getElementEntryInScopeWithTagName(t){const n=this.entries.find(r=>r.type===Ra.Marker||this.treeAdapter.getTagName(r.element)===t);return n&&n.type===Ra.Element?n:null}getElementEntry(t){return this.entries.find(n=>n.type===Ra.Element&&n.element===t)}}function v7(e){return{nodeName:"#text",value:e,parentNode:null}}const hp={createDocument(){return{nodeName:"#document",mode:go.NO_QUIRKS,childNodes:[]}},createDocumentFragment(){return{nodeName:"#document-fragment",childNodes:[]}},createElement(e,t,n){return{nodeName:e,tagName:e,attrs:n,namespaceURI:t,childNodes:[],parentNode:null}},createCommentNode(e){return{nodeName:"#comment",data:e,parentNode:null}},appendChild(e,t){e.childNodes.push(t),t.parentNode=e},insertBefore(e,t,n){const r=e.childNodes.indexOf(n);e.childNodes.splice(r,0,t),t.parentNode=e},setTemplateContent(e,t){e.content=t},getTemplateContent(e){return e.content},setDocumentType(e,t,n,r){const i=e.childNodes.find(s=>s.nodeName==="#documentType");if(i)i.name=t,i.publicId=n,i.systemId=r;else{const s={nodeName:"#documentType",name:t,publicId:n,systemId:r,parentNode:null};hp.appendChild(e,s)}},setDocumentMode(e,t){e.mode=t},getDocumentMode(e){return e.mode},detachNode(e){if(e.parentNode){const t=e.parentNode.childNodes.indexOf(e);e.parentNode.childNodes.splice(t,1),e.parentNode=null}},insertText(e,t){if(e.childNodes.length>0){const n=e.childNodes[e.childNodes.length-1];if(hp.isTextNode(n)){n.value+=t;return}}hp.appendChild(e,v7(t))},insertTextBefore(e,t,n){const r=e.childNodes[e.childNodes.indexOf(n)-1];r&&hp.isTextNode(r)?r.value+=t:hp.insertBefore(e,v7(t),n)},adoptAttributes(e,t){const n=new Set(e.attrs.map(r=>r.name));for(let r=0;re.startsWith(n))}function PBe(e){return e.name===Xre&&e.publicId===null&&(e.systemId===null||e.systemId===TBe)}function OBe(e){if(e.name!==Xre)return go.QUIRKS;const{systemId:t}=e;if(t&&t.toLowerCase()===IBe)return go.QUIRKS;let{publicId:n}=e;if(n!==null){if(n=n.toLowerCase(),CBe.has(n))return go.QUIRKS;let r=t===null?xBe:Jre;if(_7(n,r))return go.QUIRKS;if(r=t===null?Zre:ABe,_7(n,r))return go.LIMITED_QUIRKS}return go.NO_QUIRKS}const b7={TEXT_HTML:"text/html",APPLICATION_XML:"application/xhtml+xml"},RBe="definitionurl",NBe="definitionURL",kBe=new Map(["attributeName","attributeType","baseFrequency","baseProfile","calcMode","clipPathUnits","diffuseConstant","edgeMode","filterUnits","glyphRef","gradientTransform","gradientUnits","kernelMatrix","kernelUnitLength","keyPoints","keySplines","keyTimes","lengthAdjust","limitingConeAngle","markerHeight","markerUnits","markerWidth","maskContentUnits","maskUnits","numOctaves","pathLength","patternContentUnits","patternTransform","patternUnits","pointsAtX","pointsAtY","pointsAtZ","preserveAlpha","preserveAspectRatio","primitiveUnits","refX","refY","repeatCount","repeatDur","requiredExtensions","requiredFeatures","specularConstant","specularExponent","spreadMethod","startOffset","stdDeviation","stitchTiles","surfaceScale","systemLanguage","tableValues","targetX","targetY","textLength","viewBox","viewTarget","xChannelSelector","yChannelSelector","zoomAndPan"].map(e=>[e.toLowerCase(),e])),DBe=new Map([["xlink:actuate",{prefix:"xlink",name:"actuate",namespace:we.XLINK}],["xlink:arcrole",{prefix:"xlink",name:"arcrole",namespace:we.XLINK}],["xlink:href",{prefix:"xlink",name:"href",namespace:we.XLINK}],["xlink:role",{prefix:"xlink",name:"role",namespace:we.XLINK}],["xlink:show",{prefix:"xlink",name:"show",namespace:we.XLINK}],["xlink:title",{prefix:"xlink",name:"title",namespace:we.XLINK}],["xlink:type",{prefix:"xlink",name:"type",namespace:we.XLINK}],["xml:base",{prefix:"xml",name:"base",namespace:we.XML}],["xml:lang",{prefix:"xml",name:"lang",namespace:we.XML}],["xml:space",{prefix:"xml",name:"space",namespace:we.XML}],["xmlns",{prefix:"",name:"xmlns",namespace:we.XMLNS}],["xmlns:xlink",{prefix:"xmlns",name:"xlink",namespace:we.XMLNS}]]),$Be=new Map(["altGlyph","altGlyphDef","altGlyphItem","animateColor","animateMotion","animateTransform","clipPath","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","foreignObject","glyphRef","linearGradient","radialGradient","textPath"].map(e=>[e.toLowerCase(),e])),LBe=new Set([_.B,_.BIG,_.BLOCKQUOTE,_.BODY,_.BR,_.CENTER,_.CODE,_.DD,_.DIV,_.DL,_.DT,_.EM,_.EMBED,_.H1,_.H2,_.H3,_.H4,_.H5,_.H6,_.HEAD,_.HR,_.I,_.IMG,_.LI,_.LISTING,_.MENU,_.META,_.NOBR,_.OL,_.P,_.PRE,_.RUBY,_.S,_.SMALL,_.SPAN,_.STRONG,_.STRIKE,_.SUB,_.SUP,_.TABLE,_.TT,_.U,_.UL,_.VAR]);function MBe(e){const t=e.tagID;return t===_.FONT&&e.attrs.some(({name:r})=>r===gf.COLOR||r===gf.SIZE||r===gf.FACE)||LBe.has(t)}function eie(e){for(let t=0;t0&&this._setContextModes(t,n)}onItemPop(t,n){var r,i;if(this.options.sourceCodeLocationInfo&&this._setEndLocation(t,this.currentToken),(i=(r=this.treeAdapter).onItemPop)===null||i===void 0||i.call(r,t,this.openElements.current),n){let s,o;this.openElements.stackTop===0&&this.fragmentContext?(s=this.fragmentContext,o=this.fragmentContextID):{current:s,currentTagId:o}=this.openElements,this._setContextModes(s,o)}}_setContextModes(t,n){const r=t===this.document||this.treeAdapter.getNamespaceURI(t)===we.HTML;this.currentNotInHTML=!r,this.tokenizer.inForeignNode=!r&&!this._isIntegrationPoint(n,t)}_switchToTextParsing(t,n){this._insertElement(t,we.HTML),this.tokenizer.state=n,this.originalInsertionMode=this.insertionMode,this.insertionMode=Y.TEXT}switchToPlaintextParsing(){this.insertionMode=Y.TEXT,this.originalInsertionMode=Y.IN_BODY,this.tokenizer.state=Mr.PLAINTEXT}_getAdjustedCurrentElement(){return this.openElements.stackTop===0&&this.fragmentContext?this.fragmentContext:this.openElements.current}_findFormInFragmentContext(){let t=this.fragmentContext;for(;t;){if(this.treeAdapter.getTagName(t)===le.FORM){this.formElement=t;break}t=this.treeAdapter.getParentNode(t)}}_initTokenizerForFragmentParsing(){if(!(!this.fragmentContext||this.treeAdapter.getNamespaceURI(this.fragmentContext)!==we.HTML))switch(this.fragmentContextID){case _.TITLE:case _.TEXTAREA:{this.tokenizer.state=Mr.RCDATA;break}case _.STYLE:case _.XMP:case _.IFRAME:case _.NOEMBED:case _.NOFRAMES:case _.NOSCRIPT:{this.tokenizer.state=Mr.RAWTEXT;break}case _.SCRIPT:{this.tokenizer.state=Mr.SCRIPT_DATA;break}case _.PLAINTEXT:{this.tokenizer.state=Mr.PLAINTEXT;break}}}_setDocumentType(t){const n=t.name||"",r=t.publicId||"",i=t.systemId||"";if(this.treeAdapter.setDocumentType(this.document,n,r,i),t.location){const o=this.treeAdapter.getChildNodes(this.document).find(a=>this.treeAdapter.isDocumentTypeNode(a));o&&this.treeAdapter.setNodeSourceCodeLocation(o,t.location)}}_attachElementToTree(t,n){if(this.options.sourceCodeLocationInfo){const r=n&&{...n,startTag:n};this.treeAdapter.setNodeSourceCodeLocation(t,r)}if(this._shouldFosterParentOnInsertion())this._fosterParentElement(t);else{const r=this.openElements.currentTmplContentOrNode;this.treeAdapter.appendChild(r,t)}}_appendElement(t,n){const r=this.treeAdapter.createElement(t.tagName,n,t.attrs);this._attachElementToTree(r,t.location)}_insertElement(t,n){const r=this.treeAdapter.createElement(t.tagName,n,t.attrs);this._attachElementToTree(r,t.location),this.openElements.push(r,t.tagID)}_insertFakeElement(t,n){const r=this.treeAdapter.createElement(t,we.HTML,[]);this._attachElementToTree(r,null),this.openElements.push(r,n)}_insertTemplate(t){const n=this.treeAdapter.createElement(t.tagName,we.HTML,t.attrs),r=this.treeAdapter.createDocumentFragment();this.treeAdapter.setTemplateContent(n,r),this._attachElementToTree(n,t.location),this.openElements.push(n,t.tagID),this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(r,null)}_insertFakeRootElement(){const t=this.treeAdapter.createElement(le.HTML,we.HTML,[]);this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(t,null),this.treeAdapter.appendChild(this.openElements.current,t),this.openElements.push(t,_.HTML)}_appendCommentNode(t,n){const r=this.treeAdapter.createCommentNode(t.data);this.treeAdapter.appendChild(n,r),this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(r,t.location)}_insertCharacters(t){let n,r;if(this._shouldFosterParentOnInsertion()?({parent:n,beforeElement:r}=this._findFosterParentingLocation(),r?this.treeAdapter.insertTextBefore(n,t.chars,r):this.treeAdapter.insertText(n,t.chars)):(n=this.openElements.currentTmplContentOrNode,this.treeAdapter.insertText(n,t.chars)),!t.location)return;const i=this.treeAdapter.getChildNodes(n),s=r?i.lastIndexOf(r):i.length,o=i[s-1];if(this.treeAdapter.getNodeSourceCodeLocation(o)){const{endLine:u,endCol:l,endOffset:c}=t.location;this.treeAdapter.updateNodeSourceCodeLocation(o,{endLine:u,endCol:l,endOffset:c})}else this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(o,t.location)}_adoptNodes(t,n){for(let r=this.treeAdapter.getFirstChild(t);r;r=this.treeAdapter.getFirstChild(t))this.treeAdapter.detachNode(r),this.treeAdapter.appendChild(n,r)}_setEndLocation(t,n){if(this.treeAdapter.getNodeSourceCodeLocation(t)&&n.location){const r=n.location,i=this.treeAdapter.getTagName(t),s=n.type===Yt.END_TAG&&i===n.tagName?{endTag:{...r},endLine:r.endLine,endCol:r.endCol,endOffset:r.endOffset}:{endLine:r.startLine,endCol:r.startCol,endOffset:r.startOffset};this.treeAdapter.updateNodeSourceCodeLocation(t,s)}}shouldProcessStartTagTokenInForeignContent(t){if(!this.currentNotInHTML)return!1;let n,r;return this.openElements.stackTop===0&&this.fragmentContext?(n=this.fragmentContext,r=this.fragmentContextID):{current:n,currentTagId:r}=this.openElements,t.tagID===_.SVG&&this.treeAdapter.getTagName(n)===le.ANNOTATION_XML&&this.treeAdapter.getNamespaceURI(n)===we.MATHML?!1:this.tokenizer.inForeignNode||(t.tagID===_.MGLYPH||t.tagID===_.MALIGNMARK)&&!this._isIntegrationPoint(r,n,we.HTML)}_processToken(t){switch(t.type){case Yt.CHARACTER:{this.onCharacter(t);break}case Yt.NULL_CHARACTER:{this.onNullCharacter(t);break}case Yt.COMMENT:{this.onComment(t);break}case Yt.DOCTYPE:{this.onDoctype(t);break}case Yt.START_TAG:{this._processStartTag(t);break}case Yt.END_TAG:{this.onEndTag(t);break}case Yt.EOF:{this.onEof(t);break}case Yt.WHITESPACE_CHARACTER:{this.onWhitespaceCharacter(t);break}}}_isIntegrationPoint(t,n,r){const i=this.treeAdapter.getNamespaceURI(n),s=this.treeAdapter.getAttrList(n);return UBe(t,i,s,r)}_reconstructActiveFormattingElements(){const t=this.activeFormattingElements.entries.length;if(t){const n=this.activeFormattingElements.entries.findIndex(i=>i.type===Ra.Marker||this.openElements.contains(i.element)),r=n<0?t-1:n-1;for(let i=r;i>=0;i--){const s=this.activeFormattingElements.entries[i];this._insertElement(s.token,this.treeAdapter.getNamespaceURI(s.element)),s.element=this.openElements.current}}}_closeTableCell(){this.openElements.generateImpliedEndTags(),this.openElements.popUntilTableCellPopped(),this.activeFormattingElements.clearToLastMarker(),this.insertionMode=Y.IN_ROW}_closePElement(){this.openElements.generateImpliedEndTagsWithExclusion(_.P),this.openElements.popUntilTagNamePopped(_.P)}_resetInsertionMode(){for(let t=this.openElements.stackTop;t>=0;t--)switch(t===0&&this.fragmentContext?this.fragmentContextID:this.openElements.tagIDs[t]){case _.TR:{this.insertionMode=Y.IN_ROW;return}case _.TBODY:case _.THEAD:case _.TFOOT:{this.insertionMode=Y.IN_TABLE_BODY;return}case _.CAPTION:{this.insertionMode=Y.IN_CAPTION;return}case _.COLGROUP:{this.insertionMode=Y.IN_COLUMN_GROUP;return}case _.TABLE:{this.insertionMode=Y.IN_TABLE;return}case _.BODY:{this.insertionMode=Y.IN_BODY;return}case _.FRAMESET:{this.insertionMode=Y.IN_FRAMESET;return}case _.SELECT:{this._resetInsertionModeForSelect(t);return}case _.TEMPLATE:{this.insertionMode=this.tmplInsertionModeStack[0];return}case _.HTML:{this.insertionMode=this.headElement?Y.AFTER_HEAD:Y.BEFORE_HEAD;return}case _.TD:case _.TH:{if(t>0){this.insertionMode=Y.IN_CELL;return}break}case _.HEAD:{if(t>0){this.insertionMode=Y.IN_HEAD;return}break}}this.insertionMode=Y.IN_BODY}_resetInsertionModeForSelect(t){if(t>0)for(let n=t-1;n>0;n--){const r=this.openElements.tagIDs[n];if(r===_.TEMPLATE)break;if(r===_.TABLE){this.insertionMode=Y.IN_SELECT_IN_TABLE;return}}this.insertionMode=Y.IN_SELECT}_isElementCausesFosterParenting(t){return nie.has(t)}_shouldFosterParentOnInsertion(){return this.fosterParentingEnabled&&this._isElementCausesFosterParenting(this.openElements.currentTagId)}_findFosterParentingLocation(){for(let t=this.openElements.stackTop;t>=0;t--){const n=this.openElements.items[t];switch(this.openElements.tagIDs[t]){case _.TEMPLATE:{if(this.treeAdapter.getNamespaceURI(n)===we.HTML)return{parent:this.treeAdapter.getTemplateContent(n),beforeElement:null};break}case _.TABLE:{const r=this.treeAdapter.getParentNode(n);return r?{parent:r,beforeElement:n}:{parent:this.openElements.items[t-1],beforeElement:null}}}}return{parent:this.openElements.items[0],beforeElement:null}}_fosterParentElement(t){const n=this._findFosterParentingLocation();n.beforeElement?this.treeAdapter.insertBefore(n.parent,t,n.beforeElement):this.treeAdapter.appendChild(n.parent,t)}_isSpecialElement(t,n){const r=this.treeAdapter.getNamespaceURI(t);return fBe[r].has(n)}onCharacter(t){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){wUe(this,t);return}switch(this.insertionMode){case Y.INITIAL:{T0(this,t);break}case Y.BEFORE_HTML:{Oy(this,t);break}case Y.BEFORE_HEAD:{Ry(this,t);break}case Y.IN_HEAD:{Ny(this,t);break}case Y.IN_HEAD_NO_SCRIPT:{ky(this,t);break}case Y.AFTER_HEAD:{Dy(this,t);break}case Y.IN_BODY:case Y.IN_CAPTION:case Y.IN_CELL:case Y.IN_TEMPLATE:{iie(this,t);break}case Y.TEXT:case Y.IN_SELECT:case Y.IN_SELECT_IN_TABLE:{this._insertCharacters(t);break}case Y.IN_TABLE:case Y.IN_TABLE_BODY:case Y.IN_ROW:{AO(this,t);break}case Y.IN_TABLE_TEXT:{cie(this,t);break}case Y.IN_COLUMN_GROUP:{BT(this,t);break}case Y.AFTER_BODY:{jT(this,t);break}case Y.AFTER_AFTER_BODY:{Fw(this,t);break}}}onNullCharacter(t){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){bUe(this,t);return}switch(this.insertionMode){case Y.INITIAL:{T0(this,t);break}case Y.BEFORE_HTML:{Oy(this,t);break}case Y.BEFORE_HEAD:{Ry(this,t);break}case Y.IN_HEAD:{Ny(this,t);break}case Y.IN_HEAD_NO_SCRIPT:{ky(this,t);break}case Y.AFTER_HEAD:{Dy(this,t);break}case Y.TEXT:{this._insertCharacters(t);break}case Y.IN_TABLE:case Y.IN_TABLE_BODY:case Y.IN_ROW:{AO(this,t);break}case Y.IN_COLUMN_GROUP:{BT(this,t);break}case Y.AFTER_BODY:{jT(this,t);break}case Y.AFTER_AFTER_BODY:{Fw(this,t);break}}}onComment(t){if(this.skipNextNewLine=!1,this.currentNotInHTML){kN(this,t);return}switch(this.insertionMode){case Y.INITIAL:case Y.BEFORE_HTML:case Y.BEFORE_HEAD:case Y.IN_HEAD:case Y.IN_HEAD_NO_SCRIPT:case Y.AFTER_HEAD:case Y.IN_BODY:case Y.IN_TABLE:case Y.IN_CAPTION:case Y.IN_COLUMN_GROUP:case Y.IN_TABLE_BODY:case Y.IN_ROW:case Y.IN_CELL:case Y.IN_SELECT:case Y.IN_SELECT_IN_TABLE:case Y.IN_TEMPLATE:case Y.IN_FRAMESET:case Y.AFTER_FRAMESET:{kN(this,t);break}case Y.IN_TABLE_TEXT:{I0(this,t);break}case Y.AFTER_BODY:{JBe(this,t);break}case Y.AFTER_AFTER_BODY:case Y.AFTER_AFTER_FRAMESET:{ZBe(this,t);break}}}onDoctype(t){switch(this.skipNextNewLine=!1,this.insertionMode){case Y.INITIAL:{eje(this,t);break}case Y.BEFORE_HEAD:case Y.IN_HEAD:case Y.IN_HEAD_NO_SCRIPT:case Y.AFTER_HEAD:{this._err(t,_e.misplacedDoctype);break}case Y.IN_TABLE_TEXT:{I0(this,t);break}}}onStartTag(t){this.skipNextNewLine=!1,this.currentToken=t,this._processStartTag(t),t.selfClosing&&!t.ackSelfClosing&&this._err(t,_e.nonVoidHtmlElementStartTagWithTrailingSolidus)}_processStartTag(t){this.shouldProcessStartTagTokenInForeignContent(t)?EUe(this,t):this._startTagOutsideForeignContent(t)}_startTagOutsideForeignContent(t){switch(this.insertionMode){case Y.INITIAL:{T0(this,t);break}case Y.BEFORE_HTML:{tje(this,t);break}case Y.BEFORE_HEAD:{rje(this,t);break}case Y.IN_HEAD:{nu(this,t);break}case Y.IN_HEAD_NO_SCRIPT:{oje(this,t);break}case Y.AFTER_HEAD:{uje(this,t);break}case Y.IN_BODY:{ls(this,t);break}case Y.IN_TABLE:{zm(this,t);break}case Y.IN_TABLE_TEXT:{I0(this,t);break}case Y.IN_CAPTION:{iUe(this,t);break}case Y.IN_COLUMN_GROUP:{w6(this,t);break}case Y.IN_TABLE_BODY:{CC(this,t);break}case Y.IN_ROW:{AC(this,t);break}case Y.IN_CELL:{aUe(this,t);break}case Y.IN_SELECT:{hie(this,t);break}case Y.IN_SELECT_IN_TABLE:{lUe(this,t);break}case Y.IN_TEMPLATE:{fUe(this,t);break}case Y.AFTER_BODY:{hUe(this,t);break}case Y.IN_FRAMESET:{pUe(this,t);break}case Y.AFTER_FRAMESET:{gUe(this,t);break}case Y.AFTER_AFTER_BODY:{vUe(this,t);break}case Y.AFTER_AFTER_FRAMESET:{_Ue(this,t);break}}}onEndTag(t){this.skipNextNewLine=!1,this.currentToken=t,this.currentNotInHTML?SUe(this,t):this._endTagOutsideForeignContent(t)}_endTagOutsideForeignContent(t){switch(this.insertionMode){case Y.INITIAL:{T0(this,t);break}case Y.BEFORE_HTML:{nje(this,t);break}case Y.BEFORE_HEAD:{ije(this,t);break}case Y.IN_HEAD:{sje(this,t);break}case Y.IN_HEAD_NO_SCRIPT:{aje(this,t);break}case Y.AFTER_HEAD:{lje(this,t);break}case Y.IN_BODY:{xC(this,t);break}case Y.TEXT:{Yje(this,t);break}case Y.IN_TABLE:{Av(this,t);break}case Y.IN_TABLE_TEXT:{I0(this,t);break}case Y.IN_CAPTION:{sUe(this,t);break}case Y.IN_COLUMN_GROUP:{oUe(this,t);break}case Y.IN_TABLE_BODY:{DN(this,t);break}case Y.IN_ROW:{die(this,t);break}case Y.IN_CELL:{uUe(this,t);break}case Y.IN_SELECT:{pie(this,t);break}case Y.IN_SELECT_IN_TABLE:{cUe(this,t);break}case Y.IN_TEMPLATE:{dUe(this,t);break}case Y.AFTER_BODY:{gie(this,t);break}case Y.IN_FRAMESET:{mUe(this,t);break}case Y.AFTER_FRAMESET:{yUe(this,t);break}case Y.AFTER_AFTER_BODY:{Fw(this,t);break}}}onEof(t){switch(this.insertionMode){case Y.INITIAL:{T0(this,t);break}case Y.BEFORE_HTML:{Oy(this,t);break}case Y.BEFORE_HEAD:{Ry(this,t);break}case Y.IN_HEAD:{Ny(this,t);break}case Y.IN_HEAD_NO_SCRIPT:{ky(this,t);break}case Y.AFTER_HEAD:{Dy(this,t);break}case Y.IN_BODY:case Y.IN_TABLE:case Y.IN_CAPTION:case Y.IN_COLUMN_GROUP:case Y.IN_TABLE_BODY:case Y.IN_ROW:case Y.IN_CELL:case Y.IN_SELECT:case Y.IN_SELECT_IN_TABLE:{uie(this,t);break}case Y.TEXT:{Kje(this,t);break}case Y.IN_TABLE_TEXT:{I0(this,t);break}case Y.IN_TEMPLATE:{mie(this,t);break}case Y.AFTER_BODY:case Y.IN_FRAMESET:case Y.AFTER_FRAMESET:case Y.AFTER_AFTER_BODY:case Y.AFTER_AFTER_FRAMESET:{b6(this,t);break}}}onWhitespaceCharacter(t){if(this.skipNextNewLine&&(this.skipNextNewLine=!1,t.chars.charCodeAt(0)===M.LINE_FEED)){if(t.chars.length===1)return;t.chars=t.chars.substr(1)}if(this.tokenizer.inForeignNode){this._insertCharacters(t);return}switch(this.insertionMode){case Y.IN_HEAD:case Y.IN_HEAD_NO_SCRIPT:case Y.AFTER_HEAD:case Y.TEXT:case Y.IN_COLUMN_GROUP:case Y.IN_SELECT:case Y.IN_SELECT_IN_TABLE:case Y.IN_FRAMESET:case Y.AFTER_FRAMESET:{this._insertCharacters(t);break}case Y.IN_BODY:case Y.IN_CAPTION:case Y.IN_CELL:case Y.IN_TEMPLATE:case Y.AFTER_BODY:case Y.AFTER_AFTER_BODY:case Y.AFTER_AFTER_FRAMESET:{rie(this,t);break}case Y.IN_TABLE:case Y.IN_TABLE_BODY:case Y.IN_ROW:{AO(this,t);break}case Y.IN_TABLE_TEXT:{lie(this,t);break}}}};function qBe(e,t){let n=e.activeFormattingElements.getElementEntryInScopeWithTagName(t.tagName);return n?e.openElements.contains(n.element)?e.openElements.hasInScope(t.tagID)||(n=null):(e.activeFormattingElements.removeEntry(n),n=null):aie(e,t),n}function GBe(e,t){let n=null,r=e.openElements.stackTop;for(;r>=0;r--){const i=e.openElements.items[r];if(i===t.element)break;e._isSpecialElement(i,e.openElements.tagIDs[r])&&(n=i)}return n||(e.openElements.shortenToLength(r<0?0:r),e.activeFormattingElements.removeEntry(t)),n}function YBe(e,t,n){let r=t,i=e.openElements.getCommonAncestor(t);for(let s=0,o=i;o!==n;s++,o=i){i=e.openElements.getCommonAncestor(o);const a=e.activeFormattingElements.getElementEntry(o),u=a&&s>=HBe;!a||u?(u&&e.activeFormattingElements.removeEntry(a),e.openElements.remove(o)):(o=KBe(e,a),r===t&&(e.activeFormattingElements.bookmark=a),e.treeAdapter.detachNode(r),e.treeAdapter.appendChild(o,r),r=o)}return r}function KBe(e,t){const n=e.treeAdapter.getNamespaceURI(t.element),r=e.treeAdapter.createElement(t.token.tagName,n,t.token.attrs);return e.openElements.replace(t.element,r),t.element=r,r}function QBe(e,t,n){const r=e.treeAdapter.getTagName(t),i=Og(r);if(e._isElementCausesFosterParenting(i))e._fosterParentElement(n);else{const s=e.treeAdapter.getNamespaceURI(t);i===_.TEMPLATE&&s===we.HTML&&(t=e.treeAdapter.getTemplateContent(t)),e.treeAdapter.appendChild(t,n)}}function XBe(e,t,n){const r=e.treeAdapter.getNamespaceURI(n.element),{token:i}=n,s=e.treeAdapter.createElement(i.tagName,r,i.attrs);e._adoptNodes(t,s),e.treeAdapter.appendChild(t,s),e.activeFormattingElements.insertElementAfterBookmark(s,i),e.activeFormattingElements.removeEntry(n),e.openElements.remove(n.element),e.openElements.insertAfter(t,s,i.tagID)}function _6(e,t){for(let n=0;n=n;r--)e._setEndLocation(e.openElements.items[r],t);if(!e.fragmentContext&&e.openElements.stackTop>=0){const r=e.openElements.items[0],i=e.treeAdapter.getNodeSourceCodeLocation(r);if(i&&!i.endTag&&(e._setEndLocation(r,t),e.openElements.stackTop>=1)){const s=e.openElements.items[1],o=e.treeAdapter.getNodeSourceCodeLocation(s);o&&!o.endTag&&e._setEndLocation(s,t)}}}}function eje(e,t){e._setDocumentType(t);const n=t.forceQuirks?go.QUIRKS:OBe(t);PBe(t)||e._err(t,_e.nonConformingDoctype),e.treeAdapter.setDocumentMode(e.document,n),e.insertionMode=Y.BEFORE_HTML}function T0(e,t){e._err(t,_e.missingDoctype,!0),e.treeAdapter.setDocumentMode(e.document,go.QUIRKS),e.insertionMode=Y.BEFORE_HTML,e._processToken(t)}function tje(e,t){t.tagID===_.HTML?(e._insertElement(t,we.HTML),e.insertionMode=Y.BEFORE_HEAD):Oy(e,t)}function nje(e,t){const n=t.tagID;(n===_.HTML||n===_.HEAD||n===_.BODY||n===_.BR)&&Oy(e,t)}function Oy(e,t){e._insertFakeRootElement(),e.insertionMode=Y.BEFORE_HEAD,e._processToken(t)}function rje(e,t){switch(t.tagID){case _.HTML:{ls(e,t);break}case _.HEAD:{e._insertElement(t,we.HTML),e.headElement=e.openElements.current,e.insertionMode=Y.IN_HEAD;break}default:Ry(e,t)}}function ije(e,t){const n=t.tagID;n===_.HEAD||n===_.BODY||n===_.HTML||n===_.BR?Ry(e,t):e._err(t,_e.endTagWithoutMatchingOpenElement)}function Ry(e,t){e._insertFakeElement(le.HEAD,_.HEAD),e.headElement=e.openElements.current,e.insertionMode=Y.IN_HEAD,e._processToken(t)}function nu(e,t){switch(t.tagID){case _.HTML:{ls(e,t);break}case _.BASE:case _.BASEFONT:case _.BGSOUND:case _.LINK:case _.META:{e._appendElement(t,we.HTML),t.ackSelfClosing=!0;break}case _.TITLE:{e._switchToTextParsing(t,Mr.RCDATA);break}case _.NOSCRIPT:{e.options.scriptingEnabled?e._switchToTextParsing(t,Mr.RAWTEXT):(e._insertElement(t,we.HTML),e.insertionMode=Y.IN_HEAD_NO_SCRIPT);break}case _.NOFRAMES:case _.STYLE:{e._switchToTextParsing(t,Mr.RAWTEXT);break}case _.SCRIPT:{e._switchToTextParsing(t,Mr.SCRIPT_DATA);break}case _.TEMPLATE:{e._insertTemplate(t),e.activeFormattingElements.insertMarker(),e.framesetOk=!1,e.insertionMode=Y.IN_TEMPLATE,e.tmplInsertionModeStack.unshift(Y.IN_TEMPLATE);break}case _.HEAD:{e._err(t,_e.misplacedStartTagForHeadElement);break}default:Ny(e,t)}}function sje(e,t){switch(t.tagID){case _.HEAD:{e.openElements.pop(),e.insertionMode=Y.AFTER_HEAD;break}case _.BODY:case _.BR:case _.HTML:{Ny(e,t);break}case _.TEMPLATE:{Fh(e,t);break}default:e._err(t,_e.endTagWithoutMatchingOpenElement)}}function Fh(e,t){e.openElements.tmplCount>0?(e.openElements.generateImpliedEndTagsThoroughly(),e.openElements.currentTagId!==_.TEMPLATE&&e._err(t,_e.closingOfElementWithOpenChildElements),e.openElements.popUntilTagNamePopped(_.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode()):e._err(t,_e.endTagWithoutMatchingOpenElement)}function Ny(e,t){e.openElements.pop(),e.insertionMode=Y.AFTER_HEAD,e._processToken(t)}function oje(e,t){switch(t.tagID){case _.HTML:{ls(e,t);break}case _.BASEFONT:case _.BGSOUND:case _.HEAD:case _.LINK:case _.META:case _.NOFRAMES:case _.STYLE:{nu(e,t);break}case _.NOSCRIPT:{e._err(t,_e.nestedNoscriptInHead);break}default:ky(e,t)}}function aje(e,t){switch(t.tagID){case _.NOSCRIPT:{e.openElements.pop(),e.insertionMode=Y.IN_HEAD;break}case _.BR:{ky(e,t);break}default:e._err(t,_e.endTagWithoutMatchingOpenElement)}}function ky(e,t){const n=t.type===Yt.EOF?_e.openElementsLeftAfterEof:_e.disallowedContentInNoscriptInHead;e._err(t,n),e.openElements.pop(),e.insertionMode=Y.IN_HEAD,e._processToken(t)}function uje(e,t){switch(t.tagID){case _.HTML:{ls(e,t);break}case _.BODY:{e._insertElement(t,we.HTML),e.framesetOk=!1,e.insertionMode=Y.IN_BODY;break}case _.FRAMESET:{e._insertElement(t,we.HTML),e.insertionMode=Y.IN_FRAMESET;break}case _.BASE:case _.BASEFONT:case _.BGSOUND:case _.LINK:case _.META:case _.NOFRAMES:case _.SCRIPT:case _.STYLE:case _.TEMPLATE:case _.TITLE:{e._err(t,_e.abandonedHeadElementChild),e.openElements.push(e.headElement,_.HEAD),nu(e,t),e.openElements.remove(e.headElement);break}case _.HEAD:{e._err(t,_e.misplacedStartTagForHeadElement);break}default:Dy(e,t)}}function lje(e,t){switch(t.tagID){case _.BODY:case _.HTML:case _.BR:{Dy(e,t);break}case _.TEMPLATE:{Fh(e,t);break}default:e._err(t,_e.endTagWithoutMatchingOpenElement)}}function Dy(e,t){e._insertFakeElement(le.BODY,_.BODY),e.insertionMode=Y.IN_BODY,IC(e,t)}function IC(e,t){switch(t.type){case Yt.CHARACTER:{iie(e,t);break}case Yt.WHITESPACE_CHARACTER:{rie(e,t);break}case Yt.COMMENT:{kN(e,t);break}case Yt.START_TAG:{ls(e,t);break}case Yt.END_TAG:{xC(e,t);break}case Yt.EOF:{uie(e,t);break}}}function rie(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t)}function iie(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t),e.framesetOk=!1}function cje(e,t){e.openElements.tmplCount===0&&e.treeAdapter.adoptAttributes(e.openElements.items[0],t.attrs)}function fje(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e.openElements.tmplCount===0&&(e.framesetOk=!1,e.treeAdapter.adoptAttributes(n,t.attrs))}function dje(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();e.framesetOk&&n&&(e.treeAdapter.detachNode(n),e.openElements.popAllUpToHtmlElement(),e._insertElement(t,we.HTML),e.insertionMode=Y.IN_FRAMESET)}function hje(e,t){e.openElements.hasInButtonScope(_.P)&&e._closePElement(),e._insertElement(t,we.HTML)}function pje(e,t){e.openElements.hasInButtonScope(_.P)&&e._closePElement(),qre(e.openElements.currentTagId)&&e.openElements.pop(),e._insertElement(t,we.HTML)}function mje(e,t){e.openElements.hasInButtonScope(_.P)&&e._closePElement(),e._insertElement(t,we.HTML),e.skipNextNewLine=!0,e.framesetOk=!1}function gje(e,t){const n=e.openElements.tmplCount>0;(!e.formElement||n)&&(e.openElements.hasInButtonScope(_.P)&&e._closePElement(),e._insertElement(t,we.HTML),n||(e.formElement=e.openElements.current))}function yje(e,t){e.framesetOk=!1;const n=t.tagID;for(let r=e.openElements.stackTop;r>=0;r--){const i=e.openElements.tagIDs[r];if(n===_.LI&&i===_.LI||(n===_.DD||n===_.DT)&&(i===_.DD||i===_.DT)){e.openElements.generateImpliedEndTagsWithExclusion(i),e.openElements.popUntilTagNamePopped(i);break}if(i!==_.ADDRESS&&i!==_.DIV&&i!==_.P&&e._isSpecialElement(e.openElements.items[r],i))break}e.openElements.hasInButtonScope(_.P)&&e._closePElement(),e._insertElement(t,we.HTML)}function vje(e,t){e.openElements.hasInButtonScope(_.P)&&e._closePElement(),e._insertElement(t,we.HTML),e.tokenizer.state=Mr.PLAINTEXT}function _je(e,t){e.openElements.hasInScope(_.BUTTON)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(_.BUTTON)),e._reconstructActiveFormattingElements(),e._insertElement(t,we.HTML),e.framesetOk=!1}function bje(e,t){const n=e.activeFormattingElements.getElementEntryInScopeWithTagName(le.A);n&&(_6(e,t),e.openElements.remove(n.element),e.activeFormattingElements.removeEntry(n)),e._reconstructActiveFormattingElements(),e._insertElement(t,we.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function wje(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,we.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function Eje(e,t){e._reconstructActiveFormattingElements(),e.openElements.hasInScope(_.NOBR)&&(_6(e,t),e._reconstructActiveFormattingElements()),e._insertElement(t,we.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function Sje(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,we.HTML),e.activeFormattingElements.insertMarker(),e.framesetOk=!1}function Tje(e,t){e.treeAdapter.getDocumentMode(e.document)!==go.QUIRKS&&e.openElements.hasInButtonScope(_.P)&&e._closePElement(),e._insertElement(t,we.HTML),e.framesetOk=!1,e.insertionMode=Y.IN_TABLE}function sie(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,we.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function oie(e){const t=zre(e,gf.TYPE);return t!=null&&t.toLowerCase()===VBe}function Ije(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,we.HTML),oie(t)||(e.framesetOk=!1),t.ackSelfClosing=!0}function xje(e,t){e._appendElement(t,we.HTML),t.ackSelfClosing=!0}function Cje(e,t){e.openElements.hasInButtonScope(_.P)&&e._closePElement(),e._appendElement(t,we.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function Aje(e,t){t.tagName=le.IMG,t.tagID=_.IMG,sie(e,t)}function Pje(e,t){e._insertElement(t,we.HTML),e.skipNextNewLine=!0,e.tokenizer.state=Mr.RCDATA,e.originalInsertionMode=e.insertionMode,e.framesetOk=!1,e.insertionMode=Y.TEXT}function Oje(e,t){e.openElements.hasInButtonScope(_.P)&&e._closePElement(),e._reconstructActiveFormattingElements(),e.framesetOk=!1,e._switchToTextParsing(t,Mr.RAWTEXT)}function Rje(e,t){e.framesetOk=!1,e._switchToTextParsing(t,Mr.RAWTEXT)}function S7(e,t){e._switchToTextParsing(t,Mr.RAWTEXT)}function Nje(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,we.HTML),e.framesetOk=!1,e.insertionMode=e.insertionMode===Y.IN_TABLE||e.insertionMode===Y.IN_CAPTION||e.insertionMode===Y.IN_TABLE_BODY||e.insertionMode===Y.IN_ROW||e.insertionMode===Y.IN_CELL?Y.IN_SELECT_IN_TABLE:Y.IN_SELECT}function kje(e,t){e.openElements.currentTagId===_.OPTION&&e.openElements.pop(),e._reconstructActiveFormattingElements(),e._insertElement(t,we.HTML)}function Dje(e,t){e.openElements.hasInScope(_.RUBY)&&e.openElements.generateImpliedEndTags(),e._insertElement(t,we.HTML)}function $je(e,t){e.openElements.hasInScope(_.RUBY)&&e.openElements.generateImpliedEndTagsWithExclusion(_.RTC),e._insertElement(t,we.HTML)}function Lje(e,t){e._reconstructActiveFormattingElements(),eie(t),v6(t),t.selfClosing?e._appendElement(t,we.MATHML):e._insertElement(t,we.MATHML),t.ackSelfClosing=!0}function Mje(e,t){e._reconstructActiveFormattingElements(),tie(t),v6(t),t.selfClosing?e._appendElement(t,we.SVG):e._insertElement(t,we.SVG),t.ackSelfClosing=!0}function T7(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,we.HTML)}function ls(e,t){switch(t.tagID){case _.I:case _.S:case _.B:case _.U:case _.EM:case _.TT:case _.BIG:case _.CODE:case _.FONT:case _.SMALL:case _.STRIKE:case _.STRONG:{wje(e,t);break}case _.A:{bje(e,t);break}case _.H1:case _.H2:case _.H3:case _.H4:case _.H5:case _.H6:{pje(e,t);break}case _.P:case _.DL:case _.OL:case _.UL:case _.DIV:case _.DIR:case _.NAV:case _.MAIN:case _.MENU:case _.ASIDE:case _.CENTER:case _.FIGURE:case _.FOOTER:case _.HEADER:case _.HGROUP:case _.DIALOG:case _.DETAILS:case _.ADDRESS:case _.ARTICLE:case _.SECTION:case _.SUMMARY:case _.FIELDSET:case _.BLOCKQUOTE:case _.FIGCAPTION:{hje(e,t);break}case _.LI:case _.DD:case _.DT:{yje(e,t);break}case _.BR:case _.IMG:case _.WBR:case _.AREA:case _.EMBED:case _.KEYGEN:{sie(e,t);break}case _.HR:{Cje(e,t);break}case _.RB:case _.RTC:{Dje(e,t);break}case _.RT:case _.RP:{$je(e,t);break}case _.PRE:case _.LISTING:{mje(e,t);break}case _.XMP:{Oje(e,t);break}case _.SVG:{Mje(e,t);break}case _.HTML:{cje(e,t);break}case _.BASE:case _.LINK:case _.META:case _.STYLE:case _.TITLE:case _.SCRIPT:case _.BGSOUND:case _.BASEFONT:case _.TEMPLATE:{nu(e,t);break}case _.BODY:{fje(e,t);break}case _.FORM:{gje(e,t);break}case _.NOBR:{Eje(e,t);break}case _.MATH:{Lje(e,t);break}case _.TABLE:{Tje(e,t);break}case _.INPUT:{Ije(e,t);break}case _.PARAM:case _.TRACK:case _.SOURCE:{xje(e,t);break}case _.IMAGE:{Aje(e,t);break}case _.BUTTON:{_je(e,t);break}case _.APPLET:case _.OBJECT:case _.MARQUEE:{Sje(e,t);break}case _.IFRAME:{Rje(e,t);break}case _.SELECT:{Nje(e,t);break}case _.OPTION:case _.OPTGROUP:{kje(e,t);break}case _.NOEMBED:{S7(e,t);break}case _.FRAMESET:{dje(e,t);break}case _.TEXTAREA:{Pje(e,t);break}case _.NOSCRIPT:{e.options.scriptingEnabled?S7(e,t):T7(e,t);break}case _.PLAINTEXT:{vje(e,t);break}case _.COL:case _.TH:case _.TD:case _.TR:case _.HEAD:case _.FRAME:case _.TBODY:case _.TFOOT:case _.THEAD:case _.CAPTION:case _.COLGROUP:break;default:T7(e,t)}}function Fje(e,t){if(e.openElements.hasInScope(_.BODY)&&(e.insertionMode=Y.AFTER_BODY,e.options.sourceCodeLocationInfo)){const n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e._setEndLocation(n,t)}}function Bje(e,t){e.openElements.hasInScope(_.BODY)&&(e.insertionMode=Y.AFTER_BODY,gie(e,t))}function jje(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n))}function Uje(e){const t=e.openElements.tmplCount>0,{formElement:n}=e;t||(e.formElement=null),(n||t)&&e.openElements.hasInScope(_.FORM)&&(e.openElements.generateImpliedEndTags(),t?e.openElements.popUntilTagNamePopped(_.FORM):n&&e.openElements.remove(n))}function Vje(e){e.openElements.hasInButtonScope(_.P)||e._insertFakeElement(le.P,_.P),e._closePElement()}function zje(e){e.openElements.hasInListItemScope(_.LI)&&(e.openElements.generateImpliedEndTagsWithExclusion(_.LI),e.openElements.popUntilTagNamePopped(_.LI))}function Hje(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTagsWithExclusion(n),e.openElements.popUntilTagNamePopped(n))}function Wje(e){e.openElements.hasNumberedHeaderInScope()&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilNumberedHeaderPopped())}function qje(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker())}function Gje(e){e._reconstructActiveFormattingElements(),e._insertFakeElement(le.BR,_.BR),e.openElements.pop(),e.framesetOk=!1}function aie(e,t){const n=t.tagName,r=t.tagID;for(let i=e.openElements.stackTop;i>0;i--){const s=e.openElements.items[i],o=e.openElements.tagIDs[i];if(r===o&&(r!==_.UNKNOWN||e.treeAdapter.getTagName(s)===n)){e.openElements.generateImpliedEndTagsWithExclusion(r),e.openElements.stackTop>=i&&e.openElements.shortenToLength(i);break}if(e._isSpecialElement(s,o))break}}function xC(e,t){switch(t.tagID){case _.A:case _.B:case _.I:case _.S:case _.U:case _.EM:case _.TT:case _.BIG:case _.CODE:case _.FONT:case _.NOBR:case _.SMALL:case _.STRIKE:case _.STRONG:{_6(e,t);break}case _.P:{Vje(e);break}case _.DL:case _.UL:case _.OL:case _.DIR:case _.DIV:case _.NAV:case _.PRE:case _.MAIN:case _.MENU:case _.ASIDE:case _.BUTTON:case _.CENTER:case _.FIGURE:case _.FOOTER:case _.HEADER:case _.HGROUP:case _.DIALOG:case _.ADDRESS:case _.ARTICLE:case _.DETAILS:case _.SECTION:case _.SUMMARY:case _.LISTING:case _.FIELDSET:case _.BLOCKQUOTE:case _.FIGCAPTION:{jje(e,t);break}case _.LI:{zje(e);break}case _.DD:case _.DT:{Hje(e,t);break}case _.H1:case _.H2:case _.H3:case _.H4:case _.H5:case _.H6:{Wje(e);break}case _.BR:{Gje(e);break}case _.BODY:{Fje(e,t);break}case _.HTML:{Bje(e,t);break}case _.FORM:{Uje(e);break}case _.APPLET:case _.OBJECT:case _.MARQUEE:{qje(e,t);break}case _.TEMPLATE:{Fh(e,t);break}default:aie(e,t)}}function uie(e,t){e.tmplInsertionModeStack.length>0?mie(e,t):b6(e,t)}function Yje(e,t){var n;t.tagID===_.SCRIPT&&((n=e.scriptHandler)===null||n===void 0||n.call(e,e.openElements.current)),e.openElements.pop(),e.insertionMode=e.originalInsertionMode}function Kje(e,t){e._err(t,_e.eofInElementThatCanContainOnlyText),e.openElements.pop(),e.insertionMode=e.originalInsertionMode,e.onEof(t)}function AO(e,t){if(nie.has(e.openElements.currentTagId))switch(e.pendingCharacterTokens.length=0,e.hasNonWhitespacePendingCharacterToken=!1,e.originalInsertionMode=e.insertionMode,e.insertionMode=Y.IN_TABLE_TEXT,t.type){case Yt.CHARACTER:{cie(e,t);break}case Yt.WHITESPACE_CHARACTER:{lie(e,t);break}}else Z_(e,t)}function Qje(e,t){e.openElements.clearBackToTableContext(),e.activeFormattingElements.insertMarker(),e._insertElement(t,we.HTML),e.insertionMode=Y.IN_CAPTION}function Xje(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,we.HTML),e.insertionMode=Y.IN_COLUMN_GROUP}function Jje(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(le.COLGROUP,_.COLGROUP),e.insertionMode=Y.IN_COLUMN_GROUP,w6(e,t)}function Zje(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,we.HTML),e.insertionMode=Y.IN_TABLE_BODY}function eUe(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(le.TBODY,_.TBODY),e.insertionMode=Y.IN_TABLE_BODY,CC(e,t)}function tUe(e,t){e.openElements.hasInTableScope(_.TABLE)&&(e.openElements.popUntilTagNamePopped(_.TABLE),e._resetInsertionMode(),e._processStartTag(t))}function nUe(e,t){oie(t)?e._appendElement(t,we.HTML):Z_(e,t),t.ackSelfClosing=!0}function rUe(e,t){!e.formElement&&e.openElements.tmplCount===0&&(e._insertElement(t,we.HTML),e.formElement=e.openElements.current,e.openElements.pop())}function zm(e,t){switch(t.tagID){case _.TD:case _.TH:case _.TR:{eUe(e,t);break}case _.STYLE:case _.SCRIPT:case _.TEMPLATE:{nu(e,t);break}case _.COL:{Jje(e,t);break}case _.FORM:{rUe(e,t);break}case _.TABLE:{tUe(e,t);break}case _.TBODY:case _.TFOOT:case _.THEAD:{Zje(e,t);break}case _.INPUT:{nUe(e,t);break}case _.CAPTION:{Qje(e,t);break}case _.COLGROUP:{Xje(e,t);break}default:Z_(e,t)}}function Av(e,t){switch(t.tagID){case _.TABLE:{e.openElements.hasInTableScope(_.TABLE)&&(e.openElements.popUntilTagNamePopped(_.TABLE),e._resetInsertionMode());break}case _.TEMPLATE:{Fh(e,t);break}case _.BODY:case _.CAPTION:case _.COL:case _.COLGROUP:case _.HTML:case _.TBODY:case _.TD:case _.TFOOT:case _.TH:case _.THEAD:case _.TR:break;default:Z_(e,t)}}function Z_(e,t){const n=e.fosterParentingEnabled;e.fosterParentingEnabled=!0,IC(e,t),e.fosterParentingEnabled=n}function lie(e,t){e.pendingCharacterTokens.push(t)}function cie(e,t){e.pendingCharacterTokens.push(t),e.hasNonWhitespacePendingCharacterToken=!0}function I0(e,t){let n=0;if(e.hasNonWhitespacePendingCharacterToken)for(;n0&&e.openElements.currentTagId===_.OPTION&&e.openElements.tagIDs[e.openElements.stackTop-1]===_.OPTGROUP&&e.openElements.pop(),e.openElements.currentTagId===_.OPTGROUP&&e.openElements.pop();break}case _.OPTION:{e.openElements.currentTagId===_.OPTION&&e.openElements.pop();break}case _.SELECT:{e.openElements.hasInSelectScope(_.SELECT)&&(e.openElements.popUntilTagNamePopped(_.SELECT),e._resetInsertionMode());break}case _.TEMPLATE:{Fh(e,t);break}}}function lUe(e,t){const n=t.tagID;n===_.CAPTION||n===_.TABLE||n===_.TBODY||n===_.TFOOT||n===_.THEAD||n===_.TR||n===_.TD||n===_.TH?(e.openElements.popUntilTagNamePopped(_.SELECT),e._resetInsertionMode(),e._processStartTag(t)):hie(e,t)}function cUe(e,t){const n=t.tagID;n===_.CAPTION||n===_.TABLE||n===_.TBODY||n===_.TFOOT||n===_.THEAD||n===_.TR||n===_.TD||n===_.TH?e.openElements.hasInTableScope(n)&&(e.openElements.popUntilTagNamePopped(_.SELECT),e._resetInsertionMode(),e.onEndTag(t)):pie(e,t)}function fUe(e,t){switch(t.tagID){case _.BASE:case _.BASEFONT:case _.BGSOUND:case _.LINK:case _.META:case _.NOFRAMES:case _.SCRIPT:case _.STYLE:case _.TEMPLATE:case _.TITLE:{nu(e,t);break}case _.CAPTION:case _.COLGROUP:case _.TBODY:case _.TFOOT:case _.THEAD:{e.tmplInsertionModeStack[0]=Y.IN_TABLE,e.insertionMode=Y.IN_TABLE,zm(e,t);break}case _.COL:{e.tmplInsertionModeStack[0]=Y.IN_COLUMN_GROUP,e.insertionMode=Y.IN_COLUMN_GROUP,w6(e,t);break}case _.TR:{e.tmplInsertionModeStack[0]=Y.IN_TABLE_BODY,e.insertionMode=Y.IN_TABLE_BODY,CC(e,t);break}case _.TD:case _.TH:{e.tmplInsertionModeStack[0]=Y.IN_ROW,e.insertionMode=Y.IN_ROW,AC(e,t);break}default:e.tmplInsertionModeStack[0]=Y.IN_BODY,e.insertionMode=Y.IN_BODY,ls(e,t)}}function dUe(e,t){t.tagID===_.TEMPLATE&&Fh(e,t)}function mie(e,t){e.openElements.tmplCount>0?(e.openElements.popUntilTagNamePopped(_.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode(),e.onEof(t)):b6(e,t)}function hUe(e,t){t.tagID===_.HTML?ls(e,t):jT(e,t)}function gie(e,t){var n;if(t.tagID===_.HTML){if(e.fragmentContext||(e.insertionMode=Y.AFTER_AFTER_BODY),e.options.sourceCodeLocationInfo&&e.openElements.tagIDs[0]===_.HTML){e._setEndLocation(e.openElements.items[0],t);const r=e.openElements.items[1];r&&!(!((n=e.treeAdapter.getNodeSourceCodeLocation(r))===null||n===void 0)&&n.endTag)&&e._setEndLocation(r,t)}}else jT(e,t)}function jT(e,t){e.insertionMode=Y.IN_BODY,IC(e,t)}function pUe(e,t){switch(t.tagID){case _.HTML:{ls(e,t);break}case _.FRAMESET:{e._insertElement(t,we.HTML);break}case _.FRAME:{e._appendElement(t,we.HTML),t.ackSelfClosing=!0;break}case _.NOFRAMES:{nu(e,t);break}}}function mUe(e,t){t.tagID===_.FRAMESET&&!e.openElements.isRootHtmlElementCurrent()&&(e.openElements.pop(),!e.fragmentContext&&e.openElements.currentTagId!==_.FRAMESET&&(e.insertionMode=Y.AFTER_FRAMESET))}function gUe(e,t){switch(t.tagID){case _.HTML:{ls(e,t);break}case _.NOFRAMES:{nu(e,t);break}}}function yUe(e,t){t.tagID===_.HTML&&(e.insertionMode=Y.AFTER_AFTER_FRAMESET)}function vUe(e,t){t.tagID===_.HTML?ls(e,t):Fw(e,t)}function Fw(e,t){e.insertionMode=Y.IN_BODY,IC(e,t)}function _Ue(e,t){switch(t.tagID){case _.HTML:{ls(e,t);break}case _.NOFRAMES:{nu(e,t);break}}}function bUe(e,t){t.chars=lr,e._insertCharacters(t)}function wUe(e,t){e._insertCharacters(t),e.framesetOk=!1}function yie(e){for(;e.treeAdapter.getNamespaceURI(e.openElements.current)!==we.HTML&&!e._isIntegrationPoint(e.openElements.currentTagId,e.openElements.current);)e.openElements.pop()}function EUe(e,t){if(MBe(t))yie(e),e._startTagOutsideForeignContent(t);else{const n=e._getAdjustedCurrentElement(),r=e.treeAdapter.getNamespaceURI(n);r===we.MATHML?eie(t):r===we.SVG&&(FBe(t),tie(t)),v6(t),t.selfClosing?e._appendElement(t,r):e._insertElement(t,r),t.ackSelfClosing=!0}}function SUe(e,t){if(t.tagID===_.P||t.tagID===_.BR){yie(e),e._endTagOutsideForeignContent(t);return}for(let n=e.openElements.stackTop;n>0;n--){const r=e.openElements.items[n];if(e.treeAdapter.getNamespaceURI(r)===we.HTML){e._endTagOutsideForeignContent(t);break}const i=e.treeAdapter.getTagName(r);if(i.toLowerCase()===t.tagName){t.tagName=i,e.openElements.shortenToLength(n);break}}}le.AREA,le.BASE,le.BASEFONT,le.BGSOUND,le.BR,le.COL,le.EMBED,le.FRAME,le.HR,le.IMG,le.INPUT,le.KEYGEN,le.LINK,le.META,le.PARAM,le.SOURCE,le.TRACK,le.WBR;const vie=_ie("end"),Bh=_ie("start");function _ie(e){return t;function t(n){const r=n&&n.position&&n.position[e]||{};if(typeof r.line=="number"&&r.line>0&&typeof r.column=="number"&&r.column>0)return{line:r.line,column:r.column,offset:typeof r.offset=="number"&&r.offset>-1?r.offset:void 0}}}const bie=function(e){if(e==null)return CUe;if(typeof e=="function")return PC(e);if(typeof e=="object")return Array.isArray(e)?TUe(e):IUe(e);if(typeof e=="string")return xUe(e);throw new Error("Expected function, string, or object as test")};function TUe(e){const t=[];let n=-1;for(;++n":""))+")"})}return d;function d(){let h=wie,p,m,y;if((!t||s(u,l,c[c.length-1]||void 0))&&(h=NUe(n(u,c)),h[0]===I7))return h;if("children"in u&&u.children){const g=u;if(g.children&&h[0]!==OUe)for(m=(r?g.children.length:-1)+o,y=c.concat(g);m>-1&&mC.jsx(B_,{...r}),p:({node:n,...r})=>C.jsx(rt,{...r,pb:8}),h1:({node:n,...r})=>C.jsx($c,{order:1,...r,pb:12}),h2:({node:n,...r})=>C.jsx($c,{order:2,...r,pb:12}),h3:({node:n,...r})=>C.jsx($c,{order:3,...r,pb:12}),h4:({node:n,...r})=>C.jsx($c,{order:4,...r,pb:12}),h5:({node:n,...r})=>C.jsx($c,{order:5,...r,pb:12}),h6:({node:n,...r})=>C.jsx($c,{order:6,...r,pb:12}),a:({node:n,...r})=>C.jsx(RQ,{...r}),ul:({node:n,...r})=>C.jsx(Bm,{withPadding:!0,...r,pb:8}),ol:({node:n,...r})=>C.jsx(Bm,{type:"ordered",withPadding:!0,...r,pb:8})};return C.jsx("div",{style:{display:"inherit"},children:C.jsx(Rre,{components:t,rehypePlugins:[qUe],children:e})})}function GUe({response:e,disabled:t,answer:n}){const{prompt:r,required:i,options:s}=e;return C.jsx(Mm.Group,{label:C.jsx(ro,{text:r}),withAsterisk:i,...n,error:Lh(e,n,s),size:"md",children:C.jsx(ei,{mt:"md",children:s.map(o=>C.jsx(Mm,{disabled:t,value:o.value,label:o.label},o.value))})})}function YUe({response:e,disabled:t,answer:n}){const{placeholder:r,prompt:i,required:s,options:o}=e;return C.jsx(rte,{disabled:t,label:C.jsx(ro,{text:i}),placeholder:r,data:o,withAsterisk:s,radius:"md",size:"md",...n,error:Lh(e,n,o)})}function KUe({response:e,answer:t}){const{prompt:n}=e;return C.jsxs(C.Fragment,{children:[C.jsx(rt,{fz:"md",fw:500,children:C.jsx(ro,{text:n})}),C.jsx(Bm,{children:Array.isArray(t.value)&&t.value.map(r=>C.jsx(Bm.Item,{children:r},r))})]})}function xie({response:e,disabled:t,answer:n}){const{prompt:r,required:i,options:s,leftLabel:o,rightLabel:a}=e;return C.jsxs(cT.Group,{name:`radioInput${e.id}`,label:C.jsx(ro,{text:r}),withAsterisk:i,size:"md",...n,error:Lh(e,n,s),children:[o?C.jsx(rt,{children:o}):null,C.jsx(ei,{mt:"xs",noWrap:!0,children:s.map(u=>C.jsx(cT,{disabled:t,value:u.value,label:u.label},u.label))}),C.jsx(rt,{children:a})]},e.id)}function QUe({response:e,disabled:t,answer:n}){const{preset:r}=e,i=[];for(let o=1;o<=+r;o+=1)i.push({label:`${o}`,value:`${o}`});const s={...e,type:"radio",options:i};return C.jsx(xie,{disabled:t,response:s,answer:n})}function XUe({response:e,disabled:t,answer:n}){const{prompt:r,required:i,min:s,max:o,placeholder:a}=e;return C.jsx(kee,{disabled:t,placeholder:a,label:C.jsx(ro,{text:r}),withAsterisk:i,radius:"md",size:"md",min:s,max:o,...n,error:Lh(e,n)})}function JUe({response:e,disabled:t,answer:n}){const{prompt:r,options:i,leftLabel:s,rightLabel:o,required:a}=e,u=Lh(e,n);return C.jsx(Zs.Wrapper,{withAsterisk:a,label:C.jsx(ro,{text:r}),error:u,size:"md",children:C.jsxs(ei,{children:[s?C.jsx(ua,{children:C.jsx(rt,{children:s})}):null,C.jsx(fte,{disabled:t,labelAlwaysOn:n.value!=="",label:l=>`$${l}`,sx:{marginTop:"15px",marginBottom:"15px",width:"400px"},marks:i,...n,defaultValue:50,thumbSize:n.value===""?.1:17,color:n.value===""?"gray.2":"blue",min:0,max:100,showLabelOnHover:!1,styles:l=>({markFilled:{borderColor:"#E9ECEF",backgroundColor:"white"},bar:{backgroundColor:"#E9ECEF"},markLabel:{fontSize:l.fontSizes.sm,marginBottom:5,marginTop:0}})}),o?C.jsx(ua,{children:C.jsx(rt,{children:o})}):null]})})}function ZUe({response:e,disabled:t,answer:n}){const{placeholder:r,prompt:i,required:s}=e;return C.jsx(Ev,{disabled:t,placeholder:r,label:C.jsx(ro,{text:i}),radius:"md",size:"md",withAsterisk:s,...n,value:n.value||"",error:Lh(e,n)})}function eVe({response:e,disabled:t,answer:n}){const{placeholder:r,prompt:i,required:s}=e;return C.jsx(jZ,{disabled:t,placeholder:r,label:C.jsx(ro,{text:i}),radius:"md",size:"md",withAsterisk:s,...n,value:n.value||"",error:Lh(e,n)})}function tVe({response:e,answer:t,storedAnswer:n}){const r=(n?{value:n}:t)||{value:void 0},i=!!n,[s]=h$(),o=w.useMemo(()=>{if(e.paramCapture){const a=s.get(e.paramCapture);return i||!!a}return i},[i,e.paramCapture,s]);return C.jsxs(it,{sx:{margin:10,padding:5},children:[e.type==="numerical"&&C.jsx(XUe,{response:e,disabled:o,answer:r}),e.type==="shortText"&&C.jsx(ZUe,{response:e,disabled:o,answer:r}),e.type==="longText"&&C.jsx(eVe,{response:e,disabled:o,answer:r}),e.type==="likert"&&C.jsx(QUe,{response:e,disabled:o,answer:r}),e.type==="dropdown"&&C.jsx(YUe,{response:e,disabled:o,answer:r}),e.type==="slider"&&C.jsx(JUe,{response:e,disabled:o,answer:r}),e.type==="radio"&&C.jsx(xie,{response:e,disabled:o,answer:r}),e.type==="checkbox"&&C.jsx(GUe,{response:e,disabled:o,answer:r}),e.type==="iframe"&&C.jsx(KUe,{response:e,answer:r})]})}function UT({config:e,location:t,status:n,style:r}){var y,g;const i=hl(),s=n==null?void 0:n.answer,o=e,a=((y=o==null?void 0:o.response)==null?void 0:y.filter(v=>v.location?v.location===t:t==="belowStimulus"))||[],u=Ju(),{updateResponseBlockValidation:l}=Xu(),c=t4e(a,i,s||{}),[f,d]=w.useState(!1),{iframeAnswers:h}=la(v=>v),p=(((g=o==null?void 0:o.correctAnswer)==null?void 0:g.length)||0)>0,m=t===((o==null?void 0:o.nextButtonLocation)||"belowStimulus");return w.useEffect(()=>{const v=a.find(b=>b.type==="iframe");if(v){const b=v.id;c.setValues({...c.values,[b]:h})}},[h]),w.useEffect(()=>{u(l({location:t,currentStep:i,status:c.isValid(),values:Ig(c.values)}))},[c.values,i,t]),C.jsxs("div",{style:r,children:[a.map(v=>{var b,S;return C.jsx(N.Fragment,{children:v.hidden?"":C.jsxs(C.Fragment,{children:[C.jsx(tVe,{storedAnswer:s?s[v.id]:void 0,answer:{...c.getInputProps(v.id,{type:v.type==="checkbox"?"checkbox":"input"})},response:v}),p&&f&&C.jsx(rt,{children:`The correct answer is: ${(S=(b=o.correctAnswer)==null?void 0:b.find(T=>T.id===v.id))==null?void 0:S.answer}`})]})},`${v.id}-${i}`)}),C.jsxs(ei,{position:"right",spacing:"xs",mt:"xl",children:[p&&m&&C.jsx(Ws,{onClick:()=>d(!0),disabled:!c.isValid(),children:"Check Answer"}),m&&C.jsx(CMe,{disabled:p&&!f,setCheckClicked:d,label:o.nextButtonText||"Next"})]})]})}const kb="@REVISIT_COMMS",nVe={minHeight:"500px",width:"100%",border:0,marginTop:"-50px"};function rVe({currentConfig:e}){const{setIframeAnswers:t}=Xu(),n=Ju(),r=Ote(),i=w.useRef(null),s=w.useMemo(()=>crypto.randomUUID?crypto.randomUUID():`testID-${Date.now()}`,[]),o=hl(),a=Kf(),u=w.useCallback((l,c)=>{var f,d;(d=(f=i.current)==null?void 0:f.contentWindow)==null||d.postMessage({error:!1,type:`${kb}/${l}`,iframeId:s,message:c},"*")},[i,s]);return w.useEffect(()=>{const l=c=>{const{data:f}=c;if(typeof f=="object"&&s===f.iframeId)switch(f.type){case`${kb}/WINDOW_READY`:e.parameters&&u("STUDY_DATA",e.parameters);break;case`${kb}/READY`:i.current&&(i.current.style.height=`${f.message.documentHeight}px`);break;case`${kb}/ANSWERS`:n(t(f.message.answer));break}};return window.addEventListener("message",l),()=>window.removeEventListener("message",l)},[n,o,r,s,a,e,u,t]),C.jsx("div",{children:C.jsx("iframe",{ref:i,src:`${fl}${e.path}?trialid=${o}&id=${s}`,style:nVe})})}const iVe={maxWidth:"100%"};function sVe({currentConfig:e}){const t={...iVe,...e.style};return C.jsx(B_,{mx:"auto",src:`${fl}${e.path}`,style:t})}function C7({parameters:e,setAnswer:t}){return w.useEffect(()=>{navigator.mediaDevices.getUserMedia({audio:!0}).then(r=>{new MediaRecorder(r).start();const s=new AudioContext,o=s.createMediaStreamSource(r),a=s.createAnalyser();a.minDecibels=-45,o.connect(a);const u=a.frequencyBinCount,l=new Uint8Array(u);let c=!1;const f=()=>{if(!c){a.getByteFrequencyData(l);for(let d=0;d0&&(c=!0,t({status:!0,provenanceGraph:void 0,answers:{audioTest:!0}}));window.requestAnimationFrame(f)}};window.requestAnimationFrame(f)})},[t]),C.jsx(ua,{style:{height:"70%",width:"100%"},children:C.jsxs(ys,{children:[C.jsx(rt,{ta:"center",children:"Please allow us to access your microphone. There may be a popup in your browser window asking for access, click accept."}),C.jsx(rt,{ta:"center",children:"Once we can confirm that your microphone is on and we hear you say something, the continue button will become available."}),C.jsx(rt,{ta:"center",weight:700,children:"If you are not comfortable or able to speak English during this study, please close it now."})]})})}const oVe=Object.freeze(Object.defineProperty({__proto__:null,AudioTest:C7,default:C7},Symbol.toStringTag,{value:"Module"})),Si={Purple:"#6D3E91",DarkOrange:"#C05917",LightTeal:"#58AC8C",Blue:"#286BBB",Maroon:"#883039",Camel:"#BC8E5A",MidnightBlue:"#00295B",DustyCoral:"#C15065",DarkOliveGreen:"#18470F",DarkCopper:"#9A5129",Peach:"#E56E5A",Mauve:"#A2559C",Turquoise:"#38AABA",OliveGreen:"#578145",Cherry:"#970046",Teal:"#00847E",RustyOrange:"#B13507",Denim:"#4C6A9C",Fuchsia:"#CF0A66",TealishGreen:"#00875E",Copper:"#B16214",DarkMauve:"#8C4569",Lime:"#3B8E1D",Coral:"#D73C50"},rp={DarkOrangeDarker:"#BE5915",PeachDarker:"#C4523E",LightTealDarker:"#2C8465",TurquoiseDarker:"#008291",CamelDarker:"#996D39",LimeDarker:"#338711"},E6=[Si.DustyCoral,rp.LightTealDarker,rp.DarkOrangeDarker,Si.Purple,Si.DarkOliveGreen,Si.Blue,Si.Maroon,rp.CamelDarker,Si.MidnightBlue,Si.DarkCopper,rp.PeachDarker,Si.Mauve,rp.TurquoiseDarker,Si.OliveGreen,Si.Cherry,Si.Teal,Si.RustyOrange,Si.Denim,Si.TealishGreen,Si.Copper,Si.DarkMauve,rp.LimeDarker,Si.Coral],aVe=Object.freeze(Object.defineProperty({__proto__:null,OwidDistinctLinesPalette:E6},Symbol.toStringTag,{value:"Module"}));function cm(e,t){return e==null||t==null?NaN:et?1:e>=t?0:NaN}function uVe(e,t){return e==null||t==null?NaN:te?1:t>=e?0:NaN}function S6(e){let t,n,r;e.length!==2?(t=cm,n=(a,u)=>cm(e(a),u),r=(a,u)=>e(a)-u):(t=e===cm||e===uVe?e:lVe,n=e,r=e);function i(a,u,l=0,c=a.length){if(l>>1;n(a[f],u)<0?l=f+1:c=f}while(l>>1;n(a[f],u)<=0?l=f+1:c=f}while(ll&&r(a[f-1],u)>-r(a[f],u)?f-1:f}return{left:i,center:o,right:s}}function lVe(){return 0}function cVe(e){return e===null?NaN:+e}function*fVe(e,t){if(t===void 0)for(let n of e)n!=null&&(n=+n)>=n&&(yield n);else{let n=-1;for(let r of e)(r=t(r,++n,e))!=null&&(r=+r)>=r&&(yield r)}}const dVe=S6(cm),hVe=dVe.right;S6(cVe).center;function Pf(e,t){let n,r;if(t===void 0)for(const i of e)i!=null&&(n===void 0?i>=i&&(n=r=i):(n>i&&(n=i),r=s&&(n=r=s):(n>s&&(n=s),r=r.length)return n(s);const a=new $N,u=r[o++];let l=-1;for(const c of s){const f=u(c,++l,s),d=a.get(f);d?d.push(c):a.set(f,[c])}for(const[c,f]of a)a.set(c,i(f,o));return t(a)}(e,0)}function bVe(e=cm){if(e===cm)return Cie;if(typeof e!="function")throw new TypeError("compare is not a function");return(t,n)=>{const r=e(t,n);return r||r===0?r:(e(n,n)===0)-(e(t,t)===0)}}function Cie(e,t){return(e==null||!(e>=e))-(t==null||!(t>=t))||(et?1:0)}const wVe=Math.sqrt(50),EVe=Math.sqrt(10),SVe=Math.sqrt(2);function VT(e,t,n){const r=(t-e)/Math.max(0,n),i=Math.floor(Math.log10(r)),s=r/Math.pow(10,i),o=s>=wVe?10:s>=EVe?5:s>=SVe?2:1;let a,u,l;return i<0?(l=Math.pow(10,-i)/o,a=Math.round(e*l),u=Math.round(t*l),a/lt&&--u,l=-l):(l=Math.pow(10,i)*o,a=Math.round(e/l),u=Math.round(t/l),a*lt&&--u),u0))return[];if(e===t)return[e];const r=t=i))return[];const a=s-i+1,u=new Array(a);if(r)if(o<0)for(let l=0;l=r)&&(n=r);else{let r=-1;for(let i of e)(i=t(i,++r,e))!=null&&(n=i)&&(n=i)}return n}function zT(e,t){let n;if(t===void 0)for(const r of e)r!=null&&(n>r||n===void 0&&r>=r)&&(n=r);else{let r=-1;for(let i of e)(i=t(i,++r,e))!=null&&(n>i||n===void 0&&i>=i)&&(n=i)}return n}function Aie(e,t,n=0,r=1/0,i){if(t=Math.floor(t),n=Math.floor(Math.max(0,n)),r=Math.floor(Math.min(e.length-1,r)),!(n<=t&&t<=r))return e;for(i=i===void 0?Cie:bVe(i);r>n;){if(r-n>600){const u=r-n+1,l=t-n+1,c=Math.log(u),f=.5*Math.exp(2*c/3),d=.5*Math.sqrt(c*f*(u-f)/u)*(l-u/2<0?-1:1),h=Math.max(n,Math.floor(t-l*f/u+d)),p=Math.min(r,Math.floor(t+(u-l)*f/u+d));Aie(e,t,h,p,i)}const s=e[t];let o=n,a=r;for(x0(e,n,t),i(e[r],s)>0&&x0(e,n,r);o0;)--a}i(e[n],s)===0?x0(e,n,a):(++a,x0(e,a,r)),a<=t&&(n=a+1),t<=a&&(r=a-1)}return e}function x0(e,t,n){const r=e[t];e[t]=e[n],e[n]=r}function P7(e,t,n){if(e=Float64Array.from(fVe(e,n)),!(!(r=e.length)||isNaN(t=+t))){if(t<=0||r<2)return zT(e);if(t>=1)return Pv(e);var r,i=(r-1)*t,s=Math.floor(i),o=Pv(Aie(e,s).subarray(0,s+1)),a=zT(e.subarray(s+1));return o+(a-o)*(i-s)}}function IVe(e,t){let n=0,r=0;if(t===void 0)for(let i of e)i!=null&&(i=+i)>=i&&(++n,r+=i);else{let i=-1;for(let s of e)(s=t(s,++i,e))!=null&&(s=+s)>=s&&(++n,r+=s)}if(n)return r/n}function T6(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function Pie(e,t){var n=Object.create(e.prototype);for(var r in t)n[r]=t[r];return n}function t1(){}var Ov=.7,HT=1/Ov,fm="\\s*([+-]?\\d+)\\s*",Rv="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",Uu="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",xVe=/^#([0-9a-f]{3,8})$/,CVe=new RegExp(`^rgb\\(${fm},${fm},${fm}\\)$`),AVe=new RegExp(`^rgb\\(${Uu},${Uu},${Uu}\\)$`),PVe=new RegExp(`^rgba\\(${fm},${fm},${fm},${Rv}\\)$`),OVe=new RegExp(`^rgba\\(${Uu},${Uu},${Uu},${Rv}\\)$`),RVe=new RegExp(`^hsl\\(${Rv},${Uu},${Uu}\\)$`),NVe=new RegExp(`^hsla\\(${Rv},${Uu},${Uu},${Rv}\\)$`),O7={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};T6(t1,Nv,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:R7,formatHex:R7,formatHex8:kVe,formatHsl:DVe,formatRgb:N7,toString:N7});function R7(){return this.rgb().formatHex()}function kVe(){return this.rgb().formatHex8()}function DVe(){return Oie(this).formatHsl()}function N7(){return this.rgb().formatRgb()}function Nv(e){var t,n;return e=(e+"").trim().toLowerCase(),(t=xVe.exec(e))?(n=t[1].length,t=parseInt(t[1],16),n===6?k7(t):n===3?new qs(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):n===8?Db(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):n===4?Db(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|t&240,((t&15)<<4|t&15)/255):null):(t=CVe.exec(e))?new qs(t[1],t[2],t[3],1):(t=AVe.exec(e))?new qs(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=PVe.exec(e))?Db(t[1],t[2],t[3],t[4]):(t=OVe.exec(e))?Db(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=RVe.exec(e))?L7(t[1],t[2]/100,t[3]/100,1):(t=NVe.exec(e))?L7(t[1],t[2]/100,t[3]/100,t[4]):O7.hasOwnProperty(e)?k7(O7[e]):e==="transparent"?new qs(NaN,NaN,NaN,0):null}function k7(e){return new qs(e>>16&255,e>>8&255,e&255,1)}function Db(e,t,n,r){return r<=0&&(e=t=n=NaN),new qs(e,t,n,r)}function $Ve(e){return e instanceof t1||(e=Nv(e)),e?(e=e.rgb(),new qs(e.r,e.g,e.b,e.opacity)):new qs}function FN(e,t,n,r){return arguments.length===1?$Ve(e):new qs(e,t,n,r??1)}function qs(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}T6(qs,FN,Pie(t1,{brighter(e){return e=e==null?HT:Math.pow(HT,e),new qs(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?Ov:Math.pow(Ov,e),new qs(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new qs(Jd(this.r),Jd(this.g),Jd(this.b),WT(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:D7,formatHex:D7,formatHex8:LVe,formatRgb:$7,toString:$7}));function D7(){return`#${$d(this.r)}${$d(this.g)}${$d(this.b)}`}function LVe(){return`#${$d(this.r)}${$d(this.g)}${$d(this.b)}${$d((isNaN(this.opacity)?1:this.opacity)*255)}`}function $7(){const e=WT(this.opacity);return`${e===1?"rgb(":"rgba("}${Jd(this.r)}, ${Jd(this.g)}, ${Jd(this.b)}${e===1?")":`, ${e})`}`}function WT(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function Jd(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function $d(e){return e=Jd(e),(e<16?"0":"")+e.toString(16)}function L7(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new $a(e,t,n,r)}function Oie(e){if(e instanceof $a)return new $a(e.h,e.s,e.l,e.opacity);if(e instanceof t1||(e=Nv(e)),!e)return new $a;if(e instanceof $a)return e;e=e.rgb();var t=e.r/255,n=e.g/255,r=e.b/255,i=Math.min(t,n,r),s=Math.max(t,n,r),o=NaN,a=s-i,u=(s+i)/2;return a?(t===s?o=(n-r)/a+(n0&&u<1?0:o,new $a(o,a,u,e.opacity)}function MVe(e,t,n,r){return arguments.length===1?Oie(e):new $a(e,t,n,r??1)}function $a(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}T6($a,MVe,Pie(t1,{brighter(e){return e=e==null?HT:Math.pow(HT,e),new $a(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?Ov:Math.pow(Ov,e),new $a(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+(this.h<0)*360,t=isNaN(e)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*t,i=2*n-r;return new qs(PO(e>=240?e-240:e+120,i,r),PO(e,i,r),PO(e<120?e+240:e-120,i,r),this.opacity)},clamp(){return new $a(M7(this.h),$b(this.s),$b(this.l),WT(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=WT(this.opacity);return`${e===1?"hsl(":"hsla("}${M7(this.h)}, ${$b(this.s)*100}%, ${$b(this.l)*100}%${e===1?")":`, ${e})`}`}}));function M7(e){return e=(e||0)%360,e<0?e+360:e}function $b(e){return Math.max(0,Math.min(1,e||0))}function PO(e,t,n){return(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)*255}const I6=e=>()=>e;function FVe(e,t){return function(n){return e+n*t}}function BVe(e,t,n){return e=Math.pow(e,n),t=Math.pow(t,n)-e,n=1/n,function(r){return Math.pow(e+r*t,n)}}function jVe(e){return(e=+e)==1?Rie:function(t,n){return n-t?BVe(t,n,e):I6(isNaN(t)?n:t)}}function Rie(e,t){var n=t-e;return n?FVe(e,n):I6(isNaN(e)?t:e)}const F7=function e(t){var n=jVe(t);function r(i,s){var o=n((i=FN(i)).r,(s=FN(s)).r),a=n(i.g,s.g),u=n(i.b,s.b),l=Rie(i.opacity,s.opacity);return function(c){return i.r=o(c),i.g=a(c),i.b=u(c),i.opacity=l(c),i+""}}return r.gamma=e,r}(1);function UVe(e,t){t||(t=[]);var n=e?Math.min(t.length,e.length):0,r=t.slice(),i;return function(s){for(i=0;in&&(s=t.slice(n,s),a[o]?a[o]+=s:a[++o]=s),(r=r[0])===(i=i[0])?a[o]?a[o]+=i:a[++o]=i:(a[++o]=null,u.push({i:o,x:qT(r,i)})),n=OO.lastIndex;return n=0))throw new Error(`invalid digits: ${e}`);if(t>15)return Nie;const n=10**t;return function(r){this._+=r[0];for(let i=1,s=r.length;igd)if(!(Math.abs(f*u-l*c)>gd)||!s)this._append`L${this._x1=t},${this._y1=n}`;else{let h=r-o,p=i-a,m=u*u+l*l,y=h*h+p*p,g=Math.sqrt(m),v=Math.sqrt(d),b=s*Math.tan((jN-Math.acos((m+d-y)/(2*g*v)))/2),S=b/v,T=b/g;Math.abs(S-1)>gd&&this._append`L${t+S*c},${n+S*f}`,this._append`A${s},${s},0,0,${+(f*h>c*p)},${this._x1=t+T*u},${this._y1=n+T*l}`}}arc(t,n,r,i,s,o){if(t=+t,n=+n,r=+r,o=!!o,r<0)throw new Error(`negative radius: ${r}`);let a=r*Math.cos(i),u=r*Math.sin(i),l=t+a,c=n+u,f=1^o,d=o?i-s:s-i;this._x1===null?this._append`M${l},${c}`:(Math.abs(this._x1-l)>gd||Math.abs(this._y1-c)>gd)&&this._append`L${l},${c}`,r&&(d<0&&(d=d%UN+UN),d>QVe?this._append`A${r},${r},0,1,${f},${t-a},${n-u}A${r},${r},0,1,${f},${this._x1=l},${this._y1=c}`:d>gd&&this._append`A${r},${r},0,${+(d>=jN)},${f},${this._x1=t+r*Math.cos(s)},${this._y1=n+r*Math.sin(s)}`)}rect(t,n,r,i){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+n}h${r=+r}v${+i}h${-r}Z`}toString(){return this._}}var B7={},RO={},NO=34,C0=10,kO=13;function kie(e){return new Function("d","return {"+e.map(function(t,n){return JSON.stringify(t)+": d["+n+'] || ""'}).join(",")+"}")}function ZVe(e,t){var n=kie(e);return function(r,i){return t(n(r),i,e)}}function j7(e){var t=Object.create(null),n=[];return e.forEach(function(r){for(var i in r)i in t||n.push(t[i]=i)}),n}function Ns(e,t){var n=e+"",r=n.length;return r9999?"+"+Ns(e,6):Ns(e,4)}function t7e(e){var t=e.getUTCHours(),n=e.getUTCMinutes(),r=e.getUTCSeconds(),i=e.getUTCMilliseconds();return isNaN(e)?"Invalid Date":e7e(e.getUTCFullYear())+"-"+Ns(e.getUTCMonth()+1,2)+"-"+Ns(e.getUTCDate(),2)+(i?"T"+Ns(t,2)+":"+Ns(n,2)+":"+Ns(r,2)+"."+Ns(i,3)+"Z":r?"T"+Ns(t,2)+":"+Ns(n,2)+":"+Ns(r,2)+"Z":n||t?"T"+Ns(t,2)+":"+Ns(n,2)+"Z":"")}function n7e(e){var t=new RegExp('["'+e+` +\r]`),n=e.charCodeAt(0);function r(f,d){var h,p,m=i(f,function(y,g){if(h)return h(y,g-1);p=y,h=d?ZVe(y,d):kie(y)});return m.columns=p||[],m}function i(f,d){var h=[],p=f.length,m=0,y=0,g,v=p<=0,b=!1;f.charCodeAt(p-1)===C0&&--p,f.charCodeAt(p-1)===kO&&--p;function S(){if(v)return RO;if(b)return b=!1,B7;var E,I=m,A;if(f.charCodeAt(I)===NO){for(;m++=p?v=!0:(A=f.charCodeAt(m++))===C0?b=!0:A===kO&&(b=!0,f.charCodeAt(m)===C0&&++m),f.slice(I+1,E-1).replace(/""/g,'"')}for(;m=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function GT(e,t){if((n=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"))<0)return null;var n,r=e.slice(0,n);return[r.length>1?r[0]+r.slice(2):r,+e.slice(n+1)]}function Hm(e){return e=GT(Math.abs(e)),e?e[1]:NaN}function l7e(e,t){return function(n,r){for(var i=n.length,s=[],o=0,a=e[0],u=0;i>0&&a>0&&(u+a+1>r&&(a=Math.max(1,r-u)),s.push(n.substring(i-=a,i+a)),!((u+=a+1)>r));)a=e[o=(o+1)%e.length];return s.reverse().join(t)}}function c7e(e){return function(t){return t.replace(/[0-9]/g,function(n){return e[+n]})}}var f7e=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function YT(e){if(!(t=f7e.exec(e)))throw new Error("invalid format: "+e);var t;return new A6({fill:t[1],align:t[2],sign:t[3],symbol:t[4],zero:t[5],width:t[6],comma:t[7],precision:t[8]&&t[8].slice(1),trim:t[9],type:t[10]})}YT.prototype=A6.prototype;function A6(e){this.fill=e.fill===void 0?" ":e.fill+"",this.align=e.align===void 0?">":e.align+"",this.sign=e.sign===void 0?"-":e.sign+"",this.symbol=e.symbol===void 0?"":e.symbol+"",this.zero=!!e.zero,this.width=e.width===void 0?void 0:+e.width,this.comma=!!e.comma,this.precision=e.precision===void 0?void 0:+e.precision,this.trim=!!e.trim,this.type=e.type===void 0?"":e.type+""}A6.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(this.width===void 0?"":Math.max(1,this.width|0))+(this.comma?",":"")+(this.precision===void 0?"":"."+Math.max(0,this.precision|0))+(this.trim?"~":"")+this.type};function d7e(e){e:for(var t=e.length,n=1,r=-1,i;n0&&(r=0);break}return r>0?e.slice(0,r)+e.slice(i+1):e}var Die;function h7e(e,t){var n=GT(e,t);if(!n)return e+"";var r=n[0],i=n[1],s=i-(Die=Math.max(-8,Math.min(8,Math.floor(i/3)))*3)+1,o=r.length;return s===o?r:s>o?r+new Array(s-o+1).join("0"):s>0?r.slice(0,s)+"."+r.slice(s):"0."+new Array(1-s).join("0")+GT(e,Math.max(0,t+s-1))[0]}function U7(e,t){var n=GT(e,t);if(!n)return e+"";var r=n[0],i=n[1];return i<0?"0."+new Array(-i).join("0")+r:r.length>i+1?r.slice(0,i+1)+"."+r.slice(i+1):r+new Array(i-r.length+2).join("0")}const V7={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:u7e,e:(e,t)=>e.toExponential(t),f:(e,t)=>e.toFixed(t),g:(e,t)=>e.toPrecision(t),o:e=>Math.round(e).toString(8),p:(e,t)=>U7(e*100,t),r:U7,s:h7e,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function z7(e){return e}var H7=Array.prototype.map,W7=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function p7e(e){var t=e.grouping===void 0||e.thousands===void 0?z7:l7e(H7.call(e.grouping,Number),e.thousands+""),n=e.currency===void 0?"":e.currency[0]+"",r=e.currency===void 0?"":e.currency[1]+"",i=e.decimal===void 0?".":e.decimal+"",s=e.numerals===void 0?z7:c7e(H7.call(e.numerals,String)),o=e.percent===void 0?"%":e.percent+"",a=e.minus===void 0?"−":e.minus+"",u=e.nan===void 0?"NaN":e.nan+"";function l(f){f=YT(f);var d=f.fill,h=f.align,p=f.sign,m=f.symbol,y=f.zero,g=f.width,v=f.comma,b=f.precision,S=f.trim,T=f.type;T==="n"?(v=!0,T="g"):V7[T]||(b===void 0&&(b=12),S=!0,T="g"),(y||d==="0"&&h==="=")&&(y=!0,d="0",h="=");var E=m==="$"?n:m==="#"&&/[boxX]/.test(T)?"0"+T.toLowerCase():"",I=m==="$"?r:/[%p]/.test(T)?o:"",A=V7[T],R=/[defgprs%]/.test(T);b=b===void 0?6:/[gprs]/.test(T)?Math.max(1,Math.min(21,b)):Math.max(0,Math.min(20,b));function F(L){var B=E,J=I,V,re,oe;if(T==="c")J=A(L)+J,L="";else{L=+L;var ae=L<0||1/L<0;if(L=isNaN(L)?u:A(Math.abs(L),b),S&&(L=d7e(L)),ae&&+L==0&&p!=="+"&&(ae=!1),B=(ae?p==="("?p:a:p==="-"||p==="("?"":p)+B,J=(T==="s"?W7[8+Die/3]:"")+J+(ae&&p==="("?")":""),R){for(V=-1,re=L.length;++Voe||oe>57){J=(oe===46?i+L.slice(V+1):L.slice(V))+J,L=L.slice(0,V);break}}}v&&!y&&(L=t(L,1/0));var ee=B.length+L.length+J.length,ue=ee>1)+B+L+J+ue.slice(ee);break;default:L=ue+B+L+J;break}return s(L)}return F.toString=function(){return f+""},F}function c(f,d){var h=l((f=YT(f),f.type="f",f)),p=Math.max(-8,Math.min(8,Math.floor(Hm(d)/3)))*3,m=Math.pow(10,-p),y=W7[8+p/3];return function(g){return h(m*g)+y}}return{format:l,formatPrefix:c}}var Lb,yf,$ie;m7e({thousands:",",grouping:[3],currency:["$",""]});function m7e(e){return Lb=p7e(e),yf=Lb.format,$ie=Lb.formatPrefix,Lb}function g7e(e){return Math.max(0,-Hm(Math.abs(e)))}function y7e(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(Hm(t)/3)))*3-Hm(Math.abs(e)))}function v7e(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,Hm(t)-Hm(e))+1}function P6(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e);break}return this}const q7=Symbol("implicit");function O6(){var e=new LN,t=[],n=[],r=q7;function i(s){let o=e.get(s);if(o===void 0){if(r!==q7)return r;e.set(s,o=t.push(s)-1)}return n[o%n.length]}return i.domain=function(s){if(!arguments.length)return t.slice();t=[],e=new LN;for(const o of s)e.has(o)||e.set(o,t.push(o)-1);return i},i.range=function(s){return arguments.length?(n=Array.from(s),i):n.slice()},i.unknown=function(s){return arguments.length?(r=s,i):r},i.copy=function(){return O6(t,n).unknown(r)},P6.apply(i,arguments),i}function _7e(e){return function(){return e}}function b7e(e){return+e}var G7=[0,1];function $p(e){return e}function zN(e,t){return(t-=e=+e)?function(n){return(n-e)/t}:_7e(isNaN(t)?NaN:.5)}function w7e(e,t){var n;return e>t&&(n=e,e=t,t=n),function(r){return Math.max(e,Math.min(t,r))}}function E7e(e,t,n){var r=e[0],i=e[1],s=t[0],o=t[1];return i2?S7e:E7e,u=l=null,f}function f(d){return d==null||isNaN(d=+d)?s:(u||(u=a(e.map(r),t,n)))(r(o(d)))}return f.invert=function(d){return o(i((l||(l=a(t,e.map(r),qT)))(d)))},f.domain=function(d){return arguments.length?(e=Array.from(d,b7e),c()):e.slice()},f.range=function(d){return arguments.length?(t=Array.from(d),c()):t.slice()},f.rangeRound=function(d){return t=Array.from(d),n=YVe,c()},f.clamp=function(d){return arguments.length?(o=d?!0:$p,c()):o!==$p},f.interpolate=function(d){return arguments.length?(n=d,c()):n},f.unknown=function(d){return arguments.length?(s=d,f):s},function(d,h){return r=d,i=h,c()}}function Mie(){return T7e()($p,$p)}function I7e(e,t,n,r){var i=FN(e,t,n),s;switch(r=YT(r??",f"),r.type){case"s":{var o=Math.max(Math.abs(e),Math.abs(t));return r.precision==null&&!isNaN(s=y7e(i,o))&&(r.precision=s),$ie(r,o)}case"":case"e":case"g":case"p":case"r":{r.precision==null&&!isNaN(s=v7e(i,Math.max(Math.abs(e),Math.abs(t))))&&(r.precision=s-(r.type==="e"));break}case"f":case"%":{r.precision==null&&!isNaN(s=g7e(i))&&(r.precision=s-(r.type==="%")*2);break}}return yf(r)}function x7e(e){var t=e.domain;return e.ticks=function(n){var r=t();return TVe(r[0],r[r.length-1],n??10)},e.tickFormat=function(n,r){var i=t();return I7e(i[0],i[i.length-1],n??10,r)},e.nice=function(n){n==null&&(n=10);var r=t(),i=0,s=r.length-1,o=r[i],a=r[s],u,l,c=10;for(a0;){if(l=MN(o,a,n),l===u)return r[i]=o,r[s]=a,t(r);if(l>0)o=Math.floor(o/l)*l,a=Math.ceil(a/l)*l;else if(l<0)o=Math.ceil(o*l)/l,a=Math.floor(a*l)/l;else break;u=l}return e},e}function mh(){var e=Mie();return e.copy=function(){return Lie(e,mh())},P6.apply(e,arguments),x7e(e)}function C7e(e,t){e=e.slice();var n=0,r=e.length-1,i=e[n],s=e[r],o;return s(e(s=new Date(+s)),s),i.ceil=s=>(e(s=new Date(s-1)),t(s,1),e(s),s),i.round=s=>{const o=i(s),a=i.ceil(s);return s-o(t(s=new Date(+s),o==null?1:Math.floor(o)),s),i.range=(s,o,a)=>{const u=[];if(s=i.ceil(s),a=a==null?1:Math.floor(a),!(s0))return u;let l;do u.push(l=new Date(+s)),t(s,a),e(s);while(lai(o=>{if(o>=o)for(;e(o),!s(o);)o.setTime(o-1)},(o,a)=>{if(o>=o)if(a<0)for(;++a<=0;)for(;t(o,-1),!s(o););else for(;--a>=0;)for(;t(o,1),!s(o););}),n&&(i.count=(s,o)=>($O.setTime(+s),LO.setTime(+o),e($O),e(LO),Math.floor(n($O,LO))),i.every=s=>(s=Math.floor(s),!isFinite(s)||!(s>0)?null:s>1?i.filter(r?o=>r(o)%s===0:o=>i.count(0,o)%s===0):i)),i}const KT=ai(()=>{},(e,t)=>{e.setTime(+e+t)},(e,t)=>t-e);KT.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?ai(t=>{t.setTime(Math.floor(t/e)*e)},(t,n)=>{t.setTime(+t+n*e)},(t,n)=>(n-t)/e):KT);KT.range;const Nl=1e3,ta=Nl*60,kl=ta*60,Kl=kl*24,R6=Kl*7,Y7=Kl*30,MO=Kl*365,Lp=ai(e=>{e.setTime(e-e.getMilliseconds())},(e,t)=>{e.setTime(+e+t*Nl)},(e,t)=>(t-e)/Nl,e=>e.getUTCSeconds());Lp.range;const N6=ai(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*Nl)},(e,t)=>{e.setTime(+e+t*ta)},(e,t)=>(t-e)/ta,e=>e.getMinutes());N6.range;const A7e=ai(e=>{e.setUTCSeconds(0,0)},(e,t)=>{e.setTime(+e+t*ta)},(e,t)=>(t-e)/ta,e=>e.getUTCMinutes());A7e.range;const k6=ai(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*Nl-e.getMinutes()*ta)},(e,t)=>{e.setTime(+e+t*kl)},(e,t)=>(t-e)/kl,e=>e.getHours());k6.range;const P7e=ai(e=>{e.setUTCMinutes(0,0,0)},(e,t)=>{e.setTime(+e+t*kl)},(e,t)=>(t-e)/kl,e=>e.getUTCHours());P7e.range;const n1=ai(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*ta)/Kl,e=>e.getDate()-1);n1.range;const D6=ai(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/Kl,e=>e.getUTCDate()-1);D6.range;const O7e=ai(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/Kl,e=>Math.floor(e/Kl));O7e.range;function jh(e){return ai(t=>{t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)},(t,n)=>{t.setDate(t.getDate()+n*7)},(t,n)=>(n-t-(n.getTimezoneOffset()-t.getTimezoneOffset())*ta)/R6)}const OC=jh(0),QT=jh(1),R7e=jh(2),N7e=jh(3),Wm=jh(4),k7e=jh(5),D7e=jh(6);OC.range;QT.range;R7e.range;N7e.range;Wm.range;k7e.range;D7e.range;function Uh(e){return ai(t=>{t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)},(t,n)=>{t.setUTCDate(t.getUTCDate()+n*7)},(t,n)=>(n-t)/R6)}const Fie=Uh(0),XT=Uh(1),$7e=Uh(2),L7e=Uh(3),qm=Uh(4),M7e=Uh(5),F7e=Uh(6);Fie.range;XT.range;$7e.range;L7e.range;qm.range;M7e.range;F7e.range;const $6=ai(e=>{e.setDate(1),e.setHours(0,0,0,0)},(e,t)=>{e.setMonth(e.getMonth()+t)},(e,t)=>t.getMonth()-e.getMonth()+(t.getFullYear()-e.getFullYear())*12,e=>e.getMonth());$6.range;const B7e=ai(e=>{e.setUTCDate(1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCMonth(e.getUTCMonth()+t)},(e,t)=>t.getUTCMonth()-e.getUTCMonth()+(t.getUTCFullYear()-e.getUTCFullYear())*12,e=>e.getUTCMonth());B7e.range;const Ql=ai(e=>{e.setMonth(0,1),e.setHours(0,0,0,0)},(e,t)=>{e.setFullYear(e.getFullYear()+t)},(e,t)=>t.getFullYear()-e.getFullYear(),e=>e.getFullYear());Ql.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:ai(t=>{t.setFullYear(Math.floor(t.getFullYear()/e)*e),t.setMonth(0,1),t.setHours(0,0,0,0)},(t,n)=>{t.setFullYear(t.getFullYear()+n*e)});Ql.range;const gh=ai(e=>{e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCFullYear(e.getUTCFullYear()+t)},(e,t)=>t.getUTCFullYear()-e.getUTCFullYear(),e=>e.getUTCFullYear());gh.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:ai(t=>{t.setUTCFullYear(Math.floor(t.getUTCFullYear()/e)*e),t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},(t,n)=>{t.setUTCFullYear(t.getUTCFullYear()+n*e)});gh.range;function j7e(e,t,n,r,i,s){const o=[[Lp,1,Nl],[Lp,5,5*Nl],[Lp,15,15*Nl],[Lp,30,30*Nl],[s,1,ta],[s,5,5*ta],[s,15,15*ta],[s,30,30*ta],[i,1,kl],[i,3,3*kl],[i,6,6*kl],[i,12,12*kl],[r,1,Kl],[r,2,2*Kl],[n,1,R6],[t,1,Y7],[t,3,3*Y7],[e,1,MO]];function a(l,c,f){const d=cy).right(o,d);if(h===o.length)return e.every(FN(l/MO,c/MO,f));if(h===0)return KT.every(Math.max(FN(l,c,f),1));const[p,m]=o[d/o[h-1][2]53)return null;"w"in ge||(ge.w=1),"Z"in ge?(Je=BO(A0(ge.y,0,1)),yt=Je.getUTCDay(),Je=yt>4||yt===0?XT.ceil(Je):XT(Je),Je=D6.offset(Je,(ge.V-1)*7),ge.y=Je.getUTCFullYear(),ge.m=Je.getUTCMonth(),ge.d=Je.getUTCDate()+(ge.w+6)%7):(Je=FO(A0(ge.y,0,1)),yt=Je.getDay(),Je=yt>4||yt===0?QT.ceil(Je):QT(Je),Je=n1.offset(Je,(ge.V-1)*7),ge.y=Je.getFullYear(),ge.m=Je.getMonth(),ge.d=Je.getDate()+(ge.w+6)%7)}else("W"in ge||"U"in ge)&&("w"in ge||(ge.w="u"in ge?ge.u%7:"W"in ge?1:0),yt="Z"in ge?BO(A0(ge.y,0,1)).getUTCDay():FO(A0(ge.y,0,1)).getDay(),ge.m=0,ge.d="W"in ge?(ge.w+6)%7+ge.W*7-(yt+5)%7:ge.w+ge.U*7-(yt+6)%7);return"Z"in ge?(ge.H+=ge.Z/100|0,ge.M+=ge.Z%100,BO(ge)):FO(ge)}}function A(de,ve,Ee,ge){for(var nt=0,Je=ve.length,yt=Ee.length,ke,at;nt=yt)return-1;if(ke=ve.charCodeAt(nt++),ke===37){if(ke=ve.charAt(nt++),at=T[ke in K7?ve.charAt(nt++):ke],!at||(ge=at(de,Ee,ge))<0)return-1}else if(ke!=Ee.charCodeAt(ge++))return-1}return ge}function R(de,ve,Ee){var ge=l.exec(ve.slice(Ee));return ge?(de.p=c.get(ge[0].toLowerCase()),Ee+ge[0].length):-1}function F(de,ve,Ee){var ge=h.exec(ve.slice(Ee));return ge?(de.w=p.get(ge[0].toLowerCase()),Ee+ge[0].length):-1}function L(de,ve,Ee){var ge=f.exec(ve.slice(Ee));return ge?(de.w=d.get(ge[0].toLowerCase()),Ee+ge[0].length):-1}function B(de,ve,Ee){var ge=g.exec(ve.slice(Ee));return ge?(de.m=v.get(ge[0].toLowerCase()),Ee+ge[0].length):-1}function J(de,ve,Ee){var ge=m.exec(ve.slice(Ee));return ge?(de.m=y.get(ge[0].toLowerCase()),Ee+ge[0].length):-1}function V(de,ve,Ee){return A(de,t,ve,Ee)}function re(de,ve,Ee){return A(de,n,ve,Ee)}function oe(de,ve,Ee){return A(de,r,ve,Ee)}function ae(de){return o[de.getDay()]}function ee(de){return s[de.getDay()]}function ue(de){return u[de.getMonth()]}function P(de){return a[de.getMonth()]}function W(de){return i[+(de.getHours()>=12)]}function Q(de){return 1+~~(de.getMonth()/3)}function x(de){return o[de.getUTCDay()]}function O(de){return s[de.getUTCDay()]}function $(de){return u[de.getUTCMonth()]}function q(de){return a[de.getUTCMonth()]}function ce(de){return i[+(de.getUTCHours()>=12)]}function fe(de){return 1+~~(de.getUTCMonth()/3)}return{format:function(de){var ve=E(de+="",b);return ve.toString=function(){return de},ve},parse:function(de){var ve=I(de+="",!1);return ve.toString=function(){return de},ve},utcFormat:function(de){var ve=E(de+="",S);return ve.toString=function(){return de},ve},utcParse:function(de){var ve=I(de+="",!0);return ve.toString=function(){return de},ve}}}var K7={"-":"",_:" ",0:"0"},bi=/^\s*\d+/,H7e=/^%/,W7e=/[\\^$*+?|[\]().{}]/g;function Tn(e,t,n){var r=e<0?"-":"",i=(r?-e:e)+"",s=i.length;return r+(s[t.toLowerCase(),n]))}function G7e(e,t,n){var r=bi.exec(t.slice(n,n+1));return r?(e.w=+r[0],n+r[0].length):-1}function Y7e(e,t,n){var r=bi.exec(t.slice(n,n+1));return r?(e.u=+r[0],n+r[0].length):-1}function K7e(e,t,n){var r=bi.exec(t.slice(n,n+2));return r?(e.U=+r[0],n+r[0].length):-1}function Q7e(e,t,n){var r=bi.exec(t.slice(n,n+2));return r?(e.V=+r[0],n+r[0].length):-1}function X7e(e,t,n){var r=bi.exec(t.slice(n,n+2));return r?(e.W=+r[0],n+r[0].length):-1}function Q7(e,t,n){var r=bi.exec(t.slice(n,n+4));return r?(e.y=+r[0],n+r[0].length):-1}function X7(e,t,n){var r=bi.exec(t.slice(n,n+2));return r?(e.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function J7e(e,t,n){var r=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(t.slice(n,n+6));return r?(e.Z=r[1]?0:-(r[2]+(r[3]||"00")),n+r[0].length):-1}function Z7e(e,t,n){var r=bi.exec(t.slice(n,n+1));return r?(e.q=r[0]*3-3,n+r[0].length):-1}function eze(e,t,n){var r=bi.exec(t.slice(n,n+2));return r?(e.m=r[0]-1,n+r[0].length):-1}function J7(e,t,n){var r=bi.exec(t.slice(n,n+2));return r?(e.d=+r[0],n+r[0].length):-1}function tze(e,t,n){var r=bi.exec(t.slice(n,n+3));return r?(e.m=0,e.d=+r[0],n+r[0].length):-1}function Z7(e,t,n){var r=bi.exec(t.slice(n,n+2));return r?(e.H=+r[0],n+r[0].length):-1}function nze(e,t,n){var r=bi.exec(t.slice(n,n+2));return r?(e.M=+r[0],n+r[0].length):-1}function rze(e,t,n){var r=bi.exec(t.slice(n,n+2));return r?(e.S=+r[0],n+r[0].length):-1}function ize(e,t,n){var r=bi.exec(t.slice(n,n+3));return r?(e.L=+r[0],n+r[0].length):-1}function sze(e,t,n){var r=bi.exec(t.slice(n,n+6));return r?(e.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function oze(e,t,n){var r=H7e.exec(t.slice(n,n+1));return r?n+r[0].length:-1}function aze(e,t,n){var r=bi.exec(t.slice(n));return r?(e.Q=+r[0],n+r[0].length):-1}function uze(e,t,n){var r=bi.exec(t.slice(n));return r?(e.s=+r[0],n+r[0].length):-1}function ez(e,t){return Tn(e.getDate(),t,2)}function lze(e,t){return Tn(e.getHours(),t,2)}function cze(e,t){return Tn(e.getHours()%12||12,t,2)}function fze(e,t){return Tn(1+n1.count(Ql(e),e),t,3)}function Bie(e,t){return Tn(e.getMilliseconds(),t,3)}function dze(e,t){return Bie(e,t)+"000"}function hze(e,t){return Tn(e.getMonth()+1,t,2)}function pze(e,t){return Tn(e.getMinutes(),t,2)}function mze(e,t){return Tn(e.getSeconds(),t,2)}function gze(e){var t=e.getDay();return t===0?7:t}function yze(e,t){return Tn(OC.count(Ql(e)-1,e),t,2)}function jie(e){var t=e.getDay();return t>=4||t===0?Wm(e):Wm.ceil(e)}function vze(e,t){return e=jie(e),Tn(Wm.count(Ql(e),e)+(Ql(e).getDay()===4),t,2)}function _ze(e){return e.getDay()}function bze(e,t){return Tn(QT.count(Ql(e)-1,e),t,2)}function wze(e,t){return Tn(e.getFullYear()%100,t,2)}function Eze(e,t){return e=jie(e),Tn(e.getFullYear()%100,t,2)}function Sze(e,t){return Tn(e.getFullYear()%1e4,t,4)}function Tze(e,t){var n=e.getDay();return e=n>=4||n===0?Wm(e):Wm.ceil(e),Tn(e.getFullYear()%1e4,t,4)}function Ize(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+Tn(t/60|0,"0",2)+Tn(t%60,"0",2)}function tz(e,t){return Tn(e.getUTCDate(),t,2)}function xze(e,t){return Tn(e.getUTCHours(),t,2)}function Cze(e,t){return Tn(e.getUTCHours()%12||12,t,2)}function Aze(e,t){return Tn(1+D6.count(gh(e),e),t,3)}function Uie(e,t){return Tn(e.getUTCMilliseconds(),t,3)}function Pze(e,t){return Uie(e,t)+"000"}function Oze(e,t){return Tn(e.getUTCMonth()+1,t,2)}function Rze(e,t){return Tn(e.getUTCMinutes(),t,2)}function Nze(e,t){return Tn(e.getUTCSeconds(),t,2)}function kze(e){var t=e.getUTCDay();return t===0?7:t}function Dze(e,t){return Tn(Fie.count(gh(e)-1,e),t,2)}function Vie(e){var t=e.getUTCDay();return t>=4||t===0?qm(e):qm.ceil(e)}function $ze(e,t){return e=Vie(e),Tn(qm.count(gh(e),e)+(gh(e).getUTCDay()===4),t,2)}function Lze(e){return e.getUTCDay()}function Mze(e,t){return Tn(XT.count(gh(e)-1,e),t,2)}function Fze(e,t){return Tn(e.getUTCFullYear()%100,t,2)}function Bze(e,t){return e=Vie(e),Tn(e.getUTCFullYear()%100,t,2)}function jze(e,t){return Tn(e.getUTCFullYear()%1e4,t,4)}function Uze(e,t){var n=e.getUTCDay();return e=n>=4||n===0?qm(e):qm.ceil(e),Tn(e.getUTCFullYear()%1e4,t,4)}function Vze(){return"+0000"}function nz(){return"%"}function rz(e){return+e}function iz(e){return Math.floor(+e/1e3)}var ip,zie,Ld,L6;zze({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});function zze(e){return ip=z7e(e),zie=ip.format,Ld=ip.parse,L6=ip.utcFormat,ip.utcParse,ip}function Hze(e){return new Date(e)}function Wze(e){return e instanceof Date?+e:+new Date(+e)}function Hie(e,t,n,r,i,s,o,a,u,l){var c=Mie(),f=c.invert,d=c.domain,h=l(".%L"),p=l(":%S"),m=l("%I:%M"),y=l("%I %p"),g=l("%a %d"),v=l("%b %d"),b=l("%B"),S=l("%Y");function T(E){return(u(E)=0))throw new RangeError(`invalid digits: ${n}`);t=r}return e},()=>new XVe(t)}function qie(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function Gie(e){this._context=e}Gie.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:this._context.lineTo(e,t);break}}};function Yie(e){return new Gie(e)}function Kie(e){return e[0]}function Qie(e){return e[1]}function $y(e,t){var n=ci(!0),r=null,i=Yie,s=null,o=Wie(a);e=typeof e=="function"?e:e===void 0?Kie:ci(e),t=typeof t=="function"?t:t===void 0?Qie:ci(t);function a(u){var l,c=(u=qie(u)).length,f,d=!1,h;for(r==null&&(s=i(h=o())),l=0;l<=c;++l)!(l=h;--p)a.point(b[p],S[p]);a.lineEnd(),a.areaEnd()}g&&(b[d]=+e(y,d,f),S[d]=+t(y,d,f),a.point(r?+r(y,d,f):b[d],n?+n(y,d,f):S[d]))}if(v)return a=null,v+""||null}function c(){return $y().defined(i).curve(o).context(s)}return l.x=function(f){return arguments.length?(e=typeof f=="function"?f:ci(+f),r=null,l):e},l.x0=function(f){return arguments.length?(e=typeof f=="function"?f:ci(+f),l):e},l.x1=function(f){return arguments.length?(r=f==null?null:typeof f=="function"?f:ci(+f),l):r},l.y=function(f){return arguments.length?(t=typeof f=="function"?f:ci(+f),n=null,l):t},l.y0=function(f){return arguments.length?(t=typeof f=="function"?f:ci(+f),l):t},l.y1=function(f){return arguments.length?(n=f==null?null:typeof f=="function"?f:ci(+f),l):n},l.lineX0=l.lineY0=function(){return c().x(e).y(t)},l.lineY1=function(){return c().x(e).y(n)},l.lineX1=function(){return c().x(r).y(t)},l.defined=function(f){return arguments.length?(i=typeof f=="function"?f:ci(!!f),l):i},l.curve=function(f){return arguments.length?(o=f,s!=null&&(a=o(s)),l):o},l.context=function(f){return arguments.length?(f==null?s=a=null:a=o(s=f),l):s},l}function sz(e,t,n){e._context.bezierCurveTo((2*e._x0+e._x1)/3,(2*e._y0+e._y1)/3,(e._x0+2*e._x1)/3,(e._y0+2*e._y1)/3,(e._x0+4*e._x1+t)/6,(e._y0+4*e._y1+n)/6)}function Jie(e){this._context=e}Jie.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:sz(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:sz(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function Mp(e){return new Jie(e)}function J0(e,t,n){this.k=e,this.x=t,this.y=n}J0.prototype={constructor:J0,scale:function(e){return e===1?this:new J0(this.k*e,this.x,this.y)},translate:function(e,t){return e===0&t===0?this:new J0(this.k,this.x+this.k*e,this.y+this.k*t)},apply:function(e){return[e[0]*this.k+this.x,e[1]*this.k+this.y]},applyX:function(e){return e*this.k+this.x},applyY:function(e){return e*this.k+this.y},invert:function(e){return[(e[0]-this.x)/this.k,(e[1]-this.y)/this.k]},invertX:function(e){return(e-this.x)/this.k},invertY:function(e){return(e-this.y)/this.k},rescaleX:function(e){return e.copy().domain(e.range().map(this.invertX,this).map(e.invert,e))},rescaleY:function(e){return e.copy().domain(e.range().map(this.invertY,this).map(e.invert,e))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}};J0.prototype;function qze(){const e=new Map;return{listen(t,n){return e.has(t)||e.set(t,[]),e.get(t).push(n),()=>{e.set(t,(e.get(t)||[]).filter(r=>r!==n))}},fire(t,n){const r=e.get(t);r&&r.forEach(i=>i(n))}}}let Mb;const Gze=new Uint8Array(16);function Yze(){if(!Mb&&(Mb=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!Mb))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return Mb(Gze)}const Ti=[];for(let e=0;e<256;++e)Ti.push((e+256).toString(16).slice(1));function Kze(e,t=0){return(Ti[e[t+0]]+Ti[e[t+1]]+Ti[e[t+2]]+Ti[e[t+3]]+"-"+Ti[e[t+4]]+Ti[e[t+5]]+"-"+Ti[e[t+6]]+Ti[e[t+7]]+"-"+Ti[e[t+8]]+Ti[e[t+9]]+"-"+Ti[e[t+10]]+Ti[e[t+11]]+Ti[e[t+12]]+Ti[e[t+13]]+Ti[e[t+14]]+Ti[e[t+15]]).toLowerCase()}const Qze=typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto),oz={randomUUID:Qze};function az(e,t,n){if(oz.randomUUID&&!t&&!e)return oz.randomUUID();e=e||{};const r=e.random||(e.rng||Yze)();if(r[6]=r[6]&15|64,r[8]=r[8]&63|128,t){n=n||0;for(let i=0;i<16;++i)t[n+i]=r[i];return t}return Kze(r)}let Vu=class{static get(){let t=az();for(;this.ids.has(t);)t=az();return this.ids.set(t,!0),t}};Vu.ids=new Map;function zu(e){return"parent"in e}function Xze(e){const{label:t=void 0,state:n,initialArtifact:r,initialMetadata:i}=e,s={annotation:[],bookmark:[]},o=Object.keys(i||{}).reduce((u,l)=>(u[l]=[],i&&i[l]&&u[l].push({type:l,id:Vu.get(),val:i[l],createdOn:Date.now()}),u),s),a=r?[{id:Vu.get(),createdOn:Date.now(),val:r}]:[];return{id:Vu.get(),label:t||"Root",event:"Root",children:[],level:0,createdOn:Date.now(),meta:o,artifacts:a,state:{type:"checkpoint",val:n}}}function Jze({parent:e,state:t,label:n,sideEffects:r={do:[],undo:[]},initialMetadata:i,initialArtifact:s,event:o}){const a={annotation:[],bookmark:[]},u=Object.keys(i||{}).reduce((c,f)=>(c[f]=[],i&&i[f]&&c[f].push({type:f,id:Vu.get(),val:i[f],createdOn:Date.now()}),c),a),l=s?[{id:Vu.get(),createdOn:Date.now(),val:s}]:[];return{id:Vu.get(),label:n,event:o,children:[],parent:e.id,createdOn:Date.now(),meta:u,artifacts:l,sideEffects:r,state:t,level:e.level+1}}function Cr(e){for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;r3?t.i-4:t.i:Array.isArray(e)?1:RC(e)?2:NC(e)?3:0}function Dv(e,t){return Rf(e)===2?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function Bw(e,t){return Rf(e)===2?e.get(t):e[t]}function Zie(e,t,n){var r=Rf(e);r===2?e.set(t,n):r===3?(e.delete(t),e.add(n)):e[t]=n}function Zze(e,t){return e===t?e!==0||1/e==1/t:e!=e&&t!=t}function RC(e){return sHe&&e instanceof Map}function NC(e){return oHe&&e instanceof Set}function yd(e){return e.o||e.t}function M6(e){if(Array.isArray(e))return Array.prototype.slice.call(e);var t=lHe(e);delete t[Oo];for(var n=V6(t),r=0;r1&&(e.set=e.add=e.clear=e.delete=eHe),Object.freeze(e),t&&Gm(e,function(n,r){return F6(r,!0)},!0)),e}function eHe(){Cr(2)}function B6(e){return e==null||typeof e!="object"||Object.isFrozen(e)}function Hu(e){var t=GN[e];return t||Cr(18,e),t}function tHe(e,t){GN[e]||(GN[e]=t)}function uz(){return{}.NODE_ENV==="production"||Ym||Cr(0),Ym}function jO(e,t){t&&(Hu("Patches"),e.u=[],e.s=[],e.v=t)}function JT(e){HN(e),e.p.forEach(nHe),e.p=null}function HN(e){e===Ym&&(Ym=e.l)}function lz(e){return Ym={p:[],l:Ym,h:e,m:!0,_:0}}function nHe(e){var t=e[Oo];t.i===0||t.i===1?t.j():t.O=!0}function UO(e,t){t._=t.p.length;var n=t.p[0],r=e!==void 0&&e!==n;return t.h.g||Hu("ES5").S(t,e,r),r?(n[Oo].P&&(JT(t),Cr(4)),Of(e)&&(e=ZT(t,e),t.l||eI(t,e)),t.u&&Hu("Patches").M(n[Oo].t,e,t.u,t.s)):e=ZT(t,n,[]),JT(t),t.u&&t.v(t.u,t.s),e!==U6?e:void 0}function ZT(e,t,n){if(B6(t))return t;var r=t[Oo];if(!r)return Gm(t,function(s,o){return cz(e,r,t,s,o,n)},!0),t;if(r.A!==e)return t;if(!r.P)return eI(e,r.t,!0),r.t;if(!r.I){r.I=!0,r.A._--;var i=r.i===4||r.i===5?r.o=M6(r.k):r.o;Gm(r.i===3?new Set(i):i,function(s,o){return cz(e,r,i,s,o,n)}),eI(e,i,!1),n&&e.u&&Hu("Patches").R(r,n,e.u,e.s)}return r.o}function cz(e,t,n,r,i,s){if({}.NODE_ENV!=="production"&&i===n&&Cr(5),yh(i)){var o=ZT(e,i,s&&t&&t.i!==3&&!Dv(t.D,r)?s.concat(r):void 0);if(Zie(n,r,o),!yh(o))return;e.m=!1}if(Of(i)&&!B6(i)){if(!e.h.F&&e._<1)return;ZT(e,i),t&&t.A.l||eI(e,i)}}function eI(e,t,n){n===void 0&&(n=!1),e.h.F&&e.m&&F6(t,n)}function VO(e,t){var n=e[Oo];return(n?yd(n):e)[t]}function fz(e,t){if(t in e)for(var n=Object.getPrototypeOf(e);n;){var r=Object.getOwnPropertyDescriptor(n,t);if(r)return r;n=Object.getPrototypeOf(n)}}function WN(e){e.P||(e.P=!0,e.l&&WN(e.l))}function zO(e){e.o||(e.o=M6(e.t))}function qN(e,t,n){var r=RC(t)?Hu("MapSet").N(t,n):NC(t)?Hu("MapSet").T(t,n):e.g?function(i,s){var o=Array.isArray(i),a={i:o?1:0,A:s?s.A:uz(),P:!1,I:!1,D:{},l:s,t:i,k:null,o:null,j:null,C:!1},u=a,l=YN;o&&(u=[a],l=Z0);var c=Proxy.revocable(u,l),f=c.revoke,d=c.proxy;return a.k=d,a.j=f,d}(t,n):Hu("ES5").J(t,n);return(n?n.A:uz()).p.push(r),r}function rHe(e){return yh(e)||Cr(22,e),function t(n){if(!Of(n))return n;var r,i=n[Oo],s=Rf(n);if(i){if(!i.P&&(i.i<4||!Hu("ES5").K(i)))return i.t;i.I=!0,r=dz(n,s),i.I=!1}else r=dz(n,s);return Gm(r,function(o,a){i&&Bw(i.t,o)===a||Zie(r,o,t(a))}),s===3?new Set(r):r}(e)}function dz(e,t){switch(t){case 2:return new Map(e);case 3:return Array.from(e)}return M6(e)}function iHe(){function e(r){if(!Of(r))return r;if(Array.isArray(r))return r.map(e);if(RC(r))return new Map(Array.from(r.entries()).map(function(o){return[o[0],e(o[1])]}));if(NC(r))return new Set(Array.from(r).map(e));var i=Object.create(Object.getPrototypeOf(r));for(var s in r)i[s]=e(r[s]);return Dv(r,Ly)&&(i[Ly]=r[Ly]),i}function t(r){return yh(r)?e(r):r}var n="add";tHe("Patches",{$:function(r,i){return i.forEach(function(s){for(var o=s.path,a=s.op,u=r,l=0;l1?g-1:0),b=1;b1?c-1:0),d=1;d=0;i--){var s=r[i];if(s.path.length===0&&s.op==="replace"){n=s.value;break}}i>-1&&(r=r.slice(i+1));var o=Hu("Patches").$;return yh(n)?o(n,r):this.produce(n,function(a){return o(a,r)})},e}(),Ro=new cHe,fHe=Ro.produce;Ro.produceWithPatches.bind(Ro);Ro.setAutoFreeze.bind(Ro);Ro.setUseProxies.bind(Ro);Ro.applyPatches.bind(Ro);Ro.createDraft.bind(Ro);Ro.finishDraft.bind(Ro);function dHe(e,t={}){const{artifact:n=void 0,metadata:r=void 0,rootLabel:i="Root"}=t,s=Xze({state:e,label:i,initialArtifact:n,initialMetadata:r}),o={nodes:{[s.id]:s},root:s.id,current:s.id};return One({name:"provenance-graph",initialState:o,reducers:{addMetadata(a,u){const{id:l,meta:c}=u.payload,f=a.nodes[l].meta,d=Object.keys(c).reduce((h,p)=>(h[p]||(h[p]=[]),h[p].push({type:p,id:Vu.get(),val:c[p],createdOn:Date.now()}),h),f);a.nodes[u.payload.id].meta=d},addArtifact(a,u){a.nodes[u.payload.id].artifacts.push({id:Vu.get(),createdOn:Date.now(),val:u.payload.artifact})},changeCurrent(a,u){a.current=u.payload},addNode(a,{payload:u}){a.nodes[u.id]=u,a.nodes[u.parent].children.push(u.id),a.current=u.id},load(a,{payload:u}){return u}}})}function hHe(e){const t=new Map,{reducer:n,actions:r,getInitialState:i}=dHe(e),s=wMe();s.startListening({matcher:eV(r.changeCurrent,r.addNode),effect:(a,u)=>{u.cancelActiveListeners(),t.forEach(l=>{const c=eV(r.addNode)(a),{skipOnNew:f}=l.config;f&&c||l.func(c?"new":"traversal")})}});const o=Ane({reducer:n,middleware:a=>a().prepend(s.middleware)});return{initialState:i(),get backend(){return o.getState()},get current(){return o.getState().nodes[o.getState().current]},get root(){return o.getState().nodes[o.getState().root]},currentChange(a,u){const l={id:Vu.get(),func:a,config:u};return t.set(l.id,l),()=>t.delete(l.id)},update:o.dispatch,...r}}/*! +`)}function l(f){return f.map(c).join(e)}function c(f){return f==null?"":f instanceof Date?t7e(f):t.test(f+="")?'"'+f.replace(/"/g,'""')+'"':f}return{parse:r,parseRows:i,format:o,formatBody:a,formatRows:u,formatRow:l,formatValue:c}}var r7e=n7e(","),i7e=r7e.parse;function s7e(e){if(!e.ok)throw new Error(e.status+" "+e.statusText);return e.text()}function o7e(e,t){return fetch(e,t).then(s7e)}function a7e(e){return function(t,n,r){return arguments.length===2&&typeof n=="function"&&(r=n,n=void 0),o7e(t,n).then(function(i){return e(i,r)})}}var u7e=a7e(i7e);function l7e(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function GT(e,t){if((n=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"))<0)return null;var n,r=e.slice(0,n);return[r.length>1?r[0]+r.slice(2):r,+e.slice(n+1)]}function Hm(e){return e=GT(Math.abs(e)),e?e[1]:NaN}function c7e(e,t){return function(n,r){for(var i=n.length,s=[],o=0,a=e[0],u=0;i>0&&a>0&&(u+a+1>r&&(a=Math.max(1,r-u)),s.push(n.substring(i-=a,i+a)),!((u+=a+1)>r));)a=e[o=(o+1)%e.length];return s.reverse().join(t)}}function f7e(e){return function(t){return t.replace(/[0-9]/g,function(n){return e[+n]})}}var d7e=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function YT(e){if(!(t=d7e.exec(e)))throw new Error("invalid format: "+e);var t;return new C6({fill:t[1],align:t[2],sign:t[3],symbol:t[4],zero:t[5],width:t[6],comma:t[7],precision:t[8]&&t[8].slice(1),trim:t[9],type:t[10]})}YT.prototype=C6.prototype;function C6(e){this.fill=e.fill===void 0?" ":e.fill+"",this.align=e.align===void 0?">":e.align+"",this.sign=e.sign===void 0?"-":e.sign+"",this.symbol=e.symbol===void 0?"":e.symbol+"",this.zero=!!e.zero,this.width=e.width===void 0?void 0:+e.width,this.comma=!!e.comma,this.precision=e.precision===void 0?void 0:+e.precision,this.trim=!!e.trim,this.type=e.type===void 0?"":e.type+""}C6.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(this.width===void 0?"":Math.max(1,this.width|0))+(this.comma?",":"")+(this.precision===void 0?"":"."+Math.max(0,this.precision|0))+(this.trim?"~":"")+this.type};function h7e(e){e:for(var t=e.length,n=1,r=-1,i;n0&&(r=0);break}return r>0?e.slice(0,r)+e.slice(i+1):e}var Die;function p7e(e,t){var n=GT(e,t);if(!n)return e+"";var r=n[0],i=n[1],s=i-(Die=Math.max(-8,Math.min(8,Math.floor(i/3)))*3)+1,o=r.length;return s===o?r:s>o?r+new Array(s-o+1).join("0"):s>0?r.slice(0,s)+"."+r.slice(s):"0."+new Array(1-s).join("0")+GT(e,Math.max(0,t+s-1))[0]}function U7(e,t){var n=GT(e,t);if(!n)return e+"";var r=n[0],i=n[1];return i<0?"0."+new Array(-i).join("0")+r:r.length>i+1?r.slice(0,i+1)+"."+r.slice(i+1):r+new Array(i-r.length+2).join("0")}const V7={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:l7e,e:(e,t)=>e.toExponential(t),f:(e,t)=>e.toFixed(t),g:(e,t)=>e.toPrecision(t),o:e=>Math.round(e).toString(8),p:(e,t)=>U7(e*100,t),r:U7,s:p7e,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function z7(e){return e}var H7=Array.prototype.map,W7=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function m7e(e){var t=e.grouping===void 0||e.thousands===void 0?z7:c7e(H7.call(e.grouping,Number),e.thousands+""),n=e.currency===void 0?"":e.currency[0]+"",r=e.currency===void 0?"":e.currency[1]+"",i=e.decimal===void 0?".":e.decimal+"",s=e.numerals===void 0?z7:f7e(H7.call(e.numerals,String)),o=e.percent===void 0?"%":e.percent+"",a=e.minus===void 0?"−":e.minus+"",u=e.nan===void 0?"NaN":e.nan+"";function l(f){f=YT(f);var d=f.fill,h=f.align,p=f.sign,m=f.symbol,y=f.zero,g=f.width,v=f.comma,b=f.precision,S=f.trim,T=f.type;T==="n"?(v=!0,T="g"):V7[T]||(b===void 0&&(b=12),S=!0,T="g"),(y||d==="0"&&h==="=")&&(y=!0,d="0",h="=");var E=m==="$"?n:m==="#"&&/[boxX]/.test(T)?"0"+T.toLowerCase():"",I=m==="$"?r:/[%p]/.test(T)?o:"",A=V7[T],R=/[defgprs%]/.test(T);b=b===void 0?6:/[gprs]/.test(T)?Math.max(1,Math.min(21,b)):Math.max(0,Math.min(20,b));function F(L){var B=E,J=I,V,re,oe;if(T==="c")J=A(L)+J,L="";else{L=+L;var ae=L<0||1/L<0;if(L=isNaN(L)?u:A(Math.abs(L),b),S&&(L=h7e(L)),ae&&+L==0&&p!=="+"&&(ae=!1),B=(ae?p==="("?p:a:p==="-"||p==="("?"":p)+B,J=(T==="s"?W7[8+Die/3]:"")+J+(ae&&p==="("?")":""),R){for(V=-1,re=L.length;++Voe||oe>57){J=(oe===46?i+L.slice(V+1):L.slice(V))+J,L=L.slice(0,V);break}}}v&&!y&&(L=t(L,1/0));var ee=B.length+L.length+J.length,ue=ee>1)+B+L+J+ue.slice(ee);break;default:L=ue+B+L+J;break}return s(L)}return F.toString=function(){return f+""},F}function c(f,d){var h=l((f=YT(f),f.type="f",f)),p=Math.max(-8,Math.min(8,Math.floor(Hm(d)/3)))*3,m=Math.pow(10,-p),y=W7[8+p/3];return function(g){return h(m*g)+y}}return{format:l,formatPrefix:c}}var Lb,yf,$ie;g7e({thousands:",",grouping:[3],currency:["$",""]});function g7e(e){return Lb=m7e(e),yf=Lb.format,$ie=Lb.formatPrefix,Lb}function y7e(e){return Math.max(0,-Hm(Math.abs(e)))}function v7e(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(Hm(t)/3)))*3-Hm(Math.abs(e)))}function _7e(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,Hm(t)-Hm(e))+1}function A6(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e);break}return this}const q7=Symbol("implicit");function P6(){var e=new $N,t=[],n=[],r=q7;function i(s){let o=e.get(s);if(o===void 0){if(r!==q7)return r;e.set(s,o=t.push(s)-1)}return n[o%n.length]}return i.domain=function(s){if(!arguments.length)return t.slice();t=[],e=new $N;for(const o of s)e.has(o)||e.set(o,t.push(o)-1);return i},i.range=function(s){return arguments.length?(n=Array.from(s),i):n.slice()},i.unknown=function(s){return arguments.length?(r=s,i):r},i.copy=function(){return P6(t,n).unknown(r)},A6.apply(i,arguments),i}function b7e(e){return function(){return e}}function w7e(e){return+e}var G7=[0,1];function $p(e){return e}function VN(e,t){return(t-=e=+e)?function(n){return(n-e)/t}:b7e(isNaN(t)?NaN:.5)}function E7e(e,t){var n;return e>t&&(n=e,e=t,t=n),function(r){return Math.max(e,Math.min(t,r))}}function S7e(e,t,n){var r=e[0],i=e[1],s=t[0],o=t[1];return i2?T7e:S7e,u=l=null,f}function f(d){return d==null||isNaN(d=+d)?s:(u||(u=a(e.map(r),t,n)))(r(o(d)))}return f.invert=function(d){return o(i((l||(l=a(t,e.map(r),qT)))(d)))},f.domain=function(d){return arguments.length?(e=Array.from(d,w7e),c()):e.slice()},f.range=function(d){return arguments.length?(t=Array.from(d),c()):t.slice()},f.rangeRound=function(d){return t=Array.from(d),n=KVe,c()},f.clamp=function(d){return arguments.length?(o=d?!0:$p,c()):o!==$p},f.interpolate=function(d){return arguments.length?(n=d,c()):n},f.unknown=function(d){return arguments.length?(s=d,f):s},function(d,h){return r=d,i=h,c()}}function Mie(){return I7e()($p,$p)}function x7e(e,t,n,r){var i=MN(e,t,n),s;switch(r=YT(r??",f"),r.type){case"s":{var o=Math.max(Math.abs(e),Math.abs(t));return r.precision==null&&!isNaN(s=v7e(i,o))&&(r.precision=s),$ie(r,o)}case"":case"e":case"g":case"p":case"r":{r.precision==null&&!isNaN(s=_7e(i,Math.max(Math.abs(e),Math.abs(t))))&&(r.precision=s-(r.type==="e"));break}case"f":case"%":{r.precision==null&&!isNaN(s=y7e(i))&&(r.precision=s-(r.type==="%")*2);break}}return yf(r)}function C7e(e){var t=e.domain;return e.ticks=function(n){var r=t();return TVe(r[0],r[r.length-1],n??10)},e.tickFormat=function(n,r){var i=t();return x7e(i[0],i[i.length-1],n??10,r)},e.nice=function(n){n==null&&(n=10);var r=t(),i=0,s=r.length-1,o=r[i],a=r[s],u,l,c=10;for(a0;){if(l=LN(o,a,n),l===u)return r[i]=o,r[s]=a,t(r);if(l>0)o=Math.floor(o/l)*l,a=Math.ceil(a/l)*l;else if(l<0)o=Math.ceil(o*l)/l,a=Math.floor(a*l)/l;else break;u=l}return e},e}function mh(){var e=Mie();return e.copy=function(){return Lie(e,mh())},A6.apply(e,arguments),C7e(e)}function A7e(e,t){e=e.slice();var n=0,r=e.length-1,i=e[n],s=e[r],o;return s(e(s=new Date(+s)),s),i.ceil=s=>(e(s=new Date(s-1)),t(s,1),e(s),s),i.round=s=>{const o=i(s),a=i.ceil(s);return s-o(t(s=new Date(+s),o==null?1:Math.floor(o)),s),i.range=(s,o,a)=>{const u=[];if(s=i.ceil(s),a=a==null?1:Math.floor(a),!(s0))return u;let l;do u.push(l=new Date(+s)),t(s,a),e(s);while(lai(o=>{if(o>=o)for(;e(o),!s(o);)o.setTime(o-1)},(o,a)=>{if(o>=o)if(a<0)for(;++a<=0;)for(;t(o,-1),!s(o););else for(;--a>=0;)for(;t(o,1),!s(o););}),n&&(i.count=(s,o)=>(DO.setTime(+s),$O.setTime(+o),e(DO),e($O),Math.floor(n(DO,$O))),i.every=s=>(s=Math.floor(s),!isFinite(s)||!(s>0)?null:s>1?i.filter(r?o=>r(o)%s===0:o=>i.count(0,o)%s===0):i)),i}const KT=ai(()=>{},(e,t)=>{e.setTime(+e+t)},(e,t)=>t-e);KT.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?ai(t=>{t.setTime(Math.floor(t/e)*e)},(t,n)=>{t.setTime(+t+n*e)},(t,n)=>(n-t)/e):KT);KT.range;const Nl=1e3,ta=Nl*60,kl=ta*60,Kl=kl*24,O6=Kl*7,Y7=Kl*30,LO=Kl*365,Lp=ai(e=>{e.setTime(e-e.getMilliseconds())},(e,t)=>{e.setTime(+e+t*Nl)},(e,t)=>(t-e)/Nl,e=>e.getUTCSeconds());Lp.range;const R6=ai(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*Nl)},(e,t)=>{e.setTime(+e+t*ta)},(e,t)=>(t-e)/ta,e=>e.getMinutes());R6.range;const P7e=ai(e=>{e.setUTCSeconds(0,0)},(e,t)=>{e.setTime(+e+t*ta)},(e,t)=>(t-e)/ta,e=>e.getUTCMinutes());P7e.range;const N6=ai(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*Nl-e.getMinutes()*ta)},(e,t)=>{e.setTime(+e+t*kl)},(e,t)=>(t-e)/kl,e=>e.getHours());N6.range;const O7e=ai(e=>{e.setUTCMinutes(0,0,0)},(e,t)=>{e.setTime(+e+t*kl)},(e,t)=>(t-e)/kl,e=>e.getUTCHours());O7e.range;const n1=ai(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*ta)/Kl,e=>e.getDate()-1);n1.range;const k6=ai(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/Kl,e=>e.getUTCDate()-1);k6.range;const R7e=ai(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/Kl,e=>Math.floor(e/Kl));R7e.range;function jh(e){return ai(t=>{t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)},(t,n)=>{t.setDate(t.getDate()+n*7)},(t,n)=>(n-t-(n.getTimezoneOffset()-t.getTimezoneOffset())*ta)/O6)}const OC=jh(0),QT=jh(1),N7e=jh(2),k7e=jh(3),Wm=jh(4),D7e=jh(5),$7e=jh(6);OC.range;QT.range;N7e.range;k7e.range;Wm.range;D7e.range;$7e.range;function Uh(e){return ai(t=>{t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)},(t,n)=>{t.setUTCDate(t.getUTCDate()+n*7)},(t,n)=>(n-t)/O6)}const Fie=Uh(0),XT=Uh(1),L7e=Uh(2),M7e=Uh(3),qm=Uh(4),F7e=Uh(5),B7e=Uh(6);Fie.range;XT.range;L7e.range;M7e.range;qm.range;F7e.range;B7e.range;const D6=ai(e=>{e.setDate(1),e.setHours(0,0,0,0)},(e,t)=>{e.setMonth(e.getMonth()+t)},(e,t)=>t.getMonth()-e.getMonth()+(t.getFullYear()-e.getFullYear())*12,e=>e.getMonth());D6.range;const j7e=ai(e=>{e.setUTCDate(1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCMonth(e.getUTCMonth()+t)},(e,t)=>t.getUTCMonth()-e.getUTCMonth()+(t.getUTCFullYear()-e.getUTCFullYear())*12,e=>e.getUTCMonth());j7e.range;const Ql=ai(e=>{e.setMonth(0,1),e.setHours(0,0,0,0)},(e,t)=>{e.setFullYear(e.getFullYear()+t)},(e,t)=>t.getFullYear()-e.getFullYear(),e=>e.getFullYear());Ql.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:ai(t=>{t.setFullYear(Math.floor(t.getFullYear()/e)*e),t.setMonth(0,1),t.setHours(0,0,0,0)},(t,n)=>{t.setFullYear(t.getFullYear()+n*e)});Ql.range;const gh=ai(e=>{e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCFullYear(e.getUTCFullYear()+t)},(e,t)=>t.getUTCFullYear()-e.getUTCFullYear(),e=>e.getUTCFullYear());gh.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:ai(t=>{t.setUTCFullYear(Math.floor(t.getUTCFullYear()/e)*e),t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},(t,n)=>{t.setUTCFullYear(t.getUTCFullYear()+n*e)});gh.range;function U7e(e,t,n,r,i,s){const o=[[Lp,1,Nl],[Lp,5,5*Nl],[Lp,15,15*Nl],[Lp,30,30*Nl],[s,1,ta],[s,5,5*ta],[s,15,15*ta],[s,30,30*ta],[i,1,kl],[i,3,3*kl],[i,6,6*kl],[i,12,12*kl],[r,1,Kl],[r,2,2*Kl],[n,1,O6],[t,1,Y7],[t,3,3*Y7],[e,1,LO]];function a(l,c,f){const d=cy).right(o,d);if(h===o.length)return e.every(MN(l/LO,c/LO,f));if(h===0)return KT.every(Math.max(MN(l,c,f),1));const[p,m]=o[d/o[h-1][2]53)return null;"w"in ge||(ge.w=1),"Z"in ge?(Je=FO(A0(ge.y,0,1)),yt=Je.getUTCDay(),Je=yt>4||yt===0?XT.ceil(Je):XT(Je),Je=k6.offset(Je,(ge.V-1)*7),ge.y=Je.getUTCFullYear(),ge.m=Je.getUTCMonth(),ge.d=Je.getUTCDate()+(ge.w+6)%7):(Je=MO(A0(ge.y,0,1)),yt=Je.getDay(),Je=yt>4||yt===0?QT.ceil(Je):QT(Je),Je=n1.offset(Je,(ge.V-1)*7),ge.y=Je.getFullYear(),ge.m=Je.getMonth(),ge.d=Je.getDate()+(ge.w+6)%7)}else("W"in ge||"U"in ge)&&("w"in ge||(ge.w="u"in ge?ge.u%7:"W"in ge?1:0),yt="Z"in ge?FO(A0(ge.y,0,1)).getUTCDay():MO(A0(ge.y,0,1)).getDay(),ge.m=0,ge.d="W"in ge?(ge.w+6)%7+ge.W*7-(yt+5)%7:ge.w+ge.U*7-(yt+6)%7);return"Z"in ge?(ge.H+=ge.Z/100|0,ge.M+=ge.Z%100,FO(ge)):MO(ge)}}function A(de,ve,Ee,ge){for(var nt=0,Je=ve.length,yt=Ee.length,ke,at;nt=yt)return-1;if(ke=ve.charCodeAt(nt++),ke===37){if(ke=ve.charAt(nt++),at=T[ke in K7?ve.charAt(nt++):ke],!at||(ge=at(de,Ee,ge))<0)return-1}else if(ke!=Ee.charCodeAt(ge++))return-1}return ge}function R(de,ve,Ee){var ge=l.exec(ve.slice(Ee));return ge?(de.p=c.get(ge[0].toLowerCase()),Ee+ge[0].length):-1}function F(de,ve,Ee){var ge=h.exec(ve.slice(Ee));return ge?(de.w=p.get(ge[0].toLowerCase()),Ee+ge[0].length):-1}function L(de,ve,Ee){var ge=f.exec(ve.slice(Ee));return ge?(de.w=d.get(ge[0].toLowerCase()),Ee+ge[0].length):-1}function B(de,ve,Ee){var ge=g.exec(ve.slice(Ee));return ge?(de.m=v.get(ge[0].toLowerCase()),Ee+ge[0].length):-1}function J(de,ve,Ee){var ge=m.exec(ve.slice(Ee));return ge?(de.m=y.get(ge[0].toLowerCase()),Ee+ge[0].length):-1}function V(de,ve,Ee){return A(de,t,ve,Ee)}function re(de,ve,Ee){return A(de,n,ve,Ee)}function oe(de,ve,Ee){return A(de,r,ve,Ee)}function ae(de){return o[de.getDay()]}function ee(de){return s[de.getDay()]}function ue(de){return u[de.getMonth()]}function P(de){return a[de.getMonth()]}function W(de){return i[+(de.getHours()>=12)]}function Q(de){return 1+~~(de.getMonth()/3)}function x(de){return o[de.getUTCDay()]}function O(de){return s[de.getUTCDay()]}function $(de){return u[de.getUTCMonth()]}function q(de){return a[de.getUTCMonth()]}function ce(de){return i[+(de.getUTCHours()>=12)]}function fe(de){return 1+~~(de.getUTCMonth()/3)}return{format:function(de){var ve=E(de+="",b);return ve.toString=function(){return de},ve},parse:function(de){var ve=I(de+="",!1);return ve.toString=function(){return de},ve},utcFormat:function(de){var ve=E(de+="",S);return ve.toString=function(){return de},ve},utcParse:function(de){var ve=I(de+="",!0);return ve.toString=function(){return de},ve}}}var K7={"-":"",_:" ",0:"0"},bi=/^\s*\d+/,W7e=/^%/,q7e=/[\\^$*+?|[\]().{}]/g;function Tn(e,t,n){var r=e<0?"-":"",i=(r?-e:e)+"",s=i.length;return r+(s[t.toLowerCase(),n]))}function Y7e(e,t,n){var r=bi.exec(t.slice(n,n+1));return r?(e.w=+r[0],n+r[0].length):-1}function K7e(e,t,n){var r=bi.exec(t.slice(n,n+1));return r?(e.u=+r[0],n+r[0].length):-1}function Q7e(e,t,n){var r=bi.exec(t.slice(n,n+2));return r?(e.U=+r[0],n+r[0].length):-1}function X7e(e,t,n){var r=bi.exec(t.slice(n,n+2));return r?(e.V=+r[0],n+r[0].length):-1}function J7e(e,t,n){var r=bi.exec(t.slice(n,n+2));return r?(e.W=+r[0],n+r[0].length):-1}function Q7(e,t,n){var r=bi.exec(t.slice(n,n+4));return r?(e.y=+r[0],n+r[0].length):-1}function X7(e,t,n){var r=bi.exec(t.slice(n,n+2));return r?(e.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function Z7e(e,t,n){var r=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(t.slice(n,n+6));return r?(e.Z=r[1]?0:-(r[2]+(r[3]||"00")),n+r[0].length):-1}function eze(e,t,n){var r=bi.exec(t.slice(n,n+1));return r?(e.q=r[0]*3-3,n+r[0].length):-1}function tze(e,t,n){var r=bi.exec(t.slice(n,n+2));return r?(e.m=r[0]-1,n+r[0].length):-1}function J7(e,t,n){var r=bi.exec(t.slice(n,n+2));return r?(e.d=+r[0],n+r[0].length):-1}function nze(e,t,n){var r=bi.exec(t.slice(n,n+3));return r?(e.m=0,e.d=+r[0],n+r[0].length):-1}function Z7(e,t,n){var r=bi.exec(t.slice(n,n+2));return r?(e.H=+r[0],n+r[0].length):-1}function rze(e,t,n){var r=bi.exec(t.slice(n,n+2));return r?(e.M=+r[0],n+r[0].length):-1}function ize(e,t,n){var r=bi.exec(t.slice(n,n+2));return r?(e.S=+r[0],n+r[0].length):-1}function sze(e,t,n){var r=bi.exec(t.slice(n,n+3));return r?(e.L=+r[0],n+r[0].length):-1}function oze(e,t,n){var r=bi.exec(t.slice(n,n+6));return r?(e.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function aze(e,t,n){var r=W7e.exec(t.slice(n,n+1));return r?n+r[0].length:-1}function uze(e,t,n){var r=bi.exec(t.slice(n));return r?(e.Q=+r[0],n+r[0].length):-1}function lze(e,t,n){var r=bi.exec(t.slice(n));return r?(e.s=+r[0],n+r[0].length):-1}function ez(e,t){return Tn(e.getDate(),t,2)}function cze(e,t){return Tn(e.getHours(),t,2)}function fze(e,t){return Tn(e.getHours()%12||12,t,2)}function dze(e,t){return Tn(1+n1.count(Ql(e),e),t,3)}function Bie(e,t){return Tn(e.getMilliseconds(),t,3)}function hze(e,t){return Bie(e,t)+"000"}function pze(e,t){return Tn(e.getMonth()+1,t,2)}function mze(e,t){return Tn(e.getMinutes(),t,2)}function gze(e,t){return Tn(e.getSeconds(),t,2)}function yze(e){var t=e.getDay();return t===0?7:t}function vze(e,t){return Tn(OC.count(Ql(e)-1,e),t,2)}function jie(e){var t=e.getDay();return t>=4||t===0?Wm(e):Wm.ceil(e)}function _ze(e,t){return e=jie(e),Tn(Wm.count(Ql(e),e)+(Ql(e).getDay()===4),t,2)}function bze(e){return e.getDay()}function wze(e,t){return Tn(QT.count(Ql(e)-1,e),t,2)}function Eze(e,t){return Tn(e.getFullYear()%100,t,2)}function Sze(e,t){return e=jie(e),Tn(e.getFullYear()%100,t,2)}function Tze(e,t){return Tn(e.getFullYear()%1e4,t,4)}function Ize(e,t){var n=e.getDay();return e=n>=4||n===0?Wm(e):Wm.ceil(e),Tn(e.getFullYear()%1e4,t,4)}function xze(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+Tn(t/60|0,"0",2)+Tn(t%60,"0",2)}function tz(e,t){return Tn(e.getUTCDate(),t,2)}function Cze(e,t){return Tn(e.getUTCHours(),t,2)}function Aze(e,t){return Tn(e.getUTCHours()%12||12,t,2)}function Pze(e,t){return Tn(1+k6.count(gh(e),e),t,3)}function Uie(e,t){return Tn(e.getUTCMilliseconds(),t,3)}function Oze(e,t){return Uie(e,t)+"000"}function Rze(e,t){return Tn(e.getUTCMonth()+1,t,2)}function Nze(e,t){return Tn(e.getUTCMinutes(),t,2)}function kze(e,t){return Tn(e.getUTCSeconds(),t,2)}function Dze(e){var t=e.getUTCDay();return t===0?7:t}function $ze(e,t){return Tn(Fie.count(gh(e)-1,e),t,2)}function Vie(e){var t=e.getUTCDay();return t>=4||t===0?qm(e):qm.ceil(e)}function Lze(e,t){return e=Vie(e),Tn(qm.count(gh(e),e)+(gh(e).getUTCDay()===4),t,2)}function Mze(e){return e.getUTCDay()}function Fze(e,t){return Tn(XT.count(gh(e)-1,e),t,2)}function Bze(e,t){return Tn(e.getUTCFullYear()%100,t,2)}function jze(e,t){return e=Vie(e),Tn(e.getUTCFullYear()%100,t,2)}function Uze(e,t){return Tn(e.getUTCFullYear()%1e4,t,4)}function Vze(e,t){var n=e.getUTCDay();return e=n>=4||n===0?qm(e):qm.ceil(e),Tn(e.getUTCFullYear()%1e4,t,4)}function zze(){return"+0000"}function nz(){return"%"}function rz(e){return+e}function iz(e){return Math.floor(+e/1e3)}var ip,zie,Ld,$6;Hze({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});function Hze(e){return ip=H7e(e),zie=ip.format,Ld=ip.parse,$6=ip.utcFormat,ip.utcParse,ip}function Wze(e){return new Date(e)}function qze(e){return e instanceof Date?+e:+new Date(+e)}function Hie(e,t,n,r,i,s,o,a,u,l){var c=Mie(),f=c.invert,d=c.domain,h=l(".%L"),p=l(":%S"),m=l("%I:%M"),y=l("%I %p"),g=l("%a %d"),v=l("%b %d"),b=l("%B"),S=l("%Y");function T(E){return(u(E)=0))throw new RangeError(`invalid digits: ${n}`);t=r}return e},()=>new JVe(t)}function qie(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function Gie(e){this._context=e}Gie.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:this._context.lineTo(e,t);break}}};function Yie(e){return new Gie(e)}function Kie(e){return e[0]}function Qie(e){return e[1]}function $y(e,t){var n=ci(!0),r=null,i=Yie,s=null,o=Wie(a);e=typeof e=="function"?e:e===void 0?Kie:ci(e),t=typeof t=="function"?t:t===void 0?Qie:ci(t);function a(u){var l,c=(u=qie(u)).length,f,d=!1,h;for(r==null&&(s=i(h=o())),l=0;l<=c;++l)!(l=h;--p)a.point(b[p],S[p]);a.lineEnd(),a.areaEnd()}g&&(b[d]=+e(y,d,f),S[d]=+t(y,d,f),a.point(r?+r(y,d,f):b[d],n?+n(y,d,f):S[d]))}if(v)return a=null,v+""||null}function c(){return $y().defined(i).curve(o).context(s)}return l.x=function(f){return arguments.length?(e=typeof f=="function"?f:ci(+f),r=null,l):e},l.x0=function(f){return arguments.length?(e=typeof f=="function"?f:ci(+f),l):e},l.x1=function(f){return arguments.length?(r=f==null?null:typeof f=="function"?f:ci(+f),l):r},l.y=function(f){return arguments.length?(t=typeof f=="function"?f:ci(+f),n=null,l):t},l.y0=function(f){return arguments.length?(t=typeof f=="function"?f:ci(+f),l):t},l.y1=function(f){return arguments.length?(n=f==null?null:typeof f=="function"?f:ci(+f),l):n},l.lineX0=l.lineY0=function(){return c().x(e).y(t)},l.lineY1=function(){return c().x(e).y(n)},l.lineX1=function(){return c().x(r).y(t)},l.defined=function(f){return arguments.length?(i=typeof f=="function"?f:ci(!!f),l):i},l.curve=function(f){return arguments.length?(o=f,s!=null&&(a=o(s)),l):o},l.context=function(f){return arguments.length?(f==null?s=a=null:a=o(s=f),l):s},l}function sz(e,t,n){e._context.bezierCurveTo((2*e._x0+e._x1)/3,(2*e._y0+e._y1)/3,(e._x0+2*e._x1)/3,(e._y0+2*e._y1)/3,(e._x0+4*e._x1+t)/6,(e._y0+4*e._y1+n)/6)}function Jie(e){this._context=e}Jie.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:sz(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:sz(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function Mp(e){return new Jie(e)}function J0(e,t,n){this.k=e,this.x=t,this.y=n}J0.prototype={constructor:J0,scale:function(e){return e===1?this:new J0(this.k*e,this.x,this.y)},translate:function(e,t){return e===0&t===0?this:new J0(this.k,this.x+this.k*e,this.y+this.k*t)},apply:function(e){return[e[0]*this.k+this.x,e[1]*this.k+this.y]},applyX:function(e){return e*this.k+this.x},applyY:function(e){return e*this.k+this.y},invert:function(e){return[(e[0]-this.x)/this.k,(e[1]-this.y)/this.k]},invertX:function(e){return(e-this.x)/this.k},invertY:function(e){return(e-this.y)/this.k},rescaleX:function(e){return e.copy().domain(e.range().map(this.invertX,this).map(e.invert,e))},rescaleY:function(e){return e.copy().domain(e.range().map(this.invertY,this).map(e.invert,e))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}};J0.prototype;function Gze(){const e=new Map;return{listen(t,n){return e.has(t)||e.set(t,[]),e.get(t).push(n),()=>{e.set(t,(e.get(t)||[]).filter(r=>r!==n))}},fire(t,n){const r=e.get(t);r&&r.forEach(i=>i(n))}}}let Mb;const Yze=new Uint8Array(16);function Kze(){if(!Mb&&(Mb=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!Mb))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return Mb(Yze)}const Ti=[];for(let e=0;e<256;++e)Ti.push((e+256).toString(16).slice(1));function Qze(e,t=0){return(Ti[e[t+0]]+Ti[e[t+1]]+Ti[e[t+2]]+Ti[e[t+3]]+"-"+Ti[e[t+4]]+Ti[e[t+5]]+"-"+Ti[e[t+6]]+Ti[e[t+7]]+"-"+Ti[e[t+8]]+Ti[e[t+9]]+"-"+Ti[e[t+10]]+Ti[e[t+11]]+Ti[e[t+12]]+Ti[e[t+13]]+Ti[e[t+14]]+Ti[e[t+15]]).toLowerCase()}const Xze=typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto),oz={randomUUID:Xze};function az(e,t,n){if(oz.randomUUID&&!t&&!e)return oz.randomUUID();e=e||{};const r=e.random||(e.rng||Kze)();if(r[6]=r[6]&15|64,r[8]=r[8]&63|128,t){n=n||0;for(let i=0;i<16;++i)t[n+i]=r[i];return t}return Qze(r)}let Vu=class{static get(){let t=az();for(;this.ids.has(t);)t=az();return this.ids.set(t,!0),t}};Vu.ids=new Map;function zu(e){return"parent"in e}function Jze(e){const{label:t=void 0,state:n,initialArtifact:r,initialMetadata:i}=e,s={annotation:[],bookmark:[]},o=Object.keys(i||{}).reduce((u,l)=>(u[l]=[],i&&i[l]&&u[l].push({type:l,id:Vu.get(),val:i[l],createdOn:Date.now()}),u),s),a=r?[{id:Vu.get(),createdOn:Date.now(),val:r}]:[];return{id:Vu.get(),label:t||"Root",event:"Root",children:[],level:0,createdOn:Date.now(),meta:o,artifacts:a,state:{type:"checkpoint",val:n}}}function Zze({parent:e,state:t,label:n,sideEffects:r={do:[],undo:[]},initialMetadata:i,initialArtifact:s,event:o}){const a={annotation:[],bookmark:[]},u=Object.keys(i||{}).reduce((c,f)=>(c[f]=[],i&&i[f]&&c[f].push({type:f,id:Vu.get(),val:i[f],createdOn:Date.now()}),c),a),l=s?[{id:Vu.get(),createdOn:Date.now(),val:s}]:[];return{id:Vu.get(),label:n,event:o,children:[],parent:e.id,createdOn:Date.now(),meta:u,artifacts:l,sideEffects:r,state:t,level:e.level+1}}function Cr(e){for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;r3?t.i-4:t.i:Array.isArray(e)?1:RC(e)?2:NC(e)?3:0}function Dv(e,t){return Rf(e)===2?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function Bw(e,t){return Rf(e)===2?e.get(t):e[t]}function Zie(e,t,n){var r=Rf(e);r===2?e.set(t,n):r===3?(e.delete(t),e.add(n)):e[t]=n}function eHe(e,t){return e===t?e!==0||1/e==1/t:e!=e&&t!=t}function RC(e){return oHe&&e instanceof Map}function NC(e){return aHe&&e instanceof Set}function yd(e){return e.o||e.t}function L6(e){if(Array.isArray(e))return Array.prototype.slice.call(e);var t=cHe(e);delete t[Oo];for(var n=U6(t),r=0;r1&&(e.set=e.add=e.clear=e.delete=tHe),Object.freeze(e),t&&Gm(e,function(n,r){return M6(r,!0)},!0)),e}function tHe(){Cr(2)}function F6(e){return e==null||typeof e!="object"||Object.isFrozen(e)}function Hu(e){var t=qN[e];return t||Cr(18,e),t}function nHe(e,t){qN[e]||(qN[e]=t)}function uz(){return{}.NODE_ENV==="production"||Ym||Cr(0),Ym}function BO(e,t){t&&(Hu("Patches"),e.u=[],e.s=[],e.v=t)}function JT(e){zN(e),e.p.forEach(rHe),e.p=null}function zN(e){e===Ym&&(Ym=e.l)}function lz(e){return Ym={p:[],l:Ym,h:e,m:!0,_:0}}function rHe(e){var t=e[Oo];t.i===0||t.i===1?t.j():t.O=!0}function jO(e,t){t._=t.p.length;var n=t.p[0],r=e!==void 0&&e!==n;return t.h.g||Hu("ES5").S(t,e,r),r?(n[Oo].P&&(JT(t),Cr(4)),Of(e)&&(e=ZT(t,e),t.l||eI(t,e)),t.u&&Hu("Patches").M(n[Oo].t,e,t.u,t.s)):e=ZT(t,n,[]),JT(t),t.u&&t.v(t.u,t.s),e!==j6?e:void 0}function ZT(e,t,n){if(F6(t))return t;var r=t[Oo];if(!r)return Gm(t,function(s,o){return cz(e,r,t,s,o,n)},!0),t;if(r.A!==e)return t;if(!r.P)return eI(e,r.t,!0),r.t;if(!r.I){r.I=!0,r.A._--;var i=r.i===4||r.i===5?r.o=L6(r.k):r.o;Gm(r.i===3?new Set(i):i,function(s,o){return cz(e,r,i,s,o,n)}),eI(e,i,!1),n&&e.u&&Hu("Patches").R(r,n,e.u,e.s)}return r.o}function cz(e,t,n,r,i,s){if({}.NODE_ENV!=="production"&&i===n&&Cr(5),yh(i)){var o=ZT(e,i,s&&t&&t.i!==3&&!Dv(t.D,r)?s.concat(r):void 0);if(Zie(n,r,o),!yh(o))return;e.m=!1}if(Of(i)&&!F6(i)){if(!e.h.F&&e._<1)return;ZT(e,i),t&&t.A.l||eI(e,i)}}function eI(e,t,n){n===void 0&&(n=!1),e.h.F&&e.m&&M6(t,n)}function UO(e,t){var n=e[Oo];return(n?yd(n):e)[t]}function fz(e,t){if(t in e)for(var n=Object.getPrototypeOf(e);n;){var r=Object.getOwnPropertyDescriptor(n,t);if(r)return r;n=Object.getPrototypeOf(n)}}function HN(e){e.P||(e.P=!0,e.l&&HN(e.l))}function VO(e){e.o||(e.o=L6(e.t))}function WN(e,t,n){var r=RC(t)?Hu("MapSet").N(t,n):NC(t)?Hu("MapSet").T(t,n):e.g?function(i,s){var o=Array.isArray(i),a={i:o?1:0,A:s?s.A:uz(),P:!1,I:!1,D:{},l:s,t:i,k:null,o:null,j:null,C:!1},u=a,l=GN;o&&(u=[a],l=Z0);var c=Proxy.revocable(u,l),f=c.revoke,d=c.proxy;return a.k=d,a.j=f,d}(t,n):Hu("ES5").J(t,n);return(n?n.A:uz()).p.push(r),r}function iHe(e){return yh(e)||Cr(22,e),function t(n){if(!Of(n))return n;var r,i=n[Oo],s=Rf(n);if(i){if(!i.P&&(i.i<4||!Hu("ES5").K(i)))return i.t;i.I=!0,r=dz(n,s),i.I=!1}else r=dz(n,s);return Gm(r,function(o,a){i&&Bw(i.t,o)===a||Zie(r,o,t(a))}),s===3?new Set(r):r}(e)}function dz(e,t){switch(t){case 2:return new Map(e);case 3:return Array.from(e)}return L6(e)}function sHe(){function e(r){if(!Of(r))return r;if(Array.isArray(r))return r.map(e);if(RC(r))return new Map(Array.from(r.entries()).map(function(o){return[o[0],e(o[1])]}));if(NC(r))return new Set(Array.from(r).map(e));var i=Object.create(Object.getPrototypeOf(r));for(var s in r)i[s]=e(r[s]);return Dv(r,Ly)&&(i[Ly]=r[Ly]),i}function t(r){return yh(r)?e(r):r}var n="add";nHe("Patches",{$:function(r,i){return i.forEach(function(s){for(var o=s.path,a=s.op,u=r,l=0;l1?g-1:0),b=1;b1?c-1:0),d=1;d=0;i--){var s=r[i];if(s.path.length===0&&s.op==="replace"){n=s.value;break}}i>-1&&(r=r.slice(i+1));var o=Hu("Patches").$;return yh(n)?o(n,r):this.produce(n,function(a){return o(a,r)})},e}(),Ro=new fHe,dHe=Ro.produce;Ro.produceWithPatches.bind(Ro);Ro.setAutoFreeze.bind(Ro);Ro.setUseProxies.bind(Ro);Ro.applyPatches.bind(Ro);Ro.createDraft.bind(Ro);Ro.finishDraft.bind(Ro);function hHe(e,t={}){const{artifact:n=void 0,metadata:r=void 0,rootLabel:i="Root"}=t,s=Jze({state:e,label:i,initialArtifact:n,initialMetadata:r}),o={nodes:{[s.id]:s},root:s.id,current:s.id};return One({name:"provenance-graph",initialState:o,reducers:{addMetadata(a,u){const{id:l,meta:c}=u.payload,f=a.nodes[l].meta,d=Object.keys(c).reduce((h,p)=>(h[p]||(h[p]=[]),h[p].push({type:p,id:Vu.get(),val:c[p],createdOn:Date.now()}),h),f);a.nodes[u.payload.id].meta=d},addArtifact(a,u){a.nodes[u.payload.id].artifacts.push({id:Vu.get(),createdOn:Date.now(),val:u.payload.artifact})},changeCurrent(a,u){a.current=u.payload},addNode(a,{payload:u}){a.nodes[u.id]=u,a.nodes[u.parent].children.push(u.id),a.current=u.id},load(a,{payload:u}){return u}}})}function pHe(e){const t=new Map,{reducer:n,actions:r,getInitialState:i}=hHe(e),s=wMe();s.startListening({matcher:ZU(r.changeCurrent,r.addNode),effect:(a,u)=>{u.cancelActiveListeners(),t.forEach(l=>{const c=ZU(r.addNode)(a),{skipOnNew:f}=l.config;f&&c||l.func(c?"new":"traversal")})}});const o=Ane({reducer:n,middleware:a=>a().prepend(s.middleware)});return{initialState:i(),get backend(){return o.getState()},get current(){return o.getState().nodes[o.getState().current]},get root(){return o.getState().nodes[o.getState().root]},currentChange(a,u){const l={id:Vu.get(),func:a,config:u};return t.set(l.id,l),()=>t.delete(l.id)},update:o.dispatch,...r}}/*! * https://github.com/Starcounter-Jack/JSON-Patch * (c) 2017-2022 Joachim Wester * MIT licensed - */var pHe=globalThis&&globalThis.__extends||function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var s in i)i.hasOwnProperty(s)&&(r[s]=i[s])},e(t,n)};return function(t,n){e(t,n);function r(){this.constructor=t}t.prototype=n===null?Object.create(n):(r.prototype=n.prototype,new r)}}(),mHe=Object.prototype.hasOwnProperty;function KN(e,t){return mHe.call(e,t)}function QN(e){if(Array.isArray(e)){for(var t=new Array(e.length),n=0;n=48&&r<=57){t++;continue}return!1}return!0}function vd(e){return e.indexOf("/")===-1&&e.indexOf("~")===-1?e:e.replace(/~/g,"~0").replace(/\//g,"~1")}function ese(e){return e.replace(/~1/g,"/").replace(/~0/g,"~")}function JN(e){if(e===void 0)return!0;if(e){if(Array.isArray(e)){for(var t=0,n=e.length;t0&&u[c-1]=="constructor"))throw new TypeError("JSON-Patch: modifying `__proto__` or `constructor/prototype` prop is banned for security reasons, if this was on purpose, please set `banPrototypeModifications` flag false and pass it to this function. More info in fast-json-patch README");if(n&&d===void 0&&(l[h]===void 0?d=u.slice(0,c).join("/"):c==f-1&&(d=t.path),d!==void 0&&p(t,0,e,d)),c++,Array.isArray(l)){if(h==="-")h=l.length;else{if(n&&!XN(h))throw new Tr("Expected an unsigned base-10 integer value, making the new referenced value the array element with the zero-based index","OPERATION_PATH_ILLEGAL_ARRAY_INDEX",s,t,e);XN(h)&&(h=~~h)}if(c>=f){if(n&&t.op==="add"&&h>l.length)throw new Tr("The specified index MUST NOT be greater than the number of elements in the array","OPERATION_VALUE_OUT_OF_BOUNDS",s,t,e);var o=yHe[t.op].call(t,l,h,e);if(o.test===!1)throw new Tr("Test operation failed","TEST_OPERATION_FAILED",s,t,e);return o}}else if(c>=f){var o=Fp[t.op].call(t,l,h,e);if(o.test===!1)throw new Tr("Test operation failed","TEST_OPERATION_FAILED",s,t,e);return o}if(l=l[h],n&&c0)throw new Tr('Operation `path` property must start with "/"',"OPERATION_PATH_INVALID",t,e,n);if((e.op==="move"||e.op==="copy")&&typeof e.from!="string")throw new Tr("Operation `from` property is not present (applicable in `move` and `copy` operations)","OPERATION_FROM_REQUIRED",t,e,n);if((e.op==="add"||e.op==="replace"||e.op==="test")&&e.value===void 0)throw new Tr("Operation `value` property is not present (applicable in `add`, `replace` and `test` operations)","OPERATION_VALUE_REQUIRED",t,e,n);if((e.op==="add"||e.op==="replace"||e.op==="test")&&JN(e.value))throw new Tr("Operation `value` property is not present (applicable in `add`, `replace` and `test` operations)","OPERATION_VALUE_CANNOT_CONTAIN_UNDEFINED",t,e,n);if(n){if(e.op=="add"){var i=e.path.split("/").length,s=r.split("/").length;if(i!==s+1&&i!==s)throw new Tr("Cannot perform an `add` operation at the desired path","OPERATION_PATH_CANNOT_ADD",t,e,n)}else if(e.op==="replace"||e.op==="remove"||e.op==="_get"){if(e.path!==r)throw new Tr("Cannot perform the operation at a path that does not exist","OPERATION_PATH_UNRESOLVABLE",t,e,n)}else if(e.op==="move"||e.op==="copy"){var o={op:"_get",path:e.from,value:void 0},a=nse([o],n);if(a&&a.name==="OPERATION_PATH_UNRESOLVABLE")throw new Tr("Cannot perform the operation from a path that does not exist","OPERATION_FROM_UNRESOLVABLE",t,e,n)}}}else throw new Tr("Operation `op` property is not one of operations defined in RFC-6902","OPERATION_OP_INVALID",t,e,n)}function nse(e,t,n){try{if(!Array.isArray(e))throw new Tr("Patch sequence must be an array","SEQUENCE_NOT_AN_ARRAY");if(t)kC(Gs(t),Gs(e),n||!0);else{n=n||nI;for(var r=0;r=48&&r<=57){t++;continue}return!1}return!0}function vd(e){return e.indexOf("/")===-1&&e.indexOf("~")===-1?e:e.replace(/~/g,"~0").replace(/\//g,"~1")}function ese(e){return e.replace(/~1/g,"/").replace(/~0/g,"~")}function XN(e){if(e===void 0)return!0;if(e){if(Array.isArray(e)){for(var t=0,n=e.length;t0&&u[c-1]=="constructor"))throw new TypeError("JSON-Patch: modifying `__proto__` or `constructor/prototype` prop is banned for security reasons, if this was on purpose, please set `banPrototypeModifications` flag false and pass it to this function. More info in fast-json-patch README");if(n&&d===void 0&&(l[h]===void 0?d=u.slice(0,c).join("/"):c==f-1&&(d=t.path),d!==void 0&&p(t,0,e,d)),c++,Array.isArray(l)){if(h==="-")h=l.length;else{if(n&&!QN(h))throw new Tr("Expected an unsigned base-10 integer value, making the new referenced value the array element with the zero-based index","OPERATION_PATH_ILLEGAL_ARRAY_INDEX",s,t,e);QN(h)&&(h=~~h)}if(c>=f){if(n&&t.op==="add"&&h>l.length)throw new Tr("The specified index MUST NOT be greater than the number of elements in the array","OPERATION_VALUE_OUT_OF_BOUNDS",s,t,e);var o=vHe[t.op].call(t,l,h,e);if(o.test===!1)throw new Tr("Test operation failed","TEST_OPERATION_FAILED",s,t,e);return o}}else if(c>=f){var o=Fp[t.op].call(t,l,h,e);if(o.test===!1)throw new Tr("Test operation failed","TEST_OPERATION_FAILED",s,t,e);return o}if(l=l[h],n&&c0)throw new Tr('Operation `path` property must start with "/"',"OPERATION_PATH_INVALID",t,e,n);if((e.op==="move"||e.op==="copy")&&typeof e.from!="string")throw new Tr("Operation `from` property is not present (applicable in `move` and `copy` operations)","OPERATION_FROM_REQUIRED",t,e,n);if((e.op==="add"||e.op==="replace"||e.op==="test")&&e.value===void 0)throw new Tr("Operation `value` property is not present (applicable in `add`, `replace` and `test` operations)","OPERATION_VALUE_REQUIRED",t,e,n);if((e.op==="add"||e.op==="replace"||e.op==="test")&&XN(e.value))throw new Tr("Operation `value` property is not present (applicable in `add`, `replace` and `test` operations)","OPERATION_VALUE_CANNOT_CONTAIN_UNDEFINED",t,e,n);if(n){if(e.op=="add"){var i=e.path.split("/").length,s=r.split("/").length;if(i!==s+1&&i!==s)throw new Tr("Cannot perform an `add` operation at the desired path","OPERATION_PATH_CANNOT_ADD",t,e,n)}else if(e.op==="replace"||e.op==="remove"||e.op==="_get"){if(e.path!==r)throw new Tr("Cannot perform the operation at a path that does not exist","OPERATION_PATH_UNRESOLVABLE",t,e,n)}else if(e.op==="move"||e.op==="copy"){var o={op:"_get",path:e.from,value:void 0},a=nse([o],n);if(a&&a.name==="OPERATION_PATH_UNRESOLVABLE")throw new Tr("Cannot perform the operation from a path that does not exist","OPERATION_FROM_UNRESOLVABLE",t,e,n)}}}else throw new Tr("Operation `op` property is not one of operations defined in RFC-6902","OPERATION_OP_INVALID",t,e,n)}function nse(e,t,n){try{if(!Array.isArray(e))throw new Tr("Patch sequence must be an array","SEQUENCE_NOT_AN_ARRAY");if(t)kC(Gs(t),Gs(e),n||!0);else{n=n||nI;for(var r=0;r0&&(e.patches=[],e.callback&&e.callback(r)),r}function H6(e,t,n,r,i){if(t!==e){typeof t.toJSON=="function"&&(t=t.toJSON());for(var s=QN(t),o=QN(e),a=!1,u=o.length-1;u>=0;u--){var l=o[u],c=e[l];if(KN(t,l)&&!(t[l]===void 0&&c!==void 0&&Array.isArray(t)===!1)){var f=t[l];typeof c=="object"&&c!=null&&typeof f=="object"&&f!=null&&Array.isArray(c)===Array.isArray(f)?H6(c,f,n,r+"/"+vd(l),i):c!==f&&(i&&n.push({op:"test",path:r+"/"+vd(l),value:Gs(c)}),n.push({op:"replace",path:r+"/"+vd(l),value:Gs(f)}))}else Array.isArray(e)===Array.isArray(t)?(i&&n.push({op:"test",path:r+"/"+vd(l),value:Gs(c)}),n.push({op:"remove",path:r+"/"+vd(l)}),a=!0):(i&&n.push({op:"test",path:r,value:e}),n.push({op:"replace",path:r,value:t}))}if(!(!a&&s.length==o.length))for(var u=0;u(e.TRAVERSAL_START="Traversal_Start",e.TRAVERSAL_END="Traversal_End",e))(ey||{});function jw(e,t){const n=e.state;if(n.type==="checkpoint")return n.val;const{checkpointRef:r}=n,i=t[r],s=sse(i,e,t);s.shift();const o=s.map(u=>t[u]).map(u=>u.state.val).reduce((u,l)=>[...u,...l],[]),a=jw(i,t);return kC(a,Gs(o),!0,!1).newDocument}function AHe(e,t){const n=Object.keys(e).length;return new Set(t.map(r=>r.path.split("/")[0])).size{n=!0}),r.listen(ey.TRAVERSAL_END,()=>{n=!1});const o={add(c,f=i.current.id){i.update(i.addMetadata({id:f,meta:c}))},latestOfType(c,f=i.current.id){var d;return(d=i.backend.nodes[f].meta[c])==null?void 0:d.at(-1)},allOfType(c,f=i.current.id){return i.backend.nodes[f].meta[c]},latest(c=i.current.id){const f=i.backend.nodes[c].meta,d=Object.keys(f).reduce((h,p)=>{const m=f[p].at(-1);return m&&(h[p]=m),h},{});return Object.keys(d).length>0?d:void 0},all(c=i.current.id){return i.backend.nodes[c].meta},types(c=i.current.id){return Object.keys(i.backend.nodes[c].meta)}},a={add(c,f=i.current.id){i.update(i.addArtifact({id:f,artifact:c}))},latest(c=i.current.id){return i.backend.nodes[c].artifacts.at(-1)},all(c=i.current.id){return i.backend.nodes[c].artifacts}},u={add(c,f=i.current.id){o.add({annotation:c},f)},latest(c=i.current.id){var f;return(f=o.latestOfType("annotation",c))==null?void 0:f.val},all(c=i.current.id){var f;return(f=o.allOfType("annotation",c))==null?void 0:f.map(d=>d.val)}},l={add(c=i.current.id){o.add({bookmark:!0},c)},remove(c=i.current.id){o.add({bookmark:!1},c)},is(c=i.current.id){var f;return!!((f=o.latestOfType("bookmark",c))!=null&&f.val)},toggle(c=i.current.id){l.is(c)?l.remove(c):l.add(c)}};return{registry:e,get isTraversing(){return n},getState(c=i.current){return jw(c,i.backend.nodes)},graph:i,get current(){return i.current},get root(){return i.root},record({label:c,state:f,sideEffects:d,eventType:h,onlySideEffects:p=!1}){let m=null,y=null;const g=jw(this.current,this.graph.backend.nodes);if(p)y={type:"checkpoint",val:f};else{const v=rse(g,f);if(AHe(f,v)==="checkpoint")y={type:"checkpoint",val:f};else{const b=this.current.state.type==="checkpoint"?this.current.id:this.current.state.checkpointRef;y={type:"patch",val:v,checkpointRef:b}}}if(!y)throw new Error(`Could not calculate new state. Previous state is: ${JSON.stringify(this.current.state,null,2)}`);if(m=Jze({label:c,state:y,parent:this.current,sideEffects:d,event:h}),!m)throw new Error("State Node creation failed!");i.update(i.addNode(m))},async apply(c,f){const d=e.get(f.type),h=jw(this.current,this.graph.backend.nodes);if(d.config.hasSideEffects){const{do:p=f,undo:m}=d.func(f.payload);this.record({label:c,state:h,sideEffects:{do:[p],undo:[m]},eventType:d.config.eventType})}else{const p=d.func(h,f.payload);this.record({label:c,state:p,sideEffects:{do:[],undo:[]},eventType:d.config.eventType})}},async to(c){r.fire(ey.TRAVERSAL_START);const f=sse(i.current,i.backend.nodes[c],i.backend.nodes),d=[];for(let h=0;h0?this.to(f.children[c==="oldest"?0:f.children.length-1]):Promise.resolve(console.warn("Already at latest in this branch!"))},currentChange(c,f=!1){return i.currentChange(c,{skipOnNew:f})},done(){console.log("Setup later for URL sharing.")},tree(){return ose(i.root,i.backend.nodes)},on(c,f){r.listen(c,f)},export(){return JSON.stringify(i.backend)},exportObject(){return JSON.parse(JSON.stringify(i.backend))},import(c){const f=JSON.parse(c),d=f.current;f.current=f.root,i.update(i.load(f)),this.to(d)},importObject(c){const f=c.current;c.current=c.root,i.update(i.load(c)),this.to(f)},metadata:o,artifact:a,annotations:u,bookmarks:l}}function PHe(e,t,n){let[r,i]=[e,t];r.level>i.level&&([r,i]=[i,r]);let s=i.level-r.level;for(;zu(i)&&s!==0;)i=n[i.parent],s-=1;if(r.id===i.id)return r.id;for(;r.id!==i.id;)zu(r)&&(r=n[r.parent]),zu(i)&&(i=n[i.parent]);return r.id}function sse(e,t,n){const r=PHe(e,t,n),i=n[r],s=[],o=[];let[a,u]=[e,t];for(;a.id!==i.id;)s.push(a),zu(a)&&(a=n[a.parent]);for(s.push(a);u.id!==i.id;)o.push(u),zu(u)&&(u=n[u.parent]);const l=o.reverse();return[...s,...l].map(c=>c.id)}function OHe(e,t){if(zu(e)&&e.parent===t.id)return!0;if(zu(t)&&t.parent===e.id)return!1;throw new Error("Incorrect use of function. Nodes are not connected to each other.")}function ose(e,t){return{...e,children:e.children.map(n=>ose(t[n],t)),name:`${e.label}`}}iHe();function RHe(e){return e.length===2?fHe(e):e}class DC{static create(){return new DC}constructor(){this.registry=new Map}has(t){return this.registry.has(t)}register(t,n,r){const i=n.length===2;if(n.length>2)throw new Error("Incorrect action function signature. Action function can only have two arguments at most!");if(this.has(t))throw new Error(`Already registered: ${t}`);const{label:s=t,eventType:o=t}=r||{};return this.registry.set(t,{func:RHe(n),config:{hasSideEffects:!i,label:typeof s=="string"?()=>s:s,eventType:o}}),ju(t)}get(t){const n=this.registry.get(t);if(!n)throw new Error(`Not registered: ${t}`);return n}}var NHe="Expected a function",gz=NaN,kHe="[object Symbol]",DHe=/^\s+|\s+$/g,$He=/^[-+]0x[0-9a-f]+$/i,LHe=/^0b[01]+$/i,MHe=/^0o[0-7]+$/i,FHe=parseInt,BHe=typeof _o=="object"&&_o&&_o.Object===Object&&_o,jHe=typeof self=="object"&&self&&self.Object===Object&&self,UHe=BHe||jHe||Function("return this")(),VHe=Object.prototype,zHe=VHe.toString,HHe=Math.max,WHe=Math.min,HO=function(){return UHe.Date.now()};function qHe(e,t,n){var r,i,s,o,a,u,l=0,c=!1,f=!1,d=!0;if(typeof e!="function")throw new TypeError(NHe);t=yz(t)||0,ek(n)&&(c=!!n.leading,f="maxWait"in n,s=f?HHe(yz(n.maxWait)||0,t):s,d="trailing"in n?!!n.trailing:d);function h(E){var I=r,A=i;return r=i=void 0,l=E,o=e.apply(A,I),o}function p(E){return l=E,a=setTimeout(g,t),c?h(E):o}function m(E){var I=E-u,A=E-l,R=t-I;return f?WHe(R,s-A):R}function y(E){var I=E-u,A=E-l;return u===void 0||I>=t||I<0||f&&A>=s}function g(){var E=HO();if(y(E))return v(E);a=setTimeout(g,m(E))}function v(E){return a=void 0,d&&r?h(E):(r=i=void 0,o)}function b(){a!==void 0&&clearTimeout(a),l=0,r=u=i=a=void 0}function S(){return a===void 0?o:v(HO())}function T(){var E=HO(),I=y(E);if(r=arguments,i=this,u=E,I){if(a===void 0)return p(u);if(f)return a=setTimeout(g,t),h(u)}return a===void 0&&(a=setTimeout(g,t)),o}return T.cancel=b,T.flush=S,T}function ek(e){var t=typeof e;return!!e&&(t=="object"||t=="function")}function GHe(e){return!!e&&typeof e=="object"}function YHe(e){return typeof e=="symbol"||GHe(e)&&zHe.call(e)==kHe}function yz(e){if(typeof e=="number")return e;if(YHe(e))return gz;if(ek(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=ek(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=e.replace(DHe,"");var n=LHe.test(e);return n||MHe.test(e)?FHe(e.slice(2),n?2:8):$He.test(e)?gz:+e}var KHe=qHe;const ou=eu(KHe);function ase({xScale:e,yRange:t,vertPosition:n,ticks:r,isDate:i=!1,showLines:s=!0}){const o=w.useMemo(()=>r.length>1?Math.abs(r[1].offset-r[0].offset):e.range()[0]-e.range()[1],[r,e]),a=w.useCallback(u=>(i?L6("%b%e, %Y"):yf(".2s"))(u),[i]);return C.jsxs(C.Fragment,{children:[s?C.jsx("path",{transform:`translate(0, ${t[1]})`,d:["M",e.range()[0],0,"H",e.range()[1]].join(" "),fill:"none",stroke:"lightgray"}):null,r.map(({value:u,offset:l})=>C.jsxs("g",{transform:`translate(${l}, ${n})`,children:[C.jsx("line",{y2:"6",stroke:"currentColor"}),s?C.jsx("line",{y2:`${-(t[0]-t[1])}`,stroke:"lightgray"}):null,C.jsx("foreignObject",{x:0-o/2,y:10,width:o,height:20,children:C.jsx(ua,{children:C.jsx(Wx,{withinPortal:!0,label:u,children:C.jsx(rt,{px:2,size:10,style:{textAlign:"center",textOverflow:"ellipsis",overflow:"hidden",whiteSpace:"nowrap"},children:+u==0?0:a(i?new Date(u):u)})})})})]},`${u}test`))]})}const QHe=Object.freeze(Object.defineProperty({__proto__:null,XAxis:ase},Symbol.toStringTag,{value:"Module"}));function use({dataset:e,yScale:t,xRange:n,horizontalPosition:r}){const i=w.useMemo(()=>t.ticks(6).map(o=>({value:o,yOffset:t(o)})),[t]),s=w.useMemo(()=>e==="clean_stocks"?yf(",.0%"):t.domain()[1]<5?yf(",.2r"):yf(",.0f"),[e,t]);return C.jsx(C.Fragment,{children:i.map(({value:o,yOffset:a})=>C.jsxs("g",{transform:`translate(${r}, ${a})`,children:[C.jsx("line",{x2:`${n[1]-n[0]}`,stroke:`${o===0?"black":"gainsboro"}`,strokeWidth:o===0?1:.4}),C.jsx("text",{style:{dominantBaseline:"middle",fontSize:"10px",textAnchor:"end",transform:"translateX(-6px)",fill:"black",font:"Roboto"},children:s(o)},o)]},o))})}const XHe=Object.freeze(Object.defineProperty({__proto__:null,YAxis:use},Symbol.toStringTag,{value:"Module"})),Yi={top:30,left:40,right:80,bottom:50};function tk({parameters:e,data:t,dataname:n,items:r,selection:i,range:s,guardrail:o}){const[a,u]=w.useState(null),l=R=>i!=null&&i.includes(R)?!a||a.length===0?!0:a.includes(R):!1,c=w.useMemo(()=>{const R=r.filter(L=>i==null?void 0:i.includes(L.name)).map(L=>L.group);return r.filter(L=>R==null?void 0:R.includes(L.group)).filter(L=>!(i!=null&&i.includes(L.name))).map(L=>L.name)},[i,r,n]),f=w.useMemo(()=>{const R=r.map(J=>J.group),F=t.filter(J=>R==null?void 0:R.includes(J[e.group_var]));return[...vVe(F,J=>({mean:PO(J,.5,V=>V[e.y_var]),upperq:PO(J,.75,V=>V[e.y_var]),lowerq:PO(J,.25,V=>V[e.y_var])}),J=>J[e.x_var])].flatMap(([J,V])=>({date:J,mean:V.mean,upperq:V.upperq,lowerq:V.lowerq}))},[t,r,e,n]),d=n==="clean_data"?800-Yi.left-Yi.right-60:800-Yi.left-Yi.right,h=400-Yi.top-Yi.bottom,{yMin:p,yMax:m}=w.useMemo(()=>{let R=[];switch(o){case"super_data":R=i==null?void 0:i.concat(c);break;default:R=i;break}const F=t.filter(ae=>R.includes(ae[e.cat_var])).map(ae=>+ae[e.y_var]).filter(ae=>ae!==null),[L,B]=n==="clean_stocks"?Pf(F):[0,Pf(F)[1]],[J,V]=[zT(f.map(ae=>ae.lowerq)),Pv(f.map(ae=>ae.upperq))],re=o==="super_summ"?zT([L,J]):L,oe=o==="super_summ"?Pv([B,V]):B;return{yMin:re,yMax:oe}},[t,i,o,f,c,e,n]),y=w.useMemo(()=>s?kv([Yi.left,d+Yi.left]).domain(s):kv([Yi.left,d+Yi.left]).domain([new Date(e.start_date),new Date(e.end_date)]),[d,s,e,n]),g=w.useMemo(()=>mh([h+Yi.top,Yi.top]).domain([p,m]).nice(),[h,m,p,n]),v=w.useMemo(()=>{const R=Array.from(new Set(t.map(F=>F[e.cat_var])));return O6(S6).domain(R)},[t,e,n]),b=w.useMemo(()=>{if(!y||!g)return;const R=$y();return R.x(L=>y(Ld("%Y-%m-%d")(L[e.x_var]))),R.y(L=>g(L[e.y_var])),R.curve(Mp),i==null?void 0:i.map(L=>({country:L,path:R(t.filter(B=>B[e.cat_var]===L))}))},[t,y,g,i,e,n]),S=w.useMemo(()=>{if(o!=="super_data")return null;const R=$y();return R.x(L=>y(Ld("%Y-%m-%d")(L[e.x_var]))),R.y(L=>g(L[e.y_var])),R.curve(Mp),c==null?void 0:c.map(L=>({country:L,path:R(t.filter(B=>B[e.cat_var]===L))}))},[t,y,g,o,c,e,n]),T=w.useMemo(()=>{if(o!=="super_summ")return null;const R=$y();R.x(J=>y(Ld("%Y-%m-%d")(J.date))),R.y(J=>g(J.mean)),R.curve(Mp);const F=R(f),L=Xie();L.x(J=>y(Ld("%Y-%m-%d")(J.date))),L.y0(J=>g(J.lowerq)),L.y1(J=>g(J.upperq)),L.curve(Mp);const B=L(f);return{meanLine:F,confidenceBands:B,data:f}},[y,g,o,f,n]),E=w.useMemo(()=>n==="clean_stocks"?"Industry Average":"Average",[n]),I=R=>R==="Eldoril North"?"Policy A":R.split(" ")[0]==="Silvoria"||R.split(" ")[0]==="Mystara"?"Policy C":R==="Average"?"all policies":"Policy B",A=w.useMemo(()=>{let F=null;switch(o){case"super_data":F=i==null?void 0:i.concat(S==null?void 0:S.map(B=>B.country));break;case"super_summ":F=i==null?void 0:i.concat([E]);break;default:F=i;break}const L=F==null?void 0:F.map(B=>({country:B,country_policy:n==="clean_data"?`${B} (${I(B)})`:B,label_pos:B===E?T==null?void 0:T.data.slice(-1).map(J=>g(J.mean))[0]:t.filter(J=>J[e.cat_var]===B).slice(-1).map(J=>g(J[e.y_var]))[0]})).sort((B,J)=>B.label_pos=10||(L[B].label_pos=L[B].label_pos-10+J)}return L},[t,i,g,o,E,e,S,T,n]);return(i==null?void 0:i.length)===0?C.jsx(ua,{style:{width:"800px",height:"400px"},children:C.jsx(rt,{fs:"italic",c:"dimmed",children:"Select an item to view the chart."})}):C.jsxs("svg",{id:"baseLineChart",style:{height:"400px",width:"800px",fontFamily:'"Helvetica Neue", "Helvetica", "Arial", sans-serif'},children:[C.jsxs("g",{id:"axes",children:[C.jsx(ase,{isDate:!0,xScale:y,yRange:g.range(),vertPosition:h+Yi.top,showLines:!1,ticks:y.ticks(6).map(R=>({value:R.toString(),offset:y(R)}))}),C.jsx(use,{dataset:n,yScale:g,horizontalPosition:Yi.left,xRange:y.range()})]}),C.jsx("svg",{style:{width:`${d}`},children:S==null?void 0:S.map(R=>C.jsx("g",{children:C.jsx("path",{id:`${R.country}`,fill:"none",stroke:l(R.country)?v(R.country):"gray",strokeDasharray:"4,1",strokeWidth:.5,d:R.path},`${R.country}_key`)},`${R.country}_g`))},"control_lines"),C.jsx("svg",{style:{width:`${d}`},children:T?C.jsxs("g",{children:[C.jsx("path",{id:"confidenceBands",fill:"lightgray",opacity:.25,stroke:"none",d:T.confidenceBands},"confidenceBands_key"),C.jsx("path",{id:"meanLine",fill:"none",stroke:"gray",strokeDasharray:"4,1",strokeWidth:.5,d:T.meanLine},"meanLine_key")]},"summary_g"):null},"control_bands"),C.jsxs("svg",{style:{width:`${d}`},children:[b==null?void 0:b.map(R=>C.jsx("g",{children:C.jsx("path",{id:`${R.country}`,fill:"none",stroke:l(R.country)?v(R.country):"gainsboro",strokeWidth:a!=null&&a.includes(R.country)?2:1.5,d:R.path},`${R.country}_key`)},`${R.country}_g`)),A==null?void 0:A.map(R=>C.jsx("foreignObject",{x:d+Yi.left+5,y:R.label_pos-7,width:Yi.right+60,height:20,children:C.jsx(rt,{px:2,size:10,color:l(R.country)?v(R.country):"silver",onMouseOver:F=>{const L=F.target;i!=null&&i.includes(L.innerText)&&u([L.innerText])},onMouseOut:()=>u([]),children:R.country_policy})},`${R.country}_label`))]},"lines")]})}const JHe=Object.freeze(Object.defineProperty({__proto__:null,LineChart:tk,default:tk},Symbol.toStringTag,{value:"Module"})),sp={top:0,left:0,right:0,bottom:0},vz=20,WO=60;function nk({parameters:e,data:t,dataname:n,items:r,selection:i,setSelection:s,trackSelection:o,range:a,guardrail:u}){const l=w.useMemo(()=>a?kv([sp.left,WO+sp.left]).domain(a):kv([sp.left,WO+sp.left]).domain([new Date(e.start_date),new Date(e.end_date)]),[e,a]),c=w.useMemo(()=>{const p=t.filter(g=>r==null?void 0:r.map(v=>v.name).includes(g[e.cat_var])).map(g=>+g[e.y_var]).filter(g=>g!==null),[m,y]=Pf(p);return mh([vz+sp.top,sp.top]).domain([m,y]).nice()},[e,t,r]),f=w.useMemo(()=>{const p=Array.from(new Set(t.map(m=>m[e.cat_var])));return O6(S6).domain(p)},[e,t]),d=w.useMemo(()=>{if(u!=="juxt_data")return null;const p=Xie();p.x(g=>l(Ld("%Y-%m-%d")(g[e.x_var]))),p.y0(()=>c(0)),p.y1(g=>c(g[e.y_var])),p.curve(Mp);const m=$y();return m.x(g=>l(Ld("%Y-%m-%d")(g[e.x_var]))),m.y(g=>c(g[e.y_var])),m.curve(Mp),r==null?void 0:r.map(g=>({country:g.name,path:m(t.filter(v=>v[e.cat_var]===g.name)),area:p(t.filter(v=>v[e.cat_var]===g.name))}))},[e,u,t,r,l,c]),h=w.useMemo(()=>e.allow_selection===!1?"none":"block",[e]);return C.jsx(Mm.Group,{defaultValue:i,orientation:"vertical",onChange:p=>{s(p),o(p)},spacing:0,offset:"sm",styles:e.allow_selection===!1?{root:{pointerEvents:"none"}}:{root:{pointerEvents:"auto"}},children:r==null?void 0:r.map(p=>C.jsxs(C.Fragment,{children:[p.name==="Eldoril North"?C.jsx(df,{size:"xs",label:"Policy A",labelPosition:"left",color:"black"}):null,p.name==="Eldoril West"?C.jsx(df,{size:"xs",label:"Policy B",labelPosition:"left",color:"black"}):null,p.name==="Silvoria North"?C.jsx(df,{size:"xs",label:"Policy C",labelPosition:"left",color:"black"}):null,C.jsxs(Rl,{grow:!0,gutter:8,columns:2,children:[C.jsx(Rl.Col,{span:1,children:C.jsx(Mm,{value:p.name,label:p.name,color:e.allow_selection?"blue":"gray",styles:{root:{display:"flex",alignItems:"flex-end",padding:"2px 0"},inner:{display:h}},children:p.name},`${p.name}_checkbox`)},`${p.name}_grid1`),C.jsx(Rl.Col,{span:u==="juxt_data"?"auto":3,children:C.jsxs("svg",{style:{width:`${WO}`,height:`${vz}`},children:[C.jsx("path",{id:`${p.name}_sparkarea`,fill:i!=null&&i.includes(p.name)?f(p.name):"gray",stroke:"none",opacity:.25,d:d==null?void 0:d.filter(m=>m.country===p.name)[0].area},`${p.name}_sparkarea`),C.jsx("path",{id:`${p.name}_spark`,fill:"none",stroke:i!=null&&i.includes(p.name)?f(p.name):"gray",strokeWidth:.75,d:d==null?void 0:d.filter(m=>m.country===p.name)[0].path},`${p.name}_spark`)]},`${p.name}_sparksvg`)},`${p.name}_grid2`)]},`${p.name}_grid`)]}))},`${n}_checkboxgroup`)}const ZHe=Object.freeze(Object.defineProperty({__proto__:null,Sidebar:nk,default:nk},Symbol.toStringTag,{value:"Module"}));function rk({parameters:e,setRange:t,trackRange:n}){function r(s){return kv([0,100]).domain([new Date(e.start_date),new Date(e.end_date)]).invert(s)}function i(s){const o=r(s);return L6("%b %e, %Y")(o)}return C.jsx(pte,{defaultValue:[0,100],label:s=>i(s),labelAlwaysOn:!0,disabled:!e.allow_time_slider,onChange:([s,o])=>{t([r(s),r(o)]),n([r(s),r(o)])}})}const eWe=Object.freeze(Object.defineProperty({__proto__:null,RangeSelector:rk,default:rk},Symbol.toStringTag,{value:"Module"}));function ik({guardrail:e,setGuardrail:t,dataname:n,setDataname:r,setSelection:i}){return C.jsxs(C.Fragment,{children:[C.jsx(rt,{children:"Data:"}),C.jsx(ZR,{value:n,onChange:s=>{r(s),i([])},data:[{value:"clean_data",label:"Viral"},{value:"clean_stocks",label:"Stock"}]}),C.jsx(rt,{children:"Guardrail:"}),C.jsx(ZR,{value:e,onChange:s=>{t(s)},data:[{value:"none",label:"None"},{value:"super_data",label:"Sup. Data"},{value:"super_summ",label:"Sup. Summ."},{value:"juxt_data",label:"Juxt. Data"},{value:"juxt_summ",label:"Juxt. Summ."}]})]})}const tWe=Object.freeze(Object.defineProperty({__proto__:null,Selector:ik,default:ik},Symbol.toStringTag,{value:"Module"})),En=Array.isArray;function io(e){return e!=null?En(e)?e:[e]:[]}function nWe(e=0,t=1/0){return`${_z(e)} < row_number() && row_number() <= ${_z(t)}`}function _z(e){return e<0?`count() + ${e}`:e}class lse{constructor(t){t&&(this._params=t)}params(t){return arguments.length?(t&&(this._params={...this._params,...t}),this):this._params}reify(t){return this.__reify(this,t)}count(t){return this.__count(this,t)}derive(t,n){return this.__derive(this,t,n)}filter(t){return this.__filter(this,t)}slice(t,n){return this.filter(nWe(t,n)).reify()}groupby(...t){return this.__groupby(this,t.flat())}orderby(...t){return this.__orderby(this,t.flat())}relocate(t,n){return this.__relocate(this,io(t),n)}rename(...t){return this.__rename(this,t.flat())}rollup(t){return this.__rollup(this,t)}sample(t,n){return this.__sample(this,t,n)}select(...t){return this.__select(this,t.flat())}ungroup(){return this.__ungroup(this)}unorder(){return this.__unorder(this)}dedupe(...t){return this.__dedupe(this,t.flat())}impute(t,n){return this.__impute(this,t,n)}fold(t,n){return this.__fold(this,t,n)}pivot(t,n,r){return this.__pivot(this,t,n,r)}spread(t,n){return this.__spread(this,t,n)}unroll(t,n){return this.__unroll(this,t,n)}lookup(t,n,...r){return this.__lookup(this,t,n,r.flat())}join(t,n,r,i){return this.__join(this,t,n,r,i)}join_left(t,n,r,i){const s={...i,left:!0,right:!1};return this.__join(this,t,n,r,s)}join_right(t,n,r,i){const s={...i,left:!1,right:!0};return this.__join(this,t,n,r,s)}join_full(t,n,r,i){const s={...i,left:!0,right:!0};return this.__join(this,t,n,r,s)}cross(t,n,r){return this.__cross(this,t,n,r)}semijoin(t,n){return this.__semijoin(this,t,n)}antijoin(t,n){return this.__antijoin(this,t,n)}concat(...t){return this.__concat(this,t.flat())}union(...t){return this.__union(this,t.flat())}intersect(...t){return this.__intersect(this,t.flat())}except(...t){return this.__except(this,t.flat())}}function Wt(e){throw Error(e)}function bs(e){return typeof e=="number"}function sr(e){return typeof e=="function"}function $C(e,t){const n=Array(e);if(sr(t))for(let r=0;r=0;a=s.next(a+1))r[++o]=a;else for(let a=0;aa(l,c,u))}return(t||!i)&&(this._index=r),r}partitions(t=!0){if(this._partitions)return this._partitions;if(!this.isGrouped())return[this.indices(t)];const{keys:n,size:r}=this._group,i=$C(r,()=>[]),s=this._index,o=this.mask(),a=this.numRows();if(s&&this.isOrdered())for(let u=0,l;u=0;u=o.next(u+1))i[n[u]].push(u);else for(let u=0;uu(f,d,l))}return(t||!this.isOrdered())&&(this._partitions=i),i}scan(t,n,r=1/0,i=0){const s=this._mask,o=this._nrows,a=this._data;let u=i||0;if(u>o)return;const l=Math.min(o,u+r),c=()=>u=this._total;if(n&&this.isOrdered()||s&&this._index){const f=this.indices(),d=this._data;for(;u-1;u=s.next(u+1))t(u,a,c)}else for(;ur.push(s),!0,n-t,t),this.reify(r)}reduce(t){return this.__reduce(this,t)}},iWe=class{constructor(t){this.data=t}get length(){return this.data.length}get(t){return this.data[t]}[Symbol.iterator](){return this.data[Symbol.iterator]()}},sWe=function(e){return e&&sr(e.get)?e:new iWe(e)};function Xl(e){return e instanceof Date}function as(e){return e===Object(e)}function rI(e){return e instanceof RegExp}function Ui(e){return typeof e=="string"}function oWe(e,t){const n=r=>Wt(`Illegal argument type: ${r||typeof e}`);return e instanceof Map?bz(e.entries(),t):Xl(e)?n("Date"):rI(e)?n("RegExp"):Ui(e)?n():En(e)?aWe(e,t):sr(e[Symbol.iterator])?uWe(e,t):as(e)?bz(Object.entries(e),t):n()}function bz(e,t=["key","value"]){const n=[],r=[];for(const[s,o]of e)n.push(s),r.push(o);const i={};return t[0]&&(i[t[0]]=n),t[1]&&(i[t[1]]=r),i}function aWe(e,t){const n=e.length,r={},i=s=>r[s]=Array(n);if(n){t=t||Object.keys(e[0]);const s=t.map(i),o=s.length;for(let a=0;an[o]=[];let i,s;for(const o of e){i||(t=t||Object.keys(o),i=t.map(r),s=i.length);for(let a=0;aMd(e)||Ui(e),fWe={compact:e=>Md(e)?e.filter(t=>Ma(t)):e,concat:(...e)=>[].concat(...e),includes:(e,t,n)=>R0(e)?e.includes(t,n):!1,indexof:(e,t)=>R0(e)?e.indexOf(t):-1,join:(e,t)=>Md(e)?e.join(t):yn,lastindexof:(e,t)=>R0(e)?e.lastIndexOf(t):-1,length:e=>R0(e)?e.length:0,pluck:(e,t)=>Md(e)?e.map(n=>Ma(n)?n[t]:yn):yn,reverse:e=>Md(e)?e.slice().reverse():Ui(e)?e.split("").reverse().join(""):yn,slice:(e,t,n)=>R0(e)?e.slice(t,n):yn};function dWe(e,t,n,r,i){return e==null?null:en?1/0:(e=Math.max(t,Math.min(e,n)),t+r*Math.floor(1e-14+(e-t)/r+(i||0)))}function Uw(e,t,n="0"){const r=e+"",i=r.length;return i(e<10?"0":"")+e,hWe=e=>e<0?"-"+Uw(-e,6):e>9999?"+"+Uw(e,6):Uw(e,4);function cse(e,t,n,r,i,s,o,a,u){const l=a?"Z":"";return hWe(e)+"-"+su(t+1)+"-"+su(n)+(!u||o?"T"+su(r)+":"+su(i)+":"+su(s)+"."+Uw(o,3)+l:s?"T"+su(r)+":"+su(i)+":"+su(s)+l:i||r||!a?"T"+su(r)+":"+su(i)+l:"")}function fse(e,t){return isNaN(e)?"Invalid Date":cse(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds(),!1,t)}function LC(e,t){return isNaN(e)?"Invalid Date":cse(e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate(),e.getUTCHours(),e.getUTCMinutes(),e.getUTCSeconds(),e.getUTCMilliseconds(),!0,t)}const pWe=/^([-+]\d{2})?\d{4}(-\d{2}(-\d{2})?)?(T\d{2}:\d{2}(:\d{2}(\.\d{3})?)?(Z|[-+]\d{2}:\d{2})?)?$/;function mWe(e){return e.match(pWe)&&!isNaN(Date.parse(e))}function gWe(e,t=Date.parse){return mWe(e)?t(e):e}const dse=6e4,hse=864e5,pse=6048e5,xr=new Date,Ar=new Date,Dr=e=>(xr.setTime(typeof e=="string"?gWe(e):e),xr);function yWe(e,t,n,r,i,s,o){return arguments.length?new Date(e,t||0,n??1,r||0,i||0,s||0,o||0):new Date(Date.now())}function vWe(e,t,n,r,i,s,o){return arguments.length?new Date(Date.UTC(e,t||0,n??1,r||0,i||0,s||0,o||0)):new Date(Date.now())}function _We(e){Ar.setTime(+e),Ar.setHours(0,0,0,0),xr.setTime(+Ar),xr.setMonth(0),xr.setDate(1);const t=(Ar.getTimezoneOffset()-xr.getTimezoneOffset())*dse;return Math.floor(1+(Ar-xr-t)/hse)}function bWe(e){Ar.setTime(+e),Ar.setUTCHours(0,0,0,0);const t=Date.UTC(Ar.getUTCFullYear(),0,1);return Math.floor(1+(Ar-t)/hse)}function wWe(e,t){const n=t||0;Ar.setTime(+e),Ar.setDate(Ar.getDate()-(Ar.getDay()+7-n)%7),Ar.setHours(0,0,0,0),xr.setTime(+e),xr.setMonth(0),xr.setDate(1),xr.setDate(1-(xr.getDay()+7-n)%7),xr.setHours(0,0,0,0);const r=(Ar.getTimezoneOffset()-xr.getTimezoneOffset())*dse;return Math.floor((1+(Ar-xr)-r)/pse)}function EWe(e,t){const n=t||0;return Ar.setTime(+e),Ar.setUTCDate(Ar.getUTCDate()-(Ar.getUTCDay()+7-n)%7),Ar.setUTCHours(0,0,0,0),xr.setTime(+e),xr.setUTCMonth(0),xr.setUTCDate(1),xr.setUTCDate(1-(xr.getUTCDay()+7-n)%7),xr.setUTCHours(0,0,0,0),Math.floor((1+(Ar-xr))/pse)}const SWe={format_date:(e,t)=>fse(Dr(e),!t),format_utcdate:(e,t)=>LC(Dr(e),!t),timestamp:e=>+Dr(e),year:e=>Dr(e).getFullYear(),quarter:e=>Math.floor(Dr(e).getMonth()/3),month:e=>Dr(e).getMonth(),date:e=>Dr(e).getDate(),dayofweek:e=>Dr(e).getDay(),hours:e=>Dr(e).getHours(),minutes:e=>Dr(e).getMinutes(),seconds:e=>Dr(e).getSeconds(),milliseconds:e=>Dr(e).getMilliseconds(),utcyear:e=>Dr(e).getUTCFullYear(),utcquarter:e=>Math.floor(Dr(e).getUTCMonth()/3),utcmonth:e=>Dr(e).getUTCMonth(),utcdate:e=>Dr(e).getUTCDate(),utcdayofweek:e=>Dr(e).getUTCDay(),utchours:e=>Dr(e).getUTCHours(),utcminutes:e=>Dr(e).getUTCMinutes(),utcseconds:e=>Dr(e).getUTCSeconds(),utcmilliseconds:e=>Dr(e).getUTCMilliseconds(),datetime:yWe,dayofyear:_We,week:wWe,utcdatetime:vWe,utcdayofyear:bWe,utcweek:EWe,now:Date.now};function W6(e,t){return e==null||t==null||e!==e||t!==t?!1:e===t?!0:Xl(e)||Xl(t)?+e==+t:rI(e)&&rI(t)?e+""==t+"":as(e)&&as(t)?TWe(e,t):!1}function TWe(e,t){if(Object.getPrototypeOf(e)!==Object.getPrototypeOf(t))return!1;if(e.length||t.length)return Ez(e,t);const n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length||(n.sort(),r.sort(),!Ez(n,r,(s,o)=>s===o)))return!1;const i=n.length;for(let s=0;sJSON.parse(e),to_json:e=>JSON.stringify(e)};let xWe=Math.random;function Ng(){return xWe()}const CWe={random:Ng,is_nan:Number.isNaN,is_finite:Number.isFinite,abs:Math.abs,cbrt:Math.cbrt,ceil:Math.ceil,clz32:Math.clz32,exp:Math.exp,expm1:Math.expm1,floor:Math.floor,fround:Math.fround,greatest:Math.max,least:Math.min,log:Math.log,log10:Math.log10,log1p:Math.log1p,log2:Math.log2,pow:Math.pow,round:Math.round,sign:Math.sign,sqrt:Math.sqrt,trunc:Math.trunc,degrees:e=>180*e/Math.PI,radians:e=>Math.PI*e/180,acos:Math.acos,acosh:Math.acosh,asin:Math.asin,asinh:Math.asinh,atan:Math.atan,atan2:Math.atan2,atanh:Math.atanh,cos:Math.cos,cosh:Math.cosh,sin:Math.sin,sinh:Math.sinh,tan:Math.tan,tanh:Math.tanh};function q6(e){return e instanceof Map}function AWe(e){return e instanceof Set}function Vw(e){return q6(e)||AWe(e)}function qO(e){return Array.from(e)}const PWe={has:(e,t)=>Vw(e)?e.has(t):e!=null?Ya(e,t):!1,keys:e=>q6(e)?qO(e.keys()):e!=null?Object.keys(e):[],values:e=>Vw(e)?qO(e.values()):e!=null?Object.values(e):[],entries:e=>Vw(e)?qO(e.entries()):e!=null?Object.entries(e):[],object:e=>e?Object.fromEntries(e):yn};function OWe(e,t,n){if(t instanceof Map){if(t.has(e))return t.get(e)}else if(Ya(t,e))return t[e];return n!==void 0?n:e}function RWe(e,t,n){let r=arguments.length;e=+e,t=+t,n=r<2?(t=e,e=0,1):r<3?1:+n,r=Math.max(0,Math.ceil((t-e)/n))|0;const i=new Array(r);for(let s=0;se==null?e:new Date(e),parse_float:e=>e==null?e:Number.parseFloat(e),parse_int:(e,t)=>e==null?e:Number.parseInt(e,t),endswith:(e,t,n)=>e==null?!1:String(e).endsWith(t,n),match:(e,t,n)=>{const r=e==null?e:String(e).match(t);return n==null||r==null?r:typeof n=="number"?r[n]:r.groups?r.groups[n]:null},normalize:(e,t)=>e==null?e:String(e).normalize(t),padend:(e,t,n)=>e==null?e:String(e).padEnd(t,n),padstart:(e,t,n)=>e==null?e:String(e).padStart(t,n),upper:e=>e==null?e:String(e).toUpperCase(),lower:e=>e==null?e:String(e).toLowerCase(),repeat:(e,t)=>e==null?e:String(e).repeat(t),replace:(e,t,n)=>e==null?e:String(e).replace(t,String(n)),substring:(e,t,n)=>e==null?e:String(e).substring(t,n),split:(e,t,n)=>e==null?[]:String(e).split(t,n),startswith:(e,t,n)=>e==null?!1:String(e).startsWith(t,n),trim:e=>e==null?e:String(e).trim()},Bp={bin:dWe,equal:W6,recode:OWe,sequence:RWe,...fWe,...SWe,...IWe,...CWe,...PWe,...NWe};function Lv(e){return typeof e=="bigint"}function el(e){return e===void 0?e+"":Lv(e)?e+"n":JSON.stringify(e)}function Vt(e,t=[],n=[]){return new kWe(e,io(t),io(n))}let kWe=class{constructor(t,n,r){this.name=t,this.fields=n,this.params=r}toString(){const t=[...this.fields.map(n=>`d[${el(n)}]`),...this.params.map(el)];return`d => op.${this.name}(${t})`}toObject(){return{expr:this.toString(),func:!0}}};const mse=e=>Vt("any",e),gse=()=>Vt("count"),yse=e=>Vt("array_agg",e),vse=e=>Vt("array_agg_distinct",e),_se=(e,t)=>Vt("map_agg",[e,t]),bse=(e,t)=>Vt("object_agg",[e,t]),wse=(e,t)=>Vt("entries_agg",[e,t]);({...Bp});function DWe(e,t){e=Vw(e)?e:new Set(e);let n=t,r=0;for(;e.has(n);)n=t+ ++r;return n}function $We(e,t){if(!e||!t)return e;const{keys:n,rows:r,size:i}=e,s=new Int32Array(i);t.scan(c=>s[n[c]]=1);const o=s.reduce((c,f)=>c+f,0);if(o===i)return e;const a=Array(o);let u=0;for(let c=0;cl[c]=s[n[c]]),{...e,keys:l,rows:a,size:u}}function LWe(e,t,n,r){const{keys:i,rows:s,size:o}=e;let a=s,u=o,l=null;if(n){l=new Int32Array(o),t(p=>l[i[p]]=1);const h=l.reduce((p,m)=>p+m,0);if(h!==o){a=Array(h),u=0;for(let p=0;pf[++c]=l[i[h]]:h=>f[++c]=i[h]),{...e,keys:f,rows:a,size:u}}function MWe(e,t,n,r){const i=r==="map"||r===!0?_se:r==="entries"?wse:r==="object"?bse:Wt('groups option must be "map", "entries", or "object".'),{names:s}=e.groups(),o=DWe(e.columnNames(),"_");let a=e.select().reify(t).create({data:{[o]:n}}).rollup({[o]:yse(o)});for(let u=s.length;--u>=0;)a=a.groupby(s.slice(0,u)).rollup({[o]:i(s[u],o)});return a.get(o)}const FWe="ArrayPattern",BWe="ArrowFunctionExpression",jWe="FunctionExpression",vf="Identifier",kg="Literal",Ese="MemberExpression",UWe="ObjectExpression",Sse="ObjectPattern",Tse="Property",i1="Column",VWe="Constant",zWe="Dictionary",HWe="Function",WWe="Parameter",Ise="Op",Kn=(e,t)=>{const n=qWe[e.type];return n?n(e,t):Wt(`Unsupported expression construct: ${e.type}`)},GO=(e,t)=>"("+Kn(e.left,t)+" "+e.operator+" "+Kn(e.right,t)+")",YO=(e,t)=>"("+fu(e.params,t)+")=>"+Kn(e.body,t),Sz=(e,t)=>Kn(e.callee,t)+"("+fu(e.arguments,t)+")",fu=(e,t,n=",")=>e.map(r=>Kn(r,t)).join(n),xse=e=>e.computed?`[${el(e.name)}]`:`.${e.name}`,Tz=(e,t,n)=>{const r=e.table||"";return`data${r}${xse(e)}.${n}(${t.index}${r})`},qWe={Constant:e=>e.raw,Column:(e,t)=>Tz(e,t,"get"),Dictionary:(e,t)=>Tz(e,t,"key"),Function:e=>`fn.${e.name}`,Parameter:e=>`$${xse(e)}`,Op:(e,t)=>`op(${el(e.name)},${t.op||t.index})`,Literal:e=>e.raw,Identifier:e=>e.name,TemplateLiteral:(e,t)=>{const{quasis:n,expressions:r}=e,i=r.length;let s=n[0].value.raw;for(let o=0;o{const n=!e.computed,r=Kn(e.object,t),i=Kn(e.property,t);return r+(n?"."+i:"["+i+"]")},CallExpression:Sz,NewExpression:(e,t)=>"new "+Sz(e,t),ArrayExpression:(e,t)=>"["+fu(e.elements,t)+"]",AssignmentExpression:GO,BinaryExpression:GO,LogicalExpression:GO,UnaryExpression:(e,t)=>"("+e.operator+Kn(e.argument,t)+")",ConditionalExpression:(e,t)=>"("+Kn(e.test,t)+"?"+Kn(e.consequent,t)+":"+Kn(e.alternate,t)+")",ObjectExpression:(e,t)=>"({"+fu(e.properties,t)+"})",Property:(e,t)=>{const n=Kn(e.key,t);return(e.computed?`[${n}]`:n)+":"+Kn(e.value,t)},ArrowFunctionExpression:YO,FunctionExpression:YO,FunctionDeclaration:YO,ArrayPattern:(e,t)=>"["+fu(e.elements,t)+"]",ObjectPattern:(e,t)=>"{"+fu(e.properties,t)+"}",VariableDeclaration:(e,t)=>e.kind+" "+fu(e.declarations,t,","),VariableDeclarator:(e,t)=>Kn(e.id,t)+"="+Kn(e.init,t),SpreadElement:(e,t)=>"..."+Kn(e.argument,t),BlockStatement:(e,t)=>"{"+fu(e.body,t,";")+";}",BreakStatement:()=>"break",ExpressionStatement:(e,t)=>Kn(e.expression,t),IfStatement:(e,t)=>"if ("+Kn(e.test,t)+")"+Kn(e.consequent,t)+(e.alternate?" else "+Kn(e.alternate,t):""),SwitchStatement:(e,t)=>"switch ("+Kn(e.discriminant,t)+") {"+fu(e.cases,t,"")+"}",SwitchCase:(e,t)=>(e.test?"case "+Kn(e.test,t):"default")+": "+fu(e.consequent,t,";")+";",ReturnStatement:(e,t)=>"return "+Kn(e.argument,t),Program:(e,t)=>Kn(e.body[0],t)};function iI(e,t={index:"row"}){return Kn(e,t)}function GWe(e,t,n=15,r=!0,i=0,s){const a=Math.LN10;if(s==null){const u=Math.ceil(Math.log(n)/a),l=t-e||Math.abs(e)||1,c=[5,2];for(s=Math.max(i,Math.pow(10,Math.round(Math.log(l)/a)-u));Math.ceil(l/s)>n;)s*=10;const f=c.length;for(let d=0;d=i&&l/h<=n&&(s=h)}}if(r){let u=Math.log(s);const l=u>=0?0:~~(-u/a)+1,c=Math.pow(10,-l-1);u=Math.floor(e/s+c)*s,e=e0&&(t+=","),t+=`"${r}":${Km(e[r])}`;return t+="}",t}function sI(e,t){const n=e.length;return n===1?(r,i)=>Km(e[0](r,i)):(r,i)=>{let s="";for(let o=0;o0&&(s+="|");const a=e[o](r,i);if(t&&(a==null||a!==a))return null;s+=Km(a)}return s}}function KWe(){const e=new Map;return{count(){return e.size},values(){return Array.from(e.values(),t=>t.v)},increment(t){const n=Km(t),r=e.get(n);r?++r.n:e.set(n,{v:t,n:1})},decrement(t){const n=Km(t),r=e.get(n);r.n===1?e.delete(n):--r.n},forEach(t){e.forEach(({v:n,n:r})=>t(n,r))}}}function Sl(){}function QWe(e,t=0,n=e.length){let r=e[t++];for(let i=t;iXr({value:e=>e.count}),param:[]},array_agg:{create:()=>Xr({init:e=>e.values=!0,value:e=>e.list.values(e.stream)}),param:[1]},object_agg:{create:()=>Xr({init:e=>e.values=!0,value:e=>Object.fromEntries(e.list.values())}),param:[2]},map_agg:{create:()=>Xr({init:e=>e.values=!0,value:e=>new Map(e.list.values())}),param:[2]},entries_agg:{create:()=>Xr({init:e=>e.values=!0,value:e=>e.list.values(e.stream)}),param:[2]},any:{create:()=>Xr({add:(e,t)=>{e.any==null&&(e.any=t)},value:e=>e.valid?e.any:yn}),param:[1]},valid:{create:()=>Xr({value:e=>e.valid}),param:[1]},invalid:{create:()=>Xr({value:e=>e.count-e.valid}),param:[1]},distinct:{create:()=>({init:e=>e.distinct=KWe(),value:e=>e.distinct.count()+(e.valid===e.count?0:1),add:(e,t)=>e.distinct.increment(t),rem:(e,t)=>e.distinct.decrement(t)}),param:[1]},array_agg_distinct:{create:()=>Xr({value:e=>e.distinct.values()}),param:[1],req:["distinct"]},mode:{create:()=>Xr({value:e=>{let t=yn,n=0;return e.distinct.forEach((r,i)=>{i>n&&(n=i,t=r)}),t}}),param:[1],req:["distinct"]},sum:{create:()=>({init:e=>e.sum=0,value:e=>e.valid?e.sum:yn,add:(e,t)=>Lv(t)?e.sum===0?e.sum=t:e.sum+=t:e.sum+=+t,rem:(e,t)=>e.sum-=t}),param:[1]},product:{create:()=>({init:e=>Iz(e,1),value:e=>e.valid?e.product_v?Iz(e,QWe(e.list.values())):e.product:void 0,add:(e,t)=>Lv(t)&&e.product===1?e.product=t:e.product*=t,rem:(e,t)=>t==0||t===1/0||t===-1/0?e.product_v=!0:e.product/=t}),param:[1],stream:["array_agg"]},mean:{create:()=>({init:e=>e.mean=0,value:e=>e.valid?e.mean:yn,add:(e,t)=>{e.mean_d=t-e.mean,e.mean+=e.mean_d/e.valid},rem:(e,t)=>{e.mean_d=t-e.mean,e.mean-=e.valid?e.mean_d/e.valid:e.mean}}),param:[1]},average:{create:()=>Xr({value:e=>e.valid?e.mean:yn}),param:[1],req:["mean"]},variance:{create:()=>({init:e=>e.dev=0,value:e=>e.valid>1?e.dev/(e.valid-1):yn,add:(e,t)=>e.dev+=e.mean_d*(t-e.mean),rem:(e,t)=>e.dev-=e.mean_d*(t-e.mean)}),param:[1],req:["mean"]},variancep:{create:()=>Xr({value:e=>e.valid>1?e.dev/e.valid:yn}),param:[1],req:["variance"]},stdev:{create:()=>Xr({value:e=>e.valid>1?Math.sqrt(e.dev/(e.valid-1)):yn}),param:[1],req:["variance"]},stdevp:{create:()=>Xr({value:e=>e.valid>1?Math.sqrt(e.dev/e.valid):yn}),param:[1],req:["variance"]},min:{create:()=>({init:e=>e.min=yn,value:e=>e.min=Number.isNaN(e.min)?e.list.min():e.min,add:(e,t)=>{(t{t<=e.min&&(e.min=NaN)}}),param:[1],stream:["array_agg"]},max:{create:()=>({init:e=>e.max=yn,value:e=>e.max=Number.isNaN(e.max)?e.list.max():e.max,add:(e,t)=>{(t>e.max||e.max===yn)&&(e.max=t)},rem:(e,t)=>{t>=e.max&&(e.max=NaN)}}),param:[1],stream:["array_agg"]},quantile:{create:e=>Xr({value:t=>t.list.quantile(e)}),param:[1,1],req:["array_agg"]},median:{create:()=>Xr({value:e=>e.list.quantile(.5)}),param:[1],req:["array_agg"]},covariance:{create:()=>({init:e=>{e.cov=e.mean_x=e.mean_y=e.dev_x=e.dev_y=0},value:e=>e.valid>1?e.cov/(e.valid-1):yn,add:(e,t,n)=>{const r=t-e.mean_x,i=n-e.mean_y;e.mean_x+=r/e.valid,e.mean_y+=i/e.valid;const s=n-e.mean_y;e.dev_x+=r*(t-e.mean_x),e.dev_y+=i*s,e.cov+=r*s},rem:(e,t,n)=>{const r=t-e.mean_x,i=n-e.mean_y;e.mean_x-=e.valid?r/e.valid:e.mean_x,e.mean_y-=e.valid?i/e.valid:e.mean_y;const s=n-e.mean_y;e.dev_x-=r*(t-e.mean_x),e.dev_y-=i*s,e.cov-=r*s}}),param:[2]},covariancep:{create:()=>Xr({value:e=>e.valid>1?e.cov/e.valid:yn}),param:[2],req:["covariance"]},corr:{create:()=>Xr({value:e=>e.valid>1?e.cov/(Math.sqrt(e.dev_x)*Math.sqrt(e.dev_y)):yn}),param:[2],req:["covariance"]},bins:{create:(e,t,n,r)=>Xr({value:i=>GWe(i.min,i.max,e,t,n,r)}),param:[1,4],req:["min","max"]}},xz={create(){let e;return{init:()=>e=1,value:t=>{const n=t.index;return n&&!t.peer(n)?e=n+1:e}}},param:[]},Cz={create(){let e;return{init:()=>e=0,value:t=>{const{index:n,peer:r,size:i}=t;let s=n;if(ee.index+1}},param:[]},rank:xz,avg_rank:{create(){let e,t;return{init:()=>(e=-1,t=1),value:n=>{const r=n.index;if(r>=e){for(t=e=r+1;n.peer(e);t+=++e);t/=e-r}return t}}},param:[]},dense_rank:{create(){let e;return{init:()=>e=1,value:t=>{const n=t.index;return n&&!t.peer(n)?++e:e}}},param:[]},percent_rank:{create(){const{init:e,value:t}=xz.create();return{init:e,value:n=>(t(n)-1)/(n.size-1)}},param:[]},cume_dist:Cz,ntile:{create(e){e=+e,e>0||Wt("ntile num must be greater than zero.");const{init:t,value:n}=Cz.create();return{init:t,value:r=>Math.ceil(e*n(r))}},param:[0,1]},lag:{create(e,t=yn){return e=+e||1,{init:Sl,value:(n,r)=>{const i=n.index-e;return i>=0?n.value(i,r):t}}},param:[1,2]},lead:{create(e,t=yn){return e=+e||1,{init:Sl,value:(n,r)=>{const i=n.index+e;return ie.value(e.i0,t)}},param:[1]},last_value:{create(){return{init:Sl,value:(e,t)=>e.value(e.i1-1,t)}},param:[1]},nth_value:{create(e){return e=+e,e>0||Wt("nth_value nth must be greater than zero."),{init:Sl,value:(t,n)=>{const r=t.i0+(e-1);return rt=e,value:(n,r)=>{const i=n.value(n.index,r);return Ma(i)?t=i:t}}},param:[1,1]},fill_up:{create(e=yn){let t,n;return{init:()=>(t=e,n=-1),value:(r,i)=>r.index<=n?t:(n=XWe(r,i,r.index))>=0?t=r.value(n,i):(n=r.size,t=e)}},param:[1,1]}};function XWe(e,t,n){for(const r=e.size;nN0(e,t,n),expr:(e,t)=>N0(`(row,data,op)=>${e}`,Bp,t),expr2:(e,t)=>N0(`(row0,data0,row,data)=>${e}`,Bp,t),join:(e,t)=>N0(`(row1,data1,row2,data2)=>${e}`,Bp,t),param:(e,t)=>N0(e,Bp,t)},JWe={"==":1,"!=":1,"===":1,"!==":1};function Nse(e,t,n=0,r,i){if(e.type=i1,e.name=t,e.table=n,i&&r&&sr(r.keyFor)){const s=JWe[i.operator]?i.left===e?i.right:i.left:i.callee&&i.callee.name==="equal"?i.arguments[i.arguments[0]===e?1:0]:null;s&&s.type===kg&&ZWe(i,e,s,r.keyFor(s.value))}return e}function ZWe(e,t,n,r){return r<0?(e.type=kg,e.value=!1,e.raw="false"):(t.type=zWe,n.value=r,n.raw=r+""),!0}function MC(e){return En(e)?e:q6(e)?e.entries():e?Object.entries(e):[]}const kse="row_object";function Dse(e,t){e.type=UWe;const n=e.properties=[];for(const r of MC(t)){const[i,s]=En(r)?r:[r,r];n.push({type:Tse,key:{type:kg,raw:el(s)},value:Nse({computed:!0},i)})}return e}function $se(e){return iI(Dse({},e))}function Lse(e){return K6.expr($se(e))}function Q6(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,r=Object.getOwnPropertySymbols(e);i=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function un(e){return this instanceof un?(this.v=e,this):new un(e)}function Fd(e,t,n){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var r=n.apply(e,t||[]),i,s=[];return i={},o("next"),o("throw"),o("return"),i[Symbol.asyncIterator]=function(){return this},i;function o(d){r[d]&&(i[d]=function(h){return new Promise(function(p,m){s.push([d,h,p,m])>1||a(d,h)})})}function a(d,h){try{u(r[d](h))}catch(p){f(s[0][3],p)}}function u(d){d.value instanceof un?Promise.resolve(d.value.v).then(l,c):f(s[0][2],d)}function l(d){a("next",d)}function c(d){a("throw",d)}function f(d,h){d(h),s.shift(),s.length&&a(s[0][0],s[0][1])}}function KO(e){var t,n;return t={},r("next"),r("throw",function(i){throw i}),r("return"),t[Symbol.iterator]=function(){return this},t;function r(i,s){t[i]=e[i]?function(o){return(n=!n)?{value:un(e[i](o)),done:!1}:s?s(o):o}:s}}function My(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],n;return t?t.call(e):(e=typeof Az=="function"?Az(e):e[Symbol.iterator](),n={},r("next"),r("throw"),r("return"),n[Symbol.asyncIterator]=function(){return this},n);function r(s){n[s]=e[s]&&function(o){return new Promise(function(a,u){o=e[s](o),i(a,u,o.done,o.value)})}}function i(s,o,a,u){Promise.resolve(u).then(function(l){s({value:l,done:a})},o)}}const eqe=new TextDecoder("utf-8"),sk=e=>eqe.decode(e),tqe=new TextEncoder,X6=e=>tqe.encode(e),nqe=e=>typeof e=="boolean",Ls=e=>typeof e=="function",Zf=e=>e!=null&&Object(e)===e,FC=e=>Zf(e)&&Ls(e.then),J6=e=>Zf(e)&&Ls(e[Symbol.iterator]),BC=e=>Zf(e)&&Ls(e[Symbol.asyncIterator]),rqe=e=>Zf(e)&&"done"in e&&"value"in e,Mse=e=>"_getDOMStream"in e&&"_getNodeStream"in e,iqe=e=>Zf(e)&&Ls(e.abort)&&Ls(e.getWriter)&&!Mse(e),sqe=e=>Zf(e)&&Ls(e.end)&&Ls(e.write)&&nqe(e.writable)&&!Mse(e),oqe=e=>Zf(e)&&Ls(e.clear)&&Ls(e.bytes)&&Ls(e.position)&&Ls(e.setPosition)&&Ls(e.capacity)&&Ls(e.getBufferIdentifier)&&Ls(e.createLong),Z6=typeof SharedArrayBuffer<"u"?SharedArrayBuffer:ArrayBuffer;function aqe(e){const t=e[0]?[e[0]]:[];let n,r,i,s;for(let o,a,u=0,l=0,c=e.length;++uc+f.byteLength,0);let i,s,o,a=0,u=-1;const l=Math.min(t||Number.POSITIVE_INFINITY,r);for(const c=n.length;++ufi(Int32Array,e),Mn=e=>fi(Uint8Array,e),ok=e=>(e.next(),e);function*uqe(e,t){const n=function*(i){yield i},r=typeof t=="string"||ArrayBuffer.isView(t)||t instanceof ArrayBuffer||t instanceof Z6?n(t):J6(t)?t:n(t);return yield*ok(function*(i){let s=null;do s=i.next(yield fi(e,s));while(!s.done)}(r[Symbol.iterator]())),new e}const lqe=e=>uqe(Uint8Array,e);function Fse(e,t){return Fd(this,arguments,function*(){if(FC(t))return yield un(yield un(yield*KO(My(Fse(e,yield un(t))))));const r=function(o){return Fd(this,arguments,function*(){yield yield un(yield un(o))})},i=function(o){return Fd(this,arguments,function*(){yield un(yield*KO(My(ok(function*(a){let u=null;do u=a.next(yield u==null?void 0:u.value);while(!u.done)}(o[Symbol.iterator]())))))})},s=typeof t=="string"||ArrayBuffer.isView(t)||t instanceof ArrayBuffer||t instanceof Z6?r(t):J6(t)?i(t):BC(t)?t:r(t);return yield un(yield*KO(My(ok(function(o){return Fd(this,arguments,function*(){let a=null;do a=yield un(o.next(yield yield un(fi(e,a))));while(!a.done)})}(s[Symbol.asyncIterator]()))))),yield un(new e)})}const cqe=e=>Fse(Uint8Array,e);function Bse(e,t,n){if(e!==0){n=n.slice(0,t);for(let r=-1,i=n.length;++r0)do if(e[n]!==t[n])return!1;while(++n(e.next(),e);function*dqe(e){let t,n=!1,r=[],i,s,o,a=0;function u(){return s==="peek"?tl(r,o)[0]:([i,r,a]=tl(r,o),i)}({cmd:s,size:o}=yield null);const l=lqe(e)[Symbol.iterator]();try{do if({done:t,value:i}=Number.isNaN(o-a)?l.next():l.next(o-a),!t&&i.byteLength>0&&(r.push(i),a+=i.byteLength),t||o<=a)do({cmd:s,size:o}=yield u());while(o0&&(i.push(s),u+=s.byteLength),n||a<=u)do({cmd:o,size:a}=yield yield un(l()));while(a0&&(i.push(Mn(s)),u+=s.byteLength),n||a<=u)do({cmd:o,size:a}=yield yield un(l()));while(a{})}get closed(){return this.reader?this.reader.closed.catch(()=>{}):Promise.resolve()}releaseLock(){this.reader&&this.reader.releaseLock(),this.reader=null}cancel(t){return Il(this,void 0,void 0,function*(){const{reader:n,source:r}=this;n&&(yield n.cancel(t).catch(()=>{})),r&&r.locked&&this.releaseLock()})}read(t){return Il(this,void 0,void 0,function*(){if(t===0)return{done:this.reader==null,value:new Uint8Array(0)};const n=yield this.reader.read();return!n.done&&(n.value=Mn(n)),n})}}const QO=(e,t)=>{const n=i=>r([t,i]);let r;return[t,n,new Promise(i=>(r=i)&&e.once(t,n))]};function gqe(e){return Fd(this,arguments,function*(){const n=[];let r="error",i=!1,s=null,o,a,u=0,l=[],c;function f(){return o==="peek"?tl(l,a)[0]:([c,l,u]=tl(l,a),c)}if({cmd:o,size:a}=yield yield un(null),e.isTTY)return yield yield un(new Uint8Array(0)),yield un(null);try{n[0]=QO(e,"end"),n[1]=QO(e,"error");do{if(n[2]=QO(e,"readable"),[r,s]=yield un(Promise.race(n.map(h=>h[2]))),r==="error")break;if((i=r==="end")||(Number.isFinite(a-u)?(c=Mn(e.read(a-u)),c.byteLength0&&(l.push(c),u+=c.byteLength)),i||a<=u)do({cmd:o,size:a}=yield yield un(f()));while(a{for(const[g,v]of h)e.off(g,v);try{const g=e.destroy;g&&g.call(e,p),p=void 0}catch(g){p=g||p}finally{p!=null?y(p):m()}})}})}var gs;(function(e){e[e.V1=0]="V1",e[e.V2=1]="V2",e[e.V3=2]="V3",e[e.V4=3]="V4",e[e.V5=4]="V5"})(gs||(gs={}));var so;(function(e){e[e.Sparse=0]="Sparse",e[e.Dense=1]="Dense"})(so||(so={}));var $i;(function(e){e[e.HALF=0]="HALF",e[e.SINGLE=1]="SINGLE",e[e.DOUBLE=2]="DOUBLE"})($i||($i={}));var nl;(function(e){e[e.DAY=0]="DAY",e[e.MILLISECOND=1]="MILLISECOND"})(nl||(nl={}));var vt;(function(e){e[e.SECOND=0]="SECOND",e[e.MILLISECOND=1]="MILLISECOND",e[e.MICROSECOND=2]="MICROSECOND",e[e.NANOSECOND=3]="NANOSECOND"})(vt||(vt={}));var rl;(function(e){e[e.YEAR_MONTH=0]="YEAR_MONTH",e[e.DAY_TIME=1]="DAY_TIME",e[e.MONTH_DAY_NANO=2]="MONTH_DAY_NANO"})(rl||(rl={}));var pi;(function(e){e[e.NONE=0]="NONE",e[e.Schema=1]="Schema",e[e.DictionaryBatch=2]="DictionaryBatch",e[e.RecordBatch=3]="RecordBatch",e[e.Tensor=4]="Tensor",e[e.SparseTensor=5]="SparseTensor"})(pi||(pi={}));var G;(function(e){e[e.NONE=0]="NONE",e[e.Null=1]="Null",e[e.Int=2]="Int",e[e.Float=3]="Float",e[e.Binary=4]="Binary",e[e.Utf8=5]="Utf8",e[e.Bool=6]="Bool",e[e.Decimal=7]="Decimal",e[e.Date=8]="Date",e[e.Time=9]="Time",e[e.Timestamp=10]="Timestamp",e[e.Interval=11]="Interval",e[e.List=12]="List",e[e.Struct=13]="Struct",e[e.Union=14]="Union",e[e.FixedSizeBinary=15]="FixedSizeBinary",e[e.FixedSizeList=16]="FixedSizeList",e[e.Map=17]="Map",e[e.Duration=18]="Duration",e[e.Dictionary=-1]="Dictionary",e[e.Int8=-2]="Int8",e[e.Int16=-3]="Int16",e[e.Int32=-4]="Int32",e[e.Int64=-5]="Int64",e[e.Uint8=-6]="Uint8",e[e.Uint16=-7]="Uint16",e[e.Uint32=-8]="Uint32",e[e.Uint64=-9]="Uint64",e[e.Float16=-10]="Float16",e[e.Float32=-11]="Float32",e[e.Float64=-12]="Float64",e[e.DateDay=-13]="DateDay",e[e.DateMillisecond=-14]="DateMillisecond",e[e.TimestampSecond=-15]="TimestampSecond",e[e.TimestampMillisecond=-16]="TimestampMillisecond",e[e.TimestampMicrosecond=-17]="TimestampMicrosecond",e[e.TimestampNanosecond=-18]="TimestampNanosecond",e[e.TimeSecond=-19]="TimeSecond",e[e.TimeMillisecond=-20]="TimeMillisecond",e[e.TimeMicrosecond=-21]="TimeMicrosecond",e[e.TimeNanosecond=-22]="TimeNanosecond",e[e.DenseUnion=-23]="DenseUnion",e[e.SparseUnion=-24]="SparseUnion",e[e.IntervalDayTime=-25]="IntervalDayTime",e[e.IntervalYearMonth=-26]="IntervalYearMonth",e[e.DurationSecond=-27]="DurationSecond",e[e.DurationMillisecond=-28]="DurationMillisecond",e[e.DurationMicrosecond=-29]="DurationMicrosecond",e[e.DurationNanosecond=-30]="DurationNanosecond"})(G||(G={}));var _l;(function(e){e[e.OFFSET=0]="OFFSET",e[e.DATA=1]="DATA",e[e.VALIDITY=2]="VALIDITY",e[e.TYPE=3]="TYPE"})(_l||(_l={}));const yqe=void 0;function vh(e){if(e===null)return"null";if(e===yqe)return"undefined";switch(typeof e){case"number":return`${e}`;case"bigint":return`${e}`;case"string":return`"${e}"`}return typeof e[Symbol.toPrimitive]=="function"?e[Symbol.toPrimitive]("string"):ArrayBuffer.isView(e)?e instanceof BigInt64Array||e instanceof BigUint64Array?`[${[...e].map(t=>vh(t))}]`:`[${e}]`:ArrayBuffer.isView(e)?`[${e}]`:JSON.stringify(e,(t,n)=>typeof n=="bigint"?`${n}`:n)}const vqe=Symbol.for("isArrowBigNum");function ru(e,...t){return t.length===0?Object.setPrototypeOf(fi(this.TypedArray,e),this.constructor.prototype):Object.setPrototypeOf(new this.TypedArray(e,...t),this.constructor.prototype)}ru.prototype[vqe]=!0;ru.prototype.toJSON=function(){return`"${Fv(this)}"`};ru.prototype.valueOf=function(){return jse(this)};ru.prototype.toString=function(){return Fv(this)};ru.prototype[Symbol.toPrimitive]=function(e="default"){switch(e){case"number":return jse(this);case"string":return Fv(this);case"default":return _qe(this)}return Fv(this)};function dm(...e){return ru.apply(this,e)}function hm(...e){return ru.apply(this,e)}function Mv(...e){return ru.apply(this,e)}Object.setPrototypeOf(dm.prototype,Object.create(Int32Array.prototype));Object.setPrototypeOf(hm.prototype,Object.create(Uint32Array.prototype));Object.setPrototypeOf(Mv.prototype,Object.create(Uint32Array.prototype));Object.assign(dm.prototype,ru.prototype,{constructor:dm,signed:!0,TypedArray:Int32Array,BigIntArray:BigInt64Array});Object.assign(hm.prototype,ru.prototype,{constructor:hm,signed:!1,TypedArray:Uint32Array,BigIntArray:BigUint64Array});Object.assign(Mv.prototype,ru.prototype,{constructor:Mv,signed:!0,TypedArray:Uint32Array,BigIntArray:BigUint64Array});function jse(e){const{buffer:t,byteOffset:n,length:r,signed:i}=e,s=new BigUint64Array(t,n,r),o=i&&s.at(-1)&BigInt(1)<{if(e.byteLength===8)return`${new e.BigIntArray(e.buffer,e.byteOffset,1)[0]}`;if(!e.signed)return XO(e);let t=new Uint16Array(e.buffer,e.byteOffset,e.byteLength/2);if(new Int16Array([t.at(-1)])[0]>=0)return XO(e);t=t.slice();let r=1;for(let s=0;se.byteLength===8?new e.BigIntArray(e.buffer,e.byteOffset,1)[0]:Fv(e);function XO(e){let t="";const n=new Uint32Array(2);let r=new Uint16Array(e.buffer,e.byteOffset,e.byteLength/2);const i=new Uint32Array((r=new Uint16Array(r).reverse()).buffer);let s=-1;const o=r.length-1;do{for(n[0]=r[s=0];sNumber.MAX_SAFE_INTEGER))throw new TypeError(`${e} is not safe to convert to a number.`);return Number(e)}var Use,Vse,zse,Hse,Wse,qse,Gse,Yse,Kse,Qse,Xse,Jse,Zse,eoe,toe,noe,roe,ioe,soe,ooe;class Bt{static isNull(t){return(t==null?void 0:t.typeId)===G.Null}static isInt(t){return(t==null?void 0:t.typeId)===G.Int}static isFloat(t){return(t==null?void 0:t.typeId)===G.Float}static isBinary(t){return(t==null?void 0:t.typeId)===G.Binary}static isUtf8(t){return(t==null?void 0:t.typeId)===G.Utf8}static isBool(t){return(t==null?void 0:t.typeId)===G.Bool}static isDecimal(t){return(t==null?void 0:t.typeId)===G.Decimal}static isDate(t){return(t==null?void 0:t.typeId)===G.Date}static isTime(t){return(t==null?void 0:t.typeId)===G.Time}static isTimestamp(t){return(t==null?void 0:t.typeId)===G.Timestamp}static isInterval(t){return(t==null?void 0:t.typeId)===G.Interval}static isDuration(t){return(t==null?void 0:t.typeId)===G.Duration}static isList(t){return(t==null?void 0:t.typeId)===G.List}static isStruct(t){return(t==null?void 0:t.typeId)===G.Struct}static isUnion(t){return(t==null?void 0:t.typeId)===G.Union}static isFixedSizeBinary(t){return(t==null?void 0:t.typeId)===G.FixedSizeBinary}static isFixedSizeList(t){return(t==null?void 0:t.typeId)===G.FixedSizeList}static isMap(t){return(t==null?void 0:t.typeId)===G.Map}static isDictionary(t){return(t==null?void 0:t.typeId)===G.Dictionary}static isDenseUnion(t){return Bt.isUnion(t)&&t.mode===so.Dense}static isSparseUnion(t){return Bt.isUnion(t)&&t.mode===so.Sparse}get typeId(){return G.NONE}}Use=Symbol.toStringTag;Bt[Use]=(e=>(e.children=null,e.ArrayType=Array,e[Symbol.toStringTag]="DataType"))(Bt.prototype);let Jl=class extends Bt{toString(){return"Null"}get typeId(){return G.Null}};Vse=Symbol.toStringTag;Jl[Vse]=(e=>e[Symbol.toStringTag]="Null")(Jl.prototype);class ws extends Bt{constructor(t,n){super(),this.isSigned=t,this.bitWidth=n}get typeId(){return G.Int}get ArrayType(){switch(this.bitWidth){case 8:return this.isSigned?Int8Array:Uint8Array;case 16:return this.isSigned?Int16Array:Uint16Array;case 32:return this.isSigned?Int32Array:Uint32Array;case 64:return this.isSigned?BigInt64Array:BigUint64Array}throw new Error(`Unrecognized ${this[Symbol.toStringTag]} type`)}toString(){return`${this.isSigned?"I":"Ui"}nt${this.bitWidth}`}}zse=Symbol.toStringTag;ws[zse]=(e=>(e.isSigned=null,e.bitWidth=null,e[Symbol.toStringTag]="Int"))(ws.prototype);class tL extends ws{constructor(){super(!0,8)}get ArrayType(){return Int8Array}}class nL extends ws{constructor(){super(!0,16)}get ArrayType(){return Int16Array}}class Nf extends ws{constructor(){super(!0,32)}get ArrayType(){return Int32Array}}class rL extends ws{constructor(){super(!0,64)}get ArrayType(){return BigInt64Array}}class iL extends ws{constructor(){super(!1,8)}get ArrayType(){return Uint8Array}}class sL extends ws{constructor(){super(!1,16)}get ArrayType(){return Uint16Array}}class oL extends ws{constructor(){super(!1,32)}get ArrayType(){return Uint32Array}}class aL extends ws{constructor(){super(!1,64)}get ArrayType(){return BigUint64Array}}Object.defineProperty(tL.prototype,"ArrayType",{value:Int8Array});Object.defineProperty(nL.prototype,"ArrayType",{value:Int16Array});Object.defineProperty(Nf.prototype,"ArrayType",{value:Int32Array});Object.defineProperty(rL.prototype,"ArrayType",{value:BigInt64Array});Object.defineProperty(iL.prototype,"ArrayType",{value:Uint8Array});Object.defineProperty(sL.prototype,"ArrayType",{value:Uint16Array});Object.defineProperty(oL.prototype,"ArrayType",{value:Uint32Array});Object.defineProperty(aL.prototype,"ArrayType",{value:BigUint64Array});class kf extends Bt{constructor(t){super(),this.precision=t}get typeId(){return G.Float}get ArrayType(){switch(this.precision){case $i.HALF:return Uint16Array;case $i.SINGLE:return Float32Array;case $i.DOUBLE:return Float64Array}throw new Error(`Unrecognized ${this[Symbol.toStringTag]} type`)}toString(){return`Float${this.precision<<5||16}`}}Hse=Symbol.toStringTag;kf[Hse]=(e=>(e.precision=null,e[Symbol.toStringTag]="Float"))(kf.prototype);class aoe extends kf{constructor(){super($i.HALF)}}class uL extends kf{constructor(){super($i.SINGLE)}}class lL extends kf{constructor(){super($i.DOUBLE)}}Object.defineProperty(aoe.prototype,"ArrayType",{value:Uint16Array});Object.defineProperty(uL.prototype,"ArrayType",{value:Float32Array});Object.defineProperty(lL.prototype,"ArrayType",{value:Float64Array});let Bv=class extends Bt{constructor(){super()}get typeId(){return G.Binary}toString(){return"Binary"}};Wse=Symbol.toStringTag;Bv[Wse]=(e=>(e.ArrayType=Uint8Array,e[Symbol.toStringTag]="Binary"))(Bv.prototype);let Qm=class extends Bt{constructor(){super()}get typeId(){return G.Utf8}toString(){return"Utf8"}};qse=Symbol.toStringTag;Qm[qse]=(e=>(e.ArrayType=Uint8Array,e[Symbol.toStringTag]="Utf8"))(Qm.prototype);let jv=class extends Bt{constructor(){super()}get typeId(){return G.Bool}toString(){return"Bool"}};Gse=Symbol.toStringTag;jv[Gse]=(e=>(e.ArrayType=Uint8Array,e[Symbol.toStringTag]="Bool"))(jv.prototype);let aI=class extends Bt{constructor(t,n,r=128){super(),this.scale=t,this.precision=n,this.bitWidth=r}get typeId(){return G.Decimal}toString(){return`Decimal[${this.precision}e${this.scale>0?"+":""}${this.scale}]`}};Yse=Symbol.toStringTag;aI[Yse]=(e=>(e.scale=null,e.precision=null,e.ArrayType=Uint32Array,e[Symbol.toStringTag]="Decimal"))(aI.prototype);class Xm extends Bt{constructor(t){super(),this.unit=t}get typeId(){return G.Date}toString(){return`Date${(this.unit+1)*32}<${nl[this.unit]}>`}}Kse=Symbol.toStringTag;Xm[Kse]=(e=>(e.unit=null,e.ArrayType=Int32Array,e[Symbol.toStringTag]="Date"))(Xm.prototype);class bqe extends Xm{constructor(){super(nl.DAY)}}class wqe extends Xm{constructor(){super(nl.MILLISECOND)}}class Zl extends Bt{constructor(t,n){super(),this.unit=t,this.bitWidth=n}get typeId(){return G.Time}toString(){return`Time${this.bitWidth}<${vt[this.unit]}>`}get ArrayType(){switch(this.bitWidth){case 32:return Int32Array;case 64:return BigInt64Array}throw new Error(`Unrecognized ${this[Symbol.toStringTag]} type`)}}Qse=Symbol.toStringTag;Zl[Qse]=(e=>(e.unit=null,e.bitWidth=null,e[Symbol.toStringTag]="Time"))(Zl.prototype);class Eqe extends Zl{constructor(){super(vt.SECOND,32)}}class Sqe extends Zl{constructor(){super(vt.MILLISECOND,32)}}class Tqe extends Zl{constructor(){super(vt.MICROSECOND,64)}}class Iqe extends Zl{constructor(){super(vt.NANOSECOND,64)}}class uI extends Bt{constructor(t,n){super(),this.unit=t,this.timezone=n}get typeId(){return G.Timestamp}toString(){return`Timestamp<${vt[this.unit]}${this.timezone?`, ${this.timezone}`:""}>`}}Xse=Symbol.toStringTag;uI[Xse]=(e=>(e.unit=null,e.timezone=null,e.ArrayType=Int32Array,e[Symbol.toStringTag]="Timestamp"))(uI.prototype);class Jm extends Bt{constructor(t){super(),this.unit=t}get typeId(){return G.Interval}toString(){return`Interval<${rl[this.unit]}>`}}Jse=Symbol.toStringTag;Jm[Jse]=(e=>(e.unit=null,e.ArrayType=Int32Array,e[Symbol.toStringTag]="Interval"))(Jm.prototype);class xqe extends Jm{constructor(){super(rl.DAY_TIME)}}class Cqe extends Jm{constructor(){super(rl.YEAR_MONTH)}}let lI=class extends Bt{constructor(t){super(),this.unit=t}get typeId(){return G.Duration}toString(){return`Duration<${vt[this.unit]}>`}};Zse=Symbol.toStringTag;lI[Zse]=(e=>(e.unit=null,e.ArrayType=BigInt64Array,e[Symbol.toStringTag]="Duration"))(lI.prototype);let Zm=class extends Bt{constructor(t){super(),this.children=[t]}get typeId(){return G.List}toString(){return`List<${this.valueType}>`}get valueType(){return this.children[0].type}get valueField(){return this.children[0]}get ArrayType(){return this.valueType.ArrayType}};eoe=Symbol.toStringTag;Zm[eoe]=(e=>(e.children=null,e[Symbol.toStringTag]="List"))(Zm.prototype);class rs extends Bt{constructor(t){super(),this.children=t}get typeId(){return G.Struct}toString(){return`Struct<{${this.children.map(t=>`${t.name}:${t.type}`).join(", ")}}>`}}toe=Symbol.toStringTag;rs[toe]=(e=>(e.children=null,e[Symbol.toStringTag]="Struct"))(rs.prototype);class Uv extends Bt{constructor(t,n,r){super(),this.mode=t,this.children=r,this.typeIds=n=Int32Array.from(n),this.typeIdToChildIndex=n.reduce((i,s,o)=>(i[s]=o)&&i||i,Object.create(null))}get typeId(){return G.Union}toString(){return`${this[Symbol.toStringTag]}<${this.children.map(t=>`${t.type}`).join(" | ")}>`}}noe=Symbol.toStringTag;Uv[noe]=(e=>(e.mode=null,e.typeIds=null,e.children=null,e.typeIdToChildIndex=null,e.ArrayType=Int8Array,e[Symbol.toStringTag]="Union"))(Uv.prototype);let cI=class extends Bt{constructor(t){super(),this.byteWidth=t}get typeId(){return G.FixedSizeBinary}toString(){return`FixedSizeBinary[${this.byteWidth}]`}};roe=Symbol.toStringTag;cI[roe]=(e=>(e.byteWidth=null,e.ArrayType=Uint8Array,e[Symbol.toStringTag]="FixedSizeBinary"))(cI.prototype);let eg=class extends Bt{constructor(t,n){super(),this.listSize=t,this.children=[n]}get typeId(){return G.FixedSizeList}get valueType(){return this.children[0].type}get valueField(){return this.children[0]}get ArrayType(){return this.valueType.ArrayType}toString(){return`FixedSizeList[${this.listSize}]<${this.valueType}>`}};ioe=Symbol.toStringTag;eg[ioe]=(e=>(e.children=null,e.listSize=null,e[Symbol.toStringTag]="FixedSizeList"))(eg.prototype);class Vv extends Bt{constructor(t,n=!1){var r,i,s;if(super(),this.children=[t],this.keysSorted=n,t&&(t.name="entries",!((r=t==null?void 0:t.type)===null||r===void 0)&&r.children)){const o=(i=t==null?void 0:t.type)===null||i===void 0?void 0:i.children[0];o&&(o.name="key");const a=(s=t==null?void 0:t.type)===null||s===void 0?void 0:s.children[1];a&&(a.name="value")}}get typeId(){return G.Map}get keyType(){return this.children[0].type.children[0].type}get valueType(){return this.children[0].type.children[1].type}get childType(){return this.children[0].type}toString(){return`Map<{${this.children[0].type.children.map(t=>`${t.name}:${t.type}`).join(", ")}}>`}}soe=Symbol.toStringTag;Vv[soe]=(e=>(e.children=null,e.keysSorted=null,e[Symbol.toStringTag]="Map_"))(Vv.prototype);const Aqe=(e=>()=>++e)(-1);class Df extends Bt{constructor(t,n,r,i){super(),this.indices=n,this.dictionary=t,this.isOrdered=i||!1,this.id=r==null?Aqe():Ka(r)}get typeId(){return G.Dictionary}get children(){return this.dictionary.children}get valueType(){return this.dictionary}get ArrayType(){return this.dictionary.ArrayType}toString(){return`Dictionary<${this.indices}, ${this.dictionary}>`}}ooe=Symbol.toStringTag;Df[ooe]=(e=>(e.id=null,e.indices=null,e.isOrdered=null,e.dictionary=null,e[Symbol.toStringTag]="Dictionary"))(Df.prototype);function pu(e){const t=e;switch(e.typeId){case G.Decimal:return e.bitWidth/32;case G.Timestamp:return 2;case G.Date:return 1+t.unit;case G.Interval:return 1+t.unit;case G.FixedSizeList:return t.listSize;case G.FixedSizeBinary:return t.byteWidth;default:return 1}}class qt{visitMany(t,...n){return t.map((r,i)=>this.visit(r,...n.map(s=>s[i])))}visit(...t){return this.getVisitFn(t[0],!1).apply(this,t)}getVisitFn(t,n=!0){return Pqe(this,t,n)}getVisitFnByTypeId(t,n=!0){return pp(this,t,n)}visitNull(t,...n){return null}visitBool(t,...n){return null}visitInt(t,...n){return null}visitFloat(t,...n){return null}visitUtf8(t,...n){return null}visitBinary(t,...n){return null}visitFixedSizeBinary(t,...n){return null}visitDate(t,...n){return null}visitTimestamp(t,...n){return null}visitTime(t,...n){return null}visitDecimal(t,...n){return null}visitList(t,...n){return null}visitStruct(t,...n){return null}visitUnion(t,...n){return null}visitDictionary(t,...n){return null}visitInterval(t,...n){return null}visitDuration(t,...n){return null}visitFixedSizeList(t,...n){return null}visitMap(t,...n){return null}}function Pqe(e,t,n=!0){return typeof t=="number"?pp(e,t,n):typeof t=="string"&&t in G?pp(e,G[t],n):t&&t instanceof Bt?pp(e,Oz(t),n):t!=null&&t.type&&t.type instanceof Bt?pp(e,Oz(t.type),n):pp(e,G.NONE,n)}function pp(e,t,n=!0){let r=null;switch(t){case G.Null:r=e.visitNull;break;case G.Bool:r=e.visitBool;break;case G.Int:r=e.visitInt;break;case G.Int8:r=e.visitInt8||e.visitInt;break;case G.Int16:r=e.visitInt16||e.visitInt;break;case G.Int32:r=e.visitInt32||e.visitInt;break;case G.Int64:r=e.visitInt64||e.visitInt;break;case G.Uint8:r=e.visitUint8||e.visitInt;break;case G.Uint16:r=e.visitUint16||e.visitInt;break;case G.Uint32:r=e.visitUint32||e.visitInt;break;case G.Uint64:r=e.visitUint64||e.visitInt;break;case G.Float:r=e.visitFloat;break;case G.Float16:r=e.visitFloat16||e.visitFloat;break;case G.Float32:r=e.visitFloat32||e.visitFloat;break;case G.Float64:r=e.visitFloat64||e.visitFloat;break;case G.Utf8:r=e.visitUtf8;break;case G.Binary:r=e.visitBinary;break;case G.FixedSizeBinary:r=e.visitFixedSizeBinary;break;case G.Date:r=e.visitDate;break;case G.DateDay:r=e.visitDateDay||e.visitDate;break;case G.DateMillisecond:r=e.visitDateMillisecond||e.visitDate;break;case G.Timestamp:r=e.visitTimestamp;break;case G.TimestampSecond:r=e.visitTimestampSecond||e.visitTimestamp;break;case G.TimestampMillisecond:r=e.visitTimestampMillisecond||e.visitTimestamp;break;case G.TimestampMicrosecond:r=e.visitTimestampMicrosecond||e.visitTimestamp;break;case G.TimestampNanosecond:r=e.visitTimestampNanosecond||e.visitTimestamp;break;case G.Time:r=e.visitTime;break;case G.TimeSecond:r=e.visitTimeSecond||e.visitTime;break;case G.TimeMillisecond:r=e.visitTimeMillisecond||e.visitTime;break;case G.TimeMicrosecond:r=e.visitTimeMicrosecond||e.visitTime;break;case G.TimeNanosecond:r=e.visitTimeNanosecond||e.visitTime;break;case G.Decimal:r=e.visitDecimal;break;case G.List:r=e.visitList;break;case G.Struct:r=e.visitStruct;break;case G.Union:r=e.visitUnion;break;case G.DenseUnion:r=e.visitDenseUnion||e.visitUnion;break;case G.SparseUnion:r=e.visitSparseUnion||e.visitUnion;break;case G.Dictionary:r=e.visitDictionary;break;case G.Interval:r=e.visitInterval;break;case G.IntervalDayTime:r=e.visitIntervalDayTime||e.visitInterval;break;case G.IntervalYearMonth:r=e.visitIntervalYearMonth||e.visitInterval;break;case G.Duration:r=e.visitDuration;break;case G.DurationSecond:r=e.visitDurationSecond||e.visitDuration;break;case G.DurationMillisecond:r=e.visitDurationMillisecond||e.visitDuration;break;case G.DurationMicrosecond:r=e.visitDurationMicrosecond||e.visitDuration;break;case G.DurationNanosecond:r=e.visitDurationNanosecond||e.visitDuration;break;case G.FixedSizeList:r=e.visitFixedSizeList;break;case G.Map:r=e.visitMap;break}if(typeof r=="function")return r;if(!n)return()=>null;throw new Error(`Unrecognized type '${G[t]}'`)}function Oz(e){switch(e.typeId){case G.Null:return G.Null;case G.Int:{const{bitWidth:t,isSigned:n}=e;switch(t){case 8:return n?G.Int8:G.Uint8;case 16:return n?G.Int16:G.Uint16;case 32:return n?G.Int32:G.Uint32;case 64:return n?G.Int64:G.Uint64}return G.Int}case G.Float:switch(e.precision){case $i.HALF:return G.Float16;case $i.SINGLE:return G.Float32;case $i.DOUBLE:return G.Float64}return G.Float;case G.Binary:return G.Binary;case G.Utf8:return G.Utf8;case G.Bool:return G.Bool;case G.Decimal:return G.Decimal;case G.Time:switch(e.unit){case vt.SECOND:return G.TimeSecond;case vt.MILLISECOND:return G.TimeMillisecond;case vt.MICROSECOND:return G.TimeMicrosecond;case vt.NANOSECOND:return G.TimeNanosecond}return G.Time;case G.Timestamp:switch(e.unit){case vt.SECOND:return G.TimestampSecond;case vt.MILLISECOND:return G.TimestampMillisecond;case vt.MICROSECOND:return G.TimestampMicrosecond;case vt.NANOSECOND:return G.TimestampNanosecond}return G.Timestamp;case G.Date:switch(e.unit){case nl.DAY:return G.DateDay;case nl.MILLISECOND:return G.DateMillisecond}return G.Date;case G.Interval:switch(e.unit){case rl.DAY_TIME:return G.IntervalDayTime;case rl.YEAR_MONTH:return G.IntervalYearMonth}return G.Interval;case G.Duration:switch(e.unit){case vt.SECOND:return G.DurationSecond;case vt.MILLISECOND:return G.DurationMillisecond;case vt.MICROSECOND:return G.DurationMicrosecond;case vt.NANOSECOND:return G.DurationNanosecond}return G.Duration;case G.Map:return G.Map;case G.List:return G.List;case G.Struct:return G.Struct;case G.Union:switch(e.mode){case so.Dense:return G.DenseUnion;case so.Sparse:return G.SparseUnion}return G.Union;case G.FixedSizeBinary:return G.FixedSizeBinary;case G.FixedSizeList:return G.FixedSizeList;case G.Dictionary:return G.Dictionary}throw new Error(`Unrecognized type '${G[e.typeId]}'`)}qt.prototype.visitInt8=null;qt.prototype.visitInt16=null;qt.prototype.visitInt32=null;qt.prototype.visitInt64=null;qt.prototype.visitUint8=null;qt.prototype.visitUint16=null;qt.prototype.visitUint32=null;qt.prototype.visitUint64=null;qt.prototype.visitFloat16=null;qt.prototype.visitFloat32=null;qt.prototype.visitFloat64=null;qt.prototype.visitDateDay=null;qt.prototype.visitDateMillisecond=null;qt.prototype.visitTimestampSecond=null;qt.prototype.visitTimestampMillisecond=null;qt.prototype.visitTimestampMicrosecond=null;qt.prototype.visitTimestampNanosecond=null;qt.prototype.visitTimeSecond=null;qt.prototype.visitTimeMillisecond=null;qt.prototype.visitTimeMicrosecond=null;qt.prototype.visitTimeNanosecond=null;qt.prototype.visitDenseUnion=null;qt.prototype.visitSparseUnion=null;qt.prototype.visitIntervalDayTime=null;qt.prototype.visitIntervalYearMonth=null;qt.prototype.visitDuration=null;qt.prototype.visitDurationSecond=null;qt.prototype.visitDurationMillisecond=null;qt.prototype.visitDurationMicrosecond=null;qt.prototype.visitDurationNanosecond=null;const uoe=new Float64Array(1),op=new Uint32Array(uoe.buffer);function loe(e){const t=(e&31744)>>10,n=(e&1023)/1024,r=Math.pow(-1,(e&32768)>>15);switch(t){case 31:return r*(n?Number.NaN:1/0);case 0:return r*(n?6103515625e-14*n:0)}return r*Math.pow(2,t-15)*(1+n)}function coe(e){if(e!==e)return 32256;uoe[0]=e;const t=(op[1]&2147483648)>>16&65535;let n=op[1]&2146435072,r=0;return n>=1089470464?op[0]>0?n=31744:(n=(n&2080374784)>>16,r=(op[1]&1048575)>>10):n<=1056964608?(r=1048576+(op[1]&1048575),r=1048576+(r<<(n>>20)-998)>>21,n=0):(n=n-1056964608>>10,r=(op[1]&1048575)+512>>10),t|n|r&65535}class It extends qt{}function Ot(e){return(t,n,r)=>{if(t.setValid(n,r!=null))return e(t,n,r)}}const Oqe=(e,t,n)=>{e[t]=Math.trunc(n/864e5)},cL=(e,t,n)=>{e[t]=Math.trunc(n%4294967296),e[t+1]=Math.trunc(n/4294967296)},Rqe=(e,t,n)=>{e[t]=Math.trunc(n*1e3%4294967296),e[t+1]=Math.trunc(n*1e3/4294967296)},Nqe=(e,t,n)=>{e[t]=Math.trunc(n*1e6%4294967296),e[t+1]=Math.trunc(n*1e6/4294967296)},foe=(e,t,n,r)=>{if(n+1{const i=e+n;r?t[i>>3]|=1<>3]&=~(1<{e[t]=n},fL=({values:e},t,n)=>{e[t]=n},doe=({values:e},t,n)=>{e[t]=coe(n)},Dqe=(e,t,n)=>{switch(e.type.precision){case $i.HALF:return doe(e,t,n);case $i.SINGLE:case $i.DOUBLE:return fL(e,t,n)}},dL=({values:e},t,n)=>{Oqe(e,t,n.valueOf())},hL=({values:e},t,n)=>{cL(e,t*2,n.valueOf())},hoe=({stride:e,values:t},n,r)=>{t.set(r.subarray(0,e),e*n)},$qe=({values:e,valueOffsets:t},n,r)=>foe(e,t,n,r),Lqe=({values:e,valueOffsets:t},n,r)=>{foe(e,t,n,X6(r))},poe=(e,t,n)=>{e.type.unit===nl.DAY?dL(e,t,n):hL(e,t,n)},pL=({values:e},t,n)=>cL(e,t*2,n/1e3),mL=({values:e},t,n)=>cL(e,t*2,n),gL=({values:e},t,n)=>Rqe(e,t*2,n),yL=({values:e},t,n)=>Nqe(e,t*2,n),moe=(e,t,n)=>{switch(e.type.unit){case vt.SECOND:return pL(e,t,n);case vt.MILLISECOND:return mL(e,t,n);case vt.MICROSECOND:return gL(e,t,n);case vt.NANOSECOND:return yL(e,t,n)}},vL=({values:e},t,n)=>{e[t]=n},_L=({values:e},t,n)=>{e[t]=n},bL=({values:e},t,n)=>{e[t]=n},wL=({values:e},t,n)=>{e[t]=n},goe=(e,t,n)=>{switch(e.type.unit){case vt.SECOND:return vL(e,t,n);case vt.MILLISECOND:return _L(e,t,n);case vt.MICROSECOND:return bL(e,t,n);case vt.NANOSECOND:return wL(e,t,n)}},yoe=({values:e,stride:t},n,r)=>{e.set(r.subarray(0,t),t*n)},Mqe=(e,t,n)=>{const r=e.children[0],i=e.valueOffsets,s=ca.getVisitFn(r);if(Array.isArray(n))for(let o=-1,a=i[t],u=i[t+1];a{const r=e.children[0],{valueOffsets:i}=e,s=ca.getVisitFn(r);let{[t]:o,[t+1]:a}=i;const u=n instanceof Map?n.entries():Object.entries(n);for(const l of u)if(s(r,o,l),++o>=a)break},Bqe=(e,t)=>(n,r,i,s)=>r&&n(r,e,t[s]),jqe=(e,t)=>(n,r,i,s)=>r&&n(r,e,t.get(s)),Uqe=(e,t)=>(n,r,i,s)=>r&&n(r,e,t.get(i.name)),Vqe=(e,t)=>(n,r,i,s)=>r&&n(r,e,t[i.name]),zqe=(e,t,n)=>{const r=e.type.children.map(s=>ca.getVisitFn(s.type)),i=n instanceof Map?Uqe(t,n):n instanceof Sn?jqe(t,n):Array.isArray(n)?Bqe(t,n):Vqe(t,n);e.type.children.forEach((s,o)=>i(r[o],e.children[o],s,o))},Hqe=(e,t,n)=>{e.type.mode===so.Dense?voe(e,t,n):_oe(e,t,n)},voe=(e,t,n)=>{const r=e.type.typeIdToChildIndex[e.typeIds[t]],i=e.children[r];ca.visit(i,e.valueOffsets[t],n)},_oe=(e,t,n)=>{const r=e.type.typeIdToChildIndex[e.typeIds[t]],i=e.children[r];ca.visit(i,t,n)},Wqe=(e,t,n)=>{var r;(r=e.dictionary)===null||r===void 0||r.set(e.values[t],n)},boe=(e,t,n)=>{e.type.unit===rl.DAY_TIME?EL(e,t,n):SL(e,t,n)},EL=({values:e},t,n)=>{e.set(n.subarray(0,2),2*t)},SL=({values:e},t,n)=>{e[t]=n[0]*12+n[1]%12},TL=({values:e},t,n)=>{e[t]=n},IL=({values:e},t,n)=>{e[t]=n},xL=({values:e},t,n)=>{e[t]=n},CL=({values:e},t,n)=>{e[t]=n},woe=(e,t,n)=>{switch(e.type.unit){case vt.SECOND:return TL(e,t,n);case vt.MILLISECOND:return IL(e,t,n);case vt.MICROSECOND:return xL(e,t,n);case vt.NANOSECOND:return CL(e,t,n)}},qqe=(e,t,n)=>{const{stride:r}=e,i=e.children[0],s=ca.getVisitFn(i);if(Array.isArray(n))for(let o=-1,a=t*r;++o`${vh(t)}: ${vh(n)}`).join(", ")}}`}[Symbol.for("nodejs.util.inspect.custom")](){return this.toString()}[Symbol.iterator](){return new Gqe(this[Pa],this[pm])}}class Gqe{constructor(t,n){this.childIndex=0,this.children=t.children,this.rowIndex=n,this.childFields=t.type.children,this.numChildren=this.childFields.length}[Symbol.iterator](){return this}next(){const t=this.childIndex;return tn.name)}has(t,n){return t[Pa].type.children.findIndex(r=>r.name===n)!==-1}getOwnPropertyDescriptor(t,n){if(t[Pa].type.children.findIndex(r=>r.name===n)!==-1)return{writable:!0,enumerable:!0,configurable:!0}}get(t,n){if(Reflect.has(t,n))return t[n];const r=t[Pa].type.children.findIndex(i=>i.name===n);if(r!==-1){const i=oo.visit(t[Pa].children[r],t[pm]);return Reflect.set(t,n,i),i}}set(t,n,r){const i=t[Pa].type.children.findIndex(s=>s.name===n);return i!==-1?(ca.visit(t[Pa].children[i],t[pm],r),Reflect.set(t,n,r)):Reflect.has(t,n)||typeof n=="symbol"?Reflect.set(t,n,r):!1}}class _t extends qt{}function xt(e){return(t,n)=>t.getValid(n)?e(t,n):null}const Kqe=(e,t)=>864e5*e[t],PL=(e,t)=>4294967296*e[t+1]+(e[t]>>>0),Qqe=(e,t)=>4294967296*(e[t+1]/1e3)+(e[t]>>>0)/1e3,Xqe=(e,t)=>4294967296*(e[t+1]/1e6)+(e[t]>>>0)/1e6,Eoe=e=>new Date(e),Jqe=(e,t)=>Eoe(Kqe(e,t)),Zqe=(e,t)=>Eoe(PL(e,t)),eGe=(e,t)=>null,Soe=(e,t,n)=>{if(n+1>=t.length)return null;const r=t[n],i=t[n+1];return e.subarray(r,i)},tGe=({offset:e,values:t},n)=>{const r=e+n;return(t[r>>3]&1<Jqe(e,t),Ioe=({values:e},t)=>Zqe(e,t*2),ed=({stride:e,values:t},n)=>t[e*n],nGe=({stride:e,values:t},n)=>loe(t[e*n]),xoe=({values:e},t)=>e[t],rGe=({stride:e,values:t},n)=>t.subarray(e*n,e*(n+1)),iGe=({values:e,valueOffsets:t},n)=>Soe(e,t,n),sGe=({values:e,valueOffsets:t},n)=>{const r=Soe(e,t,n);return r!==null?sk(r):null},oGe=({values:e},t)=>e[t],aGe=({type:e,values:t},n)=>e.precision!==$i.HALF?t[n]:loe(t[n]),uGe=(e,t)=>e.type.unit===nl.DAY?Toe(e,t):Ioe(e,t),Coe=({values:e},t)=>1e3*PL(e,t*2),Aoe=({values:e},t)=>PL(e,t*2),Poe=({values:e},t)=>Qqe(e,t*2),Ooe=({values:e},t)=>Xqe(e,t*2),lGe=(e,t)=>{switch(e.type.unit){case vt.SECOND:return Coe(e,t);case vt.MILLISECOND:return Aoe(e,t);case vt.MICROSECOND:return Poe(e,t);case vt.NANOSECOND:return Ooe(e,t)}},Roe=({values:e},t)=>e[t],Noe=({values:e},t)=>e[t],koe=({values:e},t)=>e[t],Doe=({values:e},t)=>e[t],cGe=(e,t)=>{switch(e.type.unit){case vt.SECOND:return Roe(e,t);case vt.MILLISECOND:return Noe(e,t);case vt.MICROSECOND:return koe(e,t);case vt.NANOSECOND:return Doe(e,t)}},fGe=({values:e,stride:t},n)=>eL.decimal(e.subarray(t*n,t*(n+1))),dGe=(e,t)=>{const{valueOffsets:n,stride:r,children:i}=e,{[t*r]:s,[t*r+1]:o}=n,u=i[0].slice(s,o-s);return new Sn([u])},hGe=(e,t)=>{const{valueOffsets:n,children:r}=e,{[t]:i,[t+1]:s}=n,o=r[0];return new jC(o.slice(i,s-i))},pGe=(e,t)=>new AL(e,t),mGe=(e,t)=>e.type.mode===so.Dense?$oe(e,t):Loe(e,t),$oe=(e,t)=>{const n=e.type.typeIdToChildIndex[e.typeIds[t]],r=e.children[n];return oo.visit(r,e.valueOffsets[t])},Loe=(e,t)=>{const n=e.type.typeIdToChildIndex[e.typeIds[t]],r=e.children[n];return oo.visit(r,t)},gGe=(e,t)=>{var n;return(n=e.dictionary)===null||n===void 0?void 0:n.get(e.values[t])},yGe=(e,t)=>e.type.unit===rl.DAY_TIME?Moe(e,t):Foe(e,t),Moe=({values:e},t)=>e.subarray(2*t,2*(t+1)),Foe=({values:e},t)=>{const n=e[t],r=new Int32Array(2);return r[0]=Math.trunc(n/12),r[1]=Math.trunc(n%12),r},Boe=({values:e},t)=>e[t],joe=({values:e},t)=>e[t],Uoe=({values:e},t)=>e[t],Voe=({values:e},t)=>e[t],vGe=(e,t)=>{switch(e.type.unit){case vt.SECOND:return Boe(e,t);case vt.MILLISECOND:return joe(e,t);case vt.MICROSECOND:return Uoe(e,t);case vt.NANOSECOND:return Voe(e,t)}},_Ge=(e,t)=>{const{stride:n,children:r}=e,s=r[0].slice(t*n,n);return new Sn([s])};_t.prototype.visitNull=xt(eGe);_t.prototype.visitBool=xt(tGe);_t.prototype.visitInt=xt(oGe);_t.prototype.visitInt8=xt(ed);_t.prototype.visitInt16=xt(ed);_t.prototype.visitInt32=xt(ed);_t.prototype.visitInt64=xt(xoe);_t.prototype.visitUint8=xt(ed);_t.prototype.visitUint16=xt(ed);_t.prototype.visitUint32=xt(ed);_t.prototype.visitUint64=xt(xoe);_t.prototype.visitFloat=xt(aGe);_t.prototype.visitFloat16=xt(nGe);_t.prototype.visitFloat32=xt(ed);_t.prototype.visitFloat64=xt(ed);_t.prototype.visitUtf8=xt(sGe);_t.prototype.visitBinary=xt(iGe);_t.prototype.visitFixedSizeBinary=xt(rGe);_t.prototype.visitDate=xt(uGe);_t.prototype.visitDateDay=xt(Toe);_t.prototype.visitDateMillisecond=xt(Ioe);_t.prototype.visitTimestamp=xt(lGe);_t.prototype.visitTimestampSecond=xt(Coe);_t.prototype.visitTimestampMillisecond=xt(Aoe);_t.prototype.visitTimestampMicrosecond=xt(Poe);_t.prototype.visitTimestampNanosecond=xt(Ooe);_t.prototype.visitTime=xt(cGe);_t.prototype.visitTimeSecond=xt(Roe);_t.prototype.visitTimeMillisecond=xt(Noe);_t.prototype.visitTimeMicrosecond=xt(koe);_t.prototype.visitTimeNanosecond=xt(Doe);_t.prototype.visitDecimal=xt(fGe);_t.prototype.visitList=xt(dGe);_t.prototype.visitStruct=xt(pGe);_t.prototype.visitUnion=xt(mGe);_t.prototype.visitDenseUnion=xt($oe);_t.prototype.visitSparseUnion=xt(Loe);_t.prototype.visitDictionary=xt(gGe);_t.prototype.visitInterval=xt(yGe);_t.prototype.visitIntervalDayTime=xt(Moe);_t.prototype.visitIntervalYearMonth=xt(Foe);_t.prototype.visitDuration=xt(vGe);_t.prototype.visitDurationSecond=xt(Boe);_t.prototype.visitDurationMillisecond=xt(joe);_t.prototype.visitDurationMicrosecond=xt(Uoe);_t.prototype.visitDurationNanosecond=xt(Voe);_t.prototype.visitFixedSizeList=xt(_Ge);_t.prototype.visitMap=xt(hGe);const oo=new _t,La=Symbol.for("keys"),mm=Symbol.for("vals");class jC{constructor(t){return this[La]=new Sn([t.children[0]]).memoize(),this[mm]=t.children[1],new Proxy(this,new wGe)}[Symbol.iterator](){return new bGe(this[La],this[mm])}get size(){return this[La].length}toArray(){return Object.values(this.toJSON())}toJSON(){const t=this[La],n=this[mm],r={};for(let i=-1,s=t.length;++i`${vh(t)}: ${vh(n)}`).join(", ")}}`}[Symbol.for("nodejs.util.inspect.custom")](){return this.toString()}}class bGe{constructor(t,n){this.keys=t,this.vals=n,this.keyIndex=0,this.numKeys=t.length}[Symbol.iterator](){return this}next(){const t=this.keyIndex;return t===this.numKeys?{done:!0,value:null}:(this.keyIndex++,{done:!1,value:[this.keys.get(t),oo.visit(this.vals,t)]})}}class wGe{isExtensible(){return!1}deleteProperty(){return!1}preventExtensions(){return!0}ownKeys(t){return t[La].toArray().map(String)}has(t,n){return t[La].includes(n)}getOwnPropertyDescriptor(t,n){if(t[La].indexOf(n)!==-1)return{writable:!0,enumerable:!0,configurable:!0}}get(t,n){if(Reflect.has(t,n))return t[n];const r=t[La].indexOf(n);if(r!==-1){const i=oo.visit(Reflect.get(t,mm),r);return Reflect.set(t,n,i),i}}set(t,n,r){const i=t[La].indexOf(n);return i!==-1?(ca.visit(Reflect.get(t,mm),i,r),Reflect.set(t,n,r)):Reflect.has(t,n)?Reflect.set(t,n,r):!1}}Object.defineProperties(jC.prototype,{[Symbol.toStringTag]:{enumerable:!1,configurable:!1,value:"Row"},[La]:{writable:!0,enumerable:!1,configurable:!1,value:null},[mm]:{writable:!0,enumerable:!1,configurable:!1,value:null}});let Rz;function zoe(e,t,n,r){const{length:i=0}=e;let s=typeof t!="number"?0:t,o=typeof n!="number"?i:n;return s<0&&(s=(s%i+i)%i),o<0&&(o=(o%i+i)%i),oi&&(o=i),r?r(e,s,o):[s,o]}const Nz=e=>e!==e;function Dg(e){if(typeof e!=="object"||e===null)return Nz(e)?Nz:n=>n===e;if(e instanceof Date){const n=e.valueOf();return r=>r instanceof Date?r.valueOf()===n:!1}return ArrayBuffer.isView(e)?n=>n?fqe(e,n):!1:e instanceof Map?SGe(e):Array.isArray(e)?EGe(e):e instanceof Sn?TGe(e):IGe(e,!0)}function EGe(e){const t=[];for(let n=-1,r=e.length;++n!1;const r=[];for(let i=-1,s=n.length;++i{if(!n||typeof n!="object")return!1;switch(n.constructor){case Array:return xGe(e,n);case Map:return kz(e,n,n.keys());case jC:case AL:case Object:case void 0:return kz(e,n,t||Object.keys(n))}return n instanceof Sn?CGe(e,n):!1}}function xGe(e,t){const n=e.length;if(t.length!==n)return!1;for(let r=-1;++r>r}function fI(e,t,n){const r=n.byteLength+7&-8;if(e>0||n.byteLength>3):Woe(new OL(n,e,t,null,Hoe)).subarray(0,r)),i}return n}function Woe(e){const t=[];let n=0,r=0,i=0;for(const o of e)o&&(i|=1<0)&&(t[n++]=i);const s=new Uint8Array(t.length+7&-8);return s.set(t),s}class OL{constructor(t,n,r,i,s){this.bytes=t,this.length=r,this.context=i,this.get=s,this.bit=n%8,this.byteIndex=n>>3,this.byte=t[this.byteIndex++],this.index=0}next(){return this.index>3<<3,i=t+(t%8===0?0:8-t%8);return ak(e,t,i)+ak(e,r,n)+PGe(e,i>>3,r-i>>3)}function PGe(e,t,n){let r=0,i=Math.trunc(t);const s=new DataView(e.buffer,e.byteOffset,e.byteLength),o=n===void 0?e.byteLength:i+n;for(;o-i>=4;)r+=JO(s.getUint32(i)),i+=4;for(;o-i>=2;)r+=JO(s.getUint16(i)),i+=2;for(;o-i>=1;)r+=JO(s.getUint8(i)),i+=1;return r}function JO(e){let t=Math.trunc(e);return t=t-(t>>>1&1431655765),t=(t&858993459)+(t>>>2&858993459),(t+(t>>>4)&252645135)*16843009>>>24}const OGe=-1;class Ln{get typeId(){return this.type.typeId}get ArrayType(){return this.type.ArrayType}get buffers(){return[this.valueOffsets,this.values,this.nullBitmap,this.typeIds]}get nullable(){if(this._nullCount!==0){const{type:t}=this;return Bt.isSparseUnion(t)?this.children.some(n=>n.nullable):Bt.isDenseUnion(t)?this.children.some(n=>n.nullable):this.nullBitmap&&this.nullBitmap.byteLength>0}return!0}get byteLength(){let t=0;const{valueOffsets:n,values:r,nullBitmap:i,typeIds:s}=this;return n&&(t+=n.byteLength),r&&(t+=r.byteLength),i&&(t+=i.byteLength),s&&(t+=s.byteLength),this.children.reduce((o,a)=>o+a.byteLength,t)}get nullCount(){if(Bt.isUnion(this.type))return this.children.reduce((r,i)=>r+i.nullCount,0);let t=this._nullCount,n;return t<=OGe&&(n=this.nullBitmap)&&(this._nullCount=t=this.length-ak(n,this.offset,this.offset+this.length)),t}constructor(t,n,r,i,s,o=[],a){this.type=t,this.children=o,this.dictionary=a,this.offset=Math.floor(Math.max(n||0,0)),this.length=Math.floor(Math.max(r||0,0)),this._nullCount=Math.floor(Math.max(i||0,-1));let u;s instanceof Ln?(this.stride=s.stride,this.values=s.values,this.typeIds=s.typeIds,this.nullBitmap=s.nullBitmap,this.valueOffsets=s.valueOffsets):(this.stride=pu(t),s&&((u=s[0])&&(this.valueOffsets=u),(u=s[1])&&(this.values=u),(u=s[2])&&(this.nullBitmap=u),(u=s[3])&&(this.typeIds=u)))}getValid(t){const{type:n}=this;if(Bt.isUnion(n)){const r=n,i=this.children[r.typeIdToChildIndex[this.typeIds[t]]],s=r.mode===so.Dense?this.valueOffsets[t]:t;return i.getValid(s)}if(this.nullable&&this.nullCount>0){const r=this.offset+t;return(this.nullBitmap[r>>3]&1<>3;(!s||s.byteLength<=c)&&(s=new Uint8Array((o+a+63&-64)>>3).fill(255),this.nullCount>0&&s.set(fI(o,a,this.nullBitmap),0),Object.assign(this,{nullBitmap:s,_nullCount:-1}));const f=s[c];r=(f&l)!==0,n?s[c]=f|l:s[c]=f&~l}return r!==!!n&&(this._nullCount=this.nullCount+(n?-1:1)),n}clone(t=this.type,n=this.offset,r=this.length,i=this._nullCount,s=this,o=this.children){return new Ln(t,n,r,i,s,o,this.dictionary)}slice(t,n){const{stride:r,typeId:i,children:s}=this,o=+(this._nullCount===0)-1,a=i===16?r:1,u=this._sliceBuffers(t,n,r,i);return this.clone(this.type,this.offset+t,n,o,u,s.length===0||this.valueOffsets?s:this._sliceChildren(s,a*t,a*n))}_changeLengthAndBackfillNullBitmap(t){if(this.typeId===G.Null)return this.clone(this.type,0,t,0);const{length:n,nullCount:r}=this,i=new Uint8Array((t+63&-64)>>3).fill(255,0,n>>3);i[n>>3]=(1<0&&i.set(fI(this.offset,n,this.nullBitmap),0);const s=this.buffers;return s[_l.VALIDITY]=i,this.clone(this.type,0,t,r+(t-n),s)}_sliceBuffers(t,n,r,i){let s;const{buffers:o}=this;return(s=o[_l.TYPE])&&(o[_l.TYPE]=s.subarray(t,t+n)),(s=o[_l.OFFSET])&&(o[_l.OFFSET]=s.subarray(t,t+n+1))||(s=o[_l.DATA])&&(o[_l.DATA]=i===6?s:s.subarray(r*t,r*(t+n))),o}_sliceChildren(t,n,r){return t.map(i=>i.slice(n,r))}}Ln.prototype.children=Object.freeze([]);class Fy extends qt{visit(t){return this.getVisitFn(t.type).call(this,t)}visitNull(t){const{["type"]:n,["offset"]:r=0,["length"]:i=0}=t;return new Ln(n,r,i,i)}visitBool(t){const{["type"]:n,["offset"]:r=0}=t,i=Mn(t.nullBitmap),s=fi(n.ArrayType,t.data),{["length"]:o=s.length>>3,["nullCount"]:a=t.nullBitmap?-1:0}=t;return new Ln(n,r,o,a,[void 0,s,i])}visitInt(t){const{["type"]:n,["offset"]:r=0}=t,i=Mn(t.nullBitmap),s=fi(n.ArrayType,t.data),{["length"]:o=s.length,["nullCount"]:a=t.nullBitmap?-1:0}=t;return new Ln(n,r,o,a,[void 0,s,i])}visitFloat(t){const{["type"]:n,["offset"]:r=0}=t,i=Mn(t.nullBitmap),s=fi(n.ArrayType,t.data),{["length"]:o=s.length,["nullCount"]:a=t.nullBitmap?-1:0}=t;return new Ln(n,r,o,a,[void 0,s,i])}visitUtf8(t){const{["type"]:n,["offset"]:r=0}=t,i=Mn(t.data),s=Mn(t.nullBitmap),o=k0(t.valueOffsets),{["length"]:a=o.length-1,["nullCount"]:u=t.nullBitmap?-1:0}=t;return new Ln(n,r,a,u,[o,i,s])}visitBinary(t){const{["type"]:n,["offset"]:r=0}=t,i=Mn(t.data),s=Mn(t.nullBitmap),o=k0(t.valueOffsets),{["length"]:a=o.length-1,["nullCount"]:u=t.nullBitmap?-1:0}=t;return new Ln(n,r,a,u,[o,i,s])}visitFixedSizeBinary(t){const{["type"]:n,["offset"]:r=0}=t,i=Mn(t.nullBitmap),s=fi(n.ArrayType,t.data),{["length"]:o=s.length/pu(n),["nullCount"]:a=t.nullBitmap?-1:0}=t;return new Ln(n,r,o,a,[void 0,s,i])}visitDate(t){const{["type"]:n,["offset"]:r=0}=t,i=Mn(t.nullBitmap),s=fi(n.ArrayType,t.data),{["length"]:o=s.length/pu(n),["nullCount"]:a=t.nullBitmap?-1:0}=t;return new Ln(n,r,o,a,[void 0,s,i])}visitTimestamp(t){const{["type"]:n,["offset"]:r=0}=t,i=Mn(t.nullBitmap),s=fi(n.ArrayType,t.data),{["length"]:o=s.length/pu(n),["nullCount"]:a=t.nullBitmap?-1:0}=t;return new Ln(n,r,o,a,[void 0,s,i])}visitTime(t){const{["type"]:n,["offset"]:r=0}=t,i=Mn(t.nullBitmap),s=fi(n.ArrayType,t.data),{["length"]:o=s.length/pu(n),["nullCount"]:a=t.nullBitmap?-1:0}=t;return new Ln(n,r,o,a,[void 0,s,i])}visitDecimal(t){const{["type"]:n,["offset"]:r=0}=t,i=Mn(t.nullBitmap),s=fi(n.ArrayType,t.data),{["length"]:o=s.length/pu(n),["nullCount"]:a=t.nullBitmap?-1:0}=t;return new Ln(n,r,o,a,[void 0,s,i])}visitList(t){const{["type"]:n,["offset"]:r=0,["child"]:i}=t,s=Mn(t.nullBitmap),o=k0(t.valueOffsets),{["length"]:a=o.length-1,["nullCount"]:u=t.nullBitmap?-1:0}=t;return new Ln(n,r,a,u,[o,void 0,s],[i])}visitStruct(t){const{["type"]:n,["offset"]:r=0,["children"]:i=[]}=t,s=Mn(t.nullBitmap),{length:o=i.reduce((u,{length:l})=>Math.max(u,l),0),nullCount:a=t.nullBitmap?-1:0}=t;return new Ln(n,r,o,a,[void 0,void 0,s],i)}visitUnion(t){const{["type"]:n,["offset"]:r=0,["children"]:i=[]}=t,s=fi(n.ArrayType,t.typeIds),{["length"]:o=s.length,["nullCount"]:a=-1}=t;if(Bt.isSparseUnion(n))return new Ln(n,r,o,a,[void 0,void 0,void 0,s],i);const u=k0(t.valueOffsets);return new Ln(n,r,o,a,[u,void 0,void 0,s],i)}visitDictionary(t){const{["type"]:n,["offset"]:r=0}=t,i=Mn(t.nullBitmap),s=fi(n.indices.ArrayType,t.data),{["dictionary"]:o=new Sn([new Fy().visit({type:n.dictionary})])}=t,{["length"]:a=s.length,["nullCount"]:u=t.nullBitmap?-1:0}=t;return new Ln(n,r,a,u,[void 0,s,i],[],o)}visitInterval(t){const{["type"]:n,["offset"]:r=0}=t,i=Mn(t.nullBitmap),s=fi(n.ArrayType,t.data),{["length"]:o=s.length/pu(n),["nullCount"]:a=t.nullBitmap?-1:0}=t;return new Ln(n,r,o,a,[void 0,s,i])}visitDuration(t){const{["type"]:n,["offset"]:r=0}=t,i=Mn(t.nullBitmap),s=fi(n.ArrayType,t.data),{["length"]:o=s.length,["nullCount"]:a=t.nullBitmap?-1:0}=t;return new Ln(n,r,o,a,[void 0,s,i])}visitFixedSizeList(t){const{["type"]:n,["offset"]:r=0,["child"]:i=new Fy().visit({type:n.valueType})}=t,s=Mn(t.nullBitmap),{["length"]:o=i.length/pu(n),["nullCount"]:a=t.nullBitmap?-1:0}=t;return new Ln(n,r,o,a,[void 0,void 0,s],[i])}visitMap(t){const{["type"]:n,["offset"]:r=0,["child"]:i=new Fy().visit({type:n.childType})}=t,s=Mn(t.nullBitmap),o=k0(t.valueOffsets),{["length"]:a=o.length-1,["nullCount"]:u=t.nullBitmap?-1:0}=t;return new Ln(n,r,a,u,[o,void 0,s],[i])}}const RGe=new Fy;function Ji(e){return RGe.visit(e)}class Dz{constructor(t=0,n){this.numChunks=t,this.getChunkIterator=n,this.chunkIndex=0,this.chunkIterator=this.getChunkIterator(0)}next(){for(;this.chunkIndext+n.nullCount,0)}function Goe(e){return e.reduce((t,n,r)=>(t[r+1]=t[r]+n.length,t),new Uint32Array(e.length+1))}function Yoe(e,t,n,r){const i=[];for(let s=-1,o=e.length;++s=r)break;if(n>=u+l)continue;if(u>=n&&u+l<=r){i.push(a);continue}const c=Math.max(0,n-u),f=Math.min(r-u,l);i.push(a.slice(c,f-c))}return i.length===0&&i.push(e[0].slice(0,0)),i}function RL(e,t,n,r){let i=0,s=0,o=t.length-1;do{if(i>=o-1)return n0?0:-1}function kGe(e,t){const{nullBitmap:n}=e;if(!n||e.nullCount<=0)return-1;let r=0;for(const i of new OL(n,e.offset+(t||0),e.length,n,Hoe)){if(!i)return r;++r}return-1}function $t(e,t,n){if(t===void 0)return-1;if(t===null)switch(e.typeId){case G.Union:break;case G.Dictionary:break;default:return kGe(e,n)}const r=oo.getVisitFn(e),i=Dg(t);for(let s=(n||0)-1,o=e.length;++s{const i=e.data[r];return i.values.subarray(0,i.length)[Symbol.iterator]()});let n=0;return new Dz(e.data.length,r=>{const s=e.data[r].length,o=e.slice(n,n+s);return n+=s,new DGe(o)})}class DGe{constructor(t){this.vector=t,this.index=0}next(){return this.indexe+t;class td extends qt{visitNull(t,n){return 0}visitInt(t,n){return t.type.bitWidth/8}visitFloat(t,n){return t.type.ArrayType.BYTES_PER_ELEMENT}visitBool(t,n){return 1/8}visitDecimal(t,n){return t.type.bitWidth/8}visitDate(t,n){return(t.type.unit+1)*4}visitTime(t,n){return t.type.bitWidth/8}visitTimestamp(t,n){return t.type.unit===vt.SECOND?4:8}visitInterval(t,n){return(t.type.unit+1)*4}visitDuration(t,n){return 8}visitStruct(t,n){return t.children.reduce((r,i)=>r+il.visit(i,n),0)}visitFixedSizeBinary(t,n){return t.type.byteWidth}visitMap(t,n){return 8+t.children.reduce((r,i)=>r+il.visit(i,n),0)}visitDictionary(t,n){var r;return t.type.indices.bitWidth/8+(((r=t.dictionary)===null||r===void 0?void 0:r.getByteLength(t.values[n]))||0)}}const LGe=({valueOffsets:e},t)=>8+(e[t+1]-e[t]),MGe=({valueOffsets:e},t)=>8+(e[t+1]-e[t]),FGe=({valueOffsets:e,stride:t,children:n},r)=>{const i=n[0],{[r*t]:s}=e,{[r*t+1]:o}=e,a=il.getVisitFn(i.type),u=i.slice(s,o-s);let l=8;for(let c=-1,f=o-s;++c{const r=t[0],i=r.slice(n*e,e),s=il.getVisitFn(r.type);let o=0;for(let a=-1,u=i.length;++ae.type.mode===so.Dense?Joe(e,t):Zoe(e,t),Joe=({type:e,children:t,typeIds:n,valueOffsets:r},i)=>{const s=e.typeIdToChildIndex[n[i]];return 8+il.visit(t[s],r[i])},Zoe=({children:e},t)=>4+il.visitMany(e,e.map(()=>t)).reduce($Ge,0);td.prototype.visitUtf8=LGe;td.prototype.visitBinary=MGe;td.prototype.visitList=FGe;td.prototype.visitFixedSizeList=BGe;td.prototype.visitUnion=jGe;td.prototype.visitDenseUnion=Joe;td.prototype.visitSparseUnion=Zoe;const il=new td;var eae;const tae={},nae={};class Sn{constructor(t){var n,r,i;const s=t[0]instanceof Sn?t.flatMap(a=>a.data):t;if(s.length===0||s.some(a=>!(a instanceof Ln)))throw new TypeError("Vector constructor expects an Array of Data instances.");const o=(n=s[0])===null||n===void 0?void 0:n.type;switch(s.length){case 0:this._offsets=[0];break;case 1:{const{get:a,set:u,indexOf:l,byteLength:c}=tae[o.typeId],f=s[0];this.isValid=d=>NL(f,d),this.get=d=>a(f,d),this.set=(d,h)=>u(f,d,h),this.indexOf=d=>l(f,d),this.getByteLength=d=>c(f,d),this._offsets=[0,f.length];break}default:Object.setPrototypeOf(this,nae[o.typeId]),this._offsets=Goe(s);break}this.data=s,this.type=o,this.stride=pu(o),this.numChildren=(i=(r=o.children)===null||r===void 0?void 0:r.length)!==null&&i!==void 0?i:0,this.length=this._offsets.at(-1)}get byteLength(){return this.data.reduce((t,n)=>t+n.byteLength,0)}get nullCount(){return qoe(this.data)}get ArrayType(){return this.type.ArrayType}get[Symbol.toStringTag](){return`${this.VectorName}<${this.type[Symbol.toStringTag]}>`}get VectorName(){return`${G[this.type.typeId]}Vector`}isValid(t){return!1}get(t){return null}set(t,n){}indexOf(t,n){return-1}includes(t,n){return this.indexOf(t,n)>-1}getByteLength(t){return 0}[Symbol.iterator](){return kL.visit(this)}concat(...t){return new Sn(this.data.concat(t.flatMap(n=>n.data).flat(Number.POSITIVE_INFINITY)))}slice(t,n){return new Sn(zoe(this,t,n,({data:r,_offsets:i},s,o)=>Yoe(r,i,s,o)))}toJSON(){return[...this]}toArray(){const{type:t,data:n,length:r,stride:i,ArrayType:s}=this;switch(t.typeId){case G.Int:case G.Float:case G.Decimal:case G.Time:case G.Timestamp:switch(n.length){case 0:return new s;case 1:return n[0].values.subarray(0,r*i);default:return n.reduce((o,{values:a,length:u})=>(o.array.set(a.subarray(0,u*i),o.offset),o.offset+=u*i,o),{array:new s(r*i),offset:0}).array}}return[...this]}toString(){return`[${[...this].join(",")}]`}getChild(t){var n;return this.getChildAt((n=this.type.children)===null||n===void 0?void 0:n.findIndex(r=>r.name===t))}getChildAt(t){return t>-1&&tn[t])):null}get isMemoized(){return Bt.isDictionary(this.type)?this.data[0].dictionary.isMemoized:!1}memoize(){if(Bt.isDictionary(this.type)){const t=new hI(this.data[0].dictionary),n=this.data.map(r=>{const i=r.clone();return i.dictionary=t,i});return new Sn(n)}return new hI(this)}unmemoize(){if(Bt.isDictionary(this.type)&&this.isMemoized){const t=this.data[0].dictionary.unmemoize(),n=this.data.map(r=>{const i=r.clone();return i.dictionary=t,i});return new Sn(n)}return this}}eae=Symbol.toStringTag;Sn[eae]=(e=>{e.type=Bt.prototype,e.data=[],e.length=0,e.stride=1,e.numChildren=0,e._offsets=new Uint32Array([0]),e[Symbol.isConcatSpreadable]=!0;const t=Object.keys(G).map(n=>G[n]).filter(n=>typeof n=="number"&&n!==G.NONE);for(const n of t){const r=oo.getVisitFnByTypeId(n),i=ca.getVisitFnByTypeId(n),s=dI.getVisitFnByTypeId(n),o=il.getVisitFnByTypeId(n);tae[n]={get:r,set:i,indexOf:s,byteLength:o},nae[n]=Object.create(e,{isValid:{value:gm(NL)},get:{value:gm(oo.getVisitFnByTypeId(n))},set:{value:Koe(ca.getVisitFnByTypeId(n))},indexOf:{value:Qoe(dI.getVisitFnByTypeId(n))},getByteLength:{value:gm(il.getVisitFnByTypeId(n))}})}return"Vector"})(Sn.prototype);class hI extends Sn{constructor(t){super(t.data);const n=this.get,r=this.set,i=this.slice,s=new Array(this.length);Object.defineProperty(this,"get",{value(o){const a=s[o];if(a!==void 0)return a;const u=n.call(this,o);return s[o]=u,u}}),Object.defineProperty(this,"set",{value(o,a){r.call(this,o,a),s[o]=a}}),Object.defineProperty(this,"slice",{value:(o,a)=>new hI(i.call(this,o,a))}),Object.defineProperty(this,"isMemoized",{value:!0}),Object.defineProperty(this,"unmemoize",{value:()=>new Sn(this.data)}),Object.defineProperty(this,"memoize",{value:()=>this})}}function UGe(e){if(!e||e.length<=0)return function(i){return!0};let t="";const n=e.filter(r=>r===r);return n.length>0&&(t=` + */var V6=new WeakMap,wHe=function(){function e(t){this.observers=new Map,this.obj=t}return e}(),EHe=function(){function e(t,n){this.callback=t,this.observer=n}return e}();function SHe(e){return V6.get(e)}function THe(e,t){return e.observers.get(t)}function IHe(e,t){e.observers.delete(t.callback)}function xHe(e,t){t.unobserve()}function CHe(e,t){var n=[],r,i=SHe(e);if(!i)i=new wHe(e),V6.set(e,i);else{var s=THe(i,t);r=s&&s.observer}if(r)return r;if(r={},i.value=Gs(e),t){r.callback=t,r.next=null;var o=function(){JN(r)},a=function(){clearTimeout(r.next),r.next=setTimeout(o)};typeof window<"u"&&(window.addEventListener("mouseup",a),window.addEventListener("keyup",a),window.addEventListener("mousedown",a),window.addEventListener("keydown",a),window.addEventListener("change",a))}return r.patches=n,r.object=e,r.unobserve=function(){JN(r),clearTimeout(r.next),IHe(i,r),typeof window<"u"&&(window.removeEventListener("mouseup",a),window.removeEventListener("keyup",a),window.removeEventListener("mousedown",a),window.removeEventListener("keydown",a),window.removeEventListener("change",a))},i.observers.set(t,new EHe(t,r)),r}function JN(e,t){t===void 0&&(t=!1);var n=V6.get(e.object);z6(n.value,e.object,e.patches,"",t),e.patches.length&&kC(n.value,e.patches);var r=e.patches;return r.length>0&&(e.patches=[],e.callback&&e.callback(r)),r}function z6(e,t,n,r,i){if(t!==e){typeof t.toJSON=="function"&&(t=t.toJSON());for(var s=KN(t),o=KN(e),a=!1,u=o.length-1;u>=0;u--){var l=o[u],c=e[l];if(YN(t,l)&&!(t[l]===void 0&&c!==void 0&&Array.isArray(t)===!1)){var f=t[l];typeof c=="object"&&c!=null&&typeof f=="object"&&f!=null&&Array.isArray(c)===Array.isArray(f)?z6(c,f,n,r+"/"+vd(l),i):c!==f&&(i&&n.push({op:"test",path:r+"/"+vd(l),value:Gs(c)}),n.push({op:"replace",path:r+"/"+vd(l),value:Gs(f)}))}else Array.isArray(e)===Array.isArray(t)?(i&&n.push({op:"test",path:r+"/"+vd(l),value:Gs(c)}),n.push({op:"remove",path:r+"/"+vd(l)}),a=!0):(i&&n.push({op:"test",path:r,value:e}),n.push({op:"replace",path:r,value:t}))}if(!(!a&&s.length==o.length))for(var u=0;u(e.TRAVERSAL_START="Traversal_Start",e.TRAVERSAL_END="Traversal_End",e))(ey||{});function jw(e,t){const n=e.state;if(n.type==="checkpoint")return n.val;const{checkpointRef:r}=n,i=t[r],s=sse(i,e,t);s.shift();const o=s.map(u=>t[u]).map(u=>u.state.val).reduce((u,l)=>[...u,...l],[]),a=jw(i,t);return kC(a,Gs(o),!0,!1).newDocument}function PHe(e,t){const n=Object.keys(e).length;return new Set(t.map(r=>r.path.split("/")[0])).size{n=!0}),r.listen(ey.TRAVERSAL_END,()=>{n=!1});const o={add(c,f=i.current.id){i.update(i.addMetadata({id:f,meta:c}))},latestOfType(c,f=i.current.id){var d;return(d=i.backend.nodes[f].meta[c])==null?void 0:d.at(-1)},allOfType(c,f=i.current.id){return i.backend.nodes[f].meta[c]},latest(c=i.current.id){const f=i.backend.nodes[c].meta,d=Object.keys(f).reduce((h,p)=>{const m=f[p].at(-1);return m&&(h[p]=m),h},{});return Object.keys(d).length>0?d:void 0},all(c=i.current.id){return i.backend.nodes[c].meta},types(c=i.current.id){return Object.keys(i.backend.nodes[c].meta)}},a={add(c,f=i.current.id){i.update(i.addArtifact({id:f,artifact:c}))},latest(c=i.current.id){return i.backend.nodes[c].artifacts.at(-1)},all(c=i.current.id){return i.backend.nodes[c].artifacts}},u={add(c,f=i.current.id){o.add({annotation:c},f)},latest(c=i.current.id){var f;return(f=o.latestOfType("annotation",c))==null?void 0:f.val},all(c=i.current.id){var f;return(f=o.allOfType("annotation",c))==null?void 0:f.map(d=>d.val)}},l={add(c=i.current.id){o.add({bookmark:!0},c)},remove(c=i.current.id){o.add({bookmark:!1},c)},is(c=i.current.id){var f;return!!((f=o.latestOfType("bookmark",c))!=null&&f.val)},toggle(c=i.current.id){l.is(c)?l.remove(c):l.add(c)}};return{registry:e,get isTraversing(){return n},getState(c=i.current){return jw(c,i.backend.nodes)},graph:i,get current(){return i.current},get root(){return i.root},record({label:c,state:f,sideEffects:d,eventType:h,onlySideEffects:p=!1}){let m=null,y=null;const g=jw(this.current,this.graph.backend.nodes);if(p)y={type:"checkpoint",val:f};else{const v=rse(g,f);if(PHe(f,v)==="checkpoint")y={type:"checkpoint",val:f};else{const b=this.current.state.type==="checkpoint"?this.current.id:this.current.state.checkpointRef;y={type:"patch",val:v,checkpointRef:b}}}if(!y)throw new Error(`Could not calculate new state. Previous state is: ${JSON.stringify(this.current.state,null,2)}`);if(m=Zze({label:c,state:y,parent:this.current,sideEffects:d,event:h}),!m)throw new Error("State Node creation failed!");i.update(i.addNode(m))},async apply(c,f){const d=e.get(f.type),h=jw(this.current,this.graph.backend.nodes);if(d.config.hasSideEffects){const{do:p=f,undo:m}=d.func(f.payload);this.record({label:c,state:h,sideEffects:{do:[p],undo:[m]},eventType:d.config.eventType})}else{const p=d.func(h,f.payload);this.record({label:c,state:p,sideEffects:{do:[],undo:[]},eventType:d.config.eventType})}},async to(c){r.fire(ey.TRAVERSAL_START);const f=sse(i.current,i.backend.nodes[c],i.backend.nodes),d=[];for(let h=0;h0?this.to(f.children[c==="oldest"?0:f.children.length-1]):Promise.resolve(console.warn("Already at latest in this branch!"))},currentChange(c,f=!1){return i.currentChange(c,{skipOnNew:f})},done(){console.log("Setup later for URL sharing.")},tree(){return ose(i.root,i.backend.nodes)},on(c,f){r.listen(c,f)},export(){return JSON.stringify(i.backend)},exportObject(){return JSON.parse(JSON.stringify(i.backend))},import(c){const f=JSON.parse(c),d=f.current;f.current=f.root,i.update(i.load(f)),this.to(d)},importObject(c){const f=c.current;c.current=c.root,i.update(i.load(c)),this.to(f)},metadata:o,artifact:a,annotations:u,bookmarks:l}}function OHe(e,t,n){let[r,i]=[e,t];r.level>i.level&&([r,i]=[i,r]);let s=i.level-r.level;for(;zu(i)&&s!==0;)i=n[i.parent],s-=1;if(r.id===i.id)return r.id;for(;r.id!==i.id;)zu(r)&&(r=n[r.parent]),zu(i)&&(i=n[i.parent]);return r.id}function sse(e,t,n){const r=OHe(e,t,n),i=n[r],s=[],o=[];let[a,u]=[e,t];for(;a.id!==i.id;)s.push(a),zu(a)&&(a=n[a.parent]);for(s.push(a);u.id!==i.id;)o.push(u),zu(u)&&(u=n[u.parent]);const l=o.reverse();return[...s,...l].map(c=>c.id)}function RHe(e,t){if(zu(e)&&e.parent===t.id)return!0;if(zu(t)&&t.parent===e.id)return!1;throw new Error("Incorrect use of function. Nodes are not connected to each other.")}function ose(e,t){return{...e,children:e.children.map(n=>ose(t[n],t)),name:`${e.label}`}}sHe();function NHe(e){return e.length===2?dHe(e):e}class DC{static create(){return new DC}constructor(){this.registry=new Map}has(t){return this.registry.has(t)}register(t,n,r){const i=n.length===2;if(n.length>2)throw new Error("Incorrect action function signature. Action function can only have two arguments at most!");if(this.has(t))throw new Error(`Already registered: ${t}`);const{label:s=t,eventType:o=t}=r||{};return this.registry.set(t,{func:NHe(n),config:{hasSideEffects:!i,label:typeof s=="string"?()=>s:s,eventType:o}}),ju(t)}get(t){const n=this.registry.get(t);if(!n)throw new Error(`Not registered: ${t}`);return n}}var kHe="Expected a function",gz=NaN,DHe="[object Symbol]",$He=/^\s+|\s+$/g,LHe=/^[-+]0x[0-9a-f]+$/i,MHe=/^0b[01]+$/i,FHe=/^0o[0-7]+$/i,BHe=parseInt,jHe=typeof _o=="object"&&_o&&_o.Object===Object&&_o,UHe=typeof self=="object"&&self&&self.Object===Object&&self,VHe=jHe||UHe||Function("return this")(),zHe=Object.prototype,HHe=zHe.toString,WHe=Math.max,qHe=Math.min,zO=function(){return VHe.Date.now()};function GHe(e,t,n){var r,i,s,o,a,u,l=0,c=!1,f=!1,d=!0;if(typeof e!="function")throw new TypeError(kHe);t=yz(t)||0,ZN(n)&&(c=!!n.leading,f="maxWait"in n,s=f?WHe(yz(n.maxWait)||0,t):s,d="trailing"in n?!!n.trailing:d);function h(E){var I=r,A=i;return r=i=void 0,l=E,o=e.apply(A,I),o}function p(E){return l=E,a=setTimeout(g,t),c?h(E):o}function m(E){var I=E-u,A=E-l,R=t-I;return f?qHe(R,s-A):R}function y(E){var I=E-u,A=E-l;return u===void 0||I>=t||I<0||f&&A>=s}function g(){var E=zO();if(y(E))return v(E);a=setTimeout(g,m(E))}function v(E){return a=void 0,d&&r?h(E):(r=i=void 0,o)}function b(){a!==void 0&&clearTimeout(a),l=0,r=u=i=a=void 0}function S(){return a===void 0?o:v(zO())}function T(){var E=zO(),I=y(E);if(r=arguments,i=this,u=E,I){if(a===void 0)return p(u);if(f)return a=setTimeout(g,t),h(u)}return a===void 0&&(a=setTimeout(g,t)),o}return T.cancel=b,T.flush=S,T}function ZN(e){var t=typeof e;return!!e&&(t=="object"||t=="function")}function YHe(e){return!!e&&typeof e=="object"}function KHe(e){return typeof e=="symbol"||YHe(e)&&HHe.call(e)==DHe}function yz(e){if(typeof e=="number")return e;if(KHe(e))return gz;if(ZN(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=ZN(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=e.replace($He,"");var n=MHe.test(e);return n||FHe.test(e)?BHe(e.slice(2),n?2:8):LHe.test(e)?gz:+e}var QHe=GHe;const ou=eu(QHe);function ase({xScale:e,yRange:t,vertPosition:n,ticks:r,isDate:i=!1,showLines:s=!0}){const o=w.useMemo(()=>r.length>1?Math.abs(r[1].offset-r[0].offset):e.range()[0]-e.range()[1],[r,e]),a=w.useCallback(u=>(i?$6("%b%e, %Y"):yf(".2s"))(u),[i]);return C.jsxs(C.Fragment,{children:[s?C.jsx("path",{transform:`translate(0, ${t[1]})`,d:["M",e.range()[0],0,"H",e.range()[1]].join(" "),fill:"none",stroke:"lightgray"}):null,r.map(({value:u,offset:l})=>C.jsxs("g",{transform:`translate(${l}, ${n})`,children:[C.jsx("line",{y2:"6",stroke:"currentColor"}),s?C.jsx("line",{y2:`${-(t[0]-t[1])}`,stroke:"lightgray"}):null,C.jsx("foreignObject",{x:0-o/2,y:10,width:o,height:20,children:C.jsx(ua,{children:C.jsx(Wx,{withinPortal:!0,label:u,children:C.jsx(rt,{px:2,size:10,style:{textAlign:"center",textOverflow:"ellipsis",overflow:"hidden",whiteSpace:"nowrap"},children:+u==0?0:a(i?new Date(u):u)})})})})]},`${u}test`))]})}const XHe=Object.freeze(Object.defineProperty({__proto__:null,XAxis:ase},Symbol.toStringTag,{value:"Module"}));function use({dataset:e,yScale:t,xRange:n,horizontalPosition:r}){const i=w.useMemo(()=>t.ticks(6).map(o=>({value:o,yOffset:t(o)})),[t]),s=w.useMemo(()=>e==="clean_stocks"?yf(",.0%"):t.domain()[1]<5?yf(",.2r"):yf(",.0f"),[e,t]);return C.jsx(C.Fragment,{children:i.map(({value:o,yOffset:a})=>C.jsxs("g",{transform:`translate(${r}, ${a})`,children:[C.jsx("line",{x2:`${n[1]-n[0]}`,stroke:`${o===0?"black":"gainsboro"}`,strokeWidth:o===0?1:.4}),C.jsx("text",{style:{dominantBaseline:"middle",fontSize:"10px",textAnchor:"end",transform:"translateX(-6px)",fill:"black",font:"Roboto"},children:s(o)},o)]},o))})}const JHe=Object.freeze(Object.defineProperty({__proto__:null,YAxis:use},Symbol.toStringTag,{value:"Module"})),Yi={top:30,left:40,right:80,bottom:50};function ek({parameters:e,data:t,dataname:n,items:r,selection:i,range:s,guardrail:o}){const[a,u]=w.useState(null),l=R=>i!=null&&i.includes(R)?!a||a.length===0?!0:a.includes(R):!1,c=w.useMemo(()=>{const R=r.filter(L=>i==null?void 0:i.includes(L.name)).map(L=>L.group);return r.filter(L=>R==null?void 0:R.includes(L.group)).filter(L=>!(i!=null&&i.includes(L.name))).map(L=>L.name)},[i,r,n]),f=w.useMemo(()=>{const R=r.map(J=>J.group),F=t.filter(J=>R==null?void 0:R.includes(J[e.group_var]));return[...vVe(F,J=>({mean:IVe(J,V=>V[e.y_var]),upperq:P7(J,.75,V=>V[e.y_var]),lowerq:P7(J,.25,V=>V[e.y_var])}),J=>J[e.x_var])].flatMap(([J,V])=>({date:J,mean:V.mean,upperq:V.upperq,lowerq:V.lowerq}))},[t,r,e,n]),d=n==="clean_data"?800-Yi.left-Yi.right-60:800-Yi.left-Yi.right,h=400-Yi.top-Yi.bottom,{yMin:p,yMax:m}=w.useMemo(()=>{let R=[];switch(o){case"super_data":R=i==null?void 0:i.concat(c);break;default:R=i;break}const F=t.filter(ae=>R.includes(ae[e.cat_var])).map(ae=>+ae[e.y_var]).filter(ae=>ae!==null),[L,B]=n==="clean_stocks"?Pf(F):[0,Pf(F)[1]],[J,V]=[zT(f.map(ae=>ae.lowerq)),Pv(f.map(ae=>ae.upperq))],re=o==="super_summ"?zT([L,J]):L,oe=o==="super_summ"?Pv([B,V]):B;return{yMin:re,yMax:oe}},[t,i,o,f,c,e,n]),y=w.useMemo(()=>s?kv([Yi.left,d+Yi.left]).domain(s):kv([Yi.left,d+Yi.left]).domain([new Date(e.start_date),new Date(e.end_date)]),[d,s,e,n]),g=w.useMemo(()=>mh([h+Yi.top,Yi.top]).domain([p,m]).nice(),[h,m,p,n]),v=w.useMemo(()=>{const R=Array.from(new Set(t.map(F=>F[e.cat_var])));return P6(E6).domain(R)},[t,e,n]),b=w.useMemo(()=>{if(!y||!g)return;const R=$y();return R.x(L=>y(Ld("%Y-%m-%d")(L[e.x_var]))),R.y(L=>g(L[e.y_var])),R.curve(Mp),i==null?void 0:i.map(L=>({country:L,path:R(t.filter(B=>B[e.cat_var]===L))}))},[t,y,g,i,e,n]),S=w.useMemo(()=>{if(o!=="super_data")return null;const R=$y();return R.x(L=>y(Ld("%Y-%m-%d")(L[e.x_var]))),R.y(L=>g(L[e.y_var])),R.curve(Mp),c==null?void 0:c.map(L=>({country:L,path:R(t.filter(B=>B[e.cat_var]===L))}))},[t,y,g,o,c,e,n]),T=w.useMemo(()=>{if(o!=="super_summ")return null;const R=$y();R.x(J=>y(Ld("%Y-%m-%d")(J.date))),R.y(J=>g(J.mean)),R.curve(Mp);const F=R(f),L=Xie();L.x(J=>y(Ld("%Y-%m-%d")(J.date))),L.y0(J=>g(J.lowerq)),L.y1(J=>g(J.upperq)),L.curve(Mp);const B=L(f);return{meanLine:F,confidenceBands:B,data:f}},[y,g,o,f,n]),E=w.useMemo(()=>n==="clean_stocks"?"Industry Index":"Average",[n]),I=R=>R==="Eldoril North"?"Policy A":R.split(" ")[0]==="Silvoria"||R.split(" ")[0]==="Mystara"?"Policy C":R==="Average"?"all policies":"Policy B",A=w.useMemo(()=>{let F=null;switch(o){case"super_data":F=i==null?void 0:i.concat(S==null?void 0:S.map(B=>B.country));break;case"super_summ":F=i==null?void 0:i.concat([E]);break;default:F=i;break}const L=F==null?void 0:F.map(B=>({country:B,country_policy:n==="clean_data"?`${B} (${I(B)})`:B,label_pos:B===E?T==null?void 0:T.data.slice(-1).map(J=>g(J.mean))[0]:t.filter(J=>J[e.cat_var]===B).slice(-1).map(J=>g(J[e.y_var]))[0]})).sort((B,J)=>B.label_pos=10||(L[B].label_pos=L[B].label_pos-10+J)}return L},[t,i,g,o,E,e,S,T,n]);return(i==null?void 0:i.length)===0?C.jsx(ua,{style:{width:"800px",height:"400px"},children:C.jsx(rt,{fs:"italic",c:"dimmed",children:"Select an item to view the chart."})}):C.jsxs("svg",{id:"baseLineChart",style:{height:"400px",width:"800px",fontFamily:'"Helvetica Neue", "Helvetica", "Arial", sans-serif'},children:[C.jsxs("g",{id:"axes",children:[C.jsx(ase,{isDate:!0,xScale:y,yRange:g.range(),vertPosition:h+Yi.top,showLines:!1,ticks:y.ticks(6).map(R=>({value:R.toString(),offset:y(R)}))}),C.jsx(use,{dataset:n,yScale:g,horizontalPosition:Yi.left,xRange:y.range()})]}),C.jsx("svg",{style:{width:`${d}`},children:S==null?void 0:S.map(R=>C.jsx("g",{children:C.jsx("path",{id:`${R.country}`,fill:"none",stroke:l(R.country)?v(R.country):"gray",strokeDasharray:"4,1",strokeWidth:.5,d:R.path},`${R.country}_key`)},`${R.country}_g`))},"control_lines"),C.jsx("svg",{style:{width:`${d}`},children:T?C.jsxs("g",{children:[C.jsx("path",{id:"confidenceBands",fill:"lightgray",opacity:.25,stroke:"none",d:T.confidenceBands},"confidenceBands_key"),C.jsx("path",{id:"meanLine",fill:"none",stroke:"gray",strokeDasharray:"4,1",strokeWidth:.5,d:T.meanLine},"meanLine_key")]},"summary_g"):null},"control_bands"),C.jsxs("svg",{style:{width:`${d}`},children:[b==null?void 0:b.map(R=>C.jsx("g",{children:C.jsx("path",{id:`${R.country}`,fill:"none",stroke:l(R.country)?v(R.country):"gainsboro",strokeWidth:a!=null&&a.includes(R.country)?2:1.5,d:R.path},`${R.country}_key`)},`${R.country}_g`)),A==null?void 0:A.map(R=>C.jsx("foreignObject",{x:d+Yi.left+5,y:R.label_pos-7,width:Yi.right+60,height:20,children:C.jsx(rt,{px:2,size:10,color:l(R.country)?v(R.country):"silver",onMouseOver:F=>{const L=F.target;i!=null&&i.includes(L.innerText)&&u([L.innerText])},onMouseOut:()=>u([]),children:R.country_policy})},`${R.country}_label`))]},"lines")]})}const ZHe=Object.freeze(Object.defineProperty({__proto__:null,LineChart:ek,default:ek},Symbol.toStringTag,{value:"Module"})),sp={top:0,left:0,right:0,bottom:0},vz=20,HO=60;function tk({parameters:e,data:t,dataname:n,items:r,selection:i,setSelection:s,trackSelection:o,range:a,guardrail:u}){const l=w.useMemo(()=>a?kv([sp.left,HO+sp.left]).domain(a):kv([sp.left,HO+sp.left]).domain([new Date(e.start_date),new Date(e.end_date)]),[e,a]),c=w.useMemo(()=>{const p=t.filter(g=>r==null?void 0:r.map(v=>v.name).includes(g[e.cat_var])).map(g=>+g[e.y_var]).filter(g=>g!==null),[m,y]=Pf(p);return mh([vz+sp.top,sp.top]).domain([m,y]).nice()},[e,t,r]),f=w.useMemo(()=>{const p=Array.from(new Set(t.map(m=>m[e.cat_var])));return P6(E6).domain(p)},[e,t]),d=w.useMemo(()=>{if(u!=="juxt_data")return null;const p=Xie();p.x(g=>l(Ld("%Y-%m-%d")(g[e.x_var]))),p.y0(()=>c(0)),p.y1(g=>c(g[e.y_var])),p.curve(Mp);const m=$y();return m.x(g=>l(Ld("%Y-%m-%d")(g[e.x_var]))),m.y(g=>c(g[e.y_var])),m.curve(Mp),r==null?void 0:r.map(g=>({country:g.name,path:m(t.filter(v=>v[e.cat_var]===g.name)),area:p(t.filter(v=>v[e.cat_var]===g.name))}))},[e,u,t,r,l,c]),h=w.useMemo(()=>e.allow_selection===!1?"none":"block",[e]);return C.jsx(Mm.Group,{defaultValue:i,orientation:"vertical",onChange:p=>{s(p),o(p)},spacing:0,offset:"sm",styles:e.allow_selection===!1?{root:{pointerEvents:"none"}}:{root:{pointerEvents:"auto"}},children:r==null?void 0:r.map(p=>C.jsxs(C.Fragment,{children:[p.name==="Eldoril North"?C.jsx(df,{size:"xs",label:"Policy A",labelPosition:"left",color:"black"}):null,p.name==="Eldoril West"?C.jsx(df,{size:"xs",label:"Policy B",labelPosition:"left",color:"black"}):null,p.name==="Silvoria North"?C.jsx(df,{size:"xs",label:"Policy C",labelPosition:"left",color:"black"}):null,C.jsxs(Rl,{grow:!0,gutter:8,columns:2,children:[C.jsx(Rl.Col,{span:1,children:C.jsx(Mm,{value:p.name,label:p.name,color:e.allow_selection?"blue":"gray",styles:{root:{display:"flex",alignItems:"flex-end",padding:"2px 0"},inner:{display:h}},children:p.name},`${p.name}_checkbox`)},`${p.name}_grid1`),C.jsx(Rl.Col,{span:u==="juxt_data"?"auto":3,children:C.jsxs("svg",{style:{width:`${HO}`,height:`${vz}`},children:[C.jsx("path",{id:`${p.name}_sparkarea`,fill:i!=null&&i.includes(p.name)?f(p.name):"gray",stroke:"none",opacity:.25,d:d==null?void 0:d.filter(m=>m.country===p.name)[0].area},`${p.name}_sparkarea`),C.jsx("path",{id:`${p.name}_spark`,fill:"none",stroke:i!=null&&i.includes(p.name)?f(p.name):"gray",strokeWidth:.75,d:d==null?void 0:d.filter(m=>m.country===p.name)[0].path},`${p.name}_spark`)]},`${p.name}_sparksvg`)},`${p.name}_grid2`)]},`${p.name}_grid`)]}))},`${n}_checkboxgroup`)}const eWe=Object.freeze(Object.defineProperty({__proto__:null,Sidebar:tk,default:tk},Symbol.toStringTag,{value:"Module"}));function nk({parameters:e,setRange:t,trackRange:n}){function r(s){return kv([0,100]).domain([new Date(e.start_date),new Date(e.end_date)]).invert(s)}function i(s){const o=r(s);return $6("%b %e, %Y")(o)}return C.jsx(pte,{defaultValue:[0,100],label:s=>i(s),labelAlwaysOn:!0,disabled:!e.allow_time_slider,onChange:([s,o])=>{t([r(s),r(o)]),n([r(s),r(o)])}})}const tWe=Object.freeze(Object.defineProperty({__proto__:null,RangeSelector:nk,default:nk},Symbol.toStringTag,{value:"Module"}));function rk({guardrail:e,setGuardrail:t,dataname:n,setDataname:r,setSelection:i}){return C.jsxs(C.Fragment,{children:[C.jsx(rt,{children:"Data:"}),C.jsx(JR,{value:n,onChange:s=>{r(s),i([])},data:[{value:"clean_data",label:"Viral"},{value:"clean_stocks",label:"Stock"}]}),C.jsx(rt,{children:"Guardrail:"}),C.jsx(JR,{value:e,onChange:s=>{t(s)},data:[{value:"none",label:"None"},{value:"super_data",label:"Sup. Data"},{value:"super_summ",label:"Sup. Summ."},{value:"juxt_data",label:"Juxt. Data"},{value:"juxt_summ",label:"Juxt. Summ."}]})]})}const nWe=Object.freeze(Object.defineProperty({__proto__:null,Selector:rk,default:rk},Symbol.toStringTag,{value:"Module"})),En=Array.isArray;function io(e){return e!=null?En(e)?e:[e]:[]}function rWe(e=0,t=1/0){return`${_z(e)} < row_number() && row_number() <= ${_z(t)}`}function _z(e){return e<0?`count() + ${e}`:e}class lse{constructor(t){t&&(this._params=t)}params(t){return arguments.length?(t&&(this._params={...this._params,...t}),this):this._params}reify(t){return this.__reify(this,t)}count(t){return this.__count(this,t)}derive(t,n){return this.__derive(this,t,n)}filter(t){return this.__filter(this,t)}slice(t,n){return this.filter(rWe(t,n)).reify()}groupby(...t){return this.__groupby(this,t.flat())}orderby(...t){return this.__orderby(this,t.flat())}relocate(t,n){return this.__relocate(this,io(t),n)}rename(...t){return this.__rename(this,t.flat())}rollup(t){return this.__rollup(this,t)}sample(t,n){return this.__sample(this,t,n)}select(...t){return this.__select(this,t.flat())}ungroup(){return this.__ungroup(this)}unorder(){return this.__unorder(this)}dedupe(...t){return this.__dedupe(this,t.flat())}impute(t,n){return this.__impute(this,t,n)}fold(t,n){return this.__fold(this,t,n)}pivot(t,n,r){return this.__pivot(this,t,n,r)}spread(t,n){return this.__spread(this,t,n)}unroll(t,n){return this.__unroll(this,t,n)}lookup(t,n,...r){return this.__lookup(this,t,n,r.flat())}join(t,n,r,i){return this.__join(this,t,n,r,i)}join_left(t,n,r,i){const s={...i,left:!0,right:!1};return this.__join(this,t,n,r,s)}join_right(t,n,r,i){const s={...i,left:!1,right:!0};return this.__join(this,t,n,r,s)}join_full(t,n,r,i){const s={...i,left:!0,right:!0};return this.__join(this,t,n,r,s)}cross(t,n,r){return this.__cross(this,t,n,r)}semijoin(t,n){return this.__semijoin(this,t,n)}antijoin(t,n){return this.__antijoin(this,t,n)}concat(...t){return this.__concat(this,t.flat())}union(...t){return this.__union(this,t.flat())}intersect(...t){return this.__intersect(this,t.flat())}except(...t){return this.__except(this,t.flat())}}function Wt(e){throw Error(e)}function bs(e){return typeof e=="number"}function sr(e){return typeof e=="function"}function $C(e,t){const n=Array(e);if(sr(t))for(let r=0;r=0;a=s.next(a+1))r[++o]=a;else for(let a=0;aa(l,c,u))}return(t||!i)&&(this._index=r),r}partitions(t=!0){if(this._partitions)return this._partitions;if(!this.isGrouped())return[this.indices(t)];const{keys:n,size:r}=this._group,i=$C(r,()=>[]),s=this._index,o=this.mask(),a=this.numRows();if(s&&this.isOrdered())for(let u=0,l;u=0;u=o.next(u+1))i[n[u]].push(u);else for(let u=0;uu(f,d,l))}return(t||!this.isOrdered())&&(this._partitions=i),i}scan(t,n,r=1/0,i=0){const s=this._mask,o=this._nrows,a=this._data;let u=i||0;if(u>o)return;const l=Math.min(o,u+r),c=()=>u=this._total;if(n&&this.isOrdered()||s&&this._index){const f=this.indices(),d=this._data;for(;u-1;u=s.next(u+1))t(u,a,c)}else for(;ur.push(s),!0,n-t,t),this.reify(r)}reduce(t){return this.__reduce(this,t)}},sWe=class{constructor(t){this.data=t}get length(){return this.data.length}get(t){return this.data[t]}[Symbol.iterator](){return this.data[Symbol.iterator]()}},oWe=function(e){return e&&sr(e.get)?e:new sWe(e)};function Xl(e){return e instanceof Date}function as(e){return e===Object(e)}function rI(e){return e instanceof RegExp}function Ui(e){return typeof e=="string"}function aWe(e,t){const n=r=>Wt(`Illegal argument type: ${r||typeof e}`);return e instanceof Map?bz(e.entries(),t):Xl(e)?n("Date"):rI(e)?n("RegExp"):Ui(e)?n():En(e)?uWe(e,t):sr(e[Symbol.iterator])?lWe(e,t):as(e)?bz(Object.entries(e),t):n()}function bz(e,t=["key","value"]){const n=[],r=[];for(const[s,o]of e)n.push(s),r.push(o);const i={};return t[0]&&(i[t[0]]=n),t[1]&&(i[t[1]]=r),i}function uWe(e,t){const n=e.length,r={},i=s=>r[s]=Array(n);if(n){t=t||Object.keys(e[0]);const s=t.map(i),o=s.length;for(let a=0;an[o]=[];let i,s;for(const o of e){i||(t=t||Object.keys(o),i=t.map(r),s=i.length);for(let a=0;aMd(e)||Ui(e),dWe={compact:e=>Md(e)?e.filter(t=>Ma(t)):e,concat:(...e)=>[].concat(...e),includes:(e,t,n)=>R0(e)?e.includes(t,n):!1,indexof:(e,t)=>R0(e)?e.indexOf(t):-1,join:(e,t)=>Md(e)?e.join(t):yn,lastindexof:(e,t)=>R0(e)?e.lastIndexOf(t):-1,length:e=>R0(e)?e.length:0,pluck:(e,t)=>Md(e)?e.map(n=>Ma(n)?n[t]:yn):yn,reverse:e=>Md(e)?e.slice().reverse():Ui(e)?e.split("").reverse().join(""):yn,slice:(e,t,n)=>R0(e)?e.slice(t,n):yn};function hWe(e,t,n,r,i){return e==null?null:en?1/0:(e=Math.max(t,Math.min(e,n)),t+r*Math.floor(1e-14+(e-t)/r+(i||0)))}function Uw(e,t,n="0"){const r=e+"",i=r.length;return i(e<10?"0":"")+e,pWe=e=>e<0?"-"+Uw(-e,6):e>9999?"+"+Uw(e,6):Uw(e,4);function cse(e,t,n,r,i,s,o,a,u){const l=a?"Z":"";return pWe(e)+"-"+su(t+1)+"-"+su(n)+(!u||o?"T"+su(r)+":"+su(i)+":"+su(s)+"."+Uw(o,3)+l:s?"T"+su(r)+":"+su(i)+":"+su(s)+l:i||r||!a?"T"+su(r)+":"+su(i)+l:"")}function fse(e,t){return isNaN(e)?"Invalid Date":cse(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds(),!1,t)}function LC(e,t){return isNaN(e)?"Invalid Date":cse(e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate(),e.getUTCHours(),e.getUTCMinutes(),e.getUTCSeconds(),e.getUTCMilliseconds(),!0,t)}const mWe=/^([-+]\d{2})?\d{4}(-\d{2}(-\d{2})?)?(T\d{2}:\d{2}(:\d{2}(\.\d{3})?)?(Z|[-+]\d{2}:\d{2})?)?$/;function gWe(e){return e.match(mWe)&&!isNaN(Date.parse(e))}function yWe(e,t=Date.parse){return gWe(e)?t(e):e}const dse=6e4,hse=864e5,pse=6048e5,xr=new Date,Ar=new Date,Dr=e=>(xr.setTime(typeof e=="string"?yWe(e):e),xr);function vWe(e,t,n,r,i,s,o){return arguments.length?new Date(e,t||0,n??1,r||0,i||0,s||0,o||0):new Date(Date.now())}function _We(e,t,n,r,i,s,o){return arguments.length?new Date(Date.UTC(e,t||0,n??1,r||0,i||0,s||0,o||0)):new Date(Date.now())}function bWe(e){Ar.setTime(+e),Ar.setHours(0,0,0,0),xr.setTime(+Ar),xr.setMonth(0),xr.setDate(1);const t=(Ar.getTimezoneOffset()-xr.getTimezoneOffset())*dse;return Math.floor(1+(Ar-xr-t)/hse)}function wWe(e){Ar.setTime(+e),Ar.setUTCHours(0,0,0,0);const t=Date.UTC(Ar.getUTCFullYear(),0,1);return Math.floor(1+(Ar-t)/hse)}function EWe(e,t){const n=t||0;Ar.setTime(+e),Ar.setDate(Ar.getDate()-(Ar.getDay()+7-n)%7),Ar.setHours(0,0,0,0),xr.setTime(+e),xr.setMonth(0),xr.setDate(1),xr.setDate(1-(xr.getDay()+7-n)%7),xr.setHours(0,0,0,0);const r=(Ar.getTimezoneOffset()-xr.getTimezoneOffset())*dse;return Math.floor((1+(Ar-xr)-r)/pse)}function SWe(e,t){const n=t||0;return Ar.setTime(+e),Ar.setUTCDate(Ar.getUTCDate()-(Ar.getUTCDay()+7-n)%7),Ar.setUTCHours(0,0,0,0),xr.setTime(+e),xr.setUTCMonth(0),xr.setUTCDate(1),xr.setUTCDate(1-(xr.getUTCDay()+7-n)%7),xr.setUTCHours(0,0,0,0),Math.floor((1+(Ar-xr))/pse)}const TWe={format_date:(e,t)=>fse(Dr(e),!t),format_utcdate:(e,t)=>LC(Dr(e),!t),timestamp:e=>+Dr(e),year:e=>Dr(e).getFullYear(),quarter:e=>Math.floor(Dr(e).getMonth()/3),month:e=>Dr(e).getMonth(),date:e=>Dr(e).getDate(),dayofweek:e=>Dr(e).getDay(),hours:e=>Dr(e).getHours(),minutes:e=>Dr(e).getMinutes(),seconds:e=>Dr(e).getSeconds(),milliseconds:e=>Dr(e).getMilliseconds(),utcyear:e=>Dr(e).getUTCFullYear(),utcquarter:e=>Math.floor(Dr(e).getUTCMonth()/3),utcmonth:e=>Dr(e).getUTCMonth(),utcdate:e=>Dr(e).getUTCDate(),utcdayofweek:e=>Dr(e).getUTCDay(),utchours:e=>Dr(e).getUTCHours(),utcminutes:e=>Dr(e).getUTCMinutes(),utcseconds:e=>Dr(e).getUTCSeconds(),utcmilliseconds:e=>Dr(e).getUTCMilliseconds(),datetime:vWe,dayofyear:bWe,week:EWe,utcdatetime:_We,utcdayofyear:wWe,utcweek:SWe,now:Date.now};function H6(e,t){return e==null||t==null||e!==e||t!==t?!1:e===t?!0:Xl(e)||Xl(t)?+e==+t:rI(e)&&rI(t)?e+""==t+"":as(e)&&as(t)?IWe(e,t):!1}function IWe(e,t){if(Object.getPrototypeOf(e)!==Object.getPrototypeOf(t))return!1;if(e.length||t.length)return Ez(e,t);const n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length||(n.sort(),r.sort(),!Ez(n,r,(s,o)=>s===o)))return!1;const i=n.length;for(let s=0;sJSON.parse(e),to_json:e=>JSON.stringify(e)};let CWe=Math.random;function Ng(){return CWe()}const AWe={random:Ng,is_nan:Number.isNaN,is_finite:Number.isFinite,abs:Math.abs,cbrt:Math.cbrt,ceil:Math.ceil,clz32:Math.clz32,exp:Math.exp,expm1:Math.expm1,floor:Math.floor,fround:Math.fround,greatest:Math.max,least:Math.min,log:Math.log,log10:Math.log10,log1p:Math.log1p,log2:Math.log2,pow:Math.pow,round:Math.round,sign:Math.sign,sqrt:Math.sqrt,trunc:Math.trunc,degrees:e=>180*e/Math.PI,radians:e=>Math.PI*e/180,acos:Math.acos,acosh:Math.acosh,asin:Math.asin,asinh:Math.asinh,atan:Math.atan,atan2:Math.atan2,atanh:Math.atanh,cos:Math.cos,cosh:Math.cosh,sin:Math.sin,sinh:Math.sinh,tan:Math.tan,tanh:Math.tanh};function W6(e){return e instanceof Map}function PWe(e){return e instanceof Set}function Vw(e){return W6(e)||PWe(e)}function WO(e){return Array.from(e)}const OWe={has:(e,t)=>Vw(e)?e.has(t):e!=null?Ya(e,t):!1,keys:e=>W6(e)?WO(e.keys()):e!=null?Object.keys(e):[],values:e=>Vw(e)?WO(e.values()):e!=null?Object.values(e):[],entries:e=>Vw(e)?WO(e.entries()):e!=null?Object.entries(e):[],object:e=>e?Object.fromEntries(e):yn};function RWe(e,t,n){if(t instanceof Map){if(t.has(e))return t.get(e)}else if(Ya(t,e))return t[e];return n!==void 0?n:e}function NWe(e,t,n){let r=arguments.length;e=+e,t=+t,n=r<2?(t=e,e=0,1):r<3?1:+n,r=Math.max(0,Math.ceil((t-e)/n))|0;const i=new Array(r);for(let s=0;se==null?e:new Date(e),parse_float:e=>e==null?e:Number.parseFloat(e),parse_int:(e,t)=>e==null?e:Number.parseInt(e,t),endswith:(e,t,n)=>e==null?!1:String(e).endsWith(t,n),match:(e,t,n)=>{const r=e==null?e:String(e).match(t);return n==null||r==null?r:typeof n=="number"?r[n]:r.groups?r.groups[n]:null},normalize:(e,t)=>e==null?e:String(e).normalize(t),padend:(e,t,n)=>e==null?e:String(e).padEnd(t,n),padstart:(e,t,n)=>e==null?e:String(e).padStart(t,n),upper:e=>e==null?e:String(e).toUpperCase(),lower:e=>e==null?e:String(e).toLowerCase(),repeat:(e,t)=>e==null?e:String(e).repeat(t),replace:(e,t,n)=>e==null?e:String(e).replace(t,String(n)),substring:(e,t,n)=>e==null?e:String(e).substring(t,n),split:(e,t,n)=>e==null?[]:String(e).split(t,n),startswith:(e,t,n)=>e==null?!1:String(e).startsWith(t,n),trim:e=>e==null?e:String(e).trim()},Bp={bin:hWe,equal:H6,recode:RWe,sequence:NWe,...dWe,...TWe,...xWe,...AWe,...OWe,...kWe};function Lv(e){return typeof e=="bigint"}function el(e){return e===void 0?e+"":Lv(e)?e+"n":JSON.stringify(e)}function Vt(e,t=[],n=[]){return new DWe(e,io(t),io(n))}let DWe=class{constructor(t,n,r){this.name=t,this.fields=n,this.params=r}toString(){const t=[...this.fields.map(n=>`d[${el(n)}]`),...this.params.map(el)];return`d => op.${this.name}(${t})`}toObject(){return{expr:this.toString(),func:!0}}};const mse=e=>Vt("any",e),gse=()=>Vt("count"),yse=e=>Vt("array_agg",e),vse=e=>Vt("array_agg_distinct",e),_se=(e,t)=>Vt("map_agg",[e,t]),bse=(e,t)=>Vt("object_agg",[e,t]),wse=(e,t)=>Vt("entries_agg",[e,t]);({...Bp});function $We(e,t){e=Vw(e)?e:new Set(e);let n=t,r=0;for(;e.has(n);)n=t+ ++r;return n}function LWe(e,t){if(!e||!t)return e;const{keys:n,rows:r,size:i}=e,s=new Int32Array(i);t.scan(c=>s[n[c]]=1);const o=s.reduce((c,f)=>c+f,0);if(o===i)return e;const a=Array(o);let u=0;for(let c=0;cl[c]=s[n[c]]),{...e,keys:l,rows:a,size:u}}function MWe(e,t,n,r){const{keys:i,rows:s,size:o}=e;let a=s,u=o,l=null;if(n){l=new Int32Array(o),t(p=>l[i[p]]=1);const h=l.reduce((p,m)=>p+m,0);if(h!==o){a=Array(h),u=0;for(let p=0;pf[++c]=l[i[h]]:h=>f[++c]=i[h]),{...e,keys:f,rows:a,size:u}}function FWe(e,t,n,r){const i=r==="map"||r===!0?_se:r==="entries"?wse:r==="object"?bse:Wt('groups option must be "map", "entries", or "object".'),{names:s}=e.groups(),o=$We(e.columnNames(),"_");let a=e.select().reify(t).create({data:{[o]:n}}).rollup({[o]:yse(o)});for(let u=s.length;--u>=0;)a=a.groupby(s.slice(0,u)).rollup({[o]:i(s[u],o)});return a.get(o)}const BWe="ArrayPattern",jWe="ArrowFunctionExpression",UWe="FunctionExpression",vf="Identifier",kg="Literal",Ese="MemberExpression",VWe="ObjectExpression",Sse="ObjectPattern",Tse="Property",i1="Column",zWe="Constant",HWe="Dictionary",WWe="Function",qWe="Parameter",Ise="Op",Kn=(e,t)=>{const n=GWe[e.type];return n?n(e,t):Wt(`Unsupported expression construct: ${e.type}`)},qO=(e,t)=>"("+Kn(e.left,t)+" "+e.operator+" "+Kn(e.right,t)+")",GO=(e,t)=>"("+fu(e.params,t)+")=>"+Kn(e.body,t),Sz=(e,t)=>Kn(e.callee,t)+"("+fu(e.arguments,t)+")",fu=(e,t,n=",")=>e.map(r=>Kn(r,t)).join(n),xse=e=>e.computed?`[${el(e.name)}]`:`.${e.name}`,Tz=(e,t,n)=>{const r=e.table||"";return`data${r}${xse(e)}.${n}(${t.index}${r})`},GWe={Constant:e=>e.raw,Column:(e,t)=>Tz(e,t,"get"),Dictionary:(e,t)=>Tz(e,t,"key"),Function:e=>`fn.${e.name}`,Parameter:e=>`$${xse(e)}`,Op:(e,t)=>`op(${el(e.name)},${t.op||t.index})`,Literal:e=>e.raw,Identifier:e=>e.name,TemplateLiteral:(e,t)=>{const{quasis:n,expressions:r}=e,i=r.length;let s=n[0].value.raw;for(let o=0;o{const n=!e.computed,r=Kn(e.object,t),i=Kn(e.property,t);return r+(n?"."+i:"["+i+"]")},CallExpression:Sz,NewExpression:(e,t)=>"new "+Sz(e,t),ArrayExpression:(e,t)=>"["+fu(e.elements,t)+"]",AssignmentExpression:qO,BinaryExpression:qO,LogicalExpression:qO,UnaryExpression:(e,t)=>"("+e.operator+Kn(e.argument,t)+")",ConditionalExpression:(e,t)=>"("+Kn(e.test,t)+"?"+Kn(e.consequent,t)+":"+Kn(e.alternate,t)+")",ObjectExpression:(e,t)=>"({"+fu(e.properties,t)+"})",Property:(e,t)=>{const n=Kn(e.key,t);return(e.computed?`[${n}]`:n)+":"+Kn(e.value,t)},ArrowFunctionExpression:GO,FunctionExpression:GO,FunctionDeclaration:GO,ArrayPattern:(e,t)=>"["+fu(e.elements,t)+"]",ObjectPattern:(e,t)=>"{"+fu(e.properties,t)+"}",VariableDeclaration:(e,t)=>e.kind+" "+fu(e.declarations,t,","),VariableDeclarator:(e,t)=>Kn(e.id,t)+"="+Kn(e.init,t),SpreadElement:(e,t)=>"..."+Kn(e.argument,t),BlockStatement:(e,t)=>"{"+fu(e.body,t,";")+";}",BreakStatement:()=>"break",ExpressionStatement:(e,t)=>Kn(e.expression,t),IfStatement:(e,t)=>"if ("+Kn(e.test,t)+")"+Kn(e.consequent,t)+(e.alternate?" else "+Kn(e.alternate,t):""),SwitchStatement:(e,t)=>"switch ("+Kn(e.discriminant,t)+") {"+fu(e.cases,t,"")+"}",SwitchCase:(e,t)=>(e.test?"case "+Kn(e.test,t):"default")+": "+fu(e.consequent,t,";")+";",ReturnStatement:(e,t)=>"return "+Kn(e.argument,t),Program:(e,t)=>Kn(e.body[0],t)};function iI(e,t={index:"row"}){return Kn(e,t)}function YWe(e,t,n=15,r=!0,i=0,s){const a=Math.LN10;if(s==null){const u=Math.ceil(Math.log(n)/a),l=t-e||Math.abs(e)||1,c=[5,2];for(s=Math.max(i,Math.pow(10,Math.round(Math.log(l)/a)-u));Math.ceil(l/s)>n;)s*=10;const f=c.length;for(let d=0;d=i&&l/h<=n&&(s=h)}}if(r){let u=Math.log(s);const l=u>=0?0:~~(-u/a)+1,c=Math.pow(10,-l-1);u=Math.floor(e/s+c)*s,e=e0&&(t+=","),t+=`"${r}":${Km(e[r])}`;return t+="}",t}function sI(e,t){const n=e.length;return n===1?(r,i)=>Km(e[0](r,i)):(r,i)=>{let s="";for(let o=0;o0&&(s+="|");const a=e[o](r,i);if(t&&(a==null||a!==a))return null;s+=Km(a)}return s}}function QWe(){const e=new Map;return{count(){return e.size},values(){return Array.from(e.values(),t=>t.v)},increment(t){const n=Km(t),r=e.get(n);r?++r.n:e.set(n,{v:t,n:1})},decrement(t){const n=Km(t),r=e.get(n);r.n===1?e.delete(n):--r.n},forEach(t){e.forEach(({v:n,n:r})=>t(n,r))}}}function Sl(){}function XWe(e,t=0,n=e.length){let r=e[t++];for(let i=t;iXr({value:e=>e.count}),param:[]},array_agg:{create:()=>Xr({init:e=>e.values=!0,value:e=>e.list.values(e.stream)}),param:[1]},object_agg:{create:()=>Xr({init:e=>e.values=!0,value:e=>Object.fromEntries(e.list.values())}),param:[2]},map_agg:{create:()=>Xr({init:e=>e.values=!0,value:e=>new Map(e.list.values())}),param:[2]},entries_agg:{create:()=>Xr({init:e=>e.values=!0,value:e=>e.list.values(e.stream)}),param:[2]},any:{create:()=>Xr({add:(e,t)=>{e.any==null&&(e.any=t)},value:e=>e.valid?e.any:yn}),param:[1]},valid:{create:()=>Xr({value:e=>e.valid}),param:[1]},invalid:{create:()=>Xr({value:e=>e.count-e.valid}),param:[1]},distinct:{create:()=>({init:e=>e.distinct=QWe(),value:e=>e.distinct.count()+(e.valid===e.count?0:1),add:(e,t)=>e.distinct.increment(t),rem:(e,t)=>e.distinct.decrement(t)}),param:[1]},array_agg_distinct:{create:()=>Xr({value:e=>e.distinct.values()}),param:[1],req:["distinct"]},mode:{create:()=>Xr({value:e=>{let t=yn,n=0;return e.distinct.forEach((r,i)=>{i>n&&(n=i,t=r)}),t}}),param:[1],req:["distinct"]},sum:{create:()=>({init:e=>e.sum=0,value:e=>e.valid?e.sum:yn,add:(e,t)=>Lv(t)?e.sum===0?e.sum=t:e.sum+=t:e.sum+=+t,rem:(e,t)=>e.sum-=t}),param:[1]},product:{create:()=>({init:e=>Iz(e,1),value:e=>e.valid?e.product_v?Iz(e,XWe(e.list.values())):e.product:void 0,add:(e,t)=>Lv(t)&&e.product===1?e.product=t:e.product*=t,rem:(e,t)=>t==0||t===1/0||t===-1/0?e.product_v=!0:e.product/=t}),param:[1],stream:["array_agg"]},mean:{create:()=>({init:e=>e.mean=0,value:e=>e.valid?e.mean:yn,add:(e,t)=>{e.mean_d=t-e.mean,e.mean+=e.mean_d/e.valid},rem:(e,t)=>{e.mean_d=t-e.mean,e.mean-=e.valid?e.mean_d/e.valid:e.mean}}),param:[1]},average:{create:()=>Xr({value:e=>e.valid?e.mean:yn}),param:[1],req:["mean"]},variance:{create:()=>({init:e=>e.dev=0,value:e=>e.valid>1?e.dev/(e.valid-1):yn,add:(e,t)=>e.dev+=e.mean_d*(t-e.mean),rem:(e,t)=>e.dev-=e.mean_d*(t-e.mean)}),param:[1],req:["mean"]},variancep:{create:()=>Xr({value:e=>e.valid>1?e.dev/e.valid:yn}),param:[1],req:["variance"]},stdev:{create:()=>Xr({value:e=>e.valid>1?Math.sqrt(e.dev/(e.valid-1)):yn}),param:[1],req:["variance"]},stdevp:{create:()=>Xr({value:e=>e.valid>1?Math.sqrt(e.dev/e.valid):yn}),param:[1],req:["variance"]},min:{create:()=>({init:e=>e.min=yn,value:e=>e.min=Number.isNaN(e.min)?e.list.min():e.min,add:(e,t)=>{(t{t<=e.min&&(e.min=NaN)}}),param:[1],stream:["array_agg"]},max:{create:()=>({init:e=>e.max=yn,value:e=>e.max=Number.isNaN(e.max)?e.list.max():e.max,add:(e,t)=>{(t>e.max||e.max===yn)&&(e.max=t)},rem:(e,t)=>{t>=e.max&&(e.max=NaN)}}),param:[1],stream:["array_agg"]},quantile:{create:e=>Xr({value:t=>t.list.quantile(e)}),param:[1,1],req:["array_agg"]},median:{create:()=>Xr({value:e=>e.list.quantile(.5)}),param:[1],req:["array_agg"]},covariance:{create:()=>({init:e=>{e.cov=e.mean_x=e.mean_y=e.dev_x=e.dev_y=0},value:e=>e.valid>1?e.cov/(e.valid-1):yn,add:(e,t,n)=>{const r=t-e.mean_x,i=n-e.mean_y;e.mean_x+=r/e.valid,e.mean_y+=i/e.valid;const s=n-e.mean_y;e.dev_x+=r*(t-e.mean_x),e.dev_y+=i*s,e.cov+=r*s},rem:(e,t,n)=>{const r=t-e.mean_x,i=n-e.mean_y;e.mean_x-=e.valid?r/e.valid:e.mean_x,e.mean_y-=e.valid?i/e.valid:e.mean_y;const s=n-e.mean_y;e.dev_x-=r*(t-e.mean_x),e.dev_y-=i*s,e.cov-=r*s}}),param:[2]},covariancep:{create:()=>Xr({value:e=>e.valid>1?e.cov/e.valid:yn}),param:[2],req:["covariance"]},corr:{create:()=>Xr({value:e=>e.valid>1?e.cov/(Math.sqrt(e.dev_x)*Math.sqrt(e.dev_y)):yn}),param:[2],req:["covariance"]},bins:{create:(e,t,n,r)=>Xr({value:i=>YWe(i.min,i.max,e,t,n,r)}),param:[1,4],req:["min","max"]}},xz={create(){let e;return{init:()=>e=1,value:t=>{const n=t.index;return n&&!t.peer(n)?e=n+1:e}}},param:[]},Cz={create(){let e;return{init:()=>e=0,value:t=>{const{index:n,peer:r,size:i}=t;let s=n;if(ee.index+1}},param:[]},rank:xz,avg_rank:{create(){let e,t;return{init:()=>(e=-1,t=1),value:n=>{const r=n.index;if(r>=e){for(t=e=r+1;n.peer(e);t+=++e);t/=e-r}return t}}},param:[]},dense_rank:{create(){let e;return{init:()=>e=1,value:t=>{const n=t.index;return n&&!t.peer(n)?++e:e}}},param:[]},percent_rank:{create(){const{init:e,value:t}=xz.create();return{init:e,value:n=>(t(n)-1)/(n.size-1)}},param:[]},cume_dist:Cz,ntile:{create(e){e=+e,e>0||Wt("ntile num must be greater than zero.");const{init:t,value:n}=Cz.create();return{init:t,value:r=>Math.ceil(e*n(r))}},param:[0,1]},lag:{create(e,t=yn){return e=+e||1,{init:Sl,value:(n,r)=>{const i=n.index-e;return i>=0?n.value(i,r):t}}},param:[1,2]},lead:{create(e,t=yn){return e=+e||1,{init:Sl,value:(n,r)=>{const i=n.index+e;return ie.value(e.i0,t)}},param:[1]},last_value:{create(){return{init:Sl,value:(e,t)=>e.value(e.i1-1,t)}},param:[1]},nth_value:{create(e){return e=+e,e>0||Wt("nth_value nth must be greater than zero."),{init:Sl,value:(t,n)=>{const r=t.i0+(e-1);return rt=e,value:(n,r)=>{const i=n.value(n.index,r);return Ma(i)?t=i:t}}},param:[1,1]},fill_up:{create(e=yn){let t,n;return{init:()=>(t=e,n=-1),value:(r,i)=>r.index<=n?t:(n=JWe(r,i,r.index))>=0?t=r.value(n,i):(n=r.size,t=e)}},param:[1,1]}};function JWe(e,t,n){for(const r=e.size;nN0(e,t,n),expr:(e,t)=>N0(`(row,data,op)=>${e}`,Bp,t),expr2:(e,t)=>N0(`(row0,data0,row,data)=>${e}`,Bp,t),join:(e,t)=>N0(`(row1,data1,row2,data2)=>${e}`,Bp,t),param:(e,t)=>N0(e,Bp,t)},ZWe={"==":1,"!=":1,"===":1,"!==":1};function Nse(e,t,n=0,r,i){if(e.type=i1,e.name=t,e.table=n,i&&r&&sr(r.keyFor)){const s=ZWe[i.operator]?i.left===e?i.right:i.left:i.callee&&i.callee.name==="equal"?i.arguments[i.arguments[0]===e?1:0]:null;s&&s.type===kg&&eqe(i,e,s,r.keyFor(s.value))}return e}function eqe(e,t,n,r){return r<0?(e.type=kg,e.value=!1,e.raw="false"):(t.type=HWe,n.value=r,n.raw=r+""),!0}function MC(e){return En(e)?e:W6(e)?e.entries():e?Object.entries(e):[]}const kse="row_object";function Dse(e,t){e.type=VWe;const n=e.properties=[];for(const r of MC(t)){const[i,s]=En(r)?r:[r,r];n.push({type:Tse,key:{type:kg,raw:el(s)},value:Nse({computed:!0},i)})}return e}function $se(e){return iI(Dse({},e))}function Lse(e){return Y6.expr($se(e))}function K6(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,r=Object.getOwnPropertySymbols(e);i=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function un(e){return this instanceof un?(this.v=e,this):new un(e)}function Fd(e,t,n){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var r=n.apply(e,t||[]),i,s=[];return i={},o("next"),o("throw"),o("return"),i[Symbol.asyncIterator]=function(){return this},i;function o(d){r[d]&&(i[d]=function(h){return new Promise(function(p,m){s.push([d,h,p,m])>1||a(d,h)})})}function a(d,h){try{u(r[d](h))}catch(p){f(s[0][3],p)}}function u(d){d.value instanceof un?Promise.resolve(d.value.v).then(l,c):f(s[0][2],d)}function l(d){a("next",d)}function c(d){a("throw",d)}function f(d,h){d(h),s.shift(),s.length&&a(s[0][0],s[0][1])}}function YO(e){var t,n;return t={},r("next"),r("throw",function(i){throw i}),r("return"),t[Symbol.iterator]=function(){return this},t;function r(i,s){t[i]=e[i]?function(o){return(n=!n)?{value:un(e[i](o)),done:!1}:s?s(o):o}:s}}function My(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],n;return t?t.call(e):(e=typeof Az=="function"?Az(e):e[Symbol.iterator](),n={},r("next"),r("throw"),r("return"),n[Symbol.asyncIterator]=function(){return this},n);function r(s){n[s]=e[s]&&function(o){return new Promise(function(a,u){o=e[s](o),i(a,u,o.done,o.value)})}}function i(s,o,a,u){Promise.resolve(u).then(function(l){s({value:l,done:a})},o)}}const tqe=new TextDecoder("utf-8"),ik=e=>tqe.decode(e),nqe=new TextEncoder,Q6=e=>nqe.encode(e),rqe=e=>typeof e=="boolean",Ls=e=>typeof e=="function",Zf=e=>e!=null&&Object(e)===e,FC=e=>Zf(e)&&Ls(e.then),X6=e=>Zf(e)&&Ls(e[Symbol.iterator]),BC=e=>Zf(e)&&Ls(e[Symbol.asyncIterator]),iqe=e=>Zf(e)&&"done"in e&&"value"in e,Mse=e=>"_getDOMStream"in e&&"_getNodeStream"in e,sqe=e=>Zf(e)&&Ls(e.abort)&&Ls(e.getWriter)&&!Mse(e),oqe=e=>Zf(e)&&Ls(e.end)&&Ls(e.write)&&rqe(e.writable)&&!Mse(e),aqe=e=>Zf(e)&&Ls(e.clear)&&Ls(e.bytes)&&Ls(e.position)&&Ls(e.setPosition)&&Ls(e.capacity)&&Ls(e.getBufferIdentifier)&&Ls(e.createLong),J6=typeof SharedArrayBuffer<"u"?SharedArrayBuffer:ArrayBuffer;function uqe(e){const t=e[0]?[e[0]]:[];let n,r,i,s;for(let o,a,u=0,l=0,c=e.length;++uc+f.byteLength,0);let i,s,o,a=0,u=-1;const l=Math.min(t||Number.POSITIVE_INFINITY,r);for(const c=n.length;++ufi(Int32Array,e),Mn=e=>fi(Uint8Array,e),sk=e=>(e.next(),e);function*lqe(e,t){const n=function*(i){yield i},r=typeof t=="string"||ArrayBuffer.isView(t)||t instanceof ArrayBuffer||t instanceof J6?n(t):X6(t)?t:n(t);return yield*sk(function*(i){let s=null;do s=i.next(yield fi(e,s));while(!s.done)}(r[Symbol.iterator]())),new e}const cqe=e=>lqe(Uint8Array,e);function Fse(e,t){return Fd(this,arguments,function*(){if(FC(t))return yield un(yield un(yield*YO(My(Fse(e,yield un(t))))));const r=function(o){return Fd(this,arguments,function*(){yield yield un(yield un(o))})},i=function(o){return Fd(this,arguments,function*(){yield un(yield*YO(My(sk(function*(a){let u=null;do u=a.next(yield u==null?void 0:u.value);while(!u.done)}(o[Symbol.iterator]())))))})},s=typeof t=="string"||ArrayBuffer.isView(t)||t instanceof ArrayBuffer||t instanceof J6?r(t):X6(t)?i(t):BC(t)?t:r(t);return yield un(yield*YO(My(sk(function(o){return Fd(this,arguments,function*(){let a=null;do a=yield un(o.next(yield yield un(fi(e,a))));while(!a.done)})}(s[Symbol.asyncIterator]()))))),yield un(new e)})}const fqe=e=>Fse(Uint8Array,e);function Bse(e,t,n){if(e!==0){n=n.slice(0,t);for(let r=-1,i=n.length;++r0)do if(e[n]!==t[n])return!1;while(++n(e.next(),e);function*hqe(e){let t,n=!1,r=[],i,s,o,a=0;function u(){return s==="peek"?tl(r,o)[0]:([i,r,a]=tl(r,o),i)}({cmd:s,size:o}=yield null);const l=cqe(e)[Symbol.iterator]();try{do if({done:t,value:i}=Number.isNaN(o-a)?l.next():l.next(o-a),!t&&i.byteLength>0&&(r.push(i),a+=i.byteLength),t||o<=a)do({cmd:s,size:o}=yield u());while(o0&&(i.push(s),u+=s.byteLength),n||a<=u)do({cmd:o,size:a}=yield yield un(l()));while(a0&&(i.push(Mn(s)),u+=s.byteLength),n||a<=u)do({cmd:o,size:a}=yield yield un(l()));while(a{})}get closed(){return this.reader?this.reader.closed.catch(()=>{}):Promise.resolve()}releaseLock(){this.reader&&this.reader.releaseLock(),this.reader=null}cancel(t){return Il(this,void 0,void 0,function*(){const{reader:n,source:r}=this;n&&(yield n.cancel(t).catch(()=>{})),r&&r.locked&&this.releaseLock()})}read(t){return Il(this,void 0,void 0,function*(){if(t===0)return{done:this.reader==null,value:new Uint8Array(0)};const n=yield this.reader.read();return!n.done&&(n.value=Mn(n)),n})}}const KO=(e,t)=>{const n=i=>r([t,i]);let r;return[t,n,new Promise(i=>(r=i)&&e.once(t,n))]};function yqe(e){return Fd(this,arguments,function*(){const n=[];let r="error",i=!1,s=null,o,a,u=0,l=[],c;function f(){return o==="peek"?tl(l,a)[0]:([c,l,u]=tl(l,a),c)}if({cmd:o,size:a}=yield yield un(null),e.isTTY)return yield yield un(new Uint8Array(0)),yield un(null);try{n[0]=KO(e,"end"),n[1]=KO(e,"error");do{if(n[2]=KO(e,"readable"),[r,s]=yield un(Promise.race(n.map(h=>h[2]))),r==="error")break;if((i=r==="end")||(Number.isFinite(a-u)?(c=Mn(e.read(a-u)),c.byteLength0&&(l.push(c),u+=c.byteLength)),i||a<=u)do({cmd:o,size:a}=yield yield un(f()));while(a{for(const[g,v]of h)e.off(g,v);try{const g=e.destroy;g&&g.call(e,p),p=void 0}catch(g){p=g||p}finally{p!=null?y(p):m()}})}})}var gs;(function(e){e[e.V1=0]="V1",e[e.V2=1]="V2",e[e.V3=2]="V3",e[e.V4=3]="V4",e[e.V5=4]="V5"})(gs||(gs={}));var so;(function(e){e[e.Sparse=0]="Sparse",e[e.Dense=1]="Dense"})(so||(so={}));var $i;(function(e){e[e.HALF=0]="HALF",e[e.SINGLE=1]="SINGLE",e[e.DOUBLE=2]="DOUBLE"})($i||($i={}));var nl;(function(e){e[e.DAY=0]="DAY",e[e.MILLISECOND=1]="MILLISECOND"})(nl||(nl={}));var vt;(function(e){e[e.SECOND=0]="SECOND",e[e.MILLISECOND=1]="MILLISECOND",e[e.MICROSECOND=2]="MICROSECOND",e[e.NANOSECOND=3]="NANOSECOND"})(vt||(vt={}));var rl;(function(e){e[e.YEAR_MONTH=0]="YEAR_MONTH",e[e.DAY_TIME=1]="DAY_TIME",e[e.MONTH_DAY_NANO=2]="MONTH_DAY_NANO"})(rl||(rl={}));var pi;(function(e){e[e.NONE=0]="NONE",e[e.Schema=1]="Schema",e[e.DictionaryBatch=2]="DictionaryBatch",e[e.RecordBatch=3]="RecordBatch",e[e.Tensor=4]="Tensor",e[e.SparseTensor=5]="SparseTensor"})(pi||(pi={}));var G;(function(e){e[e.NONE=0]="NONE",e[e.Null=1]="Null",e[e.Int=2]="Int",e[e.Float=3]="Float",e[e.Binary=4]="Binary",e[e.Utf8=5]="Utf8",e[e.Bool=6]="Bool",e[e.Decimal=7]="Decimal",e[e.Date=8]="Date",e[e.Time=9]="Time",e[e.Timestamp=10]="Timestamp",e[e.Interval=11]="Interval",e[e.List=12]="List",e[e.Struct=13]="Struct",e[e.Union=14]="Union",e[e.FixedSizeBinary=15]="FixedSizeBinary",e[e.FixedSizeList=16]="FixedSizeList",e[e.Map=17]="Map",e[e.Duration=18]="Duration",e[e.Dictionary=-1]="Dictionary",e[e.Int8=-2]="Int8",e[e.Int16=-3]="Int16",e[e.Int32=-4]="Int32",e[e.Int64=-5]="Int64",e[e.Uint8=-6]="Uint8",e[e.Uint16=-7]="Uint16",e[e.Uint32=-8]="Uint32",e[e.Uint64=-9]="Uint64",e[e.Float16=-10]="Float16",e[e.Float32=-11]="Float32",e[e.Float64=-12]="Float64",e[e.DateDay=-13]="DateDay",e[e.DateMillisecond=-14]="DateMillisecond",e[e.TimestampSecond=-15]="TimestampSecond",e[e.TimestampMillisecond=-16]="TimestampMillisecond",e[e.TimestampMicrosecond=-17]="TimestampMicrosecond",e[e.TimestampNanosecond=-18]="TimestampNanosecond",e[e.TimeSecond=-19]="TimeSecond",e[e.TimeMillisecond=-20]="TimeMillisecond",e[e.TimeMicrosecond=-21]="TimeMicrosecond",e[e.TimeNanosecond=-22]="TimeNanosecond",e[e.DenseUnion=-23]="DenseUnion",e[e.SparseUnion=-24]="SparseUnion",e[e.IntervalDayTime=-25]="IntervalDayTime",e[e.IntervalYearMonth=-26]="IntervalYearMonth",e[e.DurationSecond=-27]="DurationSecond",e[e.DurationMillisecond=-28]="DurationMillisecond",e[e.DurationMicrosecond=-29]="DurationMicrosecond",e[e.DurationNanosecond=-30]="DurationNanosecond"})(G||(G={}));var _l;(function(e){e[e.OFFSET=0]="OFFSET",e[e.DATA=1]="DATA",e[e.VALIDITY=2]="VALIDITY",e[e.TYPE=3]="TYPE"})(_l||(_l={}));const vqe=void 0;function vh(e){if(e===null)return"null";if(e===vqe)return"undefined";switch(typeof e){case"number":return`${e}`;case"bigint":return`${e}`;case"string":return`"${e}"`}return typeof e[Symbol.toPrimitive]=="function"?e[Symbol.toPrimitive]("string"):ArrayBuffer.isView(e)?e instanceof BigInt64Array||e instanceof BigUint64Array?`[${[...e].map(t=>vh(t))}]`:`[${e}]`:ArrayBuffer.isView(e)?`[${e}]`:JSON.stringify(e,(t,n)=>typeof n=="bigint"?`${n}`:n)}const _qe=Symbol.for("isArrowBigNum");function ru(e,...t){return t.length===0?Object.setPrototypeOf(fi(this.TypedArray,e),this.constructor.prototype):Object.setPrototypeOf(new this.TypedArray(e,...t),this.constructor.prototype)}ru.prototype[_qe]=!0;ru.prototype.toJSON=function(){return`"${Fv(this)}"`};ru.prototype.valueOf=function(){return jse(this)};ru.prototype.toString=function(){return Fv(this)};ru.prototype[Symbol.toPrimitive]=function(e="default"){switch(e){case"number":return jse(this);case"string":return Fv(this);case"default":return bqe(this)}return Fv(this)};function dm(...e){return ru.apply(this,e)}function hm(...e){return ru.apply(this,e)}function Mv(...e){return ru.apply(this,e)}Object.setPrototypeOf(dm.prototype,Object.create(Int32Array.prototype));Object.setPrototypeOf(hm.prototype,Object.create(Uint32Array.prototype));Object.setPrototypeOf(Mv.prototype,Object.create(Uint32Array.prototype));Object.assign(dm.prototype,ru.prototype,{constructor:dm,signed:!0,TypedArray:Int32Array,BigIntArray:BigInt64Array});Object.assign(hm.prototype,ru.prototype,{constructor:hm,signed:!1,TypedArray:Uint32Array,BigIntArray:BigUint64Array});Object.assign(Mv.prototype,ru.prototype,{constructor:Mv,signed:!0,TypedArray:Uint32Array,BigIntArray:BigUint64Array});function jse(e){const{buffer:t,byteOffset:n,length:r,signed:i}=e,s=new BigUint64Array(t,n,r),o=i&&s.at(-1)&BigInt(1)<{if(e.byteLength===8)return`${new e.BigIntArray(e.buffer,e.byteOffset,1)[0]}`;if(!e.signed)return QO(e);let t=new Uint16Array(e.buffer,e.byteOffset,e.byteLength/2);if(new Int16Array([t.at(-1)])[0]>=0)return QO(e);t=t.slice();let r=1;for(let s=0;se.byteLength===8?new e.BigIntArray(e.buffer,e.byteOffset,1)[0]:Fv(e);function QO(e){let t="";const n=new Uint32Array(2);let r=new Uint16Array(e.buffer,e.byteOffset,e.byteLength/2);const i=new Uint32Array((r=new Uint16Array(r).reverse()).buffer);let s=-1;const o=r.length-1;do{for(n[0]=r[s=0];sNumber.MAX_SAFE_INTEGER))throw new TypeError(`${e} is not safe to convert to a number.`);return Number(e)}var Use,Vse,zse,Hse,Wse,qse,Gse,Yse,Kse,Qse,Xse,Jse,Zse,eoe,toe,noe,roe,ioe,soe,ooe;class Bt{static isNull(t){return(t==null?void 0:t.typeId)===G.Null}static isInt(t){return(t==null?void 0:t.typeId)===G.Int}static isFloat(t){return(t==null?void 0:t.typeId)===G.Float}static isBinary(t){return(t==null?void 0:t.typeId)===G.Binary}static isUtf8(t){return(t==null?void 0:t.typeId)===G.Utf8}static isBool(t){return(t==null?void 0:t.typeId)===G.Bool}static isDecimal(t){return(t==null?void 0:t.typeId)===G.Decimal}static isDate(t){return(t==null?void 0:t.typeId)===G.Date}static isTime(t){return(t==null?void 0:t.typeId)===G.Time}static isTimestamp(t){return(t==null?void 0:t.typeId)===G.Timestamp}static isInterval(t){return(t==null?void 0:t.typeId)===G.Interval}static isDuration(t){return(t==null?void 0:t.typeId)===G.Duration}static isList(t){return(t==null?void 0:t.typeId)===G.List}static isStruct(t){return(t==null?void 0:t.typeId)===G.Struct}static isUnion(t){return(t==null?void 0:t.typeId)===G.Union}static isFixedSizeBinary(t){return(t==null?void 0:t.typeId)===G.FixedSizeBinary}static isFixedSizeList(t){return(t==null?void 0:t.typeId)===G.FixedSizeList}static isMap(t){return(t==null?void 0:t.typeId)===G.Map}static isDictionary(t){return(t==null?void 0:t.typeId)===G.Dictionary}static isDenseUnion(t){return Bt.isUnion(t)&&t.mode===so.Dense}static isSparseUnion(t){return Bt.isUnion(t)&&t.mode===so.Sparse}get typeId(){return G.NONE}}Use=Symbol.toStringTag;Bt[Use]=(e=>(e.children=null,e.ArrayType=Array,e[Symbol.toStringTag]="DataType"))(Bt.prototype);let Jl=class extends Bt{toString(){return"Null"}get typeId(){return G.Null}};Vse=Symbol.toStringTag;Jl[Vse]=(e=>e[Symbol.toStringTag]="Null")(Jl.prototype);class ws extends Bt{constructor(t,n){super(),this.isSigned=t,this.bitWidth=n}get typeId(){return G.Int}get ArrayType(){switch(this.bitWidth){case 8:return this.isSigned?Int8Array:Uint8Array;case 16:return this.isSigned?Int16Array:Uint16Array;case 32:return this.isSigned?Int32Array:Uint32Array;case 64:return this.isSigned?BigInt64Array:BigUint64Array}throw new Error(`Unrecognized ${this[Symbol.toStringTag]} type`)}toString(){return`${this.isSigned?"I":"Ui"}nt${this.bitWidth}`}}zse=Symbol.toStringTag;ws[zse]=(e=>(e.isSigned=null,e.bitWidth=null,e[Symbol.toStringTag]="Int"))(ws.prototype);class eL extends ws{constructor(){super(!0,8)}get ArrayType(){return Int8Array}}class tL extends ws{constructor(){super(!0,16)}get ArrayType(){return Int16Array}}class Nf extends ws{constructor(){super(!0,32)}get ArrayType(){return Int32Array}}class nL extends ws{constructor(){super(!0,64)}get ArrayType(){return BigInt64Array}}class rL extends ws{constructor(){super(!1,8)}get ArrayType(){return Uint8Array}}class iL extends ws{constructor(){super(!1,16)}get ArrayType(){return Uint16Array}}class sL extends ws{constructor(){super(!1,32)}get ArrayType(){return Uint32Array}}class oL extends ws{constructor(){super(!1,64)}get ArrayType(){return BigUint64Array}}Object.defineProperty(eL.prototype,"ArrayType",{value:Int8Array});Object.defineProperty(tL.prototype,"ArrayType",{value:Int16Array});Object.defineProperty(Nf.prototype,"ArrayType",{value:Int32Array});Object.defineProperty(nL.prototype,"ArrayType",{value:BigInt64Array});Object.defineProperty(rL.prototype,"ArrayType",{value:Uint8Array});Object.defineProperty(iL.prototype,"ArrayType",{value:Uint16Array});Object.defineProperty(sL.prototype,"ArrayType",{value:Uint32Array});Object.defineProperty(oL.prototype,"ArrayType",{value:BigUint64Array});class kf extends Bt{constructor(t){super(),this.precision=t}get typeId(){return G.Float}get ArrayType(){switch(this.precision){case $i.HALF:return Uint16Array;case $i.SINGLE:return Float32Array;case $i.DOUBLE:return Float64Array}throw new Error(`Unrecognized ${this[Symbol.toStringTag]} type`)}toString(){return`Float${this.precision<<5||16}`}}Hse=Symbol.toStringTag;kf[Hse]=(e=>(e.precision=null,e[Symbol.toStringTag]="Float"))(kf.prototype);class aoe extends kf{constructor(){super($i.HALF)}}class aL extends kf{constructor(){super($i.SINGLE)}}class uL extends kf{constructor(){super($i.DOUBLE)}}Object.defineProperty(aoe.prototype,"ArrayType",{value:Uint16Array});Object.defineProperty(aL.prototype,"ArrayType",{value:Float32Array});Object.defineProperty(uL.prototype,"ArrayType",{value:Float64Array});let Bv=class extends Bt{constructor(){super()}get typeId(){return G.Binary}toString(){return"Binary"}};Wse=Symbol.toStringTag;Bv[Wse]=(e=>(e.ArrayType=Uint8Array,e[Symbol.toStringTag]="Binary"))(Bv.prototype);let Qm=class extends Bt{constructor(){super()}get typeId(){return G.Utf8}toString(){return"Utf8"}};qse=Symbol.toStringTag;Qm[qse]=(e=>(e.ArrayType=Uint8Array,e[Symbol.toStringTag]="Utf8"))(Qm.prototype);let jv=class extends Bt{constructor(){super()}get typeId(){return G.Bool}toString(){return"Bool"}};Gse=Symbol.toStringTag;jv[Gse]=(e=>(e.ArrayType=Uint8Array,e[Symbol.toStringTag]="Bool"))(jv.prototype);let aI=class extends Bt{constructor(t,n,r=128){super(),this.scale=t,this.precision=n,this.bitWidth=r}get typeId(){return G.Decimal}toString(){return`Decimal[${this.precision}e${this.scale>0?"+":""}${this.scale}]`}};Yse=Symbol.toStringTag;aI[Yse]=(e=>(e.scale=null,e.precision=null,e.ArrayType=Uint32Array,e[Symbol.toStringTag]="Decimal"))(aI.prototype);class Xm extends Bt{constructor(t){super(),this.unit=t}get typeId(){return G.Date}toString(){return`Date${(this.unit+1)*32}<${nl[this.unit]}>`}}Kse=Symbol.toStringTag;Xm[Kse]=(e=>(e.unit=null,e.ArrayType=Int32Array,e[Symbol.toStringTag]="Date"))(Xm.prototype);class wqe extends Xm{constructor(){super(nl.DAY)}}class Eqe extends Xm{constructor(){super(nl.MILLISECOND)}}class Zl extends Bt{constructor(t,n){super(),this.unit=t,this.bitWidth=n}get typeId(){return G.Time}toString(){return`Time${this.bitWidth}<${vt[this.unit]}>`}get ArrayType(){switch(this.bitWidth){case 32:return Int32Array;case 64:return BigInt64Array}throw new Error(`Unrecognized ${this[Symbol.toStringTag]} type`)}}Qse=Symbol.toStringTag;Zl[Qse]=(e=>(e.unit=null,e.bitWidth=null,e[Symbol.toStringTag]="Time"))(Zl.prototype);class Sqe extends Zl{constructor(){super(vt.SECOND,32)}}class Tqe extends Zl{constructor(){super(vt.MILLISECOND,32)}}class Iqe extends Zl{constructor(){super(vt.MICROSECOND,64)}}class xqe extends Zl{constructor(){super(vt.NANOSECOND,64)}}class uI extends Bt{constructor(t,n){super(),this.unit=t,this.timezone=n}get typeId(){return G.Timestamp}toString(){return`Timestamp<${vt[this.unit]}${this.timezone?`, ${this.timezone}`:""}>`}}Xse=Symbol.toStringTag;uI[Xse]=(e=>(e.unit=null,e.timezone=null,e.ArrayType=Int32Array,e[Symbol.toStringTag]="Timestamp"))(uI.prototype);class Jm extends Bt{constructor(t){super(),this.unit=t}get typeId(){return G.Interval}toString(){return`Interval<${rl[this.unit]}>`}}Jse=Symbol.toStringTag;Jm[Jse]=(e=>(e.unit=null,e.ArrayType=Int32Array,e[Symbol.toStringTag]="Interval"))(Jm.prototype);class Cqe extends Jm{constructor(){super(rl.DAY_TIME)}}class Aqe extends Jm{constructor(){super(rl.YEAR_MONTH)}}let lI=class extends Bt{constructor(t){super(),this.unit=t}get typeId(){return G.Duration}toString(){return`Duration<${vt[this.unit]}>`}};Zse=Symbol.toStringTag;lI[Zse]=(e=>(e.unit=null,e.ArrayType=BigInt64Array,e[Symbol.toStringTag]="Duration"))(lI.prototype);let Zm=class extends Bt{constructor(t){super(),this.children=[t]}get typeId(){return G.List}toString(){return`List<${this.valueType}>`}get valueType(){return this.children[0].type}get valueField(){return this.children[0]}get ArrayType(){return this.valueType.ArrayType}};eoe=Symbol.toStringTag;Zm[eoe]=(e=>(e.children=null,e[Symbol.toStringTag]="List"))(Zm.prototype);class rs extends Bt{constructor(t){super(),this.children=t}get typeId(){return G.Struct}toString(){return`Struct<{${this.children.map(t=>`${t.name}:${t.type}`).join(", ")}}>`}}toe=Symbol.toStringTag;rs[toe]=(e=>(e.children=null,e[Symbol.toStringTag]="Struct"))(rs.prototype);class Uv extends Bt{constructor(t,n,r){super(),this.mode=t,this.children=r,this.typeIds=n=Int32Array.from(n),this.typeIdToChildIndex=n.reduce((i,s,o)=>(i[s]=o)&&i||i,Object.create(null))}get typeId(){return G.Union}toString(){return`${this[Symbol.toStringTag]}<${this.children.map(t=>`${t.type}`).join(" | ")}>`}}noe=Symbol.toStringTag;Uv[noe]=(e=>(e.mode=null,e.typeIds=null,e.children=null,e.typeIdToChildIndex=null,e.ArrayType=Int8Array,e[Symbol.toStringTag]="Union"))(Uv.prototype);let cI=class extends Bt{constructor(t){super(),this.byteWidth=t}get typeId(){return G.FixedSizeBinary}toString(){return`FixedSizeBinary[${this.byteWidth}]`}};roe=Symbol.toStringTag;cI[roe]=(e=>(e.byteWidth=null,e.ArrayType=Uint8Array,e[Symbol.toStringTag]="FixedSizeBinary"))(cI.prototype);let eg=class extends Bt{constructor(t,n){super(),this.listSize=t,this.children=[n]}get typeId(){return G.FixedSizeList}get valueType(){return this.children[0].type}get valueField(){return this.children[0]}get ArrayType(){return this.valueType.ArrayType}toString(){return`FixedSizeList[${this.listSize}]<${this.valueType}>`}};ioe=Symbol.toStringTag;eg[ioe]=(e=>(e.children=null,e.listSize=null,e[Symbol.toStringTag]="FixedSizeList"))(eg.prototype);class Vv extends Bt{constructor(t,n=!1){var r,i,s;if(super(),this.children=[t],this.keysSorted=n,t&&(t.name="entries",!((r=t==null?void 0:t.type)===null||r===void 0)&&r.children)){const o=(i=t==null?void 0:t.type)===null||i===void 0?void 0:i.children[0];o&&(o.name="key");const a=(s=t==null?void 0:t.type)===null||s===void 0?void 0:s.children[1];a&&(a.name="value")}}get typeId(){return G.Map}get keyType(){return this.children[0].type.children[0].type}get valueType(){return this.children[0].type.children[1].type}get childType(){return this.children[0].type}toString(){return`Map<{${this.children[0].type.children.map(t=>`${t.name}:${t.type}`).join(", ")}}>`}}soe=Symbol.toStringTag;Vv[soe]=(e=>(e.children=null,e.keysSorted=null,e[Symbol.toStringTag]="Map_"))(Vv.prototype);const Pqe=(e=>()=>++e)(-1);class Df extends Bt{constructor(t,n,r,i){super(),this.indices=n,this.dictionary=t,this.isOrdered=i||!1,this.id=r==null?Pqe():Ka(r)}get typeId(){return G.Dictionary}get children(){return this.dictionary.children}get valueType(){return this.dictionary}get ArrayType(){return this.dictionary.ArrayType}toString(){return`Dictionary<${this.indices}, ${this.dictionary}>`}}ooe=Symbol.toStringTag;Df[ooe]=(e=>(e.id=null,e.indices=null,e.isOrdered=null,e.dictionary=null,e[Symbol.toStringTag]="Dictionary"))(Df.prototype);function pu(e){const t=e;switch(e.typeId){case G.Decimal:return e.bitWidth/32;case G.Timestamp:return 2;case G.Date:return 1+t.unit;case G.Interval:return 1+t.unit;case G.FixedSizeList:return t.listSize;case G.FixedSizeBinary:return t.byteWidth;default:return 1}}class qt{visitMany(t,...n){return t.map((r,i)=>this.visit(r,...n.map(s=>s[i])))}visit(...t){return this.getVisitFn(t[0],!1).apply(this,t)}getVisitFn(t,n=!0){return Oqe(this,t,n)}getVisitFnByTypeId(t,n=!0){return pp(this,t,n)}visitNull(t,...n){return null}visitBool(t,...n){return null}visitInt(t,...n){return null}visitFloat(t,...n){return null}visitUtf8(t,...n){return null}visitBinary(t,...n){return null}visitFixedSizeBinary(t,...n){return null}visitDate(t,...n){return null}visitTimestamp(t,...n){return null}visitTime(t,...n){return null}visitDecimal(t,...n){return null}visitList(t,...n){return null}visitStruct(t,...n){return null}visitUnion(t,...n){return null}visitDictionary(t,...n){return null}visitInterval(t,...n){return null}visitDuration(t,...n){return null}visitFixedSizeList(t,...n){return null}visitMap(t,...n){return null}}function Oqe(e,t,n=!0){return typeof t=="number"?pp(e,t,n):typeof t=="string"&&t in G?pp(e,G[t],n):t&&t instanceof Bt?pp(e,Oz(t),n):t!=null&&t.type&&t.type instanceof Bt?pp(e,Oz(t.type),n):pp(e,G.NONE,n)}function pp(e,t,n=!0){let r=null;switch(t){case G.Null:r=e.visitNull;break;case G.Bool:r=e.visitBool;break;case G.Int:r=e.visitInt;break;case G.Int8:r=e.visitInt8||e.visitInt;break;case G.Int16:r=e.visitInt16||e.visitInt;break;case G.Int32:r=e.visitInt32||e.visitInt;break;case G.Int64:r=e.visitInt64||e.visitInt;break;case G.Uint8:r=e.visitUint8||e.visitInt;break;case G.Uint16:r=e.visitUint16||e.visitInt;break;case G.Uint32:r=e.visitUint32||e.visitInt;break;case G.Uint64:r=e.visitUint64||e.visitInt;break;case G.Float:r=e.visitFloat;break;case G.Float16:r=e.visitFloat16||e.visitFloat;break;case G.Float32:r=e.visitFloat32||e.visitFloat;break;case G.Float64:r=e.visitFloat64||e.visitFloat;break;case G.Utf8:r=e.visitUtf8;break;case G.Binary:r=e.visitBinary;break;case G.FixedSizeBinary:r=e.visitFixedSizeBinary;break;case G.Date:r=e.visitDate;break;case G.DateDay:r=e.visitDateDay||e.visitDate;break;case G.DateMillisecond:r=e.visitDateMillisecond||e.visitDate;break;case G.Timestamp:r=e.visitTimestamp;break;case G.TimestampSecond:r=e.visitTimestampSecond||e.visitTimestamp;break;case G.TimestampMillisecond:r=e.visitTimestampMillisecond||e.visitTimestamp;break;case G.TimestampMicrosecond:r=e.visitTimestampMicrosecond||e.visitTimestamp;break;case G.TimestampNanosecond:r=e.visitTimestampNanosecond||e.visitTimestamp;break;case G.Time:r=e.visitTime;break;case G.TimeSecond:r=e.visitTimeSecond||e.visitTime;break;case G.TimeMillisecond:r=e.visitTimeMillisecond||e.visitTime;break;case G.TimeMicrosecond:r=e.visitTimeMicrosecond||e.visitTime;break;case G.TimeNanosecond:r=e.visitTimeNanosecond||e.visitTime;break;case G.Decimal:r=e.visitDecimal;break;case G.List:r=e.visitList;break;case G.Struct:r=e.visitStruct;break;case G.Union:r=e.visitUnion;break;case G.DenseUnion:r=e.visitDenseUnion||e.visitUnion;break;case G.SparseUnion:r=e.visitSparseUnion||e.visitUnion;break;case G.Dictionary:r=e.visitDictionary;break;case G.Interval:r=e.visitInterval;break;case G.IntervalDayTime:r=e.visitIntervalDayTime||e.visitInterval;break;case G.IntervalYearMonth:r=e.visitIntervalYearMonth||e.visitInterval;break;case G.Duration:r=e.visitDuration;break;case G.DurationSecond:r=e.visitDurationSecond||e.visitDuration;break;case G.DurationMillisecond:r=e.visitDurationMillisecond||e.visitDuration;break;case G.DurationMicrosecond:r=e.visitDurationMicrosecond||e.visitDuration;break;case G.DurationNanosecond:r=e.visitDurationNanosecond||e.visitDuration;break;case G.FixedSizeList:r=e.visitFixedSizeList;break;case G.Map:r=e.visitMap;break}if(typeof r=="function")return r;if(!n)return()=>null;throw new Error(`Unrecognized type '${G[t]}'`)}function Oz(e){switch(e.typeId){case G.Null:return G.Null;case G.Int:{const{bitWidth:t,isSigned:n}=e;switch(t){case 8:return n?G.Int8:G.Uint8;case 16:return n?G.Int16:G.Uint16;case 32:return n?G.Int32:G.Uint32;case 64:return n?G.Int64:G.Uint64}return G.Int}case G.Float:switch(e.precision){case $i.HALF:return G.Float16;case $i.SINGLE:return G.Float32;case $i.DOUBLE:return G.Float64}return G.Float;case G.Binary:return G.Binary;case G.Utf8:return G.Utf8;case G.Bool:return G.Bool;case G.Decimal:return G.Decimal;case G.Time:switch(e.unit){case vt.SECOND:return G.TimeSecond;case vt.MILLISECOND:return G.TimeMillisecond;case vt.MICROSECOND:return G.TimeMicrosecond;case vt.NANOSECOND:return G.TimeNanosecond}return G.Time;case G.Timestamp:switch(e.unit){case vt.SECOND:return G.TimestampSecond;case vt.MILLISECOND:return G.TimestampMillisecond;case vt.MICROSECOND:return G.TimestampMicrosecond;case vt.NANOSECOND:return G.TimestampNanosecond}return G.Timestamp;case G.Date:switch(e.unit){case nl.DAY:return G.DateDay;case nl.MILLISECOND:return G.DateMillisecond}return G.Date;case G.Interval:switch(e.unit){case rl.DAY_TIME:return G.IntervalDayTime;case rl.YEAR_MONTH:return G.IntervalYearMonth}return G.Interval;case G.Duration:switch(e.unit){case vt.SECOND:return G.DurationSecond;case vt.MILLISECOND:return G.DurationMillisecond;case vt.MICROSECOND:return G.DurationMicrosecond;case vt.NANOSECOND:return G.DurationNanosecond}return G.Duration;case G.Map:return G.Map;case G.List:return G.List;case G.Struct:return G.Struct;case G.Union:switch(e.mode){case so.Dense:return G.DenseUnion;case so.Sparse:return G.SparseUnion}return G.Union;case G.FixedSizeBinary:return G.FixedSizeBinary;case G.FixedSizeList:return G.FixedSizeList;case G.Dictionary:return G.Dictionary}throw new Error(`Unrecognized type '${G[e.typeId]}'`)}qt.prototype.visitInt8=null;qt.prototype.visitInt16=null;qt.prototype.visitInt32=null;qt.prototype.visitInt64=null;qt.prototype.visitUint8=null;qt.prototype.visitUint16=null;qt.prototype.visitUint32=null;qt.prototype.visitUint64=null;qt.prototype.visitFloat16=null;qt.prototype.visitFloat32=null;qt.prototype.visitFloat64=null;qt.prototype.visitDateDay=null;qt.prototype.visitDateMillisecond=null;qt.prototype.visitTimestampSecond=null;qt.prototype.visitTimestampMillisecond=null;qt.prototype.visitTimestampMicrosecond=null;qt.prototype.visitTimestampNanosecond=null;qt.prototype.visitTimeSecond=null;qt.prototype.visitTimeMillisecond=null;qt.prototype.visitTimeMicrosecond=null;qt.prototype.visitTimeNanosecond=null;qt.prototype.visitDenseUnion=null;qt.prototype.visitSparseUnion=null;qt.prototype.visitIntervalDayTime=null;qt.prototype.visitIntervalYearMonth=null;qt.prototype.visitDuration=null;qt.prototype.visitDurationSecond=null;qt.prototype.visitDurationMillisecond=null;qt.prototype.visitDurationMicrosecond=null;qt.prototype.visitDurationNanosecond=null;const uoe=new Float64Array(1),op=new Uint32Array(uoe.buffer);function loe(e){const t=(e&31744)>>10,n=(e&1023)/1024,r=Math.pow(-1,(e&32768)>>15);switch(t){case 31:return r*(n?Number.NaN:1/0);case 0:return r*(n?6103515625e-14*n:0)}return r*Math.pow(2,t-15)*(1+n)}function coe(e){if(e!==e)return 32256;uoe[0]=e;const t=(op[1]&2147483648)>>16&65535;let n=op[1]&2146435072,r=0;return n>=1089470464?op[0]>0?n=31744:(n=(n&2080374784)>>16,r=(op[1]&1048575)>>10):n<=1056964608?(r=1048576+(op[1]&1048575),r=1048576+(r<<(n>>20)-998)>>21,n=0):(n=n-1056964608>>10,r=(op[1]&1048575)+512>>10),t|n|r&65535}class It extends qt{}function Ot(e){return(t,n,r)=>{if(t.setValid(n,r!=null))return e(t,n,r)}}const Rqe=(e,t,n)=>{e[t]=Math.trunc(n/864e5)},lL=(e,t,n)=>{e[t]=Math.trunc(n%4294967296),e[t+1]=Math.trunc(n/4294967296)},Nqe=(e,t,n)=>{e[t]=Math.trunc(n*1e3%4294967296),e[t+1]=Math.trunc(n*1e3/4294967296)},kqe=(e,t,n)=>{e[t]=Math.trunc(n*1e6%4294967296),e[t+1]=Math.trunc(n*1e6/4294967296)},foe=(e,t,n,r)=>{if(n+1{const i=e+n;r?t[i>>3]|=1<>3]&=~(1<{e[t]=n},cL=({values:e},t,n)=>{e[t]=n},doe=({values:e},t,n)=>{e[t]=coe(n)},$qe=(e,t,n)=>{switch(e.type.precision){case $i.HALF:return doe(e,t,n);case $i.SINGLE:case $i.DOUBLE:return cL(e,t,n)}},fL=({values:e},t,n)=>{Rqe(e,t,n.valueOf())},dL=({values:e},t,n)=>{lL(e,t*2,n.valueOf())},hoe=({stride:e,values:t},n,r)=>{t.set(r.subarray(0,e),e*n)},Lqe=({values:e,valueOffsets:t},n,r)=>foe(e,t,n,r),Mqe=({values:e,valueOffsets:t},n,r)=>{foe(e,t,n,Q6(r))},poe=(e,t,n)=>{e.type.unit===nl.DAY?fL(e,t,n):dL(e,t,n)},hL=({values:e},t,n)=>lL(e,t*2,n/1e3),pL=({values:e},t,n)=>lL(e,t*2,n),mL=({values:e},t,n)=>Nqe(e,t*2,n),gL=({values:e},t,n)=>kqe(e,t*2,n),moe=(e,t,n)=>{switch(e.type.unit){case vt.SECOND:return hL(e,t,n);case vt.MILLISECOND:return pL(e,t,n);case vt.MICROSECOND:return mL(e,t,n);case vt.NANOSECOND:return gL(e,t,n)}},yL=({values:e},t,n)=>{e[t]=n},vL=({values:e},t,n)=>{e[t]=n},_L=({values:e},t,n)=>{e[t]=n},bL=({values:e},t,n)=>{e[t]=n},goe=(e,t,n)=>{switch(e.type.unit){case vt.SECOND:return yL(e,t,n);case vt.MILLISECOND:return vL(e,t,n);case vt.MICROSECOND:return _L(e,t,n);case vt.NANOSECOND:return bL(e,t,n)}},yoe=({values:e,stride:t},n,r)=>{e.set(r.subarray(0,t),t*n)},Fqe=(e,t,n)=>{const r=e.children[0],i=e.valueOffsets,s=ca.getVisitFn(r);if(Array.isArray(n))for(let o=-1,a=i[t],u=i[t+1];a{const r=e.children[0],{valueOffsets:i}=e,s=ca.getVisitFn(r);let{[t]:o,[t+1]:a}=i;const u=n instanceof Map?n.entries():Object.entries(n);for(const l of u)if(s(r,o,l),++o>=a)break},jqe=(e,t)=>(n,r,i,s)=>r&&n(r,e,t[s]),Uqe=(e,t)=>(n,r,i,s)=>r&&n(r,e,t.get(s)),Vqe=(e,t)=>(n,r,i,s)=>r&&n(r,e,t.get(i.name)),zqe=(e,t)=>(n,r,i,s)=>r&&n(r,e,t[i.name]),Hqe=(e,t,n)=>{const r=e.type.children.map(s=>ca.getVisitFn(s.type)),i=n instanceof Map?Vqe(t,n):n instanceof Sn?Uqe(t,n):Array.isArray(n)?jqe(t,n):zqe(t,n);e.type.children.forEach((s,o)=>i(r[o],e.children[o],s,o))},Wqe=(e,t,n)=>{e.type.mode===so.Dense?voe(e,t,n):_oe(e,t,n)},voe=(e,t,n)=>{const r=e.type.typeIdToChildIndex[e.typeIds[t]],i=e.children[r];ca.visit(i,e.valueOffsets[t],n)},_oe=(e,t,n)=>{const r=e.type.typeIdToChildIndex[e.typeIds[t]],i=e.children[r];ca.visit(i,t,n)},qqe=(e,t,n)=>{var r;(r=e.dictionary)===null||r===void 0||r.set(e.values[t],n)},boe=(e,t,n)=>{e.type.unit===rl.DAY_TIME?wL(e,t,n):EL(e,t,n)},wL=({values:e},t,n)=>{e.set(n.subarray(0,2),2*t)},EL=({values:e},t,n)=>{e[t]=n[0]*12+n[1]%12},SL=({values:e},t,n)=>{e[t]=n},TL=({values:e},t,n)=>{e[t]=n},IL=({values:e},t,n)=>{e[t]=n},xL=({values:e},t,n)=>{e[t]=n},woe=(e,t,n)=>{switch(e.type.unit){case vt.SECOND:return SL(e,t,n);case vt.MILLISECOND:return TL(e,t,n);case vt.MICROSECOND:return IL(e,t,n);case vt.NANOSECOND:return xL(e,t,n)}},Gqe=(e,t,n)=>{const{stride:r}=e,i=e.children[0],s=ca.getVisitFn(i);if(Array.isArray(n))for(let o=-1,a=t*r;++o`${vh(t)}: ${vh(n)}`).join(", ")}}`}[Symbol.for("nodejs.util.inspect.custom")](){return this.toString()}[Symbol.iterator](){return new Yqe(this[Pa],this[pm])}}class Yqe{constructor(t,n){this.childIndex=0,this.children=t.children,this.rowIndex=n,this.childFields=t.type.children,this.numChildren=this.childFields.length}[Symbol.iterator](){return this}next(){const t=this.childIndex;return tn.name)}has(t,n){return t[Pa].type.children.findIndex(r=>r.name===n)!==-1}getOwnPropertyDescriptor(t,n){if(t[Pa].type.children.findIndex(r=>r.name===n)!==-1)return{writable:!0,enumerable:!0,configurable:!0}}get(t,n){if(Reflect.has(t,n))return t[n];const r=t[Pa].type.children.findIndex(i=>i.name===n);if(r!==-1){const i=oo.visit(t[Pa].children[r],t[pm]);return Reflect.set(t,n,i),i}}set(t,n,r){const i=t[Pa].type.children.findIndex(s=>s.name===n);return i!==-1?(ca.visit(t[Pa].children[i],t[pm],r),Reflect.set(t,n,r)):Reflect.has(t,n)||typeof n=="symbol"?Reflect.set(t,n,r):!1}}class _t extends qt{}function xt(e){return(t,n)=>t.getValid(n)?e(t,n):null}const Qqe=(e,t)=>864e5*e[t],AL=(e,t)=>4294967296*e[t+1]+(e[t]>>>0),Xqe=(e,t)=>4294967296*(e[t+1]/1e3)+(e[t]>>>0)/1e3,Jqe=(e,t)=>4294967296*(e[t+1]/1e6)+(e[t]>>>0)/1e6,Eoe=e=>new Date(e),Zqe=(e,t)=>Eoe(Qqe(e,t)),eGe=(e,t)=>Eoe(AL(e,t)),tGe=(e,t)=>null,Soe=(e,t,n)=>{if(n+1>=t.length)return null;const r=t[n],i=t[n+1];return e.subarray(r,i)},nGe=({offset:e,values:t},n)=>{const r=e+n;return(t[r>>3]&1<Zqe(e,t),Ioe=({values:e},t)=>eGe(e,t*2),ed=({stride:e,values:t},n)=>t[e*n],rGe=({stride:e,values:t},n)=>loe(t[e*n]),xoe=({values:e},t)=>e[t],iGe=({stride:e,values:t},n)=>t.subarray(e*n,e*(n+1)),sGe=({values:e,valueOffsets:t},n)=>Soe(e,t,n),oGe=({values:e,valueOffsets:t},n)=>{const r=Soe(e,t,n);return r!==null?ik(r):null},aGe=({values:e},t)=>e[t],uGe=({type:e,values:t},n)=>e.precision!==$i.HALF?t[n]:loe(t[n]),lGe=(e,t)=>e.type.unit===nl.DAY?Toe(e,t):Ioe(e,t),Coe=({values:e},t)=>1e3*AL(e,t*2),Aoe=({values:e},t)=>AL(e,t*2),Poe=({values:e},t)=>Xqe(e,t*2),Ooe=({values:e},t)=>Jqe(e,t*2),cGe=(e,t)=>{switch(e.type.unit){case vt.SECOND:return Coe(e,t);case vt.MILLISECOND:return Aoe(e,t);case vt.MICROSECOND:return Poe(e,t);case vt.NANOSECOND:return Ooe(e,t)}},Roe=({values:e},t)=>e[t],Noe=({values:e},t)=>e[t],koe=({values:e},t)=>e[t],Doe=({values:e},t)=>e[t],fGe=(e,t)=>{switch(e.type.unit){case vt.SECOND:return Roe(e,t);case vt.MILLISECOND:return Noe(e,t);case vt.MICROSECOND:return koe(e,t);case vt.NANOSECOND:return Doe(e,t)}},dGe=({values:e,stride:t},n)=>Z6.decimal(e.subarray(t*n,t*(n+1))),hGe=(e,t)=>{const{valueOffsets:n,stride:r,children:i}=e,{[t*r]:s,[t*r+1]:o}=n,u=i[0].slice(s,o-s);return new Sn([u])},pGe=(e,t)=>{const{valueOffsets:n,children:r}=e,{[t]:i,[t+1]:s}=n,o=r[0];return new jC(o.slice(i,s-i))},mGe=(e,t)=>new CL(e,t),gGe=(e,t)=>e.type.mode===so.Dense?$oe(e,t):Loe(e,t),$oe=(e,t)=>{const n=e.type.typeIdToChildIndex[e.typeIds[t]],r=e.children[n];return oo.visit(r,e.valueOffsets[t])},Loe=(e,t)=>{const n=e.type.typeIdToChildIndex[e.typeIds[t]],r=e.children[n];return oo.visit(r,t)},yGe=(e,t)=>{var n;return(n=e.dictionary)===null||n===void 0?void 0:n.get(e.values[t])},vGe=(e,t)=>e.type.unit===rl.DAY_TIME?Moe(e,t):Foe(e,t),Moe=({values:e},t)=>e.subarray(2*t,2*(t+1)),Foe=({values:e},t)=>{const n=e[t],r=new Int32Array(2);return r[0]=Math.trunc(n/12),r[1]=Math.trunc(n%12),r},Boe=({values:e},t)=>e[t],joe=({values:e},t)=>e[t],Uoe=({values:e},t)=>e[t],Voe=({values:e},t)=>e[t],_Ge=(e,t)=>{switch(e.type.unit){case vt.SECOND:return Boe(e,t);case vt.MILLISECOND:return joe(e,t);case vt.MICROSECOND:return Uoe(e,t);case vt.NANOSECOND:return Voe(e,t)}},bGe=(e,t)=>{const{stride:n,children:r}=e,s=r[0].slice(t*n,n);return new Sn([s])};_t.prototype.visitNull=xt(tGe);_t.prototype.visitBool=xt(nGe);_t.prototype.visitInt=xt(aGe);_t.prototype.visitInt8=xt(ed);_t.prototype.visitInt16=xt(ed);_t.prototype.visitInt32=xt(ed);_t.prototype.visitInt64=xt(xoe);_t.prototype.visitUint8=xt(ed);_t.prototype.visitUint16=xt(ed);_t.prototype.visitUint32=xt(ed);_t.prototype.visitUint64=xt(xoe);_t.prototype.visitFloat=xt(uGe);_t.prototype.visitFloat16=xt(rGe);_t.prototype.visitFloat32=xt(ed);_t.prototype.visitFloat64=xt(ed);_t.prototype.visitUtf8=xt(oGe);_t.prototype.visitBinary=xt(sGe);_t.prototype.visitFixedSizeBinary=xt(iGe);_t.prototype.visitDate=xt(lGe);_t.prototype.visitDateDay=xt(Toe);_t.prototype.visitDateMillisecond=xt(Ioe);_t.prototype.visitTimestamp=xt(cGe);_t.prototype.visitTimestampSecond=xt(Coe);_t.prototype.visitTimestampMillisecond=xt(Aoe);_t.prototype.visitTimestampMicrosecond=xt(Poe);_t.prototype.visitTimestampNanosecond=xt(Ooe);_t.prototype.visitTime=xt(fGe);_t.prototype.visitTimeSecond=xt(Roe);_t.prototype.visitTimeMillisecond=xt(Noe);_t.prototype.visitTimeMicrosecond=xt(koe);_t.prototype.visitTimeNanosecond=xt(Doe);_t.prototype.visitDecimal=xt(dGe);_t.prototype.visitList=xt(hGe);_t.prototype.visitStruct=xt(mGe);_t.prototype.visitUnion=xt(gGe);_t.prototype.visitDenseUnion=xt($oe);_t.prototype.visitSparseUnion=xt(Loe);_t.prototype.visitDictionary=xt(yGe);_t.prototype.visitInterval=xt(vGe);_t.prototype.visitIntervalDayTime=xt(Moe);_t.prototype.visitIntervalYearMonth=xt(Foe);_t.prototype.visitDuration=xt(_Ge);_t.prototype.visitDurationSecond=xt(Boe);_t.prototype.visitDurationMillisecond=xt(joe);_t.prototype.visitDurationMicrosecond=xt(Uoe);_t.prototype.visitDurationNanosecond=xt(Voe);_t.prototype.visitFixedSizeList=xt(bGe);_t.prototype.visitMap=xt(pGe);const oo=new _t,La=Symbol.for("keys"),mm=Symbol.for("vals");class jC{constructor(t){return this[La]=new Sn([t.children[0]]).memoize(),this[mm]=t.children[1],new Proxy(this,new EGe)}[Symbol.iterator](){return new wGe(this[La],this[mm])}get size(){return this[La].length}toArray(){return Object.values(this.toJSON())}toJSON(){const t=this[La],n=this[mm],r={};for(let i=-1,s=t.length;++i`${vh(t)}: ${vh(n)}`).join(", ")}}`}[Symbol.for("nodejs.util.inspect.custom")](){return this.toString()}}class wGe{constructor(t,n){this.keys=t,this.vals=n,this.keyIndex=0,this.numKeys=t.length}[Symbol.iterator](){return this}next(){const t=this.keyIndex;return t===this.numKeys?{done:!0,value:null}:(this.keyIndex++,{done:!1,value:[this.keys.get(t),oo.visit(this.vals,t)]})}}class EGe{isExtensible(){return!1}deleteProperty(){return!1}preventExtensions(){return!0}ownKeys(t){return t[La].toArray().map(String)}has(t,n){return t[La].includes(n)}getOwnPropertyDescriptor(t,n){if(t[La].indexOf(n)!==-1)return{writable:!0,enumerable:!0,configurable:!0}}get(t,n){if(Reflect.has(t,n))return t[n];const r=t[La].indexOf(n);if(r!==-1){const i=oo.visit(Reflect.get(t,mm),r);return Reflect.set(t,n,i),i}}set(t,n,r){const i=t[La].indexOf(n);return i!==-1?(ca.visit(Reflect.get(t,mm),i,r),Reflect.set(t,n,r)):Reflect.has(t,n)?Reflect.set(t,n,r):!1}}Object.defineProperties(jC.prototype,{[Symbol.toStringTag]:{enumerable:!1,configurable:!1,value:"Row"},[La]:{writable:!0,enumerable:!1,configurable:!1,value:null},[mm]:{writable:!0,enumerable:!1,configurable:!1,value:null}});let Rz;function zoe(e,t,n,r){const{length:i=0}=e;let s=typeof t!="number"?0:t,o=typeof n!="number"?i:n;return s<0&&(s=(s%i+i)%i),o<0&&(o=(o%i+i)%i),oi&&(o=i),r?r(e,s,o):[s,o]}const Nz=e=>e!==e;function Dg(e){if(typeof e!=="object"||e===null)return Nz(e)?Nz:n=>n===e;if(e instanceof Date){const n=e.valueOf();return r=>r instanceof Date?r.valueOf()===n:!1}return ArrayBuffer.isView(e)?n=>n?dqe(e,n):!1:e instanceof Map?TGe(e):Array.isArray(e)?SGe(e):e instanceof Sn?IGe(e):xGe(e,!0)}function SGe(e){const t=[];for(let n=-1,r=e.length;++n!1;const r=[];for(let i=-1,s=n.length;++i{if(!n||typeof n!="object")return!1;switch(n.constructor){case Array:return CGe(e,n);case Map:return kz(e,n,n.keys());case jC:case CL:case Object:case void 0:return kz(e,n,t||Object.keys(n))}return n instanceof Sn?AGe(e,n):!1}}function CGe(e,t){const n=e.length;if(t.length!==n)return!1;for(let r=-1;++r>r}function fI(e,t,n){const r=n.byteLength+7&-8;if(e>0||n.byteLength>3):Woe(new PL(n,e,t,null,Hoe)).subarray(0,r)),i}return n}function Woe(e){const t=[];let n=0,r=0,i=0;for(const o of e)o&&(i|=1<0)&&(t[n++]=i);const s=new Uint8Array(t.length+7&-8);return s.set(t),s}class PL{constructor(t,n,r,i,s){this.bytes=t,this.length=r,this.context=i,this.get=s,this.bit=n%8,this.byteIndex=n>>3,this.byte=t[this.byteIndex++],this.index=0}next(){return this.index>3<<3,i=t+(t%8===0?0:8-t%8);return ok(e,t,i)+ok(e,r,n)+OGe(e,i>>3,r-i>>3)}function OGe(e,t,n){let r=0,i=Math.trunc(t);const s=new DataView(e.buffer,e.byteOffset,e.byteLength),o=n===void 0?e.byteLength:i+n;for(;o-i>=4;)r+=XO(s.getUint32(i)),i+=4;for(;o-i>=2;)r+=XO(s.getUint16(i)),i+=2;for(;o-i>=1;)r+=XO(s.getUint8(i)),i+=1;return r}function XO(e){let t=Math.trunc(e);return t=t-(t>>>1&1431655765),t=(t&858993459)+(t>>>2&858993459),(t+(t>>>4)&252645135)*16843009>>>24}const RGe=-1;class Ln{get typeId(){return this.type.typeId}get ArrayType(){return this.type.ArrayType}get buffers(){return[this.valueOffsets,this.values,this.nullBitmap,this.typeIds]}get nullable(){if(this._nullCount!==0){const{type:t}=this;return Bt.isSparseUnion(t)?this.children.some(n=>n.nullable):Bt.isDenseUnion(t)?this.children.some(n=>n.nullable):this.nullBitmap&&this.nullBitmap.byteLength>0}return!0}get byteLength(){let t=0;const{valueOffsets:n,values:r,nullBitmap:i,typeIds:s}=this;return n&&(t+=n.byteLength),r&&(t+=r.byteLength),i&&(t+=i.byteLength),s&&(t+=s.byteLength),this.children.reduce((o,a)=>o+a.byteLength,t)}get nullCount(){if(Bt.isUnion(this.type))return this.children.reduce((r,i)=>r+i.nullCount,0);let t=this._nullCount,n;return t<=RGe&&(n=this.nullBitmap)&&(this._nullCount=t=this.length-ok(n,this.offset,this.offset+this.length)),t}constructor(t,n,r,i,s,o=[],a){this.type=t,this.children=o,this.dictionary=a,this.offset=Math.floor(Math.max(n||0,0)),this.length=Math.floor(Math.max(r||0,0)),this._nullCount=Math.floor(Math.max(i||0,-1));let u;s instanceof Ln?(this.stride=s.stride,this.values=s.values,this.typeIds=s.typeIds,this.nullBitmap=s.nullBitmap,this.valueOffsets=s.valueOffsets):(this.stride=pu(t),s&&((u=s[0])&&(this.valueOffsets=u),(u=s[1])&&(this.values=u),(u=s[2])&&(this.nullBitmap=u),(u=s[3])&&(this.typeIds=u)))}getValid(t){const{type:n}=this;if(Bt.isUnion(n)){const r=n,i=this.children[r.typeIdToChildIndex[this.typeIds[t]]],s=r.mode===so.Dense?this.valueOffsets[t]:t;return i.getValid(s)}if(this.nullable&&this.nullCount>0){const r=this.offset+t;return(this.nullBitmap[r>>3]&1<>3;(!s||s.byteLength<=c)&&(s=new Uint8Array((o+a+63&-64)>>3).fill(255),this.nullCount>0&&s.set(fI(o,a,this.nullBitmap),0),Object.assign(this,{nullBitmap:s,_nullCount:-1}));const f=s[c];r=(f&l)!==0,n?s[c]=f|l:s[c]=f&~l}return r!==!!n&&(this._nullCount=this.nullCount+(n?-1:1)),n}clone(t=this.type,n=this.offset,r=this.length,i=this._nullCount,s=this,o=this.children){return new Ln(t,n,r,i,s,o,this.dictionary)}slice(t,n){const{stride:r,typeId:i,children:s}=this,o=+(this._nullCount===0)-1,a=i===16?r:1,u=this._sliceBuffers(t,n,r,i);return this.clone(this.type,this.offset+t,n,o,u,s.length===0||this.valueOffsets?s:this._sliceChildren(s,a*t,a*n))}_changeLengthAndBackfillNullBitmap(t){if(this.typeId===G.Null)return this.clone(this.type,0,t,0);const{length:n,nullCount:r}=this,i=new Uint8Array((t+63&-64)>>3).fill(255,0,n>>3);i[n>>3]=(1<0&&i.set(fI(this.offset,n,this.nullBitmap),0);const s=this.buffers;return s[_l.VALIDITY]=i,this.clone(this.type,0,t,r+(t-n),s)}_sliceBuffers(t,n,r,i){let s;const{buffers:o}=this;return(s=o[_l.TYPE])&&(o[_l.TYPE]=s.subarray(t,t+n)),(s=o[_l.OFFSET])&&(o[_l.OFFSET]=s.subarray(t,t+n+1))||(s=o[_l.DATA])&&(o[_l.DATA]=i===6?s:s.subarray(r*t,r*(t+n))),o}_sliceChildren(t,n,r){return t.map(i=>i.slice(n,r))}}Ln.prototype.children=Object.freeze([]);class Fy extends qt{visit(t){return this.getVisitFn(t.type).call(this,t)}visitNull(t){const{["type"]:n,["offset"]:r=0,["length"]:i=0}=t;return new Ln(n,r,i,i)}visitBool(t){const{["type"]:n,["offset"]:r=0}=t,i=Mn(t.nullBitmap),s=fi(n.ArrayType,t.data),{["length"]:o=s.length>>3,["nullCount"]:a=t.nullBitmap?-1:0}=t;return new Ln(n,r,o,a,[void 0,s,i])}visitInt(t){const{["type"]:n,["offset"]:r=0}=t,i=Mn(t.nullBitmap),s=fi(n.ArrayType,t.data),{["length"]:o=s.length,["nullCount"]:a=t.nullBitmap?-1:0}=t;return new Ln(n,r,o,a,[void 0,s,i])}visitFloat(t){const{["type"]:n,["offset"]:r=0}=t,i=Mn(t.nullBitmap),s=fi(n.ArrayType,t.data),{["length"]:o=s.length,["nullCount"]:a=t.nullBitmap?-1:0}=t;return new Ln(n,r,o,a,[void 0,s,i])}visitUtf8(t){const{["type"]:n,["offset"]:r=0}=t,i=Mn(t.data),s=Mn(t.nullBitmap),o=k0(t.valueOffsets),{["length"]:a=o.length-1,["nullCount"]:u=t.nullBitmap?-1:0}=t;return new Ln(n,r,a,u,[o,i,s])}visitBinary(t){const{["type"]:n,["offset"]:r=0}=t,i=Mn(t.data),s=Mn(t.nullBitmap),o=k0(t.valueOffsets),{["length"]:a=o.length-1,["nullCount"]:u=t.nullBitmap?-1:0}=t;return new Ln(n,r,a,u,[o,i,s])}visitFixedSizeBinary(t){const{["type"]:n,["offset"]:r=0}=t,i=Mn(t.nullBitmap),s=fi(n.ArrayType,t.data),{["length"]:o=s.length/pu(n),["nullCount"]:a=t.nullBitmap?-1:0}=t;return new Ln(n,r,o,a,[void 0,s,i])}visitDate(t){const{["type"]:n,["offset"]:r=0}=t,i=Mn(t.nullBitmap),s=fi(n.ArrayType,t.data),{["length"]:o=s.length/pu(n),["nullCount"]:a=t.nullBitmap?-1:0}=t;return new Ln(n,r,o,a,[void 0,s,i])}visitTimestamp(t){const{["type"]:n,["offset"]:r=0}=t,i=Mn(t.nullBitmap),s=fi(n.ArrayType,t.data),{["length"]:o=s.length/pu(n),["nullCount"]:a=t.nullBitmap?-1:0}=t;return new Ln(n,r,o,a,[void 0,s,i])}visitTime(t){const{["type"]:n,["offset"]:r=0}=t,i=Mn(t.nullBitmap),s=fi(n.ArrayType,t.data),{["length"]:o=s.length/pu(n),["nullCount"]:a=t.nullBitmap?-1:0}=t;return new Ln(n,r,o,a,[void 0,s,i])}visitDecimal(t){const{["type"]:n,["offset"]:r=0}=t,i=Mn(t.nullBitmap),s=fi(n.ArrayType,t.data),{["length"]:o=s.length/pu(n),["nullCount"]:a=t.nullBitmap?-1:0}=t;return new Ln(n,r,o,a,[void 0,s,i])}visitList(t){const{["type"]:n,["offset"]:r=0,["child"]:i}=t,s=Mn(t.nullBitmap),o=k0(t.valueOffsets),{["length"]:a=o.length-1,["nullCount"]:u=t.nullBitmap?-1:0}=t;return new Ln(n,r,a,u,[o,void 0,s],[i])}visitStruct(t){const{["type"]:n,["offset"]:r=0,["children"]:i=[]}=t,s=Mn(t.nullBitmap),{length:o=i.reduce((u,{length:l})=>Math.max(u,l),0),nullCount:a=t.nullBitmap?-1:0}=t;return new Ln(n,r,o,a,[void 0,void 0,s],i)}visitUnion(t){const{["type"]:n,["offset"]:r=0,["children"]:i=[]}=t,s=fi(n.ArrayType,t.typeIds),{["length"]:o=s.length,["nullCount"]:a=-1}=t;if(Bt.isSparseUnion(n))return new Ln(n,r,o,a,[void 0,void 0,void 0,s],i);const u=k0(t.valueOffsets);return new Ln(n,r,o,a,[u,void 0,void 0,s],i)}visitDictionary(t){const{["type"]:n,["offset"]:r=0}=t,i=Mn(t.nullBitmap),s=fi(n.indices.ArrayType,t.data),{["dictionary"]:o=new Sn([new Fy().visit({type:n.dictionary})])}=t,{["length"]:a=s.length,["nullCount"]:u=t.nullBitmap?-1:0}=t;return new Ln(n,r,a,u,[void 0,s,i],[],o)}visitInterval(t){const{["type"]:n,["offset"]:r=0}=t,i=Mn(t.nullBitmap),s=fi(n.ArrayType,t.data),{["length"]:o=s.length/pu(n),["nullCount"]:a=t.nullBitmap?-1:0}=t;return new Ln(n,r,o,a,[void 0,s,i])}visitDuration(t){const{["type"]:n,["offset"]:r=0}=t,i=Mn(t.nullBitmap),s=fi(n.ArrayType,t.data),{["length"]:o=s.length,["nullCount"]:a=t.nullBitmap?-1:0}=t;return new Ln(n,r,o,a,[void 0,s,i])}visitFixedSizeList(t){const{["type"]:n,["offset"]:r=0,["child"]:i=new Fy().visit({type:n.valueType})}=t,s=Mn(t.nullBitmap),{["length"]:o=i.length/pu(n),["nullCount"]:a=t.nullBitmap?-1:0}=t;return new Ln(n,r,o,a,[void 0,void 0,s],[i])}visitMap(t){const{["type"]:n,["offset"]:r=0,["child"]:i=new Fy().visit({type:n.childType})}=t,s=Mn(t.nullBitmap),o=k0(t.valueOffsets),{["length"]:a=o.length-1,["nullCount"]:u=t.nullBitmap?-1:0}=t;return new Ln(n,r,a,u,[o,void 0,s],[i])}}const NGe=new Fy;function Ji(e){return NGe.visit(e)}class Dz{constructor(t=0,n){this.numChunks=t,this.getChunkIterator=n,this.chunkIndex=0,this.chunkIterator=this.getChunkIterator(0)}next(){for(;this.chunkIndext+n.nullCount,0)}function Goe(e){return e.reduce((t,n,r)=>(t[r+1]=t[r]+n.length,t),new Uint32Array(e.length+1))}function Yoe(e,t,n,r){const i=[];for(let s=-1,o=e.length;++s=r)break;if(n>=u+l)continue;if(u>=n&&u+l<=r){i.push(a);continue}const c=Math.max(0,n-u),f=Math.min(r-u,l);i.push(a.slice(c,f-c))}return i.length===0&&i.push(e[0].slice(0,0)),i}function OL(e,t,n,r){let i=0,s=0,o=t.length-1;do{if(i>=o-1)return n0?0:-1}function DGe(e,t){const{nullBitmap:n}=e;if(!n||e.nullCount<=0)return-1;let r=0;for(const i of new PL(n,e.offset+(t||0),e.length,n,Hoe)){if(!i)return r;++r}return-1}function $t(e,t,n){if(t===void 0)return-1;if(t===null)switch(e.typeId){case G.Union:break;case G.Dictionary:break;default:return DGe(e,n)}const r=oo.getVisitFn(e),i=Dg(t);for(let s=(n||0)-1,o=e.length;++s{const i=e.data[r];return i.values.subarray(0,i.length)[Symbol.iterator]()});let n=0;return new Dz(e.data.length,r=>{const s=e.data[r].length,o=e.slice(n,n+s);return n+=s,new $Ge(o)})}class $Ge{constructor(t){this.vector=t,this.index=0}next(){return this.indexe+t;class td extends qt{visitNull(t,n){return 0}visitInt(t,n){return t.type.bitWidth/8}visitFloat(t,n){return t.type.ArrayType.BYTES_PER_ELEMENT}visitBool(t,n){return 1/8}visitDecimal(t,n){return t.type.bitWidth/8}visitDate(t,n){return(t.type.unit+1)*4}visitTime(t,n){return t.type.bitWidth/8}visitTimestamp(t,n){return t.type.unit===vt.SECOND?4:8}visitInterval(t,n){return(t.type.unit+1)*4}visitDuration(t,n){return 8}visitStruct(t,n){return t.children.reduce((r,i)=>r+il.visit(i,n),0)}visitFixedSizeBinary(t,n){return t.type.byteWidth}visitMap(t,n){return 8+t.children.reduce((r,i)=>r+il.visit(i,n),0)}visitDictionary(t,n){var r;return t.type.indices.bitWidth/8+(((r=t.dictionary)===null||r===void 0?void 0:r.getByteLength(t.values[n]))||0)}}const MGe=({valueOffsets:e},t)=>8+(e[t+1]-e[t]),FGe=({valueOffsets:e},t)=>8+(e[t+1]-e[t]),BGe=({valueOffsets:e,stride:t,children:n},r)=>{const i=n[0],{[r*t]:s}=e,{[r*t+1]:o}=e,a=il.getVisitFn(i.type),u=i.slice(s,o-s);let l=8;for(let c=-1,f=o-s;++c{const r=t[0],i=r.slice(n*e,e),s=il.getVisitFn(r.type);let o=0;for(let a=-1,u=i.length;++ae.type.mode===so.Dense?Joe(e,t):Zoe(e,t),Joe=({type:e,children:t,typeIds:n,valueOffsets:r},i)=>{const s=e.typeIdToChildIndex[n[i]];return 8+il.visit(t[s],r[i])},Zoe=({children:e},t)=>4+il.visitMany(e,e.map(()=>t)).reduce(LGe,0);td.prototype.visitUtf8=MGe;td.prototype.visitBinary=FGe;td.prototype.visitList=BGe;td.prototype.visitFixedSizeList=jGe;td.prototype.visitUnion=UGe;td.prototype.visitDenseUnion=Joe;td.prototype.visitSparseUnion=Zoe;const il=new td;var eae;const tae={},nae={};class Sn{constructor(t){var n,r,i;const s=t[0]instanceof Sn?t.flatMap(a=>a.data):t;if(s.length===0||s.some(a=>!(a instanceof Ln)))throw new TypeError("Vector constructor expects an Array of Data instances.");const o=(n=s[0])===null||n===void 0?void 0:n.type;switch(s.length){case 0:this._offsets=[0];break;case 1:{const{get:a,set:u,indexOf:l,byteLength:c}=tae[o.typeId],f=s[0];this.isValid=d=>RL(f,d),this.get=d=>a(f,d),this.set=(d,h)=>u(f,d,h),this.indexOf=d=>l(f,d),this.getByteLength=d=>c(f,d),this._offsets=[0,f.length];break}default:Object.setPrototypeOf(this,nae[o.typeId]),this._offsets=Goe(s);break}this.data=s,this.type=o,this.stride=pu(o),this.numChildren=(i=(r=o.children)===null||r===void 0?void 0:r.length)!==null&&i!==void 0?i:0,this.length=this._offsets.at(-1)}get byteLength(){return this.data.reduce((t,n)=>t+n.byteLength,0)}get nullCount(){return qoe(this.data)}get ArrayType(){return this.type.ArrayType}get[Symbol.toStringTag](){return`${this.VectorName}<${this.type[Symbol.toStringTag]}>`}get VectorName(){return`${G[this.type.typeId]}Vector`}isValid(t){return!1}get(t){return null}set(t,n){}indexOf(t,n){return-1}includes(t,n){return this.indexOf(t,n)>-1}getByteLength(t){return 0}[Symbol.iterator](){return NL.visit(this)}concat(...t){return new Sn(this.data.concat(t.flatMap(n=>n.data).flat(Number.POSITIVE_INFINITY)))}slice(t,n){return new Sn(zoe(this,t,n,({data:r,_offsets:i},s,o)=>Yoe(r,i,s,o)))}toJSON(){return[...this]}toArray(){const{type:t,data:n,length:r,stride:i,ArrayType:s}=this;switch(t.typeId){case G.Int:case G.Float:case G.Decimal:case G.Time:case G.Timestamp:switch(n.length){case 0:return new s;case 1:return n[0].values.subarray(0,r*i);default:return n.reduce((o,{values:a,length:u})=>(o.array.set(a.subarray(0,u*i),o.offset),o.offset+=u*i,o),{array:new s(r*i),offset:0}).array}}return[...this]}toString(){return`[${[...this].join(",")}]`}getChild(t){var n;return this.getChildAt((n=this.type.children)===null||n===void 0?void 0:n.findIndex(r=>r.name===t))}getChildAt(t){return t>-1&&tn[t])):null}get isMemoized(){return Bt.isDictionary(this.type)?this.data[0].dictionary.isMemoized:!1}memoize(){if(Bt.isDictionary(this.type)){const t=new hI(this.data[0].dictionary),n=this.data.map(r=>{const i=r.clone();return i.dictionary=t,i});return new Sn(n)}return new hI(this)}unmemoize(){if(Bt.isDictionary(this.type)&&this.isMemoized){const t=this.data[0].dictionary.unmemoize(),n=this.data.map(r=>{const i=r.clone();return i.dictionary=t,i});return new Sn(n)}return this}}eae=Symbol.toStringTag;Sn[eae]=(e=>{e.type=Bt.prototype,e.data=[],e.length=0,e.stride=1,e.numChildren=0,e._offsets=new Uint32Array([0]),e[Symbol.isConcatSpreadable]=!0;const t=Object.keys(G).map(n=>G[n]).filter(n=>typeof n=="number"&&n!==G.NONE);for(const n of t){const r=oo.getVisitFnByTypeId(n),i=ca.getVisitFnByTypeId(n),s=dI.getVisitFnByTypeId(n),o=il.getVisitFnByTypeId(n);tae[n]={get:r,set:i,indexOf:s,byteLength:o},nae[n]=Object.create(e,{isValid:{value:gm(RL)},get:{value:gm(oo.getVisitFnByTypeId(n))},set:{value:Koe(ca.getVisitFnByTypeId(n))},indexOf:{value:Qoe(dI.getVisitFnByTypeId(n))},getByteLength:{value:gm(il.getVisitFnByTypeId(n))}})}return"Vector"})(Sn.prototype);class hI extends Sn{constructor(t){super(t.data);const n=this.get,r=this.set,i=this.slice,s=new Array(this.length);Object.defineProperty(this,"get",{value(o){const a=s[o];if(a!==void 0)return a;const u=n.call(this,o);return s[o]=u,u}}),Object.defineProperty(this,"set",{value(o,a){r.call(this,o,a),s[o]=a}}),Object.defineProperty(this,"slice",{value:(o,a)=>new hI(i.call(this,o,a))}),Object.defineProperty(this,"isMemoized",{value:!0}),Object.defineProperty(this,"unmemoize",{value:()=>new Sn(this.data)}),Object.defineProperty(this,"memoize",{value:()=>this})}}function VGe(e){if(!e||e.length<=0)return function(i){return!0};let t="";const n=e.filter(r=>r===r);return n.length>0&&(t=` switch (x) {${n.map(r=>` - case ${VGe(r)}:`).join("")} + case ${zGe(r)}:`).join("")} return false; }`),e.length!==n.length&&(t=`if (x !== x) return false; ${t}`),new Function("x",`${t} -return true;`)}function VGe(e){return typeof e!="bigint"?vh(e):`${vh(e)}n`}const ZO=(e,t)=>(Math.ceil(e)*t+63&-64||64)/t,zGe=(e,t=0)=>e.length>=t?e.subarray(0,t):oI(new e.constructor(t),e,0);class VC{constructor(t,n=1){this.buffer=t,this.stride=n,this.BYTES_PER_ELEMENT=t.BYTES_PER_ELEMENT,this.ArrayType=t.constructor,this._resize(this.length=Math.ceil(t.length/n))}get byteLength(){return Math.ceil(this.length*this.stride)*this.BYTES_PER_ELEMENT}get reservedLength(){return this.buffer.length/this.stride}get reservedByteLength(){return this.buffer.byteLength}set(t,n){return this}append(t){return this.set(this.length,t)}reserve(t){if(t>0){this.length+=t;const n=this.stride,r=this.length*n,i=this.buffer.length;r>=i&&this._resize(i===0?ZO(r*1,this.BYTES_PER_ELEMENT):ZO(r*2,this.BYTES_PER_ELEMENT))}return this}flush(t=this.length){t=ZO(t*this.stride,this.BYTES_PER_ELEMENT);const n=zGe(this.buffer,t);return this.clear(),n}clear(){return this.length=0,this._resize(0),this}_resize(t){return this.buffer=oI(new this.ArrayType(t),this.buffer)}}VC.prototype.offset=0;class s1 extends VC{last(){return this.get(this.length-1)}get(t){return this.buffer[t]}set(t,n){return this.reserve(t-this.length+1),this.buffer[t*this.stride]=n,this}}class rae extends s1{constructor(t=new Uint8Array(0)){super(t,1/8),this.numValid=0}get numInvalid(){return this.length-this.numValid}get(t){return this.buffer[t>>3]>>t%8&1}set(t,n){const{buffer:r}=this.reserve(t-this.length+1),i=t>>3,s=t%8,o=r[i]>>s&1;return n?o===0&&(r[i]|=1<this.length&&this.set(t-1,0),super.flush(t+1)}}let uo=class{static throughNode(t){throw new Error('"throughNode" not available in this environment')}static throughDOM(t){throw new Error('"throughDOM" not available in this environment')}constructor({type:t,nullValues:n}){this.length=0,this.finished=!1,this.type=t,this.children=[],this.nullValues=n,this.stride=pu(t),this._nulls=new rae,n&&n.length>0&&(this._isValid=UGe(n))}toVector(){return new Sn([this.flush()])}get ArrayType(){return this.type.ArrayType}get nullCount(){return this._nulls.numInvalid}get numChildren(){return this.children.length}get byteLength(){let t=0;const{_offsets:n,_values:r,_nulls:i,_typeIds:s,children:o}=this;return n&&(t+=n.byteLength),r&&(t+=r.byteLength),i&&(t+=i.byteLength),s&&(t+=s.byteLength),o.reduce((a,u)=>a+u.byteLength,t)}get reservedLength(){return this._nulls.reservedLength}get reservedByteLength(){let t=0;return this._offsets&&(t+=this._offsets.reservedByteLength),this._values&&(t+=this._values.reservedByteLength),this._nulls&&(t+=this._nulls.reservedByteLength),this._typeIds&&(t+=this._typeIds.reservedByteLength),this.children.reduce((n,r)=>n+r.reservedByteLength,t)}get valueOffsets(){return this._offsets?this._offsets.buffer:null}get values(){return this._values?this._values.buffer:null}get nullBitmap(){return this._nulls?this._nulls.buffer:null}get typeIds(){return this._typeIds?this._typeIds.buffer:null}append(t){return this.set(this.length,t)}isValid(t){return this._isValid(t)}set(t,n){return this.setValid(t,this.isValid(n))&&this.setValue(t,n),this}setValue(t,n){this._setValue(this,t,n)}setValid(t,n){return this.length=this._nulls.set(t,+n).length,n}addChild(t,n=`${this.numChildren}`){throw new Error(`Cannot append children to non-nested type "${this.type}"`)}getChildAt(t){return this.children[t]||null}flush(){let t,n,r,i;const{type:s,length:o,nullCount:a,_typeIds:u,_offsets:l,_values:c,_nulls:f}=this;(n=u==null?void 0:u.flush(o))?i=l==null?void 0:l.flush(o):(i=l==null?void 0:l.flush(o))?t=c==null?void 0:c.flush(l.last()):t=c==null?void 0:c.flush(o),a>0&&(r=f==null?void 0:f.flush(o));const d=this.children.map(h=>h.flush());return this.clear(),Ji({type:s,length:o,nullCount:a,children:d,child:d[0],data:t,typeIds:n,nullBitmap:r,valueOffsets:i})}finish(){this.finished=!0;for(const t of this.children)t.finish();return this}clear(){var t,n,r,i;this.length=0,(t=this._nulls)===null||t===void 0||t.clear(),(n=this._values)===null||n===void 0||n.clear(),(r=this._offsets)===null||r===void 0||r.clear(),(i=this._typeIds)===null||i===void 0||i.clear();for(const s of this.children)s.clear();return this}};uo.prototype.length=1;uo.prototype.stride=1;uo.prototype.children=null;uo.prototype.finished=!1;uo.prototype.nullValues=null;uo.prototype._isValid=()=>!0;class pc extends uo{constructor(t){super(t),this._values=new s1(new this.ArrayType(0),this.stride)}setValue(t,n){const r=this._values;return r.reserve(t-r.length+1),super.setValue(t,n)}}class zC extends uo{constructor(t){super(t),this._pendingLength=0,this._offsets=new iae}setValue(t,n){const r=this._pending||(this._pending=new Map),i=r.get(t);i&&(this._pendingLength-=i.length),this._pendingLength+=n instanceof jC?n[La].length:n.length,r.set(t,n)}setValid(t,n){return super.setValid(t,n)?!0:((this._pending||(this._pending=new Map)).set(t,void 0),!1)}clear(){return this._pendingLength=0,this._pending=void 0,super.clear()}flush(){return this._flush(),super.flush()}finish(){return this._flush(),super.finish()}_flush(){const t=this._pending,n=this._pendingLength;return this._pendingLength=0,this._pending=void 0,t&&t.size>0&&this._flushPending(t,n),this}}class uk{constructor(){this.bb=null,this.bb_pos=0}__init(t,n){return this.bb_pos=t,this.bb=n,this}offset(){return this.bb.readInt64(this.bb_pos)}metaDataLength(){return this.bb.readInt32(this.bb_pos+8)}bodyLength(){return this.bb.readInt64(this.bb_pos+16)}static sizeOf(){return 24}static createBlock(t,n,r,i){return t.prep(8,24),t.writeInt64(BigInt(i??0)),t.pad(4),t.writeInt32(r),t.writeInt64(BigInt(n??0)),t.offset()}}const e2=2,wu=4,xl=4,Wn=4,Lc=new Int32Array(2),$z=new Float32Array(Lc.buffer),Lz=new Float64Array(Lc.buffer),Bb=new Uint16Array(new Uint8Array([1,0]).buffer)[0]===1;var lk;(function(e){e[e.UTF8_BYTES=1]="UTF8_BYTES",e[e.UTF16_STRING=2]="UTF16_STRING"})(lk||(lk={}));let pI=class sae{constructor(t){this.bytes_=t,this.position_=0,this.text_decoder_=new TextDecoder}static allocate(t){return new sae(new Uint8Array(t))}clear(){this.position_=0}bytes(){return this.bytes_}position(){return this.position_}setPosition(t){this.position_=t}capacity(){return this.bytes_.length}readInt8(t){return this.readUint8(t)<<24>>24}readUint8(t){return this.bytes_[t]}readInt16(t){return this.readUint16(t)<<16>>16}readUint16(t){return this.bytes_[t]|this.bytes_[t+1]<<8}readInt32(t){return this.bytes_[t]|this.bytes_[t+1]<<8|this.bytes_[t+2]<<16|this.bytes_[t+3]<<24}readUint32(t){return this.readInt32(t)>>>0}readInt64(t){return BigInt.asIntN(64,BigInt(this.readUint32(t))+(BigInt(this.readUint32(t+4))<>8}writeUint16(t,n){this.bytes_[t]=n,this.bytes_[t+1]=n>>8}writeInt32(t,n){this.bytes_[t]=n,this.bytes_[t+1]=n>>8,this.bytes_[t+2]=n>>16,this.bytes_[t+3]=n>>24}writeUint32(t,n){this.bytes_[t]=n,this.bytes_[t+1]=n>>8,this.bytes_[t+2]=n>>16,this.bytes_[t+3]=n>>24}writeInt64(t,n){this.writeInt32(t,Number(BigInt.asIntN(32,n))),this.writeInt32(t+4,Number(BigInt.asIntN(32,n>>BigInt(32))))}writeUint64(t,n){this.writeUint32(t,Number(BigInt.asUintN(32,n))),this.writeUint32(t+4,Number(BigInt.asUintN(32,n>>BigInt(32))))}writeFloat32(t,n){$z[0]=n,this.writeInt32(t,Lc[0])}writeFloat64(t,n){Lz[0]=n,this.writeInt32(t,Lc[Bb?0:1]),this.writeInt32(t+4,Lc[Bb?1:0])}getBufferIdentifier(){if(this.bytes_.lengththis.minalign&&(this.minalign=t);const r=~(this.bb.capacity()-this.space+n)+1&t-1;for(;this.space=0&&this.vtable[n]==0;n--);const r=n+1;for(;n>=0;n--)this.addInt16(this.vtable[n]!=0?t-this.vtable[n]:0);const i=2;this.addInt16(t-this.object_start);const s=(r+i)*e2;this.addInt16(s);let o=0;const a=this.space;e:for(n=0;n=0;o--)this.writeInt8(s.charCodeAt(o))}this.prep(this.minalign,wu+i),this.addOffset(t),i&&this.addInt32(this.bb.capacity()-this.space),this.bb.setPosition(this.space)}finishSizePrefixed(t,n){this.finish(t,n,!0)}requiredField(t,n){const r=this.bb.capacity()-t,i=r-this.bb.readInt32(r);if(!(n=0;r--)t.addInt32(n[r]);return t.endVector()}static startTypeIdsVector(t,n){t.startVector(4,n,4)}static endUnion(t){return t.endObject()}static createUnion(t,n,r){return js.startUnion(t),js.addMode(t,n),js.addTypeIds(t,r),js.endUnion(t)}}class Hd{constructor(){this.bb=null,this.bb_pos=0}__init(t,n){return this.bb_pos=t,this.bb=n,this}static getRootAsUtf8(t,n){return(n||new Hd).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsUtf8(t,n){return t.setPosition(t.position()+Wn),(n||new Hd).__init(t.readInt32(t.position())+t.position(),t)}static startUtf8(t){t.startObject(0)}static endUtf8(t){return t.endObject()}static createUtf8(t){return Hd.startUtf8(t),Hd.endUtf8(t)}}var cr;(function(e){e[e.NONE=0]="NONE",e[e.Null=1]="Null",e[e.Int=2]="Int",e[e.FloatingPoint=3]="FloatingPoint",e[e.Binary=4]="Binary",e[e.Utf8=5]="Utf8",e[e.Bool=6]="Bool",e[e.Decimal=7]="Decimal",e[e.Date=8]="Date",e[e.Time=9]="Time",e[e.Timestamp=10]="Timestamp",e[e.Interval=11]="Interval",e[e.List=12]="List",e[e.Struct_=13]="Struct_",e[e.Union=14]="Union",e[e.FixedSizeBinary=15]="FixedSizeBinary",e[e.FixedSizeList=16]="FixedSizeList",e[e.Map=17]="Map",e[e.Duration=18]="Duration",e[e.LargeBinary=19]="LargeBinary",e[e.LargeUtf8=20]="LargeUtf8",e[e.LargeList=21]="LargeList",e[e.RunEndEncoded=22]="RunEndEncoded"})(cr||(cr={}));let Uo=class Ww{constructor(){this.bb=null,this.bb_pos=0}__init(t,n){return this.bb_pos=t,this.bb=n,this}static getRootAsField(t,n){return(n||new Ww).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsField(t,n){return t.setPosition(t.position()+Wn),(n||new Ww).__init(t.readInt32(t.position())+t.position(),t)}name(t){const n=this.bb.__offset(this.bb_pos,4);return n?this.bb.__string(this.bb_pos+n,t):null}nullable(){const t=this.bb.__offset(this.bb_pos,6);return t?!!this.bb.readInt8(this.bb_pos+t):!1}typeType(){const t=this.bb.__offset(this.bb_pos,8);return t?this.bb.readUint8(this.bb_pos+t):cr.NONE}type(t){const n=this.bb.__offset(this.bb_pos,10);return n?this.bb.__union(t,this.bb_pos+n):null}dictionary(t){const n=this.bb.__offset(this.bb_pos,12);return n?(t||new Cl).__init(this.bb.__indirect(this.bb_pos+n),this.bb):null}children(t,n){const r=this.bb.__offset(this.bb_pos,14);return r?(n||new Ww).__init(this.bb.__indirect(this.bb.__vector(this.bb_pos+r)+t*4),this.bb):null}childrenLength(){const t=this.bb.__offset(this.bb_pos,14);return t?this.bb.__vector_len(this.bb_pos+t):0}customMetadata(t,n){const r=this.bb.__offset(this.bb_pos,16);return r?(n||new Zr).__init(this.bb.__indirect(this.bb.__vector(this.bb_pos+r)+t*4),this.bb):null}customMetadataLength(){const t=this.bb.__offset(this.bb_pos,16);return t?this.bb.__vector_len(this.bb_pos+t):0}static startField(t){t.startObject(7)}static addName(t,n){t.addFieldOffset(0,n,0)}static addNullable(t,n){t.addFieldInt8(1,+n,0)}static addTypeType(t,n){t.addFieldInt8(2,n,cr.NONE)}static addType(t,n){t.addFieldOffset(3,n,0)}static addDictionary(t,n){t.addFieldOffset(4,n,0)}static addChildren(t,n){t.addFieldOffset(5,n,0)}static createChildrenVector(t,n){t.startVector(4,n.length,4);for(let r=n.length-1;r>=0;r--)t.addOffset(n[r]);return t.endVector()}static startChildrenVector(t,n){t.startVector(4,n,4)}static addCustomMetadata(t,n){t.addFieldOffset(6,n,0)}static createCustomMetadataVector(t,n){t.startVector(4,n.length,4);for(let r=n.length-1;r>=0;r--)t.addOffset(n[r]);return t.endVector()}static startCustomMetadataVector(t,n){t.startVector(4,n,4)}static endField(t){return t.endObject()}},du=class yl{constructor(){this.bb=null,this.bb_pos=0}__init(t,n){return this.bb_pos=t,this.bb=n,this}static getRootAsSchema(t,n){return(n||new yl).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsSchema(t,n){return t.setPosition(t.position()+Wn),(n||new yl).__init(t.readInt32(t.position())+t.position(),t)}endianness(){const t=this.bb.__offset(this.bb_pos,4);return t?this.bb.readInt16(this.bb_pos+t):ng.Little}fields(t,n){const r=this.bb.__offset(this.bb_pos,6);return r?(n||new Uo).__init(this.bb.__indirect(this.bb.__vector(this.bb_pos+r)+t*4),this.bb):null}fieldsLength(){const t=this.bb.__offset(this.bb_pos,6);return t?this.bb.__vector_len(this.bb_pos+t):0}customMetadata(t,n){const r=this.bb.__offset(this.bb_pos,8);return r?(n||new Zr).__init(this.bb.__indirect(this.bb.__vector(this.bb_pos+r)+t*4),this.bb):null}customMetadataLength(){const t=this.bb.__offset(this.bb_pos,8);return t?this.bb.__vector_len(this.bb_pos+t):0}features(t){const n=this.bb.__offset(this.bb_pos,10);return n?this.bb.readInt64(this.bb.__vector(this.bb_pos+n)+t*8):BigInt(0)}featuresLength(){const t=this.bb.__offset(this.bb_pos,10);return t?this.bb.__vector_len(this.bb_pos+t):0}static startSchema(t){t.startObject(4)}static addEndianness(t,n){t.addFieldInt16(0,n,ng.Little)}static addFields(t,n){t.addFieldOffset(1,n,0)}static createFieldsVector(t,n){t.startVector(4,n.length,4);for(let r=n.length-1;r>=0;r--)t.addOffset(n[r]);return t.endVector()}static startFieldsVector(t,n){t.startVector(4,n,4)}static addCustomMetadata(t,n){t.addFieldOffset(2,n,0)}static createCustomMetadataVector(t,n){t.startVector(4,n.length,4);for(let r=n.length-1;r>=0;r--)t.addOffset(n[r]);return t.endVector()}static startCustomMetadataVector(t,n){t.startVector(4,n,4)}static addFeatures(t,n){t.addFieldOffset(3,n,0)}static createFeaturesVector(t,n){t.startVector(8,n.length,8);for(let r=n.length-1;r>=0;r--)t.addInt64(n[r]);return t.endVector()}static startFeaturesVector(t,n){t.startVector(8,n,8)}static endSchema(t){return t.endObject()}static finishSchemaBuffer(t,n){t.finish(n)}static finishSizePrefixedSchemaBuffer(t,n){t.finish(n,void 0,!0)}static createSchema(t,n,r,i,s){return yl.startSchema(t),yl.addEndianness(t,n),yl.addFields(t,r),yl.addCustomMetadata(t,i),yl.addFeatures(t,s),yl.endSchema(t)}};class po{constructor(){this.bb=null,this.bb_pos=0}__init(t,n){return this.bb_pos=t,this.bb=n,this}static getRootAsFooter(t,n){return(n||new po).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsFooter(t,n){return t.setPosition(t.position()+Wn),(n||new po).__init(t.readInt32(t.position())+t.position(),t)}version(){const t=this.bb.__offset(this.bb_pos,4);return t?this.bb.readInt16(this.bb_pos+t):tg.V1}schema(t){const n=this.bb.__offset(this.bb_pos,6);return n?(t||new du).__init(this.bb.__indirect(this.bb_pos+n),this.bb):null}dictionaries(t,n){const r=this.bb.__offset(this.bb_pos,8);return r?(n||new uk).__init(this.bb.__vector(this.bb_pos+r)+t*24,this.bb):null}dictionariesLength(){const t=this.bb.__offset(this.bb_pos,8);return t?this.bb.__vector_len(this.bb_pos+t):0}recordBatches(t,n){const r=this.bb.__offset(this.bb_pos,10);return r?(n||new uk).__init(this.bb.__vector(this.bb_pos+r)+t*24,this.bb):null}recordBatchesLength(){const t=this.bb.__offset(this.bb_pos,10);return t?this.bb.__vector_len(this.bb_pos+t):0}customMetadata(t,n){const r=this.bb.__offset(this.bb_pos,12);return r?(n||new Zr).__init(this.bb.__indirect(this.bb.__vector(this.bb_pos+r)+t*4),this.bb):null}customMetadataLength(){const t=this.bb.__offset(this.bb_pos,12);return t?this.bb.__vector_len(this.bb_pos+t):0}static startFooter(t){t.startObject(5)}static addVersion(t,n){t.addFieldInt16(0,n,tg.V1)}static addSchema(t,n){t.addFieldOffset(1,n,0)}static addDictionaries(t,n){t.addFieldOffset(2,n,0)}static startDictionariesVector(t,n){t.startVector(24,n,8)}static addRecordBatches(t,n){t.addFieldOffset(3,n,0)}static startRecordBatchesVector(t,n){t.startVector(24,n,8)}static addCustomMetadata(t,n){t.addFieldOffset(4,n,0)}static createCustomMetadataVector(t,n){t.startVector(4,n.length,4);for(let r=n.length-1;r>=0;r--)t.addOffset(n[r]);return t.endVector()}static startCustomMetadataVector(t,n){t.startVector(4,n,4)}static endFooter(t){return t.endObject()}static finishFooterBuffer(t,n){t.finish(n)}static finishSizePrefixedFooterBuffer(t,n){t.finish(n,void 0,!0)}}class Dn{constructor(t=[],n,r,i=gs.V5){this.fields=t||[],this.metadata=n||new Map,r||(r=ck(t)),this.dictionaries=r,this.metadataVersion=i}get[Symbol.toStringTag](){return"Schema"}get names(){return this.fields.map(t=>t.name)}toString(){return`Schema<{ ${this.fields.map((t,n)=>`${n}: ${t}`).join(", ")} }>`}select(t){const n=new Set(t),r=this.fields.filter(i=>n.has(i.name));return new Dn(r,this.metadata)}selectAt(t){const n=t.map(r=>this.fields[r]).filter(Boolean);return new Dn(n,this.metadata)}assign(...t){const n=t[0]instanceof Dn?t[0]:Array.isArray(t[0])?new Dn(t[0]):new Dn(t),r=[...this.fields],i=jb(jb(new Map,this.metadata),n.metadata),s=n.fields.filter(a=>{const u=r.findIndex(l=>l.name===a.name);return~u?(r[u]=a.clone({metadata:jb(jb(new Map,r[u].metadata),a.metadata)}))&&!1:!0}),o=ck(s,new Map);return new Dn([...r,...s],i,new Map([...this.dictionaries,...o]))}}Dn.prototype.fields=null;Dn.prototype.metadata=null;Dn.prototype.dictionaries=null;class Rn{static new(...t){let[n,r,i,s]=t;return t[0]&&typeof t[0]=="object"&&({name:n}=t[0],r===void 0&&(r=t[0].type),i===void 0&&(i=t[0].nullable),s===void 0&&(s=t[0].metadata)),new Rn(`${n}`,r,i,s)}constructor(t,n,r=!1,i){this.name=t,this.type=n,this.nullable=r,this.metadata=i||new Map}get typeId(){return this.type.typeId}get[Symbol.toStringTag](){return"Field"}toString(){return`${this.name}: ${this.type}`}clone(...t){let[n,r,i,s]=t;return!t[0]||typeof t[0]!="object"?[n=this.name,r=this.type,i=this.nullable,s=this.metadata]=t:{name:n=this.name,type:r=this.type,nullable:i=this.nullable,metadata:s=this.metadata}=t[0],Rn.new(n,r,i,s)}}Rn.prototype.type=null;Rn.prototype.name=null;Rn.prototype.nullable=null;Rn.prototype.metadata=null;function jb(e,t){return new Map([...e||new Map,...t||new Map])}function ck(e,t=new Map){for(let n=-1,r=e.length;++n0&&ck(s.children,t)}return t}var HGe=oae,WGe=pI;class fk{static decode(t){t=new WGe(Mn(t));const n=po.getRootAsFooter(t),r=Dn.decode(n.schema(),new Map,n.version());return new qGe(r,n)}static encode(t){const n=new HGe,r=Dn.encode(n,t.schema);po.startRecordBatchesVector(n,t.numRecordBatches);for(const o of[...t.recordBatches()].slice().reverse())Lf.encode(n,o);const i=n.endVector();po.startDictionariesVector(n,t.numDictionaries);for(const o of[...t.dictionaryBatches()].slice().reverse())Lf.encode(n,o);const s=n.endVector();return po.startFooter(n),po.addSchema(n,r),po.addVersion(n,gs.V5),po.addRecordBatches(n,i),po.addDictionaries(n,s),po.finishFooterBuffer(n,po.endFooter(n)),n.asUint8Array()}get numRecordBatches(){return this._recordBatches.length}get numDictionaries(){return this._dictionaryBatches.length}constructor(t,n=gs.V5,r,i){this.schema=t,this.version=n,r&&(this._recordBatches=r),i&&(this._dictionaryBatches=i)}*recordBatches(){for(let t,n=-1,r=this.numRecordBatches;++n=0&&t=0&&t=0&&t=0&&tthis._closedPromiseResolve=t)}get closed(){return this._closedPromise}cancel(t){return Il(this,void 0,void 0,function*(){yield this.return(t)})}write(t){this._ensureOpen()&&(this.resolvers.length<=0?this._values.push(t):this.resolvers.shift().resolve({done:!1,value:t}))}abort(t){this._closedPromiseResolve&&(this.resolvers.length<=0?this._error={error:t}:this.resolvers.shift().reject({done:!0,value:t}))}close(){if(this._closedPromiseResolve){const{resolvers:t}=this;for(;t.length>0;)t.shift().resolve(Ub);this._closedPromiseResolve(),this._closedPromiseResolve=void 0}}[Symbol.asyncIterator](){return this}toDOMStream(t){return Pz.toDOMStream(this._closedPromiseResolve||this._error?this:this._values,t)}toNodeStream(t){return Pz.toNodeStream(this._closedPromiseResolve||this._error?this:this._values,t)}throw(t){return Il(this,void 0,void 0,function*(){return yield this.abort(t),Ub})}return(t){return Il(this,void 0,void 0,function*(){return yield this.close(),Ub})}read(t){return Il(this,void 0,void 0,function*(){return(yield this.next(t,"read")).value})}peek(t){return Il(this,void 0,void 0,function*(){return(yield this.next(t,"peek")).value})}next(...t){return this._values.length>0?Promise.resolve({done:!1,value:this._values.shift()}):this._error?Promise.reject({done:!0,value:this._error.error}):this._closedPromiseResolve?new Promise((n,r)=>{this.resolvers.push({resolve:n,reject:r})}):Promise.resolve(Ub)}_ensureOpen(){if(this._closedPromiseResolve)return!0;throw new Error("AsyncQueue is closed")}}class t2 extends GGe{write(t){if((t=Mn(t)).byteLength>0)return super.write(t)}toString(t=!1){return t?sk(this.toUint8Array(!0)):this.toUint8Array(!1).then(sk)}toUint8Array(t=!1){return t?tl(this._values)[0]:Il(this,void 0,void 0,function*(){var n,r,i,s;const o=[];let a=0;try{for(var u=!0,l=My(this),c;c=yield l.next(),n=c.done,!n;u=!0){s=c.value,u=!1;const f=s;o.push(f),a+=f.byteLength}}catch(f){r={error:f}}finally{try{!u&&!n&&(i=l.return)&&(yield i.call(l))}finally{if(r)throw r.error}}return tl(o,a)[0]})}}class lae extends zC{constructor(t){super(t),this._values=new VC(new Uint8Array(0))}get byteLength(){let t=this._pendingLength+this.length*4;return this._offsets&&(t+=this._offsets.byteLength),this._values&&(t+=this._values.byteLength),this._nulls&&(t+=this._nulls.byteLength),t}setValue(t,n){return super.setValue(t,Mn(n))}_flushPending(t,n){const r=this._offsets,i=this._values.reserve(n).buffer;let s=0;for(const[o,a]of t)if(a===void 0)r.set(o,0);else{const u=a.length;i.set(a,s),r.set(o,u),s+=u}}}class YGe extends uo{constructor(t){super(t),this._values=new rae}setValue(t,n){this._values.set(t,+n)}}class HC extends pc{}HC.prototype._setValue=poe;class cae extends HC{}cae.prototype._setValue=dL;class fae extends HC{}fae.prototype._setValue=hL;class dae extends pc{}dae.prototype._setValue=yoe;class KGe extends uo{constructor({type:t,nullValues:n,dictionaryHashFunction:r}){super({type:new Df(t.dictionary,t.indices,t.id,t.isOrdered)}),this._nulls=null,this._dictionaryOffset=0,this._keysToIndices=Object.create(null),this.indices=bI({type:this.type.indices,nullValues:n}),this.dictionary=bI({type:this.type.dictionary,nullValues:null}),typeof r=="function"&&(this.valueToKey=r)}get values(){return this.indices.values}get nullCount(){return this.indices.nullCount}get nullBitmap(){return this.indices.nullBitmap}get byteLength(){return this.indices.byteLength+this.dictionary.byteLength}get reservedLength(){return this.indices.reservedLength+this.dictionary.reservedLength}get reservedByteLength(){return this.indices.reservedByteLength+this.dictionary.reservedByteLength}isValid(t){return this.indices.isValid(t)}setValid(t,n){const r=this.indices;return n=r.setValid(t,n),this.length=r.length,n}setValue(t,n){const r=this._keysToIndices,i=this.valueToKey(n);let s=r[i];return s===void 0&&(r[i]=s=this._dictionaryOffset+this.dictionary.append(n).length-1),this.indices.setValue(t,s)}flush(){const t=this.type,n=this._dictionary,r=this.dictionary.toVector(),i=this.indices.flush().clone(t);return i.dictionary=n?n.concat(r):r,this.finished||(this._dictionaryOffset+=r.length),this._dictionary=i.dictionary,this.clear(),i}finish(){return this.indices.finish(),this.dictionary.finish(),this._dictionaryOffset=0,this._keysToIndices=Object.create(null),super.finish()}clear(){return this.indices.clear(),this.dictionary.clear(),super.clear()}valueToKey(t){return typeof t=="string"?t:`${t}`}}class hae extends pc{}hae.prototype._setValue=hoe;class QGe extends uo{setValue(t,n){const[r]=this.children,i=t*this.stride;for(let s=-1,o=n.length;++s0)throw new Error("FixedSizeListBuilder can only have one child.");const r=this.children.push(t);return this.type=new eg(this.type.listSize,new Rn(n,t.type,!0)),r}}class WC extends pc{setValue(t,n){this._values.set(t,n)}}class XGe extends WC{setValue(t,n){super.setValue(t,coe(n))}}class JGe extends WC{}class ZGe extends WC{}class qC extends pc{}qC.prototype._setValue=boe;class pae extends qC{}pae.prototype._setValue=EL;class mae extends qC{}mae.prototype._setValue=SL;class $g extends pc{}$g.prototype._setValue=woe;class gae extends $g{}gae.prototype._setValue=TL;class yae extends $g{}yae.prototype._setValue=IL;class vae extends $g{}vae.prototype._setValue=xL;class _ae extends $g{}_ae.prototype._setValue=CL;class mc extends pc{setValue(t,n){this._values.set(t,n)}}class eYe extends mc{}class tYe extends mc{}class nYe extends mc{}class rYe extends mc{}class iYe extends mc{}class sYe extends mc{}class oYe extends mc{}class aYe extends mc{}class uYe extends zC{constructor(t){super(t),this._offsets=new iae}addChild(t,n="0"){if(this.numChildren>0)throw new Error("ListBuilder can only have one child.");return this.children[this.numChildren]=t,this.type=new Zm(new Rn(n,t.type,!0)),this.numChildren-1}_flushPending(t){const n=this._offsets,[r]=this.children;for(const[i,s]of t)if(typeof s>"u")n.set(i,0);else{const o=s,a=o.length,u=n.set(i,a).buffer[i];for(let l=-1;++l0)throw new Error("ListBuilder can only have one child.");return this.children[this.numChildren]=t,this.type=new Vv(new Rn(n,t.type,!0),this.type.keysSorted),this.numChildren-1}_flushPending(t){const n=this._offsets,[r]=this.children;for(const[i,s]of t)if(s===void 0)n.set(i,0);else{let{[i]:o,[i+1]:a}=n.set(i,s.size).buffer;for(const u of s.entries())if(r.set(o,u),++o>=a)break}}}class cYe extends uo{setValue(t,n){}setValid(t,n){return this.length=Math.max(t+1,this.length),n}}class fYe extends uo{setValue(t,n){const{children:r,type:i}=this;switch(Array.isArray(n)||n.constructor){case!0:return i.children.forEach((s,o)=>r[o].set(t,n[o]));case Map:return i.children.forEach((s,o)=>r[o].set(t,n.get(s.name)));default:return i.children.forEach((s,o)=>r[o].set(t,n[s.name]))}}setValid(t,n){return super.setValid(t,n)||this.children.forEach(r=>r.setValid(t,n)),n}addChild(t,n=`${this.numChildren}`){const r=this.children.push(t);return this.type=new rs([...this.type.children,new Rn(n,t.type,!0)]),r}}class Lg extends pc{}Lg.prototype._setValue=moe;class bae extends Lg{}bae.prototype._setValue=pL;class wae extends Lg{}wae.prototype._setValue=mL;class Eae extends Lg{}Eae.prototype._setValue=gL;class Sae extends Lg{}Sae.prototype._setValue=yL;class Mg extends pc{}Mg.prototype._setValue=goe;class Tae extends Mg{}Tae.prototype._setValue=vL;class Iae extends Mg{}Iae.prototype._setValue=_L;class xae extends Mg{}xae.prototype._setValue=bL;class Cae extends Mg{}Cae.prototype._setValue=wL;class DL extends uo{constructor(t){super(t),this._typeIds=new s1(new Int8Array(0),1),typeof t.valueToChildTypeId=="function"&&(this._valueToChildTypeId=t.valueToChildTypeId)}get typeIdToChildIndex(){return this.type.typeIdToChildIndex}append(t,n){return this.set(this.length,t,n)}set(t,n,r){return r===void 0&&(r=this._valueToChildTypeId(this,n,t)),this.setValue(t,n,r),this}setValue(t,n,r){this._typeIds.set(t,r);const i=this.type.typeIdToChildIndex[r],s=this.children[i];s==null||s.set(t,n)}addChild(t,n=`${this.children.length}`){const r=this.children.push(t),{type:{children:i,mode:s,typeIds:o}}=this,a=[...i,new Rn(n,t.type)];return this.type=new Uv(s,[...o,r],a),r}_valueToChildTypeId(t,n,r){throw new Error("Cannot map UnionBuilder value to child typeId. Pass the `childTypeId` as the second argument to unionBuilder.append(), or supply a `valueToChildTypeId` function as part of the UnionBuilder constructor options.")}}class dYe extends DL{}class hYe extends DL{constructor(t){super(t),this._offsets=new s1(new Int32Array(0))}setValue(t,n,r){const i=this._typeIds.set(t,r).buffer[t],s=this.getChildAt(this.type.typeIdToChildIndex[i]),o=this._offsets.set(t,s.length).buffer[t];s==null||s.set(o,n)}}class Aae extends zC{constructor(t){super(t),this._values=new VC(new Uint8Array(0))}get byteLength(){let t=this._pendingLength+this.length*4;return this._offsets&&(t+=this._offsets.byteLength),this._values&&(t+=this._values.byteLength),this._nulls&&(t+=this._nulls.byteLength),t}setValue(t,n){return super.setValue(t,X6(n))}_flushPending(t,n){}}Aae.prototype._flushPending=lae.prototype._flushPending;class pYe extends qt{visitNull(){return cYe}visitBool(){return YGe}visitInt(){return mc}visitInt8(){return eYe}visitInt16(){return tYe}visitInt32(){return nYe}visitInt64(){return rYe}visitUint8(){return iYe}visitUint16(){return sYe}visitUint32(){return oYe}visitUint64(){return aYe}visitFloat(){return WC}visitFloat16(){return XGe}visitFloat32(){return JGe}visitFloat64(){return ZGe}visitUtf8(){return Aae}visitBinary(){return lae}visitFixedSizeBinary(){return hae}visitDate(){return HC}visitDateDay(){return cae}visitDateMillisecond(){return fae}visitTimestamp(){return Lg}visitTimestampSecond(){return bae}visitTimestampMillisecond(){return wae}visitTimestampMicrosecond(){return Eae}visitTimestampNanosecond(){return Sae}visitTime(){return Mg}visitTimeSecond(){return Tae}visitTimeMillisecond(){return Iae}visitTimeMicrosecond(){return xae}visitTimeNanosecond(){return Cae}visitDecimal(){return dae}visitList(){return uYe}visitStruct(){return fYe}visitUnion(){return DL}visitDenseUnion(){return hYe}visitSparseUnion(){return dYe}visitDictionary(){return KGe}visitInterval(){return qC}visitIntervalDayTime(){return pae}visitIntervalYearMonth(){return mae}visitDuration(){return $g}visitDurationSecond(){return gae}visitDurationMillisecond(){return yae}visitDurationMicrosecond(){return vae}visistDurationNanosecond(){return _ae}visitFixedSizeList(){return QGe}visitMap(){return lYe}}const mYe=new pYe;class Et extends qt{compareSchemas(t,n){return t===n||n instanceof t.constructor&&this.compareManyFields(t.fields,n.fields)}compareManyFields(t,n){return t===n||Array.isArray(t)&&Array.isArray(n)&&t.length===n.length&&t.every((r,i)=>this.compareFields(r,n[i]))}compareFields(t,n){return t===n||n instanceof t.constructor&&t.name===n.name&&t.nullable===n.nullable&&this.visit(t.type,n.type)}}function Ts(e,t){return t instanceof e.constructor}function o1(e,t){return e===t||Ts(e,t)}function gc(e,t){return e===t||Ts(e,t)&&e.bitWidth===t.bitWidth&&e.isSigned===t.isSigned}function GC(e,t){return e===t||Ts(e,t)&&e.precision===t.precision}function gYe(e,t){return e===t||Ts(e,t)&&e.byteWidth===t.byteWidth}function $L(e,t){return e===t||Ts(e,t)&&e.unit===t.unit}function a1(e,t){return e===t||Ts(e,t)&&e.unit===t.unit&&e.timezone===t.timezone}function u1(e,t){return e===t||Ts(e,t)&&e.unit===t.unit&&e.bitWidth===t.bitWidth}function yYe(e,t){return e===t||Ts(e,t)&&e.children.length===t.children.length&&Mf.compareManyFields(e.children,t.children)}function vYe(e,t){return e===t||Ts(e,t)&&e.children.length===t.children.length&&Mf.compareManyFields(e.children,t.children)}function LL(e,t){return e===t||Ts(e,t)&&e.mode===t.mode&&e.typeIds.every((n,r)=>n===t.typeIds[r])&&Mf.compareManyFields(e.children,t.children)}function _Ye(e,t){return e===t||Ts(e,t)&&e.id===t.id&&e.isOrdered===t.isOrdered&&Mf.visit(e.indices,t.indices)&&Mf.visit(e.dictionary,t.dictionary)}function ML(e,t){return e===t||Ts(e,t)&&e.unit===t.unit}function l1(e,t){return e===t||Ts(e,t)&&e.unit===t.unit}function bYe(e,t){return e===t||Ts(e,t)&&e.listSize===t.listSize&&e.children.length===t.children.length&&Mf.compareManyFields(e.children,t.children)}function wYe(e,t){return e===t||Ts(e,t)&&e.keysSorted===t.keysSorted&&e.children.length===t.children.length&&Mf.compareManyFields(e.children,t.children)}Et.prototype.visitNull=o1;Et.prototype.visitBool=o1;Et.prototype.visitInt=gc;Et.prototype.visitInt8=gc;Et.prototype.visitInt16=gc;Et.prototype.visitInt32=gc;Et.prototype.visitInt64=gc;Et.prototype.visitUint8=gc;Et.prototype.visitUint16=gc;Et.prototype.visitUint32=gc;Et.prototype.visitUint64=gc;Et.prototype.visitFloat=GC;Et.prototype.visitFloat16=GC;Et.prototype.visitFloat32=GC;Et.prototype.visitFloat64=GC;Et.prototype.visitUtf8=o1;Et.prototype.visitBinary=o1;Et.prototype.visitFixedSizeBinary=gYe;Et.prototype.visitDate=$L;Et.prototype.visitDateDay=$L;Et.prototype.visitDateMillisecond=$L;Et.prototype.visitTimestamp=a1;Et.prototype.visitTimestampSecond=a1;Et.prototype.visitTimestampMillisecond=a1;Et.prototype.visitTimestampMicrosecond=a1;Et.prototype.visitTimestampNanosecond=a1;Et.prototype.visitTime=u1;Et.prototype.visitTimeSecond=u1;Et.prototype.visitTimeMillisecond=u1;Et.prototype.visitTimeMicrosecond=u1;Et.prototype.visitTimeNanosecond=u1;Et.prototype.visitDecimal=o1;Et.prototype.visitList=yYe;Et.prototype.visitStruct=vYe;Et.prototype.visitUnion=LL;Et.prototype.visitDenseUnion=LL;Et.prototype.visitSparseUnion=LL;Et.prototype.visitDictionary=_Ye;Et.prototype.visitInterval=ML;Et.prototype.visitIntervalDayTime=ML;Et.prototype.visitIntervalYearMonth=ML;Et.prototype.visitDuration=l1;Et.prototype.visitDurationSecond=l1;Et.prototype.visitDurationMillisecond=l1;Et.prototype.visitDurationMicrosecond=l1;Et.prototype.visitDurationNanosecond=l1;Et.prototype.visitFixedSizeList=bYe;Et.prototype.visitMap=wYe;const Mf=new Et;function dk(e,t){return Mf.compareSchemas(e,t)}function bI(e){const t=e.type,n=new(mYe.getVisitFn(t)())(e);if(t.children&&t.children.length>0){const r=e.children||[],i={nullValues:e.nullValues},s=Array.isArray(r)?(o,a)=>r[a]||i:({name:o})=>r[o]||i;for(const[o,a]of t.children.entries()){const{type:u}=a,l=s(a,o);n.children.push(bI(Object.assign(Object.assign({},l),{type:u})))}}return n}function n2(e,t){return EYe(e,t.map(n=>n.data.concat()))}function EYe(e,t){const n=[...e.fields],r=[],i={numBatches:t.reduce((f,d)=>Math.max(f,d.length),0)};let s=0,o=0,a=-1;const u=t.length;let l,c=[];for(;i.numBatches-- >0;){for(o=Number.POSITIVE_INFINITY,a=-1;++a0&&(r[s++]=Ji({type:new rs(n),length:o,nullCount:0,children:c.slice()})))}return[e=e.assign(n),r.map(f=>new vo(e,f))]}function SYe(e,t,n,r,i){var s;const o=(t+63&-64)>>3;for(let a=-1,u=r.length;++a=t)c===t?n[a]=l:(n[a]=l.slice(0,t),i.numBatches=Math.max(i.numBatches,r[a].unshift(l.slice(t,c-t))));else{const f=e[a];e[a]=f.clone({nullable:!0}),n[a]=(s=l==null?void 0:l._changeLengthAndBackfillNullBitmap(t))!==null&&s!==void 0?s:Ji({type:f.type,length:t,nullCount:t,nullBitmap:new Uint8Array(o)})}}return n}var Pae;class Us{constructor(...t){var n,r;if(t.length===0)return this.batches=[],this.schema=new Dn([]),this._offsets=[0],this;let i,s;t[0]instanceof Dn&&(i=t.shift()),t.at(-1)instanceof Uint32Array&&(s=t.pop());const o=u=>{if(u){if(u instanceof vo)return[u];if(u instanceof Us)return u.batches;if(u instanceof Ln){if(u.type instanceof rs)return[new vo(new Dn(u.type.children),u)]}else{if(Array.isArray(u))return u.flatMap(l=>o(l));if(typeof u[Symbol.iterator]=="function")return[...u].flatMap(l=>o(l));if(typeof u=="object"){const l=Object.keys(u),c=l.map(h=>new Sn([u[h]])),f=new Dn(l.map((h,p)=>new Rn(String(h),c[p].type))),[,d]=n2(f,c);return d.length===0?[new vo(u)]:d}}}return[]},a=t.flatMap(u=>o(u));if(i=(r=i??((n=a[0])===null||n===void 0?void 0:n.schema))!==null&&r!==void 0?r:new Dn([]),!(i instanceof Dn))throw new TypeError("Table constructor expects a [Schema, RecordBatch[]] pair.");for(const u of a){if(!(u instanceof vo))throw new TypeError("Table constructor expects a [Schema, RecordBatch[]] pair.");if(!dk(i,u.schema))throw new TypeError("Table and inner RecordBatch schemas must be equivalent.")}this.schema=i,this.batches=a,this._offsets=s??Goe(this.data)}get data(){return this.batches.map(({data:t})=>t)}get numCols(){return this.schema.fields.length}get numRows(){return this.data.reduce((t,n)=>t+n.length,0)}get nullCount(){return this._nullCount===-1&&(this._nullCount=qoe(this.data)),this._nullCount}isValid(t){return!1}get(t){return null}set(t,n){}indexOf(t,n){return-1}getByteLength(t){return 0}[Symbol.iterator](){return this.batches.length>0?kL.visit(new Sn(this.data)):new Array(0)[Symbol.iterator]()}toArray(){return[...this]}toString(){return`[ +return true;`)}function zGe(e){return typeof e!="bigint"?vh(e):`${vh(e)}n`}const JO=(e,t)=>(Math.ceil(e)*t+63&-64||64)/t,HGe=(e,t=0)=>e.length>=t?e.subarray(0,t):oI(new e.constructor(t),e,0);class VC{constructor(t,n=1){this.buffer=t,this.stride=n,this.BYTES_PER_ELEMENT=t.BYTES_PER_ELEMENT,this.ArrayType=t.constructor,this._resize(this.length=Math.ceil(t.length/n))}get byteLength(){return Math.ceil(this.length*this.stride)*this.BYTES_PER_ELEMENT}get reservedLength(){return this.buffer.length/this.stride}get reservedByteLength(){return this.buffer.byteLength}set(t,n){return this}append(t){return this.set(this.length,t)}reserve(t){if(t>0){this.length+=t;const n=this.stride,r=this.length*n,i=this.buffer.length;r>=i&&this._resize(i===0?JO(r*1,this.BYTES_PER_ELEMENT):JO(r*2,this.BYTES_PER_ELEMENT))}return this}flush(t=this.length){t=JO(t*this.stride,this.BYTES_PER_ELEMENT);const n=HGe(this.buffer,t);return this.clear(),n}clear(){return this.length=0,this._resize(0),this}_resize(t){return this.buffer=oI(new this.ArrayType(t),this.buffer)}}VC.prototype.offset=0;class s1 extends VC{last(){return this.get(this.length-1)}get(t){return this.buffer[t]}set(t,n){return this.reserve(t-this.length+1),this.buffer[t*this.stride]=n,this}}class rae extends s1{constructor(t=new Uint8Array(0)){super(t,1/8),this.numValid=0}get numInvalid(){return this.length-this.numValid}get(t){return this.buffer[t>>3]>>t%8&1}set(t,n){const{buffer:r}=this.reserve(t-this.length+1),i=t>>3,s=t%8,o=r[i]>>s&1;return n?o===0&&(r[i]|=1<this.length&&this.set(t-1,0),super.flush(t+1)}}let uo=class{static throughNode(t){throw new Error('"throughNode" not available in this environment')}static throughDOM(t){throw new Error('"throughDOM" not available in this environment')}constructor({type:t,nullValues:n}){this.length=0,this.finished=!1,this.type=t,this.children=[],this.nullValues=n,this.stride=pu(t),this._nulls=new rae,n&&n.length>0&&(this._isValid=VGe(n))}toVector(){return new Sn([this.flush()])}get ArrayType(){return this.type.ArrayType}get nullCount(){return this._nulls.numInvalid}get numChildren(){return this.children.length}get byteLength(){let t=0;const{_offsets:n,_values:r,_nulls:i,_typeIds:s,children:o}=this;return n&&(t+=n.byteLength),r&&(t+=r.byteLength),i&&(t+=i.byteLength),s&&(t+=s.byteLength),o.reduce((a,u)=>a+u.byteLength,t)}get reservedLength(){return this._nulls.reservedLength}get reservedByteLength(){let t=0;return this._offsets&&(t+=this._offsets.reservedByteLength),this._values&&(t+=this._values.reservedByteLength),this._nulls&&(t+=this._nulls.reservedByteLength),this._typeIds&&(t+=this._typeIds.reservedByteLength),this.children.reduce((n,r)=>n+r.reservedByteLength,t)}get valueOffsets(){return this._offsets?this._offsets.buffer:null}get values(){return this._values?this._values.buffer:null}get nullBitmap(){return this._nulls?this._nulls.buffer:null}get typeIds(){return this._typeIds?this._typeIds.buffer:null}append(t){return this.set(this.length,t)}isValid(t){return this._isValid(t)}set(t,n){return this.setValid(t,this.isValid(n))&&this.setValue(t,n),this}setValue(t,n){this._setValue(this,t,n)}setValid(t,n){return this.length=this._nulls.set(t,+n).length,n}addChild(t,n=`${this.numChildren}`){throw new Error(`Cannot append children to non-nested type "${this.type}"`)}getChildAt(t){return this.children[t]||null}flush(){let t,n,r,i;const{type:s,length:o,nullCount:a,_typeIds:u,_offsets:l,_values:c,_nulls:f}=this;(n=u==null?void 0:u.flush(o))?i=l==null?void 0:l.flush(o):(i=l==null?void 0:l.flush(o))?t=c==null?void 0:c.flush(l.last()):t=c==null?void 0:c.flush(o),a>0&&(r=f==null?void 0:f.flush(o));const d=this.children.map(h=>h.flush());return this.clear(),Ji({type:s,length:o,nullCount:a,children:d,child:d[0],data:t,typeIds:n,nullBitmap:r,valueOffsets:i})}finish(){this.finished=!0;for(const t of this.children)t.finish();return this}clear(){var t,n,r,i;this.length=0,(t=this._nulls)===null||t===void 0||t.clear(),(n=this._values)===null||n===void 0||n.clear(),(r=this._offsets)===null||r===void 0||r.clear(),(i=this._typeIds)===null||i===void 0||i.clear();for(const s of this.children)s.clear();return this}};uo.prototype.length=1;uo.prototype.stride=1;uo.prototype.children=null;uo.prototype.finished=!1;uo.prototype.nullValues=null;uo.prototype._isValid=()=>!0;class pc extends uo{constructor(t){super(t),this._values=new s1(new this.ArrayType(0),this.stride)}setValue(t,n){const r=this._values;return r.reserve(t-r.length+1),super.setValue(t,n)}}class zC extends uo{constructor(t){super(t),this._pendingLength=0,this._offsets=new iae}setValue(t,n){const r=this._pending||(this._pending=new Map),i=r.get(t);i&&(this._pendingLength-=i.length),this._pendingLength+=n instanceof jC?n[La].length:n.length,r.set(t,n)}setValid(t,n){return super.setValid(t,n)?!0:((this._pending||(this._pending=new Map)).set(t,void 0),!1)}clear(){return this._pendingLength=0,this._pending=void 0,super.clear()}flush(){return this._flush(),super.flush()}finish(){return this._flush(),super.finish()}_flush(){const t=this._pending,n=this._pendingLength;return this._pendingLength=0,this._pending=void 0,t&&t.size>0&&this._flushPending(t,n),this}}class ak{constructor(){this.bb=null,this.bb_pos=0}__init(t,n){return this.bb_pos=t,this.bb=n,this}offset(){return this.bb.readInt64(this.bb_pos)}metaDataLength(){return this.bb.readInt32(this.bb_pos+8)}bodyLength(){return this.bb.readInt64(this.bb_pos+16)}static sizeOf(){return 24}static createBlock(t,n,r,i){return t.prep(8,24),t.writeInt64(BigInt(i??0)),t.pad(4),t.writeInt32(r),t.writeInt64(BigInt(n??0)),t.offset()}}const ZO=2,wu=4,xl=4,Wn=4,Lc=new Int32Array(2),$z=new Float32Array(Lc.buffer),Lz=new Float64Array(Lc.buffer),Bb=new Uint16Array(new Uint8Array([1,0]).buffer)[0]===1;var uk;(function(e){e[e.UTF8_BYTES=1]="UTF8_BYTES",e[e.UTF16_STRING=2]="UTF16_STRING"})(uk||(uk={}));let pI=class sae{constructor(t){this.bytes_=t,this.position_=0,this.text_decoder_=new TextDecoder}static allocate(t){return new sae(new Uint8Array(t))}clear(){this.position_=0}bytes(){return this.bytes_}position(){return this.position_}setPosition(t){this.position_=t}capacity(){return this.bytes_.length}readInt8(t){return this.readUint8(t)<<24>>24}readUint8(t){return this.bytes_[t]}readInt16(t){return this.readUint16(t)<<16>>16}readUint16(t){return this.bytes_[t]|this.bytes_[t+1]<<8}readInt32(t){return this.bytes_[t]|this.bytes_[t+1]<<8|this.bytes_[t+2]<<16|this.bytes_[t+3]<<24}readUint32(t){return this.readInt32(t)>>>0}readInt64(t){return BigInt.asIntN(64,BigInt(this.readUint32(t))+(BigInt(this.readUint32(t+4))<>8}writeUint16(t,n){this.bytes_[t]=n,this.bytes_[t+1]=n>>8}writeInt32(t,n){this.bytes_[t]=n,this.bytes_[t+1]=n>>8,this.bytes_[t+2]=n>>16,this.bytes_[t+3]=n>>24}writeUint32(t,n){this.bytes_[t]=n,this.bytes_[t+1]=n>>8,this.bytes_[t+2]=n>>16,this.bytes_[t+3]=n>>24}writeInt64(t,n){this.writeInt32(t,Number(BigInt.asIntN(32,n))),this.writeInt32(t+4,Number(BigInt.asIntN(32,n>>BigInt(32))))}writeUint64(t,n){this.writeUint32(t,Number(BigInt.asUintN(32,n))),this.writeUint32(t+4,Number(BigInt.asUintN(32,n>>BigInt(32))))}writeFloat32(t,n){$z[0]=n,this.writeInt32(t,Lc[0])}writeFloat64(t,n){Lz[0]=n,this.writeInt32(t,Lc[Bb?0:1]),this.writeInt32(t+4,Lc[Bb?1:0])}getBufferIdentifier(){if(this.bytes_.lengththis.minalign&&(this.minalign=t);const r=~(this.bb.capacity()-this.space+n)+1&t-1;for(;this.space=0&&this.vtable[n]==0;n--);const r=n+1;for(;n>=0;n--)this.addInt16(this.vtable[n]!=0?t-this.vtable[n]:0);const i=2;this.addInt16(t-this.object_start);const s=(r+i)*ZO;this.addInt16(s);let o=0;const a=this.space;e:for(n=0;n=0;o--)this.writeInt8(s.charCodeAt(o))}this.prep(this.minalign,wu+i),this.addOffset(t),i&&this.addInt32(this.bb.capacity()-this.space),this.bb.setPosition(this.space)}finishSizePrefixed(t,n){this.finish(t,n,!0)}requiredField(t,n){const r=this.bb.capacity()-t,i=r-this.bb.readInt32(r);if(!(n=0;r--)t.addInt32(n[r]);return t.endVector()}static startTypeIdsVector(t,n){t.startVector(4,n,4)}static endUnion(t){return t.endObject()}static createUnion(t,n,r){return js.startUnion(t),js.addMode(t,n),js.addTypeIds(t,r),js.endUnion(t)}}class Hd{constructor(){this.bb=null,this.bb_pos=0}__init(t,n){return this.bb_pos=t,this.bb=n,this}static getRootAsUtf8(t,n){return(n||new Hd).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsUtf8(t,n){return t.setPosition(t.position()+Wn),(n||new Hd).__init(t.readInt32(t.position())+t.position(),t)}static startUtf8(t){t.startObject(0)}static endUtf8(t){return t.endObject()}static createUtf8(t){return Hd.startUtf8(t),Hd.endUtf8(t)}}var cr;(function(e){e[e.NONE=0]="NONE",e[e.Null=1]="Null",e[e.Int=2]="Int",e[e.FloatingPoint=3]="FloatingPoint",e[e.Binary=4]="Binary",e[e.Utf8=5]="Utf8",e[e.Bool=6]="Bool",e[e.Decimal=7]="Decimal",e[e.Date=8]="Date",e[e.Time=9]="Time",e[e.Timestamp=10]="Timestamp",e[e.Interval=11]="Interval",e[e.List=12]="List",e[e.Struct_=13]="Struct_",e[e.Union=14]="Union",e[e.FixedSizeBinary=15]="FixedSizeBinary",e[e.FixedSizeList=16]="FixedSizeList",e[e.Map=17]="Map",e[e.Duration=18]="Duration",e[e.LargeBinary=19]="LargeBinary",e[e.LargeUtf8=20]="LargeUtf8",e[e.LargeList=21]="LargeList",e[e.RunEndEncoded=22]="RunEndEncoded"})(cr||(cr={}));let Uo=class Ww{constructor(){this.bb=null,this.bb_pos=0}__init(t,n){return this.bb_pos=t,this.bb=n,this}static getRootAsField(t,n){return(n||new Ww).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsField(t,n){return t.setPosition(t.position()+Wn),(n||new Ww).__init(t.readInt32(t.position())+t.position(),t)}name(t){const n=this.bb.__offset(this.bb_pos,4);return n?this.bb.__string(this.bb_pos+n,t):null}nullable(){const t=this.bb.__offset(this.bb_pos,6);return t?!!this.bb.readInt8(this.bb_pos+t):!1}typeType(){const t=this.bb.__offset(this.bb_pos,8);return t?this.bb.readUint8(this.bb_pos+t):cr.NONE}type(t){const n=this.bb.__offset(this.bb_pos,10);return n?this.bb.__union(t,this.bb_pos+n):null}dictionary(t){const n=this.bb.__offset(this.bb_pos,12);return n?(t||new Cl).__init(this.bb.__indirect(this.bb_pos+n),this.bb):null}children(t,n){const r=this.bb.__offset(this.bb_pos,14);return r?(n||new Ww).__init(this.bb.__indirect(this.bb.__vector(this.bb_pos+r)+t*4),this.bb):null}childrenLength(){const t=this.bb.__offset(this.bb_pos,14);return t?this.bb.__vector_len(this.bb_pos+t):0}customMetadata(t,n){const r=this.bb.__offset(this.bb_pos,16);return r?(n||new Zr).__init(this.bb.__indirect(this.bb.__vector(this.bb_pos+r)+t*4),this.bb):null}customMetadataLength(){const t=this.bb.__offset(this.bb_pos,16);return t?this.bb.__vector_len(this.bb_pos+t):0}static startField(t){t.startObject(7)}static addName(t,n){t.addFieldOffset(0,n,0)}static addNullable(t,n){t.addFieldInt8(1,+n,0)}static addTypeType(t,n){t.addFieldInt8(2,n,cr.NONE)}static addType(t,n){t.addFieldOffset(3,n,0)}static addDictionary(t,n){t.addFieldOffset(4,n,0)}static addChildren(t,n){t.addFieldOffset(5,n,0)}static createChildrenVector(t,n){t.startVector(4,n.length,4);for(let r=n.length-1;r>=0;r--)t.addOffset(n[r]);return t.endVector()}static startChildrenVector(t,n){t.startVector(4,n,4)}static addCustomMetadata(t,n){t.addFieldOffset(6,n,0)}static createCustomMetadataVector(t,n){t.startVector(4,n.length,4);for(let r=n.length-1;r>=0;r--)t.addOffset(n[r]);return t.endVector()}static startCustomMetadataVector(t,n){t.startVector(4,n,4)}static endField(t){return t.endObject()}},du=class yl{constructor(){this.bb=null,this.bb_pos=0}__init(t,n){return this.bb_pos=t,this.bb=n,this}static getRootAsSchema(t,n){return(n||new yl).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsSchema(t,n){return t.setPosition(t.position()+Wn),(n||new yl).__init(t.readInt32(t.position())+t.position(),t)}endianness(){const t=this.bb.__offset(this.bb_pos,4);return t?this.bb.readInt16(this.bb_pos+t):ng.Little}fields(t,n){const r=this.bb.__offset(this.bb_pos,6);return r?(n||new Uo).__init(this.bb.__indirect(this.bb.__vector(this.bb_pos+r)+t*4),this.bb):null}fieldsLength(){const t=this.bb.__offset(this.bb_pos,6);return t?this.bb.__vector_len(this.bb_pos+t):0}customMetadata(t,n){const r=this.bb.__offset(this.bb_pos,8);return r?(n||new Zr).__init(this.bb.__indirect(this.bb.__vector(this.bb_pos+r)+t*4),this.bb):null}customMetadataLength(){const t=this.bb.__offset(this.bb_pos,8);return t?this.bb.__vector_len(this.bb_pos+t):0}features(t){const n=this.bb.__offset(this.bb_pos,10);return n?this.bb.readInt64(this.bb.__vector(this.bb_pos+n)+t*8):BigInt(0)}featuresLength(){const t=this.bb.__offset(this.bb_pos,10);return t?this.bb.__vector_len(this.bb_pos+t):0}static startSchema(t){t.startObject(4)}static addEndianness(t,n){t.addFieldInt16(0,n,ng.Little)}static addFields(t,n){t.addFieldOffset(1,n,0)}static createFieldsVector(t,n){t.startVector(4,n.length,4);for(let r=n.length-1;r>=0;r--)t.addOffset(n[r]);return t.endVector()}static startFieldsVector(t,n){t.startVector(4,n,4)}static addCustomMetadata(t,n){t.addFieldOffset(2,n,0)}static createCustomMetadataVector(t,n){t.startVector(4,n.length,4);for(let r=n.length-1;r>=0;r--)t.addOffset(n[r]);return t.endVector()}static startCustomMetadataVector(t,n){t.startVector(4,n,4)}static addFeatures(t,n){t.addFieldOffset(3,n,0)}static createFeaturesVector(t,n){t.startVector(8,n.length,8);for(let r=n.length-1;r>=0;r--)t.addInt64(n[r]);return t.endVector()}static startFeaturesVector(t,n){t.startVector(8,n,8)}static endSchema(t){return t.endObject()}static finishSchemaBuffer(t,n){t.finish(n)}static finishSizePrefixedSchemaBuffer(t,n){t.finish(n,void 0,!0)}static createSchema(t,n,r,i,s){return yl.startSchema(t),yl.addEndianness(t,n),yl.addFields(t,r),yl.addCustomMetadata(t,i),yl.addFeatures(t,s),yl.endSchema(t)}};class po{constructor(){this.bb=null,this.bb_pos=0}__init(t,n){return this.bb_pos=t,this.bb=n,this}static getRootAsFooter(t,n){return(n||new po).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsFooter(t,n){return t.setPosition(t.position()+Wn),(n||new po).__init(t.readInt32(t.position())+t.position(),t)}version(){const t=this.bb.__offset(this.bb_pos,4);return t?this.bb.readInt16(this.bb_pos+t):tg.V1}schema(t){const n=this.bb.__offset(this.bb_pos,6);return n?(t||new du).__init(this.bb.__indirect(this.bb_pos+n),this.bb):null}dictionaries(t,n){const r=this.bb.__offset(this.bb_pos,8);return r?(n||new ak).__init(this.bb.__vector(this.bb_pos+r)+t*24,this.bb):null}dictionariesLength(){const t=this.bb.__offset(this.bb_pos,8);return t?this.bb.__vector_len(this.bb_pos+t):0}recordBatches(t,n){const r=this.bb.__offset(this.bb_pos,10);return r?(n||new ak).__init(this.bb.__vector(this.bb_pos+r)+t*24,this.bb):null}recordBatchesLength(){const t=this.bb.__offset(this.bb_pos,10);return t?this.bb.__vector_len(this.bb_pos+t):0}customMetadata(t,n){const r=this.bb.__offset(this.bb_pos,12);return r?(n||new Zr).__init(this.bb.__indirect(this.bb.__vector(this.bb_pos+r)+t*4),this.bb):null}customMetadataLength(){const t=this.bb.__offset(this.bb_pos,12);return t?this.bb.__vector_len(this.bb_pos+t):0}static startFooter(t){t.startObject(5)}static addVersion(t,n){t.addFieldInt16(0,n,tg.V1)}static addSchema(t,n){t.addFieldOffset(1,n,0)}static addDictionaries(t,n){t.addFieldOffset(2,n,0)}static startDictionariesVector(t,n){t.startVector(24,n,8)}static addRecordBatches(t,n){t.addFieldOffset(3,n,0)}static startRecordBatchesVector(t,n){t.startVector(24,n,8)}static addCustomMetadata(t,n){t.addFieldOffset(4,n,0)}static createCustomMetadataVector(t,n){t.startVector(4,n.length,4);for(let r=n.length-1;r>=0;r--)t.addOffset(n[r]);return t.endVector()}static startCustomMetadataVector(t,n){t.startVector(4,n,4)}static endFooter(t){return t.endObject()}static finishFooterBuffer(t,n){t.finish(n)}static finishSizePrefixedFooterBuffer(t,n){t.finish(n,void 0,!0)}}class Dn{constructor(t=[],n,r,i=gs.V5){this.fields=t||[],this.metadata=n||new Map,r||(r=lk(t)),this.dictionaries=r,this.metadataVersion=i}get[Symbol.toStringTag](){return"Schema"}get names(){return this.fields.map(t=>t.name)}toString(){return`Schema<{ ${this.fields.map((t,n)=>`${n}: ${t}`).join(", ")} }>`}select(t){const n=new Set(t),r=this.fields.filter(i=>n.has(i.name));return new Dn(r,this.metadata)}selectAt(t){const n=t.map(r=>this.fields[r]).filter(Boolean);return new Dn(n,this.metadata)}assign(...t){const n=t[0]instanceof Dn?t[0]:Array.isArray(t[0])?new Dn(t[0]):new Dn(t),r=[...this.fields],i=jb(jb(new Map,this.metadata),n.metadata),s=n.fields.filter(a=>{const u=r.findIndex(l=>l.name===a.name);return~u?(r[u]=a.clone({metadata:jb(jb(new Map,r[u].metadata),a.metadata)}))&&!1:!0}),o=lk(s,new Map);return new Dn([...r,...s],i,new Map([...this.dictionaries,...o]))}}Dn.prototype.fields=null;Dn.prototype.metadata=null;Dn.prototype.dictionaries=null;class Rn{static new(...t){let[n,r,i,s]=t;return t[0]&&typeof t[0]=="object"&&({name:n}=t[0],r===void 0&&(r=t[0].type),i===void 0&&(i=t[0].nullable),s===void 0&&(s=t[0].metadata)),new Rn(`${n}`,r,i,s)}constructor(t,n,r=!1,i){this.name=t,this.type=n,this.nullable=r,this.metadata=i||new Map}get typeId(){return this.type.typeId}get[Symbol.toStringTag](){return"Field"}toString(){return`${this.name}: ${this.type}`}clone(...t){let[n,r,i,s]=t;return!t[0]||typeof t[0]!="object"?[n=this.name,r=this.type,i=this.nullable,s=this.metadata]=t:{name:n=this.name,type:r=this.type,nullable:i=this.nullable,metadata:s=this.metadata}=t[0],Rn.new(n,r,i,s)}}Rn.prototype.type=null;Rn.prototype.name=null;Rn.prototype.nullable=null;Rn.prototype.metadata=null;function jb(e,t){return new Map([...e||new Map,...t||new Map])}function lk(e,t=new Map){for(let n=-1,r=e.length;++n0&&lk(s.children,t)}return t}var WGe=oae,qGe=pI;class ck{static decode(t){t=new qGe(Mn(t));const n=po.getRootAsFooter(t),r=Dn.decode(n.schema(),new Map,n.version());return new GGe(r,n)}static encode(t){const n=new WGe,r=Dn.encode(n,t.schema);po.startRecordBatchesVector(n,t.numRecordBatches);for(const o of[...t.recordBatches()].slice().reverse())Lf.encode(n,o);const i=n.endVector();po.startDictionariesVector(n,t.numDictionaries);for(const o of[...t.dictionaryBatches()].slice().reverse())Lf.encode(n,o);const s=n.endVector();return po.startFooter(n),po.addSchema(n,r),po.addVersion(n,gs.V5),po.addRecordBatches(n,i),po.addDictionaries(n,s),po.finishFooterBuffer(n,po.endFooter(n)),n.asUint8Array()}get numRecordBatches(){return this._recordBatches.length}get numDictionaries(){return this._dictionaryBatches.length}constructor(t,n=gs.V5,r,i){this.schema=t,this.version=n,r&&(this._recordBatches=r),i&&(this._dictionaryBatches=i)}*recordBatches(){for(let t,n=-1,r=this.numRecordBatches;++n=0&&t=0&&t=0&&t=0&&tthis._closedPromiseResolve=t)}get closed(){return this._closedPromise}cancel(t){return Il(this,void 0,void 0,function*(){yield this.return(t)})}write(t){this._ensureOpen()&&(this.resolvers.length<=0?this._values.push(t):this.resolvers.shift().resolve({done:!1,value:t}))}abort(t){this._closedPromiseResolve&&(this.resolvers.length<=0?this._error={error:t}:this.resolvers.shift().reject({done:!0,value:t}))}close(){if(this._closedPromiseResolve){const{resolvers:t}=this;for(;t.length>0;)t.shift().resolve(Ub);this._closedPromiseResolve(),this._closedPromiseResolve=void 0}}[Symbol.asyncIterator](){return this}toDOMStream(t){return Pz.toDOMStream(this._closedPromiseResolve||this._error?this:this._values,t)}toNodeStream(t){return Pz.toNodeStream(this._closedPromiseResolve||this._error?this:this._values,t)}throw(t){return Il(this,void 0,void 0,function*(){return yield this.abort(t),Ub})}return(t){return Il(this,void 0,void 0,function*(){return yield this.close(),Ub})}read(t){return Il(this,void 0,void 0,function*(){return(yield this.next(t,"read")).value})}peek(t){return Il(this,void 0,void 0,function*(){return(yield this.next(t,"peek")).value})}next(...t){return this._values.length>0?Promise.resolve({done:!1,value:this._values.shift()}):this._error?Promise.reject({done:!0,value:this._error.error}):this._closedPromiseResolve?new Promise((n,r)=>{this.resolvers.push({resolve:n,reject:r})}):Promise.resolve(Ub)}_ensureOpen(){if(this._closedPromiseResolve)return!0;throw new Error("AsyncQueue is closed")}}class e2 extends YGe{write(t){if((t=Mn(t)).byteLength>0)return super.write(t)}toString(t=!1){return t?ik(this.toUint8Array(!0)):this.toUint8Array(!1).then(ik)}toUint8Array(t=!1){return t?tl(this._values)[0]:Il(this,void 0,void 0,function*(){var n,r,i,s;const o=[];let a=0;try{for(var u=!0,l=My(this),c;c=yield l.next(),n=c.done,!n;u=!0){s=c.value,u=!1;const f=s;o.push(f),a+=f.byteLength}}catch(f){r={error:f}}finally{try{!u&&!n&&(i=l.return)&&(yield i.call(l))}finally{if(r)throw r.error}}return tl(o,a)[0]})}}class lae extends zC{constructor(t){super(t),this._values=new VC(new Uint8Array(0))}get byteLength(){let t=this._pendingLength+this.length*4;return this._offsets&&(t+=this._offsets.byteLength),this._values&&(t+=this._values.byteLength),this._nulls&&(t+=this._nulls.byteLength),t}setValue(t,n){return super.setValue(t,Mn(n))}_flushPending(t,n){const r=this._offsets,i=this._values.reserve(n).buffer;let s=0;for(const[o,a]of t)if(a===void 0)r.set(o,0);else{const u=a.length;i.set(a,s),r.set(o,u),s+=u}}}class KGe extends uo{constructor(t){super(t),this._values=new rae}setValue(t,n){this._values.set(t,+n)}}class HC extends pc{}HC.prototype._setValue=poe;class cae extends HC{}cae.prototype._setValue=fL;class fae extends HC{}fae.prototype._setValue=dL;class dae extends pc{}dae.prototype._setValue=yoe;class QGe extends uo{constructor({type:t,nullValues:n,dictionaryHashFunction:r}){super({type:new Df(t.dictionary,t.indices,t.id,t.isOrdered)}),this._nulls=null,this._dictionaryOffset=0,this._keysToIndices=Object.create(null),this.indices=bI({type:this.type.indices,nullValues:n}),this.dictionary=bI({type:this.type.dictionary,nullValues:null}),typeof r=="function"&&(this.valueToKey=r)}get values(){return this.indices.values}get nullCount(){return this.indices.nullCount}get nullBitmap(){return this.indices.nullBitmap}get byteLength(){return this.indices.byteLength+this.dictionary.byteLength}get reservedLength(){return this.indices.reservedLength+this.dictionary.reservedLength}get reservedByteLength(){return this.indices.reservedByteLength+this.dictionary.reservedByteLength}isValid(t){return this.indices.isValid(t)}setValid(t,n){const r=this.indices;return n=r.setValid(t,n),this.length=r.length,n}setValue(t,n){const r=this._keysToIndices,i=this.valueToKey(n);let s=r[i];return s===void 0&&(r[i]=s=this._dictionaryOffset+this.dictionary.append(n).length-1),this.indices.setValue(t,s)}flush(){const t=this.type,n=this._dictionary,r=this.dictionary.toVector(),i=this.indices.flush().clone(t);return i.dictionary=n?n.concat(r):r,this.finished||(this._dictionaryOffset+=r.length),this._dictionary=i.dictionary,this.clear(),i}finish(){return this.indices.finish(),this.dictionary.finish(),this._dictionaryOffset=0,this._keysToIndices=Object.create(null),super.finish()}clear(){return this.indices.clear(),this.dictionary.clear(),super.clear()}valueToKey(t){return typeof t=="string"?t:`${t}`}}class hae extends pc{}hae.prototype._setValue=hoe;class XGe extends uo{setValue(t,n){const[r]=this.children,i=t*this.stride;for(let s=-1,o=n.length;++s0)throw new Error("FixedSizeListBuilder can only have one child.");const r=this.children.push(t);return this.type=new eg(this.type.listSize,new Rn(n,t.type,!0)),r}}class WC extends pc{setValue(t,n){this._values.set(t,n)}}class JGe extends WC{setValue(t,n){super.setValue(t,coe(n))}}class ZGe extends WC{}class eYe extends WC{}class qC extends pc{}qC.prototype._setValue=boe;class pae extends qC{}pae.prototype._setValue=wL;class mae extends qC{}mae.prototype._setValue=EL;class $g extends pc{}$g.prototype._setValue=woe;class gae extends $g{}gae.prototype._setValue=SL;class yae extends $g{}yae.prototype._setValue=TL;class vae extends $g{}vae.prototype._setValue=IL;class _ae extends $g{}_ae.prototype._setValue=xL;class mc extends pc{setValue(t,n){this._values.set(t,n)}}class tYe extends mc{}class nYe extends mc{}class rYe extends mc{}class iYe extends mc{}class sYe extends mc{}class oYe extends mc{}class aYe extends mc{}class uYe extends mc{}class lYe extends zC{constructor(t){super(t),this._offsets=new iae}addChild(t,n="0"){if(this.numChildren>0)throw new Error("ListBuilder can only have one child.");return this.children[this.numChildren]=t,this.type=new Zm(new Rn(n,t.type,!0)),this.numChildren-1}_flushPending(t){const n=this._offsets,[r]=this.children;for(const[i,s]of t)if(typeof s>"u")n.set(i,0);else{const o=s,a=o.length,u=n.set(i,a).buffer[i];for(let l=-1;++l0)throw new Error("ListBuilder can only have one child.");return this.children[this.numChildren]=t,this.type=new Vv(new Rn(n,t.type,!0),this.type.keysSorted),this.numChildren-1}_flushPending(t){const n=this._offsets,[r]=this.children;for(const[i,s]of t)if(s===void 0)n.set(i,0);else{let{[i]:o,[i+1]:a}=n.set(i,s.size).buffer;for(const u of s.entries())if(r.set(o,u),++o>=a)break}}}class fYe extends uo{setValue(t,n){}setValid(t,n){return this.length=Math.max(t+1,this.length),n}}class dYe extends uo{setValue(t,n){const{children:r,type:i}=this;switch(Array.isArray(n)||n.constructor){case!0:return i.children.forEach((s,o)=>r[o].set(t,n[o]));case Map:return i.children.forEach((s,o)=>r[o].set(t,n.get(s.name)));default:return i.children.forEach((s,o)=>r[o].set(t,n[s.name]))}}setValid(t,n){return super.setValid(t,n)||this.children.forEach(r=>r.setValid(t,n)),n}addChild(t,n=`${this.numChildren}`){const r=this.children.push(t);return this.type=new rs([...this.type.children,new Rn(n,t.type,!0)]),r}}class Lg extends pc{}Lg.prototype._setValue=moe;class bae extends Lg{}bae.prototype._setValue=hL;class wae extends Lg{}wae.prototype._setValue=pL;class Eae extends Lg{}Eae.prototype._setValue=mL;class Sae extends Lg{}Sae.prototype._setValue=gL;class Mg extends pc{}Mg.prototype._setValue=goe;class Tae extends Mg{}Tae.prototype._setValue=yL;class Iae extends Mg{}Iae.prototype._setValue=vL;class xae extends Mg{}xae.prototype._setValue=_L;class Cae extends Mg{}Cae.prototype._setValue=bL;class kL extends uo{constructor(t){super(t),this._typeIds=new s1(new Int8Array(0),1),typeof t.valueToChildTypeId=="function"&&(this._valueToChildTypeId=t.valueToChildTypeId)}get typeIdToChildIndex(){return this.type.typeIdToChildIndex}append(t,n){return this.set(this.length,t,n)}set(t,n,r){return r===void 0&&(r=this._valueToChildTypeId(this,n,t)),this.setValue(t,n,r),this}setValue(t,n,r){this._typeIds.set(t,r);const i=this.type.typeIdToChildIndex[r],s=this.children[i];s==null||s.set(t,n)}addChild(t,n=`${this.children.length}`){const r=this.children.push(t),{type:{children:i,mode:s,typeIds:o}}=this,a=[...i,new Rn(n,t.type)];return this.type=new Uv(s,[...o,r],a),r}_valueToChildTypeId(t,n,r){throw new Error("Cannot map UnionBuilder value to child typeId. Pass the `childTypeId` as the second argument to unionBuilder.append(), or supply a `valueToChildTypeId` function as part of the UnionBuilder constructor options.")}}class hYe extends kL{}class pYe extends kL{constructor(t){super(t),this._offsets=new s1(new Int32Array(0))}setValue(t,n,r){const i=this._typeIds.set(t,r).buffer[t],s=this.getChildAt(this.type.typeIdToChildIndex[i]),o=this._offsets.set(t,s.length).buffer[t];s==null||s.set(o,n)}}class Aae extends zC{constructor(t){super(t),this._values=new VC(new Uint8Array(0))}get byteLength(){let t=this._pendingLength+this.length*4;return this._offsets&&(t+=this._offsets.byteLength),this._values&&(t+=this._values.byteLength),this._nulls&&(t+=this._nulls.byteLength),t}setValue(t,n){return super.setValue(t,Q6(n))}_flushPending(t,n){}}Aae.prototype._flushPending=lae.prototype._flushPending;class mYe extends qt{visitNull(){return fYe}visitBool(){return KGe}visitInt(){return mc}visitInt8(){return tYe}visitInt16(){return nYe}visitInt32(){return rYe}visitInt64(){return iYe}visitUint8(){return sYe}visitUint16(){return oYe}visitUint32(){return aYe}visitUint64(){return uYe}visitFloat(){return WC}visitFloat16(){return JGe}visitFloat32(){return ZGe}visitFloat64(){return eYe}visitUtf8(){return Aae}visitBinary(){return lae}visitFixedSizeBinary(){return hae}visitDate(){return HC}visitDateDay(){return cae}visitDateMillisecond(){return fae}visitTimestamp(){return Lg}visitTimestampSecond(){return bae}visitTimestampMillisecond(){return wae}visitTimestampMicrosecond(){return Eae}visitTimestampNanosecond(){return Sae}visitTime(){return Mg}visitTimeSecond(){return Tae}visitTimeMillisecond(){return Iae}visitTimeMicrosecond(){return xae}visitTimeNanosecond(){return Cae}visitDecimal(){return dae}visitList(){return lYe}visitStruct(){return dYe}visitUnion(){return kL}visitDenseUnion(){return pYe}visitSparseUnion(){return hYe}visitDictionary(){return QGe}visitInterval(){return qC}visitIntervalDayTime(){return pae}visitIntervalYearMonth(){return mae}visitDuration(){return $g}visitDurationSecond(){return gae}visitDurationMillisecond(){return yae}visitDurationMicrosecond(){return vae}visistDurationNanosecond(){return _ae}visitFixedSizeList(){return XGe}visitMap(){return cYe}}const gYe=new mYe;class Et extends qt{compareSchemas(t,n){return t===n||n instanceof t.constructor&&this.compareManyFields(t.fields,n.fields)}compareManyFields(t,n){return t===n||Array.isArray(t)&&Array.isArray(n)&&t.length===n.length&&t.every((r,i)=>this.compareFields(r,n[i]))}compareFields(t,n){return t===n||n instanceof t.constructor&&t.name===n.name&&t.nullable===n.nullable&&this.visit(t.type,n.type)}}function Ts(e,t){return t instanceof e.constructor}function o1(e,t){return e===t||Ts(e,t)}function gc(e,t){return e===t||Ts(e,t)&&e.bitWidth===t.bitWidth&&e.isSigned===t.isSigned}function GC(e,t){return e===t||Ts(e,t)&&e.precision===t.precision}function yYe(e,t){return e===t||Ts(e,t)&&e.byteWidth===t.byteWidth}function DL(e,t){return e===t||Ts(e,t)&&e.unit===t.unit}function a1(e,t){return e===t||Ts(e,t)&&e.unit===t.unit&&e.timezone===t.timezone}function u1(e,t){return e===t||Ts(e,t)&&e.unit===t.unit&&e.bitWidth===t.bitWidth}function vYe(e,t){return e===t||Ts(e,t)&&e.children.length===t.children.length&&Mf.compareManyFields(e.children,t.children)}function _Ye(e,t){return e===t||Ts(e,t)&&e.children.length===t.children.length&&Mf.compareManyFields(e.children,t.children)}function $L(e,t){return e===t||Ts(e,t)&&e.mode===t.mode&&e.typeIds.every((n,r)=>n===t.typeIds[r])&&Mf.compareManyFields(e.children,t.children)}function bYe(e,t){return e===t||Ts(e,t)&&e.id===t.id&&e.isOrdered===t.isOrdered&&Mf.visit(e.indices,t.indices)&&Mf.visit(e.dictionary,t.dictionary)}function LL(e,t){return e===t||Ts(e,t)&&e.unit===t.unit}function l1(e,t){return e===t||Ts(e,t)&&e.unit===t.unit}function wYe(e,t){return e===t||Ts(e,t)&&e.listSize===t.listSize&&e.children.length===t.children.length&&Mf.compareManyFields(e.children,t.children)}function EYe(e,t){return e===t||Ts(e,t)&&e.keysSorted===t.keysSorted&&e.children.length===t.children.length&&Mf.compareManyFields(e.children,t.children)}Et.prototype.visitNull=o1;Et.prototype.visitBool=o1;Et.prototype.visitInt=gc;Et.prototype.visitInt8=gc;Et.prototype.visitInt16=gc;Et.prototype.visitInt32=gc;Et.prototype.visitInt64=gc;Et.prototype.visitUint8=gc;Et.prototype.visitUint16=gc;Et.prototype.visitUint32=gc;Et.prototype.visitUint64=gc;Et.prototype.visitFloat=GC;Et.prototype.visitFloat16=GC;Et.prototype.visitFloat32=GC;Et.prototype.visitFloat64=GC;Et.prototype.visitUtf8=o1;Et.prototype.visitBinary=o1;Et.prototype.visitFixedSizeBinary=yYe;Et.prototype.visitDate=DL;Et.prototype.visitDateDay=DL;Et.prototype.visitDateMillisecond=DL;Et.prototype.visitTimestamp=a1;Et.prototype.visitTimestampSecond=a1;Et.prototype.visitTimestampMillisecond=a1;Et.prototype.visitTimestampMicrosecond=a1;Et.prototype.visitTimestampNanosecond=a1;Et.prototype.visitTime=u1;Et.prototype.visitTimeSecond=u1;Et.prototype.visitTimeMillisecond=u1;Et.prototype.visitTimeMicrosecond=u1;Et.prototype.visitTimeNanosecond=u1;Et.prototype.visitDecimal=o1;Et.prototype.visitList=vYe;Et.prototype.visitStruct=_Ye;Et.prototype.visitUnion=$L;Et.prototype.visitDenseUnion=$L;Et.prototype.visitSparseUnion=$L;Et.prototype.visitDictionary=bYe;Et.prototype.visitInterval=LL;Et.prototype.visitIntervalDayTime=LL;Et.prototype.visitIntervalYearMonth=LL;Et.prototype.visitDuration=l1;Et.prototype.visitDurationSecond=l1;Et.prototype.visitDurationMillisecond=l1;Et.prototype.visitDurationMicrosecond=l1;Et.prototype.visitDurationNanosecond=l1;Et.prototype.visitFixedSizeList=wYe;Et.prototype.visitMap=EYe;const Mf=new Et;function fk(e,t){return Mf.compareSchemas(e,t)}function bI(e){const t=e.type,n=new(gYe.getVisitFn(t)())(e);if(t.children&&t.children.length>0){const r=e.children||[],i={nullValues:e.nullValues},s=Array.isArray(r)?(o,a)=>r[a]||i:({name:o})=>r[o]||i;for(const[o,a]of t.children.entries()){const{type:u}=a,l=s(a,o);n.children.push(bI(Object.assign(Object.assign({},l),{type:u})))}}return n}function t2(e,t){return SYe(e,t.map(n=>n.data.concat()))}function SYe(e,t){const n=[...e.fields],r=[],i={numBatches:t.reduce((f,d)=>Math.max(f,d.length),0)};let s=0,o=0,a=-1;const u=t.length;let l,c=[];for(;i.numBatches-- >0;){for(o=Number.POSITIVE_INFINITY,a=-1;++a0&&(r[s++]=Ji({type:new rs(n),length:o,nullCount:0,children:c.slice()})))}return[e=e.assign(n),r.map(f=>new vo(e,f))]}function TYe(e,t,n,r,i){var s;const o=(t+63&-64)>>3;for(let a=-1,u=r.length;++a=t)c===t?n[a]=l:(n[a]=l.slice(0,t),i.numBatches=Math.max(i.numBatches,r[a].unshift(l.slice(t,c-t))));else{const f=e[a];e[a]=f.clone({nullable:!0}),n[a]=(s=l==null?void 0:l._changeLengthAndBackfillNullBitmap(t))!==null&&s!==void 0?s:Ji({type:f.type,length:t,nullCount:t,nullBitmap:new Uint8Array(o)})}}return n}var Pae;class Us{constructor(...t){var n,r;if(t.length===0)return this.batches=[],this.schema=new Dn([]),this._offsets=[0],this;let i,s;t[0]instanceof Dn&&(i=t.shift()),t.at(-1)instanceof Uint32Array&&(s=t.pop());const o=u=>{if(u){if(u instanceof vo)return[u];if(u instanceof Us)return u.batches;if(u instanceof Ln){if(u.type instanceof rs)return[new vo(new Dn(u.type.children),u)]}else{if(Array.isArray(u))return u.flatMap(l=>o(l));if(typeof u[Symbol.iterator]=="function")return[...u].flatMap(l=>o(l));if(typeof u=="object"){const l=Object.keys(u),c=l.map(h=>new Sn([u[h]])),f=new Dn(l.map((h,p)=>new Rn(String(h),c[p].type))),[,d]=t2(f,c);return d.length===0?[new vo(u)]:d}}}return[]},a=t.flatMap(u=>o(u));if(i=(r=i??((n=a[0])===null||n===void 0?void 0:n.schema))!==null&&r!==void 0?r:new Dn([]),!(i instanceof Dn))throw new TypeError("Table constructor expects a [Schema, RecordBatch[]] pair.");for(const u of a){if(!(u instanceof vo))throw new TypeError("Table constructor expects a [Schema, RecordBatch[]] pair.");if(!fk(i,u.schema))throw new TypeError("Table and inner RecordBatch schemas must be equivalent.")}this.schema=i,this.batches=a,this._offsets=s??Goe(this.data)}get data(){return this.batches.map(({data:t})=>t)}get numCols(){return this.schema.fields.length}get numRows(){return this.data.reduce((t,n)=>t+n.length,0)}get nullCount(){return this._nullCount===-1&&(this._nullCount=qoe(this.data)),this._nullCount}isValid(t){return!1}get(t){return null}set(t,n){}indexOf(t,n){return-1}getByteLength(t){return 0}[Symbol.iterator](){return this.batches.length>0?NL.visit(new Sn(this.data)):new Array(0)[Symbol.iterator]()}toArray(){return[...this]}toString(){return`[ ${this.toArray().join(`, `)} -]`}concat(...t){const n=this.schema,r=this.data.concat(t.flatMap(({data:i})=>i));return new Us(n,r.map(i=>new vo(n,i)))}slice(t,n){const r=this.schema;[t,n]=zoe({length:this.numRows},t,n);const i=Yoe(this.data,this._offsets,t,n);return new Us(r,i.map(s=>new vo(r,s)))}getChild(t){return this.getChildAt(this.schema.fields.findIndex(n=>n.name===t))}getChildAt(t){if(t>-1&&tr.children[t]);if(n.length===0){const{type:r}=this.schema.fields[t],i=Ji({type:r,length:0,nullCount:0});n.push(i._changeLengthAndBackfillNullBitmap(this.numRows))}return new Sn(n)}return null}setChild(t,n){var r;return this.setChildAt((r=this.schema.fields)===null||r===void 0?void 0:r.findIndex(i=>i.name===t),n)}setChildAt(t,n){let r=this.schema,i=[...this.batches];if(t>-1&&tthis.getChildAt(l));[s[t],a[t]]=[o,n],[r,i]=n2(r,a)}return new Us(r,i)}select(t){const n=this.schema.fields.reduce((r,i,s)=>r.set(i.name,s),new Map);return this.selectAt(t.map(r=>n.get(r)).filter(r=>r>-1))}selectAt(t){const n=this.schema.selectAt(t),r=this.batches.map(i=>i.selectAt(t));return new Us(n,r)}assign(t){const n=this.schema.fields,[r,i]=t.schema.fields.reduce((a,u,l)=>{const[c,f]=a,d=n.findIndex(h=>h.name===u.name);return~d?f[d]=l:c.push(l),a},[[],[]]),s=this.schema.assign(t.schema),o=[...n.map((a,u)=>[u,i[u]]).map(([a,u])=>u===void 0?this.getChildAt(a):t.getChildAt(u)),...r.map(a=>t.getChildAt(a))].filter(Boolean);return new Us(...n2(s,o))}}Pae=Symbol.toStringTag;Us[Pae]=(e=>(e.schema=null,e.batches=[],e._offsets=new Uint32Array([0]),e._nullCount=-1,e[Symbol.isConcatSpreadable]=!0,e.isValid=gm(NL),e.get=gm(oo.getVisitFn(G.Struct)),e.set=Koe(ca.getVisitFn(G.Struct)),e.indexOf=Qoe(dI.getVisitFn(G.Struct)),e.getByteLength=gm(il.getVisitFn(G.Struct)),"Table"))(Us.prototype);var Oae;let vo=class ny{constructor(...t){switch(t.length){case 2:{if([this.schema]=t,!(this.schema instanceof Dn))throw new TypeError("RecordBatch constructor expects a [Schema, Data] pair.");if([,this.data=Ji({nullCount:0,type:new rs(this.schema.fields),children:this.schema.fields.map(n=>Ji({type:n.type,nullCount:0}))})]=t,!(this.data instanceof Ln))throw new TypeError("RecordBatch constructor expects a [Schema, Data] pair.");[this.schema,this.data]=Mz(this.schema,this.data.children);break}case 1:{const[n]=t,{fields:r,children:i,length:s}=Object.keys(n).reduce((u,l,c)=>(u.children[c]=n[l],u.length=Math.max(u.length,n[l].length),u.fields[c]=Rn.new({name:l,type:n[l].type,nullable:!0}),u),{length:0,fields:new Array,children:new Array}),o=new Dn(r),a=Ji({type:new rs(r),length:s,children:i,nullCount:0});[this.schema,this.data]=Mz(o,a.children,s);break}default:throw new TypeError("RecordBatch constructor expects an Object mapping names to child Data, or a [Schema, Data] pair.")}}get dictionaries(){return this._dictionaries||(this._dictionaries=Rae(this.schema.fields,this.data.children))}get numCols(){return this.schema.fields.length}get numRows(){return this.data.length}get nullCount(){return this.data.nullCount}isValid(t){return this.data.getValid(t)}get(t){return oo.visit(this.data,t)}set(t,n){return ca.visit(this.data,t,n)}indexOf(t,n){return dI.visit(this.data,t,n)}getByteLength(t){return il.visit(this.data,t)}[Symbol.iterator](){return kL.visit(new Sn([this.data]))}toArray(){return[...this]}concat(...t){return new Us(this.schema,[this,...t])}slice(t,n){const[r]=new Sn([this.data]).slice(t,n).data;return new ny(this.schema,r)}getChild(t){var n;return this.getChildAt((n=this.schema.fields)===null||n===void 0?void 0:n.findIndex(r=>r.name===t))}getChildAt(t){return t>-1&&ti.name===t),n)}setChildAt(t,n){let r=this.schema,i=this.data;if(t>-1&&ta.name===s);~o&&(i[o]=this.data.children[o])}return new ny(n,Ji({type:r,length:this.numRows,children:i}))}selectAt(t){const n=this.schema.selectAt(t),r=t.map(s=>this.data.children[s]).filter(Boolean),i=Ji({type:new rs(n.fields),length:this.numRows,children:r});return new ny(n,i)}};Oae=Symbol.toStringTag;vo[Oae]=(e=>(e._nullCount=-1,e[Symbol.isConcatSpreadable]=!0,"RecordBatch"))(vo.prototype);function Mz(e,t,n=t.reduce((r,i)=>Math.max(r,i.length),0)){var r;const i=[...e.fields],s=[...t],o=(n+63&-64)>>3;for(const[a,u]of e.fields.entries()){const l=t[a];(!l||l.length!==n)&&(i[a]=u.clone({nullable:!0}),s[a]=(r=l==null?void 0:l._changeLengthAndBackfillNullBitmap(n))!==null&&r!==void 0?r:Ji({type:u.type,length:n,nullCount:n,nullBitmap:new Uint8Array(o)}))}return[e.assign(i),Ji({type:new rs(i),length:n,children:s})]}function Rae(e,t,n=new Map){var r,i;if(((r=e==null?void 0:e.length)!==null&&r!==void 0?r:0)>0&&(e==null?void 0:e.length)===(t==null?void 0:t.length))for(let s=-1,o=e.length;++sJi({type:i.type})),r=Ji({type:new rs(t.fields),nullCount:0,children:n});super(t,r)}}var wI;(function(e){e[e.BUFFER=0]="BUFFER"})(wI||(wI={}));var EI;(function(e){e[e.LZ4_FRAME=0]="LZ4_FRAME",e[e.ZSTD=1]="ZSTD"})(EI||(EI={}));class Mc{constructor(){this.bb=null,this.bb_pos=0}__init(t,n){return this.bb_pos=t,this.bb=n,this}static getRootAsBodyCompression(t,n){return(n||new Mc).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsBodyCompression(t,n){return t.setPosition(t.position()+Wn),(n||new Mc).__init(t.readInt32(t.position())+t.position(),t)}codec(){const t=this.bb.__offset(this.bb_pos,4);return t?this.bb.readInt8(this.bb_pos+t):EI.LZ4_FRAME}method(){const t=this.bb.__offset(this.bb_pos,6);return t?this.bb.readInt8(this.bb_pos+t):wI.BUFFER}static startBodyCompression(t){t.startObject(2)}static addCodec(t,n){t.addFieldInt8(0,n,EI.LZ4_FRAME)}static addMethod(t,n){t.addFieldInt8(1,n,wI.BUFFER)}static endBodyCompression(t){return t.endObject()}static createBodyCompression(t,n,r){return Mc.startBodyCompression(t),Mc.addCodec(t,n),Mc.addMethod(t,r),Mc.endBodyCompression(t)}}class Nae{constructor(){this.bb=null,this.bb_pos=0}__init(t,n){return this.bb_pos=t,this.bb=n,this}offset(){return this.bb.readInt64(this.bb_pos)}length(){return this.bb.readInt64(this.bb_pos+8)}static sizeOf(){return 16}static createBuffer(t,n,r){return t.prep(8,16),t.writeInt64(BigInt(r??0)),t.writeInt64(BigInt(n??0)),t.offset()}}let kae=class{constructor(){this.bb=null,this.bb_pos=0}__init(t,n){return this.bb_pos=t,this.bb=n,this}length(){return this.bb.readInt64(this.bb_pos)}nullCount(){return this.bb.readInt64(this.bb_pos+8)}static sizeOf(){return 16}static createFieldNode(t,n,r){return t.prep(8,16),t.writeInt64(BigInt(r??0)),t.writeInt64(BigInt(n??0)),t.offset()}},bl=class hk{constructor(){this.bb=null,this.bb_pos=0}__init(t,n){return this.bb_pos=t,this.bb=n,this}static getRootAsRecordBatch(t,n){return(n||new hk).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsRecordBatch(t,n){return t.setPosition(t.position()+Wn),(n||new hk).__init(t.readInt32(t.position())+t.position(),t)}length(){const t=this.bb.__offset(this.bb_pos,4);return t?this.bb.readInt64(this.bb_pos+t):BigInt("0")}nodes(t,n){const r=this.bb.__offset(this.bb_pos,6);return r?(n||new kae).__init(this.bb.__vector(this.bb_pos+r)+t*16,this.bb):null}nodesLength(){const t=this.bb.__offset(this.bb_pos,6);return t?this.bb.__vector_len(this.bb_pos+t):0}buffers(t,n){const r=this.bb.__offset(this.bb_pos,8);return r?(n||new Nae).__init(this.bb.__vector(this.bb_pos+r)+t*16,this.bb):null}buffersLength(){const t=this.bb.__offset(this.bb_pos,8);return t?this.bb.__vector_len(this.bb_pos+t):0}compression(t){const n=this.bb.__offset(this.bb_pos,10);return n?(t||new Mc).__init(this.bb.__indirect(this.bb_pos+n),this.bb):null}static startRecordBatch(t){t.startObject(4)}static addLength(t,n){t.addFieldInt64(0,n,BigInt("0"))}static addNodes(t,n){t.addFieldOffset(1,n,0)}static startNodesVector(t,n){t.startVector(16,n,8)}static addBuffers(t,n){t.addFieldOffset(2,n,0)}static startBuffersVector(t,n){t.startVector(16,n,8)}static addCompression(t,n){t.addFieldOffset(3,n,0)}static endRecordBatch(t){return t.endObject()}},yp=class pk{constructor(){this.bb=null,this.bb_pos=0}__init(t,n){return this.bb_pos=t,this.bb=n,this}static getRootAsDictionaryBatch(t,n){return(n||new pk).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsDictionaryBatch(t,n){return t.setPosition(t.position()+Wn),(n||new pk).__init(t.readInt32(t.position())+t.position(),t)}id(){const t=this.bb.__offset(this.bb_pos,4);return t?this.bb.readInt64(this.bb_pos+t):BigInt("0")}data(t){const n=this.bb.__offset(this.bb_pos,6);return n?(t||new bl).__init(this.bb.__indirect(this.bb_pos+n),this.bb):null}isDelta(){const t=this.bb.__offset(this.bb_pos,8);return t?!!this.bb.readInt8(this.bb_pos+t):!1}static startDictionaryBatch(t){t.startObject(3)}static addId(t,n){t.addFieldInt64(0,n,BigInt("0"))}static addData(t,n){t.addFieldOffset(1,n,0)}static addIsDelta(t,n){t.addFieldInt8(2,+n,0)}static endDictionaryBatch(t){return t.endObject()}};var SI;(function(e){e[e.NONE=0]="NONE",e[e.Schema=1]="Schema",e[e.DictionaryBatch=2]="DictionaryBatch",e[e.RecordBatch=3]="RecordBatch",e[e.Tensor=4]="Tensor",e[e.SparseTensor=5]="SparseTensor"})(SI||(SI={}));let xc=class au{constructor(){this.bb=null,this.bb_pos=0}__init(t,n){return this.bb_pos=t,this.bb=n,this}static getRootAsMessage(t,n){return(n||new au).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsMessage(t,n){return t.setPosition(t.position()+Wn),(n||new au).__init(t.readInt32(t.position())+t.position(),t)}version(){const t=this.bb.__offset(this.bb_pos,4);return t?this.bb.readInt16(this.bb_pos+t):tg.V1}headerType(){const t=this.bb.__offset(this.bb_pos,6);return t?this.bb.readUint8(this.bb_pos+t):SI.NONE}header(t){const n=this.bb.__offset(this.bb_pos,8);return n?this.bb.__union(t,this.bb_pos+n):null}bodyLength(){const t=this.bb.__offset(this.bb_pos,10);return t?this.bb.readInt64(this.bb_pos+t):BigInt("0")}customMetadata(t,n){const r=this.bb.__offset(this.bb_pos,12);return r?(n||new Zr).__init(this.bb.__indirect(this.bb.__vector(this.bb_pos+r)+t*4),this.bb):null}customMetadataLength(){const t=this.bb.__offset(this.bb_pos,12);return t?this.bb.__vector_len(this.bb_pos+t):0}static startMessage(t){t.startObject(5)}static addVersion(t,n){t.addFieldInt16(0,n,tg.V1)}static addHeaderType(t,n){t.addFieldInt8(1,n,SI.NONE)}static addHeader(t,n){t.addFieldOffset(2,n,0)}static addBodyLength(t,n){t.addFieldInt64(3,n,BigInt("0"))}static addCustomMetadata(t,n){t.addFieldOffset(4,n,0)}static createCustomMetadataVector(t,n){t.startVector(4,n.length,4);for(let r=n.length-1;r>=0;r--)t.addOffset(n[r]);return t.endVector()}static startCustomMetadataVector(t,n){t.startVector(4,n,4)}static endMessage(t){return t.endObject()}static finishMessageBuffer(t,n){t.finish(n)}static finishSizePrefixedMessageBuffer(t,n){t.finish(n,void 0,!0)}static createMessage(t,n,r,i,s,o){return au.startMessage(t),au.addVersion(t,n),au.addHeaderType(t,r),au.addHeader(t,i),au.addBodyLength(t,s),au.addCustomMetadata(t,o),au.endMessage(t)}};class IYe extends qt{visit(t,n){return t==null||n==null?void 0:super.visit(t,n)}visitNull(t,n){return Vd.startNull(n),Vd.endNull(n)}visitInt(t,n){return yo.startInt(n),yo.addBitWidth(n,t.bitWidth),yo.addIsSigned(n,t.isSigned),yo.endInt(n)}visitFloat(t,n){return Iu.startFloatingPoint(n),Iu.addPrecision(n,t.precision),Iu.endFloatingPoint(n)}visitBinary(t,n){return Bd.startBinary(n),Bd.endBinary(n)}visitBool(t,n){return jd.startBool(n),jd.endBool(n)}visitUtf8(t,n){return Hd.startUtf8(n),Hd.endUtf8(n)}visitDecimal(t,n){return Ms.startDecimal(n),Ms.addScale(n,t.scale),Ms.addPrecision(n,t.precision),Ms.addBitWidth(n,t.bitWidth),Ms.endDecimal(n)}visitDate(t,n){return zw.startDate(n),zw.addUnit(n,t.unit),zw.endDate(n)}visitTime(t,n){return Go.startTime(n),Go.addUnit(n,t.unit),Go.addBitWidth(n,t.bitWidth),Go.endTime(n)}visitTimestamp(t,n){const r=t.timezone&&n.createString(t.timezone)||void 0;return ty.startTimestamp(n),ty.addUnit(n,t.unit),r!==void 0&&ty.addTimezone(n,r),ty.endTimestamp(n)}visitInterval(t,n){return xu.startInterval(n),xu.addUnit(n,t.unit),xu.endInterval(n)}visitDuration(t,n){return Eu.startDuration(n),Eu.addUnit(n,t.unit),Eu.endDuration(n)}visitList(t,n){return Ud.startList(n),Ud.endList(n)}visitStruct(t,n){return zd.startStruct_(n),zd.endStruct_(n)}visitUnion(t,n){js.startTypeIdsVector(n,t.typeIds.length);const r=js.createTypeIdsVector(n,t.typeIds);return js.startUnion(n),js.addMode(n,t.mode),js.addTypeIds(n,r),js.endUnion(n)}visitDictionary(t,n){const r=this.visit(t.indices,n);return Cl.startDictionaryEncoding(n),Cl.addId(n,BigInt(t.id)),Cl.addIsOrdered(n,t.isOrdered),r!==void 0&&Cl.addIndexType(n,r),Cl.endDictionaryEncoding(n)}visitFixedSizeBinary(t,n){return Su.startFixedSizeBinary(n),Su.addByteWidth(n,t.byteWidth),Su.endFixedSizeBinary(n)}visitFixedSizeList(t,n){return Tu.startFixedSizeList(n),Tu.addListSize(n,t.listSize),Tu.endFixedSizeList(n)}visitMap(t,n){return Hw.startMap(n),Hw.addKeysSorted(n,t.keysSorted),Hw.endMap(n)}}const r2=new IYe;function xYe(e,t=new Map){return new Dn(AYe(e,t),qw(e.metadata),t)}function Dae(e){return new No(e.count,$ae(e.columns),Lae(e.columns))}function CYe(e){return new sl(Dae(e.data),e.id,e.isDelta)}function AYe(e,t){return(e.fields||[]).filter(Boolean).map(n=>Rn.fromJSON(n,t))}function Fz(e,t){return(e.children||[]).filter(Boolean).map(n=>Rn.fromJSON(n,t))}function $ae(e){return(e||[]).reduce((t,n)=>[...t,new Ff(n.count,PYe(n.VALIDITY)),...$ae(n.children)],[])}function Lae(e,t=[]){for(let n=-1,r=(e||[]).length;++nt+ +(n===0),0)}function OYe(e,t){let n,r,i,s,o,a;return!t||!(s=e.dictionary)?(o=jz(e,Fz(e,t)),i=new Rn(e.name,o,e.nullable,qw(e.metadata))):t.has(n=s.id)?(r=(r=s.indexType)?Bz(r):new Nf,a=new Df(t.get(n),r,n,s.isOrdered),i=new Rn(e.name,a,e.nullable,qw(e.metadata))):(r=(r=s.indexType)?Bz(r):new Nf,t.set(n,o=jz(e,Fz(e,t))),a=new Df(o,r,n,s.isOrdered),i=new Rn(e.name,a,e.nullable,qw(e.metadata))),i||null}function qw(e=[]){return new Map(e.map(({key:t,value:n})=>[t,n]))}function Bz(e){return new ws(e.isSigned,e.bitWidth)}function jz(e,t){const n=e.type.name;switch(n){case"NONE":return new Jl;case"null":return new Jl;case"binary":return new Bv;case"utf8":return new Qm;case"bool":return new jv;case"list":return new Zm((t||[])[0]);case"struct":return new rs(t||[]);case"struct_":return new rs(t||[])}switch(n){case"int":{const r=e.type;return new ws(r.isSigned,r.bitWidth)}case"floatingpoint":{const r=e.type;return new kf($i[r.precision])}case"decimal":{const r=e.type;return new aI(r.scale,r.precision,r.bitWidth)}case"date":{const r=e.type;return new Xm(nl[r.unit])}case"time":{const r=e.type;return new Zl(vt[r.unit],r.bitWidth)}case"timestamp":{const r=e.type;return new uI(vt[r.unit],r.timezone)}case"interval":{const r=e.type;return new Jm(rl[r.unit])}case"duration":{const r=e.type;return new lI(vt[r.unit])}case"union":{const r=e.type,[i,...s]=(r.mode+"").toLowerCase(),o=i.toUpperCase()+s.join("");return new Uv(so[o],r.typeIds||[],t||[])}case"fixedsizebinary":{const r=e.type;return new cI(r.byteWidth)}case"fixedsizelist":{const r=e.type;return new eg(r.listSize,(t||[])[0])}case"map":{const r=e.type;return new Vv((t||[])[0],r.keysSorted)}}throw new Error(`Unrecognized type: "${n}"`)}var RYe=oae,NYe=pI;class Cu{static fromJSON(t,n){const r=new Cu(0,gs.V5,n);return r._createHeader=kYe(t,n),r}static decode(t){t=new NYe(Mn(t));const n=xc.getRootAsMessage(t),r=n.bodyLength(),i=n.version(),s=n.headerType(),o=new Cu(r,i,s);return o._createHeader=DYe(n,s),o}static encode(t){const n=new RYe;let r=-1;return t.isSchema()?r=Dn.encode(n,t.header()):t.isRecordBatch()?r=No.encode(n,t.header()):t.isDictionaryBatch()&&(r=sl.encode(n,t.header())),xc.startMessage(n),xc.addVersion(n,gs.V5),xc.addHeader(n,r),xc.addHeaderType(n,t.headerType),xc.addBodyLength(n,BigInt(t.bodyLength)),xc.finishMessageBuffer(n,xc.endMessage(n)),n.asUint8Array()}static from(t,n=0){if(t instanceof Dn)return new Cu(0,gs.V5,pi.Schema,t);if(t instanceof No)return new Cu(n,gs.V5,pi.RecordBatch,t);if(t instanceof sl)return new Cu(n,gs.V5,pi.DictionaryBatch,t);throw new Error(`Unrecognized Message header: ${t}`)}get type(){return this.headerType}get version(){return this._version}get headerType(){return this._headerType}get bodyLength(){return this._bodyLength}header(){return this._createHeader()}isSchema(){return this.headerType===pi.Schema}isRecordBatch(){return this.headerType===pi.RecordBatch}isDictionaryBatch(){return this.headerType===pi.DictionaryBatch}constructor(t,n,r,i){this._version=n,this._headerType=r,this.body=new Uint8Array(0),i&&(this._createHeader=()=>i),this._bodyLength=Ka(t)}}class No{get nodes(){return this._nodes}get length(){return this._length}get buffers(){return this._buffers}constructor(t,n,r){this._nodes=n,this._buffers=r,this._length=Ka(t)}}class sl{get id(){return this._id}get data(){return this._data}get isDelta(){return this._isDelta}get length(){return this.data.length}get nodes(){return this.data.nodes}get buffers(){return this.data.buffers}constructor(t,n,r=!1){this._data=t,this._isDelta=r,this._id=Ka(n)}}class Nu{constructor(t,n){this.offset=Ka(t),this.length=Ka(n)}}class Ff{constructor(t,n){this.length=Ka(t),this.nullCount=Ka(n)}}function kYe(e,t){return()=>{switch(t){case pi.Schema:return Dn.fromJSON(e);case pi.RecordBatch:return No.fromJSON(e);case pi.DictionaryBatch:return sl.fromJSON(e)}throw new Error(`Unrecognized Message type: { name: ${pi[t]}, type: ${t} }`)}}function DYe(e,t){return()=>{switch(t){case pi.Schema:return Dn.decode(e.header(new du),new Map,e.version());case pi.RecordBatch:return No.decode(e.header(new bl),e.version());case pi.DictionaryBatch:return sl.decode(e.header(new yp),e.version())}throw new Error(`Unrecognized Message type: { name: ${pi[t]}, type: ${t} }`)}}Rn.encode=WYe;Rn.decode=zYe;Rn.fromJSON=OYe;Dn.encode=HYe;Dn.decode=$Ye;Dn.fromJSON=xYe;No.encode=qYe;No.decode=LYe;No.fromJSON=Dae;sl.encode=GYe;sl.decode=MYe;sl.fromJSON=CYe;Ff.encode=YYe;Ff.decode=BYe;Nu.encode=KYe;Nu.decode=FYe;function $Ye(e,t=new Map,n=gs.V5){const r=VYe(e,t);return new Dn(r,Gw(e),t,n)}function LYe(e,t=gs.V5){if(e.compression()!==null)throw new Error("Record batch compression not implemented");return new No(e.length(),jYe(e),UYe(e,t))}function MYe(e,t=gs.V5){return new sl(No.decode(e.data(),t),e.id(),e.isDelta())}function FYe(e){return new Nu(e.offset(),e.length())}function BYe(e){return new Ff(e.length(),e.nullCount())}function jYe(e){const t=[];for(let n,r=-1,i=-1,s=e.nodesLength();++rRn.encode(e,s));du.startFieldsVector(e,n.length);const r=du.createFieldsVector(e,n),i=t.metadata&&t.metadata.size>0?du.createCustomMetadataVector(e,[...t.metadata].map(([s,o])=>{const a=e.createString(`${s}`),u=e.createString(`${o}`);return Zr.startKeyValue(e),Zr.addKey(e,a),Zr.addValue(e,u),Zr.endKeyValue(e)})):-1;return du.startSchema(e),du.addFields(e,r),du.addEndianness(e,QYe?ng.Little:ng.Big),i!==-1&&du.addCustomMetadata(e,i),du.endSchema(e)}function WYe(e,t){let n=-1,r=-1,i=-1;const s=t.type;let o=t.typeId;Bt.isDictionary(s)?(o=s.dictionary.typeId,i=r2.visit(s,e),r=r2.visit(s.dictionary,e)):r=r2.visit(s,e);const a=(s.children||[]).map(c=>Rn.encode(e,c)),u=Uo.createChildrenVector(e,a),l=t.metadata&&t.metadata.size>0?Uo.createCustomMetadataVector(e,[...t.metadata].map(([c,f])=>{const d=e.createString(`${c}`),h=e.createString(`${f}`);return Zr.startKeyValue(e),Zr.addKey(e,d),Zr.addValue(e,h),Zr.endKeyValue(e)})):-1;return t.name&&(n=e.createString(t.name)),Uo.startField(e),Uo.addType(e,r),Uo.addTypeType(e,o),Uo.addChildren(e,u),Uo.addNullable(e,!!t.nullable),n!==-1&&Uo.addName(e,n),i!==-1&&Uo.addDictionary(e,i),l!==-1&&Uo.addCustomMetadata(e,l),Uo.endField(e)}function qYe(e,t){const n=t.nodes||[],r=t.buffers||[];bl.startNodesVector(e,n.length);for(const o of n.slice().reverse())Ff.encode(e,o);const i=e.endVector();bl.startBuffersVector(e,r.length);for(const o of r.slice().reverse())Nu.encode(e,o);const s=e.endVector();return bl.startRecordBatch(e),bl.addLength(e,BigInt(t.length)),bl.addNodes(e,i),bl.addBuffers(e,s),bl.endRecordBatch(e)}function GYe(e,t){const n=No.encode(e,t.data);return yp.startDictionaryBatch(e),yp.addId(e,BigInt(t.id)),yp.addIsDelta(e,t.isDelta),yp.addData(e,n),yp.endDictionaryBatch(e)}function YYe(e,t){return kae.createFieldNode(e,BigInt(t.length),BigInt(t.nullCount))}function KYe(e,t){return Nae.createBuffer(e,BigInt(t.offset),BigInt(t.length))}const QYe=(()=>{const e=new ArrayBuffer(2);return new DataView(e).setInt16(0,256,!0),new Int16Array(e)[0]===256})(),mk="ARROW1",FL=new Uint8Array(mk.length);for(let e=0;ei.flatMap(s=>Array.isArray(s)?n(s):s instanceof vo?s.data.children:s.data),r=new Br;return r.visitMany(n(t)),r}constructor(){super(),this._byteLength=0,this._nodes=[],this._buffers=[],this._bufferRegions=[]}visit(t){if(t instanceof Sn)return this.visitMany(t.data),this;const{type:n}=t;if(!Bt.isDictionary(n)){const{length:r}=t;if(r>2147483647)throw new RangeError("Cannot write arrays larger than 2^31 - 1 in length");if(Bt.isUnion(n))this.nodes.push(new Ff(r,0));else{const{nullCount:i}=t;Bt.isNull(n)||za.call(this,i<=0?new Uint8Array(0):fI(t.offset,r,t.nullBitmap)),this.nodes.push(new Ff(r,i))}}return super.visit(t)}visitNull(t){return this}visitDictionary(t){return this.visit(t.clone(t.type.indices))}get nodes(){return this._nodes}get buffers(){return this._buffers}get byteLength(){return this._byteLength}get bufferRegions(){return this._bufferRegions}}function za(e){const t=e.byteLength+7&-8;return this.buffers.push(e),this.bufferRegions.push(new Nu(this._byteLength,t)),this._byteLength+=t,this}function XYe(e){var t;const{type:n,length:r,typeIds:i,valueOffsets:s}=e;if(za.call(this,i),n.mode===so.Sparse)return gk.call(this,e);if(n.mode===so.Dense){if(e.offset<=0)return za.call(this,s),gk.call(this,e);{const o=new Int32Array(r),a=Object.create(null),u=Object.create(null);for(let l,c,f=-1;++f{const f=n.typeIds[c],d=a[f],h=u[f];return l.slice(d,Math.min(r,h))}))}}return this}function JYe(e){let t;return e.nullCount>=e.length?za.call(this,new Uint8Array(0)):(t=e.values)instanceof Uint8Array?za.call(this,fI(e.offset,e.length,t)):za.call(this,Woe(e.values))}function yc(e){return za.call(this,e.values.subarray(0,e.length*e.stride))}function Mae(e){const{length:t,values:n,valueOffsets:r}=e,{[0]:i,[t]:s}=r,o=Math.min(s-i,n.byteLength-i);return za.call(this,Bse(-i,t+1,r)),za.call(this,n.subarray(i,i+o)),this}function BL(e){const{length:t,valueOffsets:n}=e;if(n){const{[0]:r,[t]:i}=n;return za.call(this,Bse(-r,t+1,n)),this.visit(e.children[0].slice(r,i-r))}return this.visit(e.children[0])}function gk(e){return this.visitMany(e.type.children.map((t,n)=>e.children[n]).filter(Boolean))[0]}Br.prototype.visitBool=JYe;Br.prototype.visitInt=yc;Br.prototype.visitFloat=yc;Br.prototype.visitUtf8=Mae;Br.prototype.visitBinary=Mae;Br.prototype.visitFixedSizeBinary=yc;Br.prototype.visitDate=yc;Br.prototype.visitTimestamp=yc;Br.prototype.visitTime=yc;Br.prototype.visitDecimal=yc;Br.prototype.visitList=BL;Br.prototype.visitStruct=gk;Br.prototype.visitUnion=XYe;Br.prototype.visitInterval=yc;Br.prototype.visitDuration=yc;Br.prototype.visitFixedSizeList=BL;Br.prototype.visitMap=BL;class Fae extends uae{static throughNode(t){throw new Error('"throughNode" not available in this environment')}static throughDOM(t,n){throw new Error('"throughDOM" not available in this environment')}constructor(t){super(),this._position=0,this._started=!1,this._sink=new t2,this._schema=null,this._dictionaryBlocks=[],this._recordBatchBlocks=[],this._dictionaryDeltaOffsets=new Map,Zf(t)||(t={autoDestroy:!0,writeLegacyIpcFormat:!1}),this._autoDestroy=typeof t.autoDestroy=="boolean"?t.autoDestroy:!0,this._writeLegacyIpcFormat=typeof t.writeLegacyIpcFormat=="boolean"?t.writeLegacyIpcFormat:!1}toString(t=!1){return this._sink.toString(t)}toUint8Array(t=!1){return this._sink.toUint8Array(t)}writeAll(t){return FC(t)?t.then(n=>this.writeAll(n)):BC(t)?zL(this,t):VL(this,t)}get closed(){return this._sink.closed}[Symbol.asyncIterator](){return this._sink[Symbol.asyncIterator]()}toDOMStream(t){return this._sink.toDOMStream(t)}toNodeStream(t){return this._sink.toNodeStream(t)}close(){return this.reset()._sink.close()}abort(t){return this.reset()._sink.abort(t)}finish(){return this._autoDestroy?this.close():this.reset(this._sink,this._schema),this}reset(t=this._sink,n=null){return t===this._sink||t instanceof t2?this._sink=t:(this._sink=new t2,t&&iqe(t)?this.toDOMStream({type:"bytes"}).pipeTo(t):t&&sqe(t)&&this.toNodeStream({objectMode:!1}).pipe(t)),this._started&&this._schema&&this._writeFooter(this._schema),this._started=!1,this._dictionaryBlocks=[],this._recordBatchBlocks=[],this._dictionaryDeltaOffsets=new Map,(!n||!dk(n,this._schema))&&(n==null?(this._position=0,this._schema=null):(this._started=!0,this._schema=n,this._writeSchema(n))),this}write(t){let n=null;if(this._sink){if(t==null)return this.finish()&&void 0;if(t instanceof Us&&!(n=t.schema))return this.finish()&&void 0;if(t instanceof vo&&!(n=t.schema))return this.finish()&&void 0}else throw new Error("RecordBatchWriter is closed");if(n&&!dk(n,this._schema)){if(this._started&&this._autoDestroy)return this.close();this.reset(this._sink,n)}t instanceof vo?t instanceof TYe||this._writeRecordBatch(t):t instanceof Us?this.writeAll(t.batches):J6(t)&&this.writeAll(t)}_writeMessage(t,n=8){const r=n-1,i=Cu.encode(t),s=i.byteLength,o=this._writeLegacyIpcFormat?4:8,a=s+o+r&~r,u=a-s-o;return t.headerType===pi.RecordBatch?this._recordBatchBlocks.push(new Lf(a,t.bodyLength,this._position)):t.headerType===pi.DictionaryBatch&&this._dictionaryBlocks.push(new Lf(a,t.bodyLength,this._position)),this._writeLegacyIpcFormat||this._write(Int32Array.of(-1)),this._write(Int32Array.of(a-o)),s>0&&this._write(i),this._writePadding(u)}_write(t){if(this._started){const n=Mn(t);n&&n.byteLength>0&&(this._sink.write(n),this._position+=n.byteLength)}return this}_writeSchema(t){return this._writeMessage(Cu.from(t))}_writeFooter(t){return this._writeLegacyIpcFormat?this._write(Int32Array.of(0)):this._write(Int32Array.of(-1,0))}_writeMagic(){return this._write(FL)}_writePadding(t){return t>0?this._write(new Uint8Array(t)):this}_writeRecordBatch(t){const{byteLength:n,nodes:r,bufferRegions:i,buffers:s}=Br.assemble(t),o=new No(t.numRows,r,i),a=Cu.from(o,n);return this._writeDictionaries(t)._writeMessage(a)._writeBodyBuffers(s)}_writeDictionaryBatch(t,n,r=!1){this._dictionaryDeltaOffsets.set(n,t.length+(this._dictionaryDeltaOffsets.get(n)||0));const{byteLength:i,nodes:s,bufferRegions:o,buffers:a}=Br.assemble(new Sn([t])),u=new No(t.length,s,o),l=new sl(u,n,r),c=Cu.from(l,i);return this._writeMessage(c)._writeBodyBuffers(a)}_writeBodyBuffers(t){let n,r,i;for(let s=-1,o=t.length;++s0&&(this._write(n),(i=(r+7&-8)-r)>0&&this._writePadding(i));return this}_writeDictionaries(t){for(let[n,r]of t.dictionaries){let i=this._dictionaryDeltaOffsets.get(n)||0;if(i===0||(r=r==null?void 0:r.slice(i)).length>0)for(const s of r.data)this._writeDictionaryBatch(s,n,i>0),i+=s.length}return this}}class jL extends Fae{static writeAll(t,n){const r=new jL(n);return FC(t)?t.then(i=>r.writeAll(i)):BC(t)?zL(r,t):VL(r,t)}}class UL extends Fae{static writeAll(t){const n=new UL;return FC(t)?t.then(r=>n.writeAll(r)):BC(t)?zL(n,t):VL(n,t)}constructor(){super(),this._autoDestroy=!0}_writeSchema(t){return this._writeMagic()._writePadding(2)}_writeFooter(t){const n=fk.encode(new fk(t,gs.V5,this._recordBatchBlocks,this._dictionaryBlocks));return super._writeFooter(t)._write(n)._write(Int32Array.of(n.byteLength))._writeMagic()}}function VL(e,t){let n=t;t instanceof Us&&(n=t.batches,e.reset(void 0,t.schema));for(const r of n)e.write(r);return e.finish()}function zL(e,t){var n,r,i,s,o,a,u;return Il(this,void 0,void 0,function*(){try{for(n=!0,r=My(t);i=yield r.next(),s=i.done,!s;n=!0){u=i.value,n=!1;const l=u;e.write(l)}}catch(l){o={error:l}}finally{try{!n&&!s&&(a=r.return)&&(yield a.call(r))}finally{if(o)throw o.error}}return e.finish()})}function ZYe(e,t="stream"){return(t==="stream"?jL:UL).writeAll(e).toUint8Array(!0)}function HL(e,t=1){return(e*t+63&-64||64)/t}function Bf(e,t,n=e.BYTES_PER_ELEMENT){return new e(HL(t,n))}function WL(e){return e instanceof Ln?e:new Ln(e.type,0,e.length,e.nulls,e.buffers,null,e.dict)}function eKe(e){return new Sn([WL(e)])}const qL=new TextEncoder;function tKe(e,t,n){const r=qL.encode(n);return e.set(r,t),r.length}function nKe(e,t,n){return qL.encodeInto(n,e.subarray(t)).written}const rKe=qL.encodeInto?nKe:tKe;function Hz(e,t){const n=Bf(e.ArrayType,t);return{set(r,i){n[i]=r},data:()=>({type:e,length:t,buffers:[null,n]})}}function iKe(e,t){const n=Bf(e.ArrayType,t/8);return{set(r,i){r&&(n[i>>3]|=1<({type:e,length:t,buffers:[null,n]})}}function sKe(e,t){const n=Bf(e.ArrayType,t);return{set(r,i){n[i]=r/864e5|0},data:()=>({type:e,length:t,buffers:[null,n]})}}function oKe(e,t){const n=Bf(e.ArrayType,t<<1);return{set(r,i){const s=i<<1;n[s]=r%4294967296|0,n[s+1]=r/4294967296|0},data:()=>({type:e,length:t,buffers:[null,n]})}}function aKe(e){const t=bI({type:e,nullValues:[null,void 0]});return{set(n,r){t.set(r,n)},data:()=>t.finish().flush()}}function uKe(e,t,n){const r=Bf(Int32Array,t+1),i=Bf(Uint8Array,3*n);let s=0;return{set(o,a){s+=rKe(i,s,o),r[a+1]=s},data:()=>{const o=HL(s),a=i.length>o?i.subarray(0,o):i;return{type:e,length:t,buffers:[r,a]}}}}function lKe(e,t){const n=[],r=Bf(e.indices.ArrayType,t),i=Object.create(null);let s=-1,o=0;return{set(a,u){const l=String(a);let c=i[l];c===void 0&&(o+=l.length,i[l]=c=++s,n.push(l)),r[u]=c},data:()=>({type:e,length:t,buffers:[null,r],dict:cKe(e.dictionary,n,o)})}}function cKe(e,t,n){const r=uKe(e,t.length,n);return t.forEach(r.set),eKe(r.data())}function fKe(e,t){const n=Bf(Uint8Array,t/8);let r=0;return{set(i,s){i==null?++r:(e.set(i,s),n[s>>3]|=1<{const i=e.data();return r&&(i.nulls=r,i.buffers[2]=n),i}}}function dKe(e,t,n=!0){let r;switch(e.typeId){case G.Int:r=e.bitWidth<64?Hz:null;break;case G.Float:r=e.precision>0?Hz:null;break;case G.Dictionary:r=e.dictionary.typeId===G.Utf8&&e.indices.typeId===G.Int&&e.indices.bitWidth<64?lKe:null;break;case G.Bool:r=iKe;break;case G.Date:r=e.unit?oKe:sKe;break}return r==null?aKe(e):n?fKe(r(e,t),t):r(e,t)}function hKe(e,t){const n=e.length,r=HL(n,e.BYTES_PER_ELEMENT);let i=e;return n!==r&&(i=new e.constructor(r),i.set(e)),WL({type:t,length:n,buffers:[null,i]})}function Bae(e,t,n,r,i=!0){const s=dKe(r,e,i);return t(n,s.set),WL(s.data())}function GL(e){if(e instanceof Bt||e==null)return e;switch(e){case G.Binary:return new Bv;case G.Bool:return new jv;case G.DateDay:return new bqe;case G.DateMillisecond:case G.Date:return new wqe;case G.Dictionary:return new Df(new Qm,new Nf);case G.Float16:return new aoe;case G.Float32:return new uL;case G.Float64:case G.Float:return new lL;case G.Int8:return new tL;case G.Int16:return new nL;case G.Int32:case G.Int:return new Nf;case G.Int64:return new rL;case G.IntervalDayTime:return new xqe;case G.Interval:case G.IntervalYearMonth:return new Cqe;case G.Null:return new Jl;case G.TimeMicrosecond:return new Tqe;case G.TimeMillisecond:case G.Time:return new Sqe;case G.TimeNanosecond:return new Iqe;case G.TimeSecond:return new Eqe;case G.Uint8:return new iL;case G.Uint16:return new sL;case G.Uint32:return new oL;case G.Uint64:return new aL;case G.Utf8:return new Qm;default:Wt(`Unsupported type code: ${el(e)}. Use a data type constructor instead?`)}}function pKe(e){return e.getUTCHours()===0&&e.getUTCMinutes()===0&&e.getUTCSeconds()===0&&e.getUTCMilliseconds()===0}function jae(e,t){const n=yk();return e(t,n.add),n}function yk(){const e={count:0,nulls:0,bools:0,nums:0,ints:0,bigints:0,min:1/0,max:-1/0,digits:0,dates:0,utcdays:0,strings:0,strlen:0,arrays:0,minlen:1/0,maxlen:0,structs:0,add(t){if(++e.count,t==null){++e.nulls;return}const n=typeof t;if(n==="string")++e.strings;else if(n==="number")++e.nums,te.max&&(e.max=t),Number.isInteger(t)&&++e.ints;else if(n==="boolean")++e.bools;else if(n==="object")if(Xl(t))++e.dates,pKe(t)&&++e.utcdays;else if(Md(t)){++e.arrays,t.lengthe.maxlen&&(e.maxlen=t.length);const r=e.array_prof||(e.array_prof=yk());t.forEach(r.add)}else{++e.structs;const r=e.struct_prof||(e.struct_prof={});for(const i in t)(r[i]||(r[i]=yk())).add(t[i])}else n==="bigint"&&(++e.bigints,te.max&&(e.max=t))},type(){return GL(mKe(e))}};return e}function mKe(e){const t=e.count-e.nulls;if(t===0)return G.Null;if(e.ints===t){const n=Math.max(Math.abs(e.min)-1,e.max);return e.min<0?n>=2**31?G.Float64:n<128?G.Int8:n<32768?G.Int16:G.Int32:n>=2**32?G.Float64:n<256?G.Uint8:n<65536?G.Uint16:G.Uint32}else{if(e.nums===t)return G.Float64;if(e.bigints===t){const n=-e.min>e.max?-e.min-1n:e.max;return e.min<0?n<2**63?G.Int64:Wt(`BigInt exceeds 64 bits: ${n}`):e.max<2**64?G.Uint64:Wt(`BigInt exceeds 64 bits: ${e.max}`)}else{if(e.bools===t)return G.Bool;if(e.utcdays===t)return G.DateDay;if(e.dates===t)return G.DateMillisecond;if(e.arrays===t){const n=Rn.new("value",e.array_prof.type(),!0);return e.minlen===e.maxlen?new eg(e.minlen,n):new Zm(n)}else if(e.structs===t){const n=e.struct_prof;return new rs(Object.keys(n).map(r=>Rn.new(r,n[r].type(),!0)))}else{if(e.strings>0)return G.Dictionary;Wt("Type inference failure")}}}}function gKe(e,t,n,r,i,s=!0){if(i=GL(i),!i){const o=jae(r,t);s=o.nulls>0,i=o.type()}return Bae(n,r,t,i,s)}function yKe(e,t,n,r,i,s=!0){i=GL(i);const o=e.column(t),a=!(e.isFiltered()||e.isOrdered()),u=vKe(o);if(u&&a&&Wz(u.type,i))return u;const l=o.data;if(r1(l)){const c=_Ke(l);if(a&&c&&Wz(c,i))return hKe(l,c);i=i||c,s=!1}if(!i){const c=jae(r,o);s=c.nulls>0,i=c.type()}return Bae(n,r,o,i,s)}function vKe(e){return e instanceof Sn?e:e.vector instanceof Sn?e.vector:null}function _Ke(e){const n={Float32Array:uL,Float64Array:lL,Int8Array:tL,Int16Array:nL,Int32Array:Nf,Uint8Array:iL,Uint16Array:sL,Uint32Array:oL,BigInt64Array:rL,BigUint64Array:aL}[e.constructor.name];return n?new n:null}function Wz(e,t){return!e||!t?!0:e.compareTo(t)}function bKe(e,t,n){const r=Math.min(e.length,n+t);return(i,s)=>{for(let o=n;o{let o=-1;r&&Md(i.data)?i.data.forEach(s):e.scan(a=>s(i.get(a),++o),!0,t,n)}}const EKe=()=>Wt("Apache Arrow not imported, see https://github.com/uwdata/arquero#usage");function SKe(){try{return Us}catch{EKe()}}function Uae(e,t={}){const{types:n={}}=t,{dataFrom:r,names:i,nrows:s,scan:o}=TKe(e,t),a={};i.forEach(l=>{const c=r(e,l,s,o,n[l]);c.length!==s&&Wt("Column length mismatch"),a[l]=c});const u=SKe();return new u(a)}function TKe(e,t){const{columns:n,limit:r=1/0,offset:i=0}=t,s=sr(n)?n(e):En(n)?n:null;if(En(e))return{dataFrom:gKe,names:s||Object.keys(e[0]),nrows:Math.min(r,e.length-i),scan:bKe(e,r,i)};if(IKe(e))return{dataFrom:yKe,names:s||e.columnNames(),nrows:Math.min(r,e.numRows()-i),scan:wKe(e,r,i)};Wt("Unsupported input data type")}function IKe(e){return e&&sr(e.reify)}function xKe(e,t={}){const{format:n,...r}=t,i=n||"stream";if(!["stream","file"].includes(i))throw Error("Unrecognised output format");return ZYe(Uae(e,r),n)}function CKe(e){return e.getUTCHours()===0&&e.getUTCMinutes()===0&&e.getUTCSeconds()===0&&e.getUTCMilliseconds()===0}function AKe(e,t={}){let n=0,r=0,i=0,s=0,o=0,a=0;return e(u=>{if(++n,u==null){++r;return}const l=typeof u;if(l==="object"&&Xl(u))++i,CKe(u)&&++s;else if(l==="number"&&(++o,u===u&&(u|0)!==u)){const c=u+"",f=c.indexOf(".");if(f>=0){const d=c.indexOf("e"),h=d>0?d:c.length;a=Math.max(a,h-f-1)}}}),{align:(r+o+i)/n>.5?"r":"l",format:{utc:i===s,digits:Math.min(a,t.maxdigits||6)}}}function YC(e,t){return sr(t)?t(e):t||e.columnNames()}function Vae(e,t,n){const r=n.format||{},i=n.align||{},s={},o={};return t.forEach(a=>{const u=AKe(PKe(e,a),n);o[a]=i[a]||u.align,s[a]=r[a]||u.format}),{align:o,format:s}}function PKe(e,t){const n=e.column(t);return r=>e.scan(i=>r(n.get(i)))}function YL(e,t,n=100,r,i){const s=e.data(),o=t.length;e.scan(a=>{i.row(a);for(let u=0;ul==null?"":Xl(l)?LC(l,!0):s.test(l+="")?'"'+l.replace(/"/g,'""')+'"':l,a=n.map(o);let u="";return YL(e,n,t.limit||1/0,t.offset,{row(){u+=a.join(i)+` -`},cell(l,c,f){a[f]=o(r[c]?r[c](l):l)}}),u+a.join(i)}function zae(e,t={}){if(sr(t))return t(e)+"";const n=typeof e;if(n==="object"){if(Xl(e))return t.utc?LC(e):fse(e);{const r=JSON.stringify(e,(s,o)=>r1(o)?Array.from(o):o),i=t.maxlen||30;return r.length>i?r.slice(0,28)+"…"+(r[0]==="["?"]":"}"):r}}else if(n==="number"){const r=t.digits||0;let i;return e!==0&&((i=Math.abs(e))>=1e18||im==="c"?"center":m==="r"?"right":"left",u=m=>m.replace(/&/g,"&").replace(//g,">"),l=(m,y)=>u(zae(m,y)),c=o?(m,y)=>m==null?o(m):l(m,y):l;let f=-1,d=-1;const h=(m,y,g)=>{const v=g?a(r[y]):"",b=s[m]&&s[m](y,d,f)||"",S=(v?`text-align: ${v};`+(b?" ":""):"")+b;return`<${m}${S?` style="${S}"`:""}>`};let p=h("table")+h("thead")+h("tr",f)+n.map(m=>`${h("th",m,1)}${m}`).join("")+""+h("tbody");return YL(e,n,t.limit,t.offset,{row(m){f=m,p+=(++d?"":"")+h("tr")},cell(m,y){p+=h("td",y,1)+c(m,i[y])+""}}),p+""}function NKe(e){return KC(e.style,t=>sr(t)?t:()=>t)}function kKe(e,t=!0,n=!1){return e===void 0||e?t:n}const DKe=e=>Xl(e)?LC(e,!0):e;function $Ke(e,t={}){const n=kKe(t.schema),r=t.format||{},i=YC(e,t.columns);let s="{";return n&&(s+='"schema":{"fields":'+JSON.stringify(i.map(o=>({name:o})))+'},"data":{'),i.forEach((o,a)=>{s+=(a?",":"")+JSON.stringify(o)+":[";const u=e.column(o),l=r[o]||DKe;let c=-1;e.scan(f=>{const d=u.get(f);s+=(++c?",":"")+JSON.stringify(l(d))},!0,t.limit,t.offset),s+="]"}),s+"}"+(n?"}":"")}function LKe(e,t={}){const n=YC(e,t.columns),{align:r,format:i}=Vae(e,n,t),s=u=>u==="c"?":-:":u==="r"?"-:":":-",o=u=>u.replace(/\|/g,"\\|");let a="|"+n.map(o).join("|")+`| -|`+n.map(u=>s(r[u])).join("|")+"|";return YL(e,n,t.limit,t.offset,{row(){a+=` +]`}concat(...t){const n=this.schema,r=this.data.concat(t.flatMap(({data:i})=>i));return new Us(n,r.map(i=>new vo(n,i)))}slice(t,n){const r=this.schema;[t,n]=zoe({length:this.numRows},t,n);const i=Yoe(this.data,this._offsets,t,n);return new Us(r,i.map(s=>new vo(r,s)))}getChild(t){return this.getChildAt(this.schema.fields.findIndex(n=>n.name===t))}getChildAt(t){if(t>-1&&tr.children[t]);if(n.length===0){const{type:r}=this.schema.fields[t],i=Ji({type:r,length:0,nullCount:0});n.push(i._changeLengthAndBackfillNullBitmap(this.numRows))}return new Sn(n)}return null}setChild(t,n){var r;return this.setChildAt((r=this.schema.fields)===null||r===void 0?void 0:r.findIndex(i=>i.name===t),n)}setChildAt(t,n){let r=this.schema,i=[...this.batches];if(t>-1&&tthis.getChildAt(l));[s[t],a[t]]=[o,n],[r,i]=t2(r,a)}return new Us(r,i)}select(t){const n=this.schema.fields.reduce((r,i,s)=>r.set(i.name,s),new Map);return this.selectAt(t.map(r=>n.get(r)).filter(r=>r>-1))}selectAt(t){const n=this.schema.selectAt(t),r=this.batches.map(i=>i.selectAt(t));return new Us(n,r)}assign(t){const n=this.schema.fields,[r,i]=t.schema.fields.reduce((a,u,l)=>{const[c,f]=a,d=n.findIndex(h=>h.name===u.name);return~d?f[d]=l:c.push(l),a},[[],[]]),s=this.schema.assign(t.schema),o=[...n.map((a,u)=>[u,i[u]]).map(([a,u])=>u===void 0?this.getChildAt(a):t.getChildAt(u)),...r.map(a=>t.getChildAt(a))].filter(Boolean);return new Us(...t2(s,o))}}Pae=Symbol.toStringTag;Us[Pae]=(e=>(e.schema=null,e.batches=[],e._offsets=new Uint32Array([0]),e._nullCount=-1,e[Symbol.isConcatSpreadable]=!0,e.isValid=gm(RL),e.get=gm(oo.getVisitFn(G.Struct)),e.set=Koe(ca.getVisitFn(G.Struct)),e.indexOf=Qoe(dI.getVisitFn(G.Struct)),e.getByteLength=gm(il.getVisitFn(G.Struct)),"Table"))(Us.prototype);var Oae;let vo=class ny{constructor(...t){switch(t.length){case 2:{if([this.schema]=t,!(this.schema instanceof Dn))throw new TypeError("RecordBatch constructor expects a [Schema, Data] pair.");if([,this.data=Ji({nullCount:0,type:new rs(this.schema.fields),children:this.schema.fields.map(n=>Ji({type:n.type,nullCount:0}))})]=t,!(this.data instanceof Ln))throw new TypeError("RecordBatch constructor expects a [Schema, Data] pair.");[this.schema,this.data]=Mz(this.schema,this.data.children);break}case 1:{const[n]=t,{fields:r,children:i,length:s}=Object.keys(n).reduce((u,l,c)=>(u.children[c]=n[l],u.length=Math.max(u.length,n[l].length),u.fields[c]=Rn.new({name:l,type:n[l].type,nullable:!0}),u),{length:0,fields:new Array,children:new Array}),o=new Dn(r),a=Ji({type:new rs(r),length:s,children:i,nullCount:0});[this.schema,this.data]=Mz(o,a.children,s);break}default:throw new TypeError("RecordBatch constructor expects an Object mapping names to child Data, or a [Schema, Data] pair.")}}get dictionaries(){return this._dictionaries||(this._dictionaries=Rae(this.schema.fields,this.data.children))}get numCols(){return this.schema.fields.length}get numRows(){return this.data.length}get nullCount(){return this.data.nullCount}isValid(t){return this.data.getValid(t)}get(t){return oo.visit(this.data,t)}set(t,n){return ca.visit(this.data,t,n)}indexOf(t,n){return dI.visit(this.data,t,n)}getByteLength(t){return il.visit(this.data,t)}[Symbol.iterator](){return NL.visit(new Sn([this.data]))}toArray(){return[...this]}concat(...t){return new Us(this.schema,[this,...t])}slice(t,n){const[r]=new Sn([this.data]).slice(t,n).data;return new ny(this.schema,r)}getChild(t){var n;return this.getChildAt((n=this.schema.fields)===null||n===void 0?void 0:n.findIndex(r=>r.name===t))}getChildAt(t){return t>-1&&ti.name===t),n)}setChildAt(t,n){let r=this.schema,i=this.data;if(t>-1&&ta.name===s);~o&&(i[o]=this.data.children[o])}return new ny(n,Ji({type:r,length:this.numRows,children:i}))}selectAt(t){const n=this.schema.selectAt(t),r=t.map(s=>this.data.children[s]).filter(Boolean),i=Ji({type:new rs(n.fields),length:this.numRows,children:r});return new ny(n,i)}};Oae=Symbol.toStringTag;vo[Oae]=(e=>(e._nullCount=-1,e[Symbol.isConcatSpreadable]=!0,"RecordBatch"))(vo.prototype);function Mz(e,t,n=t.reduce((r,i)=>Math.max(r,i.length),0)){var r;const i=[...e.fields],s=[...t],o=(n+63&-64)>>3;for(const[a,u]of e.fields.entries()){const l=t[a];(!l||l.length!==n)&&(i[a]=u.clone({nullable:!0}),s[a]=(r=l==null?void 0:l._changeLengthAndBackfillNullBitmap(n))!==null&&r!==void 0?r:Ji({type:u.type,length:n,nullCount:n,nullBitmap:new Uint8Array(o)}))}return[e.assign(i),Ji({type:new rs(i),length:n,children:s})]}function Rae(e,t,n=new Map){var r,i;if(((r=e==null?void 0:e.length)!==null&&r!==void 0?r:0)>0&&(e==null?void 0:e.length)===(t==null?void 0:t.length))for(let s=-1,o=e.length;++sJi({type:i.type})),r=Ji({type:new rs(t.fields),nullCount:0,children:n});super(t,r)}}var wI;(function(e){e[e.BUFFER=0]="BUFFER"})(wI||(wI={}));var EI;(function(e){e[e.LZ4_FRAME=0]="LZ4_FRAME",e[e.ZSTD=1]="ZSTD"})(EI||(EI={}));class Mc{constructor(){this.bb=null,this.bb_pos=0}__init(t,n){return this.bb_pos=t,this.bb=n,this}static getRootAsBodyCompression(t,n){return(n||new Mc).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsBodyCompression(t,n){return t.setPosition(t.position()+Wn),(n||new Mc).__init(t.readInt32(t.position())+t.position(),t)}codec(){const t=this.bb.__offset(this.bb_pos,4);return t?this.bb.readInt8(this.bb_pos+t):EI.LZ4_FRAME}method(){const t=this.bb.__offset(this.bb_pos,6);return t?this.bb.readInt8(this.bb_pos+t):wI.BUFFER}static startBodyCompression(t){t.startObject(2)}static addCodec(t,n){t.addFieldInt8(0,n,EI.LZ4_FRAME)}static addMethod(t,n){t.addFieldInt8(1,n,wI.BUFFER)}static endBodyCompression(t){return t.endObject()}static createBodyCompression(t,n,r){return Mc.startBodyCompression(t),Mc.addCodec(t,n),Mc.addMethod(t,r),Mc.endBodyCompression(t)}}class Nae{constructor(){this.bb=null,this.bb_pos=0}__init(t,n){return this.bb_pos=t,this.bb=n,this}offset(){return this.bb.readInt64(this.bb_pos)}length(){return this.bb.readInt64(this.bb_pos+8)}static sizeOf(){return 16}static createBuffer(t,n,r){return t.prep(8,16),t.writeInt64(BigInt(r??0)),t.writeInt64(BigInt(n??0)),t.offset()}}let kae=class{constructor(){this.bb=null,this.bb_pos=0}__init(t,n){return this.bb_pos=t,this.bb=n,this}length(){return this.bb.readInt64(this.bb_pos)}nullCount(){return this.bb.readInt64(this.bb_pos+8)}static sizeOf(){return 16}static createFieldNode(t,n,r){return t.prep(8,16),t.writeInt64(BigInt(r??0)),t.writeInt64(BigInt(n??0)),t.offset()}},bl=class dk{constructor(){this.bb=null,this.bb_pos=0}__init(t,n){return this.bb_pos=t,this.bb=n,this}static getRootAsRecordBatch(t,n){return(n||new dk).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsRecordBatch(t,n){return t.setPosition(t.position()+Wn),(n||new dk).__init(t.readInt32(t.position())+t.position(),t)}length(){const t=this.bb.__offset(this.bb_pos,4);return t?this.bb.readInt64(this.bb_pos+t):BigInt("0")}nodes(t,n){const r=this.bb.__offset(this.bb_pos,6);return r?(n||new kae).__init(this.bb.__vector(this.bb_pos+r)+t*16,this.bb):null}nodesLength(){const t=this.bb.__offset(this.bb_pos,6);return t?this.bb.__vector_len(this.bb_pos+t):0}buffers(t,n){const r=this.bb.__offset(this.bb_pos,8);return r?(n||new Nae).__init(this.bb.__vector(this.bb_pos+r)+t*16,this.bb):null}buffersLength(){const t=this.bb.__offset(this.bb_pos,8);return t?this.bb.__vector_len(this.bb_pos+t):0}compression(t){const n=this.bb.__offset(this.bb_pos,10);return n?(t||new Mc).__init(this.bb.__indirect(this.bb_pos+n),this.bb):null}static startRecordBatch(t){t.startObject(4)}static addLength(t,n){t.addFieldInt64(0,n,BigInt("0"))}static addNodes(t,n){t.addFieldOffset(1,n,0)}static startNodesVector(t,n){t.startVector(16,n,8)}static addBuffers(t,n){t.addFieldOffset(2,n,0)}static startBuffersVector(t,n){t.startVector(16,n,8)}static addCompression(t,n){t.addFieldOffset(3,n,0)}static endRecordBatch(t){return t.endObject()}},yp=class hk{constructor(){this.bb=null,this.bb_pos=0}__init(t,n){return this.bb_pos=t,this.bb=n,this}static getRootAsDictionaryBatch(t,n){return(n||new hk).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsDictionaryBatch(t,n){return t.setPosition(t.position()+Wn),(n||new hk).__init(t.readInt32(t.position())+t.position(),t)}id(){const t=this.bb.__offset(this.bb_pos,4);return t?this.bb.readInt64(this.bb_pos+t):BigInt("0")}data(t){const n=this.bb.__offset(this.bb_pos,6);return n?(t||new bl).__init(this.bb.__indirect(this.bb_pos+n),this.bb):null}isDelta(){const t=this.bb.__offset(this.bb_pos,8);return t?!!this.bb.readInt8(this.bb_pos+t):!1}static startDictionaryBatch(t){t.startObject(3)}static addId(t,n){t.addFieldInt64(0,n,BigInt("0"))}static addData(t,n){t.addFieldOffset(1,n,0)}static addIsDelta(t,n){t.addFieldInt8(2,+n,0)}static endDictionaryBatch(t){return t.endObject()}};var SI;(function(e){e[e.NONE=0]="NONE",e[e.Schema=1]="Schema",e[e.DictionaryBatch=2]="DictionaryBatch",e[e.RecordBatch=3]="RecordBatch",e[e.Tensor=4]="Tensor",e[e.SparseTensor=5]="SparseTensor"})(SI||(SI={}));let xc=class au{constructor(){this.bb=null,this.bb_pos=0}__init(t,n){return this.bb_pos=t,this.bb=n,this}static getRootAsMessage(t,n){return(n||new au).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsMessage(t,n){return t.setPosition(t.position()+Wn),(n||new au).__init(t.readInt32(t.position())+t.position(),t)}version(){const t=this.bb.__offset(this.bb_pos,4);return t?this.bb.readInt16(this.bb_pos+t):tg.V1}headerType(){const t=this.bb.__offset(this.bb_pos,6);return t?this.bb.readUint8(this.bb_pos+t):SI.NONE}header(t){const n=this.bb.__offset(this.bb_pos,8);return n?this.bb.__union(t,this.bb_pos+n):null}bodyLength(){const t=this.bb.__offset(this.bb_pos,10);return t?this.bb.readInt64(this.bb_pos+t):BigInt("0")}customMetadata(t,n){const r=this.bb.__offset(this.bb_pos,12);return r?(n||new Zr).__init(this.bb.__indirect(this.bb.__vector(this.bb_pos+r)+t*4),this.bb):null}customMetadataLength(){const t=this.bb.__offset(this.bb_pos,12);return t?this.bb.__vector_len(this.bb_pos+t):0}static startMessage(t){t.startObject(5)}static addVersion(t,n){t.addFieldInt16(0,n,tg.V1)}static addHeaderType(t,n){t.addFieldInt8(1,n,SI.NONE)}static addHeader(t,n){t.addFieldOffset(2,n,0)}static addBodyLength(t,n){t.addFieldInt64(3,n,BigInt("0"))}static addCustomMetadata(t,n){t.addFieldOffset(4,n,0)}static createCustomMetadataVector(t,n){t.startVector(4,n.length,4);for(let r=n.length-1;r>=0;r--)t.addOffset(n[r]);return t.endVector()}static startCustomMetadataVector(t,n){t.startVector(4,n,4)}static endMessage(t){return t.endObject()}static finishMessageBuffer(t,n){t.finish(n)}static finishSizePrefixedMessageBuffer(t,n){t.finish(n,void 0,!0)}static createMessage(t,n,r,i,s,o){return au.startMessage(t),au.addVersion(t,n),au.addHeaderType(t,r),au.addHeader(t,i),au.addBodyLength(t,s),au.addCustomMetadata(t,o),au.endMessage(t)}};class xYe extends qt{visit(t,n){return t==null||n==null?void 0:super.visit(t,n)}visitNull(t,n){return Vd.startNull(n),Vd.endNull(n)}visitInt(t,n){return yo.startInt(n),yo.addBitWidth(n,t.bitWidth),yo.addIsSigned(n,t.isSigned),yo.endInt(n)}visitFloat(t,n){return Iu.startFloatingPoint(n),Iu.addPrecision(n,t.precision),Iu.endFloatingPoint(n)}visitBinary(t,n){return Bd.startBinary(n),Bd.endBinary(n)}visitBool(t,n){return jd.startBool(n),jd.endBool(n)}visitUtf8(t,n){return Hd.startUtf8(n),Hd.endUtf8(n)}visitDecimal(t,n){return Ms.startDecimal(n),Ms.addScale(n,t.scale),Ms.addPrecision(n,t.precision),Ms.addBitWidth(n,t.bitWidth),Ms.endDecimal(n)}visitDate(t,n){return zw.startDate(n),zw.addUnit(n,t.unit),zw.endDate(n)}visitTime(t,n){return Go.startTime(n),Go.addUnit(n,t.unit),Go.addBitWidth(n,t.bitWidth),Go.endTime(n)}visitTimestamp(t,n){const r=t.timezone&&n.createString(t.timezone)||void 0;return ty.startTimestamp(n),ty.addUnit(n,t.unit),r!==void 0&&ty.addTimezone(n,r),ty.endTimestamp(n)}visitInterval(t,n){return xu.startInterval(n),xu.addUnit(n,t.unit),xu.endInterval(n)}visitDuration(t,n){return Eu.startDuration(n),Eu.addUnit(n,t.unit),Eu.endDuration(n)}visitList(t,n){return Ud.startList(n),Ud.endList(n)}visitStruct(t,n){return zd.startStruct_(n),zd.endStruct_(n)}visitUnion(t,n){js.startTypeIdsVector(n,t.typeIds.length);const r=js.createTypeIdsVector(n,t.typeIds);return js.startUnion(n),js.addMode(n,t.mode),js.addTypeIds(n,r),js.endUnion(n)}visitDictionary(t,n){const r=this.visit(t.indices,n);return Cl.startDictionaryEncoding(n),Cl.addId(n,BigInt(t.id)),Cl.addIsOrdered(n,t.isOrdered),r!==void 0&&Cl.addIndexType(n,r),Cl.endDictionaryEncoding(n)}visitFixedSizeBinary(t,n){return Su.startFixedSizeBinary(n),Su.addByteWidth(n,t.byteWidth),Su.endFixedSizeBinary(n)}visitFixedSizeList(t,n){return Tu.startFixedSizeList(n),Tu.addListSize(n,t.listSize),Tu.endFixedSizeList(n)}visitMap(t,n){return Hw.startMap(n),Hw.addKeysSorted(n,t.keysSorted),Hw.endMap(n)}}const n2=new xYe;function CYe(e,t=new Map){return new Dn(PYe(e,t),qw(e.metadata),t)}function Dae(e){return new No(e.count,$ae(e.columns),Lae(e.columns))}function AYe(e){return new sl(Dae(e.data),e.id,e.isDelta)}function PYe(e,t){return(e.fields||[]).filter(Boolean).map(n=>Rn.fromJSON(n,t))}function Fz(e,t){return(e.children||[]).filter(Boolean).map(n=>Rn.fromJSON(n,t))}function $ae(e){return(e||[]).reduce((t,n)=>[...t,new Ff(n.count,OYe(n.VALIDITY)),...$ae(n.children)],[])}function Lae(e,t=[]){for(let n=-1,r=(e||[]).length;++nt+ +(n===0),0)}function RYe(e,t){let n,r,i,s,o,a;return!t||!(s=e.dictionary)?(o=jz(e,Fz(e,t)),i=new Rn(e.name,o,e.nullable,qw(e.metadata))):t.has(n=s.id)?(r=(r=s.indexType)?Bz(r):new Nf,a=new Df(t.get(n),r,n,s.isOrdered),i=new Rn(e.name,a,e.nullable,qw(e.metadata))):(r=(r=s.indexType)?Bz(r):new Nf,t.set(n,o=jz(e,Fz(e,t))),a=new Df(o,r,n,s.isOrdered),i=new Rn(e.name,a,e.nullable,qw(e.metadata))),i||null}function qw(e=[]){return new Map(e.map(({key:t,value:n})=>[t,n]))}function Bz(e){return new ws(e.isSigned,e.bitWidth)}function jz(e,t){const n=e.type.name;switch(n){case"NONE":return new Jl;case"null":return new Jl;case"binary":return new Bv;case"utf8":return new Qm;case"bool":return new jv;case"list":return new Zm((t||[])[0]);case"struct":return new rs(t||[]);case"struct_":return new rs(t||[])}switch(n){case"int":{const r=e.type;return new ws(r.isSigned,r.bitWidth)}case"floatingpoint":{const r=e.type;return new kf($i[r.precision])}case"decimal":{const r=e.type;return new aI(r.scale,r.precision,r.bitWidth)}case"date":{const r=e.type;return new Xm(nl[r.unit])}case"time":{const r=e.type;return new Zl(vt[r.unit],r.bitWidth)}case"timestamp":{const r=e.type;return new uI(vt[r.unit],r.timezone)}case"interval":{const r=e.type;return new Jm(rl[r.unit])}case"duration":{const r=e.type;return new lI(vt[r.unit])}case"union":{const r=e.type,[i,...s]=(r.mode+"").toLowerCase(),o=i.toUpperCase()+s.join("");return new Uv(so[o],r.typeIds||[],t||[])}case"fixedsizebinary":{const r=e.type;return new cI(r.byteWidth)}case"fixedsizelist":{const r=e.type;return new eg(r.listSize,(t||[])[0])}case"map":{const r=e.type;return new Vv((t||[])[0],r.keysSorted)}}throw new Error(`Unrecognized type: "${n}"`)}var NYe=oae,kYe=pI;class Cu{static fromJSON(t,n){const r=new Cu(0,gs.V5,n);return r._createHeader=DYe(t,n),r}static decode(t){t=new kYe(Mn(t));const n=xc.getRootAsMessage(t),r=n.bodyLength(),i=n.version(),s=n.headerType(),o=new Cu(r,i,s);return o._createHeader=$Ye(n,s),o}static encode(t){const n=new NYe;let r=-1;return t.isSchema()?r=Dn.encode(n,t.header()):t.isRecordBatch()?r=No.encode(n,t.header()):t.isDictionaryBatch()&&(r=sl.encode(n,t.header())),xc.startMessage(n),xc.addVersion(n,gs.V5),xc.addHeader(n,r),xc.addHeaderType(n,t.headerType),xc.addBodyLength(n,BigInt(t.bodyLength)),xc.finishMessageBuffer(n,xc.endMessage(n)),n.asUint8Array()}static from(t,n=0){if(t instanceof Dn)return new Cu(0,gs.V5,pi.Schema,t);if(t instanceof No)return new Cu(n,gs.V5,pi.RecordBatch,t);if(t instanceof sl)return new Cu(n,gs.V5,pi.DictionaryBatch,t);throw new Error(`Unrecognized Message header: ${t}`)}get type(){return this.headerType}get version(){return this._version}get headerType(){return this._headerType}get bodyLength(){return this._bodyLength}header(){return this._createHeader()}isSchema(){return this.headerType===pi.Schema}isRecordBatch(){return this.headerType===pi.RecordBatch}isDictionaryBatch(){return this.headerType===pi.DictionaryBatch}constructor(t,n,r,i){this._version=n,this._headerType=r,this.body=new Uint8Array(0),i&&(this._createHeader=()=>i),this._bodyLength=Ka(t)}}class No{get nodes(){return this._nodes}get length(){return this._length}get buffers(){return this._buffers}constructor(t,n,r){this._nodes=n,this._buffers=r,this._length=Ka(t)}}class sl{get id(){return this._id}get data(){return this._data}get isDelta(){return this._isDelta}get length(){return this.data.length}get nodes(){return this.data.nodes}get buffers(){return this.data.buffers}constructor(t,n,r=!1){this._data=t,this._isDelta=r,this._id=Ka(n)}}class Nu{constructor(t,n){this.offset=Ka(t),this.length=Ka(n)}}class Ff{constructor(t,n){this.length=Ka(t),this.nullCount=Ka(n)}}function DYe(e,t){return()=>{switch(t){case pi.Schema:return Dn.fromJSON(e);case pi.RecordBatch:return No.fromJSON(e);case pi.DictionaryBatch:return sl.fromJSON(e)}throw new Error(`Unrecognized Message type: { name: ${pi[t]}, type: ${t} }`)}}function $Ye(e,t){return()=>{switch(t){case pi.Schema:return Dn.decode(e.header(new du),new Map,e.version());case pi.RecordBatch:return No.decode(e.header(new bl),e.version());case pi.DictionaryBatch:return sl.decode(e.header(new yp),e.version())}throw new Error(`Unrecognized Message type: { name: ${pi[t]}, type: ${t} }`)}}Rn.encode=qYe;Rn.decode=HYe;Rn.fromJSON=RYe;Dn.encode=WYe;Dn.decode=LYe;Dn.fromJSON=CYe;No.encode=GYe;No.decode=MYe;No.fromJSON=Dae;sl.encode=YYe;sl.decode=FYe;sl.fromJSON=AYe;Ff.encode=KYe;Ff.decode=jYe;Nu.encode=QYe;Nu.decode=BYe;function LYe(e,t=new Map,n=gs.V5){const r=zYe(e,t);return new Dn(r,Gw(e),t,n)}function MYe(e,t=gs.V5){if(e.compression()!==null)throw new Error("Record batch compression not implemented");return new No(e.length(),UYe(e),VYe(e,t))}function FYe(e,t=gs.V5){return new sl(No.decode(e.data(),t),e.id(),e.isDelta())}function BYe(e){return new Nu(e.offset(),e.length())}function jYe(e){return new Ff(e.length(),e.nullCount())}function UYe(e){const t=[];for(let n,r=-1,i=-1,s=e.nodesLength();++rRn.encode(e,s));du.startFieldsVector(e,n.length);const r=du.createFieldsVector(e,n),i=t.metadata&&t.metadata.size>0?du.createCustomMetadataVector(e,[...t.metadata].map(([s,o])=>{const a=e.createString(`${s}`),u=e.createString(`${o}`);return Zr.startKeyValue(e),Zr.addKey(e,a),Zr.addValue(e,u),Zr.endKeyValue(e)})):-1;return du.startSchema(e),du.addFields(e,r),du.addEndianness(e,XYe?ng.Little:ng.Big),i!==-1&&du.addCustomMetadata(e,i),du.endSchema(e)}function qYe(e,t){let n=-1,r=-1,i=-1;const s=t.type;let o=t.typeId;Bt.isDictionary(s)?(o=s.dictionary.typeId,i=n2.visit(s,e),r=n2.visit(s.dictionary,e)):r=n2.visit(s,e);const a=(s.children||[]).map(c=>Rn.encode(e,c)),u=Uo.createChildrenVector(e,a),l=t.metadata&&t.metadata.size>0?Uo.createCustomMetadataVector(e,[...t.metadata].map(([c,f])=>{const d=e.createString(`${c}`),h=e.createString(`${f}`);return Zr.startKeyValue(e),Zr.addKey(e,d),Zr.addValue(e,h),Zr.endKeyValue(e)})):-1;return t.name&&(n=e.createString(t.name)),Uo.startField(e),Uo.addType(e,r),Uo.addTypeType(e,o),Uo.addChildren(e,u),Uo.addNullable(e,!!t.nullable),n!==-1&&Uo.addName(e,n),i!==-1&&Uo.addDictionary(e,i),l!==-1&&Uo.addCustomMetadata(e,l),Uo.endField(e)}function GYe(e,t){const n=t.nodes||[],r=t.buffers||[];bl.startNodesVector(e,n.length);for(const o of n.slice().reverse())Ff.encode(e,o);const i=e.endVector();bl.startBuffersVector(e,r.length);for(const o of r.slice().reverse())Nu.encode(e,o);const s=e.endVector();return bl.startRecordBatch(e),bl.addLength(e,BigInt(t.length)),bl.addNodes(e,i),bl.addBuffers(e,s),bl.endRecordBatch(e)}function YYe(e,t){const n=No.encode(e,t.data);return yp.startDictionaryBatch(e),yp.addId(e,BigInt(t.id)),yp.addIsDelta(e,t.isDelta),yp.addData(e,n),yp.endDictionaryBatch(e)}function KYe(e,t){return kae.createFieldNode(e,BigInt(t.length),BigInt(t.nullCount))}function QYe(e,t){return Nae.createBuffer(e,BigInt(t.offset),BigInt(t.length))}const XYe=(()=>{const e=new ArrayBuffer(2);return new DataView(e).setInt16(0,256,!0),new Int16Array(e)[0]===256})(),pk="ARROW1",ML=new Uint8Array(pk.length);for(let e=0;ei.flatMap(s=>Array.isArray(s)?n(s):s instanceof vo?s.data.children:s.data),r=new Br;return r.visitMany(n(t)),r}constructor(){super(),this._byteLength=0,this._nodes=[],this._buffers=[],this._bufferRegions=[]}visit(t){if(t instanceof Sn)return this.visitMany(t.data),this;const{type:n}=t;if(!Bt.isDictionary(n)){const{length:r}=t;if(r>2147483647)throw new RangeError("Cannot write arrays larger than 2^31 - 1 in length");if(Bt.isUnion(n))this.nodes.push(new Ff(r,0));else{const{nullCount:i}=t;Bt.isNull(n)||za.call(this,i<=0?new Uint8Array(0):fI(t.offset,r,t.nullBitmap)),this.nodes.push(new Ff(r,i))}}return super.visit(t)}visitNull(t){return this}visitDictionary(t){return this.visit(t.clone(t.type.indices))}get nodes(){return this._nodes}get buffers(){return this._buffers}get byteLength(){return this._byteLength}get bufferRegions(){return this._bufferRegions}}function za(e){const t=e.byteLength+7&-8;return this.buffers.push(e),this.bufferRegions.push(new Nu(this._byteLength,t)),this._byteLength+=t,this}function JYe(e){var t;const{type:n,length:r,typeIds:i,valueOffsets:s}=e;if(za.call(this,i),n.mode===so.Sparse)return mk.call(this,e);if(n.mode===so.Dense){if(e.offset<=0)return za.call(this,s),mk.call(this,e);{const o=new Int32Array(r),a=Object.create(null),u=Object.create(null);for(let l,c,f=-1;++f{const f=n.typeIds[c],d=a[f],h=u[f];return l.slice(d,Math.min(r,h))}))}}return this}function ZYe(e){let t;return e.nullCount>=e.length?za.call(this,new Uint8Array(0)):(t=e.values)instanceof Uint8Array?za.call(this,fI(e.offset,e.length,t)):za.call(this,Woe(e.values))}function yc(e){return za.call(this,e.values.subarray(0,e.length*e.stride))}function Mae(e){const{length:t,values:n,valueOffsets:r}=e,{[0]:i,[t]:s}=r,o=Math.min(s-i,n.byteLength-i);return za.call(this,Bse(-i,t+1,r)),za.call(this,n.subarray(i,i+o)),this}function FL(e){const{length:t,valueOffsets:n}=e;if(n){const{[0]:r,[t]:i}=n;return za.call(this,Bse(-r,t+1,n)),this.visit(e.children[0].slice(r,i-r))}return this.visit(e.children[0])}function mk(e){return this.visitMany(e.type.children.map((t,n)=>e.children[n]).filter(Boolean))[0]}Br.prototype.visitBool=ZYe;Br.prototype.visitInt=yc;Br.prototype.visitFloat=yc;Br.prototype.visitUtf8=Mae;Br.prototype.visitBinary=Mae;Br.prototype.visitFixedSizeBinary=yc;Br.prototype.visitDate=yc;Br.prototype.visitTimestamp=yc;Br.prototype.visitTime=yc;Br.prototype.visitDecimal=yc;Br.prototype.visitList=FL;Br.prototype.visitStruct=mk;Br.prototype.visitUnion=JYe;Br.prototype.visitInterval=yc;Br.prototype.visitDuration=yc;Br.prototype.visitFixedSizeList=FL;Br.prototype.visitMap=FL;class Fae extends uae{static throughNode(t){throw new Error('"throughNode" not available in this environment')}static throughDOM(t,n){throw new Error('"throughDOM" not available in this environment')}constructor(t){super(),this._position=0,this._started=!1,this._sink=new e2,this._schema=null,this._dictionaryBlocks=[],this._recordBatchBlocks=[],this._dictionaryDeltaOffsets=new Map,Zf(t)||(t={autoDestroy:!0,writeLegacyIpcFormat:!1}),this._autoDestroy=typeof t.autoDestroy=="boolean"?t.autoDestroy:!0,this._writeLegacyIpcFormat=typeof t.writeLegacyIpcFormat=="boolean"?t.writeLegacyIpcFormat:!1}toString(t=!1){return this._sink.toString(t)}toUint8Array(t=!1){return this._sink.toUint8Array(t)}writeAll(t){return FC(t)?t.then(n=>this.writeAll(n)):BC(t)?VL(this,t):UL(this,t)}get closed(){return this._sink.closed}[Symbol.asyncIterator](){return this._sink[Symbol.asyncIterator]()}toDOMStream(t){return this._sink.toDOMStream(t)}toNodeStream(t){return this._sink.toNodeStream(t)}close(){return this.reset()._sink.close()}abort(t){return this.reset()._sink.abort(t)}finish(){return this._autoDestroy?this.close():this.reset(this._sink,this._schema),this}reset(t=this._sink,n=null){return t===this._sink||t instanceof e2?this._sink=t:(this._sink=new e2,t&&sqe(t)?this.toDOMStream({type:"bytes"}).pipeTo(t):t&&oqe(t)&&this.toNodeStream({objectMode:!1}).pipe(t)),this._started&&this._schema&&this._writeFooter(this._schema),this._started=!1,this._dictionaryBlocks=[],this._recordBatchBlocks=[],this._dictionaryDeltaOffsets=new Map,(!n||!fk(n,this._schema))&&(n==null?(this._position=0,this._schema=null):(this._started=!0,this._schema=n,this._writeSchema(n))),this}write(t){let n=null;if(this._sink){if(t==null)return this.finish()&&void 0;if(t instanceof Us&&!(n=t.schema))return this.finish()&&void 0;if(t instanceof vo&&!(n=t.schema))return this.finish()&&void 0}else throw new Error("RecordBatchWriter is closed");if(n&&!fk(n,this._schema)){if(this._started&&this._autoDestroy)return this.close();this.reset(this._sink,n)}t instanceof vo?t instanceof IYe||this._writeRecordBatch(t):t instanceof Us?this.writeAll(t.batches):X6(t)&&this.writeAll(t)}_writeMessage(t,n=8){const r=n-1,i=Cu.encode(t),s=i.byteLength,o=this._writeLegacyIpcFormat?4:8,a=s+o+r&~r,u=a-s-o;return t.headerType===pi.RecordBatch?this._recordBatchBlocks.push(new Lf(a,t.bodyLength,this._position)):t.headerType===pi.DictionaryBatch&&this._dictionaryBlocks.push(new Lf(a,t.bodyLength,this._position)),this._writeLegacyIpcFormat||this._write(Int32Array.of(-1)),this._write(Int32Array.of(a-o)),s>0&&this._write(i),this._writePadding(u)}_write(t){if(this._started){const n=Mn(t);n&&n.byteLength>0&&(this._sink.write(n),this._position+=n.byteLength)}return this}_writeSchema(t){return this._writeMessage(Cu.from(t))}_writeFooter(t){return this._writeLegacyIpcFormat?this._write(Int32Array.of(0)):this._write(Int32Array.of(-1,0))}_writeMagic(){return this._write(ML)}_writePadding(t){return t>0?this._write(new Uint8Array(t)):this}_writeRecordBatch(t){const{byteLength:n,nodes:r,bufferRegions:i,buffers:s}=Br.assemble(t),o=new No(t.numRows,r,i),a=Cu.from(o,n);return this._writeDictionaries(t)._writeMessage(a)._writeBodyBuffers(s)}_writeDictionaryBatch(t,n,r=!1){this._dictionaryDeltaOffsets.set(n,t.length+(this._dictionaryDeltaOffsets.get(n)||0));const{byteLength:i,nodes:s,bufferRegions:o,buffers:a}=Br.assemble(new Sn([t])),u=new No(t.length,s,o),l=new sl(u,n,r),c=Cu.from(l,i);return this._writeMessage(c)._writeBodyBuffers(a)}_writeBodyBuffers(t){let n,r,i;for(let s=-1,o=t.length;++s0&&(this._write(n),(i=(r+7&-8)-r)>0&&this._writePadding(i));return this}_writeDictionaries(t){for(let[n,r]of t.dictionaries){let i=this._dictionaryDeltaOffsets.get(n)||0;if(i===0||(r=r==null?void 0:r.slice(i)).length>0)for(const s of r.data)this._writeDictionaryBatch(s,n,i>0),i+=s.length}return this}}class BL extends Fae{static writeAll(t,n){const r=new BL(n);return FC(t)?t.then(i=>r.writeAll(i)):BC(t)?VL(r,t):UL(r,t)}}class jL extends Fae{static writeAll(t){const n=new jL;return FC(t)?t.then(r=>n.writeAll(r)):BC(t)?VL(n,t):UL(n,t)}constructor(){super(),this._autoDestroy=!0}_writeSchema(t){return this._writeMagic()._writePadding(2)}_writeFooter(t){const n=ck.encode(new ck(t,gs.V5,this._recordBatchBlocks,this._dictionaryBlocks));return super._writeFooter(t)._write(n)._write(Int32Array.of(n.byteLength))._writeMagic()}}function UL(e,t){let n=t;t instanceof Us&&(n=t.batches,e.reset(void 0,t.schema));for(const r of n)e.write(r);return e.finish()}function VL(e,t){var n,r,i,s,o,a,u;return Il(this,void 0,void 0,function*(){try{for(n=!0,r=My(t);i=yield r.next(),s=i.done,!s;n=!0){u=i.value,n=!1;const l=u;e.write(l)}}catch(l){o={error:l}}finally{try{!n&&!s&&(a=r.return)&&(yield a.call(r))}finally{if(o)throw o.error}}return e.finish()})}function eKe(e,t="stream"){return(t==="stream"?BL:jL).writeAll(e).toUint8Array(!0)}function zL(e,t=1){return(e*t+63&-64||64)/t}function Bf(e,t,n=e.BYTES_PER_ELEMENT){return new e(zL(t,n))}function HL(e){return e instanceof Ln?e:new Ln(e.type,0,e.length,e.nulls,e.buffers,null,e.dict)}function tKe(e){return new Sn([HL(e)])}const WL=new TextEncoder;function nKe(e,t,n){const r=WL.encode(n);return e.set(r,t),r.length}function rKe(e,t,n){return WL.encodeInto(n,e.subarray(t)).written}const iKe=WL.encodeInto?rKe:nKe;function Hz(e,t){const n=Bf(e.ArrayType,t);return{set(r,i){n[i]=r},data:()=>({type:e,length:t,buffers:[null,n]})}}function sKe(e,t){const n=Bf(e.ArrayType,t/8);return{set(r,i){r&&(n[i>>3]|=1<({type:e,length:t,buffers:[null,n]})}}function oKe(e,t){const n=Bf(e.ArrayType,t);return{set(r,i){n[i]=r/864e5|0},data:()=>({type:e,length:t,buffers:[null,n]})}}function aKe(e,t){const n=Bf(e.ArrayType,t<<1);return{set(r,i){const s=i<<1;n[s]=r%4294967296|0,n[s+1]=r/4294967296|0},data:()=>({type:e,length:t,buffers:[null,n]})}}function uKe(e){const t=bI({type:e,nullValues:[null,void 0]});return{set(n,r){t.set(r,n)},data:()=>t.finish().flush()}}function lKe(e,t,n){const r=Bf(Int32Array,t+1),i=Bf(Uint8Array,3*n);let s=0;return{set(o,a){s+=iKe(i,s,o),r[a+1]=s},data:()=>{const o=zL(s),a=i.length>o?i.subarray(0,o):i;return{type:e,length:t,buffers:[r,a]}}}}function cKe(e,t){const n=[],r=Bf(e.indices.ArrayType,t),i=Object.create(null);let s=-1,o=0;return{set(a,u){const l=String(a);let c=i[l];c===void 0&&(o+=l.length,i[l]=c=++s,n.push(l)),r[u]=c},data:()=>({type:e,length:t,buffers:[null,r],dict:fKe(e.dictionary,n,o)})}}function fKe(e,t,n){const r=lKe(e,t.length,n);return t.forEach(r.set),tKe(r.data())}function dKe(e,t){const n=Bf(Uint8Array,t/8);let r=0;return{set(i,s){i==null?++r:(e.set(i,s),n[s>>3]|=1<{const i=e.data();return r&&(i.nulls=r,i.buffers[2]=n),i}}}function hKe(e,t,n=!0){let r;switch(e.typeId){case G.Int:r=e.bitWidth<64?Hz:null;break;case G.Float:r=e.precision>0?Hz:null;break;case G.Dictionary:r=e.dictionary.typeId===G.Utf8&&e.indices.typeId===G.Int&&e.indices.bitWidth<64?cKe:null;break;case G.Bool:r=sKe;break;case G.Date:r=e.unit?aKe:oKe;break}return r==null?uKe(e):n?dKe(r(e,t),t):r(e,t)}function pKe(e,t){const n=e.length,r=zL(n,e.BYTES_PER_ELEMENT);let i=e;return n!==r&&(i=new e.constructor(r),i.set(e)),HL({type:t,length:n,buffers:[null,i]})}function Bae(e,t,n,r,i=!0){const s=hKe(r,e,i);return t(n,s.set),HL(s.data())}function qL(e){if(e instanceof Bt||e==null)return e;switch(e){case G.Binary:return new Bv;case G.Bool:return new jv;case G.DateDay:return new wqe;case G.DateMillisecond:case G.Date:return new Eqe;case G.Dictionary:return new Df(new Qm,new Nf);case G.Float16:return new aoe;case G.Float32:return new aL;case G.Float64:case G.Float:return new uL;case G.Int8:return new eL;case G.Int16:return new tL;case G.Int32:case G.Int:return new Nf;case G.Int64:return new nL;case G.IntervalDayTime:return new Cqe;case G.Interval:case G.IntervalYearMonth:return new Aqe;case G.Null:return new Jl;case G.TimeMicrosecond:return new Iqe;case G.TimeMillisecond:case G.Time:return new Tqe;case G.TimeNanosecond:return new xqe;case G.TimeSecond:return new Sqe;case G.Uint8:return new rL;case G.Uint16:return new iL;case G.Uint32:return new sL;case G.Uint64:return new oL;case G.Utf8:return new Qm;default:Wt(`Unsupported type code: ${el(e)}. Use a data type constructor instead?`)}}function mKe(e){return e.getUTCHours()===0&&e.getUTCMinutes()===0&&e.getUTCSeconds()===0&&e.getUTCMilliseconds()===0}function jae(e,t){const n=gk();return e(t,n.add),n}function gk(){const e={count:0,nulls:0,bools:0,nums:0,ints:0,bigints:0,min:1/0,max:-1/0,digits:0,dates:0,utcdays:0,strings:0,strlen:0,arrays:0,minlen:1/0,maxlen:0,structs:0,add(t){if(++e.count,t==null){++e.nulls;return}const n=typeof t;if(n==="string")++e.strings;else if(n==="number")++e.nums,te.max&&(e.max=t),Number.isInteger(t)&&++e.ints;else if(n==="boolean")++e.bools;else if(n==="object")if(Xl(t))++e.dates,mKe(t)&&++e.utcdays;else if(Md(t)){++e.arrays,t.lengthe.maxlen&&(e.maxlen=t.length);const r=e.array_prof||(e.array_prof=gk());t.forEach(r.add)}else{++e.structs;const r=e.struct_prof||(e.struct_prof={});for(const i in t)(r[i]||(r[i]=gk())).add(t[i])}else n==="bigint"&&(++e.bigints,te.max&&(e.max=t))},type(){return qL(gKe(e))}};return e}function gKe(e){const t=e.count-e.nulls;if(t===0)return G.Null;if(e.ints===t){const n=Math.max(Math.abs(e.min)-1,e.max);return e.min<0?n>=2**31?G.Float64:n<128?G.Int8:n<32768?G.Int16:G.Int32:n>=2**32?G.Float64:n<256?G.Uint8:n<65536?G.Uint16:G.Uint32}else{if(e.nums===t)return G.Float64;if(e.bigints===t){const n=-e.min>e.max?-e.min-1n:e.max;return e.min<0?n<2**63?G.Int64:Wt(`BigInt exceeds 64 bits: ${n}`):e.max<2**64?G.Uint64:Wt(`BigInt exceeds 64 bits: ${e.max}`)}else{if(e.bools===t)return G.Bool;if(e.utcdays===t)return G.DateDay;if(e.dates===t)return G.DateMillisecond;if(e.arrays===t){const n=Rn.new("value",e.array_prof.type(),!0);return e.minlen===e.maxlen?new eg(e.minlen,n):new Zm(n)}else if(e.structs===t){const n=e.struct_prof;return new rs(Object.keys(n).map(r=>Rn.new(r,n[r].type(),!0)))}else{if(e.strings>0)return G.Dictionary;Wt("Type inference failure")}}}}function yKe(e,t,n,r,i,s=!0){if(i=qL(i),!i){const o=jae(r,t);s=o.nulls>0,i=o.type()}return Bae(n,r,t,i,s)}function vKe(e,t,n,r,i,s=!0){i=qL(i);const o=e.column(t),a=!(e.isFiltered()||e.isOrdered()),u=_Ke(o);if(u&&a&&Wz(u.type,i))return u;const l=o.data;if(r1(l)){const c=bKe(l);if(a&&c&&Wz(c,i))return pKe(l,c);i=i||c,s=!1}if(!i){const c=jae(r,o);s=c.nulls>0,i=c.type()}return Bae(n,r,o,i,s)}function _Ke(e){return e instanceof Sn?e:e.vector instanceof Sn?e.vector:null}function bKe(e){const n={Float32Array:aL,Float64Array:uL,Int8Array:eL,Int16Array:tL,Int32Array:Nf,Uint8Array:rL,Uint16Array:iL,Uint32Array:sL,BigInt64Array:nL,BigUint64Array:oL}[e.constructor.name];return n?new n:null}function Wz(e,t){return!e||!t?!0:e.compareTo(t)}function wKe(e,t,n){const r=Math.min(e.length,n+t);return(i,s)=>{for(let o=n;o{let o=-1;r&&Md(i.data)?i.data.forEach(s):e.scan(a=>s(i.get(a),++o),!0,t,n)}}const SKe=()=>Wt("Apache Arrow not imported, see https://github.com/uwdata/arquero#usage");function TKe(){try{return Us}catch{SKe()}}function Uae(e,t={}){const{types:n={}}=t,{dataFrom:r,names:i,nrows:s,scan:o}=IKe(e,t),a={};i.forEach(l=>{const c=r(e,l,s,o,n[l]);c.length!==s&&Wt("Column length mismatch"),a[l]=c});const u=TKe();return new u(a)}function IKe(e,t){const{columns:n,limit:r=1/0,offset:i=0}=t,s=sr(n)?n(e):En(n)?n:null;if(En(e))return{dataFrom:yKe,names:s||Object.keys(e[0]),nrows:Math.min(r,e.length-i),scan:wKe(e,r,i)};if(xKe(e))return{dataFrom:vKe,names:s||e.columnNames(),nrows:Math.min(r,e.numRows()-i),scan:EKe(e,r,i)};Wt("Unsupported input data type")}function xKe(e){return e&&sr(e.reify)}function CKe(e,t={}){const{format:n,...r}=t,i=n||"stream";if(!["stream","file"].includes(i))throw Error("Unrecognised output format");return eKe(Uae(e,r),n)}function AKe(e){return e.getUTCHours()===0&&e.getUTCMinutes()===0&&e.getUTCSeconds()===0&&e.getUTCMilliseconds()===0}function PKe(e,t={}){let n=0,r=0,i=0,s=0,o=0,a=0;return e(u=>{if(++n,u==null){++r;return}const l=typeof u;if(l==="object"&&Xl(u))++i,AKe(u)&&++s;else if(l==="number"&&(++o,u===u&&(u|0)!==u)){const c=u+"",f=c.indexOf(".");if(f>=0){const d=c.indexOf("e"),h=d>0?d:c.length;a=Math.max(a,h-f-1)}}}),{align:(r+o+i)/n>.5?"r":"l",format:{utc:i===s,digits:Math.min(a,t.maxdigits||6)}}}function YC(e,t){return sr(t)?t(e):t||e.columnNames()}function Vae(e,t,n){const r=n.format||{},i=n.align||{},s={},o={};return t.forEach(a=>{const u=PKe(OKe(e,a),n);o[a]=i[a]||u.align,s[a]=r[a]||u.format}),{align:o,format:s}}function OKe(e,t){const n=e.column(t);return r=>e.scan(i=>r(n.get(i)))}function GL(e,t,n=100,r,i){const s=e.data(),o=t.length;e.scan(a=>{i.row(a);for(let u=0;ul==null?"":Xl(l)?LC(l,!0):s.test(l+="")?'"'+l.replace(/"/g,'""')+'"':l,a=n.map(o);let u="";return GL(e,n,t.limit||1/0,t.offset,{row(){u+=a.join(i)+` +`},cell(l,c,f){a[f]=o(r[c]?r[c](l):l)}}),u+a.join(i)}function zae(e,t={}){if(sr(t))return t(e)+"";const n=typeof e;if(n==="object"){if(Xl(e))return t.utc?LC(e):fse(e);{const r=JSON.stringify(e,(s,o)=>r1(o)?Array.from(o):o),i=t.maxlen||30;return r.length>i?r.slice(0,28)+"…"+(r[0]==="["?"]":"}"):r}}else if(n==="number"){const r=t.digits||0;let i;return e!==0&&((i=Math.abs(e))>=1e18||im==="c"?"center":m==="r"?"right":"left",u=m=>m.replace(/&/g,"&").replace(//g,">"),l=(m,y)=>u(zae(m,y)),c=o?(m,y)=>m==null?o(m):l(m,y):l;let f=-1,d=-1;const h=(m,y,g)=>{const v=g?a(r[y]):"",b=s[m]&&s[m](y,d,f)||"",S=(v?`text-align: ${v};`+(b?" ":""):"")+b;return`<${m}${S?` style="${S}"`:""}>`};let p=h("table")+h("thead")+h("tr",f)+n.map(m=>`${h("th",m,1)}${m}`).join("")+""+h("tbody");return GL(e,n,t.limit,t.offset,{row(m){f=m,p+=(++d?"":"")+h("tr")},cell(m,y){p+=h("td",y,1)+c(m,i[y])+""}}),p+""}function kKe(e){return KC(e.style,t=>sr(t)?t:()=>t)}function DKe(e,t=!0,n=!1){return e===void 0||e?t:n}const $Ke=e=>Xl(e)?LC(e,!0):e;function LKe(e,t={}){const n=DKe(t.schema),r=t.format||{},i=YC(e,t.columns);let s="{";return n&&(s+='"schema":{"fields":'+JSON.stringify(i.map(o=>({name:o})))+'},"data":{'),i.forEach((o,a)=>{s+=(a?",":"")+JSON.stringify(o)+":[";const u=e.column(o),l=r[o]||$Ke;let c=-1;e.scan(f=>{const d=u.get(f);s+=(++c?",":"")+JSON.stringify(l(d))},!0,t.limit,t.offset),s+="]"}),s+"}"+(n?"}":"")}function MKe(e,t={}){const n=YC(e,t.columns),{align:r,format:i}=Vae(e,n,t),s=u=>u==="c"?":-:":u==="r"?"-:":":-",o=u=>u.replace(/\|/g,"\\|");let a="|"+n.map(o).join("|")+`| +|`+n.map(u=>s(r[u])).join("|")+"|";return GL(e,n,t.limit,t.offset,{row(){a+=` |`},cell(u,l){a+=o(zae(u,i[l]))+"|"}}),a+` -`}function Hae(e,t){for(const[n,r]of MC(t))e.set(n,r);return e}function MKe(e){return e.replace(/[.*+\-?^${}()|[\]\\]/g,"\\$&")}function ec(e,t,n=new Map){return t=bs(t)?e.columnName(t):t,Ui(t)?n.set(t,t):En(t)?t.forEach(r=>ec(e,r,n)):sr(t)?ec(e,t(e),n):as(t)?Hae(n,t):Wt(`Invalid column selection: ${el(t)}`),n}function QC(e,t){return e.toObject=t,e}function Wae(e){return En(e)?e.map(Wae):e&&e.toObject?e.toObject():e}function rg(){return QC(e=>e.columnNames(),()=>({all:[]}))}function qae(...e){return e=e.flat(),QC(t=>{const n=ec(t,e);return t.columnNames(r=>!n.has(r))},()=>({not:Wae(e)}))}function FKe(e,t){return QC(n=>{let r=bs(e)?e:n.columnIndex(e),i=bs(t)?t:n.columnIndex(t);if(i({range:[e,t]}))}function BKe(e){return Ui(e)&&(e=RegExp(MKe(e))),QC(t=>t.columnNames(n=>e.test(n)),()=>({matches:[e.source,e.flags]}))}function jKe(e){return r1(e.data)?e.data.constructor:Array}class Al extends rWe{static from(t,n){return new Al(oWe(t,n),n)}static new(t,n){if(t instanceof Al)return t;const r={},i=[];for(const[s,o]of MC(t))r[s]=o,i.push(s);return new Al(r,n||i)}constructor(t,n,r,i,s,o){KC(t,sWe,t),n=n||Object.keys(t);const a=n.length?t[n[0]].length:0;super(n,a,t,r,i,s,o)}create({data:t,names:n,filter:r,groups:i,order:s}){const o=r!==void 0?r:this.mask();return new Al(t||this._data,n||(t?null:this._names),o,i!==void 0?i:$We(this._group,r&&o),s!==void 0?s:this._order,this._params)}assign(...t){const n=this.numRows(),r=this.reify(),i=Mo(r).groupby(r.groups());return t.forEach(s=>{s=Al.new(s),s.numRows()!==n&&Wt("Assign row counts do not match"),s=s.reify(),s.columnNames(o=>i.add(o,s.column(o)))}),this.create(i.new())}columns(){return this._data}column(t){return this._data[t]}columnAt(t){return this._data[this._names[t]]}array(t,n=Array){const r=this.column(t),i=new n(this.numRows());let s=-1;return this.scan(o=>i[++s]=r.get(o),!0),i}get(t,n=0){const r=this.column(t);return this.isFiltered()||this.isOrdered()?r.get(this.indices()[n]):r.get(n)}getter(t){const n=this.column(t),r=this.isFiltered()||this.isOrdered()?this.indices():null;return r?i=>n.get(r[i]):n?i=>n.get(i):Wt(`Unrecognized column: ${t}`)}object(t=0){return qz(this)(t)}objects(t={}){const{grouped:n,limit:r,offset:i}=t,s=ec(this,t.columns||rg()),o=Lse(s),a=[];if(this.scan((u,l)=>a.push(o(u,l)),!0,r,i),n&&this.isGrouped()){const u=[];return this.scan(l=>u.push(l),!0,r,i),MWe(this,u,a,n)}return a}*[Symbol.iterator](){const t=qz(this),n=this.numRows();for(let r=0;rt.forEach(u):u=>this.scan(u,!0),a=r.length;i={};for(let u=0;uf[++d]=c.get(h))}this.isGrouped()&&(s=LWe(this.groups(),o,!!t,n))}return this.create({data:i,names:r,groups:s,filter:null,order:null})}transform(...t){return t.flat().reduce((n,r)=>r(n),this)}toArrow(t){return Uae(this,t)}toArrowBuffer(t){return xKe(this,t)}toCSV(t){return OKe(this,t)}toHTML(t){return RKe(this,t)}toJSON(t){return $Ke(this,t)}toMarkdown(t){return LKe(this,t)}}function qz(e){let t=e._builder;if(!t){const n=Lse(e.columnNames()),r=e.data();if(e.isOrdered()||e.isFiltered()){const i=e.indices();t=s=>n(i[s],r)}else t=i=>n(i,r);e._builder=t}return t}class UKe{constructor(t){this._outputs=t}size(){return this._outputs.length}outputs(){return this._outputs}init(){return{}}add(){}rem(){}write(){}}function pn(e,t,n,r){const i=n[e.type]||n.Default;if(i&&i(e,t,r)===!1)return;const s=VKe[e.type];s&&s(e,t,n)}const Vb=(e,t,n)=>{pn(e.argument,t,n,e)},i2=(e,t,n)=>{pn(e.left,t,n,e),pn(e.right,t,n,e)},Gz=(e,t,n)=>{pn(e.test,t,n,e),pn(e.consequent,t,n,e),e.alternate&&pn(e.alternate,t,n,e)},s2=(e,t,n)=>{hu(e.params,t,n,e),pn(e.body,t,n,e)},Yz=(e,t,n)=>{pn(e.callee,t,n,e),hu(e.arguments,t,n,e)},hu=(e,t,n,r)=>{e.forEach(i=>pn(i,t,n,r))},VKe={TemplateLiteral:(e,t,n)=>{hu(e.expressions,t,n,e),hu(e.quasis,t,n,e)},MemberExpression:(e,t,n)=>{pn(e.object,t,n,e),pn(e.property,t,n,e)},CallExpression:Yz,NewExpression:Yz,ArrayExpression:(e,t,n)=>{hu(e.elements,t,n,e)},AssignmentExpression:i2,AwaitExpression:Vb,BinaryExpression:i2,LogicalExpression:i2,UnaryExpression:Vb,UpdateExpression:Vb,ConditionalExpression:Gz,ObjectExpression:(e,t,n)=>{hu(e.properties,t,n,e)},Property:(e,t,n)=>{pn(e.key,t,n,e),pn(e.value,t,n,e)},ArrowFunctionExpression:s2,FunctionExpression:s2,FunctionDeclaration:s2,VariableDeclaration:(e,t,n)=>{hu(e.declarations,t,n,e)},VariableDeclarator:(e,t,n)=>{pn(e.id,t,n,e),pn(e.init,t,n,e)},SpreadElement:(e,t,n)=>{pn(e.argument,t,n,e)},BlockStatement:(e,t,n)=>{hu(e.body,t,n,e)},ExpressionStatement:(e,t,n)=>{pn(e.expression,t,n,e)},IfStatement:Gz,ForStatement:(e,t,n)=>{pn(e.init,t,n,e),pn(e.test,t,n,e),pn(e.update,t,n,e),pn(e.body,t,n,e)},WhileStatement:(e,t,n)=>{pn(e.test,t,n,e),pn(e.body,t,n,e)},DoWhileStatement:(e,t,n)=>{pn(e.body,t,n,e),pn(e.test,t,n,e)},SwitchStatement:(e,t,n)=>{pn(e.discriminant,t,n,e),hu(e.cases,t,n,e)},SwitchCase:(e,t,n)=>{e.test&&pn(e.test,t,n,e),hu(e.consequent,t,n,e)},ReturnStatement:Vb,Program:(e,t,n)=>{pn(e.body[0],t,n,e)}};function Gae(e){delete e.start,delete e.end,delete e.optional}function Kz(e){Gae(e),delete e.object,delete e.property,delete e.computed,e.table||delete e.table}function zKe(e){return pn(e,null,{Column:Kz,Constant:Kz,Default:Gae}),e}function ti(e,t){return t&&t.type===e}function HKe(e){return ti(jWe,e)||ti(BWe,e)}function WKe(e){return sr(e)?e:()=>e}const qKe="Escaped functions are not valid as rollup or pivot values.";function GKe(e,t,n){e.aggronly&&Wt(qKe);const r="(row,data)=>fn("+$se(e.table.columnNames())+",$)";return{escape:K6.escape(r,WKe(t.expr),n)}}var YKe=[509,0,227,0,150,4,294,9,1368,2,2,1,6,3,41,2,5,0,166,1,574,3,9,9,370,1,81,2,71,10,50,3,123,2,54,14,32,10,3,1,11,3,46,10,8,0,46,9,7,2,37,13,2,9,6,1,45,0,13,2,49,13,9,3,2,11,83,11,7,0,3,0,158,11,6,9,7,3,56,1,2,6,3,1,3,2,10,0,11,1,3,6,4,4,193,17,10,9,5,0,82,19,13,9,214,6,3,8,28,1,83,16,16,9,82,12,9,9,84,14,5,9,243,14,166,9,71,5,2,1,3,3,2,0,2,1,13,9,120,6,3,6,4,0,29,9,41,6,2,3,9,0,10,10,47,15,406,7,2,7,17,9,57,21,2,13,123,5,4,0,2,1,2,6,2,0,9,9,49,4,2,1,2,4,9,9,330,3,10,1,2,0,49,6,4,4,14,9,5351,0,7,14,13835,9,87,9,39,4,60,6,26,9,1014,0,2,54,8,3,82,0,12,1,19628,1,4706,45,3,22,543,4,4,5,9,7,3,6,31,3,149,2,1418,49,513,54,5,49,9,0,15,0,23,4,2,14,1361,6,2,16,3,6,2,1,2,4,101,0,161,6,10,9,357,0,62,13,499,13,983,6,110,6,6,9,4759,9,787719,239],Yae=[0,11,2,25,2,18,2,1,2,14,3,13,35,122,70,52,268,28,4,48,48,31,14,29,6,37,11,29,3,35,5,7,2,4,43,157,19,35,5,35,5,39,9,51,13,10,2,14,2,6,2,1,2,10,2,14,2,6,2,1,68,310,10,21,11,7,25,5,2,41,2,8,70,5,3,0,2,43,2,1,4,0,3,22,11,22,10,30,66,18,2,1,11,21,11,25,71,55,7,1,65,0,16,3,2,2,2,28,43,28,4,28,36,7,2,27,28,53,11,21,11,18,14,17,111,72,56,50,14,50,14,35,349,41,7,1,79,28,11,0,9,21,43,17,47,20,28,22,13,52,58,1,3,0,14,44,33,24,27,35,30,0,3,0,9,34,4,0,13,47,15,3,22,0,2,0,36,17,2,24,20,1,64,6,2,0,2,3,2,14,2,9,8,46,39,7,3,1,3,21,2,6,2,1,2,4,4,0,19,0,13,4,159,52,19,3,21,2,31,47,21,1,2,0,185,46,42,3,37,47,21,0,60,42,14,0,72,26,38,6,186,43,117,63,32,7,3,0,3,7,2,1,2,23,16,0,2,0,95,7,3,38,17,0,2,0,29,0,11,39,8,0,22,0,12,45,20,0,19,72,264,8,2,36,18,0,50,29,113,6,2,1,2,37,22,0,26,5,2,1,2,31,15,0,328,18,16,0,2,12,2,33,125,0,80,921,103,110,18,195,2637,96,16,1071,18,5,4026,582,8634,568,8,30,18,78,18,29,19,47,17,3,32,20,6,18,689,63,129,74,6,0,67,12,65,1,2,0,29,6135,9,1237,43,8,8936,3,2,6,2,1,2,290,16,0,30,2,3,0,15,3,9,395,2309,106,6,12,4,8,8,9,5991,84,2,70,2,1,3,0,3,1,3,3,2,11,2,0,2,6,2,64,2,3,3,7,2,6,2,27,2,3,2,4,2,0,4,6,2,339,3,24,2,24,2,30,2,24,2,30,2,24,2,30,2,24,2,30,2,24,2,7,1845,30,7,5,262,61,147,44,11,6,17,0,322,29,19,43,485,27,757,6,2,3,2,1,2,14,2,196,60,67,8,0,1205,3,2,26,2,1,2,0,3,0,2,9,2,3,2,0,2,0,7,0,5,0,2,0,2,0,2,2,2,1,2,0,3,0,2,0,2,0,2,0,2,0,2,1,2,0,3,3,2,6,2,3,2,3,2,0,2,9,2,16,6,2,2,4,2,16,4421,42719,33,4153,7,221,3,5761,15,7472,16,621,2467,541,1507,4938,6,4191],KKe="‌‍·̀-ͯ·҃-֑҇-ׇֽֿׁׂׅׄؐ-ًؚ-٩ٰۖ-ۜ۟-۪ۤۧۨ-ۭ۰-۹ܑܰ-݊ަ-ް߀-߉߫-߽߳ࠖ-࠙ࠛ-ࠣࠥ-ࠧࠩ-࡙࠭-࡛࢘-࢟࣊-ࣣ࣡-ःऺ-़ा-ॏ॑-ॗॢॣ०-९ঁ-ঃ়া-ৄেৈো-্ৗৢৣ০-৯৾ਁ-ਃ਼ਾ-ੂੇੈੋ-੍ੑ੦-ੱੵઁ-ઃ઼ા-ૅે-ૉો-્ૢૣ૦-૯ૺ-૿ଁ-ଃ଼ା-ୄେୈୋ-୍୕-ୗୢୣ୦-୯ஂா-ூெ-ைொ-்ௗ௦-௯ఀ-ఄ఼ా-ౄె-ైొ-్ౕౖౢౣ౦-౯ಁ-ಃ಼ಾ-ೄೆ-ೈೊ-್ೕೖೢೣ೦-೯ೳഀ-ഃ഻഼ാ-ൄെ-ൈൊ-്ൗൢൣ൦-൯ඁ-ඃ්ා-ුූෘ-ෟ෦-෯ෲෳัิ-ฺ็-๎๐-๙ັິ-ຼ່-໎໐-໙༘༙༠-༩༹༵༷༾༿ཱ-྄྆྇ྍ-ྗྙ-ྼ࿆ါ-ှ၀-၉ၖ-ၙၞ-ၠၢ-ၤၧ-ၭၱ-ၴႂ-ႍႏ-ႝ፝-፟፩-፱ᜒ-᜕ᜲ-᜴ᝒᝓᝲᝳ឴-៓៝០-៩᠋-᠍᠏-᠙ᢩᤠ-ᤫᤰ-᤻᥆-᥏᧐-᧚ᨗ-ᨛᩕ-ᩞ᩠-᩿᩼-᪉᪐-᪙᪰-᪽ᪿ-ᫎᬀ-ᬄ᬴-᭄᭐-᭙᭫-᭳ᮀ-ᮂᮡ-ᮭ᮰-᮹᯦-᯳ᰤ-᰷᱀-᱉᱐-᱙᳐-᳔᳒-᳨᳭᳴᳷-᳹᷀-᷿‌‍‿⁀⁔⃐-⃥⃜⃡-⃰⳯-⵿⳱ⷠ-〪ⷿ-゙゚〯・꘠-꘩꙯ꙴ-꙽ꚞꚟ꛰꛱ꠂ꠆ꠋꠣ-ꠧ꠬ꢀꢁꢴ-ꣅ꣐-꣙꣠-꣱ꣿ-꤉ꤦ-꤭ꥇ-꥓ꦀ-ꦃ꦳-꧀꧐-꧙ꧥ꧰-꧹ꨩ-ꨶꩃꩌꩍ꩐-꩙ꩻ-ꩽꪰꪲ-ꪴꪷꪸꪾ꪿꫁ꫫ-ꫯꫵ꫶ꯣ-ꯪ꯬꯭꯰-꯹ﬞ︀-️︠-︯︳︴﹍-﹏0-9_・",Kae="ªµºÀ-ÖØ-öø-ˁˆ-ˑˠ-ˤˬˮͰ-ʹͶͷͺ-ͽͿΆΈ-ΊΌΎ-ΡΣ-ϵϷ-ҁҊ-ԯԱ-Ֆՙՠ-ֈא-תׯ-ײؠ-يٮٯٱ-ۓەۥۦۮۯۺ-ۼۿܐܒ-ܯݍ-ޥޱߊ-ߪߴߵߺࠀ-ࠕࠚࠤࠨࡀ-ࡘࡠ-ࡪࡰ-ࢇࢉ-ࢎࢠ-ࣉऄ-हऽॐक़-ॡॱ-ঀঅ-ঌএঐও-নপ-রলশ-হঽৎড়ঢ়য়-ৡৰৱৼਅ-ਊਏਐਓ-ਨਪ-ਰਲਲ਼ਵਸ਼ਸਹਖ਼-ੜਫ਼ੲ-ੴઅ-ઍએ-ઑઓ-નપ-રલળવ-હઽૐૠૡૹଅ-ଌଏଐଓ-ନପ-ରଲଳଵ-ହଽଡ଼ଢ଼ୟ-ୡୱஃஅ-ஊஎ-ஐஒ-கஙசஜஞடணதந-பம-ஹௐఅ-ఌఎ-ఐఒ-నప-హఽౘ-ౚౝౠౡಀಅ-ಌಎ-ಐಒ-ನಪ-ಳವ-ಹಽೝೞೠೡೱೲഄ-ഌഎ-ഐഒ-ഺഽൎൔ-ൖൟ-ൡൺ-ൿඅ-ඖක-නඳ-රලව-ෆก-ะาำเ-ๆກຂຄຆ-ຊຌ-ຣລວ-ະາຳຽເ-ໄໆໜ-ໟༀཀ-ཇཉ-ཬྈ-ྌက-ဪဿၐ-ၕၚ-ၝၡၥၦၮ-ၰၵ-ႁႎႠ-ჅჇჍა-ჺჼ-ቈቊ-ቍቐ-ቖቘቚ-ቝበ-ኈኊ-ኍነ-ኰኲ-ኵኸ-ኾዀዂ-ዅወ-ዖዘ-ጐጒ-ጕጘ-ፚᎀ-ᎏᎠ-Ᏽᏸ-ᏽᐁ-ᙬᙯ-ᙿᚁ-ᚚᚠ-ᛪᛮ-ᛸᜀ-ᜑᜟ-ᜱᝀ-ᝑᝠ-ᝬᝮ-ᝰក-ឳៗៜᠠ-ᡸᢀ-ᢨᢪᢰ-ᣵᤀ-ᤞᥐ-ᥭᥰ-ᥴᦀ-ᦫᦰ-ᧉᨀ-ᨖᨠ-ᩔᪧᬅ-ᬳᭅ-ᭌᮃ-ᮠᮮᮯᮺ-ᯥᰀ-ᰣᱍ-ᱏᱚ-ᱽᲀ-ᲈᲐ-ᲺᲽ-Ჿᳩ-ᳬᳮ-ᳳᳵᳶᳺᴀ-ᶿḀ-ἕἘ-Ἕἠ-ὅὈ-Ὅὐ-ὗὙὛὝὟ-ώᾀ-ᾴᾶ-ᾼιῂ-ῄῆ-ῌῐ-ΐῖ-Ίῠ-Ῥῲ-ῴῶ-ῼⁱⁿₐ-ₜℂℇℊ-ℓℕ℘-ℝℤΩℨK-ℹℼ-ℿⅅ-ⅉⅎⅠ-ↈⰀ-ⳤⳫ-ⳮⳲⳳⴀ-ⴥⴧⴭⴰ-ⵧⵯⶀ-ⶖⶠ-ⶦⶨ-ⶮⶰ-ⶶⶸ-ⶾⷀ-ⷆⷈ-ⷎⷐ-ⷖⷘ-ⷞ々-〇〡-〩〱-〵〸-〼ぁ-ゖ゛-ゟァ-ヺー-ヿㄅ-ㄯㄱ-ㆎㆠ-ㆿㇰ-ㇿ㐀-䶿一-ꒌꓐ-ꓽꔀ-ꘌꘐ-ꘟꘪꘫꙀ-ꙮꙿ-ꚝꚠ-ꛯꜗ-ꜟꜢ-ꞈꞋ-ꟊꟐꟑꟓꟕ-ꟙꟲ-ꠁꠃ-ꠅꠇ-ꠊꠌ-ꠢꡀ-ꡳꢂ-ꢳꣲ-ꣷꣻꣽꣾꤊ-ꤥꤰ-ꥆꥠ-ꥼꦄ-ꦲꧏꧠ-ꧤꧦ-ꧯꧺ-ꧾꨀ-ꨨꩀ-ꩂꩄ-ꩋꩠ-ꩶꩺꩾ-ꪯꪱꪵꪶꪹ-ꪽꫀꫂꫛ-ꫝꫠ-ꫪꫲ-ꫴꬁ-ꬆꬉ-ꬎꬑ-ꬖꬠ-ꬦꬨ-ꬮꬰ-ꭚꭜ-ꭩꭰ-ꯢ가-힣ힰ-ퟆퟋ-ퟻ豈-舘並-龎ff-stﬓ-ﬗיִײַ-ﬨשׁ-זּטּ-לּמּנּסּףּפּצּ-ﮱﯓ-ﴽﵐ-ﶏﶒ-ﷇﷰ-ﷻﹰ-ﹴﹶ-ﻼA-Za-zヲ-하-ᅦᅧ-ᅬᅭ-ᅲᅳ-ᅵ",o2={3:"abstract boolean byte char class double enum export extends final float goto implements import int interface long native package private protected public short static super synchronized throws transient volatile",5:"class enum extends super const export import",6:"enum",strict:"implements interface let package private protected public static yield",strictBind:"eval arguments"},a2="break case catch continue debugger default do else finally for function if return switch throw try var while with null true false instanceof typeof void delete new in this",QKe={5:a2,"5module":a2+" export import",6:a2+" const class extends export import super"},XKe=/^in(stanceof)?$/,JKe=new RegExp("["+Kae+"]"),ZKe=new RegExp("["+Kae+KKe+"]");function vk(e,t){for(var n=65536,r=0;re)return!1;if(n+=t[r+1],n>=e)return!0}return!1}function tc(e,t){return e<65?e===36:e<91?!0:e<97?e===95:e<123?!0:e<=65535?e>=170&&JKe.test(String.fromCharCode(e)):t===!1?!1:vk(e,Yae)}function ig(e,t){return e<48?e===36:e<58?!0:e<65?!1:e<91?!0:e<97?e===95:e<123?!0:e<=65535?e>=170&&ZKe.test(String.fromCharCode(e)):t===!1?!1:vk(e,Yae)||vk(e,YKe)}var gn=function(t,n){n===void 0&&(n={}),this.label=t,this.keyword=n.keyword,this.beforeExpr=!!n.beforeExpr,this.startsExpr=!!n.startsExpr,this.isLoop=!!n.isLoop,this.isAssign=!!n.isAssign,this.prefix=!!n.prefix,this.postfix=!!n.postfix,this.binop=n.binop||null,this.updateContext=null};function Bo(e,t){return new gn(e,{beforeExpr:!0,binop:t})}var jo={beforeExpr:!0},Ps={startsExpr:!0},KL={};function on(e,t){return t===void 0&&(t={}),t.keyword=e,KL[e]=new gn(e,t)}var D={num:new gn("num",Ps),regexp:new gn("regexp",Ps),string:new gn("string",Ps),name:new gn("name",Ps),privateId:new gn("privateId",Ps),eof:new gn("eof"),bracketL:new gn("[",{beforeExpr:!0,startsExpr:!0}),bracketR:new gn("]"),braceL:new gn("{",{beforeExpr:!0,startsExpr:!0}),braceR:new gn("}"),parenL:new gn("(",{beforeExpr:!0,startsExpr:!0}),parenR:new gn(")"),comma:new gn(",",jo),semi:new gn(";",jo),colon:new gn(":",jo),dot:new gn("."),question:new gn("?",jo),questionDot:new gn("?."),arrow:new gn("=>",jo),template:new gn("template"),invalidTemplate:new gn("invalidTemplate"),ellipsis:new gn("...",jo),backQuote:new gn("`",Ps),dollarBraceL:new gn("${",{beforeExpr:!0,startsExpr:!0}),eq:new gn("=",{beforeExpr:!0,isAssign:!0}),assign:new gn("_=",{beforeExpr:!0,isAssign:!0}),incDec:new gn("++/--",{prefix:!0,postfix:!0,startsExpr:!0}),prefix:new gn("!/~",{beforeExpr:!0,prefix:!0,startsExpr:!0}),logicalOR:Bo("||",1),logicalAND:Bo("&&",2),bitwiseOR:Bo("|",3),bitwiseXOR:Bo("^",4),bitwiseAND:Bo("&",5),equality:Bo("==/!=/===/!==",6),relational:Bo("/<=/>=",7),bitShift:Bo("<>/>>>",8),plusMin:new gn("+/-",{beforeExpr:!0,binop:9,prefix:!0,startsExpr:!0}),modulo:Bo("%",10),star:Bo("*",10),slash:Bo("/",10),starstar:new gn("**",{beforeExpr:!0}),coalesce:Bo("??",1),_break:on("break"),_case:on("case",jo),_catch:on("catch"),_continue:on("continue"),_debugger:on("debugger"),_default:on("default",jo),_do:on("do",{isLoop:!0,beforeExpr:!0}),_else:on("else",jo),_finally:on("finally"),_for:on("for",{isLoop:!0}),_function:on("function",Ps),_if:on("if"),_return:on("return",jo),_switch:on("switch"),_throw:on("throw",jo),_try:on("try"),_var:on("var"),_const:on("const"),_while:on("while",{isLoop:!0}),_with:on("with"),_new:on("new",{beforeExpr:!0,startsExpr:!0}),_this:on("this",Ps),_super:on("super",Ps),_class:on("class",Ps),_extends:on("extends",jo),_export:on("export"),_import:on("import",Ps),_null:on("null",Ps),_true:on("true",Ps),_false:on("false",Ps),_in:on("in",{beforeExpr:!0,binop:7}),_instanceof:on("instanceof",{beforeExpr:!0,binop:7}),_typeof:on("typeof",{beforeExpr:!0,prefix:!0,startsExpr:!0}),_void:on("void",{beforeExpr:!0,prefix:!0,startsExpr:!0}),_delete:on("delete",{beforeExpr:!0,prefix:!0,startsExpr:!0})},va=/\r\n?|\n|\u2028|\u2029/,eQe=new RegExp(va.source,"g");function Fg(e){return e===10||e===13||e===8232||e===8233}function Qae(e,t,n){n===void 0&&(n=e.length);for(var r=t;r>10)+55296,(e&1023)+56320))}var rQe=/(?:[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])/,zv=function(t,n){this.line=t,this.column=n};zv.prototype.offset=function(t){return new zv(this.line,this.column+t)};var XC=function(t,n,r){this.start=n,this.end=r,t.sourceFile!==null&&(this.source=t.sourceFile)};function Zae(e,t){for(var n=1,r=0;;){var i=Qae(e,r,t);if(i<0)return new zv(n,t-r);++n,r=i}}var _k={ecmaVersion:null,sourceType:"script",onInsertedSemicolon:null,onTrailingComma:null,allowReserved:null,allowReturnOutsideFunction:!1,allowImportExportEverywhere:!1,allowAwaitOutsideFunction:null,allowSuperOutsideMethod:null,allowHashBang:!1,checkPrivateFields:!0,locations:!1,onToken:null,onComment:null,ranges:!1,program:null,sourceFile:null,directSourceFile:null,preserveParens:!1},Jz=!1;function iQe(e){var t={};for(var n in _k)t[n]=e&&c1(e,n)?e[n]:_k[n];if(t.ecmaVersion==="latest"?t.ecmaVersion=1e8:t.ecmaVersion==null?(!Jz&&typeof console=="object"&&console.warn&&(Jz=!0,console.warn(`Since Acorn 8.0.0, options.ecmaVersion is required. -Defaulting to 2020, but this will stop working in the future.`)),t.ecmaVersion=11):t.ecmaVersion>=2015&&(t.ecmaVersion-=2009),t.allowReserved==null&&(t.allowReserved=t.ecmaVersion<5),(!e||e.allowHashBang==null)&&(t.allowHashBang=t.ecmaVersion>=14),Qz(t.onToken)){var r=t.onToken;t.onToken=function(i){return r.push(i)}}return Qz(t.onComment)&&(t.onComment=sQe(t,t.onComment)),t}function sQe(e,t){return function(n,r,i,s,o,a){var u={type:n?"Block":"Line",value:r,start:i,end:s};e.locations&&(u.loc=new XC(this,o,a)),e.ranges&&(u.range=[i,s]),t.push(u)}}var Hv=1,Bg=2,QL=4,eue=8,tue=16,nue=32,XL=64,rue=128,f1=256,JL=Hv|Bg|f1;function ZL(e,t){return Bg|(e?QL:0)|(t?eue:0)}var TI=0,eM=1,vc=2,iue=3,sue=4,oue=5,oi=function(t,n,r){this.options=t=iQe(t),this.sourceFile=t.sourceFile,this.keywords=Xc(QKe[t.ecmaVersion>=6?6:t.sourceType==="module"?"5module":5]);var i="";t.allowReserved!==!0&&(i=o2[t.ecmaVersion>=6?6:t.ecmaVersion===5?5:3],t.sourceType==="module"&&(i+=" await")),this.reservedWords=Xc(i);var s=(i?i+" ":"")+o2.strict;this.reservedWordsStrict=Xc(s),this.reservedWordsStrictBind=Xc(s+" "+o2.strictBind),this.input=String(n),this.containsEsc=!1,r?(this.pos=r,this.lineStart=this.input.lastIndexOf(` -`,r-1)+1,this.curLine=this.input.slice(0,this.lineStart).split(va).length):(this.pos=this.lineStart=0,this.curLine=1),this.type=D.eof,this.value=null,this.start=this.end=this.pos,this.startLoc=this.endLoc=this.curPosition(),this.lastTokEndLoc=this.lastTokStartLoc=null,this.lastTokStart=this.lastTokEnd=this.pos,this.context=this.initialContext(),this.exprAllowed=!0,this.inModule=t.sourceType==="module",this.strict=this.inModule||this.strictDirective(this.pos),this.potentialArrowAt=-1,this.potentialArrowInForAwait=!1,this.yieldPos=this.awaitPos=this.awaitIdentPos=0,this.labels=[],this.undefinedExports=Object.create(null),this.pos===0&&t.allowHashBang&&this.input.slice(0,2)==="#!"&&this.skipLineComment(2),this.scopeStack=[],this.enterScope(Hv),this.regexpState=null,this.privateNameStack=[]},pl={inFunction:{configurable:!0},inGenerator:{configurable:!0},inAsync:{configurable:!0},canAwait:{configurable:!0},allowSuper:{configurable:!0},allowDirectSuper:{configurable:!0},treatFunctionsAsVar:{configurable:!0},allowNewDotTarget:{configurable:!0},inClassStaticBlock:{configurable:!0}};oi.prototype.parse=function(){var t=this.options.program||this.startNode();return this.nextToken(),this.parseTopLevel(t)};pl.inFunction.get=function(){return(this.currentVarScope().flags&Bg)>0};pl.inGenerator.get=function(){return(this.currentVarScope().flags&eue)>0&&!this.currentVarScope().inClassFieldInit};pl.inAsync.get=function(){return(this.currentVarScope().flags&QL)>0&&!this.currentVarScope().inClassFieldInit};pl.canAwait.get=function(){for(var e=this.scopeStack.length-1;e>=0;e--){var t=this.scopeStack[e];if(t.inClassFieldInit||t.flags&f1)return!1;if(t.flags&Bg)return(t.flags&QL)>0}return this.inModule&&this.options.ecmaVersion>=13||this.options.allowAwaitOutsideFunction};pl.allowSuper.get=function(){var e=this.currentThisScope(),t=e.flags,n=e.inClassFieldInit;return(t&XL)>0||n||this.options.allowSuperOutsideMethod};pl.allowDirectSuper.get=function(){return(this.currentThisScope().flags&rue)>0};pl.treatFunctionsAsVar.get=function(){return this.treatFunctionsAsVarInScope(this.currentScope())};pl.allowNewDotTarget.get=function(){var e=this.currentThisScope(),t=e.flags,n=e.inClassFieldInit;return(t&(Bg|f1))>0||n};pl.inClassStaticBlock.get=function(){return(this.currentVarScope().flags&f1)>0};oi.extend=function(){for(var t=[],n=arguments.length;n--;)t[n]=arguments[n];for(var r=this,i=0;i=,?^&]/.test(i)||i==="!"&&this.input.charAt(r+1)==="=")}e+=t[0].length,Yo.lastIndex=e,e+=Yo.exec(this.input)[0].length,this.input[e]===";"&&e++}};Is.eat=function(e){return this.type===e?(this.next(),!0):!1};Is.isContextual=function(e){return this.type===D.name&&this.value===e&&!this.containsEsc};Is.eatContextual=function(e){return this.isContextual(e)?(this.next(),!0):!1};Is.expectContextual=function(e){this.eatContextual(e)||this.unexpected()};Is.canInsertSemicolon=function(){return this.type===D.eof||this.type===D.braceR||va.test(this.input.slice(this.lastTokEnd,this.start))};Is.insertSemicolon=function(){if(this.canInsertSemicolon())return this.options.onInsertedSemicolon&&this.options.onInsertedSemicolon(this.lastTokEnd,this.lastTokEndLoc),!0};Is.semicolon=function(){!this.eat(D.semi)&&!this.insertSemicolon()&&this.unexpected()};Is.afterTrailingComma=function(e,t){if(this.type===e)return this.options.onTrailingComma&&this.options.onTrailingComma(this.lastTokStart,this.lastTokStartLoc),t||this.next(),!0};Is.expect=function(e){this.eat(e)||this.unexpected()};Is.unexpected=function(e){this.raise(e??this.start,"Unexpected token")};var JC=function(){this.shorthandAssign=this.trailingComma=this.parenthesizedAssign=this.parenthesizedBind=this.doubleProto=-1};Is.checkPatternErrors=function(e,t){if(e){e.trailingComma>-1&&this.raiseRecoverable(e.trailingComma,"Comma is not permitted after the rest element");var n=t?e.parenthesizedAssign:e.parenthesizedBind;n>-1&&this.raiseRecoverable(n,t?"Assigning to rvalue":"Parenthesized pattern")}};Is.checkExpressionErrors=function(e,t){if(!e)return!1;var n=e.shorthandAssign,r=e.doubleProto;if(!t)return n>=0||r>=0;n>=0&&this.raise(n,"Shorthand property assignments are valid only in destructuring patterns"),r>=0&&this.raiseRecoverable(r,"Redefinition of __proto__ property")};Is.checkYieldAwaitInDefaultParams=function(){this.yieldPos&&(!this.awaitPos||this.yieldPos55295&&r<56320)return!0;if(tc(r,!0)){for(var i=n+1;ig(r=this.input.charCodeAt(i),!0);)++i;if(r===92||r>55295&&r<56320)return!0;var s=this.input.slice(n,i);if(!XKe.test(s))return!0}return!1};ft.isAsyncFunction=function(){if(this.options.ecmaVersion<8||!this.isContextual("async"))return!1;Yo.lastIndex=this.pos;var e=Yo.exec(this.input),t=this.pos+e[0].length,n;return!va.test(this.input.slice(this.pos,t))&&this.input.slice(t,t+8)==="function"&&(t+8===this.input.length||!(ig(n=this.input.charCodeAt(t+8))||n>55295&&n<56320))};ft.parseStatement=function(e,t,n){var r=this.type,i=this.startNode(),s;switch(this.isLet(e)&&(r=D._var,s="let"),r){case D._break:case D._continue:return this.parseBreakContinueStatement(i,r.keyword);case D._debugger:return this.parseDebuggerStatement(i);case D._do:return this.parseDoStatement(i);case D._for:return this.parseForStatement(i);case D._function:return e&&(this.strict||e!=="if"&&e!=="label")&&this.options.ecmaVersion>=6&&this.unexpected(),this.parseFunctionStatement(i,!1,!e);case D._class:return e&&this.unexpected(),this.parseClass(i,!0);case D._if:return this.parseIfStatement(i);case D._return:return this.parseReturnStatement(i);case D._switch:return this.parseSwitchStatement(i);case D._throw:return this.parseThrowStatement(i);case D._try:return this.parseTryStatement(i);case D._const:case D._var:return s=s||this.value,e&&s!=="var"&&this.unexpected(),this.parseVarStatement(i,s);case D._while:return this.parseWhileStatement(i);case D._with:return this.parseWithStatement(i);case D.braceL:return this.parseBlock(!0,i);case D.semi:return this.parseEmptyStatement(i);case D._export:case D._import:if(this.options.ecmaVersion>10&&r===D._import){Yo.lastIndex=this.pos;var o=Yo.exec(this.input),a=this.pos+o[0].length,u=this.input.charCodeAt(a);if(u===40||u===46)return this.parseExpressionStatement(i,this.parseExpression())}return this.options.allowImportExportEverywhere||(t||this.raise(this.start,"'import' and 'export' may only appear at the top level"),this.inModule||this.raise(this.start,"'import' and 'export' may appear only with 'sourceType: module'")),r===D._import?this.parseImport(i):this.parseExport(i,n);default:if(this.isAsyncFunction())return e&&this.unexpected(),this.next(),this.parseFunctionStatement(i,!0,!e);var l=this.value,c=this.parseExpression();return r===D.name&&c.type==="Identifier"&&this.eat(D.colon)?this.parseLabeledStatement(i,l,c,e):this.parseExpressionStatement(i,c)}};ft.parseBreakContinueStatement=function(e,t){var n=t==="break";this.next(),this.eat(D.semi)||this.insertSemicolon()?e.label=null:this.type!==D.name?this.unexpected():(e.label=this.parseIdent(),this.semicolon());for(var r=0;r=6?this.eat(D.semi):this.semicolon(),this.finishNode(e,"DoWhileStatement")};ft.parseForStatement=function(e){this.next();var t=this.options.ecmaVersion>=9&&this.canAwait&&this.eatContextual("await")?this.lastTokStart:-1;if(this.labels.push(tM),this.enterScope(0),this.expect(D.parenL),this.type===D.semi)return t>-1&&this.unexpected(t),this.parseFor(e,null);var n=this.isLet();if(this.type===D._var||this.type===D._const||n){var r=this.startNode(),i=n?"let":this.value;return this.next(),this.parseVar(r,!0,i),this.finishNode(r,"VariableDeclaration"),(this.type===D._in||this.options.ecmaVersion>=6&&this.isContextual("of"))&&r.declarations.length===1?(this.options.ecmaVersion>=9&&(this.type===D._in?t>-1&&this.unexpected(t):e.await=t>-1),this.parseForIn(e,r)):(t>-1&&this.unexpected(t),this.parseFor(e,r))}var s=this.isContextual("let"),o=!1,a=new JC,u=this.parseExpression(t>-1?"await":!0,a);return this.type===D._in||(o=this.options.ecmaVersion>=6&&this.isContextual("of"))?(this.options.ecmaVersion>=9&&(this.type===D._in?t>-1&&this.unexpected(t):e.await=t>-1),s&&o&&this.raise(u.start,"The left-hand side of a for-of loop may not start with 'let'."),this.toAssignable(u,!1,a),this.checkLValPattern(u),this.parseForIn(e,u)):(this.checkExpressionErrors(a,!0),t>-1&&this.unexpected(t),this.parseFor(e,u))};ft.parseFunctionStatement=function(e,t,n){return this.next(),this.parseFunction(e,By|(n?0:bk),!1,t)};ft.parseIfStatement=function(e){return this.next(),e.test=this.parseParenExpression(),e.consequent=this.parseStatement("if"),e.alternate=this.eat(D._else)?this.parseStatement("if"):null,this.finishNode(e,"IfStatement")};ft.parseReturnStatement=function(e){return!this.inFunction&&!this.options.allowReturnOutsideFunction&&this.raise(this.start,"'return' outside of function"),this.next(),this.eat(D.semi)||this.insertSemicolon()?e.argument=null:(e.argument=this.parseExpression(),this.semicolon()),this.finishNode(e,"ReturnStatement")};ft.parseSwitchStatement=function(e){this.next(),e.discriminant=this.parseParenExpression(),e.cases=[],this.expect(D.braceL),this.labels.push(aQe),this.enterScope(0);for(var t,n=!1;this.type!==D.braceR;)if(this.type===D._case||this.type===D._default){var r=this.type===D._case;t&&this.finishNode(t,"SwitchCase"),e.cases.push(t=this.startNode()),t.consequent=[],this.next(),r?t.test=this.parseExpression():(n&&this.raiseRecoverable(this.lastTokStart,"Multiple default clauses"),n=!0,t.test=null),this.expect(D.colon)}else t||this.unexpected(),t.consequent.push(this.parseStatement(null));return this.exitScope(),t&&this.finishNode(t,"SwitchCase"),this.next(),this.labels.pop(),this.finishNode(e,"SwitchStatement")};ft.parseThrowStatement=function(e){return this.next(),va.test(this.input.slice(this.lastTokEnd,this.start))&&this.raise(this.lastTokEnd,"Illegal newline after throw"),e.argument=this.parseExpression(),this.semicolon(),this.finishNode(e,"ThrowStatement")};var uQe=[];ft.parseCatchClauseParam=function(){var e=this.parseBindingAtom(),t=e.type==="Identifier";return this.enterScope(t?nue:0),this.checkLValPattern(e,t?sue:vc),this.expect(D.parenR),e};ft.parseTryStatement=function(e){if(this.next(),e.block=this.parseBlock(),e.handler=null,this.type===D._catch){var t=this.startNode();this.next(),this.eat(D.parenL)?t.param=this.parseCatchClauseParam():(this.options.ecmaVersion<10&&this.unexpected(),t.param=null,this.enterScope(0)),t.body=this.parseBlock(!1),this.exitScope(),e.handler=this.finishNode(t,"CatchClause")}return e.finalizer=this.eat(D._finally)?this.parseBlock():null,!e.handler&&!e.finalizer&&this.raise(e.start,"Missing catch or finally clause"),this.finishNode(e,"TryStatement")};ft.parseVarStatement=function(e,t,n){return this.next(),this.parseVar(e,!1,t,n),this.semicolon(),this.finishNode(e,"VariableDeclaration")};ft.parseWhileStatement=function(e){return this.next(),e.test=this.parseParenExpression(),this.labels.push(tM),e.body=this.parseStatement("while"),this.labels.pop(),this.finishNode(e,"WhileStatement")};ft.parseWithStatement=function(e){return this.strict&&this.raise(this.start,"'with' in strict mode"),this.next(),e.object=this.parseParenExpression(),e.body=this.parseStatement("with"),this.finishNode(e,"WithStatement")};ft.parseEmptyStatement=function(e){return this.next(),this.finishNode(e,"EmptyStatement")};ft.parseLabeledStatement=function(e,t,n,r){for(var i=0,s=this.labels;i=0;u--){var l=this.labels[u];if(l.statementStart===e.start)l.statementStart=this.start,l.kind=a;else break}return this.labels.push({name:t,kind:a,statementStart:this.start}),e.body=this.parseStatement(r?r.indexOf("label")===-1?r+"label":r:"label"),this.labels.pop(),e.label=n,this.finishNode(e,"LabeledStatement")};ft.parseExpressionStatement=function(e,t){return e.expression=t,this.semicolon(),this.finishNode(e,"ExpressionStatement")};ft.parseBlock=function(e,t,n){for(e===void 0&&(e=!0),t===void 0&&(t=this.startNode()),t.body=[],this.expect(D.braceL),e&&this.enterScope(0);this.type!==D.braceR;){var r=this.parseStatement(null);t.body.push(r)}return n&&(this.strict=!1),this.next(),e&&this.exitScope(),this.finishNode(t,"BlockStatement")};ft.parseFor=function(e,t){return e.init=t,this.expect(D.semi),e.test=this.type===D.semi?null:this.parseExpression(),this.expect(D.semi),e.update=this.type===D.parenR?null:this.parseExpression(),this.expect(D.parenR),e.body=this.parseStatement("for"),this.exitScope(),this.labels.pop(),this.finishNode(e,"ForStatement")};ft.parseForIn=function(e,t){var n=this.type===D._in;return this.next(),t.type==="VariableDeclaration"&&t.declarations[0].init!=null&&(!n||this.options.ecmaVersion<8||this.strict||t.kind!=="var"||t.declarations[0].id.type!=="Identifier")&&this.raise(t.start,(n?"for-in":"for-of")+" loop variable declaration may not have an initializer"),e.left=t,e.right=n?this.parseExpression():this.parseMaybeAssign(),this.expect(D.parenR),e.body=this.parseStatement("for"),this.exitScope(),this.labels.pop(),this.finishNode(e,n?"ForInStatement":"ForOfStatement")};ft.parseVar=function(e,t,n,r){for(e.declarations=[],e.kind=n;;){var i=this.startNode();if(this.parseVarId(i,n),this.eat(D.eq)?i.init=this.parseMaybeAssign(t):!r&&n==="const"&&!(this.type===D._in||this.options.ecmaVersion>=6&&this.isContextual("of"))?this.unexpected():!r&&i.id.type!=="Identifier"&&!(t&&(this.type===D._in||this.isContextual("of")))?this.raise(this.lastTokEnd,"Complex binding patterns require an initialization value"):i.init=null,e.declarations.push(this.finishNode(i,"VariableDeclarator")),!this.eat(D.comma))break}return e};ft.parseVarId=function(e,t){e.id=this.parseBindingAtom(),this.checkLValPattern(e.id,t==="var"?eM:vc,!1)};var By=1,bk=2,aue=4;ft.parseFunction=function(e,t,n,r,i){this.initFunction(e),(this.options.ecmaVersion>=9||this.options.ecmaVersion>=6&&!r)&&(this.type===D.star&&t&bk&&this.unexpected(),e.generator=this.eat(D.star)),this.options.ecmaVersion>=8&&(e.async=!!r),t&By&&(e.id=t&aue&&this.type!==D.name?null:this.parseIdent(),e.id&&!(t&bk)&&this.checkLValSimple(e.id,this.strict||e.generator||e.async?this.treatFunctionsAsVar?eM:vc:iue));var s=this.yieldPos,o=this.awaitPos,a=this.awaitIdentPos;return this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0,this.enterScope(ZL(e.async,e.generator)),t&By||(e.id=this.type===D.name?this.parseIdent():null),this.parseFunctionParams(e),this.parseFunctionBody(e,n,!1,i),this.yieldPos=s,this.awaitPos=o,this.awaitIdentPos=a,this.finishNode(e,t&By?"FunctionDeclaration":"FunctionExpression")};ft.parseFunctionParams=function(e){this.expect(D.parenL),e.params=this.parseBindingList(D.parenR,!1,this.options.ecmaVersion>=8),this.checkYieldAwaitInDefaultParams()};ft.parseClass=function(e,t){this.next();var n=this.strict;this.strict=!0,this.parseClassId(e,t),this.parseClassSuper(e);var r=this.enterClassBody(),i=this.startNode(),s=!1;for(i.body=[],this.expect(D.braceL);this.type!==D.braceR;){var o=this.parseClassElement(e.superClass!==null);o&&(i.body.push(o),o.type==="MethodDefinition"&&o.kind==="constructor"?(s&&this.raiseRecoverable(o.start,"Duplicate constructor in the same class"),s=!0):o.key&&o.key.type==="PrivateIdentifier"&&lQe(r,o)&&this.raiseRecoverable(o.key.start,"Identifier '#"+o.key.name+"' has already been declared"))}return this.strict=n,this.next(),e.body=this.finishNode(i,"ClassBody"),this.exitClassBody(),this.finishNode(e,t?"ClassDeclaration":"ClassExpression")};ft.parseClassElement=function(e){if(this.eat(D.semi))return null;var t=this.options.ecmaVersion,n=this.startNode(),r="",i=!1,s=!1,o="method",a=!1;if(this.eatContextual("static")){if(t>=13&&this.eat(D.braceL))return this.parseClassStaticBlock(n),n;this.isClassElementNameStart()||this.type===D.star?a=!0:r="static"}if(n.static=a,!r&&t>=8&&this.eatContextual("async")&&((this.isClassElementNameStart()||this.type===D.star)&&!this.canInsertSemicolon()?s=!0:r="async"),!r&&(t>=9||!s)&&this.eat(D.star)&&(i=!0),!r&&!s&&!i){var u=this.value;(this.eatContextual("get")||this.eatContextual("set"))&&(this.isClassElementNameStart()?o=u:r=u)}if(r?(n.computed=!1,n.key=this.startNodeAt(this.lastTokStart,this.lastTokStartLoc),n.key.name=r,this.finishNode(n.key,"Identifier")):this.parseClassElementName(n),t<13||this.type===D.parenL||o!=="method"||i||s){var l=!n.static&&II(n,"constructor"),c=l&&e;l&&o!=="method"&&this.raise(n.key.start,"Constructor can't have get/set modifier"),n.kind=l?"constructor":o,this.parseClassMethod(n,i,s,c)}else this.parseClassField(n);return n};ft.isClassElementNameStart=function(){return this.type===D.name||this.type===D.privateId||this.type===D.num||this.type===D.string||this.type===D.bracketL||this.type.keyword};ft.parseClassElementName=function(e){this.type===D.privateId?(this.value==="constructor"&&this.raise(this.start,"Classes can't have an element named '#constructor'"),e.computed=!1,e.key=this.parsePrivateIdent()):this.parsePropertyName(e)};ft.parseClassMethod=function(e,t,n,r){var i=e.key;e.kind==="constructor"?(t&&this.raise(i.start,"Constructor can't be a generator"),n&&this.raise(i.start,"Constructor can't be an async method")):e.static&&II(e,"prototype")&&this.raise(i.start,"Classes may not have a static property named prototype");var s=e.value=this.parseMethod(t,n,r);return e.kind==="get"&&s.params.length!==0&&this.raiseRecoverable(s.start,"getter should have no params"),e.kind==="set"&&s.params.length!==1&&this.raiseRecoverable(s.start,"setter should have exactly one param"),e.kind==="set"&&s.params[0].type==="RestElement"&&this.raiseRecoverable(s.params[0].start,"Setter cannot use rest params"),this.finishNode(e,"MethodDefinition")};ft.parseClassField=function(e){if(II(e,"constructor")?this.raise(e.key.start,"Classes can't have a field named 'constructor'"):e.static&&II(e,"prototype")&&this.raise(e.key.start,"Classes can't have a static field named 'prototype'"),this.eat(D.eq)){var t=this.currentThisScope(),n=t.inClassFieldInit;t.inClassFieldInit=!0,e.value=this.parseMaybeAssign(),t.inClassFieldInit=n}else e.value=null;return this.semicolon(),this.finishNode(e,"PropertyDefinition")};ft.parseClassStaticBlock=function(e){e.body=[];var t=this.labels;for(this.labels=[],this.enterScope(f1|XL);this.type!==D.braceR;){var n=this.parseStatement(null);e.body.push(n)}return this.next(),this.exitScope(),this.labels=t,this.finishNode(e,"StaticBlock")};ft.parseClassId=function(e,t){this.type===D.name?(e.id=this.parseIdent(),t&&this.checkLValSimple(e.id,vc,!1)):(t===!0&&this.unexpected(),e.id=null)};ft.parseClassSuper=function(e){e.superClass=this.eat(D._extends)?this.parseExprSubscripts(null,!1):null};ft.enterClassBody=function(){var e={declared:Object.create(null),used:[]};return this.privateNameStack.push(e),e.declared};ft.exitClassBody=function(){var e=this.privateNameStack.pop(),t=e.declared,n=e.used;if(this.options.checkPrivateFields)for(var r=this.privateNameStack.length,i=r===0?null:this.privateNameStack[r-1],s=0;s=11&&(this.eatContextual("as")?(e.exported=this.parseModuleExportName(),this.checkExport(t,e.exported,this.lastTokStart)):e.exported=null),this.expectContextual("from"),this.type!==D.string&&this.unexpected(),e.source=this.parseExprAtom(),this.semicolon(),this.finishNode(e,"ExportAllDeclaration")};ft.parseExport=function(e,t){if(this.next(),this.eat(D.star))return this.parseExportAllDeclaration(e,t);if(this.eat(D._default))return this.checkExport(t,"default",this.lastTokStart),e.declaration=this.parseExportDefaultDeclaration(),this.finishNode(e,"ExportDefaultDeclaration");if(this.shouldParseExportStatement())e.declaration=this.parseExportDeclaration(e),e.declaration.type==="VariableDeclaration"?this.checkVariableExport(t,e.declaration.declarations):this.checkExport(t,e.declaration.id,e.declaration.id.start),e.specifiers=[],e.source=null;else{if(e.declaration=null,e.specifiers=this.parseExportSpecifiers(t),this.eatContextual("from"))this.type!==D.string&&this.unexpected(),e.source=this.parseExprAtom();else{for(var n=0,r=e.specifiers;n=13&&this.type===D.string){var e=this.parseLiteral(this.value);return rQe.test(e.value)&&this.raise(e.start,"An export name cannot include a lone surrogate."),e}return this.parseIdent(!0)};ft.adaptDirectivePrologue=function(e){for(var t=0;t=5&&e.type==="ExpressionStatement"&&e.expression.type==="Literal"&&typeof e.expression.value=="string"&&(this.input[e.start]==='"'||this.input[e.start]==="'")};var _a=oi.prototype;_a.toAssignable=function(e,t,n){if(this.options.ecmaVersion>=6&&e)switch(e.type){case"Identifier":this.inAsync&&e.name==="await"&&this.raise(e.start,"Cannot use 'await' as identifier inside an async function");break;case"ObjectPattern":case"ArrayPattern":case"AssignmentPattern":case"RestElement":break;case"ObjectExpression":e.type="ObjectPattern",n&&this.checkPatternErrors(n,!0);for(var r=0,i=e.properties;r=8&&!a&&u.name==="async"&&!this.canInsertSemicolon()&&this.eat(D._function))return this.overrideContext(hr.f_expr),this.parseFunction(this.startNodeAt(s,o),0,!1,!0,t);if(i&&!this.canInsertSemicolon()){if(this.eat(D.arrow))return this.parseArrowExpression(this.startNodeAt(s,o),[u],!1,t);if(this.options.ecmaVersion>=8&&u.name==="async"&&this.type===D.name&&!a&&(!this.potentialArrowInForAwait||this.value!=="of"||this.containsEsc))return u=this.parseIdent(!1),(this.canInsertSemicolon()||!this.eat(D.arrow))&&this.unexpected(),this.parseArrowExpression(this.startNodeAt(s,o),[u],!0,t)}return u;case D.regexp:var l=this.value;return r=this.parseLiteral(l.value),r.regex={pattern:l.pattern,flags:l.flags},r;case D.num:case D.string:return this.parseLiteral(this.value);case D._null:case D._true:case D._false:return r=this.startNode(),r.value=this.type===D._null?null:this.type===D._true,r.raw=this.type.keyword,this.next(),this.finishNode(r,"Literal");case D.parenL:var c=this.start,f=this.parseParenAndDistinguishExpression(i,t);return e&&(e.parenthesizedAssign<0&&!this.isSimpleAssignTarget(f)&&(e.parenthesizedAssign=c),e.parenthesizedBind<0&&(e.parenthesizedBind=c)),f;case D.bracketL:return r=this.startNode(),this.next(),r.elements=this.parseExprList(D.bracketR,!0,!0,e),this.finishNode(r,"ArrayExpression");case D.braceL:return this.overrideContext(hr.b_expr),this.parseObj(!1,e);case D._function:return r=this.startNode(),this.next(),this.parseFunction(r,0);case D._class:return this.parseClass(this.startNode(),!1);case D._new:return this.parseNew();case D.backQuote:return this.parseTemplate();case D._import:return this.options.ecmaVersion>=11?this.parseExprImport(n):this.unexpected();default:return this.parseExprAtomDefault()}};kt.parseExprAtomDefault=function(){this.unexpected()};kt.parseExprImport=function(e){var t=this.startNode();if(this.containsEsc&&this.raiseRecoverable(this.start,"Escape sequence in keyword import"),this.next(),this.type===D.parenL&&!e)return this.parseDynamicImport(t);if(this.type===D.dot){var n=this.startNodeAt(t.start,t.loc&&t.loc.start);return n.name="import",t.meta=this.finishNode(n,"Identifier"),this.parseImportMeta(t)}else this.unexpected()};kt.parseDynamicImport=function(e){if(this.next(),e.source=this.parseMaybeAssign(),!this.eat(D.parenR)){var t=this.start;this.eat(D.comma)&&this.eat(D.parenR)?this.raiseRecoverable(t,"Trailing comma is not allowed in import()"):this.unexpected(t)}return this.finishNode(e,"ImportExpression")};kt.parseImportMeta=function(e){this.next();var t=this.containsEsc;return e.property=this.parseIdent(!0),e.property.name!=="meta"&&this.raiseRecoverable(e.property.start,"The only valid meta property for import is 'import.meta'"),t&&this.raiseRecoverable(e.start,"'import.meta' must not contain escaped characters"),this.options.sourceType!=="module"&&!this.options.allowImportExportEverywhere&&this.raiseRecoverable(e.start,"Cannot use 'import.meta' outside a module"),this.finishNode(e,"MetaProperty")};kt.parseLiteral=function(e){var t=this.startNode();return t.value=e,t.raw=this.input.slice(this.start,this.end),t.raw.charCodeAt(t.raw.length-1)===110&&(t.bigint=t.raw.slice(0,-1).replace(/_/g,"")),this.next(),this.finishNode(t,"Literal")};kt.parseParenExpression=function(){this.expect(D.parenL);var e=this.parseExpression();return this.expect(D.parenR),e};kt.shouldParseArrow=function(e){return!this.canInsertSemicolon()};kt.parseParenAndDistinguishExpression=function(e,t){var n=this.start,r=this.startLoc,i,s=this.options.ecmaVersion>=8;if(this.options.ecmaVersion>=6){this.next();var o=this.start,a=this.startLoc,u=[],l=!0,c=!1,f=new JC,d=this.yieldPos,h=this.awaitPos,p;for(this.yieldPos=0,this.awaitPos=0;this.type!==D.parenR;)if(l?l=!1:this.expect(D.comma),s&&this.afterTrailingComma(D.parenR,!0)){c=!0;break}else if(this.type===D.ellipsis){p=this.start,u.push(this.parseParenItem(this.parseRestBinding())),this.type===D.comma&&this.raiseRecoverable(this.start,"Comma is not permitted after the rest element");break}else u.push(this.parseMaybeAssign(!1,f,this.parseParenItem));var m=this.lastTokEnd,y=this.lastTokEndLoc;if(this.expect(D.parenR),e&&this.shouldParseArrow(u)&&this.eat(D.arrow))return this.checkPatternErrors(f,!1),this.checkYieldAwaitInDefaultParams(),this.yieldPos=d,this.awaitPos=h,this.parseParenArrowList(n,r,u,t);(!u.length||c)&&this.unexpected(this.lastTokStart),p&&this.unexpected(p),this.checkExpressionErrors(f,!0),this.yieldPos=d||this.yieldPos,this.awaitPos=h||this.awaitPos,u.length>1?(i=this.startNodeAt(o,a),i.expressions=u,this.finishNodeAt(i,"SequenceExpression",m,y)):i=u[0]}else i=this.parseParenExpression();if(this.options.preserveParens){var g=this.startNodeAt(n,r);return g.expression=i,this.finishNode(g,"ParenthesizedExpression")}else return i};kt.parseParenItem=function(e){return e};kt.parseParenArrowList=function(e,t,n,r){return this.parseArrowExpression(this.startNodeAt(e,t),n,!1,r)};var cQe=[];kt.parseNew=function(){this.containsEsc&&this.raiseRecoverable(this.start,"Escape sequence in keyword new");var e=this.startNode();if(this.next(),this.options.ecmaVersion>=6&&this.type===D.dot){var t=this.startNodeAt(e.start,e.loc&&e.loc.start);t.name="new",e.meta=this.finishNode(t,"Identifier"),this.next();var n=this.containsEsc;return e.property=this.parseIdent(!0),e.property.name!=="target"&&this.raiseRecoverable(e.property.start,"The only valid meta property for new is 'new.target'"),n&&this.raiseRecoverable(e.start,"'new.target' must not contain escaped characters"),this.allowNewDotTarget||this.raiseRecoverable(e.start,"'new.target' can only be used in functions and class static block"),this.finishNode(e,"MetaProperty")}var r=this.start,i=this.startLoc;return e.callee=this.parseSubscripts(this.parseExprAtom(null,!1,!0),r,i,!0,!1),this.eat(D.parenL)?e.arguments=this.parseExprList(D.parenR,this.options.ecmaVersion>=8,!1):e.arguments=cQe,this.finishNode(e,"NewExpression")};kt.parseTemplateElement=function(e){var t=e.isTagged,n=this.startNode();return this.type===D.invalidTemplate?(t||this.raiseRecoverable(this.start,"Bad escape sequence in untagged template literal"),n.value={raw:this.value,cooked:null}):n.value={raw:this.input.slice(this.start,this.end).replace(/\r\n?/g,` -`),cooked:this.value},this.next(),n.tail=this.type===D.backQuote,this.finishNode(n,"TemplateElement")};kt.parseTemplate=function(e){e===void 0&&(e={});var t=e.isTagged;t===void 0&&(t=!1);var n=this.startNode();this.next(),n.expressions=[];var r=this.parseTemplateElement({isTagged:t});for(n.quasis=[r];!r.tail;)this.type===D.eof&&this.raise(this.pos,"Unterminated template literal"),this.expect(D.dollarBraceL),n.expressions.push(this.parseExpression()),this.expect(D.braceR),n.quasis.push(r=this.parseTemplateElement({isTagged:t}));return this.next(),this.finishNode(n,"TemplateLiteral")};kt.isAsyncProp=function(e){return!e.computed&&e.key.type==="Identifier"&&e.key.name==="async"&&(this.type===D.name||this.type===D.num||this.type===D.string||this.type===D.bracketL||this.type.keyword||this.options.ecmaVersion>=9&&this.type===D.star)&&!va.test(this.input.slice(this.lastTokEnd,this.start))};kt.parseObj=function(e,t){var n=this.startNode(),r=!0,i={};for(n.properties=[],this.next();!this.eat(D.braceR);){if(r)r=!1;else if(this.expect(D.comma),this.options.ecmaVersion>=5&&this.afterTrailingComma(D.braceR))break;var s=this.parseProperty(e,t);e||this.checkPropClash(s,i,t),n.properties.push(s)}return this.finishNode(n,e?"ObjectPattern":"ObjectExpression")};kt.parseProperty=function(e,t){var n=this.startNode(),r,i,s,o;if(this.options.ecmaVersion>=9&&this.eat(D.ellipsis))return e?(n.argument=this.parseIdent(!1),this.type===D.comma&&this.raiseRecoverable(this.start,"Comma is not permitted after the rest element"),this.finishNode(n,"RestElement")):(n.argument=this.parseMaybeAssign(!1,t),this.type===D.comma&&t&&t.trailingComma<0&&(t.trailingComma=this.start),this.finishNode(n,"SpreadElement"));this.options.ecmaVersion>=6&&(n.method=!1,n.shorthand=!1,(e||t)&&(s=this.start,o=this.startLoc),e||(r=this.eat(D.star)));var a=this.containsEsc;return this.parsePropertyName(n),!e&&!a&&this.options.ecmaVersion>=8&&!r&&this.isAsyncProp(n)?(i=!0,r=this.options.ecmaVersion>=9&&this.eat(D.star),this.parsePropertyName(n)):i=!1,this.parsePropertyValue(n,e,r,i,s,o,t,a),this.finishNode(n,"Property")};kt.parseGetterSetter=function(e){e.kind=e.key.name,this.parsePropertyName(e),e.value=this.parseMethod(!1);var t=e.kind==="get"?0:1;if(e.value.params.length!==t){var n=e.value.start;e.kind==="get"?this.raiseRecoverable(n,"getter should have no params"):this.raiseRecoverable(n,"setter should have exactly one param")}else e.kind==="set"&&e.value.params[0].type==="RestElement"&&this.raiseRecoverable(e.value.params[0].start,"Setter cannot use rest params")};kt.parsePropertyValue=function(e,t,n,r,i,s,o,a){(n||r)&&this.type===D.colon&&this.unexpected(),this.eat(D.colon)?(e.value=t?this.parseMaybeDefault(this.start,this.startLoc):this.parseMaybeAssign(!1,o),e.kind="init"):this.options.ecmaVersion>=6&&this.type===D.parenL?(t&&this.unexpected(),e.kind="init",e.method=!0,e.value=this.parseMethod(n,r)):!t&&!a&&this.options.ecmaVersion>=5&&!e.computed&&e.key.type==="Identifier"&&(e.key.name==="get"||e.key.name==="set")&&this.type!==D.comma&&this.type!==D.braceR&&this.type!==D.eq?((n||r)&&this.unexpected(),this.parseGetterSetter(e)):this.options.ecmaVersion>=6&&!e.computed&&e.key.type==="Identifier"?((n||r)&&this.unexpected(),this.checkUnreserved(e.key),e.key.name==="await"&&!this.awaitIdentPos&&(this.awaitIdentPos=i),e.kind="init",t?e.value=this.parseMaybeDefault(i,s,this.copyNode(e.key)):this.type===D.eq&&o?(o.shorthandAssign<0&&(o.shorthandAssign=this.start),e.value=this.parseMaybeDefault(i,s,this.copyNode(e.key))):e.value=this.copyNode(e.key),e.shorthand=!0):this.unexpected()};kt.parsePropertyName=function(e){if(this.options.ecmaVersion>=6){if(this.eat(D.bracketL))return e.computed=!0,e.key=this.parseMaybeAssign(),this.expect(D.bracketR),e.key;e.computed=!1}return e.key=this.type===D.num||this.type===D.string?this.parseExprAtom():this.parseIdent(this.options.allowReserved!=="never")};kt.initFunction=function(e){e.id=null,this.options.ecmaVersion>=6&&(e.generator=e.expression=!1),this.options.ecmaVersion>=8&&(e.async=!1)};kt.parseMethod=function(e,t,n){var r=this.startNode(),i=this.yieldPos,s=this.awaitPos,o=this.awaitIdentPos;return this.initFunction(r),this.options.ecmaVersion>=6&&(r.generator=e),this.options.ecmaVersion>=8&&(r.async=!!t),this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0,this.enterScope(ZL(t,r.generator)|XL|(n?rue:0)),this.expect(D.parenL),r.params=this.parseBindingList(D.parenR,!1,this.options.ecmaVersion>=8),this.checkYieldAwaitInDefaultParams(),this.parseFunctionBody(r,!1,!0,!1),this.yieldPos=i,this.awaitPos=s,this.awaitIdentPos=o,this.finishNode(r,"FunctionExpression")};kt.parseArrowExpression=function(e,t,n,r){var i=this.yieldPos,s=this.awaitPos,o=this.awaitIdentPos;return this.enterScope(ZL(n,!1)|tue),this.initFunction(e),this.options.ecmaVersion>=8&&(e.async=!!n),this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0,e.params=this.toAssignableList(t,!0),this.parseFunctionBody(e,!0,!1,r),this.yieldPos=i,this.awaitPos=s,this.awaitIdentPos=o,this.finishNode(e,"ArrowFunctionExpression")};kt.parseFunctionBody=function(e,t,n,r){var i=t&&this.type!==D.braceL,s=this.strict,o=!1;if(i)e.body=this.parseMaybeAssign(r),e.expression=!0,this.checkParams(e,!1);else{var a=this.options.ecmaVersion>=7&&!this.isSimpleParamList(e.params);(!s||a)&&(o=this.strictDirective(this.end),o&&a&&this.raiseRecoverable(e.start,"Illegal 'use strict' directive in function with non-simple parameter list"));var u=this.labels;this.labels=[],o&&(this.strict=!0),this.checkParams(e,!s&&!o&&!t&&!n&&this.isSimpleParamList(e.params)),this.strict&&e.id&&this.checkLValSimple(e.id,oue),e.body=this.parseBlock(!1,void 0,o&&!s),e.expression=!1,this.adaptDirectivePrologue(e.body.body),this.labels=u}this.exitScope()};kt.isSimpleParamList=function(e){for(var t=0,n=e;t-1||i.functions.indexOf(e)>-1||i.var.indexOf(e)>-1,i.lexical.push(e),this.inModule&&i.flags&Hv&&delete this.undefinedExports[e]}else if(t===sue){var s=this.currentScope();s.lexical.push(e)}else if(t===iue){var o=this.currentScope();this.treatFunctionsAsVar?r=o.lexical.indexOf(e)>-1:r=o.lexical.indexOf(e)>-1||o.var.indexOf(e)>-1,o.functions.push(e)}else for(var a=this.scopeStack.length-1;a>=0;--a){var u=this.scopeStack[a];if(u.lexical.indexOf(e)>-1&&!(u.flags&nue&&u.lexical[0]===e)||!this.treatFunctionsAsVarInScope(u)&&u.functions.indexOf(e)>-1){r=!0;break}if(u.var.push(e),this.inModule&&u.flags&Hv&&delete this.undefinedExports[e],u.flags&JL)break}r&&this.raiseRecoverable(n,"Identifier '"+e+"' has already been declared")};nd.checkLocalExport=function(e){this.scopeStack[0].lexical.indexOf(e.name)===-1&&this.scopeStack[0].var.indexOf(e.name)===-1&&(this.undefinedExports[e.name]=e)};nd.currentScope=function(){return this.scopeStack[this.scopeStack.length-1]};nd.currentVarScope=function(){for(var e=this.scopeStack.length-1;;e--){var t=this.scopeStack[e];if(t.flags&JL)return t}};nd.currentThisScope=function(){for(var e=this.scopeStack.length-1;;e--){var t=this.scopeStack[e];if(t.flags&JL&&!(t.flags&tue))return t}};var ZC=function(t,n,r){this.type="",this.start=n,this.end=0,t.options.locations&&(this.loc=new XC(t,r)),t.options.directSourceFile&&(this.sourceFile=t.options.directSourceFile),t.options.ranges&&(this.range=[n,0])},d1=oi.prototype;d1.startNode=function(){return new ZC(this,this.start,this.startLoc)};d1.startNodeAt=function(e,t){return new ZC(this,e,t)};function lue(e,t,n,r){return e.type=t,e.end=n,this.options.locations&&(e.loc.end=r),this.options.ranges&&(e.range[1]=n),e}d1.finishNode=function(e,t){return lue.call(this,e,t,this.lastTokEnd,this.lastTokEndLoc)};d1.finishNodeAt=function(e,t,n,r){return lue.call(this,e,t,n,r)};d1.copyNode=function(e){var t=new ZC(this,e.start,this.startLoc);for(var n in e)t[n]=e[n];return t};var cue="ASCII ASCII_Hex_Digit AHex Alphabetic Alpha Any Assigned Bidi_Control Bidi_C Bidi_Mirrored Bidi_M Case_Ignorable CI Cased Changes_When_Casefolded CWCF Changes_When_Casemapped CWCM Changes_When_Lowercased CWL Changes_When_NFKC_Casefolded CWKCF Changes_When_Titlecased CWT Changes_When_Uppercased CWU Dash Default_Ignorable_Code_Point DI Deprecated Dep Diacritic Dia Emoji Emoji_Component Emoji_Modifier Emoji_Modifier_Base Emoji_Presentation Extender Ext Grapheme_Base Gr_Base Grapheme_Extend Gr_Ext Hex_Digit Hex IDS_Binary_Operator IDSB IDS_Trinary_Operator IDST ID_Continue IDC ID_Start IDS Ideographic Ideo Join_Control Join_C Logical_Order_Exception LOE Lowercase Lower Math Noncharacter_Code_Point NChar Pattern_Syntax Pat_Syn Pattern_White_Space Pat_WS Quotation_Mark QMark Radical Regional_Indicator RI Sentence_Terminal STerm Soft_Dotted SD Terminal_Punctuation Term Unified_Ideograph UIdeo Uppercase Upper Variation_Selector VS White_Space space XID_Continue XIDC XID_Start XIDS",fue=cue+" Extended_Pictographic",due=fue,hue=due+" EBase EComp EMod EPres ExtPict",pue=hue,dQe=pue,hQe={9:cue,10:fue,11:due,12:hue,13:pue,14:dQe},pQe="Basic_Emoji Emoji_Keycap_Sequence RGI_Emoji_Modifier_Sequence RGI_Emoji_Flag_Sequence RGI_Emoji_Tag_Sequence RGI_Emoji_ZWJ_Sequence RGI_Emoji",mQe={9:"",10:"",11:"",12:"",13:"",14:pQe},Zz="Cased_Letter LC Close_Punctuation Pe Connector_Punctuation Pc Control Cc cntrl Currency_Symbol Sc Dash_Punctuation Pd Decimal_Number Nd digit Enclosing_Mark Me Final_Punctuation Pf Format Cf Initial_Punctuation Pi Letter L Letter_Number Nl Line_Separator Zl Lowercase_Letter Ll Mark M Combining_Mark Math_Symbol Sm Modifier_Letter Lm Modifier_Symbol Sk Nonspacing_Mark Mn Number N Open_Punctuation Ps Other C Other_Letter Lo Other_Number No Other_Punctuation Po Other_Symbol So Paragraph_Separator Zp Private_Use Co Punctuation P punct Separator Z Space_Separator Zs Spacing_Mark Mc Surrogate Cs Symbol S Titlecase_Letter Lt Unassigned Cn Uppercase_Letter Lu",mue="Adlam Adlm Ahom Anatolian_Hieroglyphs Hluw Arabic Arab Armenian Armn Avestan Avst Balinese Bali Bamum Bamu Bassa_Vah Bass Batak Batk Bengali Beng Bhaiksuki Bhks Bopomofo Bopo Brahmi Brah Braille Brai Buginese Bugi Buhid Buhd Canadian_Aboriginal Cans Carian Cari Caucasian_Albanian Aghb Chakma Cakm Cham Cham Cherokee Cher Common Zyyy Coptic Copt Qaac Cuneiform Xsux Cypriot Cprt Cyrillic Cyrl Deseret Dsrt Devanagari Deva Duployan Dupl Egyptian_Hieroglyphs Egyp Elbasan Elba Ethiopic Ethi Georgian Geor Glagolitic Glag Gothic Goth Grantha Gran Greek Grek Gujarati Gujr Gurmukhi Guru Han Hani Hangul Hang Hanunoo Hano Hatran Hatr Hebrew Hebr Hiragana Hira Imperial_Aramaic Armi Inherited Zinh Qaai Inscriptional_Pahlavi Phli Inscriptional_Parthian Prti Javanese Java Kaithi Kthi Kannada Knda Katakana Kana Kayah_Li Kali Kharoshthi Khar Khmer Khmr Khojki Khoj Khudawadi Sind Lao Laoo Latin Latn Lepcha Lepc Limbu Limb Linear_A Lina Linear_B Linb Lisu Lisu Lycian Lyci Lydian Lydi Mahajani Mahj Malayalam Mlym Mandaic Mand Manichaean Mani Marchen Marc Masaram_Gondi Gonm Meetei_Mayek Mtei Mende_Kikakui Mend Meroitic_Cursive Merc Meroitic_Hieroglyphs Mero Miao Plrd Modi Mongolian Mong Mro Mroo Multani Mult Myanmar Mymr Nabataean Nbat New_Tai_Lue Talu Newa Newa Nko Nkoo Nushu Nshu Ogham Ogam Ol_Chiki Olck Old_Hungarian Hung Old_Italic Ital Old_North_Arabian Narb Old_Permic Perm Old_Persian Xpeo Old_South_Arabian Sarb Old_Turkic Orkh Oriya Orya Osage Osge Osmanya Osma Pahawh_Hmong Hmng Palmyrene Palm Pau_Cin_Hau Pauc Phags_Pa Phag Phoenician Phnx Psalter_Pahlavi Phlp Rejang Rjng Runic Runr Samaritan Samr Saurashtra Saur Sharada Shrd Shavian Shaw Siddham Sidd SignWriting Sgnw Sinhala Sinh Sora_Sompeng Sora Soyombo Soyo Sundanese Sund Syloti_Nagri Sylo Syriac Syrc Tagalog Tglg Tagbanwa Tagb Tai_Le Tale Tai_Tham Lana Tai_Viet Tavt Takri Takr Tamil Taml Tangut Tang Telugu Telu Thaana Thaa Thai Thai Tibetan Tibt Tifinagh Tfng Tirhuta Tirh Ugaritic Ugar Vai Vaii Warang_Citi Wara Yi Yiii Zanabazar_Square Zanb",gue=mue+" Dogra Dogr Gunjala_Gondi Gong Hanifi_Rohingya Rohg Makasar Maka Medefaidrin Medf Old_Sogdian Sogo Sogdian Sogd",yue=gue+" Elymaic Elym Nandinagari Nand Nyiakeng_Puachue_Hmong Hmnp Wancho Wcho",vue=yue+" Chorasmian Chrs Diak Dives_Akuru Khitan_Small_Script Kits Yezi Yezidi",_ue=vue+" Cypro_Minoan Cpmn Old_Uyghur Ougr Tangsa Tnsa Toto Vithkuqi Vith",gQe=_ue+" Hrkt Katakana_Or_Hiragana Kawi Nag_Mundari Nagm Unknown Zzzz",yQe={9:mue,10:gue,11:yue,12:vue,13:_ue,14:gQe},bue={};function vQe(e){var t=bue[e]={binary:Xc(hQe[e]+" "+Zz),binaryOfStrings:Xc(mQe[e]),nonBinary:{General_Category:Xc(Zz),Script:Xc(yQe[e])}};t.nonBinary.Script_Extensions=t.nonBinary.Script,t.nonBinary.gc=t.nonBinary.General_Category,t.nonBinary.sc=t.nonBinary.Script,t.nonBinary.scx=t.nonBinary.Script_Extensions}for(var u2=0,eH=[9,10,11,12,13,14];u2=6?"uy":"")+(t.options.ecmaVersion>=9?"s":"")+(t.options.ecmaVersion>=13?"d":"")+(t.options.ecmaVersion>=15?"v":""),this.unicodeProperties=bue[t.options.ecmaVersion>=14?14:t.options.ecmaVersion],this.source="",this.flags="",this.start=0,this.switchU=!1,this.switchV=!1,this.switchN=!1,this.pos=0,this.lastIntValue=0,this.lastStringValue="",this.lastAssertionIsQuantifiable=!1,this.numCapturingParens=0,this.maxBackReference=0,this.groupNames=[],this.backReferenceNames=[]};ml.prototype.reset=function(t,n,r){var i=r.indexOf("v")!==-1,s=r.indexOf("u")!==-1;this.start=t|0,this.source=n+"",this.flags=r,i&&this.parser.options.ecmaVersion>=15?(this.switchU=!0,this.switchV=!0,this.switchN=!0):(this.switchU=s&&this.parser.options.ecmaVersion>=6,this.switchV=!1,this.switchN=s&&this.parser.options.ecmaVersion>=9)};ml.prototype.raise=function(t){this.parser.raiseRecoverable(this.start,"Invalid regular expression: /"+this.source+"/: "+t)};ml.prototype.at=function(t,n){n===void 0&&(n=!1);var r=this.source,i=r.length;if(t>=i)return-1;var s=r.charCodeAt(t);if(!(n||this.switchU)||s<=55295||s>=57344||t+1>=i)return s;var o=r.charCodeAt(t+1);return o>=56320&&o<=57343?(s<<10)+o-56613888:s};ml.prototype.nextIndex=function(t,n){n===void 0&&(n=!1);var r=this.source,i=r.length;if(t>=i)return i;var s=r.charCodeAt(t),o;return!(n||this.switchU)||s<=55295||s>=57344||t+1>=i||(o=r.charCodeAt(t+1))<56320||o>57343?t+1:t+2};ml.prototype.current=function(t){return t===void 0&&(t=!1),this.at(this.pos,t)};ml.prototype.lookahead=function(t){return t===void 0&&(t=!1),this.at(this.nextIndex(this.pos,t),t)};ml.prototype.advance=function(t){t===void 0&&(t=!1),this.pos=this.nextIndex(this.pos,t)};ml.prototype.eat=function(t,n){return n===void 0&&(n=!1),this.current(n)===t?(this.advance(n),!0):!1};ml.prototype.eatChars=function(t,n){n===void 0&&(n=!1);for(var r=this.pos,i=0,s=t;i-1&&this.raise(e.start,"Duplicate regular expression flag"),o==="u"&&(r=!0),o==="v"&&(i=!0)}this.options.ecmaVersion>=15&&r&&i&&this.raise(e.start,"Invalid regular expression flag")};Xe.validateRegExpPattern=function(e){this.regexp_pattern(e),!e.switchN&&this.options.ecmaVersion>=9&&e.groupNames.length>0&&(e.switchN=!0,this.regexp_pattern(e))};Xe.regexp_pattern=function(e){e.pos=0,e.lastIntValue=0,e.lastStringValue="",e.lastAssertionIsQuantifiable=!1,e.numCapturingParens=0,e.maxBackReference=0,e.groupNames.length=0,e.backReferenceNames.length=0,this.regexp_disjunction(e),e.pos!==e.source.length&&(e.eat(41)&&e.raise("Unmatched ')'"),(e.eat(93)||e.eat(125))&&e.raise("Lone quantifier brackets")),e.maxBackReference>e.numCapturingParens&&e.raise("Invalid escape");for(var t=0,n=e.backReferenceNames;t=9&&(n=e.eat(60)),e.eat(61)||e.eat(33))return this.regexp_disjunction(e),e.eat(41)||e.raise("Unterminated group"),e.lastAssertionIsQuantifiable=!n,!0}return e.pos=t,!1};Xe.regexp_eatQuantifier=function(e,t){return t===void 0&&(t=!1),this.regexp_eatQuantifierPrefix(e,t)?(e.eat(63),!0):!1};Xe.regexp_eatQuantifierPrefix=function(e,t){return e.eat(42)||e.eat(43)||e.eat(63)||this.regexp_eatBracedQuantifier(e,t)};Xe.regexp_eatBracedQuantifier=function(e,t){var n=e.pos;if(e.eat(123)){var r=0,i=-1;if(this.regexp_eatDecimalDigits(e)&&(r=e.lastIntValue,e.eat(44)&&this.regexp_eatDecimalDigits(e)&&(i=e.lastIntValue),e.eat(125)))return i!==-1&&i=9?this.regexp_groupSpecifier(e):e.current()===63&&e.raise("Invalid group"),this.regexp_disjunction(e),e.eat(41))return e.numCapturingParens+=1,!0;e.raise("Unterminated group")}return!1};Xe.regexp_eatExtendedAtom=function(e){return e.eat(46)||this.regexp_eatReverseSolidusAtomEscape(e)||this.regexp_eatCharacterClass(e)||this.regexp_eatUncapturingGroup(e)||this.regexp_eatCapturingGroup(e)||this.regexp_eatInvalidBracedQuantifier(e)||this.regexp_eatExtendedPatternCharacter(e)};Xe.regexp_eatInvalidBracedQuantifier=function(e){return this.regexp_eatBracedQuantifier(e,!0)&&e.raise("Nothing to repeat"),!1};Xe.regexp_eatSyntaxCharacter=function(e){var t=e.current();return wue(t)?(e.lastIntValue=t,e.advance(),!0):!1};function wue(e){return e===36||e>=40&&e<=43||e===46||e===63||e>=91&&e<=94||e>=123&&e<=125}Xe.regexp_eatPatternCharacters=function(e){for(var t=e.pos,n=0;(n=e.current())!==-1&&!wue(n);)e.advance();return e.pos!==t};Xe.regexp_eatExtendedPatternCharacter=function(e){var t=e.current();return t!==-1&&t!==36&&!(t>=40&&t<=43)&&t!==46&&t!==63&&t!==91&&t!==94&&t!==124?(e.advance(),!0):!1};Xe.regexp_groupSpecifier=function(e){if(e.eat(63)){if(this.regexp_eatGroupName(e)){e.groupNames.indexOf(e.lastStringValue)!==-1&&e.raise("Duplicate capture group name"),e.groupNames.push(e.lastStringValue);return}e.raise("Invalid group")}};Xe.regexp_eatGroupName=function(e){if(e.lastStringValue="",e.eat(60)){if(this.regexp_eatRegExpIdentifierName(e)&&e.eat(62))return!0;e.raise("Invalid capture group name")}return!1};Xe.regexp_eatRegExpIdentifierName=function(e){if(e.lastStringValue="",this.regexp_eatRegExpIdentifierStart(e)){for(e.lastStringValue+=jf(e.lastIntValue);this.regexp_eatRegExpIdentifierPart(e);)e.lastStringValue+=jf(e.lastIntValue);return!0}return!1};Xe.regexp_eatRegExpIdentifierStart=function(e){var t=e.pos,n=this.options.ecmaVersion>=11,r=e.current(n);return e.advance(n),r===92&&this.regexp_eatRegExpUnicodeEscapeSequence(e,n)&&(r=e.lastIntValue),bQe(r)?(e.lastIntValue=r,!0):(e.pos=t,!1)};function bQe(e){return tc(e,!0)||e===36||e===95}Xe.regexp_eatRegExpIdentifierPart=function(e){var t=e.pos,n=this.options.ecmaVersion>=11,r=e.current(n);return e.advance(n),r===92&&this.regexp_eatRegExpUnicodeEscapeSequence(e,n)&&(r=e.lastIntValue),wQe(r)?(e.lastIntValue=r,!0):(e.pos=t,!1)};function wQe(e){return ig(e,!0)||e===36||e===95||e===8204||e===8205}Xe.regexp_eatAtomEscape=function(e){return this.regexp_eatBackReference(e)||this.regexp_eatCharacterClassEscape(e)||this.regexp_eatCharacterEscape(e)||e.switchN&&this.regexp_eatKGroupName(e)?!0:(e.switchU&&(e.current()===99&&e.raise("Invalid unicode escape"),e.raise("Invalid escape")),!1)};Xe.regexp_eatBackReference=function(e){var t=e.pos;if(this.regexp_eatDecimalEscape(e)){var n=e.lastIntValue;if(e.switchU)return n>e.maxBackReference&&(e.maxBackReference=n),!0;if(n<=e.numCapturingParens)return!0;e.pos=t}return!1};Xe.regexp_eatKGroupName=function(e){if(e.eat(107)){if(this.regexp_eatGroupName(e))return e.backReferenceNames.push(e.lastStringValue),!0;e.raise("Invalid named reference")}return!1};Xe.regexp_eatCharacterEscape=function(e){return this.regexp_eatControlEscape(e)||this.regexp_eatCControlLetter(e)||this.regexp_eatZero(e)||this.regexp_eatHexEscapeSequence(e)||this.regexp_eatRegExpUnicodeEscapeSequence(e,!1)||!e.switchU&&this.regexp_eatLegacyOctalEscapeSequence(e)||this.regexp_eatIdentityEscape(e)};Xe.regexp_eatCControlLetter=function(e){var t=e.pos;if(e.eat(99)){if(this.regexp_eatControlLetter(e))return!0;e.pos=t}return!1};Xe.regexp_eatZero=function(e){return e.current()===48&&!eA(e.lookahead())?(e.lastIntValue=0,e.advance(),!0):!1};Xe.regexp_eatControlEscape=function(e){var t=e.current();return t===116?(e.lastIntValue=9,e.advance(),!0):t===110?(e.lastIntValue=10,e.advance(),!0):t===118?(e.lastIntValue=11,e.advance(),!0):t===102?(e.lastIntValue=12,e.advance(),!0):t===114?(e.lastIntValue=13,e.advance(),!0):!1};Xe.regexp_eatControlLetter=function(e){var t=e.current();return Eue(t)?(e.lastIntValue=t%32,e.advance(),!0):!1};function Eue(e){return e>=65&&e<=90||e>=97&&e<=122}Xe.regexp_eatRegExpUnicodeEscapeSequence=function(e,t){t===void 0&&(t=!1);var n=e.pos,r=t||e.switchU;if(e.eat(117)){if(this.regexp_eatFixedHexDigits(e,4)){var i=e.lastIntValue;if(r&&i>=55296&&i<=56319){var s=e.pos;if(e.eat(92)&&e.eat(117)&&this.regexp_eatFixedHexDigits(e,4)){var o=e.lastIntValue;if(o>=56320&&o<=57343)return e.lastIntValue=(i-55296)*1024+(o-56320)+65536,!0}e.pos=s,e.lastIntValue=i}return!0}if(r&&e.eat(123)&&this.regexp_eatHexDigits(e)&&e.eat(125)&&EQe(e.lastIntValue))return!0;r&&e.raise("Invalid unicode escape"),e.pos=n}return!1};function EQe(e){return e>=0&&e<=1114111}Xe.regexp_eatIdentityEscape=function(e){if(e.switchU)return this.regexp_eatSyntaxCharacter(e)?!0:e.eat(47)?(e.lastIntValue=47,!0):!1;var t=e.current();return t!==99&&(!e.switchN||t!==107)?(e.lastIntValue=t,e.advance(),!0):!1};Xe.regexp_eatDecimalEscape=function(e){e.lastIntValue=0;var t=e.current();if(t>=49&&t<=57){do e.lastIntValue=10*e.lastIntValue+(t-48),e.advance();while((t=e.current())>=48&&t<=57);return!0}return!1};var Sue=0,nc=1,Qo=2;Xe.regexp_eatCharacterClassEscape=function(e){var t=e.current();if(SQe(t))return e.lastIntValue=-1,e.advance(),nc;var n=!1;if(e.switchU&&this.options.ecmaVersion>=9&&((n=t===80)||t===112)){e.lastIntValue=-1,e.advance();var r;if(e.eat(123)&&(r=this.regexp_eatUnicodePropertyValueExpression(e))&&e.eat(125))return n&&r===Qo&&e.raise("Invalid property name"),r;e.raise("Invalid property name")}return Sue};function SQe(e){return e===100||e===68||e===115||e===83||e===119||e===87}Xe.regexp_eatUnicodePropertyValueExpression=function(e){var t=e.pos;if(this.regexp_eatUnicodePropertyName(e)&&e.eat(61)){var n=e.lastStringValue;if(this.regexp_eatUnicodePropertyValue(e)){var r=e.lastStringValue;return this.regexp_validateUnicodePropertyNameAndValue(e,n,r),nc}}if(e.pos=t,this.regexp_eatLoneUnicodePropertyNameOrValue(e)){var i=e.lastStringValue;return this.regexp_validateUnicodePropertyNameOrValue(e,i)}return Sue};Xe.regexp_validateUnicodePropertyNameAndValue=function(e,t,n){c1(e.unicodeProperties.nonBinary,t)||e.raise("Invalid property name"),e.unicodeProperties.nonBinary[t].test(n)||e.raise("Invalid property value")};Xe.regexp_validateUnicodePropertyNameOrValue=function(e,t){if(e.unicodeProperties.binary.test(t))return nc;if(e.switchV&&e.unicodeProperties.binaryOfStrings.test(t))return Qo;e.raise("Invalid property name")};Xe.regexp_eatUnicodePropertyName=function(e){var t=0;for(e.lastStringValue="";Tue(t=e.current());)e.lastStringValue+=jf(t),e.advance();return e.lastStringValue!==""};function Tue(e){return Eue(e)||e===95}Xe.regexp_eatUnicodePropertyValue=function(e){var t=0;for(e.lastStringValue="";TQe(t=e.current());)e.lastStringValue+=jf(t),e.advance();return e.lastStringValue!==""};function TQe(e){return Tue(e)||eA(e)}Xe.regexp_eatLoneUnicodePropertyNameOrValue=function(e){return this.regexp_eatUnicodePropertyValue(e)};Xe.regexp_eatCharacterClass=function(e){if(e.eat(91)){var t=e.eat(94),n=this.regexp_classContents(e);return e.eat(93)||e.raise("Unterminated character class"),t&&n===Qo&&e.raise("Negated character class may contain strings"),!0}return!1};Xe.regexp_classContents=function(e){return e.current()===93?nc:e.switchV?this.regexp_classSetExpression(e):(this.regexp_nonEmptyClassRanges(e),nc)};Xe.regexp_nonEmptyClassRanges=function(e){for(;this.regexp_eatClassAtom(e);){var t=e.lastIntValue;if(e.eat(45)&&this.regexp_eatClassAtom(e)){var n=e.lastIntValue;e.switchU&&(t===-1||n===-1)&&e.raise("Invalid character class"),t!==-1&&n!==-1&&t>n&&e.raise("Range out of order in character class")}}};Xe.regexp_eatClassAtom=function(e){var t=e.pos;if(e.eat(92)){if(this.regexp_eatClassEscape(e))return!0;if(e.switchU){var n=e.current();(n===99||Cue(n))&&e.raise("Invalid class escape"),e.raise("Invalid escape")}e.pos=t}var r=e.current();return r!==93?(e.lastIntValue=r,e.advance(),!0):!1};Xe.regexp_eatClassEscape=function(e){var t=e.pos;if(e.eat(98))return e.lastIntValue=8,!0;if(e.switchU&&e.eat(45))return e.lastIntValue=45,!0;if(!e.switchU&&e.eat(99)){if(this.regexp_eatClassControlLetter(e))return!0;e.pos=t}return this.regexp_eatCharacterClassEscape(e)||this.regexp_eatCharacterEscape(e)};Xe.regexp_classSetExpression=function(e){var t=nc,n;if(!this.regexp_eatClassSetRange(e))if(n=this.regexp_eatClassSetOperand(e)){n===Qo&&(t=Qo);for(var r=e.pos;e.eatChars([38,38]);){if(e.current()!==38&&(n=this.regexp_eatClassSetOperand(e))){n!==Qo&&(t=nc);continue}e.raise("Invalid character in character class")}if(r!==e.pos)return t;for(;e.eatChars([45,45]);)this.regexp_eatClassSetOperand(e)||e.raise("Invalid character in character class");if(r!==e.pos)return t}else e.raise("Invalid character in character class");for(;;)if(!this.regexp_eatClassSetRange(e)){if(n=this.regexp_eatClassSetOperand(e),!n)return t;n===Qo&&(t=Qo)}};Xe.regexp_eatClassSetRange=function(e){var t=e.pos;if(this.regexp_eatClassSetCharacter(e)){var n=e.lastIntValue;if(e.eat(45)&&this.regexp_eatClassSetCharacter(e)){var r=e.lastIntValue;return n!==-1&&r!==-1&&n>r&&e.raise("Range out of order in character class"),!0}e.pos=t}return!1};Xe.regexp_eatClassSetOperand=function(e){return this.regexp_eatClassSetCharacter(e)?nc:this.regexp_eatClassStringDisjunction(e)||this.regexp_eatNestedClass(e)};Xe.regexp_eatNestedClass=function(e){var t=e.pos;if(e.eat(91)){var n=e.eat(94),r=this.regexp_classContents(e);if(e.eat(93))return n&&r===Qo&&e.raise("Negated character class may contain strings"),r;e.pos=t}if(e.eat(92)){var i=this.regexp_eatCharacterClassEscape(e);if(i)return i;e.pos=t}return null};Xe.regexp_eatClassStringDisjunction=function(e){var t=e.pos;if(e.eatChars([92,113])){if(e.eat(123)){var n=this.regexp_classStringDisjunctionContents(e);if(e.eat(125))return n}else e.raise("Invalid escape");e.pos=t}return null};Xe.regexp_classStringDisjunctionContents=function(e){for(var t=this.regexp_classString(e);e.eat(124);)this.regexp_classString(e)===Qo&&(t=Qo);return t};Xe.regexp_classString=function(e){for(var t=0;this.regexp_eatClassSetCharacter(e);)t++;return t===1?nc:Qo};Xe.regexp_eatClassSetCharacter=function(e){var t=e.pos;if(e.eat(92))return this.regexp_eatCharacterEscape(e)||this.regexp_eatClassSetReservedPunctuator(e)?!0:e.eat(98)?(e.lastIntValue=8,!0):(e.pos=t,!1);var n=e.current();return n<0||n===e.lookahead()&&IQe(n)||xQe(n)?!1:(e.advance(),e.lastIntValue=n,!0)};function IQe(e){return e===33||e>=35&&e<=38||e>=42&&e<=44||e===46||e>=58&&e<=64||e===94||e===96||e===126}function xQe(e){return e===40||e===41||e===45||e===47||e>=91&&e<=93||e>=123&&e<=125}Xe.regexp_eatClassSetReservedPunctuator=function(e){var t=e.current();return CQe(t)?(e.lastIntValue=t,e.advance(),!0):!1};function CQe(e){return e===33||e===35||e===37||e===38||e===44||e===45||e>=58&&e<=62||e===64||e===96||e===126}Xe.regexp_eatClassControlLetter=function(e){var t=e.current();return eA(t)||t===95?(e.lastIntValue=t%32,e.advance(),!0):!1};Xe.regexp_eatHexEscapeSequence=function(e){var t=e.pos;if(e.eat(120)){if(this.regexp_eatFixedHexDigits(e,2))return!0;e.switchU&&e.raise("Invalid escape"),e.pos=t}return!1};Xe.regexp_eatDecimalDigits=function(e){var t=e.pos,n=0;for(e.lastIntValue=0;eA(n=e.current());)e.lastIntValue=10*e.lastIntValue+(n-48),e.advance();return e.pos!==t};function eA(e){return e>=48&&e<=57}Xe.regexp_eatHexDigits=function(e){var t=e.pos,n=0;for(e.lastIntValue=0;Iue(n=e.current());)e.lastIntValue=16*e.lastIntValue+xue(n),e.advance();return e.pos!==t};function Iue(e){return e>=48&&e<=57||e>=65&&e<=70||e>=97&&e<=102}function xue(e){return e>=65&&e<=70?10+(e-65):e>=97&&e<=102?10+(e-97):e-48}Xe.regexp_eatLegacyOctalEscapeSequence=function(e){if(this.regexp_eatOctalDigit(e)){var t=e.lastIntValue;if(this.regexp_eatOctalDigit(e)){var n=e.lastIntValue;t<=3&&this.regexp_eatOctalDigit(e)?e.lastIntValue=t*64+n*8+e.lastIntValue:e.lastIntValue=t*8+n}else e.lastIntValue=t;return!0}return!1};Xe.regexp_eatOctalDigit=function(e){var t=e.current();return Cue(t)?(e.lastIntValue=t-48,e.advance(),!0):(e.lastIntValue=0,!1)};function Cue(e){return e>=48&&e<=55}Xe.regexp_eatFixedHexDigits=function(e,t){var n=e.pos;e.lastIntValue=0;for(var r=0;r=this.input.length)return this.finishToken(D.eof);if(e.override)return e.override(this);this.readToken(this.fullCharCodeAtPos())};rn.readToken=function(e){return tc(e,this.options.ecmaVersion>=6)||e===92?this.readWord():this.getTokenFromCode(e)};rn.fullCharCodeAtPos=function(){var e=this.input.charCodeAt(this.pos);if(e<=55295||e>=56320)return e;var t=this.input.charCodeAt(this.pos+1);return t<=56319||t>=57344?e:(e<<10)+t-56613888};rn.skipBlockComment=function(){var e=this.options.onComment&&this.curPosition(),t=this.pos,n=this.input.indexOf("*/",this.pos+=2);if(n===-1&&this.raise(this.pos-2,"Unterminated comment"),this.pos=n+2,this.options.locations)for(var r=void 0,i=t;(r=Qae(this.input,i,this.pos))>-1;)++this.curLine,i=this.lineStart=r;this.options.onComment&&this.options.onComment(!0,this.input.slice(t+2,n),t,this.pos,e,this.curPosition())};rn.skipLineComment=function(e){for(var t=this.pos,n=this.options.onComment&&this.curPosition(),r=this.input.charCodeAt(this.pos+=e);this.pos8&&e<14||e>=5760&&Xae.test(String.fromCharCode(e)))++this.pos;else break e}}};rn.finishToken=function(e,t){this.end=this.pos,this.options.locations&&(this.endLoc=this.curPosition());var n=this.type;this.type=e,this.value=t,this.updateContext(n)};rn.readToken_dot=function(){var e=this.input.charCodeAt(this.pos+1);if(e>=48&&e<=57)return this.readNumber(!0);var t=this.input.charCodeAt(this.pos+2);return this.options.ecmaVersion>=6&&e===46&&t===46?(this.pos+=3,this.finishToken(D.ellipsis)):(++this.pos,this.finishToken(D.dot))};rn.readToken_slash=function(){var e=this.input.charCodeAt(this.pos+1);return this.exprAllowed?(++this.pos,this.readRegexp()):e===61?this.finishOp(D.assign,2):this.finishOp(D.slash,1)};rn.readToken_mult_modulo_exp=function(e){var t=this.input.charCodeAt(this.pos+1),n=1,r=e===42?D.star:D.modulo;return this.options.ecmaVersion>=7&&e===42&&t===42&&(++n,r=D.starstar,t=this.input.charCodeAt(this.pos+2)),t===61?this.finishOp(D.assign,n+1):this.finishOp(r,n)};rn.readToken_pipe_amp=function(e){var t=this.input.charCodeAt(this.pos+1);if(t===e){if(this.options.ecmaVersion>=12){var n=this.input.charCodeAt(this.pos+2);if(n===61)return this.finishOp(D.assign,3)}return this.finishOp(e===124?D.logicalOR:D.logicalAND,2)}return t===61?this.finishOp(D.assign,2):this.finishOp(e===124?D.bitwiseOR:D.bitwiseAND,1)};rn.readToken_caret=function(){var e=this.input.charCodeAt(this.pos+1);return e===61?this.finishOp(D.assign,2):this.finishOp(D.bitwiseXOR,1)};rn.readToken_plus_min=function(e){var t=this.input.charCodeAt(this.pos+1);return t===e?t===45&&!this.inModule&&this.input.charCodeAt(this.pos+2)===62&&(this.lastTokEnd===0||va.test(this.input.slice(this.lastTokEnd,this.pos)))?(this.skipLineComment(3),this.skipSpace(),this.nextToken()):this.finishOp(D.incDec,2):t===61?this.finishOp(D.assign,2):this.finishOp(D.plusMin,1)};rn.readToken_lt_gt=function(e){var t=this.input.charCodeAt(this.pos+1),n=1;return t===e?(n=e===62&&this.input.charCodeAt(this.pos+2)===62?3:2,this.input.charCodeAt(this.pos+n)===61?this.finishOp(D.assign,n+1):this.finishOp(D.bitShift,n)):t===33&&e===60&&!this.inModule&&this.input.charCodeAt(this.pos+2)===45&&this.input.charCodeAt(this.pos+3)===45?(this.skipLineComment(4),this.skipSpace(),this.nextToken()):(t===61&&(n=2),this.finishOp(D.relational,n))};rn.readToken_eq_excl=function(e){var t=this.input.charCodeAt(this.pos+1);return t===61?this.finishOp(D.equality,this.input.charCodeAt(this.pos+2)===61?3:2):e===61&&t===62&&this.options.ecmaVersion>=6?(this.pos+=2,this.finishToken(D.arrow)):this.finishOp(e===61?D.eq:D.prefix,1)};rn.readToken_question=function(){var e=this.options.ecmaVersion;if(e>=11){var t=this.input.charCodeAt(this.pos+1);if(t===46){var n=this.input.charCodeAt(this.pos+2);if(n<48||n>57)return this.finishOp(D.questionDot,2)}if(t===63){if(e>=12){var r=this.input.charCodeAt(this.pos+2);if(r===61)return this.finishOp(D.assign,3)}return this.finishOp(D.coalesce,2)}}return this.finishOp(D.question,1)};rn.readToken_numberSign=function(){var e=this.options.ecmaVersion,t=35;if(e>=13&&(++this.pos,t=this.fullCharCodeAtPos(),tc(t,!0)||t===92))return this.finishToken(D.privateId,this.readWord1());this.raise(this.pos,"Unexpected character '"+jf(t)+"'")};rn.getTokenFromCode=function(e){switch(e){case 46:return this.readToken_dot();case 40:return++this.pos,this.finishToken(D.parenL);case 41:return++this.pos,this.finishToken(D.parenR);case 59:return++this.pos,this.finishToken(D.semi);case 44:return++this.pos,this.finishToken(D.comma);case 91:return++this.pos,this.finishToken(D.bracketL);case 93:return++this.pos,this.finishToken(D.bracketR);case 123:return++this.pos,this.finishToken(D.braceL);case 125:return++this.pos,this.finishToken(D.braceR);case 58:return++this.pos,this.finishToken(D.colon);case 96:if(this.options.ecmaVersion<6)break;return++this.pos,this.finishToken(D.backQuote);case 48:var t=this.input.charCodeAt(this.pos+1);if(t===120||t===88)return this.readRadixNumber(16);if(this.options.ecmaVersion>=6){if(t===111||t===79)return this.readRadixNumber(8);if(t===98||t===66)return this.readRadixNumber(2)}case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:return this.readNumber(!1);case 34:case 39:return this.readString(e);case 47:return this.readToken_slash();case 37:case 42:return this.readToken_mult_modulo_exp(e);case 124:case 38:return this.readToken_pipe_amp(e);case 94:return this.readToken_caret();case 43:case 45:return this.readToken_plus_min(e);case 60:case 62:return this.readToken_lt_gt(e);case 61:case 33:return this.readToken_eq_excl(e);case 63:return this.readToken_question();case 126:return this.finishOp(D.prefix,1);case 35:return this.readToken_numberSign()}this.raise(this.pos,"Unexpected character '"+jf(e)+"'")};rn.finishOp=function(e,t){var n=this.input.slice(this.pos,this.pos+t);return this.pos+=t,this.finishToken(e,n)};rn.readRegexp=function(){for(var e,t,n=this.pos;;){this.pos>=this.input.length&&this.raise(n,"Unterminated regular expression");var r=this.input.charAt(this.pos);if(va.test(r)&&this.raise(n,"Unterminated regular expression"),e)e=!1;else{if(r==="[")t=!0;else if(r==="]"&&t)t=!1;else if(r==="/"&&!t)break;e=r==="\\"}++this.pos}var i=this.input.slice(n,this.pos);++this.pos;var s=this.pos,o=this.readWord1();this.containsEsc&&this.unexpected(s);var a=this.regexpState||(this.regexpState=new ml(this));a.reset(n,i,o),this.validateRegExpFlags(a),this.validateRegExpPattern(a);var u=null;try{u=new RegExp(i,o)}catch{}return this.finishToken(D.regexp,{pattern:i,flags:o,value:u})};rn.readInt=function(e,t,n){for(var r=this.options.ecmaVersion>=12&&t===void 0,i=n&&this.input.charCodeAt(this.pos)===48,s=this.pos,o=0,a=0,u=0,l=t??1/0;u=97?f=c-97+10:c>=65?f=c-65+10:c>=48&&c<=57?f=c-48:f=1/0,f>=e)break;a=c,o=o*e+f}return r&&a===95&&this.raiseRecoverable(this.pos-1,"Numeric separator is not allowed at the last of digits"),this.pos===s||t!=null&&this.pos-s!==t?null:o};function AQe(e,t){return t?parseInt(e,8):parseFloat(e.replace(/_/g,""))}function Aue(e){return typeof BigInt!="function"?null:BigInt(e.replace(/_/g,""))}rn.readRadixNumber=function(e){var t=this.pos;this.pos+=2;var n=this.readInt(e);return n==null&&this.raise(this.start+2,"Expected number in radix "+e),this.options.ecmaVersion>=11&&this.input.charCodeAt(this.pos)===110?(n=Aue(this.input.slice(t,this.pos)),++this.pos):tc(this.fullCharCodeAtPos())&&this.raise(this.pos,"Identifier directly after number"),this.finishToken(D.num,n)};rn.readNumber=function(e){var t=this.pos;!e&&this.readInt(10,void 0,!0)===null&&this.raise(t,"Invalid number");var n=this.pos-t>=2&&this.input.charCodeAt(t)===48;n&&this.strict&&this.raise(t,"Invalid number");var r=this.input.charCodeAt(this.pos);if(!n&&!e&&this.options.ecmaVersion>=11&&r===110){var i=Aue(this.input.slice(t,this.pos));return++this.pos,tc(this.fullCharCodeAtPos())&&this.raise(this.pos,"Identifier directly after number"),this.finishToken(D.num,i)}n&&/[89]/.test(this.input.slice(t,this.pos))&&(n=!1),r===46&&!n&&(++this.pos,this.readInt(10),r=this.input.charCodeAt(this.pos)),(r===69||r===101)&&!n&&(r=this.input.charCodeAt(++this.pos),(r===43||r===45)&&++this.pos,this.readInt(10)===null&&this.raise(t,"Invalid number")),tc(this.fullCharCodeAtPos())&&this.raise(this.pos,"Identifier directly after number");var s=AQe(this.input.slice(t,this.pos),n);return this.finishToken(D.num,s)};rn.readCodePoint=function(){var e=this.input.charCodeAt(this.pos),t;if(e===123){this.options.ecmaVersion<6&&this.unexpected();var n=++this.pos;t=this.readHexChar(this.input.indexOf("}",this.pos)-this.pos),++this.pos,t>1114111&&this.invalidStringToken(n,"Code point out of bounds")}else t=this.readHexChar(4);return t};rn.readString=function(e){for(var t="",n=++this.pos;;){this.pos>=this.input.length&&this.raise(this.start,"Unterminated string constant");var r=this.input.charCodeAt(this.pos);if(r===e)break;r===92?(t+=this.input.slice(n,this.pos),t+=this.readEscapedChar(!1),n=this.pos):r===8232||r===8233?(this.options.ecmaVersion<10&&this.raise(this.start,"Unterminated string constant"),++this.pos,this.options.locations&&(this.curLine++,this.lineStart=this.pos)):(Fg(r)&&this.raise(this.start,"Unterminated string constant"),++this.pos)}return t+=this.input.slice(n,this.pos++),this.finishToken(D.string,t)};var Pue={};rn.tryReadTemplateToken=function(){this.inTemplateElement=!0;try{this.readTmplToken()}catch(e){if(e===Pue)this.readInvalidTemplateToken();else throw e}this.inTemplateElement=!1};rn.invalidStringToken=function(e,t){if(this.inTemplateElement&&this.options.ecmaVersion>=9)throw Pue;this.raise(e,t)};rn.readTmplToken=function(){for(var e="",t=this.pos;;){this.pos>=this.input.length&&this.raise(this.start,"Unterminated template");var n=this.input.charCodeAt(this.pos);if(n===96||n===36&&this.input.charCodeAt(this.pos+1)===123)return this.pos===this.start&&(this.type===D.template||this.type===D.invalidTemplate)?n===36?(this.pos+=2,this.finishToken(D.dollarBraceL)):(++this.pos,this.finishToken(D.backQuote)):(e+=this.input.slice(t,this.pos),this.finishToken(D.template,e));if(n===92)e+=this.input.slice(t,this.pos),e+=this.readEscapedChar(!0),t=this.pos;else if(Fg(n)){switch(e+=this.input.slice(t,this.pos),++this.pos,n){case 13:this.input.charCodeAt(this.pos)===10&&++this.pos;case 10:e+=` +`}function Hae(e,t){for(const[n,r]of MC(t))e.set(n,r);return e}function FKe(e){return e.replace(/[.*+\-?^${}()|[\]\\]/g,"\\$&")}function ec(e,t,n=new Map){return t=bs(t)?e.columnName(t):t,Ui(t)?n.set(t,t):En(t)?t.forEach(r=>ec(e,r,n)):sr(t)?ec(e,t(e),n):as(t)?Hae(n,t):Wt(`Invalid column selection: ${el(t)}`),n}function QC(e,t){return e.toObject=t,e}function Wae(e){return En(e)?e.map(Wae):e&&e.toObject?e.toObject():e}function rg(){return QC(e=>e.columnNames(),()=>({all:[]}))}function qae(...e){return e=e.flat(),QC(t=>{const n=ec(t,e);return t.columnNames(r=>!n.has(r))},()=>({not:Wae(e)}))}function BKe(e,t){return QC(n=>{let r=bs(e)?e:n.columnIndex(e),i=bs(t)?t:n.columnIndex(t);if(i({range:[e,t]}))}function jKe(e){return Ui(e)&&(e=RegExp(FKe(e))),QC(t=>t.columnNames(n=>e.test(n)),()=>({matches:[e.source,e.flags]}))}function UKe(e){return r1(e.data)?e.data.constructor:Array}class Al extends iWe{static from(t,n){return new Al(aWe(t,n),n)}static new(t,n){if(t instanceof Al)return t;const r={},i=[];for(const[s,o]of MC(t))r[s]=o,i.push(s);return new Al(r,n||i)}constructor(t,n,r,i,s,o){KC(t,oWe,t),n=n||Object.keys(t);const a=n.length?t[n[0]].length:0;super(n,a,t,r,i,s,o)}create({data:t,names:n,filter:r,groups:i,order:s}){const o=r!==void 0?r:this.mask();return new Al(t||this._data,n||(t?null:this._names),o,i!==void 0?i:LWe(this._group,r&&o),s!==void 0?s:this._order,this._params)}assign(...t){const n=this.numRows(),r=this.reify(),i=Mo(r).groupby(r.groups());return t.forEach(s=>{s=Al.new(s),s.numRows()!==n&&Wt("Assign row counts do not match"),s=s.reify(),s.columnNames(o=>i.add(o,s.column(o)))}),this.create(i.new())}columns(){return this._data}column(t){return this._data[t]}columnAt(t){return this._data[this._names[t]]}array(t,n=Array){const r=this.column(t),i=new n(this.numRows());let s=-1;return this.scan(o=>i[++s]=r.get(o),!0),i}get(t,n=0){const r=this.column(t);return this.isFiltered()||this.isOrdered()?r.get(this.indices()[n]):r.get(n)}getter(t){const n=this.column(t),r=this.isFiltered()||this.isOrdered()?this.indices():null;return r?i=>n.get(r[i]):n?i=>n.get(i):Wt(`Unrecognized column: ${t}`)}object(t=0){return qz(this)(t)}objects(t={}){const{grouped:n,limit:r,offset:i}=t,s=ec(this,t.columns||rg()),o=Lse(s),a=[];if(this.scan((u,l)=>a.push(o(u,l)),!0,r,i),n&&this.isGrouped()){const u=[];return this.scan(l=>u.push(l),!0,r,i),FWe(this,u,a,n)}return a}*[Symbol.iterator](){const t=qz(this),n=this.numRows();for(let r=0;rt.forEach(u):u=>this.scan(u,!0),a=r.length;i={};for(let u=0;uf[++d]=c.get(h))}this.isGrouped()&&(s=MWe(this.groups(),o,!!t,n))}return this.create({data:i,names:r,groups:s,filter:null,order:null})}transform(...t){return t.flat().reduce((n,r)=>r(n),this)}toArrow(t){return Uae(this,t)}toArrowBuffer(t){return CKe(this,t)}toCSV(t){return RKe(this,t)}toHTML(t){return NKe(this,t)}toJSON(t){return LKe(this,t)}toMarkdown(t){return MKe(this,t)}}function qz(e){let t=e._builder;if(!t){const n=Lse(e.columnNames()),r=e.data();if(e.isOrdered()||e.isFiltered()){const i=e.indices();t=s=>n(i[s],r)}else t=i=>n(i,r);e._builder=t}return t}class VKe{constructor(t){this._outputs=t}size(){return this._outputs.length}outputs(){return this._outputs}init(){return{}}add(){}rem(){}write(){}}function pn(e,t,n,r){const i=n[e.type]||n.Default;if(i&&i(e,t,r)===!1)return;const s=zKe[e.type];s&&s(e,t,n)}const Vb=(e,t,n)=>{pn(e.argument,t,n,e)},r2=(e,t,n)=>{pn(e.left,t,n,e),pn(e.right,t,n,e)},Gz=(e,t,n)=>{pn(e.test,t,n,e),pn(e.consequent,t,n,e),e.alternate&&pn(e.alternate,t,n,e)},i2=(e,t,n)=>{hu(e.params,t,n,e),pn(e.body,t,n,e)},Yz=(e,t,n)=>{pn(e.callee,t,n,e),hu(e.arguments,t,n,e)},hu=(e,t,n,r)=>{e.forEach(i=>pn(i,t,n,r))},zKe={TemplateLiteral:(e,t,n)=>{hu(e.expressions,t,n,e),hu(e.quasis,t,n,e)},MemberExpression:(e,t,n)=>{pn(e.object,t,n,e),pn(e.property,t,n,e)},CallExpression:Yz,NewExpression:Yz,ArrayExpression:(e,t,n)=>{hu(e.elements,t,n,e)},AssignmentExpression:r2,AwaitExpression:Vb,BinaryExpression:r2,LogicalExpression:r2,UnaryExpression:Vb,UpdateExpression:Vb,ConditionalExpression:Gz,ObjectExpression:(e,t,n)=>{hu(e.properties,t,n,e)},Property:(e,t,n)=>{pn(e.key,t,n,e),pn(e.value,t,n,e)},ArrowFunctionExpression:i2,FunctionExpression:i2,FunctionDeclaration:i2,VariableDeclaration:(e,t,n)=>{hu(e.declarations,t,n,e)},VariableDeclarator:(e,t,n)=>{pn(e.id,t,n,e),pn(e.init,t,n,e)},SpreadElement:(e,t,n)=>{pn(e.argument,t,n,e)},BlockStatement:(e,t,n)=>{hu(e.body,t,n,e)},ExpressionStatement:(e,t,n)=>{pn(e.expression,t,n,e)},IfStatement:Gz,ForStatement:(e,t,n)=>{pn(e.init,t,n,e),pn(e.test,t,n,e),pn(e.update,t,n,e),pn(e.body,t,n,e)},WhileStatement:(e,t,n)=>{pn(e.test,t,n,e),pn(e.body,t,n,e)},DoWhileStatement:(e,t,n)=>{pn(e.body,t,n,e),pn(e.test,t,n,e)},SwitchStatement:(e,t,n)=>{pn(e.discriminant,t,n,e),hu(e.cases,t,n,e)},SwitchCase:(e,t,n)=>{e.test&&pn(e.test,t,n,e),hu(e.consequent,t,n,e)},ReturnStatement:Vb,Program:(e,t,n)=>{pn(e.body[0],t,n,e)}};function Gae(e){delete e.start,delete e.end,delete e.optional}function Kz(e){Gae(e),delete e.object,delete e.property,delete e.computed,e.table||delete e.table}function HKe(e){return pn(e,null,{Column:Kz,Constant:Kz,Default:Gae}),e}function ti(e,t){return t&&t.type===e}function WKe(e){return ti(UWe,e)||ti(jWe,e)}function qKe(e){return sr(e)?e:()=>e}const GKe="Escaped functions are not valid as rollup or pivot values.";function YKe(e,t,n){e.aggronly&&Wt(GKe);const r="(row,data)=>fn("+$se(e.table.columnNames())+",$)";return{escape:Y6.escape(r,qKe(t.expr),n)}}var KKe=[509,0,227,0,150,4,294,9,1368,2,2,1,6,3,41,2,5,0,166,1,574,3,9,9,370,1,81,2,71,10,50,3,123,2,54,14,32,10,3,1,11,3,46,10,8,0,46,9,7,2,37,13,2,9,6,1,45,0,13,2,49,13,9,3,2,11,83,11,7,0,3,0,158,11,6,9,7,3,56,1,2,6,3,1,3,2,10,0,11,1,3,6,4,4,193,17,10,9,5,0,82,19,13,9,214,6,3,8,28,1,83,16,16,9,82,12,9,9,84,14,5,9,243,14,166,9,71,5,2,1,3,3,2,0,2,1,13,9,120,6,3,6,4,0,29,9,41,6,2,3,9,0,10,10,47,15,406,7,2,7,17,9,57,21,2,13,123,5,4,0,2,1,2,6,2,0,9,9,49,4,2,1,2,4,9,9,330,3,10,1,2,0,49,6,4,4,14,9,5351,0,7,14,13835,9,87,9,39,4,60,6,26,9,1014,0,2,54,8,3,82,0,12,1,19628,1,4706,45,3,22,543,4,4,5,9,7,3,6,31,3,149,2,1418,49,513,54,5,49,9,0,15,0,23,4,2,14,1361,6,2,16,3,6,2,1,2,4,101,0,161,6,10,9,357,0,62,13,499,13,983,6,110,6,6,9,4759,9,787719,239],Yae=[0,11,2,25,2,18,2,1,2,14,3,13,35,122,70,52,268,28,4,48,48,31,14,29,6,37,11,29,3,35,5,7,2,4,43,157,19,35,5,35,5,39,9,51,13,10,2,14,2,6,2,1,2,10,2,14,2,6,2,1,68,310,10,21,11,7,25,5,2,41,2,8,70,5,3,0,2,43,2,1,4,0,3,22,11,22,10,30,66,18,2,1,11,21,11,25,71,55,7,1,65,0,16,3,2,2,2,28,43,28,4,28,36,7,2,27,28,53,11,21,11,18,14,17,111,72,56,50,14,50,14,35,349,41,7,1,79,28,11,0,9,21,43,17,47,20,28,22,13,52,58,1,3,0,14,44,33,24,27,35,30,0,3,0,9,34,4,0,13,47,15,3,22,0,2,0,36,17,2,24,20,1,64,6,2,0,2,3,2,14,2,9,8,46,39,7,3,1,3,21,2,6,2,1,2,4,4,0,19,0,13,4,159,52,19,3,21,2,31,47,21,1,2,0,185,46,42,3,37,47,21,0,60,42,14,0,72,26,38,6,186,43,117,63,32,7,3,0,3,7,2,1,2,23,16,0,2,0,95,7,3,38,17,0,2,0,29,0,11,39,8,0,22,0,12,45,20,0,19,72,264,8,2,36,18,0,50,29,113,6,2,1,2,37,22,0,26,5,2,1,2,31,15,0,328,18,16,0,2,12,2,33,125,0,80,921,103,110,18,195,2637,96,16,1071,18,5,4026,582,8634,568,8,30,18,78,18,29,19,47,17,3,32,20,6,18,689,63,129,74,6,0,67,12,65,1,2,0,29,6135,9,1237,43,8,8936,3,2,6,2,1,2,290,16,0,30,2,3,0,15,3,9,395,2309,106,6,12,4,8,8,9,5991,84,2,70,2,1,3,0,3,1,3,3,2,11,2,0,2,6,2,64,2,3,3,7,2,6,2,27,2,3,2,4,2,0,4,6,2,339,3,24,2,24,2,30,2,24,2,30,2,24,2,30,2,24,2,30,2,24,2,7,1845,30,7,5,262,61,147,44,11,6,17,0,322,29,19,43,485,27,757,6,2,3,2,1,2,14,2,196,60,67,8,0,1205,3,2,26,2,1,2,0,3,0,2,9,2,3,2,0,2,0,7,0,5,0,2,0,2,0,2,2,2,1,2,0,3,0,2,0,2,0,2,0,2,0,2,1,2,0,3,3,2,6,2,3,2,3,2,0,2,9,2,16,6,2,2,4,2,16,4421,42719,33,4153,7,221,3,5761,15,7472,16,621,2467,541,1507,4938,6,4191],QKe="‌‍·̀-ͯ·҃-֑҇-ׇֽֿׁׂׅׄؐ-ًؚ-٩ٰۖ-ۜ۟-۪ۤۧۨ-ۭ۰-۹ܑܰ-݊ަ-ް߀-߉߫-߽߳ࠖ-࠙ࠛ-ࠣࠥ-ࠧࠩ-࡙࠭-࡛࢘-࢟࣊-ࣣ࣡-ःऺ-़ा-ॏ॑-ॗॢॣ०-९ঁ-ঃ়া-ৄেৈো-্ৗৢৣ০-৯৾ਁ-ਃ਼ਾ-ੂੇੈੋ-੍ੑ੦-ੱੵઁ-ઃ઼ા-ૅે-ૉો-્ૢૣ૦-૯ૺ-૿ଁ-ଃ଼ା-ୄେୈୋ-୍୕-ୗୢୣ୦-୯ஂா-ூெ-ைொ-்ௗ௦-௯ఀ-ఄ఼ా-ౄె-ైొ-్ౕౖౢౣ౦-౯ಁ-ಃ಼ಾ-ೄೆ-ೈೊ-್ೕೖೢೣ೦-೯ೳഀ-ഃ഻഼ാ-ൄെ-ൈൊ-്ൗൢൣ൦-൯ඁ-ඃ්ා-ුූෘ-ෟ෦-෯ෲෳัิ-ฺ็-๎๐-๙ັິ-ຼ່-໎໐-໙༘༙༠-༩༹༵༷༾༿ཱ-྄྆྇ྍ-ྗྙ-ྼ࿆ါ-ှ၀-၉ၖ-ၙၞ-ၠၢ-ၤၧ-ၭၱ-ၴႂ-ႍႏ-ႝ፝-፟፩-፱ᜒ-᜕ᜲ-᜴ᝒᝓᝲᝳ឴-៓៝០-៩᠋-᠍᠏-᠙ᢩᤠ-ᤫᤰ-᤻᥆-᥏᧐-᧚ᨗ-ᨛᩕ-ᩞ᩠-᩿᩼-᪉᪐-᪙᪰-᪽ᪿ-ᫎᬀ-ᬄ᬴-᭄᭐-᭙᭫-᭳ᮀ-ᮂᮡ-ᮭ᮰-᮹᯦-᯳ᰤ-᰷᱀-᱉᱐-᱙᳐-᳔᳒-᳨᳭᳴᳷-᳹᷀-᷿‌‍‿⁀⁔⃐-⃥⃜⃡-⃰⳯-⵿⳱ⷠ-〪ⷿ-゙゚〯・꘠-꘩꙯ꙴ-꙽ꚞꚟ꛰꛱ꠂ꠆ꠋꠣ-ꠧ꠬ꢀꢁꢴ-ꣅ꣐-꣙꣠-꣱ꣿ-꤉ꤦ-꤭ꥇ-꥓ꦀ-ꦃ꦳-꧀꧐-꧙ꧥ꧰-꧹ꨩ-ꨶꩃꩌꩍ꩐-꩙ꩻ-ꩽꪰꪲ-ꪴꪷꪸꪾ꪿꫁ꫫ-ꫯꫵ꫶ꯣ-ꯪ꯬꯭꯰-꯹ﬞ︀-️︠-︯︳︴﹍-﹏0-9_・",Kae="ªµºÀ-ÖØ-öø-ˁˆ-ˑˠ-ˤˬˮͰ-ʹͶͷͺ-ͽͿΆΈ-ΊΌΎ-ΡΣ-ϵϷ-ҁҊ-ԯԱ-Ֆՙՠ-ֈא-תׯ-ײؠ-يٮٯٱ-ۓەۥۦۮۯۺ-ۼۿܐܒ-ܯݍ-ޥޱߊ-ߪߴߵߺࠀ-ࠕࠚࠤࠨࡀ-ࡘࡠ-ࡪࡰ-ࢇࢉ-ࢎࢠ-ࣉऄ-हऽॐक़-ॡॱ-ঀঅ-ঌএঐও-নপ-রলশ-হঽৎড়ঢ়য়-ৡৰৱৼਅ-ਊਏਐਓ-ਨਪ-ਰਲਲ਼ਵਸ਼ਸਹਖ਼-ੜਫ਼ੲ-ੴઅ-ઍએ-ઑઓ-નપ-રલળવ-હઽૐૠૡૹଅ-ଌଏଐଓ-ନପ-ରଲଳଵ-ହଽଡ଼ଢ଼ୟ-ୡୱஃஅ-ஊஎ-ஐஒ-கஙசஜஞடணதந-பம-ஹௐఅ-ఌఎ-ఐఒ-నప-హఽౘ-ౚౝౠౡಀಅ-ಌಎ-ಐಒ-ನಪ-ಳವ-ಹಽೝೞೠೡೱೲഄ-ഌഎ-ഐഒ-ഺഽൎൔ-ൖൟ-ൡൺ-ൿඅ-ඖක-නඳ-රලව-ෆก-ะาำเ-ๆກຂຄຆ-ຊຌ-ຣລວ-ະາຳຽເ-ໄໆໜ-ໟༀཀ-ཇཉ-ཬྈ-ྌက-ဪဿၐ-ၕၚ-ၝၡၥၦၮ-ၰၵ-ႁႎႠ-ჅჇჍა-ჺჼ-ቈቊ-ቍቐ-ቖቘቚ-ቝበ-ኈኊ-ኍነ-ኰኲ-ኵኸ-ኾዀዂ-ዅወ-ዖዘ-ጐጒ-ጕጘ-ፚᎀ-ᎏᎠ-Ᏽᏸ-ᏽᐁ-ᙬᙯ-ᙿᚁ-ᚚᚠ-ᛪᛮ-ᛸᜀ-ᜑᜟ-ᜱᝀ-ᝑᝠ-ᝬᝮ-ᝰក-ឳៗៜᠠ-ᡸᢀ-ᢨᢪᢰ-ᣵᤀ-ᤞᥐ-ᥭᥰ-ᥴᦀ-ᦫᦰ-ᧉᨀ-ᨖᨠ-ᩔᪧᬅ-ᬳᭅ-ᭌᮃ-ᮠᮮᮯᮺ-ᯥᰀ-ᰣᱍ-ᱏᱚ-ᱽᲀ-ᲈᲐ-ᲺᲽ-Ჿᳩ-ᳬᳮ-ᳳᳵᳶᳺᴀ-ᶿḀ-ἕἘ-Ἕἠ-ὅὈ-Ὅὐ-ὗὙὛὝὟ-ώᾀ-ᾴᾶ-ᾼιῂ-ῄῆ-ῌῐ-ΐῖ-Ίῠ-Ῥῲ-ῴῶ-ῼⁱⁿₐ-ₜℂℇℊ-ℓℕ℘-ℝℤΩℨK-ℹℼ-ℿⅅ-ⅉⅎⅠ-ↈⰀ-ⳤⳫ-ⳮⳲⳳⴀ-ⴥⴧⴭⴰ-ⵧⵯⶀ-ⶖⶠ-ⶦⶨ-ⶮⶰ-ⶶⶸ-ⶾⷀ-ⷆⷈ-ⷎⷐ-ⷖⷘ-ⷞ々-〇〡-〩〱-〵〸-〼ぁ-ゖ゛-ゟァ-ヺー-ヿㄅ-ㄯㄱ-ㆎㆠ-ㆿㇰ-ㇿ㐀-䶿一-ꒌꓐ-ꓽꔀ-ꘌꘐ-ꘟꘪꘫꙀ-ꙮꙿ-ꚝꚠ-ꛯꜗ-ꜟꜢ-ꞈꞋ-ꟊꟐꟑꟓꟕ-ꟙꟲ-ꠁꠃ-ꠅꠇ-ꠊꠌ-ꠢꡀ-ꡳꢂ-ꢳꣲ-ꣷꣻꣽꣾꤊ-ꤥꤰ-ꥆꥠ-ꥼꦄ-ꦲꧏꧠ-ꧤꧦ-ꧯꧺ-ꧾꨀ-ꨨꩀ-ꩂꩄ-ꩋꩠ-ꩶꩺꩾ-ꪯꪱꪵꪶꪹ-ꪽꫀꫂꫛ-ꫝꫠ-ꫪꫲ-ꫴꬁ-ꬆꬉ-ꬎꬑ-ꬖꬠ-ꬦꬨ-ꬮꬰ-ꭚꭜ-ꭩꭰ-ꯢ가-힣ힰ-ퟆퟋ-ퟻ豈-舘並-龎ff-stﬓ-ﬗיִײַ-ﬨשׁ-זּטּ-לּמּנּסּףּפּצּ-ﮱﯓ-ﴽﵐ-ﶏﶒ-ﷇﷰ-ﷻﹰ-ﹴﹶ-ﻼA-Za-zヲ-하-ᅦᅧ-ᅬᅭ-ᅲᅳ-ᅵ",s2={3:"abstract boolean byte char class double enum export extends final float goto implements import int interface long native package private protected public short static super synchronized throws transient volatile",5:"class enum extends super const export import",6:"enum",strict:"implements interface let package private protected public static yield",strictBind:"eval arguments"},o2="break case catch continue debugger default do else finally for function if return switch throw try var while with null true false instanceof typeof void delete new in this",XKe={5:o2,"5module":o2+" export import",6:o2+" const class extends export import super"},JKe=/^in(stanceof)?$/,ZKe=new RegExp("["+Kae+"]"),eQe=new RegExp("["+Kae+QKe+"]");function yk(e,t){for(var n=65536,r=0;re)return!1;if(n+=t[r+1],n>=e)return!0}return!1}function tc(e,t){return e<65?e===36:e<91?!0:e<97?e===95:e<123?!0:e<=65535?e>=170&&ZKe.test(String.fromCharCode(e)):t===!1?!1:yk(e,Yae)}function ig(e,t){return e<48?e===36:e<58?!0:e<65?!1:e<91?!0:e<97?e===95:e<123?!0:e<=65535?e>=170&&eQe.test(String.fromCharCode(e)):t===!1?!1:yk(e,Yae)||yk(e,KKe)}var gn=function(t,n){n===void 0&&(n={}),this.label=t,this.keyword=n.keyword,this.beforeExpr=!!n.beforeExpr,this.startsExpr=!!n.startsExpr,this.isLoop=!!n.isLoop,this.isAssign=!!n.isAssign,this.prefix=!!n.prefix,this.postfix=!!n.postfix,this.binop=n.binop||null,this.updateContext=null};function Bo(e,t){return new gn(e,{beforeExpr:!0,binop:t})}var jo={beforeExpr:!0},Ps={startsExpr:!0},YL={};function on(e,t){return t===void 0&&(t={}),t.keyword=e,YL[e]=new gn(e,t)}var D={num:new gn("num",Ps),regexp:new gn("regexp",Ps),string:new gn("string",Ps),name:new gn("name",Ps),privateId:new gn("privateId",Ps),eof:new gn("eof"),bracketL:new gn("[",{beforeExpr:!0,startsExpr:!0}),bracketR:new gn("]"),braceL:new gn("{",{beforeExpr:!0,startsExpr:!0}),braceR:new gn("}"),parenL:new gn("(",{beforeExpr:!0,startsExpr:!0}),parenR:new gn(")"),comma:new gn(",",jo),semi:new gn(";",jo),colon:new gn(":",jo),dot:new gn("."),question:new gn("?",jo),questionDot:new gn("?."),arrow:new gn("=>",jo),template:new gn("template"),invalidTemplate:new gn("invalidTemplate"),ellipsis:new gn("...",jo),backQuote:new gn("`",Ps),dollarBraceL:new gn("${",{beforeExpr:!0,startsExpr:!0}),eq:new gn("=",{beforeExpr:!0,isAssign:!0}),assign:new gn("_=",{beforeExpr:!0,isAssign:!0}),incDec:new gn("++/--",{prefix:!0,postfix:!0,startsExpr:!0}),prefix:new gn("!/~",{beforeExpr:!0,prefix:!0,startsExpr:!0}),logicalOR:Bo("||",1),logicalAND:Bo("&&",2),bitwiseOR:Bo("|",3),bitwiseXOR:Bo("^",4),bitwiseAND:Bo("&",5),equality:Bo("==/!=/===/!==",6),relational:Bo("/<=/>=",7),bitShift:Bo("<>/>>>",8),plusMin:new gn("+/-",{beforeExpr:!0,binop:9,prefix:!0,startsExpr:!0}),modulo:Bo("%",10),star:Bo("*",10),slash:Bo("/",10),starstar:new gn("**",{beforeExpr:!0}),coalesce:Bo("??",1),_break:on("break"),_case:on("case",jo),_catch:on("catch"),_continue:on("continue"),_debugger:on("debugger"),_default:on("default",jo),_do:on("do",{isLoop:!0,beforeExpr:!0}),_else:on("else",jo),_finally:on("finally"),_for:on("for",{isLoop:!0}),_function:on("function",Ps),_if:on("if"),_return:on("return",jo),_switch:on("switch"),_throw:on("throw",jo),_try:on("try"),_var:on("var"),_const:on("const"),_while:on("while",{isLoop:!0}),_with:on("with"),_new:on("new",{beforeExpr:!0,startsExpr:!0}),_this:on("this",Ps),_super:on("super",Ps),_class:on("class",Ps),_extends:on("extends",jo),_export:on("export"),_import:on("import",Ps),_null:on("null",Ps),_true:on("true",Ps),_false:on("false",Ps),_in:on("in",{beforeExpr:!0,binop:7}),_instanceof:on("instanceof",{beforeExpr:!0,binop:7}),_typeof:on("typeof",{beforeExpr:!0,prefix:!0,startsExpr:!0}),_void:on("void",{beforeExpr:!0,prefix:!0,startsExpr:!0}),_delete:on("delete",{beforeExpr:!0,prefix:!0,startsExpr:!0})},va=/\r\n?|\n|\u2028|\u2029/,tQe=new RegExp(va.source,"g");function Fg(e){return e===10||e===13||e===8232||e===8233}function Qae(e,t,n){n===void 0&&(n=e.length);for(var r=t;r>10)+55296,(e&1023)+56320))}var iQe=/(?:[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])/,zv=function(t,n){this.line=t,this.column=n};zv.prototype.offset=function(t){return new zv(this.line,this.column+t)};var XC=function(t,n,r){this.start=n,this.end=r,t.sourceFile!==null&&(this.source=t.sourceFile)};function Zae(e,t){for(var n=1,r=0;;){var i=Qae(e,r,t);if(i<0)return new zv(n,t-r);++n,r=i}}var vk={ecmaVersion:null,sourceType:"script",onInsertedSemicolon:null,onTrailingComma:null,allowReserved:null,allowReturnOutsideFunction:!1,allowImportExportEverywhere:!1,allowAwaitOutsideFunction:null,allowSuperOutsideMethod:null,allowHashBang:!1,checkPrivateFields:!0,locations:!1,onToken:null,onComment:null,ranges:!1,program:null,sourceFile:null,directSourceFile:null,preserveParens:!1},Jz=!1;function sQe(e){var t={};for(var n in vk)t[n]=e&&c1(e,n)?e[n]:vk[n];if(t.ecmaVersion==="latest"?t.ecmaVersion=1e8:t.ecmaVersion==null?(!Jz&&typeof console=="object"&&console.warn&&(Jz=!0,console.warn(`Since Acorn 8.0.0, options.ecmaVersion is required. +Defaulting to 2020, but this will stop working in the future.`)),t.ecmaVersion=11):t.ecmaVersion>=2015&&(t.ecmaVersion-=2009),t.allowReserved==null&&(t.allowReserved=t.ecmaVersion<5),(!e||e.allowHashBang==null)&&(t.allowHashBang=t.ecmaVersion>=14),Qz(t.onToken)){var r=t.onToken;t.onToken=function(i){return r.push(i)}}return Qz(t.onComment)&&(t.onComment=oQe(t,t.onComment)),t}function oQe(e,t){return function(n,r,i,s,o,a){var u={type:n?"Block":"Line",value:r,start:i,end:s};e.locations&&(u.loc=new XC(this,o,a)),e.ranges&&(u.range=[i,s]),t.push(u)}}var Hv=1,Bg=2,KL=4,eue=8,tue=16,nue=32,QL=64,rue=128,f1=256,XL=Hv|Bg|f1;function JL(e,t){return Bg|(e?KL:0)|(t?eue:0)}var TI=0,ZL=1,vc=2,iue=3,sue=4,oue=5,oi=function(t,n,r){this.options=t=sQe(t),this.sourceFile=t.sourceFile,this.keywords=Xc(XKe[t.ecmaVersion>=6?6:t.sourceType==="module"?"5module":5]);var i="";t.allowReserved!==!0&&(i=s2[t.ecmaVersion>=6?6:t.ecmaVersion===5?5:3],t.sourceType==="module"&&(i+=" await")),this.reservedWords=Xc(i);var s=(i?i+" ":"")+s2.strict;this.reservedWordsStrict=Xc(s),this.reservedWordsStrictBind=Xc(s+" "+s2.strictBind),this.input=String(n),this.containsEsc=!1,r?(this.pos=r,this.lineStart=this.input.lastIndexOf(` +`,r-1)+1,this.curLine=this.input.slice(0,this.lineStart).split(va).length):(this.pos=this.lineStart=0,this.curLine=1),this.type=D.eof,this.value=null,this.start=this.end=this.pos,this.startLoc=this.endLoc=this.curPosition(),this.lastTokEndLoc=this.lastTokStartLoc=null,this.lastTokStart=this.lastTokEnd=this.pos,this.context=this.initialContext(),this.exprAllowed=!0,this.inModule=t.sourceType==="module",this.strict=this.inModule||this.strictDirective(this.pos),this.potentialArrowAt=-1,this.potentialArrowInForAwait=!1,this.yieldPos=this.awaitPos=this.awaitIdentPos=0,this.labels=[],this.undefinedExports=Object.create(null),this.pos===0&&t.allowHashBang&&this.input.slice(0,2)==="#!"&&this.skipLineComment(2),this.scopeStack=[],this.enterScope(Hv),this.regexpState=null,this.privateNameStack=[]},pl={inFunction:{configurable:!0},inGenerator:{configurable:!0},inAsync:{configurable:!0},canAwait:{configurable:!0},allowSuper:{configurable:!0},allowDirectSuper:{configurable:!0},treatFunctionsAsVar:{configurable:!0},allowNewDotTarget:{configurable:!0},inClassStaticBlock:{configurable:!0}};oi.prototype.parse=function(){var t=this.options.program||this.startNode();return this.nextToken(),this.parseTopLevel(t)};pl.inFunction.get=function(){return(this.currentVarScope().flags&Bg)>0};pl.inGenerator.get=function(){return(this.currentVarScope().flags&eue)>0&&!this.currentVarScope().inClassFieldInit};pl.inAsync.get=function(){return(this.currentVarScope().flags&KL)>0&&!this.currentVarScope().inClassFieldInit};pl.canAwait.get=function(){for(var e=this.scopeStack.length-1;e>=0;e--){var t=this.scopeStack[e];if(t.inClassFieldInit||t.flags&f1)return!1;if(t.flags&Bg)return(t.flags&KL)>0}return this.inModule&&this.options.ecmaVersion>=13||this.options.allowAwaitOutsideFunction};pl.allowSuper.get=function(){var e=this.currentThisScope(),t=e.flags,n=e.inClassFieldInit;return(t&QL)>0||n||this.options.allowSuperOutsideMethod};pl.allowDirectSuper.get=function(){return(this.currentThisScope().flags&rue)>0};pl.treatFunctionsAsVar.get=function(){return this.treatFunctionsAsVarInScope(this.currentScope())};pl.allowNewDotTarget.get=function(){var e=this.currentThisScope(),t=e.flags,n=e.inClassFieldInit;return(t&(Bg|f1))>0||n};pl.inClassStaticBlock.get=function(){return(this.currentVarScope().flags&f1)>0};oi.extend=function(){for(var t=[],n=arguments.length;n--;)t[n]=arguments[n];for(var r=this,i=0;i=,?^&]/.test(i)||i==="!"&&this.input.charAt(r+1)==="=")}e+=t[0].length,Yo.lastIndex=e,e+=Yo.exec(this.input)[0].length,this.input[e]===";"&&e++}};Is.eat=function(e){return this.type===e?(this.next(),!0):!1};Is.isContextual=function(e){return this.type===D.name&&this.value===e&&!this.containsEsc};Is.eatContextual=function(e){return this.isContextual(e)?(this.next(),!0):!1};Is.expectContextual=function(e){this.eatContextual(e)||this.unexpected()};Is.canInsertSemicolon=function(){return this.type===D.eof||this.type===D.braceR||va.test(this.input.slice(this.lastTokEnd,this.start))};Is.insertSemicolon=function(){if(this.canInsertSemicolon())return this.options.onInsertedSemicolon&&this.options.onInsertedSemicolon(this.lastTokEnd,this.lastTokEndLoc),!0};Is.semicolon=function(){!this.eat(D.semi)&&!this.insertSemicolon()&&this.unexpected()};Is.afterTrailingComma=function(e,t){if(this.type===e)return this.options.onTrailingComma&&this.options.onTrailingComma(this.lastTokStart,this.lastTokStartLoc),t||this.next(),!0};Is.expect=function(e){this.eat(e)||this.unexpected()};Is.unexpected=function(e){this.raise(e??this.start,"Unexpected token")};var JC=function(){this.shorthandAssign=this.trailingComma=this.parenthesizedAssign=this.parenthesizedBind=this.doubleProto=-1};Is.checkPatternErrors=function(e,t){if(e){e.trailingComma>-1&&this.raiseRecoverable(e.trailingComma,"Comma is not permitted after the rest element");var n=t?e.parenthesizedAssign:e.parenthesizedBind;n>-1&&this.raiseRecoverable(n,t?"Assigning to rvalue":"Parenthesized pattern")}};Is.checkExpressionErrors=function(e,t){if(!e)return!1;var n=e.shorthandAssign,r=e.doubleProto;if(!t)return n>=0||r>=0;n>=0&&this.raise(n,"Shorthand property assignments are valid only in destructuring patterns"),r>=0&&this.raiseRecoverable(r,"Redefinition of __proto__ property")};Is.checkYieldAwaitInDefaultParams=function(){this.yieldPos&&(!this.awaitPos||this.yieldPos55295&&r<56320)return!0;if(tc(r,!0)){for(var i=n+1;ig(r=this.input.charCodeAt(i),!0);)++i;if(r===92||r>55295&&r<56320)return!0;var s=this.input.slice(n,i);if(!JKe.test(s))return!0}return!1};ft.isAsyncFunction=function(){if(this.options.ecmaVersion<8||!this.isContextual("async"))return!1;Yo.lastIndex=this.pos;var e=Yo.exec(this.input),t=this.pos+e[0].length,n;return!va.test(this.input.slice(this.pos,t))&&this.input.slice(t,t+8)==="function"&&(t+8===this.input.length||!(ig(n=this.input.charCodeAt(t+8))||n>55295&&n<56320))};ft.parseStatement=function(e,t,n){var r=this.type,i=this.startNode(),s;switch(this.isLet(e)&&(r=D._var,s="let"),r){case D._break:case D._continue:return this.parseBreakContinueStatement(i,r.keyword);case D._debugger:return this.parseDebuggerStatement(i);case D._do:return this.parseDoStatement(i);case D._for:return this.parseForStatement(i);case D._function:return e&&(this.strict||e!=="if"&&e!=="label")&&this.options.ecmaVersion>=6&&this.unexpected(),this.parseFunctionStatement(i,!1,!e);case D._class:return e&&this.unexpected(),this.parseClass(i,!0);case D._if:return this.parseIfStatement(i);case D._return:return this.parseReturnStatement(i);case D._switch:return this.parseSwitchStatement(i);case D._throw:return this.parseThrowStatement(i);case D._try:return this.parseTryStatement(i);case D._const:case D._var:return s=s||this.value,e&&s!=="var"&&this.unexpected(),this.parseVarStatement(i,s);case D._while:return this.parseWhileStatement(i);case D._with:return this.parseWithStatement(i);case D.braceL:return this.parseBlock(!0,i);case D.semi:return this.parseEmptyStatement(i);case D._export:case D._import:if(this.options.ecmaVersion>10&&r===D._import){Yo.lastIndex=this.pos;var o=Yo.exec(this.input),a=this.pos+o[0].length,u=this.input.charCodeAt(a);if(u===40||u===46)return this.parseExpressionStatement(i,this.parseExpression())}return this.options.allowImportExportEverywhere||(t||this.raise(this.start,"'import' and 'export' may only appear at the top level"),this.inModule||this.raise(this.start,"'import' and 'export' may appear only with 'sourceType: module'")),r===D._import?this.parseImport(i):this.parseExport(i,n);default:if(this.isAsyncFunction())return e&&this.unexpected(),this.next(),this.parseFunctionStatement(i,!0,!e);var l=this.value,c=this.parseExpression();return r===D.name&&c.type==="Identifier"&&this.eat(D.colon)?this.parseLabeledStatement(i,l,c,e):this.parseExpressionStatement(i,c)}};ft.parseBreakContinueStatement=function(e,t){var n=t==="break";this.next(),this.eat(D.semi)||this.insertSemicolon()?e.label=null:this.type!==D.name?this.unexpected():(e.label=this.parseIdent(),this.semicolon());for(var r=0;r=6?this.eat(D.semi):this.semicolon(),this.finishNode(e,"DoWhileStatement")};ft.parseForStatement=function(e){this.next();var t=this.options.ecmaVersion>=9&&this.canAwait&&this.eatContextual("await")?this.lastTokStart:-1;if(this.labels.push(eM),this.enterScope(0),this.expect(D.parenL),this.type===D.semi)return t>-1&&this.unexpected(t),this.parseFor(e,null);var n=this.isLet();if(this.type===D._var||this.type===D._const||n){var r=this.startNode(),i=n?"let":this.value;return this.next(),this.parseVar(r,!0,i),this.finishNode(r,"VariableDeclaration"),(this.type===D._in||this.options.ecmaVersion>=6&&this.isContextual("of"))&&r.declarations.length===1?(this.options.ecmaVersion>=9&&(this.type===D._in?t>-1&&this.unexpected(t):e.await=t>-1),this.parseForIn(e,r)):(t>-1&&this.unexpected(t),this.parseFor(e,r))}var s=this.isContextual("let"),o=!1,a=new JC,u=this.parseExpression(t>-1?"await":!0,a);return this.type===D._in||(o=this.options.ecmaVersion>=6&&this.isContextual("of"))?(this.options.ecmaVersion>=9&&(this.type===D._in?t>-1&&this.unexpected(t):e.await=t>-1),s&&o&&this.raise(u.start,"The left-hand side of a for-of loop may not start with 'let'."),this.toAssignable(u,!1,a),this.checkLValPattern(u),this.parseForIn(e,u)):(this.checkExpressionErrors(a,!0),t>-1&&this.unexpected(t),this.parseFor(e,u))};ft.parseFunctionStatement=function(e,t,n){return this.next(),this.parseFunction(e,By|(n?0:_k),!1,t)};ft.parseIfStatement=function(e){return this.next(),e.test=this.parseParenExpression(),e.consequent=this.parseStatement("if"),e.alternate=this.eat(D._else)?this.parseStatement("if"):null,this.finishNode(e,"IfStatement")};ft.parseReturnStatement=function(e){return!this.inFunction&&!this.options.allowReturnOutsideFunction&&this.raise(this.start,"'return' outside of function"),this.next(),this.eat(D.semi)||this.insertSemicolon()?e.argument=null:(e.argument=this.parseExpression(),this.semicolon()),this.finishNode(e,"ReturnStatement")};ft.parseSwitchStatement=function(e){this.next(),e.discriminant=this.parseParenExpression(),e.cases=[],this.expect(D.braceL),this.labels.push(uQe),this.enterScope(0);for(var t,n=!1;this.type!==D.braceR;)if(this.type===D._case||this.type===D._default){var r=this.type===D._case;t&&this.finishNode(t,"SwitchCase"),e.cases.push(t=this.startNode()),t.consequent=[],this.next(),r?t.test=this.parseExpression():(n&&this.raiseRecoverable(this.lastTokStart,"Multiple default clauses"),n=!0,t.test=null),this.expect(D.colon)}else t||this.unexpected(),t.consequent.push(this.parseStatement(null));return this.exitScope(),t&&this.finishNode(t,"SwitchCase"),this.next(),this.labels.pop(),this.finishNode(e,"SwitchStatement")};ft.parseThrowStatement=function(e){return this.next(),va.test(this.input.slice(this.lastTokEnd,this.start))&&this.raise(this.lastTokEnd,"Illegal newline after throw"),e.argument=this.parseExpression(),this.semicolon(),this.finishNode(e,"ThrowStatement")};var lQe=[];ft.parseCatchClauseParam=function(){var e=this.parseBindingAtom(),t=e.type==="Identifier";return this.enterScope(t?nue:0),this.checkLValPattern(e,t?sue:vc),this.expect(D.parenR),e};ft.parseTryStatement=function(e){if(this.next(),e.block=this.parseBlock(),e.handler=null,this.type===D._catch){var t=this.startNode();this.next(),this.eat(D.parenL)?t.param=this.parseCatchClauseParam():(this.options.ecmaVersion<10&&this.unexpected(),t.param=null,this.enterScope(0)),t.body=this.parseBlock(!1),this.exitScope(),e.handler=this.finishNode(t,"CatchClause")}return e.finalizer=this.eat(D._finally)?this.parseBlock():null,!e.handler&&!e.finalizer&&this.raise(e.start,"Missing catch or finally clause"),this.finishNode(e,"TryStatement")};ft.parseVarStatement=function(e,t,n){return this.next(),this.parseVar(e,!1,t,n),this.semicolon(),this.finishNode(e,"VariableDeclaration")};ft.parseWhileStatement=function(e){return this.next(),e.test=this.parseParenExpression(),this.labels.push(eM),e.body=this.parseStatement("while"),this.labels.pop(),this.finishNode(e,"WhileStatement")};ft.parseWithStatement=function(e){return this.strict&&this.raise(this.start,"'with' in strict mode"),this.next(),e.object=this.parseParenExpression(),e.body=this.parseStatement("with"),this.finishNode(e,"WithStatement")};ft.parseEmptyStatement=function(e){return this.next(),this.finishNode(e,"EmptyStatement")};ft.parseLabeledStatement=function(e,t,n,r){for(var i=0,s=this.labels;i=0;u--){var l=this.labels[u];if(l.statementStart===e.start)l.statementStart=this.start,l.kind=a;else break}return this.labels.push({name:t,kind:a,statementStart:this.start}),e.body=this.parseStatement(r?r.indexOf("label")===-1?r+"label":r:"label"),this.labels.pop(),e.label=n,this.finishNode(e,"LabeledStatement")};ft.parseExpressionStatement=function(e,t){return e.expression=t,this.semicolon(),this.finishNode(e,"ExpressionStatement")};ft.parseBlock=function(e,t,n){for(e===void 0&&(e=!0),t===void 0&&(t=this.startNode()),t.body=[],this.expect(D.braceL),e&&this.enterScope(0);this.type!==D.braceR;){var r=this.parseStatement(null);t.body.push(r)}return n&&(this.strict=!1),this.next(),e&&this.exitScope(),this.finishNode(t,"BlockStatement")};ft.parseFor=function(e,t){return e.init=t,this.expect(D.semi),e.test=this.type===D.semi?null:this.parseExpression(),this.expect(D.semi),e.update=this.type===D.parenR?null:this.parseExpression(),this.expect(D.parenR),e.body=this.parseStatement("for"),this.exitScope(),this.labels.pop(),this.finishNode(e,"ForStatement")};ft.parseForIn=function(e,t){var n=this.type===D._in;return this.next(),t.type==="VariableDeclaration"&&t.declarations[0].init!=null&&(!n||this.options.ecmaVersion<8||this.strict||t.kind!=="var"||t.declarations[0].id.type!=="Identifier")&&this.raise(t.start,(n?"for-in":"for-of")+" loop variable declaration may not have an initializer"),e.left=t,e.right=n?this.parseExpression():this.parseMaybeAssign(),this.expect(D.parenR),e.body=this.parseStatement("for"),this.exitScope(),this.labels.pop(),this.finishNode(e,n?"ForInStatement":"ForOfStatement")};ft.parseVar=function(e,t,n,r){for(e.declarations=[],e.kind=n;;){var i=this.startNode();if(this.parseVarId(i,n),this.eat(D.eq)?i.init=this.parseMaybeAssign(t):!r&&n==="const"&&!(this.type===D._in||this.options.ecmaVersion>=6&&this.isContextual("of"))?this.unexpected():!r&&i.id.type!=="Identifier"&&!(t&&(this.type===D._in||this.isContextual("of")))?this.raise(this.lastTokEnd,"Complex binding patterns require an initialization value"):i.init=null,e.declarations.push(this.finishNode(i,"VariableDeclarator")),!this.eat(D.comma))break}return e};ft.parseVarId=function(e,t){e.id=this.parseBindingAtom(),this.checkLValPattern(e.id,t==="var"?ZL:vc,!1)};var By=1,_k=2,aue=4;ft.parseFunction=function(e,t,n,r,i){this.initFunction(e),(this.options.ecmaVersion>=9||this.options.ecmaVersion>=6&&!r)&&(this.type===D.star&&t&_k&&this.unexpected(),e.generator=this.eat(D.star)),this.options.ecmaVersion>=8&&(e.async=!!r),t&By&&(e.id=t&aue&&this.type!==D.name?null:this.parseIdent(),e.id&&!(t&_k)&&this.checkLValSimple(e.id,this.strict||e.generator||e.async?this.treatFunctionsAsVar?ZL:vc:iue));var s=this.yieldPos,o=this.awaitPos,a=this.awaitIdentPos;return this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0,this.enterScope(JL(e.async,e.generator)),t&By||(e.id=this.type===D.name?this.parseIdent():null),this.parseFunctionParams(e),this.parseFunctionBody(e,n,!1,i),this.yieldPos=s,this.awaitPos=o,this.awaitIdentPos=a,this.finishNode(e,t&By?"FunctionDeclaration":"FunctionExpression")};ft.parseFunctionParams=function(e){this.expect(D.parenL),e.params=this.parseBindingList(D.parenR,!1,this.options.ecmaVersion>=8),this.checkYieldAwaitInDefaultParams()};ft.parseClass=function(e,t){this.next();var n=this.strict;this.strict=!0,this.parseClassId(e,t),this.parseClassSuper(e);var r=this.enterClassBody(),i=this.startNode(),s=!1;for(i.body=[],this.expect(D.braceL);this.type!==D.braceR;){var o=this.parseClassElement(e.superClass!==null);o&&(i.body.push(o),o.type==="MethodDefinition"&&o.kind==="constructor"?(s&&this.raiseRecoverable(o.start,"Duplicate constructor in the same class"),s=!0):o.key&&o.key.type==="PrivateIdentifier"&&cQe(r,o)&&this.raiseRecoverable(o.key.start,"Identifier '#"+o.key.name+"' has already been declared"))}return this.strict=n,this.next(),e.body=this.finishNode(i,"ClassBody"),this.exitClassBody(),this.finishNode(e,t?"ClassDeclaration":"ClassExpression")};ft.parseClassElement=function(e){if(this.eat(D.semi))return null;var t=this.options.ecmaVersion,n=this.startNode(),r="",i=!1,s=!1,o="method",a=!1;if(this.eatContextual("static")){if(t>=13&&this.eat(D.braceL))return this.parseClassStaticBlock(n),n;this.isClassElementNameStart()||this.type===D.star?a=!0:r="static"}if(n.static=a,!r&&t>=8&&this.eatContextual("async")&&((this.isClassElementNameStart()||this.type===D.star)&&!this.canInsertSemicolon()?s=!0:r="async"),!r&&(t>=9||!s)&&this.eat(D.star)&&(i=!0),!r&&!s&&!i){var u=this.value;(this.eatContextual("get")||this.eatContextual("set"))&&(this.isClassElementNameStart()?o=u:r=u)}if(r?(n.computed=!1,n.key=this.startNodeAt(this.lastTokStart,this.lastTokStartLoc),n.key.name=r,this.finishNode(n.key,"Identifier")):this.parseClassElementName(n),t<13||this.type===D.parenL||o!=="method"||i||s){var l=!n.static&&II(n,"constructor"),c=l&&e;l&&o!=="method"&&this.raise(n.key.start,"Constructor can't have get/set modifier"),n.kind=l?"constructor":o,this.parseClassMethod(n,i,s,c)}else this.parseClassField(n);return n};ft.isClassElementNameStart=function(){return this.type===D.name||this.type===D.privateId||this.type===D.num||this.type===D.string||this.type===D.bracketL||this.type.keyword};ft.parseClassElementName=function(e){this.type===D.privateId?(this.value==="constructor"&&this.raise(this.start,"Classes can't have an element named '#constructor'"),e.computed=!1,e.key=this.parsePrivateIdent()):this.parsePropertyName(e)};ft.parseClassMethod=function(e,t,n,r){var i=e.key;e.kind==="constructor"?(t&&this.raise(i.start,"Constructor can't be a generator"),n&&this.raise(i.start,"Constructor can't be an async method")):e.static&&II(e,"prototype")&&this.raise(i.start,"Classes may not have a static property named prototype");var s=e.value=this.parseMethod(t,n,r);return e.kind==="get"&&s.params.length!==0&&this.raiseRecoverable(s.start,"getter should have no params"),e.kind==="set"&&s.params.length!==1&&this.raiseRecoverable(s.start,"setter should have exactly one param"),e.kind==="set"&&s.params[0].type==="RestElement"&&this.raiseRecoverable(s.params[0].start,"Setter cannot use rest params"),this.finishNode(e,"MethodDefinition")};ft.parseClassField=function(e){if(II(e,"constructor")?this.raise(e.key.start,"Classes can't have a field named 'constructor'"):e.static&&II(e,"prototype")&&this.raise(e.key.start,"Classes can't have a static field named 'prototype'"),this.eat(D.eq)){var t=this.currentThisScope(),n=t.inClassFieldInit;t.inClassFieldInit=!0,e.value=this.parseMaybeAssign(),t.inClassFieldInit=n}else e.value=null;return this.semicolon(),this.finishNode(e,"PropertyDefinition")};ft.parseClassStaticBlock=function(e){e.body=[];var t=this.labels;for(this.labels=[],this.enterScope(f1|QL);this.type!==D.braceR;){var n=this.parseStatement(null);e.body.push(n)}return this.next(),this.exitScope(),this.labels=t,this.finishNode(e,"StaticBlock")};ft.parseClassId=function(e,t){this.type===D.name?(e.id=this.parseIdent(),t&&this.checkLValSimple(e.id,vc,!1)):(t===!0&&this.unexpected(),e.id=null)};ft.parseClassSuper=function(e){e.superClass=this.eat(D._extends)?this.parseExprSubscripts(null,!1):null};ft.enterClassBody=function(){var e={declared:Object.create(null),used:[]};return this.privateNameStack.push(e),e.declared};ft.exitClassBody=function(){var e=this.privateNameStack.pop(),t=e.declared,n=e.used;if(this.options.checkPrivateFields)for(var r=this.privateNameStack.length,i=r===0?null:this.privateNameStack[r-1],s=0;s=11&&(this.eatContextual("as")?(e.exported=this.parseModuleExportName(),this.checkExport(t,e.exported,this.lastTokStart)):e.exported=null),this.expectContextual("from"),this.type!==D.string&&this.unexpected(),e.source=this.parseExprAtom(),this.semicolon(),this.finishNode(e,"ExportAllDeclaration")};ft.parseExport=function(e,t){if(this.next(),this.eat(D.star))return this.parseExportAllDeclaration(e,t);if(this.eat(D._default))return this.checkExport(t,"default",this.lastTokStart),e.declaration=this.parseExportDefaultDeclaration(),this.finishNode(e,"ExportDefaultDeclaration");if(this.shouldParseExportStatement())e.declaration=this.parseExportDeclaration(e),e.declaration.type==="VariableDeclaration"?this.checkVariableExport(t,e.declaration.declarations):this.checkExport(t,e.declaration.id,e.declaration.id.start),e.specifiers=[],e.source=null;else{if(e.declaration=null,e.specifiers=this.parseExportSpecifiers(t),this.eatContextual("from"))this.type!==D.string&&this.unexpected(),e.source=this.parseExprAtom();else{for(var n=0,r=e.specifiers;n=13&&this.type===D.string){var e=this.parseLiteral(this.value);return iQe.test(e.value)&&this.raise(e.start,"An export name cannot include a lone surrogate."),e}return this.parseIdent(!0)};ft.adaptDirectivePrologue=function(e){for(var t=0;t=5&&e.type==="ExpressionStatement"&&e.expression.type==="Literal"&&typeof e.expression.value=="string"&&(this.input[e.start]==='"'||this.input[e.start]==="'")};var _a=oi.prototype;_a.toAssignable=function(e,t,n){if(this.options.ecmaVersion>=6&&e)switch(e.type){case"Identifier":this.inAsync&&e.name==="await"&&this.raise(e.start,"Cannot use 'await' as identifier inside an async function");break;case"ObjectPattern":case"ArrayPattern":case"AssignmentPattern":case"RestElement":break;case"ObjectExpression":e.type="ObjectPattern",n&&this.checkPatternErrors(n,!0);for(var r=0,i=e.properties;r=8&&!a&&u.name==="async"&&!this.canInsertSemicolon()&&this.eat(D._function))return this.overrideContext(hr.f_expr),this.parseFunction(this.startNodeAt(s,o),0,!1,!0,t);if(i&&!this.canInsertSemicolon()){if(this.eat(D.arrow))return this.parseArrowExpression(this.startNodeAt(s,o),[u],!1,t);if(this.options.ecmaVersion>=8&&u.name==="async"&&this.type===D.name&&!a&&(!this.potentialArrowInForAwait||this.value!=="of"||this.containsEsc))return u=this.parseIdent(!1),(this.canInsertSemicolon()||!this.eat(D.arrow))&&this.unexpected(),this.parseArrowExpression(this.startNodeAt(s,o),[u],!0,t)}return u;case D.regexp:var l=this.value;return r=this.parseLiteral(l.value),r.regex={pattern:l.pattern,flags:l.flags},r;case D.num:case D.string:return this.parseLiteral(this.value);case D._null:case D._true:case D._false:return r=this.startNode(),r.value=this.type===D._null?null:this.type===D._true,r.raw=this.type.keyword,this.next(),this.finishNode(r,"Literal");case D.parenL:var c=this.start,f=this.parseParenAndDistinguishExpression(i,t);return e&&(e.parenthesizedAssign<0&&!this.isSimpleAssignTarget(f)&&(e.parenthesizedAssign=c),e.parenthesizedBind<0&&(e.parenthesizedBind=c)),f;case D.bracketL:return r=this.startNode(),this.next(),r.elements=this.parseExprList(D.bracketR,!0,!0,e),this.finishNode(r,"ArrayExpression");case D.braceL:return this.overrideContext(hr.b_expr),this.parseObj(!1,e);case D._function:return r=this.startNode(),this.next(),this.parseFunction(r,0);case D._class:return this.parseClass(this.startNode(),!1);case D._new:return this.parseNew();case D.backQuote:return this.parseTemplate();case D._import:return this.options.ecmaVersion>=11?this.parseExprImport(n):this.unexpected();default:return this.parseExprAtomDefault()}};kt.parseExprAtomDefault=function(){this.unexpected()};kt.parseExprImport=function(e){var t=this.startNode();if(this.containsEsc&&this.raiseRecoverable(this.start,"Escape sequence in keyword import"),this.next(),this.type===D.parenL&&!e)return this.parseDynamicImport(t);if(this.type===D.dot){var n=this.startNodeAt(t.start,t.loc&&t.loc.start);return n.name="import",t.meta=this.finishNode(n,"Identifier"),this.parseImportMeta(t)}else this.unexpected()};kt.parseDynamicImport=function(e){if(this.next(),e.source=this.parseMaybeAssign(),!this.eat(D.parenR)){var t=this.start;this.eat(D.comma)&&this.eat(D.parenR)?this.raiseRecoverable(t,"Trailing comma is not allowed in import()"):this.unexpected(t)}return this.finishNode(e,"ImportExpression")};kt.parseImportMeta=function(e){this.next();var t=this.containsEsc;return e.property=this.parseIdent(!0),e.property.name!=="meta"&&this.raiseRecoverable(e.property.start,"The only valid meta property for import is 'import.meta'"),t&&this.raiseRecoverable(e.start,"'import.meta' must not contain escaped characters"),this.options.sourceType!=="module"&&!this.options.allowImportExportEverywhere&&this.raiseRecoverable(e.start,"Cannot use 'import.meta' outside a module"),this.finishNode(e,"MetaProperty")};kt.parseLiteral=function(e){var t=this.startNode();return t.value=e,t.raw=this.input.slice(this.start,this.end),t.raw.charCodeAt(t.raw.length-1)===110&&(t.bigint=t.raw.slice(0,-1).replace(/_/g,"")),this.next(),this.finishNode(t,"Literal")};kt.parseParenExpression=function(){this.expect(D.parenL);var e=this.parseExpression();return this.expect(D.parenR),e};kt.shouldParseArrow=function(e){return!this.canInsertSemicolon()};kt.parseParenAndDistinguishExpression=function(e,t){var n=this.start,r=this.startLoc,i,s=this.options.ecmaVersion>=8;if(this.options.ecmaVersion>=6){this.next();var o=this.start,a=this.startLoc,u=[],l=!0,c=!1,f=new JC,d=this.yieldPos,h=this.awaitPos,p;for(this.yieldPos=0,this.awaitPos=0;this.type!==D.parenR;)if(l?l=!1:this.expect(D.comma),s&&this.afterTrailingComma(D.parenR,!0)){c=!0;break}else if(this.type===D.ellipsis){p=this.start,u.push(this.parseParenItem(this.parseRestBinding())),this.type===D.comma&&this.raiseRecoverable(this.start,"Comma is not permitted after the rest element");break}else u.push(this.parseMaybeAssign(!1,f,this.parseParenItem));var m=this.lastTokEnd,y=this.lastTokEndLoc;if(this.expect(D.parenR),e&&this.shouldParseArrow(u)&&this.eat(D.arrow))return this.checkPatternErrors(f,!1),this.checkYieldAwaitInDefaultParams(),this.yieldPos=d,this.awaitPos=h,this.parseParenArrowList(n,r,u,t);(!u.length||c)&&this.unexpected(this.lastTokStart),p&&this.unexpected(p),this.checkExpressionErrors(f,!0),this.yieldPos=d||this.yieldPos,this.awaitPos=h||this.awaitPos,u.length>1?(i=this.startNodeAt(o,a),i.expressions=u,this.finishNodeAt(i,"SequenceExpression",m,y)):i=u[0]}else i=this.parseParenExpression();if(this.options.preserveParens){var g=this.startNodeAt(n,r);return g.expression=i,this.finishNode(g,"ParenthesizedExpression")}else return i};kt.parseParenItem=function(e){return e};kt.parseParenArrowList=function(e,t,n,r){return this.parseArrowExpression(this.startNodeAt(e,t),n,!1,r)};var fQe=[];kt.parseNew=function(){this.containsEsc&&this.raiseRecoverable(this.start,"Escape sequence in keyword new");var e=this.startNode();if(this.next(),this.options.ecmaVersion>=6&&this.type===D.dot){var t=this.startNodeAt(e.start,e.loc&&e.loc.start);t.name="new",e.meta=this.finishNode(t,"Identifier"),this.next();var n=this.containsEsc;return e.property=this.parseIdent(!0),e.property.name!=="target"&&this.raiseRecoverable(e.property.start,"The only valid meta property for new is 'new.target'"),n&&this.raiseRecoverable(e.start,"'new.target' must not contain escaped characters"),this.allowNewDotTarget||this.raiseRecoverable(e.start,"'new.target' can only be used in functions and class static block"),this.finishNode(e,"MetaProperty")}var r=this.start,i=this.startLoc;return e.callee=this.parseSubscripts(this.parseExprAtom(null,!1,!0),r,i,!0,!1),this.eat(D.parenL)?e.arguments=this.parseExprList(D.parenR,this.options.ecmaVersion>=8,!1):e.arguments=fQe,this.finishNode(e,"NewExpression")};kt.parseTemplateElement=function(e){var t=e.isTagged,n=this.startNode();return this.type===D.invalidTemplate?(t||this.raiseRecoverable(this.start,"Bad escape sequence in untagged template literal"),n.value={raw:this.value,cooked:null}):n.value={raw:this.input.slice(this.start,this.end).replace(/\r\n?/g,` +`),cooked:this.value},this.next(),n.tail=this.type===D.backQuote,this.finishNode(n,"TemplateElement")};kt.parseTemplate=function(e){e===void 0&&(e={});var t=e.isTagged;t===void 0&&(t=!1);var n=this.startNode();this.next(),n.expressions=[];var r=this.parseTemplateElement({isTagged:t});for(n.quasis=[r];!r.tail;)this.type===D.eof&&this.raise(this.pos,"Unterminated template literal"),this.expect(D.dollarBraceL),n.expressions.push(this.parseExpression()),this.expect(D.braceR),n.quasis.push(r=this.parseTemplateElement({isTagged:t}));return this.next(),this.finishNode(n,"TemplateLiteral")};kt.isAsyncProp=function(e){return!e.computed&&e.key.type==="Identifier"&&e.key.name==="async"&&(this.type===D.name||this.type===D.num||this.type===D.string||this.type===D.bracketL||this.type.keyword||this.options.ecmaVersion>=9&&this.type===D.star)&&!va.test(this.input.slice(this.lastTokEnd,this.start))};kt.parseObj=function(e,t){var n=this.startNode(),r=!0,i={};for(n.properties=[],this.next();!this.eat(D.braceR);){if(r)r=!1;else if(this.expect(D.comma),this.options.ecmaVersion>=5&&this.afterTrailingComma(D.braceR))break;var s=this.parseProperty(e,t);e||this.checkPropClash(s,i,t),n.properties.push(s)}return this.finishNode(n,e?"ObjectPattern":"ObjectExpression")};kt.parseProperty=function(e,t){var n=this.startNode(),r,i,s,o;if(this.options.ecmaVersion>=9&&this.eat(D.ellipsis))return e?(n.argument=this.parseIdent(!1),this.type===D.comma&&this.raiseRecoverable(this.start,"Comma is not permitted after the rest element"),this.finishNode(n,"RestElement")):(n.argument=this.parseMaybeAssign(!1,t),this.type===D.comma&&t&&t.trailingComma<0&&(t.trailingComma=this.start),this.finishNode(n,"SpreadElement"));this.options.ecmaVersion>=6&&(n.method=!1,n.shorthand=!1,(e||t)&&(s=this.start,o=this.startLoc),e||(r=this.eat(D.star)));var a=this.containsEsc;return this.parsePropertyName(n),!e&&!a&&this.options.ecmaVersion>=8&&!r&&this.isAsyncProp(n)?(i=!0,r=this.options.ecmaVersion>=9&&this.eat(D.star),this.parsePropertyName(n)):i=!1,this.parsePropertyValue(n,e,r,i,s,o,t,a),this.finishNode(n,"Property")};kt.parseGetterSetter=function(e){e.kind=e.key.name,this.parsePropertyName(e),e.value=this.parseMethod(!1);var t=e.kind==="get"?0:1;if(e.value.params.length!==t){var n=e.value.start;e.kind==="get"?this.raiseRecoverable(n,"getter should have no params"):this.raiseRecoverable(n,"setter should have exactly one param")}else e.kind==="set"&&e.value.params[0].type==="RestElement"&&this.raiseRecoverable(e.value.params[0].start,"Setter cannot use rest params")};kt.parsePropertyValue=function(e,t,n,r,i,s,o,a){(n||r)&&this.type===D.colon&&this.unexpected(),this.eat(D.colon)?(e.value=t?this.parseMaybeDefault(this.start,this.startLoc):this.parseMaybeAssign(!1,o),e.kind="init"):this.options.ecmaVersion>=6&&this.type===D.parenL?(t&&this.unexpected(),e.kind="init",e.method=!0,e.value=this.parseMethod(n,r)):!t&&!a&&this.options.ecmaVersion>=5&&!e.computed&&e.key.type==="Identifier"&&(e.key.name==="get"||e.key.name==="set")&&this.type!==D.comma&&this.type!==D.braceR&&this.type!==D.eq?((n||r)&&this.unexpected(),this.parseGetterSetter(e)):this.options.ecmaVersion>=6&&!e.computed&&e.key.type==="Identifier"?((n||r)&&this.unexpected(),this.checkUnreserved(e.key),e.key.name==="await"&&!this.awaitIdentPos&&(this.awaitIdentPos=i),e.kind="init",t?e.value=this.parseMaybeDefault(i,s,this.copyNode(e.key)):this.type===D.eq&&o?(o.shorthandAssign<0&&(o.shorthandAssign=this.start),e.value=this.parseMaybeDefault(i,s,this.copyNode(e.key))):e.value=this.copyNode(e.key),e.shorthand=!0):this.unexpected()};kt.parsePropertyName=function(e){if(this.options.ecmaVersion>=6){if(this.eat(D.bracketL))return e.computed=!0,e.key=this.parseMaybeAssign(),this.expect(D.bracketR),e.key;e.computed=!1}return e.key=this.type===D.num||this.type===D.string?this.parseExprAtom():this.parseIdent(this.options.allowReserved!=="never")};kt.initFunction=function(e){e.id=null,this.options.ecmaVersion>=6&&(e.generator=e.expression=!1),this.options.ecmaVersion>=8&&(e.async=!1)};kt.parseMethod=function(e,t,n){var r=this.startNode(),i=this.yieldPos,s=this.awaitPos,o=this.awaitIdentPos;return this.initFunction(r),this.options.ecmaVersion>=6&&(r.generator=e),this.options.ecmaVersion>=8&&(r.async=!!t),this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0,this.enterScope(JL(t,r.generator)|QL|(n?rue:0)),this.expect(D.parenL),r.params=this.parseBindingList(D.parenR,!1,this.options.ecmaVersion>=8),this.checkYieldAwaitInDefaultParams(),this.parseFunctionBody(r,!1,!0,!1),this.yieldPos=i,this.awaitPos=s,this.awaitIdentPos=o,this.finishNode(r,"FunctionExpression")};kt.parseArrowExpression=function(e,t,n,r){var i=this.yieldPos,s=this.awaitPos,o=this.awaitIdentPos;return this.enterScope(JL(n,!1)|tue),this.initFunction(e),this.options.ecmaVersion>=8&&(e.async=!!n),this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0,e.params=this.toAssignableList(t,!0),this.parseFunctionBody(e,!0,!1,r),this.yieldPos=i,this.awaitPos=s,this.awaitIdentPos=o,this.finishNode(e,"ArrowFunctionExpression")};kt.parseFunctionBody=function(e,t,n,r){var i=t&&this.type!==D.braceL,s=this.strict,o=!1;if(i)e.body=this.parseMaybeAssign(r),e.expression=!0,this.checkParams(e,!1);else{var a=this.options.ecmaVersion>=7&&!this.isSimpleParamList(e.params);(!s||a)&&(o=this.strictDirective(this.end),o&&a&&this.raiseRecoverable(e.start,"Illegal 'use strict' directive in function with non-simple parameter list"));var u=this.labels;this.labels=[],o&&(this.strict=!0),this.checkParams(e,!s&&!o&&!t&&!n&&this.isSimpleParamList(e.params)),this.strict&&e.id&&this.checkLValSimple(e.id,oue),e.body=this.parseBlock(!1,void 0,o&&!s),e.expression=!1,this.adaptDirectivePrologue(e.body.body),this.labels=u}this.exitScope()};kt.isSimpleParamList=function(e){for(var t=0,n=e;t-1||i.functions.indexOf(e)>-1||i.var.indexOf(e)>-1,i.lexical.push(e),this.inModule&&i.flags&Hv&&delete this.undefinedExports[e]}else if(t===sue){var s=this.currentScope();s.lexical.push(e)}else if(t===iue){var o=this.currentScope();this.treatFunctionsAsVar?r=o.lexical.indexOf(e)>-1:r=o.lexical.indexOf(e)>-1||o.var.indexOf(e)>-1,o.functions.push(e)}else for(var a=this.scopeStack.length-1;a>=0;--a){var u=this.scopeStack[a];if(u.lexical.indexOf(e)>-1&&!(u.flags&nue&&u.lexical[0]===e)||!this.treatFunctionsAsVarInScope(u)&&u.functions.indexOf(e)>-1){r=!0;break}if(u.var.push(e),this.inModule&&u.flags&Hv&&delete this.undefinedExports[e],u.flags&XL)break}r&&this.raiseRecoverable(n,"Identifier '"+e+"' has already been declared")};nd.checkLocalExport=function(e){this.scopeStack[0].lexical.indexOf(e.name)===-1&&this.scopeStack[0].var.indexOf(e.name)===-1&&(this.undefinedExports[e.name]=e)};nd.currentScope=function(){return this.scopeStack[this.scopeStack.length-1]};nd.currentVarScope=function(){for(var e=this.scopeStack.length-1;;e--){var t=this.scopeStack[e];if(t.flags&XL)return t}};nd.currentThisScope=function(){for(var e=this.scopeStack.length-1;;e--){var t=this.scopeStack[e];if(t.flags&XL&&!(t.flags&tue))return t}};var ZC=function(t,n,r){this.type="",this.start=n,this.end=0,t.options.locations&&(this.loc=new XC(t,r)),t.options.directSourceFile&&(this.sourceFile=t.options.directSourceFile),t.options.ranges&&(this.range=[n,0])},d1=oi.prototype;d1.startNode=function(){return new ZC(this,this.start,this.startLoc)};d1.startNodeAt=function(e,t){return new ZC(this,e,t)};function lue(e,t,n,r){return e.type=t,e.end=n,this.options.locations&&(e.loc.end=r),this.options.ranges&&(e.range[1]=n),e}d1.finishNode=function(e,t){return lue.call(this,e,t,this.lastTokEnd,this.lastTokEndLoc)};d1.finishNodeAt=function(e,t,n,r){return lue.call(this,e,t,n,r)};d1.copyNode=function(e){var t=new ZC(this,e.start,this.startLoc);for(var n in e)t[n]=e[n];return t};var cue="ASCII ASCII_Hex_Digit AHex Alphabetic Alpha Any Assigned Bidi_Control Bidi_C Bidi_Mirrored Bidi_M Case_Ignorable CI Cased Changes_When_Casefolded CWCF Changes_When_Casemapped CWCM Changes_When_Lowercased CWL Changes_When_NFKC_Casefolded CWKCF Changes_When_Titlecased CWT Changes_When_Uppercased CWU Dash Default_Ignorable_Code_Point DI Deprecated Dep Diacritic Dia Emoji Emoji_Component Emoji_Modifier Emoji_Modifier_Base Emoji_Presentation Extender Ext Grapheme_Base Gr_Base Grapheme_Extend Gr_Ext Hex_Digit Hex IDS_Binary_Operator IDSB IDS_Trinary_Operator IDST ID_Continue IDC ID_Start IDS Ideographic Ideo Join_Control Join_C Logical_Order_Exception LOE Lowercase Lower Math Noncharacter_Code_Point NChar Pattern_Syntax Pat_Syn Pattern_White_Space Pat_WS Quotation_Mark QMark Radical Regional_Indicator RI Sentence_Terminal STerm Soft_Dotted SD Terminal_Punctuation Term Unified_Ideograph UIdeo Uppercase Upper Variation_Selector VS White_Space space XID_Continue XIDC XID_Start XIDS",fue=cue+" Extended_Pictographic",due=fue,hue=due+" EBase EComp EMod EPres ExtPict",pue=hue,hQe=pue,pQe={9:cue,10:fue,11:due,12:hue,13:pue,14:hQe},mQe="Basic_Emoji Emoji_Keycap_Sequence RGI_Emoji_Modifier_Sequence RGI_Emoji_Flag_Sequence RGI_Emoji_Tag_Sequence RGI_Emoji_ZWJ_Sequence RGI_Emoji",gQe={9:"",10:"",11:"",12:"",13:"",14:mQe},Zz="Cased_Letter LC Close_Punctuation Pe Connector_Punctuation Pc Control Cc cntrl Currency_Symbol Sc Dash_Punctuation Pd Decimal_Number Nd digit Enclosing_Mark Me Final_Punctuation Pf Format Cf Initial_Punctuation Pi Letter L Letter_Number Nl Line_Separator Zl Lowercase_Letter Ll Mark M Combining_Mark Math_Symbol Sm Modifier_Letter Lm Modifier_Symbol Sk Nonspacing_Mark Mn Number N Open_Punctuation Ps Other C Other_Letter Lo Other_Number No Other_Punctuation Po Other_Symbol So Paragraph_Separator Zp Private_Use Co Punctuation P punct Separator Z Space_Separator Zs Spacing_Mark Mc Surrogate Cs Symbol S Titlecase_Letter Lt Unassigned Cn Uppercase_Letter Lu",mue="Adlam Adlm Ahom Anatolian_Hieroglyphs Hluw Arabic Arab Armenian Armn Avestan Avst Balinese Bali Bamum Bamu Bassa_Vah Bass Batak Batk Bengali Beng Bhaiksuki Bhks Bopomofo Bopo Brahmi Brah Braille Brai Buginese Bugi Buhid Buhd Canadian_Aboriginal Cans Carian Cari Caucasian_Albanian Aghb Chakma Cakm Cham Cham Cherokee Cher Common Zyyy Coptic Copt Qaac Cuneiform Xsux Cypriot Cprt Cyrillic Cyrl Deseret Dsrt Devanagari Deva Duployan Dupl Egyptian_Hieroglyphs Egyp Elbasan Elba Ethiopic Ethi Georgian Geor Glagolitic Glag Gothic Goth Grantha Gran Greek Grek Gujarati Gujr Gurmukhi Guru Han Hani Hangul Hang Hanunoo Hano Hatran Hatr Hebrew Hebr Hiragana Hira Imperial_Aramaic Armi Inherited Zinh Qaai Inscriptional_Pahlavi Phli Inscriptional_Parthian Prti Javanese Java Kaithi Kthi Kannada Knda Katakana Kana Kayah_Li Kali Kharoshthi Khar Khmer Khmr Khojki Khoj Khudawadi Sind Lao Laoo Latin Latn Lepcha Lepc Limbu Limb Linear_A Lina Linear_B Linb Lisu Lisu Lycian Lyci Lydian Lydi Mahajani Mahj Malayalam Mlym Mandaic Mand Manichaean Mani Marchen Marc Masaram_Gondi Gonm Meetei_Mayek Mtei Mende_Kikakui Mend Meroitic_Cursive Merc Meroitic_Hieroglyphs Mero Miao Plrd Modi Mongolian Mong Mro Mroo Multani Mult Myanmar Mymr Nabataean Nbat New_Tai_Lue Talu Newa Newa Nko Nkoo Nushu Nshu Ogham Ogam Ol_Chiki Olck Old_Hungarian Hung Old_Italic Ital Old_North_Arabian Narb Old_Permic Perm Old_Persian Xpeo Old_South_Arabian Sarb Old_Turkic Orkh Oriya Orya Osage Osge Osmanya Osma Pahawh_Hmong Hmng Palmyrene Palm Pau_Cin_Hau Pauc Phags_Pa Phag Phoenician Phnx Psalter_Pahlavi Phlp Rejang Rjng Runic Runr Samaritan Samr Saurashtra Saur Sharada Shrd Shavian Shaw Siddham Sidd SignWriting Sgnw Sinhala Sinh Sora_Sompeng Sora Soyombo Soyo Sundanese Sund Syloti_Nagri Sylo Syriac Syrc Tagalog Tglg Tagbanwa Tagb Tai_Le Tale Tai_Tham Lana Tai_Viet Tavt Takri Takr Tamil Taml Tangut Tang Telugu Telu Thaana Thaa Thai Thai Tibetan Tibt Tifinagh Tfng Tirhuta Tirh Ugaritic Ugar Vai Vaii Warang_Citi Wara Yi Yiii Zanabazar_Square Zanb",gue=mue+" Dogra Dogr Gunjala_Gondi Gong Hanifi_Rohingya Rohg Makasar Maka Medefaidrin Medf Old_Sogdian Sogo Sogdian Sogd",yue=gue+" Elymaic Elym Nandinagari Nand Nyiakeng_Puachue_Hmong Hmnp Wancho Wcho",vue=yue+" Chorasmian Chrs Diak Dives_Akuru Khitan_Small_Script Kits Yezi Yezidi",_ue=vue+" Cypro_Minoan Cpmn Old_Uyghur Ougr Tangsa Tnsa Toto Vithkuqi Vith",yQe=_ue+" Hrkt Katakana_Or_Hiragana Kawi Nag_Mundari Nagm Unknown Zzzz",vQe={9:mue,10:gue,11:yue,12:vue,13:_ue,14:yQe},bue={};function _Qe(e){var t=bue[e]={binary:Xc(pQe[e]+" "+Zz),binaryOfStrings:Xc(gQe[e]),nonBinary:{General_Category:Xc(Zz),Script:Xc(vQe[e])}};t.nonBinary.Script_Extensions=t.nonBinary.Script,t.nonBinary.gc=t.nonBinary.General_Category,t.nonBinary.sc=t.nonBinary.Script,t.nonBinary.scx=t.nonBinary.Script_Extensions}for(var a2=0,eH=[9,10,11,12,13,14];a2=6?"uy":"")+(t.options.ecmaVersion>=9?"s":"")+(t.options.ecmaVersion>=13?"d":"")+(t.options.ecmaVersion>=15?"v":""),this.unicodeProperties=bue[t.options.ecmaVersion>=14?14:t.options.ecmaVersion],this.source="",this.flags="",this.start=0,this.switchU=!1,this.switchV=!1,this.switchN=!1,this.pos=0,this.lastIntValue=0,this.lastStringValue="",this.lastAssertionIsQuantifiable=!1,this.numCapturingParens=0,this.maxBackReference=0,this.groupNames=[],this.backReferenceNames=[]};ml.prototype.reset=function(t,n,r){var i=r.indexOf("v")!==-1,s=r.indexOf("u")!==-1;this.start=t|0,this.source=n+"",this.flags=r,i&&this.parser.options.ecmaVersion>=15?(this.switchU=!0,this.switchV=!0,this.switchN=!0):(this.switchU=s&&this.parser.options.ecmaVersion>=6,this.switchV=!1,this.switchN=s&&this.parser.options.ecmaVersion>=9)};ml.prototype.raise=function(t){this.parser.raiseRecoverable(this.start,"Invalid regular expression: /"+this.source+"/: "+t)};ml.prototype.at=function(t,n){n===void 0&&(n=!1);var r=this.source,i=r.length;if(t>=i)return-1;var s=r.charCodeAt(t);if(!(n||this.switchU)||s<=55295||s>=57344||t+1>=i)return s;var o=r.charCodeAt(t+1);return o>=56320&&o<=57343?(s<<10)+o-56613888:s};ml.prototype.nextIndex=function(t,n){n===void 0&&(n=!1);var r=this.source,i=r.length;if(t>=i)return i;var s=r.charCodeAt(t),o;return!(n||this.switchU)||s<=55295||s>=57344||t+1>=i||(o=r.charCodeAt(t+1))<56320||o>57343?t+1:t+2};ml.prototype.current=function(t){return t===void 0&&(t=!1),this.at(this.pos,t)};ml.prototype.lookahead=function(t){return t===void 0&&(t=!1),this.at(this.nextIndex(this.pos,t),t)};ml.prototype.advance=function(t){t===void 0&&(t=!1),this.pos=this.nextIndex(this.pos,t)};ml.prototype.eat=function(t,n){return n===void 0&&(n=!1),this.current(n)===t?(this.advance(n),!0):!1};ml.prototype.eatChars=function(t,n){n===void 0&&(n=!1);for(var r=this.pos,i=0,s=t;i-1&&this.raise(e.start,"Duplicate regular expression flag"),o==="u"&&(r=!0),o==="v"&&(i=!0)}this.options.ecmaVersion>=15&&r&&i&&this.raise(e.start,"Invalid regular expression flag")};Xe.validateRegExpPattern=function(e){this.regexp_pattern(e),!e.switchN&&this.options.ecmaVersion>=9&&e.groupNames.length>0&&(e.switchN=!0,this.regexp_pattern(e))};Xe.regexp_pattern=function(e){e.pos=0,e.lastIntValue=0,e.lastStringValue="",e.lastAssertionIsQuantifiable=!1,e.numCapturingParens=0,e.maxBackReference=0,e.groupNames.length=0,e.backReferenceNames.length=0,this.regexp_disjunction(e),e.pos!==e.source.length&&(e.eat(41)&&e.raise("Unmatched ')'"),(e.eat(93)||e.eat(125))&&e.raise("Lone quantifier brackets")),e.maxBackReference>e.numCapturingParens&&e.raise("Invalid escape");for(var t=0,n=e.backReferenceNames;t=9&&(n=e.eat(60)),e.eat(61)||e.eat(33))return this.regexp_disjunction(e),e.eat(41)||e.raise("Unterminated group"),e.lastAssertionIsQuantifiable=!n,!0}return e.pos=t,!1};Xe.regexp_eatQuantifier=function(e,t){return t===void 0&&(t=!1),this.regexp_eatQuantifierPrefix(e,t)?(e.eat(63),!0):!1};Xe.regexp_eatQuantifierPrefix=function(e,t){return e.eat(42)||e.eat(43)||e.eat(63)||this.regexp_eatBracedQuantifier(e,t)};Xe.regexp_eatBracedQuantifier=function(e,t){var n=e.pos;if(e.eat(123)){var r=0,i=-1;if(this.regexp_eatDecimalDigits(e)&&(r=e.lastIntValue,e.eat(44)&&this.regexp_eatDecimalDigits(e)&&(i=e.lastIntValue),e.eat(125)))return i!==-1&&i=9?this.regexp_groupSpecifier(e):e.current()===63&&e.raise("Invalid group"),this.regexp_disjunction(e),e.eat(41))return e.numCapturingParens+=1,!0;e.raise("Unterminated group")}return!1};Xe.regexp_eatExtendedAtom=function(e){return e.eat(46)||this.regexp_eatReverseSolidusAtomEscape(e)||this.regexp_eatCharacterClass(e)||this.regexp_eatUncapturingGroup(e)||this.regexp_eatCapturingGroup(e)||this.regexp_eatInvalidBracedQuantifier(e)||this.regexp_eatExtendedPatternCharacter(e)};Xe.regexp_eatInvalidBracedQuantifier=function(e){return this.regexp_eatBracedQuantifier(e,!0)&&e.raise("Nothing to repeat"),!1};Xe.regexp_eatSyntaxCharacter=function(e){var t=e.current();return wue(t)?(e.lastIntValue=t,e.advance(),!0):!1};function wue(e){return e===36||e>=40&&e<=43||e===46||e===63||e>=91&&e<=94||e>=123&&e<=125}Xe.regexp_eatPatternCharacters=function(e){for(var t=e.pos,n=0;(n=e.current())!==-1&&!wue(n);)e.advance();return e.pos!==t};Xe.regexp_eatExtendedPatternCharacter=function(e){var t=e.current();return t!==-1&&t!==36&&!(t>=40&&t<=43)&&t!==46&&t!==63&&t!==91&&t!==94&&t!==124?(e.advance(),!0):!1};Xe.regexp_groupSpecifier=function(e){if(e.eat(63)){if(this.regexp_eatGroupName(e)){e.groupNames.indexOf(e.lastStringValue)!==-1&&e.raise("Duplicate capture group name"),e.groupNames.push(e.lastStringValue);return}e.raise("Invalid group")}};Xe.regexp_eatGroupName=function(e){if(e.lastStringValue="",e.eat(60)){if(this.regexp_eatRegExpIdentifierName(e)&&e.eat(62))return!0;e.raise("Invalid capture group name")}return!1};Xe.regexp_eatRegExpIdentifierName=function(e){if(e.lastStringValue="",this.regexp_eatRegExpIdentifierStart(e)){for(e.lastStringValue+=jf(e.lastIntValue);this.regexp_eatRegExpIdentifierPart(e);)e.lastStringValue+=jf(e.lastIntValue);return!0}return!1};Xe.regexp_eatRegExpIdentifierStart=function(e){var t=e.pos,n=this.options.ecmaVersion>=11,r=e.current(n);return e.advance(n),r===92&&this.regexp_eatRegExpUnicodeEscapeSequence(e,n)&&(r=e.lastIntValue),wQe(r)?(e.lastIntValue=r,!0):(e.pos=t,!1)};function wQe(e){return tc(e,!0)||e===36||e===95}Xe.regexp_eatRegExpIdentifierPart=function(e){var t=e.pos,n=this.options.ecmaVersion>=11,r=e.current(n);return e.advance(n),r===92&&this.regexp_eatRegExpUnicodeEscapeSequence(e,n)&&(r=e.lastIntValue),EQe(r)?(e.lastIntValue=r,!0):(e.pos=t,!1)};function EQe(e){return ig(e,!0)||e===36||e===95||e===8204||e===8205}Xe.regexp_eatAtomEscape=function(e){return this.regexp_eatBackReference(e)||this.regexp_eatCharacterClassEscape(e)||this.regexp_eatCharacterEscape(e)||e.switchN&&this.regexp_eatKGroupName(e)?!0:(e.switchU&&(e.current()===99&&e.raise("Invalid unicode escape"),e.raise("Invalid escape")),!1)};Xe.regexp_eatBackReference=function(e){var t=e.pos;if(this.regexp_eatDecimalEscape(e)){var n=e.lastIntValue;if(e.switchU)return n>e.maxBackReference&&(e.maxBackReference=n),!0;if(n<=e.numCapturingParens)return!0;e.pos=t}return!1};Xe.regexp_eatKGroupName=function(e){if(e.eat(107)){if(this.regexp_eatGroupName(e))return e.backReferenceNames.push(e.lastStringValue),!0;e.raise("Invalid named reference")}return!1};Xe.regexp_eatCharacterEscape=function(e){return this.regexp_eatControlEscape(e)||this.regexp_eatCControlLetter(e)||this.regexp_eatZero(e)||this.regexp_eatHexEscapeSequence(e)||this.regexp_eatRegExpUnicodeEscapeSequence(e,!1)||!e.switchU&&this.regexp_eatLegacyOctalEscapeSequence(e)||this.regexp_eatIdentityEscape(e)};Xe.regexp_eatCControlLetter=function(e){var t=e.pos;if(e.eat(99)){if(this.regexp_eatControlLetter(e))return!0;e.pos=t}return!1};Xe.regexp_eatZero=function(e){return e.current()===48&&!eA(e.lookahead())?(e.lastIntValue=0,e.advance(),!0):!1};Xe.regexp_eatControlEscape=function(e){var t=e.current();return t===116?(e.lastIntValue=9,e.advance(),!0):t===110?(e.lastIntValue=10,e.advance(),!0):t===118?(e.lastIntValue=11,e.advance(),!0):t===102?(e.lastIntValue=12,e.advance(),!0):t===114?(e.lastIntValue=13,e.advance(),!0):!1};Xe.regexp_eatControlLetter=function(e){var t=e.current();return Eue(t)?(e.lastIntValue=t%32,e.advance(),!0):!1};function Eue(e){return e>=65&&e<=90||e>=97&&e<=122}Xe.regexp_eatRegExpUnicodeEscapeSequence=function(e,t){t===void 0&&(t=!1);var n=e.pos,r=t||e.switchU;if(e.eat(117)){if(this.regexp_eatFixedHexDigits(e,4)){var i=e.lastIntValue;if(r&&i>=55296&&i<=56319){var s=e.pos;if(e.eat(92)&&e.eat(117)&&this.regexp_eatFixedHexDigits(e,4)){var o=e.lastIntValue;if(o>=56320&&o<=57343)return e.lastIntValue=(i-55296)*1024+(o-56320)+65536,!0}e.pos=s,e.lastIntValue=i}return!0}if(r&&e.eat(123)&&this.regexp_eatHexDigits(e)&&e.eat(125)&&SQe(e.lastIntValue))return!0;r&&e.raise("Invalid unicode escape"),e.pos=n}return!1};function SQe(e){return e>=0&&e<=1114111}Xe.regexp_eatIdentityEscape=function(e){if(e.switchU)return this.regexp_eatSyntaxCharacter(e)?!0:e.eat(47)?(e.lastIntValue=47,!0):!1;var t=e.current();return t!==99&&(!e.switchN||t!==107)?(e.lastIntValue=t,e.advance(),!0):!1};Xe.regexp_eatDecimalEscape=function(e){e.lastIntValue=0;var t=e.current();if(t>=49&&t<=57){do e.lastIntValue=10*e.lastIntValue+(t-48),e.advance();while((t=e.current())>=48&&t<=57);return!0}return!1};var Sue=0,nc=1,Qo=2;Xe.regexp_eatCharacterClassEscape=function(e){var t=e.current();if(TQe(t))return e.lastIntValue=-1,e.advance(),nc;var n=!1;if(e.switchU&&this.options.ecmaVersion>=9&&((n=t===80)||t===112)){e.lastIntValue=-1,e.advance();var r;if(e.eat(123)&&(r=this.regexp_eatUnicodePropertyValueExpression(e))&&e.eat(125))return n&&r===Qo&&e.raise("Invalid property name"),r;e.raise("Invalid property name")}return Sue};function TQe(e){return e===100||e===68||e===115||e===83||e===119||e===87}Xe.regexp_eatUnicodePropertyValueExpression=function(e){var t=e.pos;if(this.regexp_eatUnicodePropertyName(e)&&e.eat(61)){var n=e.lastStringValue;if(this.regexp_eatUnicodePropertyValue(e)){var r=e.lastStringValue;return this.regexp_validateUnicodePropertyNameAndValue(e,n,r),nc}}if(e.pos=t,this.regexp_eatLoneUnicodePropertyNameOrValue(e)){var i=e.lastStringValue;return this.regexp_validateUnicodePropertyNameOrValue(e,i)}return Sue};Xe.regexp_validateUnicodePropertyNameAndValue=function(e,t,n){c1(e.unicodeProperties.nonBinary,t)||e.raise("Invalid property name"),e.unicodeProperties.nonBinary[t].test(n)||e.raise("Invalid property value")};Xe.regexp_validateUnicodePropertyNameOrValue=function(e,t){if(e.unicodeProperties.binary.test(t))return nc;if(e.switchV&&e.unicodeProperties.binaryOfStrings.test(t))return Qo;e.raise("Invalid property name")};Xe.regexp_eatUnicodePropertyName=function(e){var t=0;for(e.lastStringValue="";Tue(t=e.current());)e.lastStringValue+=jf(t),e.advance();return e.lastStringValue!==""};function Tue(e){return Eue(e)||e===95}Xe.regexp_eatUnicodePropertyValue=function(e){var t=0;for(e.lastStringValue="";IQe(t=e.current());)e.lastStringValue+=jf(t),e.advance();return e.lastStringValue!==""};function IQe(e){return Tue(e)||eA(e)}Xe.regexp_eatLoneUnicodePropertyNameOrValue=function(e){return this.regexp_eatUnicodePropertyValue(e)};Xe.regexp_eatCharacterClass=function(e){if(e.eat(91)){var t=e.eat(94),n=this.regexp_classContents(e);return e.eat(93)||e.raise("Unterminated character class"),t&&n===Qo&&e.raise("Negated character class may contain strings"),!0}return!1};Xe.regexp_classContents=function(e){return e.current()===93?nc:e.switchV?this.regexp_classSetExpression(e):(this.regexp_nonEmptyClassRanges(e),nc)};Xe.regexp_nonEmptyClassRanges=function(e){for(;this.regexp_eatClassAtom(e);){var t=e.lastIntValue;if(e.eat(45)&&this.regexp_eatClassAtom(e)){var n=e.lastIntValue;e.switchU&&(t===-1||n===-1)&&e.raise("Invalid character class"),t!==-1&&n!==-1&&t>n&&e.raise("Range out of order in character class")}}};Xe.regexp_eatClassAtom=function(e){var t=e.pos;if(e.eat(92)){if(this.regexp_eatClassEscape(e))return!0;if(e.switchU){var n=e.current();(n===99||Cue(n))&&e.raise("Invalid class escape"),e.raise("Invalid escape")}e.pos=t}var r=e.current();return r!==93?(e.lastIntValue=r,e.advance(),!0):!1};Xe.regexp_eatClassEscape=function(e){var t=e.pos;if(e.eat(98))return e.lastIntValue=8,!0;if(e.switchU&&e.eat(45))return e.lastIntValue=45,!0;if(!e.switchU&&e.eat(99)){if(this.regexp_eatClassControlLetter(e))return!0;e.pos=t}return this.regexp_eatCharacterClassEscape(e)||this.regexp_eatCharacterEscape(e)};Xe.regexp_classSetExpression=function(e){var t=nc,n;if(!this.regexp_eatClassSetRange(e))if(n=this.regexp_eatClassSetOperand(e)){n===Qo&&(t=Qo);for(var r=e.pos;e.eatChars([38,38]);){if(e.current()!==38&&(n=this.regexp_eatClassSetOperand(e))){n!==Qo&&(t=nc);continue}e.raise("Invalid character in character class")}if(r!==e.pos)return t;for(;e.eatChars([45,45]);)this.regexp_eatClassSetOperand(e)||e.raise("Invalid character in character class");if(r!==e.pos)return t}else e.raise("Invalid character in character class");for(;;)if(!this.regexp_eatClassSetRange(e)){if(n=this.regexp_eatClassSetOperand(e),!n)return t;n===Qo&&(t=Qo)}};Xe.regexp_eatClassSetRange=function(e){var t=e.pos;if(this.regexp_eatClassSetCharacter(e)){var n=e.lastIntValue;if(e.eat(45)&&this.regexp_eatClassSetCharacter(e)){var r=e.lastIntValue;return n!==-1&&r!==-1&&n>r&&e.raise("Range out of order in character class"),!0}e.pos=t}return!1};Xe.regexp_eatClassSetOperand=function(e){return this.regexp_eatClassSetCharacter(e)?nc:this.regexp_eatClassStringDisjunction(e)||this.regexp_eatNestedClass(e)};Xe.regexp_eatNestedClass=function(e){var t=e.pos;if(e.eat(91)){var n=e.eat(94),r=this.regexp_classContents(e);if(e.eat(93))return n&&r===Qo&&e.raise("Negated character class may contain strings"),r;e.pos=t}if(e.eat(92)){var i=this.regexp_eatCharacterClassEscape(e);if(i)return i;e.pos=t}return null};Xe.regexp_eatClassStringDisjunction=function(e){var t=e.pos;if(e.eatChars([92,113])){if(e.eat(123)){var n=this.regexp_classStringDisjunctionContents(e);if(e.eat(125))return n}else e.raise("Invalid escape");e.pos=t}return null};Xe.regexp_classStringDisjunctionContents=function(e){for(var t=this.regexp_classString(e);e.eat(124);)this.regexp_classString(e)===Qo&&(t=Qo);return t};Xe.regexp_classString=function(e){for(var t=0;this.regexp_eatClassSetCharacter(e);)t++;return t===1?nc:Qo};Xe.regexp_eatClassSetCharacter=function(e){var t=e.pos;if(e.eat(92))return this.regexp_eatCharacterEscape(e)||this.regexp_eatClassSetReservedPunctuator(e)?!0:e.eat(98)?(e.lastIntValue=8,!0):(e.pos=t,!1);var n=e.current();return n<0||n===e.lookahead()&&xQe(n)||CQe(n)?!1:(e.advance(),e.lastIntValue=n,!0)};function xQe(e){return e===33||e>=35&&e<=38||e>=42&&e<=44||e===46||e>=58&&e<=64||e===94||e===96||e===126}function CQe(e){return e===40||e===41||e===45||e===47||e>=91&&e<=93||e>=123&&e<=125}Xe.regexp_eatClassSetReservedPunctuator=function(e){var t=e.current();return AQe(t)?(e.lastIntValue=t,e.advance(),!0):!1};function AQe(e){return e===33||e===35||e===37||e===38||e===44||e===45||e>=58&&e<=62||e===64||e===96||e===126}Xe.regexp_eatClassControlLetter=function(e){var t=e.current();return eA(t)||t===95?(e.lastIntValue=t%32,e.advance(),!0):!1};Xe.regexp_eatHexEscapeSequence=function(e){var t=e.pos;if(e.eat(120)){if(this.regexp_eatFixedHexDigits(e,2))return!0;e.switchU&&e.raise("Invalid escape"),e.pos=t}return!1};Xe.regexp_eatDecimalDigits=function(e){var t=e.pos,n=0;for(e.lastIntValue=0;eA(n=e.current());)e.lastIntValue=10*e.lastIntValue+(n-48),e.advance();return e.pos!==t};function eA(e){return e>=48&&e<=57}Xe.regexp_eatHexDigits=function(e){var t=e.pos,n=0;for(e.lastIntValue=0;Iue(n=e.current());)e.lastIntValue=16*e.lastIntValue+xue(n),e.advance();return e.pos!==t};function Iue(e){return e>=48&&e<=57||e>=65&&e<=70||e>=97&&e<=102}function xue(e){return e>=65&&e<=70?10+(e-65):e>=97&&e<=102?10+(e-97):e-48}Xe.regexp_eatLegacyOctalEscapeSequence=function(e){if(this.regexp_eatOctalDigit(e)){var t=e.lastIntValue;if(this.regexp_eatOctalDigit(e)){var n=e.lastIntValue;t<=3&&this.regexp_eatOctalDigit(e)?e.lastIntValue=t*64+n*8+e.lastIntValue:e.lastIntValue=t*8+n}else e.lastIntValue=t;return!0}return!1};Xe.regexp_eatOctalDigit=function(e){var t=e.current();return Cue(t)?(e.lastIntValue=t-48,e.advance(),!0):(e.lastIntValue=0,!1)};function Cue(e){return e>=48&&e<=55}Xe.regexp_eatFixedHexDigits=function(e,t){var n=e.pos;e.lastIntValue=0;for(var r=0;r=this.input.length)return this.finishToken(D.eof);if(e.override)return e.override(this);this.readToken(this.fullCharCodeAtPos())};rn.readToken=function(e){return tc(e,this.options.ecmaVersion>=6)||e===92?this.readWord():this.getTokenFromCode(e)};rn.fullCharCodeAtPos=function(){var e=this.input.charCodeAt(this.pos);if(e<=55295||e>=56320)return e;var t=this.input.charCodeAt(this.pos+1);return t<=56319||t>=57344?e:(e<<10)+t-56613888};rn.skipBlockComment=function(){var e=this.options.onComment&&this.curPosition(),t=this.pos,n=this.input.indexOf("*/",this.pos+=2);if(n===-1&&this.raise(this.pos-2,"Unterminated comment"),this.pos=n+2,this.options.locations)for(var r=void 0,i=t;(r=Qae(this.input,i,this.pos))>-1;)++this.curLine,i=this.lineStart=r;this.options.onComment&&this.options.onComment(!0,this.input.slice(t+2,n),t,this.pos,e,this.curPosition())};rn.skipLineComment=function(e){for(var t=this.pos,n=this.options.onComment&&this.curPosition(),r=this.input.charCodeAt(this.pos+=e);this.pos8&&e<14||e>=5760&&Xae.test(String.fromCharCode(e)))++this.pos;else break e}}};rn.finishToken=function(e,t){this.end=this.pos,this.options.locations&&(this.endLoc=this.curPosition());var n=this.type;this.type=e,this.value=t,this.updateContext(n)};rn.readToken_dot=function(){var e=this.input.charCodeAt(this.pos+1);if(e>=48&&e<=57)return this.readNumber(!0);var t=this.input.charCodeAt(this.pos+2);return this.options.ecmaVersion>=6&&e===46&&t===46?(this.pos+=3,this.finishToken(D.ellipsis)):(++this.pos,this.finishToken(D.dot))};rn.readToken_slash=function(){var e=this.input.charCodeAt(this.pos+1);return this.exprAllowed?(++this.pos,this.readRegexp()):e===61?this.finishOp(D.assign,2):this.finishOp(D.slash,1)};rn.readToken_mult_modulo_exp=function(e){var t=this.input.charCodeAt(this.pos+1),n=1,r=e===42?D.star:D.modulo;return this.options.ecmaVersion>=7&&e===42&&t===42&&(++n,r=D.starstar,t=this.input.charCodeAt(this.pos+2)),t===61?this.finishOp(D.assign,n+1):this.finishOp(r,n)};rn.readToken_pipe_amp=function(e){var t=this.input.charCodeAt(this.pos+1);if(t===e){if(this.options.ecmaVersion>=12){var n=this.input.charCodeAt(this.pos+2);if(n===61)return this.finishOp(D.assign,3)}return this.finishOp(e===124?D.logicalOR:D.logicalAND,2)}return t===61?this.finishOp(D.assign,2):this.finishOp(e===124?D.bitwiseOR:D.bitwiseAND,1)};rn.readToken_caret=function(){var e=this.input.charCodeAt(this.pos+1);return e===61?this.finishOp(D.assign,2):this.finishOp(D.bitwiseXOR,1)};rn.readToken_plus_min=function(e){var t=this.input.charCodeAt(this.pos+1);return t===e?t===45&&!this.inModule&&this.input.charCodeAt(this.pos+2)===62&&(this.lastTokEnd===0||va.test(this.input.slice(this.lastTokEnd,this.pos)))?(this.skipLineComment(3),this.skipSpace(),this.nextToken()):this.finishOp(D.incDec,2):t===61?this.finishOp(D.assign,2):this.finishOp(D.plusMin,1)};rn.readToken_lt_gt=function(e){var t=this.input.charCodeAt(this.pos+1),n=1;return t===e?(n=e===62&&this.input.charCodeAt(this.pos+2)===62?3:2,this.input.charCodeAt(this.pos+n)===61?this.finishOp(D.assign,n+1):this.finishOp(D.bitShift,n)):t===33&&e===60&&!this.inModule&&this.input.charCodeAt(this.pos+2)===45&&this.input.charCodeAt(this.pos+3)===45?(this.skipLineComment(4),this.skipSpace(),this.nextToken()):(t===61&&(n=2),this.finishOp(D.relational,n))};rn.readToken_eq_excl=function(e){var t=this.input.charCodeAt(this.pos+1);return t===61?this.finishOp(D.equality,this.input.charCodeAt(this.pos+2)===61?3:2):e===61&&t===62&&this.options.ecmaVersion>=6?(this.pos+=2,this.finishToken(D.arrow)):this.finishOp(e===61?D.eq:D.prefix,1)};rn.readToken_question=function(){var e=this.options.ecmaVersion;if(e>=11){var t=this.input.charCodeAt(this.pos+1);if(t===46){var n=this.input.charCodeAt(this.pos+2);if(n<48||n>57)return this.finishOp(D.questionDot,2)}if(t===63){if(e>=12){var r=this.input.charCodeAt(this.pos+2);if(r===61)return this.finishOp(D.assign,3)}return this.finishOp(D.coalesce,2)}}return this.finishOp(D.question,1)};rn.readToken_numberSign=function(){var e=this.options.ecmaVersion,t=35;if(e>=13&&(++this.pos,t=this.fullCharCodeAtPos(),tc(t,!0)||t===92))return this.finishToken(D.privateId,this.readWord1());this.raise(this.pos,"Unexpected character '"+jf(t)+"'")};rn.getTokenFromCode=function(e){switch(e){case 46:return this.readToken_dot();case 40:return++this.pos,this.finishToken(D.parenL);case 41:return++this.pos,this.finishToken(D.parenR);case 59:return++this.pos,this.finishToken(D.semi);case 44:return++this.pos,this.finishToken(D.comma);case 91:return++this.pos,this.finishToken(D.bracketL);case 93:return++this.pos,this.finishToken(D.bracketR);case 123:return++this.pos,this.finishToken(D.braceL);case 125:return++this.pos,this.finishToken(D.braceR);case 58:return++this.pos,this.finishToken(D.colon);case 96:if(this.options.ecmaVersion<6)break;return++this.pos,this.finishToken(D.backQuote);case 48:var t=this.input.charCodeAt(this.pos+1);if(t===120||t===88)return this.readRadixNumber(16);if(this.options.ecmaVersion>=6){if(t===111||t===79)return this.readRadixNumber(8);if(t===98||t===66)return this.readRadixNumber(2)}case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:return this.readNumber(!1);case 34:case 39:return this.readString(e);case 47:return this.readToken_slash();case 37:case 42:return this.readToken_mult_modulo_exp(e);case 124:case 38:return this.readToken_pipe_amp(e);case 94:return this.readToken_caret();case 43:case 45:return this.readToken_plus_min(e);case 60:case 62:return this.readToken_lt_gt(e);case 61:case 33:return this.readToken_eq_excl(e);case 63:return this.readToken_question();case 126:return this.finishOp(D.prefix,1);case 35:return this.readToken_numberSign()}this.raise(this.pos,"Unexpected character '"+jf(e)+"'")};rn.finishOp=function(e,t){var n=this.input.slice(this.pos,this.pos+t);return this.pos+=t,this.finishToken(e,n)};rn.readRegexp=function(){for(var e,t,n=this.pos;;){this.pos>=this.input.length&&this.raise(n,"Unterminated regular expression");var r=this.input.charAt(this.pos);if(va.test(r)&&this.raise(n,"Unterminated regular expression"),e)e=!1;else{if(r==="[")t=!0;else if(r==="]"&&t)t=!1;else if(r==="/"&&!t)break;e=r==="\\"}++this.pos}var i=this.input.slice(n,this.pos);++this.pos;var s=this.pos,o=this.readWord1();this.containsEsc&&this.unexpected(s);var a=this.regexpState||(this.regexpState=new ml(this));a.reset(n,i,o),this.validateRegExpFlags(a),this.validateRegExpPattern(a);var u=null;try{u=new RegExp(i,o)}catch{}return this.finishToken(D.regexp,{pattern:i,flags:o,value:u})};rn.readInt=function(e,t,n){for(var r=this.options.ecmaVersion>=12&&t===void 0,i=n&&this.input.charCodeAt(this.pos)===48,s=this.pos,o=0,a=0,u=0,l=t??1/0;u=97?f=c-97+10:c>=65?f=c-65+10:c>=48&&c<=57?f=c-48:f=1/0,f>=e)break;a=c,o=o*e+f}return r&&a===95&&this.raiseRecoverable(this.pos-1,"Numeric separator is not allowed at the last of digits"),this.pos===s||t!=null&&this.pos-s!==t?null:o};function PQe(e,t){return t?parseInt(e,8):parseFloat(e.replace(/_/g,""))}function Aue(e){return typeof BigInt!="function"?null:BigInt(e.replace(/_/g,""))}rn.readRadixNumber=function(e){var t=this.pos;this.pos+=2;var n=this.readInt(e);return n==null&&this.raise(this.start+2,"Expected number in radix "+e),this.options.ecmaVersion>=11&&this.input.charCodeAt(this.pos)===110?(n=Aue(this.input.slice(t,this.pos)),++this.pos):tc(this.fullCharCodeAtPos())&&this.raise(this.pos,"Identifier directly after number"),this.finishToken(D.num,n)};rn.readNumber=function(e){var t=this.pos;!e&&this.readInt(10,void 0,!0)===null&&this.raise(t,"Invalid number");var n=this.pos-t>=2&&this.input.charCodeAt(t)===48;n&&this.strict&&this.raise(t,"Invalid number");var r=this.input.charCodeAt(this.pos);if(!n&&!e&&this.options.ecmaVersion>=11&&r===110){var i=Aue(this.input.slice(t,this.pos));return++this.pos,tc(this.fullCharCodeAtPos())&&this.raise(this.pos,"Identifier directly after number"),this.finishToken(D.num,i)}n&&/[89]/.test(this.input.slice(t,this.pos))&&(n=!1),r===46&&!n&&(++this.pos,this.readInt(10),r=this.input.charCodeAt(this.pos)),(r===69||r===101)&&!n&&(r=this.input.charCodeAt(++this.pos),(r===43||r===45)&&++this.pos,this.readInt(10)===null&&this.raise(t,"Invalid number")),tc(this.fullCharCodeAtPos())&&this.raise(this.pos,"Identifier directly after number");var s=PQe(this.input.slice(t,this.pos),n);return this.finishToken(D.num,s)};rn.readCodePoint=function(){var e=this.input.charCodeAt(this.pos),t;if(e===123){this.options.ecmaVersion<6&&this.unexpected();var n=++this.pos;t=this.readHexChar(this.input.indexOf("}",this.pos)-this.pos),++this.pos,t>1114111&&this.invalidStringToken(n,"Code point out of bounds")}else t=this.readHexChar(4);return t};rn.readString=function(e){for(var t="",n=++this.pos;;){this.pos>=this.input.length&&this.raise(this.start,"Unterminated string constant");var r=this.input.charCodeAt(this.pos);if(r===e)break;r===92?(t+=this.input.slice(n,this.pos),t+=this.readEscapedChar(!1),n=this.pos):r===8232||r===8233?(this.options.ecmaVersion<10&&this.raise(this.start,"Unterminated string constant"),++this.pos,this.options.locations&&(this.curLine++,this.lineStart=this.pos)):(Fg(r)&&this.raise(this.start,"Unterminated string constant"),++this.pos)}return t+=this.input.slice(n,this.pos++),this.finishToken(D.string,t)};var Pue={};rn.tryReadTemplateToken=function(){this.inTemplateElement=!0;try{this.readTmplToken()}catch(e){if(e===Pue)this.readInvalidTemplateToken();else throw e}this.inTemplateElement=!1};rn.invalidStringToken=function(e,t){if(this.inTemplateElement&&this.options.ecmaVersion>=9)throw Pue;this.raise(e,t)};rn.readTmplToken=function(){for(var e="",t=this.pos;;){this.pos>=this.input.length&&this.raise(this.start,"Unterminated template");var n=this.input.charCodeAt(this.pos);if(n===96||n===36&&this.input.charCodeAt(this.pos+1)===123)return this.pos===this.start&&(this.type===D.template||this.type===D.invalidTemplate)?n===36?(this.pos+=2,this.finishToken(D.dollarBraceL)):(++this.pos,this.finishToken(D.backQuote)):(e+=this.input.slice(t,this.pos),this.finishToken(D.template,e));if(n===92)e+=this.input.slice(t,this.pos),e+=this.readEscapedChar(!0),t=this.pos;else if(Fg(n)){switch(e+=this.input.slice(t,this.pos),++this.pos,n){case 13:this.input.charCodeAt(this.pos)===10&&++this.pos;case 10:e+=` `;break;default:e+=String.fromCharCode(n);break}this.options.locations&&(++this.curLine,this.lineStart=this.pos),t=this.pos}else++this.pos}};rn.readInvalidTemplateToken=function(){for(;this.pos=48&&t<=55){var r=this.input.substr(this.pos-1,3).match(/^[0-7]+/)[0],i=parseInt(r,8);return i>255&&(r=r.slice(0,-1),i=parseInt(r,8)),this.pos+=r.length-1,t=this.input.charCodeAt(this.pos),(r!=="0"||t===56||t===57)&&(this.strict||e)&&this.invalidStringToken(this.pos-1-r.length,e?"Octal literal in template string":"Octal literal in strict mode"),String.fromCharCode(i)}return Fg(t)?"":String.fromCharCode(t)}};rn.readHexChar=function(e){var t=this.pos,n=this.readInt(16,e);return n===null&&this.invalidStringToken(t,"Bad character escape sequence"),n};rn.readWord1=function(){this.containsEsc=!1;for(var e="",t=!0,n=this.pos,r=this.options.ecmaVersion>=6;this.pos(t,n)=>n.error(t,e+" not allowed"),$Qe=Ai("Aggregate function"),LQe=Ai("Window function"),MQe="Invalid argument",iM="Invalid column reference",FQe=iM+" (must be input to an aggregate function)",Oue="Invalid function call",BQe="Invalid member expression",jQe="Invalid operator parameter",UQe="Invalid param reference",VQe="Invalid variable reference",zQe="Variable not accessible in operator call",HQe="Unsupported variable declaration",WQe="Unsupported destructuring pattern",Rue="Table expressions do not support closures",Nue="Use aq.escape(fn) to use a function as-is (including closures)",qQe="use table.params({ name: value }) to define dynamic parameters",GQe="use aq.addFunction(name, fn) to add new op functions",YQe=` -Note: ${Rue}. ${Nue}, or ${qQe}.`,kue=` -Note: ${Rue}. ${Nue}, or ${GQe}.`,KQe=`The ${kse} method is not valid in multi-table expressions.`;function QQe(e,t){const n=XQe(t);let r=e.root=n;return e.spec=t,e.tuple=null,e.tuple1=null,e.tuple2=null,e.$param=null,e.$op=0,e.scope=new Set,e.paramsRef=new Map,e.columnRef=new Map,HKe(r)?(ZQe(r,e),r=r.body):e.join?(e.scope.add(e.tuple1=kQe),e.scope.add(e.tuple2=DQe),e.scope.add(e.$param=tH)):(e.scope.add(e.tuple=NQe),e.scope.add(e.$param=tH)),pn(r,e,sM),e.root}function XQe(e){try{const t=e.field?JQe(e):En(e)?el(e):e;return OQe(`expr=(${t})`,RQe).body[0].expression.right}catch{Wt(`Expression parse error: ${e+""}`)}}function JQe(e){const t=JSON.stringify(e+"");return e.table?`(a,b)=>b[${t}]`:`d=>d[${t}]`}const sM={FunctionDeclaration:Ai("Function definitions"),ForStatement:Ai("For loops"),ForOfStatement:Ai("For-of loops"),ForInStatement:Ai("For-in loops"),WhileStatement:Ai("While loops"),DoWhileStatement:Ai("Do-while loops"),AwaitExpression:Ai("Await expressions"),ArrowFunctionExpression:Ai("Function definitions"),AssignmentExpression:Ai("Assignments"),FunctionExpression:Ai("Function definitions"),NewExpression:Ai('Use of "new"'),UpdateExpression:Ai("Update expressions"),VariableDeclarator(e,t){Sk(e.id,t)},Identifier(e,t,n){Lue(e,t,n)&&!t.scope.has(e.name)&&t.error(e,VQe,YQe)},CallExpression(e,t){const n=Due(e.callee),r=Ose(n)||Rse(n);if(r){if((t.join||t.aggregate===!1)&&G6(n)&&$Qe(e,t),(t.join||t.window===!1)&&Y6(n)&&LQe(e,t),t.$op=1,t.ast)Ek(e,n,t),e.arguments.forEach(i=>pn(i,t,wk));else{const i=t.op(eXe(t,r,n,e.arguments));Object.assign(e,{type:Ise,name:i.id})}return t.$op=0,!1}else Pse(n)?Ek(e,n,t):t.error(e,Oue,kue)},MemberExpression(e,t,n){const{object:r,property:i}=e;if(!ti(vf,r))return;const{name:s}=r;if($ue(e)&&ti(vf,i)&&Ya(rM,i.name)){Bue(e,i.name);return}const o=s===t.tuple?0:s===t.tuple1?1:s===t.tuple2?2:-1;if(o>=0)return nH(e,o,t,Mue,n);if(s===t.$param)return nH(e,o,t,nXe);t.paramsRef.has(s)?Wv(e,t.paramsRef.get(s)):t.columnRef.has(s)?Fue(r,s,t,e):Ya(t.params,s)&&Wv(r,s)}};function nH(e,t,n,r,i){const{property:s,computed:o}=e;let a;if(!o)a=s.name;else if(ti(kg,s))a=s.value;else try{pn(s,n,sM,e),a=n.param(s)}catch{n.error(e,BQe)}return r(e,a,t,n,i),!1}const wk={...sM,VariableDeclarator:Ai("Variable declaration in operator call"),Identifier(e,t,n){Lue(e,t,n)&&t.error(e,zQe)},CallExpression(e,t){const n=Due(e.callee);Pse(n)?Ek(e,n,t):t.error(e,Oue,kue)}};function ZQe(e,t){e.generator&&Ai("Generator functions")(e,t),e.async&&Ai("Async functions")(e,t);const{params:n}=e,r=n.length,i=o=>(a,u)=>t.columnRef.set(a,[u,o]),s=(o,a)=>t.paramsRef.set(o,a);r&&(t.join?(D0(t,n[0],"tuple1",i(1)),r>1&&D0(t,n[1],"tuple2",i(2)),r>2&&D0(t,n[2],"$param",s)):(D0(t,n[0],"tuple",i(0)),r>1&&D0(t,n[1],"$param",s))),t.root=e.body}function D0(e,t,n,r){ti(vf,t)?(e.scope.add(t.name),e[n]=t.name):ti(Sse,t)&&t.properties.forEach(i=>{const s=ti(vf,i.key)?i.key.name:ti(kg,i.key)?i.key.value:e.error(i,MQe);ti(vf,i.value)||e.error(i.value,WQe),r(i.value.name,s)})}function eXe(e,t,n,r){const i=[],s=[],o=t.param[0]||0,a=o+(t.param[1]||0);return r.forEach((u,l)=>{l0?r.join[n-1]:null,o=s&&s.column(t);s&&!o&&r.error(e,iM),r.aggronly&&!r.$op&&r.error(e,FQe),Nse(e,t,n,o,i)}function Fue(e,t,n,r){const[i,s]=n.columnRef.get(t);Mue(e,i,s,n,r)}function nXe(e,t,n,r){r.params&&!Ya(r.params,t)&&r.error(e,UQe),Wv(e,t)}function Wv(e,t){e.type=WWe,e.name=t}function Bue(e,t){e.type=VWe,e.name=t,e.raw=rM[t]}function Ek(e,t,n){if(t===kse){const r=n.table;r||n.error(e,KQe),Dse(e,e.arguments.length?e.arguments.map(i=>{const s=n.param(i),o=bs(s)?r.columnName(s):s;return r.column(o)||n.error(i,iM),o}):r.columnNames())}else e.callee={type:HWe,name:t}}function Sk(e,t){ti(vf,e)?t.scope.add(e.name):ti(FWe,e)?e.elements.forEach(n=>Sk(n,t)):ti(Sse,e)?e.properties.forEach(n=>Sk(n.value,t)):t.error(e.id,HQe)}const rXe={[i1]:1,[Ise]:1};function ao(e,t={}){const n=t.generate||iI,r=t.compiler||K6,i=sXe(t),s={},o={},a=[],u=[];let l=0,c=-1;const f=t.join?r.join:t.index==1?r.expr2:r.expr,d={op(m){const y=iXe(m);return o[y]||(m.id=++c,o[y]=m)},field(m){const y=n(m);return s[y]||(s[y]=++l)},param(m){return ti(kg,m)?m.value:r.param(n(m),i)},value(m,y){a.push(m);const g=y.escape||(t.ast?zKe(y):f(n(y),i));u.push(g),rXe[y.type]&&g!==y&&as(g)&&(g.field=y.name)},error(m,y,g=""){const v=m.start-6,b=m.end-6,S=String(d.spec).slice(v,b);Wt(`${y}: "${S}"${g}`)}};Object.assign(d,t,{params:i});for(const[m,y]of MC(e))d.value(m+"",y.escape?GKe(d,y,i):QQe(d,y));if(t.ast)return{names:a,exprs:u};const h=[];for(const m in s)h[s[m]]=r.expr(m,i);const p=Object.values(o);return p.forEach(m=>m.fields=m.fields.map(y=>h[y])),{names:a,exprs:u,ops:p}}function iXe(e){let t=`${e.name}(${e.fields.concat(e.params).join(",")})`;if(e.frame){const n=e.frame.map(r=>Number.isFinite(r)?Math.abs(r):-1);t+=`[${n},${!!e.peers}]`}return t}function sXe(e){return(e.table?l2(e.table):e.join?{...l2(e.join[1]),...l2(e.join[0])}:{})||{}}function l2(e){return e&&sr(e.params)?e.params():{}}const jue="Expr",xa="ExprList",Uue="ExprNumber",ry="ExprObject",jp="JoinKeys",CI="JoinValues",Vo="Options",oM="OrderKeys",Nc="SelectionList",Ad="TableRef",Up="TableRefList",oXe="Descending",aXe="Query",uXe="Selection",lXe="Verb",cXe="Window";function tA(e,t){return e&&e.expr?new rH({...e,...t}):new rH(t,e)}class rH{constructor(t,n){this.expr=n,Object.assign(this,t)}toString(){return String(this.expr)}toObject(){return{...this,expr:this.toString(),...sr(this.expr)?{func:!0}:{}}}}function fXe(e){return tA(e,{desc:!0})}function _h(e,t,n=0){const r=n?{field:!0,table:n}:{field:!0};return tA(e,t?{expr:t,...r}:r)}function dXe(e,t,n){return tA(e,{window:{frame:t||[-1/0,0],peers:!!n}})}function hXe(e){const t=n=>n;return t.toString=()=>e,t}function iH(e,t){return t=t&&sr(t.query)?t.query():t,t&&sr(t.evaluate)?t.evaluate(null,e):e(t)}function Vue(e){return as(e)&&(En(e.all)||En(e.matches)||En(e.not)||En(e.range))}function qv(e){return e&&sr(e.toObject)?e.toObject():sr(e)?{expr:String(e),func:!0}:En(e)?e.map(qv):as(e)?KC(e,t=>qv(t)):e}function aM(e){return En(e)?e.map(aM):as(e)?En(e.verbs)?lM.from(e):En(e.all)?rg():En(e.range)?FKe(...e.range):En(e.match)?BKe(RegExp(...e.match)):En(e.not)?qae(e.not.map(qv)):pXe(e):e}function pXe(e){let t=e,n=e.expr;if(n!=null){if(e.field===!0?t=n=_h(n):e.func===!0&&(t=n=hXe(n)),as(e.window)){const{frame:r,peers:i}=e.window;t=n=dXe(n,r,i)}e.desc===!0&&(t=fXe(n))}return e===t?KC(e,r=>aM(r)):t}function mXe(e){return En(e)?e.map(gXe):e}function gXe(e){const t=[];return io(e).forEach(n=>{bs(n)?t.push(n):Ui(n)?t.push(_h(n,null)):as(n)&&n.expr||sr(n)?t.push(n):Wt(`Invalid key value: ${n+""}`)}),t}function yXe(e){return En(e)?e.map(vXe):e}function vXe(e,t){return t<2?io(e):e}function _Xe(e){const t=[];return e.forEach(n=>{const r=n.expr!=null?n.expr:n;if(as(r)&&!sr(r))for(const i in r)t.push(r[i]);else n=bs(r)?r:Ui(r)?_h(n):sr(r)?n:Wt(`Invalid orderby field: ${n+""}`),t.push(n)}),t}const bXe={[jue]:que,[xa]:sg,[Uue]:xXe,[ry]:Uf,[jp]:CXe,[CI]:AXe,[oM]:sg,[Nc]:TXe};function wXe(e,t,n){return t===Ad?sH(e):t===Up?e.map(sH):zue(qv(e),t,n)}function zue(e,t,n){return t===Vo?e&&EXe(e,n):bXe[t](e)}function EXe(e,t={}){const n={};for(const r in e){const i=e[r];n[r]=t[r]?zue(i,t[r]):i}return n}function SXe(e,t){return ao({expr:e},{...t,ast:!0}).exprs[0]}function uM(e){return{type:i1,name:e}}function Hue(e){return{type:i1,index:e}}function Uf(e,t){if(Ui(e))return SXe(e,t);if(e.expr){let n;if(e.field===!0?n=uM(e.expr):e.func===!0&&(n=Uf(e.expr,t)),n)return e.desc&&(n={type:oXe,expr:n}),e.window&&(n={type:cXe,expr:n,...e.window}),n}return Object.keys(e).map(n=>({...Uf(e[n],t),as:n}))}function Wue(e){const t=uXe;return e.all?{type:t,operator:"all"}:e.not?{type:t,operator:"not",arguments:sg(e.not)}:e.range?{type:t,operator:"range",arguments:sg(e.range)}:e.matches?{type:t,operator:"matches",arguments:e.matches}:Wt("Invalid input")}function TXe(e){return io(e).map(IXe).flat()}function IXe(e){return Vue(e)?Wue(e):bs(e)?Hue(e):Ui(e)?uM(e):as(e)?Object.keys(e).map(t=>({type:i1,name:t,as:e[t]})):Wt("Invalid input")}function que(e){return Vue(e)?Wue(e):bs(e)?Hue(e):Ui(e)?uM(e):as(e)?Uf(e):Wt("Invalid input")}function sg(e){return io(e).map(que).flat()}function xXe(e){return bs(e)?e:Uf(e)}function CXe(e){return En(e)?e.map(sg):Uf(e,{join:!0})}function AXe(e){return En(e)?e.map((t,n)=>n<2?sg(t):Uf(t,{join:!0})):Uf(e,{join:!0})}function sH(e){return e&&sr(e.toAST)?e.toAST():e}class Gue{constructor(t,n=[],r=[]){this.verb=t,this.schema=n,n.forEach((i,s)=>{const o=i.type,a=r[s],u=o===jp?mXe(a):o===CI?yXe(a):o===oM?_Xe(a):a;this[i.name]=u!==void 0?u:i.default})}static from(t){const n=Tk[t.verb],r=(n.schema||[]).map(({name:i})=>aM(t[i]));return n(...r)}evaluate(t,n){const r=this.schema.map(({name:i,type:s})=>{const o=this[i];return s===Ad?iH(n,o):s===Up?o.map(a=>iH(n,a)):o});return t[this.verb](...r)}toObject(){const t={verb:this.verb};return this.schema.forEach(({name:n})=>{t[n]=qv(this[n])}),t}toAST(){const t={type:lXe,verb:this.verb};return this.schema.forEach(({name:n,type:r,props:i})=>{t[n]=wXe(this[n],r,i)}),t}}function zn(e,t){return Object.assign((...n)=>new Gue(e,t,n),{schema:t})}const Tk={count:zn("count",[{name:"options",type:Vo}]),derive:zn("derive",[{name:"values",type:ry},{name:"options",type:Vo,props:{before:Nc,after:Nc}}]),filter:zn("filter",[{name:"criteria",type:ry}]),groupby:zn("groupby",[{name:"keys",type:xa}]),orderby:zn("orderby",[{name:"keys",type:oM}]),relocate:zn("relocate",[{name:"columns",type:Nc},{name:"options",type:Vo,props:{before:Nc,after:Nc}}]),rename:zn("rename",[{name:"columns",type:Nc}]),rollup:zn("rollup",[{name:"values",type:ry}]),sample:zn("sample",[{name:"size",type:Uue},{name:"options",type:Vo,props:{weight:jue}}]),select:zn("select",[{name:"columns",type:Nc}]),ungroup:zn("ungroup"),unorder:zn("unorder"),reify:zn("reify"),dedupe:zn("dedupe",[{name:"keys",type:xa,default:[]}]),impute:zn("impute",[{name:"values",type:ry},{name:"options",type:Vo,props:{expand:xa}}]),fold:zn("fold",[{name:"values",type:xa},{name:"options",type:Vo}]),pivot:zn("pivot",[{name:"keys",type:xa},{name:"values",type:xa},{name:"options",type:Vo}]),spread:zn("spread",[{name:"values",type:xa},{name:"options",type:Vo}]),unroll:zn("unroll",[{name:"values",type:xa},{name:"options",type:Vo,props:{drop:xa}}]),lookup:zn("lookup",[{name:"table",type:Ad},{name:"on",type:jp},{name:"values",type:xa}]),join:zn("join",[{name:"table",type:Ad},{name:"on",type:jp},{name:"values",type:CI},{name:"options",type:Vo}]),cross:zn("cross",[{name:"table",type:Ad},{name:"values",type:CI},{name:"options",type:Vo}]),semijoin:zn("semijoin",[{name:"table",type:Ad},{name:"on",type:jp}]),antijoin:zn("antijoin",[{name:"table",type:Ad},{name:"on",type:jp}]),concat:zn("concat",[{name:"tables",type:Up}]),union:zn("union",[{name:"tables",type:Up}]),intersect:zn("intersect",[{name:"tables",type:Up}]),except:zn("except",[{name:"tables",type:Up}])};let lM=class Yue extends lse{constructor(t,n,r){super(n),this._verbs=t||[],this._table=r}static from({verbs:t,table:n,params:r}){return new Yue(t.map(Gue.from),r,n)}get[Symbol.toStringTag](){return this._verbs?`Query: ${this._verbs.length} verbs`+(this._table?` on '${this._table}'`:""):"Object"}get length(){return this._verbs.length}get tableName(){return this._table}params(t){return arguments.length?(this._params={...this._params,...t},this):this._params}evaluate(t,n){t=t||n(this._table);for(const r of this._verbs)t=r.evaluate(t.params(this._params),n);return t}toObject(){return oH(this,"toObject")}toJSON(){return this.toObject()}toAST(){return oH(this,"toAST",{type:aXe})}};function oH(e,t,n){return{...n,verbs:e._verbs.map(r=>r[t]()),...e._params?{params:e._params}:null,...e._table?{table:e._table}:null}}function PXe(e,t){return new lM(e._verbs.concat(t),e._params,e._table)}for(const e in Tk){const t=Tk[e];lM.prototype["__"+e]=function(n,...r){return PXe(n,t(...r))}}function Ug(e,t,...n){const r=["_","$"],i=r.slice(0,n.length);return i.push('"use strict"; const '+n.map((s,o)=>s.map((a,u)=>`${r[o]}${u} = ${r[o]}[${u}]`).join(", ")).join(", ")+`; return (${e}) => ${t};`),Function(...i)(...n)}function OXe(e,t=[]){return e.groupby(t.length?t:e.columnNames()).filter("row_number() === 1").ungroup().reify()}function cM(e,t){const n=Mo();return t.forEach((r,i)=>{const s=Ui(r)?r:i;if(s){const o=e.column(i)||Wt(`Unrecognized column: ${i}`);n.add(s,o)}}),e.create(n)}function Kue(e,t,{before:n,after:r}={}){const i=n!=null,s=r!=null;i||s||Wt("relocate requires a before or after option."),i&&s&&Wt("relocate accepts only one of the before or after options."),t=ec(e,t);const o=[...ec(e,i?n:r).keys()],a=i?o[0]:o.pop(),u=new Map;return e.columnNames().forEach(l=>{const c=!t.has(l);if(l===a){s&&c&&u.set(l,l);for(const[f,d]of t)u.set(f,d);if(s)return}c&&u.set(l,l)}),cM(e,u)}function h1(e,t=r=>r,n=""){const r=e.length;if(!r)return"";let i=t(e[0],0);for(let s=1;st?1:e>=t?0:NaN}function RXe(e,t=0,n=e.length){let r=n?e[t++]:yn;for(let i=t;ie[i]&&(r=e[i]);return r}function NXe(e,t=0,n=e.length){let r=n?e[t++]:yn;for(let i=t;i=1)return zb(e[n-1]);const r=(n-1)*t,i=Math.floor(r),s=zb(e[i]);return Lv(s)?s:s+(zb(e[i+1])-s)*(r-i)}class DXe{constructor(t){this._values=t||[],this._sorted=null,this._start=0}values(t){return this._start&&(this._values=this._values.slice(this._start),this._start=0),t?this._values.slice():this._values}add(t){this._values.push(t),this._sorted=null}rem(){this._start+=1,this._sorted=null}min(){return this._sorted&&this._sorted.length?this._sorted[0]:RXe(this._values,this._start)}max(){return this._sorted&&this._sorted.length?this._sorted[this._sorted.length-1]:NXe(this._values,this._start)}quantile(t){return this._sorted||(this._sorted=this.values(!0),this._sorted.sort(fM)),kXe(this._sorted,t)}}const AI=(e,t,n)=>Ug(t,"{"+h1(e,(r,i)=>`_${i}.${n}(${t});`)+"}",e);function $Xe(e,t){const{ops:n,output:r}=LXe(e,t),i=e[0].fields,s=i.length,o=s===0?dM:s===1?MXe:s===2?FXe:Wt("Unsupported field count: "+s);return new o(i,n,r,t)}function LXe(e,t){const n={},r=[];function i(o,a=[]){const u=o+":"+a;if(n[u])return n[u];const l=Ose(o),c=l.create(...a);return t<0&&l.stream&&l.stream.forEach(f=>i(f,[])),l.req&&l.req.forEach(f=>i(f,[])),n[u]=c,r.push(c),c}const s=e.map(o=>{const a=i(o.name,o.params);return a.output=o.id,a});return{ops:r,output:s}}class dM extends UKe{constructor(t,n,r,i){super(r),this._op=n,this._fields=t,this._stream=!!i}init(){const t={count:0,valid:0,stream:this._stream};return this._op.forEach(n=>n.init(t)),t.values&&(t.list=new DXe),t}write(t,n,r){const i=this._outputs,s=i.length;for(let o=0;os[a][i[u]]:a=>s[a][0];n=n.map(a=>u=>a(u,r,o))}return n}function Vg(e,t,n){if(!t.length)return n;const r=Que(t),i=e.groups(),s=i?i.size:1;return n=n||$C(t.length,()=>Array(s)),s>1?r.forEach(o=>{const a=Jue(e,o,i);for(let u=0;u{const a=Xue(e,o);o.write(a,n,0)}),n}function Que(e,t){const n=[],r={};for(const i of e){const s=i.fields.map(o=>o+"").join(",");(r[s]||(r[s]=[])).push(i)}for(const i in r)n.push($Xe(r[i],t));return n}function Xue(e,t){const n=t.init(),r=e.totalRows(),i=e.data(),s=e.mask();if(e.isOrdered()){const o=e.indices();for(let a=0;a=0;o=s.next(o+1))t.add(n,o,i);else for(let o=0;ot.init()),o=e.data();if(e.isOrdered()){const a=e.indices(),u=a.length;for(let l=0;l=0;u=a.next(u+1))t.add(s[r[u]],u,o)}else{const a=e.totalRows();for(let u=0;u>>1;e(t[s],n)<0?r=s+1:i=s}return r},right(t,n,r,i){for(r==null&&(r=0),i==null&&(i=t.length);r>>1;e(t[s],n)>0?i=s:r=s+1}return r}}}const aH=ele(fM);function BXe(e,t,n,r,i){let s,o,a,u,l;const c=m=>o[m-1]===o[m],f=r.length,d=i.length,h=r.length?Ug(["w","r","k"],"{"+h1(r,(m,y)=>`r[_${y}.id][k]=_${y}.value(w,_${y}.get);`)+"}",r):()=>{},p={i0:0,i1:0,index:0,size:0,peer:c,init(m,y,g,v){p.index=p.i0=p.i1=0,p.size=y.length,s=m,o=y,u=g,l=v,a=i?i.map(b=>b.init()):null;for(let b=0;b0&&c(p.i0)&&(p.i0=aH.left(o,o[p.i0])),p.i1(e.frame||[null,null]).map(t=>Number.isFinite(t)?Math.abs(t):null),UXe=e=>!!e.peers;function VXe(e){const{id:t,name:n,fields:r=[],params:i=[]}=e,s=Rse(n).create(...i);return r.length&&(s.get=r[0]),s.id=t,s}function zXe(e,t,n,r={},i){const s=e.data(),o=HXe(i,s),a=o.length,u=Ug(["r","d","op"],"{"+h1(t,(l,c)=>`_${c}[r] = $${c}(r, d, op);`)+"}",t,n);e.partitions().forEach((l,c)=>{const f=l.length,d=WXe(e,l);for(let p=0;pr[p][c];for(let p=0;p{const i=jXe(r),s=UXe(r),o=`${i},${s}`,{aggOps:a,winOps:u}=n[o]||(n[o]={frame:i,peers:s,aggOps:[],winOps:[]});G6(r.name)?a.push(r):u.push(VXe(r))}),Object.values(n).map(r=>BXe(t,r.frame,r.peers,r.winOps,Que(r.aggOps,r.frame[0]!=null?-1:1)))}function WXe(e,t){if(e.isOrdered()){const n=e.comparator(),r=e.data(),i=t.length,s=new Uint32Array(i);for(let o=1,a=0;oo.add(d,Array(s))),[u,l]=GXe(r),c=e.isGrouped()?e.groups().size:1,f=Vg(e,u,$C(r.length,()=>Array(c)));return l.length?zXe(e,a,n,f,l):YXe(e,a,n,f),e.create(o)}function GXe(e){const t=[],n=[],r=e.length;for(let i=0;ir[l][o[c]]:l=>r[l][0],u=t.length;for(let l=0;l=0;d=i.next(d+1))f[d]=c(d,s,a);else{const d=e.totalRows();for(let h=0;h!e.column(i)),n)}function QXe(e,t){if(t.length===0)return e;const n=e.columnNames();return t.reduce((r,i)=>r.antijoin(i.select(n)),e).dedupe()}const Hb=2147483648,XXe=4294967295;class tle{constructor(t){this._size=t,this._bits=new Uint32Array(Math.ceil(t/32))}get length(){return this._size}count(){const t=this._bits.length;let n=0;for(let r=0;r>5]&Hb>>>t}set(t){this._bits[t>>5]|=Hb>>>t}clear(t){this._bits[t>>5]&=~(Hb>>>t)}scan(t){for(let n=this.next(0);n>=0;n=this.next(n+1))t(n)}next(t){const n=this._bits,r=n.length;let i=t>>5,s=n[i]&XXe>>>t;for(;i=0;)n=this.next(n+1);return n}not(){const t=this._bits,n=t.length;for(let i=0;i>r-1),this}and(t){if(t){const n=this._bits,r=t._bits,i=n.length;for(let s=0;s=0;o=r.next(o+1))t(o,i)&&s.set(o);else for(let o=0;oi[s]}return JXe(e,r)}function nle(e,{names:t=[],exprs:n=[],ops:r=[]},i={}){if(!t.length)return e;const s=i.limit>0?+i.limit:1/0,o=i.index?i.index===!0?"index":i.index+"":null,a=new Set(i.drop),u=Vh(e,r,n),l=Mo(),c=new Set(t),f=[],d=[],h=[];e.columnNames().forEach(S=>{if(!a.has(S)){const T=l.add(S,[]);c.has(S)||(f.push(e.column(S)),d.push(T))}}),t.forEach(S=>{a.has(S)||(l.has(S)||l.add(S,[]),h.push(l.data[S]))});const p=o?l.add(o,[]):null;let m=0;const y=f.length,g=h.length,v=(S,T)=>{for(let E=0;E{for(let E=0;E{};if(g===1){const S=u[0],T=h[0];e.scan((E,I)=>{const A=io(S(E,I)),R=Math.min(A.length,s);v(E,R);for(let F=0;F{let E=0;const I=u.map(A=>{const R=io(A(S,T));return E=Math.min(Math.max(E,R.length),s),R});v(S,E);for(let A=0;At,(u,l)=>a.map(c=>c(u,l))]},{...i,drop:t})}function Qa(e,t,n,r={window:!1}){const i=new Map,s=o=>{o=bs(o)?t.columnName(o):o,Ui(o)?i.set(o,_h(o)):sr(o)?ec(t,o).forEach(s):as(o)?Hae(i,o):Wt(`Invalid ${e} value: ${o+""}`)};return io(n).forEach(s),r.preparse&&r.preparse(i),ao(i,{table:t,...r})}function tJe(e,t,n){return eJe(e,Qa("fold",e,t),n)}function uH(e,t,n,r){const i=n&&n.length;return nJe(i?rJe(e,n,r):e,t,i)}function nJe(e,{names:t,exprs:n,ops:r},i){const s=Vh(e,r,n),o=i?null:Mo(e),a=e.totalRows();return t.forEach((u,l)=>{const c=e.column(u),f=i?c.data:o.add(u,Array(a)),d=s[l];e.scan(h=>{const p=c.get(h);f[h]=Ma(p)?p:d(h)})}),i?e:e.create(o)}function rJe(e,t,n){const r=e.groups(),i=e.data(),s=(r?r.names:[]).concat(t),o=(r?r.get:[]).concat(t.map(p=>e.getter(p))),a=new Set,u=sI(o);e.scan((p,m)=>a.add(u(p,m)));const l=e.columnNames(),c=Mo(),f=l.map(p=>c.add(p,[]));l.forEach((p,m)=>{const y=i[p],g=f[m];e.scan(v=>g.push(y.get(v)))});const d=sI(o.map((p,m)=>y=>y[m])),h=Ug("v","{"+f.map((p,m)=>`_${m}.push(v[$${m}]);`).join("")+"}",f,l.map(p=>s.indexOf(p)));if(r){let p=r.keys.length;const m=n.reduce((g,v)=>g*v.length,r.size),y=new Uint32Array(m+(p-a.size));y.set(r.keys),lH(r,n,(g,v)=>{a.has(d(g))||(h(g),y[p++]=v[0])}),c.groupby({...r,keys:y})}else lH(r,n,p=>{a.has(d(p))||h(p)});return e.create(c.new())}function lH(e,t,n){const r=e?e.get.length:0,i=e?1:0,s=i+t.length,o=new Int32Array(s),a=new Int32Array(s),u=[];if(e){const{get:c,rows:f,size:d}=e;o[0]=d,u.push((h,p)=>{const m=f[p];for(let y=0;y{const d=f+r;o[f+i]=c.length,u.push((h,p)=>h[d]=c[p])});const l=Array(r+t.length);for(let c=0;c=0;){const f=++a[c];fr[u][l],a=e.length;for(let u=0;u1){const c=i.add(e[u],Array(s));for(let f=0;fe.column(r)?0:Wt(`Invalid impute column ${el(r)}`)),n.expand){const r={preparse:oJe,aggronly:!0},i=Qa("impute",e,n.expand,r),s=pM(e.ungroup(),i);return uH(e,t,i.names,i.names.map(o=>s.get(o,0)))}else return uH(e,t)}function oJe(e){e.forEach((t,n)=>t.field?e.set(n,vse(t+"")):0)}function aJe(e,t){const n=e.columnNames();return t.length?t.reduce((r,i)=>r.semijoin(i.select(n)),e).dedupe():e.reify([])}function rle(e,t){const n=new Map;return e.scan((r,i)=>{const s=t(r,i);s!=null&&s===s&&n.set(s,r)}),n}function uJe(e,t,n){const r=new Map,i=e.length;for(let s=0;s`_${i}.push($${i}(${n}));`)+"}",e,t)}function cJe(e,t,n,{names:r,exprs:i},s={}){const o=e.data(),a=e.indices(!1),u=a.length,l=new Int32Array(u),c=t.data(),f=t.indices(!1),d=f.length,h=new Int32Array(d),p=r.length,m=Mo(),y=Array(p),g=Array(p);for(let S=0;S=c?(f=r,d=t,h=a,p=s,m=i,y=n,g=u,v=o):(f=i,d=n,h=u,p=o,m=r,y=t,g=a,v=s,b=(E,I,A,R)=>e(A,R,E,I));const S=uJe(v,m,y),T=p.length;for(let E=0;E{s=bs(s)?t.columnName(s):s,Ui(s)?r.set(o,_h(s)):sr(s)||as(s)&&s.expr?r.set(o,s):Wt(`Invalid ${e} key value: ${s+""}`)});const i=ao(r,{table:t,aggregate:!1,window:!1});return sI(i.exprs,!0)}function hJe(e,t){const n=new Set(t);return e.filter(r=>n.has(r))}function mM(e,t,n){if(n)Ui(n)?n=[n,n]:En(n)&&n.length===1&&(n=[n[0],n[0]]);else{const r=hJe(e.columnNames(),t.columnNames());r.length||Wt("Natural join requires shared column names."),n=[r,r]}return n}function ile(e,t,n,r){return n.length!==r.length&&Wt("Mismatched number of join keys"),[PI("join",e,n),PI("join",t,r)]}const pJe={aggregate:!1,window:!1},mJe={...pJe,index:1};function cH(e,t,n,r,i={}){n=mM(e,t,n);const s={join:[e,t]};let o;if(En(n)){const[a,u]=n.map(io);o=ile(e,t,a,u),r||(r=gJe(e,a,u,i))}else o=ao({on:n},s).exprs[0],r||(r=[rg(),rg()]);return cJe(e,t,o,yJe(e,t,r,s,i&&i.suffix),i)}function gJe(e,t,n,r){const i=[];t.forEach((o,a)=>Ui(o)&&o===n[a]?i.push(o):0);const s=qae(i);if(r.left&&r.right){const o=new Set(i);return[e.columnNames().map(a=>{const u=`[${el(a)}]`;return o.has(a)?{[a]:`(a, b) => a${u} == null ? b${u} : a${u}`}:a}),s]}return r.right?[s,rg()]:[rg(),s]}function yJe(e,t,n,r,i=[]){if(En(n)){let s,o,a,u=n.length;s=o=a={names:[],exprs:[]},u--&&(s=Qa("join",e,n[0],r)),u--&&(o=Qa("join",t,n[1],mJe)),u--&&(a=ao(n[2],r));const l=new Set,c=new Set(s.names);return o.names.forEach(f=>{c.has(f)&&l.add(f)}),l.size&&(i[0]!==""&&fH(s.names,l,i[0]||"_1"),i[1]!==""&&fH(o.names,l,i[1]||"_2")),{names:s.names.concat(o.names,a.names),exprs:s.exprs.concat(o.exprs,a.exprs)}}else return ao(n,r)}function fH(e,t,n){e.forEach((r,i)=>t.has(r)?e[i]=r+n:0)}function vJe(e,t,n,r={}){const i=new tle(e.totalRows());return(En(n)?_Je:bJe)(i,e,t,n),r.anti&&i.not().and(e.mask()),e.create({filter:i})}function _Je(e,t,n,[r,i]){const s=rle(n,i);t.scan((o,a)=>{s.get(r(o,a))>=0&&e.set(o)})}function bJe(e,t,n,r){const i=t.numRows(),s=n.numRows(),o=t.data(),a=n.data();if(t.isFiltered()||n.isFiltered()){const u=t.indices(!1),l=n.indices(!1);for(let c=0;ca.add(d,Array(u).fill(yn)));const l=rle(t,r),c=Ug(["lr","rr","data"],"{"+h1(i,(d,h)=>`_[${h}][lr] = $[${h}](rr, data);`)+"}",i.map(d=>a.data[d]),Vh(t,o,s)),f=t.data();return e.scan((d,h)=>{const p=l.get(n(d,h));p>=0&&c(d,p,f)}),e.create(a)}function EJe(e,t,n,r){return n=mM(e,t,n),wJe(e,t,[PI("lookup",e,n[0]),PI("lookup",t,n[1])],Qa("lookup",t,r))}const Ik=(e,t)=>e??t;function SJe(e,t,n,r={}){const{keys:i,keyColumn:s}=TJe(e,t,r),o=Ik(r.valueSeparator,"_"),a=n.names.length>1?(l,c)=>c+o+i[l]:l=>i[l],u=i.map(l=>Vg(e,n.ops.map(c=>{if(c.name==="count"){const d=h=>l===s[h]?1:NaN;return d.toString=()=>l+":1",{...c,name:"sum",fields:[d]}}const f=c.fields.map(d=>{const h=(p,m)=>l===s[p]?d(p,m):NaN;return h.toString=()=>l+":"+d,h});return{...c,fields:f}})));return e.create(IJe(n,a,e.groups(),u))}function TJe(e,t,n){const r=n.limit>0?+n.limit:1/0,i=Ik(n.sort,!0),s=Ik(n.keySeparator,"_"),o=Vh(e,t.ops,t.exprs),a=o.length===1?o[0]:(f,d)=>o.map(h=>h(f,d)).join(s),u=Array(e.totalRows());e.scan((f,d)=>u[f]=a(f,d));const l=Vg(e.ungroup(),[{id:0,name:"array_agg_distinct",fields:[f=>u[f]],params:[]}])[0][0],c=i?l.sort():l;return{keys:Number.isFinite(r)?c.slice(0,r):c,keyColumn:u}}function IJe({names:e,exprs:t},n,r,i){const s=r?r.size:1,o=Mo(),a=i.length,u=e.length;let l;const c=(f,d)=>l[f][d];r&&Zue(o,r);for(let f=0;f1)for(let h=0;ht.field?e.set(n,mse(t+"")):0)}function AJe(e,t){const n=new Map;return e.columnNames(r=>(n.set(r,r),0)),cM(e,ec(e,t,n))}function hH(e,t){return pM(e,ao(t,{table:e,aggronly:!0,window:!1}))}function PJe(e,t,n,r){return(t?r?RJe:OJe:r?kJe:NJe)(e.length,e,n,r)}function OJe(e,t,n){const r=n.length;for(let i=0;i=r)return n;for(let i=0;i=i)return n;const s=new Float32Array(i),o=new Uint32Array(i);for(let a=0;as[a]-s[u]);for(let a=0;a{let d=t(f);return a+=d=i?d:Math.min(c.length,d),d});const u=new Uint32Array(a);let l=0;return o.forEach((c,f)=>{const d=t[f],h=u.subarray(l,l+=d);!i&&d===c.length?h.set(c):PJe(h,i,c,n)}),s!==!1&&(o.length>1||!i)&&DJe(u),e.reify(u)}function LJe(e,t,n={}){return $Je(e,MJe(e,t),FJe(e,n.weight),n)}const sle=e=>t=>e.get(t)||0;function MJe(e,t){return bs(t)?()=>t:sle(pM(e,ao({size:t},{table:e,window:!1})).column("size"))}function FJe(e,t){return t==null?null:(t=bs(t)?e.columnName(t):t,sle(Ui(t)?e.column(t):hM(e,ao({w:t},{table:e}),{drop:!0}).column("w")))}function BJe(e,t){return cM(e,ec(e,t))}function jJe(e,{names:t,exprs:n,ops:r=[]},i={}){if(t.length===0)return e;const s=t.length===1&&i.as||[],o=i.drop==null?!0:!!i.drop,a=i.limit==null?s.length||1/0:Math.max(1,+i.limit||1),u=Vh(e,r,n),l=Mo(),c=t.reduce((d,h,p)=>d.set(h,p),new Map),f=(d,h)=>{const p=UJe(e,u[d],a),m=p.length;for(let y=0;y{c.has(d)?(o||l.add(d,e.column(d)),f(c.get(d),d),c.delete(d)):l.add(d,e.column(d))}),c.forEach(f),e.create(l)}function UJe(e,t,n){const r=e.totalRows(),i=[];return e.scan((s,o)=>{const a=io(t(s,o)),u=Math.min(a.length,n);for(;i.length=0;h=d.next(h+1)){const p=o(h,f)+"",m=l[p];u[h]=m??(l[p]=c.push(h)-1)}else for(let h=0;hp=>h(p,f))),{keys:u,get:s,names:t,rows:c,size:c.length}}function GJe(e,t){return WJe(e,Qa("groupby",e,t))}function YJe(e,t){return e.create({order:t})}const KJe=(e,t,n,r)=>`((u = ${e}) < (v = ${t}) || u == null) && v != null ? ${n} +`;case 114:return"\r";case 120:return String.fromCharCode(this.readHexChar(2));case 117:return jf(this.readCodePoint());case 116:return" ";case 98:return"\b";case 118:return"\v";case 102:return"\f";case 13:this.input.charCodeAt(this.pos)===10&&++this.pos;case 10:return this.options.locations&&(this.lineStart=this.pos,++this.curLine),"";case 56:case 57:if(this.strict&&this.invalidStringToken(this.pos-1,"Invalid escape sequence"),e){var n=this.pos-1;this.invalidStringToken(n,"Invalid escape sequence in template string")}default:if(t>=48&&t<=55){var r=this.input.substr(this.pos-1,3).match(/^[0-7]+/)[0],i=parseInt(r,8);return i>255&&(r=r.slice(0,-1),i=parseInt(r,8)),this.pos+=r.length-1,t=this.input.charCodeAt(this.pos),(r!=="0"||t===56||t===57)&&(this.strict||e)&&this.invalidStringToken(this.pos-1-r.length,e?"Octal literal in template string":"Octal literal in strict mode"),String.fromCharCode(i)}return Fg(t)?"":String.fromCharCode(t)}};rn.readHexChar=function(e){var t=this.pos,n=this.readInt(16,e);return n===null&&this.invalidStringToken(t,"Bad character escape sequence"),n};rn.readWord1=function(){this.containsEsc=!1;for(var e="",t=!0,n=this.pos,r=this.options.ecmaVersion>=6;this.pos(t,n)=>n.error(t,e+" not allowed"),LQe=Ai("Aggregate function"),MQe=Ai("Window function"),FQe="Invalid argument",rM="Invalid column reference",BQe=rM+" (must be input to an aggregate function)",Oue="Invalid function call",jQe="Invalid member expression",UQe="Invalid operator parameter",VQe="Invalid param reference",zQe="Invalid variable reference",HQe="Variable not accessible in operator call",WQe="Unsupported variable declaration",qQe="Unsupported destructuring pattern",Rue="Table expressions do not support closures",Nue="Use aq.escape(fn) to use a function as-is (including closures)",GQe="use table.params({ name: value }) to define dynamic parameters",YQe="use aq.addFunction(name, fn) to add new op functions",KQe=` +Note: ${Rue}. ${Nue}, or ${GQe}.`,kue=` +Note: ${Rue}. ${Nue}, or ${YQe}.`,QQe=`The ${kse} method is not valid in multi-table expressions.`;function XQe(e,t){const n=JQe(t);let r=e.root=n;return e.spec=t,e.tuple=null,e.tuple1=null,e.tuple2=null,e.$param=null,e.$op=0,e.scope=new Set,e.paramsRef=new Map,e.columnRef=new Map,WKe(r)?(eXe(r,e),r=r.body):e.join?(e.scope.add(e.tuple1=DQe),e.scope.add(e.tuple2=$Qe),e.scope.add(e.$param=tH)):(e.scope.add(e.tuple=kQe),e.scope.add(e.$param=tH)),pn(r,e,iM),e.root}function JQe(e){try{const t=e.field?ZQe(e):En(e)?el(e):e;return RQe(`expr=(${t})`,NQe).body[0].expression.right}catch{Wt(`Expression parse error: ${e+""}`)}}function ZQe(e){const t=JSON.stringify(e+"");return e.table?`(a,b)=>b[${t}]`:`d=>d[${t}]`}const iM={FunctionDeclaration:Ai("Function definitions"),ForStatement:Ai("For loops"),ForOfStatement:Ai("For-of loops"),ForInStatement:Ai("For-in loops"),WhileStatement:Ai("While loops"),DoWhileStatement:Ai("Do-while loops"),AwaitExpression:Ai("Await expressions"),ArrowFunctionExpression:Ai("Function definitions"),AssignmentExpression:Ai("Assignments"),FunctionExpression:Ai("Function definitions"),NewExpression:Ai('Use of "new"'),UpdateExpression:Ai("Update expressions"),VariableDeclarator(e,t){Ek(e.id,t)},Identifier(e,t,n){Lue(e,t,n)&&!t.scope.has(e.name)&&t.error(e,zQe,KQe)},CallExpression(e,t){const n=Due(e.callee),r=Ose(n)||Rse(n);if(r){if((t.join||t.aggregate===!1)&&q6(n)&&LQe(e,t),(t.join||t.window===!1)&&G6(n)&&MQe(e,t),t.$op=1,t.ast)wk(e,n,t),e.arguments.forEach(i=>pn(i,t,bk));else{const i=t.op(tXe(t,r,n,e.arguments));Object.assign(e,{type:Ise,name:i.id})}return t.$op=0,!1}else Pse(n)?wk(e,n,t):t.error(e,Oue,kue)},MemberExpression(e,t,n){const{object:r,property:i}=e;if(!ti(vf,r))return;const{name:s}=r;if($ue(e)&&ti(vf,i)&&Ya(nM,i.name)){Bue(e,i.name);return}const o=s===t.tuple?0:s===t.tuple1?1:s===t.tuple2?2:-1;if(o>=0)return nH(e,o,t,Mue,n);if(s===t.$param)return nH(e,o,t,rXe);t.paramsRef.has(s)?Wv(e,t.paramsRef.get(s)):t.columnRef.has(s)?Fue(r,s,t,e):Ya(t.params,s)&&Wv(r,s)}};function nH(e,t,n,r,i){const{property:s,computed:o}=e;let a;if(!o)a=s.name;else if(ti(kg,s))a=s.value;else try{pn(s,n,iM,e),a=n.param(s)}catch{n.error(e,jQe)}return r(e,a,t,n,i),!1}const bk={...iM,VariableDeclarator:Ai("Variable declaration in operator call"),Identifier(e,t,n){Lue(e,t,n)&&t.error(e,HQe)},CallExpression(e,t){const n=Due(e.callee);Pse(n)?wk(e,n,t):t.error(e,Oue,kue)}};function eXe(e,t){e.generator&&Ai("Generator functions")(e,t),e.async&&Ai("Async functions")(e,t);const{params:n}=e,r=n.length,i=o=>(a,u)=>t.columnRef.set(a,[u,o]),s=(o,a)=>t.paramsRef.set(o,a);r&&(t.join?(D0(t,n[0],"tuple1",i(1)),r>1&&D0(t,n[1],"tuple2",i(2)),r>2&&D0(t,n[2],"$param",s)):(D0(t,n[0],"tuple",i(0)),r>1&&D0(t,n[1],"$param",s))),t.root=e.body}function D0(e,t,n,r){ti(vf,t)?(e.scope.add(t.name),e[n]=t.name):ti(Sse,t)&&t.properties.forEach(i=>{const s=ti(vf,i.key)?i.key.name:ti(kg,i.key)?i.key.value:e.error(i,FQe);ti(vf,i.value)||e.error(i.value,qQe),r(i.value.name,s)})}function tXe(e,t,n,r){const i=[],s=[],o=t.param[0]||0,a=o+(t.param[1]||0);return r.forEach((u,l)=>{l0?r.join[n-1]:null,o=s&&s.column(t);s&&!o&&r.error(e,rM),r.aggronly&&!r.$op&&r.error(e,BQe),Nse(e,t,n,o,i)}function Fue(e,t,n,r){const[i,s]=n.columnRef.get(t);Mue(e,i,s,n,r)}function rXe(e,t,n,r){r.params&&!Ya(r.params,t)&&r.error(e,VQe),Wv(e,t)}function Wv(e,t){e.type=qWe,e.name=t}function Bue(e,t){e.type=zWe,e.name=t,e.raw=nM[t]}function wk(e,t,n){if(t===kse){const r=n.table;r||n.error(e,QQe),Dse(e,e.arguments.length?e.arguments.map(i=>{const s=n.param(i),o=bs(s)?r.columnName(s):s;return r.column(o)||n.error(i,rM),o}):r.columnNames())}else e.callee={type:WWe,name:t}}function Ek(e,t){ti(vf,e)?t.scope.add(e.name):ti(BWe,e)?e.elements.forEach(n=>Ek(n,t)):ti(Sse,e)?e.properties.forEach(n=>Ek(n.value,t)):t.error(e.id,WQe)}const iXe={[i1]:1,[Ise]:1};function ao(e,t={}){const n=t.generate||iI,r=t.compiler||Y6,i=oXe(t),s={},o={},a=[],u=[];let l=0,c=-1;const f=t.join?r.join:t.index==1?r.expr2:r.expr,d={op(m){const y=sXe(m);return o[y]||(m.id=++c,o[y]=m)},field(m){const y=n(m);return s[y]||(s[y]=++l)},param(m){return ti(kg,m)?m.value:r.param(n(m),i)},value(m,y){a.push(m);const g=y.escape||(t.ast?HKe(y):f(n(y),i));u.push(g),iXe[y.type]&&g!==y&&as(g)&&(g.field=y.name)},error(m,y,g=""){const v=m.start-6,b=m.end-6,S=String(d.spec).slice(v,b);Wt(`${y}: "${S}"${g}`)}};Object.assign(d,t,{params:i});for(const[m,y]of MC(e))d.value(m+"",y.escape?YKe(d,y,i):XQe(d,y));if(t.ast)return{names:a,exprs:u};const h=[];for(const m in s)h[s[m]]=r.expr(m,i);const p=Object.values(o);return p.forEach(m=>m.fields=m.fields.map(y=>h[y])),{names:a,exprs:u,ops:p}}function sXe(e){let t=`${e.name}(${e.fields.concat(e.params).join(",")})`;if(e.frame){const n=e.frame.map(r=>Number.isFinite(r)?Math.abs(r):-1);t+=`[${n},${!!e.peers}]`}return t}function oXe(e){return(e.table?u2(e.table):e.join?{...u2(e.join[1]),...u2(e.join[0])}:{})||{}}function u2(e){return e&&sr(e.params)?e.params():{}}const jue="Expr",xa="ExprList",Uue="ExprNumber",ry="ExprObject",jp="JoinKeys",CI="JoinValues",Vo="Options",sM="OrderKeys",Nc="SelectionList",Ad="TableRef",Up="TableRefList",aXe="Descending",uXe="Query",lXe="Selection",cXe="Verb",fXe="Window";function tA(e,t){return e&&e.expr?new rH({...e,...t}):new rH(t,e)}class rH{constructor(t,n){this.expr=n,Object.assign(this,t)}toString(){return String(this.expr)}toObject(){return{...this,expr:this.toString(),...sr(this.expr)?{func:!0}:{}}}}function dXe(e){return tA(e,{desc:!0})}function _h(e,t,n=0){const r=n?{field:!0,table:n}:{field:!0};return tA(e,t?{expr:t,...r}:r)}function hXe(e,t,n){return tA(e,{window:{frame:t||[-1/0,0],peers:!!n}})}function pXe(e){const t=n=>n;return t.toString=()=>e,t}function iH(e,t){return t=t&&sr(t.query)?t.query():t,t&&sr(t.evaluate)?t.evaluate(null,e):e(t)}function Vue(e){return as(e)&&(En(e.all)||En(e.matches)||En(e.not)||En(e.range))}function qv(e){return e&&sr(e.toObject)?e.toObject():sr(e)?{expr:String(e),func:!0}:En(e)?e.map(qv):as(e)?KC(e,t=>qv(t)):e}function oM(e){return En(e)?e.map(oM):as(e)?En(e.verbs)?uM.from(e):En(e.all)?rg():En(e.range)?BKe(...e.range):En(e.match)?jKe(RegExp(...e.match)):En(e.not)?qae(e.not.map(qv)):mXe(e):e}function mXe(e){let t=e,n=e.expr;if(n!=null){if(e.field===!0?t=n=_h(n):e.func===!0&&(t=n=pXe(n)),as(e.window)){const{frame:r,peers:i}=e.window;t=n=hXe(n,r,i)}e.desc===!0&&(t=dXe(n))}return e===t?KC(e,r=>oM(r)):t}function gXe(e){return En(e)?e.map(yXe):e}function yXe(e){const t=[];return io(e).forEach(n=>{bs(n)?t.push(n):Ui(n)?t.push(_h(n,null)):as(n)&&n.expr||sr(n)?t.push(n):Wt(`Invalid key value: ${n+""}`)}),t}function vXe(e){return En(e)?e.map(_Xe):e}function _Xe(e,t){return t<2?io(e):e}function bXe(e){const t=[];return e.forEach(n=>{const r=n.expr!=null?n.expr:n;if(as(r)&&!sr(r))for(const i in r)t.push(r[i]);else n=bs(r)?r:Ui(r)?_h(n):sr(r)?n:Wt(`Invalid orderby field: ${n+""}`),t.push(n)}),t}const wXe={[jue]:que,[xa]:sg,[Uue]:CXe,[ry]:Uf,[jp]:AXe,[CI]:PXe,[sM]:sg,[Nc]:IXe};function EXe(e,t,n){return t===Ad?sH(e):t===Up?e.map(sH):zue(qv(e),t,n)}function zue(e,t,n){return t===Vo?e&&SXe(e,n):wXe[t](e)}function SXe(e,t={}){const n={};for(const r in e){const i=e[r];n[r]=t[r]?zue(i,t[r]):i}return n}function TXe(e,t){return ao({expr:e},{...t,ast:!0}).exprs[0]}function aM(e){return{type:i1,name:e}}function Hue(e){return{type:i1,index:e}}function Uf(e,t){if(Ui(e))return TXe(e,t);if(e.expr){let n;if(e.field===!0?n=aM(e.expr):e.func===!0&&(n=Uf(e.expr,t)),n)return e.desc&&(n={type:aXe,expr:n}),e.window&&(n={type:fXe,expr:n,...e.window}),n}return Object.keys(e).map(n=>({...Uf(e[n],t),as:n}))}function Wue(e){const t=lXe;return e.all?{type:t,operator:"all"}:e.not?{type:t,operator:"not",arguments:sg(e.not)}:e.range?{type:t,operator:"range",arguments:sg(e.range)}:e.matches?{type:t,operator:"matches",arguments:e.matches}:Wt("Invalid input")}function IXe(e){return io(e).map(xXe).flat()}function xXe(e){return Vue(e)?Wue(e):bs(e)?Hue(e):Ui(e)?aM(e):as(e)?Object.keys(e).map(t=>({type:i1,name:t,as:e[t]})):Wt("Invalid input")}function que(e){return Vue(e)?Wue(e):bs(e)?Hue(e):Ui(e)?aM(e):as(e)?Uf(e):Wt("Invalid input")}function sg(e){return io(e).map(que).flat()}function CXe(e){return bs(e)?e:Uf(e)}function AXe(e){return En(e)?e.map(sg):Uf(e,{join:!0})}function PXe(e){return En(e)?e.map((t,n)=>n<2?sg(t):Uf(t,{join:!0})):Uf(e,{join:!0})}function sH(e){return e&&sr(e.toAST)?e.toAST():e}class Gue{constructor(t,n=[],r=[]){this.verb=t,this.schema=n,n.forEach((i,s)=>{const o=i.type,a=r[s],u=o===jp?gXe(a):o===CI?vXe(a):o===sM?bXe(a):a;this[i.name]=u!==void 0?u:i.default})}static from(t){const n=Sk[t.verb],r=(n.schema||[]).map(({name:i})=>oM(t[i]));return n(...r)}evaluate(t,n){const r=this.schema.map(({name:i,type:s})=>{const o=this[i];return s===Ad?iH(n,o):s===Up?o.map(a=>iH(n,a)):o});return t[this.verb](...r)}toObject(){const t={verb:this.verb};return this.schema.forEach(({name:n})=>{t[n]=qv(this[n])}),t}toAST(){const t={type:cXe,verb:this.verb};return this.schema.forEach(({name:n,type:r,props:i})=>{t[n]=EXe(this[n],r,i)}),t}}function zn(e,t){return Object.assign((...n)=>new Gue(e,t,n),{schema:t})}const Sk={count:zn("count",[{name:"options",type:Vo}]),derive:zn("derive",[{name:"values",type:ry},{name:"options",type:Vo,props:{before:Nc,after:Nc}}]),filter:zn("filter",[{name:"criteria",type:ry}]),groupby:zn("groupby",[{name:"keys",type:xa}]),orderby:zn("orderby",[{name:"keys",type:sM}]),relocate:zn("relocate",[{name:"columns",type:Nc},{name:"options",type:Vo,props:{before:Nc,after:Nc}}]),rename:zn("rename",[{name:"columns",type:Nc}]),rollup:zn("rollup",[{name:"values",type:ry}]),sample:zn("sample",[{name:"size",type:Uue},{name:"options",type:Vo,props:{weight:jue}}]),select:zn("select",[{name:"columns",type:Nc}]),ungroup:zn("ungroup"),unorder:zn("unorder"),reify:zn("reify"),dedupe:zn("dedupe",[{name:"keys",type:xa,default:[]}]),impute:zn("impute",[{name:"values",type:ry},{name:"options",type:Vo,props:{expand:xa}}]),fold:zn("fold",[{name:"values",type:xa},{name:"options",type:Vo}]),pivot:zn("pivot",[{name:"keys",type:xa},{name:"values",type:xa},{name:"options",type:Vo}]),spread:zn("spread",[{name:"values",type:xa},{name:"options",type:Vo}]),unroll:zn("unroll",[{name:"values",type:xa},{name:"options",type:Vo,props:{drop:xa}}]),lookup:zn("lookup",[{name:"table",type:Ad},{name:"on",type:jp},{name:"values",type:xa}]),join:zn("join",[{name:"table",type:Ad},{name:"on",type:jp},{name:"values",type:CI},{name:"options",type:Vo}]),cross:zn("cross",[{name:"table",type:Ad},{name:"values",type:CI},{name:"options",type:Vo}]),semijoin:zn("semijoin",[{name:"table",type:Ad},{name:"on",type:jp}]),antijoin:zn("antijoin",[{name:"table",type:Ad},{name:"on",type:jp}]),concat:zn("concat",[{name:"tables",type:Up}]),union:zn("union",[{name:"tables",type:Up}]),intersect:zn("intersect",[{name:"tables",type:Up}]),except:zn("except",[{name:"tables",type:Up}])};let uM=class Yue extends lse{constructor(t,n,r){super(n),this._verbs=t||[],this._table=r}static from({verbs:t,table:n,params:r}){return new Yue(t.map(Gue.from),r,n)}get[Symbol.toStringTag](){return this._verbs?`Query: ${this._verbs.length} verbs`+(this._table?` on '${this._table}'`:""):"Object"}get length(){return this._verbs.length}get tableName(){return this._table}params(t){return arguments.length?(this._params={...this._params,...t},this):this._params}evaluate(t,n){t=t||n(this._table);for(const r of this._verbs)t=r.evaluate(t.params(this._params),n);return t}toObject(){return oH(this,"toObject")}toJSON(){return this.toObject()}toAST(){return oH(this,"toAST",{type:uXe})}};function oH(e,t,n){return{...n,verbs:e._verbs.map(r=>r[t]()),...e._params?{params:e._params}:null,...e._table?{table:e._table}:null}}function OXe(e,t){return new uM(e._verbs.concat(t),e._params,e._table)}for(const e in Sk){const t=Sk[e];uM.prototype["__"+e]=function(n,...r){return OXe(n,t(...r))}}function Ug(e,t,...n){const r=["_","$"],i=r.slice(0,n.length);return i.push('"use strict"; const '+n.map((s,o)=>s.map((a,u)=>`${r[o]}${u} = ${r[o]}[${u}]`).join(", ")).join(", ")+`; return (${e}) => ${t};`),Function(...i)(...n)}function RXe(e,t=[]){return e.groupby(t.length?t:e.columnNames()).filter("row_number() === 1").ungroup().reify()}function lM(e,t){const n=Mo();return t.forEach((r,i)=>{const s=Ui(r)?r:i;if(s){const o=e.column(i)||Wt(`Unrecognized column: ${i}`);n.add(s,o)}}),e.create(n)}function Kue(e,t,{before:n,after:r}={}){const i=n!=null,s=r!=null;i||s||Wt("relocate requires a before or after option."),i&&s&&Wt("relocate accepts only one of the before or after options."),t=ec(e,t);const o=[...ec(e,i?n:r).keys()],a=i?o[0]:o.pop(),u=new Map;return e.columnNames().forEach(l=>{const c=!t.has(l);if(l===a){s&&c&&u.set(l,l);for(const[f,d]of t)u.set(f,d);if(s)return}c&&u.set(l,l)}),lM(e,u)}function h1(e,t=r=>r,n=""){const r=e.length;if(!r)return"";let i=t(e[0],0);for(let s=1;st?1:e>=t?0:NaN}function NXe(e,t=0,n=e.length){let r=n?e[t++]:yn;for(let i=t;ie[i]&&(r=e[i]);return r}function kXe(e,t=0,n=e.length){let r=n?e[t++]:yn;for(let i=t;i=1)return zb(e[n-1]);const r=(n-1)*t,i=Math.floor(r),s=zb(e[i]);return Lv(s)?s:s+(zb(e[i+1])-s)*(r-i)}class $Xe{constructor(t){this._values=t||[],this._sorted=null,this._start=0}values(t){return this._start&&(this._values=this._values.slice(this._start),this._start=0),t?this._values.slice():this._values}add(t){this._values.push(t),this._sorted=null}rem(){this._start+=1,this._sorted=null}min(){return this._sorted&&this._sorted.length?this._sorted[0]:NXe(this._values,this._start)}max(){return this._sorted&&this._sorted.length?this._sorted[this._sorted.length-1]:kXe(this._values,this._start)}quantile(t){return this._sorted||(this._sorted=this.values(!0),this._sorted.sort(cM)),DXe(this._sorted,t)}}const AI=(e,t,n)=>Ug(t,"{"+h1(e,(r,i)=>`_${i}.${n}(${t});`)+"}",e);function LXe(e,t){const{ops:n,output:r}=MXe(e,t),i=e[0].fields,s=i.length,o=s===0?fM:s===1?FXe:s===2?BXe:Wt("Unsupported field count: "+s);return new o(i,n,r,t)}function MXe(e,t){const n={},r=[];function i(o,a=[]){const u=o+":"+a;if(n[u])return n[u];const l=Ose(o),c=l.create(...a);return t<0&&l.stream&&l.stream.forEach(f=>i(f,[])),l.req&&l.req.forEach(f=>i(f,[])),n[u]=c,r.push(c),c}const s=e.map(o=>{const a=i(o.name,o.params);return a.output=o.id,a});return{ops:r,output:s}}class fM extends VKe{constructor(t,n,r,i){super(r),this._op=n,this._fields=t,this._stream=!!i}init(){const t={count:0,valid:0,stream:this._stream};return this._op.forEach(n=>n.init(t)),t.values&&(t.list=new $Xe),t}write(t,n,r){const i=this._outputs,s=i.length;for(let o=0;os[a][i[u]]:a=>s[a][0];n=n.map(a=>u=>a(u,r,o))}return n}function Vg(e,t,n){if(!t.length)return n;const r=Que(t),i=e.groups(),s=i?i.size:1;return n=n||$C(t.length,()=>Array(s)),s>1?r.forEach(o=>{const a=Jue(e,o,i);for(let u=0;u{const a=Xue(e,o);o.write(a,n,0)}),n}function Que(e,t){const n=[],r={};for(const i of e){const s=i.fields.map(o=>o+"").join(",");(r[s]||(r[s]=[])).push(i)}for(const i in r)n.push(LXe(r[i],t));return n}function Xue(e,t){const n=t.init(),r=e.totalRows(),i=e.data(),s=e.mask();if(e.isOrdered()){const o=e.indices();for(let a=0;a=0;o=s.next(o+1))t.add(n,o,i);else for(let o=0;ot.init()),o=e.data();if(e.isOrdered()){const a=e.indices(),u=a.length;for(let l=0;l=0;u=a.next(u+1))t.add(s[r[u]],u,o)}else{const a=e.totalRows();for(let u=0;u>>1;e(t[s],n)<0?r=s+1:i=s}return r},right(t,n,r,i){for(r==null&&(r=0),i==null&&(i=t.length);r>>1;e(t[s],n)>0?i=s:r=s+1}return r}}}const aH=ele(cM);function jXe(e,t,n,r,i){let s,o,a,u,l;const c=m=>o[m-1]===o[m],f=r.length,d=i.length,h=r.length?Ug(["w","r","k"],"{"+h1(r,(m,y)=>`r[_${y}.id][k]=_${y}.value(w,_${y}.get);`)+"}",r):()=>{},p={i0:0,i1:0,index:0,size:0,peer:c,init(m,y,g,v){p.index=p.i0=p.i1=0,p.size=y.length,s=m,o=y,u=g,l=v,a=i?i.map(b=>b.init()):null;for(let b=0;b0&&c(p.i0)&&(p.i0=aH.left(o,o[p.i0])),p.i1(e.frame||[null,null]).map(t=>Number.isFinite(t)?Math.abs(t):null),VXe=e=>!!e.peers;function zXe(e){const{id:t,name:n,fields:r=[],params:i=[]}=e,s=Rse(n).create(...i);return r.length&&(s.get=r[0]),s.id=t,s}function HXe(e,t,n,r={},i){const s=e.data(),o=WXe(i,s),a=o.length,u=Ug(["r","d","op"],"{"+h1(t,(l,c)=>`_${c}[r] = $${c}(r, d, op);`)+"}",t,n);e.partitions().forEach((l,c)=>{const f=l.length,d=qXe(e,l);for(let p=0;pr[p][c];for(let p=0;p{const i=UXe(r),s=VXe(r),o=`${i},${s}`,{aggOps:a,winOps:u}=n[o]||(n[o]={frame:i,peers:s,aggOps:[],winOps:[]});q6(r.name)?a.push(r):u.push(zXe(r))}),Object.values(n).map(r=>jXe(t,r.frame,r.peers,r.winOps,Que(r.aggOps,r.frame[0]!=null?-1:1)))}function qXe(e,t){if(e.isOrdered()){const n=e.comparator(),r=e.data(),i=t.length,s=new Uint32Array(i);for(let o=1,a=0;oo.add(d,Array(s))),[u,l]=YXe(r),c=e.isGrouped()?e.groups().size:1,f=Vg(e,u,$C(r.length,()=>Array(c)));return l.length?HXe(e,a,n,f,l):KXe(e,a,n,f),e.create(o)}function YXe(e){const t=[],n=[],r=e.length;for(let i=0;ir[l][o[c]]:l=>r[l][0],u=t.length;for(let l=0;l=0;d=i.next(d+1))f[d]=c(d,s,a);else{const d=e.totalRows();for(let h=0;h!e.column(i)),n)}function XXe(e,t){if(t.length===0)return e;const n=e.columnNames();return t.reduce((r,i)=>r.antijoin(i.select(n)),e).dedupe()}const Hb=2147483648,JXe=4294967295;class tle{constructor(t){this._size=t,this._bits=new Uint32Array(Math.ceil(t/32))}get length(){return this._size}count(){const t=this._bits.length;let n=0;for(let r=0;r>5]&Hb>>>t}set(t){this._bits[t>>5]|=Hb>>>t}clear(t){this._bits[t>>5]&=~(Hb>>>t)}scan(t){for(let n=this.next(0);n>=0;n=this.next(n+1))t(n)}next(t){const n=this._bits,r=n.length;let i=t>>5,s=n[i]&JXe>>>t;for(;i=0;)n=this.next(n+1);return n}not(){const t=this._bits,n=t.length;for(let i=0;i>r-1),this}and(t){if(t){const n=this._bits,r=t._bits,i=n.length;for(let s=0;s=0;o=r.next(o+1))t(o,i)&&s.set(o);else for(let o=0;oi[s]}return ZXe(e,r)}function nle(e,{names:t=[],exprs:n=[],ops:r=[]},i={}){if(!t.length)return e;const s=i.limit>0?+i.limit:1/0,o=i.index?i.index===!0?"index":i.index+"":null,a=new Set(i.drop),u=Vh(e,r,n),l=Mo(),c=new Set(t),f=[],d=[],h=[];e.columnNames().forEach(S=>{if(!a.has(S)){const T=l.add(S,[]);c.has(S)||(f.push(e.column(S)),d.push(T))}}),t.forEach(S=>{a.has(S)||(l.has(S)||l.add(S,[]),h.push(l.data[S]))});const p=o?l.add(o,[]):null;let m=0;const y=f.length,g=h.length,v=(S,T)=>{for(let E=0;E{for(let E=0;E{};if(g===1){const S=u[0],T=h[0];e.scan((E,I)=>{const A=io(S(E,I)),R=Math.min(A.length,s);v(E,R);for(let F=0;F{let E=0;const I=u.map(A=>{const R=io(A(S,T));return E=Math.min(Math.max(E,R.length),s),R});v(S,E);for(let A=0;At,(u,l)=>a.map(c=>c(u,l))]},{...i,drop:t})}function Qa(e,t,n,r={window:!1}){const i=new Map,s=o=>{o=bs(o)?t.columnName(o):o,Ui(o)?i.set(o,_h(o)):sr(o)?ec(t,o).forEach(s):as(o)?Hae(i,o):Wt(`Invalid ${e} value: ${o+""}`)};return io(n).forEach(s),r.preparse&&r.preparse(i),ao(i,{table:t,...r})}function nJe(e,t,n){return tJe(e,Qa("fold",e,t),n)}function uH(e,t,n,r){const i=n&&n.length;return rJe(i?iJe(e,n,r):e,t,i)}function rJe(e,{names:t,exprs:n,ops:r},i){const s=Vh(e,r,n),o=i?null:Mo(e),a=e.totalRows();return t.forEach((u,l)=>{const c=e.column(u),f=i?c.data:o.add(u,Array(a)),d=s[l];e.scan(h=>{const p=c.get(h);f[h]=Ma(p)?p:d(h)})}),i?e:e.create(o)}function iJe(e,t,n){const r=e.groups(),i=e.data(),s=(r?r.names:[]).concat(t),o=(r?r.get:[]).concat(t.map(p=>e.getter(p))),a=new Set,u=sI(o);e.scan((p,m)=>a.add(u(p,m)));const l=e.columnNames(),c=Mo(),f=l.map(p=>c.add(p,[]));l.forEach((p,m)=>{const y=i[p],g=f[m];e.scan(v=>g.push(y.get(v)))});const d=sI(o.map((p,m)=>y=>y[m])),h=Ug("v","{"+f.map((p,m)=>`_${m}.push(v[$${m}]);`).join("")+"}",f,l.map(p=>s.indexOf(p)));if(r){let p=r.keys.length;const m=n.reduce((g,v)=>g*v.length,r.size),y=new Uint32Array(m+(p-a.size));y.set(r.keys),lH(r,n,(g,v)=>{a.has(d(g))||(h(g),y[p++]=v[0])}),c.groupby({...r,keys:y})}else lH(r,n,p=>{a.has(d(p))||h(p)});return e.create(c.new())}function lH(e,t,n){const r=e?e.get.length:0,i=e?1:0,s=i+t.length,o=new Int32Array(s),a=new Int32Array(s),u=[];if(e){const{get:c,rows:f,size:d}=e;o[0]=d,u.push((h,p)=>{const m=f[p];for(let y=0;y{const d=f+r;o[f+i]=c.length,u.push((h,p)=>h[d]=c[p])});const l=Array(r+t.length);for(let c=0;c=0;){const f=++a[c];fr[u][l],a=e.length;for(let u=0;u1){const c=i.add(e[u],Array(s));for(let f=0;fe.column(r)?0:Wt(`Invalid impute column ${el(r)}`)),n.expand){const r={preparse:aJe,aggronly:!0},i=Qa("impute",e,n.expand,r),s=hM(e.ungroup(),i);return uH(e,t,i.names,i.names.map(o=>s.get(o,0)))}else return uH(e,t)}function aJe(e){e.forEach((t,n)=>t.field?e.set(n,vse(t+"")):0)}function uJe(e,t){const n=e.columnNames();return t.length?t.reduce((r,i)=>r.semijoin(i.select(n)),e).dedupe():e.reify([])}function rle(e,t){const n=new Map;return e.scan((r,i)=>{const s=t(r,i);s!=null&&s===s&&n.set(s,r)}),n}function lJe(e,t,n){const r=new Map,i=e.length;for(let s=0;s`_${i}.push($${i}(${n}));`)+"}",e,t)}function fJe(e,t,n,{names:r,exprs:i},s={}){const o=e.data(),a=e.indices(!1),u=a.length,l=new Int32Array(u),c=t.data(),f=t.indices(!1),d=f.length,h=new Int32Array(d),p=r.length,m=Mo(),y=Array(p),g=Array(p);for(let S=0;S=c?(f=r,d=t,h=a,p=s,m=i,y=n,g=u,v=o):(f=i,d=n,h=u,p=o,m=r,y=t,g=a,v=s,b=(E,I,A,R)=>e(A,R,E,I));const S=lJe(v,m,y),T=p.length;for(let E=0;E{s=bs(s)?t.columnName(s):s,Ui(s)?r.set(o,_h(s)):sr(s)||as(s)&&s.expr?r.set(o,s):Wt(`Invalid ${e} key value: ${s+""}`)});const i=ao(r,{table:t,aggregate:!1,window:!1});return sI(i.exprs,!0)}function pJe(e,t){const n=new Set(t);return e.filter(r=>n.has(r))}function pM(e,t,n){if(n)Ui(n)?n=[n,n]:En(n)&&n.length===1&&(n=[n[0],n[0]]);else{const r=pJe(e.columnNames(),t.columnNames());r.length||Wt("Natural join requires shared column names."),n=[r,r]}return n}function ile(e,t,n,r){return n.length!==r.length&&Wt("Mismatched number of join keys"),[PI("join",e,n),PI("join",t,r)]}const mJe={aggregate:!1,window:!1},gJe={...mJe,index:1};function cH(e,t,n,r,i={}){n=pM(e,t,n);const s={join:[e,t]};let o;if(En(n)){const[a,u]=n.map(io);o=ile(e,t,a,u),r||(r=yJe(e,a,u,i))}else o=ao({on:n},s).exprs[0],r||(r=[rg(),rg()]);return fJe(e,t,o,vJe(e,t,r,s,i&&i.suffix),i)}function yJe(e,t,n,r){const i=[];t.forEach((o,a)=>Ui(o)&&o===n[a]?i.push(o):0);const s=qae(i);if(r.left&&r.right){const o=new Set(i);return[e.columnNames().map(a=>{const u=`[${el(a)}]`;return o.has(a)?{[a]:`(a, b) => a${u} == null ? b${u} : a${u}`}:a}),s]}return r.right?[s,rg()]:[rg(),s]}function vJe(e,t,n,r,i=[]){if(En(n)){let s,o,a,u=n.length;s=o=a={names:[],exprs:[]},u--&&(s=Qa("join",e,n[0],r)),u--&&(o=Qa("join",t,n[1],gJe)),u--&&(a=ao(n[2],r));const l=new Set,c=new Set(s.names);return o.names.forEach(f=>{c.has(f)&&l.add(f)}),l.size&&(i[0]!==""&&fH(s.names,l,i[0]||"_1"),i[1]!==""&&fH(o.names,l,i[1]||"_2")),{names:s.names.concat(o.names,a.names),exprs:s.exprs.concat(o.exprs,a.exprs)}}else return ao(n,r)}function fH(e,t,n){e.forEach((r,i)=>t.has(r)?e[i]=r+n:0)}function _Je(e,t,n,r={}){const i=new tle(e.totalRows());return(En(n)?bJe:wJe)(i,e,t,n),r.anti&&i.not().and(e.mask()),e.create({filter:i})}function bJe(e,t,n,[r,i]){const s=rle(n,i);t.scan((o,a)=>{s.get(r(o,a))>=0&&e.set(o)})}function wJe(e,t,n,r){const i=t.numRows(),s=n.numRows(),o=t.data(),a=n.data();if(t.isFiltered()||n.isFiltered()){const u=t.indices(!1),l=n.indices(!1);for(let c=0;ca.add(d,Array(u).fill(yn)));const l=rle(t,r),c=Ug(["lr","rr","data"],"{"+h1(i,(d,h)=>`_[${h}][lr] = $[${h}](rr, data);`)+"}",i.map(d=>a.data[d]),Vh(t,o,s)),f=t.data();return e.scan((d,h)=>{const p=l.get(n(d,h));p>=0&&c(d,p,f)}),e.create(a)}function SJe(e,t,n,r){return n=pM(e,t,n),EJe(e,t,[PI("lookup",e,n[0]),PI("lookup",t,n[1])],Qa("lookup",t,r))}const Tk=(e,t)=>e??t;function TJe(e,t,n,r={}){const{keys:i,keyColumn:s}=IJe(e,t,r),o=Tk(r.valueSeparator,"_"),a=n.names.length>1?(l,c)=>c+o+i[l]:l=>i[l],u=i.map(l=>Vg(e,n.ops.map(c=>{if(c.name==="count"){const d=h=>l===s[h]?1:NaN;return d.toString=()=>l+":1",{...c,name:"sum",fields:[d]}}const f=c.fields.map(d=>{const h=(p,m)=>l===s[p]?d(p,m):NaN;return h.toString=()=>l+":"+d,h});return{...c,fields:f}})));return e.create(xJe(n,a,e.groups(),u))}function IJe(e,t,n){const r=n.limit>0?+n.limit:1/0,i=Tk(n.sort,!0),s=Tk(n.keySeparator,"_"),o=Vh(e,t.ops,t.exprs),a=o.length===1?o[0]:(f,d)=>o.map(h=>h(f,d)).join(s),u=Array(e.totalRows());e.scan((f,d)=>u[f]=a(f,d));const l=Vg(e.ungroup(),[{id:0,name:"array_agg_distinct",fields:[f=>u[f]],params:[]}])[0][0],c=i?l.sort():l;return{keys:Number.isFinite(r)?c.slice(0,r):c,keyColumn:u}}function xJe({names:e,exprs:t},n,r,i){const s=r?r.size:1,o=Mo(),a=i.length,u=e.length;let l;const c=(f,d)=>l[f][d];r&&Zue(o,r);for(let f=0;f1)for(let h=0;ht.field?e.set(n,mse(t+"")):0)}function PJe(e,t){const n=new Map;return e.columnNames(r=>(n.set(r,r),0)),lM(e,ec(e,t,n))}function hH(e,t){return hM(e,ao(t,{table:e,aggronly:!0,window:!1}))}function OJe(e,t,n,r){return(t?r?NJe:RJe:r?DJe:kJe)(e.length,e,n,r)}function RJe(e,t,n){const r=n.length;for(let i=0;i=r)return n;for(let i=0;i=i)return n;const s=new Float32Array(i),o=new Uint32Array(i);for(let a=0;as[a]-s[u]);for(let a=0;a{let d=t(f);return a+=d=i?d:Math.min(c.length,d),d});const u=new Uint32Array(a);let l=0;return o.forEach((c,f)=>{const d=t[f],h=u.subarray(l,l+=d);!i&&d===c.length?h.set(c):OJe(h,i,c,n)}),s!==!1&&(o.length>1||!i)&&$Je(u),e.reify(u)}function MJe(e,t,n={}){return LJe(e,FJe(e,t),BJe(e,n.weight),n)}const sle=e=>t=>e.get(t)||0;function FJe(e,t){return bs(t)?()=>t:sle(hM(e,ao({size:t},{table:e,window:!1})).column("size"))}function BJe(e,t){return t==null?null:(t=bs(t)?e.columnName(t):t,sle(Ui(t)?e.column(t):dM(e,ao({w:t},{table:e}),{drop:!0}).column("w")))}function jJe(e,t){return lM(e,ec(e,t))}function UJe(e,{names:t,exprs:n,ops:r=[]},i={}){if(t.length===0)return e;const s=t.length===1&&i.as||[],o=i.drop==null?!0:!!i.drop,a=i.limit==null?s.length||1/0:Math.max(1,+i.limit||1),u=Vh(e,r,n),l=Mo(),c=t.reduce((d,h,p)=>d.set(h,p),new Map),f=(d,h)=>{const p=VJe(e,u[d],a),m=p.length;for(let y=0;y{c.has(d)?(o||l.add(d,e.column(d)),f(c.get(d),d),c.delete(d)):l.add(d,e.column(d))}),c.forEach(f),e.create(l)}function VJe(e,t,n){const r=e.totalRows(),i=[];return e.scan((s,o)=>{const a=io(t(s,o)),u=Math.min(a.length,n);for(;i.length=0;h=d.next(h+1)){const p=o(h,f)+"",m=l[p];u[h]=m??(l[p]=c.push(h)-1)}else for(let h=0;hp=>h(p,f))),{keys:u,get:s,names:t,rows:c,size:c.length}}function YJe(e,t){return qJe(e,Qa("groupby",e,t))}function KJe(e,t){return e.create({order:t})}const QJe=(e,t,n,r)=>`((u = ${e}) < (v = ${t}) || u == null) && v != null ? ${n} : (u > v || v == null) && u != null ? ${r} : ((v = v instanceof Date ? +v : v), (u = u instanceof Date ? +u : u)) !== u && v === v ? ${n} - : v !== v && u === u ? ${r} : `;function QJe(e,t){const n=[],r=[],i=[];let s=null,o="0",a="0";e.isGrouped()&&(s=e.groups().keys,o="ka",a="kb");const{ops:u}=ao(t,{table:e,value:(h,p)=>{if(n.push(h),p.escape){const m=y=>`fn[${i.length}](${y}, data)`;r.push([m("a"),m("b")]),i.push(p.escape)}else r.push([iI(p,{index:"a",op:o}),iI(p,{index:"b",op:a})])},window:!1}),l=Vg(e,u),c=(h,p)=>l[h][p],f=n.length;let d="return (a, b) => {"+(c&&e.isGrouped()?"const ka = keys[a], kb = keys[b];":"")+"let u, v; return ";for(let h=0;hr.set(++n+"",s);return t.forEach(s=>{const o=s.expr!=null?s.expr:s;if(as(o)&&!sr(o))for(const a in o)i(o[a]);else i(bs(o)?_h(s,e.columnName(o)):Ui(o)?_h(s):sr(o)?s:Wt(`Invalid orderby field: ${s+""}`))}),QJe(e,r)}function ZJe(e,t){const n=e.numRows(),r=n+t.reduce((o,a)=>o+a.numRows(),0);if(n===r)return e;const i=[e,...t],s=Mo();return e.columnNames().forEach(o=>{const a=Array(r);let u=0;i.forEach(l=>{const c=l.column(o)||{get:()=>yn};l.scan(f=>a[u++]=c.get(f))}),s.add(o,a)}),e.create(s.new())}function eZe(e,t){const n=Mo(),r=e.groups(),{get:i,names:s=[],rows:o,size:a=1}=r||{},u=new Uint32Array(a+1);s.forEach(d=>n.add(d,null));const l=r?Jue(e,t,r):[Xue(e,t)];t.outputs().map(d=>n.add(d,[]));const c=u.length-1;let f=0;for(let d=0;d{const m=n.data[h]=Array(f),y=i[p];for(let g=0,v=0;gdH(e,t,n,{anti:!0}),__count:(e,t={})=>hH(e,{[t.as||"count"]:gse()}),__cross:(e,t,n,r)=>cH(e,t,()=>!0,n,{...r,left:!0,right:!0}),__concat:ZJe,__dedupe:OXe,__derive:KXe,__except:QXe,__filter:ZXe,__fold:tJe,__impute:sJe,__intersect:aJe,__join:cH,__lookup:EJe,__pivot:xJe,__relocate:Kue,__rename:AJe,__rollup:hH,__sample:LJe,__select:BJe,__semijoin:dH,__spread:VJe,__union:zJe,__unroll:HJe,__groupby:GJe,__orderby:XJe,__ungroup:tZe,__unorder:nZe,__reduce:eZe};Object.assign(Al.prototype,rZe);function iZe(e,t){return Al.from(e,t)}function sZe(e){return tA(e,{escape:!0,toString(){Wt("Escaped values can not be serialized.")}})}Al.prototype;const Sa={top:30,left:60,right:80,bottom:50};function ole({data:e,selection:t,parameters:n,dataname:r}){const o=w.useMemo(()=>{const c=e.map(f=>({...f,value:+f[n.y_var]}));return iZe(c)},[e,n]),a=w.useMemo(()=>{const c=Pf(o.filter(sZe(f=>t.includes(f[n.cat_var]))).array("value"));return r==="clean_stocks"?c:[0,c[1]]},[o,t,n,r]),u=w.useMemo(()=>mh([Sa.top,400-Sa.bottom]).domain(Pf(o.array("value")).reverse()),[o,400]),l=yf(r==="clean_stocks"?".0%":",.0f");return(t==null?void 0:t.length)===0?null:C.jsxs("svg",{style:{height:"400px",width:"60px",overflow:"visible"},children:[C.jsx("rect",{y:u(a[1]),height:u(a[0])-u(a[1]),x:Sa.left-10,width:10,opacity:.1,fill:"black"}),C.jsx("text",{style:{fontSize:10,dominantBaseline:"middle",textAnchor:"middle",fontFamily:'"Helvetica Neue", Helvetica, Arial, sans-serif'},x:25,y:Sa.top-5,children:l(u.domain()[0])}),C.jsx("text",{style:{fontSize:10,dominantBaseline:"middle",textAnchor:"middle",fontFamily:'"Helvetica Neue", Helvetica, Arial, sans-serif'},x:25,y:400-Sa.bottom+8,children:l(u.domain()[1])}),C.jsx("text",{style:{fontSize:10,dominantBaseline:"middle",fontFamily:'"Helvetica Neue", Helvetica, Arial, sans-serif'},x:Sa.left-5,y:u(a[0]),children:l(a[0])}),C.jsx("text",{style:{fontSize:10,dominantBaseline:"middle",fontFamily:'"Helvetica Neue", Helvetica, Arial, sans-serif'},x:Sa.left-5,y:u(a[1]),children:l(a[1])}),e.map(c=>C.jsx("rect",{opacity:.2,fill:+c[n.y_var]>0?"steelblue":"firebrick",x:0,width:50,y:u(+c[n.y_var]),height:1},"strip")),C.jsx("line",{strokeWidth:2,stroke:"black",style:{fontSize:10,dominantBaseline:"middle"},x1:0,x2:50,y1:u(a[0]),y2:u(a[0])}),C.jsx("line",{strokeWidth:2,stroke:"black",x1:0,x2:50,y1:u(a[1]),y2:u(a[1])}),C.jsx("line",{strokeWidth:2,stroke:"black",x1:0,x2:0,y1:u(a[1]),y2:u(a[0])}),C.jsx("line",{strokeWidth:2,stroke:"black",x1:50,x2:50,y1:u(a[1]),y2:u(a[0])}),C.jsx("path",{fill:"black",opacity:"0.1",d:`M${Sa.left}, ${u(a[1])} L 113, ${Sa.top} L 113, ${400-Sa.bottom} L ${Sa.left}, ${u(a[0])}`})]})}const oZe=Object.freeze(Object.defineProperty({__proto__:null,StripPlot:ole},Symbol.toStringTag,{value:"Module"}));function ale({parameters:e}){const t=e.dataset==="clean_data"?C.jsxs(Y0,{children:["Select any subset of countries to the left of the visualization to support the prompt at the top of the page.",C.jsx("h4",{children:"Background:"}),"You live in a fantasy world that consists of your home country, as well as other 15 countries located across 5 continents: Eldoril, Thundoril, Aerion, Silvoria, and Mystara. Countries within each continent are similar to each other in size and demographics.",C.jsx("h4",{children:"Scenario:"}),"You are an analyst for the Viral Disease Policy Center of your home country at time when there is a new viral disease called",C.jsx("i",{children:" Celestial Sniffles"}),". Luckily, your country has not been affected yet and has time to prepare and decide on a policy to combat it. You have access to the infection data from other countries that implemented one of the 3 available policies: A, B, or C. However, due to socioeconomic factors, the Surgeon General in your country has",C.jsx("i",{children:" already decided on a policy"}),".",C.jsx("h4",{children:"Task:"}),"You are tasked with leading the promotion efforts that make the case for the chosen policy. In the experiment, you will use an interactive data explorer that shows infection data from other countries. You should select a view that best shows (and convinces the population) that your country's"," ",C.jsx("b",{children:"chosen policy is the best policy to combat the disease"}),". After finalizing the view, click the camera button and add a caption or a slogan that will go along with your visualization."]}):C.jsxs(Y0,{children:["Select any subset of stocks to the left of the visualization to support the prompt at the top of the page.",C.jsx("h4",{children:"Scenario:"})," ","You are a financial advisor. Your client approached you asking for help in picking a new investment—an industry fund that equally invests within a single industry. The client prefers to make their decisions"," ",C.jsx("i",{children:"solely based on the data"}),", and not based on any inside knowledge about the type of industry. However, your boss"," ",C.jsx("i",{children:"does"})," ","have inside knowledge and orders you to recommend a specific industry (which is ultimately in the best interest of the client). You cannot disclose this to the client and have to use data to support your recommendations.",C.jsx("h4",{children:"Task:"})," ","In the experiment, you will use an interactive data explorer that shows performance of different stocks from a variety of industries. You should select a view that best shows (and convinces your client) that"," ",C.jsx("b",{children:"the chosen industry fund would be the best investment with the highest returns"}),". After finalizing the view, click the camera button and add a caption or a slogan that will go along with your visualization."]}),n=e.dataset==="clean_data"?C.jsxs(Y0,{children:[C.jsx("h4",{children:"Background:"}),"You live in a fantasy world that consists of your home country, as well as other 15 countries located across 5 continents: Eldoril, Thundoril, Aerion, Silvoria, and Mystara. Countries within each continent are similar to each other in size and demographics.",C.jsx("h4",{children:"Scenario:"}),"There's a new viral disease called"," ",C.jsx("i",{children:"Celestial Sniffles"}),". Most countries in the world have adopted one of 3 major disease containment policies: A, B, or C. Luckily, your country has not been affected yet but you may need to travel to one of the affected countries for work. Afraid of getting sick and stuck abroad with a huge hospital bill, you decide to purchase a traveler's health insurance policy. The price of the policy is very flexible and depends on the amount of coverage you'll get: anywhere between $0 (no coverage) to $100 (full coverage). Since you are not familiar with the disease trends or containment policies, you turn to social media to read what people shared about recent infection rates.",C.jsx("h4",{children:"Task:"}),"In the experiment, you will see a set of visualizations that show infection rates in different countries that adopted one of the containment policies A, B, or C. You can refer to the list of countries to the left of the visualization to see which country adopted which Policy. Based on each visualization, you will be asked to decide"," ",C.jsx("b",{children:"how much to spend on your insurance policy"})," ","and"," ",C.jsx("b",{children:"answer a short survey"}),"."]}):C.jsxs(Y0,{children:[C.jsx("h4",{children:"Scenario:"}),"You have $100 that you would like to invest in"," ",C.jsx("i",{children:"industry funds"})," ","but are not sure how to best allocate that money. An industry fund is composed of all individual stocks pertaining to that industry (e.g., a Pharma fund is composed of Pharma A, Pharma B, and Pharma C stocks). Since you are not familiar with the current market, you turn to social media to read what people shared about recent stock performance.",C.jsx("h4",{children:"Task:"}),"In the experiment, you will see a set of visualizations that show performance of different stocks from a variety of industries. Based on each visualization, you will be asked to decide"," ",C.jsx("b",{children:"how much to invest in a given industry fund"})," ","and"," ",C.jsx("b",{children:"answer a short survey"}),"."]});return C.jsx(ei,{position:"right",children:C.jsxs(em,{width:800,shadow:"md",children:[C.jsx(em.Target,{children:C.jsx(Ws,{variant:"light",color:"gray",compact:!0,children:"Help"})}),C.jsx(em.Dropdown,{children:C.jsx(rt,{size:"sm",children:e.allow_selection?t:n})})]})})}const aZe=Object.freeze(Object.defineProperty({__proto__:null,Help:ale},Symbol.toStringTag,{value:"Module"}));function pH({parameters:e,setAnswer:t}){const[n,r]=w.useState(null),[i,s]=w.useState(e.dataset),[o,a]=w.useState(e.initial_selection),[u,l]=w.useState(null),[c,f]=w.useState([new Date(e.start_date),new Date(e.end_date)]),[d,h]=w.useState(e.guardrail);w.useEffect(()=>{a7e(`./data/${i}.csv`).then(T=>{r(T),l(Array.from(new Set(T.map(E=>JSON.stringify({name:E[e.cat_var],group:E[e.group_var]})))).map(E=>JSON.parse(E)))})},[i,e]);const p=w.useMemo(()=>n&&c?n.filter(T=>new Date(T[e.x_var]).getTime()>=c[0].getTime()).filter(T=>new Date(T[e.x_var]).getTime()<=c[1].getTime()):null,[n,c,e.x_var,i]),m=T=>{s(T),a([])},{actions:y,trrack:g}=w.useMemo(()=>{const T=DC.create(),E=T.register("selection",(R,F)=>(R.selection=F,R)),I=T.register("range",(R,F)=>(R.range=F,R)),A=ise({registry:T,initialState:{selection:[],range:[e.start_date,e.end_date]}});return{actions:{selection:E,range:I},trrack:A}},[e.end_date,e.start_date]),v=w.useCallback(T=>{g.apply("Change daterange",y.range([T[0].toISOString().slice(0,10),T[1].toISOString().slice(0,10)]))},[g,y]),b=w.useMemo(()=>ou(v,200),[v]),S=w.useCallback(T=>{g.apply("Change selection",y.selection(T)),t({status:!0,provenanceGraph:g.graph.backend,answers:{}})},[g,y,t]);return p&&u&&c&&o?C.jsxs(ys,{children:[e.allow_guardrail_selector?C.jsx(wS,{shadow:"sm",radius:"md",p:"md",style:{width:"500px"},children:C.jsx(ik,{guardrail:d,setGuardrail:h,dataname:i,setDataname:m,setSelection:a})}):null,C.jsx(Fm,{children:C.jsxs(wS,{shadow:"md",radius:"md",p:"md",withBorder:!0,children:[e.caption===""?null:C.jsx(Fm,{style:{width:"800px"},children:e.caption?C.jsx(wJ,{children:e.caption}):null}),C.jsxs(ei,{noWrap:!0,children:[e.allow_selection===!1&&e.guardrail!=="juxt_data"?null:C.jsx(ei,{noWrap:!0,children:C.jsx(nk,{parameters:e,data:p,dataname:i,items:u,selection:o,setSelection:a,trackSelection:S,range:c,guardrail:d})}),e.allow_selection===!1&&e.guardrail!=="juxt_data"?null:C.jsx(df,{orientation:"vertical",size:"xs"}),C.jsxs(ys,{children:[C.jsxs(ei,{position:"apart",children:[C.jsxs(ys,{spacing:0,justify:"flex-start",children:[C.jsx(rt,{fw:500,children:i==="clean_stocks"?"Percent change in stock price":"Infections per million people"}),d==="super_summ"?C.jsx(rt,{fz:"xs",c:"dimmed",children:"Shaded area represents the middle 50% of all values."}):null,d==="juxt_summ"?C.jsx(rt,{fz:"xs",c:"dimmed",children:"Bar on the left highlights the range of selection among all data."}):null]}),e.allow_help?C.jsx(ale,{parameters:e}):null]}),C.jsxs(ys,{children:[C.jsxs(ei,{noWrap:!0,children:[d==="juxt_summ"?C.jsx(ole,{parameters:e,data:p,selection:o,dataname:i}):null,C.jsx(tk,{parameters:e,data:p,dataname:i,items:u,selection:o,range:c,guardrail:d})]}),e.allow_time_slider?C.jsx("div",{style:{width:"500px"},children:C.jsx(rk,{parameters:e,setRange:f,trackRange:b})}):null]})]})]})]})})]}):C.jsx(Xf,{})}const uZe=Object.freeze(Object.defineProperty({__proto__:null,DataExplorer:pH,default:pH},Symbol.toStringTag,{value:"Module"})),lZe=Object.assign({"../public/viz-guardrails/AudioTest.tsx":oVe,"../public/viz-guardrails/Color.tsx":aVe,"../public/viz-guardrails/DataExplorer.tsx":uZe,"../public/viz-guardrails/Help.tsx":aZe,"../public/viz-guardrails/LineChart.tsx":JHe,"../public/viz-guardrails/RangeSelector.tsx":eWe,"../public/viz-guardrails/Selector.tsx":tWe,"../public/viz-guardrails/Sidebar.tsx":ZHe,"../public/viz-guardrails/StripPlot.tsx":oZe,"../public/viz-guardrails/XAxis.tsx":QHe,"../public/viz-guardrails/YAxis.tsx":XHe});function cZe({currentConfig:e,provState:t}){const n=hl(),r=`../public/${e.path}`,i=lZe[r].default,s=Ju(),{updateResponseBlockValidation:o,setIframeAnswers:a}=Xu(),u=w.useCallback(({status:l,provenanceGraph:c,answers:f})=>{s(o({location:"sidebar",currentStep:n,status:l,values:f,provenanceGraph:c})),s(a(Object.values(f).map(d=>d)))},[s,o,n,a]);return C.jsx(w.Suspense,{fallback:C.jsx("div",{children:"Loading..."}),children:C.jsx(i,{parameters:e.parameters,setAnswer:u,provenanceState:t})})}function fZe({currentConfig:e}){const[t,n]=w.useState(null);return w.useEffect(()=>{fetch(`${fl}${e.path}`).then(r=>r.text()).then(r=>n(r))},[e]),t===null?null:C.jsx("div",{style:{maxWidth:700,margin:"0 0"},children:C.jsx(ro,{text:t})})}function bh(){return la(e=>e.config)}function ule(){const e=hl(),{setAlertModal:t}=Xu(),n=Ju();w.useEffect(()=>{(new URLSearchParams(window.location.search).get("admin")||"f")==="t"||(window.history.pushState(null,"",window.location.href),window.onpopstate=()=>{window.history.pushState(null,"",window.location.href),n(t({show:!0,message:"Using the browser's back button is prohibited during the study."}))})},[e,t,n])}function lle({provState:e}){var S;const t=bh(),n=sa(),{trialName:r}=uh(),i=t.components[r],s=e6(),o=uC(i)&&t.baseComponents?Z3({},(S=t.baseComponents)==null?void 0:S[i.baseComponent],i):i,a=o.instruction||"",{instructionLocation:u}=o,l=t.uiConfig.sidebar&&(u==="sidebar"||u===void 0),[c,f]=w.useState(null),d=Ju(),{setIsRecording:h}=Xu(),{trialName:p}=uh(),[m,y]=w.useState(null);w.useEffect(()=>{!p||!t||!t.recordStudyAudio||!n.storageEngine||(c&&m&&n.storageEngine.saveAudio(c,m),t.tasksToNotRecordAudio&&t.tasksToNotRecordAudio.includes(p)?(y(null),f(null),d(h(!1))):(navigator.mediaDevices.getUserMedia({audio:!0}).then(E=>{const I=new MediaRecorder(E);I.start(),f(I),d(h(!0))}),y(p)))},[p]),ule();const{storageEngine:g}=sa(),v=Ju(),{setAlertModal:b}=Xu();return w.useEffect(()=>{(g==null?void 0:g.getEngine())!=="firebase"&&v(b({show:!0,message:"There was an issue connecting to the firebase database. This could be caused by a network issue or your adblocker. If you are using an adblocker, please disable it for this website and refresh."}))},[b,g,v]),C.jsxs(C.Fragment,{children:[u==="aboveStimulus"&&C.jsx(ro,{text:a}),C.jsx(UT,{status:s,config:o,location:"aboveStimulus"},`${r}-above-response-block`),C.jsxs(w.Suspense,{fallback:C.jsx("div",{children:"Loading..."}),children:[o.type==="markdown"&&C.jsx(fZe,{currentConfig:o}),o.type==="website"&&C.jsx(rVe,{currentConfig:o}),o.type==="image"&&C.jsx(sVe,{currentConfig:o}),o.type==="react-component"&&C.jsx(cZe,{currentConfig:o,provState:e})]},`${r}-stimulus`),(u==="belowStimulus"||u===void 0&&!l)&&C.jsx(ro,{text:a}),C.jsx("div",{style:{maxWidth:800,margin:"0 0"},children:C.jsx(UT,{status:s,config:o,location:"belowStimulus"},`${r}-below-response-block`)})]})}function dZe(e){const[t]=p$();return C.jsx(c0e,{...e,to:{pathname:e.to,search:t.toString()}})}function hZe(){const e=bh(),{storageEngine:t}=sa(),{answers:n}=la(s=>s),[r,i]=w.useState(!1);return w.useEffect(()=>{const s=setInterval(async()=>{await t.verifyCompletion(n)&&(i(!0),clearInterval(s))},1e3)},[]),ule(),C.jsx(ua,{style:{height:"100%"},children:C.jsx(Fm,{direction:"column",children:r?C.jsx(rt,{size:"xl",display:"block",children:e.uiConfig.studyEndMsg?C.jsx(ro,{text:e.uiConfig.studyEndMsg}):"Thank you for completing the study. You may close this window now."}):C.jsxs(C.Fragment,{children:[C.jsx(rt,{size:"xl",display:"block",children:"Please wait while your answers are uploaded."}),C.jsx(bT,{h:"lg"}),C.jsx(ua,{children:C.jsx(Xf,{color:"blue"})})]})})})}function pZe(e,t=!1){return typeof e=="number"?mH(e,t):mH(e.length,t).map(r=>r.map(i=>e[i]))}function mH(e,t){if(e<0)throw new Error("Latin square size must be > 0");if(e==0)return[];if(e==1)return[[0]];let n=new Array(e);for(let s=0;s(a+1)%e);r.push(o),i=o}if(t&&e%2>0)for(let s=0;s.5-Math.random());e.components=r}else e.order==="latinSquare"&&t&&(e.components=t[n].pop().map(r=>r.startsWith("_orderObj")?e.components[+r.slice(9)]:r));return e.components.slice(0,e.numSamples?e.numSamples:void 0).flat()}function mZe(e,t){const n=Ig(e);return cle(n,t,"root"),n.components.slice(0,n.numSamples?n.numSamples:void 0).flat()}function fle(e,t,n,r=0){const i=n.length>0?`${n}-${r}`:"root";e.order==="latinSquare"&&t.push(i),e.components.forEach((s,o)=>{typeof s!="string"&&fle(s,t,i,o)})}function gZe(e){const t=[];return fle(e,t,"",0),t}function gH(e,t){const n=t.split("-");let r={};n.forEach(o=>{o==="root"?r=e.sequence:r=r.components[+o]});const i=r.components.map((o,a)=>typeof o=="string"?o:`_orderObj${a}`);return pZe(i.sort(()=>.5-Math.random()),!0)}function yZe(e){const n=gZe(e.sequence).map(s=>({[s]:gH(e,s)})).reduce((s,o)=>({...s,...o}),{}),r=e.uiConfig.numSequences||1e3,i=[];return Array.from({length:r}).forEach(()=>{const s=mZe(e.sequence,n);s.push("end"),i.push(s),Object.entries(n).forEach(([o,a])=>{a.length===0&&(n[o]=gH(e,o))})}),i}var vZe={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"},_Ze=Object.defineProperty,bZe=Object.defineProperties,wZe=Object.getOwnPropertyDescriptors,OI=Object.getOwnPropertySymbols,dle=Object.prototype.hasOwnProperty,hle=Object.prototype.propertyIsEnumerable,yH=(e,t,n)=>t in e?_Ze(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,vH=(e,t)=>{for(var n in t||(t={}))dle.call(t,n)&&yH(e,n,t[n]);if(OI)for(var n of OI(t))hle.call(t,n)&&yH(e,n,t[n]);return e},EZe=(e,t)=>bZe(e,wZe(t)),SZe=(e,t)=>{var n={};for(var r in e)dle.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&OI)for(var r of OI(e))t.indexOf(r)<0&&hle.call(e,r)&&(n[r]=e[r]);return n},rd=(e,t,n)=>{const r=w.forwardRef((i,s)=>{var o=i,{color:a="currentColor",size:u=24,stroke:l=2,children:c}=o,f=SZe(o,["color","size","stroke","children"]);return w.createElement("svg",vH(EZe(vH({ref:s},vZe),{width:u,height:u,stroke:a,strokeWidth:l,className:`tabler-icon tabler-icon-${e}`}),f),[...n.map(([d,h])=>w.createElement(d,h)),...c||[]])});return r.propTypes={color:gt.string,size:gt.oneOfType([gt.string,gt.number]),stroke:gt.oneOfType([gt.string,gt.number])},r.displayName=`${t}`,r},TZe=rd("alert-circle","IconAlertCircle",[["path",{d:"M3 12a9 9 0 1 0 18 0a9 9 0 0 0 -18 0",key:"svg-0"}],["path",{d:"M12 8v4",key:"svg-1"}],["path",{d:"M12 16h.01",key:"svg-2"}]]),IZe=rd("arrows-shuffle","IconArrowsShuffle",[["path",{d:"M18 4l3 3l-3 3",key:"svg-0"}],["path",{d:"M18 20l3 -3l-3 -3",key:"svg-1"}],["path",{d:"M3 7h3a5 5 0 0 1 5 5a5 5 0 0 0 5 5h5",key:"svg-2"}],["path",{d:"M21 7h-5a4.978 4.978 0 0 0 -3 1m-4 8a4.984 4.984 0 0 1 -3 1h-3",key:"svg-3"}]]),xZe=rd("code-dots","IconCodeDots",[["path",{d:"M15 12h.01",key:"svg-0"}],["path",{d:"M12 12h.01",key:"svg-1"}],["path",{d:"M9 12h.01",key:"svg-2"}],["path",{d:"M6 19a2 2 0 0 1 -2 -2v-4l-1 -1l1 -1v-4a2 2 0 0 1 2 -2",key:"svg-3"}],["path",{d:"M18 19a2 2 0 0 0 2 -2v-4l1 -1l-1 -1v-4a2 2 0 0 0 -2 -2",key:"svg-4"}]]),CZe=rd("code-plus","IconCodePlus",[["path",{d:"M9 12h6",key:"svg-0"}],["path",{d:"M12 9v6",key:"svg-1"}],["path",{d:"M6 19a2 2 0 0 1 -2 -2v-4l-1 -1l1 -1v-4a2 2 0 0 1 2 -2",key:"svg-2"}],["path",{d:"M18 19a2 2 0 0 0 2 -2v-4l1 -1l-1 -1v-4a2 2 0 0 0 -2 -2",key:"svg-3"}]]),AZe=rd("dots-vertical","IconDotsVertical",[["path",{d:"M12 12m-1 0a1 1 0 1 0 2 0a1 1 0 1 0 -2 0",key:"svg-0"}],["path",{d:"M12 19m-1 0a1 1 0 1 0 2 0a1 1 0 1 0 -2 0",key:"svg-1"}],["path",{d:"M12 5m-1 0a1 1 0 1 0 2 0a1 1 0 1 0 -2 0",key:"svg-2"}]]),PZe=rd("mail","IconMail",[["path",{d:"M3 7a2 2 0 0 1 2 -2h14a2 2 0 0 1 2 2v10a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-10z",key:"svg-0"}],["path",{d:"M3 7l9 6l9 -6",key:"svg-1"}]]),_H=rd("schema","IconSchema",[["path",{d:"M5 2h5v4h-5z",key:"svg-0"}],["path",{d:"M15 10h5v4h-5z",key:"svg-1"}],["path",{d:"M5 18h5v4h-5z",key:"svg-2"}],["path",{d:"M5 10h5v4h-5z",key:"svg-3"}],["path",{d:"M10 12h5",key:"svg-4"}],["path",{d:"M7.5 6v4",key:"svg-5"}],["path",{d:"M7.5 14v4",key:"svg-6"}]]),ple=rd("table","IconTable",[["path",{d:"M3 5a2 2 0 0 1 2 -2h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14z",key:"svg-0"}],["path",{d:"M3 10h18",key:"svg-1"}],["path",{d:"M10 3v18",key:"svg-2"}]]);const xk=["description","instruction","answer","correctAnswer","startTime","endTime","duration","taskOrder"],Yw=["participantId","trialId","responseId"];function Kw(e,t){const n=`data:text/json;charset=utf-8,${encodeURIComponent(e)}`,r=document.createElement("a");r.setAttribute("href",n),r.setAttribute("download",t),document.body.appendChild(r),r.click(),r.remove()}function OZe(e,t,n){return Object.entries(t.components).map(([r,i])=>{const s=uC(i)&&i.baseComponent&&t.baseComponents?Z3({},t.baseComponents[i.baseComponent],i):i,o=e.answers[r],a=o!==void 0?o:{answer:{},startTime:-1,endTime:-1,windowEvents:[]},u=a.endTime-a.startTime;return Object.entries(a.answer).map(([c,f])=>{const d={participantId:e.participantId,trialId:r,responseId:c,startTime:new Date(a.startTime).toUTCString(),endTime:new Date(a.endTime).toUTCString(),duration:u};return n.includes("description")&&(d.description=s.description),n.includes("instruction")&&(d.instruction=s.instruction),n.includes("answer")&&(d.answer=f),n.includes("correctAnswer")&&(d.correctAnswer=s.correctAnswer),n.includes("taskOrder")&&(d.taskOrder=e.sequence.indexOf(r)),d}).flat()}).flat()}async function RZe(e,t,n,r=[...Yw,...xk]){const s=(await t.getAllParticipantsData()).map(l=>OZe(l,n,r)).flat(),o=l=>l.replace(/"/g,'""'),a=s.map(l=>r.map(c=>l===null?"":typeof l[c]=="string"?`"${o(l[c])}"`:JSON.stringify(l[c])).join(",")),u=[r.join(","),...a].join(` -`);Kw(u,e)}function NZe({opened:e,close:t,filename:n,studyConfig:r}){const[i,s]=e_e([...Yw,...xk]),o=w.useCallback(l=>{Yw.every(c=>l.includes(c))&&s(l)},[s]),a=w.useMemo(()=>[...Yw,...xk],[]),{storageEngine:u}=sa();return u?C.jsxs(zx,{opened:e,size:"lg",onClose:t,title:C.jsx(rt,{size:"xl",children:"Download Tidy CSV"}),centered:!0,radius:"md",padding:"xl",children:[C.jsx(it,{children:C.jsx(See,{searchable:!0,limit:30,nothingFound:"Property not found",data:a,value:i,onChange:o,label:C.jsx(rt,{fw:"bold",size:"lg",children:"Select properties to include in tidy csv:"}),placeholder:"Select atleast one property"})}),C.jsxs(Fm,{mt:"xl",direction:{base:"column",sm:"row"},gap:{base:"sm",sm:"lg"},justify:{sm:"space-around"},children:[C.jsx(Ws,{leftIcon:C.jsx(ple,{}),onClick:()=>RZe(n,u,r,i),children:"Download"}),C.jsx(Ws,{onClick:t,color:"red",children:"Close"})]})]}):null}function kZe({studyConfig:e}){const{storageEngine:t}=sa(),[n,{open:r,close:i}]=x$(!1),[s,o]=w.useState(),[a,u]=w.useState(""),l=e.studyMetadata.title.replace(" ","_");w.useEffect(()=>{async function m(){if(t){const y=await t.getCurrentParticipantId(),g=await t.getParticipantData();u(y),o(g)}}m()},[t]);const c=w.useCallback(async()=>{Kw(JSON.stringify(s,null,2),`${l}_${a}.json`)},[s]),f=e.uiConfig.autoDownloadStudy||!1,d=f&&e.uiConfig.autoDownloadTime||-1,[h,p]=w.useState(Math.floor(d/1e3));return w.useEffect(()=>{const m=setInterval(()=>{p(y=>y-1)},1e3);return h<=0?(c(),clearInterval(m),()=>clearInterval(m)):()=>clearInterval(m)},[h]),C.jsxs(ys,{children:[C.jsx(Ws,{leftIcon:C.jsx(xZe,{}),onClick:()=>Kw(JSON.stringify(s,null,2),`${l}_${a}.json`),display:"block",children:"Download Current (JSON)"}),C.jsx(Ws,{disabled:!(t!=null&&t.isConnected()),leftIcon:C.jsx(CZe,{}),onClick:async()=>{if(!t)return;const m=await t.getAllParticipantsData();Kw(JSON.stringify(m,null,2),`${l}_all.json`)},display:"block",children:"Download All (JSON)"}),C.jsx(Ws,{disabled:!(t!=null&&t.isConnected()),leftIcon:C.jsx(ple,{}),onClick:r,display:"block",children:"Download All (Tidy)"}),f&&C.jsxs(rt,{size:"lg",children:["Study results will be downloaded in"," ",h," ","seconds. If the download does not start automatically, click above to download."]}),C.jsx(NZe,{opened:n,close:i,filename:`${l}_${a}.csv`,studyConfig:e})]})}function nA(e){return e.components.flatMap(t=>typeof t=="string"?t:nA(t))}function bH(e,t){return nA(t).find(i=>e.indexOf(i)!==-1)}function DZe(e,t){return nA(t).filter(i=>e.indexOf(i)!==-1)}function $Ze({step:e,currentStep:t,sequence:n,task:r,studyId:i}){const s=Kf(),[o,{close:a,open:u}]=x$(!1);return C.jsxs(yi,{position:"left",withArrow:!0,arrowSize:10,shadow:"md",opened:o,offset:20,children:[C.jsx(yi.Target,{children:C.jsx("div",{onMouseEnter:u,onMouseLeave:a,children:C.jsx(Cee,{active:e===t,style:{lineHeight:"32px",height:"32px"},label:C.jsx("div",{style:{opacity:n.indexOf(e)===-1?".3":1},children:e===t?C.jsx("strong",{children:e}):e}),onClick:()=>s(`/${i}/${e}`),disabled:n.indexOf(e)===-1})})}),r&&(r.description||r.meta)&&lc.createPortal(C.jsx(yi.Dropdown,{onMouseLeave:a,children:C.jsx(rt,{size:"sm",children:C.jsxs("div",{children:[r.description&&C.jsxs("div",{children:[C.jsx(rt,{fw:900,display:"inline-block",mr:2,children:"Description:"}),C.jsx(rt,{fw:400,component:"span",children:r.description})]}),r.meta&&C.jsxs(rt,{children:[C.jsx(rt,{fw:"900",component:"span",children:"Task Meta: "}),C.jsx("pre",{style:{margin:0,padding:0},children:`${JSON.stringify(r.meta,null,2)}`})]})]})})}),document.body)]})}function mle({sequence:e,order:t,depth:n=0}){const{studyId:r=null}=uh(),i=hl(),s=bh(),o=w.useMemo(()=>{const a=Ig(t);return a.components.sort((u,l)=>{const c=typeof u=="string"?u:bH(e,u),f=typeof l=="string"?l:bH(e,l),d=c?e.indexOf(c):1e4,h=f?e.indexOf(f):1e4;return(d===-1?1e4:d)-(h===-1?1e4:h)}),a},[t,e]);return C.jsx("div",{children:o.components.map((a,u)=>{if(typeof a=="string"){const f=a in s.components&&s.components[a];return C.jsx($Ze,{currentStep:i,sequence:e,step:a,studyId:r,task:f},u)}const l=nA(a),c=DZe(e,a);return C.jsx(Cee,{label:C.jsxs("div",{style:{opacity:c.length?1:.5},children:["Group:",C.jsxs(_Ie,{ml:5,children:[c.length,"/",l.length]}),C.jsx(rt,{c:"dimmed",display:"inline",mr:5,ml:5,children:a.order}),a.order==="random"||a.order==="latinSquare"?C.jsx(IZe,{size:"15",opacity:.5,style:{marginLeft:"5px",verticalAlign:"middle"}}):null]}),defaultOpened:!0,childrenOffset:32,style:{lineHeight:"32px",height:"32px",position:"sticky",top:`${32*n}px`,backgroundColor:"#fff"},children:C.jsx("div",{style:{borderLeft:"1px solid #e9ecef"},children:C.jsx(mle,{order:a,sequence:e,depth:n+1})})},u)})})}function LZe(){const{showAdmin:e,sequence:t}=la(s=>s),n=hl(),r=bh(),i=w.useMemo(()=>{const s=Ig(r.sequence);return s.components.push("end"),s},[r.sequence]);return e||n==="end"&&r.uiConfig.autoDownloadStudy?C.jsx(A$,{p:"0",width:{base:300},style:{zIndex:0},children:C.jsxs(N$,{p:"0",children:[n==="end"&&C.jsxs("div",{style:{padding:10,paddingBottom:15,borderBottom:"1px solid #e9ecef"},children:[C.jsx(rt,{size:"md",p:10,weight:"bold",children:"Download"}),C.jsx(kZe,{studyConfig:r})]}),C.jsx(rt,{size:"md",p:10,weight:"bold",children:"Study Sequence"}),C.jsx(mle,{order:i,sequence:t})]})}):null}const gle=w.createContext(null),gM=({id:e="waveform",children:t})=>N.createElement("div",{id:e},t),MZe=["audioRate","audioContext","audioScriptProcessor","autoCenter","backend","backgroundColor","barGap","barHeight","barMinHeight","barRadius","barWidth","closeAudioContext","cursorColor","cursorWidth","fillParent","forceDecode","height","hideScrollbar","interact","loopSelection","maxCanvasWidth","mediaControls","mediaType","minPxPerSec","normalize","partialRender","pixelRatio","progressColor","removeMediaElementOnDestroy","renderer","responsive","scrollParent","skipLength","splitChannels","waveColor","autoCenterRate","autoCenterImmediately","drawingContextAttributes","duration","ignoreSilenceMode","rtl","splitChannelsOptions","vertical","xhr"],FZe=e=>e?MZe.reduce((t,n)=>Object.prototype.hasOwnProperty.call(e,n)?Object.assign(Object.assign({},t),{[n]:e[n]}):t,{}):{};/*! ***************************************************************************** + : v !== v && u === u ? ${r} : `;function XJe(e,t){const n=[],r=[],i=[];let s=null,o="0",a="0";e.isGrouped()&&(s=e.groups().keys,o="ka",a="kb");const{ops:u}=ao(t,{table:e,value:(h,p)=>{if(n.push(h),p.escape){const m=y=>`fn[${i.length}](${y}, data)`;r.push([m("a"),m("b")]),i.push(p.escape)}else r.push([iI(p,{index:"a",op:o}),iI(p,{index:"b",op:a})])},window:!1}),l=Vg(e,u),c=(h,p)=>l[h][p],f=n.length;let d="return (a, b) => {"+(c&&e.isGrouped()?"const ka = keys[a], kb = keys[b];":"")+"let u, v; return ";for(let h=0;hr.set(++n+"",s);return t.forEach(s=>{const o=s.expr!=null?s.expr:s;if(as(o)&&!sr(o))for(const a in o)i(o[a]);else i(bs(o)?_h(s,e.columnName(o)):Ui(o)?_h(s):sr(o)?s:Wt(`Invalid orderby field: ${s+""}`))}),XJe(e,r)}function eZe(e,t){const n=e.numRows(),r=n+t.reduce((o,a)=>o+a.numRows(),0);if(n===r)return e;const i=[e,...t],s=Mo();return e.columnNames().forEach(o=>{const a=Array(r);let u=0;i.forEach(l=>{const c=l.column(o)||{get:()=>yn};l.scan(f=>a[u++]=c.get(f))}),s.add(o,a)}),e.create(s.new())}function tZe(e,t){const n=Mo(),r=e.groups(),{get:i,names:s=[],rows:o,size:a=1}=r||{},u=new Uint32Array(a+1);s.forEach(d=>n.add(d,null));const l=r?Jue(e,t,r):[Xue(e,t)];t.outputs().map(d=>n.add(d,[]));const c=u.length-1;let f=0;for(let d=0;d{const m=n.data[h]=Array(f),y=i[p];for(let g=0,v=0;gdH(e,t,n,{anti:!0}),__count:(e,t={})=>hH(e,{[t.as||"count"]:gse()}),__cross:(e,t,n,r)=>cH(e,t,()=>!0,n,{...r,left:!0,right:!0}),__concat:eZe,__dedupe:RXe,__derive:QXe,__except:XXe,__filter:eJe,__fold:nJe,__impute:oJe,__intersect:uJe,__join:cH,__lookup:SJe,__pivot:CJe,__relocate:Kue,__rename:PJe,__rollup:hH,__sample:MJe,__select:jJe,__semijoin:dH,__spread:zJe,__union:HJe,__unroll:WJe,__groupby:YJe,__orderby:JJe,__ungroup:nZe,__unorder:rZe,__reduce:tZe};Object.assign(Al.prototype,iZe);function sZe(e,t){return Al.from(e,t)}function oZe(e){return tA(e,{escape:!0,toString(){Wt("Escaped values can not be serialized.")}})}Al.prototype;const Sa={top:30,left:60,right:80,bottom:50};function ole({data:e,selection:t,parameters:n,dataname:r}){const o=w.useMemo(()=>{const c=e.map(f=>({...f,value:+f[n.y_var]}));return sZe(c)},[e,n]),a=w.useMemo(()=>{const c=Pf(o.filter(oZe(f=>t.includes(f[n.cat_var]))).array("value"));return r==="clean_stocks"?c:[0,c[1]]},[o,t,n,r]),u=w.useMemo(()=>mh([Sa.top,400-Sa.bottom]).domain(Pf(o.array("value")).reverse()),[o,400]),l=yf(r==="clean_stocks"?".0%":",.0f");return(t==null?void 0:t.length)===0?null:C.jsxs("svg",{style:{height:"400px",width:"60px",overflow:"visible"},children:[C.jsx("rect",{y:u(a[1]),height:u(a[0])-u(a[1]),x:Sa.left-10,width:10,opacity:.1,fill:"black"}),C.jsx("text",{style:{fontSize:10,dominantBaseline:"middle",textAnchor:"middle",fontFamily:'"Helvetica Neue", Helvetica, Arial, sans-serif'},x:25,y:Sa.top-5,children:l(u.domain()[0])}),C.jsx("text",{style:{fontSize:10,dominantBaseline:"middle",textAnchor:"middle",fontFamily:'"Helvetica Neue", Helvetica, Arial, sans-serif'},x:25,y:400-Sa.bottom+8,children:l(u.domain()[1])}),C.jsx("text",{style:{fontSize:10,dominantBaseline:"middle",fontFamily:'"Helvetica Neue", Helvetica, Arial, sans-serif'},x:Sa.left-5,y:u(a[0]),children:l(a[0])}),C.jsx("text",{style:{fontSize:10,dominantBaseline:"middle",fontFamily:'"Helvetica Neue", Helvetica, Arial, sans-serif'},x:Sa.left-5,y:u(a[1]),children:l(a[1])}),e.map(c=>C.jsx("rect",{opacity:.2,fill:+c[n.y_var]>0?"steelblue":"firebrick",x:0,width:50,y:u(+c[n.y_var]),height:1},"strip")),C.jsx("line",{strokeWidth:2,stroke:"black",style:{fontSize:10,dominantBaseline:"middle"},x1:0,x2:50,y1:u(a[0]),y2:u(a[0])}),C.jsx("line",{strokeWidth:2,stroke:"black",x1:0,x2:50,y1:u(a[1]),y2:u(a[1])}),C.jsx("line",{strokeWidth:2,stroke:"black",x1:0,x2:0,y1:u(a[1]),y2:u(a[0])}),C.jsx("line",{strokeWidth:2,stroke:"black",x1:50,x2:50,y1:u(a[1]),y2:u(a[0])}),C.jsx("path",{fill:"black",opacity:"0.1",d:`M${Sa.left}, ${u(a[1])} L 113, ${Sa.top} L 113, ${400-Sa.bottom} L ${Sa.left}, ${u(a[0])}`})]})}const aZe=Object.freeze(Object.defineProperty({__proto__:null,StripPlot:ole},Symbol.toStringTag,{value:"Module"}));function ale({parameters:e}){const t=e.dataset==="clean_data"?C.jsxs(Y0,{children:["Select any subset of countries to the left of the visualization to support the prompt at the top of the page.",C.jsx("h4",{children:"Background:"}),"You live in a fantasy world that consists of your home country, as well as other 15 countries located across 5 continents: Eldoril, Thundoril, Aerion, Silvoria, and Mystara. Countries within each continent are similar to each other in size and demographics.",C.jsx("h4",{children:"Scenario:"}),"You are an analyst for the Viral Disease Policy Center of your home country at time when there is a new viral disease called",C.jsx("i",{children:" Celestial Sniffles"}),". Luckily, your country has not been affected yet and has time to prepare and decide on a policy to combat it. You have access to the infection data from other countries that implemented one of the 3 available policies: A, B, or C. However, due to socioeconomic factors, the Surgeon General in your country has",C.jsx("i",{children:" already decided on a policy"}),".",C.jsx("h4",{children:"Task:"}),"You are tasked with leading the promotion efforts that make the case for the chosen policy. In the experiment, you will use an interactive data explorer that shows infection data from other countries. You should select a view that best shows (and convinces the population) that your country's"," ",C.jsx("b",{children:"chosen policy is the best policy to combat the disease"}),". After finalizing the view, click the camera button and add a caption or a slogan that will go along with your visualization."]}):C.jsxs(Y0,{children:["Select any subset of stocks to the left of the visualization to support the prompt at the top of the page.",C.jsx("h4",{children:"Scenario:"})," ","You are a financial advisor. Your client approached you asking for help in picking a new investment—an industry fund that equally invests within a single industry. The client prefers to make their decisions"," ",C.jsx("i",{children:"solely based on the data"}),", and not based on any inside knowledge about the type of industry. However, your boss"," ",C.jsx("i",{children:"does"})," ","have inside knowledge and orders you to recommend a specific industry (which is ultimately in the best interest of the client). You cannot disclose this to the client and have to use data to support your recommendations.",C.jsx("h4",{children:"Task:"})," ","In the experiment, you will use an interactive data explorer that shows performance of different stocks from a variety of industries. You should select a view that best shows (and convinces your client) that"," ",C.jsx("b",{children:"the chosen industry fund would be the best investment with the highest returns"}),". After finalizing the view, click the camera button and add a caption or a slogan that will go along with your visualization."]}),n=e.dataset==="clean_data"?C.jsxs(Y0,{children:[C.jsx("h4",{children:"Background:"}),"You live in a fantasy world that consists of your home country, as well as other 15 countries located across 5 continents: Eldoril, Thundoril, Aerion, Silvoria, and Mystara. Countries within each continent are similar to each other in size and demographics.",C.jsx("h4",{children:"Scenario:"}),"There's a new viral disease called"," ",C.jsx("i",{children:"Celestial Sniffles"}),". Most countries in the world have adopted one of 3 major disease containment policies: A, B, or C. Luckily, your country has not been affected yet but you may need to travel to one of the affected countries for work. Afraid of getting sick and stuck abroad with a huge hospital bill, you decide to purchase a traveler's health insurance policy. The price of the policy is very flexible and depends on the amount of coverage you'll get: anywhere between $0 (no coverage) to $100 (full coverage). Since you are not familiar with the disease trends or containment policies, you turn to social media to read what people shared about recent infection rates.",C.jsx("h4",{children:"Task:"}),"In the experiment, you will see a set of visualizations that show infection rates in different countries that adopted one of the containment policies A, B, or C. You can refer to the list of countries to the left of the visualization to see which country adopted which Policy. Based on each visualization, you will be asked to decide"," ",C.jsx("b",{children:"how much to spend on your insurance policy"})," ","and"," ",C.jsx("b",{children:"answer a short survey"}),"."]}):C.jsxs(Y0,{children:[C.jsx("h4",{children:"Scenario:"}),"You have $100 that you would like to invest in"," ",C.jsx("i",{children:"industry funds"})," ","but are not sure how to best allocate that money. An industry fund is composed of all individual stocks pertaining to that industry (e.g., a Pharma fund is composed of Pharma A, Pharma B, and Pharma C stocks). Since you are not familiar with the current market, you turn to social media to read what people shared about recent stock performance.",C.jsx("h4",{children:"Task:"}),"In the experiment, you will see a set of visualizations that show performance of different stocks from a variety of industries. Based on each visualization, you will be asked to decide"," ",C.jsx("b",{children:"how much to invest in a given industry fund"})," ","and"," ",C.jsx("b",{children:"answer a short survey"}),"."]});return C.jsx(ei,{position:"right",children:C.jsxs(em,{width:800,shadow:"md",children:[C.jsx(em.Target,{children:C.jsx(Ws,{variant:"light",color:"gray",compact:!0,children:"Help"})}),C.jsx(em.Dropdown,{children:C.jsx(rt,{size:"sm",children:e.allow_selection?t:n})})]})})}const uZe=Object.freeze(Object.defineProperty({__proto__:null,Help:ale},Symbol.toStringTag,{value:"Module"}));function pH({parameters:e,setAnswer:t}){const[n,r]=w.useState(null),[i,s]=w.useState(e.dataset),[o,a]=w.useState(e.initial_selection),[u,l]=w.useState(null),[c,f]=w.useState([new Date(e.start_date),new Date(e.end_date)]),[d,h]=w.useState(e.guardrail);w.useEffect(()=>{u7e(`./data/${i}.csv`).then(T=>{r(T),l(Array.from(new Set(T.map(E=>JSON.stringify({name:E[e.cat_var],group:E[e.group_var]})))).map(E=>JSON.parse(E)))})},[i,e]);const p=w.useMemo(()=>n&&c?n.filter(T=>new Date(T[e.x_var]).getTime()>=c[0].getTime()).filter(T=>new Date(T[e.x_var]).getTime()<=c[1].getTime()):null,[n,c,e.x_var,i]),m=T=>{s(T),a([])},{actions:y,trrack:g}=w.useMemo(()=>{const T=DC.create(),E=T.register("selection",(R,F)=>(R.selection=F,R)),I=T.register("range",(R,F)=>(R.range=F,R)),A=ise({registry:T,initialState:{selection:[],range:[e.start_date,e.end_date]}});return{actions:{selection:E,range:I},trrack:A}},[e.end_date,e.start_date]),v=w.useCallback(T=>{g.apply("Change daterange",y.range([T[0].toISOString().slice(0,10),T[1].toISOString().slice(0,10)]))},[g,y]),b=w.useMemo(()=>ou(v,200),[v]),S=w.useCallback(T=>{g.apply("Change selection",y.selection(T)),t({status:!0,provenanceGraph:g.graph.backend,answers:{}})},[g,y,t]);return p&&u&&c&&o?C.jsxs(ys,{children:[e.allow_guardrail_selector?C.jsx(wS,{shadow:"sm",radius:"md",p:"md",style:{width:"500px"},children:C.jsx(rk,{guardrail:d,setGuardrail:h,dataname:i,setDataname:m,setSelection:a})}):null,C.jsx(Fm,{children:C.jsxs(wS,{shadow:"md",radius:"md",p:"md",withBorder:!0,children:[e.caption===""?null:C.jsx(Fm,{style:{width:"800px"},children:e.caption?C.jsx(wJ,{children:e.caption}):null}),C.jsxs(ei,{noWrap:!0,children:[e.allow_selection===!1&&e.guardrail!=="juxt_data"?null:C.jsx(ei,{noWrap:!0,children:C.jsx(tk,{parameters:e,data:p,dataname:i,items:u,selection:o,setSelection:a,trackSelection:S,range:c,guardrail:d})}),e.allow_selection===!1&&e.guardrail!=="juxt_data"?null:C.jsx(df,{orientation:"vertical",size:"xs"}),C.jsxs(ys,{children:[C.jsxs(ei,{position:"apart",children:[C.jsxs(ys,{spacing:0,justify:"flex-start",children:[C.jsx(rt,{fw:500,children:i==="clean_stocks"?"Percent change in stock price":"Infections per million people"}),d==="super_summ"?C.jsx(rt,{fz:"xs",c:"dimmed",children:"Shaded area represents the middle 50% of all values."}):null,d==="juxt_summ"?C.jsx(rt,{fz:"xs",c:"dimmed",children:"Bar on the left highlights the range of selection among all data."}):null]}),e.allow_help?C.jsx(ale,{parameters:e}):null]}),C.jsxs(ys,{children:[C.jsxs(ei,{noWrap:!0,children:[d==="juxt_summ"?C.jsx(ole,{parameters:e,data:p,selection:o,dataname:i}):null,C.jsx(ek,{parameters:e,data:p,dataname:i,items:u,selection:o,range:c,guardrail:d})]}),e.allow_time_slider?C.jsx("div",{style:{width:"500px"},children:C.jsx(nk,{parameters:e,setRange:f,trackRange:b})}):null]})]})]})]})})]}):C.jsx(Xf,{})}const lZe=Object.freeze(Object.defineProperty({__proto__:null,DataExplorer:pH,default:pH},Symbol.toStringTag,{value:"Module"})),cZe=Object.assign({"../public/viz-guardrails/AudioTest.tsx":oVe,"../public/viz-guardrails/Color.tsx":aVe,"../public/viz-guardrails/DataExplorer.tsx":lZe,"../public/viz-guardrails/Help.tsx":uZe,"../public/viz-guardrails/LineChart.tsx":ZHe,"../public/viz-guardrails/RangeSelector.tsx":tWe,"../public/viz-guardrails/Selector.tsx":nWe,"../public/viz-guardrails/Sidebar.tsx":eWe,"../public/viz-guardrails/StripPlot.tsx":aZe,"../public/viz-guardrails/XAxis.tsx":XHe,"../public/viz-guardrails/YAxis.tsx":JHe});function fZe({currentConfig:e,provState:t}){const n=hl(),r=`../public/${e.path}`,i=cZe[r].default,s=Ju(),{updateResponseBlockValidation:o,setIframeAnswers:a}=Xu(),u=w.useCallback(({status:l,provenanceGraph:c,answers:f})=>{s(o({location:"sidebar",currentStep:n,status:l,values:f,provenanceGraph:c})),s(a(Object.values(f).map(d=>d)))},[s,o,n,a]);return C.jsx(w.Suspense,{fallback:C.jsx("div",{children:"Loading..."}),children:C.jsx(i,{parameters:e.parameters,setAnswer:u,provenanceState:t})})}function dZe({currentConfig:e}){const[t,n]=w.useState(null);return w.useEffect(()=>{fetch(`${fl}${e.path}`).then(r=>r.text()).then(r=>n(r))},[e]),t===null?null:C.jsx("div",{style:{maxWidth:700,margin:"0 0"},children:C.jsx(ro,{text:t})})}function bh(){return la(e=>e.config)}function ule(){const e=hl(),{setAlertModal:t}=Xu(),n=Ju();w.useEffect(()=>{(new URLSearchParams(window.location.search).get("admin")||"f")==="t"||(window.history.pushState(null,"",window.location.href),window.onpopstate=()=>{window.history.pushState(null,"",window.location.href),n(t({show:!0,message:"Using the browser's back button is prohibited during the study."}))})},[e,t,n])}function lle({provState:e}){var S;const t=bh(),n=sa(),{trialName:r}=uh(),i=t.components[r],s=Z3(),o=uC(i)&&t.baseComponents?J3({},(S=t.baseComponents)==null?void 0:S[i.baseComponent],i):i,a=o.instruction||"",{instructionLocation:u}=o,l=t.uiConfig.sidebar&&(u==="sidebar"||u===void 0),[c,f]=w.useState(null),d=Ju(),{setIsRecording:h}=Xu(),{trialName:p}=uh(),[m,y]=w.useState(null);w.useEffect(()=>{!p||!t||!t.recordStudyAudio||!n.storageEngine||(c&&m&&n.storageEngine.saveAudio(c,m),t.tasksToNotRecordAudio&&t.tasksToNotRecordAudio.includes(p)?(y(null),f(null),d(h(!1))):(navigator.mediaDevices.getUserMedia({audio:!0}).then(E=>{const I=new MediaRecorder(E);I.start(),f(I),d(h(!0))}),y(p)))},[p]),ule();const{storageEngine:g}=sa(),v=Ju(),{setAlertModal:b}=Xu();return w.useEffect(()=>{(g==null?void 0:g.getEngine())!=="firebase"&&v(b({show:!0,message:"There was an issue connecting to the firebase database. This could be caused by a network issue or your adblocker. If you are using an adblocker, please disable it for this website and refresh."}))},[b,g,v]),C.jsxs(C.Fragment,{children:[u==="aboveStimulus"&&C.jsx(ro,{text:a}),C.jsx(UT,{status:s,config:o,location:"aboveStimulus"},`${r}-above-response-block`),C.jsxs(w.Suspense,{fallback:C.jsx("div",{children:"Loading..."}),children:[o.type==="markdown"&&C.jsx(dZe,{currentConfig:o}),o.type==="website"&&C.jsx(rVe,{currentConfig:o}),o.type==="image"&&C.jsx(sVe,{currentConfig:o}),o.type==="react-component"&&C.jsx(fZe,{currentConfig:o,provState:e})]},`${r}-stimulus`),(u==="belowStimulus"||u===void 0&&!l)&&C.jsx(ro,{text:a}),C.jsx("div",{style:{maxWidth:800,margin:"0 0"},children:C.jsx(UT,{status:s,config:o,location:"belowStimulus"},`${r}-below-response-block`)})]})}function hZe(e){const[t]=h$();return C.jsx(c0e,{...e,to:{pathname:e.to,search:t.toString()}})}function pZe(){const e=bh(),{storageEngine:t}=sa(),{answers:n}=la(s=>s),[r,i]=w.useState(!1);return w.useEffect(()=>{const s=setInterval(async()=>{await t.verifyCompletion(n)&&(i(!0),clearInterval(s))},1e3)},[]),ule(),C.jsx(ua,{style:{height:"100%"},children:C.jsx(Fm,{direction:"column",children:r?C.jsx(rt,{size:"xl",display:"block",children:e.uiConfig.studyEndMsg?C.jsx(ro,{text:e.uiConfig.studyEndMsg}):"Thank you for completing the study. You may close this window now."}):C.jsxs(C.Fragment,{children:[C.jsx(rt,{size:"xl",display:"block",children:"Please wait while your answers are uploaded."}),C.jsx(bT,{h:"lg"}),C.jsx(ua,{children:C.jsx(Xf,{color:"blue"})})]})})})}function mZe(e,t=!1){return typeof e=="number"?mH(e,t):mH(e.length,t).map(r=>r.map(i=>e[i]))}function mH(e,t){if(e<0)throw new Error("Latin square size must be > 0");if(e==0)return[];if(e==1)return[[0]];let n=new Array(e);for(let s=0;s(a+1)%e);r.push(o),i=o}if(t&&e%2>0)for(let s=0;s.5-Math.random());e.components=r}else e.order==="latinSquare"&&t&&(e.components=t[n].pop().map(r=>r.startsWith("_orderObj")?e.components[+r.slice(9)]:r));return e.components.slice(0,e.numSamples?e.numSamples:void 0).flat()}function gZe(e,t){const n=Ig(e);return cle(n,t,"root"),n.components.slice(0,n.numSamples?n.numSamples:void 0).flat()}function fle(e,t,n,r=0){const i=n.length>0?`${n}-${r}`:"root";e.order==="latinSquare"&&t.push(i),e.components.forEach((s,o)=>{typeof s!="string"&&fle(s,t,i,o)})}function yZe(e){const t=[];return fle(e,t,"",0),t}function gH(e,t){const n=t.split("-");let r={};n.forEach(o=>{o==="root"?r=e.sequence:r=r.components[+o]});const i=r.components.map((o,a)=>typeof o=="string"?o:`_orderObj${a}`);return mZe(i.sort(()=>.5-Math.random()),!0)}function vZe(e){const n=yZe(e.sequence).map(s=>({[s]:gH(e,s)})).reduce((s,o)=>({...s,...o}),{}),r=e.uiConfig.numSequences||1e3,i=[];return Array.from({length:r}).forEach(()=>{const s=gZe(e.sequence,n);s.push("end"),i.push(s),Object.entries(n).forEach(([o,a])=>{a.length===0&&(n[o]=gH(e,o))})}),i}var _Ze={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"},bZe=Object.defineProperty,wZe=Object.defineProperties,EZe=Object.getOwnPropertyDescriptors,OI=Object.getOwnPropertySymbols,dle=Object.prototype.hasOwnProperty,hle=Object.prototype.propertyIsEnumerable,yH=(e,t,n)=>t in e?bZe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,vH=(e,t)=>{for(var n in t||(t={}))dle.call(t,n)&&yH(e,n,t[n]);if(OI)for(var n of OI(t))hle.call(t,n)&&yH(e,n,t[n]);return e},SZe=(e,t)=>wZe(e,EZe(t)),TZe=(e,t)=>{var n={};for(var r in e)dle.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&OI)for(var r of OI(e))t.indexOf(r)<0&&hle.call(e,r)&&(n[r]=e[r]);return n},rd=(e,t,n)=>{const r=w.forwardRef((i,s)=>{var o=i,{color:a="currentColor",size:u=24,stroke:l=2,children:c}=o,f=TZe(o,["color","size","stroke","children"]);return w.createElement("svg",vH(SZe(vH({ref:s},_Ze),{width:u,height:u,stroke:a,strokeWidth:l,className:`tabler-icon tabler-icon-${e}`}),f),[...n.map(([d,h])=>w.createElement(d,h)),...c||[]])});return r.propTypes={color:gt.string,size:gt.oneOfType([gt.string,gt.number]),stroke:gt.oneOfType([gt.string,gt.number])},r.displayName=`${t}`,r},IZe=rd("alert-circle","IconAlertCircle",[["path",{d:"M3 12a9 9 0 1 0 18 0a9 9 0 0 0 -18 0",key:"svg-0"}],["path",{d:"M12 8v4",key:"svg-1"}],["path",{d:"M12 16h.01",key:"svg-2"}]]),xZe=rd("arrows-shuffle","IconArrowsShuffle",[["path",{d:"M18 4l3 3l-3 3",key:"svg-0"}],["path",{d:"M18 20l3 -3l-3 -3",key:"svg-1"}],["path",{d:"M3 7h3a5 5 0 0 1 5 5a5 5 0 0 0 5 5h5",key:"svg-2"}],["path",{d:"M21 7h-5a4.978 4.978 0 0 0 -3 1m-4 8a4.984 4.984 0 0 1 -3 1h-3",key:"svg-3"}]]),CZe=rd("code-dots","IconCodeDots",[["path",{d:"M15 12h.01",key:"svg-0"}],["path",{d:"M12 12h.01",key:"svg-1"}],["path",{d:"M9 12h.01",key:"svg-2"}],["path",{d:"M6 19a2 2 0 0 1 -2 -2v-4l-1 -1l1 -1v-4a2 2 0 0 1 2 -2",key:"svg-3"}],["path",{d:"M18 19a2 2 0 0 0 2 -2v-4l1 -1l-1 -1v-4a2 2 0 0 0 -2 -2",key:"svg-4"}]]),AZe=rd("code-plus","IconCodePlus",[["path",{d:"M9 12h6",key:"svg-0"}],["path",{d:"M12 9v6",key:"svg-1"}],["path",{d:"M6 19a2 2 0 0 1 -2 -2v-4l-1 -1l1 -1v-4a2 2 0 0 1 2 -2",key:"svg-2"}],["path",{d:"M18 19a2 2 0 0 0 2 -2v-4l1 -1l-1 -1v-4a2 2 0 0 0 -2 -2",key:"svg-3"}]]),PZe=rd("dots-vertical","IconDotsVertical",[["path",{d:"M12 12m-1 0a1 1 0 1 0 2 0a1 1 0 1 0 -2 0",key:"svg-0"}],["path",{d:"M12 19m-1 0a1 1 0 1 0 2 0a1 1 0 1 0 -2 0",key:"svg-1"}],["path",{d:"M12 5m-1 0a1 1 0 1 0 2 0a1 1 0 1 0 -2 0",key:"svg-2"}]]),OZe=rd("mail","IconMail",[["path",{d:"M3 7a2 2 0 0 1 2 -2h14a2 2 0 0 1 2 2v10a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-10z",key:"svg-0"}],["path",{d:"M3 7l9 6l9 -6",key:"svg-1"}]]),_H=rd("schema","IconSchema",[["path",{d:"M5 2h5v4h-5z",key:"svg-0"}],["path",{d:"M15 10h5v4h-5z",key:"svg-1"}],["path",{d:"M5 18h5v4h-5z",key:"svg-2"}],["path",{d:"M5 10h5v4h-5z",key:"svg-3"}],["path",{d:"M10 12h5",key:"svg-4"}],["path",{d:"M7.5 6v4",key:"svg-5"}],["path",{d:"M7.5 14v4",key:"svg-6"}]]),ple=rd("table","IconTable",[["path",{d:"M3 5a2 2 0 0 1 2 -2h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14z",key:"svg-0"}],["path",{d:"M3 10h18",key:"svg-1"}],["path",{d:"M10 3v18",key:"svg-2"}]]);const Ik=["description","instruction","answer","correctAnswer","startTime","endTime","duration","taskOrder"],Yw=["participantId","trialId","responseId"];function Kw(e,t){const n=`data:text/json;charset=utf-8,${encodeURIComponent(e)}`,r=document.createElement("a");r.setAttribute("href",n),r.setAttribute("download",t),document.body.appendChild(r),r.click(),r.remove()}function RZe(e,t,n){return Object.entries(t.components).map(([r,i])=>{const s=uC(i)&&i.baseComponent&&t.baseComponents?J3({},t.baseComponents[i.baseComponent],i):i,o=e.answers[r],a=o!==void 0?o:{answer:{},startTime:-1,endTime:-1,windowEvents:[]},u=a.endTime-a.startTime;return Object.entries(a.answer).map(([c,f])=>{const d={participantId:e.participantId,trialId:r,responseId:c,startTime:new Date(a.startTime).toUTCString(),endTime:new Date(a.endTime).toUTCString(),duration:u};return n.includes("description")&&(d.description=s.description),n.includes("instruction")&&(d.instruction=s.instruction),n.includes("answer")&&(d.answer=f),n.includes("correctAnswer")&&(d.correctAnswer=s.correctAnswer),n.includes("taskOrder")&&(d.taskOrder=e.sequence.indexOf(r)),d}).flat()}).flat()}async function NZe(e,t,n,r=[...Yw,...Ik]){const s=(await t.getAllParticipantsData()).map(l=>RZe(l,n,r)).flat(),o=l=>l.replace(/"/g,'""'),a=s.map(l=>r.map(c=>l===null?"":typeof l[c]=="string"?`"${o(l[c])}"`:JSON.stringify(l[c])).join(",")),u=[r.join(","),...a].join(` +`);Kw(u,e)}function kZe({opened:e,close:t,filename:n,studyConfig:r}){const[i,s]=e_e([...Yw,...Ik]),o=w.useCallback(l=>{Yw.every(c=>l.includes(c))&&s(l)},[s]),a=w.useMemo(()=>[...Yw,...Ik],[]),{storageEngine:u}=sa();return u?C.jsxs(zx,{opened:e,size:"lg",onClose:t,title:C.jsx(rt,{size:"xl",children:"Download Tidy CSV"}),centered:!0,radius:"md",padding:"xl",children:[C.jsx(it,{children:C.jsx(See,{searchable:!0,limit:30,nothingFound:"Property not found",data:a,value:i,onChange:o,label:C.jsx(rt,{fw:"bold",size:"lg",children:"Select properties to include in tidy csv:"}),placeholder:"Select atleast one property"})}),C.jsxs(Fm,{mt:"xl",direction:{base:"column",sm:"row"},gap:{base:"sm",sm:"lg"},justify:{sm:"space-around"},children:[C.jsx(Ws,{leftIcon:C.jsx(ple,{}),onClick:()=>NZe(n,u,r,i),children:"Download"}),C.jsx(Ws,{onClick:t,color:"red",children:"Close"})]})]}):null}function DZe({studyConfig:e}){const{storageEngine:t}=sa(),[n,{open:r,close:i}]=I$(!1),[s,o]=w.useState(),[a,u]=w.useState(""),l=e.studyMetadata.title.replace(" ","_");w.useEffect(()=>{async function m(){if(t){const y=await t.getCurrentParticipantId(),g=await t.getParticipantData();u(y),o(g)}}m()},[t]);const c=w.useCallback(async()=>{Kw(JSON.stringify(s,null,2),`${l}_${a}.json`)},[s]),f=e.uiConfig.autoDownloadStudy||!1,d=f&&e.uiConfig.autoDownloadTime||-1,[h,p]=w.useState(Math.floor(d/1e3));return w.useEffect(()=>{const m=setInterval(()=>{p(y=>y-1)},1e3);return h<=0?(c(),clearInterval(m),()=>clearInterval(m)):()=>clearInterval(m)},[h]),C.jsxs(ys,{children:[C.jsx(Ws,{leftIcon:C.jsx(CZe,{}),onClick:()=>Kw(JSON.stringify(s,null,2),`${l}_${a}.json`),display:"block",children:"Download Current (JSON)"}),C.jsx(Ws,{disabled:!(t!=null&&t.isConnected()),leftIcon:C.jsx(AZe,{}),onClick:async()=>{if(!t)return;const m=await t.getAllParticipantsData();Kw(JSON.stringify(m,null,2),`${l}_all.json`)},display:"block",children:"Download All (JSON)"}),C.jsx(Ws,{disabled:!(t!=null&&t.isConnected()),leftIcon:C.jsx(ple,{}),onClick:r,display:"block",children:"Download All (Tidy)"}),f&&C.jsxs(rt,{size:"lg",children:["Study results will be downloaded in"," ",h," ","seconds. If the download does not start automatically, click above to download."]}),C.jsx(kZe,{opened:n,close:i,filename:`${l}_${a}.csv`,studyConfig:e})]})}function nA(e){return e.components.flatMap(t=>typeof t=="string"?t:nA(t))}function bH(e,t){return nA(t).find(i=>e.indexOf(i)!==-1)}function $Ze(e,t){return nA(t).filter(i=>e.indexOf(i)!==-1)}function LZe({step:e,currentStep:t,sequence:n,task:r,studyId:i}){const s=Kf(),[o,{close:a,open:u}]=I$(!1);return C.jsxs(yi,{position:"left",withArrow:!0,arrowSize:10,shadow:"md",opened:o,offset:20,children:[C.jsx(yi.Target,{children:C.jsx("div",{onMouseEnter:u,onMouseLeave:a,children:C.jsx(Cee,{active:e===t,style:{lineHeight:"32px",height:"32px"},label:C.jsx("div",{style:{opacity:n.indexOf(e)===-1?".3":1},children:e===t?C.jsx("strong",{children:e}):e}),onClick:()=>s(`/${i}/${e}`),disabled:n.indexOf(e)===-1})})}),r&&(r.description||r.meta)&&lc.createPortal(C.jsx(yi.Dropdown,{onMouseLeave:a,children:C.jsx(rt,{size:"sm",children:C.jsxs("div",{children:[r.description&&C.jsxs("div",{children:[C.jsx(rt,{fw:900,display:"inline-block",mr:2,children:"Description:"}),C.jsx(rt,{fw:400,component:"span",children:r.description})]}),r.meta&&C.jsxs(rt,{children:[C.jsx(rt,{fw:"900",component:"span",children:"Task Meta: "}),C.jsx("pre",{style:{margin:0,padding:0},children:`${JSON.stringify(r.meta,null,2)}`})]})]})})}),document.body)]})}function mle({sequence:e,order:t,depth:n=0}){const{studyId:r=null}=uh(),i=hl(),s=bh(),o=w.useMemo(()=>{const a=Ig(t);return a.components.sort((u,l)=>{const c=typeof u=="string"?u:bH(e,u),f=typeof l=="string"?l:bH(e,l),d=c?e.indexOf(c):1e4,h=f?e.indexOf(f):1e4;return(d===-1?1e4:d)-(h===-1?1e4:h)}),a},[t,e]);return C.jsx("div",{children:o.components.map((a,u)=>{if(typeof a=="string"){const f=a in s.components&&s.components[a];return C.jsx(LZe,{currentStep:i,sequence:e,step:a,studyId:r,task:f},u)}const l=nA(a),c=$Ze(e,a);return C.jsx(Cee,{label:C.jsxs("div",{style:{opacity:c.length?1:.5},children:["Group:",C.jsxs(_Ie,{ml:5,children:[c.length,"/",l.length]}),C.jsx(rt,{c:"dimmed",display:"inline",mr:5,ml:5,children:a.order}),a.order==="random"||a.order==="latinSquare"?C.jsx(xZe,{size:"15",opacity:.5,style:{marginLeft:"5px",verticalAlign:"middle"}}):null]}),defaultOpened:!0,childrenOffset:32,style:{lineHeight:"32px",height:"32px",position:"sticky",top:`${32*n}px`,backgroundColor:"#fff"},children:C.jsx("div",{style:{borderLeft:"1px solid #e9ecef"},children:C.jsx(mle,{order:a,sequence:e,depth:n+1})})},u)})})}function MZe(){const{showAdmin:e,sequence:t}=la(s=>s),n=hl(),r=bh(),i=w.useMemo(()=>{const s=Ig(r.sequence);return s.components.push("end"),s},[r.sequence]);return e||n==="end"&&r.uiConfig.autoDownloadStudy?C.jsx(C$,{p:"0",width:{base:300},style:{zIndex:0},children:C.jsxs(R$,{p:"0",children:[n==="end"&&C.jsxs("div",{style:{padding:10,paddingBottom:15,borderBottom:"1px solid #e9ecef"},children:[C.jsx(rt,{size:"md",p:10,weight:"bold",children:"Download"}),C.jsx(DZe,{studyConfig:r})]}),C.jsx(rt,{size:"md",p:10,weight:"bold",children:"Study Sequence"}),C.jsx(mle,{order:i,sequence:t})]})}):null}const gle=w.createContext(null),mM=({id:e="waveform",children:t})=>N.createElement("div",{id:e},t),FZe=["audioRate","audioContext","audioScriptProcessor","autoCenter","backend","backgroundColor","barGap","barHeight","barMinHeight","barRadius","barWidth","closeAudioContext","cursorColor","cursorWidth","fillParent","forceDecode","height","hideScrollbar","interact","loopSelection","maxCanvasWidth","mediaControls","mediaType","minPxPerSec","normalize","partialRender","pixelRatio","progressColor","removeMediaElementOnDestroy","renderer","responsive","scrollParent","skipLength","splitChannels","waveColor","autoCenterRate","autoCenterImmediately","drawingContextAttributes","duration","ignoreSilenceMode","rtl","splitChannelsOptions","vertical","xhr"],BZe=e=>e?FZe.reduce((t,n)=>Object.prototype.hasOwnProperty.call(e,n)?Object.assign(Object.assign({},t),{[n]:e[n]}):t,{}):{};/*! ***************************************************************************** Copyright (c) Microsoft Corporation. Permission to use, copy, modify, and/or distribute this software for any @@ -237,7 +237,7 @@ INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. -***************************************************************************** */function ni(e,t,n,r){return new(n||(n=Promise))(function(i,s){function o(l){try{u(r.next(l))}catch(c){s(c)}}function a(l){try{u(r.throw(l))}catch(c){s(c)}}function u(l){var c;l.done?i(l.value):(c=l.value,c instanceof n?c:new n(function(f){f(c)})).then(o,a)}u((r=r.apply(e,t||[])).next())})}let p1=class{constructor(){this.listeners={}}on(t,n,r){if(this.listeners[t]||(this.listeners[t]=new Set),this.listeners[t].add(n),r==null?void 0:r.once){const i=()=>{this.un(t,i),this.un(t,n)};return this.on(t,i),i}return()=>this.un(t,n)}un(t,n){var r;(r=this.listeners[t])===null||r===void 0||r.delete(n)}once(t,n){return this.on(t,n,{once:!0})}unAll(){this.listeners={}}emit(t,...n){this.listeners[t]&&this.listeners[t].forEach(r=>r(...n))}};const wH={decode:function(e,t){return ni(this,void 0,void 0,function*(){const n=new AudioContext({sampleRate:t});return n.decodeAudioData(e).finally(()=>n.close())})},createBuffer:function(e,t){return typeof e[0]=="number"&&(e=[e]),function(n){const r=n[0];if(r.some(i=>i>1||i<-1)){const i=r.length;let s=0;for(let o=0;os&&(s=a)}for(const o of n)for(let a=0;ae==null?void 0:e[n],copyFromChannel:AudioBuffer.prototype.copyFromChannel,copyToChannel:AudioBuffer.prototype.copyToChannel}}};function yle(e,t){const n=t.xmlns?document.createElementNS(t.xmlns,e):document.createElement(e);for(const[r,i]of Object.entries(t))if(r==="children")for(const[s,o]of Object.entries(t))typeof o=="string"?n.appendChild(document.createTextNode(o)):n.appendChild(yle(s,o));else r==="style"?Object.assign(n.style,i):r==="textContent"?n.textContent=i:n.setAttribute(r,i.toString());return n}function EH(e,t,n){const r=yle(e,t||{});return n==null||n.appendChild(r),r}var BZe=Object.freeze({__proto__:null,createElement:EH,default:EH});const jZe={fetchBlob:function(e,t,n){return ni(this,void 0,void 0,function*(){const r=yield fetch(e,n);if(r.status>=400)throw new Error(`Failed to fetch ${e}: ${r.status} (${r.statusText})`);return function(i,s){ni(this,void 0,void 0,function*(){if(!i.body||!i.headers)return;const o=i.body.getReader(),a=Number(i.headers.get("Content-Length"))||0;let u=0;const l=f=>ni(this,void 0,void 0,function*(){u+=(f==null?void 0:f.length)||0;const d=Math.round(u/a*100);s(d)}),c=()=>ni(this,void 0,void 0,function*(){let f;try{f=yield o.read()}catch{return}f.done||(l(f.value),yield c())});c()})}(r.clone(),t),r.blob()})}};class UZe extends p1{constructor(t){super(),this.isExternalMedia=!1,t.media?(this.media=t.media,this.isExternalMedia=!0):this.media=document.createElement("audio"),t.mediaControls&&(this.media.controls=!0),t.autoplay&&(this.media.autoplay=!0),t.playbackRate!=null&&this.onceMediaEvent("canplay",()=>{t.playbackRate!=null&&(this.media.playbackRate=t.playbackRate)})}onMediaEvent(t,n,r){return this.media.addEventListener(t,n,r),()=>this.media.removeEventListener(t,n)}onceMediaEvent(t,n){return this.onMediaEvent(t,n,{once:!0})}getSrc(){return this.media.currentSrc||this.media.src||""}revokeSrc(){const t=this.getSrc();t.startsWith("blob:")&&URL.revokeObjectURL(t)}canPlayType(t){return this.media.canPlayType(t)!==""}setSrc(t,n){if(this.getSrc()===t)return;this.revokeSrc();const r=n instanceof Blob&&this.canPlayType(n.type)?URL.createObjectURL(n):t;this.media.src=r}destroy(){this.media.pause(),this.isExternalMedia||(this.media.remove(),this.revokeSrc(),this.media.src="",this.media.load())}setMediaElement(t){this.media=t}play(){return ni(this,void 0,void 0,function*(){if(this.media.src)return this.media.play()})}pause(){this.media.pause()}isPlaying(){return!this.media.paused&&!this.media.ended}setTime(t){this.media.currentTime=t}getDuration(){return this.media.duration}getCurrentTime(){return this.media.currentTime}getVolume(){return this.media.volume}setVolume(t){this.media.volume=t}getMuted(){return this.media.muted}setMuted(t){this.media.muted=t}getPlaybackRate(){return this.media.playbackRate}isSeeking(){return this.media.seeking}setPlaybackRate(t,n){n!=null&&(this.media.preservesPitch=n),this.media.playbackRate=t}getMediaElement(){return this.media}setSinkId(t){return this.media.setSinkId(t)}}class rA extends p1{constructor(t,n){super(),this.timeouts=[],this.isScrollable=!1,this.audioData=null,this.resizeObserver=null,this.lastContainerWidth=0,this.isDragging=!1,this.options=t;const r=this.parentFromOptionsContainer(t.container);this.parent=r;const[i,s]=this.initHtml();r.appendChild(i),this.container=i,this.scrollContainer=s.querySelector(".scroll"),this.wrapper=s.querySelector(".wrapper"),this.canvasWrapper=s.querySelector(".canvases"),this.progressWrapper=s.querySelector(".progress"),this.cursor=s.querySelector(".cursor"),n&&s.appendChild(n),this.initEvents()}parentFromOptionsContainer(t){let n;if(typeof t=="string"?n=document.querySelector(t):t instanceof HTMLElement&&(n=t),!n)throw new Error("Container not found");return n}initEvents(){const t=r=>{const i=this.wrapper.getBoundingClientRect(),s=r.clientX-i.left,o=r.clientX-i.left;return[s/i.width,o/i.height]};this.wrapper.addEventListener("click",r=>{const[i,s]=t(r);this.emit("click",i,s)}),this.wrapper.addEventListener("dblclick",r=>{const[i,s]=t(r);this.emit("dblclick",i,s)}),this.options.dragToSeek&&this.initDrag(),this.scrollContainer.addEventListener("scroll",()=>{const{scrollLeft:r,scrollWidth:i,clientWidth:s}=this.scrollContainer,o=r/i,a=(r+s)/i;this.emit("scroll",o,a)});const n=this.createDelay(100);this.resizeObserver=new ResizeObserver(()=>{n().then(()=>this.onContainerResize()).catch(()=>{})}),this.resizeObserver.observe(this.scrollContainer)}onContainerResize(){const t=this.parent.clientWidth;t===this.lastContainerWidth&&this.options.height!=="auto"||(this.lastContainerWidth=t,this.reRender())}initDrag(){(function(t,n,r,i,s=3,o=0){if(!t)return()=>{};let a=()=>{};const u=l=>{if(l.button!==o)return;l.preventDefault(),l.stopPropagation();let c=l.clientX,f=l.clientY,d=!1;const h=v=>{v.preventDefault(),v.stopPropagation();const b=v.clientX,S=v.clientY,T=b-c,E=S-f;if(d||Math.abs(T)>s||Math.abs(E)>s){const I=t.getBoundingClientRect(),{left:A,top:R}=I;d||(r==null||r(c-A,f-R),d=!0),n(T,E,b-A,S-R),c=b,f=S}},p=()=>{d&&(i==null||i()),a()},m=v=>{v.relatedTarget&&v.relatedTarget!==document.documentElement||p()},y=v=>{d&&(v.stopPropagation(),v.preventDefault())},g=v=>{d&&v.preventDefault()};document.addEventListener("pointermove",h),document.addEventListener("pointerup",p),document.addEventListener("pointerout",m),document.addEventListener("pointercancel",m),document.addEventListener("touchmove",g,{passive:!1}),document.addEventListener("click",y,{capture:!0}),a=()=>{document.removeEventListener("pointermove",h),document.removeEventListener("pointerup",p),document.removeEventListener("pointerout",m),document.removeEventListener("pointercancel",m),document.removeEventListener("touchmove",g),setTimeout(()=>{document.removeEventListener("click",y,{capture:!0})},10)}};t.addEventListener("pointerdown",u)})(this.wrapper,(t,n,r)=>{this.emit("drag",Math.max(0,Math.min(1,r/this.wrapper.getBoundingClientRect().width)))},()=>this.isDragging=!0,()=>this.isDragging=!1)}getHeight(t){return t==null?128:isNaN(Number(t))?t==="auto"&&this.parent.clientHeight||128:Number(t)}initHtml(){const t=document.createElement("div"),n=t.attachShadow({mode:"open"});return n.innerHTML=` +***************************************************************************** */function ni(e,t,n,r){return new(n||(n=Promise))(function(i,s){function o(l){try{u(r.next(l))}catch(c){s(c)}}function a(l){try{u(r.throw(l))}catch(c){s(c)}}function u(l){var c;l.done?i(l.value):(c=l.value,c instanceof n?c:new n(function(f){f(c)})).then(o,a)}u((r=r.apply(e,t||[])).next())})}let p1=class{constructor(){this.listeners={}}on(t,n,r){if(this.listeners[t]||(this.listeners[t]=new Set),this.listeners[t].add(n),r==null?void 0:r.once){const i=()=>{this.un(t,i),this.un(t,n)};return this.on(t,i),i}return()=>this.un(t,n)}un(t,n){var r;(r=this.listeners[t])===null||r===void 0||r.delete(n)}once(t,n){return this.on(t,n,{once:!0})}unAll(){this.listeners={}}emit(t,...n){this.listeners[t]&&this.listeners[t].forEach(r=>r(...n))}};const wH={decode:function(e,t){return ni(this,void 0,void 0,function*(){const n=new AudioContext({sampleRate:t});return n.decodeAudioData(e).finally(()=>n.close())})},createBuffer:function(e,t){return typeof e[0]=="number"&&(e=[e]),function(n){const r=n[0];if(r.some(i=>i>1||i<-1)){const i=r.length;let s=0;for(let o=0;os&&(s=a)}for(const o of n)for(let a=0;ae==null?void 0:e[n],copyFromChannel:AudioBuffer.prototype.copyFromChannel,copyToChannel:AudioBuffer.prototype.copyToChannel}}};function yle(e,t){const n=t.xmlns?document.createElementNS(t.xmlns,e):document.createElement(e);for(const[r,i]of Object.entries(t))if(r==="children")for(const[s,o]of Object.entries(t))typeof o=="string"?n.appendChild(document.createTextNode(o)):n.appendChild(yle(s,o));else r==="style"?Object.assign(n.style,i):r==="textContent"?n.textContent=i:n.setAttribute(r,i.toString());return n}function EH(e,t,n){const r=yle(e,t||{});return n==null||n.appendChild(r),r}var jZe=Object.freeze({__proto__:null,createElement:EH,default:EH});const UZe={fetchBlob:function(e,t,n){return ni(this,void 0,void 0,function*(){const r=yield fetch(e,n);if(r.status>=400)throw new Error(`Failed to fetch ${e}: ${r.status} (${r.statusText})`);return function(i,s){ni(this,void 0,void 0,function*(){if(!i.body||!i.headers)return;const o=i.body.getReader(),a=Number(i.headers.get("Content-Length"))||0;let u=0;const l=f=>ni(this,void 0,void 0,function*(){u+=(f==null?void 0:f.length)||0;const d=Math.round(u/a*100);s(d)}),c=()=>ni(this,void 0,void 0,function*(){let f;try{f=yield o.read()}catch{return}f.done||(l(f.value),yield c())});c()})}(r.clone(),t),r.blob()})}};class VZe extends p1{constructor(t){super(),this.isExternalMedia=!1,t.media?(this.media=t.media,this.isExternalMedia=!0):this.media=document.createElement("audio"),t.mediaControls&&(this.media.controls=!0),t.autoplay&&(this.media.autoplay=!0),t.playbackRate!=null&&this.onceMediaEvent("canplay",()=>{t.playbackRate!=null&&(this.media.playbackRate=t.playbackRate)})}onMediaEvent(t,n,r){return this.media.addEventListener(t,n,r),()=>this.media.removeEventListener(t,n)}onceMediaEvent(t,n){return this.onMediaEvent(t,n,{once:!0})}getSrc(){return this.media.currentSrc||this.media.src||""}revokeSrc(){const t=this.getSrc();t.startsWith("blob:")&&URL.revokeObjectURL(t)}canPlayType(t){return this.media.canPlayType(t)!==""}setSrc(t,n){if(this.getSrc()===t)return;this.revokeSrc();const r=n instanceof Blob&&this.canPlayType(n.type)?URL.createObjectURL(n):t;this.media.src=r}destroy(){this.media.pause(),this.isExternalMedia||(this.media.remove(),this.revokeSrc(),this.media.src="",this.media.load())}setMediaElement(t){this.media=t}play(){return ni(this,void 0,void 0,function*(){if(this.media.src)return this.media.play()})}pause(){this.media.pause()}isPlaying(){return!this.media.paused&&!this.media.ended}setTime(t){this.media.currentTime=t}getDuration(){return this.media.duration}getCurrentTime(){return this.media.currentTime}getVolume(){return this.media.volume}setVolume(t){this.media.volume=t}getMuted(){return this.media.muted}setMuted(t){this.media.muted=t}getPlaybackRate(){return this.media.playbackRate}isSeeking(){return this.media.seeking}setPlaybackRate(t,n){n!=null&&(this.media.preservesPitch=n),this.media.playbackRate=t}getMediaElement(){return this.media}setSinkId(t){return this.media.setSinkId(t)}}class rA extends p1{constructor(t,n){super(),this.timeouts=[],this.isScrollable=!1,this.audioData=null,this.resizeObserver=null,this.lastContainerWidth=0,this.isDragging=!1,this.options=t;const r=this.parentFromOptionsContainer(t.container);this.parent=r;const[i,s]=this.initHtml();r.appendChild(i),this.container=i,this.scrollContainer=s.querySelector(".scroll"),this.wrapper=s.querySelector(".wrapper"),this.canvasWrapper=s.querySelector(".canvases"),this.progressWrapper=s.querySelector(".progress"),this.cursor=s.querySelector(".cursor"),n&&s.appendChild(n),this.initEvents()}parentFromOptionsContainer(t){let n;if(typeof t=="string"?n=document.querySelector(t):t instanceof HTMLElement&&(n=t),!n)throw new Error("Container not found");return n}initEvents(){const t=r=>{const i=this.wrapper.getBoundingClientRect(),s=r.clientX-i.left,o=r.clientX-i.left;return[s/i.width,o/i.height]};this.wrapper.addEventListener("click",r=>{const[i,s]=t(r);this.emit("click",i,s)}),this.wrapper.addEventListener("dblclick",r=>{const[i,s]=t(r);this.emit("dblclick",i,s)}),this.options.dragToSeek&&this.initDrag(),this.scrollContainer.addEventListener("scroll",()=>{const{scrollLeft:r,scrollWidth:i,clientWidth:s}=this.scrollContainer,o=r/i,a=(r+s)/i;this.emit("scroll",o,a)});const n=this.createDelay(100);this.resizeObserver=new ResizeObserver(()=>{n().then(()=>this.onContainerResize()).catch(()=>{})}),this.resizeObserver.observe(this.scrollContainer)}onContainerResize(){const t=this.parent.clientWidth;t===this.lastContainerWidth&&this.options.height!=="auto"||(this.lastContainerWidth=t,this.reRender())}initDrag(){(function(t,n,r,i,s=3,o=0){if(!t)return()=>{};let a=()=>{};const u=l=>{if(l.button!==o)return;l.preventDefault(),l.stopPropagation();let c=l.clientX,f=l.clientY,d=!1;const h=v=>{v.preventDefault(),v.stopPropagation();const b=v.clientX,S=v.clientY,T=b-c,E=S-f;if(d||Math.abs(T)>s||Math.abs(E)>s){const I=t.getBoundingClientRect(),{left:A,top:R}=I;d||(r==null||r(c-A,f-R),d=!0),n(T,E,b-A,S-R),c=b,f=S}},p=()=>{d&&(i==null||i()),a()},m=v=>{v.relatedTarget&&v.relatedTarget!==document.documentElement||p()},y=v=>{d&&(v.stopPropagation(),v.preventDefault())},g=v=>{d&&v.preventDefault()};document.addEventListener("pointermove",h),document.addEventListener("pointerup",p),document.addEventListener("pointerout",m),document.addEventListener("pointercancel",m),document.addEventListener("touchmove",g,{passive:!1}),document.addEventListener("click",y,{capture:!0}),a=()=>{document.removeEventListener("pointermove",h),document.removeEventListener("pointerup",p),document.removeEventListener("pointerout",m),document.removeEventListener("pointercancel",m),document.removeEventListener("touchmove",g),setTimeout(()=>{document.removeEventListener("click",y,{capture:!0})},10)}};t.addEventListener("pointerdown",u)})(this.wrapper,(t,n,r)=>{this.emit("drag",Math.max(0,Math.min(1,r/this.wrapper.getBoundingClientRect().width)))},()=>this.isDragging=!0,()=>this.isDragging=!1)}getHeight(t){return t==null?128:isNaN(Number(t))?t==="auto"&&this.parent.clientHeight||128:Number(t)}initHtml(){const t=document.createElement("div"),n=t.attachShadow({mode:"open"});return n.innerHTML=`