@wistia/vhs 2.62.0-beta.0777e663.cd76af5 → 2.62.0-beta.8b159dd5.e739534

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.mjs CHANGED
@@ -1,13 +1,13 @@
1
1
 
2
2
  /*
3
- * @license VHS v2.62.0-beta.0777e663.cd76af5
3
+ * @license VHS v2.62.0-beta.8b159dd5.e739534
4
4
  *
5
5
  * Copyright (c) 2021-2024, Wistia, Inc. and its affiliates.
6
6
  *
7
7
  * This source code is unlicensed, all rights reserved.
8
8
  */
9
9
 
10
- var zO=Object.create;var Nl=Object.defineProperty;var HO=Object.getOwnPropertyDescriptor;var GO=Object.getOwnPropertyNames;var jO=Object.getPrototypeOf,_O=Object.prototype.hasOwnProperty;var L1=(e,t)=>()=>(e&&(t=e(e=0)),t);var Be=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),$1=(e,t)=>{for(var r in t)Nl(e,r,{get:t[r],enumerable:!0})},U5=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let o of GO(t))!_O.call(e,o)&&o!==r&&Nl(e,o,{get:()=>t[o],enumerable:!(n=HO(t,o))||n.enumerable});return e};var U=(e,t,r)=>(r=e!=null?zO(jO(e)):{},U5(t||!e||!e.__esModule?Nl(r,"default",{value:e,enumerable:!0}):r,e)),WO=e=>U5(Nl({},"__esModule",{value:!0}),e);import*as f from"react";var i=L1(()=>{"use strict"});var Z=Be(ee=>{"use strict";i();Object.defineProperty(ee,"__esModule",{value:!0});ee.hasKey=ee.isError=ee.isVoid=ee.isBoolean=ee.isFunction=ee.isNonEmptyArray=ee.isEmptyArray=ee.isArray=ee.isNonEmptyRecord=ee.isEmptyRecord=ee.isRecord=ee.isInteger=ee.isNaN=ee.isNotNumber=ee.isNumber=ee.isNonEmptyString=ee.isEmptyString=ee.isNotString=ee.isString=ee.isNotNil=ee.isNil=ee.isNotUndefined=ee.isUndefined=ee.isNotNull=ee.isNull=void 0;var UO=e=>e===null;ee.isNull=UO;var KO=e=>!(0,ee.isNull)(e);ee.isNotNull=KO;var qO=e=>e===void 0;ee.isUndefined=qO;var XO=e=>!(0,ee.isUndefined)(e);ee.isNotUndefined=XO;var YO=e=>(0,ee.isNull)(e)||(0,ee.isUndefined)(e);ee.isNil=YO;var JO=e=>!(0,ee.isNil)(e);ee.isNotNil=JO;var ZO=e=>typeof e=="string";ee.isString=ZO;var QO=e=>!(0,ee.isString)(e);ee.isNotString=QO;var eM=e=>(0,ee.isString)(e)&&e==="";ee.isEmptyString=eM;var tM=e=>(0,ee.isString)(e)&&!(0,ee.isEmptyString)(e);ee.isNonEmptyString=tM;var rM=e=>typeof e=="number";ee.isNumber=rM;var nM=e=>!(0,ee.isNumber)(e);ee.isNotNumber=nM;var oM=e=>Number.isNaN(e);ee.isNaN=oM;var iM=e=>Number.isInteger(e);ee.isInteger=iM;var aM=e=>(0,ee.isNotNil)(e)&&typeof e=="object"&&!(e instanceof Array);ee.isRecord=aM;var sM=e=>(0,ee.isRecord)(e)&&Object.keys(e).length===0;ee.isEmptyRecord=sM;var uM=e=>(0,ee.isRecord)(e)&&Object.keys(e).length>0;ee.isNonEmptyRecord=uM;var lM=e=>(0,ee.isNotNil)(e)&&typeof e=="object"&&e instanceof Array;ee.isArray=lM;var cM=e=>(0,ee.isArray)(e)&&e.length===0;ee.isEmptyArray=cM;var fM=e=>(0,ee.isArray)(e)&&e.length>0;ee.isNonEmptyArray=fM;var pM=e=>(0,ee.isNotNil)(e)&&typeof e=="function";ee.isFunction=pM;var dM=e=>(0,ee.isNotNil)(e)&&typeof e=="boolean";ee.isBoolean=dM;var mM=e=>e===void 0;ee.isVoid=mM;var hM=e=>(0,ee.isNotNil)(e)&&e instanceof Error;ee.isError=hM;var gM=(e,t)=>(0,ee.isNonEmptyRecord)(e)&&t in e;ee.hasKey=gM});var G3=Be((spe,fm)=>{i();var H3=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||typeof msCrypto<"u"&&typeof window.msCrypto.getRandomValues=="function"&&msCrypto.getRandomValues.bind(msCrypto);H3?(lm=new Uint8Array(16),fm.exports=function(){return H3(lm),lm}):(cm=new Array(16),fm.exports=function(){for(var t=0,r;t<16;t++)t&3||(r=Math.random()*4294967296),cm[t]=r>>>((t&3)<<3)&255;return cm});var lm,cm});var W3=Be((lpe,_3)=>{i();var j3=[];for(Js=0;Js<256;++Js)j3[Js]=(Js+256).toString(16).substr(1);var Js;function TI(e,t){var r=t||0,n=j3;return[n[e[r++]],n[e[r++]],n[e[r++]],n[e[r++]],"-",n[e[r++]],n[e[r++]],"-",n[e[r++]],n[e[r++]],"-",n[e[r++]],n[e[r++]],"-",n[e[r++]],n[e[r++]],n[e[r++]],n[e[r++]],n[e[r++]],n[e[r++]]].join("")}_3.exports=TI});var K3=Be((fpe,U3)=>{i();var AI=G3(),RI=W3();function FI(e,t,r){var n=t&&r||0;typeof e=="string"&&(t=e==="binary"?new Array(16):null,e=null),e=e||{};var o=e.random||(e.rng||AI)();if(o[6]=o[6]&15|64,o[8]=o[8]&63|128,t)for(var a=0;a<16;++a)t[n+a]=o[a];return t||RI(o)}U3.exports=FI});function Sv(e){var t=Object.create(null);return function(r){return t[r]===void 0&&(t[r]=e(r)),t[r]}}var Dv=L1(()=>{i()});var Ev={};$1(Ev,{default:()=>hk});var mk,hk,Pv=L1(()=>{i();Dv();mk=/^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|abbr|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|disableRemotePlayback|download|draggable|encType|enterKeyHint|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/,hk=Sv(function(e){return mk.test(e)||e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)<91})});var Lx=Be((z$e,Vx)=>{"use strict";i();var kx=Array.isArray,Nx=Object.keys,Wj=Object.prototype.hasOwnProperty,Uj=typeof Element<"u";function G0(e,t){if(e===t)return!0;if(e&&t&&typeof e=="object"&&typeof t=="object"){var r=kx(e),n=kx(t),o,a,s;if(r&&n){if(a=e.length,a!=t.length)return!1;for(o=a;o--!==0;)if(!G0(e[o],t[o]))return!1;return!0}if(r!=n)return!1;var u=e instanceof Date,l=t instanceof Date;if(u!=l)return!1;if(u&&l)return e.getTime()==t.getTime();var c=e instanceof RegExp,p=t instanceof RegExp;if(c!=p)return!1;if(c&&p)return e.toString()==t.toString();var d=Nx(e);if(a=d.length,a!==Nx(t).length)return!1;for(o=a;o--!==0;)if(!Wj.call(t,d[o]))return!1;if(Uj&&e instanceof Element&&t instanceof Element)return e===t;for(o=a;o--!==0;)if(s=d[o],!(s==="_owner"&&e.$$typeof)&&!G0(e[s],t[s]))return!1;return!0}return e!==e&&t!==t}Vx.exports=function(t,r){try{return G0(t,r)}catch(n){if(n.message&&n.message.match(/stack|recursion/i)||n.number===-2146828260)return console.warn("Warning: react-fast-compare does not handle circular references.",n.name,n.message),!1;throw n}}});var Yx=Be(Te=>{"use strict";i();var lt=typeof Symbol=="function"&&Symbol.for,U0=lt?Symbol.for("react.element"):60103,K0=lt?Symbol.for("react.portal"):60106,qf=lt?Symbol.for("react.fragment"):60107,Xf=lt?Symbol.for("react.strict_mode"):60108,Yf=lt?Symbol.for("react.profiler"):60114,Jf=lt?Symbol.for("react.provider"):60109,Zf=lt?Symbol.for("react.context"):60110,q0=lt?Symbol.for("react.async_mode"):60111,Qf=lt?Symbol.for("react.concurrent_mode"):60111,ep=lt?Symbol.for("react.forward_ref"):60112,tp=lt?Symbol.for("react.suspense"):60113,f_=lt?Symbol.for("react.suspense_list"):60120,rp=lt?Symbol.for("react.memo"):60115,np=lt?Symbol.for("react.lazy"):60116,p_=lt?Symbol.for("react.block"):60121,d_=lt?Symbol.for("react.fundamental"):60117,m_=lt?Symbol.for("react.responder"):60118,h_=lt?Symbol.for("react.scope"):60119;function pr(e){if(typeof e=="object"&&e!==null){var t=e.$$typeof;switch(t){case U0:switch(e=e.type,e){case q0:case Qf:case qf:case Yf:case Xf:case tp:return e;default:switch(e=e&&e.$$typeof,e){case Zf:case ep:case np:case rp:case Jf:return e;default:return t}}case K0:return t}}}function Xx(e){return pr(e)===Qf}Te.AsyncMode=q0;Te.ConcurrentMode=Qf;Te.ContextConsumer=Zf;Te.ContextProvider=Jf;Te.Element=U0;Te.ForwardRef=ep;Te.Fragment=qf;Te.Lazy=np;Te.Memo=rp;Te.Portal=K0;Te.Profiler=Yf;Te.StrictMode=Xf;Te.Suspense=tp;Te.isAsyncMode=function(e){return Xx(e)||pr(e)===q0};Te.isConcurrentMode=Xx;Te.isContextConsumer=function(e){return pr(e)===Zf};Te.isContextProvider=function(e){return pr(e)===Jf};Te.isElement=function(e){return typeof e=="object"&&e!==null&&e.$$typeof===U0};Te.isForwardRef=function(e){return pr(e)===ep};Te.isFragment=function(e){return pr(e)===qf};Te.isLazy=function(e){return pr(e)===np};Te.isMemo=function(e){return pr(e)===rp};Te.isPortal=function(e){return pr(e)===K0};Te.isProfiler=function(e){return pr(e)===Yf};Te.isStrictMode=function(e){return pr(e)===Xf};Te.isSuspense=function(e){return pr(e)===tp};Te.isValidElementType=function(e){return typeof e=="string"||typeof e=="function"||e===qf||e===Qf||e===Yf||e===Xf||e===tp||e===f_||typeof e=="object"&&e!==null&&(e.$$typeof===np||e.$$typeof===rp||e.$$typeof===Jf||e.$$typeof===Zf||e.$$typeof===ep||e.$$typeof===d_||e.$$typeof===m_||e.$$typeof===h_||e.$$typeof===p_)};Te.typeOf=pr});var Zx=Be((Bze,Jx)=>{"use strict";i();Jx.exports=Yx()});var iw=Be((Mze,ow)=>{"use strict";i();var X0=Zx(),g_={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},v_={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},y_={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},rw={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},Y0={};Y0[X0.ForwardRef]=y_;Y0[X0.Memo]=rw;function Qx(e){return X0.isMemo(e)?rw:Y0[e.$$typeof]||g_}var b_=Object.defineProperty,C_=Object.getOwnPropertyNames,ew=Object.getOwnPropertySymbols,x_=Object.getOwnPropertyDescriptor,w_=Object.getPrototypeOf,tw=Object.prototype;function nw(e,t,r){if(typeof t!="string"){if(tw){var n=w_(t);n&&n!==tw&&nw(e,n,r)}var o=C_(t);ew&&(o=o.concat(ew(t)));for(var a=Qx(e),s=Qx(t),u=0;u<o.length;++u){var l=o[u];if(!v_[l]&&!(r&&r[l])&&!(s&&s[l])&&!(a&&a[l])){var c=x_(t,l);try{b_(e,l,c)}catch{}}}}return e}ow.exports=nw});var up=Be((rGe,mw)=>{i();var iW=typeof Element<"u",aW=typeof Map=="function",sW=typeof Set=="function",uW=typeof ArrayBuffer=="function"&&!!ArrayBuffer.isView;function sp(e,t){if(e===t)return!0;if(e&&t&&typeof e=="object"&&typeof t=="object"){if(e.constructor!==t.constructor)return!1;var r,n,o;if(Array.isArray(e)){if(r=e.length,r!=t.length)return!1;for(n=r;n--!==0;)if(!sp(e[n],t[n]))return!1;return!0}var a;if(aW&&e instanceof Map&&t instanceof Map){if(e.size!==t.size)return!1;for(a=e.entries();!(n=a.next()).done;)if(!t.has(n.value[0]))return!1;for(a=e.entries();!(n=a.next()).done;)if(!sp(n.value[1],t.get(n.value[0])))return!1;return!0}if(sW&&e instanceof Set&&t instanceof Set){if(e.size!==t.size)return!1;for(a=e.entries();!(n=a.next()).done;)if(!t.has(n.value[0]))return!1;return!0}if(uW&&ArrayBuffer.isView(e)&&ArrayBuffer.isView(t)){if(r=e.length,r!=t.length)return!1;for(n=r;n--!==0;)if(e[n]!==t[n])return!1;return!0}if(e.constructor===RegExp)return e.source===t.source&&e.flags===t.flags;if(e.valueOf!==Object.prototype.valueOf&&typeof e.valueOf=="function"&&typeof t.valueOf=="function")return e.valueOf()===t.valueOf();if(e.toString!==Object.prototype.toString&&typeof e.toString=="function"&&typeof t.toString=="function")return e.toString()===t.toString();if(o=Object.keys(e),r=o.length,r!==Object.keys(t).length)return!1;for(n=r;n--!==0;)if(!Object.prototype.hasOwnProperty.call(t,o[n]))return!1;if(iW&&e instanceof Element)return!1;for(n=r;n--!==0;)if(!((o[n]==="_owner"||o[n]==="__v"||o[n]==="__o")&&e.$$typeof)&&!sp(e[o[n]],t[o[n]]))return!1;return!0}return e!==e&&t!==t}mw.exports=function(t,r){try{return sp(t,r)}catch(n){if((n.message||"").match(/stack|recursion/i))return console.warn("react-fast-compare cannot handle circular refs"),!1;throw n}}});var fD=Be((gJe,cD)=>{"use strict";i();cD.exports=UX;var uD="\u0591-\u07FF\uFB1D-\uFDFD\uFE70-\uFEFC",lD="A-Za-z\xC0-\xD6\xD8-\xF6\xF8-\u02B8\u0300-\u0590\u0800-\u1FFF\u200E\u2C00-\uFB1C\uFE00-\uFE6F\uFEFD-\uFFFF",_X=new RegExp("^[^"+lD+"]*["+uD+"]"),WX=new RegExp("^[^"+uD+"]*["+lD+"]");function UX(e){return e=String(e||""),_X.test(e)?"rtl":WX.test(e)?"ltr":"neutral"}});var qp=Be((yJe,pD)=>{i();function KX(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}pD.exports=KX});var mD=Be((CJe,dD)=>{i();var qX=typeof window=="object"&&window&&window.Object===Object&&window;dD.exports=qX});var Kh=Be((wJe,hD)=>{i();var XX=mD(),YX=typeof self=="object"&&self&&self.Object===Object&&self,JX=XX||YX||Function("return this")();hD.exports=JX});var vD=Be((DJe,gD)=>{i();var ZX=Kh(),QX=function(){return ZX.Date.now()};gD.exports=QX});var bD=Be((PJe,yD)=>{i();var eY=/\s/;function tY(e){for(var t=e.length;t--&&eY.test(e.charAt(t)););return t}yD.exports=tY});var xD=Be((AJe,CD)=>{i();var rY=bD(),nY=/^\s+/;function oY(e){return e&&e.slice(0,rY(e)+1).replace(nY,"")}CD.exports=oY});var qh=Be((FJe,wD)=>{i();var iY=Kh(),aY=iY.Symbol;wD.exports=aY});var PD=Be((OJe,ED)=>{i();var SD=qh(),DD=Object.prototype,sY=DD.hasOwnProperty,uY=DD.toString,ju=SD?SD.toStringTag:void 0;function lY(e){var t=sY.call(e,ju),r=e[ju];try{e[ju]=void 0;var n=!0}catch{}var o=uY.call(e);return n&&(t?e[ju]=r:delete e[ju]),o}ED.exports=lY});var AD=Be((IJe,TD)=>{i();var cY=Object.prototype,fY=cY.toString;function pY(e){return fY.call(e)}TD.exports=pY});var OD=Be((NJe,BD)=>{i();var RD=qh(),dY=PD(),mY=AD(),hY="[object Null]",gY="[object Undefined]",FD=RD?RD.toStringTag:void 0;function vY(e){return e==null?e===void 0?gY:hY:FD&&FD in Object(e)?dY(e):mY(e)}BD.exports=vY});var ID=Be((LJe,MD)=>{i();function yY(e){return e!=null&&typeof e=="object"}MD.exports=yY});var ND=Be((zJe,kD)=>{i();var bY=OD(),CY=ID(),xY="[object Symbol]";function wY(e){return typeof e=="symbol"||CY(e)&&bY(e)==xY}kD.exports=wY});var zD=Be((GJe,$D)=>{i();var SY=xD(),VD=qp(),DY=ND(),LD=NaN,EY=/^[-+]0x[0-9a-f]+$/i,PY=/^0b[01]+$/i,TY=/^0o[0-7]+$/i,AY=parseInt;function RY(e){if(typeof e=="number")return e;if(DY(e))return LD;if(VD(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=VD(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=SY(e);var r=PY.test(e);return r||TY.test(e)?AY(e.slice(2),r?2:8):EY.test(e)?LD:+e}$D.exports=RY});var Yh=Be((_Je,GD)=>{i();var FY=qp(),Xh=vD(),HD=zD(),BY="Expected a function",OY=Math.max,MY=Math.min;function IY(e,t,r){var n,o,a,s,u,l,c=0,p=!1,d=!1,h=!0;if(typeof e!="function")throw new TypeError(BY);t=HD(t)||0,FY(r)&&(p=!!r.leading,d="maxWait"in r,a=d?OY(HD(r.maxWait)||0,t):a,h="trailing"in r?!!r.trailing:h);function g(D){var P=n,R=o;return n=o=void 0,c=D,s=e.apply(R,P),s}function v(D){return c=D,u=setTimeout(y,t),p?g(D):s}function m(D){var P=D-l,R=D-c,F=t-P;return d?MY(F,a-R):F}function b(D){var P=D-l,R=D-c;return l===void 0||P>=t||P<0||d&&R>=a}function y(){var D=Xh();if(b(D))return x(D);u=setTimeout(y,m(D))}function x(D){return u=void 0,h&&n?g(D):(n=o=void 0,s)}function w(){u!==void 0&&clearTimeout(u),c=0,n=l=o=u=void 0}function S(){return u===void 0?s:x(Xh())}function E(){var D=Xh(),P=b(D);if(n=arguments,o=this,l=D,P){if(u===void 0)return v(l);if(d)return clearTimeout(u),u=setTimeout(y,t),g(l)}return u===void 0&&(u=setTimeout(y,t)),s}return E.cancel=w,E.flush=S,E}GD.exports=IY});var _D=Be((UJe,jD)=>{i();var kY=Yh(),NY=qp(),VY="Expected a function";function LY(e,t,r){var n=!0,o=!0;if(typeof e!="function")throw new TypeError(VY);return NY(r)&&(n="leading"in r?!!r.leading:n,o="trailing"in r?!!r.trailing:o),kY(e,t,{leading:n,maxWait:t,trailing:o})}jD.exports=LY});var sP=Be(sn=>{"use strict";i();Object.defineProperty(sn,"__esModule",{value:!0});var wQ=typeof window<"u"&&/Mac|iPod|iPhone|iPad/.test(window.navigator.platform),F2={alt:"altKey",control:"ctrlKey",meta:"metaKey",shift:"shiftKey"},SQ={add:"+",break:"pause",cmd:"meta",command:"meta",ctl:"control",ctrl:"control",del:"delete",down:"arrowdown",esc:"escape",ins:"insert",left:"arrowleft",mod:wQ?"meta":"control",opt:"alt",option:"alt",return:"enter",right:"arrowright",space:" ",spacebar:" ",up:"arrowup",win:"meta",windows:"meta"},nP={backspace:8,tab:9,enter:13,shift:16,control:17,alt:18,pause:19,capslock:20,escape:27," ":32,pageup:33,pagedown:34,end:35,home:36,arrowleft:37,arrowup:38,arrowright:39,arrowdown:40,insert:45,delete:46,meta:91,numlock:144,scrolllock:145,";":186,"=":187,",":188,"-":189,".":190,"/":191,"`":192,"[":219,"\\":220,"]":221,"'":222};for(Ju=1;Ju<20;Ju++)nP["f"+Ju]=111+Ju;var Ju;function fd(e,t,r){t&&!("byKey"in t)&&(r=t,t=null),Array.isArray(e)||(e=[e]);var n=e.map(function(s){return oP(s,t)}),o=function(u){return n.some(function(l){return iP(l,u)})},a=r==null?o:o(r);return a}function DQ(e,t){return fd(e,t)}function EQ(e,t){return fd(e,{byKey:!0},t)}function oP(e,t){var r=t&&t.byKey,n={};e=e.replace("++","+add");var o=e.split("+"),a=o.length;for(var s in F2)n[F2[s]]=!1;var u=!0,l=!1,c=void 0;try{for(var p=o[Symbol.iterator](),d;!(u=(d=p.next()).done);u=!0){var h=d.value,g=h.endsWith("?")&&h.length>1;g&&(h=h.slice(0,-1));var v=B2(h),m=F2[v];(a===1||!m)&&(r?n.key=v:n.which=aP(h)),m&&(n[m]=g?null:!0)}}catch(b){l=!0,c=b}finally{try{!u&&p.return&&p.return()}finally{if(l)throw c}}return n}function iP(e,t){for(var r in e){var n=e[r],o=void 0;if(n!=null&&(r==="key"&&t.key!=null?o=t.key.toLowerCase():r==="which"?o=n===91&&t.which===93?91:t.which:o=t[r],!(o==null&&n===!1)&&o!==n))return!1}return!0}function aP(e){e=B2(e);var t=nP[e]||e.toUpperCase().charCodeAt(0);return t}function B2(e){return e=e.toLowerCase(),e=SQ[e]||e,e}sn.default=fd;sn.isHotkey=fd;sn.isCodeHotkey=DQ;sn.isKeyHotkey=EQ;sn.parseHotkey=oP;sn.compareHotkey=iP;sn.toKeyCode=aP;sn.toKeyName=B2});var JP=Be(un=>{"use strict";i();Object.defineProperty(un,"__esModule",{value:!0});var Jee=typeof window<"u"&&/Mac|iPod|iPhone|iPad/.test(window.navigator.platform),X2={alt:"altKey",control:"ctrlKey",meta:"metaKey",shift:"shiftKey"},KP={add:"+",break:"pause",cmd:"meta",command:"meta",ctl:"control",ctrl:"control",del:"delete",down:"arrowdown",esc:"escape",ins:"insert",left:"arrowleft",mod:Jee?"meta":"control",opt:"alt",option:"alt",return:"enter",right:"arrowright",space:" ",spacebar:" ",up:"arrowup",win:"meta",windows:"meta"},Y2={backspace:8,tab:9,enter:13,shift:16,control:17,alt:18,pause:19,capslock:20,escape:27," ":32,pageup:33,pagedown:34,end:35,home:36,arrowleft:37,arrowup:38,arrowright:39,arrowdown:40,insert:45,delete:46,meta:91,numlock:144,scrolllock:145,";":186,"=":187,",":188,"-":189,".":190,"/":191,"`":192,"[":219,"\\":220,"]":221,"'":222};for(nl=1;nl<20;nl++)Y2["f"+nl]=111+nl;var nl;function wd(e,t,r){t&&!("byKey"in t)&&(r=t,t=null),Array.isArray(e)||(e=[e]);var n=e.map(function(s){return qP(s,t)}),o=function(u){return n.some(function(l){return XP(l,u)})},a=r==null?o:o(r);return a}function Zee(e,t){return wd(e,t)}function Qee(e,t){return wd(e,{byKey:!0},t)}function qP(e,t){var r=t&&t.byKey,n={};e=e.replace("++","+add");var o=e.split("+"),a=o.length;for(var s in X2)n[X2[s]]=!1;var u=!0,l=!1,c=void 0;try{for(var p=o[Symbol.iterator](),d;!(u=(d=p.next()).done);u=!0){var h=d.value,g=h.endsWith("?")&&h.length>1;g&&(h=h.slice(0,-1));var v=J2(h),m=X2[v];if(h.length>1&&!m&&!KP[h]&&!Y2[v])throw new TypeError('Unknown modifier: "'+h+'"');(a===1||!m)&&(r?n.key=v:n.which=YP(h)),m&&(n[m]=g?null:!0)}}catch(b){l=!0,c=b}finally{try{!u&&p.return&&p.return()}finally{if(l)throw c}}return n}function XP(e,t){for(var r in e){var n=e[r],o=void 0;if(n!=null&&(r==="key"&&t.key!=null?o=t.key.toLowerCase():r==="which"?o=n===91&&t.which===93?91:t.which:o=t[r],!(o==null&&n===!1)&&o!==n))return!1}return!0}function YP(e){e=J2(e);var t=Y2[e]||e.toUpperCase().charCodeAt(0);return t}function J2(e){return e=e.toLowerCase(),e=KP[e]||e,e}un.default=wd;un.isHotkey=wd;un.isCodeHotkey=Zee;un.isKeyHotkey=Qee;un.parseHotkey=qP;un.compareHotkey=XP;un.toKeyCode=YP;un.toKeyName=J2});i();i();i();var Vs=async e=>{if(navigator.clipboard)return navigator.clipboard.writeText(e).catch(a=>{throw a instanceof Error?a:new DOMException("The clipboard is not accessible","NotAllowedError")});let t=document.createElement("span");t.textContent=e,t.style.whiteSpace="pre",document.body.appendChild(t);let r=window.getSelection(),n=window.document.createRange();r?.removeAllRanges(),n.selectNode(t),r?.addRange(n);let o=!1;try{o=window.document.execCommand("copy")}catch(a){console.error("error",a)}return r?.removeAllRanges(),window.document.body.removeChild(t),o?Promise.resolve():Promise.reject(new DOMException("The request is not allowed","NotAllowedError"))};i();i();var o3=U(Z());i();i();function ae(e){let t=Object.prototype.toString.call(e);return e instanceof Date||typeof e=="object"&&t==="[object Date]"?new e.constructor(+e):typeof e=="number"||t==="[object Number]"||typeof e=="string"||t==="[object String]"?new Date(e):new Date(NaN)}i();function Jo(e,t){return e instanceof Date?new e.constructor(t):new Date(t)}function z1(e,t){let r=ae(e);return isNaN(t)?Jo(e,NaN):(t&&r.setDate(r.getDate()+t),r)}i();function Ls(e,t){let r=ae(e);if(isNaN(t))return Jo(e,NaN);if(!t)return r;let n=r.getDate(),o=Jo(e,r.getTime());o.setMonth(r.getMonth()+t+1,0);let a=o.getDate();return n>=a?o:(r.setFullYear(o.getFullYear(),o.getMonth(),n),r)}i();var vM=Math.pow(10,8)*24*60*60*1e3,lue=-vM;var K5=864e5;var yM=3600;var q5=yM*24,cue=q5*7,bM=q5*365.2425,CM=bM/12,fue=CM*3;i();i();function kr(e){let t=ae(e);return t.setHours(0,0,0,0),t}i();function H1(e){let t=ae(e),r=new Date(Date.UTC(t.getFullYear(),t.getMonth(),t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()));return r.setUTCFullYear(t.getFullYear()),+e-+r}function Vl(e,t){let r=kr(e),n=kr(t),o=+r-H1(r),a=+n-H1(n);return Math.round((o-a)/K5)}i();function G1(e,t){return Ls(e,t*12)}i();function Ll(e,t){let r=ae(e),n=ae(t),o=r.getTime()-n.getTime();return o<0?-1:o>0?1:o}i();function ar(e,t){let r=kr(e),n=kr(t);return+r==+n}i();i();function X5(e){return e instanceof Date||typeof e=="object"&&Object.prototype.toString.call(e)==="[object Date]"}function $s(e){if(!X5(e)&&typeof e!="number")return!1;let t=ae(e);return!isNaN(Number(t))}i();function J5(e,t){let r=ae(e),n=ae(t),o=Y5(r,n),a=Math.abs(Vl(r,n));r.setDate(r.getDate()-o*a);let s=+(Y5(r,n)===-o),u=o*(a-s);return u===0?0:u}function Y5(e,t){let r=e.getFullYear()-t.getFullYear()||e.getMonth()-t.getMonth()||e.getDate()-t.getDate()||e.getHours()-t.getHours()||e.getMinutes()-t.getMinutes()||e.getSeconds()-t.getSeconds()||e.getMilliseconds()-t.getMilliseconds();return r<0?-1:r>0?1:r}i();function Ji(e){let t=ae(e);return t.setHours(23,59,59,999),t}i();function j1(e){let t=ae(e),r=t.getMonth();return t.setFullYear(t.getFullYear(),r+1,0),t.setHours(23,59,59,999),t}i();function Z5(e,t){let r=ae(e.start),n=ae(e.end),o=+r>+n,a=o?+r:+n,s=o?n:r;s.setHours(0,0,0,0);let u=t?.step??1;if(!u)return[];u<0&&(u=-u,o=!o);let l=[];for(;+s<=a;)l.push(ae(s)),s.setDate(s.getDate()+u),s.setHours(0,0,0,0);return o?l.reverse():l}i();function _1(e,t){let r=ae(e.start),n=ae(e.end),o=+r>+n,a=o?+r:+n,s=o?n:r;s.setHours(0,0,0,0),s.setDate(1);let u=t?.step??1;if(!u)return[];u<0&&(u=-u,o=!o);let l=[];for(;+s<=a;)l.push(ae(s)),s.setMonth(s.getMonth()+u);return o?l.reverse():l}i();function zs(e){let t=ae(e);return t.setDate(1),t.setHours(0,0,0,0),t}i();function Q5(e){return ae(e).getDay()}i();function W1(e){let t=ae(e),r=t.getFullYear(),n=t.getMonth(),o=Jo(e,0);return o.setFullYear(r,n+1,0),o.setHours(0,0,0,0),o.getDate()}i();function U1(e){return ae(e).getFullYear()}i();function e3(e,t){let r=ae(e),n=ae(t);return r.getTime()>n.getTime()}i();function qr(e,t){let r=ae(e),n=ae(t);return+r<+n}i();function K1(e,t){let r=ae(e),n=ae(t);return+r==+n}i();function t3(e){return+ae(e)>Date.now()}i();function r3(e,t){let r=+ae(e),[n,o]=[+ae(t.start),+ae(t.end)].sort((a,s)=>a-s);return r>=n&&r<=o}var i3=1e3,q1=60,Gs=60,n3=30,br=["en-US"],yn=Intl.DateTimeFormat().resolvedOptions().timeZone||"UTC",Hs=e=>e.toString().padStart(2,"0"),Nr=e=>e instanceof Date,bn=e=>!Nr(e)||e.getTime()===0,a3=(e,{timeZone:t=yn}={})=>{if(!Nr(e)||bn(e))return"";try{return new Intl.DateTimeFormat(br,{dateStyle:"medium",timeZone:t}).format(e)}catch(r){return console.error(r),""}},s3=(e,{timeZone:t=yn}={})=>{if(!Nr(e)||bn(e))return"";try{return new Intl.DateTimeFormat(br,{year:"numeric",month:"2-digit",day:"2-digit",timeZone:t}).format(e)}catch(r){return console.error(r),""}},u3=(e,{timeZone:t=yn}={})=>{if(!Nr(e)||bn(e))return"";try{let o=new Intl.DateTimeFormat(br,{year:"numeric",month:"2-digit",day:"2-digit",timeZone:t}).formatToParts(e).reduce((a,s)=>(a[s.type]=s.value,a),{});return`${o.year}-${o.month}-${o.day}`}catch(r){return console.error(r),""}},l3=(e,{timeZone:t=yn}={})=>{if(!Nr(e)||bn(e))return"";try{return new Intl.DateTimeFormat(br,{month:"2-digit",day:"2-digit",timeZone:t}).format(e)}catch(r){return console.error(r),""}},c3=(e,{timeZone:t=yn}={})=>{if(e===null)return"";try{return new Intl.DateTimeFormat(br,{weekday:"long",timeZone:t}).format(e)}catch(r){return console.error(r),""}},f3=(e,{timeZone:t=yn}={})=>{if(!Nr(e)||bn(e))return"";try{return new Intl.DateTimeFormat(br,{timeStyle:"short",timeZone:t}).format(e)}catch(r){return console.error(r),""}},$l=(e,{timeZone:t=yn}={})=>{if((0,o3.isNil)(e))return"";let r=new Date(e);if(bn(r))return"";try{return new Intl.DateTimeFormat(br,{dateStyle:"medium",timeStyle:"short",timeZone:t}).format(r)}catch(n){return console.error(n),""}},p3=(e,{timeZone:t=yn}={})=>{if(!Nr(e)||bn(e))return"";try{let{year:r,month:n,day:o,hour:a,minute:s,dayPeriod:u}=new Intl.DateTimeFormat(br,{month:"long",day:"numeric",year:"numeric",hour:"numeric",minute:"2-digit",timeZone:t}).formatToParts(e).reduce((l,c)=>(c.type!=="literal"&&(l[c.type]=c.value),l),{});return`${n} ${o}, ${r}, ${a}:${s} ${u}`}catch(r){return console.error(r),""}},d3=(e,{timeZone:t=yn}={})=>{if(!Nr(e)||bn(e))return"";try{return new Intl.DateTimeFormat(br,{dateStyle:"long",timeZone:t}).format(e)}catch(r){return console.error(r),""}},m3=(e,{nowAnchor:t=new Date}={})=>{if(bn(e))return"";let r=(t.valueOf()-e.valueOf())/(q1*i3),n=Math.round(r),o=Vl(t,e);return r<0?$l(e):r<1?"< 1 minute ago":n<2?"1 minute ago":n<=Gs?`${n} minutes ago`:o===0?`Today, ${Intl.DateTimeFormat(br,{timeStyle:"short"}).format(e)}`:o===1?`Yesterday, ${Intl.DateTimeFormat(br,{timeStyle:"short"}).format(e)}`:e.getFullYear()===t.getFullYear()?Intl.DateTimeFormat(br,{day:"numeric",month:"short",hour:"numeric",minute:"2-digit"}).format(e):$l(e)},h3=e=>{let t=e.getTimezoneOffset()/Gs*-1,r=Math.round(t),n=(t-r)*Gs,o=r>=0?"+":"",a=`${r}`.padStart(2,"0"),s=`${n}`.padStart(2,"0");return`${o}${a}:${s}`},js=e=>{let t=Math.floor(e/i3),r=Math.floor(t/q1),n=Math.floor(r/Gs),o=t-r*q1,a=r-n*Gs;return{seconds:o,minutes:a,hours:n}},g3=e=>{let{hours:t,minutes:r,seconds:n}=js(e);return t<1?`${r}:${Hs(n)}`:`${t}:${Hs(r)}:${Hs(n)}`},v3=e=>{let{hours:t,minutes:r,seconds:n}=js(e);return`${t}:${Hs(r)}:${Hs(n)}`},X1=e=>Nr(e)?{year:e.getFullYear(),month:e.getMonth(),dayOfMonth:e.getDate(),hours:e.getHours(),minutes:e.getMinutes()}:null,zl=e=>{let{year:t,month:r,dayOfMonth:n,hours:o,minutes:a}=e??{};return t!==void 0&&r!==void 0&&n!==void 0?new Date(t,r,n,o??0,a??0):null},Y1=e=>zl(e)?.toISOString()??null,y3=(e,t=!0)=>{let r=e.getMinutes()<=n3,n=r?e.getHours():e.getHours()+1,o=r?n3:0,a={...X1(e),hours:n,minutes:o};return t?Y1(a):zl(a)},b3=e=>{let{seconds:t,minutes:r,hours:n}=js(e),o="PT";return n&&(o+=`${n}H`),r&&(o+=`${r}M`),t&&(o+=`${t}S`),t||r||n||(o+="0S"),o};var Ile={isDate:Nr,dateOnlyString:a3,dateOnlyStringNumeric:s3,dateOnlyISOString:u3,monthDayStringNumeric:l3,dayOfWeekString:c3,timeOnlyString:f3,dateTimeString:$l,dateTimeStringForSentence:p3,dateOnlyStringForSentence:d3,timeAgoString:m3,dateUTCOffset:h3,buildTimeDuration:js,mediaDurationString:g3,sessionDurationString:v3,dateToDateTime:X1,dateTimeToDate:zl,dateTimeToISO:Y1,dateTimeRounded:y3,millisecondsToDurationISOString:b3};i();i();var C3=U(Z());import{css as Dt}from"styled-components";var J1={defaultDarkOne:Dt`
10
+ var zO=Object.create;var Nl=Object.defineProperty;var HO=Object.getOwnPropertyDescriptor;var GO=Object.getOwnPropertyNames;var jO=Object.getPrototypeOf,_O=Object.prototype.hasOwnProperty;var L1=(e,t)=>()=>(e&&(t=e(e=0)),t);var Be=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),$1=(e,t)=>{for(var r in t)Nl(e,r,{get:t[r],enumerable:!0})},U5=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let o of GO(t))!_O.call(e,o)&&o!==r&&Nl(e,o,{get:()=>t[o],enumerable:!(n=HO(t,o))||n.enumerable});return e};var U=(e,t,r)=>(r=e!=null?zO(jO(e)):{},U5(t||!e||!e.__esModule?Nl(r,"default",{value:e,enumerable:!0}):r,e)),WO=e=>U5(Nl({},"__esModule",{value:!0}),e);import*as f from"react";var i=L1(()=>{"use strict"});var Z=Be(ee=>{"use strict";i();Object.defineProperty(ee,"__esModule",{value:!0});ee.hasKey=ee.isError=ee.isVoid=ee.isBoolean=ee.isFunction=ee.isNonEmptyArray=ee.isEmptyArray=ee.isArray=ee.isNonEmptyRecord=ee.isEmptyRecord=ee.isRecord=ee.isInteger=ee.isNaN=ee.isNotNumber=ee.isNumber=ee.isNonEmptyString=ee.isEmptyString=ee.isNotString=ee.isString=ee.isNotNil=ee.isNil=ee.isNotUndefined=ee.isUndefined=ee.isNotNull=ee.isNull=void 0;var UO=e=>e===null;ee.isNull=UO;var KO=e=>!(0,ee.isNull)(e);ee.isNotNull=KO;var qO=e=>e===void 0;ee.isUndefined=qO;var XO=e=>!(0,ee.isUndefined)(e);ee.isNotUndefined=XO;var YO=e=>(0,ee.isNull)(e)||(0,ee.isUndefined)(e);ee.isNil=YO;var JO=e=>!(0,ee.isNil)(e);ee.isNotNil=JO;var ZO=e=>typeof e=="string";ee.isString=ZO;var QO=e=>!(0,ee.isString)(e);ee.isNotString=QO;var eM=e=>(0,ee.isString)(e)&&e==="";ee.isEmptyString=eM;var tM=e=>(0,ee.isString)(e)&&!(0,ee.isEmptyString)(e);ee.isNonEmptyString=tM;var rM=e=>typeof e=="number";ee.isNumber=rM;var nM=e=>!(0,ee.isNumber)(e);ee.isNotNumber=nM;var oM=e=>Number.isNaN(e);ee.isNaN=oM;var iM=e=>Number.isInteger(e);ee.isInteger=iM;var aM=e=>(0,ee.isNotNil)(e)&&typeof e=="object"&&!(e instanceof Array);ee.isRecord=aM;var sM=e=>(0,ee.isRecord)(e)&&Object.keys(e).length===0;ee.isEmptyRecord=sM;var uM=e=>(0,ee.isRecord)(e)&&Object.keys(e).length>0;ee.isNonEmptyRecord=uM;var lM=e=>(0,ee.isNotNil)(e)&&typeof e=="object"&&e instanceof Array;ee.isArray=lM;var cM=e=>(0,ee.isArray)(e)&&e.length===0;ee.isEmptyArray=cM;var fM=e=>(0,ee.isArray)(e)&&e.length>0;ee.isNonEmptyArray=fM;var pM=e=>(0,ee.isNotNil)(e)&&typeof e=="function";ee.isFunction=pM;var dM=e=>(0,ee.isNotNil)(e)&&typeof e=="boolean";ee.isBoolean=dM;var mM=e=>e===void 0;ee.isVoid=mM;var hM=e=>(0,ee.isNotNil)(e)&&e instanceof Error;ee.isError=hM;var gM=(e,t)=>(0,ee.isNonEmptyRecord)(e)&&t in e;ee.hasKey=gM});var G3=Be((spe,fm)=>{i();var H3=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||typeof msCrypto<"u"&&typeof window.msCrypto.getRandomValues=="function"&&msCrypto.getRandomValues.bind(msCrypto);H3?(lm=new Uint8Array(16),fm.exports=function(){return H3(lm),lm}):(cm=new Array(16),fm.exports=function(){for(var t=0,r;t<16;t++)t&3||(r=Math.random()*4294967296),cm[t]=r>>>((t&3)<<3)&255;return cm});var lm,cm});var W3=Be((lpe,_3)=>{i();var j3=[];for(Js=0;Js<256;++Js)j3[Js]=(Js+256).toString(16).substr(1);var Js;function TI(e,t){var r=t||0,n=j3;return[n[e[r++]],n[e[r++]],n[e[r++]],n[e[r++]],"-",n[e[r++]],n[e[r++]],"-",n[e[r++]],n[e[r++]],"-",n[e[r++]],n[e[r++]],"-",n[e[r++]],n[e[r++]],n[e[r++]],n[e[r++]],n[e[r++]],n[e[r++]]].join("")}_3.exports=TI});var K3=Be((fpe,U3)=>{i();var AI=G3(),RI=W3();function FI(e,t,r){var n=t&&r||0;typeof e=="string"&&(t=e==="binary"?new Array(16):null,e=null),e=e||{};var o=e.random||(e.rng||AI)();if(o[6]=o[6]&15|64,o[8]=o[8]&63|128,t)for(var a=0;a<16;++a)t[n+a]=o[a];return t||RI(o)}U3.exports=FI});function Sv(e){var t=Object.create(null);return function(r){return t[r]===void 0&&(t[r]=e(r)),t[r]}}var Dv=L1(()=>{i()});var Ev={};$1(Ev,{default:()=>hk});var mk,hk,Pv=L1(()=>{i();Dv();mk=/^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|abbr|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|disableRemotePlayback|download|draggable|encType|enterKeyHint|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/,hk=Sv(function(e){return mk.test(e)||e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)<91})});var Lx=Be((z$e,Vx)=>{"use strict";i();var kx=Array.isArray,Nx=Object.keys,Wj=Object.prototype.hasOwnProperty,Uj=typeof Element<"u";function G0(e,t){if(e===t)return!0;if(e&&t&&typeof e=="object"&&typeof t=="object"){var r=kx(e),n=kx(t),o,a,s;if(r&&n){if(a=e.length,a!=t.length)return!1;for(o=a;o--!==0;)if(!G0(e[o],t[o]))return!1;return!0}if(r!=n)return!1;var u=e instanceof Date,l=t instanceof Date;if(u!=l)return!1;if(u&&l)return e.getTime()==t.getTime();var c=e instanceof RegExp,p=t instanceof RegExp;if(c!=p)return!1;if(c&&p)return e.toString()==t.toString();var d=Nx(e);if(a=d.length,a!==Nx(t).length)return!1;for(o=a;o--!==0;)if(!Wj.call(t,d[o]))return!1;if(Uj&&e instanceof Element&&t instanceof Element)return e===t;for(o=a;o--!==0;)if(s=d[o],!(s==="_owner"&&e.$$typeof)&&!G0(e[s],t[s]))return!1;return!0}return e!==e&&t!==t}Vx.exports=function(t,r){try{return G0(t,r)}catch(n){if(n.message&&n.message.match(/stack|recursion/i)||n.number===-2146828260)return console.warn("Warning: react-fast-compare does not handle circular references.",n.name,n.message),!1;throw n}}});var Yx=Be(Te=>{"use strict";i();var ct=typeof Symbol=="function"&&Symbol.for,U0=ct?Symbol.for("react.element"):60103,K0=ct?Symbol.for("react.portal"):60106,qf=ct?Symbol.for("react.fragment"):60107,Xf=ct?Symbol.for("react.strict_mode"):60108,Yf=ct?Symbol.for("react.profiler"):60114,Jf=ct?Symbol.for("react.provider"):60109,Zf=ct?Symbol.for("react.context"):60110,q0=ct?Symbol.for("react.async_mode"):60111,Qf=ct?Symbol.for("react.concurrent_mode"):60111,ep=ct?Symbol.for("react.forward_ref"):60112,tp=ct?Symbol.for("react.suspense"):60113,f_=ct?Symbol.for("react.suspense_list"):60120,rp=ct?Symbol.for("react.memo"):60115,np=ct?Symbol.for("react.lazy"):60116,p_=ct?Symbol.for("react.block"):60121,d_=ct?Symbol.for("react.fundamental"):60117,m_=ct?Symbol.for("react.responder"):60118,h_=ct?Symbol.for("react.scope"):60119;function pr(e){if(typeof e=="object"&&e!==null){var t=e.$$typeof;switch(t){case U0:switch(e=e.type,e){case q0:case Qf:case qf:case Yf:case Xf:case tp:return e;default:switch(e=e&&e.$$typeof,e){case Zf:case ep:case np:case rp:case Jf:return e;default:return t}}case K0:return t}}}function Xx(e){return pr(e)===Qf}Te.AsyncMode=q0;Te.ConcurrentMode=Qf;Te.ContextConsumer=Zf;Te.ContextProvider=Jf;Te.Element=U0;Te.ForwardRef=ep;Te.Fragment=qf;Te.Lazy=np;Te.Memo=rp;Te.Portal=K0;Te.Profiler=Yf;Te.StrictMode=Xf;Te.Suspense=tp;Te.isAsyncMode=function(e){return Xx(e)||pr(e)===q0};Te.isConcurrentMode=Xx;Te.isContextConsumer=function(e){return pr(e)===Zf};Te.isContextProvider=function(e){return pr(e)===Jf};Te.isElement=function(e){return typeof e=="object"&&e!==null&&e.$$typeof===U0};Te.isForwardRef=function(e){return pr(e)===ep};Te.isFragment=function(e){return pr(e)===qf};Te.isLazy=function(e){return pr(e)===np};Te.isMemo=function(e){return pr(e)===rp};Te.isPortal=function(e){return pr(e)===K0};Te.isProfiler=function(e){return pr(e)===Yf};Te.isStrictMode=function(e){return pr(e)===Xf};Te.isSuspense=function(e){return pr(e)===tp};Te.isValidElementType=function(e){return typeof e=="string"||typeof e=="function"||e===qf||e===Qf||e===Yf||e===Xf||e===tp||e===f_||typeof e=="object"&&e!==null&&(e.$$typeof===np||e.$$typeof===rp||e.$$typeof===Jf||e.$$typeof===Zf||e.$$typeof===ep||e.$$typeof===d_||e.$$typeof===m_||e.$$typeof===h_||e.$$typeof===p_)};Te.typeOf=pr});var Zx=Be((Bze,Jx)=>{"use strict";i();Jx.exports=Yx()});var iw=Be((Mze,ow)=>{"use strict";i();var X0=Zx(),g_={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},v_={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},y_={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},rw={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},Y0={};Y0[X0.ForwardRef]=y_;Y0[X0.Memo]=rw;function Qx(e){return X0.isMemo(e)?rw:Y0[e.$$typeof]||g_}var b_=Object.defineProperty,C_=Object.getOwnPropertyNames,ew=Object.getOwnPropertySymbols,x_=Object.getOwnPropertyDescriptor,w_=Object.getPrototypeOf,tw=Object.prototype;function nw(e,t,r){if(typeof t!="string"){if(tw){var n=w_(t);n&&n!==tw&&nw(e,n,r)}var o=C_(t);ew&&(o=o.concat(ew(t)));for(var a=Qx(e),s=Qx(t),u=0;u<o.length;++u){var l=o[u];if(!v_[l]&&!(r&&r[l])&&!(s&&s[l])&&!(a&&a[l])){var c=x_(t,l);try{b_(e,l,c)}catch{}}}}return e}ow.exports=nw});var up=Be((rGe,mw)=>{i();var iW=typeof Element<"u",aW=typeof Map=="function",sW=typeof Set=="function",uW=typeof ArrayBuffer=="function"&&!!ArrayBuffer.isView;function sp(e,t){if(e===t)return!0;if(e&&t&&typeof e=="object"&&typeof t=="object"){if(e.constructor!==t.constructor)return!1;var r,n,o;if(Array.isArray(e)){if(r=e.length,r!=t.length)return!1;for(n=r;n--!==0;)if(!sp(e[n],t[n]))return!1;return!0}var a;if(aW&&e instanceof Map&&t instanceof Map){if(e.size!==t.size)return!1;for(a=e.entries();!(n=a.next()).done;)if(!t.has(n.value[0]))return!1;for(a=e.entries();!(n=a.next()).done;)if(!sp(n.value[1],t.get(n.value[0])))return!1;return!0}if(sW&&e instanceof Set&&t instanceof Set){if(e.size!==t.size)return!1;for(a=e.entries();!(n=a.next()).done;)if(!t.has(n.value[0]))return!1;return!0}if(uW&&ArrayBuffer.isView(e)&&ArrayBuffer.isView(t)){if(r=e.length,r!=t.length)return!1;for(n=r;n--!==0;)if(e[n]!==t[n])return!1;return!0}if(e.constructor===RegExp)return e.source===t.source&&e.flags===t.flags;if(e.valueOf!==Object.prototype.valueOf&&typeof e.valueOf=="function"&&typeof t.valueOf=="function")return e.valueOf()===t.valueOf();if(e.toString!==Object.prototype.toString&&typeof e.toString=="function"&&typeof t.toString=="function")return e.toString()===t.toString();if(o=Object.keys(e),r=o.length,r!==Object.keys(t).length)return!1;for(n=r;n--!==0;)if(!Object.prototype.hasOwnProperty.call(t,o[n]))return!1;if(iW&&e instanceof Element)return!1;for(n=r;n--!==0;)if(!((o[n]==="_owner"||o[n]==="__v"||o[n]==="__o")&&e.$$typeof)&&!sp(e[o[n]],t[o[n]]))return!1;return!0}return e!==e&&t!==t}mw.exports=function(t,r){try{return sp(t,r)}catch(n){if((n.message||"").match(/stack|recursion/i))return console.warn("react-fast-compare cannot handle circular refs"),!1;throw n}}});var fD=Be((gJe,cD)=>{"use strict";i();cD.exports=UX;var uD="\u0591-\u07FF\uFB1D-\uFDFD\uFE70-\uFEFC",lD="A-Za-z\xC0-\xD6\xD8-\xF6\xF8-\u02B8\u0300-\u0590\u0800-\u1FFF\u200E\u2C00-\uFB1C\uFE00-\uFE6F\uFEFD-\uFFFF",_X=new RegExp("^[^"+lD+"]*["+uD+"]"),WX=new RegExp("^[^"+uD+"]*["+lD+"]");function UX(e){return e=String(e||""),_X.test(e)?"rtl":WX.test(e)?"ltr":"neutral"}});var qp=Be((yJe,pD)=>{i();function KX(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}pD.exports=KX});var mD=Be((CJe,dD)=>{i();var qX=typeof window=="object"&&window&&window.Object===Object&&window;dD.exports=qX});var Kh=Be((wJe,hD)=>{i();var XX=mD(),YX=typeof self=="object"&&self&&self.Object===Object&&self,JX=XX||YX||Function("return this")();hD.exports=JX});var vD=Be((DJe,gD)=>{i();var ZX=Kh(),QX=function(){return ZX.Date.now()};gD.exports=QX});var bD=Be((PJe,yD)=>{i();var eY=/\s/;function tY(e){for(var t=e.length;t--&&eY.test(e.charAt(t)););return t}yD.exports=tY});var xD=Be((AJe,CD)=>{i();var rY=bD(),nY=/^\s+/;function oY(e){return e&&e.slice(0,rY(e)+1).replace(nY,"")}CD.exports=oY});var qh=Be((FJe,wD)=>{i();var iY=Kh(),aY=iY.Symbol;wD.exports=aY});var PD=Be((OJe,ED)=>{i();var SD=qh(),DD=Object.prototype,sY=DD.hasOwnProperty,uY=DD.toString,ju=SD?SD.toStringTag:void 0;function lY(e){var t=sY.call(e,ju),r=e[ju];try{e[ju]=void 0;var n=!0}catch{}var o=uY.call(e);return n&&(t?e[ju]=r:delete e[ju]),o}ED.exports=lY});var AD=Be((IJe,TD)=>{i();var cY=Object.prototype,fY=cY.toString;function pY(e){return fY.call(e)}TD.exports=pY});var OD=Be((NJe,BD)=>{i();var RD=qh(),dY=PD(),mY=AD(),hY="[object Null]",gY="[object Undefined]",FD=RD?RD.toStringTag:void 0;function vY(e){return e==null?e===void 0?gY:hY:FD&&FD in Object(e)?dY(e):mY(e)}BD.exports=vY});var ID=Be((LJe,MD)=>{i();function yY(e){return e!=null&&typeof e=="object"}MD.exports=yY});var ND=Be((zJe,kD)=>{i();var bY=OD(),CY=ID(),xY="[object Symbol]";function wY(e){return typeof e=="symbol"||CY(e)&&bY(e)==xY}kD.exports=wY});var zD=Be((GJe,$D)=>{i();var SY=xD(),VD=qp(),DY=ND(),LD=NaN,EY=/^[-+]0x[0-9a-f]+$/i,PY=/^0b[01]+$/i,TY=/^0o[0-7]+$/i,AY=parseInt;function RY(e){if(typeof e=="number")return e;if(DY(e))return LD;if(VD(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=VD(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=SY(e);var r=PY.test(e);return r||TY.test(e)?AY(e.slice(2),r?2:8):EY.test(e)?LD:+e}$D.exports=RY});var Yh=Be((_Je,GD)=>{i();var FY=qp(),Xh=vD(),HD=zD(),BY="Expected a function",OY=Math.max,MY=Math.min;function IY(e,t,r){var n,o,a,s,u,l,c=0,p=!1,d=!1,h=!0;if(typeof e!="function")throw new TypeError(BY);t=HD(t)||0,FY(r)&&(p=!!r.leading,d="maxWait"in r,a=d?OY(HD(r.maxWait)||0,t):a,h="trailing"in r?!!r.trailing:h);function g(D){var P=n,R=o;return n=o=void 0,c=D,s=e.apply(R,P),s}function v(D){return c=D,u=setTimeout(y,t),p?g(D):s}function m(D){var P=D-l,R=D-c,F=t-P;return d?MY(F,a-R):F}function b(D){var P=D-l,R=D-c;return l===void 0||P>=t||P<0||d&&R>=a}function y(){var D=Xh();if(b(D))return x(D);u=setTimeout(y,m(D))}function x(D){return u=void 0,h&&n?g(D):(n=o=void 0,s)}function w(){u!==void 0&&clearTimeout(u),c=0,n=l=o=u=void 0}function S(){return u===void 0?s:x(Xh())}function E(){var D=Xh(),P=b(D);if(n=arguments,o=this,l=D,P){if(u===void 0)return v(l);if(d)return clearTimeout(u),u=setTimeout(y,t),g(l)}return u===void 0&&(u=setTimeout(y,t)),s}return E.cancel=w,E.flush=S,E}GD.exports=IY});var _D=Be((UJe,jD)=>{i();var kY=Yh(),NY=qp(),VY="Expected a function";function LY(e,t,r){var n=!0,o=!0;if(typeof e!="function")throw new TypeError(VY);return NY(r)&&(n="leading"in r?!!r.leading:n,o="trailing"in r?!!r.trailing:o),kY(e,t,{leading:n,maxWait:t,trailing:o})}jD.exports=LY});var sP=Be(sn=>{"use strict";i();Object.defineProperty(sn,"__esModule",{value:!0});var wQ=typeof window<"u"&&/Mac|iPod|iPhone|iPad/.test(window.navigator.platform),F2={alt:"altKey",control:"ctrlKey",meta:"metaKey",shift:"shiftKey"},SQ={add:"+",break:"pause",cmd:"meta",command:"meta",ctl:"control",ctrl:"control",del:"delete",down:"arrowdown",esc:"escape",ins:"insert",left:"arrowleft",mod:wQ?"meta":"control",opt:"alt",option:"alt",return:"enter",right:"arrowright",space:" ",spacebar:" ",up:"arrowup",win:"meta",windows:"meta"},nP={backspace:8,tab:9,enter:13,shift:16,control:17,alt:18,pause:19,capslock:20,escape:27," ":32,pageup:33,pagedown:34,end:35,home:36,arrowleft:37,arrowup:38,arrowright:39,arrowdown:40,insert:45,delete:46,meta:91,numlock:144,scrolllock:145,";":186,"=":187,",":188,"-":189,".":190,"/":191,"`":192,"[":219,"\\":220,"]":221,"'":222};for(Ju=1;Ju<20;Ju++)nP["f"+Ju]=111+Ju;var Ju;function fd(e,t,r){t&&!("byKey"in t)&&(r=t,t=null),Array.isArray(e)||(e=[e]);var n=e.map(function(s){return oP(s,t)}),o=function(u){return n.some(function(l){return iP(l,u)})},a=r==null?o:o(r);return a}function DQ(e,t){return fd(e,t)}function EQ(e,t){return fd(e,{byKey:!0},t)}function oP(e,t){var r=t&&t.byKey,n={};e=e.replace("++","+add");var o=e.split("+"),a=o.length;for(var s in F2)n[F2[s]]=!1;var u=!0,l=!1,c=void 0;try{for(var p=o[Symbol.iterator](),d;!(u=(d=p.next()).done);u=!0){var h=d.value,g=h.endsWith("?")&&h.length>1;g&&(h=h.slice(0,-1));var v=B2(h),m=F2[v];(a===1||!m)&&(r?n.key=v:n.which=aP(h)),m&&(n[m]=g?null:!0)}}catch(b){l=!0,c=b}finally{try{!u&&p.return&&p.return()}finally{if(l)throw c}}return n}function iP(e,t){for(var r in e){var n=e[r],o=void 0;if(n!=null&&(r==="key"&&t.key!=null?o=t.key.toLowerCase():r==="which"?o=n===91&&t.which===93?91:t.which:o=t[r],!(o==null&&n===!1)&&o!==n))return!1}return!0}function aP(e){e=B2(e);var t=nP[e]||e.toUpperCase().charCodeAt(0);return t}function B2(e){return e=e.toLowerCase(),e=SQ[e]||e,e}sn.default=fd;sn.isHotkey=fd;sn.isCodeHotkey=DQ;sn.isKeyHotkey=EQ;sn.parseHotkey=oP;sn.compareHotkey=iP;sn.toKeyCode=aP;sn.toKeyName=B2});var JP=Be(un=>{"use strict";i();Object.defineProperty(un,"__esModule",{value:!0});var Jee=typeof window<"u"&&/Mac|iPod|iPhone|iPad/.test(window.navigator.platform),X2={alt:"altKey",control:"ctrlKey",meta:"metaKey",shift:"shiftKey"},KP={add:"+",break:"pause",cmd:"meta",command:"meta",ctl:"control",ctrl:"control",del:"delete",down:"arrowdown",esc:"escape",ins:"insert",left:"arrowleft",mod:Jee?"meta":"control",opt:"alt",option:"alt",return:"enter",right:"arrowright",space:" ",spacebar:" ",up:"arrowup",win:"meta",windows:"meta"},Y2={backspace:8,tab:9,enter:13,shift:16,control:17,alt:18,pause:19,capslock:20,escape:27," ":32,pageup:33,pagedown:34,end:35,home:36,arrowleft:37,arrowup:38,arrowright:39,arrowdown:40,insert:45,delete:46,meta:91,numlock:144,scrolllock:145,";":186,"=":187,",":188,"-":189,".":190,"/":191,"`":192,"[":219,"\\":220,"]":221,"'":222};for(nl=1;nl<20;nl++)Y2["f"+nl]=111+nl;var nl;function wd(e,t,r){t&&!("byKey"in t)&&(r=t,t=null),Array.isArray(e)||(e=[e]);var n=e.map(function(s){return qP(s,t)}),o=function(u){return n.some(function(l){return XP(l,u)})},a=r==null?o:o(r);return a}function Zee(e,t){return wd(e,t)}function Qee(e,t){return wd(e,{byKey:!0},t)}function qP(e,t){var r=t&&t.byKey,n={};e=e.replace("++","+add");var o=e.split("+"),a=o.length;for(var s in X2)n[X2[s]]=!1;var u=!0,l=!1,c=void 0;try{for(var p=o[Symbol.iterator](),d;!(u=(d=p.next()).done);u=!0){var h=d.value,g=h.endsWith("?")&&h.length>1;g&&(h=h.slice(0,-1));var v=J2(h),m=X2[v];if(h.length>1&&!m&&!KP[h]&&!Y2[v])throw new TypeError('Unknown modifier: "'+h+'"');(a===1||!m)&&(r?n.key=v:n.which=YP(h)),m&&(n[m]=g?null:!0)}}catch(b){l=!0,c=b}finally{try{!u&&p.return&&p.return()}finally{if(l)throw c}}return n}function XP(e,t){for(var r in e){var n=e[r],o=void 0;if(n!=null&&(r==="key"&&t.key!=null?o=t.key.toLowerCase():r==="which"?o=n===91&&t.which===93?91:t.which:o=t[r],!(o==null&&n===!1)&&o!==n))return!1}return!0}function YP(e){e=J2(e);var t=Y2[e]||e.toUpperCase().charCodeAt(0);return t}function J2(e){return e=e.toLowerCase(),e=KP[e]||e,e}un.default=wd;un.isHotkey=wd;un.isCodeHotkey=Zee;un.isKeyHotkey=Qee;un.parseHotkey=qP;un.compareHotkey=XP;un.toKeyCode=YP;un.toKeyName=J2});i();i();i();var Vs=async e=>{if(navigator.clipboard)return navigator.clipboard.writeText(e).catch(a=>{throw a instanceof Error?a:new DOMException("The clipboard is not accessible","NotAllowedError")});let t=document.createElement("span");t.textContent=e,t.style.whiteSpace="pre",document.body.appendChild(t);let r=window.getSelection(),n=window.document.createRange();r?.removeAllRanges(),n.selectNode(t),r?.addRange(n);let o=!1;try{o=window.document.execCommand("copy")}catch(a){console.error("error",a)}return r?.removeAllRanges(),window.document.body.removeChild(t),o?Promise.resolve():Promise.reject(new DOMException("The request is not allowed","NotAllowedError"))};i();i();var o3=U(Z());i();i();function ae(e){let t=Object.prototype.toString.call(e);return e instanceof Date||typeof e=="object"&&t==="[object Date]"?new e.constructor(+e):typeof e=="number"||t==="[object Number]"||typeof e=="string"||t==="[object String]"?new Date(e):new Date(NaN)}i();function Jo(e,t){return e instanceof Date?new e.constructor(t):new Date(t)}function z1(e,t){let r=ae(e);return isNaN(t)?Jo(e,NaN):(t&&r.setDate(r.getDate()+t),r)}i();function Ls(e,t){let r=ae(e);if(isNaN(t))return Jo(e,NaN);if(!t)return r;let n=r.getDate(),o=Jo(e,r.getTime());o.setMonth(r.getMonth()+t+1,0);let a=o.getDate();return n>=a?o:(r.setFullYear(o.getFullYear(),o.getMonth(),n),r)}i();var vM=Math.pow(10,8)*24*60*60*1e3,lue=-vM;var K5=864e5;var yM=3600;var q5=yM*24,cue=q5*7,bM=q5*365.2425,CM=bM/12,fue=CM*3;i();i();function kr(e){let t=ae(e);return t.setHours(0,0,0,0),t}i();function H1(e){let t=ae(e),r=new Date(Date.UTC(t.getFullYear(),t.getMonth(),t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()));return r.setUTCFullYear(t.getFullYear()),+e-+r}function Vl(e,t){let r=kr(e),n=kr(t),o=+r-H1(r),a=+n-H1(n);return Math.round((o-a)/K5)}i();function G1(e,t){return Ls(e,t*12)}i();function Ll(e,t){let r=ae(e),n=ae(t),o=r.getTime()-n.getTime();return o<0?-1:o>0?1:o}i();function ar(e,t){let r=kr(e),n=kr(t);return+r==+n}i();i();function X5(e){return e instanceof Date||typeof e=="object"&&Object.prototype.toString.call(e)==="[object Date]"}function $s(e){if(!X5(e)&&typeof e!="number")return!1;let t=ae(e);return!isNaN(Number(t))}i();function J5(e,t){let r=ae(e),n=ae(t),o=Y5(r,n),a=Math.abs(Vl(r,n));r.setDate(r.getDate()-o*a);let s=+(Y5(r,n)===-o),u=o*(a-s);return u===0?0:u}function Y5(e,t){let r=e.getFullYear()-t.getFullYear()||e.getMonth()-t.getMonth()||e.getDate()-t.getDate()||e.getHours()-t.getHours()||e.getMinutes()-t.getMinutes()||e.getSeconds()-t.getSeconds()||e.getMilliseconds()-t.getMilliseconds();return r<0?-1:r>0?1:r}i();function Ji(e){let t=ae(e);return t.setHours(23,59,59,999),t}i();function j1(e){let t=ae(e),r=t.getMonth();return t.setFullYear(t.getFullYear(),r+1,0),t.setHours(23,59,59,999),t}i();function Z5(e,t){let r=ae(e.start),n=ae(e.end),o=+r>+n,a=o?+r:+n,s=o?n:r;s.setHours(0,0,0,0);let u=t?.step??1;if(!u)return[];u<0&&(u=-u,o=!o);let l=[];for(;+s<=a;)l.push(ae(s)),s.setDate(s.getDate()+u),s.setHours(0,0,0,0);return o?l.reverse():l}i();function _1(e,t){let r=ae(e.start),n=ae(e.end),o=+r>+n,a=o?+r:+n,s=o?n:r;s.setHours(0,0,0,0),s.setDate(1);let u=t?.step??1;if(!u)return[];u<0&&(u=-u,o=!o);let l=[];for(;+s<=a;)l.push(ae(s)),s.setMonth(s.getMonth()+u);return o?l.reverse():l}i();function zs(e){let t=ae(e);return t.setDate(1),t.setHours(0,0,0,0),t}i();function Q5(e){return ae(e).getDay()}i();function W1(e){let t=ae(e),r=t.getFullYear(),n=t.getMonth(),o=Jo(e,0);return o.setFullYear(r,n+1,0),o.setHours(0,0,0,0),o.getDate()}i();function U1(e){return ae(e).getFullYear()}i();function e3(e,t){let r=ae(e),n=ae(t);return r.getTime()>n.getTime()}i();function qr(e,t){let r=ae(e),n=ae(t);return+r<+n}i();function K1(e,t){let r=ae(e),n=ae(t);return+r==+n}i();function t3(e){return+ae(e)>Date.now()}i();function r3(e,t){let r=+ae(e),[n,o]=[+ae(t.start),+ae(t.end)].sort((a,s)=>a-s);return r>=n&&r<=o}var i3=1e3,q1=60,Gs=60,n3=30,br=["en-US"],yn=Intl.DateTimeFormat().resolvedOptions().timeZone||"UTC",Hs=e=>e.toString().padStart(2,"0"),Nr=e=>e instanceof Date,bn=e=>!Nr(e)||e.getTime()===0,a3=(e,{timeZone:t=yn}={})=>{if(!Nr(e)||bn(e))return"";try{return new Intl.DateTimeFormat(br,{dateStyle:"medium",timeZone:t}).format(e)}catch(r){return console.error(r),""}},s3=(e,{timeZone:t=yn}={})=>{if(!Nr(e)||bn(e))return"";try{return new Intl.DateTimeFormat(br,{year:"numeric",month:"2-digit",day:"2-digit",timeZone:t}).format(e)}catch(r){return console.error(r),""}},u3=(e,{timeZone:t=yn}={})=>{if(!Nr(e)||bn(e))return"";try{let o=new Intl.DateTimeFormat(br,{year:"numeric",month:"2-digit",day:"2-digit",timeZone:t}).formatToParts(e).reduce((a,s)=>(a[s.type]=s.value,a),{});return`${o.year}-${o.month}-${o.day}`}catch(r){return console.error(r),""}},l3=(e,{timeZone:t=yn}={})=>{if(!Nr(e)||bn(e))return"";try{return new Intl.DateTimeFormat(br,{month:"2-digit",day:"2-digit",timeZone:t}).format(e)}catch(r){return console.error(r),""}},c3=(e,{timeZone:t=yn}={})=>{if(e===null)return"";try{return new Intl.DateTimeFormat(br,{weekday:"long",timeZone:t}).format(e)}catch(r){return console.error(r),""}},f3=(e,{timeZone:t=yn}={})=>{if(!Nr(e)||bn(e))return"";try{return new Intl.DateTimeFormat(br,{timeStyle:"short",timeZone:t}).format(e)}catch(r){return console.error(r),""}},$l=(e,{timeZone:t=yn}={})=>{if((0,o3.isNil)(e))return"";let r=new Date(e);if(bn(r))return"";try{return new Intl.DateTimeFormat(br,{dateStyle:"medium",timeStyle:"short",timeZone:t}).format(r)}catch(n){return console.error(n),""}},p3=(e,{timeZone:t=yn}={})=>{if(!Nr(e)||bn(e))return"";try{let{year:r,month:n,day:o,hour:a,minute:s,dayPeriod:u}=new Intl.DateTimeFormat(br,{month:"long",day:"numeric",year:"numeric",hour:"numeric",minute:"2-digit",timeZone:t}).formatToParts(e).reduce((l,c)=>(c.type!=="literal"&&(l[c.type]=c.value),l),{});return`${n} ${o}, ${r}, ${a}:${s} ${u}`}catch(r){return console.error(r),""}},d3=(e,{timeZone:t=yn}={})=>{if(!Nr(e)||bn(e))return"";try{return new Intl.DateTimeFormat(br,{dateStyle:"long",timeZone:t}).format(e)}catch(r){return console.error(r),""}},m3=(e,{nowAnchor:t=new Date}={})=>{if(bn(e))return"";let r=(t.valueOf()-e.valueOf())/(q1*i3),n=Math.round(r),o=Vl(t,e);return r<0?$l(e):r<1?"< 1 minute ago":n<2?"1 minute ago":n<=Gs?`${n} minutes ago`:o===0?`Today, ${Intl.DateTimeFormat(br,{timeStyle:"short"}).format(e)}`:o===1?`Yesterday, ${Intl.DateTimeFormat(br,{timeStyle:"short"}).format(e)}`:e.getFullYear()===t.getFullYear()?Intl.DateTimeFormat(br,{day:"numeric",month:"short",hour:"numeric",minute:"2-digit"}).format(e):$l(e)},h3=e=>{let t=e.getTimezoneOffset()/Gs*-1,r=Math.round(t),n=(t-r)*Gs,o=r>=0?"+":"",a=`${r}`.padStart(2,"0"),s=`${n}`.padStart(2,"0");return`${o}${a}:${s}`},js=e=>{let t=Math.floor(e/i3),r=Math.floor(t/q1),n=Math.floor(r/Gs),o=t-r*q1,a=r-n*Gs;return{seconds:o,minutes:a,hours:n}},g3=e=>{let{hours:t,minutes:r,seconds:n}=js(e);return t<1?`${r}:${Hs(n)}`:`${t}:${Hs(r)}:${Hs(n)}`},v3=e=>{let{hours:t,minutes:r,seconds:n}=js(e);return`${t}:${Hs(r)}:${Hs(n)}`},X1=e=>Nr(e)?{year:e.getFullYear(),month:e.getMonth(),dayOfMonth:e.getDate(),hours:e.getHours(),minutes:e.getMinutes()}:null,zl=e=>{let{year:t,month:r,dayOfMonth:n,hours:o,minutes:a}=e??{};return t!==void 0&&r!==void 0&&n!==void 0?new Date(t,r,n,o??0,a??0):null},Y1=e=>zl(e)?.toISOString()??null,y3=(e,t=!0)=>{let r=e.getMinutes()<=n3,n=r?e.getHours():e.getHours()+1,o=r?n3:0,a={...X1(e),hours:n,minutes:o};return t?Y1(a):zl(a)},b3=e=>{let{seconds:t,minutes:r,hours:n}=js(e),o="PT";return n&&(o+=`${n}H`),r&&(o+=`${r}M`),t&&(o+=`${t}S`),t||r||n||(o+="0S"),o};var Ile={isDate:Nr,dateOnlyString:a3,dateOnlyStringNumeric:s3,dateOnlyISOString:u3,monthDayStringNumeric:l3,dayOfWeekString:c3,timeOnlyString:f3,dateTimeString:$l,dateTimeStringForSentence:p3,dateOnlyStringForSentence:d3,timeAgoString:m3,dateUTCOffset:h3,buildTimeDuration:js,mediaDurationString:g3,sessionDurationString:v3,dateToDateTime:X1,dateTimeToDate:zl,dateTimeToISO:Y1,dateTimeRounded:y3,millisecondsToDurationISOString:b3};i();i();var C3=U(Z());import{css as Dt}from"styled-components";var J1={defaultDarkOne:Dt`
11
11
  background-color: #222d66;
12
12
  background-image: radial-gradient(farthest-corner at top right, #222d66, transparent 70%),
13
13
  radial-gradient(farthest-corner at bottom right, #2949e5, transparent 50%),
@@ -97,7 +97,7 @@ var zO=Object.create;var Nl=Object.defineProperty;var HO=Object.getOwnPropertyDe
97
97
  radial-gradient(farthest-corner at top right, #bcbf19, transparent 70%),
98
98
  radial-gradient(farthest-corner at top left, #e8ec1e, transparent 65%),
99
99
  radial-gradient(farthest-corner at bottom right, #2949e5, transparent 55%);
100
- `},Hl=Object.keys(J1),Cr=(e=void 0)=>(0,C3.isNotNil)(e)?J1[e]:J1.defaultDarkOne;i();var xM=31,_le=e=>{let t=null;if(typeof e=="string"&&e)t=Array.from(e).reduce((n,o)=>Math.imul(xM,n)+o.charCodeAt(0)||0,0);else return Hl[0];let r=Math.abs(t)%Hl.length;return Hl[r]};i();i();i();i();function Et(){return Et=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Et.apply(this,arguments)}i();function Z1(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}i();i();function Cn(e,t){return Cn=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,o){return n.__proto__=o,n},Cn(e,t)}function Q1(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,Cn(e,t)}i();i();function _s(e){return _s=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},_s(e)}i();function em(e){try{return Function.toString.call(e).indexOf("[native code]")!==-1}catch{return typeof e=="function"}}i();i();function Gl(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(Gl=function(){return!!e})()}function tm(e,t,r){if(Gl())return Reflect.construct.apply(null,arguments);var n=[null];n.push.apply(n,t);var o=new(e.bind.apply(e,n));return r&&Cn(o,r.prototype),o}function Ws(e){var t=typeof Map=="function"?new Map:void 0;return Ws=function(n){if(n===null||!em(n))return n;if(typeof n!="function")throw new TypeError("Super expression must either be null or a function");if(typeof t<"u"){if(t.has(n))return t.get(n);t.set(n,o)}function o(){return tm(n,arguments,_s(this).constructor)}return o.prototype=Object.create(n.prototype,{constructor:{value:o,enumerable:!1,writable:!0,configurable:!0}}),Cn(o,n)},Ws(e)}i();var Gt=function(e){Q1(t,e);function t(r){var n;if(1)n=e.call(this,"An error occurred. See https://github.com/styled-components/polished/blob/main/src/internalHelpers/errors.md#"+r+" for more information.")||this;else for(var o,a,s;s<o;s++);return Z1(n)}return t}(Ws(Error));function x3(e,t){return e.substr(-t.length)===t}var wM=/^([+-]?(?:\d+|\d*\.\d+))([a-z]*|%)$/;function w3(e){if(typeof e!="string")return e;var t=e.match(wM);return t?parseFloat(e):e}var SM=function(t){return function(r,n){n===void 0&&(n="16px");var o=r,a=n;if(typeof r=="string"){if(!x3(r,"px"))throw new Gt(69,t,r);o=w3(r)}if(typeof n=="string"){if(!x3(n,"px"))throw new Gt(70,t,n);a=w3(n)}if(typeof o=="string")throw new Gt(71,r,t);if(typeof a=="string")throw new Gt(72,n,t);return""+o/a+t}},D3=SM,Pce=D3("em");var DM=/^([+-]?(?:\d+|\d*\.\d+))([a-z]*|%)$/;function E3(e){if(typeof e!="string")return[e,""];var t=e.match(DM);return t?[parseFloat(e),t[2]]:[e,void 0]}var Tce=D3("rem");function rm(e){return Math.round(e*255)}function EM(e,t,r){return rm(e)+","+rm(t)+","+rm(r)}function Us(e,t,r,n){if(n===void 0&&(n=EM),t===0)return n(r,r,r);var o=(e%360+360)%360/60,a=(1-Math.abs(2*r-1))*t,s=a*(1-Math.abs(o%2-1)),u=0,l=0,c=0;o>=0&&o<1?(u=a,l=s):o>=1&&o<2?(u=s,l=a):o>=2&&o<3?(l=a,c=s):o>=3&&o<4?(l=s,c=a):o>=4&&o<5?(u=s,c=a):o>=5&&o<6&&(u=a,c=s);var p=r-a/2,d=u+p,h=l+p,g=c+p;return n(d,h,g)}var S3={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"00ffff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"0000ff",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"00ffff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"ff00ff",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"639",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"};function PM(e){if(typeof e!="string")return e;var t=e.toLowerCase();return S3[t]?"#"+S3[t]:e}var TM=/^#[a-fA-F0-9]{6}$/,AM=/^#[a-fA-F0-9]{8}$/,RM=/^#[a-fA-F0-9]{3}$/,FM=/^#[a-fA-F0-9]{4}$/,nm=/^rgb\(\s*(\d{1,3})\s*(?:,)?\s*(\d{1,3})\s*(?:,)?\s*(\d{1,3})\s*\)$/i,BM=/^rgb(?:a)?\(\s*(\d{1,3})\s*(?:,)?\s*(\d{1,3})\s*(?:,)?\s*(\d{1,3})\s*(?:,|\/)\s*([-+]?\d*[.]?\d+[%]?)\s*\)$/i,OM=/^hsl\(\s*(\d{0,3}[.]?[0-9]+(?:deg)?)\s*(?:,)?\s*(\d{1,3}[.]?[0-9]?)%\s*(?:,)?\s*(\d{1,3}[.]?[0-9]?)%\s*\)$/i,MM=/^hsl(?:a)?\(\s*(\d{0,3}[.]?[0-9]+(?:deg)?)\s*(?:,)?\s*(\d{1,3}[.]?[0-9]?)%\s*(?:,)?\s*(\d{1,3}[.]?[0-9]?)%\s*(?:,|\/)\s*([-+]?\d*[.]?\d+[%]?)\s*\)$/i;function Zi(e){if(typeof e!="string")throw new Gt(3);var t=PM(e);if(t.match(TM))return{red:parseInt(""+t[1]+t[2],16),green:parseInt(""+t[3]+t[4],16),blue:parseInt(""+t[5]+t[6],16)};if(t.match(AM)){var r=parseFloat((parseInt(""+t[7]+t[8],16)/255).toFixed(2));return{red:parseInt(""+t[1]+t[2],16),green:parseInt(""+t[3]+t[4],16),blue:parseInt(""+t[5]+t[6],16),alpha:r}}if(t.match(RM))return{red:parseInt(""+t[1]+t[1],16),green:parseInt(""+t[2]+t[2],16),blue:parseInt(""+t[3]+t[3],16)};if(t.match(FM)){var n=parseFloat((parseInt(""+t[4]+t[4],16)/255).toFixed(2));return{red:parseInt(""+t[1]+t[1],16),green:parseInt(""+t[2]+t[2],16),blue:parseInt(""+t[3]+t[3],16),alpha:n}}var o=nm.exec(t);if(o)return{red:parseInt(""+o[1],10),green:parseInt(""+o[2],10),blue:parseInt(""+o[3],10)};var a=BM.exec(t.substring(0,50));if(a)return{red:parseInt(""+a[1],10),green:parseInt(""+a[2],10),blue:parseInt(""+a[3],10),alpha:parseFloat(""+a[4])>1?parseFloat(""+a[4])/100:parseFloat(""+a[4])};var s=OM.exec(t);if(s){var u=parseInt(""+s[1],10),l=parseInt(""+s[2],10)/100,c=parseInt(""+s[3],10)/100,p="rgb("+Us(u,l,c)+")",d=nm.exec(p);if(!d)throw new Gt(4,t,p);return{red:parseInt(""+d[1],10),green:parseInt(""+d[2],10),blue:parseInt(""+d[3],10)}}var h=MM.exec(t.substring(0,50));if(h){var g=parseInt(""+h[1],10),v=parseInt(""+h[2],10)/100,m=parseInt(""+h[3],10)/100,b="rgb("+Us(g,v,m)+")",y=nm.exec(b);if(!y)throw new Gt(4,t,b);return{red:parseInt(""+y[1],10),green:parseInt(""+y[2],10),blue:parseInt(""+y[3],10),alpha:parseFloat(""+h[4])>1?parseFloat(""+h[4])/100:parseFloat(""+h[4])}}throw new Gt(5)}function IM(e){var t=e.red/255,r=e.green/255,n=e.blue/255,o=Math.max(t,r,n),a=Math.min(t,r,n),s=(o+a)/2;if(o===a)return e.alpha!==void 0?{hue:0,saturation:0,lightness:s,alpha:e.alpha}:{hue:0,saturation:0,lightness:s};var u,l=o-a,c=s>.5?l/(2-o-a):l/(o+a);switch(o){case t:u=(r-n)/l+(r<n?6:0);break;case r:u=(n-t)/l+2;break;default:u=(t-r)/l+4;break}return u*=60,e.alpha!==void 0?{hue:u,saturation:c,lightness:s,alpha:e.alpha}:{hue:u,saturation:c,lightness:s}}function to(e){return IM(Zi(e))}var kM=function(t){return t.length===7&&t[1]===t[2]&&t[3]===t[4]&&t[5]===t[6]?"#"+t[1]+t[3]+t[5]:t},im=kM;function Zo(e){var t=e.toString(16);return t.length===1?"0"+t:t}function om(e){return Zo(Math.round(e*255))}function NM(e,t,r){return im("#"+om(e)+om(t)+om(r))}function jl(e,t,r){return Us(e,t,r,NM)}function VM(e,t,r){if(typeof e=="number"&&typeof t=="number"&&typeof r=="number")return jl(e,t,r);if(typeof e=="object"&&t===void 0&&r===void 0)return jl(e.hue,e.saturation,e.lightness);throw new Gt(1)}function LM(e,t,r,n){if(typeof e=="number"&&typeof t=="number"&&typeof r=="number"&&typeof n=="number")return n>=1?jl(e,t,r):"rgba("+Us(e,t,r)+","+n+")";if(typeof e=="object"&&t===void 0&&r===void 0&&n===void 0)return e.alpha>=1?jl(e.hue,e.saturation,e.lightness):"rgba("+Us(e.hue,e.saturation,e.lightness)+","+e.alpha+")";throw new Gt(2)}function am(e,t,r){if(typeof e=="number"&&typeof t=="number"&&typeof r=="number")return im("#"+Zo(e)+Zo(t)+Zo(r));if(typeof e=="object"&&t===void 0&&r===void 0)return im("#"+Zo(e.red)+Zo(e.green)+Zo(e.blue));throw new Gt(6)}function _l(e,t,r,n){if(typeof e=="string"&&typeof t=="number"){var o=Zi(e);return"rgba("+o.red+","+o.green+","+o.blue+","+t+")"}else{if(typeof e=="number"&&typeof t=="number"&&typeof r=="number"&&typeof n=="number")return n>=1?am(e,t,r):"rgba("+e+","+t+","+r+","+n+")";if(typeof e=="object"&&t===void 0&&r===void 0&&n===void 0)return e.alpha>=1?am(e.red,e.green,e.blue):"rgba("+e.red+","+e.green+","+e.blue+","+e.alpha+")"}throw new Gt(7)}var $M=function(t){return typeof t.red=="number"&&typeof t.green=="number"&&typeof t.blue=="number"&&(typeof t.alpha!="number"||typeof t.alpha>"u")},zM=function(t){return typeof t.red=="number"&&typeof t.green=="number"&&typeof t.blue=="number"&&typeof t.alpha=="number"},HM=function(t){return typeof t.hue=="number"&&typeof t.saturation=="number"&&typeof t.lightness=="number"&&(typeof t.alpha!="number"||typeof t.alpha>"u")},GM=function(t){return typeof t.hue=="number"&&typeof t.saturation=="number"&&typeof t.lightness=="number"&&typeof t.alpha=="number"};function ro(e){if(typeof e!="object")throw new Gt(8);if(zM(e))return _l(e);if($M(e))return am(e);if(GM(e))return LM(e);if(HM(e))return VM(e);throw new Gt(8)}function P3(e,t,r){return function(){var o=r.concat(Array.prototype.slice.call(arguments));return o.length>=t?e.apply(this,o):P3(e,t,o)}}function sr(e){return P3(e,e.length,[])}function jM(e,t){if(t==="transparent")return t;var r=to(t);return ro(Et({},r,{hue:r.hue+parseFloat(e)}))}var Ace=sr(jM);function Qi(e,t,r){return Math.max(e,Math.min(t,r))}function _M(e,t){if(t==="transparent")return t;var r=to(t);return ro(Et({},r,{lightness:Qi(0,1,r.lightness-parseFloat(e))}))}var WM=sr(_M),ot=WM;function UM(e,t){if(t==="transparent")return t;var r=to(t);return ro(Et({},r,{saturation:Qi(0,1,r.saturation-parseFloat(e))}))}var Rce=sr(UM);function KM(e,t){if(t==="transparent")return t;var r=to(t);return ro(Et({},r,{lightness:Qi(0,1,r.lightness+parseFloat(e))}))}var Fce=sr(KM);function qM(e,t,r){if(t==="transparent")return r;if(r==="transparent")return t;if(e===0)return r;var n=Zi(t),o=Et({},n,{alpha:typeof n.alpha=="number"?n.alpha:1}),a=Zi(r),s=Et({},a,{alpha:typeof a.alpha=="number"?a.alpha:1}),u=o.alpha-s.alpha,l=parseFloat(e)*2-1,c=l*u===-1?l:l+u,p=1+l*u,d=(c/p+1)/2,h=1-d,g={red:Math.floor(o.red*d+s.red*h),green:Math.floor(o.green*d+s.green*h),blue:Math.floor(o.blue*d+s.blue*h),alpha:o.alpha*parseFloat(e)+s.alpha*(1-parseFloat(e))};return _l(g)}var XM=sr(qM),T3=XM;function YM(e,t){if(t==="transparent")return t;var r=Zi(t),n=typeof r.alpha=="number"?r.alpha:1,o=Et({},r,{alpha:Qi(0,1,(n*100+parseFloat(e)*100)/100)});return _l(o)}var Bce=sr(YM);function JM(e,t){if(t==="transparent")return t;var r=to(t);return ro(Et({},r,{saturation:Qi(0,1,r.saturation+parseFloat(e))}))}var Oce=sr(JM);function ZM(e,t){return t==="transparent"?t:ro(Et({},to(t),{hue:parseFloat(e)}))}var Mce=sr(ZM);function QM(e,t){return t==="transparent"?t:ro(Et({},to(t),{lightness:parseFloat(e)}))}var Ice=sr(QM);function eI(e,t){return t==="transparent"?t:ro(Et({},to(t),{saturation:parseFloat(e)}))}var kce=sr(eI);function tI(e,t){return t==="transparent"?t:T3(parseFloat(e),"rgb(0, 0, 0)",t)}var Nce=sr(tI);function rI(e,t){return t==="transparent"?t:T3(parseFloat(e),"rgb(255, 255, 255)",t)}var Vce=sr(rI);function nI(e,t){if(t==="transparent")return t;var r=Zi(t),n=typeof r.alpha=="number"?r.alpha:1,o=Et({},r,{alpha:Qi(0,1,+(n*100-parseFloat(e)*100).toFixed(2)/100)});return _l(o)}var oI=sr(nI),jt=oI;var Ks=e=>{let[r,n]=E3(e);return`@media (max-width: ${Math.max(r-.0025,0)}${n})`},iI=({theme:e})=>`@media (min-width: ${e.breakpoint.xs})`,aI=({theme:e})=>`@media (min-width: ${e.breakpoint.sm})`,sI=({theme:e})=>`@media (min-width: ${e.breakpoint.md})`,uI=({theme:e})=>`@media (min-width: ${e.breakpoint.lg})`,lI=({theme:e})=>`@media (min-width: ${e.breakpoint.xl})`,cI=({theme:e})=>Ks(e.breakpoint.xs),fI=({theme:e})=>Ks(e.breakpoint.sm),pI=({theme:e})=>Ks(e.breakpoint.md),dI=({theme:e})=>Ks(e.breakpoint.lg),mI=({theme:e})=>Ks(e.breakpoint.xl),Ne={xsAndUp:iI,smAndUp:aI,mdAndUp:sI,lgAndUp:uI,xlAndUp:lI,xsAndDown:cI,smAndDown:fI,mdAndDown:pI,lgAndDown:dI,xlAndDown:mI};i();i();var xn=e=>e!=null&&(Object.getPrototypeOf(e)===null||e.constructor===Object);i();var sm=e=>(Object.freeze(e),Object.getOwnPropertyNames(e).forEach(t=>{Object.prototype.hasOwnProperty.call(e,t)&&(typeof e!="function"||t!=="caller"&&t!=="callee"&&t!=="arguments")&&e[t]!==null&&(typeof e[t]=="object"||typeof e[t]=="function")&&!Object.isFrozen(e[t])&&sm(e[t])}),e);i();var qs=(e,...t)=>{if(!t.length)return e;let r={...e};return t.forEach(n=>{xn(n)&&Object.keys(n).forEach(o=>{xn(n[o])?r[o]===null||r[o]===void 0?r[o]={...n[o]}:r[o]=qs(r[o],n[o]):r[o]=n[o]})}),r};i();var Wl=(e,t)=>t.reduce((r,n)=>(Object.prototype.hasOwnProperty.call(e,n)&&(r[n]=e[n]),r),{});var ife={isObject:xn,deepFreeze:sm,merge:qs,selectKeys:Wl};i();i();var A3=(e="")=>e.replace(/(?:^\w|[A-Z]|\b\w|\s+)/g,(t,r)=>+t==0?"":r===0?t.toLowerCase():t.toUpperCase());i();var wn=e=>e==="true"||e==="false"?e==="true":!!e;i();var ur=e=>e==null?"":String(e);i();i();var ea=e=>typeof e=="string"||e instanceof String;var R3=e=>{if(!ea(e))return!1;try{let t=new URL(e);return t.protocol==="http:"||t.protocol==="https:"}catch{return!1}};i();var no=e=>{let t=/^(?:\w+:)?\/\/(\S+)$/,r=/^localhost[:?\d]*(?:[^:?\d]\S*)?$/,n=/^[^\s.]+\.\S{2,}$/;if(!ea(e))return!1;let o=t.exec(e);if(!o)return!1;let a=o[1];return a===void 0||!a?!1:r.test(a)||n.test(a)};i();var F3=(e="")=>(e[0]?.toLowerCase()??"")+e.slice(1);i();var B3=e=>e.replace(/\n/g,"");i();var O3=e=>(e||"").replace(/\.[^/.]{1,4}$/,"");i();var M3=(e,t)=>e.length<=t?e:`${e.slice(0,t-3)}...`;i();var I3=(e="")=>(e[0]?.toUpperCase()??"")+e.slice(1);var jfe={camelCase:A3,coerceToBoolean:wn,coerceToString:ur,isHttpUrl:R3,isString:ea,isUrl:no,lowerFirst:F3,removeNewlines:B3,stripExtension:O3,truncate:M3,upperFirst:I3};i();i();i();import z3,{Component as EI}from"react";i();import Ys,{Component as bI}from"react";i();import hI from"react";var gI={border:0,clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",whiteSpace:"nowrap",padding:0,width:"1px",position:"absolute"},k3=function(t){var r=t.message,n=t["aria-live"];return hI.createElement("div",{style:gI,role:"log","aria-live":n},r||"")};k3.propTypes={};var Xs=k3;function vI(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function N3(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t&&(typeof t=="object"||typeof t=="function")?t:e}function yI(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var V3=function(e){yI(t,e);function t(){var r,n,o;vI(this,t);for(var a=arguments.length,s=Array(a),u=0;u<a;u++)s[u]=arguments[u];return o=(r=(n=N3(this,e.call.apply(e,[this].concat(s))),n),n.state={assertiveMessage1:"",assertiveMessage2:"",politeMessage1:"",politeMessage2:"",oldPolitemessage:"",oldPoliteMessageId:"",oldAssertiveMessage:"",oldAssertiveMessageId:"",setAlternatePolite:!1,setAlternateAssertive:!1},r),N3(n,o)}return t.getDerivedStateFromProps=function(n,o){var a=o.oldPolitemessage,s=o.oldPoliteMessageId,u=o.oldAssertiveMessage,l=o.oldAssertiveMessageId,c=n.politeMessage,p=n.politeMessageId,d=n.assertiveMessage,h=n.assertiveMessageId;return a!==c||s!==p?{politeMessage1:o.setAlternatePolite?"":c,politeMessage2:o.setAlternatePolite?c:"",oldPolitemessage:c,oldPoliteMessageId:p,setAlternatePolite:!o.setAlternatePolite}:u!==d||l!==h?{assertiveMessage1:o.setAlternateAssertive?"":d,assertiveMessage2:o.setAlternateAssertive?d:"",oldAssertiveMessage:d,oldAssertiveMessageId:h,setAlternateAssertive:!o.setAlternateAssertive}:null},t.prototype.render=function(){var n=this.state,o=n.assertiveMessage1,a=n.assertiveMessage2,s=n.politeMessage1,u=n.politeMessage2;return Ys.createElement("div",null,Ys.createElement(Xs,{"aria-live":"assertive",message:o}),Ys.createElement(Xs,{"aria-live":"assertive",message:a}),Ys.createElement(Xs,{"aria-live":"polite",message:s}),Ys.createElement(Xs,{"aria-live":"polite",message:u}))},t}(bI);V3.propTypes={};var L3=V3;i();import CI from"react";var xI=CI.createContext({announceAssertive:$3,announcePolite:$3});function $3(){console.warn("Announcement failed, LiveAnnouncer context is missing")}var ta=xI;function wI(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function SI(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t&&(typeof t=="object"||typeof t=="function")?t:e}function DI(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var PI=function(e){DI(t,e);function t(r){wI(this,t);var n=SI(this,e.call(this,r));return n.announcePolite=function(o,a){n.setState({announcePoliteMessage:o,politeMessageId:a||""})},n.announceAssertive=function(o,a){n.setState({announceAssertiveMessage:o,assertiveMessageId:a||""})},n.state={announcePoliteMessage:"",politeMessageId:"",announceAssertiveMessage:"",assertiveMessageId:"",updateFunctions:{announcePolite:n.announcePolite,announceAssertive:n.announceAssertive}},n}return t.prototype.render=function(){var n=this.state,o=n.announcePoliteMessage,a=n.politeMessageId,s=n.announceAssertiveMessage,u=n.assertiveMessageId,l=n.updateFunctions;return z3.createElement(ta.Provider,{value:l},this.props.children,z3.createElement(L3,{assertiveMessage:s,assertiveMessageId:u,politeMessage:o,politeMessageId:a}))},t}(EI),um=PI;i();import J3 from"react";i();var pm=U(K3());import{Component as MI}from"react";function BI(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function q3(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t&&(typeof t=="object"||typeof t=="function")?t:e}function OI(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var X3=function(e){OI(t,e);function t(){var r,n,o;BI(this,t);for(var a=arguments.length,s=Array(a),u=0;u<a;u++)s[u]=arguments[u];return o=(r=(n=q3(this,e.call.apply(e,[this].concat(s))),n),n.announce=function(){var l=n.props,c=l.message,p=l["aria-live"],d=l.announceAssertive,h=l.announcePolite;p==="assertive"&&d(c||"",(0,pm.default)()),p==="polite"&&h(c||"",(0,pm.default)())},r),q3(n,o)}return t.prototype.componentDidMount=function(){this.announce()},t.prototype.componentDidUpdate=function(n){var o=this.props.message;o!==n.message&&this.announce()},t.prototype.componentWillUnmount=function(){var n=this.props,o=n.clearOnUnmount,a=n.announceAssertive,s=n.announcePolite;(o===!0||o==="true")&&(a(""),s(""))},t.prototype.render=function(){return null},t}(MI);X3.propTypes={};var Y3=X3;var II=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Z3=function(t){return J3.createElement(ta.Consumer,null,function(r){return J3.createElement(Y3,II({},r,t))})};Z3.propTypes={};var Zs=Z3;i();import kI from"react";var NI=function(t){var r=t.children;return kI.createElement(ta.Consumer,null,function(n){return r(n)})};NI.propTypes={};i();i();i();import{jsxs as ek,jsx as tk}from"react/jsx-runtime";import{forwardRef as rk,useContext as dm}from"react";i();import{createContext as VI}from"react";var ra=VI({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"});i();import{createContext as LI}from"react";var oo=LI({});i();import{useContext as Qs,useRef as ev,useInsertionEffect as UI,useEffect as KI}from"react";i();import{createContext as $I}from"react";var io=$I(null);i();import{useLayoutEffect as zI,useEffect as HI}from"react";i();var na=typeof window<"u";var Ul=na?zI:HI;i();import{createContext as GI}from"react";var Kl=GI({strict:!1});i();i();var ao=e=>e.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase();var jI="framerAppearId",ql="data-"+ao(jI);i();i();i();var Sn={skipAnimations:!1,useManualTiming:!1};i();function Q3(e){let t=new Set,r=new Set,n=!1,o=!1,a=new WeakSet,s={delta:0,timestamp:0,isProcessing:!1};function u(c){a.has(c)&&(l.schedule(c),e()),c(s)}let l={schedule:(c,p=!1,d=!1)=>{let g=d&&n?t:r;return p&&a.add(c),g.has(c)||g.add(c),c},cancel:c=>{r.delete(c),a.delete(c)},process:c=>{if(s=c,n){o=!0;return}n=!0,[t,r]=[r,t],r.clear(),t.forEach(u),n=!1,o&&(o=!1,l.process(c))}};return l}var Xl=["read","resolveKeyframes","update","preRender","render","postRender"],_I=40;function Yl(e,t){let r=!1,n=!0,o={delta:0,timestamp:0,isProcessing:!1},a=()=>r=!0,s=Xl.reduce((y,x)=>(y[x]=Q3(a),y),{}),{read:u,resolveKeyframes:l,update:c,preRender:p,render:d,postRender:h}=s,g=()=>{let y=Sn.useManualTiming?o.timestamp:performance.now();r=!1,o.delta=n?1e3/60:Math.max(Math.min(y-o.timestamp,_I),1),o.timestamp=y,o.isProcessing=!0,u.process(o),l.process(o),c.process(o),p.process(o),d.process(o),h.process(o),o.isProcessing=!1,r&&t&&(n=!1,e(g))},v=()=>{r=!0,n=!0,o.isProcessing||e(g)};return{schedule:Xl.reduce((y,x)=>{let w=s[x];return y[x]=(S,E=!1,D=!1)=>(r||v(),w.schedule(S,E,D)),y},{}),cancel:y=>{for(let x=0;x<Xl.length;x++)s[Xl[x]].cancel(y)},state:o,steps:s}}var{schedule:oa,cancel:lde}=Yl(queueMicrotask,!1);i();function Dn(e){return e&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}i();import{createContext as WI}from"react";var Jl=WI({});var tv=!1;function rv(e,t,r,n,o){let{visualElement:a}=Qs(oo),s=Qs(Kl),u=Qs(io),l=Qs(ra).reducedMotion,c=ev();n=n||s.renderer,!c.current&&n&&(c.current=n(e,{visualState:t,parent:a,props:r,presenceContext:u,blockInitialAnimation:u?u.initial===!1:!1,reducedMotionConfig:l}));let p=c.current,d=Qs(Jl);p&&!p.projection&&o&&(p.type==="html"||p.type==="svg")&&XI(c.current,r,o,d),UI(()=>{p&&p.update(r,u)});let h=ev(!!(r[ql]&&!window.HandoffComplete));return Ul(()=>{p&&(p.updateFeatures(),oa.render(p.render),h.current&&p.animationState&&p.animationState.animateChanges())}),KI(()=>{p&&(!h.current&&p.animationState&&p.animationState.animateChanges(),h.current&&(h.current=!1,tv||(tv=!0,queueMicrotask(qI))))}),p}function qI(){window.HandoffComplete=!0}function XI(e,t,r,n){let{layoutId:o,layout:a,drag:s,dragConstraints:u,layoutScroll:l,layoutRoot:c}=t;e.projection=new r(e.latestValues,t["data-framer-portal-id"]?void 0:nv(e.parent)),e.projection.setOptions({layoutId:o,layout:a,alwaysMeasureLayout:!!s||u&&Dn(u),visualElement:e,animationType:typeof a=="string"?a:"both",initialPromotionConfig:n,layoutScroll:l,layoutRoot:c})}function nv(e){if(e)return e.options.allowProjection!==!1?e.projection:nv(e.parent)}i();import{useCallback as YI}from"react";function ov(e,t,r){return YI(n=>{n&&e.mount&&e.mount(n),t&&(n?t.mount(n):t.unmount()),r&&(typeof r=="function"?r(n):Dn(r)&&(r.current=n))},[t])}i();import{useContext as JI,useMemo as ZI}from"react";i();i();function En(e){return typeof e=="string"||Array.isArray(e)}i();i();function Pn(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}i();var Zl=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],eu=["initial",...Zl];function Qo(e){return Pn(e.animate)||eu.some(t=>En(e[t]))}function Ql(e){return!!(Qo(e)||e.variants)}function iv(e,t){if(Qo(e)){let{initial:r,animate:n}=e;return{initial:r===!1||En(r)?r:void 0,animate:En(n)?n:void 0}}return e.inherit!==!1?t:{}}function sv(e){let{initial:t,animate:r}=iv(e,JI(oo));return ZI(()=>({initial:t,animate:r}),[av(t),av(r)])}function av(e){return Array.isArray(e)?e.join(" "):e}i();i();var uv={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]},Tn={};for(let e in uv)Tn[e]={isEnabled:t=>uv[e].some(r=>!!t[r])};function lv(e){for(let t in e)Tn[t]={...Tn[t],...e[t]}}i();import{createContext as QI}from"react";var ia=QI({});i();var cv=Symbol.for("motionComponentSymbol");i();i();var Ae=e=>e;var so=Ae,Vr=Ae;function fv({preloadedFeatures:e,createVisualElement:t,useRender:r,useVisualState:n,Component:o}){e&&lv(e);function a(u,l){let c,p={...dm(ra),...u,layoutId:nk(u)},{isStatic:d}=p,h=sv(u),g=n(u,d);if(!d&&na){ok(p,e);let v=ik(p);c=v.MeasureLayout,h.visualElement=rv(o,g,p,t,v.ProjectionNode)}return ek(oo.Provider,{value:h,children:[c&&h.visualElement?tk(c,{visualElement:h.visualElement,...p}):null,r(o,u,ov(g,h.visualElement,l),g,d,h.visualElement)]})}let s=rk(a);return s[cv]=o,s}function nk({layoutId:e}){let t=dm(ia).id;return t&&e!==void 0?t+"-"+e:e}function ok(e,t){let r=dm(Kl).strict}function ik(e){let{drag:t,layout:r}=Tn;if(!t&&!r)return{};let n={...t,...r};return{MeasureLayout:t?.isEnabled(e)||r?.isEnabled(e)?n.MeasureLayout:void 0,ProjectionNode:n.ProjectionNode}}i();function pv(e){function t(n,o={}){return fv(e(n,o))}if(typeof Proxy>"u")return t;let r=new Map;return new Proxy(t,{get:(n,o)=>(r.has(o)||r.set(o,t(o)),r.get(o))})}i();i();i();var dv=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function aa(e){return typeof e!="string"||e.includes("-")?!1:!!(dv.indexOf(e)>-1||/[A-Z]/u.test(e))}i();import{Fragment as Ck,useMemo as xk,createElement as wk}from"react";i();import{useMemo as ck}from"react";i();i();var sa={};function mv(e){Object.assign(sa,e)}i();var uo=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],Pt=new Set(uo);function ec(e,{layout:t,layoutId:r}){return Pt.has(e)||e.startsWith("origin")||(t||r!==void 0)&&(!!sa[e]||e==="opacity")}i();var Me=e=>!!(e&&e.getVelocity);i();i();i();var tc=(e,t)=>t&&typeof e=="number"?t.transform(e):e;i();i();i();var Ot=(e,t,r)=>r>t?t:r<e?e:r;var Xr={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},lo={...Xr,transform:e=>Ot(0,1,e)},tu={...Xr,default:1};i();i();var co=e=>Math.round(e*1e5)/1e5,ua=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu,hv=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu,gv=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu;function An(e){return typeof e=="string"}function vv(e){return e==null}var ru=e=>({test:t=>An(t)&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),Yr=ru("deg"),Mt=ru("%"),ie=ru("px"),yv=ru("vh"),bv=ru("vw"),mm={...Mt,parse:e=>Mt.parse(e)/100,transform:e=>Mt.transform(e*100)};i();var hm={...Xr,transform:Math.round};var la={borderWidth:ie,borderTopWidth:ie,borderRightWidth:ie,borderBottomWidth:ie,borderLeftWidth:ie,borderRadius:ie,radius:ie,borderTopLeftRadius:ie,borderTopRightRadius:ie,borderBottomRightRadius:ie,borderBottomLeftRadius:ie,width:ie,maxWidth:ie,height:ie,maxHeight:ie,size:ie,top:ie,right:ie,bottom:ie,left:ie,padding:ie,paddingTop:ie,paddingRight:ie,paddingBottom:ie,paddingLeft:ie,margin:ie,marginTop:ie,marginRight:ie,marginBottom:ie,marginLeft:ie,rotate:Yr,rotateX:Yr,rotateY:Yr,rotateZ:Yr,scale:tu,scaleX:tu,scaleY:tu,scaleZ:tu,skew:Yr,skewX:Yr,skewY:Yr,distance:ie,translateX:ie,translateY:ie,translateZ:ie,x:ie,y:ie,z:ie,perspective:ie,transformPerspective:ie,opacity:lo,originX:mm,originY:mm,originZ:ie,zIndex:hm,backgroundPositionX:ie,backgroundPositionY:ie,fillOpacity:lo,strokeOpacity:lo,numOctaves:hm};var ak={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},sk=uo.length;function Cv(e,t,r){let n="",o=!0;for(let a=0;a<sk;a++){let s=uo[a],u=e[s];if(u===void 0)continue;let l=!0;if(typeof u=="number"?l=u===(s.startsWith("scale")?1:0):l=parseFloat(u)===0,!l||r){let c=tc(u,la[s]);if(!l){o=!1;let p=ak[s]||s;n+=`${p}(${c}) `}r&&(t[s]=c)}}return n=n.trim(),r?n=r(t,o?"":n):o&&(n="none"),n}i();var xv=e=>t=>typeof t=="string"&&t.startsWith(e),rc=xv("--"),uk=xv("var(--"),ca=e=>uk(e)?lk.test(e.split("/*")[0].trim()):!1,lk=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu;function fa(e,t,r){let{style:n,vars:o,transformOrigin:a}=e,s=!1,u=!1;for(let l in t){let c=t[l];if(Pt.has(l)){s=!0;continue}else if(rc(l)){o[l]=c;continue}else{let p=tc(c,la[l]);l.startsWith("origin")?(u=!0,a[l]=p):n[l]=p}}if(t.transform||(s||r?n.transform=Cv(t,e.transform,r):n.transform&&(n.transform="none")),u){let{originX:l="50%",originY:c="50%",originZ:p=0}=a;n.transformOrigin=`${l} ${c} ${p}`}}i();var pa=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function gm(e,t,r){for(let n in t)!Me(t[n])&&!ec(n,r)&&(e[n]=t[n])}function fk({transformTemplate:e},t){return ck(()=>{let r=pa();return fa(r,t,e),Object.assign({},r.vars,r.style)},[t])}function pk(e,t){let r=e.style||{},n={};return gm(n,r,e),Object.assign(n,fk(e,t)),n}function wv(e,t){let r={},n=pk(e,t);return e.drag&&e.dragListener!==!1&&(r.draggable=!1,n.userSelect=n.WebkitUserSelect=n.WebkitTouchCallout="none",n.touchAction=e.drag===!0?"none":`pan-${e.drag==="x"?"y":"x"}`),e.tabIndex===void 0&&(e.onTap||e.onTapStart||e.whileTap)&&(r.tabIndex=0),r.style=n,r}i();i();var dk=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function nu(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||dk.has(e)}var Tv=e=>!nu(e);function gk(e){e&&(Tv=t=>t.startsWith("on")?!nu(t):e(t))}try{gk((Pv(),WO(Ev)).default)}catch{}function Av(e,t,r){let n={};for(let o in e)o==="values"&&typeof e.values=="object"||(Tv(o)||r===!0&&nu(o)||!t&&!nu(o)||e.draggable&&o.startsWith("onDrag"))&&(n[o]=e[o]);return n}i();import{useMemo as bk}from"react";i();i();function Rv(e,t,r){return typeof e=="string"?e:ie.transform(t+r*e)}function Fv(e,t,r){let n=Rv(t,e.x,e.width),o=Rv(r,e.y,e.height);return`${n} ${o}`}i();var vk={offset:"stroke-dashoffset",array:"stroke-dasharray"},yk={offset:"strokeDashoffset",array:"strokeDasharray"};function Bv(e,t,r=1,n=0,o=!0){e.pathLength=1;let a=o?vk:yk;e[a.offset]=ie.transform(-n);let s=ie.transform(t),u=ie.transform(r);e[a.array]=`${s} ${u}`}function da(e,{attrX:t,attrY:r,attrScale:n,originX:o,originY:a,pathLength:s,pathSpacing:u=1,pathOffset:l=0,...c},p,d){if(fa(e,c,d),p){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};let{attrs:h,style:g,dimensions:v}=e;h.transform&&(v&&(g.transform=h.transform),delete h.transform),v&&(o!==void 0||a!==void 0||g.transform)&&(g.transformOrigin=Fv(v,o!==void 0?o:.5,a!==void 0?a:.5)),t!==void 0&&(h.x=t),r!==void 0&&(h.y=r),n!==void 0&&(h.scale=n),s!==void 0&&Bv(h,s,u,l,!1)}i();var nc=()=>({...pa(),attrs:{}});i();var ma=e=>typeof e=="string"&&e.toLowerCase()==="svg";function Ov(e,t,r,n){let o=bk(()=>{let a=nc();return da(a,t,ma(n),e.transformTemplate),{...a.attrs,style:{...a.style}}},[t]);if(e.style){let a={};gm(a,e.style,e),o.style={...a,...o.style}}return o}function Mv(e=!1){return(r,n,o,{latestValues:a},s)=>{let l=(aa(r)?Ov:wv)(n,a,s,r),c=Av(n,typeof r=="string",e),p=r!==Ck?{...c,...l,ref:o}:{},{children:d}=n,h=xk(()=>Me(d)?d.get():d,[d]);return wk(r,{...p,children:h})}}i();i();i();function oc(e,{style:t,vars:r},n,o){Object.assign(e.style,t,o&&o.getProjectionStyles(n));for(let a in r)e.style.setProperty(a,r[a])}i();var ic=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]);function ac(e,t,r,n){oc(e,t,void 0,n);for(let o in t.attrs)e.setAttribute(ic.has(o)?o:ao(o),t.attrs[o])}i();i();function ha(e,t,r){var n;let{style:o}=e,a={};for(let s in o)(Me(o[s])||t.style&&Me(t.style[s])||ec(s,e)||((n=r?.getValue(s))===null||n===void 0?void 0:n.liveStyle)!==void 0)&&(a[s]=o[s]);return r&&o&&typeof o.willChange=="string"&&(r.applyWillChange=!1),a}function sc(e,t,r){let n=ha(e,t,r);for(let o in e)if(Me(e[o])||Me(t[o])){let a=uo.indexOf(o)!==-1?"attr"+o.charAt(0).toUpperCase()+o.substring(1):o;n[a]=e[o]}return n}i();import{useContext as Vv}from"react";i();function Iv(e){let t=[{},{}];return e?.values.forEach((r,n)=>{t[0][n]=r.get(),t[1][n]=r.getVelocity()}),t}function ga(e,t,r,n){if(typeof t=="function"){let[o,a]=Iv(n);t=t(r!==void 0?r:e.custom,o,a)}if(typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"){let[o,a]=Iv(n);t=t(r!==void 0?r:e.custom,o,a)}return t}i();import{useRef as Sk}from"react";function va(e){let t=Sk(null);return t.current===null&&(t.current=e()),t.current}i();i();i();var ou=e=>Array.isArray(e);var kv=e=>!!(e&&typeof e=="object"&&e.mix&&e.toValue),Nv=e=>ou(e)?e[e.length-1]||0:e;function ya(e){let t=Me(e)?e.get():e;return kv(t)?t.toValue():t}i();i();var uc=new Set(["opacity","clipPath","filter","transform"]);function lc(e){if(Pt.has(e))return"transform";if(uc.has(e))return ao(e)}i();function fo(e,t){e.indexOf(t)===-1&&e.push(t)}function po(e,t){let r=e.indexOf(t);r>-1&&e.splice(r,1)}function Dk({applyWillChange:e=!1,scrapeMotionValuesFromProps:t,createRenderState:r,onMount:n},o,a,s,u){let l={latestValues:Pk(o,a,s,u?!1:e,t),renderState:r()};return n&&(l.mount=c=>n(o,c,l)),l}var cc=e=>(t,r)=>{let n=Vv(oo),o=Vv(io),a=()=>Dk(e,t,n,o,r);return r?a():va(a)};function Ek(e,t){let r=lc(t);r&&fo(e,r)}function Lv(e,t,r){let n=Array.isArray(t)?t:[t];for(let o=0;o<n.length;o++){let a=ga(e,n[o]);if(a){let{transitionEnd:s,transition:u,...l}=a;r(l,s)}}}function Pk(e,t,r,n,o){var a;let s={},u=[],l=n&&((a=e.style)===null||a===void 0?void 0:a.willChange)===void 0,c=o(e,{});for(let b in c)s[b]=ya(c[b]);let{initial:p,animate:d}=e,h=Qo(e),g=Ql(e);t&&g&&!h&&e.inherit!==!1&&(p===void 0&&(p=t.initial),d===void 0&&(d=t.animate));let v=r?r.initial===!1:!1;v=v||p===!1;let m=v?d:p;return m&&typeof m!="boolean"&&!Pn(m)&&Lv(e,m,(b,y)=>{for(let x in b){let w=b[x];if(Array.isArray(w)){let S=v?w.length-1:0;w=w[S]}w!==null&&(s[x]=w)}for(let x in y)s[x]=y[x]}),l&&(d&&p!==!1&&!Pn(d)&&Lv(e,d,b=>{for(let y in b)Ek(u,y)}),u.length&&(s.willChange=u.join(","))),s}i();var{schedule:pe,cancel:It,state:qe,steps:fc}=Yl(typeof requestAnimationFrame<"u"?requestAnimationFrame:Ae,!0);var $v={useVisualState:cc({scrapeMotionValuesFromProps:sc,createRenderState:nc,onMount:(e,t,{renderState:r,latestValues:n})=>{pe.read(()=>{try{r.dimensions=typeof t.getBBox=="function"?t.getBBox():t.getBoundingClientRect()}catch{r.dimensions={x:0,y:0,width:0,height:0}}}),pe.render(()=>{da(r,n,ma(t.tagName),e.transformTemplate),ac(t,r)})}})};i();var zv={useVisualState:cc({applyWillChange:!0,scrapeMotionValuesFromProps:ha,createRenderState:pa})};function Hv(e,{forwardMotionProps:t=!1},r,n){return{...aa(e)?$v:zv,preloadedFeatures:r,useRender:Mv(t),createVisualElement:n,Component:e}}i();i();i();i();function _t(e,t,r,n={passive:!0}){return e.addEventListener(t,r,n),()=>e.removeEventListener(t,r)}i();i();var pc=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1;function ei(e,t="page"){return{point:{x:e[`${t}X`],y:e[`${t}Y`]}}}var Gv=e=>t=>pc(t)&&e(t,ei(t));function Wt(e,t,r,n){return _t(e,t,Gv(r),n)}i();var Tk=(e,t)=>r=>t(e(r)),Tt=(...e)=>e.reduce(Tk);i();function Wv(e){let t=null;return()=>{let r=()=>{t=null};return t===null?(t=e,r):!1}}var jv=Wv("dragHorizontal"),_v=Wv("dragVertical");function vm(e){let t=!1;if(e==="y")t=_v();else if(e==="x")t=jv();else{let r=jv(),n=_v();r&&n?t=()=>{r(),n()}:(r&&r(),n&&n())}return t}function dc(){let e=vm(!0);return e?(e(),!1):!0}i();var ut=class{constructor(t){this.isMounted=!1,this.node=t}update(){}};function Uv(e,t){let r=t?"pointerenter":"pointerleave",n=t?"onHoverStart":"onHoverEnd",o=(a,s)=>{if(a.pointerType==="touch"||dc())return;let u=e.getProps();e.animationState&&u.whileHover&&e.animationState.setActive("whileHover",t);let l=u[n];l&&pe.postRender(()=>l(a,s))};return Wt(e.current,r,o,{passive:!e.getProps()[n]})}var mc=class extends ut{mount(){this.unmount=Tt(Uv(this.node,!0),Uv(this.node,!1))}unmount(){}};i();var hc=class extends ut{constructor(){super(...arguments),this.isActive=!1}onFocus(){let t=!1;try{t=this.node.current.matches(":focus-visible")}catch{t=!0}!t||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){!this.isActive||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=Tt(_t(this.node.current,"focus",()=>this.onFocus()),_t(this.node.current,"blur",()=>this.onBlur()))}unmount(){}};i();i();var ym=(e,t)=>t?e===t?!0:ym(e,t.parentElement):!1;function bm(e,t){if(!t)return;let r=new PointerEvent("pointer"+e);t(r,ei(r))}var gc=class extends ut{constructor(){super(...arguments),this.removeStartListeners=Ae,this.removeEndListeners=Ae,this.removeAccessibleListeners=Ae,this.startPointerPress=(t,r)=>{if(this.isPressing)return;this.removeEndListeners();let n=this.node.getProps(),a=Wt(window,"pointerup",(u,l)=>{if(!this.checkPressEnd())return;let{onTap:c,onTapCancel:p,globalTapTarget:d}=this.node.getProps(),h=!d&&!ym(this.node.current,u.target)?p:c;h&&pe.update(()=>h(u,l))},{passive:!(n.onTap||n.onPointerUp)}),s=Wt(window,"pointercancel",(u,l)=>this.cancelPress(u,l),{passive:!(n.onTapCancel||n.onPointerCancel)});this.removeEndListeners=Tt(a,s),this.startPress(t,r)},this.startAccessiblePress=()=>{let t=a=>{if(a.key!=="Enter"||this.isPressing)return;let s=u=>{u.key!=="Enter"||!this.checkPressEnd()||bm("up",(l,c)=>{let{onTap:p}=this.node.getProps();p&&pe.postRender(()=>p(l,c))})};this.removeEndListeners(),this.removeEndListeners=_t(this.node.current,"keyup",s),bm("down",(u,l)=>{this.startPress(u,l)})},r=_t(this.node.current,"keydown",t),n=()=>{this.isPressing&&bm("cancel",(a,s)=>this.cancelPress(a,s))},o=_t(this.node.current,"blur",n);this.removeAccessibleListeners=Tt(r,o)}}startPress(t,r){this.isPressing=!0;let{onTapStart:n,whileTap:o}=this.node.getProps();o&&this.node.animationState&&this.node.animationState.setActive("whileTap",!0),n&&pe.postRender(()=>n(t,r))}checkPressEnd(){return this.removeEndListeners(),this.isPressing=!1,this.node.getProps().whileTap&&this.node.animationState&&this.node.animationState.setActive("whileTap",!1),!dc()}cancelPress(t,r){if(!this.checkPressEnd())return;let{onTapCancel:n}=this.node.getProps();n&&pe.postRender(()=>n(t,r))}mount(){let t=this.node.getProps(),r=Wt(t.globalTapTarget?window:this.node.current,"pointerdown",this.startPointerPress,{passive:!(t.onTapStart||t.onPointerStart)}),n=_t(this.node.current,"focus",this.startAccessiblePress);this.removeStartListeners=Tt(r,n)}unmount(){this.removeStartListeners(),this.removeEndListeners(),this.removeAccessibleListeners()}};i();i();var xm=new WeakMap,Cm=new WeakMap,Ak=e=>{let t=xm.get(e.target);t&&t(e)},Rk=e=>{e.forEach(Ak)};function Fk({root:e,...t}){let r=e||document;Cm.has(r)||Cm.set(r,{});let n=Cm.get(r),o=JSON.stringify(t);return n[o]||(n[o]=new IntersectionObserver(Rk,{root:e,...t})),n[o]}function Kv(e,t,r){let n=Fk(t);return xm.set(e,r),n.observe(e),()=>{xm.delete(e),n.unobserve(e)}}var Bk={some:0,all:1},vc=class extends ut{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();let{viewport:t={}}=this.node.getProps(),{root:r,margin:n,amount:o="some",once:a}=t,s={root:r?r.current:void 0,rootMargin:n,threshold:typeof o=="number"?o:Bk[o]},u=l=>{let{isIntersecting:c}=l;if(this.isInView===c||(this.isInView=c,a&&!c&&this.hasEnteredView))return;c&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",c);let{onViewportEnter:p,onViewportLeave:d}=this.node.getProps(),h=c?p:d;h&&h(l)};return Kv(this.node.current,s,u)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;let{props:t,prevProps:r}=this.node;["amount","margin","root"].some(Ok(t,r))&&this.startObserver()}unmount(){}};function Ok({viewport:e={}},{viewport:t={}}={}){return r=>e[r]!==t[r]}var qv={inView:{Feature:vc},tap:{Feature:gc},focus:{Feature:hc},hover:{Feature:mc}};i();i();i();i();function wm(e,t){if(!Array.isArray(t))return!1;let r=t.length;if(r!==e.length)return!1;for(let n=0;n<r;n++)if(t[n]!==e[n])return!1;return!0}i();function mo(e,t,r){let n=e.getProps();return ga(n,t,r!==void 0?r:n.custom,e)}i();i();i();i();var Ut=e=>e*1e3,Kt=e=>e/1e3;i();var Mk={type:"spring",stiffness:500,damping:25,restSpeed:10},Ik=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),kk={type:"keyframes",duration:.8},Nk={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},Xv=(e,{keyframes:t})=>t.length>2?kk:Pt.has(e)?e.startsWith("scale")?Ik(t[1]):Mk:Nk;i();function Yv({when:e,delay:t,delayChildren:r,staggerChildren:n,staggerDirection:o,repeat:a,repeatType:s,repeatDelay:u,from:l,elapsed:c,...p}){return!!Object.keys(p).length}function ba(e,t){return e[t]||e.default||e}i();var yc={current:!1};i();var Vk=e=>e!==null;function ho(e,{repeat:t,repeatType:r="loop"},n){let o=e.filter(Vk),a=t&&r!=="loop"&&t%2===1?0:o.length-1;return!a||n===void 0?o[a]:n}i();i();var bc;function Lk(){bc=void 0}var lr={now:()=>(bc===void 0&&lr.set(qe.isProcessing||Sn.useManualTiming?qe.timestamp:performance.now()),bc),set:e=>{bc=e,queueMicrotask(Lk)}};i();i();i();var Cc=e=>/^0[^.\s]+$/u.test(e);function Jv(e){return typeof e=="number"?e===0:e!==null?e==="none"||e==="0"||Cc(e):!0}i();i();var xc=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e);var $k=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function zk(e){let t=$k.exec(e);if(!t)return[,];let[,r,n,o]=t;return[`--${r??n}`,o]}var Hk=4;function Sm(e,t,r=1){Vr(r<=Hk,`Max CSS variable fallback depth detected in property "${e}". This may indicate a circular fallback dependency.`);let[n,o]=zk(e);if(!n)return;let a=window.getComputedStyle(t).getPropertyValue(n);if(a){let s=a.trim();return xc(s)?parseFloat(s):s}return ca(o)?Sm(o,t,r+1):o}i();var e4=new Set(["width","height","top","left","right","bottom","x","y","translateX","translateY"]),Dm=e=>e===Xr||e===ie,Zv=(e,t)=>parseFloat(e.split(", ")[t]),Qv=(e,t)=>(r,{transform:n})=>{if(n==="none"||!n)return 0;let o=n.match(/^matrix3d\((.+)\)$/u);if(o)return Zv(o[1],t);{let a=n.match(/^matrix\((.+)\)$/u);return a?Zv(a[1],e):0}},Gk=new Set(["x","y","z"]),jk=uo.filter(e=>!Gk.has(e));function t4(e){let t=[];return jk.forEach(r=>{let n=e.getValue(r);n!==void 0&&(t.push([r,n.get()]),n.set(r.startsWith("scale")?1:0))}),t}var ti={width:({x:e},{paddingLeft:t="0",paddingRight:r="0"})=>e.max-e.min-parseFloat(t)-parseFloat(r),height:({y:e},{paddingTop:t="0",paddingBottom:r="0"})=>e.max-e.min-parseFloat(t)-parseFloat(r),top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:Qv(4,13),y:Qv(5,14)};ti.translateX=ti.x;ti.translateY=ti.y;i();i();var wc=e=>t=>t.test(e);i();var r4={test:e=>e==="auto",parse:e=>e};var Em=[Xr,ie,Mt,Yr,bv,yv,r4],Pm=e=>Em.find(wc(e));i();var ri=new Set,Tm=!1,Am=!1;function n4(){if(Am){let e=Array.from(ri).filter(n=>n.needsMeasurement),t=new Set(e.map(n=>n.element)),r=new Map;t.forEach(n=>{let o=t4(n);o.length&&(r.set(n,o),n.render())}),e.forEach(n=>n.measureInitialState()),t.forEach(n=>{n.render();let o=r.get(n);o&&o.forEach(([a,s])=>{var u;(u=n.getValue(a))===null||u===void 0||u.set(s)})}),e.forEach(n=>n.measureEndState()),e.forEach(n=>{n.suspendedScrollY!==void 0&&window.scrollTo(0,n.suspendedScrollY)})}Am=!1,Tm=!1,ri.forEach(e=>e.complete()),ri.clear()}function o4(){ri.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(Am=!0)})}function i4(){o4(),n4()}var go=class{constructor(t,r,n,o,a,s=!1){this.isComplete=!1,this.isAsync=!1,this.needsMeasurement=!1,this.isScheduled=!1,this.unresolvedKeyframes=[...t],this.onComplete=r,this.name=n,this.motionValue=o,this.element=a,this.isAsync=s}scheduleResolve(){this.isScheduled=!0,this.isAsync?(ri.add(this),Tm||(Tm=!0,pe.read(o4),pe.resolveKeyframes(n4))):(this.readKeyframes(),this.complete())}readKeyframes(){let{unresolvedKeyframes:t,name:r,element:n,motionValue:o}=this;for(let a=0;a<t.length;a++)if(t[a]===null)if(a===0){let s=o?.get(),u=t[t.length-1];if(s!==void 0)t[0]=s;else if(n&&r){let l=n.readValue(r,u);l!=null&&(t[0]=l)}t[0]===void 0&&(t[0]=u),o&&s===void 0&&o.set(t[0])}else t[a]=t[a-1]}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(){this.isComplete=!0,this.onComplete(this.unresolvedKeyframes,this.finalKeyframe),ri.delete(this)}cancel(){this.isComplete||(this.isScheduled=!1,ri.delete(this))}resume(){this.isComplete||this.scheduleResolve()}};i();i();i();i();i();i();var Ca=(e,t)=>r=>!!(An(r)&&gv.test(r)&&r.startsWith(e)||t&&!vv(r)&&Object.prototype.hasOwnProperty.call(r,t)),Sc=(e,t,r)=>n=>{if(!An(n))return n;let[o,a,s,u]=n.match(ua);return{[e]:parseFloat(o),[t]:parseFloat(a),[r]:parseFloat(s),alpha:u!==void 0?parseFloat(u):1}};var _k=e=>Ot(0,255,e),Rm={...Xr,transform:e=>Math.round(_k(e))},Jr={test:Ca("rgb","red"),parse:Sc("red","green","blue"),transform:({red:e,green:t,blue:r,alpha:n=1})=>"rgba("+Rm.transform(e)+", "+Rm.transform(t)+", "+Rm.transform(r)+", "+co(lo.transform(n))+")"};function Wk(e){let t="",r="",n="",o="";return e.length>5?(t=e.substring(1,3),r=e.substring(3,5),n=e.substring(5,7),o=e.substring(7,9)):(t=e.substring(1,2),r=e.substring(2,3),n=e.substring(3,4),o=e.substring(4,5),t+=t,r+=r,n+=n,o+=o),{red:parseInt(t,16),green:parseInt(r,16),blue:parseInt(n,16),alpha:o?parseInt(o,16)/255:1}}var iu={test:Ca("#"),parse:Wk,transform:Jr.transform};i();var vo={test:Ca("hsl","hue"),parse:Sc("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:r,alpha:n=1})=>"hsla("+Math.round(e)+", "+Mt.transform(co(t))+", "+Mt.transform(co(r))+", "+co(lo.transform(n))+")"};var Ze={test:e=>Jr.test(e)||iu.test(e)||vo.test(e),parse:e=>Jr.test(e)?Jr.parse(e):vo.test(e)?vo.parse(e):iu.parse(e),transform:e=>An(e)?e:e.hasOwnProperty("red")?Jr.transform(e):vo.transform(e)};function Uk(e){var t,r;return isNaN(e)&&An(e)&&(((t=e.match(ua))===null||t===void 0?void 0:t.length)||0)+(((r=e.match(hv))===null||r===void 0?void 0:r.length)||0)>0}var s4="number",u4="color",Kk="var",qk="var(",a4="${}",Xk=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function ni(e){let t=e.toString(),r=[],n={color:[],number:[],var:[]},o=[],a=0,u=t.replace(Xk,l=>(Ze.test(l)?(n.color.push(a),o.push(u4),r.push(Ze.parse(l))):l.startsWith(qk)?(n.var.push(a),o.push(Kk),r.push(l)):(n.number.push(a),o.push(s4),r.push(parseFloat(l))),++a,a4)).split(a4);return{values:r,split:u,indexes:n,types:o}}function l4(e){return ni(e).values}function c4(e){let{split:t,types:r}=ni(e),n=t.length;return o=>{let a="";for(let s=0;s<n;s++)if(a+=t[s],o[s]!==void 0){let u=r[s];u===s4?a+=co(o[s]):u===u4?a+=Ze.transform(o[s]):a+=o[s]}return a}}var Yk=e=>typeof e=="number"?0:e;function Jk(e){let t=l4(e);return c4(e)(t.map(Yk))}var kt={test:Uk,parse:l4,createTransformer:c4,getAnimatableNone:Jk};i();i();var Zk=new Set(["brightness","contrast","saturate","opacity"]);function Qk(e){let[t,r]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;let[n]=r.match(ua)||[];if(!n)return e;let o=r.replace(n,""),a=Zk.has(t)?1:0;return n!==r&&(a*=100),t+"("+a+o+")"}var eN=/\b([a-z-]*)\(.*?\)/gu,au={...kt,getAnimatableNone:e=>{let t=e.match(eN);return t?t.map(Qk).join(" "):e}};i();var tN={...la,color:Ze,backgroundColor:Ze,outlineColor:Ze,fill:Ze,stroke:Ze,borderColor:Ze,borderTopColor:Ze,borderRightColor:Ze,borderBottomColor:Ze,borderLeftColor:Ze,filter:au,WebkitFilter:au},xa=e=>tN[e];function Dc(e,t){let r=xa(e);return r!==au&&(r=kt),r.getAnimatableNone?r.getAnimatableNone(t):void 0}var rN=new Set(["auto","none","0"]);function f4(e,t,r){let n=0,o;for(;n<e.length&&!o;){let a=e[n];typeof a=="string"&&!rN.has(a)&&ni(a).values.length&&(o=e[n]),n++}if(o&&r)for(let a of t)e[a]=Dc(r,o)}var wa=class extends go{constructor(t,r,n,o){super(t,r,n,o,o?.owner,!0)}readKeyframes(){let{unresolvedKeyframes:t,element:r,name:n}=this;if(!r.current)return;super.readKeyframes();for(let l=0;l<t.length;l++){let c=t[l];if(typeof c=="string"&&(c=c.trim(),ca(c))){let p=Sm(c,r.current);p!==void 0&&(t[l]=p),l===t.length-1&&(this.finalKeyframe=c)}}if(this.resolveNoneKeyframes(),!e4.has(n)||t.length!==2)return;let[o,a]=t,s=Pm(o),u=Pm(a);if(s!==u)if(Dm(s)&&Dm(u))for(let l=0;l<t.length;l++){let c=t[l];typeof c=="string"&&(t[l]=parseFloat(c))}else this.needsMeasurement=!0}resolveNoneKeyframes(){let{unresolvedKeyframes:t,name:r}=this,n=[];for(let o=0;o<t.length;o++)Jv(t[o])&&n.push(o);n.length&&f4(t,n,r)}measureInitialState(){let{element:t,unresolvedKeyframes:r,name:n}=this;if(!t.current)return;n==="height"&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=ti[n](t.measureViewportBox(),window.getComputedStyle(t.current)),r[0]=this.measuredOrigin;let o=r[r.length-1];o!==void 0&&t.getValue(n,o).jump(o,!1)}measureEndState(){var t;let{element:r,name:n,unresolvedKeyframes:o}=this;if(!r.current)return;let a=r.getValue(n);a&&a.jump(this.measuredOrigin,!1);let s=o.length-1,u=o[s];o[s]=ti[n](r.measureViewportBox(),window.getComputedStyle(r.current)),u!==null&&this.finalKeyframe===void 0&&(this.finalKeyframe=u),!((t=this.removedTransforms)===null||t===void 0)&&t.length&&this.removedTransforms.forEach(([l,c])=>{r.getValue(l).set(c)}),this.resolveNoneKeyframes()}};i();function Ec(e){let t;return()=>(t===void 0&&(t=e()),t)}i();i();i();var Fm=(e,t)=>t==="zIndex"?!1:!!(typeof e=="number"||Array.isArray(e)||typeof e=="string"&&(kt.test(e)||e==="0")&&!e.startsWith("url("));function nN(e){let t=e[0];if(e.length===1)return!0;for(let r=0;r<e.length;r++)if(e[r]!==t)return!0}function p4(e,t,r,n){let o=e[0];if(o===null)return!1;if(t==="display"||t==="visibility")return!0;let a=e[e.length-1],s=Fm(o,t),u=Fm(a,t);return so(s===u,`You are trying to animate ${t} from "${o}" to "${a}". ${o} is not an animatable value - to enable this animation set ${o} to a value animatable to ${a} via the \`style\` property.`),!s||!u?!1:nN(e)||r==="spring"&&n}var Sa=class{constructor({autoplay:t=!0,delay:r=0,type:n="keyframes",repeat:o=0,repeatDelay:a=0,repeatType:s="loop",...u}){this.isStopped=!1,this.hasAttemptedResolve=!1,this.options={autoplay:t,delay:r,type:n,repeat:o,repeatDelay:a,repeatType:s,...u},this.updateFinishedPromise()}get resolved(){return!this._resolved&&!this.hasAttemptedResolve&&i4(),this._resolved}onKeyframesResolved(t,r){this.hasAttemptedResolve=!0;let{name:n,type:o,velocity:a,delay:s,onComplete:u,onUpdate:l,isGenerator:c}=this.options;if(!c&&!p4(t,n,o,a))if(yc.current||!s){l?.(ho(t,this.options,r)),u?.(),this.resolveFinishedPromise();return}else this.options.duration=0;let p=this.initPlayback(t,r);p!==!1&&(this._resolved={keyframes:t,finalKeyframe:r,...p},this.onPostResolved())}onPostResolved(){}then(t,r){return this.currentFinishedPromise.then(t,r)}updateFinishedPromise(){this.currentFinishedPromise=new Promise(t=>{this.resolveFinishedPromise=t})}};i();i();i();i();function Pc(e,t){return t?e*(1e3/t):0}var oN=5;function Tc(e,t,r){let n=Math.max(t-oN,0);return Pc(r-e(n),t-n)}i();var Bm=.001,iN=.01,d4=10,aN=.05,sN=1;function m4({duration:e=800,bounce:t=.25,velocity:r=0,mass:n=1}){let o,a;so(e<=Ut(d4),"Spring duration must be 10 seconds or less");let s=1-t;s=Ot(aN,sN,s),e=Ot(iN,d4,Kt(e)),s<1?(o=c=>{let p=c*s,d=p*e,h=p-r,g=Ac(c,s),v=Math.exp(-d);return Bm-h/g*v},a=c=>{let d=c*s*e,h=d*r+r,g=Math.pow(s,2)*Math.pow(c,2)*e,v=Math.exp(-d),m=Ac(Math.pow(c,2),s);return(-o(c)+Bm>0?-1:1)*((h-g)*v)/m}):(o=c=>{let p=Math.exp(-c*e),d=(c-r)*e+1;return-Bm+p*d},a=c=>{let p=Math.exp(-c*e),d=(r-c)*(e*e);return p*d});let u=5/e,l=lN(o,a,u);if(e=Ut(e),isNaN(l))return{stiffness:100,damping:10,duration:e};{let c=Math.pow(l,2)*n;return{stiffness:c,damping:s*2*Math.sqrt(n*c),duration:e}}}var uN=12;function lN(e,t,r){let n=r;for(let o=1;o<uN;o++)n=n-e(n)/t(n);return n}function Ac(e,t){return e*Math.sqrt(1-t*t)}var cN=["duration","bounce"],fN=["stiffness","damping","mass"];function h4(e,t){return t.some(r=>e[r]!==void 0)}function pN(e){let t={velocity:0,stiffness:100,damping:10,mass:1,isResolvedFromDuration:!1,...e};if(!h4(e,fN)&&h4(e,cN)){let r=m4(e);t={...t,...r,mass:1},t.isResolvedFromDuration=!0}return t}function Rc({keyframes:e,restDelta:t,restSpeed:r,...n}){let o=e[0],a=e[e.length-1],s={done:!1,value:o},{stiffness:u,damping:l,mass:c,duration:p,velocity:d,isResolvedFromDuration:h}=pN({...n,velocity:-Kt(n.velocity||0)}),g=d||0,v=l/(2*Math.sqrt(u*c)),m=a-o,b=Kt(Math.sqrt(u/c)),y=Math.abs(m)<5;r||(r=y?.01:2),t||(t=y?.005:.5);let x;if(v<1){let w=Ac(b,v);x=S=>{let E=Math.exp(-v*b*S);return a-E*((g+v*b*m)/w*Math.sin(w*S)+m*Math.cos(w*S))}}else if(v===1)x=w=>a-Math.exp(-b*w)*(m+(g+b*m)*w);else{let w=b*Math.sqrt(v*v-1);x=S=>{let E=Math.exp(-v*b*S),D=Math.min(w*S,300);return a-E*((g+v*b*m)*Math.sinh(D)+w*m*Math.cosh(D))/w}}return{calculatedDuration:h&&p||null,next:w=>{let S=x(w);if(h)s.done=w>=p;else{let E=g;w!==0&&(v<1?E=Tc(x,w,S):E=0);let D=Math.abs(E)<=r,P=Math.abs(a-S)<=t;s.done=D&&P}return s.value=s.done?a:S,s}}}i();function Om({keyframes:e,velocity:t=0,power:r=.8,timeConstant:n=325,bounceDamping:o=10,bounceStiffness:a=500,modifyTarget:s,min:u,max:l,restDelta:c=.5,restSpeed:p}){let d=e[0],h={done:!1,value:d},g=R=>u!==void 0&&R<u||l!==void 0&&R>l,v=R=>u===void 0?l:l===void 0||Math.abs(u-R)<Math.abs(l-R)?u:l,m=r*t,b=d+m,y=s===void 0?b:s(b);y!==b&&(m=y-d);let x=R=>-m*Math.exp(-R/n),w=R=>y+x(R),S=R=>{let F=x(R),M=w(R);h.done=Math.abs(F)<=c,h.value=h.done?y:M},E,D,P=R=>{g(h.value)&&(E=R,D=Rc({keyframes:[h.value,v(h.value)],velocity:Tc(w,R,h.value),damping:o,stiffness:a,restDelta:c,restSpeed:p}))};return P(0),{calculatedDuration:null,next:R=>{let F=!1;return!D&&E===void 0&&(F=!0,S(R),P(R)),E!==void 0&&R>=E?D.next(R-E):(!F&&S(R),h)}}}i();i();i();var g4=(e,t,r)=>(((1-3*r+3*t)*e+(3*r-6*t))*e+3*t)*e,dN=1e-7,mN=12;function hN(e,t,r,n,o){let a,s,u=0;do s=t+(r-t)/2,a=g4(s,n,o)-e,a>0?r=s:t=s;while(Math.abs(a)>dN&&++u<mN);return s}function yo(e,t,r,n){if(e===t&&r===n)return Ae;let o=a=>hN(a,0,1,e,r);return a=>a===0||a===1?a:g4(o(a),t,n)}var v4=yo(.42,0,1,1),y4=yo(0,0,.58,1),Fc=yo(.42,0,.58,1);i();var b4=e=>Array.isArray(e)&&typeof e[0]!="number";i();i();i();var Bc=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2;i();var Oc=e=>t=>1-e(1-t);var Mc=e=>1-Math.sin(Math.acos(e)),Ic=Oc(Mc),C4=Bc(Mc);i();var Mm=yo(.33,1.53,.69,.99),su=Oc(Mm),x4=Bc(su);i();var w4=e=>(e*=2)<1?.5*su(e):.5*(2-Math.pow(2,-10*(e-1)));var S4={linear:Ae,easeIn:v4,easeInOut:Fc,easeOut:y4,circIn:Mc,circInOut:C4,circOut:Ic,backIn:su,backInOut:x4,backOut:Mm,anticipate:w4},Im=e=>{if(Array.isArray(e)){Vr(e.length===4,"Cubic bezier arrays must contain four numerical values.");let[t,r,n,o]=e;return yo(t,r,n,o)}else if(typeof e=="string")return Vr(S4[e]!==void 0,`Invalid easing type '${e}'`),S4[e];return e};i();i();var Rn=(e,t,r)=>{let n=t-e;return n===0?1:(r-e)/n};i();i();i();var be=(e,t,r)=>e+(t-e)*r;i();i();function km(e,t,r){return r<0&&(r+=1),r>1&&(r-=1),r<1/6?e+(t-e)*6*r:r<1/2?t:r<2/3?e+(t-e)*(2/3-r)*6:e}function D4({hue:e,saturation:t,lightness:r,alpha:n}){e/=360,t/=100,r/=100;let o=0,a=0,s=0;if(!t)o=a=s=r;else{let u=r<.5?r*(1+t):r+t-r*t,l=2*r-u;o=km(l,u,e+1/3),a=km(l,u,e),s=km(l,u,e-1/3)}return{red:Math.round(o*255),green:Math.round(a*255),blue:Math.round(s*255),alpha:n}}i();function Da(e,t){return r=>r>0?t:e}var Nm=(e,t,r)=>{let n=e*e,o=r*(t*t-n)+n;return o<0?0:Math.sqrt(o)},gN=[iu,Jr,vo],vN=e=>gN.find(t=>t.test(e));function E4(e){let t=vN(e);if(so(!!t,`'${e}' is not an animatable color. Use the equivalent color code instead.`),!t)return!1;let r=t.parse(e);return t===vo&&(r=D4(r)),r}var Vm=(e,t)=>{let r=E4(e),n=E4(t);if(!r||!n)return Da(e,t);let o={...r};return a=>(o.red=Nm(r.red,n.red,a),o.green=Nm(r.green,n.green,a),o.blue=Nm(r.blue,n.blue,a),o.alpha=be(r.alpha,n.alpha,a),Jr.transform(o))};i();var kc=new Set(["none","hidden"]);function P4(e,t){return kc.has(e)?r=>r<=0?e:t:r=>r>=1?t:e}function yN(e,t){return r=>be(e,t,r)}function Nc(e){return typeof e=="number"?yN:typeof e=="string"?ca(e)?Da:Ze.test(e)?Vm:xN:Array.isArray(e)?T4:typeof e=="object"?Ze.test(e)?Vm:bN:Da}function T4(e,t){let r=[...e],n=r.length,o=e.map((a,s)=>Nc(a)(a,t[s]));return a=>{for(let s=0;s<n;s++)r[s]=o[s](a);return r}}function bN(e,t){let r={...e,...t},n={};for(let o in r)e[o]!==void 0&&t[o]!==void 0&&(n[o]=Nc(e[o])(e[o],t[o]));return o=>{for(let a in n)r[a]=n[a](o);return r}}function CN(e,t){var r;let n=[],o={color:0,var:0,number:0};for(let a=0;a<t.values.length;a++){let s=t.types[a],u=e.indexes[s][o[s]],l=(r=e.values[u])!==null&&r!==void 0?r:0;n[a]=l,o[s]++}return n}var xN=(e,t)=>{let r=kt.createTransformer(t),n=ni(e),o=ni(t);return n.indexes.var.length===o.indexes.var.length&&n.indexes.color.length===o.indexes.color.length&&n.indexes.number.length>=o.indexes.number.length?kc.has(e)&&!o.values.length||kc.has(t)&&!n.values.length?P4(e,t):Tt(T4(CN(n,o),o.values),r):(so(!0,`Complex values '${e}' and '${t}' too different to mix. Ensure all colors are of the same type, and that each contains the same quantity of number and color values. Falling back to instant transition.`),Da(e,t))};function Vc(e,t,r){return typeof e=="number"&&typeof t=="number"&&typeof r=="number"?be(e,t,r):Nc(e)(e,t)}function wN(e,t,r){let n=[],o=r||Vc,a=e.length-1;for(let s=0;s<a;s++){let u=o(e[s],e[s+1]);if(t){let l=Array.isArray(t)?t[s]||Ae:t;u=Tt(l,u)}n.push(u)}return n}function A4(e,t,{clamp:r=!0,ease:n,mixer:o}={}){let a=e.length;if(Vr(a===t.length,"Both input and output ranges must be the same length"),a===1)return()=>t[0];if(a===2&&e[0]===e[1])return()=>t[1];e[0]>e[a-1]&&(e=[...e].reverse(),t=[...t].reverse());let s=wN(t,n,o),u=s.length,l=c=>{let p=0;if(u>1)for(;p<e.length-2&&!(c<e[p+1]);p++);let d=Rn(e[p],e[p+1],c);return s[p](d)};return r?c=>l(Ot(e[0],e[a-1],c)):l}i();i();function R4(e,t){let r=e[e.length-1];for(let n=1;n<=t;n++){let o=Rn(0,t,n);e.push(be(r,1,o))}}function F4(e){let t=[0];return R4(t,e.length-1),t}i();function B4(e,t){return e.map(r=>r*t)}function SN(e,t){return e.map(()=>t||Fc).splice(0,e.length-1)}function uu({duration:e=300,keyframes:t,times:r,ease:n="easeInOut"}){let o=b4(n)?n.map(Im):Im(n),a={done:!1,value:t[0]},s=B4(r&&r.length===t.length?r:F4(t),e),u=A4(s,t,{ease:Array.isArray(o)?o:SN(t,o)});return{calculatedDuration:e,next:l=>(a.value=u(l),a.done=l>=e,a)}}i();function O4(e){let t=0,r=50,n=e.next(t);for(;!n.done&&t<2e4;)t+=r,n=e.next(t);return t>=2e4?1/0:t}i();var M4=e=>{let t=({timestamp:r})=>e(r);return{start:()=>pe.update(t,!0),stop:()=>It(t),now:()=>qe.isProcessing?qe.timestamp:lr.now()}};var DN={decay:Om,inertia:Om,tween:uu,keyframes:uu,spring:Rc},EN=e=>e/100,oi=class extends Sa{constructor({KeyframeResolver:t=go,...r}){super(r),this.holdTime=null,this.startTime=null,this.cancelTime=null,this.currentTime=0,this.playbackSpeed=1,this.pendingPlayState="running",this.state="idle",this.stop=()=>{if(this.resolver.cancel(),this.isStopped=!0,this.state==="idle")return;this.teardown();let{onStop:u}=this.options;u&&u()};let{name:n,motionValue:o,keyframes:a}=this.options,s=(u,l)=>this.onKeyframesResolved(u,l);n&&o&&o.owner?this.resolver=o.owner.resolveKeyframes(a,s,n,o):this.resolver=new t(a,s,n,o),this.resolver.scheduleResolve()}initPlayback(t){let{type:r="keyframes",repeat:n=0,repeatDelay:o=0,repeatType:a,velocity:s=0}=this.options,u=DN[r]||uu,l,c;u!==uu&&typeof t[0]!="number"&&(l=Tt(EN,Vc(t[0],t[1])),t=[0,100]);let p=u({...this.options,keyframes:t});a==="mirror"&&(c=u({...this.options,keyframes:[...t].reverse(),velocity:-s})),p.calculatedDuration===null&&(p.calculatedDuration=O4(p));let{calculatedDuration:d}=p,h=d+o,g=h*(n+1)-o;return{generator:p,mirroredGenerator:c,mapPercentToKeyframes:l,calculatedDuration:d,resolvedDuration:h,totalDuration:g}}onPostResolved(){let{autoplay:t=!0}=this.options;this.play(),this.pendingPlayState==="paused"||!t?this.pause():this.state=this.pendingPlayState}tick(t,r=!1){let{resolved:n}=this;if(!n){let{keyframes:R}=this.options;return{done:!0,value:R[R.length-1]}}let{finalKeyframe:o,generator:a,mirroredGenerator:s,mapPercentToKeyframes:u,keyframes:l,calculatedDuration:c,totalDuration:p,resolvedDuration:d}=n;if(this.startTime===null)return a.next(0);let{delay:h,repeat:g,repeatType:v,repeatDelay:m,onUpdate:b}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-p/this.speed,this.startTime)),r?this.currentTime=t:this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=Math.round(t-this.startTime)*this.speed;let y=this.currentTime-h*(this.speed>=0?1:-1),x=this.speed>=0?y<0:y>p;this.currentTime=Math.max(y,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=p);let w=this.currentTime,S=a;if(g){let R=Math.min(this.currentTime,p)/d,F=Math.floor(R),M=R%1;!M&&R>=1&&(M=1),M===1&&F--,F=Math.min(F,g+1),!!(F%2)&&(v==="reverse"?(M=1-M,m&&(M-=m/d)):v==="mirror"&&(S=s)),w=Ot(0,1,M)*d}let E=x?{done:!1,value:l[0]}:S.next(w);u&&(E.value=u(E.value));let{done:D}=E;!x&&c!==null&&(D=this.speed>=0?this.currentTime>=p:this.currentTime<=0);let P=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&D);return P&&o!==void 0&&(E.value=ho(l,this.options,o)),b&&b(E.value),P&&this.finish(),E}get duration(){let{resolved:t}=this;return t?Kt(t.calculatedDuration):0}get time(){return Kt(this.currentTime)}set time(t){t=Ut(t),this.currentTime=t,this.holdTime!==null||this.speed===0?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.speed)}get speed(){return this.playbackSpeed}set speed(t){let r=this.playbackSpeed!==t;this.playbackSpeed=t,r&&(this.time=Kt(this.currentTime))}play(){if(this.resolver.isScheduled||this.resolver.resume(),!this._resolved){this.pendingPlayState="running";return}if(this.isStopped)return;let{driver:t=M4,onPlay:r}=this.options;this.driver||(this.driver=t(o=>this.tick(o))),r&&r();let n=this.driver.now();this.holdTime!==null?this.startTime=n-this.holdTime:(!this.startTime||this.state==="finished")&&(this.startTime=n),this.state==="finished"&&this.updateFinishedPromise(),this.cancelTime=this.startTime,this.holdTime=null,this.state="running",this.driver.start()}pause(){var t;if(!this._resolved){this.pendingPlayState="paused";return}this.state="paused",this.holdTime=(t=this.currentTime)!==null&&t!==void 0?t:0}complete(){this.state!=="running"&&this.play(),this.pendingPlayState=this.state="finished",this.holdTime=null}finish(){this.teardown(),this.state="finished";let{onComplete:t}=this.options;t&&t()}cancel(){this.cancelTime!==null&&this.tick(this.cancelTime),this.teardown(),this.updateFinishedPromise()}teardown(){this.state="idle",this.stopDriver(),this.resolveFinishedPromise(),this.updateFinishedPromise(),this.startTime=this.cancelTime=null,this.resolver.cancel()}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}};i();i();i();var Lm=e=>Array.isArray(e)&&typeof e[0]=="number";function $m(e){return!!(!e||typeof e=="string"&&e in zm||Lm(e)||Array.isArray(e)&&e.every($m))}var lu=([e,t,r,n])=>`cubic-bezier(${e}, ${t}, ${r}, ${n})`,zm={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:lu([0,.65,.55,1]),circOut:lu([.55,0,1,.45]),backIn:lu([.31,.01,.66,-.59]),backOut:lu([.33,1.53,.69,.99])};function PN(e){return Hm(e)||zm.easeOut}function Hm(e){if(e)return Lm(e)?lu(e):Array.isArray(e)?e.map(PN):zm[e]}function I4(e,t,r,{delay:n=0,duration:o=300,repeat:a=0,repeatType:s="loop",ease:u,times:l}={}){let c={[t]:r};l&&(c.offset=l);let p=Hm(u);return Array.isArray(p)&&(c.easing=p),e.animate(c,{delay:n,duration:o,easing:Array.isArray(p)?"linear":p,fill:"both",iterations:a+1,direction:s==="reverse"?"alternate":"normal"})}var TN=Ec(()=>Object.hasOwnProperty.call(Element.prototype,"animate")),Lc=10,AN=2e4;function RN(e){return e.type==="spring"||!$m(e.ease)}function FN(e,t){let r=new oi({...t,keyframes:e,repeat:0,delay:0,isGenerator:!0}),n={done:!1,value:e[0]},o=[],a=0;for(;!n.done&&a<AN;)n=r.sample(a),o.push(n.value),a+=Lc;return{times:void 0,keyframes:o,duration:a-Lc,ease:"linear"}}var cu=class extends Sa{constructor(t){super(t);let{name:r,motionValue:n,keyframes:o}=this.options;this.resolver=new wa(o,(a,s)=>this.onKeyframesResolved(a,s),r,n),this.resolver.scheduleResolve()}initPlayback(t,r){var n;let{duration:o=300,times:a,ease:s,type:u,motionValue:l,name:c}=this.options;if(!(!((n=l.owner)===null||n===void 0)&&n.current))return!1;if(RN(this.options)){let{onComplete:d,onUpdate:h,motionValue:g,...v}=this.options,m=FN(t,v);t=m.keyframes,t.length===1&&(t[1]=t[0]),o=m.duration,a=m.times,s=m.ease,u="keyframes"}let p=I4(l.owner.current,c,t,{...this.options,duration:o,times:a,ease:s});return p.startTime=lr.now(),this.pendingTimeline?(p.timeline=this.pendingTimeline,this.pendingTimeline=void 0):p.onfinish=()=>{let{onComplete:d}=this.options;l.set(ho(t,this.options,r)),d&&d(),this.cancel(),this.resolveFinishedPromise()},{animation:p,duration:o,times:a,type:u,ease:s,keyframes:t}}get duration(){let{resolved:t}=this;if(!t)return 0;let{duration:r}=t;return Kt(r)}get time(){let{resolved:t}=this;if(!t)return 0;let{animation:r}=t;return Kt(r.currentTime||0)}set time(t){let{resolved:r}=this;if(!r)return;let{animation:n}=r;n.currentTime=Ut(t)}get speed(){let{resolved:t}=this;if(!t)return 1;let{animation:r}=t;return r.playbackRate}set speed(t){let{resolved:r}=this;if(!r)return;let{animation:n}=r;n.playbackRate=t}get state(){let{resolved:t}=this;if(!t)return"idle";let{animation:r}=t;return r.playState}attachTimeline(t){if(!this._resolved)this.pendingTimeline=t;else{let{resolved:r}=this;if(!r)return Ae;let{animation:n}=r;n.timeline=t,n.onfinish=null}return Ae}play(){if(this.isStopped)return;let{resolved:t}=this;if(!t)return;let{animation:r}=t;r.playState==="finished"&&this.updateFinishedPromise(),r.play()}pause(){let{resolved:t}=this;if(!t)return;let{animation:r}=t;r.pause()}stop(){if(this.resolver.cancel(),this.isStopped=!0,this.state==="idle")return;this.resolveFinishedPromise(),this.updateFinishedPromise();let{resolved:t}=this;if(!t)return;let{animation:r,keyframes:n,duration:o,type:a,ease:s,times:u}=t;if(r.playState==="idle"||r.playState==="finished")return;if(this.time){let{motionValue:c,onUpdate:p,onComplete:d,...h}=this.options,g=new oi({...h,keyframes:n,duration:o,type:a,ease:s,times:u,isGenerator:!0}),v=Ut(this.time);c.setWithVelocity(g.sample(v-Lc).value,g.sample(v).value,Lc)}let{onStop:l}=this.options;l&&l(),this.cancel()}complete(){let{resolved:t}=this;t&&t.animation.finish()}cancel(){let{resolved:t}=this;t&&t.animation.cancel()}static supports(t){let{motionValue:r,name:n,repeatDelay:o,repeatType:a,damping:s,type:u}=t;return TN()&&n&&uc.has(n)&&r&&r.owner&&r.owner.current instanceof HTMLElement&&!r.owner.getProps().onUpdate&&!o&&a!=="mirror"&&s!==0&&u!=="inertia"}};i();i();function k4(e,t){let r,n=()=>{let{currentTime:o}=t,s=(o===null?0:o.value)/100;r!==s&&e(s),r=s};return pe.update(n,!0),()=>It(n)}i();var N4=Ec(()=>window.ScrollTimeline!==void 0);var $c=class{constructor(t){this.stop=()=>this.runAll("stop"),this.animations=t.filter(Boolean)}then(t,r){return Promise.all(this.animations).then(t).catch(r)}getAll(t){return this.animations[0][t]}setAll(t,r){for(let n=0;n<this.animations.length;n++)this.animations[n][t]=r}attachTimeline(t){let r=this.animations.map(n=>{if(N4()&&n.attachTimeline)n.attachTimeline(t);else return n.pause(),k4(o=>{n.time=n.duration*o},t)});return()=>{r.forEach((n,o)=>{n&&n(),this.animations[o].stop()})}}get time(){return this.getAll("time")}set time(t){this.setAll("time",t)}get speed(){return this.getAll("speed")}set speed(t){this.setAll("speed",t)}get duration(){let t=0;for(let r=0;r<this.animations.length;r++)t=Math.max(t,this.animations[r].duration);return t}runAll(t){this.animations.forEach(r=>r[t]())}play(){this.runAll("play")}pause(){this.runAll("pause")}cancel(){this.runAll("cancel")}complete(){this.runAll("complete")}};var Ea=(e,t,r,n={},o,a,s)=>u=>{let l=ba(n,e)||{},c=l.delay||n.delay||0,{elapsed:p=0}=n;p=p-Ut(c);let d={keyframes:Array.isArray(r)?r:[null,r],ease:"easeOut",velocity:t.getVelocity(),...l,delay:-p,onUpdate:g=>{t.set(g),l.onUpdate&&l.onUpdate(g)},onComplete:()=>{u(),l.onComplete&&l.onComplete(),s&&s()},onStop:s,name:e,motionValue:t,element:a?void 0:o};Yv(l)||(d={...d,...Xv(e,d)}),d.duration&&(d.duration=Ut(d.duration)),d.repeatDelay&&(d.repeatDelay=Ut(d.repeatDelay)),d.from!==void 0&&(d.keyframes[0]=d.from);let h=!1;if((d.type===!1||d.duration===0&&!d.repeatDelay)&&(d.duration=0,d.delay===0&&(h=!0)),(yc.current||Sn.skipAnimations)&&(h=!0,d.duration=0,d.delay=0),h&&!a&&t.get()!==void 0){let g=ho(d.keyframes,l);if(g!==void 0)return pe.update(()=>{d.onUpdate(g),d.onComplete()}),new $c([])}return!a&&cu.supports(d)?new cu(d):new oi(d)};i();i();i();var bo=class{constructor(){this.subscriptions=[]}add(t){return fo(this.subscriptions,t),()=>po(this.subscriptions,t)}notify(t,r,n){let o=this.subscriptions.length;if(o)if(o===1)this.subscriptions[0](t,r,n);else for(let a=0;a<o;a++){let s=this.subscriptions[a];s&&s(t,r,n)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}};var V4=30,BN=e=>!isNaN(parseFloat(e)),L4={current:void 0},fu=class{constructor(t,r={}){this.version="11.3.21",this.canTrackVelocity=null,this.events={},this.updateAndNotify=(n,o=!0)=>{let a=lr.now();this.updatedAt!==a&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(n),this.current!==this.prev&&this.events.change&&this.events.change.notify(this.current),o&&this.events.renderRequest&&this.events.renderRequest.notify(this.current)},this.hasAnimated=!1,this.setCurrent(t),this.owner=r.owner}setCurrent(t){this.current=t,this.updatedAt=lr.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=BN(this.current))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return this.on("change",t)}on(t,r){this.events[t]||(this.events[t]=new bo);let n=this.events[t].add(r);return t==="change"?()=>{n(),pe.read(()=>{this.events.change.getSize()||this.stop()})}:n}clearListeners(){for(let t in this.events)this.events[t].clear()}attach(t,r){this.passiveEffect=t,this.stopPassiveEffect=r}set(t,r=!0){!r||!this.passiveEffect?this.updateAndNotify(t,r):this.passiveEffect(t,this.updateAndNotify)}setWithVelocity(t,r,n){this.set(r),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-n}jump(t,r=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,r&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}get(){return L4.current&&L4.current.push(this),this.current}getPrevious(){return this.prev}getVelocity(){let t=lr.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>V4)return 0;let r=Math.min(this.updatedAt-this.prevUpdatedAt,V4);return Pc(parseFloat(this.current)-parseFloat(this.prevFrameValue),r)}start(t){return this.stop(),new Promise(r=>{this.hasAnimated=!0,this.animation=t(r),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}};function Fn(e,t){return new fu(e,t)}function ON(e,t,r){e.hasValue(t)?e.getValue(t).set(r):e.addValue(t,Fn(r))}function $4(e,t){let r=mo(e,t),{transitionEnd:n={},transition:o={},...a}=r||{};a={...a,...n};for(let s in a){let u=Nv(a[s]);ON(e,s,u)}}i();function zc(e){return e.getProps()[ql]}i();i();var Hc=class extends fu{constructor(){super(...arguments),this.output=[],this.counts=new Map}add(t){let r=lc(t);if(!r)return;let n=this.counts.get(r)||0;this.counts.set(r,n+1),n===0&&(this.output.push(r),this.update());let o=!1;return()=>{if(o)return;o=!0;let a=this.counts.get(r)-1;this.counts.set(r,a),a===0&&(po(this.output,r),this.update())}}update(){this.set(this.output.length?this.output.join(", "):"auto")}};i();function z4(e){return!!(Me(e)&&e.add)}function pu(e,t){var r;if(!e.applyWillChange)return;let n=e.getValue("willChange");if(!n&&!(!((r=e.props.style)===null||r===void 0)&&r.willChange)&&(n=new Hc("auto"),e.addValue("willChange",n)),z4(n))return n.add(t)}function MN({protectedKeys:e,needsAnimating:t},r){let n=e.hasOwnProperty(r)&&t[r]!==!0;return t[r]=!1,n}function Gc(e,t,{delay:r=0,transitionOverride:n,type:o}={}){var a;let{transition:s=e.getDefaultTransition(),transitionEnd:u,...l}=t;n&&(s=n);let c=[],p=o&&e.animationState&&e.animationState.getState()[o];for(let d in l){let h=e.getValue(d,(a=e.latestValues[d])!==null&&a!==void 0?a:null),g=l[d];if(g===void 0||p&&MN(p,d))continue;let v={delay:r,elapsed:0,...ba(s||{},d)},m=!1;if(window.HandoffAppearAnimations){let y=zc(e);if(y){let x=window.HandoffAppearAnimations(y,d,h,pe);x!==null&&(v.elapsed=x,m=!0)}}h.start(Ea(d,h,g,e.shouldReduceMotion&&Pt.has(d)?{type:!1}:v,e,m,pu(e,d)));let b=h.animation;b&&c.push(b)}return u&&Promise.all(c).then(()=>{pe.update(()=>{u&&$4(e,u)})}),c}i();function jc(e,t,r={}){var n;let o=mo(e,t,r.type==="exit"?(n=e.presenceContext)===null||n===void 0?void 0:n.custom:void 0),{transition:a=e.getDefaultTransition()||{}}=o||{};r.transitionOverride&&(a=r.transitionOverride);let s=o?()=>Promise.all(Gc(e,o,r)):()=>Promise.resolve(),u=e.variantChildren&&e.variantChildren.size?(c=0)=>{let{delayChildren:p=0,staggerChildren:d,staggerDirection:h}=a;return IN(e,t,p+c,d,h,r)}:()=>Promise.resolve(),{when:l}=a;if(l){let[c,p]=l==="beforeChildren"?[s,u]:[u,s];return c().then(()=>p())}else return Promise.all([s(),u(r.delay)])}function IN(e,t,r=0,n=0,o=1,a){let s=[],u=(e.variantChildren.size-1)*n,l=o===1?(c=0)=>c*n:(c=0)=>u-c*n;return Array.from(e.variantChildren).sort(kN).forEach((c,p)=>{c.notify("AnimationStart",t),s.push(jc(c,t,{...a,delay:r+l(p)}).then(()=>c.notify("AnimationComplete",t)))}),Promise.all(s)}function kN(e,t){return e.sortNodePosition(t)}function H4(e,t,r={}){e.notify("AnimationStart",t);let n;if(Array.isArray(t)){let o=t.map(a=>jc(e,a,r));n=Promise.all(o)}else if(typeof t=="string")n=jc(e,t,r);else{let o=typeof t=="function"?mo(e,t,r.custom):t;n=Promise.all(Gc(e,o,r))}return n.then(()=>{e.notify("AnimationComplete",t)})}var NN=[...Zl].reverse(),VN=Zl.length;function LN(e){return t=>Promise.all(t.map(({animation:r,options:n})=>H4(e,r,n)))}function j4(e){let t=LN(e),r=G4(),n=!0,o=l=>(c,p)=>{var d;let h=mo(e,p,l==="exit"?(d=e.presenceContext)===null||d===void 0?void 0:d.custom:void 0);if(h){let{transition:g,transitionEnd:v,...m}=h;c={...c,...m,...v}}return c};function a(l){t=l(e)}function s(l){let c=e.getProps(),p=e.getVariantContext(!0)||{},d=[],h=new Set,g={},v=1/0;for(let b=0;b<VN;b++){let y=NN[b],x=r[y],w=c[y]!==void 0?c[y]:p[y],S=En(w),E=y===l?x.isActive:null;E===!1&&(v=b);let D=w===p[y]&&w!==c[y]&&S;if(D&&n&&e.manuallyAnimateOnMount&&(D=!1),x.protectedKeys={...g},!x.isActive&&E===null||!w&&!x.prevProp||Pn(w)||typeof w=="boolean")continue;let R=$N(x.prevProp,w)||y===l&&x.isActive&&!D&&S||b>v&&S,F=!1,M=Array.isArray(w)?w:[w],G=M.reduce(o(y),{});E===!1&&(G={});let{prevResolvedValues:N={}}=x,L={...N,...G},I=V=>{R=!0,h.has(V)&&(F=!0,h.delete(V)),x.needsAnimating[V]=!0;let Y=e.getValue(V);Y&&(Y.liveStyle=!1)};for(let V in L){let Y=G[V],Q=N[V];if(g.hasOwnProperty(V))continue;let re=!1;ou(Y)&&ou(Q)?re=!wm(Y,Q):re=Y!==Q,re?Y!=null?I(V):h.add(V):Y!==void 0&&h.has(V)?I(V):x.protectedKeys[V]=!0}x.prevProp=w,x.prevResolvedValues=G,x.isActive&&(g={...g,...G}),n&&e.blockInitialAnimation&&(R=!1),R&&(!D||F)&&d.push(...M.map(V=>({animation:V,options:{type:y}})))}if(h.size){let b={};h.forEach(y=>{let x=e.getBaseTarget(y),w=e.getValue(y);w&&(w.liveStyle=!0),b[y]=x??null}),d.push({animation:b})}let m=!!d.length;return n&&(c.initial===!1||c.initial===c.animate)&&!e.manuallyAnimateOnMount&&(m=!1),n=!1,m?t(d):Promise.resolve()}function u(l,c){var p;if(r[l].isActive===c)return Promise.resolve();(p=e.variantChildren)===null||p===void 0||p.forEach(h=>{var g;return(g=h.animationState)===null||g===void 0?void 0:g.setActive(l,c)}),r[l].isActive=c;let d=s(l);for(let h in r)r[h].protectedKeys={};return d}return{animateChanges:s,setActive:u,setAnimateFunction:a,getState:()=>r,reset:()=>{r=G4(),n=!0}}}function $N(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!wm(t,e):!1}function ii(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function G4(){return{animate:ii(!0),whileInView:ii(),whileHover:ii(),whileTap:ii(),whileDrag:ii(),whileFocus:ii(),exit:ii()}}var _c=class extends ut{constructor(t){super(t),t.animationState||(t.animationState=j4(t))}updateAnimationControlsSubscription(){let{animate:t}=this.node.getProps();Pn(t)&&(this.unmountControls=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){let{animate:t}=this.node.getProps(),{animate:r}=this.node.prevProps||{};t!==r&&this.updateAnimationControlsSubscription()}unmount(){var t;this.node.animationState.reset(),(t=this.unmountControls)===null||t===void 0||t.call(this)}};i();var zN=0,Wc=class extends ut{constructor(){super(...arguments),this.id=zN++}update(){if(!this.node.presenceContext)return;let{isPresent:t,onExitComplete:r}=this.node.presenceContext,{isPresent:n}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===n)return;let o=this.node.animationState.setActive("exit",!t);r&&!t&&o.then(()=>r(this.id))}mount(){let{register:t}=this.node.presenceContext||{};t&&(this.unmount=t(this.id))}unmount(){}};var _4={animation:{Feature:_c},exit:{Feature:Wc}};i();i();i();i();i();var W4=(e,t)=>Math.abs(e-t);function U4(e,t){let r=W4(e.x,t.x),n=W4(e.y,t.y);return Math.sqrt(r**2+n**2)}var Pa=class{constructor(t,r,{transformPagePoint:n,contextWindow:o,dragSnapToOrigin:a=!1}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;let d=jm(this.lastMoveEventInfo,this.history),h=this.startEvent!==null,g=U4(d.offset,{x:0,y:0})>=3;if(!h&&!g)return;let{point:v}=d,{timestamp:m}=qe;this.history.push({...v,timestamp:m});let{onStart:b,onMove:y}=this.handlers;h||(b&&b(this.lastMoveEvent,d),this.startEvent=this.lastMoveEvent),y&&y(this.lastMoveEvent,d)},this.handlePointerMove=(d,h)=>{this.lastMoveEvent=d,this.lastMoveEventInfo=Gm(h,this.transformPagePoint),pe.update(this.updatePoint,!0)},this.handlePointerUp=(d,h)=>{this.end();let{onEnd:g,onSessionEnd:v,resumeAnimation:m}=this.handlers;if(this.dragSnapToOrigin&&m&&m(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;let b=jm(d.type==="pointercancel"?this.lastMoveEventInfo:Gm(h,this.transformPagePoint),this.history);this.startEvent&&g&&g(d,b),v&&v(d,b)},!pc(t))return;this.dragSnapToOrigin=a,this.handlers=r,this.transformPagePoint=n,this.contextWindow=o||window;let s=ei(t),u=Gm(s,this.transformPagePoint),{point:l}=u,{timestamp:c}=qe;this.history=[{...l,timestamp:c}];let{onSessionStart:p}=r;p&&p(t,jm(u,this.history)),this.removeListeners=Tt(Wt(this.contextWindow,"pointermove",this.handlePointerMove),Wt(this.contextWindow,"pointerup",this.handlePointerUp),Wt(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),It(this.updatePoint)}};function Gm(e,t){return t?{point:t(e.point)}:e}function K4(e,t){return{x:e.x-t.x,y:e.y-t.y}}function jm({point:e},t){return{point:e,delta:K4(e,q4(t)),offset:K4(e,HN(t)),velocity:GN(t,.1)}}function HN(e){return e[0]}function q4(e){return e[e.length-1]}function GN(e,t){if(e.length<2)return{x:0,y:0};let r=e.length-1,n=null,o=q4(e);for(;r>=0&&(n=e[r],!(o.timestamp-n.timestamp>Ut(t)));)r--;if(!n)return{x:0,y:0};let a=Kt(o.timestamp-n.timestamp);if(a===0)return{x:0,y:0};let s={x:(o.x-n.x)/a,y:(o.y-n.y)/a};return s.x===1/0&&(s.x=0),s.y===1/0&&(s.y=0),s}i();i();var Z4=1e-4,jN=1-Z4,_N=1+Z4,Q4=.01,WN=0-Q4,UN=0+Q4;function yt(e){return e.max-e.min}function e7(e,t,r){return Math.abs(e-t)<=r}function X4(e,t,r,n=.5){e.origin=n,e.originPoint=be(t.min,t.max,e.origin),e.scale=yt(r)/yt(t),e.translate=be(r.min,r.max,e.origin)-e.originPoint,(e.scale>=jN&&e.scale<=_N||isNaN(e.scale))&&(e.scale=1),(e.translate>=WN&&e.translate<=UN||isNaN(e.translate))&&(e.translate=0)}function Ta(e,t,r,n){X4(e.x,t.x,r.x,n?n.originX:void 0),X4(e.y,t.y,r.y,n?n.originY:void 0)}function Y4(e,t,r){e.min=r.min+t.min,e.max=e.min+yt(t)}function t7(e,t,r){Y4(e.x,t.x,r.x),Y4(e.y,t.y,r.y)}function J4(e,t,r){e.min=t.min-r.min,e.max=e.min+yt(t)}function Aa(e,t,r){J4(e.x,t.x,r.x),J4(e.y,t.y,r.y)}function a7(e,{min:t,max:r},n){return t!==void 0&&e<t?e=n?be(t,e,n.min):Math.max(e,t):r!==void 0&&e>r&&(e=n?be(r,e,n.max):Math.min(e,r)),e}function r7(e,t,r){return{min:t!==void 0?e.min+t:void 0,max:r!==void 0?e.max+r-(e.max-e.min):void 0}}function s7(e,{top:t,left:r,bottom:n,right:o}){return{x:r7(e.x,r,o),y:r7(e.y,t,n)}}function n7(e,t){let r=t.min-e.min,n=t.max-e.max;return t.max-t.min<e.max-e.min&&([r,n]=[n,r]),{min:r,max:n}}function u7(e,t){return{x:n7(e.x,t.x),y:n7(e.y,t.y)}}function l7(e,t){let r=.5,n=yt(e),o=yt(t);return o>n?r=Rn(t.min,t.max-n,e.min):n>o&&(r=Rn(e.min,e.max-o,t.min)),Ot(0,1,r)}function c7(e,t){let r={};return t.min!==void 0&&(r.min=t.min-e.min),t.max!==void 0&&(r.max=t.max-e.min),r}var Uc=.35;function f7(e=Uc){return e===!1?e=0:e===!0&&(e=Uc),{x:o7(e,"left","right"),y:o7(e,"top","bottom")}}function o7(e,t,r){return{min:i7(e,t),max:i7(e,r)}}function i7(e,t){return typeof e=="number"?e:e[t]||0}i();var p7=()=>({translate:0,scale:1,origin:0,originPoint:0}),ai=()=>({x:p7(),y:p7()}),d7=()=>({min:0,max:0}),Ve=()=>({x:d7(),y:d7()});i();function qt(e){return[e("x"),e("y")]}i();i();function Kc({top:e,left:t,right:r,bottom:n}){return{x:{min:t,max:r},y:{min:e,max:n}}}function m7({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function h7(e,t){if(!t)return e;let r=t({x:e.left,y:e.top}),n=t({x:e.right,y:e.bottom});return{top:r.y,left:r.x,bottom:n.y,right:n.x}}i();i();function _m(e){return e===void 0||e===1}function qc({scale:e,scaleX:t,scaleY:r}){return!_m(e)||!_m(t)||!_m(r)}function Bn(e){return qc(e)||Wm(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function Wm(e){return g7(e.x)||g7(e.y)}function g7(e){return e&&e!=="0%"}function du(e,t,r){let n=e-r,o=t*n;return r+o}function v7(e,t,r,n,o){return o!==void 0&&(e=du(e,o,n)),du(e,r,n)+t}function Um(e,t=0,r=1,n,o){e.min=v7(e.min,t,r,n,o),e.max=v7(e.max,t,r,n,o)}function Km(e,{x:t,y:r}){Um(e.x,t.translate,t.scale,t.originPoint),Um(e.y,r.translate,r.scale,r.originPoint)}var y7=.999999999999,b7=1.0000000000001;function x7(e,t,r,n=!1){let o=r.length;if(!o)return;t.x=t.y=1;let a,s;for(let u=0;u<o;u++){a=r[u],s=a.projectionDelta;let{visualElement:l}=a.options;l&&l.props.style&&l.props.style.display==="contents"||(n&&a.options.layoutScroll&&a.scroll&&a!==a.root&&si(e,{x:-a.scroll.offset.x,y:-a.scroll.offset.y}),s&&(t.x*=s.x.scale,t.y*=s.y.scale,Km(e,s)),n&&Bn(a.latestValues)&&si(e,a.latestValues))}t.x<b7&&t.x>y7&&(t.x=1),t.y<b7&&t.y>y7&&(t.y=1)}function Co(e,t){e.min=e.min+t,e.max=e.max+t}function C7(e,t,r,n,o=.5){let a=be(e.min,e.max,o);Um(e,t,r,a,n)}function si(e,t){C7(e.x,t.x,t.scaleX,t.scale,t.originX),C7(e.y,t.y,t.scaleY,t.scale,t.originY)}function qm(e,t){return Kc(h7(e.getBoundingClientRect(),t))}function w7(e,t,r){let n=qm(e,r),{scroll:o}=t;return o&&(Co(n.x,o.offset.x),Co(n.y,o.offset.y)),n}i();var Xc=({current:e})=>e?e.ownerDocument.defaultView:null;var KN=new WeakMap,Jc=class{constructor(t){this.openGlobalLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=Ve(),this.visualElement=t}start(t,{snapToCursor:r=!1}={}){let{presenceContext:n}=this.visualElement;if(n&&n.isPresent===!1)return;let o=p=>{let{dragSnapToOrigin:d}=this.getProps();d?this.pauseAnimation():this.stopAnimation(),r&&this.snapToCursor(ei(p,"page").point)},a=(p,d)=>{var h;let{drag:g,dragPropagation:v,onDragStart:m}=this.getProps();if(g&&!v&&(this.openGlobalLock&&this.openGlobalLock(),this.openGlobalLock=vm(g),!this.openGlobalLock))return;this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),qt(y=>{let x=this.getAxisMotionValue(y).get()||0;if(Mt.test(x)){let{projection:w}=this.visualElement;if(w&&w.layout){let S=w.layout.layoutBox[y];S&&(x=yt(S)*(parseFloat(x)/100))}}this.originPoint[y]=x}),m&&pe.postRender(()=>m(p,d)),(h=this.removeWillChange)===null||h===void 0||h.call(this),this.removeWillChange=pu(this.visualElement,"transform");let{animationState:b}=this.visualElement;b&&b.setActive("whileDrag",!0)},s=(p,d)=>{let{dragPropagation:h,dragDirectionLock:g,onDirectionLock:v,onDrag:m}=this.getProps();if(!h&&!this.openGlobalLock)return;let{offset:b}=d;if(g&&this.currentDirection===null){this.currentDirection=qN(b),this.currentDirection!==null&&v&&v(this.currentDirection);return}this.updateAxis("x",d.point,b),this.updateAxis("y",d.point,b),this.visualElement.render(),m&&m(p,d)},u=(p,d)=>this.stop(p,d),l=()=>qt(p=>{var d;return this.getAnimationState(p)==="paused"&&((d=this.getAxisMotionValue(p).animation)===null||d===void 0?void 0:d.play())}),{dragSnapToOrigin:c}=this.getProps();this.panSession=new Pa(t,{onSessionStart:o,onStart:a,onMove:s,onSessionEnd:u,resumeAnimation:l},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:c,contextWindow:Xc(this.visualElement)})}stop(t,r){var n;(n=this.removeWillChange)===null||n===void 0||n.call(this);let o=this.isDragging;if(this.cancel(),!o)return;let{velocity:a}=r;this.startAnimation(a);let{onDragEnd:s}=this.getProps();s&&pe.postRender(()=>s(t,r))}cancel(){this.isDragging=!1;let{projection:t,animationState:r}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;let{dragPropagation:n}=this.getProps();!n&&this.openGlobalLock&&(this.openGlobalLock(),this.openGlobalLock=null),r&&r.setActive("whileDrag",!1)}updateAxis(t,r,n){let{drag:o}=this.getProps();if(!n||!Yc(t,o,this.currentDirection))return;let a=this.getAxisMotionValue(t),s=this.originPoint[t]+n[t];this.constraints&&this.constraints[t]&&(s=a7(s,this.constraints[t],this.elastic[t])),a.set(s)}resolveConstraints(){var t;let{dragConstraints:r,dragElastic:n}=this.getProps(),o=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):(t=this.visualElement.projection)===null||t===void 0?void 0:t.layout,a=this.constraints;r&&Dn(r)?this.constraints||(this.constraints=this.resolveRefConstraints()):r&&o?this.constraints=s7(o.layoutBox,r):this.constraints=!1,this.elastic=f7(n),a!==this.constraints&&o&&this.constraints&&!this.hasMutatedConstraints&&qt(s=>{this.constraints!==!1&&this.getAxisMotionValue(s)&&(this.constraints[s]=c7(o.layoutBox[s],this.constraints[s]))})}resolveRefConstraints(){let{dragConstraints:t,onMeasureDragConstraints:r}=this.getProps();if(!t||!Dn(t))return!1;let n=t.current;Vr(n!==null,"If `dragConstraints` is set as a React ref, that ref must be passed to another component's `ref` prop.");let{projection:o}=this.visualElement;if(!o||!o.layout)return!1;let a=w7(n,o.root,this.visualElement.getTransformPagePoint()),s=u7(o.layout.layoutBox,a);if(r){let u=r(m7(s));this.hasMutatedConstraints=!!u,u&&(s=Kc(u))}return s}startAnimation(t){let{drag:r,dragMomentum:n,dragElastic:o,dragTransition:a,dragSnapToOrigin:s,onDragTransitionEnd:u}=this.getProps(),l=this.constraints||{},c=qt(p=>{if(!Yc(p,r,this.currentDirection))return;let d=l&&l[p]||{};s&&(d={min:0,max:0});let h=o?200:1e6,g=o?40:1e7,v={type:"inertia",velocity:n?t[p]:0,bounceStiffness:h,bounceDamping:g,timeConstant:750,restDelta:1,restSpeed:10,...a,...d};return this.startAxisValueAnimation(p,v)});return Promise.all(c).then(u)}startAxisValueAnimation(t,r){let n=this.getAxisMotionValue(t);return n.start(Ea(t,n,0,r,this.visualElement,!1,pu(this.visualElement,t)))}stopAnimation(){qt(t=>this.getAxisMotionValue(t).stop())}pauseAnimation(){qt(t=>{var r;return(r=this.getAxisMotionValue(t).animation)===null||r===void 0?void 0:r.pause()})}getAnimationState(t){var r;return(r=this.getAxisMotionValue(t).animation)===null||r===void 0?void 0:r.state}getAxisMotionValue(t){let r=`_drag${t.toUpperCase()}`,n=this.visualElement.getProps(),o=n[r];return o||this.visualElement.getValue(t,(n.initial?n.initial[t]:void 0)||0)}snapToCursor(t){qt(r=>{let{drag:n}=this.getProps();if(!Yc(r,n,this.currentDirection))return;let{projection:o}=this.visualElement,a=this.getAxisMotionValue(r);if(o&&o.layout){let{min:s,max:u}=o.layout.layoutBox[r];a.set(t[r]-be(s,u,.5))}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;let{drag:t,dragConstraints:r}=this.getProps(),{projection:n}=this.visualElement;if(!Dn(r)||!n||!this.constraints)return;this.stopAnimation();let o={x:0,y:0};qt(s=>{let u=this.getAxisMotionValue(s);if(u&&this.constraints!==!1){let l=u.get();o[s]=l7({min:l,max:l},this.constraints[s])}});let{transformTemplate:a}=this.visualElement.getProps();this.visualElement.current.style.transform=a?a({},""):"none",n.root&&n.root.updateScroll(),n.updateLayout(),this.resolveConstraints(),qt(s=>{if(!Yc(s,t,null))return;let u=this.getAxisMotionValue(s),{min:l,max:c}=this.constraints[s];u.set(be(l,c,o[s]))})}addListeners(){if(!this.visualElement.current)return;KN.set(this.visualElement,this);let t=this.visualElement.current,r=Wt(t,"pointerdown",l=>{let{drag:c,dragListener:p=!0}=this.getProps();c&&p&&this.start(l)}),n=()=>{let{dragConstraints:l}=this.getProps();Dn(l)&&l.current&&(this.constraints=this.resolveRefConstraints())},{projection:o}=this.visualElement,a=o.addEventListener("measure",n);o&&!o.layout&&(o.root&&o.root.updateScroll(),o.updateLayout()),pe.read(n);let s=_t(window,"resize",()=>this.scalePositionWithinConstraints()),u=o.addEventListener("didUpdate",({delta:l,hasLayoutChanged:c})=>{this.isDragging&&c&&(qt(p=>{let d=this.getAxisMotionValue(p);d&&(this.originPoint[p]+=l[p].translate,d.set(d.get()+l[p].translate))}),this.visualElement.render())});return()=>{s(),r(),a(),u&&u()}}getProps(){let t=this.visualElement.getProps(),{drag:r=!1,dragDirectionLock:n=!1,dragPropagation:o=!1,dragConstraints:a=!1,dragElastic:s=Uc,dragMomentum:u=!0}=t;return{...t,drag:r,dragDirectionLock:n,dragPropagation:o,dragConstraints:a,dragElastic:s,dragMomentum:u}}};function Yc(e,t,r){return(t===!0||t===e)&&(r===null||r===e)}function qN(e,t=10){let r=null;return Math.abs(e.y)>t?r="y":Math.abs(e.x)>t&&(r="x"),r}var Zc=class extends ut{constructor(t){super(t),this.removeGroupControls=Ae,this.removeListeners=Ae,this.controls=new Jc(t)}mount(){let{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||Ae}unmount(){this.removeGroupControls(),this.removeListeners()}};i();var S7=e=>(t,r)=>{e&&pe.postRender(()=>e(t,r))},Qc=class extends ut{constructor(){super(...arguments),this.removePointerDownListener=Ae}onPointerDown(t){this.session=new Pa(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:Xc(this.node)})}createPanHandlers(){let{onPanSessionStart:t,onPanStart:r,onPan:n,onPanEnd:o}=this.node.getProps();return{onSessionStart:S7(t),onStart:S7(r),onMove:n,onEnd:(a,s)=>{delete this.session,o&&pe.postRender(()=>o(a,s))}}}mount(){this.removePointerDownListener=Wt(this.node.current,"pointerdown",t=>this.onPointerDown(t))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}};i();import{jsx as QN}from"react/jsx-runtime";import{useContext as T7,Component as eV}from"react";i();import{useContext as XN,useId as YN,useEffect as JN,useCallback as ZN}from"react";function D7(){let e=XN(io);if(e===null)return[!0,null];let{isPresent:t,onExitComplete:r,register:n}=e,o=YN();JN(()=>n(o),[]);let a=ZN(()=>r&&r(o),[o,r]);return!t&&r?[!1,a]:[!0]}i();var Ra={hasAnimatedSinceResize:!0,hasEverUpdated:!1};i();function E7(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}var Fa={correct:(e,t)=>{if(!t.target)return e;if(typeof e=="string")if(ie.test(e))e=parseFloat(e);else return e;let r=E7(e,t.target.x),n=E7(e,t.target.y);return`${r}% ${n}%`}};i();var P7={correct:(e,{treeScale:t,projectionDelta:r})=>{let n=e,o=kt.parse(e);if(o.length>5)return n;let a=kt.createTransformer(e),s=typeof o[0]!="number"?1:0,u=r.x.scale*t.x,l=r.y.scale*t.y;o[0+s]/=u,o[1+s]/=l;let c=be(u,l,.5);return typeof o[2+s]=="number"&&(o[2+s]/=c),typeof o[3+s]=="number"&&(o[3+s]/=c),a(o)}};var Xm=class extends eV{componentDidMount(){let{visualElement:t,layoutGroup:r,switchLayoutGroup:n,layoutId:o}=this.props,{projection:a}=t;mv(tV),a&&(r.group&&r.group.add(a),n&&n.register&&o&&n.register(a),a.root.didUpdate(),a.addEventListener("animationComplete",()=>{this.safeToRemove()}),a.setOptions({...a.options,onExitComplete:()=>this.safeToRemove()})),Ra.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){let{layoutDependency:r,visualElement:n,drag:o,isPresent:a}=this.props,s=n.projection;return s&&(s.isPresent=a,o||t.layoutDependency!==r||r===void 0?s.willUpdate():this.safeToRemove(),t.isPresent!==a&&(a?s.promote():s.relegate()||pe.postRender(()=>{let u=s.getStack();(!u||!u.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){let{projection:t}=this.props.visualElement;t&&(t.root.didUpdate(),oa.postRender(()=>{!t.currentAnimation&&t.isLead()&&this.safeToRemove()}))}componentWillUnmount(){let{visualElement:t,layoutGroup:r,switchLayoutGroup:n}=this.props,{projection:o}=t;o&&(o.scheduleCheckAfterUnmount(),r&&r.group&&r.group.remove(o),n&&n.deregister&&n.deregister(o))}safeToRemove(){let{safeToRemove:t}=this.props;t&&t()}render(){return null}};function ef(e){let[t,r]=D7(),n=T7(ia);return QN(Xm,{...e,layoutGroup:n,switchLayoutGroup:T7(Jl),isPresent:t,safeToRemove:r})}var tV={borderRadius:{...Fa,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:Fa,borderTopRightRadius:Fa,borderBottomLeftRadius:Fa,borderBottomRightRadius:Fa,boxShadow:P7};i();i();i();var B7=["TopLeft","TopRight","BottomLeft","BottomRight"],rV=B7.length,A7=e=>typeof e=="string"?parseFloat(e):e,R7=e=>typeof e=="number"||ie.test(e);function O7(e,t,r,n,o,a){o?(e.opacity=be(0,r.opacity!==void 0?r.opacity:1,nV(n)),e.opacityExit=be(t.opacity!==void 0?t.opacity:1,0,oV(n))):a&&(e.opacity=be(t.opacity!==void 0?t.opacity:1,r.opacity!==void 0?r.opacity:1,n));for(let s=0;s<rV;s++){let u=`border${B7[s]}Radius`,l=F7(t,u),c=F7(r,u);if(l===void 0&&c===void 0)continue;l||(l=0),c||(c=0),l===0||c===0||R7(l)===R7(c)?(e[u]=Math.max(be(A7(l),A7(c),n),0),(Mt.test(c)||Mt.test(l))&&(e[u]+="%")):e[u]=c}(t.rotate||r.rotate)&&(e.rotate=be(t.rotate||0,r.rotate||0,n))}function F7(e,t){return e[t]!==void 0?e[t]:e.borderRadius}var nV=M7(0,.5,Ic),oV=M7(.5,.95,Ae);function M7(e,t,r){return n=>n<e?0:n>t?1:r(Rn(e,t,n))}i();function I7(e,t){e.min=t.min,e.max=t.max}function cr(e,t){I7(e.x,t.x),I7(e.y,t.y)}function Ym(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}i();function k7(e,t,r,n,o){return e-=t,e=du(e,1/r,n),o!==void 0&&(e=du(e,1/o,n)),e}function iV(e,t=0,r=1,n=.5,o,a=e,s=e){if(Mt.test(t)&&(t=parseFloat(t),t=be(s.min,s.max,t/100)-s.min),typeof t!="number")return;let u=be(a.min,a.max,n);e===a&&(u-=t),e.min=k7(e.min,t,r,u,o),e.max=k7(e.max,t,r,u,o)}function N7(e,t,[r,n,o],a,s){iV(e,t[r],t[n],t[o],t.scale,a,s)}var aV=["x","scaleX","originX"],sV=["y","scaleY","originY"];function Jm(e,t,r,n){N7(e.x,t,aV,r?r.x:void 0,n?n.x:void 0),N7(e.y,t,sV,r?r.y:void 0,n?n.y:void 0)}i();function V7(e){return e.translate===0&&e.scale===1}function Zm(e){return V7(e.x)&&V7(e.y)}function L7(e,t){return e.min===t.min&&e.max===t.max}function z7(e,t){return L7(e.x,t.x)&&L7(e.y,t.y)}function $7(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function Qm(e,t){return $7(e.x,t.x)&&$7(e.y,t.y)}function e0(e){return yt(e.x)/yt(e.y)}function t0(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}i();var tf=class{constructor(){this.members=[]}add(t){fo(this.members,t),t.scheduleRender()}remove(t){if(po(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){let r=this.members[this.members.length-1];r&&this.promote(r)}}relegate(t){let r=this.members.findIndex(o=>t===o);if(r===0)return!1;let n;for(let o=r;o>=0;o--){let a=this.members[o];if(a.isPresent!==!1){n=a;break}}return n?(this.promote(n),!0):!1}promote(t,r){let n=this.lead;if(t!==n&&(this.prevLead=n,this.lead=t,t.show(),n)){n.instance&&n.scheduleRender(),t.scheduleRender(),t.resumeFrom=n,r&&(t.resumeFrom.preserveOpacity=!0),n.snapshot&&(t.snapshot=n.snapshot,t.snapshot.latestValues=n.animationValues||n.latestValues),t.root&&t.root.isUpdating&&(t.isLayoutDirty=!0);let{crossfade:o}=t.options;o===!1&&n.hide()}}exitAnimationComplete(){this.members.forEach(t=>{let{options:r,resumingFrom:n}=t;r.onExitComplete&&r.onExitComplete(),n&&n.options.onExitComplete&&n.options.onExitComplete()})}scheduleRender(){this.members.forEach(t=>{t.instance&&t.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}};i();function H7(e,t,r){let n="",o=e.x.translate/t.x,a=e.y.translate/t.y,s=r?.z||0;if((o||a||s)&&(n=`translate3d(${o}px, ${a}px, ${s}px) `),(t.x!==1||t.y!==1)&&(n+=`scale(${1/t.x}, ${1/t.y}) `),r){let{transformPerspective:c,rotate:p,rotateX:d,rotateY:h,skewX:g,skewY:v}=r;c&&(n=`perspective(${c}px) ${n}`),p&&(n+=`rotate(${p}deg) `),d&&(n+=`rotateX(${d}deg) `),h&&(n+=`rotateY(${h}deg) `),g&&(n+=`skewX(${g}deg) `),v&&(n+=`skewY(${v}deg) `)}let u=e.x.scale*t.x,l=e.y.scale*t.y;return(u!==1||l!==1)&&(n+=`scale(${u}, ${l})`),n||"none"}i();i();var G7=(e,t)=>e.depth-t.depth;var rf=class{constructor(){this.children=[],this.isDirty=!1}add(t){fo(this.children,t),this.isDirty=!0}remove(t){po(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(G7),this.isDirty=!1,this.children.forEach(t)}};i();function j7(e,t){let r=lr.now(),n=({timestamp:o})=>{let a=o-r;a>=t&&(It(n),e(a-t))};return pe.read(n,!0),()=>It(n)}i();function _7(e){return e instanceof SVGElement&&e.tagName!=="svg"}i();function W7(e,t,r){let n=Me(e)?e:Fn(e);return n.start(Ea("",n,t,r)),n.animation}var ui={type:"projectionFrame",totalNodes:0,resolvedTargetDeltas:0,recalculatedProjection:0},mu=typeof window<"u"&&window.MotionDebug!==void 0,r0=["","X","Y","Z"],uV={visibility:"hidden"},U7=1e3,lV=0;function n0(e,t,r,n){let{latestValues:o}=t;o[e]&&(r[e]=o[e],t.setStaticValue(e,0),n&&(n[e]=0))}function e6(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return!1;let{visualElement:t}=e.options;return t?zc(t)?!0:e.parent&&!e.parent.hasCheckedOptimisedAppear?e6(e.parent):!1:!1}function nf({attachResizeListener:e,defaultParent:t,measureScroll:r,checkIsScrollRoot:n,resetTransform:o}){return class{constructor(s={},u=t?.()){this.id=lV++,this.animationId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,mu&&(ui.totalNodes=ui.resolvedTargetDeltas=ui.recalculatedProjection=0),this.nodes.forEach(pV),this.nodes.forEach(vV),this.nodes.forEach(yV),this.nodes.forEach(dV),mu&&window.MotionDebug.record(ui)},this.resolvedRelativeTargetAt=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=s,this.root=u?u.root||u:this,this.path=u?[...u.path,u]:[],this.parent=u,this.depth=u?u.depth+1:0;for(let l=0;l<this.path.length;l++)this.path[l].shouldResetTransform=!0;this.root===this&&(this.nodes=new rf)}addEventListener(s,u){return this.eventHandlers.has(s)||this.eventHandlers.set(s,new bo),this.eventHandlers.get(s).add(u)}notifyListeners(s,...u){let l=this.eventHandlers.get(s);l&&l.notify(...u)}hasListeners(s){return this.eventHandlers.has(s)}mount(s,u=this.root.hasTreeAnimated){if(this.instance)return;this.isSVG=_7(s),this.instance=s;let{layoutId:l,layout:c,visualElement:p}=this.options;if(p&&!p.current&&p.mount(s),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),u&&(c||l)&&(this.isLayoutDirty=!0),e){let d,h=()=>this.root.updateBlockedByResize=!1;e(s,()=>{this.root.updateBlockedByResize=!0,d&&d(),d=j7(h,250),Ra.hasAnimatedSinceResize&&(Ra.hasAnimatedSinceResize=!1,this.nodes.forEach(q7))})}l&&this.root.registerSharedNode(l,this),this.options.animate!==!1&&p&&(l||c)&&this.addEventListener("didUpdate",({delta:d,hasLayoutChanged:h,hasRelativeTargetChanged:g,layout:v})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}let m=this.options.transition||p.getDefaultTransition()||SV,{onLayoutAnimationStart:b,onLayoutAnimationComplete:y}=p.getProps(),x=!this.targetLayout||!Qm(this.targetLayout,v)||g,w=!h&&g;if(this.options.layoutRoot||this.resumeFrom&&this.resumeFrom.instance||w||h&&(x||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0),this.setAnimationOrigin(d,w);let S={...ba(m,"layout"),onPlay:b,onComplete:y};(p.shouldReduceMotion||this.options.layoutRoot)&&(S.delay=0,S.type=!1),this.startAnimation(S)}else h||q7(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=v})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);let s=this.getStack();s&&s.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,It(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(bV),this.animationId++)}getTransformTemplate(){let{visualElement:s}=this.options;return s&&s.getProps().transformTemplate}willUpdate(s=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.HandoffCancelAllAnimations&&e6(this)&&window.HandoffCancelAllAnimations(),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let p=0;p<this.path.length;p++){let d=this.path[p];d.shouldResetTransform=!0,d.updateScroll("snapshot"),d.options.layoutRoot&&d.willUpdate(!1)}let{layoutId:u,layout:l}=this.options;if(u===void 0&&!l)return;let c=this.getTransformTemplate();this.prevTransformTemplateValue=c?c(this.latestValues,""):void 0,this.updateSnapshot(),s&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){this.unblockUpdate(),this.clearAllSnapshots(),this.nodes.forEach(K7);return}this.isUpdating||this.nodes.forEach(hV),this.isUpdating=!1,this.nodes.forEach(gV),this.nodes.forEach(cV),this.nodes.forEach(fV),this.clearAllSnapshots();let u=lr.now();qe.delta=Ot(0,1e3/60,u-qe.timestamp),qe.timestamp=u,qe.isProcessing=!0,fc.update.process(qe),fc.preRender.process(qe),fc.render.process(qe),qe.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,oa.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(mV),this.sharedNodes.forEach(CV)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,pe.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){pe.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure())}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let l=0;l<this.path.length;l++)this.path[l].updateScroll();let s=this.layout;this.layout=this.measure(!1),this.layoutCorrected=Ve(),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);let{visualElement:u}=this.options;u&&u.notify("LayoutMeasure",this.layout.layoutBox,s?s.layoutBox:void 0)}updateScroll(s="measure"){let u=!!(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===s&&(u=!1),u){let l=n(this.instance);this.scroll={animationId:this.root.animationId,phase:s,isRoot:l,offset:r(this.instance),wasRoot:this.scroll?this.scroll.isRoot:l}}}resetTransform(){if(!o)return;let s=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,u=this.projectionDelta&&!Zm(this.projectionDelta),l=this.getTransformTemplate(),c=l?l(this.latestValues,""):void 0,p=c!==this.prevTransformTemplateValue;s&&(u||Bn(this.latestValues)||p)&&(o(this.instance,c),this.shouldResetTransform=!1,this.scheduleRender())}measure(s=!0){let u=this.measurePageBox(),l=this.removeElementScroll(u);return s&&(l=this.removeTransform(l)),DV(l),{animationId:this.root.animationId,measuredBox:u,layoutBox:l,latestValues:{},source:this.id}}measurePageBox(){var s;let{visualElement:u}=this.options;if(!u)return Ve();let l=u.measureViewportBox();if(!(((s=this.scroll)===null||s===void 0?void 0:s.wasRoot)||this.path.some(EV))){let{scroll:p}=this.root;p&&(Co(l.x,p.offset.x),Co(l.y,p.offset.y))}return l}removeElementScroll(s){var u;let l=Ve();if(cr(l,s),!((u=this.scroll)===null||u===void 0)&&u.wasRoot)return l;for(let c=0;c<this.path.length;c++){let p=this.path[c],{scroll:d,options:h}=p;p!==this.root&&d&&h.layoutScroll&&(d.wasRoot&&cr(l,s),Co(l.x,d.offset.x),Co(l.y,d.offset.y))}return l}applyTransform(s,u=!1){let l=Ve();cr(l,s);for(let c=0;c<this.path.length;c++){let p=this.path[c];!u&&p.options.layoutScroll&&p.scroll&&p!==p.root&&si(l,{x:-p.scroll.offset.x,y:-p.scroll.offset.y}),Bn(p.latestValues)&&si(l,p.latestValues)}return Bn(this.latestValues)&&si(l,this.latestValues),l}removeTransform(s){let u=Ve();cr(u,s);for(let l=0;l<this.path.length;l++){let c=this.path[l];if(!c.instance||!Bn(c.latestValues))continue;qc(c.latestValues)&&c.updateSnapshot();let p=Ve(),d=c.measurePageBox();cr(p,d),Jm(u,c.latestValues,c.snapshot?c.snapshot.layoutBox:void 0,p)}return Bn(this.latestValues)&&Jm(u,this.latestValues),u}setTargetDelta(s){this.targetDelta=s,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(s){this.options={...this.options,...s,crossfade:s.crossfade!==void 0?s.crossfade:!0}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==qe.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(s=!1){var u;let l=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=l.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=l.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=l.isSharedProjectionDirty);let c=!!this.resumingFrom||this!==l;if(!(s||c&&this.isSharedProjectionDirty||this.isProjectionDirty||!((u=this.parent)===null||u===void 0)&&u.isProjectionDirty||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;let{layout:d,layoutId:h}=this.options;if(!(!this.layout||!(d||h))){if(this.resolvedRelativeTargetAt=qe.timestamp,!this.targetDelta&&!this.relativeTarget){let g=this.getClosestProjectingParent();g&&g.layout&&this.animationProgress!==1?(this.relativeParent=g,this.forceRelativeParentToResolveTarget(),this.relativeTarget=Ve(),this.relativeTargetOrigin=Ve(),Aa(this.relativeTargetOrigin,this.layout.layoutBox,g.layout.layoutBox),cr(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}if(!(!this.relativeTarget&&!this.targetDelta)){if(this.target||(this.target=Ve(),this.targetWithTransforms=Ve()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),t7(this.target,this.relativeTarget,this.relativeParent.target)):this.targetDelta?(this.resumingFrom?this.target=this.applyTransform(this.layout.layoutBox):cr(this.target,this.layout.layoutBox),Km(this.target,this.targetDelta)):cr(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget){this.attemptToResolveRelativeTarget=!1;let g=this.getClosestProjectingParent();g&&!!g.resumingFrom==!!this.resumingFrom&&!g.options.layoutScroll&&g.target&&this.animationProgress!==1?(this.relativeParent=g,this.forceRelativeParentToResolveTarget(),this.relativeTarget=Ve(),this.relativeTargetOrigin=Ve(),Aa(this.relativeTargetOrigin,this.target,g.target),cr(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}mu&&ui.resolvedTargetDeltas++}}}getClosestProjectingParent(){if(!(!this.parent||qc(this.parent.latestValues)||Wm(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}calcProjection(){var s;let u=this.getLead(),l=!!this.resumingFrom||this!==u,c=!0;if((this.isProjectionDirty||!((s=this.parent)===null||s===void 0)&&s.isProjectionDirty)&&(c=!1),l&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(c=!1),this.resolvedRelativeTargetAt===qe.timestamp&&(c=!1),c)return;let{layout:p,layoutId:d}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(p||d))return;cr(this.layoutCorrected,this.layout.layoutBox);let h=this.treeScale.x,g=this.treeScale.y;x7(this.layoutCorrected,this.treeScale,this.path,l),u.layout&&!u.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(u.target=u.layout.layoutBox,u.targetWithTransforms=Ve());let{target:v}=u;if(!v){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}!this.projectionDelta||!this.prevProjectionDelta?this.createProjectionDeltas():(Ym(this.prevProjectionDelta.x,this.projectionDelta.x),Ym(this.prevProjectionDelta.y,this.projectionDelta.y)),Ta(this.projectionDelta,this.layoutCorrected,v,this.latestValues),(this.treeScale.x!==h||this.treeScale.y!==g||!t0(this.projectionDelta.x,this.prevProjectionDelta.x)||!t0(this.projectionDelta.y,this.prevProjectionDelta.y))&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",v)),mu&&ui.recalculatedProjection++}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(s=!0){var u;if((u=this.options.visualElement)===null||u===void 0||u.scheduleRender(),s){let l=this.getStack();l&&l.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=ai(),this.projectionDelta=ai(),this.projectionDeltaWithTransform=ai()}setAnimationOrigin(s,u=!1){let l=this.snapshot,c=l?l.latestValues:{},p={...this.latestValues},d=ai();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!u;let h=Ve(),g=l?l.source:void 0,v=this.layout?this.layout.source:void 0,m=g!==v,b=this.getStack(),y=!b||b.members.length<=1,x=!!(m&&!y&&this.options.crossfade===!0&&!this.path.some(wV));this.animationProgress=0;let w;this.mixTargetDelta=S=>{let E=S/1e3;X7(d.x,s.x,E),X7(d.y,s.y,E),this.setTargetDelta(d),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(Aa(h,this.layout.layoutBox,this.relativeParent.layout.layoutBox),xV(this.relativeTarget,this.relativeTargetOrigin,h,E),w&&z7(this.relativeTarget,w)&&(this.isProjectionDirty=!1),w||(w=Ve()),cr(w,this.relativeTarget)),m&&(this.animationValues=p,O7(p,c,this.latestValues,E,x,y)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=E},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(s){this.notifyListeners("animationStart"),this.currentAnimation&&this.currentAnimation.stop(),this.resumingFrom&&this.resumingFrom.currentAnimation&&this.resumingFrom.currentAnimation.stop(),this.pendingAnimation&&(It(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=pe.update(()=>{Ra.hasAnimatedSinceResize=!0,this.currentAnimation=W7(0,U7,{...s,onUpdate:u=>{this.mixTargetDelta(u),s.onUpdate&&s.onUpdate(u)},onComplete:()=>{s.onComplete&&s.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);let s=this.getStack();s&&s.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(U7),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){let s=this.getLead(),{targetWithTransforms:u,target:l,layout:c,latestValues:p}=s;if(!(!u||!l||!c)){if(this!==s&&this.layout&&c&&t6(this.options.animationType,this.layout.layoutBox,c.layoutBox)){l=this.target||Ve();let d=yt(this.layout.layoutBox.x);l.x.min=s.target.x.min,l.x.max=l.x.min+d;let h=yt(this.layout.layoutBox.y);l.y.min=s.target.y.min,l.y.max=l.y.min+h}cr(u,l),si(u,p),Ta(this.projectionDeltaWithTransform,this.layoutCorrected,u,p)}}registerSharedNode(s,u){this.sharedNodes.has(s)||this.sharedNodes.set(s,new tf),this.sharedNodes.get(s).add(u);let c=u.options.initialPromotionConfig;u.promote({transition:c?c.transition:void 0,preserveFollowOpacity:c&&c.shouldPreserveFollowOpacity?c.shouldPreserveFollowOpacity(u):void 0})}isLead(){let s=this.getStack();return s?s.lead===this:!0}getLead(){var s;let{layoutId:u}=this.options;return u?((s=this.getStack())===null||s===void 0?void 0:s.lead)||this:this}getPrevLead(){var s;let{layoutId:u}=this.options;return u?(s=this.getStack())===null||s===void 0?void 0:s.prevLead:void 0}getStack(){let{layoutId:s}=this.options;if(s)return this.root.sharedNodes.get(s)}promote({needsReset:s,transition:u,preserveFollowOpacity:l}={}){let c=this.getStack();c&&c.promote(this,l),s&&(this.projectionDelta=void 0,this.needsReset=!0),u&&this.setOptions({transition:u})}relegate(){let s=this.getStack();return s?s.relegate(this):!1}resetSkewAndRotation(){let{visualElement:s}=this.options;if(!s)return;let u=!1,{latestValues:l}=s;if((l.z||l.rotate||l.rotateX||l.rotateY||l.rotateZ||l.skewX||l.skewY)&&(u=!0),!u)return;let c={};l.z&&n0("z",s,c,this.animationValues);for(let p=0;p<r0.length;p++)n0(`rotate${r0[p]}`,s,c,this.animationValues),n0(`skew${r0[p]}`,s,c,this.animationValues);s.render();for(let p in c)s.setStaticValue(p,c[p]),this.animationValues&&(this.animationValues[p]=c[p]);s.scheduleRender()}getProjectionStyles(s){var u,l;if(!this.instance||this.isSVG)return;if(!this.isVisible)return uV;let c={visibility:""},p=this.getTransformTemplate();if(this.needsReset)return this.needsReset=!1,c.opacity="",c.pointerEvents=ya(s?.pointerEvents)||"",c.transform=p?p(this.latestValues,""):"none",c;let d=this.getLead();if(!this.projectionDelta||!this.layout||!d.target){let m={};return this.options.layoutId&&(m.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,m.pointerEvents=ya(s?.pointerEvents)||""),this.hasProjected&&!Bn(this.latestValues)&&(m.transform=p?p({},""):"none",this.hasProjected=!1),m}let h=d.animationValues||d.latestValues;this.applyTransformsToTarget(),c.transform=H7(this.projectionDeltaWithTransform,this.treeScale,h),p&&(c.transform=p(h,c.transform));let{x:g,y:v}=this.projectionDelta;c.transformOrigin=`${g.origin*100}% ${v.origin*100}% 0`,d.animationValues?c.opacity=d===this?(l=(u=h.opacity)!==null&&u!==void 0?u:this.latestValues.opacity)!==null&&l!==void 0?l:1:this.preserveOpacity?this.latestValues.opacity:h.opacityExit:c.opacity=d===this?h.opacity!==void 0?h.opacity:"":h.opacityExit!==void 0?h.opacityExit:0;for(let m in sa){if(h[m]===void 0)continue;let{correct:b,applyTo:y}=sa[m],x=c.transform==="none"?h[m]:b(h[m],d);if(y){let w=y.length;for(let S=0;S<w;S++)c[y[S]]=x}else c[m]=x}return this.options.layoutId&&(c.pointerEvents=d===this?ya(s?.pointerEvents)||"":"none"),c}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(s=>{var u;return(u=s.currentAnimation)===null||u===void 0?void 0:u.stop()}),this.root.nodes.forEach(K7),this.root.sharedNodes.clear()}}}function cV(e){e.updateLayout()}function fV(e){var t;let r=((t=e.resumeFrom)===null||t===void 0?void 0:t.snapshot)||e.snapshot;if(e.isLead()&&e.layout&&r&&e.hasListeners("didUpdate")){let{layoutBox:n,measuredBox:o}=e.layout,{animationType:a}=e.options,s=r.source!==e.layout.source;a==="size"?qt(d=>{let h=s?r.measuredBox[d]:r.layoutBox[d],g=yt(h);h.min=n[d].min,h.max=h.min+g}):t6(a,r.layoutBox,n)&&qt(d=>{let h=s?r.measuredBox[d]:r.layoutBox[d],g=yt(n[d]);h.max=h.min+g,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[d].max=e.relativeTarget[d].min+g)});let u=ai();Ta(u,n,r.layoutBox);let l=ai();s?Ta(l,e.applyTransform(o,!0),r.measuredBox):Ta(l,n,r.layoutBox);let c=!Zm(u),p=!1;if(!e.resumeFrom){let d=e.getClosestProjectingParent();if(d&&!d.resumeFrom){let{snapshot:h,layout:g}=d;if(h&&g){let v=Ve();Aa(v,r.layoutBox,h.layoutBox);let m=Ve();Aa(m,n,g.layoutBox),Qm(v,m)||(p=!0),d.options.layoutRoot&&(e.relativeTarget=m,e.relativeTargetOrigin=v,e.relativeParent=d)}}}e.notifyListeners("didUpdate",{layout:n,snapshot:r,delta:l,layoutDelta:u,hasLayoutChanged:c,hasRelativeTargetChanged:p})}else if(e.isLead()){let{onExitComplete:n}=e.options;n&&n()}e.options.transition=void 0}function pV(e){mu&&ui.totalNodes++,e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function dV(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function mV(e){e.clearSnapshot()}function K7(e){e.clearMeasurements()}function hV(e){e.isLayoutDirty=!1}function gV(e){let{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function q7(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function vV(e){e.resolveTargetDelta()}function yV(e){e.calcProjection()}function bV(e){e.resetSkewAndRotation()}function CV(e){e.removeLeadSnapshot()}function X7(e,t,r){e.translate=be(t.translate,0,r),e.scale=be(t.scale,1,r),e.origin=t.origin,e.originPoint=t.originPoint}function Y7(e,t,r,n){e.min=be(t.min,r.min,n),e.max=be(t.max,r.max,n)}function xV(e,t,r,n){Y7(e.x,t.x,r.x,n),Y7(e.y,t.y,r.y,n)}function wV(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}var SV={duration:.45,ease:[.4,0,.1,1]},J7=e=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),Z7=J7("applewebkit/")&&!J7("chrome/")?Math.round:Ae;function Q7(e){e.min=Z7(e.min),e.max=Z7(e.max)}function DV(e){Q7(e.x),Q7(e.y)}function t6(e,t,r){return e==="position"||e==="preserve-aspect"&&!e7(e0(t),e0(r),.2)}function EV(e){var t;return e!==e.root&&((t=e.scroll)===null||t===void 0?void 0:t.wasRoot)}i();var r6=nf({attachResizeListener:(e,t)=>_t(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0});var o0={current:void 0},of=nf({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!o0.current){let e=new r6({});e.mount(window),e.setOptions({layoutScroll:!0}),o0.current=e}return o0.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"});var n6={pan:{Feature:Qc},drag:{Feature:Zc,ProjectionNode:of,MeasureLayout:ef}};i();import{Fragment as RV}from"react";i();i();i();i();i();var hu={current:null},af={current:!1};function o6(){if(af.current=!0,!!na)if(window.matchMedia){let e=window.matchMedia("(prefers-reduced-motion)"),t=()=>hu.current=e.matches;e.addListener(t),t()}else hu.current=!1}i();function i6(e,t,r){for(let n in t){let o=t[n],a=r[n];if(Me(o))e.addValue(n,o);else if(Me(a))e.addValue(n,Fn(o,{owner:e}));else if(a!==o)if(e.hasValue(n)){let s=e.getValue(n);s.liveStyle===!0?s.jump(o):s.hasAnimated||s.set(o)}else{let s=e.getStaticValue(n);e.addValue(n,Fn(s!==void 0?s:o,{owner:e}))}}for(let n in r)t[n]===void 0&&e.removeValue(n);return t}i();var i0=new WeakMap;i();var PV=[...Em,Ze,kt],a6=e=>PV.find(wc(e));var s6=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"],TV=eu.length,sf=class{scrapeMotionValuesFromProps(t,r,n){return{}}constructor({parent:t,props:r,presenceContext:n,reducedMotionConfig:o,blockInitialAnimation:a,visualState:s},u={}){this.applyWillChange=!1,this.resolveKeyframes=(h,g,v,m)=>new this.KeyframeResolver(h,g,v,m,this),this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=go,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.isRenderScheduled=!1,this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.isRenderScheduled=!1,this.scheduleRender=()=>{this.isRenderScheduled||(this.isRenderScheduled=!0,pe.render(this.render,!1,!0))};let{latestValues:l,renderState:c}=s;this.latestValues=l,this.baseTarget={...l},this.initialValues=r.initial?{...l}:{},this.renderState=c,this.parent=t,this.props=r,this.presenceContext=n,this.depth=t?t.depth+1:0,this.reducedMotionConfig=o,this.options=u,this.blockInitialAnimation=!!a,this.isControllingVariants=Qo(r),this.isVariantNode=Ql(r),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(t&&t.current);let{willChange:p,...d}=this.scrapeMotionValuesFromProps(r,{},this);for(let h in d){let g=d[h];l[h]!==void 0&&Me(g)&&g.set(l[h],!1)}}mount(t){this.current=t,i0.set(t,this),this.projection&&!this.projection.instance&&this.projection.mount(t),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((r,n)=>this.bindToMotionValue(n,r)),af.current||o6(),this.shouldReduceMotion=this.reducedMotionConfig==="never"?!1:this.reducedMotionConfig==="always"?!0:hu.current,this.parent&&this.parent.children.add(this),this.update(this.props,this.presenceContext)}unmount(){i0.delete(this.current),this.projection&&this.projection.unmount(),It(this.notifyUpdate),It(this.render),this.valueSubscriptions.forEach(t=>t()),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent&&this.parent.children.delete(this);for(let t in this.events)this.events[t].clear();for(let t in this.features){let r=this.features[t];r&&(r.unmount(),r.isMounted=!1)}this.current=null}bindToMotionValue(t,r){let n=Pt.has(t),o=r.on("change",s=>{this.latestValues[t]=s,this.props.onUpdate&&pe.preRender(this.notifyUpdate),n&&this.projection&&(this.projection.isTransformDirty=!0)}),a=r.on("renderRequest",this.scheduleRender);this.valueSubscriptions.set(t,()=>{o(),a(),r.owner&&r.stop()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}updateFeatures(){let t="animation";for(t in Tn){let r=Tn[t];if(!r)continue;let{isEnabled:n,Feature:o}=r;if(!this.features[t]&&o&&n(this.props)&&(this.features[t]=new o(this)),this.features[t]){let a=this.features[t];a.isMounted?a.update():(a.mount(),a.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):Ve()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,r){this.latestValues[t]=r}update(t,r){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=r;for(let n=0;n<s6.length;n++){let o=s6[n];this.propEventSubscriptions[o]&&(this.propEventSubscriptions[o](),delete this.propEventSubscriptions[o]);let a="on"+o,s=t[a];s&&(this.propEventSubscriptions[o]=this.on(o,s))}this.prevMotionValues=i6(this,this.scrapeMotionValuesFromProps(t,this.prevProps,this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(t){return this.props.variants?this.props.variants[t]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}getVariantContext(t=!1){if(t)return this.parent?this.parent.getVariantContext():void 0;if(!this.isControllingVariants){let n=this.parent?this.parent.getVariantContext()||{}:{};return this.props.initial!==void 0&&(n.initial=this.props.initial),n}let r={};for(let n=0;n<TV;n++){let o=eu[n],a=this.props[o];(En(a)||a===!1)&&(r[o]=a)}return r}addVariantChild(t){let r=this.getClosestVariantNode();if(r)return r.variantChildren&&r.variantChildren.add(t),()=>r.variantChildren.delete(t)}addValue(t,r){let n=this.values.get(t);r!==n&&(n&&this.removeValue(t),this.bindToMotionValue(t,r),this.values.set(t,r),this.latestValues[t]=r.get())}removeValue(t){this.values.delete(t);let r=this.valueSubscriptions.get(t);r&&(r(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,r){if(this.props.values&&this.props.values[t])return this.props.values[t];let n=this.values.get(t);return n===void 0&&r!==void 0&&(n=Fn(r===null?void 0:r,{owner:this}),this.addValue(t,n)),n}readValue(t,r){var n;let o=this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:(n=this.getBaseTargetFromProps(this.props,t))!==null&&n!==void 0?n:this.readValueFromInstance(this.current,t,this.options);return o!=null&&(typeof o=="string"&&(xc(o)||Cc(o))?o=parseFloat(o):!a6(o)&&kt.test(r)&&(o=Dc(t,r)),this.setBaseTarget(t,Me(o)?o.get():o)),Me(o)?o.get():o}setBaseTarget(t,r){this.baseTarget[t]=r}getBaseTarget(t){var r;let{initial:n}=this.props,o;if(typeof n=="string"||typeof n=="object"){let s=ga(this.props,n,(r=this.presenceContext)===null||r===void 0?void 0:r.custom);s&&(o=s[t])}if(n&&o!==void 0)return o;let a=this.getBaseTargetFromProps(this.props,t);return a!==void 0&&!Me(a)?a:this.initialValues[t]!==void 0&&o===void 0?void 0:this.baseTarget[t]}on(t,r){return this.events[t]||(this.events[t]=new bo),this.events[t].add(r)}notify(t,...r){this.events[t]&&this.events[t].notify(...r)}};var Ba=class extends sf{constructor(){super(...arguments),this.KeyframeResolver=wa}sortInstanceNodePosition(t,r){return t.compareDocumentPosition(r)&2?1:-1}getBaseTargetFromProps(t,r){return t.style?t.style[r]:void 0}removeValueFromRenderState(t,{vars:r,style:n}){delete r[t],delete n[t]}};function AV(e){return window.getComputedStyle(e)}var uf=class extends Ba{constructor(){super(...arguments),this.type="html",this.applyWillChange=!0,this.renderInstance=oc}readValueFromInstance(t,r){if(Pt.has(r)){let n=xa(r);return n&&n.default||0}else{let n=AV(t),o=(rc(r)?n.getPropertyValue(r):n[r])||0;return typeof o=="string"?o.trim():o}}measureInstanceViewportBox(t,{transformPagePoint:r}){return qm(t,r)}build(t,r,n){fa(t,r,n.transformTemplate)}scrapeMotionValuesFromProps(t,r,n){return ha(t,r,n)}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);let{children:t}=this.props;Me(t)&&(this.childSubscription=t.on("change",r=>{this.current&&(this.current.textContent=`${r}`)}))}};i();var lf=class extends Ba{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=Ve}getBaseTargetFromProps(t,r){return t[r]}readValueFromInstance(t,r){if(Pt.has(r)){let n=xa(r);return n&&n.default||0}return r=ic.has(r)?r:ao(r),t.getAttribute(r)}scrapeMotionValuesFromProps(t,r,n){return sc(t,r,n)}build(t,r,n){da(t,r,this.isSVGTag,n.transformTemplate)}renderInstance(t,r,n,o){ac(t,r,n,o)}mount(t){this.isSVGTag=ma(t.tagName),super.mount(t)}};var u6=(e,t)=>aa(e)?new lf(t):new uf(t,{allowProjection:e!==RV});i();var l6={layout:{ProjectionNode:of,MeasureLayout:ef}};var FV={..._4,...qv,...n6,...l6},gu=pv((e,t)=>Hv(e,t,FV,u6));i();import{jsx as g6,Fragment as $V}from"react/jsx-runtime";import{useMemo as zV,useRef as v6,useState as y6,useContext as HV}from"react";i();import{jsx as p6}from"react/jsx-runtime";import*as m6 from"react";import{useId as kV,useMemo as d6}from"react";i();import{jsx as BV}from"react/jsx-runtime";import*as cf from"react";import{useId as OV,useRef as c6,useContext as MV,useInsertionEffect as IV}from"react";var a0=class extends cf.Component{getSnapshotBeforeUpdate(t){let r=this.props.childRef.current;if(r&&t.isPresent&&!this.props.isPresent){let n=this.props.sizeRef.current;n.height=r.offsetHeight||0,n.width=r.offsetWidth||0,n.top=r.offsetTop,n.left=r.offsetLeft}return null}componentDidUpdate(){}render(){return this.props.children}};function f6({children:e,isPresent:t}){let r=OV(),n=c6(null),o=c6({width:0,height:0,top:0,left:0}),{nonce:a}=MV(ra);return IV(()=>{let{width:s,height:u,top:l,left:c}=o.current;if(t||!n.current||!s||!u)return;n.current.dataset.motionPopId=r;let p=document.createElement("style");return a&&(p.nonce=a),document.head.appendChild(p),p.sheet&&p.sheet.insertRule(`
100
+ `},Hl=Object.keys(J1),Cr=(e=void 0)=>(0,C3.isNotNil)(e)?J1[e]:J1.defaultDarkOne;i();var xM=31,_le=e=>{let t=null;if(typeof e=="string"&&e)t=Array.from(e).reduce((n,o)=>Math.imul(xM,n)+o.charCodeAt(0)||0,0);else return Hl[0];let r=Math.abs(t)%Hl.length;return Hl[r]};i();i();i();i();function Et(){return Et=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Et.apply(this,arguments)}i();function Z1(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}i();i();function Cn(e,t){return Cn=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,o){return n.__proto__=o,n},Cn(e,t)}function Q1(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,Cn(e,t)}i();i();function _s(e){return _s=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},_s(e)}i();function em(e){try{return Function.toString.call(e).indexOf("[native code]")!==-1}catch{return typeof e=="function"}}i();i();function Gl(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(Gl=function(){return!!e})()}function tm(e,t,r){if(Gl())return Reflect.construct.apply(null,arguments);var n=[null];n.push.apply(n,t);var o=new(e.bind.apply(e,n));return r&&Cn(o,r.prototype),o}function Ws(e){var t=typeof Map=="function"?new Map:void 0;return Ws=function(n){if(n===null||!em(n))return n;if(typeof n!="function")throw new TypeError("Super expression must either be null or a function");if(typeof t<"u"){if(t.has(n))return t.get(n);t.set(n,o)}function o(){return tm(n,arguments,_s(this).constructor)}return o.prototype=Object.create(n.prototype,{constructor:{value:o,enumerable:!1,writable:!0,configurable:!0}}),Cn(o,n)},Ws(e)}i();var Gt=function(e){Q1(t,e);function t(r){var n;if(1)n=e.call(this,"An error occurred. See https://github.com/styled-components/polished/blob/main/src/internalHelpers/errors.md#"+r+" for more information.")||this;else for(var o,a,s;s<o;s++);return Z1(n)}return t}(Ws(Error));function x3(e,t){return e.substr(-t.length)===t}var wM=/^([+-]?(?:\d+|\d*\.\d+))([a-z]*|%)$/;function w3(e){if(typeof e!="string")return e;var t=e.match(wM);return t?parseFloat(e):e}var SM=function(t){return function(r,n){n===void 0&&(n="16px");var o=r,a=n;if(typeof r=="string"){if(!x3(r,"px"))throw new Gt(69,t,r);o=w3(r)}if(typeof n=="string"){if(!x3(n,"px"))throw new Gt(70,t,n);a=w3(n)}if(typeof o=="string")throw new Gt(71,r,t);if(typeof a=="string")throw new Gt(72,n,t);return""+o/a+t}},D3=SM,Pce=D3("em");var DM=/^([+-]?(?:\d+|\d*\.\d+))([a-z]*|%)$/;function E3(e){if(typeof e!="string")return[e,""];var t=e.match(DM);return t?[parseFloat(e),t[2]]:[e,void 0]}var Tce=D3("rem");function rm(e){return Math.round(e*255)}function EM(e,t,r){return rm(e)+","+rm(t)+","+rm(r)}function Us(e,t,r,n){if(n===void 0&&(n=EM),t===0)return n(r,r,r);var o=(e%360+360)%360/60,a=(1-Math.abs(2*r-1))*t,s=a*(1-Math.abs(o%2-1)),u=0,l=0,c=0;o>=0&&o<1?(u=a,l=s):o>=1&&o<2?(u=s,l=a):o>=2&&o<3?(l=a,c=s):o>=3&&o<4?(l=s,c=a):o>=4&&o<5?(u=s,c=a):o>=5&&o<6&&(u=a,c=s);var p=r-a/2,d=u+p,h=l+p,g=c+p;return n(d,h,g)}var S3={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"00ffff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"0000ff",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"00ffff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"ff00ff",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"639",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"};function PM(e){if(typeof e!="string")return e;var t=e.toLowerCase();return S3[t]?"#"+S3[t]:e}var TM=/^#[a-fA-F0-9]{6}$/,AM=/^#[a-fA-F0-9]{8}$/,RM=/^#[a-fA-F0-9]{3}$/,FM=/^#[a-fA-F0-9]{4}$/,nm=/^rgb\(\s*(\d{1,3})\s*(?:,)?\s*(\d{1,3})\s*(?:,)?\s*(\d{1,3})\s*\)$/i,BM=/^rgb(?:a)?\(\s*(\d{1,3})\s*(?:,)?\s*(\d{1,3})\s*(?:,)?\s*(\d{1,3})\s*(?:,|\/)\s*([-+]?\d*[.]?\d+[%]?)\s*\)$/i,OM=/^hsl\(\s*(\d{0,3}[.]?[0-9]+(?:deg)?)\s*(?:,)?\s*(\d{1,3}[.]?[0-9]?)%\s*(?:,)?\s*(\d{1,3}[.]?[0-9]?)%\s*\)$/i,MM=/^hsl(?:a)?\(\s*(\d{0,3}[.]?[0-9]+(?:deg)?)\s*(?:,)?\s*(\d{1,3}[.]?[0-9]?)%\s*(?:,)?\s*(\d{1,3}[.]?[0-9]?)%\s*(?:,|\/)\s*([-+]?\d*[.]?\d+[%]?)\s*\)$/i;function Zi(e){if(typeof e!="string")throw new Gt(3);var t=PM(e);if(t.match(TM))return{red:parseInt(""+t[1]+t[2],16),green:parseInt(""+t[3]+t[4],16),blue:parseInt(""+t[5]+t[6],16)};if(t.match(AM)){var r=parseFloat((parseInt(""+t[7]+t[8],16)/255).toFixed(2));return{red:parseInt(""+t[1]+t[2],16),green:parseInt(""+t[3]+t[4],16),blue:parseInt(""+t[5]+t[6],16),alpha:r}}if(t.match(RM))return{red:parseInt(""+t[1]+t[1],16),green:parseInt(""+t[2]+t[2],16),blue:parseInt(""+t[3]+t[3],16)};if(t.match(FM)){var n=parseFloat((parseInt(""+t[4]+t[4],16)/255).toFixed(2));return{red:parseInt(""+t[1]+t[1],16),green:parseInt(""+t[2]+t[2],16),blue:parseInt(""+t[3]+t[3],16),alpha:n}}var o=nm.exec(t);if(o)return{red:parseInt(""+o[1],10),green:parseInt(""+o[2],10),blue:parseInt(""+o[3],10)};var a=BM.exec(t.substring(0,50));if(a)return{red:parseInt(""+a[1],10),green:parseInt(""+a[2],10),blue:parseInt(""+a[3],10),alpha:parseFloat(""+a[4])>1?parseFloat(""+a[4])/100:parseFloat(""+a[4])};var s=OM.exec(t);if(s){var u=parseInt(""+s[1],10),l=parseInt(""+s[2],10)/100,c=parseInt(""+s[3],10)/100,p="rgb("+Us(u,l,c)+")",d=nm.exec(p);if(!d)throw new Gt(4,t,p);return{red:parseInt(""+d[1],10),green:parseInt(""+d[2],10),blue:parseInt(""+d[3],10)}}var h=MM.exec(t.substring(0,50));if(h){var g=parseInt(""+h[1],10),v=parseInt(""+h[2],10)/100,m=parseInt(""+h[3],10)/100,b="rgb("+Us(g,v,m)+")",y=nm.exec(b);if(!y)throw new Gt(4,t,b);return{red:parseInt(""+y[1],10),green:parseInt(""+y[2],10),blue:parseInt(""+y[3],10),alpha:parseFloat(""+h[4])>1?parseFloat(""+h[4])/100:parseFloat(""+h[4])}}throw new Gt(5)}function IM(e){var t=e.red/255,r=e.green/255,n=e.blue/255,o=Math.max(t,r,n),a=Math.min(t,r,n),s=(o+a)/2;if(o===a)return e.alpha!==void 0?{hue:0,saturation:0,lightness:s,alpha:e.alpha}:{hue:0,saturation:0,lightness:s};var u,l=o-a,c=s>.5?l/(2-o-a):l/(o+a);switch(o){case t:u=(r-n)/l+(r<n?6:0);break;case r:u=(n-t)/l+2;break;default:u=(t-r)/l+4;break}return u*=60,e.alpha!==void 0?{hue:u,saturation:c,lightness:s,alpha:e.alpha}:{hue:u,saturation:c,lightness:s}}function to(e){return IM(Zi(e))}var kM=function(t){return t.length===7&&t[1]===t[2]&&t[3]===t[4]&&t[5]===t[6]?"#"+t[1]+t[3]+t[5]:t},im=kM;function Zo(e){var t=e.toString(16);return t.length===1?"0"+t:t}function om(e){return Zo(Math.round(e*255))}function NM(e,t,r){return im("#"+om(e)+om(t)+om(r))}function jl(e,t,r){return Us(e,t,r,NM)}function VM(e,t,r){if(typeof e=="number"&&typeof t=="number"&&typeof r=="number")return jl(e,t,r);if(typeof e=="object"&&t===void 0&&r===void 0)return jl(e.hue,e.saturation,e.lightness);throw new Gt(1)}function LM(e,t,r,n){if(typeof e=="number"&&typeof t=="number"&&typeof r=="number"&&typeof n=="number")return n>=1?jl(e,t,r):"rgba("+Us(e,t,r)+","+n+")";if(typeof e=="object"&&t===void 0&&r===void 0&&n===void 0)return e.alpha>=1?jl(e.hue,e.saturation,e.lightness):"rgba("+Us(e.hue,e.saturation,e.lightness)+","+e.alpha+")";throw new Gt(2)}function am(e,t,r){if(typeof e=="number"&&typeof t=="number"&&typeof r=="number")return im("#"+Zo(e)+Zo(t)+Zo(r));if(typeof e=="object"&&t===void 0&&r===void 0)return im("#"+Zo(e.red)+Zo(e.green)+Zo(e.blue));throw new Gt(6)}function _l(e,t,r,n){if(typeof e=="string"&&typeof t=="number"){var o=Zi(e);return"rgba("+o.red+","+o.green+","+o.blue+","+t+")"}else{if(typeof e=="number"&&typeof t=="number"&&typeof r=="number"&&typeof n=="number")return n>=1?am(e,t,r):"rgba("+e+","+t+","+r+","+n+")";if(typeof e=="object"&&t===void 0&&r===void 0&&n===void 0)return e.alpha>=1?am(e.red,e.green,e.blue):"rgba("+e.red+","+e.green+","+e.blue+","+e.alpha+")"}throw new Gt(7)}var $M=function(t){return typeof t.red=="number"&&typeof t.green=="number"&&typeof t.blue=="number"&&(typeof t.alpha!="number"||typeof t.alpha>"u")},zM=function(t){return typeof t.red=="number"&&typeof t.green=="number"&&typeof t.blue=="number"&&typeof t.alpha=="number"},HM=function(t){return typeof t.hue=="number"&&typeof t.saturation=="number"&&typeof t.lightness=="number"&&(typeof t.alpha!="number"||typeof t.alpha>"u")},GM=function(t){return typeof t.hue=="number"&&typeof t.saturation=="number"&&typeof t.lightness=="number"&&typeof t.alpha=="number"};function ro(e){if(typeof e!="object")throw new Gt(8);if(zM(e))return _l(e);if($M(e))return am(e);if(GM(e))return LM(e);if(HM(e))return VM(e);throw new Gt(8)}function P3(e,t,r){return function(){var o=r.concat(Array.prototype.slice.call(arguments));return o.length>=t?e.apply(this,o):P3(e,t,o)}}function sr(e){return P3(e,e.length,[])}function jM(e,t){if(t==="transparent")return t;var r=to(t);return ro(Et({},r,{hue:r.hue+parseFloat(e)}))}var Ace=sr(jM);function Qi(e,t,r){return Math.max(e,Math.min(t,r))}function _M(e,t){if(t==="transparent")return t;var r=to(t);return ro(Et({},r,{lightness:Qi(0,1,r.lightness-parseFloat(e))}))}var WM=sr(_M),ot=WM;function UM(e,t){if(t==="transparent")return t;var r=to(t);return ro(Et({},r,{saturation:Qi(0,1,r.saturation-parseFloat(e))}))}var Rce=sr(UM);function KM(e,t){if(t==="transparent")return t;var r=to(t);return ro(Et({},r,{lightness:Qi(0,1,r.lightness+parseFloat(e))}))}var Fce=sr(KM);function qM(e,t,r){if(t==="transparent")return r;if(r==="transparent")return t;if(e===0)return r;var n=Zi(t),o=Et({},n,{alpha:typeof n.alpha=="number"?n.alpha:1}),a=Zi(r),s=Et({},a,{alpha:typeof a.alpha=="number"?a.alpha:1}),u=o.alpha-s.alpha,l=parseFloat(e)*2-1,c=l*u===-1?l:l+u,p=1+l*u,d=(c/p+1)/2,h=1-d,g={red:Math.floor(o.red*d+s.red*h),green:Math.floor(o.green*d+s.green*h),blue:Math.floor(o.blue*d+s.blue*h),alpha:o.alpha*parseFloat(e)+s.alpha*(1-parseFloat(e))};return _l(g)}var XM=sr(qM),T3=XM;function YM(e,t){if(t==="transparent")return t;var r=Zi(t),n=typeof r.alpha=="number"?r.alpha:1,o=Et({},r,{alpha:Qi(0,1,(n*100+parseFloat(e)*100)/100)});return _l(o)}var Bce=sr(YM);function JM(e,t){if(t==="transparent")return t;var r=to(t);return ro(Et({},r,{saturation:Qi(0,1,r.saturation+parseFloat(e))}))}var Oce=sr(JM);function ZM(e,t){return t==="transparent"?t:ro(Et({},to(t),{hue:parseFloat(e)}))}var Mce=sr(ZM);function QM(e,t){return t==="transparent"?t:ro(Et({},to(t),{lightness:parseFloat(e)}))}var Ice=sr(QM);function eI(e,t){return t==="transparent"?t:ro(Et({},to(t),{saturation:parseFloat(e)}))}var kce=sr(eI);function tI(e,t){return t==="transparent"?t:T3(parseFloat(e),"rgb(0, 0, 0)",t)}var Nce=sr(tI);function rI(e,t){return t==="transparent"?t:T3(parseFloat(e),"rgb(255, 255, 255)",t)}var Vce=sr(rI);function nI(e,t){if(t==="transparent")return t;var r=Zi(t),n=typeof r.alpha=="number"?r.alpha:1,o=Et({},r,{alpha:Qi(0,1,+(n*100-parseFloat(e)*100).toFixed(2)/100)});return _l(o)}var oI=sr(nI),jt=oI;var Ks=e=>{let[r,n]=E3(e);return`@media (max-width: ${Math.max(r-.0025,0)}${n})`},iI=({theme:e})=>`@media (min-width: ${e.breakpoint.xs})`,aI=({theme:e})=>`@media (min-width: ${e.breakpoint.sm})`,sI=({theme:e})=>`@media (min-width: ${e.breakpoint.md})`,uI=({theme:e})=>`@media (min-width: ${e.breakpoint.lg})`,lI=({theme:e})=>`@media (min-width: ${e.breakpoint.xl})`,cI=({theme:e})=>Ks(e.breakpoint.xs),fI=({theme:e})=>Ks(e.breakpoint.sm),pI=({theme:e})=>Ks(e.breakpoint.md),dI=({theme:e})=>Ks(e.breakpoint.lg),mI=({theme:e})=>Ks(e.breakpoint.xl),Ne={xsAndUp:iI,smAndUp:aI,mdAndUp:sI,lgAndUp:uI,xlAndUp:lI,xsAndDown:cI,smAndDown:fI,mdAndDown:pI,lgAndDown:dI,xlAndDown:mI};i();i();var xn=e=>e!=null&&(Object.getPrototypeOf(e)===null||e.constructor===Object);i();var sm=e=>(Object.freeze(e),Object.getOwnPropertyNames(e).forEach(t=>{Object.prototype.hasOwnProperty.call(e,t)&&(typeof e!="function"||t!=="caller"&&t!=="callee"&&t!=="arguments")&&e[t]!==null&&(typeof e[t]=="object"||typeof e[t]=="function")&&!Object.isFrozen(e[t])&&sm(e[t])}),e);i();var qs=(e,...t)=>{if(!t.length)return e;let r={...e};return t.forEach(n=>{xn(n)&&Object.keys(n).forEach(o=>{xn(n[o])?r[o]===null||r[o]===void 0?r[o]={...n[o]}:r[o]=qs(r[o],n[o]):r[o]=n[o]})}),r};i();var Wl=(e,t)=>t.reduce((r,n)=>(Object.prototype.hasOwnProperty.call(e,n)&&(r[n]=e[n]),r),{});var ife={isObject:xn,deepFreeze:sm,merge:qs,selectKeys:Wl};i();i();var A3=(e="")=>e.replace(/(?:^\w|[A-Z]|\b\w|\s+)/g,(t,r)=>+t==0?"":r===0?t.toLowerCase():t.toUpperCase());i();var wn=e=>e==="true"||e==="false"?e==="true":!!e;i();var ur=e=>e==null?"":String(e);i();i();var ea=e=>typeof e=="string"||e instanceof String;var R3=e=>{if(!ea(e))return!1;try{let t=new URL(e);return t.protocol==="http:"||t.protocol==="https:"}catch{return!1}};i();var no=e=>{let t=/^(?:\w+:)?\/\/(\S+)$/,r=/^localhost[:?\d]*(?:[^:?\d]\S*)?$/,n=/^[^\s.]+\.\S{2,}$/;if(!ea(e))return!1;let o=t.exec(e);if(!o)return!1;let a=o[1];return a===void 0||!a?!1:r.test(a)||n.test(a)};i();var F3=(e="")=>(e[0]?.toLowerCase()??"")+e.slice(1);i();var B3=e=>e.replace(/\n/g,"");i();var O3=e=>(e||"").replace(/\.[^/.]{1,4}$/,"");i();var M3=(e,t)=>e.length<=t?e:`${e.slice(0,t-3)}...`;i();var I3=(e="")=>(e[0]?.toUpperCase()??"")+e.slice(1);var jfe={camelCase:A3,coerceToBoolean:wn,coerceToString:ur,isHttpUrl:R3,isString:ea,isUrl:no,lowerFirst:F3,removeNewlines:B3,stripExtension:O3,truncate:M3,upperFirst:I3};i();i();i();import z3,{Component as EI}from"react";i();import Ys,{Component as bI}from"react";i();import hI from"react";var gI={border:0,clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",whiteSpace:"nowrap",padding:0,width:"1px",position:"absolute"},k3=function(t){var r=t.message,n=t["aria-live"];return hI.createElement("div",{style:gI,role:"log","aria-live":n},r||"")};k3.propTypes={};var Xs=k3;function vI(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function N3(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t&&(typeof t=="object"||typeof t=="function")?t:e}function yI(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var V3=function(e){yI(t,e);function t(){var r,n,o;vI(this,t);for(var a=arguments.length,s=Array(a),u=0;u<a;u++)s[u]=arguments[u];return o=(r=(n=N3(this,e.call.apply(e,[this].concat(s))),n),n.state={assertiveMessage1:"",assertiveMessage2:"",politeMessage1:"",politeMessage2:"",oldPolitemessage:"",oldPoliteMessageId:"",oldAssertiveMessage:"",oldAssertiveMessageId:"",setAlternatePolite:!1,setAlternateAssertive:!1},r),N3(n,o)}return t.getDerivedStateFromProps=function(n,o){var a=o.oldPolitemessage,s=o.oldPoliteMessageId,u=o.oldAssertiveMessage,l=o.oldAssertiveMessageId,c=n.politeMessage,p=n.politeMessageId,d=n.assertiveMessage,h=n.assertiveMessageId;return a!==c||s!==p?{politeMessage1:o.setAlternatePolite?"":c,politeMessage2:o.setAlternatePolite?c:"",oldPolitemessage:c,oldPoliteMessageId:p,setAlternatePolite:!o.setAlternatePolite}:u!==d||l!==h?{assertiveMessage1:o.setAlternateAssertive?"":d,assertiveMessage2:o.setAlternateAssertive?d:"",oldAssertiveMessage:d,oldAssertiveMessageId:h,setAlternateAssertive:!o.setAlternateAssertive}:null},t.prototype.render=function(){var n=this.state,o=n.assertiveMessage1,a=n.assertiveMessage2,s=n.politeMessage1,u=n.politeMessage2;return Ys.createElement("div",null,Ys.createElement(Xs,{"aria-live":"assertive",message:o}),Ys.createElement(Xs,{"aria-live":"assertive",message:a}),Ys.createElement(Xs,{"aria-live":"polite",message:s}),Ys.createElement(Xs,{"aria-live":"polite",message:u}))},t}(bI);V3.propTypes={};var L3=V3;i();import CI from"react";var xI=CI.createContext({announceAssertive:$3,announcePolite:$3});function $3(){console.warn("Announcement failed, LiveAnnouncer context is missing")}var ta=xI;function wI(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function SI(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t&&(typeof t=="object"||typeof t=="function")?t:e}function DI(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var PI=function(e){DI(t,e);function t(r){wI(this,t);var n=SI(this,e.call(this,r));return n.announcePolite=function(o,a){n.setState({announcePoliteMessage:o,politeMessageId:a||""})},n.announceAssertive=function(o,a){n.setState({announceAssertiveMessage:o,assertiveMessageId:a||""})},n.state={announcePoliteMessage:"",politeMessageId:"",announceAssertiveMessage:"",assertiveMessageId:"",updateFunctions:{announcePolite:n.announcePolite,announceAssertive:n.announceAssertive}},n}return t.prototype.render=function(){var n=this.state,o=n.announcePoliteMessage,a=n.politeMessageId,s=n.announceAssertiveMessage,u=n.assertiveMessageId,l=n.updateFunctions;return z3.createElement(ta.Provider,{value:l},this.props.children,z3.createElement(L3,{assertiveMessage:s,assertiveMessageId:u,politeMessage:o,politeMessageId:a}))},t}(EI),um=PI;i();import J3 from"react";i();var pm=U(K3());import{Component as MI}from"react";function BI(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function q3(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t&&(typeof t=="object"||typeof t=="function")?t:e}function OI(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var X3=function(e){OI(t,e);function t(){var r,n,o;BI(this,t);for(var a=arguments.length,s=Array(a),u=0;u<a;u++)s[u]=arguments[u];return o=(r=(n=q3(this,e.call.apply(e,[this].concat(s))),n),n.announce=function(){var l=n.props,c=l.message,p=l["aria-live"],d=l.announceAssertive,h=l.announcePolite;p==="assertive"&&d(c||"",(0,pm.default)()),p==="polite"&&h(c||"",(0,pm.default)())},r),q3(n,o)}return t.prototype.componentDidMount=function(){this.announce()},t.prototype.componentDidUpdate=function(n){var o=this.props.message;o!==n.message&&this.announce()},t.prototype.componentWillUnmount=function(){var n=this.props,o=n.clearOnUnmount,a=n.announceAssertive,s=n.announcePolite;(o===!0||o==="true")&&(a(""),s(""))},t.prototype.render=function(){return null},t}(MI);X3.propTypes={};var Y3=X3;var II=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Z3=function(t){return J3.createElement(ta.Consumer,null,function(r){return J3.createElement(Y3,II({},r,t))})};Z3.propTypes={};var Zs=Z3;i();import kI from"react";var NI=function(t){var r=t.children;return kI.createElement(ta.Consumer,null,function(n){return r(n)})};NI.propTypes={};i();i();i();import{jsxs as ek,jsx as tk}from"react/jsx-runtime";import{forwardRef as rk,useContext as dm}from"react";i();import{createContext as VI}from"react";var ra=VI({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"});i();import{createContext as LI}from"react";var oo=LI({});i();import{useContext as Qs,useRef as ev,useInsertionEffect as UI,useEffect as KI}from"react";i();import{createContext as $I}from"react";var io=$I(null);i();import{useLayoutEffect as zI,useEffect as HI}from"react";i();var na=typeof window<"u";var Ul=na?zI:HI;i();import{createContext as GI}from"react";var Kl=GI({strict:!1});i();i();var ao=e=>e.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase();var jI="framerAppearId",ql="data-"+ao(jI);i();i();i();var Sn={skipAnimations:!1,useManualTiming:!1};i();function Q3(e){let t=new Set,r=new Set,n=!1,o=!1,a=new WeakSet,s={delta:0,timestamp:0,isProcessing:!1};function u(c){a.has(c)&&(l.schedule(c),e()),c(s)}let l={schedule:(c,p=!1,d=!1)=>{let g=d&&n?t:r;return p&&a.add(c),g.has(c)||g.add(c),c},cancel:c=>{r.delete(c),a.delete(c)},process:c=>{if(s=c,n){o=!0;return}n=!0,[t,r]=[r,t],r.clear(),t.forEach(u),n=!1,o&&(o=!1,l.process(c))}};return l}var Xl=["read","resolveKeyframes","update","preRender","render","postRender"],_I=40;function Yl(e,t){let r=!1,n=!0,o={delta:0,timestamp:0,isProcessing:!1},a=()=>r=!0,s=Xl.reduce((y,x)=>(y[x]=Q3(a),y),{}),{read:u,resolveKeyframes:l,update:c,preRender:p,render:d,postRender:h}=s,g=()=>{let y=Sn.useManualTiming?o.timestamp:performance.now();r=!1,o.delta=n?1e3/60:Math.max(Math.min(y-o.timestamp,_I),1),o.timestamp=y,o.isProcessing=!0,u.process(o),l.process(o),c.process(o),p.process(o),d.process(o),h.process(o),o.isProcessing=!1,r&&t&&(n=!1,e(g))},v=()=>{r=!0,n=!0,o.isProcessing||e(g)};return{schedule:Xl.reduce((y,x)=>{let w=s[x];return y[x]=(S,E=!1,D=!1)=>(r||v(),w.schedule(S,E,D)),y},{}),cancel:y=>{for(let x=0;x<Xl.length;x++)s[Xl[x]].cancel(y)},state:o,steps:s}}var{schedule:oa,cancel:lde}=Yl(queueMicrotask,!1);i();function Dn(e){return e&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}i();import{createContext as WI}from"react";var Jl=WI({});var tv=!1;function rv(e,t,r,n,o){let{visualElement:a}=Qs(oo),s=Qs(Kl),u=Qs(io),l=Qs(ra).reducedMotion,c=ev();n=n||s.renderer,!c.current&&n&&(c.current=n(e,{visualState:t,parent:a,props:r,presenceContext:u,blockInitialAnimation:u?u.initial===!1:!1,reducedMotionConfig:l}));let p=c.current,d=Qs(Jl);p&&!p.projection&&o&&(p.type==="html"||p.type==="svg")&&XI(c.current,r,o,d),UI(()=>{p&&p.update(r,u)});let h=ev(!!(r[ql]&&!window.HandoffComplete));return Ul(()=>{p&&(p.updateFeatures(),oa.render(p.render),h.current&&p.animationState&&p.animationState.animateChanges())}),KI(()=>{p&&(!h.current&&p.animationState&&p.animationState.animateChanges(),h.current&&(h.current=!1,tv||(tv=!0,queueMicrotask(qI))))}),p}function qI(){window.HandoffComplete=!0}function XI(e,t,r,n){let{layoutId:o,layout:a,drag:s,dragConstraints:u,layoutScroll:l,layoutRoot:c}=t;e.projection=new r(e.latestValues,t["data-framer-portal-id"]?void 0:nv(e.parent)),e.projection.setOptions({layoutId:o,layout:a,alwaysMeasureLayout:!!s||u&&Dn(u),visualElement:e,animationType:typeof a=="string"?a:"both",initialPromotionConfig:n,layoutScroll:l,layoutRoot:c})}function nv(e){if(e)return e.options.allowProjection!==!1?e.projection:nv(e.parent)}i();import{useCallback as YI}from"react";function ov(e,t,r){return YI(n=>{n&&e.mount&&e.mount(n),t&&(n?t.mount(n):t.unmount()),r&&(typeof r=="function"?r(n):Dn(r)&&(r.current=n))},[t])}i();import{useContext as JI,useMemo as ZI}from"react";i();i();function En(e){return typeof e=="string"||Array.isArray(e)}i();i();function Pn(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}i();var Zl=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],eu=["initial",...Zl];function Qo(e){return Pn(e.animate)||eu.some(t=>En(e[t]))}function Ql(e){return!!(Qo(e)||e.variants)}function iv(e,t){if(Qo(e)){let{initial:r,animate:n}=e;return{initial:r===!1||En(r)?r:void 0,animate:En(n)?n:void 0}}return e.inherit!==!1?t:{}}function sv(e){let{initial:t,animate:r}=iv(e,JI(oo));return ZI(()=>({initial:t,animate:r}),[av(t),av(r)])}function av(e){return Array.isArray(e)?e.join(" "):e}i();i();var uv={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]},Tn={};for(let e in uv)Tn[e]={isEnabled:t=>uv[e].some(r=>!!t[r])};function lv(e){for(let t in e)Tn[t]={...Tn[t],...e[t]}}i();import{createContext as QI}from"react";var ia=QI({});i();var cv=Symbol.for("motionComponentSymbol");i();i();var Ae=e=>e;var so=Ae,Vr=Ae;function fv({preloadedFeatures:e,createVisualElement:t,useRender:r,useVisualState:n,Component:o}){e&&lv(e);function a(u,l){let c,p={...dm(ra),...u,layoutId:nk(u)},{isStatic:d}=p,h=sv(u),g=n(u,d);if(!d&&na){ok(p,e);let v=ik(p);c=v.MeasureLayout,h.visualElement=rv(o,g,p,t,v.ProjectionNode)}return ek(oo.Provider,{value:h,children:[c&&h.visualElement?tk(c,{visualElement:h.visualElement,...p}):null,r(o,u,ov(g,h.visualElement,l),g,d,h.visualElement)]})}let s=rk(a);return s[cv]=o,s}function nk({layoutId:e}){let t=dm(ia).id;return t&&e!==void 0?t+"-"+e:e}function ok(e,t){let r=dm(Kl).strict}function ik(e){let{drag:t,layout:r}=Tn;if(!t&&!r)return{};let n={...t,...r};return{MeasureLayout:t?.isEnabled(e)||r?.isEnabled(e)?n.MeasureLayout:void 0,ProjectionNode:n.ProjectionNode}}i();function pv(e){function t(n,o={}){return fv(e(n,o))}if(typeof Proxy>"u")return t;let r=new Map;return new Proxy(t,{get:(n,o)=>(r.has(o)||r.set(o,t(o)),r.get(o))})}i();i();i();var dv=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function aa(e){return typeof e!="string"||e.includes("-")?!1:!!(dv.indexOf(e)>-1||/[A-Z]/u.test(e))}i();import{Fragment as Ck,useMemo as xk,createElement as wk}from"react";i();import{useMemo as ck}from"react";i();i();var sa={};function mv(e){Object.assign(sa,e)}i();var uo=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],Pt=new Set(uo);function ec(e,{layout:t,layoutId:r}){return Pt.has(e)||e.startsWith("origin")||(t||r!==void 0)&&(!!sa[e]||e==="opacity")}i();var Me=e=>!!(e&&e.getVelocity);i();i();i();var tc=(e,t)=>t&&typeof e=="number"?t.transform(e):e;i();i();i();var Ot=(e,t,r)=>r>t?t:r<e?e:r;var Xr={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},lo={...Xr,transform:e=>Ot(0,1,e)},tu={...Xr,default:1};i();i();var co=e=>Math.round(e*1e5)/1e5,ua=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu,hv=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu,gv=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu;function An(e){return typeof e=="string"}function vv(e){return e==null}var ru=e=>({test:t=>An(t)&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),Yr=ru("deg"),Mt=ru("%"),ie=ru("px"),yv=ru("vh"),bv=ru("vw"),mm={...Mt,parse:e=>Mt.parse(e)/100,transform:e=>Mt.transform(e*100)};i();var hm={...Xr,transform:Math.round};var la={borderWidth:ie,borderTopWidth:ie,borderRightWidth:ie,borderBottomWidth:ie,borderLeftWidth:ie,borderRadius:ie,radius:ie,borderTopLeftRadius:ie,borderTopRightRadius:ie,borderBottomRightRadius:ie,borderBottomLeftRadius:ie,width:ie,maxWidth:ie,height:ie,maxHeight:ie,size:ie,top:ie,right:ie,bottom:ie,left:ie,padding:ie,paddingTop:ie,paddingRight:ie,paddingBottom:ie,paddingLeft:ie,margin:ie,marginTop:ie,marginRight:ie,marginBottom:ie,marginLeft:ie,rotate:Yr,rotateX:Yr,rotateY:Yr,rotateZ:Yr,scale:tu,scaleX:tu,scaleY:tu,scaleZ:tu,skew:Yr,skewX:Yr,skewY:Yr,distance:ie,translateX:ie,translateY:ie,translateZ:ie,x:ie,y:ie,z:ie,perspective:ie,transformPerspective:ie,opacity:lo,originX:mm,originY:mm,originZ:ie,zIndex:hm,backgroundPositionX:ie,backgroundPositionY:ie,fillOpacity:lo,strokeOpacity:lo,numOctaves:hm};var ak={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},sk=uo.length;function Cv(e,t,r){let n="",o=!0;for(let a=0;a<sk;a++){let s=uo[a],u=e[s];if(u===void 0)continue;let l=!0;if(typeof u=="number"?l=u===(s.startsWith("scale")?1:0):l=parseFloat(u)===0,!l||r){let c=tc(u,la[s]);if(!l){o=!1;let p=ak[s]||s;n+=`${p}(${c}) `}r&&(t[s]=c)}}return n=n.trim(),r?n=r(t,o?"":n):o&&(n="none"),n}i();var xv=e=>t=>typeof t=="string"&&t.startsWith(e),rc=xv("--"),uk=xv("var(--"),ca=e=>uk(e)?lk.test(e.split("/*")[0].trim()):!1,lk=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu;function fa(e,t,r){let{style:n,vars:o,transformOrigin:a}=e,s=!1,u=!1;for(let l in t){let c=t[l];if(Pt.has(l)){s=!0;continue}else if(rc(l)){o[l]=c;continue}else{let p=tc(c,la[l]);l.startsWith("origin")?(u=!0,a[l]=p):n[l]=p}}if(t.transform||(s||r?n.transform=Cv(t,e.transform,r):n.transform&&(n.transform="none")),u){let{originX:l="50%",originY:c="50%",originZ:p=0}=a;n.transformOrigin=`${l} ${c} ${p}`}}i();var pa=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function gm(e,t,r){for(let n in t)!Me(t[n])&&!ec(n,r)&&(e[n]=t[n])}function fk({transformTemplate:e},t){return ck(()=>{let r=pa();return fa(r,t,e),Object.assign({},r.vars,r.style)},[t])}function pk(e,t){let r=e.style||{},n={};return gm(n,r,e),Object.assign(n,fk(e,t)),n}function wv(e,t){let r={},n=pk(e,t);return e.drag&&e.dragListener!==!1&&(r.draggable=!1,n.userSelect=n.WebkitUserSelect=n.WebkitTouchCallout="none",n.touchAction=e.drag===!0?"none":`pan-${e.drag==="x"?"y":"x"}`),e.tabIndex===void 0&&(e.onTap||e.onTapStart||e.whileTap)&&(r.tabIndex=0),r.style=n,r}i();i();var dk=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function nu(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||dk.has(e)}var Tv=e=>!nu(e);function gk(e){e&&(Tv=t=>t.startsWith("on")?!nu(t):e(t))}try{gk((Pv(),WO(Ev)).default)}catch{}function Av(e,t,r){let n={};for(let o in e)o==="values"&&typeof e.values=="object"||(Tv(o)||r===!0&&nu(o)||!t&&!nu(o)||e.draggable&&o.startsWith("onDrag"))&&(n[o]=e[o]);return n}i();import{useMemo as bk}from"react";i();i();function Rv(e,t,r){return typeof e=="string"?e:ie.transform(t+r*e)}function Fv(e,t,r){let n=Rv(t,e.x,e.width),o=Rv(r,e.y,e.height);return`${n} ${o}`}i();var vk={offset:"stroke-dashoffset",array:"stroke-dasharray"},yk={offset:"strokeDashoffset",array:"strokeDasharray"};function Bv(e,t,r=1,n=0,o=!0){e.pathLength=1;let a=o?vk:yk;e[a.offset]=ie.transform(-n);let s=ie.transform(t),u=ie.transform(r);e[a.array]=`${s} ${u}`}function da(e,{attrX:t,attrY:r,attrScale:n,originX:o,originY:a,pathLength:s,pathSpacing:u=1,pathOffset:l=0,...c},p,d){if(fa(e,c,d),p){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};let{attrs:h,style:g,dimensions:v}=e;h.transform&&(v&&(g.transform=h.transform),delete h.transform),v&&(o!==void 0||a!==void 0||g.transform)&&(g.transformOrigin=Fv(v,o!==void 0?o:.5,a!==void 0?a:.5)),t!==void 0&&(h.x=t),r!==void 0&&(h.y=r),n!==void 0&&(h.scale=n),s!==void 0&&Bv(h,s,u,l,!1)}i();var nc=()=>({...pa(),attrs:{}});i();var ma=e=>typeof e=="string"&&e.toLowerCase()==="svg";function Ov(e,t,r,n){let o=bk(()=>{let a=nc();return da(a,t,ma(n),e.transformTemplate),{...a.attrs,style:{...a.style}}},[t]);if(e.style){let a={};gm(a,e.style,e),o.style={...a,...o.style}}return o}function Mv(e=!1){return(r,n,o,{latestValues:a},s)=>{let l=(aa(r)?Ov:wv)(n,a,s,r),c=Av(n,typeof r=="string",e),p=r!==Ck?{...c,...l,ref:o}:{},{children:d}=n,h=xk(()=>Me(d)?d.get():d,[d]);return wk(r,{...p,children:h})}}i();i();i();function oc(e,{style:t,vars:r},n,o){Object.assign(e.style,t,o&&o.getProjectionStyles(n));for(let a in r)e.style.setProperty(a,r[a])}i();var ic=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]);function ac(e,t,r,n){oc(e,t,void 0,n);for(let o in t.attrs)e.setAttribute(ic.has(o)?o:ao(o),t.attrs[o])}i();i();function ha(e,t,r){var n;let{style:o}=e,a={};for(let s in o)(Me(o[s])||t.style&&Me(t.style[s])||ec(s,e)||((n=r?.getValue(s))===null||n===void 0?void 0:n.liveStyle)!==void 0)&&(a[s]=o[s]);return r&&o&&typeof o.willChange=="string"&&(r.applyWillChange=!1),a}function sc(e,t,r){let n=ha(e,t,r);for(let o in e)if(Me(e[o])||Me(t[o])){let a=uo.indexOf(o)!==-1?"attr"+o.charAt(0).toUpperCase()+o.substring(1):o;n[a]=e[o]}return n}i();import{useContext as Vv}from"react";i();function Iv(e){let t=[{},{}];return e?.values.forEach((r,n)=>{t[0][n]=r.get(),t[1][n]=r.getVelocity()}),t}function ga(e,t,r,n){if(typeof t=="function"){let[o,a]=Iv(n);t=t(r!==void 0?r:e.custom,o,a)}if(typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"){let[o,a]=Iv(n);t=t(r!==void 0?r:e.custom,o,a)}return t}i();import{useRef as Sk}from"react";function va(e){let t=Sk(null);return t.current===null&&(t.current=e()),t.current}i();i();i();var ou=e=>Array.isArray(e);var kv=e=>!!(e&&typeof e=="object"&&e.mix&&e.toValue),Nv=e=>ou(e)?e[e.length-1]||0:e;function ya(e){let t=Me(e)?e.get():e;return kv(t)?t.toValue():t}i();i();var uc=new Set(["opacity","clipPath","filter","transform"]);function lc(e){if(Pt.has(e))return"transform";if(uc.has(e))return ao(e)}i();function fo(e,t){e.indexOf(t)===-1&&e.push(t)}function po(e,t){let r=e.indexOf(t);r>-1&&e.splice(r,1)}function Dk({applyWillChange:e=!1,scrapeMotionValuesFromProps:t,createRenderState:r,onMount:n},o,a,s,u){let l={latestValues:Pk(o,a,s,u?!1:e,t),renderState:r()};return n&&(l.mount=c=>n(o,c,l)),l}var cc=e=>(t,r)=>{let n=Vv(oo),o=Vv(io),a=()=>Dk(e,t,n,o,r);return r?a():va(a)};function Ek(e,t){let r=lc(t);r&&fo(e,r)}function Lv(e,t,r){let n=Array.isArray(t)?t:[t];for(let o=0;o<n.length;o++){let a=ga(e,n[o]);if(a){let{transitionEnd:s,transition:u,...l}=a;r(l,s)}}}function Pk(e,t,r,n,o){var a;let s={},u=[],l=n&&((a=e.style)===null||a===void 0?void 0:a.willChange)===void 0,c=o(e,{});for(let b in c)s[b]=ya(c[b]);let{initial:p,animate:d}=e,h=Qo(e),g=Ql(e);t&&g&&!h&&e.inherit!==!1&&(p===void 0&&(p=t.initial),d===void 0&&(d=t.animate));let v=r?r.initial===!1:!1;v=v||p===!1;let m=v?d:p;return m&&typeof m!="boolean"&&!Pn(m)&&Lv(e,m,(b,y)=>{for(let x in b){let w=b[x];if(Array.isArray(w)){let S=v?w.length-1:0;w=w[S]}w!==null&&(s[x]=w)}for(let x in y)s[x]=y[x]}),l&&(d&&p!==!1&&!Pn(d)&&Lv(e,d,b=>{for(let y in b)Ek(u,y)}),u.length&&(s.willChange=u.join(","))),s}i();var{schedule:pe,cancel:It,state:qe,steps:fc}=Yl(typeof requestAnimationFrame<"u"?requestAnimationFrame:Ae,!0);var $v={useVisualState:cc({scrapeMotionValuesFromProps:sc,createRenderState:nc,onMount:(e,t,{renderState:r,latestValues:n})=>{pe.read(()=>{try{r.dimensions=typeof t.getBBox=="function"?t.getBBox():t.getBoundingClientRect()}catch{r.dimensions={x:0,y:0,width:0,height:0}}}),pe.render(()=>{da(r,n,ma(t.tagName),e.transformTemplate),ac(t,r)})}})};i();var zv={useVisualState:cc({applyWillChange:!0,scrapeMotionValuesFromProps:ha,createRenderState:pa})};function Hv(e,{forwardMotionProps:t=!1},r,n){return{...aa(e)?$v:zv,preloadedFeatures:r,useRender:Mv(t),createVisualElement:n,Component:e}}i();i();i();i();function _t(e,t,r,n={passive:!0}){return e.addEventListener(t,r,n),()=>e.removeEventListener(t,r)}i();i();var pc=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1;function ei(e,t="page"){return{point:{x:e[`${t}X`],y:e[`${t}Y`]}}}var Gv=e=>t=>pc(t)&&e(t,ei(t));function Wt(e,t,r,n){return _t(e,t,Gv(r),n)}i();var Tk=(e,t)=>r=>t(e(r)),Tt=(...e)=>e.reduce(Tk);i();function Wv(e){let t=null;return()=>{let r=()=>{t=null};return t===null?(t=e,r):!1}}var jv=Wv("dragHorizontal"),_v=Wv("dragVertical");function vm(e){let t=!1;if(e==="y")t=_v();else if(e==="x")t=jv();else{let r=jv(),n=_v();r&&n?t=()=>{r(),n()}:(r&&r(),n&&n())}return t}function dc(){let e=vm(!0);return e?(e(),!1):!0}i();var lt=class{constructor(t){this.isMounted=!1,this.node=t}update(){}};function Uv(e,t){let r=t?"pointerenter":"pointerleave",n=t?"onHoverStart":"onHoverEnd",o=(a,s)=>{if(a.pointerType==="touch"||dc())return;let u=e.getProps();e.animationState&&u.whileHover&&e.animationState.setActive("whileHover",t);let l=u[n];l&&pe.postRender(()=>l(a,s))};return Wt(e.current,r,o,{passive:!e.getProps()[n]})}var mc=class extends lt{mount(){this.unmount=Tt(Uv(this.node,!0),Uv(this.node,!1))}unmount(){}};i();var hc=class extends lt{constructor(){super(...arguments),this.isActive=!1}onFocus(){let t=!1;try{t=this.node.current.matches(":focus-visible")}catch{t=!0}!t||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){!this.isActive||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=Tt(_t(this.node.current,"focus",()=>this.onFocus()),_t(this.node.current,"blur",()=>this.onBlur()))}unmount(){}};i();i();var ym=(e,t)=>t?e===t?!0:ym(e,t.parentElement):!1;function bm(e,t){if(!t)return;let r=new PointerEvent("pointer"+e);t(r,ei(r))}var gc=class extends lt{constructor(){super(...arguments),this.removeStartListeners=Ae,this.removeEndListeners=Ae,this.removeAccessibleListeners=Ae,this.startPointerPress=(t,r)=>{if(this.isPressing)return;this.removeEndListeners();let n=this.node.getProps(),a=Wt(window,"pointerup",(u,l)=>{if(!this.checkPressEnd())return;let{onTap:c,onTapCancel:p,globalTapTarget:d}=this.node.getProps(),h=!d&&!ym(this.node.current,u.target)?p:c;h&&pe.update(()=>h(u,l))},{passive:!(n.onTap||n.onPointerUp)}),s=Wt(window,"pointercancel",(u,l)=>this.cancelPress(u,l),{passive:!(n.onTapCancel||n.onPointerCancel)});this.removeEndListeners=Tt(a,s),this.startPress(t,r)},this.startAccessiblePress=()=>{let t=a=>{if(a.key!=="Enter"||this.isPressing)return;let s=u=>{u.key!=="Enter"||!this.checkPressEnd()||bm("up",(l,c)=>{let{onTap:p}=this.node.getProps();p&&pe.postRender(()=>p(l,c))})};this.removeEndListeners(),this.removeEndListeners=_t(this.node.current,"keyup",s),bm("down",(u,l)=>{this.startPress(u,l)})},r=_t(this.node.current,"keydown",t),n=()=>{this.isPressing&&bm("cancel",(a,s)=>this.cancelPress(a,s))},o=_t(this.node.current,"blur",n);this.removeAccessibleListeners=Tt(r,o)}}startPress(t,r){this.isPressing=!0;let{onTapStart:n,whileTap:o}=this.node.getProps();o&&this.node.animationState&&this.node.animationState.setActive("whileTap",!0),n&&pe.postRender(()=>n(t,r))}checkPressEnd(){return this.removeEndListeners(),this.isPressing=!1,this.node.getProps().whileTap&&this.node.animationState&&this.node.animationState.setActive("whileTap",!1),!dc()}cancelPress(t,r){if(!this.checkPressEnd())return;let{onTapCancel:n}=this.node.getProps();n&&pe.postRender(()=>n(t,r))}mount(){let t=this.node.getProps(),r=Wt(t.globalTapTarget?window:this.node.current,"pointerdown",this.startPointerPress,{passive:!(t.onTapStart||t.onPointerStart)}),n=_t(this.node.current,"focus",this.startAccessiblePress);this.removeStartListeners=Tt(r,n)}unmount(){this.removeStartListeners(),this.removeEndListeners(),this.removeAccessibleListeners()}};i();i();var xm=new WeakMap,Cm=new WeakMap,Ak=e=>{let t=xm.get(e.target);t&&t(e)},Rk=e=>{e.forEach(Ak)};function Fk({root:e,...t}){let r=e||document;Cm.has(r)||Cm.set(r,{});let n=Cm.get(r),o=JSON.stringify(t);return n[o]||(n[o]=new IntersectionObserver(Rk,{root:e,...t})),n[o]}function Kv(e,t,r){let n=Fk(t);return xm.set(e,r),n.observe(e),()=>{xm.delete(e),n.unobserve(e)}}var Bk={some:0,all:1},vc=class extends lt{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();let{viewport:t={}}=this.node.getProps(),{root:r,margin:n,amount:o="some",once:a}=t,s={root:r?r.current:void 0,rootMargin:n,threshold:typeof o=="number"?o:Bk[o]},u=l=>{let{isIntersecting:c}=l;if(this.isInView===c||(this.isInView=c,a&&!c&&this.hasEnteredView))return;c&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",c);let{onViewportEnter:p,onViewportLeave:d}=this.node.getProps(),h=c?p:d;h&&h(l)};return Kv(this.node.current,s,u)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;let{props:t,prevProps:r}=this.node;["amount","margin","root"].some(Ok(t,r))&&this.startObserver()}unmount(){}};function Ok({viewport:e={}},{viewport:t={}}={}){return r=>e[r]!==t[r]}var qv={inView:{Feature:vc},tap:{Feature:gc},focus:{Feature:hc},hover:{Feature:mc}};i();i();i();i();function wm(e,t){if(!Array.isArray(t))return!1;let r=t.length;if(r!==e.length)return!1;for(let n=0;n<r;n++)if(t[n]!==e[n])return!1;return!0}i();function mo(e,t,r){let n=e.getProps();return ga(n,t,r!==void 0?r:n.custom,e)}i();i();i();i();var Ut=e=>e*1e3,Kt=e=>e/1e3;i();var Mk={type:"spring",stiffness:500,damping:25,restSpeed:10},Ik=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),kk={type:"keyframes",duration:.8},Nk={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},Xv=(e,{keyframes:t})=>t.length>2?kk:Pt.has(e)?e.startsWith("scale")?Ik(t[1]):Mk:Nk;i();function Yv({when:e,delay:t,delayChildren:r,staggerChildren:n,staggerDirection:o,repeat:a,repeatType:s,repeatDelay:u,from:l,elapsed:c,...p}){return!!Object.keys(p).length}function ba(e,t){return e[t]||e.default||e}i();var yc={current:!1};i();var Vk=e=>e!==null;function ho(e,{repeat:t,repeatType:r="loop"},n){let o=e.filter(Vk),a=t&&r!=="loop"&&t%2===1?0:o.length-1;return!a||n===void 0?o[a]:n}i();i();var bc;function Lk(){bc=void 0}var lr={now:()=>(bc===void 0&&lr.set(qe.isProcessing||Sn.useManualTiming?qe.timestamp:performance.now()),bc),set:e=>{bc=e,queueMicrotask(Lk)}};i();i();i();var Cc=e=>/^0[^.\s]+$/u.test(e);function Jv(e){return typeof e=="number"?e===0:e!==null?e==="none"||e==="0"||Cc(e):!0}i();i();var xc=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e);var $k=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function zk(e){let t=$k.exec(e);if(!t)return[,];let[,r,n,o]=t;return[`--${r??n}`,o]}var Hk=4;function Sm(e,t,r=1){Vr(r<=Hk,`Max CSS variable fallback depth detected in property "${e}". This may indicate a circular fallback dependency.`);let[n,o]=zk(e);if(!n)return;let a=window.getComputedStyle(t).getPropertyValue(n);if(a){let s=a.trim();return xc(s)?parseFloat(s):s}return ca(o)?Sm(o,t,r+1):o}i();var e4=new Set(["width","height","top","left","right","bottom","x","y","translateX","translateY"]),Dm=e=>e===Xr||e===ie,Zv=(e,t)=>parseFloat(e.split(", ")[t]),Qv=(e,t)=>(r,{transform:n})=>{if(n==="none"||!n)return 0;let o=n.match(/^matrix3d\((.+)\)$/u);if(o)return Zv(o[1],t);{let a=n.match(/^matrix\((.+)\)$/u);return a?Zv(a[1],e):0}},Gk=new Set(["x","y","z"]),jk=uo.filter(e=>!Gk.has(e));function t4(e){let t=[];return jk.forEach(r=>{let n=e.getValue(r);n!==void 0&&(t.push([r,n.get()]),n.set(r.startsWith("scale")?1:0))}),t}var ti={width:({x:e},{paddingLeft:t="0",paddingRight:r="0"})=>e.max-e.min-parseFloat(t)-parseFloat(r),height:({y:e},{paddingTop:t="0",paddingBottom:r="0"})=>e.max-e.min-parseFloat(t)-parseFloat(r),top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:Qv(4,13),y:Qv(5,14)};ti.translateX=ti.x;ti.translateY=ti.y;i();i();var wc=e=>t=>t.test(e);i();var r4={test:e=>e==="auto",parse:e=>e};var Em=[Xr,ie,Mt,Yr,bv,yv,r4],Pm=e=>Em.find(wc(e));i();var ri=new Set,Tm=!1,Am=!1;function n4(){if(Am){let e=Array.from(ri).filter(n=>n.needsMeasurement),t=new Set(e.map(n=>n.element)),r=new Map;t.forEach(n=>{let o=t4(n);o.length&&(r.set(n,o),n.render())}),e.forEach(n=>n.measureInitialState()),t.forEach(n=>{n.render();let o=r.get(n);o&&o.forEach(([a,s])=>{var u;(u=n.getValue(a))===null||u===void 0||u.set(s)})}),e.forEach(n=>n.measureEndState()),e.forEach(n=>{n.suspendedScrollY!==void 0&&window.scrollTo(0,n.suspendedScrollY)})}Am=!1,Tm=!1,ri.forEach(e=>e.complete()),ri.clear()}function o4(){ri.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(Am=!0)})}function i4(){o4(),n4()}var go=class{constructor(t,r,n,o,a,s=!1){this.isComplete=!1,this.isAsync=!1,this.needsMeasurement=!1,this.isScheduled=!1,this.unresolvedKeyframes=[...t],this.onComplete=r,this.name=n,this.motionValue=o,this.element=a,this.isAsync=s}scheduleResolve(){this.isScheduled=!0,this.isAsync?(ri.add(this),Tm||(Tm=!0,pe.read(o4),pe.resolveKeyframes(n4))):(this.readKeyframes(),this.complete())}readKeyframes(){let{unresolvedKeyframes:t,name:r,element:n,motionValue:o}=this;for(let a=0;a<t.length;a++)if(t[a]===null)if(a===0){let s=o?.get(),u=t[t.length-1];if(s!==void 0)t[0]=s;else if(n&&r){let l=n.readValue(r,u);l!=null&&(t[0]=l)}t[0]===void 0&&(t[0]=u),o&&s===void 0&&o.set(t[0])}else t[a]=t[a-1]}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(){this.isComplete=!0,this.onComplete(this.unresolvedKeyframes,this.finalKeyframe),ri.delete(this)}cancel(){this.isComplete||(this.isScheduled=!1,ri.delete(this))}resume(){this.isComplete||this.scheduleResolve()}};i();i();i();i();i();i();var Ca=(e,t)=>r=>!!(An(r)&&gv.test(r)&&r.startsWith(e)||t&&!vv(r)&&Object.prototype.hasOwnProperty.call(r,t)),Sc=(e,t,r)=>n=>{if(!An(n))return n;let[o,a,s,u]=n.match(ua);return{[e]:parseFloat(o),[t]:parseFloat(a),[r]:parseFloat(s),alpha:u!==void 0?parseFloat(u):1}};var _k=e=>Ot(0,255,e),Rm={...Xr,transform:e=>Math.round(_k(e))},Jr={test:Ca("rgb","red"),parse:Sc("red","green","blue"),transform:({red:e,green:t,blue:r,alpha:n=1})=>"rgba("+Rm.transform(e)+", "+Rm.transform(t)+", "+Rm.transform(r)+", "+co(lo.transform(n))+")"};function Wk(e){let t="",r="",n="",o="";return e.length>5?(t=e.substring(1,3),r=e.substring(3,5),n=e.substring(5,7),o=e.substring(7,9)):(t=e.substring(1,2),r=e.substring(2,3),n=e.substring(3,4),o=e.substring(4,5),t+=t,r+=r,n+=n,o+=o),{red:parseInt(t,16),green:parseInt(r,16),blue:parseInt(n,16),alpha:o?parseInt(o,16)/255:1}}var iu={test:Ca("#"),parse:Wk,transform:Jr.transform};i();var vo={test:Ca("hsl","hue"),parse:Sc("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:r,alpha:n=1})=>"hsla("+Math.round(e)+", "+Mt.transform(co(t))+", "+Mt.transform(co(r))+", "+co(lo.transform(n))+")"};var Ze={test:e=>Jr.test(e)||iu.test(e)||vo.test(e),parse:e=>Jr.test(e)?Jr.parse(e):vo.test(e)?vo.parse(e):iu.parse(e),transform:e=>An(e)?e:e.hasOwnProperty("red")?Jr.transform(e):vo.transform(e)};function Uk(e){var t,r;return isNaN(e)&&An(e)&&(((t=e.match(ua))===null||t===void 0?void 0:t.length)||0)+(((r=e.match(hv))===null||r===void 0?void 0:r.length)||0)>0}var s4="number",u4="color",Kk="var",qk="var(",a4="${}",Xk=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function ni(e){let t=e.toString(),r=[],n={color:[],number:[],var:[]},o=[],a=0,u=t.replace(Xk,l=>(Ze.test(l)?(n.color.push(a),o.push(u4),r.push(Ze.parse(l))):l.startsWith(qk)?(n.var.push(a),o.push(Kk),r.push(l)):(n.number.push(a),o.push(s4),r.push(parseFloat(l))),++a,a4)).split(a4);return{values:r,split:u,indexes:n,types:o}}function l4(e){return ni(e).values}function c4(e){let{split:t,types:r}=ni(e),n=t.length;return o=>{let a="";for(let s=0;s<n;s++)if(a+=t[s],o[s]!==void 0){let u=r[s];u===s4?a+=co(o[s]):u===u4?a+=Ze.transform(o[s]):a+=o[s]}return a}}var Yk=e=>typeof e=="number"?0:e;function Jk(e){let t=l4(e);return c4(e)(t.map(Yk))}var kt={test:Uk,parse:l4,createTransformer:c4,getAnimatableNone:Jk};i();i();var Zk=new Set(["brightness","contrast","saturate","opacity"]);function Qk(e){let[t,r]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;let[n]=r.match(ua)||[];if(!n)return e;let o=r.replace(n,""),a=Zk.has(t)?1:0;return n!==r&&(a*=100),t+"("+a+o+")"}var eN=/\b([a-z-]*)\(.*?\)/gu,au={...kt,getAnimatableNone:e=>{let t=e.match(eN);return t?t.map(Qk).join(" "):e}};i();var tN={...la,color:Ze,backgroundColor:Ze,outlineColor:Ze,fill:Ze,stroke:Ze,borderColor:Ze,borderTopColor:Ze,borderRightColor:Ze,borderBottomColor:Ze,borderLeftColor:Ze,filter:au,WebkitFilter:au},xa=e=>tN[e];function Dc(e,t){let r=xa(e);return r!==au&&(r=kt),r.getAnimatableNone?r.getAnimatableNone(t):void 0}var rN=new Set(["auto","none","0"]);function f4(e,t,r){let n=0,o;for(;n<e.length&&!o;){let a=e[n];typeof a=="string"&&!rN.has(a)&&ni(a).values.length&&(o=e[n]),n++}if(o&&r)for(let a of t)e[a]=Dc(r,o)}var wa=class extends go{constructor(t,r,n,o){super(t,r,n,o,o?.owner,!0)}readKeyframes(){let{unresolvedKeyframes:t,element:r,name:n}=this;if(!r.current)return;super.readKeyframes();for(let l=0;l<t.length;l++){let c=t[l];if(typeof c=="string"&&(c=c.trim(),ca(c))){let p=Sm(c,r.current);p!==void 0&&(t[l]=p),l===t.length-1&&(this.finalKeyframe=c)}}if(this.resolveNoneKeyframes(),!e4.has(n)||t.length!==2)return;let[o,a]=t,s=Pm(o),u=Pm(a);if(s!==u)if(Dm(s)&&Dm(u))for(let l=0;l<t.length;l++){let c=t[l];typeof c=="string"&&(t[l]=parseFloat(c))}else this.needsMeasurement=!0}resolveNoneKeyframes(){let{unresolvedKeyframes:t,name:r}=this,n=[];for(let o=0;o<t.length;o++)Jv(t[o])&&n.push(o);n.length&&f4(t,n,r)}measureInitialState(){let{element:t,unresolvedKeyframes:r,name:n}=this;if(!t.current)return;n==="height"&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=ti[n](t.measureViewportBox(),window.getComputedStyle(t.current)),r[0]=this.measuredOrigin;let o=r[r.length-1];o!==void 0&&t.getValue(n,o).jump(o,!1)}measureEndState(){var t;let{element:r,name:n,unresolvedKeyframes:o}=this;if(!r.current)return;let a=r.getValue(n);a&&a.jump(this.measuredOrigin,!1);let s=o.length-1,u=o[s];o[s]=ti[n](r.measureViewportBox(),window.getComputedStyle(r.current)),u!==null&&this.finalKeyframe===void 0&&(this.finalKeyframe=u),!((t=this.removedTransforms)===null||t===void 0)&&t.length&&this.removedTransforms.forEach(([l,c])=>{r.getValue(l).set(c)}),this.resolveNoneKeyframes()}};i();function Ec(e){let t;return()=>(t===void 0&&(t=e()),t)}i();i();i();var Fm=(e,t)=>t==="zIndex"?!1:!!(typeof e=="number"||Array.isArray(e)||typeof e=="string"&&(kt.test(e)||e==="0")&&!e.startsWith("url("));function nN(e){let t=e[0];if(e.length===1)return!0;for(let r=0;r<e.length;r++)if(e[r]!==t)return!0}function p4(e,t,r,n){let o=e[0];if(o===null)return!1;if(t==="display"||t==="visibility")return!0;let a=e[e.length-1],s=Fm(o,t),u=Fm(a,t);return so(s===u,`You are trying to animate ${t} from "${o}" to "${a}". ${o} is not an animatable value - to enable this animation set ${o} to a value animatable to ${a} via the \`style\` property.`),!s||!u?!1:nN(e)||r==="spring"&&n}var Sa=class{constructor({autoplay:t=!0,delay:r=0,type:n="keyframes",repeat:o=0,repeatDelay:a=0,repeatType:s="loop",...u}){this.isStopped=!1,this.hasAttemptedResolve=!1,this.options={autoplay:t,delay:r,type:n,repeat:o,repeatDelay:a,repeatType:s,...u},this.updateFinishedPromise()}get resolved(){return!this._resolved&&!this.hasAttemptedResolve&&i4(),this._resolved}onKeyframesResolved(t,r){this.hasAttemptedResolve=!0;let{name:n,type:o,velocity:a,delay:s,onComplete:u,onUpdate:l,isGenerator:c}=this.options;if(!c&&!p4(t,n,o,a))if(yc.current||!s){l?.(ho(t,this.options,r)),u?.(),this.resolveFinishedPromise();return}else this.options.duration=0;let p=this.initPlayback(t,r);p!==!1&&(this._resolved={keyframes:t,finalKeyframe:r,...p},this.onPostResolved())}onPostResolved(){}then(t,r){return this.currentFinishedPromise.then(t,r)}updateFinishedPromise(){this.currentFinishedPromise=new Promise(t=>{this.resolveFinishedPromise=t})}};i();i();i();i();function Pc(e,t){return t?e*(1e3/t):0}var oN=5;function Tc(e,t,r){let n=Math.max(t-oN,0);return Pc(r-e(n),t-n)}i();var Bm=.001,iN=.01,d4=10,aN=.05,sN=1;function m4({duration:e=800,bounce:t=.25,velocity:r=0,mass:n=1}){let o,a;so(e<=Ut(d4),"Spring duration must be 10 seconds or less");let s=1-t;s=Ot(aN,sN,s),e=Ot(iN,d4,Kt(e)),s<1?(o=c=>{let p=c*s,d=p*e,h=p-r,g=Ac(c,s),v=Math.exp(-d);return Bm-h/g*v},a=c=>{let d=c*s*e,h=d*r+r,g=Math.pow(s,2)*Math.pow(c,2)*e,v=Math.exp(-d),m=Ac(Math.pow(c,2),s);return(-o(c)+Bm>0?-1:1)*((h-g)*v)/m}):(o=c=>{let p=Math.exp(-c*e),d=(c-r)*e+1;return-Bm+p*d},a=c=>{let p=Math.exp(-c*e),d=(r-c)*(e*e);return p*d});let u=5/e,l=lN(o,a,u);if(e=Ut(e),isNaN(l))return{stiffness:100,damping:10,duration:e};{let c=Math.pow(l,2)*n;return{stiffness:c,damping:s*2*Math.sqrt(n*c),duration:e}}}var uN=12;function lN(e,t,r){let n=r;for(let o=1;o<uN;o++)n=n-e(n)/t(n);return n}function Ac(e,t){return e*Math.sqrt(1-t*t)}var cN=["duration","bounce"],fN=["stiffness","damping","mass"];function h4(e,t){return t.some(r=>e[r]!==void 0)}function pN(e){let t={velocity:0,stiffness:100,damping:10,mass:1,isResolvedFromDuration:!1,...e};if(!h4(e,fN)&&h4(e,cN)){let r=m4(e);t={...t,...r,mass:1},t.isResolvedFromDuration=!0}return t}function Rc({keyframes:e,restDelta:t,restSpeed:r,...n}){let o=e[0],a=e[e.length-1],s={done:!1,value:o},{stiffness:u,damping:l,mass:c,duration:p,velocity:d,isResolvedFromDuration:h}=pN({...n,velocity:-Kt(n.velocity||0)}),g=d||0,v=l/(2*Math.sqrt(u*c)),m=a-o,b=Kt(Math.sqrt(u/c)),y=Math.abs(m)<5;r||(r=y?.01:2),t||(t=y?.005:.5);let x;if(v<1){let w=Ac(b,v);x=S=>{let E=Math.exp(-v*b*S);return a-E*((g+v*b*m)/w*Math.sin(w*S)+m*Math.cos(w*S))}}else if(v===1)x=w=>a-Math.exp(-b*w)*(m+(g+b*m)*w);else{let w=b*Math.sqrt(v*v-1);x=S=>{let E=Math.exp(-v*b*S),D=Math.min(w*S,300);return a-E*((g+v*b*m)*Math.sinh(D)+w*m*Math.cosh(D))/w}}return{calculatedDuration:h&&p||null,next:w=>{let S=x(w);if(h)s.done=w>=p;else{let E=g;w!==0&&(v<1?E=Tc(x,w,S):E=0);let D=Math.abs(E)<=r,P=Math.abs(a-S)<=t;s.done=D&&P}return s.value=s.done?a:S,s}}}i();function Om({keyframes:e,velocity:t=0,power:r=.8,timeConstant:n=325,bounceDamping:o=10,bounceStiffness:a=500,modifyTarget:s,min:u,max:l,restDelta:c=.5,restSpeed:p}){let d=e[0],h={done:!1,value:d},g=R=>u!==void 0&&R<u||l!==void 0&&R>l,v=R=>u===void 0?l:l===void 0||Math.abs(u-R)<Math.abs(l-R)?u:l,m=r*t,b=d+m,y=s===void 0?b:s(b);y!==b&&(m=y-d);let x=R=>-m*Math.exp(-R/n),w=R=>y+x(R),S=R=>{let F=x(R),M=w(R);h.done=Math.abs(F)<=c,h.value=h.done?y:M},E,D,P=R=>{g(h.value)&&(E=R,D=Rc({keyframes:[h.value,v(h.value)],velocity:Tc(w,R,h.value),damping:o,stiffness:a,restDelta:c,restSpeed:p}))};return P(0),{calculatedDuration:null,next:R=>{let F=!1;return!D&&E===void 0&&(F=!0,S(R),P(R)),E!==void 0&&R>=E?D.next(R-E):(!F&&S(R),h)}}}i();i();i();var g4=(e,t,r)=>(((1-3*r+3*t)*e+(3*r-6*t))*e+3*t)*e,dN=1e-7,mN=12;function hN(e,t,r,n,o){let a,s,u=0;do s=t+(r-t)/2,a=g4(s,n,o)-e,a>0?r=s:t=s;while(Math.abs(a)>dN&&++u<mN);return s}function yo(e,t,r,n){if(e===t&&r===n)return Ae;let o=a=>hN(a,0,1,e,r);return a=>a===0||a===1?a:g4(o(a),t,n)}var v4=yo(.42,0,1,1),y4=yo(0,0,.58,1),Fc=yo(.42,0,.58,1);i();var b4=e=>Array.isArray(e)&&typeof e[0]!="number";i();i();i();var Bc=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2;i();var Oc=e=>t=>1-e(1-t);var Mc=e=>1-Math.sin(Math.acos(e)),Ic=Oc(Mc),C4=Bc(Mc);i();var Mm=yo(.33,1.53,.69,.99),su=Oc(Mm),x4=Bc(su);i();var w4=e=>(e*=2)<1?.5*su(e):.5*(2-Math.pow(2,-10*(e-1)));var S4={linear:Ae,easeIn:v4,easeInOut:Fc,easeOut:y4,circIn:Mc,circInOut:C4,circOut:Ic,backIn:su,backInOut:x4,backOut:Mm,anticipate:w4},Im=e=>{if(Array.isArray(e)){Vr(e.length===4,"Cubic bezier arrays must contain four numerical values.");let[t,r,n,o]=e;return yo(t,r,n,o)}else if(typeof e=="string")return Vr(S4[e]!==void 0,`Invalid easing type '${e}'`),S4[e];return e};i();i();var Rn=(e,t,r)=>{let n=t-e;return n===0?1:(r-e)/n};i();i();i();var be=(e,t,r)=>e+(t-e)*r;i();i();function km(e,t,r){return r<0&&(r+=1),r>1&&(r-=1),r<1/6?e+(t-e)*6*r:r<1/2?t:r<2/3?e+(t-e)*(2/3-r)*6:e}function D4({hue:e,saturation:t,lightness:r,alpha:n}){e/=360,t/=100,r/=100;let o=0,a=0,s=0;if(!t)o=a=s=r;else{let u=r<.5?r*(1+t):r+t-r*t,l=2*r-u;o=km(l,u,e+1/3),a=km(l,u,e),s=km(l,u,e-1/3)}return{red:Math.round(o*255),green:Math.round(a*255),blue:Math.round(s*255),alpha:n}}i();function Da(e,t){return r=>r>0?t:e}var Nm=(e,t,r)=>{let n=e*e,o=r*(t*t-n)+n;return o<0?0:Math.sqrt(o)},gN=[iu,Jr,vo],vN=e=>gN.find(t=>t.test(e));function E4(e){let t=vN(e);if(so(!!t,`'${e}' is not an animatable color. Use the equivalent color code instead.`),!t)return!1;let r=t.parse(e);return t===vo&&(r=D4(r)),r}var Vm=(e,t)=>{let r=E4(e),n=E4(t);if(!r||!n)return Da(e,t);let o={...r};return a=>(o.red=Nm(r.red,n.red,a),o.green=Nm(r.green,n.green,a),o.blue=Nm(r.blue,n.blue,a),o.alpha=be(r.alpha,n.alpha,a),Jr.transform(o))};i();var kc=new Set(["none","hidden"]);function P4(e,t){return kc.has(e)?r=>r<=0?e:t:r=>r>=1?t:e}function yN(e,t){return r=>be(e,t,r)}function Nc(e){return typeof e=="number"?yN:typeof e=="string"?ca(e)?Da:Ze.test(e)?Vm:xN:Array.isArray(e)?T4:typeof e=="object"?Ze.test(e)?Vm:bN:Da}function T4(e,t){let r=[...e],n=r.length,o=e.map((a,s)=>Nc(a)(a,t[s]));return a=>{for(let s=0;s<n;s++)r[s]=o[s](a);return r}}function bN(e,t){let r={...e,...t},n={};for(let o in r)e[o]!==void 0&&t[o]!==void 0&&(n[o]=Nc(e[o])(e[o],t[o]));return o=>{for(let a in n)r[a]=n[a](o);return r}}function CN(e,t){var r;let n=[],o={color:0,var:0,number:0};for(let a=0;a<t.values.length;a++){let s=t.types[a],u=e.indexes[s][o[s]],l=(r=e.values[u])!==null&&r!==void 0?r:0;n[a]=l,o[s]++}return n}var xN=(e,t)=>{let r=kt.createTransformer(t),n=ni(e),o=ni(t);return n.indexes.var.length===o.indexes.var.length&&n.indexes.color.length===o.indexes.color.length&&n.indexes.number.length>=o.indexes.number.length?kc.has(e)&&!o.values.length||kc.has(t)&&!n.values.length?P4(e,t):Tt(T4(CN(n,o),o.values),r):(so(!0,`Complex values '${e}' and '${t}' too different to mix. Ensure all colors are of the same type, and that each contains the same quantity of number and color values. Falling back to instant transition.`),Da(e,t))};function Vc(e,t,r){return typeof e=="number"&&typeof t=="number"&&typeof r=="number"?be(e,t,r):Nc(e)(e,t)}function wN(e,t,r){let n=[],o=r||Vc,a=e.length-1;for(let s=0;s<a;s++){let u=o(e[s],e[s+1]);if(t){let l=Array.isArray(t)?t[s]||Ae:t;u=Tt(l,u)}n.push(u)}return n}function A4(e,t,{clamp:r=!0,ease:n,mixer:o}={}){let a=e.length;if(Vr(a===t.length,"Both input and output ranges must be the same length"),a===1)return()=>t[0];if(a===2&&e[0]===e[1])return()=>t[1];e[0]>e[a-1]&&(e=[...e].reverse(),t=[...t].reverse());let s=wN(t,n,o),u=s.length,l=c=>{let p=0;if(u>1)for(;p<e.length-2&&!(c<e[p+1]);p++);let d=Rn(e[p],e[p+1],c);return s[p](d)};return r?c=>l(Ot(e[0],e[a-1],c)):l}i();i();function R4(e,t){let r=e[e.length-1];for(let n=1;n<=t;n++){let o=Rn(0,t,n);e.push(be(r,1,o))}}function F4(e){let t=[0];return R4(t,e.length-1),t}i();function B4(e,t){return e.map(r=>r*t)}function SN(e,t){return e.map(()=>t||Fc).splice(0,e.length-1)}function uu({duration:e=300,keyframes:t,times:r,ease:n="easeInOut"}){let o=b4(n)?n.map(Im):Im(n),a={done:!1,value:t[0]},s=B4(r&&r.length===t.length?r:F4(t),e),u=A4(s,t,{ease:Array.isArray(o)?o:SN(t,o)});return{calculatedDuration:e,next:l=>(a.value=u(l),a.done=l>=e,a)}}i();function O4(e){let t=0,r=50,n=e.next(t);for(;!n.done&&t<2e4;)t+=r,n=e.next(t);return t>=2e4?1/0:t}i();var M4=e=>{let t=({timestamp:r})=>e(r);return{start:()=>pe.update(t,!0),stop:()=>It(t),now:()=>qe.isProcessing?qe.timestamp:lr.now()}};var DN={decay:Om,inertia:Om,tween:uu,keyframes:uu,spring:Rc},EN=e=>e/100,oi=class extends Sa{constructor({KeyframeResolver:t=go,...r}){super(r),this.holdTime=null,this.startTime=null,this.cancelTime=null,this.currentTime=0,this.playbackSpeed=1,this.pendingPlayState="running",this.state="idle",this.stop=()=>{if(this.resolver.cancel(),this.isStopped=!0,this.state==="idle")return;this.teardown();let{onStop:u}=this.options;u&&u()};let{name:n,motionValue:o,keyframes:a}=this.options,s=(u,l)=>this.onKeyframesResolved(u,l);n&&o&&o.owner?this.resolver=o.owner.resolveKeyframes(a,s,n,o):this.resolver=new t(a,s,n,o),this.resolver.scheduleResolve()}initPlayback(t){let{type:r="keyframes",repeat:n=0,repeatDelay:o=0,repeatType:a,velocity:s=0}=this.options,u=DN[r]||uu,l,c;u!==uu&&typeof t[0]!="number"&&(l=Tt(EN,Vc(t[0],t[1])),t=[0,100]);let p=u({...this.options,keyframes:t});a==="mirror"&&(c=u({...this.options,keyframes:[...t].reverse(),velocity:-s})),p.calculatedDuration===null&&(p.calculatedDuration=O4(p));let{calculatedDuration:d}=p,h=d+o,g=h*(n+1)-o;return{generator:p,mirroredGenerator:c,mapPercentToKeyframes:l,calculatedDuration:d,resolvedDuration:h,totalDuration:g}}onPostResolved(){let{autoplay:t=!0}=this.options;this.play(),this.pendingPlayState==="paused"||!t?this.pause():this.state=this.pendingPlayState}tick(t,r=!1){let{resolved:n}=this;if(!n){let{keyframes:R}=this.options;return{done:!0,value:R[R.length-1]}}let{finalKeyframe:o,generator:a,mirroredGenerator:s,mapPercentToKeyframes:u,keyframes:l,calculatedDuration:c,totalDuration:p,resolvedDuration:d}=n;if(this.startTime===null)return a.next(0);let{delay:h,repeat:g,repeatType:v,repeatDelay:m,onUpdate:b}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-p/this.speed,this.startTime)),r?this.currentTime=t:this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=Math.round(t-this.startTime)*this.speed;let y=this.currentTime-h*(this.speed>=0?1:-1),x=this.speed>=0?y<0:y>p;this.currentTime=Math.max(y,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=p);let w=this.currentTime,S=a;if(g){let R=Math.min(this.currentTime,p)/d,F=Math.floor(R),M=R%1;!M&&R>=1&&(M=1),M===1&&F--,F=Math.min(F,g+1),!!(F%2)&&(v==="reverse"?(M=1-M,m&&(M-=m/d)):v==="mirror"&&(S=s)),w=Ot(0,1,M)*d}let E=x?{done:!1,value:l[0]}:S.next(w);u&&(E.value=u(E.value));let{done:D}=E;!x&&c!==null&&(D=this.speed>=0?this.currentTime>=p:this.currentTime<=0);let P=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&D);return P&&o!==void 0&&(E.value=ho(l,this.options,o)),b&&b(E.value),P&&this.finish(),E}get duration(){let{resolved:t}=this;return t?Kt(t.calculatedDuration):0}get time(){return Kt(this.currentTime)}set time(t){t=Ut(t),this.currentTime=t,this.holdTime!==null||this.speed===0?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.speed)}get speed(){return this.playbackSpeed}set speed(t){let r=this.playbackSpeed!==t;this.playbackSpeed=t,r&&(this.time=Kt(this.currentTime))}play(){if(this.resolver.isScheduled||this.resolver.resume(),!this._resolved){this.pendingPlayState="running";return}if(this.isStopped)return;let{driver:t=M4,onPlay:r}=this.options;this.driver||(this.driver=t(o=>this.tick(o))),r&&r();let n=this.driver.now();this.holdTime!==null?this.startTime=n-this.holdTime:(!this.startTime||this.state==="finished")&&(this.startTime=n),this.state==="finished"&&this.updateFinishedPromise(),this.cancelTime=this.startTime,this.holdTime=null,this.state="running",this.driver.start()}pause(){var t;if(!this._resolved){this.pendingPlayState="paused";return}this.state="paused",this.holdTime=(t=this.currentTime)!==null&&t!==void 0?t:0}complete(){this.state!=="running"&&this.play(),this.pendingPlayState=this.state="finished",this.holdTime=null}finish(){this.teardown(),this.state="finished";let{onComplete:t}=this.options;t&&t()}cancel(){this.cancelTime!==null&&this.tick(this.cancelTime),this.teardown(),this.updateFinishedPromise()}teardown(){this.state="idle",this.stopDriver(),this.resolveFinishedPromise(),this.updateFinishedPromise(),this.startTime=this.cancelTime=null,this.resolver.cancel()}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}};i();i();i();var Lm=e=>Array.isArray(e)&&typeof e[0]=="number";function $m(e){return!!(!e||typeof e=="string"&&e in zm||Lm(e)||Array.isArray(e)&&e.every($m))}var lu=([e,t,r,n])=>`cubic-bezier(${e}, ${t}, ${r}, ${n})`,zm={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:lu([0,.65,.55,1]),circOut:lu([.55,0,1,.45]),backIn:lu([.31,.01,.66,-.59]),backOut:lu([.33,1.53,.69,.99])};function PN(e){return Hm(e)||zm.easeOut}function Hm(e){if(e)return Lm(e)?lu(e):Array.isArray(e)?e.map(PN):zm[e]}function I4(e,t,r,{delay:n=0,duration:o=300,repeat:a=0,repeatType:s="loop",ease:u,times:l}={}){let c={[t]:r};l&&(c.offset=l);let p=Hm(u);return Array.isArray(p)&&(c.easing=p),e.animate(c,{delay:n,duration:o,easing:Array.isArray(p)?"linear":p,fill:"both",iterations:a+1,direction:s==="reverse"?"alternate":"normal"})}var TN=Ec(()=>Object.hasOwnProperty.call(Element.prototype,"animate")),Lc=10,AN=2e4;function RN(e){return e.type==="spring"||!$m(e.ease)}function FN(e,t){let r=new oi({...t,keyframes:e,repeat:0,delay:0,isGenerator:!0}),n={done:!1,value:e[0]},o=[],a=0;for(;!n.done&&a<AN;)n=r.sample(a),o.push(n.value),a+=Lc;return{times:void 0,keyframes:o,duration:a-Lc,ease:"linear"}}var cu=class extends Sa{constructor(t){super(t);let{name:r,motionValue:n,keyframes:o}=this.options;this.resolver=new wa(o,(a,s)=>this.onKeyframesResolved(a,s),r,n),this.resolver.scheduleResolve()}initPlayback(t,r){var n;let{duration:o=300,times:a,ease:s,type:u,motionValue:l,name:c}=this.options;if(!(!((n=l.owner)===null||n===void 0)&&n.current))return!1;if(RN(this.options)){let{onComplete:d,onUpdate:h,motionValue:g,...v}=this.options,m=FN(t,v);t=m.keyframes,t.length===1&&(t[1]=t[0]),o=m.duration,a=m.times,s=m.ease,u="keyframes"}let p=I4(l.owner.current,c,t,{...this.options,duration:o,times:a,ease:s});return p.startTime=lr.now(),this.pendingTimeline?(p.timeline=this.pendingTimeline,this.pendingTimeline=void 0):p.onfinish=()=>{let{onComplete:d}=this.options;l.set(ho(t,this.options,r)),d&&d(),this.cancel(),this.resolveFinishedPromise()},{animation:p,duration:o,times:a,type:u,ease:s,keyframes:t}}get duration(){let{resolved:t}=this;if(!t)return 0;let{duration:r}=t;return Kt(r)}get time(){let{resolved:t}=this;if(!t)return 0;let{animation:r}=t;return Kt(r.currentTime||0)}set time(t){let{resolved:r}=this;if(!r)return;let{animation:n}=r;n.currentTime=Ut(t)}get speed(){let{resolved:t}=this;if(!t)return 1;let{animation:r}=t;return r.playbackRate}set speed(t){let{resolved:r}=this;if(!r)return;let{animation:n}=r;n.playbackRate=t}get state(){let{resolved:t}=this;if(!t)return"idle";let{animation:r}=t;return r.playState}attachTimeline(t){if(!this._resolved)this.pendingTimeline=t;else{let{resolved:r}=this;if(!r)return Ae;let{animation:n}=r;n.timeline=t,n.onfinish=null}return Ae}play(){if(this.isStopped)return;let{resolved:t}=this;if(!t)return;let{animation:r}=t;r.playState==="finished"&&this.updateFinishedPromise(),r.play()}pause(){let{resolved:t}=this;if(!t)return;let{animation:r}=t;r.pause()}stop(){if(this.resolver.cancel(),this.isStopped=!0,this.state==="idle")return;this.resolveFinishedPromise(),this.updateFinishedPromise();let{resolved:t}=this;if(!t)return;let{animation:r,keyframes:n,duration:o,type:a,ease:s,times:u}=t;if(r.playState==="idle"||r.playState==="finished")return;if(this.time){let{motionValue:c,onUpdate:p,onComplete:d,...h}=this.options,g=new oi({...h,keyframes:n,duration:o,type:a,ease:s,times:u,isGenerator:!0}),v=Ut(this.time);c.setWithVelocity(g.sample(v-Lc).value,g.sample(v).value,Lc)}let{onStop:l}=this.options;l&&l(),this.cancel()}complete(){let{resolved:t}=this;t&&t.animation.finish()}cancel(){let{resolved:t}=this;t&&t.animation.cancel()}static supports(t){let{motionValue:r,name:n,repeatDelay:o,repeatType:a,damping:s,type:u}=t;return TN()&&n&&uc.has(n)&&r&&r.owner&&r.owner.current instanceof HTMLElement&&!r.owner.getProps().onUpdate&&!o&&a!=="mirror"&&s!==0&&u!=="inertia"}};i();i();function k4(e,t){let r,n=()=>{let{currentTime:o}=t,s=(o===null?0:o.value)/100;r!==s&&e(s),r=s};return pe.update(n,!0),()=>It(n)}i();var N4=Ec(()=>window.ScrollTimeline!==void 0);var $c=class{constructor(t){this.stop=()=>this.runAll("stop"),this.animations=t.filter(Boolean)}then(t,r){return Promise.all(this.animations).then(t).catch(r)}getAll(t){return this.animations[0][t]}setAll(t,r){for(let n=0;n<this.animations.length;n++)this.animations[n][t]=r}attachTimeline(t){let r=this.animations.map(n=>{if(N4()&&n.attachTimeline)n.attachTimeline(t);else return n.pause(),k4(o=>{n.time=n.duration*o},t)});return()=>{r.forEach((n,o)=>{n&&n(),this.animations[o].stop()})}}get time(){return this.getAll("time")}set time(t){this.setAll("time",t)}get speed(){return this.getAll("speed")}set speed(t){this.setAll("speed",t)}get duration(){let t=0;for(let r=0;r<this.animations.length;r++)t=Math.max(t,this.animations[r].duration);return t}runAll(t){this.animations.forEach(r=>r[t]())}play(){this.runAll("play")}pause(){this.runAll("pause")}cancel(){this.runAll("cancel")}complete(){this.runAll("complete")}};var Ea=(e,t,r,n={},o,a,s)=>u=>{let l=ba(n,e)||{},c=l.delay||n.delay||0,{elapsed:p=0}=n;p=p-Ut(c);let d={keyframes:Array.isArray(r)?r:[null,r],ease:"easeOut",velocity:t.getVelocity(),...l,delay:-p,onUpdate:g=>{t.set(g),l.onUpdate&&l.onUpdate(g)},onComplete:()=>{u(),l.onComplete&&l.onComplete(),s&&s()},onStop:s,name:e,motionValue:t,element:a?void 0:o};Yv(l)||(d={...d,...Xv(e,d)}),d.duration&&(d.duration=Ut(d.duration)),d.repeatDelay&&(d.repeatDelay=Ut(d.repeatDelay)),d.from!==void 0&&(d.keyframes[0]=d.from);let h=!1;if((d.type===!1||d.duration===0&&!d.repeatDelay)&&(d.duration=0,d.delay===0&&(h=!0)),(yc.current||Sn.skipAnimations)&&(h=!0,d.duration=0,d.delay=0),h&&!a&&t.get()!==void 0){let g=ho(d.keyframes,l);if(g!==void 0)return pe.update(()=>{d.onUpdate(g),d.onComplete()}),new $c([])}return!a&&cu.supports(d)?new cu(d):new oi(d)};i();i();i();var bo=class{constructor(){this.subscriptions=[]}add(t){return fo(this.subscriptions,t),()=>po(this.subscriptions,t)}notify(t,r,n){let o=this.subscriptions.length;if(o)if(o===1)this.subscriptions[0](t,r,n);else for(let a=0;a<o;a++){let s=this.subscriptions[a];s&&s(t,r,n)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}};var V4=30,BN=e=>!isNaN(parseFloat(e)),L4={current:void 0},fu=class{constructor(t,r={}){this.version="11.3.21",this.canTrackVelocity=null,this.events={},this.updateAndNotify=(n,o=!0)=>{let a=lr.now();this.updatedAt!==a&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(n),this.current!==this.prev&&this.events.change&&this.events.change.notify(this.current),o&&this.events.renderRequest&&this.events.renderRequest.notify(this.current)},this.hasAnimated=!1,this.setCurrent(t),this.owner=r.owner}setCurrent(t){this.current=t,this.updatedAt=lr.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=BN(this.current))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return this.on("change",t)}on(t,r){this.events[t]||(this.events[t]=new bo);let n=this.events[t].add(r);return t==="change"?()=>{n(),pe.read(()=>{this.events.change.getSize()||this.stop()})}:n}clearListeners(){for(let t in this.events)this.events[t].clear()}attach(t,r){this.passiveEffect=t,this.stopPassiveEffect=r}set(t,r=!0){!r||!this.passiveEffect?this.updateAndNotify(t,r):this.passiveEffect(t,this.updateAndNotify)}setWithVelocity(t,r,n){this.set(r),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-n}jump(t,r=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,r&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}get(){return L4.current&&L4.current.push(this),this.current}getPrevious(){return this.prev}getVelocity(){let t=lr.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>V4)return 0;let r=Math.min(this.updatedAt-this.prevUpdatedAt,V4);return Pc(parseFloat(this.current)-parseFloat(this.prevFrameValue),r)}start(t){return this.stop(),new Promise(r=>{this.hasAnimated=!0,this.animation=t(r),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}};function Fn(e,t){return new fu(e,t)}function ON(e,t,r){e.hasValue(t)?e.getValue(t).set(r):e.addValue(t,Fn(r))}function $4(e,t){let r=mo(e,t),{transitionEnd:n={},transition:o={},...a}=r||{};a={...a,...n};for(let s in a){let u=Nv(a[s]);ON(e,s,u)}}i();function zc(e){return e.getProps()[ql]}i();i();var Hc=class extends fu{constructor(){super(...arguments),this.output=[],this.counts=new Map}add(t){let r=lc(t);if(!r)return;let n=this.counts.get(r)||0;this.counts.set(r,n+1),n===0&&(this.output.push(r),this.update());let o=!1;return()=>{if(o)return;o=!0;let a=this.counts.get(r)-1;this.counts.set(r,a),a===0&&(po(this.output,r),this.update())}}update(){this.set(this.output.length?this.output.join(", "):"auto")}};i();function z4(e){return!!(Me(e)&&e.add)}function pu(e,t){var r;if(!e.applyWillChange)return;let n=e.getValue("willChange");if(!n&&!(!((r=e.props.style)===null||r===void 0)&&r.willChange)&&(n=new Hc("auto"),e.addValue("willChange",n)),z4(n))return n.add(t)}function MN({protectedKeys:e,needsAnimating:t},r){let n=e.hasOwnProperty(r)&&t[r]!==!0;return t[r]=!1,n}function Gc(e,t,{delay:r=0,transitionOverride:n,type:o}={}){var a;let{transition:s=e.getDefaultTransition(),transitionEnd:u,...l}=t;n&&(s=n);let c=[],p=o&&e.animationState&&e.animationState.getState()[o];for(let d in l){let h=e.getValue(d,(a=e.latestValues[d])!==null&&a!==void 0?a:null),g=l[d];if(g===void 0||p&&MN(p,d))continue;let v={delay:r,elapsed:0,...ba(s||{},d)},m=!1;if(window.HandoffAppearAnimations){let y=zc(e);if(y){let x=window.HandoffAppearAnimations(y,d,h,pe);x!==null&&(v.elapsed=x,m=!0)}}h.start(Ea(d,h,g,e.shouldReduceMotion&&Pt.has(d)?{type:!1}:v,e,m,pu(e,d)));let b=h.animation;b&&c.push(b)}return u&&Promise.all(c).then(()=>{pe.update(()=>{u&&$4(e,u)})}),c}i();function jc(e,t,r={}){var n;let o=mo(e,t,r.type==="exit"?(n=e.presenceContext)===null||n===void 0?void 0:n.custom:void 0),{transition:a=e.getDefaultTransition()||{}}=o||{};r.transitionOverride&&(a=r.transitionOverride);let s=o?()=>Promise.all(Gc(e,o,r)):()=>Promise.resolve(),u=e.variantChildren&&e.variantChildren.size?(c=0)=>{let{delayChildren:p=0,staggerChildren:d,staggerDirection:h}=a;return IN(e,t,p+c,d,h,r)}:()=>Promise.resolve(),{when:l}=a;if(l){let[c,p]=l==="beforeChildren"?[s,u]:[u,s];return c().then(()=>p())}else return Promise.all([s(),u(r.delay)])}function IN(e,t,r=0,n=0,o=1,a){let s=[],u=(e.variantChildren.size-1)*n,l=o===1?(c=0)=>c*n:(c=0)=>u-c*n;return Array.from(e.variantChildren).sort(kN).forEach((c,p)=>{c.notify("AnimationStart",t),s.push(jc(c,t,{...a,delay:r+l(p)}).then(()=>c.notify("AnimationComplete",t)))}),Promise.all(s)}function kN(e,t){return e.sortNodePosition(t)}function H4(e,t,r={}){e.notify("AnimationStart",t);let n;if(Array.isArray(t)){let o=t.map(a=>jc(e,a,r));n=Promise.all(o)}else if(typeof t=="string")n=jc(e,t,r);else{let o=typeof t=="function"?mo(e,t,r.custom):t;n=Promise.all(Gc(e,o,r))}return n.then(()=>{e.notify("AnimationComplete",t)})}var NN=[...Zl].reverse(),VN=Zl.length;function LN(e){return t=>Promise.all(t.map(({animation:r,options:n})=>H4(e,r,n)))}function j4(e){let t=LN(e),r=G4(),n=!0,o=l=>(c,p)=>{var d;let h=mo(e,p,l==="exit"?(d=e.presenceContext)===null||d===void 0?void 0:d.custom:void 0);if(h){let{transition:g,transitionEnd:v,...m}=h;c={...c,...m,...v}}return c};function a(l){t=l(e)}function s(l){let c=e.getProps(),p=e.getVariantContext(!0)||{},d=[],h=new Set,g={},v=1/0;for(let b=0;b<VN;b++){let y=NN[b],x=r[y],w=c[y]!==void 0?c[y]:p[y],S=En(w),E=y===l?x.isActive:null;E===!1&&(v=b);let D=w===p[y]&&w!==c[y]&&S;if(D&&n&&e.manuallyAnimateOnMount&&(D=!1),x.protectedKeys={...g},!x.isActive&&E===null||!w&&!x.prevProp||Pn(w)||typeof w=="boolean")continue;let R=$N(x.prevProp,w)||y===l&&x.isActive&&!D&&S||b>v&&S,F=!1,M=Array.isArray(w)?w:[w],G=M.reduce(o(y),{});E===!1&&(G={});let{prevResolvedValues:N={}}=x,L={...N,...G},I=V=>{R=!0,h.has(V)&&(F=!0,h.delete(V)),x.needsAnimating[V]=!0;let Y=e.getValue(V);Y&&(Y.liveStyle=!1)};for(let V in L){let Y=G[V],Q=N[V];if(g.hasOwnProperty(V))continue;let re=!1;ou(Y)&&ou(Q)?re=!wm(Y,Q):re=Y!==Q,re?Y!=null?I(V):h.add(V):Y!==void 0&&h.has(V)?I(V):x.protectedKeys[V]=!0}x.prevProp=w,x.prevResolvedValues=G,x.isActive&&(g={...g,...G}),n&&e.blockInitialAnimation&&(R=!1),R&&(!D||F)&&d.push(...M.map(V=>({animation:V,options:{type:y}})))}if(h.size){let b={};h.forEach(y=>{let x=e.getBaseTarget(y),w=e.getValue(y);w&&(w.liveStyle=!0),b[y]=x??null}),d.push({animation:b})}let m=!!d.length;return n&&(c.initial===!1||c.initial===c.animate)&&!e.manuallyAnimateOnMount&&(m=!1),n=!1,m?t(d):Promise.resolve()}function u(l,c){var p;if(r[l].isActive===c)return Promise.resolve();(p=e.variantChildren)===null||p===void 0||p.forEach(h=>{var g;return(g=h.animationState)===null||g===void 0?void 0:g.setActive(l,c)}),r[l].isActive=c;let d=s(l);for(let h in r)r[h].protectedKeys={};return d}return{animateChanges:s,setActive:u,setAnimateFunction:a,getState:()=>r,reset:()=>{r=G4(),n=!0}}}function $N(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!wm(t,e):!1}function ii(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function G4(){return{animate:ii(!0),whileInView:ii(),whileHover:ii(),whileTap:ii(),whileDrag:ii(),whileFocus:ii(),exit:ii()}}var _c=class extends lt{constructor(t){super(t),t.animationState||(t.animationState=j4(t))}updateAnimationControlsSubscription(){let{animate:t}=this.node.getProps();Pn(t)&&(this.unmountControls=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){let{animate:t}=this.node.getProps(),{animate:r}=this.node.prevProps||{};t!==r&&this.updateAnimationControlsSubscription()}unmount(){var t;this.node.animationState.reset(),(t=this.unmountControls)===null||t===void 0||t.call(this)}};i();var zN=0,Wc=class extends lt{constructor(){super(...arguments),this.id=zN++}update(){if(!this.node.presenceContext)return;let{isPresent:t,onExitComplete:r}=this.node.presenceContext,{isPresent:n}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===n)return;let o=this.node.animationState.setActive("exit",!t);r&&!t&&o.then(()=>r(this.id))}mount(){let{register:t}=this.node.presenceContext||{};t&&(this.unmount=t(this.id))}unmount(){}};var _4={animation:{Feature:_c},exit:{Feature:Wc}};i();i();i();i();i();var W4=(e,t)=>Math.abs(e-t);function U4(e,t){let r=W4(e.x,t.x),n=W4(e.y,t.y);return Math.sqrt(r**2+n**2)}var Pa=class{constructor(t,r,{transformPagePoint:n,contextWindow:o,dragSnapToOrigin:a=!1}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;let d=jm(this.lastMoveEventInfo,this.history),h=this.startEvent!==null,g=U4(d.offset,{x:0,y:0})>=3;if(!h&&!g)return;let{point:v}=d,{timestamp:m}=qe;this.history.push({...v,timestamp:m});let{onStart:b,onMove:y}=this.handlers;h||(b&&b(this.lastMoveEvent,d),this.startEvent=this.lastMoveEvent),y&&y(this.lastMoveEvent,d)},this.handlePointerMove=(d,h)=>{this.lastMoveEvent=d,this.lastMoveEventInfo=Gm(h,this.transformPagePoint),pe.update(this.updatePoint,!0)},this.handlePointerUp=(d,h)=>{this.end();let{onEnd:g,onSessionEnd:v,resumeAnimation:m}=this.handlers;if(this.dragSnapToOrigin&&m&&m(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;let b=jm(d.type==="pointercancel"?this.lastMoveEventInfo:Gm(h,this.transformPagePoint),this.history);this.startEvent&&g&&g(d,b),v&&v(d,b)},!pc(t))return;this.dragSnapToOrigin=a,this.handlers=r,this.transformPagePoint=n,this.contextWindow=o||window;let s=ei(t),u=Gm(s,this.transformPagePoint),{point:l}=u,{timestamp:c}=qe;this.history=[{...l,timestamp:c}];let{onSessionStart:p}=r;p&&p(t,jm(u,this.history)),this.removeListeners=Tt(Wt(this.contextWindow,"pointermove",this.handlePointerMove),Wt(this.contextWindow,"pointerup",this.handlePointerUp),Wt(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),It(this.updatePoint)}};function Gm(e,t){return t?{point:t(e.point)}:e}function K4(e,t){return{x:e.x-t.x,y:e.y-t.y}}function jm({point:e},t){return{point:e,delta:K4(e,q4(t)),offset:K4(e,HN(t)),velocity:GN(t,.1)}}function HN(e){return e[0]}function q4(e){return e[e.length-1]}function GN(e,t){if(e.length<2)return{x:0,y:0};let r=e.length-1,n=null,o=q4(e);for(;r>=0&&(n=e[r],!(o.timestamp-n.timestamp>Ut(t)));)r--;if(!n)return{x:0,y:0};let a=Kt(o.timestamp-n.timestamp);if(a===0)return{x:0,y:0};let s={x:(o.x-n.x)/a,y:(o.y-n.y)/a};return s.x===1/0&&(s.x=0),s.y===1/0&&(s.y=0),s}i();i();var Z4=1e-4,jN=1-Z4,_N=1+Z4,Q4=.01,WN=0-Q4,UN=0+Q4;function bt(e){return e.max-e.min}function e7(e,t,r){return Math.abs(e-t)<=r}function X4(e,t,r,n=.5){e.origin=n,e.originPoint=be(t.min,t.max,e.origin),e.scale=bt(r)/bt(t),e.translate=be(r.min,r.max,e.origin)-e.originPoint,(e.scale>=jN&&e.scale<=_N||isNaN(e.scale))&&(e.scale=1),(e.translate>=WN&&e.translate<=UN||isNaN(e.translate))&&(e.translate=0)}function Ta(e,t,r,n){X4(e.x,t.x,r.x,n?n.originX:void 0),X4(e.y,t.y,r.y,n?n.originY:void 0)}function Y4(e,t,r){e.min=r.min+t.min,e.max=e.min+bt(t)}function t7(e,t,r){Y4(e.x,t.x,r.x),Y4(e.y,t.y,r.y)}function J4(e,t,r){e.min=t.min-r.min,e.max=e.min+bt(t)}function Aa(e,t,r){J4(e.x,t.x,r.x),J4(e.y,t.y,r.y)}function a7(e,{min:t,max:r},n){return t!==void 0&&e<t?e=n?be(t,e,n.min):Math.max(e,t):r!==void 0&&e>r&&(e=n?be(r,e,n.max):Math.min(e,r)),e}function r7(e,t,r){return{min:t!==void 0?e.min+t:void 0,max:r!==void 0?e.max+r-(e.max-e.min):void 0}}function s7(e,{top:t,left:r,bottom:n,right:o}){return{x:r7(e.x,r,o),y:r7(e.y,t,n)}}function n7(e,t){let r=t.min-e.min,n=t.max-e.max;return t.max-t.min<e.max-e.min&&([r,n]=[n,r]),{min:r,max:n}}function u7(e,t){return{x:n7(e.x,t.x),y:n7(e.y,t.y)}}function l7(e,t){let r=.5,n=bt(e),o=bt(t);return o>n?r=Rn(t.min,t.max-n,e.min):n>o&&(r=Rn(e.min,e.max-o,t.min)),Ot(0,1,r)}function c7(e,t){let r={};return t.min!==void 0&&(r.min=t.min-e.min),t.max!==void 0&&(r.max=t.max-e.min),r}var Uc=.35;function f7(e=Uc){return e===!1?e=0:e===!0&&(e=Uc),{x:o7(e,"left","right"),y:o7(e,"top","bottom")}}function o7(e,t,r){return{min:i7(e,t),max:i7(e,r)}}function i7(e,t){return typeof e=="number"?e:e[t]||0}i();var p7=()=>({translate:0,scale:1,origin:0,originPoint:0}),ai=()=>({x:p7(),y:p7()}),d7=()=>({min:0,max:0}),Ve=()=>({x:d7(),y:d7()});i();function qt(e){return[e("x"),e("y")]}i();i();function Kc({top:e,left:t,right:r,bottom:n}){return{x:{min:t,max:r},y:{min:e,max:n}}}function m7({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function h7(e,t){if(!t)return e;let r=t({x:e.left,y:e.top}),n=t({x:e.right,y:e.bottom});return{top:r.y,left:r.x,bottom:n.y,right:n.x}}i();i();function _m(e){return e===void 0||e===1}function qc({scale:e,scaleX:t,scaleY:r}){return!_m(e)||!_m(t)||!_m(r)}function Bn(e){return qc(e)||Wm(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function Wm(e){return g7(e.x)||g7(e.y)}function g7(e){return e&&e!=="0%"}function du(e,t,r){let n=e-r,o=t*n;return r+o}function v7(e,t,r,n,o){return o!==void 0&&(e=du(e,o,n)),du(e,r,n)+t}function Um(e,t=0,r=1,n,o){e.min=v7(e.min,t,r,n,o),e.max=v7(e.max,t,r,n,o)}function Km(e,{x:t,y:r}){Um(e.x,t.translate,t.scale,t.originPoint),Um(e.y,r.translate,r.scale,r.originPoint)}var y7=.999999999999,b7=1.0000000000001;function x7(e,t,r,n=!1){let o=r.length;if(!o)return;t.x=t.y=1;let a,s;for(let u=0;u<o;u++){a=r[u],s=a.projectionDelta;let{visualElement:l}=a.options;l&&l.props.style&&l.props.style.display==="contents"||(n&&a.options.layoutScroll&&a.scroll&&a!==a.root&&si(e,{x:-a.scroll.offset.x,y:-a.scroll.offset.y}),s&&(t.x*=s.x.scale,t.y*=s.y.scale,Km(e,s)),n&&Bn(a.latestValues)&&si(e,a.latestValues))}t.x<b7&&t.x>y7&&(t.x=1),t.y<b7&&t.y>y7&&(t.y=1)}function Co(e,t){e.min=e.min+t,e.max=e.max+t}function C7(e,t,r,n,o=.5){let a=be(e.min,e.max,o);Um(e,t,r,a,n)}function si(e,t){C7(e.x,t.x,t.scaleX,t.scale,t.originX),C7(e.y,t.y,t.scaleY,t.scale,t.originY)}function qm(e,t){return Kc(h7(e.getBoundingClientRect(),t))}function w7(e,t,r){let n=qm(e,r),{scroll:o}=t;return o&&(Co(n.x,o.offset.x),Co(n.y,o.offset.y)),n}i();var Xc=({current:e})=>e?e.ownerDocument.defaultView:null;var KN=new WeakMap,Jc=class{constructor(t){this.openGlobalLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=Ve(),this.visualElement=t}start(t,{snapToCursor:r=!1}={}){let{presenceContext:n}=this.visualElement;if(n&&n.isPresent===!1)return;let o=p=>{let{dragSnapToOrigin:d}=this.getProps();d?this.pauseAnimation():this.stopAnimation(),r&&this.snapToCursor(ei(p,"page").point)},a=(p,d)=>{var h;let{drag:g,dragPropagation:v,onDragStart:m}=this.getProps();if(g&&!v&&(this.openGlobalLock&&this.openGlobalLock(),this.openGlobalLock=vm(g),!this.openGlobalLock))return;this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),qt(y=>{let x=this.getAxisMotionValue(y).get()||0;if(Mt.test(x)){let{projection:w}=this.visualElement;if(w&&w.layout){let S=w.layout.layoutBox[y];S&&(x=bt(S)*(parseFloat(x)/100))}}this.originPoint[y]=x}),m&&pe.postRender(()=>m(p,d)),(h=this.removeWillChange)===null||h===void 0||h.call(this),this.removeWillChange=pu(this.visualElement,"transform");let{animationState:b}=this.visualElement;b&&b.setActive("whileDrag",!0)},s=(p,d)=>{let{dragPropagation:h,dragDirectionLock:g,onDirectionLock:v,onDrag:m}=this.getProps();if(!h&&!this.openGlobalLock)return;let{offset:b}=d;if(g&&this.currentDirection===null){this.currentDirection=qN(b),this.currentDirection!==null&&v&&v(this.currentDirection);return}this.updateAxis("x",d.point,b),this.updateAxis("y",d.point,b),this.visualElement.render(),m&&m(p,d)},u=(p,d)=>this.stop(p,d),l=()=>qt(p=>{var d;return this.getAnimationState(p)==="paused"&&((d=this.getAxisMotionValue(p).animation)===null||d===void 0?void 0:d.play())}),{dragSnapToOrigin:c}=this.getProps();this.panSession=new Pa(t,{onSessionStart:o,onStart:a,onMove:s,onSessionEnd:u,resumeAnimation:l},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:c,contextWindow:Xc(this.visualElement)})}stop(t,r){var n;(n=this.removeWillChange)===null||n===void 0||n.call(this);let o=this.isDragging;if(this.cancel(),!o)return;let{velocity:a}=r;this.startAnimation(a);let{onDragEnd:s}=this.getProps();s&&pe.postRender(()=>s(t,r))}cancel(){this.isDragging=!1;let{projection:t,animationState:r}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;let{dragPropagation:n}=this.getProps();!n&&this.openGlobalLock&&(this.openGlobalLock(),this.openGlobalLock=null),r&&r.setActive("whileDrag",!1)}updateAxis(t,r,n){let{drag:o}=this.getProps();if(!n||!Yc(t,o,this.currentDirection))return;let a=this.getAxisMotionValue(t),s=this.originPoint[t]+n[t];this.constraints&&this.constraints[t]&&(s=a7(s,this.constraints[t],this.elastic[t])),a.set(s)}resolveConstraints(){var t;let{dragConstraints:r,dragElastic:n}=this.getProps(),o=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):(t=this.visualElement.projection)===null||t===void 0?void 0:t.layout,a=this.constraints;r&&Dn(r)?this.constraints||(this.constraints=this.resolveRefConstraints()):r&&o?this.constraints=s7(o.layoutBox,r):this.constraints=!1,this.elastic=f7(n),a!==this.constraints&&o&&this.constraints&&!this.hasMutatedConstraints&&qt(s=>{this.constraints!==!1&&this.getAxisMotionValue(s)&&(this.constraints[s]=c7(o.layoutBox[s],this.constraints[s]))})}resolveRefConstraints(){let{dragConstraints:t,onMeasureDragConstraints:r}=this.getProps();if(!t||!Dn(t))return!1;let n=t.current;Vr(n!==null,"If `dragConstraints` is set as a React ref, that ref must be passed to another component's `ref` prop.");let{projection:o}=this.visualElement;if(!o||!o.layout)return!1;let a=w7(n,o.root,this.visualElement.getTransformPagePoint()),s=u7(o.layout.layoutBox,a);if(r){let u=r(m7(s));this.hasMutatedConstraints=!!u,u&&(s=Kc(u))}return s}startAnimation(t){let{drag:r,dragMomentum:n,dragElastic:o,dragTransition:a,dragSnapToOrigin:s,onDragTransitionEnd:u}=this.getProps(),l=this.constraints||{},c=qt(p=>{if(!Yc(p,r,this.currentDirection))return;let d=l&&l[p]||{};s&&(d={min:0,max:0});let h=o?200:1e6,g=o?40:1e7,v={type:"inertia",velocity:n?t[p]:0,bounceStiffness:h,bounceDamping:g,timeConstant:750,restDelta:1,restSpeed:10,...a,...d};return this.startAxisValueAnimation(p,v)});return Promise.all(c).then(u)}startAxisValueAnimation(t,r){let n=this.getAxisMotionValue(t);return n.start(Ea(t,n,0,r,this.visualElement,!1,pu(this.visualElement,t)))}stopAnimation(){qt(t=>this.getAxisMotionValue(t).stop())}pauseAnimation(){qt(t=>{var r;return(r=this.getAxisMotionValue(t).animation)===null||r===void 0?void 0:r.pause()})}getAnimationState(t){var r;return(r=this.getAxisMotionValue(t).animation)===null||r===void 0?void 0:r.state}getAxisMotionValue(t){let r=`_drag${t.toUpperCase()}`,n=this.visualElement.getProps(),o=n[r];return o||this.visualElement.getValue(t,(n.initial?n.initial[t]:void 0)||0)}snapToCursor(t){qt(r=>{let{drag:n}=this.getProps();if(!Yc(r,n,this.currentDirection))return;let{projection:o}=this.visualElement,a=this.getAxisMotionValue(r);if(o&&o.layout){let{min:s,max:u}=o.layout.layoutBox[r];a.set(t[r]-be(s,u,.5))}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;let{drag:t,dragConstraints:r}=this.getProps(),{projection:n}=this.visualElement;if(!Dn(r)||!n||!this.constraints)return;this.stopAnimation();let o={x:0,y:0};qt(s=>{let u=this.getAxisMotionValue(s);if(u&&this.constraints!==!1){let l=u.get();o[s]=l7({min:l,max:l},this.constraints[s])}});let{transformTemplate:a}=this.visualElement.getProps();this.visualElement.current.style.transform=a?a({},""):"none",n.root&&n.root.updateScroll(),n.updateLayout(),this.resolveConstraints(),qt(s=>{if(!Yc(s,t,null))return;let u=this.getAxisMotionValue(s),{min:l,max:c}=this.constraints[s];u.set(be(l,c,o[s]))})}addListeners(){if(!this.visualElement.current)return;KN.set(this.visualElement,this);let t=this.visualElement.current,r=Wt(t,"pointerdown",l=>{let{drag:c,dragListener:p=!0}=this.getProps();c&&p&&this.start(l)}),n=()=>{let{dragConstraints:l}=this.getProps();Dn(l)&&l.current&&(this.constraints=this.resolveRefConstraints())},{projection:o}=this.visualElement,a=o.addEventListener("measure",n);o&&!o.layout&&(o.root&&o.root.updateScroll(),o.updateLayout()),pe.read(n);let s=_t(window,"resize",()=>this.scalePositionWithinConstraints()),u=o.addEventListener("didUpdate",({delta:l,hasLayoutChanged:c})=>{this.isDragging&&c&&(qt(p=>{let d=this.getAxisMotionValue(p);d&&(this.originPoint[p]+=l[p].translate,d.set(d.get()+l[p].translate))}),this.visualElement.render())});return()=>{s(),r(),a(),u&&u()}}getProps(){let t=this.visualElement.getProps(),{drag:r=!1,dragDirectionLock:n=!1,dragPropagation:o=!1,dragConstraints:a=!1,dragElastic:s=Uc,dragMomentum:u=!0}=t;return{...t,drag:r,dragDirectionLock:n,dragPropagation:o,dragConstraints:a,dragElastic:s,dragMomentum:u}}};function Yc(e,t,r){return(t===!0||t===e)&&(r===null||r===e)}function qN(e,t=10){let r=null;return Math.abs(e.y)>t?r="y":Math.abs(e.x)>t&&(r="x"),r}var Zc=class extends lt{constructor(t){super(t),this.removeGroupControls=Ae,this.removeListeners=Ae,this.controls=new Jc(t)}mount(){let{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||Ae}unmount(){this.removeGroupControls(),this.removeListeners()}};i();var S7=e=>(t,r)=>{e&&pe.postRender(()=>e(t,r))},Qc=class extends lt{constructor(){super(...arguments),this.removePointerDownListener=Ae}onPointerDown(t){this.session=new Pa(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:Xc(this.node)})}createPanHandlers(){let{onPanSessionStart:t,onPanStart:r,onPan:n,onPanEnd:o}=this.node.getProps();return{onSessionStart:S7(t),onStart:S7(r),onMove:n,onEnd:(a,s)=>{delete this.session,o&&pe.postRender(()=>o(a,s))}}}mount(){this.removePointerDownListener=Wt(this.node.current,"pointerdown",t=>this.onPointerDown(t))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}};i();import{jsx as QN}from"react/jsx-runtime";import{useContext as T7,Component as eV}from"react";i();import{useContext as XN,useId as YN,useEffect as JN,useCallback as ZN}from"react";function D7(){let e=XN(io);if(e===null)return[!0,null];let{isPresent:t,onExitComplete:r,register:n}=e,o=YN();JN(()=>n(o),[]);let a=ZN(()=>r&&r(o),[o,r]);return!t&&r?[!1,a]:[!0]}i();var Ra={hasAnimatedSinceResize:!0,hasEverUpdated:!1};i();function E7(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}var Fa={correct:(e,t)=>{if(!t.target)return e;if(typeof e=="string")if(ie.test(e))e=parseFloat(e);else return e;let r=E7(e,t.target.x),n=E7(e,t.target.y);return`${r}% ${n}%`}};i();var P7={correct:(e,{treeScale:t,projectionDelta:r})=>{let n=e,o=kt.parse(e);if(o.length>5)return n;let a=kt.createTransformer(e),s=typeof o[0]!="number"?1:0,u=r.x.scale*t.x,l=r.y.scale*t.y;o[0+s]/=u,o[1+s]/=l;let c=be(u,l,.5);return typeof o[2+s]=="number"&&(o[2+s]/=c),typeof o[3+s]=="number"&&(o[3+s]/=c),a(o)}};var Xm=class extends eV{componentDidMount(){let{visualElement:t,layoutGroup:r,switchLayoutGroup:n,layoutId:o}=this.props,{projection:a}=t;mv(tV),a&&(r.group&&r.group.add(a),n&&n.register&&o&&n.register(a),a.root.didUpdate(),a.addEventListener("animationComplete",()=>{this.safeToRemove()}),a.setOptions({...a.options,onExitComplete:()=>this.safeToRemove()})),Ra.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){let{layoutDependency:r,visualElement:n,drag:o,isPresent:a}=this.props,s=n.projection;return s&&(s.isPresent=a,o||t.layoutDependency!==r||r===void 0?s.willUpdate():this.safeToRemove(),t.isPresent!==a&&(a?s.promote():s.relegate()||pe.postRender(()=>{let u=s.getStack();(!u||!u.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){let{projection:t}=this.props.visualElement;t&&(t.root.didUpdate(),oa.postRender(()=>{!t.currentAnimation&&t.isLead()&&this.safeToRemove()}))}componentWillUnmount(){let{visualElement:t,layoutGroup:r,switchLayoutGroup:n}=this.props,{projection:o}=t;o&&(o.scheduleCheckAfterUnmount(),r&&r.group&&r.group.remove(o),n&&n.deregister&&n.deregister(o))}safeToRemove(){let{safeToRemove:t}=this.props;t&&t()}render(){return null}};function ef(e){let[t,r]=D7(),n=T7(ia);return QN(Xm,{...e,layoutGroup:n,switchLayoutGroup:T7(Jl),isPresent:t,safeToRemove:r})}var tV={borderRadius:{...Fa,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:Fa,borderTopRightRadius:Fa,borderBottomLeftRadius:Fa,borderBottomRightRadius:Fa,boxShadow:P7};i();i();i();var B7=["TopLeft","TopRight","BottomLeft","BottomRight"],rV=B7.length,A7=e=>typeof e=="string"?parseFloat(e):e,R7=e=>typeof e=="number"||ie.test(e);function O7(e,t,r,n,o,a){o?(e.opacity=be(0,r.opacity!==void 0?r.opacity:1,nV(n)),e.opacityExit=be(t.opacity!==void 0?t.opacity:1,0,oV(n))):a&&(e.opacity=be(t.opacity!==void 0?t.opacity:1,r.opacity!==void 0?r.opacity:1,n));for(let s=0;s<rV;s++){let u=`border${B7[s]}Radius`,l=F7(t,u),c=F7(r,u);if(l===void 0&&c===void 0)continue;l||(l=0),c||(c=0),l===0||c===0||R7(l)===R7(c)?(e[u]=Math.max(be(A7(l),A7(c),n),0),(Mt.test(c)||Mt.test(l))&&(e[u]+="%")):e[u]=c}(t.rotate||r.rotate)&&(e.rotate=be(t.rotate||0,r.rotate||0,n))}function F7(e,t){return e[t]!==void 0?e[t]:e.borderRadius}var nV=M7(0,.5,Ic),oV=M7(.5,.95,Ae);function M7(e,t,r){return n=>n<e?0:n>t?1:r(Rn(e,t,n))}i();function I7(e,t){e.min=t.min,e.max=t.max}function cr(e,t){I7(e.x,t.x),I7(e.y,t.y)}function Ym(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}i();function k7(e,t,r,n,o){return e-=t,e=du(e,1/r,n),o!==void 0&&(e=du(e,1/o,n)),e}function iV(e,t=0,r=1,n=.5,o,a=e,s=e){if(Mt.test(t)&&(t=parseFloat(t),t=be(s.min,s.max,t/100)-s.min),typeof t!="number")return;let u=be(a.min,a.max,n);e===a&&(u-=t),e.min=k7(e.min,t,r,u,o),e.max=k7(e.max,t,r,u,o)}function N7(e,t,[r,n,o],a,s){iV(e,t[r],t[n],t[o],t.scale,a,s)}var aV=["x","scaleX","originX"],sV=["y","scaleY","originY"];function Jm(e,t,r,n){N7(e.x,t,aV,r?r.x:void 0,n?n.x:void 0),N7(e.y,t,sV,r?r.y:void 0,n?n.y:void 0)}i();function V7(e){return e.translate===0&&e.scale===1}function Zm(e){return V7(e.x)&&V7(e.y)}function L7(e,t){return e.min===t.min&&e.max===t.max}function z7(e,t){return L7(e.x,t.x)&&L7(e.y,t.y)}function $7(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function Qm(e,t){return $7(e.x,t.x)&&$7(e.y,t.y)}function e0(e){return bt(e.x)/bt(e.y)}function t0(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}i();var tf=class{constructor(){this.members=[]}add(t){fo(this.members,t),t.scheduleRender()}remove(t){if(po(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){let r=this.members[this.members.length-1];r&&this.promote(r)}}relegate(t){let r=this.members.findIndex(o=>t===o);if(r===0)return!1;let n;for(let o=r;o>=0;o--){let a=this.members[o];if(a.isPresent!==!1){n=a;break}}return n?(this.promote(n),!0):!1}promote(t,r){let n=this.lead;if(t!==n&&(this.prevLead=n,this.lead=t,t.show(),n)){n.instance&&n.scheduleRender(),t.scheduleRender(),t.resumeFrom=n,r&&(t.resumeFrom.preserveOpacity=!0),n.snapshot&&(t.snapshot=n.snapshot,t.snapshot.latestValues=n.animationValues||n.latestValues),t.root&&t.root.isUpdating&&(t.isLayoutDirty=!0);let{crossfade:o}=t.options;o===!1&&n.hide()}}exitAnimationComplete(){this.members.forEach(t=>{let{options:r,resumingFrom:n}=t;r.onExitComplete&&r.onExitComplete(),n&&n.options.onExitComplete&&n.options.onExitComplete()})}scheduleRender(){this.members.forEach(t=>{t.instance&&t.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}};i();function H7(e,t,r){let n="",o=e.x.translate/t.x,a=e.y.translate/t.y,s=r?.z||0;if((o||a||s)&&(n=`translate3d(${o}px, ${a}px, ${s}px) `),(t.x!==1||t.y!==1)&&(n+=`scale(${1/t.x}, ${1/t.y}) `),r){let{transformPerspective:c,rotate:p,rotateX:d,rotateY:h,skewX:g,skewY:v}=r;c&&(n=`perspective(${c}px) ${n}`),p&&(n+=`rotate(${p}deg) `),d&&(n+=`rotateX(${d}deg) `),h&&(n+=`rotateY(${h}deg) `),g&&(n+=`skewX(${g}deg) `),v&&(n+=`skewY(${v}deg) `)}let u=e.x.scale*t.x,l=e.y.scale*t.y;return(u!==1||l!==1)&&(n+=`scale(${u}, ${l})`),n||"none"}i();i();var G7=(e,t)=>e.depth-t.depth;var rf=class{constructor(){this.children=[],this.isDirty=!1}add(t){fo(this.children,t),this.isDirty=!0}remove(t){po(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(G7),this.isDirty=!1,this.children.forEach(t)}};i();function j7(e,t){let r=lr.now(),n=({timestamp:o})=>{let a=o-r;a>=t&&(It(n),e(a-t))};return pe.read(n,!0),()=>It(n)}i();function _7(e){return e instanceof SVGElement&&e.tagName!=="svg"}i();function W7(e,t,r){let n=Me(e)?e:Fn(e);return n.start(Ea("",n,t,r)),n.animation}var ui={type:"projectionFrame",totalNodes:0,resolvedTargetDeltas:0,recalculatedProjection:0},mu=typeof window<"u"&&window.MotionDebug!==void 0,r0=["","X","Y","Z"],uV={visibility:"hidden"},U7=1e3,lV=0;function n0(e,t,r,n){let{latestValues:o}=t;o[e]&&(r[e]=o[e],t.setStaticValue(e,0),n&&(n[e]=0))}function e6(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return!1;let{visualElement:t}=e.options;return t?zc(t)?!0:e.parent&&!e.parent.hasCheckedOptimisedAppear?e6(e.parent):!1:!1}function nf({attachResizeListener:e,defaultParent:t,measureScroll:r,checkIsScrollRoot:n,resetTransform:o}){return class{constructor(s={},u=t?.()){this.id=lV++,this.animationId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,mu&&(ui.totalNodes=ui.resolvedTargetDeltas=ui.recalculatedProjection=0),this.nodes.forEach(pV),this.nodes.forEach(vV),this.nodes.forEach(yV),this.nodes.forEach(dV),mu&&window.MotionDebug.record(ui)},this.resolvedRelativeTargetAt=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=s,this.root=u?u.root||u:this,this.path=u?[...u.path,u]:[],this.parent=u,this.depth=u?u.depth+1:0;for(let l=0;l<this.path.length;l++)this.path[l].shouldResetTransform=!0;this.root===this&&(this.nodes=new rf)}addEventListener(s,u){return this.eventHandlers.has(s)||this.eventHandlers.set(s,new bo),this.eventHandlers.get(s).add(u)}notifyListeners(s,...u){let l=this.eventHandlers.get(s);l&&l.notify(...u)}hasListeners(s){return this.eventHandlers.has(s)}mount(s,u=this.root.hasTreeAnimated){if(this.instance)return;this.isSVG=_7(s),this.instance=s;let{layoutId:l,layout:c,visualElement:p}=this.options;if(p&&!p.current&&p.mount(s),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),u&&(c||l)&&(this.isLayoutDirty=!0),e){let d,h=()=>this.root.updateBlockedByResize=!1;e(s,()=>{this.root.updateBlockedByResize=!0,d&&d(),d=j7(h,250),Ra.hasAnimatedSinceResize&&(Ra.hasAnimatedSinceResize=!1,this.nodes.forEach(q7))})}l&&this.root.registerSharedNode(l,this),this.options.animate!==!1&&p&&(l||c)&&this.addEventListener("didUpdate",({delta:d,hasLayoutChanged:h,hasRelativeTargetChanged:g,layout:v})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}let m=this.options.transition||p.getDefaultTransition()||SV,{onLayoutAnimationStart:b,onLayoutAnimationComplete:y}=p.getProps(),x=!this.targetLayout||!Qm(this.targetLayout,v)||g,w=!h&&g;if(this.options.layoutRoot||this.resumeFrom&&this.resumeFrom.instance||w||h&&(x||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0),this.setAnimationOrigin(d,w);let S={...ba(m,"layout"),onPlay:b,onComplete:y};(p.shouldReduceMotion||this.options.layoutRoot)&&(S.delay=0,S.type=!1),this.startAnimation(S)}else h||q7(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=v})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);let s=this.getStack();s&&s.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,It(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(bV),this.animationId++)}getTransformTemplate(){let{visualElement:s}=this.options;return s&&s.getProps().transformTemplate}willUpdate(s=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.HandoffCancelAllAnimations&&e6(this)&&window.HandoffCancelAllAnimations(),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let p=0;p<this.path.length;p++){let d=this.path[p];d.shouldResetTransform=!0,d.updateScroll("snapshot"),d.options.layoutRoot&&d.willUpdate(!1)}let{layoutId:u,layout:l}=this.options;if(u===void 0&&!l)return;let c=this.getTransformTemplate();this.prevTransformTemplateValue=c?c(this.latestValues,""):void 0,this.updateSnapshot(),s&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){this.unblockUpdate(),this.clearAllSnapshots(),this.nodes.forEach(K7);return}this.isUpdating||this.nodes.forEach(hV),this.isUpdating=!1,this.nodes.forEach(gV),this.nodes.forEach(cV),this.nodes.forEach(fV),this.clearAllSnapshots();let u=lr.now();qe.delta=Ot(0,1e3/60,u-qe.timestamp),qe.timestamp=u,qe.isProcessing=!0,fc.update.process(qe),fc.preRender.process(qe),fc.render.process(qe),qe.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,oa.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(mV),this.sharedNodes.forEach(CV)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,pe.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){pe.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure())}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let l=0;l<this.path.length;l++)this.path[l].updateScroll();let s=this.layout;this.layout=this.measure(!1),this.layoutCorrected=Ve(),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);let{visualElement:u}=this.options;u&&u.notify("LayoutMeasure",this.layout.layoutBox,s?s.layoutBox:void 0)}updateScroll(s="measure"){let u=!!(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===s&&(u=!1),u){let l=n(this.instance);this.scroll={animationId:this.root.animationId,phase:s,isRoot:l,offset:r(this.instance),wasRoot:this.scroll?this.scroll.isRoot:l}}}resetTransform(){if(!o)return;let s=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,u=this.projectionDelta&&!Zm(this.projectionDelta),l=this.getTransformTemplate(),c=l?l(this.latestValues,""):void 0,p=c!==this.prevTransformTemplateValue;s&&(u||Bn(this.latestValues)||p)&&(o(this.instance,c),this.shouldResetTransform=!1,this.scheduleRender())}measure(s=!0){let u=this.measurePageBox(),l=this.removeElementScroll(u);return s&&(l=this.removeTransform(l)),DV(l),{animationId:this.root.animationId,measuredBox:u,layoutBox:l,latestValues:{},source:this.id}}measurePageBox(){var s;let{visualElement:u}=this.options;if(!u)return Ve();let l=u.measureViewportBox();if(!(((s=this.scroll)===null||s===void 0?void 0:s.wasRoot)||this.path.some(EV))){let{scroll:p}=this.root;p&&(Co(l.x,p.offset.x),Co(l.y,p.offset.y))}return l}removeElementScroll(s){var u;let l=Ve();if(cr(l,s),!((u=this.scroll)===null||u===void 0)&&u.wasRoot)return l;for(let c=0;c<this.path.length;c++){let p=this.path[c],{scroll:d,options:h}=p;p!==this.root&&d&&h.layoutScroll&&(d.wasRoot&&cr(l,s),Co(l.x,d.offset.x),Co(l.y,d.offset.y))}return l}applyTransform(s,u=!1){let l=Ve();cr(l,s);for(let c=0;c<this.path.length;c++){let p=this.path[c];!u&&p.options.layoutScroll&&p.scroll&&p!==p.root&&si(l,{x:-p.scroll.offset.x,y:-p.scroll.offset.y}),Bn(p.latestValues)&&si(l,p.latestValues)}return Bn(this.latestValues)&&si(l,this.latestValues),l}removeTransform(s){let u=Ve();cr(u,s);for(let l=0;l<this.path.length;l++){let c=this.path[l];if(!c.instance||!Bn(c.latestValues))continue;qc(c.latestValues)&&c.updateSnapshot();let p=Ve(),d=c.measurePageBox();cr(p,d),Jm(u,c.latestValues,c.snapshot?c.snapshot.layoutBox:void 0,p)}return Bn(this.latestValues)&&Jm(u,this.latestValues),u}setTargetDelta(s){this.targetDelta=s,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(s){this.options={...this.options,...s,crossfade:s.crossfade!==void 0?s.crossfade:!0}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==qe.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(s=!1){var u;let l=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=l.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=l.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=l.isSharedProjectionDirty);let c=!!this.resumingFrom||this!==l;if(!(s||c&&this.isSharedProjectionDirty||this.isProjectionDirty||!((u=this.parent)===null||u===void 0)&&u.isProjectionDirty||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;let{layout:d,layoutId:h}=this.options;if(!(!this.layout||!(d||h))){if(this.resolvedRelativeTargetAt=qe.timestamp,!this.targetDelta&&!this.relativeTarget){let g=this.getClosestProjectingParent();g&&g.layout&&this.animationProgress!==1?(this.relativeParent=g,this.forceRelativeParentToResolveTarget(),this.relativeTarget=Ve(),this.relativeTargetOrigin=Ve(),Aa(this.relativeTargetOrigin,this.layout.layoutBox,g.layout.layoutBox),cr(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}if(!(!this.relativeTarget&&!this.targetDelta)){if(this.target||(this.target=Ve(),this.targetWithTransforms=Ve()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),t7(this.target,this.relativeTarget,this.relativeParent.target)):this.targetDelta?(this.resumingFrom?this.target=this.applyTransform(this.layout.layoutBox):cr(this.target,this.layout.layoutBox),Km(this.target,this.targetDelta)):cr(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget){this.attemptToResolveRelativeTarget=!1;let g=this.getClosestProjectingParent();g&&!!g.resumingFrom==!!this.resumingFrom&&!g.options.layoutScroll&&g.target&&this.animationProgress!==1?(this.relativeParent=g,this.forceRelativeParentToResolveTarget(),this.relativeTarget=Ve(),this.relativeTargetOrigin=Ve(),Aa(this.relativeTargetOrigin,this.target,g.target),cr(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}mu&&ui.resolvedTargetDeltas++}}}getClosestProjectingParent(){if(!(!this.parent||qc(this.parent.latestValues)||Wm(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}calcProjection(){var s;let u=this.getLead(),l=!!this.resumingFrom||this!==u,c=!0;if((this.isProjectionDirty||!((s=this.parent)===null||s===void 0)&&s.isProjectionDirty)&&(c=!1),l&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(c=!1),this.resolvedRelativeTargetAt===qe.timestamp&&(c=!1),c)return;let{layout:p,layoutId:d}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(p||d))return;cr(this.layoutCorrected,this.layout.layoutBox);let h=this.treeScale.x,g=this.treeScale.y;x7(this.layoutCorrected,this.treeScale,this.path,l),u.layout&&!u.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(u.target=u.layout.layoutBox,u.targetWithTransforms=Ve());let{target:v}=u;if(!v){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}!this.projectionDelta||!this.prevProjectionDelta?this.createProjectionDeltas():(Ym(this.prevProjectionDelta.x,this.projectionDelta.x),Ym(this.prevProjectionDelta.y,this.projectionDelta.y)),Ta(this.projectionDelta,this.layoutCorrected,v,this.latestValues),(this.treeScale.x!==h||this.treeScale.y!==g||!t0(this.projectionDelta.x,this.prevProjectionDelta.x)||!t0(this.projectionDelta.y,this.prevProjectionDelta.y))&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",v)),mu&&ui.recalculatedProjection++}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(s=!0){var u;if((u=this.options.visualElement)===null||u===void 0||u.scheduleRender(),s){let l=this.getStack();l&&l.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=ai(),this.projectionDelta=ai(),this.projectionDeltaWithTransform=ai()}setAnimationOrigin(s,u=!1){let l=this.snapshot,c=l?l.latestValues:{},p={...this.latestValues},d=ai();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!u;let h=Ve(),g=l?l.source:void 0,v=this.layout?this.layout.source:void 0,m=g!==v,b=this.getStack(),y=!b||b.members.length<=1,x=!!(m&&!y&&this.options.crossfade===!0&&!this.path.some(wV));this.animationProgress=0;let w;this.mixTargetDelta=S=>{let E=S/1e3;X7(d.x,s.x,E),X7(d.y,s.y,E),this.setTargetDelta(d),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(Aa(h,this.layout.layoutBox,this.relativeParent.layout.layoutBox),xV(this.relativeTarget,this.relativeTargetOrigin,h,E),w&&z7(this.relativeTarget,w)&&(this.isProjectionDirty=!1),w||(w=Ve()),cr(w,this.relativeTarget)),m&&(this.animationValues=p,O7(p,c,this.latestValues,E,x,y)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=E},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(s){this.notifyListeners("animationStart"),this.currentAnimation&&this.currentAnimation.stop(),this.resumingFrom&&this.resumingFrom.currentAnimation&&this.resumingFrom.currentAnimation.stop(),this.pendingAnimation&&(It(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=pe.update(()=>{Ra.hasAnimatedSinceResize=!0,this.currentAnimation=W7(0,U7,{...s,onUpdate:u=>{this.mixTargetDelta(u),s.onUpdate&&s.onUpdate(u)},onComplete:()=>{s.onComplete&&s.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);let s=this.getStack();s&&s.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(U7),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){let s=this.getLead(),{targetWithTransforms:u,target:l,layout:c,latestValues:p}=s;if(!(!u||!l||!c)){if(this!==s&&this.layout&&c&&t6(this.options.animationType,this.layout.layoutBox,c.layoutBox)){l=this.target||Ve();let d=bt(this.layout.layoutBox.x);l.x.min=s.target.x.min,l.x.max=l.x.min+d;let h=bt(this.layout.layoutBox.y);l.y.min=s.target.y.min,l.y.max=l.y.min+h}cr(u,l),si(u,p),Ta(this.projectionDeltaWithTransform,this.layoutCorrected,u,p)}}registerSharedNode(s,u){this.sharedNodes.has(s)||this.sharedNodes.set(s,new tf),this.sharedNodes.get(s).add(u);let c=u.options.initialPromotionConfig;u.promote({transition:c?c.transition:void 0,preserveFollowOpacity:c&&c.shouldPreserveFollowOpacity?c.shouldPreserveFollowOpacity(u):void 0})}isLead(){let s=this.getStack();return s?s.lead===this:!0}getLead(){var s;let{layoutId:u}=this.options;return u?((s=this.getStack())===null||s===void 0?void 0:s.lead)||this:this}getPrevLead(){var s;let{layoutId:u}=this.options;return u?(s=this.getStack())===null||s===void 0?void 0:s.prevLead:void 0}getStack(){let{layoutId:s}=this.options;if(s)return this.root.sharedNodes.get(s)}promote({needsReset:s,transition:u,preserveFollowOpacity:l}={}){let c=this.getStack();c&&c.promote(this,l),s&&(this.projectionDelta=void 0,this.needsReset=!0),u&&this.setOptions({transition:u})}relegate(){let s=this.getStack();return s?s.relegate(this):!1}resetSkewAndRotation(){let{visualElement:s}=this.options;if(!s)return;let u=!1,{latestValues:l}=s;if((l.z||l.rotate||l.rotateX||l.rotateY||l.rotateZ||l.skewX||l.skewY)&&(u=!0),!u)return;let c={};l.z&&n0("z",s,c,this.animationValues);for(let p=0;p<r0.length;p++)n0(`rotate${r0[p]}`,s,c,this.animationValues),n0(`skew${r0[p]}`,s,c,this.animationValues);s.render();for(let p in c)s.setStaticValue(p,c[p]),this.animationValues&&(this.animationValues[p]=c[p]);s.scheduleRender()}getProjectionStyles(s){var u,l;if(!this.instance||this.isSVG)return;if(!this.isVisible)return uV;let c={visibility:""},p=this.getTransformTemplate();if(this.needsReset)return this.needsReset=!1,c.opacity="",c.pointerEvents=ya(s?.pointerEvents)||"",c.transform=p?p(this.latestValues,""):"none",c;let d=this.getLead();if(!this.projectionDelta||!this.layout||!d.target){let m={};return this.options.layoutId&&(m.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,m.pointerEvents=ya(s?.pointerEvents)||""),this.hasProjected&&!Bn(this.latestValues)&&(m.transform=p?p({},""):"none",this.hasProjected=!1),m}let h=d.animationValues||d.latestValues;this.applyTransformsToTarget(),c.transform=H7(this.projectionDeltaWithTransform,this.treeScale,h),p&&(c.transform=p(h,c.transform));let{x:g,y:v}=this.projectionDelta;c.transformOrigin=`${g.origin*100}% ${v.origin*100}% 0`,d.animationValues?c.opacity=d===this?(l=(u=h.opacity)!==null&&u!==void 0?u:this.latestValues.opacity)!==null&&l!==void 0?l:1:this.preserveOpacity?this.latestValues.opacity:h.opacityExit:c.opacity=d===this?h.opacity!==void 0?h.opacity:"":h.opacityExit!==void 0?h.opacityExit:0;for(let m in sa){if(h[m]===void 0)continue;let{correct:b,applyTo:y}=sa[m],x=c.transform==="none"?h[m]:b(h[m],d);if(y){let w=y.length;for(let S=0;S<w;S++)c[y[S]]=x}else c[m]=x}return this.options.layoutId&&(c.pointerEvents=d===this?ya(s?.pointerEvents)||"":"none"),c}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(s=>{var u;return(u=s.currentAnimation)===null||u===void 0?void 0:u.stop()}),this.root.nodes.forEach(K7),this.root.sharedNodes.clear()}}}function cV(e){e.updateLayout()}function fV(e){var t;let r=((t=e.resumeFrom)===null||t===void 0?void 0:t.snapshot)||e.snapshot;if(e.isLead()&&e.layout&&r&&e.hasListeners("didUpdate")){let{layoutBox:n,measuredBox:o}=e.layout,{animationType:a}=e.options,s=r.source!==e.layout.source;a==="size"?qt(d=>{let h=s?r.measuredBox[d]:r.layoutBox[d],g=bt(h);h.min=n[d].min,h.max=h.min+g}):t6(a,r.layoutBox,n)&&qt(d=>{let h=s?r.measuredBox[d]:r.layoutBox[d],g=bt(n[d]);h.max=h.min+g,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[d].max=e.relativeTarget[d].min+g)});let u=ai();Ta(u,n,r.layoutBox);let l=ai();s?Ta(l,e.applyTransform(o,!0),r.measuredBox):Ta(l,n,r.layoutBox);let c=!Zm(u),p=!1;if(!e.resumeFrom){let d=e.getClosestProjectingParent();if(d&&!d.resumeFrom){let{snapshot:h,layout:g}=d;if(h&&g){let v=Ve();Aa(v,r.layoutBox,h.layoutBox);let m=Ve();Aa(m,n,g.layoutBox),Qm(v,m)||(p=!0),d.options.layoutRoot&&(e.relativeTarget=m,e.relativeTargetOrigin=v,e.relativeParent=d)}}}e.notifyListeners("didUpdate",{layout:n,snapshot:r,delta:l,layoutDelta:u,hasLayoutChanged:c,hasRelativeTargetChanged:p})}else if(e.isLead()){let{onExitComplete:n}=e.options;n&&n()}e.options.transition=void 0}function pV(e){mu&&ui.totalNodes++,e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function dV(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function mV(e){e.clearSnapshot()}function K7(e){e.clearMeasurements()}function hV(e){e.isLayoutDirty=!1}function gV(e){let{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function q7(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function vV(e){e.resolveTargetDelta()}function yV(e){e.calcProjection()}function bV(e){e.resetSkewAndRotation()}function CV(e){e.removeLeadSnapshot()}function X7(e,t,r){e.translate=be(t.translate,0,r),e.scale=be(t.scale,1,r),e.origin=t.origin,e.originPoint=t.originPoint}function Y7(e,t,r,n){e.min=be(t.min,r.min,n),e.max=be(t.max,r.max,n)}function xV(e,t,r,n){Y7(e.x,t.x,r.x,n),Y7(e.y,t.y,r.y,n)}function wV(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}var SV={duration:.45,ease:[.4,0,.1,1]},J7=e=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),Z7=J7("applewebkit/")&&!J7("chrome/")?Math.round:Ae;function Q7(e){e.min=Z7(e.min),e.max=Z7(e.max)}function DV(e){Q7(e.x),Q7(e.y)}function t6(e,t,r){return e==="position"||e==="preserve-aspect"&&!e7(e0(t),e0(r),.2)}function EV(e){var t;return e!==e.root&&((t=e.scroll)===null||t===void 0?void 0:t.wasRoot)}i();var r6=nf({attachResizeListener:(e,t)=>_t(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0});var o0={current:void 0},of=nf({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!o0.current){let e=new r6({});e.mount(window),e.setOptions({layoutScroll:!0}),o0.current=e}return o0.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"});var n6={pan:{Feature:Qc},drag:{Feature:Zc,ProjectionNode:of,MeasureLayout:ef}};i();import{Fragment as RV}from"react";i();i();i();i();i();var hu={current:null},af={current:!1};function o6(){if(af.current=!0,!!na)if(window.matchMedia){let e=window.matchMedia("(prefers-reduced-motion)"),t=()=>hu.current=e.matches;e.addListener(t),t()}else hu.current=!1}i();function i6(e,t,r){for(let n in t){let o=t[n],a=r[n];if(Me(o))e.addValue(n,o);else if(Me(a))e.addValue(n,Fn(o,{owner:e}));else if(a!==o)if(e.hasValue(n)){let s=e.getValue(n);s.liveStyle===!0?s.jump(o):s.hasAnimated||s.set(o)}else{let s=e.getStaticValue(n);e.addValue(n,Fn(s!==void 0?s:o,{owner:e}))}}for(let n in r)t[n]===void 0&&e.removeValue(n);return t}i();var i0=new WeakMap;i();var PV=[...Em,Ze,kt],a6=e=>PV.find(wc(e));var s6=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"],TV=eu.length,sf=class{scrapeMotionValuesFromProps(t,r,n){return{}}constructor({parent:t,props:r,presenceContext:n,reducedMotionConfig:o,blockInitialAnimation:a,visualState:s},u={}){this.applyWillChange=!1,this.resolveKeyframes=(h,g,v,m)=>new this.KeyframeResolver(h,g,v,m,this),this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=go,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.isRenderScheduled=!1,this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.isRenderScheduled=!1,this.scheduleRender=()=>{this.isRenderScheduled||(this.isRenderScheduled=!0,pe.render(this.render,!1,!0))};let{latestValues:l,renderState:c}=s;this.latestValues=l,this.baseTarget={...l},this.initialValues=r.initial?{...l}:{},this.renderState=c,this.parent=t,this.props=r,this.presenceContext=n,this.depth=t?t.depth+1:0,this.reducedMotionConfig=o,this.options=u,this.blockInitialAnimation=!!a,this.isControllingVariants=Qo(r),this.isVariantNode=Ql(r),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(t&&t.current);let{willChange:p,...d}=this.scrapeMotionValuesFromProps(r,{},this);for(let h in d){let g=d[h];l[h]!==void 0&&Me(g)&&g.set(l[h],!1)}}mount(t){this.current=t,i0.set(t,this),this.projection&&!this.projection.instance&&this.projection.mount(t),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((r,n)=>this.bindToMotionValue(n,r)),af.current||o6(),this.shouldReduceMotion=this.reducedMotionConfig==="never"?!1:this.reducedMotionConfig==="always"?!0:hu.current,this.parent&&this.parent.children.add(this),this.update(this.props,this.presenceContext)}unmount(){i0.delete(this.current),this.projection&&this.projection.unmount(),It(this.notifyUpdate),It(this.render),this.valueSubscriptions.forEach(t=>t()),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent&&this.parent.children.delete(this);for(let t in this.events)this.events[t].clear();for(let t in this.features){let r=this.features[t];r&&(r.unmount(),r.isMounted=!1)}this.current=null}bindToMotionValue(t,r){let n=Pt.has(t),o=r.on("change",s=>{this.latestValues[t]=s,this.props.onUpdate&&pe.preRender(this.notifyUpdate),n&&this.projection&&(this.projection.isTransformDirty=!0)}),a=r.on("renderRequest",this.scheduleRender);this.valueSubscriptions.set(t,()=>{o(),a(),r.owner&&r.stop()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}updateFeatures(){let t="animation";for(t in Tn){let r=Tn[t];if(!r)continue;let{isEnabled:n,Feature:o}=r;if(!this.features[t]&&o&&n(this.props)&&(this.features[t]=new o(this)),this.features[t]){let a=this.features[t];a.isMounted?a.update():(a.mount(),a.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):Ve()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,r){this.latestValues[t]=r}update(t,r){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=r;for(let n=0;n<s6.length;n++){let o=s6[n];this.propEventSubscriptions[o]&&(this.propEventSubscriptions[o](),delete this.propEventSubscriptions[o]);let a="on"+o,s=t[a];s&&(this.propEventSubscriptions[o]=this.on(o,s))}this.prevMotionValues=i6(this,this.scrapeMotionValuesFromProps(t,this.prevProps,this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(t){return this.props.variants?this.props.variants[t]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}getVariantContext(t=!1){if(t)return this.parent?this.parent.getVariantContext():void 0;if(!this.isControllingVariants){let n=this.parent?this.parent.getVariantContext()||{}:{};return this.props.initial!==void 0&&(n.initial=this.props.initial),n}let r={};for(let n=0;n<TV;n++){let o=eu[n],a=this.props[o];(En(a)||a===!1)&&(r[o]=a)}return r}addVariantChild(t){let r=this.getClosestVariantNode();if(r)return r.variantChildren&&r.variantChildren.add(t),()=>r.variantChildren.delete(t)}addValue(t,r){let n=this.values.get(t);r!==n&&(n&&this.removeValue(t),this.bindToMotionValue(t,r),this.values.set(t,r),this.latestValues[t]=r.get())}removeValue(t){this.values.delete(t);let r=this.valueSubscriptions.get(t);r&&(r(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,r){if(this.props.values&&this.props.values[t])return this.props.values[t];let n=this.values.get(t);return n===void 0&&r!==void 0&&(n=Fn(r===null?void 0:r,{owner:this}),this.addValue(t,n)),n}readValue(t,r){var n;let o=this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:(n=this.getBaseTargetFromProps(this.props,t))!==null&&n!==void 0?n:this.readValueFromInstance(this.current,t,this.options);return o!=null&&(typeof o=="string"&&(xc(o)||Cc(o))?o=parseFloat(o):!a6(o)&&kt.test(r)&&(o=Dc(t,r)),this.setBaseTarget(t,Me(o)?o.get():o)),Me(o)?o.get():o}setBaseTarget(t,r){this.baseTarget[t]=r}getBaseTarget(t){var r;let{initial:n}=this.props,o;if(typeof n=="string"||typeof n=="object"){let s=ga(this.props,n,(r=this.presenceContext)===null||r===void 0?void 0:r.custom);s&&(o=s[t])}if(n&&o!==void 0)return o;let a=this.getBaseTargetFromProps(this.props,t);return a!==void 0&&!Me(a)?a:this.initialValues[t]!==void 0&&o===void 0?void 0:this.baseTarget[t]}on(t,r){return this.events[t]||(this.events[t]=new bo),this.events[t].add(r)}notify(t,...r){this.events[t]&&this.events[t].notify(...r)}};var Ba=class extends sf{constructor(){super(...arguments),this.KeyframeResolver=wa}sortInstanceNodePosition(t,r){return t.compareDocumentPosition(r)&2?1:-1}getBaseTargetFromProps(t,r){return t.style?t.style[r]:void 0}removeValueFromRenderState(t,{vars:r,style:n}){delete r[t],delete n[t]}};function AV(e){return window.getComputedStyle(e)}var uf=class extends Ba{constructor(){super(...arguments),this.type="html",this.applyWillChange=!0,this.renderInstance=oc}readValueFromInstance(t,r){if(Pt.has(r)){let n=xa(r);return n&&n.default||0}else{let n=AV(t),o=(rc(r)?n.getPropertyValue(r):n[r])||0;return typeof o=="string"?o.trim():o}}measureInstanceViewportBox(t,{transformPagePoint:r}){return qm(t,r)}build(t,r,n){fa(t,r,n.transformTemplate)}scrapeMotionValuesFromProps(t,r,n){return ha(t,r,n)}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);let{children:t}=this.props;Me(t)&&(this.childSubscription=t.on("change",r=>{this.current&&(this.current.textContent=`${r}`)}))}};i();var lf=class extends Ba{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=Ve}getBaseTargetFromProps(t,r){return t[r]}readValueFromInstance(t,r){if(Pt.has(r)){let n=xa(r);return n&&n.default||0}return r=ic.has(r)?r:ao(r),t.getAttribute(r)}scrapeMotionValuesFromProps(t,r,n){return sc(t,r,n)}build(t,r,n){da(t,r,this.isSVGTag,n.transformTemplate)}renderInstance(t,r,n,o){ac(t,r,n,o)}mount(t){this.isSVGTag=ma(t.tagName),super.mount(t)}};var u6=(e,t)=>aa(e)?new lf(t):new uf(t,{allowProjection:e!==RV});i();var l6={layout:{ProjectionNode:of,MeasureLayout:ef}};var FV={..._4,...qv,...n6,...l6},gu=pv((e,t)=>Hv(e,t,FV,u6));i();import{jsx as g6,Fragment as $V}from"react/jsx-runtime";import{useMemo as zV,useRef as v6,useState as y6,useContext as HV}from"react";i();import{jsx as p6}from"react/jsx-runtime";import*as m6 from"react";import{useId as kV,useMemo as d6}from"react";i();import{jsx as BV}from"react/jsx-runtime";import*as cf from"react";import{useId as OV,useRef as c6,useContext as MV,useInsertionEffect as IV}from"react";var a0=class extends cf.Component{getSnapshotBeforeUpdate(t){let r=this.props.childRef.current;if(r&&t.isPresent&&!this.props.isPresent){let n=this.props.sizeRef.current;n.height=r.offsetHeight||0,n.width=r.offsetWidth||0,n.top=r.offsetTop,n.left=r.offsetLeft}return null}componentDidUpdate(){}render(){return this.props.children}};function f6({children:e,isPresent:t}){let r=OV(),n=c6(null),o=c6({width:0,height:0,top:0,left:0}),{nonce:a}=MV(ra);return IV(()=>{let{width:s,height:u,top:l,left:c}=o.current;if(t||!n.current||!s||!u)return;n.current.dataset.motionPopId=r;let p=document.createElement("style");return a&&(p.nonce=a),document.head.appendChild(p),p.sheet&&p.sheet.insertRule(`
101
101
  [data-motion-pop-id="${r}"] {
102
102
  position: absolute !important;
103
103
  width: ${s}px !important;
@@ -705,7 +705,7 @@ var zO=Object.create;var Nl=Object.defineProperty;var HO=Object.getOwnPropertyDe
705
705
  `;var zb=_L`
706
706
  ${Lb}
707
707
  ${$b}
708
- `;import{jsx as wu,jsxs as WL}from"react/jsx-runtime";var pBe=({children:e,theme:t={},globalStylesIncluded:r=!0,skipAnimations:n=!1,Link:o})=>(n&&(Sn.skipAnimations=!0),WL(w6,{theme:t,children:[r?wu(zb,{}):null,wu(um,{children:wu(E6,{value:{Link:o},children:wu(Cf,{children:wu(S0,{children:e})})})})]}));i();i();import{useState as UL,useCallback as T0}from"react";var A0=(e=!1)=>{let[t,r]=UL(e),n=T0(()=>r(s=>!s),[]),o=T0(()=>r(!0),[]),a=T0(()=>r(!1),[]);return[t,n,o,a,r]};i();i();import{useCallback as XL}from"react";i();i();import{useEffect as KL,useRef as Hb,useState as qL}from"react";var xf=e=>{let[t,r]=qL(!1),n=Hb(),o=Hb(e),a=s=>{clearTimeout(n.current),r(!o.current),n.current=window.setTimeout(()=>r(o.current),s)};return KL(()=>()=>clearTimeout(n.current),[]),[t,a]};var YL=(e,t=1500)=>{let[r,n]=xf(!1),[o,a]=xf(!1);return[XL(async()=>{try{await Vs(e),t&&t>0&&n(t)}catch(u){u instanceof Error&&a(t)}},[e,t,n,a]),r,o]};i();i();import{useMemo as JL,useState as ZL,useRef as QL,useLayoutEffect as e$}from"react";var t$={width:0,height:0,top:0,left:0,bottom:0,right:0,x:0,y:0},R0=()=>{let e=QL(null),[t,r]=ZL(t$),n=JL(()=>new window.ResizeObserver(o=>{if(o[0]){let{width:a,height:s,top:u,left:l,bottom:c,right:p,x:d,y:h}=o[0].contentRect;r({width:a,height:s,top:u,left:l,bottom:c,right:p,x:d,y:h})}}),[]);return e$(()=>{if(e.current)return n.observe(e.current),()=>{n.disconnect()}},[n]),[e,t]};i();i();import{useEffect as F0,useRef as Gb}from"react";var r$=e=>!!(typeof e=="object"&&e?.addEventListener),B0=(e,t,r=window,n={})=>{let o=Gb(),a=Gb();F0(()=>{o.current=t},[t]),F0(()=>{a.current=n},[n]),F0(()=>{if(!e||!r$(r))return;let s=u=>o.current!==void 0?o.current(u):()=>{};return r.addEventListener(e,s,a.current),()=>{r.removeEventListener(e,s,a.current)}},[e,r,a])};i();i();var rC=U(Z());import{useRef as tC,useCallback as i$,useEffect as a$}from"react";i();var M0='a[href], area[href], input:not([disabled]), select:not([disabled]), textarea:not([disabled]), button:not([disabled]), iframe, object, [tabindex="0"], [contenteditable]',n$=e=>{let{display:t,visibility:r}=window.getComputedStyle(e),n=t==="none"||e.style.display==="none"||r==="none"||e.style.visibility==="hidden";return e.offsetWidth<=0&&e.offsetHeight<=0||n},o$=e=>{let t=e;for(;t&&t!==document.body;){if(n$(t))return!1;t=t.parentNode}return!0},jb=e=>{let t=e.getAttribute("tabindex");return Number.parseInt(t??void 0,10)},_b=e=>{let t=jb(e);return Number.isNaN(t)},wf=e=>{let t=/input|select|textarea|button|object/,r=e.nodeName.toLowerCase(),n=!_b(e);return!!(t.test(r)&&!e.disabled||e instanceof HTMLAnchorElement&&e.href||n)&&o$(e)},I0=e=>{let t=jb(e);return(_b(e)||t>=0)&&wf(e)},Wb=e=>Array.from(e.querySelectorAll(M0)).filter(I0),Ub=[],ka=null,O0=!1,Kb=()=>{O0=!0},qb=()=>{if(O0){if(O0=!1,!ka||ka.contains(document.activeElement))return;(Wb(ka)[0]??ka).focus()}},Xb=()=>{let e=document.activeElement;e!==null&&Ub.push(e)},Yb=()=>{let e=null;try{e=Ub.pop(),e&&e.focus()}catch{console.warn(["You tried to return focus to",e,"but it is not in the DOM anymore"].join(" "))}},Jb=e=>{ka=e,document.addEventListener("focusout",Kb,!1),document.addEventListener("focusin",qb,!0)},Zb=()=>{ka=null,document.removeEventListener("focusout",Kb),document.removeEventListener("focusin",qb)},Qb=(e,t)=>{let r=Wb(e);if(!r.length){t.preventDefault();return}if(!(r[t.shiftKey?0:r.length-1]===document.activeElement||e===document.activeElement))return;t.preventDefault();let a=r[t.shiftKey?r.length-1:0];a&&a.focus()},eC=(e,t)=>{t===void 0&&(t="body > :not(script)");let r=Array.from(document.querySelectorAll(t)).map(n=>{if(n.contains(e))return;let o=n.getAttribute("aria-hidden");return(o===null||o==="false")&&n.setAttribute("aria-hidden","true"),{node:n,ariaHidden:o}});return()=>{r.forEach(n=>{n&&(n.ariaHidden===null?n.node.removeAttribute("aria-hidden"):n.node.setAttribute("aria-hidden",n.ariaHidden))})}};var k0=(e=!0,t={})=>{let r=tC(null),n=tC(null),o=i$(a=>{if(n.current!==null&&n.current(),r.current&&(Yb(),Zb()),e&&a!==null&&a!==void 0){Jb(a),Xb();let s=u=>{n.current=t.disableAriaHider??!1?null:eC(u);let l=null;if((0,rC.isNotUndefined)(t.focusSelector)&&(l=typeof t.focusSelector=="string"?u.querySelector(t.focusSelector):t.focusSelector),!l){let c=Array.from(u.querySelectorAll(M0));l=c.find(I0)??c.find(wf)??null,!l&&wf(u)&&(l=u)}l&&l.focus()};setTimeout(()=>{a.ownerDocument&&s(a),a.ownerDocument}),r.current=a}else r.current=null},[e,t.focusSelector,t.disableAriaHider]);return a$(()=>{if(!e)return;let a=s=>{s.key==="Tab"&&r.current&&Qb(r.current,s)};return document.addEventListener("keydown",a),()=>{document.removeEventListener("keydown",a)}},[e]),o};i();i();import{useCallback as s$,useState as u$}from"react";var l$=()=>{let[,e]=u$(Object.create(null));return s$(()=>{e(Object.create(null))},[e])};i();i();i();var c$=function(t){return f$(t)&&!p$(t)};function f$(e){return!!e&&typeof e=="object"}function p$(e){var t=Object.prototype.toString.call(e);return t==="[object RegExp]"||t==="[object Date]"||h$(e)}var d$=typeof Symbol=="function"&&Symbol.for,m$=d$?Symbol.for("react.element"):60103;function h$(e){return e.$$typeof===m$}function g$(e){return Array.isArray(e)?[]:{}}function Sf(e,t){return t.clone!==!1&&t.isMergeableObject(e)?Su(g$(e),e,t):e}function v$(e,t,r){return e.concat(t).map(function(n){return Sf(n,r)})}function y$(e,t,r){var n={};return r.isMergeableObject(e)&&Object.keys(e).forEach(function(o){n[o]=Sf(e[o],r)}),Object.keys(t).forEach(function(o){!r.isMergeableObject(t[o])||!e[o]?n[o]=Sf(t[o],r):n[o]=Su(e[o],t[o],r)}),n}function Su(e,t,r){r=r||{},r.arrayMerge=r.arrayMerge||v$,r.isMergeableObject=r.isMergeableObject||c$;var n=Array.isArray(t),o=Array.isArray(e),a=n===o;return a?n?r.arrayMerge(e,t,r):y$(e,t,r):Sf(t,r)}Su.all=function(t,r){if(!Array.isArray(t))throw new Error("first argument should be an array");return t.reduce(function(n,o){return Su(n,o,r)},{})};var b$=Su,Df=b$;i();i();i();i();i();var C$=typeof window=="object"&&window&&window.Object===Object&&window,Ef=C$;var x$=typeof self=="object"&&self&&self.Object===Object&&self,w$=Ef||x$||Function("return this")(),tt=w$;var S$=tt.Symbol,xr=S$;i();var nC=Object.prototype,D$=nC.hasOwnProperty,E$=nC.toString,Du=xr?xr.toStringTag:void 0;function P$(e){var t=D$.call(e,Du),r=e[Du];try{e[Du]=void 0;var n=!0}catch{}var o=E$.call(e);return n&&(t?e[Du]=r:delete e[Du]),o}var oC=P$;i();var T$=Object.prototype,A$=T$.toString;function R$(e){return A$.call(e)}var iC=R$;var F$="[object Null]",B$="[object Undefined]",aC=xr?xr.toStringTag:void 0;function O$(e){return e==null?e===void 0?B$:F$:aC&&aC in Object(e)?oC(e):iC(e)}var fr=O$;i();i();function M$(e,t){return function(r){return e(t(r))}}var Pf=M$;var I$=Pf(Object.getPrototypeOf,Object),Na=I$;i();function k$(e){return e!=null&&typeof e=="object"}var Xt=k$;var N$="[object Object]",V$=Function.prototype,L$=Object.prototype,sC=V$.toString,$$=L$.hasOwnProperty,z$=sC.call(Object);function H$(e){if(!Xt(e)||fr(e)!=N$)return!1;var t=Na(e);if(t===null)return!0;var r=$$.call(t,"constructor")&&t.constructor;return typeof r=="function"&&r instanceof r&&sC.call(r)==z$}var N0=H$;i();i();i();i();i();function G$(){this.__data__=[],this.size=0}var uC=G$;i();i();i();function j$(e,t){return e===t||e!==e&&t!==t}var Tf=j$;function _$(e,t){for(var r=e.length;r--;)if(Tf(e[r][0],t))return r;return-1}var wo=_$;var W$=Array.prototype,U$=W$.splice;function K$(e){var t=this.__data__,r=wo(t,e);if(r<0)return!1;var n=t.length-1;return r==n?t.pop():U$.call(t,r,1),--this.size,!0}var lC=K$;i();function q$(e){var t=this.__data__,r=wo(t,e);return r<0?void 0:t[r][1]}var cC=q$;i();function X$(e){return wo(this.__data__,e)>-1}var fC=X$;i();function Y$(e,t){var r=this.__data__,n=wo(r,e);return n<0?(++this.size,r.push([e,t])):r[n][1]=t,this}var pC=Y$;function Va(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}Va.prototype.clear=uC;Va.prototype.delete=lC;Va.prototype.get=cC;Va.prototype.has=fC;Va.prototype.set=pC;var So=Va;i();function J$(){this.__data__=new So,this.size=0}var dC=J$;i();function Z$(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r}var mC=Z$;i();function Q$(e){return this.__data__.get(e)}var hC=Q$;i();function ez(e){return this.__data__.has(e)}var gC=ez;i();i();i();i();i();i();function tz(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var Zr=tz;var rz="[object AsyncFunction]",nz="[object Function]",oz="[object GeneratorFunction]",iz="[object Proxy]";function az(e){if(!Zr(e))return!1;var t=fr(e);return t==nz||t==oz||t==rz||t==iz}var Af=az;i();i();var sz=tt["__core-js_shared__"],Rf=sz;var vC=function(){var e=/[^.]+$/.exec(Rf&&Rf.keys&&Rf.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function uz(e){return!!vC&&vC in e}var yC=uz;i();var lz=Function.prototype,cz=lz.toString;function fz(e){if(e!=null){try{return cz.call(e)}catch{}try{return e+""}catch{}}return""}var In=fz;var pz=/[\\^$.*+?()[\]{}|]/g,dz=/^\[object .+?Constructor\]$/,mz=Function.prototype,hz=Object.prototype,gz=mz.toString,vz=hz.hasOwnProperty,yz=RegExp("^"+gz.call(vz).replace(pz,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function bz(e){if(!Zr(e)||yC(e))return!1;var t=Af(e)?yz:dz;return t.test(In(e))}var bC=bz;i();function Cz(e,t){return e?.[t]}var CC=Cz;function xz(e,t){var r=CC(e,t);return bC(r)?r:void 0}var Yt=xz;var wz=Yt(tt,"Map"),Do=wz;i();i();i();i();i();var Sz=Yt(Object,"create"),kn=Sz;function Dz(){this.__data__=kn?kn(null):{},this.size=0}var xC=Dz;i();function Ez(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var wC=Ez;i();var Pz="__lodash_hash_undefined__",Tz=Object.prototype,Az=Tz.hasOwnProperty;function Rz(e){var t=this.__data__;if(kn){var r=t[e];return r===Pz?void 0:r}return Az.call(t,e)?t[e]:void 0}var SC=Rz;i();var Fz=Object.prototype,Bz=Fz.hasOwnProperty;function Oz(e){var t=this.__data__;return kn?t[e]!==void 0:Bz.call(t,e)}var DC=Oz;i();var Mz="__lodash_hash_undefined__";function Iz(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=kn&&t===void 0?Mz:t,this}var EC=Iz;function La(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}La.prototype.clear=xC;La.prototype.delete=wC;La.prototype.get=SC;La.prototype.has=DC;La.prototype.set=EC;var V0=La;function kz(){this.size=0,this.__data__={hash:new V0,map:new(Do||So),string:new V0}}var PC=kz;i();i();i();function Nz(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}var TC=Nz;function Vz(e,t){var r=e.__data__;return TC(t)?r[typeof t=="string"?"string":"hash"]:r.map}var Eo=Vz;function Lz(e){var t=Eo(this,e).delete(e);return this.size-=t?1:0,t}var AC=Lz;i();function $z(e){return Eo(this,e).get(e)}var RC=$z;i();function zz(e){return Eo(this,e).has(e)}var FC=zz;i();function Hz(e,t){var r=Eo(this,e),n=r.size;return r.set(e,t),this.size+=r.size==n?0:1,this}var BC=Hz;function $a(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}$a.prototype.clear=PC;$a.prototype.delete=AC;$a.prototype.get=RC;$a.prototype.has=FC;$a.prototype.set=BC;var Eu=$a;var Gz=200;function jz(e,t){var r=this.__data__;if(r instanceof So){var n=r.__data__;if(!Do||n.length<Gz-1)return n.push([e,t]),this.size=++r.size,this;r=this.__data__=new Eu(n)}return r.set(e,t),this.size=r.size,this}var OC=jz;function za(e){var t=this.__data__=new So(e);this.size=t.size}za.prototype.clear=dC;za.prototype.delete=mC;za.prototype.get=hC;za.prototype.has=gC;za.prototype.set=OC;var MC=za;i();function _z(e,t){for(var r=-1,n=e==null?0:e.length;++r<n&&t(e[r],r,e)!==!1;);return e}var IC=_z;i();i();i();var Wz=function(){try{var e=Yt(Object,"defineProperty");return e({},"",{}),e}catch{}}(),L0=Wz;function Uz(e,t,r){t=="__proto__"&&L0?L0(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r}var Ff=Uz;var Kz=Object.prototype,qz=Kz.hasOwnProperty;function Xz(e,t,r){var n=e[t];(!(qz.call(e,t)&&Tf(n,r))||r===void 0&&!(t in e))&&Ff(e,t,r)}var Bf=Xz;i();i();function Yz(e,t,r,n){var o=!r;r||(r={});for(var a=-1,s=t.length;++a<s;){var u=t[a],l=n?n(r[u],e[u],u,r,e):void 0;l===void 0&&(l=e[u]),o?Ff(r,u,l):Bf(r,u,l)}return r}var Po=Yz;i();i();i();function Jz(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}var kC=Jz;i();i();var Zz="[object Arguments]";function Qz(e){return Xt(e)&&fr(e)==Zz}var $0=Qz;var NC=Object.prototype,eH=NC.hasOwnProperty,tH=NC.propertyIsEnumerable,rH=$0(function(){return arguments}())?$0:function(e){return Xt(e)&&eH.call(e,"callee")&&!tH.call(e,"callee")},VC=rH;i();var nH=Array.isArray,Qr=nH;i();i();function oH(){return!1}var LC=oH;var HC=typeof exports=="object"&&exports&&!exports.nodeType&&exports,$C=HC&&typeof module=="object"&&module&&!module.nodeType&&module,iH=$C&&$C.exports===HC,zC=iH?tt.Buffer:void 0,aH=zC?zC.isBuffer:void 0,sH=aH||LC,Of=sH;i();var uH=9007199254740991,lH=/^(?:0|[1-9]\d*)$/;function cH(e,t){var r=typeof e;return t=t??uH,!!t&&(r=="number"||r!="symbol"&&lH.test(e))&&e>-1&&e%1==0&&e<t}var GC=cH;i();i();i();var fH=9007199254740991;function pH(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=fH}var Mf=pH;var dH="[object Arguments]",mH="[object Array]",hH="[object Boolean]",gH="[object Date]",vH="[object Error]",yH="[object Function]",bH="[object Map]",CH="[object Number]",xH="[object Object]",wH="[object RegExp]",SH="[object Set]",DH="[object String]",EH="[object WeakMap]",PH="[object ArrayBuffer]",TH="[object DataView]",AH="[object Float32Array]",RH="[object Float64Array]",FH="[object Int8Array]",BH="[object Int16Array]",OH="[object Int32Array]",MH="[object Uint8Array]",IH="[object Uint8ClampedArray]",kH="[object Uint16Array]",NH="[object Uint32Array]",Le={};Le[AH]=Le[RH]=Le[FH]=Le[BH]=Le[OH]=Le[MH]=Le[IH]=Le[kH]=Le[NH]=!0;Le[dH]=Le[mH]=Le[PH]=Le[hH]=Le[TH]=Le[gH]=Le[vH]=Le[yH]=Le[bH]=Le[CH]=Le[xH]=Le[wH]=Le[SH]=Le[DH]=Le[EH]=!1;function VH(e){return Xt(e)&&Mf(e.length)&&!!Le[fr(e)]}var jC=VH;i();function LH(e){return function(t){return e(t)}}var Ha=LH;i();var _C=typeof exports=="object"&&exports&&!exports.nodeType&&exports,Pu=_C&&typeof module=="object"&&module&&!module.nodeType&&module,$H=Pu&&Pu.exports===_C,z0=$H&&Ef.process,zH=function(){try{var e=Pu&&Pu.require&&Pu.require("util").types;return e||z0&&z0.binding&&z0.binding("util")}catch{}}(),Nn=zH;var WC=Nn&&Nn.isTypedArray,HH=WC?Ha(WC):jC,UC=HH;var GH=Object.prototype,jH=GH.hasOwnProperty;function _H(e,t){var r=Qr(e),n=!r&&VC(e),o=!r&&!n&&Of(e),a=!r&&!n&&!o&&UC(e),s=r||n||o||a,u=s?kC(e.length,String):[],l=u.length;for(var c in e)(t||jH.call(e,c))&&!(s&&(c=="length"||o&&(c=="offset"||c=="parent")||a&&(c=="buffer"||c=="byteLength"||c=="byteOffset")||GC(c,l)))&&u.push(c);return u}var If=_H;i();i();var WH=Object.prototype;function UH(e){var t=e&&e.constructor,r=typeof t=="function"&&t.prototype||WH;return e===r}var Ga=UH;i();var KH=Pf(Object.keys,Object),KC=KH;var qH=Object.prototype,XH=qH.hasOwnProperty;function YH(e){if(!Ga(e))return KC(e);var t=[];for(var r in Object(e))XH.call(e,r)&&r!="constructor"&&t.push(r);return t}var qC=YH;i();function JH(e){return e!=null&&Mf(e.length)&&!Af(e)}var kf=JH;function ZH(e){return kf(e)?If(e):qC(e)}var ja=ZH;function QH(e,t){return e&&Po(t,ja(t),e)}var XC=QH;i();i();i();i();function eG(e){var t=[];if(e!=null)for(var r in Object(e))t.push(r);return t}var YC=eG;var tG=Object.prototype,rG=tG.hasOwnProperty;function nG(e){if(!Zr(e))return YC(e);var t=Ga(e),r=[];for(var n in e)n=="constructor"&&(t||!rG.call(e,n))||r.push(n);return r}var JC=nG;function oG(e){return kf(e)?If(e,!0):JC(e)}var _a=oG;function iG(e,t){return e&&Po(t,_a(t),e)}var ZC=iG;i();var rx=typeof exports=="object"&&exports&&!exports.nodeType&&exports,QC=rx&&typeof module=="object"&&module&&!module.nodeType&&module,aG=QC&&QC.exports===rx,ex=aG?tt.Buffer:void 0,tx=ex?ex.allocUnsafe:void 0;function sG(e,t){if(t)return e.slice();var r=e.length,n=tx?tx(r):new e.constructor(r);return e.copy(n),n}var nx=sG;i();function uG(e,t){var r=-1,n=e.length;for(t||(t=Array(n));++r<n;)t[r]=e[r];return t}var Nf=uG;i();i();i();function lG(e,t){for(var r=-1,n=e==null?0:e.length,o=0,a=[];++r<n;){var s=e[r];t(s,r,e)&&(a[o++]=s)}return a}var ox=lG;i();function cG(){return[]}var Vf=cG;var fG=Object.prototype,pG=fG.propertyIsEnumerable,ix=Object.getOwnPropertySymbols,dG=ix?function(e){return e==null?[]:(e=Object(e),ox(ix(e),function(t){return pG.call(e,t)}))}:Vf,Wa=dG;function mG(e,t){return Po(e,Wa(e),t)}var ax=mG;i();i();i();function hG(e,t){for(var r=-1,n=t.length,o=e.length;++r<n;)e[o+r]=t[r];return e}var Lf=hG;var gG=Object.getOwnPropertySymbols,vG=gG?function(e){for(var t=[];e;)Lf(t,Wa(e)),e=Na(e);return t}:Vf,$f=vG;function yG(e,t){return Po(e,$f(e),t)}var sx=yG;i();i();function bG(e,t,r){var n=t(e);return Qr(e)?n:Lf(n,r(e))}var zf=bG;function CG(e){return zf(e,ja,Wa)}var ux=CG;i();function xG(e){return zf(e,_a,$f)}var lx=xG;i();i();var wG=Yt(tt,"DataView"),Hf=wG;i();var SG=Yt(tt,"Promise"),Gf=SG;i();var DG=Yt(tt,"Set"),jf=DG;i();var EG=Yt(tt,"WeakMap"),_f=EG;var cx="[object Map]",PG="[object Object]",fx="[object Promise]",px="[object Set]",dx="[object WeakMap]",mx="[object DataView]",TG=In(Hf),AG=In(Do),RG=In(Gf),FG=In(jf),BG=In(_f),fi=fr;(Hf&&fi(new Hf(new ArrayBuffer(1)))!=mx||Do&&fi(new Do)!=cx||Gf&&fi(Gf.resolve())!=fx||jf&&fi(new jf)!=px||_f&&fi(new _f)!=dx)&&(fi=function(e){var t=fr(e),r=t==PG?e.constructor:void 0,n=r?In(r):"";if(n)switch(n){case TG:return mx;case AG:return cx;case RG:return fx;case FG:return px;case BG:return dx}return t});var Ua=fi;i();var OG=Object.prototype,MG=OG.hasOwnProperty;function IG(e){var t=e.length,r=new e.constructor(t);return t&&typeof e[0]=="string"&&MG.call(e,"index")&&(r.index=e.index,r.input=e.input),r}var hx=IG;i();i();i();var kG=tt.Uint8Array,H0=kG;function NG(e){var t=new e.constructor(e.byteLength);return new H0(t).set(new H0(e)),t}var Ka=NG;i();function VG(e,t){var r=t?Ka(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.byteLength)}var gx=VG;i();var LG=/\w*$/;function $G(e){var t=new e.constructor(e.source,LG.exec(e));return t.lastIndex=e.lastIndex,t}var vx=$G;i();var yx=xr?xr.prototype:void 0,bx=yx?yx.valueOf:void 0;function zG(e){return bx?Object(bx.call(e)):{}}var Cx=zG;i();function HG(e,t){var r=t?Ka(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.length)}var xx=HG;var GG="[object Boolean]",jG="[object Date]",_G="[object Map]",WG="[object Number]",UG="[object RegExp]",KG="[object Set]",qG="[object String]",XG="[object Symbol]",YG="[object ArrayBuffer]",JG="[object DataView]",ZG="[object Float32Array]",QG="[object Float64Array]",ej="[object Int8Array]",tj="[object Int16Array]",rj="[object Int32Array]",nj="[object Uint8Array]",oj="[object Uint8ClampedArray]",ij="[object Uint16Array]",aj="[object Uint32Array]";function sj(e,t,r){var n=e.constructor;switch(t){case YG:return Ka(e);case GG:case jG:return new n(+e);case JG:return gx(e,r);case ZG:case QG:case ej:case tj:case rj:case nj:case oj:case ij:case aj:return xx(e,r);case _G:return new n;case WG:case qG:return new n(e);case UG:return vx(e);case KG:return new n;case XG:return Cx(e)}}var wx=sj;i();i();var Sx=Object.create,uj=function(){function e(){}return function(t){if(!Zr(t))return{};if(Sx)return Sx(t);e.prototype=t;var r=new e;return e.prototype=void 0,r}}(),Dx=uj;function lj(e){return typeof e.constructor=="function"&&!Ga(e)?Dx(Na(e)):{}}var Ex=lj;i();i();var cj="[object Map]";function fj(e){return Xt(e)&&Ua(e)==cj}var Px=fj;var Tx=Nn&&Nn.isMap,pj=Tx?Ha(Tx):Px,Ax=pj;i();i();var dj="[object Set]";function mj(e){return Xt(e)&&Ua(e)==dj}var Rx=mj;var Fx=Nn&&Nn.isSet,hj=Fx?Ha(Fx):Rx,Bx=hj;var gj=1,vj=2,yj=4,Ox="[object Arguments]",bj="[object Array]",Cj="[object Boolean]",xj="[object Date]",wj="[object Error]",Mx="[object Function]",Sj="[object GeneratorFunction]",Dj="[object Map]",Ej="[object Number]",Ix="[object Object]",Pj="[object RegExp]",Tj="[object Set]",Aj="[object String]",Rj="[object Symbol]",Fj="[object WeakMap]",Bj="[object ArrayBuffer]",Oj="[object DataView]",Mj="[object Float32Array]",Ij="[object Float64Array]",kj="[object Int8Array]",Nj="[object Int16Array]",Vj="[object Int32Array]",Lj="[object Uint8Array]",$j="[object Uint8ClampedArray]",zj="[object Uint16Array]",Hj="[object Uint32Array]",Ie={};Ie[Ox]=Ie[bj]=Ie[Bj]=Ie[Oj]=Ie[Cj]=Ie[xj]=Ie[Mj]=Ie[Ij]=Ie[kj]=Ie[Nj]=Ie[Vj]=Ie[Dj]=Ie[Ej]=Ie[Ix]=Ie[Pj]=Ie[Tj]=Ie[Aj]=Ie[Rj]=Ie[Lj]=Ie[$j]=Ie[zj]=Ie[Hj]=!0;Ie[wj]=Ie[Mx]=Ie[Fj]=!1;function Wf(e,t,r,n,o,a){var s,u=t&gj,l=t&vj,c=t&yj;if(r&&(s=o?r(e,n,o,a):r(e)),s!==void 0)return s;if(!Zr(e))return e;var p=Qr(e);if(p){if(s=hx(e),!u)return Nf(e,s)}else{var d=Ua(e),h=d==Mx||d==Sj;if(Of(e))return nx(e,u);if(d==Ix||d==Ox||h&&!o){if(s=l||h?{}:Ex(e),!u)return l?sx(e,ZC(s,e)):ax(e,XC(s,e))}else{if(!Ie[d])return o?e:{};s=wx(e,d,u)}}a||(a=new MC);var g=a.get(e);if(g)return g;a.set(e,s),Bx(e)?e.forEach(function(b){s.add(Wf(b,t,r,b,e,a))}):Ax(e)&&e.forEach(function(b,y){s.set(y,Wf(b,t,r,y,e,a))});var v=c?l?lx:ux:l?_a:ja,m=p?void 0:v(e);return IC(m||e,function(b,y){m&&(y=b,b=e[y]),Bf(s,y,Wf(b,t,r,y,e,a))}),s}var Uf=Wf;var Gj=1,jj=4;function _j(e){return Uf(e,Gj|jj)}var qa=_j;var Vn=U(Lx());import{createContext as S_,useContext as D_,Children as th,useRef as To,useEffect as Ao,useState as E_,useCallback as rt,useMemo as aw,useImperativeHandle as P_,createElement as Ro,useLayoutEffect as T_,forwardRef as A_,Component as R_}from"react";i();var Kj=!0;function qj(e,t){if(!Kj){if(e)return;var r="Warning: "+t;typeof console<"u"&&console.warn(r);try{throw Error(r)}catch{}}}var $x=qj;i();var Xj=4;function Yj(e){return Uf(e,Xj)}var j0=Yj;i();i();function Jj(e,t){for(var r=-1,n=e==null?0:e.length,o=Array(n);++r<n;)o[r]=t(e[r],r,e);return o}var Kf=Jj;i();var Zj="[object Symbol]";function Qj(e){return typeof e=="symbol"||Xt(e)&&fr(e)==Zj}var Xa=Qj;i();i();i();var e_="Expected a function";function _0(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(e_);var r=function(){var n=arguments,o=t?t.apply(this,n):n[0],a=r.cache;if(a.has(o))return a.get(o);var s=e.apply(this,n);return r.cache=a.set(o,s)||a,s};return r.cache=new(_0.Cache||Eu),r}_0.Cache=Eu;var zx=_0;var t_=500;function r_(e){var t=zx(e,function(n){return r.size===t_&&r.clear(),n}),r=t.cache;return t}var Hx=r_;var n_=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,o_=/\\(\\)?/g,i_=Hx(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(""),e.replace(n_,function(r,n,o,a){t.push(o?a.replace(o_,"$1"):n||r)}),t}),Gx=i_;i();var a_=1/0;function s_(e){if(typeof e=="string"||Xa(e))return e;var t=e+"";return t=="0"&&1/e==-a_?"-0":t}var jx=s_;i();i();var u_=1/0,_x=xr?xr.prototype:void 0,Wx=_x?_x.toString:void 0;function Ux(e){if(typeof e=="string")return e;if(Qr(e))return Kf(e,Ux)+"";if(Xa(e))return Wx?Wx.call(e):"";var t=e+"";return t=="0"&&1/e==-u_?"-0":t}var Kx=Ux;function l_(e){return e==null?"":Kx(e)}var qx=l_;function c_(e){return Qr(e)?Kf(e,jx):Xa(e)?[e]:Nf(Gx(qx(e)))}var W0=c_;var F_=U(iw());function Re(){return Re=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Re.apply(this,arguments)}function B_(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,e.__proto__=t}function di(e,t){if(e==null)return{};var r={},n=Object.keys(e),o,a;for(a=0;a<n.length;a++)o=n[a],!(t.indexOf(o)>=0)&&(r[o]=e[o]);return r}function sw(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}var ip=S_(void 0);ip.displayName="FormikContext";var O_=ip.Provider,Gze=ip.Consumer;function hi(){var e=D_(ip);return e||$x(!1),e}var uw=function(t){return Array.isArray(t)&&t.length===0},Nt=function(t){return typeof t=="function"},Tu=function(t){return t!==null&&typeof t=="object"},M_=function(t){return String(Math.floor(Number(t)))===t},J0=function(t){return Object.prototype.toString.call(t)==="[object String]"};var cw=function(t){return th.count(t)===0},Z0=function(t){return Tu(t)&&Nt(t.then)};function ct(e,t,r,n){n===void 0&&(n=0);for(var o=W0(t);e&&n<o.length;)e=e[o[n++]];return n!==o.length&&!e||e===void 0?r:e}function en(e,t,r){for(var n=j0(e),o=n,a=0,s=W0(t);a<s.length-1;a++){var u=s[a],l=ct(e,s.slice(0,a+1));if(l&&(Tu(l)||Array.isArray(l)))o=o[u]=j0(l);else{var c=s[a+1];o=o[u]=M_(c)&&Number(c)>=0?[]:{}}}return(a===0?e:o)[s[a]]===r?e:(r===void 0?delete o[s[a]]:o[s[a]]=r,a===0&&r===void 0&&delete n[s[a]],n)}function fw(e,t,r,n){r===void 0&&(r=new WeakMap),n===void 0&&(n={});for(var o=0,a=Object.keys(e);o<a.length;o++){var s=a[o],u=e[s];Tu(u)?r.get(u)||(r.set(u,!0),n[s]=Array.isArray(u)?[]:{},fw(u,t,r,n[s])):n[s]=t}return n}function I_(e,t){switch(t.type){case"SET_VALUES":return Re({},e,{values:t.payload});case"SET_TOUCHED":return Re({},e,{touched:t.payload});case"SET_ERRORS":return(0,Vn.default)(e.errors,t.payload)?e:Re({},e,{errors:t.payload});case"SET_STATUS":return Re({},e,{status:t.payload});case"SET_ISSUBMITTING":return Re({},e,{isSubmitting:t.payload});case"SET_ISVALIDATING":return Re({},e,{isValidating:t.payload});case"SET_FIELD_VALUE":return Re({},e,{values:en(e.values,t.payload.field,t.payload.value)});case"SET_FIELD_TOUCHED":return Re({},e,{touched:en(e.touched,t.payload.field,t.payload.value)});case"SET_FIELD_ERROR":return Re({},e,{errors:en(e.errors,t.payload.field,t.payload.value)});case"RESET_FORM":return Re({},e,t.payload);case"SET_FORMIK_STATE":return t.payload(e);case"SUBMIT_ATTEMPT":return Re({},e,{touched:fw(e.values,!0),isSubmitting:!0,submitCount:e.submitCount+1});case"SUBMIT_FAILURE":return Re({},e,{isSubmitting:!1});case"SUBMIT_SUCCESS":return Re({},e,{isSubmitting:!1});default:return e}}var pi={},op={};function k_(e){var t=e.validateOnChange,r=t===void 0?!0:t,n=e.validateOnBlur,o=n===void 0?!0:n,a=e.validateOnMount,s=a===void 0?!1:a,u=e.isInitialValid,l=e.enableReinitialize,c=l===void 0?!1:l,p=e.onSubmit,d=di(e,["validateOnChange","validateOnBlur","validateOnMount","isInitialValid","enableReinitialize","onSubmit"]),h=Re({validateOnChange:r,validateOnBlur:o,validateOnMount:s,onSubmit:p},d),g=To(h.initialValues),v=To(h.initialErrors||pi),m=To(h.initialTouched||op),b=To(h.initialStatus),y=To(!1),x=To({});Ao(function(){return y.current=!0,function(){y.current=!1}},[]);var w=E_(0),S=w[1],E=To({values:qa(h.initialValues),errors:qa(h.initialErrors)||pi,touched:qa(h.initialTouched)||op,status:qa(h.initialStatus),isSubmitting:!1,isValidating:!1,submitCount:0}),D=E.current,P=rt(function(B){var X=E.current;E.current=I_(X,B),X!==E.current&&S(function(te){return te+1})},[]),R=rt(function(B,X){return new Promise(function(te,q){var se=h.validate(B,X);se==null?te(pi):Z0(se)?se.then(function(we){te(we||pi)},function(we){q(we)}):te(se)})},[h.validate]),F=rt(function(B,X){var te=h.validationSchema,q=Nt(te)?te(X):te,se=X&&q.validateAt?q.validateAt(X,B):V_(B,q);return new Promise(function(we,Pe){se.then(function(){we(pi)},function(vt){vt.name==="ValidationError"?we(N_(vt)):Pe(vt)})})},[h.validationSchema]),M=rt(function(B,X){return new Promise(function(te){return te(x.current[B].validate(X))})},[]),G=rt(function(B){var X=Object.keys(x.current).filter(function(q){return Nt(x.current[q].validate)}),te=X.length>0?X.map(function(q){return M(q,ct(B,q))}):[Promise.resolve("DO_NOT_DELETE_YOU_WILL_BE_FIRED")];return Promise.all(te).then(function(q){return q.reduce(function(se,we,Pe){return we==="DO_NOT_DELETE_YOU_WILL_BE_FIRED"||we&&(se=en(se,X[Pe],we)),se},{})})},[M]),N=rt(function(B){return Promise.all([G(B),h.validationSchema?F(B):{},h.validate?R(B):{}]).then(function(X){var te=X[0],q=X[1],se=X[2],we=Df.all([te,q,se],{arrayMerge:L_});return we})},[h.validate,h.validationSchema,G,R,F]),L=wr(function(B){return B===void 0&&(B=D.values),P({type:"SET_ISVALIDATING",payload:!0}),N(B).then(function(X){return y.current&&(P({type:"SET_ISVALIDATING",payload:!1}),P({type:"SET_ERRORS",payload:X})),X})});Ao(function(){s&&y.current===!0&&(0,Vn.default)(g.current,h.initialValues)&&L(g.current)},[s,L]);var I=rt(function(B){var X=B&&B.values?B.values:g.current,te=B&&B.errors?B.errors:v.current?v.current:h.initialErrors||{},q=B&&B.touched?B.touched:m.current?m.current:h.initialTouched||{},se=B&&B.status?B.status:b.current?b.current:h.initialStatus;g.current=X,v.current=te,m.current=q,b.current=se;var we=function(){P({type:"RESET_FORM",payload:{isSubmitting:!!B&&!!B.isSubmitting,errors:te,touched:q,status:se,values:X,isValidating:!!B&&!!B.isValidating,submitCount:B&&B.submitCount&&typeof B.submitCount=="number"?B.submitCount:0}})};if(h.onReset){var Pe=h.onReset(D.values,Ee);Z0(Pe)?Pe.then(we):we()}else we()},[h.initialErrors,h.initialStatus,h.initialTouched,h.onReset]);Ao(function(){y.current===!0&&!(0,Vn.default)(g.current,h.initialValues)&&c&&(g.current=h.initialValues,I(),s&&L(g.current))},[c,h.initialValues,I,s,L]),Ao(function(){c&&y.current===!0&&!(0,Vn.default)(v.current,h.initialErrors)&&(v.current=h.initialErrors||pi,P({type:"SET_ERRORS",payload:h.initialErrors||pi}))},[c,h.initialErrors]),Ao(function(){c&&y.current===!0&&!(0,Vn.default)(m.current,h.initialTouched)&&(m.current=h.initialTouched||op,P({type:"SET_TOUCHED",payload:h.initialTouched||op}))},[c,h.initialTouched]),Ao(function(){c&&y.current===!0&&!(0,Vn.default)(b.current,h.initialStatus)&&(b.current=h.initialStatus,P({type:"SET_STATUS",payload:h.initialStatus}))},[c,h.initialStatus,h.initialTouched]);var V=wr(function(B){if(x.current[B]&&Nt(x.current[B].validate)){var X=ct(D.values,B),te=x.current[B].validate(X);return Z0(te)?(P({type:"SET_ISVALIDATING",payload:!0}),te.then(function(q){return q}).then(function(q){P({type:"SET_FIELD_ERROR",payload:{field:B,value:q}}),P({type:"SET_ISVALIDATING",payload:!1})})):(P({type:"SET_FIELD_ERROR",payload:{field:B,value:te}}),Promise.resolve(te))}else if(h.validationSchema)return P({type:"SET_ISVALIDATING",payload:!0}),F(D.values,B).then(function(q){return q}).then(function(q){P({type:"SET_FIELD_ERROR",payload:{field:B,value:ct(q,B)}}),P({type:"SET_ISVALIDATING",payload:!1})});return Promise.resolve()}),Y=rt(function(B,X){var te=X.validate;x.current[B]={validate:te}},[]),Q=rt(function(B){delete x.current[B]},[]),re=wr(function(B,X){P({type:"SET_TOUCHED",payload:B});var te=X===void 0?o:X;return te?L(D.values):Promise.resolve()}),H=rt(function(B){P({type:"SET_ERRORS",payload:B})},[]),le=wr(function(B,X){var te=Nt(B)?B(D.values):B;P({type:"SET_VALUES",payload:te});var q=X===void 0?r:X;return q?L(te):Promise.resolve()}),ve=rt(function(B,X){P({type:"SET_FIELD_ERROR",payload:{field:B,value:X}})},[]),me=wr(function(B,X,te){P({type:"SET_FIELD_VALUE",payload:{field:B,value:X}});var q=te===void 0?r:te;return q?L(en(D.values,B,X)):Promise.resolve()}),Ge=rt(function(B,X){var te=X,q=B,se;if(!J0(B)){B.persist&&B.persist();var we=B.target?B.target:B.currentTarget,Pe=we.type,vt=we.name,eo=we.id,Ir=we.value,N1=we.checked,W5=we.outerHTML,Yi=we.options,V1=we.multiple;te=X||vt||eo,q=/number|range/.test(Pe)?(se=parseFloat(Ir),isNaN(se)?"":se):/checkbox/.test(Pe)?z_(ct(D.values,te),N1,Ir):Yi&&V1?$_(Yi):Ir}te&&me(te,q)},[me,D.values]),A=wr(function(B){if(J0(B))return function(X){return Ge(X,B)};Ge(B)}),_=wr(function(B,X,te){X===void 0&&(X=!0),P({type:"SET_FIELD_TOUCHED",payload:{field:B,value:X}});var q=te===void 0?o:te;return q?L(D.values):Promise.resolve()}),z=rt(function(B,X){B.persist&&B.persist();var te=B.target,q=te.name,se=te.id,we=te.outerHTML,Pe=X||q||se;_(Pe,!0)},[_]),j=wr(function(B){if(J0(B))return function(X){return z(X,B)};z(B)}),ue=rt(function(B){Nt(B)?P({type:"SET_FORMIK_STATE",payload:B}):P({type:"SET_FORMIK_STATE",payload:function(){return B}})},[]),oe=rt(function(B){P({type:"SET_STATUS",payload:B})},[]),he=rt(function(B){P({type:"SET_ISSUBMITTING",payload:B})},[]),Ce=wr(function(){return P({type:"SUBMIT_ATTEMPT"}),L().then(function(B){var X=B instanceof Error,te=!X&&Object.keys(B).length===0;if(te){var q;try{if(q=xe(),q===void 0)return}catch(se){throw se}return Promise.resolve(q).then(function(se){return y.current&&P({type:"SUBMIT_SUCCESS"}),se}).catch(function(se){if(y.current)throw P({type:"SUBMIT_FAILURE"}),se})}else if(y.current&&(P({type:"SUBMIT_FAILURE"}),X))throw B})}),Se=wr(function(B){if(B&&B.preventDefault&&Nt(B.preventDefault)&&B.preventDefault(),B&&B.stopPropagation&&Nt(B.stopPropagation)&&B.stopPropagation(),0)var X;Ce().catch(function(te){console.warn("Warning: An unhandled error was caught from submitForm()",te)})}),Ee={resetForm:I,validateForm:L,validateField:V,setErrors:H,setFieldError:ve,setFieldTouched:_,setFieldValue:me,setStatus:oe,setSubmitting:he,setTouched:re,setValues:le,setFormikState:ue,submitForm:Ce},xe=wr(function(){return p(D.values,Ee)}),ht=wr(function(B){B&&B.preventDefault&&Nt(B.preventDefault)&&B.preventDefault(),B&&B.stopPropagation&&Nt(B.stopPropagation)&&B.stopPropagation(),I()}),gt=rt(function(B){return{value:ct(D.values,B),error:ct(D.errors,B),touched:!!ct(D.touched,B),initialValue:ct(g.current,B),initialTouched:!!ct(m.current,B),initialError:ct(v.current,B)}},[D.errors,D.touched,D.values]),je=rt(function(B){return{setValue:function(te,q){return me(B,te,q)},setTouched:function(te,q){return _(B,te,q)},setError:function(te){return ve(B,te)}}},[me,_,ve]),or=rt(function(B){var X=Tu(B),te=X?B.name:B,q=ct(D.values,te),se={name:te,value:q,onChange:A,onBlur:j};if(X){var we=B.type,Pe=B.value,vt=B.as,eo=B.multiple;we==="checkbox"?Pe===void 0?se.checked=!!q:(se.checked=!!(Array.isArray(q)&&~q.indexOf(Pe)),se.value=Pe):we==="radio"?(se.checked=q===Pe,se.value=Pe):vt==="select"&&eo&&(se.value=se.value||[],se.multiple=!0)}return se},[j,A,D.values]),Ht=aw(function(){return!(0,Vn.default)(g.current,D.values)},[g.current,D.values]),St=aw(function(){return typeof u<"u"?Ht?D.errors&&Object.keys(D.errors).length===0:u!==!1&&Nt(u)?u(h):u:D.errors&&Object.keys(D.errors).length===0},[u,Ht,D.errors,h]),ir=Re({},D,{initialValues:g.current,initialErrors:v.current,initialTouched:m.current,initialStatus:b.current,handleBlur:j,handleChange:A,handleReset:ht,handleSubmit:Se,resetForm:I,setErrors:H,setFormikState:ue,setFieldTouched:_,setFieldValue:me,setFieldError:ve,setStatus:oe,setSubmitting:he,setTouched:re,setValues:le,submitForm:Ce,validateForm:L,validateField:V,isValid:St,dirty:Ht,unregisterField:Q,registerField:Y,getFieldProps:or,getFieldMeta:gt,getFieldHelpers:je,validateOnBlur:o,validateOnChange:r,validateOnMount:s});return ir}function pw(e){var t=k_(e),r=e.component,n=e.children,o=e.render,a=e.innerRef;return P_(a,function(){return t}),Ro(O_,{value:t},r?Ro(r,t):o?o(t):n?Nt(n)?n(t):cw(n)?null:th.only(n):null)}function N_(e){var t={};if(e.inner){if(e.inner.length===0)return en(t,e.path,e.message);for(var o=e.inner,r=Array.isArray(o),n=0,o=r?o:o[Symbol.iterator]();;){var a;if(r){if(n>=o.length)break;a=o[n++]}else{if(n=o.next(),n.done)break;a=n.value}var s=a;ct(t,s.path)||(t=en(t,s.path,s.message))}}return t}function V_(e,t,r,n){r===void 0&&(r=!1);var o=eh(e);return t[r?"validateSync":"validate"](o,{abortEarly:!1,context:n||o})}function eh(e){var t=Array.isArray(e)?[]:{};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){var n=String(r);Array.isArray(e[n])===!0?t[n]=e[n].map(function(o){return Array.isArray(o)===!0||N0(o)?eh(o):o!==""?o:void 0}):N0(e[n])?t[n]=eh(e[n]):t[n]=e[n]!==""?e[n]:void 0}return t}function L_(e,t,r){var n=e.slice();return t.forEach(function(a,s){if(typeof n[s]>"u"){var u=r.clone!==!1,l=u&&r.isMergeableObject(a);n[s]=l?Df(Array.isArray(a)?[]:{},a,r):a}else r.isMergeableObject(a)?n[s]=Df(e[s],a,r):e.indexOf(a)===-1&&n.push(a)}),n}function $_(e){return Array.from(e).filter(function(t){return t.selected}).map(function(t){return t.value})}function z_(e,t,r){if(typeof e=="boolean")return!!t;var n=[],o=!1,a=-1;if(Array.isArray(e))n=e,a=e.indexOf(r),o=a>=0;else if(!r||r=="true"||r=="false")return!!t;return t&&r&&!o?n.concat(r):o?n.slice(0,a).concat(n.slice(a+1)):n}var H_=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u"?T_:Ao;function wr(e){var t=To(e);return H_(function(){t.current=e}),rt(function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return t.current.apply(void 0,n)},[])}function dw(e){var t=e.validate,r=e.name,n=e.render,o=e.children,a=e.as,s=e.component,u=e.className,l=di(e,["validate","name","render","children","as","component","className"]),c=hi(),p=di(c,["validate","validationSchema"]),d=p.registerField,h=p.unregisterField;Ao(function(){return d(r,{validate:t}),function(){h(r)}},[d,h,r,t]);var g=p.getFieldProps(Re({name:r},l)),v=p.getFieldMeta(r),m={field:g,form:p};if(n)return n(Re({},m,{meta:v}));if(Nt(o))return o(Re({},m,{meta:v}));if(s){if(typeof s=="string"){var b=l.innerRef,y=di(l,["innerRef"]);return Ro(s,Re({ref:b},g,y,{className:u}),o)}return Ro(s,Re({field:g,form:p},l,{className:u}),o)}var x=a||"input";if(typeof x=="string"){var w=l.innerRef,S=di(l,["innerRef"]);return Ro(x,Re({ref:w},g,S,{className:u}),o)}return Ro(x,Re({},g,l,{className:u}),o)}var rh=A_(function(e,t){var r=e.action,n=di(e,["action"]),o=r??"#",a=hi(),s=a.handleReset,u=a.handleSubmit;return Ro("form",Re({onSubmit:u,ref:t,onReset:s,action:o},n))});rh.displayName="Form";var G_=function(t,r,n){var o=mi(t),a=o[r];return o.splice(r,1),o.splice(n,0,a),o},j_=function(t,r,n){var o=mi(t),a=o[r];return o[r]=o[n],o[n]=a,o},Q0=function(t,r,n){var o=mi(t);return o.splice(r,0,n),o},__=function(t,r,n){var o=mi(t);return o[r]=n,o},mi=function(t){if(t){if(Array.isArray(t))return[].concat(t);var r=Object.keys(t).map(function(n){return parseInt(n)}).reduce(function(n,o){return o>n?o:n},0);return Array.from(Re({},t,{length:r+1}))}else return[]},lw=function(t,r){var n=typeof t=="function"?t:r;return function(o){if(Array.isArray(o)||Tu(o)){var a=mi(o);return n(a)}return o}},W_=function(e){B_(t,e);function t(n){var o;return o=e.call(this,n)||this,o.updateArrayField=function(a,s,u){var l=o.props,c=l.name,p=l.formik.setFormikState;p(function(d){var h=lw(u,a),g=lw(s,a),v=en(d.values,c,a(ct(d.values,c))),m=u?h(ct(d.errors,c)):void 0,b=s?g(ct(d.touched,c)):void 0;return uw(m)&&(m=void 0),uw(b)&&(b=void 0),Re({},d,{values:v,errors:u?en(d.errors,c,m):d.errors,touched:s?en(d.touched,c,b):d.touched})})},o.push=function(a){return o.updateArrayField(function(s){return[].concat(mi(s),[qa(a)])},!1,!1)},o.handlePush=function(a){return function(){return o.push(a)}},o.swap=function(a,s){return o.updateArrayField(function(u){return j_(u,a,s)},!0,!0)},o.handleSwap=function(a,s){return function(){return o.swap(a,s)}},o.move=function(a,s){return o.updateArrayField(function(u){return G_(u,a,s)},!0,!0)},o.handleMove=function(a,s){return function(){return o.move(a,s)}},o.insert=function(a,s){return o.updateArrayField(function(u){return Q0(u,a,s)},function(u){return Q0(u,a,null)},function(u){return Q0(u,a,null)})},o.handleInsert=function(a,s){return function(){return o.insert(a,s)}},o.replace=function(a,s){return o.updateArrayField(function(u){return __(u,a,s)},!1,!1)},o.handleReplace=function(a,s){return function(){return o.replace(a,s)}},o.unshift=function(a){var s=-1;return o.updateArrayField(function(u){var l=u?[a].concat(u):[a];return s=l.length,l},function(u){return u?[null].concat(u):[null]},function(u){return u?[null].concat(u):[null]}),s},o.handleUnshift=function(a){return function(){return o.unshift(a)}},o.handleRemove=function(a){return function(){return o.remove(a)}},o.handlePop=function(){return function(){return o.pop()}},o.remove=o.remove.bind(sw(o)),o.pop=o.pop.bind(sw(o)),o}var r=t.prototype;return r.componentDidUpdate=function(o){this.props.validateOnChange&&this.props.formik.validateOnChange&&!(0,Vn.default)(ct(o.formik.values,o.name),ct(this.props.formik.values,this.props.name))&&this.props.formik.validateForm(this.props.formik.values)},r.remove=function(o){var a;return this.updateArrayField(function(s){var u=s?mi(s):[];return a||(a=u[o]),Nt(u.splice)&&u.splice(o,1),Nt(u.every)&&u.every(function(l){return l===void 0})?[]:u},!0,!0),a},r.pop=function(){var o;return this.updateArrayField(function(a){var s=a.slice();return o||(o=s&&s.pop&&s.pop()),s},!0,!0),o},r.render=function(){var o={push:this.push,pop:this.pop,swap:this.swap,move:this.move,insert:this.insert,replace:this.replace,unshift:this.unshift,remove:this.remove,handlePush:this.handlePush,handlePop:this.handlePop,handleSwap:this.handleSwap,handleMove:this.handleMove,handleInsert:this.handleInsert,handleReplace:this.handleReplace,handleUnshift:this.handleUnshift,handleRemove:this.handleRemove},a=this.props,s=a.component,u=a.render,l=a.children,c=a.name,p=a.formik,d=di(p,["validate","validationSchema"]),h=Re({},o,{form:d,name:c});return s?Ro(s,h):u?u(h):l?typeof l=="function"?l(h):cw(l)?null:th.only(l):null},t}(R_);W_.defaultProps={validateOnChange:!0};i();i();import{useState as U_}from"react";var K_=()=>{let[e,t]=U_(!1),r=()=>t(!0),n=()=>t(!0),o=()=>t(!0),u={onFocus:r,onMouseEnter:n,onBlur:()=>t(!1),onMouseLeave:()=>t(!1)};return e||(u.onMouseMove=o),[e,u,t]};i();i();import{useMemo as q_}from"react";var X_=e=>typeof e=="function"?e:typeof e=="string"?t=>t.key===e:e!=null&&e?()=>!0:()=>!1,ap=(e,t,r={},n=[e])=>{let{eventName:o="keydown",eventTarget:a,eventOptions:s}=r,u=q_(()=>{let l=X_(e);return c=>{if(!(["INPUT","TEXTAREA","SELECT"].includes(document.activeElement?.nodeName??"")||document.activeElement?.isContentEditable)&&l(c))return t(c)}},n);B0(o,u,a,s)};i();i();import{useState as Y_}from"react";var nh=e=>{let[t,r]=Y_([!1,null]);return ap(e,n=>r([!0,n]),{eventName:"keydown"},[t]),ap(e,n=>r([!1,n]),{eventName:"keyup"},[t]),t};i();i();i();i();import{useEffect as J_,useRef as Z_}from"react";var oh=(e,t)=>{let r=Z_(!0);J_(()=>r.current?(r.current=!1,()=>{}):e(),t)};var ih=(e,t=void 0,r=void 0)=>{let[n,o]=nh(e);oh(()=>(!n&&r&&o!==null?r(o):n&&t&&o!==null&&t(o),()=>{}),[n])};i();i();import{useState as Q_}from"react";var eW=(e,t,r=window.localStorage)=>{let[n,o]=Q_(()=>{try{let u=r.getItem(e);return u!==null&&u?JSON.parse(u):t}catch(u){return console.log(u),t}});return[n,u=>{try{let l=u instanceof Function?u(n):u;o(l),r.setItem(e,JSON.stringify(l))}catch(l){console.error(l)}},()=>{r.removeItem(e),o(void 0)}]};i();i();var Au=e=>t=>{e.forEach(r=>{typeof r=="function"?r(t):r!=null&&(r.current=t)})};i();i();import{useEffect as tW}from"react";var Ru=(e,t)=>{tW(()=>{let r=n=>{!e.current||e.current.contains(n.target)||t(n)};return document.addEventListener("mousedown",r),document.addEventListener("touchstart",r),()=>{document.removeEventListener("mousedown",r),document.removeEventListener("touchstart",r)}},[e,t])};i();i();import{useLayoutEffect as rW}from"react";var ah=e=>{rW(()=>{if(e){let t=window.getComputedStyle(document.body).overflow;return document.body.style.overflow="hidden",()=>{document.body.style.overflow=t}}return()=>{}},[e])};i();i();import{useEffect as nW,useRef as oW}from"react";var Fu=e=>{let t=oW();return nW(()=>{t.current=e}),t.current};i();i();var Hw=U(Z());import hp from"styled-components";i();i();var Cw=U(up()),Sr=U(Z());import{useEffect as gi,useRef as gw,useState as vw,useCallback as yw}from"react";import{createPortal as hW}from"react-dom";import{createGlobalStyle as gW}from"styled-components";i();i();import{Children as lW}from"react";var hw=U(Z());import{createGlobalStyle as cW}from"styled-components";import{Fragment as dW,jsx as sh,jsxs as mW}from"react/jsx-runtime";var fW=100,pW=cW`
708
+ `;import{jsx as wu,jsxs as WL}from"react/jsx-runtime";var pBe=({children:e,theme:t={},globalStylesIncluded:r=!0,skipAnimations:n=!1,Link:o})=>(n&&(Sn.skipAnimations=!0),WL(w6,{theme:t,children:[r?wu(zb,{}):null,wu(um,{children:wu(E6,{value:{Link:o},children:wu(Cf,{children:wu(S0,{children:e})})})})]}));i();i();import{useState as UL,useCallback as T0}from"react";var A0=(e=!1)=>{let[t,r]=UL(e),n=T0(()=>r(s=>!s),[]),o=T0(()=>r(!0),[]),a=T0(()=>r(!1),[]);return[t,n,o,a,r]};i();i();import{useCallback as XL}from"react";i();i();import{useEffect as KL,useRef as Hb,useState as qL}from"react";var xf=e=>{let[t,r]=qL(!1),n=Hb(),o=Hb(e),a=s=>{clearTimeout(n.current),r(!o.current),n.current=window.setTimeout(()=>r(o.current),s)};return KL(()=>()=>clearTimeout(n.current),[]),[t,a]};var YL=(e,t=1500)=>{let[r,n]=xf(!1),[o,a]=xf(!1);return[XL(async()=>{try{await Vs(e),t&&t>0&&n(t)}catch(u){u instanceof Error&&a(t)}},[e,t,n,a]),r,o]};i();i();import{useMemo as JL,useState as ZL,useRef as QL,useLayoutEffect as e$}from"react";var t$={width:0,height:0,top:0,left:0,bottom:0,right:0,x:0,y:0},R0=()=>{let e=QL(null),[t,r]=ZL(t$),n=JL(()=>new window.ResizeObserver(o=>{if(o[0]){let{width:a,height:s,top:u,left:l,bottom:c,right:p,x:d,y:h}=o[0].contentRect;r({width:a,height:s,top:u,left:l,bottom:c,right:p,x:d,y:h})}}),[]);return e$(()=>{if(e.current)return n.observe(e.current),()=>{n.disconnect()}},[n]),[e,t]};i();i();import{useEffect as F0,useRef as Gb}from"react";var r$=e=>!!(typeof e=="object"&&e?.addEventListener),B0=(e,t,r=window,n={})=>{let o=Gb(),a=Gb();F0(()=>{o.current=t},[t]),F0(()=>{a.current=n},[n]),F0(()=>{if(!e||!r$(r))return;let s=u=>o.current!==void 0?o.current(u):()=>{};return r.addEventListener(e,s,a.current),()=>{r.removeEventListener(e,s,a.current)}},[e,r,a])};i();i();var rC=U(Z());import{useRef as tC,useCallback as i$,useEffect as a$}from"react";i();var M0='a[href], area[href], input:not([disabled]), select:not([disabled]), textarea:not([disabled]), button:not([disabled]), iframe, object, [tabindex="0"], [contenteditable]',n$=e=>{let{display:t,visibility:r}=window.getComputedStyle(e),n=t==="none"||e.style.display==="none"||r==="none"||e.style.visibility==="hidden";return e.offsetWidth<=0&&e.offsetHeight<=0||n},o$=e=>{let t=e;for(;t&&t!==document.body;){if(n$(t))return!1;t=t.parentNode}return!0},jb=e=>{let t=e.getAttribute("tabindex");return Number.parseInt(t??void 0,10)},_b=e=>{let t=jb(e);return Number.isNaN(t)},wf=e=>{let t=/input|select|textarea|button|object/,r=e.nodeName.toLowerCase(),n=!_b(e);return!!(t.test(r)&&!e.disabled||e instanceof HTMLAnchorElement&&e.href||n)&&o$(e)},I0=e=>{let t=jb(e);return(_b(e)||t>=0)&&wf(e)},Wb=e=>Array.from(e.querySelectorAll(M0)).filter(I0),Ub=[],ka=null,O0=!1,Kb=()=>{O0=!0},qb=()=>{if(O0){if(O0=!1,!ka||ka.contains(document.activeElement))return;(Wb(ka)[0]??ka).focus()}},Xb=()=>{let e=document.activeElement;e!==null&&Ub.push(e)},Yb=()=>{let e=null;try{e=Ub.pop(),e&&e.focus()}catch{console.warn(["You tried to return focus to",e,"but it is not in the DOM anymore"].join(" "))}},Jb=e=>{ka=e,document.addEventListener("focusout",Kb,!1),document.addEventListener("focusin",qb,!0)},Zb=()=>{ka=null,document.removeEventListener("focusout",Kb),document.removeEventListener("focusin",qb)},Qb=(e,t)=>{let r=Wb(e);if(!r.length){t.preventDefault();return}if(!(r[t.shiftKey?0:r.length-1]===document.activeElement||e===document.activeElement))return;t.preventDefault();let a=r[t.shiftKey?r.length-1:0];a&&a.focus()},eC=(e,t)=>{t===void 0&&(t="body > :not(script)");let r=Array.from(document.querySelectorAll(t)).map(n=>{if(n.contains(e))return;let o=n.getAttribute("aria-hidden");return(o===null||o==="false")&&n.setAttribute("aria-hidden","true"),{node:n,ariaHidden:o}});return()=>{r.forEach(n=>{n&&(n.ariaHidden===null?n.node.removeAttribute("aria-hidden"):n.node.setAttribute("aria-hidden",n.ariaHidden))})}};var k0=(e=!0,t={})=>{let r=tC(null),n=tC(null),o=i$(a=>{if(n.current!==null&&n.current(),r.current&&(Yb(),Zb()),e&&a!==null&&a!==void 0){Jb(a),Xb();let s=u=>{n.current=t.disableAriaHider??!1?null:eC(u);let l=null;if((0,rC.isNotUndefined)(t.focusSelector)&&(l=typeof t.focusSelector=="string"?u.querySelector(t.focusSelector):t.focusSelector),!l){let c=Array.from(u.querySelectorAll(M0));l=c.find(I0)??c.find(wf)??null,!l&&wf(u)&&(l=u)}l&&l.focus()};setTimeout(()=>{a.ownerDocument&&s(a),a.ownerDocument}),r.current=a}else r.current=null},[e,t.focusSelector,t.disableAriaHider]);return a$(()=>{if(!e)return;let a=s=>{s.key==="Tab"&&r.current&&Qb(r.current,s)};return document.addEventListener("keydown",a),()=>{document.removeEventListener("keydown",a)}},[e]),o};i();i();import{useCallback as s$,useState as u$}from"react";var l$=()=>{let[,e]=u$(Object.create(null));return s$(()=>{e(Object.create(null))},[e])};i();i();i();var c$=function(t){return f$(t)&&!p$(t)};function f$(e){return!!e&&typeof e=="object"}function p$(e){var t=Object.prototype.toString.call(e);return t==="[object RegExp]"||t==="[object Date]"||h$(e)}var d$=typeof Symbol=="function"&&Symbol.for,m$=d$?Symbol.for("react.element"):60103;function h$(e){return e.$$typeof===m$}function g$(e){return Array.isArray(e)?[]:{}}function Sf(e,t){return t.clone!==!1&&t.isMergeableObject(e)?Su(g$(e),e,t):e}function v$(e,t,r){return e.concat(t).map(function(n){return Sf(n,r)})}function y$(e,t,r){var n={};return r.isMergeableObject(e)&&Object.keys(e).forEach(function(o){n[o]=Sf(e[o],r)}),Object.keys(t).forEach(function(o){!r.isMergeableObject(t[o])||!e[o]?n[o]=Sf(t[o],r):n[o]=Su(e[o],t[o],r)}),n}function Su(e,t,r){r=r||{},r.arrayMerge=r.arrayMerge||v$,r.isMergeableObject=r.isMergeableObject||c$;var n=Array.isArray(t),o=Array.isArray(e),a=n===o;return a?n?r.arrayMerge(e,t,r):y$(e,t,r):Sf(t,r)}Su.all=function(t,r){if(!Array.isArray(t))throw new Error("first argument should be an array");return t.reduce(function(n,o){return Su(n,o,r)},{})};var b$=Su,Df=b$;i();i();i();i();i();var C$=typeof window=="object"&&window&&window.Object===Object&&window,Ef=C$;var x$=typeof self=="object"&&self&&self.Object===Object&&self,w$=Ef||x$||Function("return this")(),tt=w$;var S$=tt.Symbol,xr=S$;i();var nC=Object.prototype,D$=nC.hasOwnProperty,E$=nC.toString,Du=xr?xr.toStringTag:void 0;function P$(e){var t=D$.call(e,Du),r=e[Du];try{e[Du]=void 0;var n=!0}catch{}var o=E$.call(e);return n&&(t?e[Du]=r:delete e[Du]),o}var oC=P$;i();var T$=Object.prototype,A$=T$.toString;function R$(e){return A$.call(e)}var iC=R$;var F$="[object Null]",B$="[object Undefined]",aC=xr?xr.toStringTag:void 0;function O$(e){return e==null?e===void 0?B$:F$:aC&&aC in Object(e)?oC(e):iC(e)}var fr=O$;i();i();function M$(e,t){return function(r){return e(t(r))}}var Pf=M$;var I$=Pf(Object.getPrototypeOf,Object),Na=I$;i();function k$(e){return e!=null&&typeof e=="object"}var Xt=k$;var N$="[object Object]",V$=Function.prototype,L$=Object.prototype,sC=V$.toString,$$=L$.hasOwnProperty,z$=sC.call(Object);function H$(e){if(!Xt(e)||fr(e)!=N$)return!1;var t=Na(e);if(t===null)return!0;var r=$$.call(t,"constructor")&&t.constructor;return typeof r=="function"&&r instanceof r&&sC.call(r)==z$}var N0=H$;i();i();i();i();i();function G$(){this.__data__=[],this.size=0}var uC=G$;i();i();i();function j$(e,t){return e===t||e!==e&&t!==t}var Tf=j$;function _$(e,t){for(var r=e.length;r--;)if(Tf(e[r][0],t))return r;return-1}var wo=_$;var W$=Array.prototype,U$=W$.splice;function K$(e){var t=this.__data__,r=wo(t,e);if(r<0)return!1;var n=t.length-1;return r==n?t.pop():U$.call(t,r,1),--this.size,!0}var lC=K$;i();function q$(e){var t=this.__data__,r=wo(t,e);return r<0?void 0:t[r][1]}var cC=q$;i();function X$(e){return wo(this.__data__,e)>-1}var fC=X$;i();function Y$(e,t){var r=this.__data__,n=wo(r,e);return n<0?(++this.size,r.push([e,t])):r[n][1]=t,this}var pC=Y$;function Va(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}Va.prototype.clear=uC;Va.prototype.delete=lC;Va.prototype.get=cC;Va.prototype.has=fC;Va.prototype.set=pC;var So=Va;i();function J$(){this.__data__=new So,this.size=0}var dC=J$;i();function Z$(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r}var mC=Z$;i();function Q$(e){return this.__data__.get(e)}var hC=Q$;i();function ez(e){return this.__data__.has(e)}var gC=ez;i();i();i();i();i();i();function tz(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var Zr=tz;var rz="[object AsyncFunction]",nz="[object Function]",oz="[object GeneratorFunction]",iz="[object Proxy]";function az(e){if(!Zr(e))return!1;var t=fr(e);return t==nz||t==oz||t==rz||t==iz}var Af=az;i();i();var sz=tt["__core-js_shared__"],Rf=sz;var vC=function(){var e=/[^.]+$/.exec(Rf&&Rf.keys&&Rf.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function uz(e){return!!vC&&vC in e}var yC=uz;i();var lz=Function.prototype,cz=lz.toString;function fz(e){if(e!=null){try{return cz.call(e)}catch{}try{return e+""}catch{}}return""}var In=fz;var pz=/[\\^$.*+?()[\]{}|]/g,dz=/^\[object .+?Constructor\]$/,mz=Function.prototype,hz=Object.prototype,gz=mz.toString,vz=hz.hasOwnProperty,yz=RegExp("^"+gz.call(vz).replace(pz,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function bz(e){if(!Zr(e)||yC(e))return!1;var t=Af(e)?yz:dz;return t.test(In(e))}var bC=bz;i();function Cz(e,t){return e?.[t]}var CC=Cz;function xz(e,t){var r=CC(e,t);return bC(r)?r:void 0}var Yt=xz;var wz=Yt(tt,"Map"),Do=wz;i();i();i();i();i();var Sz=Yt(Object,"create"),kn=Sz;function Dz(){this.__data__=kn?kn(null):{},this.size=0}var xC=Dz;i();function Ez(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var wC=Ez;i();var Pz="__lodash_hash_undefined__",Tz=Object.prototype,Az=Tz.hasOwnProperty;function Rz(e){var t=this.__data__;if(kn){var r=t[e];return r===Pz?void 0:r}return Az.call(t,e)?t[e]:void 0}var SC=Rz;i();var Fz=Object.prototype,Bz=Fz.hasOwnProperty;function Oz(e){var t=this.__data__;return kn?t[e]!==void 0:Bz.call(t,e)}var DC=Oz;i();var Mz="__lodash_hash_undefined__";function Iz(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=kn&&t===void 0?Mz:t,this}var EC=Iz;function La(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}La.prototype.clear=xC;La.prototype.delete=wC;La.prototype.get=SC;La.prototype.has=DC;La.prototype.set=EC;var V0=La;function kz(){this.size=0,this.__data__={hash:new V0,map:new(Do||So),string:new V0}}var PC=kz;i();i();i();function Nz(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}var TC=Nz;function Vz(e,t){var r=e.__data__;return TC(t)?r[typeof t=="string"?"string":"hash"]:r.map}var Eo=Vz;function Lz(e){var t=Eo(this,e).delete(e);return this.size-=t?1:0,t}var AC=Lz;i();function $z(e){return Eo(this,e).get(e)}var RC=$z;i();function zz(e){return Eo(this,e).has(e)}var FC=zz;i();function Hz(e,t){var r=Eo(this,e),n=r.size;return r.set(e,t),this.size+=r.size==n?0:1,this}var BC=Hz;function $a(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}$a.prototype.clear=PC;$a.prototype.delete=AC;$a.prototype.get=RC;$a.prototype.has=FC;$a.prototype.set=BC;var Eu=$a;var Gz=200;function jz(e,t){var r=this.__data__;if(r instanceof So){var n=r.__data__;if(!Do||n.length<Gz-1)return n.push([e,t]),this.size=++r.size,this;r=this.__data__=new Eu(n)}return r.set(e,t),this.size=r.size,this}var OC=jz;function za(e){var t=this.__data__=new So(e);this.size=t.size}za.prototype.clear=dC;za.prototype.delete=mC;za.prototype.get=hC;za.prototype.has=gC;za.prototype.set=OC;var MC=za;i();function _z(e,t){for(var r=-1,n=e==null?0:e.length;++r<n&&t(e[r],r,e)!==!1;);return e}var IC=_z;i();i();i();var Wz=function(){try{var e=Yt(Object,"defineProperty");return e({},"",{}),e}catch{}}(),L0=Wz;function Uz(e,t,r){t=="__proto__"&&L0?L0(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r}var Ff=Uz;var Kz=Object.prototype,qz=Kz.hasOwnProperty;function Xz(e,t,r){var n=e[t];(!(qz.call(e,t)&&Tf(n,r))||r===void 0&&!(t in e))&&Ff(e,t,r)}var Bf=Xz;i();i();function Yz(e,t,r,n){var o=!r;r||(r={});for(var a=-1,s=t.length;++a<s;){var u=t[a],l=n?n(r[u],e[u],u,r,e):void 0;l===void 0&&(l=e[u]),o?Ff(r,u,l):Bf(r,u,l)}return r}var Po=Yz;i();i();i();function Jz(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}var kC=Jz;i();i();var Zz="[object Arguments]";function Qz(e){return Xt(e)&&fr(e)==Zz}var $0=Qz;var NC=Object.prototype,eH=NC.hasOwnProperty,tH=NC.propertyIsEnumerable,rH=$0(function(){return arguments}())?$0:function(e){return Xt(e)&&eH.call(e,"callee")&&!tH.call(e,"callee")},VC=rH;i();var nH=Array.isArray,Qr=nH;i();i();function oH(){return!1}var LC=oH;var HC=typeof exports=="object"&&exports&&!exports.nodeType&&exports,$C=HC&&typeof module=="object"&&module&&!module.nodeType&&module,iH=$C&&$C.exports===HC,zC=iH?tt.Buffer:void 0,aH=zC?zC.isBuffer:void 0,sH=aH||LC,Of=sH;i();var uH=9007199254740991,lH=/^(?:0|[1-9]\d*)$/;function cH(e,t){var r=typeof e;return t=t??uH,!!t&&(r=="number"||r!="symbol"&&lH.test(e))&&e>-1&&e%1==0&&e<t}var GC=cH;i();i();i();var fH=9007199254740991;function pH(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=fH}var Mf=pH;var dH="[object Arguments]",mH="[object Array]",hH="[object Boolean]",gH="[object Date]",vH="[object Error]",yH="[object Function]",bH="[object Map]",CH="[object Number]",xH="[object Object]",wH="[object RegExp]",SH="[object Set]",DH="[object String]",EH="[object WeakMap]",PH="[object ArrayBuffer]",TH="[object DataView]",AH="[object Float32Array]",RH="[object Float64Array]",FH="[object Int8Array]",BH="[object Int16Array]",OH="[object Int32Array]",MH="[object Uint8Array]",IH="[object Uint8ClampedArray]",kH="[object Uint16Array]",NH="[object Uint32Array]",Le={};Le[AH]=Le[RH]=Le[FH]=Le[BH]=Le[OH]=Le[MH]=Le[IH]=Le[kH]=Le[NH]=!0;Le[dH]=Le[mH]=Le[PH]=Le[hH]=Le[TH]=Le[gH]=Le[vH]=Le[yH]=Le[bH]=Le[CH]=Le[xH]=Le[wH]=Le[SH]=Le[DH]=Le[EH]=!1;function VH(e){return Xt(e)&&Mf(e.length)&&!!Le[fr(e)]}var jC=VH;i();function LH(e){return function(t){return e(t)}}var Ha=LH;i();var _C=typeof exports=="object"&&exports&&!exports.nodeType&&exports,Pu=_C&&typeof module=="object"&&module&&!module.nodeType&&module,$H=Pu&&Pu.exports===_C,z0=$H&&Ef.process,zH=function(){try{var e=Pu&&Pu.require&&Pu.require("util").types;return e||z0&&z0.binding&&z0.binding("util")}catch{}}(),Nn=zH;var WC=Nn&&Nn.isTypedArray,HH=WC?Ha(WC):jC,UC=HH;var GH=Object.prototype,jH=GH.hasOwnProperty;function _H(e,t){var r=Qr(e),n=!r&&VC(e),o=!r&&!n&&Of(e),a=!r&&!n&&!o&&UC(e),s=r||n||o||a,u=s?kC(e.length,String):[],l=u.length;for(var c in e)(t||jH.call(e,c))&&!(s&&(c=="length"||o&&(c=="offset"||c=="parent")||a&&(c=="buffer"||c=="byteLength"||c=="byteOffset")||GC(c,l)))&&u.push(c);return u}var If=_H;i();i();var WH=Object.prototype;function UH(e){var t=e&&e.constructor,r=typeof t=="function"&&t.prototype||WH;return e===r}var Ga=UH;i();var KH=Pf(Object.keys,Object),KC=KH;var qH=Object.prototype,XH=qH.hasOwnProperty;function YH(e){if(!Ga(e))return KC(e);var t=[];for(var r in Object(e))XH.call(e,r)&&r!="constructor"&&t.push(r);return t}var qC=YH;i();function JH(e){return e!=null&&Mf(e.length)&&!Af(e)}var kf=JH;function ZH(e){return kf(e)?If(e):qC(e)}var ja=ZH;function QH(e,t){return e&&Po(t,ja(t),e)}var XC=QH;i();i();i();i();function eG(e){var t=[];if(e!=null)for(var r in Object(e))t.push(r);return t}var YC=eG;var tG=Object.prototype,rG=tG.hasOwnProperty;function nG(e){if(!Zr(e))return YC(e);var t=Ga(e),r=[];for(var n in e)n=="constructor"&&(t||!rG.call(e,n))||r.push(n);return r}var JC=nG;function oG(e){return kf(e)?If(e,!0):JC(e)}var _a=oG;function iG(e,t){return e&&Po(t,_a(t),e)}var ZC=iG;i();var rx=typeof exports=="object"&&exports&&!exports.nodeType&&exports,QC=rx&&typeof module=="object"&&module&&!module.nodeType&&module,aG=QC&&QC.exports===rx,ex=aG?tt.Buffer:void 0,tx=ex?ex.allocUnsafe:void 0;function sG(e,t){if(t)return e.slice();var r=e.length,n=tx?tx(r):new e.constructor(r);return e.copy(n),n}var nx=sG;i();function uG(e,t){var r=-1,n=e.length;for(t||(t=Array(n));++r<n;)t[r]=e[r];return t}var Nf=uG;i();i();i();function lG(e,t){for(var r=-1,n=e==null?0:e.length,o=0,a=[];++r<n;){var s=e[r];t(s,r,e)&&(a[o++]=s)}return a}var ox=lG;i();function cG(){return[]}var Vf=cG;var fG=Object.prototype,pG=fG.propertyIsEnumerable,ix=Object.getOwnPropertySymbols,dG=ix?function(e){return e==null?[]:(e=Object(e),ox(ix(e),function(t){return pG.call(e,t)}))}:Vf,Wa=dG;function mG(e,t){return Po(e,Wa(e),t)}var ax=mG;i();i();i();function hG(e,t){for(var r=-1,n=t.length,o=e.length;++r<n;)e[o+r]=t[r];return e}var Lf=hG;var gG=Object.getOwnPropertySymbols,vG=gG?function(e){for(var t=[];e;)Lf(t,Wa(e)),e=Na(e);return t}:Vf,$f=vG;function yG(e,t){return Po(e,$f(e),t)}var sx=yG;i();i();function bG(e,t,r){var n=t(e);return Qr(e)?n:Lf(n,r(e))}var zf=bG;function CG(e){return zf(e,ja,Wa)}var ux=CG;i();function xG(e){return zf(e,_a,$f)}var lx=xG;i();i();var wG=Yt(tt,"DataView"),Hf=wG;i();var SG=Yt(tt,"Promise"),Gf=SG;i();var DG=Yt(tt,"Set"),jf=DG;i();var EG=Yt(tt,"WeakMap"),_f=EG;var cx="[object Map]",PG="[object Object]",fx="[object Promise]",px="[object Set]",dx="[object WeakMap]",mx="[object DataView]",TG=In(Hf),AG=In(Do),RG=In(Gf),FG=In(jf),BG=In(_f),fi=fr;(Hf&&fi(new Hf(new ArrayBuffer(1)))!=mx||Do&&fi(new Do)!=cx||Gf&&fi(Gf.resolve())!=fx||jf&&fi(new jf)!=px||_f&&fi(new _f)!=dx)&&(fi=function(e){var t=fr(e),r=t==PG?e.constructor:void 0,n=r?In(r):"";if(n)switch(n){case TG:return mx;case AG:return cx;case RG:return fx;case FG:return px;case BG:return dx}return t});var Ua=fi;i();var OG=Object.prototype,MG=OG.hasOwnProperty;function IG(e){var t=e.length,r=new e.constructor(t);return t&&typeof e[0]=="string"&&MG.call(e,"index")&&(r.index=e.index,r.input=e.input),r}var hx=IG;i();i();i();var kG=tt.Uint8Array,H0=kG;function NG(e){var t=new e.constructor(e.byteLength);return new H0(t).set(new H0(e)),t}var Ka=NG;i();function VG(e,t){var r=t?Ka(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.byteLength)}var gx=VG;i();var LG=/\w*$/;function $G(e){var t=new e.constructor(e.source,LG.exec(e));return t.lastIndex=e.lastIndex,t}var vx=$G;i();var yx=xr?xr.prototype:void 0,bx=yx?yx.valueOf:void 0;function zG(e){return bx?Object(bx.call(e)):{}}var Cx=zG;i();function HG(e,t){var r=t?Ka(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.length)}var xx=HG;var GG="[object Boolean]",jG="[object Date]",_G="[object Map]",WG="[object Number]",UG="[object RegExp]",KG="[object Set]",qG="[object String]",XG="[object Symbol]",YG="[object ArrayBuffer]",JG="[object DataView]",ZG="[object Float32Array]",QG="[object Float64Array]",ej="[object Int8Array]",tj="[object Int16Array]",rj="[object Int32Array]",nj="[object Uint8Array]",oj="[object Uint8ClampedArray]",ij="[object Uint16Array]",aj="[object Uint32Array]";function sj(e,t,r){var n=e.constructor;switch(t){case YG:return Ka(e);case GG:case jG:return new n(+e);case JG:return gx(e,r);case ZG:case QG:case ej:case tj:case rj:case nj:case oj:case ij:case aj:return xx(e,r);case _G:return new n;case WG:case qG:return new n(e);case UG:return vx(e);case KG:return new n;case XG:return Cx(e)}}var wx=sj;i();i();var Sx=Object.create,uj=function(){function e(){}return function(t){if(!Zr(t))return{};if(Sx)return Sx(t);e.prototype=t;var r=new e;return e.prototype=void 0,r}}(),Dx=uj;function lj(e){return typeof e.constructor=="function"&&!Ga(e)?Dx(Na(e)):{}}var Ex=lj;i();i();var cj="[object Map]";function fj(e){return Xt(e)&&Ua(e)==cj}var Px=fj;var Tx=Nn&&Nn.isMap,pj=Tx?Ha(Tx):Px,Ax=pj;i();i();var dj="[object Set]";function mj(e){return Xt(e)&&Ua(e)==dj}var Rx=mj;var Fx=Nn&&Nn.isSet,hj=Fx?Ha(Fx):Rx,Bx=hj;var gj=1,vj=2,yj=4,Ox="[object Arguments]",bj="[object Array]",Cj="[object Boolean]",xj="[object Date]",wj="[object Error]",Mx="[object Function]",Sj="[object GeneratorFunction]",Dj="[object Map]",Ej="[object Number]",Ix="[object Object]",Pj="[object RegExp]",Tj="[object Set]",Aj="[object String]",Rj="[object Symbol]",Fj="[object WeakMap]",Bj="[object ArrayBuffer]",Oj="[object DataView]",Mj="[object Float32Array]",Ij="[object Float64Array]",kj="[object Int8Array]",Nj="[object Int16Array]",Vj="[object Int32Array]",Lj="[object Uint8Array]",$j="[object Uint8ClampedArray]",zj="[object Uint16Array]",Hj="[object Uint32Array]",Ie={};Ie[Ox]=Ie[bj]=Ie[Bj]=Ie[Oj]=Ie[Cj]=Ie[xj]=Ie[Mj]=Ie[Ij]=Ie[kj]=Ie[Nj]=Ie[Vj]=Ie[Dj]=Ie[Ej]=Ie[Ix]=Ie[Pj]=Ie[Tj]=Ie[Aj]=Ie[Rj]=Ie[Lj]=Ie[$j]=Ie[zj]=Ie[Hj]=!0;Ie[wj]=Ie[Mx]=Ie[Fj]=!1;function Wf(e,t,r,n,o,a){var s,u=t&gj,l=t&vj,c=t&yj;if(r&&(s=o?r(e,n,o,a):r(e)),s!==void 0)return s;if(!Zr(e))return e;var p=Qr(e);if(p){if(s=hx(e),!u)return Nf(e,s)}else{var d=Ua(e),h=d==Mx||d==Sj;if(Of(e))return nx(e,u);if(d==Ix||d==Ox||h&&!o){if(s=l||h?{}:Ex(e),!u)return l?sx(e,ZC(s,e)):ax(e,XC(s,e))}else{if(!Ie[d])return o?e:{};s=wx(e,d,u)}}a||(a=new MC);var g=a.get(e);if(g)return g;a.set(e,s),Bx(e)?e.forEach(function(b){s.add(Wf(b,t,r,b,e,a))}):Ax(e)&&e.forEach(function(b,y){s.set(y,Wf(b,t,r,y,e,a))});var v=c?l?lx:ux:l?_a:ja,m=p?void 0:v(e);return IC(m||e,function(b,y){m&&(y=b,b=e[y]),Bf(s,y,Wf(b,t,r,y,e,a))}),s}var Uf=Wf;var Gj=1,jj=4;function _j(e){return Uf(e,Gj|jj)}var qa=_j;var Vn=U(Lx());import{createContext as S_,useContext as D_,Children as th,useRef as To,useEffect as Ao,useState as E_,useCallback as rt,useMemo as aw,useImperativeHandle as P_,createElement as Ro,useLayoutEffect as T_,forwardRef as A_,Component as R_}from"react";i();var Kj=!0;function qj(e,t){if(!Kj){if(e)return;var r="Warning: "+t;typeof console<"u"&&console.warn(r);try{throw Error(r)}catch{}}}var $x=qj;i();var Xj=4;function Yj(e){return Uf(e,Xj)}var j0=Yj;i();i();function Jj(e,t){for(var r=-1,n=e==null?0:e.length,o=Array(n);++r<n;)o[r]=t(e[r],r,e);return o}var Kf=Jj;i();var Zj="[object Symbol]";function Qj(e){return typeof e=="symbol"||Xt(e)&&fr(e)==Zj}var Xa=Qj;i();i();i();var e_="Expected a function";function _0(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(e_);var r=function(){var n=arguments,o=t?t.apply(this,n):n[0],a=r.cache;if(a.has(o))return a.get(o);var s=e.apply(this,n);return r.cache=a.set(o,s)||a,s};return r.cache=new(_0.Cache||Eu),r}_0.Cache=Eu;var zx=_0;var t_=500;function r_(e){var t=zx(e,function(n){return r.size===t_&&r.clear(),n}),r=t.cache;return t}var Hx=r_;var n_=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,o_=/\\(\\)?/g,i_=Hx(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(""),e.replace(n_,function(r,n,o,a){t.push(o?a.replace(o_,"$1"):n||r)}),t}),Gx=i_;i();var a_=1/0;function s_(e){if(typeof e=="string"||Xa(e))return e;var t=e+"";return t=="0"&&1/e==-a_?"-0":t}var jx=s_;i();i();var u_=1/0,_x=xr?xr.prototype:void 0,Wx=_x?_x.toString:void 0;function Ux(e){if(typeof e=="string")return e;if(Qr(e))return Kf(e,Ux)+"";if(Xa(e))return Wx?Wx.call(e):"";var t=e+"";return t=="0"&&1/e==-u_?"-0":t}var Kx=Ux;function l_(e){return e==null?"":Kx(e)}var qx=l_;function c_(e){return Qr(e)?Kf(e,jx):Xa(e)?[e]:Nf(Gx(qx(e)))}var W0=c_;var F_=U(iw());function Re(){return Re=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Re.apply(this,arguments)}function B_(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,e.__proto__=t}function di(e,t){if(e==null)return{};var r={},n=Object.keys(e),o,a;for(a=0;a<n.length;a++)o=n[a],!(t.indexOf(o)>=0)&&(r[o]=e[o]);return r}function sw(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}var ip=S_(void 0);ip.displayName="FormikContext";var O_=ip.Provider,Gze=ip.Consumer;function hi(){var e=D_(ip);return e||$x(!1),e}var uw=function(t){return Array.isArray(t)&&t.length===0},Nt=function(t){return typeof t=="function"},Tu=function(t){return t!==null&&typeof t=="object"},M_=function(t){return String(Math.floor(Number(t)))===t},J0=function(t){return Object.prototype.toString.call(t)==="[object String]"};var cw=function(t){return th.count(t)===0},Z0=function(t){return Tu(t)&&Nt(t.then)};function ft(e,t,r,n){n===void 0&&(n=0);for(var o=W0(t);e&&n<o.length;)e=e[o[n++]];return n!==o.length&&!e||e===void 0?r:e}function en(e,t,r){for(var n=j0(e),o=n,a=0,s=W0(t);a<s.length-1;a++){var u=s[a],l=ft(e,s.slice(0,a+1));if(l&&(Tu(l)||Array.isArray(l)))o=o[u]=j0(l);else{var c=s[a+1];o=o[u]=M_(c)&&Number(c)>=0?[]:{}}}return(a===0?e:o)[s[a]]===r?e:(r===void 0?delete o[s[a]]:o[s[a]]=r,a===0&&r===void 0&&delete n[s[a]],n)}function fw(e,t,r,n){r===void 0&&(r=new WeakMap),n===void 0&&(n={});for(var o=0,a=Object.keys(e);o<a.length;o++){var s=a[o],u=e[s];Tu(u)?r.get(u)||(r.set(u,!0),n[s]=Array.isArray(u)?[]:{},fw(u,t,r,n[s])):n[s]=t}return n}function I_(e,t){switch(t.type){case"SET_VALUES":return Re({},e,{values:t.payload});case"SET_TOUCHED":return Re({},e,{touched:t.payload});case"SET_ERRORS":return(0,Vn.default)(e.errors,t.payload)?e:Re({},e,{errors:t.payload});case"SET_STATUS":return Re({},e,{status:t.payload});case"SET_ISSUBMITTING":return Re({},e,{isSubmitting:t.payload});case"SET_ISVALIDATING":return Re({},e,{isValidating:t.payload});case"SET_FIELD_VALUE":return Re({},e,{values:en(e.values,t.payload.field,t.payload.value)});case"SET_FIELD_TOUCHED":return Re({},e,{touched:en(e.touched,t.payload.field,t.payload.value)});case"SET_FIELD_ERROR":return Re({},e,{errors:en(e.errors,t.payload.field,t.payload.value)});case"RESET_FORM":return Re({},e,t.payload);case"SET_FORMIK_STATE":return t.payload(e);case"SUBMIT_ATTEMPT":return Re({},e,{touched:fw(e.values,!0),isSubmitting:!0,submitCount:e.submitCount+1});case"SUBMIT_FAILURE":return Re({},e,{isSubmitting:!1});case"SUBMIT_SUCCESS":return Re({},e,{isSubmitting:!1});default:return e}}var pi={},op={};function k_(e){var t=e.validateOnChange,r=t===void 0?!0:t,n=e.validateOnBlur,o=n===void 0?!0:n,a=e.validateOnMount,s=a===void 0?!1:a,u=e.isInitialValid,l=e.enableReinitialize,c=l===void 0?!1:l,p=e.onSubmit,d=di(e,["validateOnChange","validateOnBlur","validateOnMount","isInitialValid","enableReinitialize","onSubmit"]),h=Re({validateOnChange:r,validateOnBlur:o,validateOnMount:s,onSubmit:p},d),g=To(h.initialValues),v=To(h.initialErrors||pi),m=To(h.initialTouched||op),b=To(h.initialStatus),y=To(!1),x=To({});Ao(function(){return y.current=!0,function(){y.current=!1}},[]);var w=E_(0),S=w[1],E=To({values:qa(h.initialValues),errors:qa(h.initialErrors)||pi,touched:qa(h.initialTouched)||op,status:qa(h.initialStatus),isSubmitting:!1,isValidating:!1,submitCount:0}),D=E.current,P=rt(function(B){var X=E.current;E.current=I_(X,B),X!==E.current&&S(function(te){return te+1})},[]),R=rt(function(B,X){return new Promise(function(te,q){var se=h.validate(B,X);se==null?te(pi):Z0(se)?se.then(function(we){te(we||pi)},function(we){q(we)}):te(se)})},[h.validate]),F=rt(function(B,X){var te=h.validationSchema,q=Nt(te)?te(X):te,se=X&&q.validateAt?q.validateAt(X,B):V_(B,q);return new Promise(function(we,Pe){se.then(function(){we(pi)},function(yt){yt.name==="ValidationError"?we(N_(yt)):Pe(yt)})})},[h.validationSchema]),M=rt(function(B,X){return new Promise(function(te){return te(x.current[B].validate(X))})},[]),G=rt(function(B){var X=Object.keys(x.current).filter(function(q){return Nt(x.current[q].validate)}),te=X.length>0?X.map(function(q){return M(q,ft(B,q))}):[Promise.resolve("DO_NOT_DELETE_YOU_WILL_BE_FIRED")];return Promise.all(te).then(function(q){return q.reduce(function(se,we,Pe){return we==="DO_NOT_DELETE_YOU_WILL_BE_FIRED"||we&&(se=en(se,X[Pe],we)),se},{})})},[M]),N=rt(function(B){return Promise.all([G(B),h.validationSchema?F(B):{},h.validate?R(B):{}]).then(function(X){var te=X[0],q=X[1],se=X[2],we=Df.all([te,q,se],{arrayMerge:L_});return we})},[h.validate,h.validationSchema,G,R,F]),L=wr(function(B){return B===void 0&&(B=D.values),P({type:"SET_ISVALIDATING",payload:!0}),N(B).then(function(X){return y.current&&(P({type:"SET_ISVALIDATING",payload:!1}),P({type:"SET_ERRORS",payload:X})),X})});Ao(function(){s&&y.current===!0&&(0,Vn.default)(g.current,h.initialValues)&&L(g.current)},[s,L]);var I=rt(function(B){var X=B&&B.values?B.values:g.current,te=B&&B.errors?B.errors:v.current?v.current:h.initialErrors||{},q=B&&B.touched?B.touched:m.current?m.current:h.initialTouched||{},se=B&&B.status?B.status:b.current?b.current:h.initialStatus;g.current=X,v.current=te,m.current=q,b.current=se;var we=function(){P({type:"RESET_FORM",payload:{isSubmitting:!!B&&!!B.isSubmitting,errors:te,touched:q,status:se,values:X,isValidating:!!B&&!!B.isValidating,submitCount:B&&B.submitCount&&typeof B.submitCount=="number"?B.submitCount:0}})};if(h.onReset){var Pe=h.onReset(D.values,Ee);Z0(Pe)?Pe.then(we):we()}else we()},[h.initialErrors,h.initialStatus,h.initialTouched,h.onReset]);Ao(function(){y.current===!0&&!(0,Vn.default)(g.current,h.initialValues)&&c&&(g.current=h.initialValues,I(),s&&L(g.current))},[c,h.initialValues,I,s,L]),Ao(function(){c&&y.current===!0&&!(0,Vn.default)(v.current,h.initialErrors)&&(v.current=h.initialErrors||pi,P({type:"SET_ERRORS",payload:h.initialErrors||pi}))},[c,h.initialErrors]),Ao(function(){c&&y.current===!0&&!(0,Vn.default)(m.current,h.initialTouched)&&(m.current=h.initialTouched||op,P({type:"SET_TOUCHED",payload:h.initialTouched||op}))},[c,h.initialTouched]),Ao(function(){c&&y.current===!0&&!(0,Vn.default)(b.current,h.initialStatus)&&(b.current=h.initialStatus,P({type:"SET_STATUS",payload:h.initialStatus}))},[c,h.initialStatus,h.initialTouched]);var V=wr(function(B){if(x.current[B]&&Nt(x.current[B].validate)){var X=ft(D.values,B),te=x.current[B].validate(X);return Z0(te)?(P({type:"SET_ISVALIDATING",payload:!0}),te.then(function(q){return q}).then(function(q){P({type:"SET_FIELD_ERROR",payload:{field:B,value:q}}),P({type:"SET_ISVALIDATING",payload:!1})})):(P({type:"SET_FIELD_ERROR",payload:{field:B,value:te}}),Promise.resolve(te))}else if(h.validationSchema)return P({type:"SET_ISVALIDATING",payload:!0}),F(D.values,B).then(function(q){return q}).then(function(q){P({type:"SET_FIELD_ERROR",payload:{field:B,value:ft(q,B)}}),P({type:"SET_ISVALIDATING",payload:!1})});return Promise.resolve()}),Y=rt(function(B,X){var te=X.validate;x.current[B]={validate:te}},[]),Q=rt(function(B){delete x.current[B]},[]),re=wr(function(B,X){P({type:"SET_TOUCHED",payload:B});var te=X===void 0?o:X;return te?L(D.values):Promise.resolve()}),H=rt(function(B){P({type:"SET_ERRORS",payload:B})},[]),le=wr(function(B,X){var te=Nt(B)?B(D.values):B;P({type:"SET_VALUES",payload:te});var q=X===void 0?r:X;return q?L(te):Promise.resolve()}),ve=rt(function(B,X){P({type:"SET_FIELD_ERROR",payload:{field:B,value:X}})},[]),me=wr(function(B,X,te){P({type:"SET_FIELD_VALUE",payload:{field:B,value:X}});var q=te===void 0?r:te;return q?L(en(D.values,B,X)):Promise.resolve()}),Ge=rt(function(B,X){var te=X,q=B,se;if(!J0(B)){B.persist&&B.persist();var we=B.target?B.target:B.currentTarget,Pe=we.type,yt=we.name,eo=we.id,Ir=we.value,N1=we.checked,W5=we.outerHTML,Yi=we.options,V1=we.multiple;te=X||yt||eo,q=/number|range/.test(Pe)?(se=parseFloat(Ir),isNaN(se)?"":se):/checkbox/.test(Pe)?z_(ft(D.values,te),N1,Ir):Yi&&V1?$_(Yi):Ir}te&&me(te,q)},[me,D.values]),A=wr(function(B){if(J0(B))return function(X){return Ge(X,B)};Ge(B)}),_=wr(function(B,X,te){X===void 0&&(X=!0),P({type:"SET_FIELD_TOUCHED",payload:{field:B,value:X}});var q=te===void 0?o:te;return q?L(D.values):Promise.resolve()}),z=rt(function(B,X){B.persist&&B.persist();var te=B.target,q=te.name,se=te.id,we=te.outerHTML,Pe=X||q||se;_(Pe,!0)},[_]),j=wr(function(B){if(J0(B))return function(X){return z(X,B)};z(B)}),ue=rt(function(B){Nt(B)?P({type:"SET_FORMIK_STATE",payload:B}):P({type:"SET_FORMIK_STATE",payload:function(){return B}})},[]),oe=rt(function(B){P({type:"SET_STATUS",payload:B})},[]),he=rt(function(B){P({type:"SET_ISSUBMITTING",payload:B})},[]),Ce=wr(function(){return P({type:"SUBMIT_ATTEMPT"}),L().then(function(B){var X=B instanceof Error,te=!X&&Object.keys(B).length===0;if(te){var q;try{if(q=xe(),q===void 0)return}catch(se){throw se}return Promise.resolve(q).then(function(se){return y.current&&P({type:"SUBMIT_SUCCESS"}),se}).catch(function(se){if(y.current)throw P({type:"SUBMIT_FAILURE"}),se})}else if(y.current&&(P({type:"SUBMIT_FAILURE"}),X))throw B})}),Se=wr(function(B){if(B&&B.preventDefault&&Nt(B.preventDefault)&&B.preventDefault(),B&&B.stopPropagation&&Nt(B.stopPropagation)&&B.stopPropagation(),0)var X;Ce().catch(function(te){console.warn("Warning: An unhandled error was caught from submitForm()",te)})}),Ee={resetForm:I,validateForm:L,validateField:V,setErrors:H,setFieldError:ve,setFieldTouched:_,setFieldValue:me,setStatus:oe,setSubmitting:he,setTouched:re,setValues:le,setFormikState:ue,submitForm:Ce},xe=wr(function(){return p(D.values,Ee)}),gt=wr(function(B){B&&B.preventDefault&&Nt(B.preventDefault)&&B.preventDefault(),B&&B.stopPropagation&&Nt(B.stopPropagation)&&B.stopPropagation(),I()}),vt=rt(function(B){return{value:ft(D.values,B),error:ft(D.errors,B),touched:!!ft(D.touched,B),initialValue:ft(g.current,B),initialTouched:!!ft(m.current,B),initialError:ft(v.current,B)}},[D.errors,D.touched,D.values]),je=rt(function(B){return{setValue:function(te,q){return me(B,te,q)},setTouched:function(te,q){return _(B,te,q)},setError:function(te){return ve(B,te)}}},[me,_,ve]),or=rt(function(B){var X=Tu(B),te=X?B.name:B,q=ft(D.values,te),se={name:te,value:q,onChange:A,onBlur:j};if(X){var we=B.type,Pe=B.value,yt=B.as,eo=B.multiple;we==="checkbox"?Pe===void 0?se.checked=!!q:(se.checked=!!(Array.isArray(q)&&~q.indexOf(Pe)),se.value=Pe):we==="radio"?(se.checked=q===Pe,se.value=Pe):yt==="select"&&eo&&(se.value=se.value||[],se.multiple=!0)}return se},[j,A,D.values]),Ht=aw(function(){return!(0,Vn.default)(g.current,D.values)},[g.current,D.values]),St=aw(function(){return typeof u<"u"?Ht?D.errors&&Object.keys(D.errors).length===0:u!==!1&&Nt(u)?u(h):u:D.errors&&Object.keys(D.errors).length===0},[u,Ht,D.errors,h]),ir=Re({},D,{initialValues:g.current,initialErrors:v.current,initialTouched:m.current,initialStatus:b.current,handleBlur:j,handleChange:A,handleReset:gt,handleSubmit:Se,resetForm:I,setErrors:H,setFormikState:ue,setFieldTouched:_,setFieldValue:me,setFieldError:ve,setStatus:oe,setSubmitting:he,setTouched:re,setValues:le,submitForm:Ce,validateForm:L,validateField:V,isValid:St,dirty:Ht,unregisterField:Q,registerField:Y,getFieldProps:or,getFieldMeta:vt,getFieldHelpers:je,validateOnBlur:o,validateOnChange:r,validateOnMount:s});return ir}function pw(e){var t=k_(e),r=e.component,n=e.children,o=e.render,a=e.innerRef;return P_(a,function(){return t}),Ro(O_,{value:t},r?Ro(r,t):o?o(t):n?Nt(n)?n(t):cw(n)?null:th.only(n):null)}function N_(e){var t={};if(e.inner){if(e.inner.length===0)return en(t,e.path,e.message);for(var o=e.inner,r=Array.isArray(o),n=0,o=r?o:o[Symbol.iterator]();;){var a;if(r){if(n>=o.length)break;a=o[n++]}else{if(n=o.next(),n.done)break;a=n.value}var s=a;ft(t,s.path)||(t=en(t,s.path,s.message))}}return t}function V_(e,t,r,n){r===void 0&&(r=!1);var o=eh(e);return t[r?"validateSync":"validate"](o,{abortEarly:!1,context:n||o})}function eh(e){var t=Array.isArray(e)?[]:{};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){var n=String(r);Array.isArray(e[n])===!0?t[n]=e[n].map(function(o){return Array.isArray(o)===!0||N0(o)?eh(o):o!==""?o:void 0}):N0(e[n])?t[n]=eh(e[n]):t[n]=e[n]!==""?e[n]:void 0}return t}function L_(e,t,r){var n=e.slice();return t.forEach(function(a,s){if(typeof n[s]>"u"){var u=r.clone!==!1,l=u&&r.isMergeableObject(a);n[s]=l?Df(Array.isArray(a)?[]:{},a,r):a}else r.isMergeableObject(a)?n[s]=Df(e[s],a,r):e.indexOf(a)===-1&&n.push(a)}),n}function $_(e){return Array.from(e).filter(function(t){return t.selected}).map(function(t){return t.value})}function z_(e,t,r){if(typeof e=="boolean")return!!t;var n=[],o=!1,a=-1;if(Array.isArray(e))n=e,a=e.indexOf(r),o=a>=0;else if(!r||r=="true"||r=="false")return!!t;return t&&r&&!o?n.concat(r):o?n.slice(0,a).concat(n.slice(a+1)):n}var H_=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u"?T_:Ao;function wr(e){var t=To(e);return H_(function(){t.current=e}),rt(function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return t.current.apply(void 0,n)},[])}function dw(e){var t=e.validate,r=e.name,n=e.render,o=e.children,a=e.as,s=e.component,u=e.className,l=di(e,["validate","name","render","children","as","component","className"]),c=hi(),p=di(c,["validate","validationSchema"]),d=p.registerField,h=p.unregisterField;Ao(function(){return d(r,{validate:t}),function(){h(r)}},[d,h,r,t]);var g=p.getFieldProps(Re({name:r},l)),v=p.getFieldMeta(r),m={field:g,form:p};if(n)return n(Re({},m,{meta:v}));if(Nt(o))return o(Re({},m,{meta:v}));if(s){if(typeof s=="string"){var b=l.innerRef,y=di(l,["innerRef"]);return Ro(s,Re({ref:b},g,y,{className:u}),o)}return Ro(s,Re({field:g,form:p},l,{className:u}),o)}var x=a||"input";if(typeof x=="string"){var w=l.innerRef,S=di(l,["innerRef"]);return Ro(x,Re({ref:w},g,S,{className:u}),o)}return Ro(x,Re({},g,l,{className:u}),o)}var rh=A_(function(e,t){var r=e.action,n=di(e,["action"]),o=r??"#",a=hi(),s=a.handleReset,u=a.handleSubmit;return Ro("form",Re({onSubmit:u,ref:t,onReset:s,action:o},n))});rh.displayName="Form";var G_=function(t,r,n){var o=mi(t),a=o[r];return o.splice(r,1),o.splice(n,0,a),o},j_=function(t,r,n){var o=mi(t),a=o[r];return o[r]=o[n],o[n]=a,o},Q0=function(t,r,n){var o=mi(t);return o.splice(r,0,n),o},__=function(t,r,n){var o=mi(t);return o[r]=n,o},mi=function(t){if(t){if(Array.isArray(t))return[].concat(t);var r=Object.keys(t).map(function(n){return parseInt(n)}).reduce(function(n,o){return o>n?o:n},0);return Array.from(Re({},t,{length:r+1}))}else return[]},lw=function(t,r){var n=typeof t=="function"?t:r;return function(o){if(Array.isArray(o)||Tu(o)){var a=mi(o);return n(a)}return o}},W_=function(e){B_(t,e);function t(n){var o;return o=e.call(this,n)||this,o.updateArrayField=function(a,s,u){var l=o.props,c=l.name,p=l.formik.setFormikState;p(function(d){var h=lw(u,a),g=lw(s,a),v=en(d.values,c,a(ft(d.values,c))),m=u?h(ft(d.errors,c)):void 0,b=s?g(ft(d.touched,c)):void 0;return uw(m)&&(m=void 0),uw(b)&&(b=void 0),Re({},d,{values:v,errors:u?en(d.errors,c,m):d.errors,touched:s?en(d.touched,c,b):d.touched})})},o.push=function(a){return o.updateArrayField(function(s){return[].concat(mi(s),[qa(a)])},!1,!1)},o.handlePush=function(a){return function(){return o.push(a)}},o.swap=function(a,s){return o.updateArrayField(function(u){return j_(u,a,s)},!0,!0)},o.handleSwap=function(a,s){return function(){return o.swap(a,s)}},o.move=function(a,s){return o.updateArrayField(function(u){return G_(u,a,s)},!0,!0)},o.handleMove=function(a,s){return function(){return o.move(a,s)}},o.insert=function(a,s){return o.updateArrayField(function(u){return Q0(u,a,s)},function(u){return Q0(u,a,null)},function(u){return Q0(u,a,null)})},o.handleInsert=function(a,s){return function(){return o.insert(a,s)}},o.replace=function(a,s){return o.updateArrayField(function(u){return __(u,a,s)},!1,!1)},o.handleReplace=function(a,s){return function(){return o.replace(a,s)}},o.unshift=function(a){var s=-1;return o.updateArrayField(function(u){var l=u?[a].concat(u):[a];return s=l.length,l},function(u){return u?[null].concat(u):[null]},function(u){return u?[null].concat(u):[null]}),s},o.handleUnshift=function(a){return function(){return o.unshift(a)}},o.handleRemove=function(a){return function(){return o.remove(a)}},o.handlePop=function(){return function(){return o.pop()}},o.remove=o.remove.bind(sw(o)),o.pop=o.pop.bind(sw(o)),o}var r=t.prototype;return r.componentDidUpdate=function(o){this.props.validateOnChange&&this.props.formik.validateOnChange&&!(0,Vn.default)(ft(o.formik.values,o.name),ft(this.props.formik.values,this.props.name))&&this.props.formik.validateForm(this.props.formik.values)},r.remove=function(o){var a;return this.updateArrayField(function(s){var u=s?mi(s):[];return a||(a=u[o]),Nt(u.splice)&&u.splice(o,1),Nt(u.every)&&u.every(function(l){return l===void 0})?[]:u},!0,!0),a},r.pop=function(){var o;return this.updateArrayField(function(a){var s=a.slice();return o||(o=s&&s.pop&&s.pop()),s},!0,!0),o},r.render=function(){var o={push:this.push,pop:this.pop,swap:this.swap,move:this.move,insert:this.insert,replace:this.replace,unshift:this.unshift,remove:this.remove,handlePush:this.handlePush,handlePop:this.handlePop,handleSwap:this.handleSwap,handleMove:this.handleMove,handleInsert:this.handleInsert,handleReplace:this.handleReplace,handleUnshift:this.handleUnshift,handleRemove:this.handleRemove},a=this.props,s=a.component,u=a.render,l=a.children,c=a.name,p=a.formik,d=di(p,["validate","validationSchema"]),h=Re({},o,{form:d,name:c});return s?Ro(s,h):u?u(h):l?typeof l=="function"?l(h):cw(l)?null:th.only(l):null},t}(R_);W_.defaultProps={validateOnChange:!0};i();i();import{useState as U_}from"react";var K_=()=>{let[e,t]=U_(!1),r=()=>t(!0),n=()=>t(!0),o=()=>t(!0),u={onFocus:r,onMouseEnter:n,onBlur:()=>t(!1),onMouseLeave:()=>t(!1)};return e||(u.onMouseMove=o),[e,u,t]};i();i();import{useMemo as q_}from"react";var X_=e=>typeof e=="function"?e:typeof e=="string"?t=>t.key===e:e!=null&&e?()=>!0:()=>!1,ap=(e,t,r={},n=[e])=>{let{eventName:o="keydown",eventTarget:a,eventOptions:s}=r,u=q_(()=>{let l=X_(e);return c=>{if(!(["INPUT","TEXTAREA","SELECT"].includes(document.activeElement?.nodeName??"")||document.activeElement?.isContentEditable)&&l(c))return t(c)}},n);B0(o,u,a,s)};i();i();import{useState as Y_}from"react";var nh=e=>{let[t,r]=Y_([!1,null]);return ap(e,n=>r([!0,n]),{eventName:"keydown"},[t]),ap(e,n=>r([!1,n]),{eventName:"keyup"},[t]),t};i();i();i();i();import{useEffect as J_,useRef as Z_}from"react";var oh=(e,t)=>{let r=Z_(!0);J_(()=>r.current?(r.current=!1,()=>{}):e(),t)};var ih=(e,t=void 0,r=void 0)=>{let[n,o]=nh(e);oh(()=>(!n&&r&&o!==null?r(o):n&&t&&o!==null&&t(o),()=>{}),[n])};i();i();import{useState as Q_}from"react";var eW=(e,t,r=window.localStorage)=>{let[n,o]=Q_(()=>{try{let u=r.getItem(e);return u!==null&&u?JSON.parse(u):t}catch(u){return console.log(u),t}});return[n,u=>{try{let l=u instanceof Function?u(n):u;o(l),r.setItem(e,JSON.stringify(l))}catch(l){console.error(l)}},()=>{r.removeItem(e),o(void 0)}]};i();i();var Au=e=>t=>{e.forEach(r=>{typeof r=="function"?r(t):r!=null&&(r.current=t)})};i();i();import{useEffect as tW}from"react";var Ru=(e,t)=>{tW(()=>{let r=n=>{!e.current||e.current.contains(n.target)||t(n)};return document.addEventListener("mousedown",r),document.addEventListener("touchstart",r),()=>{document.removeEventListener("mousedown",r),document.removeEventListener("touchstart",r)}},[e,t])};i();i();import{useLayoutEffect as rW}from"react";var ah=e=>{rW(()=>{if(e){let t=window.getComputedStyle(document.body).overflow;return document.body.style.overflow="hidden",()=>{document.body.style.overflow=t}}return()=>{}},[e])};i();i();import{useEffect as nW,useRef as oW}from"react";var Fu=e=>{let t=oW();return nW(()=>{t.current=e}),t.current};i();i();var Hw=U(Z());import hp from"styled-components";i();i();var Cw=U(up()),Sr=U(Z());import{useEffect as gi,useRef as gw,useState as vw,useCallback as yw}from"react";import{createPortal as hW}from"react-dom";import{createGlobalStyle as gW}from"styled-components";i();i();import{Children as lW}from"react";var hw=U(Z());import{createGlobalStyle as cW}from"styled-components";import{Fragment as dW,jsx as sh,jsxs as mW}from"react/jsx-runtime";var fW=100,pW=cW`
709
709
  .EnterTransition {
710
710
  opacity: 0;
711
711
  }
@@ -736,7 +736,7 @@ var zO=Object.create;var Nl=Object.defineProperty;var HO=Object.getOwnPropertyDe
736
736
  width: auto;
737
737
  }
738
738
  }
739
- `,Fo=({children:e,align:t="left",fullWidth:r=!1,...n})=>(0,ww.isNil)(e)?null:DW(SW,{align:t,fullWidth:r,...n,children:e});Fo.displayName="ButtonGroup_VHS";i();i();import{forwardRef as RW}from"react";import FW,{css as bt}from"styled-components";i();i();var Sw=U(Z());import EW,{css as lh}from"styled-components";import{jsx as AW}from"react/jsx-runtime";var Dr=lh`
739
+ `,Fo=({children:e,align:t="left",fullWidth:r=!1,...n})=>(0,ww.isNil)(e)?null:DW(SW,{align:t,fullWidth:r,...n,children:e});Fo.displayName="ButtonGroup_VHS";i();i();import{forwardRef as RW}from"react";import FW,{css as Ct}from"styled-components";i();i();var Sw=U(Z());import EW,{css as lh}from"styled-components";import{jsx as AW}from"react/jsx-runtime";var Dr=lh`
740
740
  overflow: hidden;
741
741
  text-overflow: ellipsis;
742
742
  white-space: nowrap;
@@ -768,44 +768,44 @@ var zO=Object.create;var Nl=Object.defineProperty;var HO=Object.getOwnPropertyDe
768
768
  display: -webkit-box;
769
769
  white-space: initial;
770
770
  `}}
771
- `,Dw=({children:e,lines:t,...r})=>AW(TW,{lines:t,...r,children:e});Dw.displayName="Ellipsis_VHS";import{jsx as _W}from"react/jsx-runtime";var BW={left:"left",right:"right",center:"center",justify:"justify"};var OW=bt`
771
+ `,Dw=({children:e,lines:t,...r})=>AW(TW,{lines:t,...r,children:e});Dw.displayName="Ellipsis_VHS";import{jsx as _W}from"react/jsx-runtime";var BW={left:"left",right:"right",center:"center",justify:"justify"};var OW=Ct`
772
772
  font-size: 24px;
773
773
  font-weight: ${({theme:e})=>e.font.weight.bold};
774
774
  line-height: 1.25;
775
- `,MW=bt`
775
+ `,MW=Ct`
776
776
  font-size: 20px;
777
777
  font-weight: ${({theme:e})=>e.font.weight.medium};
778
778
  line-height: 1.25;
779
- `,IW=bt`
779
+ `,IW=Ct`
780
780
  font-size: 16px;
781
781
  font-weight: ${({theme:e})=>e.font.weight.bold};
782
782
  line-height: 1.25;
783
- `,kW=bt`
783
+ `,kW=Ct`
784
784
  font-size: 12px;
785
785
  font-weight: ${({theme:e})=>e.font.weight.bold};
786
786
  line-height: 1.25;
787
787
  text-transform: uppercase;
788
- `,NW=bt`
788
+ `,NW=Ct`
789
789
  font-size: 16px;
790
790
  font-weight: ${({theme:e})=>e.font.weight.regular};
791
791
  line-height: 1.5;
792
- `,VW=bt`
792
+ `,VW=Ct`
793
793
  font-size: 14px;
794
794
  font-weight: ${({theme:e})=>e.font.weight.regular};
795
795
  line-height: 1.5;
796
- `,LW=bt`
796
+ `,LW=Ct`
797
797
  font-size: 12px;
798
798
  font-weight: ${({theme:e})=>e.font.weight.regular};
799
799
  line-height: 1.5;
800
- `,$W=bt`
800
+ `,$W=Ct`
801
801
  font-size: 16px;
802
802
  font-weight: ${({theme:e})=>e.font.weight.medium};
803
803
  line-height: 1.5;
804
- `,zW=bt`
804
+ `,zW=Ct`
805
805
  font-size: 14px;
806
806
  font-weight: ${({theme:e})=>e.font.weight.medium};
807
807
  line-height: 1.5;
808
- `,HW=bt`
808
+ `,HW=Ct`
809
809
  font-family: ${({theme:e})=>e.font.family.monospace};
810
810
  font-size: 14px;
811
811
  font-weight: ${({theme:e})=>e.font.weight.regular};
@@ -816,25 +816,25 @@ var zO=Object.create;var Nl=Object.defineProperty;var HO=Object.getOwnPropertyDe
816
816
  margin: 0;
817
817
  ${({variant:e})=>GW[e]}
818
818
  ${({ellipsis:e})=>e&&Dr};
819
- ${({bold:e})=>e&&bt`
819
+ ${({bold:e})=>e&&Ct`
820
820
  font-weight: ${({theme:t})=>t.font.weight.bold} !important;
821
821
  `}
822
- ${({italic:e})=>e&&bt`
822
+ ${({italic:e})=>e&&Ct`
823
823
  font-style: italic;
824
824
  `}
825
- ${({inline:e})=>e&&bt`
825
+ ${({inline:e})=>e&&Ct`
826
826
  display: inline-block;
827
827
  `}
828
- ${({disabled:e})=>e&&bt`
828
+ ${({disabled:e})=>e&&Ct`
829
829
  opacity: 0.5;
830
830
  `}
831
- ${({preventUserSelect:e})=>e&&bt`
831
+ ${({preventUserSelect:e})=>e&&Ct`
832
832
  user-select: none;
833
833
  `}
834
- ${({align:e})=>bt`
834
+ ${({align:e})=>Ct`
835
835
  text-align: ${BW[e]};
836
836
  `}
837
- ${({as:e,theme:t})=>e==="p"&&bt`
837
+ ${({as:e,theme:t})=>e==="p"&&Ct`
838
838
  display: block;
839
839
  margin-bottom: ${t.spacing.space05};
840
840
  `}
@@ -866,7 +866,7 @@ var zO=Object.create;var Nl=Object.defineProperty;var HO=Object.getOwnPropertyDe
866
866
  &:not(:focus-within) {
867
867
  ${Mu}
868
868
  }
869
- `,lp=({text:e,children:t,focusable:r=!1,...n})=>{let o=(0,Tw.isNotNil)(e)?e:t;return r?Ew(ZW,{...n,children:o}):Ew(JW,{...n,children:o})};lp.displayName="ScreenReaderOnly_VHS";i();i();import{useEffect as sU,useState as uU,useRef as Iw,useMemo as lU}from"react";import cU from"styled-components";i();i();var Ct=[];for(cp=0;cp<256;++cp)Ct.push((cp+256).toString(16).slice(1));var cp;function Aw(e,t=0){return(Ct[e[t+0]]+Ct[e[t+1]]+Ct[e[t+2]]+Ct[e[t+3]]+"-"+Ct[e[t+4]]+Ct[e[t+5]]+"-"+Ct[e[t+6]]+Ct[e[t+7]]+"-"+Ct[e[t+8]]+Ct[e[t+9]]+"-"+Ct[e[t+10]]+Ct[e[t+11]]+Ct[e[t+12]]+Ct[e[t+13]]+Ct[e[t+14]]+Ct[e[t+15]]).toLowerCase()}i();var fp,QW=new Uint8Array(16);function ch(){if(!fp&&(fp=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!fp))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return fp(QW)}i();i();var eU=typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto),fh={randomUUID:eU};function tU(e,t,r){if(fh.randomUUID&&!t&&!e)return fh.randomUUID();e=e||{};var n=e.random||(e.rng||ch)();if(n[6]=n[6]&15|64,n[8]=n[8]&63|128,t){r=r||0;for(var o=0;o<16;++o)t[r+o]=n[o];return t}return Aw(n)}var Iu=tU;var kw=U(Z());i();import Fw,{css as pp}from"styled-components";import{jsx as Rw}from"react/jsx-runtime";var vi=8,ku=Fw.div`
869
+ `,lp=({text:e,children:t,focusable:r=!1,...n})=>{let o=(0,Tw.isNotNil)(e)?e:t;return r?Ew(ZW,{...n,children:o}):Ew(JW,{...n,children:o})};lp.displayName="ScreenReaderOnly_VHS";i();i();import{useEffect as sU,useState as uU,useRef as Iw,useMemo as lU}from"react";import cU from"styled-components";i();i();var xt=[];for(cp=0;cp<256;++cp)xt.push((cp+256).toString(16).slice(1));var cp;function Aw(e,t=0){return(xt[e[t+0]]+xt[e[t+1]]+xt[e[t+2]]+xt[e[t+3]]+"-"+xt[e[t+4]]+xt[e[t+5]]+"-"+xt[e[t+6]]+xt[e[t+7]]+"-"+xt[e[t+8]]+xt[e[t+9]]+"-"+xt[e[t+10]]+xt[e[t+11]]+xt[e[t+12]]+xt[e[t+13]]+xt[e[t+14]]+xt[e[t+15]]).toLowerCase()}i();var fp,QW=new Uint8Array(16);function ch(){if(!fp&&(fp=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!fp))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return fp(QW)}i();i();var eU=typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto),fh={randomUUID:eU};function tU(e,t,r){if(fh.randomUUID&&!t&&!e)return fh.randomUUID();e=e||{};var n=e.random||(e.rng||ch)();if(n[6]=n[6]&15|64,n[8]=n[8]&63|128,t){r=r||0;for(var o=0;o<16;++o)t[r+o]=n[o];return t}return Aw(n)}var Iu=tU;var kw=U(Z());i();import Fw,{css as pp}from"styled-components";import{jsx as Rw}from"react/jsx-runtime";var vi=8,ku=Fw.div`
870
870
  color: ${({fontColorOverride:e})=>e??"white"};
871
871
  font-size: 12px;
872
872
  font-weight: ${({theme:e})=>e.font.weight.regular};
@@ -1821,14 +1821,14 @@ var zO=Object.create;var Nl=Object.defineProperty;var HO=Object.getOwnPropertyDe
1821
1821
  }
1822
1822
 
1823
1823
  width: ${({fullWidth:e})=>e?"100%":"auto"};
1824
- `,Uh=(e,t,r)=>{let n=({groupLabel:o,groupOptions:a,disabled:s=!1})=>Wh("optgroup",{"data-testid":o,disabled:s,label:o,children:Uh(a)},o);return e.map(o=>{if(Object.prototype.hasOwnProperty.call(o,"groupLabel"))return n(o);let{label:a,value:s,disabled:u=!1}=o,l=(0,xi.isNonEmptyString)(r)?o[r]:s,c=(0,xi.isNonEmptyString)(t)?o[t]:a;return(0,xi.isBoolean)(l)&&(l=ur(l)),Wh("option",{disabled:u,value:l,children:c},`${ur(c)}--${ur(l)}`)})},zX=(e,t,r)=>(0,xi.isNotNil)(e)&&!r?Uh([{label:e,value:"",disabled:t}]):null,HX=e=>e?null:Wh(De,{size:"md",type:"caret-down"}),wi=NX(({ariaLabel:e,disabled:t=!1,forceState:r,fullWidth:n=!0,hasError:o=!1,labelName:a="label",multiple:s=!1,options:u,placeholder:l="Please select...",preventPlaceholderSelection:c=!1,required:p=!1,valueName:d="value",...h},g)=>aD($X,{disabled:t,forceState:r,fullWidth:n,children:[aD(jh,{ref:g,"aria-invalid":o?"true":"false","aria-label":e,disabled:t,forceState:r,hasError:o,multiple:s,required:p,...h,children:[zX(l,c,s),Uh(u,a,d)]}),HX(s)]}));wi.displayName="Select_VHS";import{jsx as sD}from"react/jsx-runtime";var Up=({disabled:e=!1,field:{name:t,value:r,onChange:n,onBlur:o},form:{errors:a},label:s,labelDescription:u,labelProps:l={},options:c,placeholder:p,onChangeCustom:d,...h})=>{let g=v=>(0,Wp.isNil)(v)?"":(0,Wp.isBoolean)(v)?ur(r):v;return sD(Jt,{disabled:e,error:a[t],label:s,labelDescription:u,labelProps:l,name:t,children:sD(wi,{"data-testid":`select-${t}`,disabled:e,name:t,onBlur:o,onChange:v=>{n(v),d&&d(v.target.value)},options:c,placeholder:p,value:g(r),...h})})};Up.displayName="FormConnectorSelect_VHS";i();i();var rs=U(Z());import{useEffect as GX}from"react";import{jsx as jX}from"react/jsx-runtime";var Kp=({field:{name:e,value:t,onChange:r},form:{setFieldValue:n}={},onChangeCustom:o,valueState:a="",...s})=>(GX(()=>{!a&&(0,rs.isNil)(t)||a!==t&&(0,rs.isNotUndefined)(n)&&n(e,a)},[n,e,a,t]),jX(ts,{"data-testid":`input-${e}`,name:e,onChange:u=>{r(u),(0,rs.isNotUndefined)(o)&&o(u.target.value)},type:"hidden",value:(0,rs.isNil)(t)?"":t,...s}));Kp.displayName="FormConnectorHidden_VHS";i();i();var YT=U(Z());import{useState as ure,useEffect as lre}from"react";import cre from"styled-components";i();i();import{useCallback as cg,useMemo as tre,useEffect as rre}from"react";import KT from"styled-components";i();var z2=U(fD()),xP=U(Yh()),wP=U(_D());import de,{createContext as Bi,useContext as fs,useRef as gr,useEffect as jn,useLayoutEffect as PQ,useState as Fi,memo as TQ,forwardRef as AQ,useCallback as ke,Component as RQ,useReducer as FQ,useMemo as dd}from"react";i();i();function WD(e){return typeof e=="object"&&e!=null&&e.nodeType===1}function UD(e,t){return(!t||e!=="hidden")&&e!=="visible"&&e!=="clip"}function Jh(e,t){if(e.clientHeight<e.scrollHeight||e.clientWidth<e.scrollWidth){var r=getComputedStyle(e,null);return UD(r.overflowY,t)||UD(r.overflowX,t)||function(n){var o=function(a){if(!a.ownerDocument||!a.ownerDocument.defaultView)return null;try{return a.ownerDocument.defaultView.frameElement}catch{return null}}(n);return!!o&&(o.clientHeight<n.scrollHeight||o.clientWidth<n.scrollWidth)}(e)}return!1}function Xp(e,t,r,n,o,a,s,u){return a<e&&s>t||a>e&&s<t?0:a<=e&&u<=r||s>=t&&u>=r?a-e-n:s>t&&u<r||a<e&&u>r?s-t+o:0}var Zh=function(e,t){var r=window,n=t.scrollMode,o=t.block,a=t.inline,s=t.boundary,u=t.skipOverflowHiddenElements,l=typeof s=="function"?s:function(xe){return xe!==s};if(!WD(e))throw new TypeError("Invalid target");for(var c,p,d=document.scrollingElement||document.documentElement,h=[],g=e;WD(g)&&l(g);){if((g=(p=(c=g).parentElement)==null?c.getRootNode().host||null:p)===d){h.push(g);break}g!=null&&g===document.body&&Jh(g)&&!Jh(document.documentElement)||g!=null&&Jh(g,u)&&h.push(g)}for(var v=r.visualViewport?r.visualViewport.width:innerWidth,m=r.visualViewport?r.visualViewport.height:innerHeight,b=window.scrollX||pageXOffset,y=window.scrollY||pageYOffset,x=e.getBoundingClientRect(),w=x.height,S=x.width,E=x.top,D=x.right,P=x.bottom,R=x.left,F=o==="start"||o==="nearest"?E:o==="end"?P:E+w/2,M=a==="center"?R+S/2:a==="end"?D:R,G=[],N=0;N<h.length;N++){var L=h[N],I=L.getBoundingClientRect(),V=I.height,Y=I.width,Q=I.top,re=I.right,H=I.bottom,le=I.left;if(n==="if-needed"&&E>=0&&R>=0&&P<=m&&D<=v&&E>=Q&&P<=H&&R>=le&&D<=re)return G;var ve=getComputedStyle(L),me=parseInt(ve.borderLeftWidth,10),Ge=parseInt(ve.borderTopWidth,10),A=parseInt(ve.borderRightWidth,10),_=parseInt(ve.borderBottomWidth,10),z=0,j=0,ue="offsetWidth"in L?L.offsetWidth-L.clientWidth-me-A:0,oe="offsetHeight"in L?L.offsetHeight-L.clientHeight-Ge-_:0,he="offsetWidth"in L?L.offsetWidth===0?0:Y/L.offsetWidth:0,Ce="offsetHeight"in L?L.offsetHeight===0?0:V/L.offsetHeight:0;if(d===L)z=o==="start"?F:o==="end"?F-m:o==="nearest"?Xp(y,y+m,m,Ge,_,y+F,y+F+w,w):F-m/2,j=a==="start"?M:a==="center"?M-v/2:a==="end"?M-v:Xp(b,b+v,v,me,A,b+M,b+M+S,S),z=Math.max(0,z+y),j=Math.max(0,j+b);else{z=o==="start"?F-Q-Ge:o==="end"?F-H+_+oe:o==="nearest"?Xp(Q,H,V,Ge,_+oe,F,F+w,w):F-(Q+V/2)+oe/2,j=a==="start"?M-le-me:a==="center"?M-(le+Y/2)+ue/2:a==="end"?M-re+A+ue:Xp(le,re,Y,me,A+ue,M,M+S,S);var Se=L.scrollLeft,Ee=L.scrollTop;F+=Ee-(z=Math.max(0,Math.min(Ee+z/Ce,L.scrollHeight-V/Ce+oe))),M+=Se-(j=Math.max(0,Math.min(Se+j/he,L.scrollWidth-Y/he+ue)))}G.push({el:L,top:z,left:j})}return G};function KD(e){return e===Object(e)&&Object.keys(e).length!==0}function $Y(e,t){t===void 0&&(t="auto");var r="scrollBehavior"in document.body.style;e.forEach(function(n){var o=n.el,a=n.top,s=n.left;o.scroll&&r?o.scroll({top:a,left:s,behavior:t}):(o.scrollTop=a,o.scrollLeft=s)})}function zY(e){return e===!1?{block:"end",inline:"nearest"}:KD(e)?e:{block:"start",inline:"nearest"}}function HY(e,t){var r=e.isConnected||e.ownerDocument.documentElement.contains(e);if(KD(t)&&typeof t.behavior=="function")return t.behavior(r?Zh(e,t):[]);if(r){var n=zY(t);return $Y(Zh(e,n),n.behavior)}}var qD=HY;i();i();function XD(e){return Object.prototype.toString.call(e)==="[object Object]"}function Xe(e){var t,r;return XD(e)===!1?!1:(t=e.constructor,t===void 0?!0:(r=t.prototype,!(XD(r)===!1||r.hasOwnProperty("isPrototypeOf")===!1)))}i();function zr(e){for(var t=arguments.length,r=Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];if(0)var o,a;throw Error("[Immer] minified error nr: "+e+(r.length?" "+r.map(function(s){return"'"+s+"'"}).join(","):"")+". Find the full error at: https://bit.ly/3cXEKWf")}function Mo(e){return!!e&&!!e[mr]}function Di(e){var t;return!!e&&(function(r){if(!r||typeof r!="object")return!1;var n=Object.getPrototypeOf(r);if(n===null)return!0;var o=Object.hasOwnProperty.call(n,"constructor")&&n.constructor;return o===Object||typeof o=="function"&&Function.toString.call(o)===XY}(e)||Array.isArray(e)||!!e[nE]||!!(!((t=e.constructor)===null||t===void 0)&&t[nE])||u2(e)||l2(e))}function Wu(e,t,r){r===void 0&&(r=!1),ns(e)===0?(r?Object.keys:m2)(e).forEach(function(n){r&&typeof n=="symbol"||t(n,e[n],e)}):e.forEach(function(n,o){return t(o,n,e)})}function ns(e){var t=e[mr];return t?t.i>3?t.i-4:t.i:Array.isArray(e)?1:u2(e)?2:l2(e)?3:0}function n2(e,t){return ns(e)===2?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function GY(e,t){return ns(e)===2?e.get(t):e[t]}function oE(e,t,r){var n=ns(e);n===2?e.set(t,r):n===3?e.add(r):e[t]=r}function jY(e,t){return e===t?e!==0||1/e==1/t:e!=e&&t!=t}function u2(e){return KY&&e instanceof Map}function l2(e){return qY&&e instanceof Set}function Si(e){return e.o||e.t}function c2(e){if(Array.isArray(e))return Array.prototype.slice.call(e);var t=YY(e);delete t[mr];for(var r=m2(t),n=0;n<r.length;n++){var o=r[n],a=t[o];a.writable===!1&&(a.writable=!0,a.configurable=!0),(a.get||a.set)&&(t[o]={configurable:!0,writable:!0,enumerable:a.enumerable,value:e[o]})}return Object.create(Object.getPrototypeOf(e),t)}function f2(e,t){return t===void 0&&(t=!1),p2(e)||Mo(e)||!Di(e)||(ns(e)>1&&(e.set=e.add=e.clear=e.delete=_Y),Object.freeze(e),t&&Wu(e,function(r,n){return f2(n,!0)},!0)),e}function _Y(){zr(2)}function p2(e){return e==null||typeof e!="object"||Object.isFrozen(e)}function on(e){var t=JY[e];return t||zr(18,e),t}function YD(){return Uu}function Qh(e,t){t&&(on("Patches"),e.u=[],e.s=[],e.v=t)}function Yp(e){o2(e),e.p.forEach(WY),e.p=null}function o2(e){e===Uu&&(Uu=e.l)}function JD(e){return Uu={p:[],l:Uu,h:e,m:!0,_:0}}function WY(e){var t=e[mr];t.i===0||t.i===1?t.j():t.g=!0}function e2(e,t){t._=t.p.length;var r=t.p[0],n=e!==void 0&&e!==r;return t.h.O||on("ES5").S(t,e,n),n?(r[mr].P&&(Yp(t),zr(4)),Di(e)&&(e=Jp(t,e),t.l||Zp(t,e)),t.u&&on("Patches").M(r[mr].t,e,t.u,t.s)):e=Jp(t,r,[]),Yp(t),t.u&&t.v(t.u,t.s),e!==iE?e:void 0}function Jp(e,t,r){if(p2(t))return t;var n=t[mr];if(!n)return Wu(t,function(u,l){return ZD(e,n,t,u,l,r)},!0),t;if(n.A!==e)return t;if(!n.P)return Zp(e,n.t,!0),n.t;if(!n.I){n.I=!0,n.A._--;var o=n.i===4||n.i===5?n.o=c2(n.k):n.o,a=o,s=!1;n.i===3&&(a=new Set(o),o.clear(),s=!0),Wu(a,function(u,l){return ZD(e,n,o,u,l,r,s)}),Zp(e,o,!1),r&&e.u&&on("Patches").N(n,r,e.u,e.s)}return n.o}function ZD(e,t,r,n,o,a,s){if(Mo(o)){var u=Jp(e,o,a&&t&&t.i!==3&&!n2(t.R,n)?a.concat(n):void 0);if(oE(r,n,u),!Mo(u))return;e.m=!1}else s&&r.add(o);if(Di(o)&&!p2(o)){if(!e.h.D&&e._<1)return;Jp(e,o),t&&t.A.l||Zp(e,o)}}function Zp(e,t,r){r===void 0&&(r=!1),!e.l&&e.h.D&&e.m&&f2(t,r)}function t2(e,t){var r=e[mr];return(r?Si(r):e)[t]}function QD(e,t){if(t in e)for(var r=Object.getPrototypeOf(e);r;){var n=Object.getOwnPropertyDescriptor(r,t);if(n)return n;r=Object.getPrototypeOf(r)}}function i2(e){e.P||(e.P=!0,e.l&&i2(e.l))}function r2(e){e.o||(e.o=c2(e.t))}function a2(e,t,r){var n=u2(t)?on("MapSet").F(t,r):l2(t)?on("MapSet").T(t,r):e.O?function(o,a){var s=Array.isArray(o),u={i:s?1:0,A:a?a.A:YD(),P:!1,I:!1,R:{},l:a,t:o,k:null,o:null,j:null,C:!1},l=u,c=s2;s&&(l=[u],c=_u);var p=Proxy.revocable(l,c),d=p.revoke,h=p.proxy;return u.k=h,u.j=d,h}(t,r):on("ES5").J(t,r);return(r?r.A:YD()).p.push(n),n}function UY(e){return Mo(e)||zr(22,e),function t(r){if(!Di(r))return r;var n,o=r[mr],a=ns(r);if(o){if(!o.P&&(o.i<4||!on("ES5").K(o)))return o.t;o.I=!0,n=eE(r,a),o.I=!1}else n=eE(r,a);return Wu(n,function(s,u){o&&GY(o.t,s)===u||oE(n,s,t(u))}),a===3?new Set(n):n}(e)}function eE(e,t){switch(t){case 2:return new Map(e);case 3:return Array.from(e)}return c2(e)}var tE,Uu,d2=typeof Symbol<"u"&&typeof Symbol("x")=="symbol",KY=typeof Map<"u",qY=typeof Set<"u",rE=typeof Proxy<"u"&&Proxy.revocable!==void 0&&typeof Reflect<"u",iE=d2?Symbol.for("immer-nothing"):((tE={})["immer-nothing"]=!0,tE),nE=d2?Symbol.for("immer-draftable"):"__$immer_draftable",mr=d2?Symbol.for("immer-state"):"__$immer_state";var XY=""+Object.prototype.constructor,m2=typeof Reflect<"u"&&Reflect.ownKeys?Reflect.ownKeys:Object.getOwnPropertySymbols!==void 0?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:Object.getOwnPropertyNames,YY=Object.getOwnPropertyDescriptors||function(e){var t={};return m2(e).forEach(function(r){t[r]=Object.getOwnPropertyDescriptor(e,r)}),t},JY={},s2={get:function(e,t){if(t===mr)return e;var r=Si(e);if(!n2(r,t))return function(o,a,s){var u,l=QD(a,s);return l?"value"in l?l.value:(u=l.get)===null||u===void 0?void 0:u.call(o.k):void 0}(e,r,t);var n=r[t];return e.I||!Di(n)?n:n===t2(e.t,t)?(r2(e),e.o[t]=a2(e.A.h,n,e)):n},has:function(e,t){return t in Si(e)},ownKeys:function(e){return Reflect.ownKeys(Si(e))},set:function(e,t,r){var n=QD(Si(e),t);if(n?.set)return n.set.call(e.k,r),!0;if(!e.P){var o=t2(Si(e),t),a=o?.[mr];if(a&&a.t===r)return e.o[t]=r,e.R[t]=!1,!0;if(jY(r,o)&&(r!==void 0||n2(e.t,t)))return!0;r2(e),i2(e)}return e.o[t]===r&&(r!==void 0||t in e.o)||Number.isNaN(r)&&Number.isNaN(e.o[t])||(e.o[t]=r,e.R[t]=!0),!0},deleteProperty:function(e,t){return t2(e.t,t)!==void 0||t in e.t?(e.R[t]=!1,r2(e),i2(e)):delete e.R[t],e.o&&delete e.o[t],!0},getOwnPropertyDescriptor:function(e,t){var r=Si(e),n=Reflect.getOwnPropertyDescriptor(r,t);return n&&{writable:!0,configurable:e.i!==1||t!=="length",enumerable:n.enumerable,value:r[t]}},defineProperty:function(){zr(11)},getPrototypeOf:function(e){return Object.getPrototypeOf(e.t)},setPrototypeOf:function(){zr(12)}},_u={};Wu(s2,function(e,t){_u[e]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}}),_u.deleteProperty=function(e,t){return _u.set.call(this,e,t,void 0)},_u.set=function(e,t,r){return s2.set.call(this,e[0],t,r,e[0])};var ZY=function(){function e(r){var n=this;this.O=rE,this.D=!0,this.produce=function(o,a,s){if(typeof o=="function"&&typeof a!="function"){var u=a;a=o;var l=n;return function(m){var b=this;m===void 0&&(m=u);for(var y=arguments.length,x=Array(y>1?y-1:0),w=1;w<y;w++)x[w-1]=arguments[w];return l.produce(m,function(S){var E;return(E=a).call.apply(E,[b,S].concat(x))})}}var c;if(typeof a!="function"&&zr(6),s!==void 0&&typeof s!="function"&&zr(7),Di(o)){var p=JD(n),d=a2(n,o,void 0),h=!0;try{c=a(d),h=!1}finally{h?Yp(p):o2(p)}return typeof Promise<"u"&&c instanceof Promise?c.then(function(m){return Qh(p,s),e2(m,p)},function(m){throw Yp(p),m}):(Qh(p,s),e2(c,p))}if(!o||typeof o!="object"){if((c=a(o))===void 0&&(c=o),c===iE&&(c=void 0),n.D&&f2(c,!0),s){var g=[],v=[];on("Patches").M(o,c,g,v),s(g,v)}return c}zr(21,o)},this.produceWithPatches=function(o,a){if(typeof o=="function")return function(c){for(var p=arguments.length,d=Array(p>1?p-1:0),h=1;h<p;h++)d[h-1]=arguments[h];return n.produceWithPatches(c,function(g){return o.apply(void 0,[g].concat(d))})};var s,u,l=n.produce(o,a,function(c,p){s=c,u=p});return typeof Promise<"u"&&l instanceof Promise?l.then(function(c){return[c,s,u]}):[l,s,u]},typeof r?.useProxies=="boolean"&&this.setUseProxies(r.useProxies),typeof r?.autoFreeze=="boolean"&&this.setAutoFreeze(r.autoFreeze)}var t=e.prototype;return t.createDraft=function(r){Di(r)||zr(8),Mo(r)&&(r=UY(r));var n=JD(this),o=a2(this,r,void 0);return o[mr].C=!0,o2(n),o},t.finishDraft=function(r,n){var o=r&&r[mr],a=o.A;return Qh(a,n),e2(void 0,a)},t.setAutoFreeze=function(r){this.D=r},t.setUseProxies=function(r){r&&!rE&&zr(20),this.O=r},t.applyPatches=function(r,n){var o;for(o=n.length-1;o>=0;o--){var a=n[o];if(a.path.length===0&&a.op==="replace"){r=a.value;break}}o>-1&&(n=n.slice(o+1));var s=on("Patches").$;return Mo(r)?s(r,n):this.produce(r,function(u){return s(u,n)})},e}(),hr=new ZY,Qp=hr.produce,tZe=hr.produceWithPatches.bind(hr),rZe=hr.setAutoFreeze.bind(hr),nZe=hr.setUseProxies.bind(hr),oZe=hr.applyPatches.bind(hr),h2=hr.createDraft.bind(hr),g2=hr.finishDraft.bind(hr);var QY={transform(e,t){var{current:r,affinity:n}=e;if(r!=null){var o=T.transform(r,t,{affinity:n});e.current=o,o==null&&e.unref()}}},eJ={transform(e,t){var{current:r,affinity:n}=e;if(r!=null){var o=ge.transform(r,t,{affinity:n});e.current=o,o==null&&e.unref()}}},tJ={transform(e,t){var{current:r,affinity:n}=e;if(r!=null){var o=O.transform(r,t,{affinity:n});e.current=o,o==null&&e.unref()}}},td=new WeakMap,rd=new WeakMap,qu=new WeakMap,VE=new WeakMap,aE=new WeakMap,sE=new WeakMap,uE=new WeakMap,T={ancestors(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{reverse:r=!1}=t,n=T.levels(e,t);return r?n=n.slice(1):n=n.slice(0,-1),n},common(e,t){for(var r=[],n=0;n<e.length&&n<t.length;n++){var o=e[n],a=t[n];if(o!==a)break;r.push(o)}return r},compare(e,t){for(var r=Math.min(e.length,t.length),n=0;n<r;n++){if(e[n]<t[n])return-1;if(e[n]>t[n])return 1}return 0},endsAfter(e,t){var r=e.length-1,n=e.slice(0,r),o=t.slice(0,r),a=e[r],s=t[r];return T.equals(n,o)&&a>s},endsAt(e,t){var r=e.length,n=e.slice(0,r),o=t.slice(0,r);return T.equals(n,o)},endsBefore(e,t){var r=e.length-1,n=e.slice(0,r),o=t.slice(0,r),a=e[r],s=t[r];return T.equals(n,o)&&a<s},equals(e,t){return e.length===t.length&&e.every((r,n)=>r===t[n])},hasPrevious(e){return e[e.length-1]>0},isAfter(e,t){return T.compare(e,t)===1},isAncestor(e,t){return e.length<t.length&&T.compare(e,t)===0},isBefore(e,t){return T.compare(e,t)===-1},isChild(e,t){return e.length===t.length+1&&T.compare(e,t)===0},isCommon(e,t){return e.length<=t.length&&T.compare(e,t)===0},isDescendant(e,t){return e.length>t.length&&T.compare(e,t)===0},isParent(e,t){return e.length+1===t.length&&T.compare(e,t)===0},isPath(e){return Array.isArray(e)&&(e.length===0||typeof e[0]=="number")},isSibling(e,t){if(e.length!==t.length)return!1;var r=e.slice(0,-1),n=t.slice(0,-1),o=e[e.length-1],a=t[t.length-1];return o!==a&&T.equals(r,n)},levels(e){for(var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{reverse:r=!1}=t,n=[],o=0;o<=e.length;o++)n.push(e.slice(0,o));return r&&n.reverse(),n},next(e){if(e.length===0)throw new Error("Cannot get the next path of a root path [".concat(e,"], because it has no next index."));var t=e[e.length-1];return e.slice(0,-1).concat(t+1)},operationCanTransformPath(e){switch(e.type){case"insert_node":case"remove_node":case"merge_node":case"split_node":case"move_node":return!0;default:return!1}},parent(e){if(e.length===0)throw new Error("Cannot get the parent path of the root path [".concat(e,"]."));return e.slice(0,-1)},previous(e){if(e.length===0)throw new Error("Cannot get the previous path of a root path [".concat(e,"], because it has no previous index."));var t=e[e.length-1];if(t<=0)throw new Error("Cannot get the previous path of a first child path [".concat(e,"] because it would result in a negative index."));return e.slice(0,-1).concat(t-1)},relative(e,t){if(!T.isAncestor(t,e)&&!T.equals(e,t))throw new Error("Cannot get the relative path of [".concat(e,"] inside ancestor [").concat(t,"], because it is not above or equal to the path."));return e.slice(t.length)},transform(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};if(!e)return null;var n=[...e],{affinity:o="forward"}=r;if(e.length===0)return n;switch(t.type){case"insert_node":{var{path:a}=t;(T.equals(a,n)||T.endsBefore(a,n)||T.isAncestor(a,n))&&(n[a.length-1]+=1);break}case"remove_node":{var{path:s}=t;if(T.equals(s,n)||T.isAncestor(s,n))return null;T.endsBefore(s,n)&&(n[s.length-1]-=1);break}case"merge_node":{var{path:u,position:l}=t;T.equals(u,n)||T.endsBefore(u,n)?n[u.length-1]-=1:T.isAncestor(u,n)&&(n[u.length-1]-=1,n[u.length]+=l);break}case"split_node":{var{path:c,position:p}=t;if(T.equals(c,n)){if(o==="forward")n[n.length-1]+=1;else if(o!=="backward")return null}else T.endsBefore(c,n)?n[c.length-1]+=1:T.isAncestor(c,n)&&e[c.length]>=p&&(n[c.length-1]+=1,n[c.length]-=p);break}case"move_node":{var{path:d,newPath:h}=t;if(T.equals(d,h))return n;if(T.isAncestor(d,n)||T.equals(d,n)){var g=h.slice();return T.endsBefore(d,h)&&d.length<h.length&&(g[d.length-1]-=1),g.concat(n.slice(d.length))}else T.isSibling(d,h)&&(T.isAncestor(h,n)||T.equals(h,n))?T.endsBefore(d,n)?n[d.length-1]-=1:n[d.length-1]+=1:T.endsBefore(h,n)||T.equals(h,n)||T.isAncestor(h,n)?(T.endsBefore(d,n)&&(n[d.length-1]-=1),n[h.length-1]+=1):T.endsBefore(d,n)&&(T.equals(h,n)&&(n[h.length-1]+=1),n[d.length-1]-=1);break}}return n}};function Vt(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function lE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function Ku(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?lE(Object(r),!0).forEach(function(n){Vt(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):lE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var rJ=(e,t,r)=>{switch(r.type){case"insert_node":{var{path:n,node:o}=r,a=W.parent(e,n),s=n[n.length-1];if(s>a.children.length)throw new Error('Cannot apply an "insert_node" operation at path ['.concat(n,"] because the destination is past the end of the node."));if(a.children.splice(s,0,o),t)for(var[u,l]of O.points(t))t[l]=ge.transform(u,r);break}case"insert_text":{var{path:c,offset:p,text:d}=r;if(d.length===0)break;var h=W.leaf(e,c),g=h.text.slice(0,p),v=h.text.slice(p);if(h.text=g+d+v,t)for(var[m,b]of O.points(t))t[b]=ge.transform(m,r);break}case"merge_node":{var{path:y}=r,x=W.get(e,y),w=T.previous(y),S=W.get(e,w),E=W.parent(e,y),D=y[y.length-1];if(J.isText(x)&&J.isText(S))S.text+=x.text;else if(!J.isText(x)&&!J.isText(S))S.children.push(...x.children);else throw new Error('Cannot apply a "merge_node" operation at path ['.concat(y,"] to nodes of different interfaces: ").concat(it.stringify(x)," ").concat(it.stringify(S)));if(E.children.splice(D,1),t)for(var[P,R]of O.points(t))t[R]=ge.transform(P,r);break}case"move_node":{var{path:F,newPath:M}=r;if(T.isAncestor(F,M))throw new Error("Cannot move a path [".concat(F,"] to new path [").concat(M,"] because the destination is inside itself."));var G=W.get(e,F),N=W.parent(e,F),L=F[F.length-1];N.children.splice(L,1);var I=T.transform(F,r),V=W.get(e,T.parent(I)),Y=I[I.length-1];if(V.children.splice(Y,0,G),t)for(var[Q,re]of O.points(t))t[re]=ge.transform(Q,r);break}case"remove_node":{var{path:H}=r,le=H[H.length-1],ve=W.parent(e,H);if(ve.children.splice(le,1),t)for(var[me,Ge]of O.points(t)){var A=ge.transform(me,r);if(t!=null&&A!=null)t[Ge]=A;else{var _=void 0,z=void 0;for(var[j,ue]of W.texts(e))if(T.compare(ue,H)===-1)_=[j,ue];else{z=[j,ue];break}var oe=!1;_&&z&&(T.equals(z[1],H)?oe=!T.hasPrevious(z[1]):oe=T.common(_[1],H).length<T.common(z[1],H).length),_&&!oe?(me.path=_[1],me.offset=_[0].text.length):z?(me.path=z[1],me.offset=0):t=null}}break}case"remove_text":{var{path:he,offset:Ce,text:Se}=r;if(Se.length===0)break;var Ee=W.leaf(e,he),xe=Ee.text.slice(0,Ce),ht=Ee.text.slice(Ce+Se.length);if(Ee.text=xe+ht,t)for(var[gt,je]of O.points(t))t[je]=ge.transform(gt,r);break}case"set_node":{var{path:or,properties:Ht,newProperties:St}=r;if(or.length===0)throw new Error("Cannot set properties on the root node!");var ir=W.get(e,or);for(var B in St){if(B==="children"||B==="text")throw new Error('Cannot set the "'.concat(B,'" property of nodes!'));var X=St[B];X==null?delete ir[B]:ir[B]=X}for(var te in Ht)St.hasOwnProperty(te)||delete ir[te];break}case"set_selection":{var{newProperties:q}=r;if(q==null)t=q;else{if(t==null){if(!O.isRange(q))throw new Error('Cannot apply an incomplete "set_selection" operation properties '.concat(it.stringify(q)," when there is no current selection."));t=Ku({},q)}for(var se in q){var we=q[se];if(we==null){if(se==="anchor"||se==="focus")throw new Error('Cannot remove the "'.concat(se,'" selection property'));delete t[se]}else t[se]=we}}break}case"split_node":{var{path:Pe,position:vt,properties:eo}=r;if(Pe.length===0)throw new Error('Cannot apply a "split_node" operation at path ['.concat(Pe,"] because the root node cannot be split."));var Ir=W.get(e,Pe),N1=W.parent(e,Pe),W5=Pe[Pe.length-1],Yi;if(J.isText(Ir)){var V1=Ir.text.slice(0,vt),kO=Ir.text.slice(vt);Ir.text=V1,Yi=Ku(Ku({},eo),{},{text:kO})}else{var NO=Ir.children.slice(0,vt),VO=Ir.children.slice(vt);Ir.children=NO,Yi=Ku(Ku({},eo),{},{children:VO})}if(N1.children.splice(W5+1,0,Yi),t)for(var[LO,$O]of O.points(t))t[$O]=ge.transform(LO,r);break}}return t},nJ={transform(e,t){e.children=h2(e.children);var r=e.selection&&h2(e.selection);try{r=rJ(e,r,t)}finally{e.children=g2(e.children),r?e.selection=Mo(r)?g2(r):r:e.selection=null}}},oJ={insertNodes(e,t,r){e.insertNodes(t,r)},liftNodes(e,t){e.liftNodes(t)},mergeNodes(e,t){e.mergeNodes(t)},moveNodes(e,t){e.moveNodes(t)},removeNodes(e,t){e.removeNodes(t)},setNodes(e,t,r){e.setNodes(t,r)},splitNodes(e,t){e.splitNodes(t)},unsetNodes(e,t,r){e.unsetNodes(t,r)},unwrapNodes(e,t){e.unwrapNodes(t)},wrapNodes(e,t,r){e.wrapNodes(t,r)}},iJ={collapse(e,t){e.collapse(t)},deselect(e){e.deselect()},move(e,t){e.move(t)},select(e,t){e.select(t)},setPoint(e,t,r){e.setPoint(t,r)},setSelection(e,t){e.setSelection(t)}},LE=(e,t)=>{for(var r in e){var n=e[r],o=t[r];if(Xe(n)&&Xe(o)){if(!LE(n,o))return!1}else if(Array.isArray(n)&&Array.isArray(o)){if(n.length!==o.length)return!1;for(var a=0;a<n.length;a++)if(n[a]!==o[a])return!1}else if(n!==o)return!1}for(var s in t)if(e[s]===void 0&&t[s]!==void 0)return!1;return!0};function aJ(e,t){if(e==null)return{};var r={},n=Object.keys(e),o,a;for(a=0;a<n.length;a++)o=n[a],!(t.indexOf(o)>=0)&&(r[o]=e[o]);return r}function Hn(e,t){if(e==null)return{};var r=aJ(e,t),n,o;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(o=0;o<a.length;o++)n=a[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}var sJ=["anchor","focus"];function cE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function uJ(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?cE(Object(r),!0).forEach(function(n){Vt(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):cE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var O={edges(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{reverse:r=!1}=t,{anchor:n,focus:o}=e;return O.isBackward(e)===r?[n,o]:[o,n]},end(e){var[,t]=O.edges(e);return t},equals(e,t){return ge.equals(e.anchor,t.anchor)&&ge.equals(e.focus,t.focus)},includes(e,t){if(O.isRange(t)){if(O.includes(e,t.anchor)||O.includes(e,t.focus))return!0;var[r,n]=O.edges(e),[o,a]=O.edges(t);return ge.isBefore(r,o)&&ge.isAfter(n,a)}var[s,u]=O.edges(e),l=!1,c=!1;return ge.isPoint(t)?(l=ge.compare(t,s)>=0,c=ge.compare(t,u)<=0):(l=T.compare(t,s.path)>=0,c=T.compare(t,u.path)<=0),l&&c},intersection(e,t){var r=Hn(e,sJ),[n,o]=O.edges(e),[a,s]=O.edges(t),u=ge.isBefore(n,a)?a:n,l=ge.isBefore(o,s)?o:s;return ge.isBefore(l,u)?null:uJ({anchor:u,focus:l},r)},isBackward(e){var{anchor:t,focus:r}=e;return ge.isAfter(t,r)},isCollapsed(e){var{anchor:t,focus:r}=e;return ge.equals(t,r)},isExpanded(e){return!O.isCollapsed(e)},isForward(e){return!O.isBackward(e)},isRange(e){return Xe(e)&&ge.isPoint(e.anchor)&&ge.isPoint(e.focus)},*points(e){yield[e.anchor,"anchor"],yield[e.focus,"focus"]},start(e){var[t]=O.edges(e);return t},transform(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return Qp(e,n=>{if(n===null)return null;var{affinity:o="inward"}=r,a,s;if(o==="inward"){var u=O.isCollapsed(n);O.isForward(n)?(a="forward",s=u?a:"backward"):(a="backward",s=u?a:"forward")}else o==="outward"?O.isForward(n)?(a="backward",s="forward"):(a="forward",s="backward"):(a=o,s=o);var l=ge.transform(n.anchor,t,{affinity:a}),c=ge.transform(n.focus,t,{affinity:s});if(!l||!c)return null;n.anchor=l,n.focus=c})}},fE=e=>Xe(e)&&W.isNodeList(e.children)&&!C.isEditor(e),K={isAncestor(e){return Xe(e)&&W.isNodeList(e.children)},isElement:fE,isElementList(e){return Array.isArray(e)&&e.every(t=>K.isElement(t))},isElementProps(e){return e.children!==void 0},isElementType:function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"type";return fE(t)&&t[n]===r},matches(e,t){for(var r in t)if(r!=="children"&&e[r]!==t[r])return!1;return!0}},lJ=["children"],cJ=["text"],pE=new WeakMap,W={ancestor(e,t){var r=W.get(e,t);if(J.isText(r))throw new Error("Cannot get the ancestor node at path [".concat(t,"] because it refers to a text node instead: ").concat(it.stringify(r)));return r},*ancestors(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};for(var n of T.ancestors(t,r)){var o=W.ancestor(e,n),a=[o,n];yield a}},child(e,t){if(J.isText(e))throw new Error("Cannot get the child of a text node: ".concat(it.stringify(e)));var r=e.children[t];if(r==null)throw new Error("Cannot get child at index `".concat(t,"` in node: ").concat(it.stringify(e)));return r},*children(e,t){for(var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{reverse:n=!1}=r,o=W.ancestor(e,t),{children:a}=o,s=n?a.length-1:0;n?s>=0:s<a.length;){var u=W.child(o,s),l=t.concat(s);yield[u,l],s=n?s-1:s+1}},common(e,t,r){var n=T.common(t,r),o=W.get(e,n);return[o,n]},descendant(e,t){var r=W.get(e,t);if(C.isEditor(r))throw new Error("Cannot get the descendant node at path [".concat(t,"] because it refers to the root editor node instead: ").concat(it.stringify(r)));return r},*descendants(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};for(var[r,n]of W.nodes(e,t))n.length!==0&&(yield[r,n])},*elements(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};for(var[r,n]of W.nodes(e,t))K.isElement(r)&&(yield[r,n])},extractProps(e){if(K.isAncestor(e)){var t=Hn(e,lJ);return t}else{var t=Hn(e,cJ);return t}},first(e,t){for(var r=t.slice(),n=W.get(e,r);n&&!(J.isText(n)||n.children.length===0);)n=n.children[0],r.push(0);return[n,r]},fragment(e,t){if(J.isText(e))throw new Error("Cannot get a fragment starting from a root text node: ".concat(it.stringify(e)));var r=Qp({children:e.children},n=>{var[o,a]=O.edges(t),s=W.nodes(n,{reverse:!0,pass:h=>{var[,g]=h;return!O.includes(t,g)}});for(var[,u]of s){if(!O.includes(t,u)){var l=W.parent(n,u),c=u[u.length-1];l.children.splice(c,1)}if(T.equals(u,a.path)){var p=W.leaf(n,u);p.text=p.text.slice(0,a.offset)}if(T.equals(u,o.path)){var d=W.leaf(n,u);d.text=d.text.slice(o.offset)}}C.isEditor(n)&&(n.selection=null)});return r.children},get(e,t){for(var r=e,n=0;n<t.length;n++){var o=t[n];if(J.isText(r)||!r.children[o])throw new Error("Cannot find a descendant at path [".concat(t,"] in node: ").concat(it.stringify(e)));r=r.children[o]}return r},has(e,t){for(var r=e,n=0;n<t.length;n++){var o=t[n];if(J.isText(r)||!r.children[o])return!1;r=r.children[o]}return!0},isNode(e){return J.isText(e)||K.isElement(e)||C.isEditor(e)},isNodeList(e){if(!Array.isArray(e))return!1;var t=pE.get(e);if(t!==void 0)return t;var r=e.every(n=>W.isNode(n));return pE.set(e,r),r},last(e,t){for(var r=t.slice(),n=W.get(e,r);n&&!(J.isText(n)||n.children.length===0);){var o=n.children.length-1;n=n.children[o],r.push(o)}return[n,r]},leaf(e,t){var r=W.get(e,t);if(!J.isText(r))throw new Error("Cannot get the leaf node at path [".concat(t,"] because it refers to a non-leaf node: ").concat(it.stringify(r)));return r},*levels(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};for(var n of T.levels(t,r)){var o=W.get(e,n);yield[o,n]}},matches(e,t){return K.isElement(e)&&K.isElementProps(t)&&K.matches(e,t)||J.isText(e)&&J.isTextProps(t)&&J.matches(e,t)},*nodes(e){for(var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{pass:r,reverse:n=!1}=t,{from:o=[],to:a}=t,s=new Set,u=[],l=e;!(a&&(n?T.isBefore(u,a):T.isAfter(u,a)));){if(s.has(l)||(yield[l,u]),!s.has(l)&&!J.isText(l)&&l.children.length!==0&&(r==null||r([l,u])===!1)){s.add(l);var c=n?l.children.length-1:0;T.isAncestor(u,o)&&(c=o[u.length]),u=u.concat(c),l=W.get(e,u);continue}if(u.length===0)break;if(!n){var p=T.next(u);if(W.has(e,p)){u=p,l=W.get(e,u);continue}}if(n&&u[u.length-1]!==0){var d=T.previous(u);u=d,l=W.get(e,u);continue}u=T.parent(u),l=W.get(e,u),s.add(l)}},parent(e,t){var r=T.parent(t),n=W.get(e,r);if(J.isText(n))throw new Error("Cannot get the parent of path [".concat(t,"] because it does not exist in the root."));return n},string(e){return J.isText(e)?e.text:e.children.map(W.string).join("")},*texts(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};for(var[r,n]of W.nodes(e,t))J.isText(r)&&(yield[r,n])}};function dE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function ze(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?dE(Object(r),!0).forEach(function(n){Vt(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):dE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var zn={isNodeOperation(e){return zn.isOperation(e)&&e.type.endsWith("_node")},isOperation(e){if(!Xe(e))return!1;switch(e.type){case"insert_node":return T.isPath(e.path)&&W.isNode(e.node);case"insert_text":return typeof e.offset=="number"&&typeof e.text=="string"&&T.isPath(e.path);case"merge_node":return typeof e.position=="number"&&T.isPath(e.path)&&Xe(e.properties);case"move_node":return T.isPath(e.path)&&T.isPath(e.newPath);case"remove_node":return T.isPath(e.path)&&W.isNode(e.node);case"remove_text":return typeof e.offset=="number"&&typeof e.text=="string"&&T.isPath(e.path);case"set_node":return T.isPath(e.path)&&Xe(e.properties)&&Xe(e.newProperties);case"set_selection":return e.properties===null&&O.isRange(e.newProperties)||e.newProperties===null&&O.isRange(e.properties)||Xe(e.properties)&&Xe(e.newProperties);case"split_node":return T.isPath(e.path)&&typeof e.position=="number"&&Xe(e.properties);default:return!1}},isOperationList(e){return Array.isArray(e)&&e.every(t=>zn.isOperation(t))},isSelectionOperation(e){return zn.isOperation(e)&&e.type.endsWith("_selection")},isTextOperation(e){return zn.isOperation(e)&&e.type.endsWith("_text")},inverse(e){switch(e.type){case"insert_node":return ze(ze({},e),{},{type:"remove_node"});case"insert_text":return ze(ze({},e),{},{type:"remove_text"});case"merge_node":return ze(ze({},e),{},{type:"split_node",path:T.previous(e.path)});case"move_node":{var{newPath:t,path:r}=e;if(T.equals(t,r))return e;if(T.isSibling(r,t))return ze(ze({},e),{},{path:t,newPath:r});var n=T.transform(r,e),o=T.transform(T.next(r),e);return ze(ze({},e),{},{path:n,newPath:o})}case"remove_node":return ze(ze({},e),{},{type:"insert_node"});case"remove_text":return ze(ze({},e),{},{type:"insert_text"});case"set_node":{var{properties:a,newProperties:s}=e;return ze(ze({},e),{},{properties:s,newProperties:a})}case"set_selection":{var{properties:u,newProperties:l}=e;return u==null?ze(ze({},e),{},{properties:l,newProperties:null}):l==null?ze(ze({},e),{},{properties:null,newProperties:u}):ze(ze({},e),{},{properties:l,newProperties:u})}case"split_node":return ze(ze({},e),{},{type:"merge_node",path:T.next(e.path)})}}},mE=new WeakMap,fJ=e=>{var t=mE.get(e);if(t!==void 0)return t;if(!Xe(e))return!1;var r=typeof e.addMark=="function"&&typeof e.apply=="function"&&typeof e.deleteFragment=="function"&&typeof e.insertBreak=="function"&&typeof e.insertSoftBreak=="function"&&typeof e.insertFragment=="function"&&typeof e.insertNode=="function"&&typeof e.insertText=="function"&&typeof e.isElementReadOnly=="function"&&typeof e.isInline=="function"&&typeof e.isSelectable=="function"&&typeof e.isVoid=="function"&&typeof e.normalizeNode=="function"&&typeof e.onChange=="function"&&typeof e.removeMark=="function"&&typeof e.getDirtyPaths=="function"&&(e.marks===null||Xe(e.marks))&&(e.selection===null||O.isRange(e.selection))&&W.isNodeList(e.children)&&zn.isOperationList(e.operations);return mE.set(e,r),r},C={above(e,t){return e.above(t)},addMark(e,t,r){e.addMark(t,r)},after(e,t,r){return e.after(t,r)},before(e,t,r){return e.before(t,r)},deleteBackward(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{unit:r="character"}=t;e.deleteBackward(r)},deleteForward(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{unit:r="character"}=t;e.deleteForward(r)},deleteFragment(e,t){e.deleteFragment(t)},edges(e,t){return e.edges(t)},elementReadOnly(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return e.elementReadOnly(t)},end(e,t){return e.end(t)},first(e,t){return e.first(t)},fragment(e,t){return e.fragment(t)},hasBlocks(e,t){return e.hasBlocks(t)},hasInlines(e,t){return e.hasInlines(t)},hasPath(e,t){return e.hasPath(t)},hasTexts(e,t){return e.hasTexts(t)},insertBreak(e){e.insertBreak()},insertFragment(e,t,r){e.insertFragment(t,r)},insertNode(e,t){e.insertNode(t)},insertSoftBreak(e){e.insertSoftBreak()},insertText(e,t){e.insertText(t)},isBlock(e,t){return e.isBlock(t)},isEdge(e,t,r){return e.isEdge(t,r)},isEditor(e){return fJ(e)},isElementReadOnly(e,t){return e.isElementReadOnly(t)},isEmpty(e,t){return e.isEmpty(t)},isEnd(e,t,r){return e.isEnd(t,r)},isInline(e,t){return e.isInline(t)},isNormalizing(e){return e.isNormalizing()},isSelectable(e,t){return e.isSelectable(t)},isStart(e,t,r){return e.isStart(t,r)},isVoid(e,t){return e.isVoid(t)},last(e,t){return e.last(t)},leaf(e,t,r){return e.leaf(t,r)},levels(e,t){return e.levels(t)},marks(e){return e.getMarks()},next(e,t){return e.next(t)},node(e,t,r){return e.node(t,r)},nodes(e,t){return e.nodes(t)},normalize(e,t){e.normalize(t)},parent(e,t,r){return e.parent(t,r)},path(e,t,r){return e.path(t,r)},pathRef(e,t,r){return e.pathRef(t,r)},pathRefs(e){return e.pathRefs()},point(e,t,r){return e.point(t,r)},pointRef(e,t,r){return e.pointRef(t,r)},pointRefs(e){return e.pointRefs()},positions(e,t){return e.positions(t)},previous(e,t){return e.previous(t)},range(e,t,r){return e.range(t,r)},rangeRef(e,t,r){return e.rangeRef(t,r)},rangeRefs(e){return e.rangeRefs()},removeMark(e,t){e.removeMark(t)},setNormalizing(e,t){e.setNormalizing(t)},start(e,t){return e.start(t)},string(e,t,r){return e.string(t,r)},unhangRange(e,t,r){return e.unhangRange(t,r)},void(e,t){return e.void(t)},withoutNormalizing(e,t){e.withoutNormalizing(t)}};var pJ={isSpan(e){return Array.isArray(e)&&e.length===2&&e.every(T.isPath)}};function hE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function gE(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?hE(Object(r),!0).forEach(function(n){Vt(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):hE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var ge={compare(e,t){var r=T.compare(e.path,t.path);return r===0?e.offset<t.offset?-1:e.offset>t.offset?1:0:r},isAfter(e,t){return ge.compare(e,t)===1},isBefore(e,t){return ge.compare(e,t)===-1},equals(e,t){return e.offset===t.offset&&T.equals(e.path,t.path)},isPoint(e){return Xe(e)&&typeof e.offset=="number"&&T.isPath(e.path)},transform(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return Qp(e,n=>{if(n===null)return null;var{affinity:o="forward"}=r,{path:a,offset:s}=n;switch(t.type){case"insert_node":case"move_node":{n.path=T.transform(a,t,r);break}case"insert_text":{T.equals(t.path,a)&&(t.offset<s||t.offset===s&&o==="forward")&&(n.offset+=t.text.length);break}case"merge_node":{T.equals(t.path,a)&&(n.offset+=t.position),n.path=T.transform(a,t,r);break}case"remove_text":{T.equals(t.path,a)&&t.offset<=s&&(n.offset-=Math.min(s-t.offset,t.text.length));break}case"remove_node":{if(T.equals(t.path,a)||T.isAncestor(t.path,a))return null;n.path=T.transform(a,t,r);break}case"split_node":{if(T.equals(t.path,a)){if(t.position===s&&o==null)return null;(t.position<s||t.position===s&&o==="forward")&&(n.offset-=t.position,n.path=T.transform(a,t,gE(gE({},r),{},{affinity:"forward"})))}else n.path=T.transform(a,t,r);break}}})}},vE=void 0,it={setScrubber(e){vE=e},stringify(e){return JSON.stringify(e,vE)}},dJ=["text"],mJ=["anchor","focus"];function yE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function $n(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?yE(Object(r),!0).forEach(function(n){Vt(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):yE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var J={equals(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{loose:n=!1}=r;function o(a){var s=Hn(a,dJ);return s}return LE(n?o(e):e,n?o(t):t)},isText(e){return Xe(e)&&typeof e.text=="string"},isTextList(e){return Array.isArray(e)&&e.every(t=>J.isText(t))},isTextProps(e){return e.text!==void 0},matches(e,t){for(var r in t)if(r!=="text"&&(!e.hasOwnProperty(r)||e[r]!==t[r]))return!1;return!0},decorations(e,t){var r=[$n({},e)];for(var n of t){var o=Hn(n,mJ),[a,s]=O.edges(n),u=[],l=0,c=a.offset,p=s.offset;for(var d of r){var{length:h}=d.text,g=l;if(l+=h,c<=g&&l<=p){Object.assign(d,o),u.push(d);continue}if(c!==p&&(c===l||p===g)||c>l||p<g||p===g&&g!==0){u.push(d);continue}var v=d,m=void 0,b=void 0;if(p<l){var y=p-g;b=$n($n({},v),{},{text:v.text.slice(y)}),v=$n($n({},v),{},{text:v.text.slice(0,y)})}if(c>g){var x=c-g;m=$n($n({},v),{},{text:v.text.slice(0,x)}),v=$n($n({},v),{},{text:v.text.slice(x)})}Object.assign(v,o),m&&u.push(m),u.push(v),b&&u.push(b)}r=u}return r}},v2=e=>e.selection?e.selection:e.children.length>0?C.end(e,[]):[0],is=(e,t)=>{var[r]=C.node(e,t);return n=>n===r},y2=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,n=!r,o=r?CJ(t):t,a=ce.None,s=ce.None,u=0,l=null,c=null;for(var p of o){var d=p.codePointAt(0);if(!d)break;var h=OJ(p,d);if([a,s]=n?[s,h]:[h,a],os(a,ce.ZWJ)&&os(s,ce.ExtPict)&&(n?l=bE(t.substring(0,u)):l=bE(t.substring(0,t.length-u)),!l)||os(a,ce.RI)&&os(s,ce.RI)&&(c!==null?c=!c:n?c=!0:c=VJ(t.substring(0,t.length-u)),!c)||a!==ce.None&&s!==ce.None&&IJ(a,s))break;u+=p.length}return u||1},hJ=/\s/,gJ=/[\u0021-\u0023\u0025-\u002A\u002C-\u002F\u003A\u003B\u003F\u0040\u005B-\u005D\u005F\u007B\u007D\u00A1\u00A7\u00AB\u00B6\u00B7\u00BB\u00BF\u037E\u0387\u055A-\u055F\u0589\u058A\u05BE\u05C0\u05C3\u05C6\u05F3\u05F4\u0609\u060A\u060C\u060D\u061B\u061E\u061F\u066A-\u066D\u06D4\u0700-\u070D\u07F7-\u07F9\u0830-\u083E\u085E\u0964\u0965\u0970\u0AF0\u0DF4\u0E4F\u0E5A\u0E5B\u0F04-\u0F12\u0F14\u0F3A-\u0F3D\u0F85\u0FD0-\u0FD4\u0FD9\u0FDA\u104A-\u104F\u10FB\u1360-\u1368\u1400\u166D\u166E\u169B\u169C\u16EB-\u16ED\u1735\u1736\u17D4-\u17D6\u17D8-\u17DA\u1800-\u180A\u1944\u1945\u1A1E\u1A1F\u1AA0-\u1AA6\u1AA8-\u1AAD\u1B5A-\u1B60\u1BFC-\u1BFF\u1C3B-\u1C3F\u1C7E\u1C7F\u1CC0-\u1CC7\u1CD3\u2010-\u2027\u2030-\u2043\u2045-\u2051\u2053-\u205E\u207D\u207E\u208D\u208E\u2329\u232A\u2768-\u2775\u27C5\u27C6\u27E6-\u27EF\u2983-\u2998\u29D8-\u29DB\u29FC\u29FD\u2CF9-\u2CFC\u2CFE\u2CFF\u2D70\u2E00-\u2E2E\u2E30-\u2E3B\u3001-\u3003\u3008-\u3011\u3014-\u301F\u3030\u303D\u30A0\u30FB\uA4FE\uA4FF\uA60D-\uA60F\uA673\uA67E\uA6F2-\uA6F7\uA874-\uA877\uA8CE\uA8CF\uA8F8-\uA8FA\uA92E\uA92F\uA95F\uA9C1-\uA9CD\uA9DE\uA9DF\uAA5C-\uAA5F\uAADE\uAADF\uAAF0\uAAF1\uABEB\uFD3E\uFD3F\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE61\uFE63\uFE68\uFE6A\uFE6B\uFF01-\uFF03\uFF05-\uFF0A\uFF0C-\uFF0F\uFF1A\uFF1B\uFF1F\uFF20\uFF3B-\uFF3D\uFF3F\uFF5B\uFF5D\uFF5F-\uFF65]/,vJ=/['\u2018\u2019]/,yJ=function(t){for(var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,n=0,o=!1;t.length>0;){var a=y2(t,r),[s,u]=b2(t,a,r);if(bJ(s,u,r))o=!0,n+=a;else if(!o)n+=a;else break;t=u}return n},b2=(e,t,r)=>{if(r){var n=e.length-t;return[e.slice(n,e.length),e.slice(0,n)]}return[e.slice(0,t),e.slice(t)]},bJ=function e(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1;if(hJ.test(t))return!1;if(vJ.test(t)){var o=y2(r,n),[a,s]=b2(r,o,n);if(e(a,s,n))return!0}return!gJ.test(t)},CJ=function*(t){for(var r=t.length-1,n=0;n<t.length;n++){var o=t.charAt(r-n);if(wJ(o.charCodeAt(0))){var a=t.charAt(r-n-1);if(xJ(a.charCodeAt(0))){yield a+o,n++;continue}}yield o}},xJ=e=>e>=55296&&e<=56319,wJ=e=>e>=56320&&e<=57343,ce;(function(e){e[e.None=0]="None",e[e.Extend=1]="Extend",e[e.ZWJ=2]="ZWJ",e[e.RI=4]="RI",e[e.Prepend=8]="Prepend",e[e.SpacingMark=16]="SpacingMark",e[e.L=32]="L",e[e.V=64]="V",e[e.T=128]="T",e[e.LV=256]="LV",e[e.LVT=512]="LVT",e[e.ExtPict=1024]="ExtPict",e[e.Any=2048]="Any"})(ce||(ce={}));var SJ=/^(?:[\u0300-\u036F\u0483-\u0489\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u065F\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u08D3-\u08E1\u08E3-\u0902\u093A\u093C\u0941-\u0948\u094D\u0951-\u0957\u0962\u0963\u0981\u09BC\u09BE\u09C1-\u09C4\u09CD\u09D7\u09E2\u09E3\u09FE\u0A01\u0A02\u0A3C\u0A41\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81\u0A82\u0ABC\u0AC1-\u0AC5\u0AC7\u0AC8\u0ACD\u0AE2\u0AE3\u0AFA-\u0AFF\u0B01\u0B3C\u0B3E\u0B3F\u0B41-\u0B44\u0B4D\u0B55-\u0B57\u0B62\u0B63\u0B82\u0BBE\u0BC0\u0BCD\u0BD7\u0C00\u0C04\u0C3E-\u0C40\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C81\u0CBC\u0CBF\u0CC2\u0CC6\u0CCC\u0CCD\u0CD5\u0CD6\u0CE2\u0CE3\u0D00\u0D01\u0D3B\u0D3C\u0D3E\u0D41-\u0D44\u0D4D\u0D57\u0D62\u0D63\u0D81\u0DCA\u0DCF\u0DD2-\u0DD4\u0DD6\u0DDF\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EBC\u0EC8-\u0ECD\u0F18\u0F19\u0F35\u0F37\u0F39\u0F71-\u0F7E\u0F80-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102D-\u1030\u1032-\u1037\u1039\u103A\u103D\u103E\u1058\u1059\u105E-\u1060\u1071-\u1074\u1082\u1085\u1086\u108D\u109D\u135D-\u135F\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17B4\u17B5\u17B7-\u17BD\u17C6\u17C9-\u17D3\u17DD\u180B-\u180D\u1885\u1886\u18A9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193B\u1A17\u1A18\u1A1B\u1A56\u1A58-\u1A5E\u1A60\u1A62\u1A65-\u1A6C\u1A73-\u1A7C\u1A7F\u1AB0-\u1AC0\u1B00-\u1B03\u1B34-\u1B3A\u1B3C\u1B42\u1B6B-\u1B73\u1B80\u1B81\u1BA2-\u1BA5\u1BA8\u1BA9\u1BAB-\u1BAD\u1BE6\u1BE8\u1BE9\u1BED\u1BEF-\u1BF1\u1C2C-\u1C33\u1C36\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE0\u1CE2-\u1CE8\u1CED\u1CF4\u1CF8\u1CF9\u1DC0-\u1DF9\u1DFB-\u1DFF\u200C\u20D0-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302F\u3099\u309A\uA66F-\uA672\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA825\uA826\uA82C\uA8C4\uA8C5\uA8E0-\uA8F1\uA8FF\uA926-\uA92D\uA947-\uA951\uA980-\uA982\uA9B3\uA9B6-\uA9B9\uA9BC\uA9BD\uA9E5\uAA29-\uAA2E\uAA31\uAA32\uAA35\uAA36\uAA43\uAA4C\uAA7C\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEC\uAAED\uAAF6\uABE5\uABE8\uABED\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F\uFF9E\uFF9F]|\uD800[\uDDFD\uDEE0\uDF76-\uDF7A]|\uD802[\uDE01-\uDE03\uDE05\uDE06\uDE0C-\uDE0F\uDE38-\uDE3A\uDE3F\uDEE5\uDEE6]|\uD803[\uDD24-\uDD27\uDEAB\uDEAC\uDF46-\uDF50]|\uD804[\uDC01\uDC38-\uDC46\uDC7F-\uDC81\uDCB3-\uDCB6\uDCB9\uDCBA\uDD00-\uDD02\uDD27-\uDD2B\uDD2D-\uDD34\uDD73\uDD80\uDD81\uDDB6-\uDDBE\uDDC9-\uDDCC\uDDCF\uDE2F-\uDE31\uDE34\uDE36\uDE37\uDE3E\uDEDF\uDEE3-\uDEEA\uDF00\uDF01\uDF3B\uDF3C\uDF3E\uDF40\uDF57\uDF66-\uDF6C\uDF70-\uDF74]|\uD805[\uDC38-\uDC3F\uDC42-\uDC44\uDC46\uDC5E\uDCB0\uDCB3-\uDCB8\uDCBA\uDCBD\uDCBF\uDCC0\uDCC2\uDCC3\uDDAF\uDDB2-\uDDB5\uDDBC\uDDBD\uDDBF\uDDC0\uDDDC\uDDDD\uDE33-\uDE3A\uDE3D\uDE3F\uDE40\uDEAB\uDEAD\uDEB0-\uDEB5\uDEB7\uDF1D-\uDF1F\uDF22-\uDF25\uDF27-\uDF2B]|\uD806[\uDC2F-\uDC37\uDC39\uDC3A\uDD30\uDD3B\uDD3C\uDD3E\uDD43\uDDD4-\uDDD7\uDDDA\uDDDB\uDDE0\uDE01-\uDE0A\uDE33-\uDE38\uDE3B-\uDE3E\uDE47\uDE51-\uDE56\uDE59-\uDE5B\uDE8A-\uDE96\uDE98\uDE99]|\uD807[\uDC30-\uDC36\uDC38-\uDC3D\uDC3F\uDC92-\uDCA7\uDCAA-\uDCB0\uDCB2\uDCB3\uDCB5\uDCB6\uDD31-\uDD36\uDD3A\uDD3C\uDD3D\uDD3F-\uDD45\uDD47\uDD90\uDD91\uDD95\uDD97\uDEF3\uDEF4]|\uD81A[\uDEF0-\uDEF4\uDF30-\uDF36]|\uD81B[\uDF4F\uDF8F-\uDF92\uDFE4]|\uD82F[\uDC9D\uDC9E]|\uD834[\uDD65\uDD67-\uDD69\uDD6E-\uDD72\uDD7B-\uDD82\uDD85-\uDD8B\uDDAA-\uDDAD\uDE42-\uDE44]|\uD836[\uDE00-\uDE36\uDE3B-\uDE6C\uDE75\uDE84\uDE9B-\uDE9F\uDEA1-\uDEAF]|\uD838[\uDC00-\uDC06\uDC08-\uDC18\uDC1B-\uDC21\uDC23\uDC24\uDC26-\uDC2A\uDD30-\uDD36\uDEEC-\uDEEF]|\uD83A[\uDCD0-\uDCD6\uDD44-\uDD4A]|\uD83C[\uDFFB-\uDFFF]|\uDB40[\uDC20-\uDC7F\uDD00-\uDDEF])$/,DJ=/^(?:[\u0600-\u0605\u06DD\u070F\u0890\u0891\u08E2\u0D4E]|\uD804[\uDCBD\uDCCD\uDDC2\uDDC3]|\uD806[\uDD3F\uDD41\uDE3A\uDE84-\uDE89]|\uD807\uDD46)$/,EJ=/^(?:[\u0903\u093B\u093E-\u0940\u0949-\u094C\u094E\u094F\u0982\u0983\u09BF\u09C0\u09C7\u09C8\u09CB\u09CC\u0A03\u0A3E-\u0A40\u0A83\u0ABE-\u0AC0\u0AC9\u0ACB\u0ACC\u0B02\u0B03\u0B40\u0B47\u0B48\u0B4B\u0B4C\u0BBF\u0BC1\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCC\u0C01-\u0C03\u0C41-\u0C44\u0C82\u0C83\u0CBE\u0CC0\u0CC1\u0CC3\u0CC4\u0CC7\u0CC8\u0CCA\u0CCB\u0D02\u0D03\u0D3F\u0D40\u0D46-\u0D48\u0D4A-\u0D4C\u0D82\u0D83\u0DD0\u0DD1\u0DD8-\u0DDE\u0DF2\u0DF3\u0E33\u0EB3\u0F3E\u0F3F\u0F7F\u1031\u103B\u103C\u1056\u1057\u1084\u1715\u1734\u17B6\u17BE-\u17C5\u17C7\u17C8\u1923-\u1926\u1929-\u192B\u1930\u1931\u1933-\u1938\u1A19\u1A1A\u1A55\u1A57\u1A6D-\u1A72\u1B04\u1B3B\u1B3D-\u1B41\u1B43\u1B44\u1B82\u1BA1\u1BA6\u1BA7\u1BAA\u1BE7\u1BEA-\u1BEC\u1BEE\u1BF2\u1BF3\u1C24-\u1C2B\u1C34\u1C35\u1CE1\u1CF7\uA823\uA824\uA827\uA880\uA881\uA8B4-\uA8C3\uA952\uA953\uA983\uA9B4\uA9B5\uA9BA\uA9BB\uA9BE-\uA9C0\uAA2F\uAA30\uAA33\uAA34\uAA4D\uAAEB\uAAEE\uAAEF\uAAF5\uABE3\uABE4\uABE6\uABE7\uABE9\uABEA\uABEC]|\uD804[\uDC00\uDC02\uDC82\uDCB0-\uDCB2\uDCB7\uDCB8\uDD2C\uDD45\uDD46\uDD82\uDDB3-\uDDB5\uDDBF\uDDC0\uDDCE\uDE2C-\uDE2E\uDE32\uDE33\uDE35\uDEE0-\uDEE2\uDF02\uDF03\uDF3F\uDF41-\uDF44\uDF47\uDF48\uDF4B-\uDF4D\uDF62\uDF63]|\uD805[\uDC35-\uDC37\uDC40\uDC41\uDC45\uDCB1\uDCB2\uDCB9\uDCBB\uDCBC\uDCBE\uDCC1\uDDB0\uDDB1\uDDB8-\uDDBB\uDDBE\uDE30-\uDE32\uDE3B\uDE3C\uDE3E\uDEAC\uDEAE\uDEAF\uDEB6\uDF26]|\uD806[\uDC2C-\uDC2E\uDC38\uDD31-\uDD35\uDD37\uDD38\uDD3D\uDD40\uDD42\uDDD1-\uDDD3\uDDDC-\uDDDF\uDDE4\uDE39\uDE57\uDE58\uDE97]|\uD807[\uDC2F\uDC3E\uDCA9\uDCB1\uDCB4\uDD8A-\uDD8E\uDD93\uDD94\uDD96\uDEF5\uDEF6]|\uD81B[\uDF51-\uDF87\uDFF0\uDFF1]|\uD834[\uDD66\uDD6D])$/,PJ=/^[\u1100-\u115F\uA960-\uA97C]$/,TJ=/^[\u1160-\u11A7\uD7B0-\uD7C6]$/,AJ=/^[\u11A8-\u11FF\uD7CB-\uD7FB]$/,RJ=/^[\uAC00\uAC1C\uAC38\uAC54\uAC70\uAC8C\uACA8\uACC4\uACE0\uACFC\uAD18\uAD34\uAD50\uAD6C\uAD88\uADA4\uADC0\uADDC\uADF8\uAE14\uAE30\uAE4C\uAE68\uAE84\uAEA0\uAEBC\uAED8\uAEF4\uAF10\uAF2C\uAF48\uAF64\uAF80\uAF9C\uAFB8\uAFD4\uAFF0\uB00C\uB028\uB044\uB060\uB07C\uB098\uB0B4\uB0D0\uB0EC\uB108\uB124\uB140\uB15C\uB178\uB194\uB1B0\uB1CC\uB1E8\uB204\uB220\uB23C\uB258\uB274\uB290\uB2AC\uB2C8\uB2E4\uB300\uB31C\uB338\uB354\uB370\uB38C\uB3A8\uB3C4\uB3E0\uB3FC\uB418\uB434\uB450\uB46C\uB488\uB4A4\uB4C0\uB4DC\uB4F8\uB514\uB530\uB54C\uB568\uB584\uB5A0\uB5BC\uB5D8\uB5F4\uB610\uB62C\uB648\uB664\uB680\uB69C\uB6B8\uB6D4\uB6F0\uB70C\uB728\uB744\uB760\uB77C\uB798\uB7B4\uB7D0\uB7EC\uB808\uB824\uB840\uB85C\uB878\uB894\uB8B0\uB8CC\uB8E8\uB904\uB920\uB93C\uB958\uB974\uB990\uB9AC\uB9C8\uB9E4\uBA00\uBA1C\uBA38\uBA54\uBA70\uBA8C\uBAA8\uBAC4\uBAE0\uBAFC\uBB18\uBB34\uBB50\uBB6C\uBB88\uBBA4\uBBC0\uBBDC\uBBF8\uBC14\uBC30\uBC4C\uBC68\uBC84\uBCA0\uBCBC\uBCD8\uBCF4\uBD10\uBD2C\uBD48\uBD64\uBD80\uBD9C\uBDB8\uBDD4\uBDF0\uBE0C\uBE28\uBE44\uBE60\uBE7C\uBE98\uBEB4\uBED0\uBEEC\uBF08\uBF24\uBF40\uBF5C\uBF78\uBF94\uBFB0\uBFCC\uBFE8\uC004\uC020\uC03C\uC058\uC074\uC090\uC0AC\uC0C8\uC0E4\uC100\uC11C\uC138\uC154\uC170\uC18C\uC1A8\uC1C4\uC1E0\uC1FC\uC218\uC234\uC250\uC26C\uC288\uC2A4\uC2C0\uC2DC\uC2F8\uC314\uC330\uC34C\uC368\uC384\uC3A0\uC3BC\uC3D8\uC3F4\uC410\uC42C\uC448\uC464\uC480\uC49C\uC4B8\uC4D4\uC4F0\uC50C\uC528\uC544\uC560\uC57C\uC598\uC5B4\uC5D0\uC5EC\uC608\uC624\uC640\uC65C\uC678\uC694\uC6B0\uC6CC\uC6E8\uC704\uC720\uC73C\uC758\uC774\uC790\uC7AC\uC7C8\uC7E4\uC800\uC81C\uC838\uC854\uC870\uC88C\uC8A8\uC8C4\uC8E0\uC8FC\uC918\uC934\uC950\uC96C\uC988\uC9A4\uC9C0\uC9DC\uC9F8\uCA14\uCA30\uCA4C\uCA68\uCA84\uCAA0\uCABC\uCAD8\uCAF4\uCB10\uCB2C\uCB48\uCB64\uCB80\uCB9C\uCBB8\uCBD4\uCBF0\uCC0C\uCC28\uCC44\uCC60\uCC7C\uCC98\uCCB4\uCCD0\uCCEC\uCD08\uCD24\uCD40\uCD5C\uCD78\uCD94\uCDB0\uCDCC\uCDE8\uCE04\uCE20\uCE3C\uCE58\uCE74\uCE90\uCEAC\uCEC8\uCEE4\uCF00\uCF1C\uCF38\uCF54\uCF70\uCF8C\uCFA8\uCFC4\uCFE0\uCFFC\uD018\uD034\uD050\uD06C\uD088\uD0A4\uD0C0\uD0DC\uD0F8\uD114\uD130\uD14C\uD168\uD184\uD1A0\uD1BC\uD1D8\uD1F4\uD210\uD22C\uD248\uD264\uD280\uD29C\uD2B8\uD2D4\uD2F0\uD30C\uD328\uD344\uD360\uD37C\uD398\uD3B4\uD3D0\uD3EC\uD408\uD424\uD440\uD45C\uD478\uD494\uD4B0\uD4CC\uD4E8\uD504\uD520\uD53C\uD558\uD574\uD590\uD5AC\uD5C8\uD5E4\uD600\uD61C\uD638\uD654\uD670\uD68C\uD6A8\uD6C4\uD6E0\uD6FC\uD718\uD734\uD750\uD76C\uD788]$/,FJ=/^[\uAC01-\uAC1B\uAC1D-\uAC37\uAC39-\uAC53\uAC55-\uAC6F\uAC71-\uAC8B\uAC8D-\uACA7\uACA9-\uACC3\uACC5-\uACDF\uACE1-\uACFB\uACFD-\uAD17\uAD19-\uAD33\uAD35-\uAD4F\uAD51-\uAD6B\uAD6D-\uAD87\uAD89-\uADA3\uADA5-\uADBF\uADC1-\uADDB\uADDD-\uADF7\uADF9-\uAE13\uAE15-\uAE2F\uAE31-\uAE4B\uAE4D-\uAE67\uAE69-\uAE83\uAE85-\uAE9F\uAEA1-\uAEBB\uAEBD-\uAED7\uAED9-\uAEF3\uAEF5-\uAF0F\uAF11-\uAF2B\uAF2D-\uAF47\uAF49-\uAF63\uAF65-\uAF7F\uAF81-\uAF9B\uAF9D-\uAFB7\uAFB9-\uAFD3\uAFD5-\uAFEF\uAFF1-\uB00B\uB00D-\uB027\uB029-\uB043\uB045-\uB05F\uB061-\uB07B\uB07D-\uB097\uB099-\uB0B3\uB0B5-\uB0CF\uB0D1-\uB0EB\uB0ED-\uB107\uB109-\uB123\uB125-\uB13F\uB141-\uB15B\uB15D-\uB177\uB179-\uB193\uB195-\uB1AF\uB1B1-\uB1CB\uB1CD-\uB1E7\uB1E9-\uB203\uB205-\uB21F\uB221-\uB23B\uB23D-\uB257\uB259-\uB273\uB275-\uB28F\uB291-\uB2AB\uB2AD-\uB2C7\uB2C9-\uB2E3\uB2E5-\uB2FF\uB301-\uB31B\uB31D-\uB337\uB339-\uB353\uB355-\uB36F\uB371-\uB38B\uB38D-\uB3A7\uB3A9-\uB3C3\uB3C5-\uB3DF\uB3E1-\uB3FB\uB3FD-\uB417\uB419-\uB433\uB435-\uB44F\uB451-\uB46B\uB46D-\uB487\uB489-\uB4A3\uB4A5-\uB4BF\uB4C1-\uB4DB\uB4DD-\uB4F7\uB4F9-\uB513\uB515-\uB52F\uB531-\uB54B\uB54D-\uB567\uB569-\uB583\uB585-\uB59F\uB5A1-\uB5BB\uB5BD-\uB5D7\uB5D9-\uB5F3\uB5F5-\uB60F\uB611-\uB62B\uB62D-\uB647\uB649-\uB663\uB665-\uB67F\uB681-\uB69B\uB69D-\uB6B7\uB6B9-\uB6D3\uB6D5-\uB6EF\uB6F1-\uB70B\uB70D-\uB727\uB729-\uB743\uB745-\uB75F\uB761-\uB77B\uB77D-\uB797\uB799-\uB7B3\uB7B5-\uB7CF\uB7D1-\uB7EB\uB7ED-\uB807\uB809-\uB823\uB825-\uB83F\uB841-\uB85B\uB85D-\uB877\uB879-\uB893\uB895-\uB8AF\uB8B1-\uB8CB\uB8CD-\uB8E7\uB8E9-\uB903\uB905-\uB91F\uB921-\uB93B\uB93D-\uB957\uB959-\uB973\uB975-\uB98F\uB991-\uB9AB\uB9AD-\uB9C7\uB9C9-\uB9E3\uB9E5-\uB9FF\uBA01-\uBA1B\uBA1D-\uBA37\uBA39-\uBA53\uBA55-\uBA6F\uBA71-\uBA8B\uBA8D-\uBAA7\uBAA9-\uBAC3\uBAC5-\uBADF\uBAE1-\uBAFB\uBAFD-\uBB17\uBB19-\uBB33\uBB35-\uBB4F\uBB51-\uBB6B\uBB6D-\uBB87\uBB89-\uBBA3\uBBA5-\uBBBF\uBBC1-\uBBDB\uBBDD-\uBBF7\uBBF9-\uBC13\uBC15-\uBC2F\uBC31-\uBC4B\uBC4D-\uBC67\uBC69-\uBC83\uBC85-\uBC9F\uBCA1-\uBCBB\uBCBD-\uBCD7\uBCD9-\uBCF3\uBCF5-\uBD0F\uBD11-\uBD2B\uBD2D-\uBD47\uBD49-\uBD63\uBD65-\uBD7F\uBD81-\uBD9B\uBD9D-\uBDB7\uBDB9-\uBDD3\uBDD5-\uBDEF\uBDF1-\uBE0B\uBE0D-\uBE27\uBE29-\uBE43\uBE45-\uBE5F\uBE61-\uBE7B\uBE7D-\uBE97\uBE99-\uBEB3\uBEB5-\uBECF\uBED1-\uBEEB\uBEED-\uBF07\uBF09-\uBF23\uBF25-\uBF3F\uBF41-\uBF5B\uBF5D-\uBF77\uBF79-\uBF93\uBF95-\uBFAF\uBFB1-\uBFCB\uBFCD-\uBFE7\uBFE9-\uC003\uC005-\uC01F\uC021-\uC03B\uC03D-\uC057\uC059-\uC073\uC075-\uC08F\uC091-\uC0AB\uC0AD-\uC0C7\uC0C9-\uC0E3\uC0E5-\uC0FF\uC101-\uC11B\uC11D-\uC137\uC139-\uC153\uC155-\uC16F\uC171-\uC18B\uC18D-\uC1A7\uC1A9-\uC1C3\uC1C5-\uC1DF\uC1E1-\uC1FB\uC1FD-\uC217\uC219-\uC233\uC235-\uC24F\uC251-\uC26B\uC26D-\uC287\uC289-\uC2A3\uC2A5-\uC2BF\uC2C1-\uC2DB\uC2DD-\uC2F7\uC2F9-\uC313\uC315-\uC32F\uC331-\uC34B\uC34D-\uC367\uC369-\uC383\uC385-\uC39F\uC3A1-\uC3BB\uC3BD-\uC3D7\uC3D9-\uC3F3\uC3F5-\uC40F\uC411-\uC42B\uC42D-\uC447\uC449-\uC463\uC465-\uC47F\uC481-\uC49B\uC49D-\uC4B7\uC4B9-\uC4D3\uC4D5-\uC4EF\uC4F1-\uC50B\uC50D-\uC527\uC529-\uC543\uC545-\uC55F\uC561-\uC57B\uC57D-\uC597\uC599-\uC5B3\uC5B5-\uC5CF\uC5D1-\uC5EB\uC5ED-\uC607\uC609-\uC623\uC625-\uC63F\uC641-\uC65B\uC65D-\uC677\uC679-\uC693\uC695-\uC6AF\uC6B1-\uC6CB\uC6CD-\uC6E7\uC6E9-\uC703\uC705-\uC71F\uC721-\uC73B\uC73D-\uC757\uC759-\uC773\uC775-\uC78F\uC791-\uC7AB\uC7AD-\uC7C7\uC7C9-\uC7E3\uC7E5-\uC7FF\uC801-\uC81B\uC81D-\uC837\uC839-\uC853\uC855-\uC86F\uC871-\uC88B\uC88D-\uC8A7\uC8A9-\uC8C3\uC8C5-\uC8DF\uC8E1-\uC8FB\uC8FD-\uC917\uC919-\uC933\uC935-\uC94F\uC951-\uC96B\uC96D-\uC987\uC989-\uC9A3\uC9A5-\uC9BF\uC9C1-\uC9DB\uC9DD-\uC9F7\uC9F9-\uCA13\uCA15-\uCA2F\uCA31-\uCA4B\uCA4D-\uCA67\uCA69-\uCA83\uCA85-\uCA9F\uCAA1-\uCABB\uCABD-\uCAD7\uCAD9-\uCAF3\uCAF5-\uCB0F\uCB11-\uCB2B\uCB2D-\uCB47\uCB49-\uCB63\uCB65-\uCB7F\uCB81-\uCB9B\uCB9D-\uCBB7\uCBB9-\uCBD3\uCBD5-\uCBEF\uCBF1-\uCC0B\uCC0D-\uCC27\uCC29-\uCC43\uCC45-\uCC5F\uCC61-\uCC7B\uCC7D-\uCC97\uCC99-\uCCB3\uCCB5-\uCCCF\uCCD1-\uCCEB\uCCED-\uCD07\uCD09-\uCD23\uCD25-\uCD3F\uCD41-\uCD5B\uCD5D-\uCD77\uCD79-\uCD93\uCD95-\uCDAF\uCDB1-\uCDCB\uCDCD-\uCDE7\uCDE9-\uCE03\uCE05-\uCE1F\uCE21-\uCE3B\uCE3D-\uCE57\uCE59-\uCE73\uCE75-\uCE8F\uCE91-\uCEAB\uCEAD-\uCEC7\uCEC9-\uCEE3\uCEE5-\uCEFF\uCF01-\uCF1B\uCF1D-\uCF37\uCF39-\uCF53\uCF55-\uCF6F\uCF71-\uCF8B\uCF8D-\uCFA7\uCFA9-\uCFC3\uCFC5-\uCFDF\uCFE1-\uCFFB\uCFFD-\uD017\uD019-\uD033\uD035-\uD04F\uD051-\uD06B\uD06D-\uD087\uD089-\uD0A3\uD0A5-\uD0BF\uD0C1-\uD0DB\uD0DD-\uD0F7\uD0F9-\uD113\uD115-\uD12F\uD131-\uD14B\uD14D-\uD167\uD169-\uD183\uD185-\uD19F\uD1A1-\uD1BB\uD1BD-\uD1D7\uD1D9-\uD1F3\uD1F5-\uD20F\uD211-\uD22B\uD22D-\uD247\uD249-\uD263\uD265-\uD27F\uD281-\uD29B\uD29D-\uD2B7\uD2B9-\uD2D3\uD2D5-\uD2EF\uD2F1-\uD30B\uD30D-\uD327\uD329-\uD343\uD345-\uD35F\uD361-\uD37B\uD37D-\uD397\uD399-\uD3B3\uD3B5-\uD3CF\uD3D1-\uD3EB\uD3ED-\uD407\uD409-\uD423\uD425-\uD43F\uD441-\uD45B\uD45D-\uD477\uD479-\uD493\uD495-\uD4AF\uD4B1-\uD4CB\uD4CD-\uD4E7\uD4E9-\uD503\uD505-\uD51F\uD521-\uD53B\uD53D-\uD557\uD559-\uD573\uD575-\uD58F\uD591-\uD5AB\uD5AD-\uD5C7\uD5C9-\uD5E3\uD5E5-\uD5FF\uD601-\uD61B\uD61D-\uD637\uD639-\uD653\uD655-\uD66F\uD671-\uD68B\uD68D-\uD6A7\uD6A9-\uD6C3\uD6C5-\uD6DF\uD6E1-\uD6FB\uD6FD-\uD717\uD719-\uD733\uD735-\uD74F\uD751-\uD76B\uD76D-\uD787\uD789-\uD7A3]$/,BJ=/^(?:[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u2388\u23CF\u23E9-\u23F3\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB-\u25FE\u2600-\u2605\u2607-\u2612\u2614-\u2685\u2690-\u2705\u2708-\u2712\u2714\u2716\u271D\u2721\u2728\u2733\u2734\u2744\u2747\u274C\u274E\u2753-\u2755\u2757\u2763-\u2767\u2795-\u2797\u27A1\u27B0\u27BF\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B50\u2B55\u3030\u303D\u3297\u3299]|\uD83C[\uDC00-\uDCFF\uDD0D-\uDD0F\uDD2F\uDD6C-\uDD71\uDD7E\uDD7F\uDD8E\uDD91-\uDD9A\uDDAD-\uDDE5\uDE01-\uDE0F\uDE1A\uDE2F\uDE32-\uDE3A\uDE3C-\uDE3F\uDE49-\uDFFA]|\uD83D[\uDC00-\uDD3D\uDD46-\uDE4F\uDE80-\uDEFF\uDF74-\uDF7F\uDFD5-\uDFFF]|\uD83E[\uDC0C-\uDC0F\uDC48-\uDC4F\uDC5A-\uDC5F\uDC88-\uDC8F\uDCAE-\uDCFF\uDD0C-\uDD3A\uDD3C-\uDD45\uDD47-\uDEFF]|\uD83F[\uDC00-\uDFFD])$/,OJ=(e,t)=>{var r=ce.Any;return e.search(SJ)!==-1&&(r|=ce.Extend),t===8205&&(r|=ce.ZWJ),t>=127462&&t<=127487&&(r|=ce.RI),e.search(DJ)!==-1&&(r|=ce.Prepend),e.search(EJ)!==-1&&(r|=ce.SpacingMark),e.search(PJ)!==-1&&(r|=ce.L),e.search(TJ)!==-1&&(r|=ce.V),e.search(AJ)!==-1&&(r|=ce.T),e.search(RJ)!==-1&&(r|=ce.LV),e.search(FJ)!==-1&&(r|=ce.LVT),e.search(BJ)!==-1&&(r|=ce.ExtPict),r};function os(e,t){return(e&t)!==0}var MJ=[[ce.L,ce.L|ce.V|ce.LV|ce.LVT],[ce.LV|ce.V,ce.V|ce.T],[ce.LVT|ce.T,ce.T],[ce.Any,ce.Extend|ce.ZWJ],[ce.Any,ce.SpacingMark],[ce.Prepend,ce.Any],[ce.ZWJ,ce.ExtPict],[ce.RI,ce.RI]];function IJ(e,t){return MJ.findIndex(r=>os(e,r[0])&&os(t,r[1]))===-1}var kJ=/(?:[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u2388\u23CF\u23E9-\u23F3\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB-\u25FE\u2600-\u2605\u2607-\u2612\u2614-\u2685\u2690-\u2705\u2708-\u2712\u2714\u2716\u271D\u2721\u2728\u2733\u2734\u2744\u2747\u274C\u274E\u2753-\u2755\u2757\u2763-\u2767\u2795-\u2797\u27A1\u27B0\u27BF\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B50\u2B55\u3030\u303D\u3297\u3299]|\uD83C[\uDC00-\uDCFF\uDD0D-\uDD0F\uDD2F\uDD6C-\uDD71\uDD7E\uDD7F\uDD8E\uDD91-\uDD9A\uDDAD-\uDDE5\uDE01-\uDE0F\uDE1A\uDE2F\uDE32-\uDE3A\uDE3C-\uDE3F\uDE49-\uDFFA]|\uD83D[\uDC00-\uDD3D\uDD46-\uDE4F\uDE80-\uDEFF\uDF74-\uDF7F\uDFD5-\uDFFF]|\uD83E[\uDC0C-\uDC0F\uDC48-\uDC4F\uDC5A-\uDC5F\uDC88-\uDC8F\uDCAE-\uDCFF\uDD0C-\uDD3A\uDD3C-\uDD45\uDD47-\uDEFF]|\uD83F[\uDC00-\uDFFD])(?:[\u0300-\u036F\u0483-\u0489\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u065F\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u08D3-\u08E1\u08E3-\u0902\u093A\u093C\u0941-\u0948\u094D\u0951-\u0957\u0962\u0963\u0981\u09BC\u09BE\u09C1-\u09C4\u09CD\u09D7\u09E2\u09E3\u09FE\u0A01\u0A02\u0A3C\u0A41\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81\u0A82\u0ABC\u0AC1-\u0AC5\u0AC7\u0AC8\u0ACD\u0AE2\u0AE3\u0AFA-\u0AFF\u0B01\u0B3C\u0B3E\u0B3F\u0B41-\u0B44\u0B4D\u0B55-\u0B57\u0B62\u0B63\u0B82\u0BBE\u0BC0\u0BCD\u0BD7\u0C00\u0C04\u0C3E-\u0C40\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C81\u0CBC\u0CBF\u0CC2\u0CC6\u0CCC\u0CCD\u0CD5\u0CD6\u0CE2\u0CE3\u0D00\u0D01\u0D3B\u0D3C\u0D3E\u0D41-\u0D44\u0D4D\u0D57\u0D62\u0D63\u0D81\u0DCA\u0DCF\u0DD2-\u0DD4\u0DD6\u0DDF\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EBC\u0EC8-\u0ECD\u0F18\u0F19\u0F35\u0F37\u0F39\u0F71-\u0F7E\u0F80-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102D-\u1030\u1032-\u1037\u1039\u103A\u103D\u103E\u1058\u1059\u105E-\u1060\u1071-\u1074\u1082\u1085\u1086\u108D\u109D\u135D-\u135F\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17B4\u17B5\u17B7-\u17BD\u17C6\u17C9-\u17D3\u17DD\u180B-\u180D\u1885\u1886\u18A9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193B\u1A17\u1A18\u1A1B\u1A56\u1A58-\u1A5E\u1A60\u1A62\u1A65-\u1A6C\u1A73-\u1A7C\u1A7F\u1AB0-\u1AC0\u1B00-\u1B03\u1B34-\u1B3A\u1B3C\u1B42\u1B6B-\u1B73\u1B80\u1B81\u1BA2-\u1BA5\u1BA8\u1BA9\u1BAB-\u1BAD\u1BE6\u1BE8\u1BE9\u1BED\u1BEF-\u1BF1\u1C2C-\u1C33\u1C36\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE0\u1CE2-\u1CE8\u1CED\u1CF4\u1CF8\u1CF9\u1DC0-\u1DF9\u1DFB-\u1DFF\u200C\u20D0-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302F\u3099\u309A\uA66F-\uA672\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA825\uA826\uA82C\uA8C4\uA8C5\uA8E0-\uA8F1\uA8FF\uA926-\uA92D\uA947-\uA951\uA980-\uA982\uA9B3\uA9B6-\uA9B9\uA9BC\uA9BD\uA9E5\uAA29-\uAA2E\uAA31\uAA32\uAA35\uAA36\uAA43\uAA4C\uAA7C\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEC\uAAED\uAAF6\uABE5\uABE8\uABED\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F\uFF9E\uFF9F]|\uD800[\uDDFD\uDEE0\uDF76-\uDF7A]|\uD802[\uDE01-\uDE03\uDE05\uDE06\uDE0C-\uDE0F\uDE38-\uDE3A\uDE3F\uDEE5\uDEE6]|\uD803[\uDD24-\uDD27\uDEAB\uDEAC\uDF46-\uDF50]|\uD804[\uDC01\uDC38-\uDC46\uDC7F-\uDC81\uDCB3-\uDCB6\uDCB9\uDCBA\uDD00-\uDD02\uDD27-\uDD2B\uDD2D-\uDD34\uDD73\uDD80\uDD81\uDDB6-\uDDBE\uDDC9-\uDDCC\uDDCF\uDE2F-\uDE31\uDE34\uDE36\uDE37\uDE3E\uDEDF\uDEE3-\uDEEA\uDF00\uDF01\uDF3B\uDF3C\uDF3E\uDF40\uDF57\uDF66-\uDF6C\uDF70-\uDF74]|\uD805[\uDC38-\uDC3F\uDC42-\uDC44\uDC46\uDC5E\uDCB0\uDCB3-\uDCB8\uDCBA\uDCBD\uDCBF\uDCC0\uDCC2\uDCC3\uDDAF\uDDB2-\uDDB5\uDDBC\uDDBD\uDDBF\uDDC0\uDDDC\uDDDD\uDE33-\uDE3A\uDE3D\uDE3F\uDE40\uDEAB\uDEAD\uDEB0-\uDEB5\uDEB7\uDF1D-\uDF1F\uDF22-\uDF25\uDF27-\uDF2B]|\uD806[\uDC2F-\uDC37\uDC39\uDC3A\uDD30\uDD3B\uDD3C\uDD3E\uDD43\uDDD4-\uDDD7\uDDDA\uDDDB\uDDE0\uDE01-\uDE0A\uDE33-\uDE38\uDE3B-\uDE3E\uDE47\uDE51-\uDE56\uDE59-\uDE5B\uDE8A-\uDE96\uDE98\uDE99]|\uD807[\uDC30-\uDC36\uDC38-\uDC3D\uDC3F\uDC92-\uDCA7\uDCAA-\uDCB0\uDCB2\uDCB3\uDCB5\uDCB6\uDD31-\uDD36\uDD3A\uDD3C\uDD3D\uDD3F-\uDD45\uDD47\uDD90\uDD91\uDD95\uDD97\uDEF3\uDEF4]|\uD81A[\uDEF0-\uDEF4\uDF30-\uDF36]|\uD81B[\uDF4F\uDF8F-\uDF92\uDFE4]|\uD82F[\uDC9D\uDC9E]|\uD834[\uDD65\uDD67-\uDD69\uDD6E-\uDD72\uDD7B-\uDD82\uDD85-\uDD8B\uDDAA-\uDDAD\uDE42-\uDE44]|\uD836[\uDE00-\uDE36\uDE3B-\uDE6C\uDE75\uDE84\uDE9B-\uDE9F\uDEA1-\uDEAF]|\uD838[\uDC00-\uDC06\uDC08-\uDC18\uDC1B-\uDC21\uDC23\uDC24\uDC26-\uDC2A\uDD30-\uDD36\uDEEC-\uDEEF]|\uD83A[\uDCD0-\uDCD6\uDD44-\uDD4A]|\uD83C[\uDFFB-\uDFFF]|\uDB40[\uDC20-\uDC7F\uDD00-\uDDEF])*\u200D$/,bE=e=>e.search(kJ)!==-1,NJ=/(?:\uD83C[\uDDE6-\uDDFF])+$/g,VJ=e=>{var t=e.match(NJ);if(t===null)return!1;var r=t[0].length/2;return r%2===1},LJ={delete(e,t){e.delete(t)},insertFragment(e,t,r){e.insertFragment(t,r)},insertText(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};C.withoutNormalizing(e,()=>{var{voids:n=!1}=r,{at:o=v2(e)}=r;if(T.isPath(o)&&(o=C.range(e,o)),O.isRange(o))if(O.isCollapsed(o))o=o.anchor;else{var a=O.end(o);if(!n&&C.void(e,{at:a}))return;var s=O.start(o),u=C.pointRef(e,s),l=C.pointRef(e,a);k.delete(e,{at:o,voids:n});var c=u.unref(),p=l.unref();o=c||p,k.setSelection(e,{anchor:o,focus:o})}if(!(!n&&C.void(e,{at:o})||C.elementReadOnly(e,{at:o}))){var{path:d,offset:h}=o;t.length>0&&e.apply({type:"insert_text",path:d,offset:h,text:t})}})}};function CE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function ed(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?CE(Object(r),!0).forEach(function(n){Vt(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):CE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var k=ed(ed(ed(ed({},nJ),oJ),iJ),LJ),$J=(e,t)=>{for(var r of C.pathRefs(e))QY.transform(r,t);for(var n of C.pointRefs(e))eJ.transform(n,t);for(var o of C.rangeRefs(e))tJ.transform(o,t);var a=td.get(e)||[],s=rd.get(e)||new Set,u,l,c=v=>{if(v){var m=v.join(",");l.has(m)||(l.add(m),u.push(v))}};if(T.operationCanTransformPath(t)){u=[],l=new Set;for(var p of a){var d=T.transform(p,t);c(d)}}else u=a,l=s;var h=e.getDirtyPaths(t);for(var g of h)c(g);td.set(e,u),rd.set(e,l),k.transform(e,t),e.operations.push(t),C.normalize(e,{operation:t}),t.type==="set_selection"&&(e.marks=null),qu.get(e)||(qu.set(e,!0),Promise.resolve().then(()=>{qu.set(e,!1),e.onChange({operation:t}),e.operations=[]}))},zJ=(e,t)=>{switch(t.type){case"insert_text":case"remove_text":case"set_node":{var{path:r}=t;return T.levels(r)}case"insert_node":{var{node:n,path:o}=t,a=T.levels(o),s=J.isText(n)?[]:Array.from(W.nodes(n),M=>{var[,G]=M;return o.concat(G)});return[...a,...s]}case"merge_node":{var{path:u}=t,l=T.ancestors(u),c=T.previous(u);return[...l,c]}case"move_node":{var{path:p,newPath:d}=t;if(T.equals(p,d))return[];var h=[],g=[];for(var v of T.ancestors(p)){var m=T.transform(v,t);h.push(m)}for(var b of T.ancestors(d)){var y=T.transform(b,t);g.push(y)}var x=g[g.length-1],w=d[d.length-1],S=x.concat(w);return[...h,...g,S]}case"remove_node":{var{path:E}=t,D=T.ancestors(E);return[...D]}case"split_node":{var{path:P}=t,R=T.levels(P),F=T.next(P);return[...R,F]}default:return[]}},HJ=e=>{var{selection:t}=e;return t?W.fragment(e,t):[]},GJ=(e,t)=>{var[r,n]=t;if(!J.isText(r)){if(K.isElement(r)&&r.children.length===0){var o={text:""};k.insertNodes(e,o,{at:n.concat(0),voids:!0});return}for(var a=C.isEditor(r)?!1:K.isElement(r)&&(e.isInline(r)||r.children.length===0||J.isText(r.children[0])||e.isInline(r.children[0])),s=0,u=0;u<r.children.length;u++,s++){var l=W.get(e,n);if(!J.isText(l)){var c=l.children[s],p=l.children[s-1],d=u===r.children.length-1,h=J.isText(c)||K.isElement(c)&&e.isInline(c);if(h!==a)k.removeNodes(e,{at:n.concat(s),voids:!0}),s--;else if(K.isElement(c)){if(e.isInline(c)){if(p==null||!J.isText(p)){var g={text:""};k.insertNodes(e,g,{at:n.concat(s),voids:!0}),s++}else if(d){var v={text:""};k.insertNodes(e,v,{at:n.concat(s+1),voids:!0}),s++}}}else p!=null&&J.isText(p)&&(J.equals(c,p,{loose:!0})?(k.mergeNodes(e,{at:n.concat(s),voids:!0}),s--):p.text===""?(k.removeNodes(e,{at:n.concat(s-1),voids:!0}),s--):c.text===""&&(k.removeNodes(e,{at:n.concat(s),voids:!0}),s--))}}}},jJ=(e,t)=>{var{iteration:r,initialDirtyPathsLength:n}=t,o=n*42;if(r>o)throw new Error("Could not completely normalize the editor after ".concat(o," iterations! This is usually due to incorrect normalization logic that leaves a node in an invalid state."));return!0},_J=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{voids:n=!1,mode:o="lowest",at:a=t.selection,match:s}=r;if(a){var u=C.path(t,a),l=o==="lowest";for(var[c,p]of C.levels(t,{at:u,voids:n,match:s,reverse:l}))if(!J.isText(c)){if(O.isRange(a)){if(T.isAncestor(p,a.anchor.path)&&T.isAncestor(p,a.focus.path))return[c,p]}else if(!T.equals(u,p))return[c,p]}}};function xE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function wE(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?xE(Object(r),!0).forEach(function(n){Vt(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):xE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var WJ=(e,t,r)=>{var{selection:n}=e;if(n){var o=(d,h)=>{if(!J.isText(d))return!1;var[g,v]=C.parent(e,h);return!e.isVoid(g)||e.markableVoid(g)},a=O.isExpanded(n),s=!1;if(!a){var[u,l]=C.node(e,n);if(u&&o(u,l)){var[c]=C.parent(e,l);s=c&&e.markableVoid(c)}}if(a||s)k.setNodes(e,{[t]:r},{match:o,split:!0,voids:!0});else{var p=wE(wE({},C.marks(e)||{}),{},{[t]:r});e.marks=p,qu.get(e)||e.onChange()}}};function SE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function DE(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?SE(Object(r),!0).forEach(function(n){Vt(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):SE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var UJ=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},o=C.point(t,r,{edge:"end"}),a=C.end(t,[]),s={anchor:o,focus:a},{distance:u=1}=n,l=0,c;for(var p of C.positions(t,DE(DE({},n),{},{at:s}))){if(l>u)break;l!==0&&(c=p),l++}return c};function EE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function PE(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?EE(Object(r),!0).forEach(function(n){Vt(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):EE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var KJ=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},o=C.start(t,[]),a=C.point(t,r,{edge:"start"}),s={anchor:o,focus:a},{distance:u=1}=n,l=0,c;for(var p of C.positions(t,PE(PE({},n),{},{at:s,reverse:!0}))){if(l>u)break;l!==0&&(c=p),l++}return c},qJ=(e,t)=>{var{selection:r}=e;r&&O.isCollapsed(r)&&k.delete(e,{unit:t,reverse:!0})},XJ=(e,t)=>{var{selection:r}=e;r&&O.isCollapsed(r)&&k.delete(e,{unit:t})},YJ=function(t){var{direction:r="forward"}=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{selection:n}=t;n&&O.isExpanded(n)&&k.delete(t,{reverse:r==="backward"})},JJ=(e,t)=>[C.start(e,t),C.end(e,t)];function TE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function AE(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?TE(Object(r),!0).forEach(function(n){Vt(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):TE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var ZJ=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return C.above(t,AE(AE({},r),{},{match:n=>K.isElement(n)&&C.isElementReadOnly(t,n)}))},QJ=(e,t)=>C.point(e,t,{edge:"end"}),eZ=(e,t)=>{var r=C.path(e,t,{edge:"start"});return C.node(e,r)},tZ=(e,t)=>{var r=C.range(e,t);return W.fragment(e,r)};function RE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function FE(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?RE(Object(r),!0).forEach(function(n){Vt(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):RE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var rZ=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return C.above(t,FE(FE({},r),{},{match:n=>K.isElement(n)&&C.isVoid(t,n)}))},nZ=(e,t)=>t.children.some(r=>K.isElement(r)&&C.isBlock(e,r)),oZ=(e,t)=>t.children.some(r=>J.isText(r)||C.isInline(e,r)),iZ=(e,t)=>W.has(e,t),aZ=(e,t)=>t.children.every(r=>J.isText(r)),sZ=e=>{k.splitNodes(e,{always:!0})},uZ=(e,t,r)=>{k.insertNodes(e,t,r)},lZ=e=>{k.splitNodes(e,{always:!0})};function BE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function cZ(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?BE(Object(r),!0).forEach(function(n){Vt(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):BE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var fZ=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{selection:o,marks:a}=t;if(o){if(a){var s=cZ({text:r},a);k.insertNodes(t,s,{at:n.at,voids:n.voids})}else k.insertText(t,r,n);t.marks=null}},pZ=(e,t)=>!e.isInline(t),dZ=(e,t,r)=>C.isStart(e,t,r)||C.isEnd(e,t,r),mZ=(e,t)=>{var{children:r}=t,[n]=r;return r.length===0||r.length===1&&J.isText(n)&&n.text===""&&!e.isVoid(t)},hZ=(e,t,r)=>{var n=C.end(e,r);return ge.equals(t,n)},gZ=e=>{var t=VE.get(e);return t===void 0?!0:t},vZ=(e,t,r)=>{if(t.offset!==0)return!1;var n=C.start(e,r);return ge.equals(t,n)},yZ=(e,t)=>{var r=C.path(e,t,{edge:"end"});return C.node(e,r)},bZ=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},o=C.path(t,r,n),a=W.leaf(t,o);return[a,o]};function*CZ(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{at:r=e.selection,reverse:n=!1,voids:o=!1}=t,{match:a}=t;if(a==null&&(a=()=>!0),!!r){var s=[],u=C.path(e,r);for(var[l,c]of W.levels(e,u))if(a(l,c)&&(s.push([l,c]),!o&&K.isElement(l)&&C.isVoid(e,l)))break;n&&s.reverse(),yield*s}}var xZ=["text"],wZ=["text"],SZ=function(t){var{marks:r,selection:n}=t;if(!n)return null;if(r)return r;if(O.isExpanded(n)){var[o]=C.nodes(t,{match:J.isText});if(o){var[a]=o,s=Hn(a,xZ);return s}else return{}}var{anchor:u}=n,{path:l}=u,[c]=C.leaf(t,l);if(u.offset===0){var p=C.previous(t,{at:l,match:J.isText}),d=C.above(t,{match:y=>K.isElement(y)&&C.isVoid(t,y)&&t.markableVoid(y)});if(!d){var h=C.above(t,{match:y=>K.isElement(y)&&C.isBlock(t,y)});if(p&&h){var[g,v]=p,[,m]=h;T.isAncestor(m,v)&&(c=g)}}}var b=Hn(c,wZ);return b},DZ=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{mode:n="lowest",voids:o=!1}=r,{match:a,at:s=t.selection}=r;if(s){var u=C.after(t,s,{voids:o});if(u){var[,l]=C.last(t,[]),c=[u.path,l];if(T.isPath(s)&&s.length===0)throw new Error("Cannot get the next node from the root node!");if(a==null)if(T.isPath(s)){var[p]=C.parent(t,s);a=h=>p.children.includes(h)}else a=()=>!0;var[d]=C.nodes(t,{at:c,match:a,mode:n,voids:o});return d}}},EZ=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},o=C.path(t,r,n),a=W.get(t,o);return[a,o]};function*PZ(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{at:r=e.selection,mode:n="all",universal:o=!1,reverse:a=!1,voids:s=!1,ignoreNonSelectable:u=!1}=t,{match:l}=t;if(l||(l=()=>!0),!!r){var c,p;if(pJ.isSpan(r))c=r[0],p=r[1];else{var d=C.path(e,r,{edge:"start"}),h=C.path(e,r,{edge:"end"});c=a?h:d,p=a?d:h}var g=W.nodes(e,{reverse:a,from:c,to:p,pass:S=>{var[E]=S;return K.isElement(E)?!!(!s&&(C.isVoid(e,E)||C.isElementReadOnly(e,E))||u&&!C.isSelectable(e,E)):!1}}),v=[],m;for(var[b,y]of g)if(!(u&&K.isElement(b)&&!C.isSelectable(e,b))){var x=m&&T.compare(y,m[1])===0;if(!(n==="highest"&&x)){if(!l(b,y)){if(o&&!x&&J.isText(b))return;continue}if(n==="lowest"&&x){m=[b,y];continue}var w=n==="lowest"?m:[b,y];w&&(o?v.push(w):yield w),m=[b,y]}}n==="lowest"&&m&&(o?v.push(m):yield m),o&&(yield*v)}}var TZ=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{force:n=!1,operation:o}=r,a=p=>td.get(p)||[],s=p=>rd.get(p)||new Set,u=p=>{var d=a(p).pop(),h=d.join(",");return s(p).delete(h),d};if(C.isNormalizing(t)){if(n){var l=Array.from(W.nodes(t),p=>{var[,d]=p;return d}),c=new Set(l.map(p=>p.join(",")));td.set(t,l),rd.set(t,c)}a(t).length!==0&&C.withoutNormalizing(t,()=>{for(var p of a(t))if(W.has(t,p)){var d=C.node(t,p),[h,g]=d;K.isElement(h)&&h.children.length===0&&t.normalizeNode(d,{operation:o})}for(var v=a(t),m=v.length,b=0;v.length!==0;){if(!t.shouldNormalize({dirtyPaths:v,iteration:b,initialDirtyPathsLength:m,operation:o}))return;var y=u(t);if(W.has(t,y)){var x=C.node(t,y);t.normalizeNode(x,{operation:o})}b++,v=a(t)}})}},AZ=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},o=C.path(t,r,n),a=T.parent(o),s=C.node(t,a);return s},RZ=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{affinity:o="forward"}=n,a={current:r,affinity:o,unref(){var{current:u}=a,l=C.pathRefs(t);return l.delete(a),a.current=null,u}},s=C.pathRefs(t);return s.add(a),a},FZ=e=>{var t=aE.get(e);return t||(t=new Set,aE.set(e,t)),t},BZ=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{depth:o,edge:a}=n;if(T.isPath(r)){if(a==="start"){var[,s]=W.first(t,r);r=s}else if(a==="end"){var[,u]=W.last(t,r);r=u}}return O.isRange(r)&&(a==="start"?r=O.start(r):a==="end"?r=O.end(r):r=T.common(r.anchor.path,r.focus.path)),ge.isPoint(r)&&(r=r.path),o!=null&&(r=r.slice(0,o)),r},OZ=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{affinity:o="forward"}=n,a={current:r,affinity:o,unref(){var{current:u}=a,l=C.pointRefs(t);return l.delete(a),a.current=null,u}},s=C.pointRefs(t);return s.add(a),a},MZ=e=>{var t=sE.get(e);return t||(t=new Set,sE.set(e,t)),t},IZ=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{edge:o="start"}=n;if(T.isPath(r)){var a;if(o==="end"){var[,s]=W.last(t,r);a=s}else{var[,u]=W.first(t,r);a=u}var l=W.get(t,a);if(!J.isText(l))throw new Error("Cannot get the ".concat(o," point in the node at path [").concat(r,"] because it has no ").concat(o," text node."));return{path:a,offset:o==="end"?l.text.length:0}}if(O.isRange(r)){var[c,p]=O.edges(r);return o==="start"?c:p}return r};function*kZ(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{at:r=e.selection,unit:n="offset",reverse:o=!1,voids:a=!1,ignoreNonSelectable:s=!1}=t;if(!r)return;var u=C.range(e,r),[l,c]=O.edges(u),p=o?c:l,d=!1,h="",g=0,v=0,m=0;for(var[b,y]of C.nodes(e,{at:r,reverse:o,voids:a,ignoreNonSelectable:s})){if(K.isElement(b)){if(!a&&(e.isVoid(b)||e.isElementReadOnly(b))){yield C.start(e,y);continue}if(e.isInline(b))continue;if(C.hasInlines(e,b)){var x=T.isAncestor(y,c.path)?c:C.end(e,y),w=T.isAncestor(y,l.path)?l:C.start(e,y);h=C.string(e,{anchor:w,focus:x},{voids:a}),d=!0}}if(J.isText(b)){var S=T.equals(y,p.path);for(S?(v=o?p.offset:b.text.length-p.offset,m=p.offset):(v=b.text.length,m=o?v:0),(S||d||n==="offset")&&(yield{path:y,offset:m},d=!1);;){if(g===0){if(h==="")break;g=E(h,n,o),h=b2(h,g,o)[1]}if(m=o?m-g:m+g,v=v-g,v<0){g=-v;break}g=0,yield{path:y,offset:m}}}}function E(D,P,R){return P==="character"?y2(D,R):P==="word"?yJ(D,R):P==="line"||P==="block"?D.length:1}}var NZ=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{mode:n="lowest",voids:o=!1}=r,{match:a,at:s=t.selection}=r;if(s){var u=C.before(t,s,{voids:o});if(u){var[,l]=C.first(t,[]),c=[u.path,l];if(T.isPath(s)&&s.length===0)throw new Error("Cannot get the previous node from the root node!");if(a==null)if(T.isPath(s)){var[p]=C.parent(t,s);a=h=>p.children.includes(h)}else a=()=>!0;var[d]=C.nodes(t,{reverse:!0,at:c,match:a,mode:n,voids:o});return d}}},VZ=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{affinity:o="forward"}=n,a={current:r,affinity:o,unref(){var{current:u}=a,l=C.rangeRefs(t);return l.delete(a),a.current=null,u}},s=C.rangeRefs(t);return s.add(a),a},LZ=e=>{var t=uE.get(e);return t||(t=new Set,uE.set(e,t)),t},$Z=(e,t,r)=>{if(O.isRange(t)&&!r)return t;var n=C.start(e,t),o=C.end(e,r||t);return{anchor:n,focus:o}};function OE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function zZ(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?OE(Object(r),!0).forEach(function(n){Vt(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):OE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var HZ=(e,t)=>{var{selection:r}=e;if(r){var n=(p,d)=>{if(!J.isText(p))return!1;var[h,g]=C.parent(e,d);return!e.isVoid(h)||e.markableVoid(h)},o=O.isExpanded(r),a=!1;if(!o){var[s,u]=C.node(e,r);if(s&&n(s,u)){var[l]=C.parent(e,u);a=l&&e.markableVoid(l)}}if(o||a)k.unsetNodes(e,t,{match:n,split:!0,voids:!0});else{var c=zZ({},C.marks(e)||{});delete c[t],e.marks=c,qu.get(e)||e.onChange()}}},GZ=(e,t)=>{VE.set(e,t)},jZ=(e,t)=>C.point(e,t,{edge:"start"}),_Z=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{voids:o=!1}=n,a=C.range(t,r),[s,u]=O.edges(a),l="";for(var[c,p]of C.nodes(t,{at:a,match:J.isText,voids:o})){var d=c.text;T.equals(p,u.path)&&(d=d.slice(0,u.offset)),T.equals(p,s.path)&&(d=d.slice(s.offset)),l+=d}return l},WZ=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{voids:o=!1}=n,[a,s]=O.edges(r);if(a.offset!==0||s.offset!==0||O.isCollapsed(r)||T.hasPrevious(s.path))return r;var u=C.above(t,{at:s,match:v=>K.isElement(v)&&C.isBlock(t,v),voids:o}),l=u?u[1]:[],c=C.start(t,a),p={anchor:c,focus:s},d=!0;for(var[h,g]of C.nodes(t,{at:p,match:J.isText,reverse:!0,voids:o})){if(d){d=!1;continue}if(h.text!==""||T.isBefore(g,l)){s={path:g,offset:h.text.length};break}}return{anchor:a,focus:s}},UZ=(e,t)=>{var r=C.isNormalizing(e);C.setNormalizing(e,!1);try{t()}finally{C.setNormalizing(e,r)}C.normalize(e)},KZ=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};C.withoutNormalizing(t,()=>{var n,o,{reverse:a=!1,unit:s="character",distance:u=1,voids:l=!1}=r,{at:c=t.selection,hanging:p=!1}=r;if(c){var d=!1;if(O.isRange(c)&&O.isCollapsed(c)&&(d=!0,c=c.anchor),ge.isPoint(c)){var h=C.void(t,{at:c,mode:"highest"});if(!l&&h){var[,g]=h;c=g}else{var v={unit:s,distance:u},m=a?C.before(t,c,v)||C.start(t,[]):C.after(t,c,v)||C.end(t,[]);c={anchor:c,focus:m},p=!0}}if(T.isPath(c)){k.removeNodes(t,{at:c,voids:l});return}if(!O.isCollapsed(c)){if(!p){var[,b]=O.edges(c),y=C.end(t,[]);ge.equals(b,y)||(c=C.unhangRange(t,c,{voids:l}))}var[x,w]=O.edges(c),S=C.above(t,{match:xe=>K.isElement(xe)&&C.isBlock(t,xe),at:x,voids:l}),E=C.above(t,{match:xe=>K.isElement(xe)&&C.isBlock(t,xe),at:w,voids:l}),D=S&&E&&!T.equals(S[1],E[1]),P=T.equals(x.path,w.path),R=l?null:(n=C.void(t,{at:x,mode:"highest"}))!==null&&n!==void 0?n:C.elementReadOnly(t,{at:x,mode:"highest"}),F=l?null:(o=C.void(t,{at:w,mode:"highest"}))!==null&&o!==void 0?o:C.elementReadOnly(t,{at:w,mode:"highest"});if(R){var M=C.before(t,x);M&&S&&T.isAncestor(S[1],M.path)&&(x=M)}if(F){var G=C.after(t,w);G&&E&&T.isAncestor(E[1],G.path)&&(w=G)}var N=[],L;for(var I of C.nodes(t,{at:c,voids:l})){var[V,Y]=I;L&&T.compare(Y,L)===0||(!l&&K.isElement(V)&&(C.isVoid(t,V)||C.isElementReadOnly(t,V))||!T.isCommon(Y,x.path)&&!T.isCommon(Y,w.path))&&(N.push(I),L=Y)}var Q=Array.from(N,xe=>{var[,ht]=xe;return C.pathRef(t,ht)}),re=C.pointRef(t,x),H=C.pointRef(t,w),le="";if(!P&&!R){var ve=re.current,[me]=C.leaf(t,ve),{path:Ge}=ve,{offset:A}=x,_=me.text.slice(A);_.length>0&&(t.apply({type:"remove_text",path:Ge,offset:A,text:_}),le=_)}if(Q.reverse().map(xe=>xe.unref()).filter(xe=>xe!==null).forEach(xe=>k.removeNodes(t,{at:xe,voids:l})),!F){var z=H.current,[j]=C.leaf(t,z),{path:ue}=z,oe=P?x.offset:0,he=j.text.slice(oe,w.offset);he.length>0&&(t.apply({type:"remove_text",path:ue,offset:oe,text:he}),le=he)}!P&&D&&H.current&&re.current&&k.mergeNodes(t,{at:H.current,hanging:!0,voids:l}),d&&a&&s==="character"&&le.length>1&&le.match(/[\u0E00-\u0E7F]+/)&&k.insertText(t,le.slice(0,le.length-u));var Ce=re.unref(),Se=H.unref(),Ee=a?Ce||Se:Se||Ce;r.at==null&&Ee&&k.select(t,Ee)}}})},qZ=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};C.withoutNormalizing(t,()=>{var{hanging:o=!1,voids:a=!1}=n,{at:s=v2(t)}=n;if(r.length){if(O.isRange(s))if(o||(s=C.unhangRange(t,s,{voids:a})),O.isCollapsed(s))s=s.anchor;else{var[,u]=O.edges(s);if(!a&&C.void(t,{at:u}))return;var l=C.pointRef(t,u);k.delete(t,{at:s}),s=l.unref()}else T.isPath(s)&&(s=C.start(t,s));if(!(!a&&C.void(t,{at:s}))){var c=C.above(t,{at:s,match:A=>K.isElement(A)&&C.isInline(t,A),mode:"highest",voids:a});if(c){var[,p]=c;if(C.isEnd(t,s,p)){var d=C.after(t,p);s=d}else if(C.isStart(t,s,p)){var h=C.before(t,p);s=h}}var g=C.above(t,{match:A=>K.isElement(A)&&C.isBlock(t,A),at:s,voids:a}),[,v]=g,m=C.isStart(t,s,v),b=C.isEnd(t,s,v),y=m&&b,x=!m||m&&b,w=!b,[,S]=W.first({children:r},[]),[,E]=W.last({children:r},[]),D=[],P=A=>{var[_,z]=A,j=z.length===0;return j?!1:y?!0:!(x&&T.isAncestor(z,S)&&K.isElement(_)&&!t.isVoid(_)&&!t.isInline(_)||w&&T.isAncestor(z,E)&&K.isElement(_)&&!t.isVoid(_)&&!t.isInline(_))};for(var R of W.nodes({children:r},{pass:P}))P(R)&&D.push(R);var F=[],M=[],G=[],N=!0,L=!1;for(var[I]of D)K.isElement(I)&&!t.isInline(I)?(N=!1,L=!0,M.push(I)):N?F.push(I):G.push(I);var[V]=C.nodes(t,{at:s,match:A=>J.isText(A)||C.isInline(t,A),mode:"highest",voids:a}),[,Y]=V,Q=C.isStart(t,s,Y),re=C.isEnd(t,s,Y),H=C.pathRef(t,b&&!G.length?T.next(v):v),le=C.pathRef(t,re?T.next(Y):Y);k.splitNodes(t,{at:s,match:A=>L?K.isElement(A)&&C.isBlock(t,A):J.isText(A)||C.isInline(t,A),mode:L?"lowest":"highest",always:L&&(!m||F.length>0)&&(!b||G.length>0),voids:a});var ve=C.pathRef(t,!Q||Q&&re?T.next(Y):Y);if(k.insertNodes(t,F,{at:ve.current,match:A=>J.isText(A)||C.isInline(t,A),mode:"highest",voids:a}),y&&!F.length&&M.length&&!G.length&&k.delete(t,{at:v,voids:a}),k.insertNodes(t,M,{at:H.current,match:A=>K.isElement(A)&&C.isBlock(t,A),mode:"lowest",voids:a}),k.insertNodes(t,G,{at:le.current,match:A=>J.isText(A)||C.isInline(t,A),mode:"highest",voids:a}),!n.at){var me;if(G.length>0&&le.current?me=T.previous(le.current):M.length>0&&H.current?me=T.previous(H.current):ve.current&&(me=T.previous(ve.current)),me){var Ge=C.end(t,me);k.select(t,Ge)}}ve.unref(),H.unref(),le.unref()}}})},XZ=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{edge:n="anchor"}=r,{selection:o}=t;if(o){if(n==="anchor")k.select(t,o.anchor);else if(n==="focus")k.select(t,o.focus);else if(n==="start"){var[a]=O.edges(o);k.select(t,a)}else if(n==="end"){var[,s]=O.edges(o);k.select(t,s)}}else return},YZ=e=>{var{selection:t}=e;t&&e.apply({type:"set_selection",properties:t,newProperties:null})},JZ=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{selection:n}=t,{distance:o=1,unit:a="character",reverse:s=!1}=r,{edge:u=null}=r;if(n){u==="start"&&(u=O.isBackward(n)?"focus":"anchor"),u==="end"&&(u=O.isBackward(n)?"anchor":"focus");var{anchor:l,focus:c}=n,p={distance:o,unit:a,ignoreNonSelectable:!0},d={};if(u==null||u==="anchor"){var h=s?C.before(t,l,p):C.after(t,l,p);h&&(d.anchor=h)}if(u==null||u==="focus"){var g=s?C.before(t,c,p):C.after(t,c,p);g&&(d.focus=g)}k.setSelection(t,d)}},ZZ=(e,t)=>{var{selection:r}=e;if(t=C.range(e,t),r){k.setSelection(e,t);return}if(!O.isRange(t))throw new Error("When setting the selection and the current selection is `null` you must provide at least an `anchor` and `focus`, but you passed: ".concat(it.stringify(t)));e.apply({type:"set_selection",properties:r,newProperties:t})};function ME(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function IE(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?ME(Object(r),!0).forEach(function(n){Vt(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):ME(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var QZ=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{selection:o}=t,{edge:a="both"}=n;if(o){a==="start"&&(a=O.isBackward(o)?"focus":"anchor"),a==="end"&&(a=O.isBackward(o)?"anchor":"focus");var{anchor:s,focus:u}=o,l=a==="anchor"?s:u;k.setSelection(t,{[a==="anchor"?"anchor":"focus"]:IE(IE({},l),r)})}},eQ=(e,t)=>{var{selection:r}=e,n={},o={};if(r){for(var a in t)(a==="anchor"&&t.anchor!=null&&!ge.equals(t.anchor,r.anchor)||a==="focus"&&t.focus!=null&&!ge.equals(t.focus,r.focus)||a!=="anchor"&&a!=="focus"&&t[a]!==r[a])&&(n[a]=r[a],o[a]=t[a]);Object.keys(n).length>0&&e.apply({type:"set_selection",properties:n,newProperties:o})}},tQ=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};C.withoutNormalizing(t,()=>{var{hanging:o=!1,voids:a=!1,mode:s="lowest"}=n,{at:u,match:l,select:c}=n;if(W.isNode(r)&&(r=[r]),r.length!==0){var[p]=r;if(u||(u=v2(t),c=!0),c==null&&(c=!1),O.isRange(u))if(o||(u=C.unhangRange(t,u,{voids:a})),O.isCollapsed(u))u=u.anchor;else{var[,d]=O.edges(u),h=C.pointRef(t,d);k.delete(t,{at:u}),u=h.unref()}if(ge.isPoint(u)){l==null&&(J.isText(p)?l=P=>J.isText(P):t.isInline(p)?l=P=>J.isText(P)||C.isInline(t,P):l=P=>K.isElement(P)&&C.isBlock(t,P));var[g]=C.nodes(t,{at:u.path,match:l,mode:s,voids:a});if(g){var[,v]=g,m=C.pathRef(t,v),b=C.isEnd(t,u,v);k.splitNodes(t,{at:u,match:l,mode:s,voids:a});var y=m.unref();u=b?T.next(y):y}else return}var x=T.parent(u),w=u[u.length-1];if(!(!a&&C.void(t,{at:x}))){for(var S of r){var E=x.concat(w);w++,t.apply({type:"insert_node",path:E,node:S}),u=T.next(u)}if(u=T.previous(u),c){var D=C.end(t,u);D&&k.select(t,D)}}}})},rQ=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};C.withoutNormalizing(t,()=>{var{at:n=t.selection,mode:o="lowest",voids:a=!1}=r,{match:s}=r;if(s==null&&(s=T.isPath(n)?is(t,n):S=>K.isElement(S)&&C.isBlock(t,S)),!!n){var u=C.nodes(t,{at:n,match:s,mode:o,voids:a}),l=Array.from(u,S=>{var[,E]=S;return C.pathRef(t,E)});for(var c of l){var p=c.unref();if(p.length<2)throw new Error("Cannot lift node at a path [".concat(p,"] because it has a depth of less than `2`."));var d=C.node(t,T.parent(p)),[h,g]=d,v=p[p.length-1],{length:m}=h.children;if(m===1){var b=T.next(g);k.moveNodes(t,{at:p,to:b,voids:a}),k.removeNodes(t,{at:g,voids:a})}else if(v===0)k.moveNodes(t,{at:p,to:g,voids:a});else if(v===m-1){var y=T.next(g);k.moveNodes(t,{at:p,to:y,voids:a})}else{var x=T.next(p),w=T.next(g);k.splitNodes(t,{at:x,voids:a}),k.moveNodes(t,{at:p,to:w,voids:a})}}}})},nQ=["text"],oQ=["children"],$E=(e,t)=>{if(K.isElement(t)){var r=t;return C.isVoid(e,t)?!0:r.children.length===1?$E(e,r.children[0]):!1}else return!C.isEditor(t)},iQ=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};C.withoutNormalizing(t,()=>{var{match:n,at:o=t.selection}=r,{hanging:a=!1,voids:s=!1,mode:u="lowest"}=r;if(o){if(n==null)if(T.isPath(o)){var[l]=C.parent(t,o);n=M=>l.children.includes(M)}else n=M=>K.isElement(M)&&C.isBlock(t,M);if(!a&&O.isRange(o)&&(o=C.unhangRange(t,o,{voids:s})),O.isRange(o))if(O.isCollapsed(o))o=o.anchor;else{var[,c]=O.edges(o),p=C.pointRef(t,c);k.delete(t,{at:o}),o=p.unref(),r.at==null&&k.select(t,o)}var[d]=C.nodes(t,{at:o,match:n,voids:s,mode:u}),h=C.previous(t,{at:o,match:n,voids:s,mode:u});if(!(!d||!h)){var[g,v]=d,[m,b]=h;if(!(v.length===0||b.length===0)){var y=T.next(b),x=T.common(v,b),w=T.isSibling(v,b),S=Array.from(C.levels(t,{at:v}),M=>{var[G]=M;return G}).slice(x.length).slice(0,-1),E=C.above(t,{at:v,mode:"highest",match:M=>S.includes(M)&&$E(t,M)}),D=E&&C.pathRef(t,E[1]),P,R;if(J.isText(g)&&J.isText(m)){var F=Hn(g,nQ);R=m.text.length,P=F}else if(K.isElement(g)&&K.isElement(m)){var F=Hn(g,oQ);R=m.children.length,P=F}else throw new Error("Cannot merge the node at path [".concat(v,"] with the previous sibling because it is not the same kind: ").concat(it.stringify(g)," ").concat(it.stringify(m)));w||k.moveNodes(t,{at:v,to:y,voids:s}),D&&k.removeNodes(t,{at:D.current,voids:s}),K.isElement(m)&&C.isEmpty(t,m)||J.isText(m)&&m.text===""&&b[b.length-1]!==0?k.removeNodes(t,{at:b,voids:s}):t.apply({type:"merge_node",path:y,position:R,properties:P}),D&&D.unref()}}}})},aQ=(e,t)=>{C.withoutNormalizing(e,()=>{var{to:r,at:n=e.selection,mode:o="lowest",voids:a=!1}=t,{match:s}=t;if(n){s==null&&(s=T.isPath(n)?is(e,n):g=>K.isElement(g)&&C.isBlock(e,g));var u=C.pathRef(e,r),l=C.nodes(e,{at:n,match:s,mode:o,voids:a}),c=Array.from(l,g=>{var[,v]=g;return C.pathRef(e,v)});for(var p of c){var d=p.unref(),h=u.current;d.length!==0&&e.apply({type:"move_node",path:d,newPath:h}),u.current&&T.isSibling(h,d)&&T.isAfter(h,d)&&(u.current=T.next(u.current))}u.unref()}})},sQ=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};C.withoutNormalizing(t,()=>{var{hanging:n=!1,voids:o=!1,mode:a="lowest"}=r,{at:s=t.selection,match:u}=r;if(s){u==null&&(u=T.isPath(s)?is(t,s):g=>K.isElement(g)&&C.isBlock(t,g)),!n&&O.isRange(s)&&(s=C.unhangRange(t,s,{voids:o}));var l=C.nodes(t,{at:s,match:u,mode:a,voids:o}),c=Array.from(l,g=>{var[,v]=g;return C.pathRef(t,v)});for(var p of c){var d=p.unref();if(d){var[h]=C.node(t,d);t.apply({type:"remove_node",path:d,node:h})}}}})},uQ=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};C.withoutNormalizing(t,()=>{var{match:o,at:a=t.selection,compare:s,merge:u}=n,{hanging:l=!1,mode:c="lowest",split:p=!1,voids:d=!1}=n;if(a){if(o==null&&(o=T.isPath(a)?is(t,a):R=>K.isElement(R)&&C.isBlock(t,R)),!l&&O.isRange(a)&&(a=C.unhangRange(t,a,{voids:d})),p&&O.isRange(a)){if(O.isCollapsed(a)&&C.leaf(t,a.anchor)[0].text.length>0)return;var h=C.rangeRef(t,a,{affinity:"inward"}),[g,v]=O.edges(a),m=c==="lowest"?"lowest":"highest",b=C.isEnd(t,v,v.path);k.splitNodes(t,{at:v,match:o,mode:m,voids:d,always:!b});var y=C.isStart(t,g,g.path);k.splitNodes(t,{at:g,match:o,mode:m,voids:d,always:!y}),a=h.unref(),n.at==null&&k.select(t,a)}s||(s=(R,F)=>R!==F);for(var[x,w]of C.nodes(t,{at:a,match:o,mode:c,voids:d})){var S={},E={};if(w.length!==0){var D=!1;for(var P in r)P==="children"||P==="text"||s(r[P],x[P])&&(D=!0,x.hasOwnProperty(P)&&(S[P]=x[P]),u?r[P]!=null&&(E[P]=u(x[P],r[P])):r[P]!=null&&(E[P]=r[P]));D&&t.apply({type:"set_node",path:w,properties:S,newProperties:E})}}}})},lQ=(e,t)=>{if(O.isCollapsed(t))return t.anchor;var[,r]=O.edges(t),n=C.pointRef(e,r);return k.delete(e,{at:t}),n.unref()},cQ=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};C.withoutNormalizing(t,()=>{var{mode:n="lowest",voids:o=!1}=r,{match:a,at:s=t.selection,height:u=0,always:l=!1}=r;if(a==null&&(a=H=>K.isElement(H)&&C.isBlock(t,H)),O.isRange(s)&&(s=lQ(t,s)),T.isPath(s)){var c=s,p=C.point(t,c),[d]=C.parent(t,c);a=H=>H===d,u=p.path.length-c.length+1,s=p,l=!0}if(s){var h=C.pointRef(t,s,{affinity:"backward"}),g;try{var[v]=C.nodes(t,{at:s,match:a,mode:n,voids:o});if(!v)return;var m=C.void(t,{at:s,mode:"highest"}),b=0;if(!o&&m){var[y,x]=m;if(K.isElement(y)&&t.isInline(y)){var w=C.after(t,x);if(!w){var S={text:""},E=T.next(x);k.insertNodes(t,S,{at:E,voids:o}),w=C.point(t,E)}s=w,l=!0}var D=s.path.length-x.length;u=D+1,l=!0}g=C.pointRef(t,s);var P=s.path.length-u,[,R]=v,F=s.path.slice(0,P),M=u===0?s.offset:s.path[P]+b;for(var[G,N]of C.levels(t,{at:F,reverse:!0,voids:o})){var L=!1;if(N.length<R.length||N.length===0||!o&&K.isElement(G)&&C.isVoid(t,G))break;var I=h.current,V=C.isEnd(t,I,N);if(l||!h||!C.isEdge(t,I,N)){L=!0;var Y=W.extractProps(G);t.apply({type:"split_node",path:N,position:M,properties:Y})}M=N[N.length-1]+(L||V?1:0)}if(r.at==null){var Q=g.current||C.end(t,[]);k.select(t,Q)}}finally{var re;h.unref(),(re=g)===null||re===void 0||re.unref()}}})},fQ=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};Array.isArray(r)||(r=[r]);var o={};for(var a of r)o[a]=null;k.setNodes(t,o,n)},pQ=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};C.withoutNormalizing(t,()=>{var{mode:n="lowest",split:o=!1,voids:a=!1}=r,{at:s=t.selection,match:u}=r;if(s){u==null&&(u=T.isPath(s)?is(t,s):g=>K.isElement(g)&&C.isBlock(t,g)),T.isPath(s)&&(s=C.range(t,s));var l=O.isRange(s)?C.rangeRef(t,s):null,c=C.nodes(t,{at:s,match:u,mode:n,voids:a}),p=Array.from(c,g=>{var[,v]=g;return C.pathRef(t,v)}).reverse(),d=function(v){var m=v.unref(),[b]=C.node(t,m),y=C.range(t,m);o&&l&&(y=O.intersection(l.current,y)),k.liftNodes(t,{at:y,match:x=>K.isAncestor(b)&&b.children.includes(x),voids:a})};for(var h of p)d(h);l&&l.unref()}})};function kE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function NE(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?kE(Object(r),!0).forEach(function(n){Vt(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):kE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var dQ=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};C.withoutNormalizing(t,()=>{var{mode:o="lowest",split:a=!1,voids:s=!1}=n,{match:u,at:l=t.selection}=n;if(l){if(u==null&&(T.isPath(l)?u=is(t,l):t.isInline(r)?u=y=>K.isElement(y)&&C.isInline(t,y)||J.isText(y):u=y=>K.isElement(y)&&C.isBlock(t,y)),a&&O.isRange(l)){var[c,p]=O.edges(l),d=C.rangeRef(t,l,{affinity:"inward"});k.splitNodes(t,{at:p,match:u,voids:s}),k.splitNodes(t,{at:c,match:u,voids:s}),l=d.unref(),n.at==null&&k.select(t,l)}var h=Array.from(C.nodes(t,{at:l,match:t.isInline(r)?y=>K.isElement(y)&&C.isBlock(t,y):y=>C.isEditor(y),mode:"lowest",voids:s}));for(var[,g]of h){var v=O.isRange(l)?O.intersection(l,C.range(t,g)):l;if(v){var m=Array.from(C.nodes(t,{at:v,match:u,mode:o,voids:s}));if(m.length>0){var b=function(){var[y]=m,x=m[m.length-1],[,w]=y,[,S]=x;if(w.length===0&&S.length===0)return"continue";var E=T.equals(w,S)?T.parent(w):T.common(w,S),D=C.range(t,w,S),P=C.node(t,E),[R]=P,F=E.length+1,M=T.next(S.slice(0,F)),G=NE(NE({},r),{},{children:[]});k.insertNodes(t,G,{at:M,voids:s}),k.moveNodes(t,{at:D,match:N=>K.isAncestor(R)&&R.children.includes(N),to:M.concat(0),voids:s})}();if(b==="continue")continue}}}}})},nd=()=>{var e={children:[],operations:[],selection:null,marks:null,isElementReadOnly:()=>!1,isInline:()=>!1,isSelectable:()=>!0,isVoid:()=>!1,markableVoid:()=>!1,onChange:()=>{},apply:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return $J(e,...n)},addMark:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return WJ(e,...n)},deleteBackward:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return qJ(e,...n)},deleteForward:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return XJ(e,...n)},deleteFragment:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return YJ(e,...n)},getFragment:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return HJ(e,...n)},insertBreak:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return sZ(e,...n)},insertSoftBreak:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return lZ(e,...n)},insertFragment:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return qZ(e,...n)},insertNode:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return uZ(e,...n)},insertText:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return fZ(e,...n)},normalizeNode:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return GJ(e,...n)},removeMark:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return HZ(e,...n)},getDirtyPaths:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return zJ(e,...n)},shouldNormalize:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return jJ(e,...n)},above:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return _J(e,...n)},after:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return UJ(e,...n)},before:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return KJ(e,...n)},collapse:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return XZ(e,...n)},delete:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return KZ(e,...n)},deselect:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return YZ(e,...n)},edges:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return JJ(e,...n)},elementReadOnly:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return ZJ(e,...n)},end:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return QJ(e,...n)},first:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return eZ(e,...n)},fragment:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return tZ(e,...n)},getMarks:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return SZ(e,...n)},hasBlocks:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return nZ(e,...n)},hasInlines:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return oZ(e,...n)},hasPath:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return iZ(e,...n)},hasTexts:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return aZ(e,...n)},insertNodes:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return tQ(e,...n)},isBlock:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return pZ(e,...n)},isEdge:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return dZ(e,...n)},isEmpty:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return mZ(e,...n)},isEnd:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return hZ(e,...n)},isNormalizing:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return gZ(e,...n)},isStart:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return vZ(e,...n)},last:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return yZ(e,...n)},leaf:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return bZ(e,...n)},levels:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return CZ(e,...n)},liftNodes:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return rQ(e,...n)},mergeNodes:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return iQ(e,...n)},move:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return JZ(e,...n)},moveNodes:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return aQ(e,...n)},next:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return DZ(e,...n)},node:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return EZ(e,...n)},nodes:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return PZ(e,...n)},normalize:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return TZ(e,...n)},parent:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return AZ(e,...n)},path:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return BZ(e,...n)},pathRef:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return RZ(e,...n)},pathRefs:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return FZ(e,...n)},point:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return IZ(e,...n)},pointRef:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return OZ(e,...n)},pointRefs:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return MZ(e,...n)},positions:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return kZ(e,...n)},previous:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return NZ(e,...n)},range:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return $Z(e,...n)},rangeRef:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return VZ(e,...n)},rangeRefs:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return LZ(e,...n)},removeNodes:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return sQ(e,...n)},select:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return ZZ(e,...n)},setNodes:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return uQ(e,...n)},setNormalizing:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return GZ(e,...n)},setPoint:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return QZ(e,...n)},setSelection:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return eQ(e,...n)},splitNodes:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return cQ(e,...n)},start:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return jZ(e,...n)},string:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return _Z(e,...n)},unhangRange:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return WZ(e,...n)},unsetNodes:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return fQ(e,...n)},unwrapNodes:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return pQ(e,...n)},void:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return rZ(e,...n)},withoutNormalizing:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return UZ(e,...n)},wrapNodes:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return dQ(e,...n)}};return e};i();i();i();i();i();i();i();var Er=[];var zE=function(){return Er.some(function(e){return e.activeTargets.length>0})};i();var HE=function(){return Er.some(function(e){return e.skippedTargets.length>0})};i();var GE="ResizeObserver loop completed with undelivered notifications.",jE=function(){var e;typeof ErrorEvent=="function"?e=new ErrorEvent("error",{message:GE}):(e=document.createEvent("Event"),e.initEvent("error",!1,!1),e.message=GE),window.dispatchEvent(e)};i();i();i();i();var Ei;(function(e){e.BORDER_BOX="border-box",e.CONTENT_BOX="content-box",e.DEVICE_PIXEL_CONTENT_BOX="device-pixel-content-box"})(Ei||(Ei={}));i();i();var Hr=function(e){return Object.freeze(e)};var C2=function(){function e(t,r){this.inlineSize=t,this.blockSize=r,Hr(this)}return e}();i();var x2=function(){function e(t,r,n,o){return this.x=t,this.y=r,this.width=n,this.height=o,this.top=this.y,this.left=this.x,this.bottom=this.top+this.height,this.right=this.left+this.width,Hr(this)}return e.prototype.toJSON=function(){var t=this,r=t.x,n=t.y,o=t.top,a=t.right,s=t.bottom,u=t.left,l=t.width,c=t.height;return{x:r,y:n,top:o,right:a,bottom:s,left:u,width:l,height:c}},e.fromRect=function(t){return new e(t.x,t.y,t.width,t.height)},e}();i();var Xu=function(e){return e instanceof SVGElement&&"getBBox"in e},od=function(e){if(Xu(e)){var t=e.getBBox(),r=t.width,n=t.height;return!r&&!n}var o=e,a=o.offsetWidth,s=o.offsetHeight;return!(a||s||e.getClientRects().length)},w2=function(e){var t;if(e instanceof Element)return!0;var r=(t=e?.ownerDocument)===null||t===void 0?void 0:t.defaultView;return!!(r&&e instanceof r.Element)},_E=function(e){switch(e.tagName){case"INPUT":if(e.type!=="image")break;case"VIDEO":case"AUDIO":case"EMBED":case"OBJECT":case"CANVAS":case"IFRAME":case"IMG":return!0}return!1};i();var Pi=typeof window<"u"?window:{};var id=new WeakMap,WE=/auto|scroll/,mQ=/^tb|vertical/,hQ=/msie|trident/i.test(Pi.navigator&&Pi.navigator.userAgent),an=function(e){return parseFloat(e||"0")},as=function(e,t,r){return e===void 0&&(e=0),t===void 0&&(t=0),r===void 0&&(r=!1),new C2((r?t:e)||0,(r?e:t)||0)},UE=Hr({devicePixelContentBoxSize:as(),borderBoxSize:as(),contentBoxSize:as(),contentRect:new x2(0,0,0,0)}),S2=function(e,t){if(t===void 0&&(t=!1),id.has(e)&&!t)return id.get(e);if(od(e))return id.set(e,UE),UE;var r=getComputedStyle(e),n=Xu(e)&&e.ownerSVGElement&&e.getBBox(),o=!hQ&&r.boxSizing==="border-box",a=mQ.test(r.writingMode||""),s=!n&&WE.test(r.overflowY||""),u=!n&&WE.test(r.overflowX||""),l=n?0:an(r.paddingTop),c=n?0:an(r.paddingRight),p=n?0:an(r.paddingBottom),d=n?0:an(r.paddingLeft),h=n?0:an(r.borderTopWidth),g=n?0:an(r.borderRightWidth),v=n?0:an(r.borderBottomWidth),m=n?0:an(r.borderLeftWidth),b=d+c,y=l+p,x=m+g,w=h+v,S=u?e.offsetHeight-w-e.clientHeight:0,E=s?e.offsetWidth-x-e.clientWidth:0,D=o?b+x:0,P=o?y+w:0,R=n?n.width:an(r.width)-D-E,F=n?n.height:an(r.height)-P-S,M=R+b+E+x,G=F+y+S+w,N=Hr({devicePixelContentBoxSize:as(Math.round(R*devicePixelRatio),Math.round(F*devicePixelRatio),a),borderBoxSize:as(M,G,a),contentBoxSize:as(R,F,a),contentRect:new x2(d,l,R,F)});return id.set(e,N),N},ad=function(e,t,r){var n=S2(e,r),o=n.borderBoxSize,a=n.contentBoxSize,s=n.devicePixelContentBoxSize;switch(t){case Ei.DEVICE_PIXEL_CONTENT_BOX:return s;case Ei.BORDER_BOX:return o;default:return a}};var D2=function(){function e(t){var r=S2(t);this.target=t,this.contentRect=r.contentRect,this.borderBoxSize=Hr([r.borderBoxSize]),this.contentBoxSize=Hr([r.contentBoxSize]),this.devicePixelContentBoxSize=Hr([r.devicePixelContentBoxSize])}return e}();i();var sd=function(e){if(od(e))return 1/0;for(var t=0,r=e.parentNode;r;)t+=1,r=r.parentNode;return t};var KE=function(){var e=1/0,t=[];Er.forEach(function(s){if(s.activeTargets.length!==0){var u=[];s.activeTargets.forEach(function(c){var p=new D2(c.target),d=sd(c.target);u.push(p),c.lastReportedSize=ad(c.target,c.observedBox),d<e&&(e=d)}),t.push(function(){s.callback.call(s.observer,u,s.observer)}),s.activeTargets.splice(0,s.activeTargets.length)}});for(var r=0,n=t;r<n.length;r++){var o=n[r];o()}return e};i();var E2=function(e){Er.forEach(function(r){r.activeTargets.splice(0,r.activeTargets.length),r.skippedTargets.splice(0,r.skippedTargets.length),r.observationTargets.forEach(function(o){o.isActive()&&(sd(o.target)>e?r.activeTargets.push(o):r.skippedTargets.push(o))})})};var qE=function(){var e=0;for(E2(e);zE();)e=KE(),E2(e);return HE()&&jE(),e>0};i();i();var P2,XE=[],gQ=function(){return XE.splice(0).forEach(function(e){return e()})},YE=function(e){if(!P2){var t=0,r=document.createTextNode(""),n={characterData:!0};new MutationObserver(function(){return gQ()}).observe(r,n),P2=function(){r.textContent="".concat(t?t--:t++)}}XE.push(e),P2()};var JE=function(e){YE(function(){requestAnimationFrame(e)})};var ud=0,vQ=function(){return!!ud},yQ=250,bQ={attributes:!0,characterData:!0,childList:!0,subtree:!0},ZE=["resize","load","transitionend","animationend","animationstart","animationiteration","keyup","keydown","mouseup","mousedown","mouseover","mouseout","blur","focus"],QE=function(e){return e===void 0&&(e=0),Date.now()+e},T2=!1,CQ=function(){function e(){var t=this;this.stopped=!0,this.listener=function(){return t.schedule()}}return e.prototype.run=function(t){var r=this;if(t===void 0&&(t=yQ),!T2){T2=!0;var n=QE(t);JE(function(){var o=!1;try{o=qE()}finally{if(T2=!1,t=n-QE(),!vQ())return;o?r.run(1e3):t>0?r.run(t):r.start()}})}},e.prototype.schedule=function(){this.stop(),this.run()},e.prototype.observe=function(){var t=this,r=function(){return t.observer&&t.observer.observe(document.body,bQ)};document.body?r():Pi.addEventListener("DOMContentLoaded",r)},e.prototype.start=function(){var t=this;this.stopped&&(this.stopped=!1,this.observer=new MutationObserver(this.listener),this.observe(),ZE.forEach(function(r){return Pi.addEventListener(r,t.listener,!0)}))},e.prototype.stop=function(){var t=this;this.stopped||(this.observer&&this.observer.disconnect(),ZE.forEach(function(r){return Pi.removeEventListener(r,t.listener,!0)}),this.stopped=!0)},e}(),ld=new CQ,A2=function(e){!ud&&e>0&&ld.start(),ud+=e,!ud&&ld.stop()};i();var xQ=function(e){return!Xu(e)&&!_E(e)&&getComputedStyle(e).display==="inline"},eP=function(){function e(t,r){this.target=t,this.observedBox=r||Ei.CONTENT_BOX,this.lastReportedSize={inlineSize:0,blockSize:0}}return e.prototype.isActive=function(){var t=ad(this.target,this.observedBox,!0);return xQ(this.target)&&(this.lastReportedSize=t),this.lastReportedSize.inlineSize!==t.inlineSize||this.lastReportedSize.blockSize!==t.blockSize},e}();i();var tP=function(){function e(t,r){this.activeTargets=[],this.skippedTargets=[],this.observationTargets=[],this.observer=t,this.callback=r}return e}();var cd=new WeakMap,rP=function(e,t){for(var r=0;r<e.length;r+=1)if(e[r].target===t)return r;return-1},Yu=function(){function e(){}return e.connect=function(t,r){var n=new tP(t,r);cd.set(t,n)},e.observe=function(t,r,n){var o=cd.get(t),a=o.observationTargets.length===0;rP(o.observationTargets,r)<0&&(a&&Er.push(o),o.observationTargets.push(new eP(r,n&&n.box)),A2(1),ld.schedule())},e.unobserve=function(t,r){var n=cd.get(t),o=rP(n.observationTargets,r),a=n.observationTargets.length===1;o>=0&&(a&&Er.splice(Er.indexOf(n),1),n.observationTargets.splice(o,1),A2(-1))},e.disconnect=function(t){var r=this,n=cd.get(t);n.observationTargets.slice().forEach(function(o){return r.unobserve(t,o.target)}),n.activeTargets.splice(0,n.activeTargets.length)},e}();var R2=function(){function e(t){if(arguments.length===0)throw new TypeError("Failed to construct 'ResizeObserver': 1 argument required, but only 0 present.");if(typeof t!="function")throw new TypeError("Failed to construct 'ResizeObserver': The callback provided as parameter 1 is not a function.");Yu.connect(this,t)}return e.prototype.observe=function(t,r){if(arguments.length===0)throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!w2(t))throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': parameter 1 is not of type 'Element");Yu.observe(this,t,r)},e.prototype.unobserve=function(t){if(arguments.length===0)throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!w2(t))throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': parameter 1 is not of type 'Element");Yu.unobserve(this,t)},e.prototype.disconnect=function(){Yu.disconnect(this)},e.toString=function(){return"function ResizeObserver () { [polyfill code] }"},e}();var md=U(sP());import BQ from"react-dom";function bd(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function OQ(e,t){if(e==null)return{};var r={},n=Object.keys(e),o,a;for(a=0;a<n.length;a++)o=n[a],!(t.indexOf(o)>=0)&&(r[o]=e[o]);return r}function ls(e,t){if(e==null)return{};var r=OQ(e,t),n,o;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(o=0;o<a.length;o++)n=a[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}var H2=Bi(null),Lo=()=>{var e=fs(H2);if(!e)throw new Error("The `useSlateStatic` hook must be used inside the <Slate> component's context.");return e},SP=parseInt(de.version.split(".")[0],10),MQ=typeof navigator<"u"&&typeof window<"u"&&/iPad|iPhone|iPod/.test(navigator.userAgent)&&!window.MSStream,uP=typeof navigator<"u"&&/Mac OS X/.test(navigator.userAgent),Qt=typeof navigator<"u"&&/Android/.test(navigator.userAgent),Qu=typeof navigator<"u"&&/^(?!.*Seamonkey)(?=.*Firefox).*/i.test(navigator.userAgent),Zu=typeof navigator<"u"&&/AppleWebKit(?!.*Chrome)/i.test(navigator.userAgent),IQ=typeof navigator<"u"&&/Edge?\/(?:[0-6][0-9]|[0-7][0-8])(?:\.)/i.test(navigator.userAgent),DP=typeof navigator<"u"&&/Chrome/i.test(navigator.userAgent),kQ=typeof navigator<"u"&&/Chrome?\/(?:[0-7][0-5]|[0-6][0-9])(?:\.)/i.test(navigator.userAgent),NQ=Qt&&typeof navigator<"u"&&/Chrome?\/(?:[0-5]?\d)(?:\.)/i.test(navigator.userAgent),VQ=typeof navigator<"u"&&/^(?!.*Seamonkey)(?=.*Firefox\/(?:[0-7][0-9]|[0-8][0-6])(?:\.)).*/i.test(navigator.userAgent),LQ=typeof navigator<"u"&&/.*UCBrowser/.test(navigator.userAgent),$Q=typeof navigator<"u"&&/.*Wechat/.test(navigator.userAgent)&&!/.*MacWechat/.test(navigator.userAgent),hd=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",Io=(!kQ||!NQ)&&!IQ&&typeof globalThis<"u"&&globalThis.InputEvent&&typeof globalThis.InputEvent.prototype.getTargetRanges=="function",G2=new WeakMap,j2=new WeakMap,EP=new WeakMap,gd=new WeakMap,M2=new WeakMap,tl=new WeakMap,Ri=new WeakMap,vd=new WeakMap,Cd=new WeakMap,I2=new WeakMap,Ti=new WeakMap,Ai=new WeakMap,el=new WeakMap,k2=new WeakMap,_2=new WeakMap,Gr=new WeakMap,Gn=new WeakMap,Zt=new WeakMap,ko=new WeakMap,No=new WeakMap,PP=new WeakMap,cs=Symbol("placeholder"),TP=Symbol("mark-placeholder"),zQ=globalThis.Text,W2=e=>e&&e.ownerDocument&&e.ownerDocument.defaultView||null,HQ=e=>Vo(e)&&e.nodeType===8,Pr=e=>Vo(e)&&e.nodeType===1,Vo=e=>{var t=W2(e);return!!t&&e instanceof t.Node},N2=e=>{var t=e&&e.anchorNode&&W2(e.anchorNode);return!!t&&e instanceof t.Selection},AP=e=>Vo(e)&&e.nodeType===3,GQ=e=>e.clipboardData&&e.clipboardData.getData("text/plain")!==""&&e.clipboardData.types.length===1,jQ=e=>{var[t,r]=e;if(Pr(t)&&t.childNodes.length){var n=r===t.childNodes.length,o=n?r-1:r;for([t,o]=RP(t,o,n?"backward":"forward"),n=o<r;Pr(t)&&t.childNodes.length;){var a=n?t.childNodes.length-1:0;t=WQ(t,a,n?"backward":"forward")}r=n&&t.textContent!=null?t.textContent.length:0}return[t,r]},_Q=e=>{for(var t=e&&e.parentNode;t;){if(t.toString()==="[object ShadowRoot]")return!0;t=t.parentNode}return!1},RP=(e,t,r)=>{for(var{childNodes:n}=e,o=n[t],a=t,s=!1,u=!1;(HQ(o)||Pr(o)&&o.childNodes.length===0||Pr(o)&&o.getAttribute("contenteditable")==="false")&&!(s&&u);){if(a>=n.length){s=!0,a=t-1,r="backward";continue}if(a<0){u=!0,a=t+1,r="forward";continue}o=n[a],t=a,a+=r==="forward"?1:-1}return[o,t]},WQ=(e,t,r)=>{var[n]=RP(e,t,r);return n},FP=e=>{var t="";if(AP(e)&&e.nodeValue)return e.nodeValue;if(Pr(e)){for(var r of Array.from(e.childNodes))t+=FP(r);var n=getComputedStyle(e).getPropertyValue("display");(n==="block"||n==="list"||e.tagName==="BR")&&(t+=`
1824
+ `,Uh=(e,t,r)=>{let n=({groupLabel:o,groupOptions:a,disabled:s=!1})=>Wh("optgroup",{"data-testid":o,disabled:s,label:o,children:Uh(a)},o);return e.map(o=>{if(Object.prototype.hasOwnProperty.call(o,"groupLabel"))return n(o);let{label:a,value:s,disabled:u=!1}=o,l=(0,xi.isNonEmptyString)(r)?o[r]:s,c=(0,xi.isNonEmptyString)(t)?o[t]:a;return(0,xi.isBoolean)(l)&&(l=ur(l)),Wh("option",{disabled:u,value:l,children:c},`${ur(c)}--${ur(l)}`)})},zX=(e,t,r)=>(0,xi.isNotNil)(e)&&!r?Uh([{label:e,value:"",disabled:t}]):null,HX=e=>e?null:Wh(De,{size:"md",type:"caret-down"}),wi=NX(({ariaLabel:e,disabled:t=!1,forceState:r,fullWidth:n=!0,hasError:o=!1,labelName:a="label",multiple:s=!1,options:u,placeholder:l="Please select...",preventPlaceholderSelection:c=!1,required:p=!1,valueName:d="value",...h},g)=>aD($X,{disabled:t,forceState:r,fullWidth:n,children:[aD(jh,{ref:g,"aria-invalid":o?"true":"false","aria-label":e,disabled:t,forceState:r,hasError:o,multiple:s,required:p,...h,children:[zX(l,c,s),Uh(u,a,d)]}),HX(s)]}));wi.displayName="Select_VHS";import{jsx as sD}from"react/jsx-runtime";var Up=({disabled:e=!1,field:{name:t,value:r,onChange:n,onBlur:o},form:{errors:a},label:s,labelDescription:u,labelProps:l={},options:c,placeholder:p,onChangeCustom:d,...h})=>{let g=v=>(0,Wp.isNil)(v)?"":(0,Wp.isBoolean)(v)?ur(r):v;return sD(Jt,{disabled:e,error:a[t],label:s,labelDescription:u,labelProps:l,name:t,children:sD(wi,{"data-testid":`select-${t}`,disabled:e,name:t,onBlur:o,onChange:v=>{n(v),d&&d(v.target.value)},options:c,placeholder:p,value:g(r),...h})})};Up.displayName="FormConnectorSelect_VHS";i();i();var rs=U(Z());import{useEffect as GX}from"react";import{jsx as jX}from"react/jsx-runtime";var Kp=({field:{name:e,value:t,onChange:r},form:{setFieldValue:n}={},onChangeCustom:o,valueState:a="",...s})=>(GX(()=>{!a&&(0,rs.isNil)(t)||a!==t&&(0,rs.isNotUndefined)(n)&&n(e,a)},[n,e,a,t]),jX(ts,{"data-testid":`input-${e}`,name:e,onChange:u=>{r(u),(0,rs.isNotUndefined)(o)&&o(u.target.value)},type:"hidden",value:(0,rs.isNil)(t)?"":t,...s}));Kp.displayName="FormConnectorHidden_VHS";i();i();var YT=U(Z());import{useState as ure,useEffect as lre}from"react";import cre from"styled-components";i();i();import{useCallback as cg,useMemo as tre,useEffect as rre}from"react";import KT from"styled-components";i();var z2=U(fD()),xP=U(Yh()),wP=U(_D());import de,{createContext as Bi,useContext as fs,useRef as gr,useEffect as jn,useLayoutEffect as PQ,useState as Fi,memo as TQ,forwardRef as AQ,useCallback as ke,Component as RQ,useReducer as FQ,useMemo as dd}from"react";i();i();function WD(e){return typeof e=="object"&&e!=null&&e.nodeType===1}function UD(e,t){return(!t||e!=="hidden")&&e!=="visible"&&e!=="clip"}function Jh(e,t){if(e.clientHeight<e.scrollHeight||e.clientWidth<e.scrollWidth){var r=getComputedStyle(e,null);return UD(r.overflowY,t)||UD(r.overflowX,t)||function(n){var o=function(a){if(!a.ownerDocument||!a.ownerDocument.defaultView)return null;try{return a.ownerDocument.defaultView.frameElement}catch{return null}}(n);return!!o&&(o.clientHeight<n.scrollHeight||o.clientWidth<n.scrollWidth)}(e)}return!1}function Xp(e,t,r,n,o,a,s,u){return a<e&&s>t||a>e&&s<t?0:a<=e&&u<=r||s>=t&&u>=r?a-e-n:s>t&&u<r||a<e&&u>r?s-t+o:0}var Zh=function(e,t){var r=window,n=t.scrollMode,o=t.block,a=t.inline,s=t.boundary,u=t.skipOverflowHiddenElements,l=typeof s=="function"?s:function(xe){return xe!==s};if(!WD(e))throw new TypeError("Invalid target");for(var c,p,d=document.scrollingElement||document.documentElement,h=[],g=e;WD(g)&&l(g);){if((g=(p=(c=g).parentElement)==null?c.getRootNode().host||null:p)===d){h.push(g);break}g!=null&&g===document.body&&Jh(g)&&!Jh(document.documentElement)||g!=null&&Jh(g,u)&&h.push(g)}for(var v=r.visualViewport?r.visualViewport.width:innerWidth,m=r.visualViewport?r.visualViewport.height:innerHeight,b=window.scrollX||pageXOffset,y=window.scrollY||pageYOffset,x=e.getBoundingClientRect(),w=x.height,S=x.width,E=x.top,D=x.right,P=x.bottom,R=x.left,F=o==="start"||o==="nearest"?E:o==="end"?P:E+w/2,M=a==="center"?R+S/2:a==="end"?D:R,G=[],N=0;N<h.length;N++){var L=h[N],I=L.getBoundingClientRect(),V=I.height,Y=I.width,Q=I.top,re=I.right,H=I.bottom,le=I.left;if(n==="if-needed"&&E>=0&&R>=0&&P<=m&&D<=v&&E>=Q&&P<=H&&R>=le&&D<=re)return G;var ve=getComputedStyle(L),me=parseInt(ve.borderLeftWidth,10),Ge=parseInt(ve.borderTopWidth,10),A=parseInt(ve.borderRightWidth,10),_=parseInt(ve.borderBottomWidth,10),z=0,j=0,ue="offsetWidth"in L?L.offsetWidth-L.clientWidth-me-A:0,oe="offsetHeight"in L?L.offsetHeight-L.clientHeight-Ge-_:0,he="offsetWidth"in L?L.offsetWidth===0?0:Y/L.offsetWidth:0,Ce="offsetHeight"in L?L.offsetHeight===0?0:V/L.offsetHeight:0;if(d===L)z=o==="start"?F:o==="end"?F-m:o==="nearest"?Xp(y,y+m,m,Ge,_,y+F,y+F+w,w):F-m/2,j=a==="start"?M:a==="center"?M-v/2:a==="end"?M-v:Xp(b,b+v,v,me,A,b+M,b+M+S,S),z=Math.max(0,z+y),j=Math.max(0,j+b);else{z=o==="start"?F-Q-Ge:o==="end"?F-H+_+oe:o==="nearest"?Xp(Q,H,V,Ge,_+oe,F,F+w,w):F-(Q+V/2)+oe/2,j=a==="start"?M-le-me:a==="center"?M-(le+Y/2)+ue/2:a==="end"?M-re+A+ue:Xp(le,re,Y,me,A+ue,M,M+S,S);var Se=L.scrollLeft,Ee=L.scrollTop;F+=Ee-(z=Math.max(0,Math.min(Ee+z/Ce,L.scrollHeight-V/Ce+oe))),M+=Se-(j=Math.max(0,Math.min(Se+j/he,L.scrollWidth-Y/he+ue)))}G.push({el:L,top:z,left:j})}return G};function KD(e){return e===Object(e)&&Object.keys(e).length!==0}function $Y(e,t){t===void 0&&(t="auto");var r="scrollBehavior"in document.body.style;e.forEach(function(n){var o=n.el,a=n.top,s=n.left;o.scroll&&r?o.scroll({top:a,left:s,behavior:t}):(o.scrollTop=a,o.scrollLeft=s)})}function zY(e){return e===!1?{block:"end",inline:"nearest"}:KD(e)?e:{block:"start",inline:"nearest"}}function HY(e,t){var r=e.isConnected||e.ownerDocument.documentElement.contains(e);if(KD(t)&&typeof t.behavior=="function")return t.behavior(r?Zh(e,t):[]);if(r){var n=zY(t);return $Y(Zh(e,n),n.behavior)}}var qD=HY;i();i();function XD(e){return Object.prototype.toString.call(e)==="[object Object]"}function Xe(e){var t,r;return XD(e)===!1?!1:(t=e.constructor,t===void 0?!0:(r=t.prototype,!(XD(r)===!1||r.hasOwnProperty("isPrototypeOf")===!1)))}i();function zr(e){for(var t=arguments.length,r=Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];if(0)var o,a;throw Error("[Immer] minified error nr: "+e+(r.length?" "+r.map(function(s){return"'"+s+"'"}).join(","):"")+". Find the full error at: https://bit.ly/3cXEKWf")}function Mo(e){return!!e&&!!e[mr]}function Di(e){var t;return!!e&&(function(r){if(!r||typeof r!="object")return!1;var n=Object.getPrototypeOf(r);if(n===null)return!0;var o=Object.hasOwnProperty.call(n,"constructor")&&n.constructor;return o===Object||typeof o=="function"&&Function.toString.call(o)===XY}(e)||Array.isArray(e)||!!e[nE]||!!(!((t=e.constructor)===null||t===void 0)&&t[nE])||u2(e)||l2(e))}function Wu(e,t,r){r===void 0&&(r=!1),ns(e)===0?(r?Object.keys:m2)(e).forEach(function(n){r&&typeof n=="symbol"||t(n,e[n],e)}):e.forEach(function(n,o){return t(o,n,e)})}function ns(e){var t=e[mr];return t?t.i>3?t.i-4:t.i:Array.isArray(e)?1:u2(e)?2:l2(e)?3:0}function n2(e,t){return ns(e)===2?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function GY(e,t){return ns(e)===2?e.get(t):e[t]}function oE(e,t,r){var n=ns(e);n===2?e.set(t,r):n===3?e.add(r):e[t]=r}function jY(e,t){return e===t?e!==0||1/e==1/t:e!=e&&t!=t}function u2(e){return KY&&e instanceof Map}function l2(e){return qY&&e instanceof Set}function Si(e){return e.o||e.t}function c2(e){if(Array.isArray(e))return Array.prototype.slice.call(e);var t=YY(e);delete t[mr];for(var r=m2(t),n=0;n<r.length;n++){var o=r[n],a=t[o];a.writable===!1&&(a.writable=!0,a.configurable=!0),(a.get||a.set)&&(t[o]={configurable:!0,writable:!0,enumerable:a.enumerable,value:e[o]})}return Object.create(Object.getPrototypeOf(e),t)}function f2(e,t){return t===void 0&&(t=!1),p2(e)||Mo(e)||!Di(e)||(ns(e)>1&&(e.set=e.add=e.clear=e.delete=_Y),Object.freeze(e),t&&Wu(e,function(r,n){return f2(n,!0)},!0)),e}function _Y(){zr(2)}function p2(e){return e==null||typeof e!="object"||Object.isFrozen(e)}function on(e){var t=JY[e];return t||zr(18,e),t}function YD(){return Uu}function Qh(e,t){t&&(on("Patches"),e.u=[],e.s=[],e.v=t)}function Yp(e){o2(e),e.p.forEach(WY),e.p=null}function o2(e){e===Uu&&(Uu=e.l)}function JD(e){return Uu={p:[],l:Uu,h:e,m:!0,_:0}}function WY(e){var t=e[mr];t.i===0||t.i===1?t.j():t.g=!0}function e2(e,t){t._=t.p.length;var r=t.p[0],n=e!==void 0&&e!==r;return t.h.O||on("ES5").S(t,e,n),n?(r[mr].P&&(Yp(t),zr(4)),Di(e)&&(e=Jp(t,e),t.l||Zp(t,e)),t.u&&on("Patches").M(r[mr].t,e,t.u,t.s)):e=Jp(t,r,[]),Yp(t),t.u&&t.v(t.u,t.s),e!==iE?e:void 0}function Jp(e,t,r){if(p2(t))return t;var n=t[mr];if(!n)return Wu(t,function(u,l){return ZD(e,n,t,u,l,r)},!0),t;if(n.A!==e)return t;if(!n.P)return Zp(e,n.t,!0),n.t;if(!n.I){n.I=!0,n.A._--;var o=n.i===4||n.i===5?n.o=c2(n.k):n.o,a=o,s=!1;n.i===3&&(a=new Set(o),o.clear(),s=!0),Wu(a,function(u,l){return ZD(e,n,o,u,l,r,s)}),Zp(e,o,!1),r&&e.u&&on("Patches").N(n,r,e.u,e.s)}return n.o}function ZD(e,t,r,n,o,a,s){if(Mo(o)){var u=Jp(e,o,a&&t&&t.i!==3&&!n2(t.R,n)?a.concat(n):void 0);if(oE(r,n,u),!Mo(u))return;e.m=!1}else s&&r.add(o);if(Di(o)&&!p2(o)){if(!e.h.D&&e._<1)return;Jp(e,o),t&&t.A.l||Zp(e,o)}}function Zp(e,t,r){r===void 0&&(r=!1),!e.l&&e.h.D&&e.m&&f2(t,r)}function t2(e,t){var r=e[mr];return(r?Si(r):e)[t]}function QD(e,t){if(t in e)for(var r=Object.getPrototypeOf(e);r;){var n=Object.getOwnPropertyDescriptor(r,t);if(n)return n;r=Object.getPrototypeOf(r)}}function i2(e){e.P||(e.P=!0,e.l&&i2(e.l))}function r2(e){e.o||(e.o=c2(e.t))}function a2(e,t,r){var n=u2(t)?on("MapSet").F(t,r):l2(t)?on("MapSet").T(t,r):e.O?function(o,a){var s=Array.isArray(o),u={i:s?1:0,A:a?a.A:YD(),P:!1,I:!1,R:{},l:a,t:o,k:null,o:null,j:null,C:!1},l=u,c=s2;s&&(l=[u],c=_u);var p=Proxy.revocable(l,c),d=p.revoke,h=p.proxy;return u.k=h,u.j=d,h}(t,r):on("ES5").J(t,r);return(r?r.A:YD()).p.push(n),n}function UY(e){return Mo(e)||zr(22,e),function t(r){if(!Di(r))return r;var n,o=r[mr],a=ns(r);if(o){if(!o.P&&(o.i<4||!on("ES5").K(o)))return o.t;o.I=!0,n=eE(r,a),o.I=!1}else n=eE(r,a);return Wu(n,function(s,u){o&&GY(o.t,s)===u||oE(n,s,t(u))}),a===3?new Set(n):n}(e)}function eE(e,t){switch(t){case 2:return new Map(e);case 3:return Array.from(e)}return c2(e)}var tE,Uu,d2=typeof Symbol<"u"&&typeof Symbol("x")=="symbol",KY=typeof Map<"u",qY=typeof Set<"u",rE=typeof Proxy<"u"&&Proxy.revocable!==void 0&&typeof Reflect<"u",iE=d2?Symbol.for("immer-nothing"):((tE={})["immer-nothing"]=!0,tE),nE=d2?Symbol.for("immer-draftable"):"__$immer_draftable",mr=d2?Symbol.for("immer-state"):"__$immer_state";var XY=""+Object.prototype.constructor,m2=typeof Reflect<"u"&&Reflect.ownKeys?Reflect.ownKeys:Object.getOwnPropertySymbols!==void 0?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:Object.getOwnPropertyNames,YY=Object.getOwnPropertyDescriptors||function(e){var t={};return m2(e).forEach(function(r){t[r]=Object.getOwnPropertyDescriptor(e,r)}),t},JY={},s2={get:function(e,t){if(t===mr)return e;var r=Si(e);if(!n2(r,t))return function(o,a,s){var u,l=QD(a,s);return l?"value"in l?l.value:(u=l.get)===null||u===void 0?void 0:u.call(o.k):void 0}(e,r,t);var n=r[t];return e.I||!Di(n)?n:n===t2(e.t,t)?(r2(e),e.o[t]=a2(e.A.h,n,e)):n},has:function(e,t){return t in Si(e)},ownKeys:function(e){return Reflect.ownKeys(Si(e))},set:function(e,t,r){var n=QD(Si(e),t);if(n?.set)return n.set.call(e.k,r),!0;if(!e.P){var o=t2(Si(e),t),a=o?.[mr];if(a&&a.t===r)return e.o[t]=r,e.R[t]=!1,!0;if(jY(r,o)&&(r!==void 0||n2(e.t,t)))return!0;r2(e),i2(e)}return e.o[t]===r&&(r!==void 0||t in e.o)||Number.isNaN(r)&&Number.isNaN(e.o[t])||(e.o[t]=r,e.R[t]=!0),!0},deleteProperty:function(e,t){return t2(e.t,t)!==void 0||t in e.t?(e.R[t]=!1,r2(e),i2(e)):delete e.R[t],e.o&&delete e.o[t],!0},getOwnPropertyDescriptor:function(e,t){var r=Si(e),n=Reflect.getOwnPropertyDescriptor(r,t);return n&&{writable:!0,configurable:e.i!==1||t!=="length",enumerable:n.enumerable,value:r[t]}},defineProperty:function(){zr(11)},getPrototypeOf:function(e){return Object.getPrototypeOf(e.t)},setPrototypeOf:function(){zr(12)}},_u={};Wu(s2,function(e,t){_u[e]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}}),_u.deleteProperty=function(e,t){return _u.set.call(this,e,t,void 0)},_u.set=function(e,t,r){return s2.set.call(this,e[0],t,r,e[0])};var ZY=function(){function e(r){var n=this;this.O=rE,this.D=!0,this.produce=function(o,a,s){if(typeof o=="function"&&typeof a!="function"){var u=a;a=o;var l=n;return function(m){var b=this;m===void 0&&(m=u);for(var y=arguments.length,x=Array(y>1?y-1:0),w=1;w<y;w++)x[w-1]=arguments[w];return l.produce(m,function(S){var E;return(E=a).call.apply(E,[b,S].concat(x))})}}var c;if(typeof a!="function"&&zr(6),s!==void 0&&typeof s!="function"&&zr(7),Di(o)){var p=JD(n),d=a2(n,o,void 0),h=!0;try{c=a(d),h=!1}finally{h?Yp(p):o2(p)}return typeof Promise<"u"&&c instanceof Promise?c.then(function(m){return Qh(p,s),e2(m,p)},function(m){throw Yp(p),m}):(Qh(p,s),e2(c,p))}if(!o||typeof o!="object"){if((c=a(o))===void 0&&(c=o),c===iE&&(c=void 0),n.D&&f2(c,!0),s){var g=[],v=[];on("Patches").M(o,c,g,v),s(g,v)}return c}zr(21,o)},this.produceWithPatches=function(o,a){if(typeof o=="function")return function(c){for(var p=arguments.length,d=Array(p>1?p-1:0),h=1;h<p;h++)d[h-1]=arguments[h];return n.produceWithPatches(c,function(g){return o.apply(void 0,[g].concat(d))})};var s,u,l=n.produce(o,a,function(c,p){s=c,u=p});return typeof Promise<"u"&&l instanceof Promise?l.then(function(c){return[c,s,u]}):[l,s,u]},typeof r?.useProxies=="boolean"&&this.setUseProxies(r.useProxies),typeof r?.autoFreeze=="boolean"&&this.setAutoFreeze(r.autoFreeze)}var t=e.prototype;return t.createDraft=function(r){Di(r)||zr(8),Mo(r)&&(r=UY(r));var n=JD(this),o=a2(this,r,void 0);return o[mr].C=!0,o2(n),o},t.finishDraft=function(r,n){var o=r&&r[mr],a=o.A;return Qh(a,n),e2(void 0,a)},t.setAutoFreeze=function(r){this.D=r},t.setUseProxies=function(r){r&&!rE&&zr(20),this.O=r},t.applyPatches=function(r,n){var o;for(o=n.length-1;o>=0;o--){var a=n[o];if(a.path.length===0&&a.op==="replace"){r=a.value;break}}o>-1&&(n=n.slice(o+1));var s=on("Patches").$;return Mo(r)?s(r,n):this.produce(r,function(u){return s(u,n)})},e}(),hr=new ZY,Qp=hr.produce,tZe=hr.produceWithPatches.bind(hr),rZe=hr.setAutoFreeze.bind(hr),nZe=hr.setUseProxies.bind(hr),oZe=hr.applyPatches.bind(hr),h2=hr.createDraft.bind(hr),g2=hr.finishDraft.bind(hr);var QY={transform(e,t){var{current:r,affinity:n}=e;if(r!=null){var o=T.transform(r,t,{affinity:n});e.current=o,o==null&&e.unref()}}},eJ={transform(e,t){var{current:r,affinity:n}=e;if(r!=null){var o=ge.transform(r,t,{affinity:n});e.current=o,o==null&&e.unref()}}},tJ={transform(e,t){var{current:r,affinity:n}=e;if(r!=null){var o=O.transform(r,t,{affinity:n});e.current=o,o==null&&e.unref()}}},td=new WeakMap,rd=new WeakMap,qu=new WeakMap,VE=new WeakMap,aE=new WeakMap,sE=new WeakMap,uE=new WeakMap,T={ancestors(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{reverse:r=!1}=t,n=T.levels(e,t);return r?n=n.slice(1):n=n.slice(0,-1),n},common(e,t){for(var r=[],n=0;n<e.length&&n<t.length;n++){var o=e[n],a=t[n];if(o!==a)break;r.push(o)}return r},compare(e,t){for(var r=Math.min(e.length,t.length),n=0;n<r;n++){if(e[n]<t[n])return-1;if(e[n]>t[n])return 1}return 0},endsAfter(e,t){var r=e.length-1,n=e.slice(0,r),o=t.slice(0,r),a=e[r],s=t[r];return T.equals(n,o)&&a>s},endsAt(e,t){var r=e.length,n=e.slice(0,r),o=t.slice(0,r);return T.equals(n,o)},endsBefore(e,t){var r=e.length-1,n=e.slice(0,r),o=t.slice(0,r),a=e[r],s=t[r];return T.equals(n,o)&&a<s},equals(e,t){return e.length===t.length&&e.every((r,n)=>r===t[n])},hasPrevious(e){return e[e.length-1]>0},isAfter(e,t){return T.compare(e,t)===1},isAncestor(e,t){return e.length<t.length&&T.compare(e,t)===0},isBefore(e,t){return T.compare(e,t)===-1},isChild(e,t){return e.length===t.length+1&&T.compare(e,t)===0},isCommon(e,t){return e.length<=t.length&&T.compare(e,t)===0},isDescendant(e,t){return e.length>t.length&&T.compare(e,t)===0},isParent(e,t){return e.length+1===t.length&&T.compare(e,t)===0},isPath(e){return Array.isArray(e)&&(e.length===0||typeof e[0]=="number")},isSibling(e,t){if(e.length!==t.length)return!1;var r=e.slice(0,-1),n=t.slice(0,-1),o=e[e.length-1],a=t[t.length-1];return o!==a&&T.equals(r,n)},levels(e){for(var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{reverse:r=!1}=t,n=[],o=0;o<=e.length;o++)n.push(e.slice(0,o));return r&&n.reverse(),n},next(e){if(e.length===0)throw new Error("Cannot get the next path of a root path [".concat(e,"], because it has no next index."));var t=e[e.length-1];return e.slice(0,-1).concat(t+1)},operationCanTransformPath(e){switch(e.type){case"insert_node":case"remove_node":case"merge_node":case"split_node":case"move_node":return!0;default:return!1}},parent(e){if(e.length===0)throw new Error("Cannot get the parent path of the root path [".concat(e,"]."));return e.slice(0,-1)},previous(e){if(e.length===0)throw new Error("Cannot get the previous path of a root path [".concat(e,"], because it has no previous index."));var t=e[e.length-1];if(t<=0)throw new Error("Cannot get the previous path of a first child path [".concat(e,"] because it would result in a negative index."));return e.slice(0,-1).concat(t-1)},relative(e,t){if(!T.isAncestor(t,e)&&!T.equals(e,t))throw new Error("Cannot get the relative path of [".concat(e,"] inside ancestor [").concat(t,"], because it is not above or equal to the path."));return e.slice(t.length)},transform(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};if(!e)return null;var n=[...e],{affinity:o="forward"}=r;if(e.length===0)return n;switch(t.type){case"insert_node":{var{path:a}=t;(T.equals(a,n)||T.endsBefore(a,n)||T.isAncestor(a,n))&&(n[a.length-1]+=1);break}case"remove_node":{var{path:s}=t;if(T.equals(s,n)||T.isAncestor(s,n))return null;T.endsBefore(s,n)&&(n[s.length-1]-=1);break}case"merge_node":{var{path:u,position:l}=t;T.equals(u,n)||T.endsBefore(u,n)?n[u.length-1]-=1:T.isAncestor(u,n)&&(n[u.length-1]-=1,n[u.length]+=l);break}case"split_node":{var{path:c,position:p}=t;if(T.equals(c,n)){if(o==="forward")n[n.length-1]+=1;else if(o!=="backward")return null}else T.endsBefore(c,n)?n[c.length-1]+=1:T.isAncestor(c,n)&&e[c.length]>=p&&(n[c.length-1]+=1,n[c.length]-=p);break}case"move_node":{var{path:d,newPath:h}=t;if(T.equals(d,h))return n;if(T.isAncestor(d,n)||T.equals(d,n)){var g=h.slice();return T.endsBefore(d,h)&&d.length<h.length&&(g[d.length-1]-=1),g.concat(n.slice(d.length))}else T.isSibling(d,h)&&(T.isAncestor(h,n)||T.equals(h,n))?T.endsBefore(d,n)?n[d.length-1]-=1:n[d.length-1]+=1:T.endsBefore(h,n)||T.equals(h,n)||T.isAncestor(h,n)?(T.endsBefore(d,n)&&(n[d.length-1]-=1),n[h.length-1]+=1):T.endsBefore(d,n)&&(T.equals(h,n)&&(n[h.length-1]+=1),n[d.length-1]-=1);break}}return n}};function Vt(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function lE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function Ku(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?lE(Object(r),!0).forEach(function(n){Vt(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):lE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var rJ=(e,t,r)=>{switch(r.type){case"insert_node":{var{path:n,node:o}=r,a=W.parent(e,n),s=n[n.length-1];if(s>a.children.length)throw new Error('Cannot apply an "insert_node" operation at path ['.concat(n,"] because the destination is past the end of the node."));if(a.children.splice(s,0,o),t)for(var[u,l]of O.points(t))t[l]=ge.transform(u,r);break}case"insert_text":{var{path:c,offset:p,text:d}=r;if(d.length===0)break;var h=W.leaf(e,c),g=h.text.slice(0,p),v=h.text.slice(p);if(h.text=g+d+v,t)for(var[m,b]of O.points(t))t[b]=ge.transform(m,r);break}case"merge_node":{var{path:y}=r,x=W.get(e,y),w=T.previous(y),S=W.get(e,w),E=W.parent(e,y),D=y[y.length-1];if(J.isText(x)&&J.isText(S))S.text+=x.text;else if(!J.isText(x)&&!J.isText(S))S.children.push(...x.children);else throw new Error('Cannot apply a "merge_node" operation at path ['.concat(y,"] to nodes of different interfaces: ").concat(it.stringify(x)," ").concat(it.stringify(S)));if(E.children.splice(D,1),t)for(var[P,R]of O.points(t))t[R]=ge.transform(P,r);break}case"move_node":{var{path:F,newPath:M}=r;if(T.isAncestor(F,M))throw new Error("Cannot move a path [".concat(F,"] to new path [").concat(M,"] because the destination is inside itself."));var G=W.get(e,F),N=W.parent(e,F),L=F[F.length-1];N.children.splice(L,1);var I=T.transform(F,r),V=W.get(e,T.parent(I)),Y=I[I.length-1];if(V.children.splice(Y,0,G),t)for(var[Q,re]of O.points(t))t[re]=ge.transform(Q,r);break}case"remove_node":{var{path:H}=r,le=H[H.length-1],ve=W.parent(e,H);if(ve.children.splice(le,1),t)for(var[me,Ge]of O.points(t)){var A=ge.transform(me,r);if(t!=null&&A!=null)t[Ge]=A;else{var _=void 0,z=void 0;for(var[j,ue]of W.texts(e))if(T.compare(ue,H)===-1)_=[j,ue];else{z=[j,ue];break}var oe=!1;_&&z&&(T.equals(z[1],H)?oe=!T.hasPrevious(z[1]):oe=T.common(_[1],H).length<T.common(z[1],H).length),_&&!oe?(me.path=_[1],me.offset=_[0].text.length):z?(me.path=z[1],me.offset=0):t=null}}break}case"remove_text":{var{path:he,offset:Ce,text:Se}=r;if(Se.length===0)break;var Ee=W.leaf(e,he),xe=Ee.text.slice(0,Ce),gt=Ee.text.slice(Ce+Se.length);if(Ee.text=xe+gt,t)for(var[vt,je]of O.points(t))t[je]=ge.transform(vt,r);break}case"set_node":{var{path:or,properties:Ht,newProperties:St}=r;if(or.length===0)throw new Error("Cannot set properties on the root node!");var ir=W.get(e,or);for(var B in St){if(B==="children"||B==="text")throw new Error('Cannot set the "'.concat(B,'" property of nodes!'));var X=St[B];X==null?delete ir[B]:ir[B]=X}for(var te in Ht)St.hasOwnProperty(te)||delete ir[te];break}case"set_selection":{var{newProperties:q}=r;if(q==null)t=q;else{if(t==null){if(!O.isRange(q))throw new Error('Cannot apply an incomplete "set_selection" operation properties '.concat(it.stringify(q)," when there is no current selection."));t=Ku({},q)}for(var se in q){var we=q[se];if(we==null){if(se==="anchor"||se==="focus")throw new Error('Cannot remove the "'.concat(se,'" selection property'));delete t[se]}else t[se]=we}}break}case"split_node":{var{path:Pe,position:yt,properties:eo}=r;if(Pe.length===0)throw new Error('Cannot apply a "split_node" operation at path ['.concat(Pe,"] because the root node cannot be split."));var Ir=W.get(e,Pe),N1=W.parent(e,Pe),W5=Pe[Pe.length-1],Yi;if(J.isText(Ir)){var V1=Ir.text.slice(0,yt),kO=Ir.text.slice(yt);Ir.text=V1,Yi=Ku(Ku({},eo),{},{text:kO})}else{var NO=Ir.children.slice(0,yt),VO=Ir.children.slice(yt);Ir.children=NO,Yi=Ku(Ku({},eo),{},{children:VO})}if(N1.children.splice(W5+1,0,Yi),t)for(var[LO,$O]of O.points(t))t[$O]=ge.transform(LO,r);break}}return t},nJ={transform(e,t){e.children=h2(e.children);var r=e.selection&&h2(e.selection);try{r=rJ(e,r,t)}finally{e.children=g2(e.children),r?e.selection=Mo(r)?g2(r):r:e.selection=null}}},oJ={insertNodes(e,t,r){e.insertNodes(t,r)},liftNodes(e,t){e.liftNodes(t)},mergeNodes(e,t){e.mergeNodes(t)},moveNodes(e,t){e.moveNodes(t)},removeNodes(e,t){e.removeNodes(t)},setNodes(e,t,r){e.setNodes(t,r)},splitNodes(e,t){e.splitNodes(t)},unsetNodes(e,t,r){e.unsetNodes(t,r)},unwrapNodes(e,t){e.unwrapNodes(t)},wrapNodes(e,t,r){e.wrapNodes(t,r)}},iJ={collapse(e,t){e.collapse(t)},deselect(e){e.deselect()},move(e,t){e.move(t)},select(e,t){e.select(t)},setPoint(e,t,r){e.setPoint(t,r)},setSelection(e,t){e.setSelection(t)}},LE=(e,t)=>{for(var r in e){var n=e[r],o=t[r];if(Xe(n)&&Xe(o)){if(!LE(n,o))return!1}else if(Array.isArray(n)&&Array.isArray(o)){if(n.length!==o.length)return!1;for(var a=0;a<n.length;a++)if(n[a]!==o[a])return!1}else if(n!==o)return!1}for(var s in t)if(e[s]===void 0&&t[s]!==void 0)return!1;return!0};function aJ(e,t){if(e==null)return{};var r={},n=Object.keys(e),o,a;for(a=0;a<n.length;a++)o=n[a],!(t.indexOf(o)>=0)&&(r[o]=e[o]);return r}function Hn(e,t){if(e==null)return{};var r=aJ(e,t),n,o;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(o=0;o<a.length;o++)n=a[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}var sJ=["anchor","focus"];function cE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function uJ(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?cE(Object(r),!0).forEach(function(n){Vt(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):cE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var O={edges(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{reverse:r=!1}=t,{anchor:n,focus:o}=e;return O.isBackward(e)===r?[n,o]:[o,n]},end(e){var[,t]=O.edges(e);return t},equals(e,t){return ge.equals(e.anchor,t.anchor)&&ge.equals(e.focus,t.focus)},includes(e,t){if(O.isRange(t)){if(O.includes(e,t.anchor)||O.includes(e,t.focus))return!0;var[r,n]=O.edges(e),[o,a]=O.edges(t);return ge.isBefore(r,o)&&ge.isAfter(n,a)}var[s,u]=O.edges(e),l=!1,c=!1;return ge.isPoint(t)?(l=ge.compare(t,s)>=0,c=ge.compare(t,u)<=0):(l=T.compare(t,s.path)>=0,c=T.compare(t,u.path)<=0),l&&c},intersection(e,t){var r=Hn(e,sJ),[n,o]=O.edges(e),[a,s]=O.edges(t),u=ge.isBefore(n,a)?a:n,l=ge.isBefore(o,s)?o:s;return ge.isBefore(l,u)?null:uJ({anchor:u,focus:l},r)},isBackward(e){var{anchor:t,focus:r}=e;return ge.isAfter(t,r)},isCollapsed(e){var{anchor:t,focus:r}=e;return ge.equals(t,r)},isExpanded(e){return!O.isCollapsed(e)},isForward(e){return!O.isBackward(e)},isRange(e){return Xe(e)&&ge.isPoint(e.anchor)&&ge.isPoint(e.focus)},*points(e){yield[e.anchor,"anchor"],yield[e.focus,"focus"]},start(e){var[t]=O.edges(e);return t},transform(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return Qp(e,n=>{if(n===null)return null;var{affinity:o="inward"}=r,a,s;if(o==="inward"){var u=O.isCollapsed(n);O.isForward(n)?(a="forward",s=u?a:"backward"):(a="backward",s=u?a:"forward")}else o==="outward"?O.isForward(n)?(a="backward",s="forward"):(a="forward",s="backward"):(a=o,s=o);var l=ge.transform(n.anchor,t,{affinity:a}),c=ge.transform(n.focus,t,{affinity:s});if(!l||!c)return null;n.anchor=l,n.focus=c})}},fE=e=>Xe(e)&&W.isNodeList(e.children)&&!C.isEditor(e),K={isAncestor(e){return Xe(e)&&W.isNodeList(e.children)},isElement:fE,isElementList(e){return Array.isArray(e)&&e.every(t=>K.isElement(t))},isElementProps(e){return e.children!==void 0},isElementType:function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"type";return fE(t)&&t[n]===r},matches(e,t){for(var r in t)if(r!=="children"&&e[r]!==t[r])return!1;return!0}},lJ=["children"],cJ=["text"],pE=new WeakMap,W={ancestor(e,t){var r=W.get(e,t);if(J.isText(r))throw new Error("Cannot get the ancestor node at path [".concat(t,"] because it refers to a text node instead: ").concat(it.stringify(r)));return r},*ancestors(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};for(var n of T.ancestors(t,r)){var o=W.ancestor(e,n),a=[o,n];yield a}},child(e,t){if(J.isText(e))throw new Error("Cannot get the child of a text node: ".concat(it.stringify(e)));var r=e.children[t];if(r==null)throw new Error("Cannot get child at index `".concat(t,"` in node: ").concat(it.stringify(e)));return r},*children(e,t){for(var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{reverse:n=!1}=r,o=W.ancestor(e,t),{children:a}=o,s=n?a.length-1:0;n?s>=0:s<a.length;){var u=W.child(o,s),l=t.concat(s);yield[u,l],s=n?s-1:s+1}},common(e,t,r){var n=T.common(t,r),o=W.get(e,n);return[o,n]},descendant(e,t){var r=W.get(e,t);if(C.isEditor(r))throw new Error("Cannot get the descendant node at path [".concat(t,"] because it refers to the root editor node instead: ").concat(it.stringify(r)));return r},*descendants(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};for(var[r,n]of W.nodes(e,t))n.length!==0&&(yield[r,n])},*elements(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};for(var[r,n]of W.nodes(e,t))K.isElement(r)&&(yield[r,n])},extractProps(e){if(K.isAncestor(e)){var t=Hn(e,lJ);return t}else{var t=Hn(e,cJ);return t}},first(e,t){for(var r=t.slice(),n=W.get(e,r);n&&!(J.isText(n)||n.children.length===0);)n=n.children[0],r.push(0);return[n,r]},fragment(e,t){if(J.isText(e))throw new Error("Cannot get a fragment starting from a root text node: ".concat(it.stringify(e)));var r=Qp({children:e.children},n=>{var[o,a]=O.edges(t),s=W.nodes(n,{reverse:!0,pass:h=>{var[,g]=h;return!O.includes(t,g)}});for(var[,u]of s){if(!O.includes(t,u)){var l=W.parent(n,u),c=u[u.length-1];l.children.splice(c,1)}if(T.equals(u,a.path)){var p=W.leaf(n,u);p.text=p.text.slice(0,a.offset)}if(T.equals(u,o.path)){var d=W.leaf(n,u);d.text=d.text.slice(o.offset)}}C.isEditor(n)&&(n.selection=null)});return r.children},get(e,t){for(var r=e,n=0;n<t.length;n++){var o=t[n];if(J.isText(r)||!r.children[o])throw new Error("Cannot find a descendant at path [".concat(t,"] in node: ").concat(it.stringify(e)));r=r.children[o]}return r},has(e,t){for(var r=e,n=0;n<t.length;n++){var o=t[n];if(J.isText(r)||!r.children[o])return!1;r=r.children[o]}return!0},isNode(e){return J.isText(e)||K.isElement(e)||C.isEditor(e)},isNodeList(e){if(!Array.isArray(e))return!1;var t=pE.get(e);if(t!==void 0)return t;var r=e.every(n=>W.isNode(n));return pE.set(e,r),r},last(e,t){for(var r=t.slice(),n=W.get(e,r);n&&!(J.isText(n)||n.children.length===0);){var o=n.children.length-1;n=n.children[o],r.push(o)}return[n,r]},leaf(e,t){var r=W.get(e,t);if(!J.isText(r))throw new Error("Cannot get the leaf node at path [".concat(t,"] because it refers to a non-leaf node: ").concat(it.stringify(r)));return r},*levels(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};for(var n of T.levels(t,r)){var o=W.get(e,n);yield[o,n]}},matches(e,t){return K.isElement(e)&&K.isElementProps(t)&&K.matches(e,t)||J.isText(e)&&J.isTextProps(t)&&J.matches(e,t)},*nodes(e){for(var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{pass:r,reverse:n=!1}=t,{from:o=[],to:a}=t,s=new Set,u=[],l=e;!(a&&(n?T.isBefore(u,a):T.isAfter(u,a)));){if(s.has(l)||(yield[l,u]),!s.has(l)&&!J.isText(l)&&l.children.length!==0&&(r==null||r([l,u])===!1)){s.add(l);var c=n?l.children.length-1:0;T.isAncestor(u,o)&&(c=o[u.length]),u=u.concat(c),l=W.get(e,u);continue}if(u.length===0)break;if(!n){var p=T.next(u);if(W.has(e,p)){u=p,l=W.get(e,u);continue}}if(n&&u[u.length-1]!==0){var d=T.previous(u);u=d,l=W.get(e,u);continue}u=T.parent(u),l=W.get(e,u),s.add(l)}},parent(e,t){var r=T.parent(t),n=W.get(e,r);if(J.isText(n))throw new Error("Cannot get the parent of path [".concat(t,"] because it does not exist in the root."));return n},string(e){return J.isText(e)?e.text:e.children.map(W.string).join("")},*texts(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};for(var[r,n]of W.nodes(e,t))J.isText(r)&&(yield[r,n])}};function dE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function ze(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?dE(Object(r),!0).forEach(function(n){Vt(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):dE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var zn={isNodeOperation(e){return zn.isOperation(e)&&e.type.endsWith("_node")},isOperation(e){if(!Xe(e))return!1;switch(e.type){case"insert_node":return T.isPath(e.path)&&W.isNode(e.node);case"insert_text":return typeof e.offset=="number"&&typeof e.text=="string"&&T.isPath(e.path);case"merge_node":return typeof e.position=="number"&&T.isPath(e.path)&&Xe(e.properties);case"move_node":return T.isPath(e.path)&&T.isPath(e.newPath);case"remove_node":return T.isPath(e.path)&&W.isNode(e.node);case"remove_text":return typeof e.offset=="number"&&typeof e.text=="string"&&T.isPath(e.path);case"set_node":return T.isPath(e.path)&&Xe(e.properties)&&Xe(e.newProperties);case"set_selection":return e.properties===null&&O.isRange(e.newProperties)||e.newProperties===null&&O.isRange(e.properties)||Xe(e.properties)&&Xe(e.newProperties);case"split_node":return T.isPath(e.path)&&typeof e.position=="number"&&Xe(e.properties);default:return!1}},isOperationList(e){return Array.isArray(e)&&e.every(t=>zn.isOperation(t))},isSelectionOperation(e){return zn.isOperation(e)&&e.type.endsWith("_selection")},isTextOperation(e){return zn.isOperation(e)&&e.type.endsWith("_text")},inverse(e){switch(e.type){case"insert_node":return ze(ze({},e),{},{type:"remove_node"});case"insert_text":return ze(ze({},e),{},{type:"remove_text"});case"merge_node":return ze(ze({},e),{},{type:"split_node",path:T.previous(e.path)});case"move_node":{var{newPath:t,path:r}=e;if(T.equals(t,r))return e;if(T.isSibling(r,t))return ze(ze({},e),{},{path:t,newPath:r});var n=T.transform(r,e),o=T.transform(T.next(r),e);return ze(ze({},e),{},{path:n,newPath:o})}case"remove_node":return ze(ze({},e),{},{type:"insert_node"});case"remove_text":return ze(ze({},e),{},{type:"insert_text"});case"set_node":{var{properties:a,newProperties:s}=e;return ze(ze({},e),{},{properties:s,newProperties:a})}case"set_selection":{var{properties:u,newProperties:l}=e;return u==null?ze(ze({},e),{},{properties:l,newProperties:null}):l==null?ze(ze({},e),{},{properties:null,newProperties:u}):ze(ze({},e),{},{properties:l,newProperties:u})}case"split_node":return ze(ze({},e),{},{type:"merge_node",path:T.next(e.path)})}}},mE=new WeakMap,fJ=e=>{var t=mE.get(e);if(t!==void 0)return t;if(!Xe(e))return!1;var r=typeof e.addMark=="function"&&typeof e.apply=="function"&&typeof e.deleteFragment=="function"&&typeof e.insertBreak=="function"&&typeof e.insertSoftBreak=="function"&&typeof e.insertFragment=="function"&&typeof e.insertNode=="function"&&typeof e.insertText=="function"&&typeof e.isElementReadOnly=="function"&&typeof e.isInline=="function"&&typeof e.isSelectable=="function"&&typeof e.isVoid=="function"&&typeof e.normalizeNode=="function"&&typeof e.onChange=="function"&&typeof e.removeMark=="function"&&typeof e.getDirtyPaths=="function"&&(e.marks===null||Xe(e.marks))&&(e.selection===null||O.isRange(e.selection))&&W.isNodeList(e.children)&&zn.isOperationList(e.operations);return mE.set(e,r),r},C={above(e,t){return e.above(t)},addMark(e,t,r){e.addMark(t,r)},after(e,t,r){return e.after(t,r)},before(e,t,r){return e.before(t,r)},deleteBackward(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{unit:r="character"}=t;e.deleteBackward(r)},deleteForward(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{unit:r="character"}=t;e.deleteForward(r)},deleteFragment(e,t){e.deleteFragment(t)},edges(e,t){return e.edges(t)},elementReadOnly(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return e.elementReadOnly(t)},end(e,t){return e.end(t)},first(e,t){return e.first(t)},fragment(e,t){return e.fragment(t)},hasBlocks(e,t){return e.hasBlocks(t)},hasInlines(e,t){return e.hasInlines(t)},hasPath(e,t){return e.hasPath(t)},hasTexts(e,t){return e.hasTexts(t)},insertBreak(e){e.insertBreak()},insertFragment(e,t,r){e.insertFragment(t,r)},insertNode(e,t){e.insertNode(t)},insertSoftBreak(e){e.insertSoftBreak()},insertText(e,t){e.insertText(t)},isBlock(e,t){return e.isBlock(t)},isEdge(e,t,r){return e.isEdge(t,r)},isEditor(e){return fJ(e)},isElementReadOnly(e,t){return e.isElementReadOnly(t)},isEmpty(e,t){return e.isEmpty(t)},isEnd(e,t,r){return e.isEnd(t,r)},isInline(e,t){return e.isInline(t)},isNormalizing(e){return e.isNormalizing()},isSelectable(e,t){return e.isSelectable(t)},isStart(e,t,r){return e.isStart(t,r)},isVoid(e,t){return e.isVoid(t)},last(e,t){return e.last(t)},leaf(e,t,r){return e.leaf(t,r)},levels(e,t){return e.levels(t)},marks(e){return e.getMarks()},next(e,t){return e.next(t)},node(e,t,r){return e.node(t,r)},nodes(e,t){return e.nodes(t)},normalize(e,t){e.normalize(t)},parent(e,t,r){return e.parent(t,r)},path(e,t,r){return e.path(t,r)},pathRef(e,t,r){return e.pathRef(t,r)},pathRefs(e){return e.pathRefs()},point(e,t,r){return e.point(t,r)},pointRef(e,t,r){return e.pointRef(t,r)},pointRefs(e){return e.pointRefs()},positions(e,t){return e.positions(t)},previous(e,t){return e.previous(t)},range(e,t,r){return e.range(t,r)},rangeRef(e,t,r){return e.rangeRef(t,r)},rangeRefs(e){return e.rangeRefs()},removeMark(e,t){e.removeMark(t)},setNormalizing(e,t){e.setNormalizing(t)},start(e,t){return e.start(t)},string(e,t,r){return e.string(t,r)},unhangRange(e,t,r){return e.unhangRange(t,r)},void(e,t){return e.void(t)},withoutNormalizing(e,t){e.withoutNormalizing(t)}};var pJ={isSpan(e){return Array.isArray(e)&&e.length===2&&e.every(T.isPath)}};function hE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function gE(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?hE(Object(r),!0).forEach(function(n){Vt(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):hE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var ge={compare(e,t){var r=T.compare(e.path,t.path);return r===0?e.offset<t.offset?-1:e.offset>t.offset?1:0:r},isAfter(e,t){return ge.compare(e,t)===1},isBefore(e,t){return ge.compare(e,t)===-1},equals(e,t){return e.offset===t.offset&&T.equals(e.path,t.path)},isPoint(e){return Xe(e)&&typeof e.offset=="number"&&T.isPath(e.path)},transform(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return Qp(e,n=>{if(n===null)return null;var{affinity:o="forward"}=r,{path:a,offset:s}=n;switch(t.type){case"insert_node":case"move_node":{n.path=T.transform(a,t,r);break}case"insert_text":{T.equals(t.path,a)&&(t.offset<s||t.offset===s&&o==="forward")&&(n.offset+=t.text.length);break}case"merge_node":{T.equals(t.path,a)&&(n.offset+=t.position),n.path=T.transform(a,t,r);break}case"remove_text":{T.equals(t.path,a)&&t.offset<=s&&(n.offset-=Math.min(s-t.offset,t.text.length));break}case"remove_node":{if(T.equals(t.path,a)||T.isAncestor(t.path,a))return null;n.path=T.transform(a,t,r);break}case"split_node":{if(T.equals(t.path,a)){if(t.position===s&&o==null)return null;(t.position<s||t.position===s&&o==="forward")&&(n.offset-=t.position,n.path=T.transform(a,t,gE(gE({},r),{},{affinity:"forward"})))}else n.path=T.transform(a,t,r);break}}})}},vE=void 0,it={setScrubber(e){vE=e},stringify(e){return JSON.stringify(e,vE)}},dJ=["text"],mJ=["anchor","focus"];function yE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function $n(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?yE(Object(r),!0).forEach(function(n){Vt(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):yE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var J={equals(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{loose:n=!1}=r;function o(a){var s=Hn(a,dJ);return s}return LE(n?o(e):e,n?o(t):t)},isText(e){return Xe(e)&&typeof e.text=="string"},isTextList(e){return Array.isArray(e)&&e.every(t=>J.isText(t))},isTextProps(e){return e.text!==void 0},matches(e,t){for(var r in t)if(r!=="text"&&(!e.hasOwnProperty(r)||e[r]!==t[r]))return!1;return!0},decorations(e,t){var r=[$n({},e)];for(var n of t){var o=Hn(n,mJ),[a,s]=O.edges(n),u=[],l=0,c=a.offset,p=s.offset;for(var d of r){var{length:h}=d.text,g=l;if(l+=h,c<=g&&l<=p){Object.assign(d,o),u.push(d);continue}if(c!==p&&(c===l||p===g)||c>l||p<g||p===g&&g!==0){u.push(d);continue}var v=d,m=void 0,b=void 0;if(p<l){var y=p-g;b=$n($n({},v),{},{text:v.text.slice(y)}),v=$n($n({},v),{},{text:v.text.slice(0,y)})}if(c>g){var x=c-g;m=$n($n({},v),{},{text:v.text.slice(0,x)}),v=$n($n({},v),{},{text:v.text.slice(x)})}Object.assign(v,o),m&&u.push(m),u.push(v),b&&u.push(b)}r=u}return r}},v2=e=>e.selection?e.selection:e.children.length>0?C.end(e,[]):[0],is=(e,t)=>{var[r]=C.node(e,t);return n=>n===r},y2=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,n=!r,o=r?CJ(t):t,a=ce.None,s=ce.None,u=0,l=null,c=null;for(var p of o){var d=p.codePointAt(0);if(!d)break;var h=OJ(p,d);if([a,s]=n?[s,h]:[h,a],os(a,ce.ZWJ)&&os(s,ce.ExtPict)&&(n?l=bE(t.substring(0,u)):l=bE(t.substring(0,t.length-u)),!l)||os(a,ce.RI)&&os(s,ce.RI)&&(c!==null?c=!c:n?c=!0:c=VJ(t.substring(0,t.length-u)),!c)||a!==ce.None&&s!==ce.None&&IJ(a,s))break;u+=p.length}return u||1},hJ=/\s/,gJ=/[\u0021-\u0023\u0025-\u002A\u002C-\u002F\u003A\u003B\u003F\u0040\u005B-\u005D\u005F\u007B\u007D\u00A1\u00A7\u00AB\u00B6\u00B7\u00BB\u00BF\u037E\u0387\u055A-\u055F\u0589\u058A\u05BE\u05C0\u05C3\u05C6\u05F3\u05F4\u0609\u060A\u060C\u060D\u061B\u061E\u061F\u066A-\u066D\u06D4\u0700-\u070D\u07F7-\u07F9\u0830-\u083E\u085E\u0964\u0965\u0970\u0AF0\u0DF4\u0E4F\u0E5A\u0E5B\u0F04-\u0F12\u0F14\u0F3A-\u0F3D\u0F85\u0FD0-\u0FD4\u0FD9\u0FDA\u104A-\u104F\u10FB\u1360-\u1368\u1400\u166D\u166E\u169B\u169C\u16EB-\u16ED\u1735\u1736\u17D4-\u17D6\u17D8-\u17DA\u1800-\u180A\u1944\u1945\u1A1E\u1A1F\u1AA0-\u1AA6\u1AA8-\u1AAD\u1B5A-\u1B60\u1BFC-\u1BFF\u1C3B-\u1C3F\u1C7E\u1C7F\u1CC0-\u1CC7\u1CD3\u2010-\u2027\u2030-\u2043\u2045-\u2051\u2053-\u205E\u207D\u207E\u208D\u208E\u2329\u232A\u2768-\u2775\u27C5\u27C6\u27E6-\u27EF\u2983-\u2998\u29D8-\u29DB\u29FC\u29FD\u2CF9-\u2CFC\u2CFE\u2CFF\u2D70\u2E00-\u2E2E\u2E30-\u2E3B\u3001-\u3003\u3008-\u3011\u3014-\u301F\u3030\u303D\u30A0\u30FB\uA4FE\uA4FF\uA60D-\uA60F\uA673\uA67E\uA6F2-\uA6F7\uA874-\uA877\uA8CE\uA8CF\uA8F8-\uA8FA\uA92E\uA92F\uA95F\uA9C1-\uA9CD\uA9DE\uA9DF\uAA5C-\uAA5F\uAADE\uAADF\uAAF0\uAAF1\uABEB\uFD3E\uFD3F\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE61\uFE63\uFE68\uFE6A\uFE6B\uFF01-\uFF03\uFF05-\uFF0A\uFF0C-\uFF0F\uFF1A\uFF1B\uFF1F\uFF20\uFF3B-\uFF3D\uFF3F\uFF5B\uFF5D\uFF5F-\uFF65]/,vJ=/['\u2018\u2019]/,yJ=function(t){for(var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,n=0,o=!1;t.length>0;){var a=y2(t,r),[s,u]=b2(t,a,r);if(bJ(s,u,r))o=!0,n+=a;else if(!o)n+=a;else break;t=u}return n},b2=(e,t,r)=>{if(r){var n=e.length-t;return[e.slice(n,e.length),e.slice(0,n)]}return[e.slice(0,t),e.slice(t)]},bJ=function e(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1;if(hJ.test(t))return!1;if(vJ.test(t)){var o=y2(r,n),[a,s]=b2(r,o,n);if(e(a,s,n))return!0}return!gJ.test(t)},CJ=function*(t){for(var r=t.length-1,n=0;n<t.length;n++){var o=t.charAt(r-n);if(wJ(o.charCodeAt(0))){var a=t.charAt(r-n-1);if(xJ(a.charCodeAt(0))){yield a+o,n++;continue}}yield o}},xJ=e=>e>=55296&&e<=56319,wJ=e=>e>=56320&&e<=57343,ce;(function(e){e[e.None=0]="None",e[e.Extend=1]="Extend",e[e.ZWJ=2]="ZWJ",e[e.RI=4]="RI",e[e.Prepend=8]="Prepend",e[e.SpacingMark=16]="SpacingMark",e[e.L=32]="L",e[e.V=64]="V",e[e.T=128]="T",e[e.LV=256]="LV",e[e.LVT=512]="LVT",e[e.ExtPict=1024]="ExtPict",e[e.Any=2048]="Any"})(ce||(ce={}));var SJ=/^(?:[\u0300-\u036F\u0483-\u0489\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u065F\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u08D3-\u08E1\u08E3-\u0902\u093A\u093C\u0941-\u0948\u094D\u0951-\u0957\u0962\u0963\u0981\u09BC\u09BE\u09C1-\u09C4\u09CD\u09D7\u09E2\u09E3\u09FE\u0A01\u0A02\u0A3C\u0A41\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81\u0A82\u0ABC\u0AC1-\u0AC5\u0AC7\u0AC8\u0ACD\u0AE2\u0AE3\u0AFA-\u0AFF\u0B01\u0B3C\u0B3E\u0B3F\u0B41-\u0B44\u0B4D\u0B55-\u0B57\u0B62\u0B63\u0B82\u0BBE\u0BC0\u0BCD\u0BD7\u0C00\u0C04\u0C3E-\u0C40\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C81\u0CBC\u0CBF\u0CC2\u0CC6\u0CCC\u0CCD\u0CD5\u0CD6\u0CE2\u0CE3\u0D00\u0D01\u0D3B\u0D3C\u0D3E\u0D41-\u0D44\u0D4D\u0D57\u0D62\u0D63\u0D81\u0DCA\u0DCF\u0DD2-\u0DD4\u0DD6\u0DDF\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EBC\u0EC8-\u0ECD\u0F18\u0F19\u0F35\u0F37\u0F39\u0F71-\u0F7E\u0F80-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102D-\u1030\u1032-\u1037\u1039\u103A\u103D\u103E\u1058\u1059\u105E-\u1060\u1071-\u1074\u1082\u1085\u1086\u108D\u109D\u135D-\u135F\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17B4\u17B5\u17B7-\u17BD\u17C6\u17C9-\u17D3\u17DD\u180B-\u180D\u1885\u1886\u18A9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193B\u1A17\u1A18\u1A1B\u1A56\u1A58-\u1A5E\u1A60\u1A62\u1A65-\u1A6C\u1A73-\u1A7C\u1A7F\u1AB0-\u1AC0\u1B00-\u1B03\u1B34-\u1B3A\u1B3C\u1B42\u1B6B-\u1B73\u1B80\u1B81\u1BA2-\u1BA5\u1BA8\u1BA9\u1BAB-\u1BAD\u1BE6\u1BE8\u1BE9\u1BED\u1BEF-\u1BF1\u1C2C-\u1C33\u1C36\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE0\u1CE2-\u1CE8\u1CED\u1CF4\u1CF8\u1CF9\u1DC0-\u1DF9\u1DFB-\u1DFF\u200C\u20D0-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302F\u3099\u309A\uA66F-\uA672\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA825\uA826\uA82C\uA8C4\uA8C5\uA8E0-\uA8F1\uA8FF\uA926-\uA92D\uA947-\uA951\uA980-\uA982\uA9B3\uA9B6-\uA9B9\uA9BC\uA9BD\uA9E5\uAA29-\uAA2E\uAA31\uAA32\uAA35\uAA36\uAA43\uAA4C\uAA7C\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEC\uAAED\uAAF6\uABE5\uABE8\uABED\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F\uFF9E\uFF9F]|\uD800[\uDDFD\uDEE0\uDF76-\uDF7A]|\uD802[\uDE01-\uDE03\uDE05\uDE06\uDE0C-\uDE0F\uDE38-\uDE3A\uDE3F\uDEE5\uDEE6]|\uD803[\uDD24-\uDD27\uDEAB\uDEAC\uDF46-\uDF50]|\uD804[\uDC01\uDC38-\uDC46\uDC7F-\uDC81\uDCB3-\uDCB6\uDCB9\uDCBA\uDD00-\uDD02\uDD27-\uDD2B\uDD2D-\uDD34\uDD73\uDD80\uDD81\uDDB6-\uDDBE\uDDC9-\uDDCC\uDDCF\uDE2F-\uDE31\uDE34\uDE36\uDE37\uDE3E\uDEDF\uDEE3-\uDEEA\uDF00\uDF01\uDF3B\uDF3C\uDF3E\uDF40\uDF57\uDF66-\uDF6C\uDF70-\uDF74]|\uD805[\uDC38-\uDC3F\uDC42-\uDC44\uDC46\uDC5E\uDCB0\uDCB3-\uDCB8\uDCBA\uDCBD\uDCBF\uDCC0\uDCC2\uDCC3\uDDAF\uDDB2-\uDDB5\uDDBC\uDDBD\uDDBF\uDDC0\uDDDC\uDDDD\uDE33-\uDE3A\uDE3D\uDE3F\uDE40\uDEAB\uDEAD\uDEB0-\uDEB5\uDEB7\uDF1D-\uDF1F\uDF22-\uDF25\uDF27-\uDF2B]|\uD806[\uDC2F-\uDC37\uDC39\uDC3A\uDD30\uDD3B\uDD3C\uDD3E\uDD43\uDDD4-\uDDD7\uDDDA\uDDDB\uDDE0\uDE01-\uDE0A\uDE33-\uDE38\uDE3B-\uDE3E\uDE47\uDE51-\uDE56\uDE59-\uDE5B\uDE8A-\uDE96\uDE98\uDE99]|\uD807[\uDC30-\uDC36\uDC38-\uDC3D\uDC3F\uDC92-\uDCA7\uDCAA-\uDCB0\uDCB2\uDCB3\uDCB5\uDCB6\uDD31-\uDD36\uDD3A\uDD3C\uDD3D\uDD3F-\uDD45\uDD47\uDD90\uDD91\uDD95\uDD97\uDEF3\uDEF4]|\uD81A[\uDEF0-\uDEF4\uDF30-\uDF36]|\uD81B[\uDF4F\uDF8F-\uDF92\uDFE4]|\uD82F[\uDC9D\uDC9E]|\uD834[\uDD65\uDD67-\uDD69\uDD6E-\uDD72\uDD7B-\uDD82\uDD85-\uDD8B\uDDAA-\uDDAD\uDE42-\uDE44]|\uD836[\uDE00-\uDE36\uDE3B-\uDE6C\uDE75\uDE84\uDE9B-\uDE9F\uDEA1-\uDEAF]|\uD838[\uDC00-\uDC06\uDC08-\uDC18\uDC1B-\uDC21\uDC23\uDC24\uDC26-\uDC2A\uDD30-\uDD36\uDEEC-\uDEEF]|\uD83A[\uDCD0-\uDCD6\uDD44-\uDD4A]|\uD83C[\uDFFB-\uDFFF]|\uDB40[\uDC20-\uDC7F\uDD00-\uDDEF])$/,DJ=/^(?:[\u0600-\u0605\u06DD\u070F\u0890\u0891\u08E2\u0D4E]|\uD804[\uDCBD\uDCCD\uDDC2\uDDC3]|\uD806[\uDD3F\uDD41\uDE3A\uDE84-\uDE89]|\uD807\uDD46)$/,EJ=/^(?:[\u0903\u093B\u093E-\u0940\u0949-\u094C\u094E\u094F\u0982\u0983\u09BF\u09C0\u09C7\u09C8\u09CB\u09CC\u0A03\u0A3E-\u0A40\u0A83\u0ABE-\u0AC0\u0AC9\u0ACB\u0ACC\u0B02\u0B03\u0B40\u0B47\u0B48\u0B4B\u0B4C\u0BBF\u0BC1\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCC\u0C01-\u0C03\u0C41-\u0C44\u0C82\u0C83\u0CBE\u0CC0\u0CC1\u0CC3\u0CC4\u0CC7\u0CC8\u0CCA\u0CCB\u0D02\u0D03\u0D3F\u0D40\u0D46-\u0D48\u0D4A-\u0D4C\u0D82\u0D83\u0DD0\u0DD1\u0DD8-\u0DDE\u0DF2\u0DF3\u0E33\u0EB3\u0F3E\u0F3F\u0F7F\u1031\u103B\u103C\u1056\u1057\u1084\u1715\u1734\u17B6\u17BE-\u17C5\u17C7\u17C8\u1923-\u1926\u1929-\u192B\u1930\u1931\u1933-\u1938\u1A19\u1A1A\u1A55\u1A57\u1A6D-\u1A72\u1B04\u1B3B\u1B3D-\u1B41\u1B43\u1B44\u1B82\u1BA1\u1BA6\u1BA7\u1BAA\u1BE7\u1BEA-\u1BEC\u1BEE\u1BF2\u1BF3\u1C24-\u1C2B\u1C34\u1C35\u1CE1\u1CF7\uA823\uA824\uA827\uA880\uA881\uA8B4-\uA8C3\uA952\uA953\uA983\uA9B4\uA9B5\uA9BA\uA9BB\uA9BE-\uA9C0\uAA2F\uAA30\uAA33\uAA34\uAA4D\uAAEB\uAAEE\uAAEF\uAAF5\uABE3\uABE4\uABE6\uABE7\uABE9\uABEA\uABEC]|\uD804[\uDC00\uDC02\uDC82\uDCB0-\uDCB2\uDCB7\uDCB8\uDD2C\uDD45\uDD46\uDD82\uDDB3-\uDDB5\uDDBF\uDDC0\uDDCE\uDE2C-\uDE2E\uDE32\uDE33\uDE35\uDEE0-\uDEE2\uDF02\uDF03\uDF3F\uDF41-\uDF44\uDF47\uDF48\uDF4B-\uDF4D\uDF62\uDF63]|\uD805[\uDC35-\uDC37\uDC40\uDC41\uDC45\uDCB1\uDCB2\uDCB9\uDCBB\uDCBC\uDCBE\uDCC1\uDDB0\uDDB1\uDDB8-\uDDBB\uDDBE\uDE30-\uDE32\uDE3B\uDE3C\uDE3E\uDEAC\uDEAE\uDEAF\uDEB6\uDF26]|\uD806[\uDC2C-\uDC2E\uDC38\uDD31-\uDD35\uDD37\uDD38\uDD3D\uDD40\uDD42\uDDD1-\uDDD3\uDDDC-\uDDDF\uDDE4\uDE39\uDE57\uDE58\uDE97]|\uD807[\uDC2F\uDC3E\uDCA9\uDCB1\uDCB4\uDD8A-\uDD8E\uDD93\uDD94\uDD96\uDEF5\uDEF6]|\uD81B[\uDF51-\uDF87\uDFF0\uDFF1]|\uD834[\uDD66\uDD6D])$/,PJ=/^[\u1100-\u115F\uA960-\uA97C]$/,TJ=/^[\u1160-\u11A7\uD7B0-\uD7C6]$/,AJ=/^[\u11A8-\u11FF\uD7CB-\uD7FB]$/,RJ=/^[\uAC00\uAC1C\uAC38\uAC54\uAC70\uAC8C\uACA8\uACC4\uACE0\uACFC\uAD18\uAD34\uAD50\uAD6C\uAD88\uADA4\uADC0\uADDC\uADF8\uAE14\uAE30\uAE4C\uAE68\uAE84\uAEA0\uAEBC\uAED8\uAEF4\uAF10\uAF2C\uAF48\uAF64\uAF80\uAF9C\uAFB8\uAFD4\uAFF0\uB00C\uB028\uB044\uB060\uB07C\uB098\uB0B4\uB0D0\uB0EC\uB108\uB124\uB140\uB15C\uB178\uB194\uB1B0\uB1CC\uB1E8\uB204\uB220\uB23C\uB258\uB274\uB290\uB2AC\uB2C8\uB2E4\uB300\uB31C\uB338\uB354\uB370\uB38C\uB3A8\uB3C4\uB3E0\uB3FC\uB418\uB434\uB450\uB46C\uB488\uB4A4\uB4C0\uB4DC\uB4F8\uB514\uB530\uB54C\uB568\uB584\uB5A0\uB5BC\uB5D8\uB5F4\uB610\uB62C\uB648\uB664\uB680\uB69C\uB6B8\uB6D4\uB6F0\uB70C\uB728\uB744\uB760\uB77C\uB798\uB7B4\uB7D0\uB7EC\uB808\uB824\uB840\uB85C\uB878\uB894\uB8B0\uB8CC\uB8E8\uB904\uB920\uB93C\uB958\uB974\uB990\uB9AC\uB9C8\uB9E4\uBA00\uBA1C\uBA38\uBA54\uBA70\uBA8C\uBAA8\uBAC4\uBAE0\uBAFC\uBB18\uBB34\uBB50\uBB6C\uBB88\uBBA4\uBBC0\uBBDC\uBBF8\uBC14\uBC30\uBC4C\uBC68\uBC84\uBCA0\uBCBC\uBCD8\uBCF4\uBD10\uBD2C\uBD48\uBD64\uBD80\uBD9C\uBDB8\uBDD4\uBDF0\uBE0C\uBE28\uBE44\uBE60\uBE7C\uBE98\uBEB4\uBED0\uBEEC\uBF08\uBF24\uBF40\uBF5C\uBF78\uBF94\uBFB0\uBFCC\uBFE8\uC004\uC020\uC03C\uC058\uC074\uC090\uC0AC\uC0C8\uC0E4\uC100\uC11C\uC138\uC154\uC170\uC18C\uC1A8\uC1C4\uC1E0\uC1FC\uC218\uC234\uC250\uC26C\uC288\uC2A4\uC2C0\uC2DC\uC2F8\uC314\uC330\uC34C\uC368\uC384\uC3A0\uC3BC\uC3D8\uC3F4\uC410\uC42C\uC448\uC464\uC480\uC49C\uC4B8\uC4D4\uC4F0\uC50C\uC528\uC544\uC560\uC57C\uC598\uC5B4\uC5D0\uC5EC\uC608\uC624\uC640\uC65C\uC678\uC694\uC6B0\uC6CC\uC6E8\uC704\uC720\uC73C\uC758\uC774\uC790\uC7AC\uC7C8\uC7E4\uC800\uC81C\uC838\uC854\uC870\uC88C\uC8A8\uC8C4\uC8E0\uC8FC\uC918\uC934\uC950\uC96C\uC988\uC9A4\uC9C0\uC9DC\uC9F8\uCA14\uCA30\uCA4C\uCA68\uCA84\uCAA0\uCABC\uCAD8\uCAF4\uCB10\uCB2C\uCB48\uCB64\uCB80\uCB9C\uCBB8\uCBD4\uCBF0\uCC0C\uCC28\uCC44\uCC60\uCC7C\uCC98\uCCB4\uCCD0\uCCEC\uCD08\uCD24\uCD40\uCD5C\uCD78\uCD94\uCDB0\uCDCC\uCDE8\uCE04\uCE20\uCE3C\uCE58\uCE74\uCE90\uCEAC\uCEC8\uCEE4\uCF00\uCF1C\uCF38\uCF54\uCF70\uCF8C\uCFA8\uCFC4\uCFE0\uCFFC\uD018\uD034\uD050\uD06C\uD088\uD0A4\uD0C0\uD0DC\uD0F8\uD114\uD130\uD14C\uD168\uD184\uD1A0\uD1BC\uD1D8\uD1F4\uD210\uD22C\uD248\uD264\uD280\uD29C\uD2B8\uD2D4\uD2F0\uD30C\uD328\uD344\uD360\uD37C\uD398\uD3B4\uD3D0\uD3EC\uD408\uD424\uD440\uD45C\uD478\uD494\uD4B0\uD4CC\uD4E8\uD504\uD520\uD53C\uD558\uD574\uD590\uD5AC\uD5C8\uD5E4\uD600\uD61C\uD638\uD654\uD670\uD68C\uD6A8\uD6C4\uD6E0\uD6FC\uD718\uD734\uD750\uD76C\uD788]$/,FJ=/^[\uAC01-\uAC1B\uAC1D-\uAC37\uAC39-\uAC53\uAC55-\uAC6F\uAC71-\uAC8B\uAC8D-\uACA7\uACA9-\uACC3\uACC5-\uACDF\uACE1-\uACFB\uACFD-\uAD17\uAD19-\uAD33\uAD35-\uAD4F\uAD51-\uAD6B\uAD6D-\uAD87\uAD89-\uADA3\uADA5-\uADBF\uADC1-\uADDB\uADDD-\uADF7\uADF9-\uAE13\uAE15-\uAE2F\uAE31-\uAE4B\uAE4D-\uAE67\uAE69-\uAE83\uAE85-\uAE9F\uAEA1-\uAEBB\uAEBD-\uAED7\uAED9-\uAEF3\uAEF5-\uAF0F\uAF11-\uAF2B\uAF2D-\uAF47\uAF49-\uAF63\uAF65-\uAF7F\uAF81-\uAF9B\uAF9D-\uAFB7\uAFB9-\uAFD3\uAFD5-\uAFEF\uAFF1-\uB00B\uB00D-\uB027\uB029-\uB043\uB045-\uB05F\uB061-\uB07B\uB07D-\uB097\uB099-\uB0B3\uB0B5-\uB0CF\uB0D1-\uB0EB\uB0ED-\uB107\uB109-\uB123\uB125-\uB13F\uB141-\uB15B\uB15D-\uB177\uB179-\uB193\uB195-\uB1AF\uB1B1-\uB1CB\uB1CD-\uB1E7\uB1E9-\uB203\uB205-\uB21F\uB221-\uB23B\uB23D-\uB257\uB259-\uB273\uB275-\uB28F\uB291-\uB2AB\uB2AD-\uB2C7\uB2C9-\uB2E3\uB2E5-\uB2FF\uB301-\uB31B\uB31D-\uB337\uB339-\uB353\uB355-\uB36F\uB371-\uB38B\uB38D-\uB3A7\uB3A9-\uB3C3\uB3C5-\uB3DF\uB3E1-\uB3FB\uB3FD-\uB417\uB419-\uB433\uB435-\uB44F\uB451-\uB46B\uB46D-\uB487\uB489-\uB4A3\uB4A5-\uB4BF\uB4C1-\uB4DB\uB4DD-\uB4F7\uB4F9-\uB513\uB515-\uB52F\uB531-\uB54B\uB54D-\uB567\uB569-\uB583\uB585-\uB59F\uB5A1-\uB5BB\uB5BD-\uB5D7\uB5D9-\uB5F3\uB5F5-\uB60F\uB611-\uB62B\uB62D-\uB647\uB649-\uB663\uB665-\uB67F\uB681-\uB69B\uB69D-\uB6B7\uB6B9-\uB6D3\uB6D5-\uB6EF\uB6F1-\uB70B\uB70D-\uB727\uB729-\uB743\uB745-\uB75F\uB761-\uB77B\uB77D-\uB797\uB799-\uB7B3\uB7B5-\uB7CF\uB7D1-\uB7EB\uB7ED-\uB807\uB809-\uB823\uB825-\uB83F\uB841-\uB85B\uB85D-\uB877\uB879-\uB893\uB895-\uB8AF\uB8B1-\uB8CB\uB8CD-\uB8E7\uB8E9-\uB903\uB905-\uB91F\uB921-\uB93B\uB93D-\uB957\uB959-\uB973\uB975-\uB98F\uB991-\uB9AB\uB9AD-\uB9C7\uB9C9-\uB9E3\uB9E5-\uB9FF\uBA01-\uBA1B\uBA1D-\uBA37\uBA39-\uBA53\uBA55-\uBA6F\uBA71-\uBA8B\uBA8D-\uBAA7\uBAA9-\uBAC3\uBAC5-\uBADF\uBAE1-\uBAFB\uBAFD-\uBB17\uBB19-\uBB33\uBB35-\uBB4F\uBB51-\uBB6B\uBB6D-\uBB87\uBB89-\uBBA3\uBBA5-\uBBBF\uBBC1-\uBBDB\uBBDD-\uBBF7\uBBF9-\uBC13\uBC15-\uBC2F\uBC31-\uBC4B\uBC4D-\uBC67\uBC69-\uBC83\uBC85-\uBC9F\uBCA1-\uBCBB\uBCBD-\uBCD7\uBCD9-\uBCF3\uBCF5-\uBD0F\uBD11-\uBD2B\uBD2D-\uBD47\uBD49-\uBD63\uBD65-\uBD7F\uBD81-\uBD9B\uBD9D-\uBDB7\uBDB9-\uBDD3\uBDD5-\uBDEF\uBDF1-\uBE0B\uBE0D-\uBE27\uBE29-\uBE43\uBE45-\uBE5F\uBE61-\uBE7B\uBE7D-\uBE97\uBE99-\uBEB3\uBEB5-\uBECF\uBED1-\uBEEB\uBEED-\uBF07\uBF09-\uBF23\uBF25-\uBF3F\uBF41-\uBF5B\uBF5D-\uBF77\uBF79-\uBF93\uBF95-\uBFAF\uBFB1-\uBFCB\uBFCD-\uBFE7\uBFE9-\uC003\uC005-\uC01F\uC021-\uC03B\uC03D-\uC057\uC059-\uC073\uC075-\uC08F\uC091-\uC0AB\uC0AD-\uC0C7\uC0C9-\uC0E3\uC0E5-\uC0FF\uC101-\uC11B\uC11D-\uC137\uC139-\uC153\uC155-\uC16F\uC171-\uC18B\uC18D-\uC1A7\uC1A9-\uC1C3\uC1C5-\uC1DF\uC1E1-\uC1FB\uC1FD-\uC217\uC219-\uC233\uC235-\uC24F\uC251-\uC26B\uC26D-\uC287\uC289-\uC2A3\uC2A5-\uC2BF\uC2C1-\uC2DB\uC2DD-\uC2F7\uC2F9-\uC313\uC315-\uC32F\uC331-\uC34B\uC34D-\uC367\uC369-\uC383\uC385-\uC39F\uC3A1-\uC3BB\uC3BD-\uC3D7\uC3D9-\uC3F3\uC3F5-\uC40F\uC411-\uC42B\uC42D-\uC447\uC449-\uC463\uC465-\uC47F\uC481-\uC49B\uC49D-\uC4B7\uC4B9-\uC4D3\uC4D5-\uC4EF\uC4F1-\uC50B\uC50D-\uC527\uC529-\uC543\uC545-\uC55F\uC561-\uC57B\uC57D-\uC597\uC599-\uC5B3\uC5B5-\uC5CF\uC5D1-\uC5EB\uC5ED-\uC607\uC609-\uC623\uC625-\uC63F\uC641-\uC65B\uC65D-\uC677\uC679-\uC693\uC695-\uC6AF\uC6B1-\uC6CB\uC6CD-\uC6E7\uC6E9-\uC703\uC705-\uC71F\uC721-\uC73B\uC73D-\uC757\uC759-\uC773\uC775-\uC78F\uC791-\uC7AB\uC7AD-\uC7C7\uC7C9-\uC7E3\uC7E5-\uC7FF\uC801-\uC81B\uC81D-\uC837\uC839-\uC853\uC855-\uC86F\uC871-\uC88B\uC88D-\uC8A7\uC8A9-\uC8C3\uC8C5-\uC8DF\uC8E1-\uC8FB\uC8FD-\uC917\uC919-\uC933\uC935-\uC94F\uC951-\uC96B\uC96D-\uC987\uC989-\uC9A3\uC9A5-\uC9BF\uC9C1-\uC9DB\uC9DD-\uC9F7\uC9F9-\uCA13\uCA15-\uCA2F\uCA31-\uCA4B\uCA4D-\uCA67\uCA69-\uCA83\uCA85-\uCA9F\uCAA1-\uCABB\uCABD-\uCAD7\uCAD9-\uCAF3\uCAF5-\uCB0F\uCB11-\uCB2B\uCB2D-\uCB47\uCB49-\uCB63\uCB65-\uCB7F\uCB81-\uCB9B\uCB9D-\uCBB7\uCBB9-\uCBD3\uCBD5-\uCBEF\uCBF1-\uCC0B\uCC0D-\uCC27\uCC29-\uCC43\uCC45-\uCC5F\uCC61-\uCC7B\uCC7D-\uCC97\uCC99-\uCCB3\uCCB5-\uCCCF\uCCD1-\uCCEB\uCCED-\uCD07\uCD09-\uCD23\uCD25-\uCD3F\uCD41-\uCD5B\uCD5D-\uCD77\uCD79-\uCD93\uCD95-\uCDAF\uCDB1-\uCDCB\uCDCD-\uCDE7\uCDE9-\uCE03\uCE05-\uCE1F\uCE21-\uCE3B\uCE3D-\uCE57\uCE59-\uCE73\uCE75-\uCE8F\uCE91-\uCEAB\uCEAD-\uCEC7\uCEC9-\uCEE3\uCEE5-\uCEFF\uCF01-\uCF1B\uCF1D-\uCF37\uCF39-\uCF53\uCF55-\uCF6F\uCF71-\uCF8B\uCF8D-\uCFA7\uCFA9-\uCFC3\uCFC5-\uCFDF\uCFE1-\uCFFB\uCFFD-\uD017\uD019-\uD033\uD035-\uD04F\uD051-\uD06B\uD06D-\uD087\uD089-\uD0A3\uD0A5-\uD0BF\uD0C1-\uD0DB\uD0DD-\uD0F7\uD0F9-\uD113\uD115-\uD12F\uD131-\uD14B\uD14D-\uD167\uD169-\uD183\uD185-\uD19F\uD1A1-\uD1BB\uD1BD-\uD1D7\uD1D9-\uD1F3\uD1F5-\uD20F\uD211-\uD22B\uD22D-\uD247\uD249-\uD263\uD265-\uD27F\uD281-\uD29B\uD29D-\uD2B7\uD2B9-\uD2D3\uD2D5-\uD2EF\uD2F1-\uD30B\uD30D-\uD327\uD329-\uD343\uD345-\uD35F\uD361-\uD37B\uD37D-\uD397\uD399-\uD3B3\uD3B5-\uD3CF\uD3D1-\uD3EB\uD3ED-\uD407\uD409-\uD423\uD425-\uD43F\uD441-\uD45B\uD45D-\uD477\uD479-\uD493\uD495-\uD4AF\uD4B1-\uD4CB\uD4CD-\uD4E7\uD4E9-\uD503\uD505-\uD51F\uD521-\uD53B\uD53D-\uD557\uD559-\uD573\uD575-\uD58F\uD591-\uD5AB\uD5AD-\uD5C7\uD5C9-\uD5E3\uD5E5-\uD5FF\uD601-\uD61B\uD61D-\uD637\uD639-\uD653\uD655-\uD66F\uD671-\uD68B\uD68D-\uD6A7\uD6A9-\uD6C3\uD6C5-\uD6DF\uD6E1-\uD6FB\uD6FD-\uD717\uD719-\uD733\uD735-\uD74F\uD751-\uD76B\uD76D-\uD787\uD789-\uD7A3]$/,BJ=/^(?:[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u2388\u23CF\u23E9-\u23F3\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB-\u25FE\u2600-\u2605\u2607-\u2612\u2614-\u2685\u2690-\u2705\u2708-\u2712\u2714\u2716\u271D\u2721\u2728\u2733\u2734\u2744\u2747\u274C\u274E\u2753-\u2755\u2757\u2763-\u2767\u2795-\u2797\u27A1\u27B0\u27BF\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B50\u2B55\u3030\u303D\u3297\u3299]|\uD83C[\uDC00-\uDCFF\uDD0D-\uDD0F\uDD2F\uDD6C-\uDD71\uDD7E\uDD7F\uDD8E\uDD91-\uDD9A\uDDAD-\uDDE5\uDE01-\uDE0F\uDE1A\uDE2F\uDE32-\uDE3A\uDE3C-\uDE3F\uDE49-\uDFFA]|\uD83D[\uDC00-\uDD3D\uDD46-\uDE4F\uDE80-\uDEFF\uDF74-\uDF7F\uDFD5-\uDFFF]|\uD83E[\uDC0C-\uDC0F\uDC48-\uDC4F\uDC5A-\uDC5F\uDC88-\uDC8F\uDCAE-\uDCFF\uDD0C-\uDD3A\uDD3C-\uDD45\uDD47-\uDEFF]|\uD83F[\uDC00-\uDFFD])$/,OJ=(e,t)=>{var r=ce.Any;return e.search(SJ)!==-1&&(r|=ce.Extend),t===8205&&(r|=ce.ZWJ),t>=127462&&t<=127487&&(r|=ce.RI),e.search(DJ)!==-1&&(r|=ce.Prepend),e.search(EJ)!==-1&&(r|=ce.SpacingMark),e.search(PJ)!==-1&&(r|=ce.L),e.search(TJ)!==-1&&(r|=ce.V),e.search(AJ)!==-1&&(r|=ce.T),e.search(RJ)!==-1&&(r|=ce.LV),e.search(FJ)!==-1&&(r|=ce.LVT),e.search(BJ)!==-1&&(r|=ce.ExtPict),r};function os(e,t){return(e&t)!==0}var MJ=[[ce.L,ce.L|ce.V|ce.LV|ce.LVT],[ce.LV|ce.V,ce.V|ce.T],[ce.LVT|ce.T,ce.T],[ce.Any,ce.Extend|ce.ZWJ],[ce.Any,ce.SpacingMark],[ce.Prepend,ce.Any],[ce.ZWJ,ce.ExtPict],[ce.RI,ce.RI]];function IJ(e,t){return MJ.findIndex(r=>os(e,r[0])&&os(t,r[1]))===-1}var kJ=/(?:[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u2388\u23CF\u23E9-\u23F3\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB-\u25FE\u2600-\u2605\u2607-\u2612\u2614-\u2685\u2690-\u2705\u2708-\u2712\u2714\u2716\u271D\u2721\u2728\u2733\u2734\u2744\u2747\u274C\u274E\u2753-\u2755\u2757\u2763-\u2767\u2795-\u2797\u27A1\u27B0\u27BF\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B50\u2B55\u3030\u303D\u3297\u3299]|\uD83C[\uDC00-\uDCFF\uDD0D-\uDD0F\uDD2F\uDD6C-\uDD71\uDD7E\uDD7F\uDD8E\uDD91-\uDD9A\uDDAD-\uDDE5\uDE01-\uDE0F\uDE1A\uDE2F\uDE32-\uDE3A\uDE3C-\uDE3F\uDE49-\uDFFA]|\uD83D[\uDC00-\uDD3D\uDD46-\uDE4F\uDE80-\uDEFF\uDF74-\uDF7F\uDFD5-\uDFFF]|\uD83E[\uDC0C-\uDC0F\uDC48-\uDC4F\uDC5A-\uDC5F\uDC88-\uDC8F\uDCAE-\uDCFF\uDD0C-\uDD3A\uDD3C-\uDD45\uDD47-\uDEFF]|\uD83F[\uDC00-\uDFFD])(?:[\u0300-\u036F\u0483-\u0489\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u065F\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u08D3-\u08E1\u08E3-\u0902\u093A\u093C\u0941-\u0948\u094D\u0951-\u0957\u0962\u0963\u0981\u09BC\u09BE\u09C1-\u09C4\u09CD\u09D7\u09E2\u09E3\u09FE\u0A01\u0A02\u0A3C\u0A41\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81\u0A82\u0ABC\u0AC1-\u0AC5\u0AC7\u0AC8\u0ACD\u0AE2\u0AE3\u0AFA-\u0AFF\u0B01\u0B3C\u0B3E\u0B3F\u0B41-\u0B44\u0B4D\u0B55-\u0B57\u0B62\u0B63\u0B82\u0BBE\u0BC0\u0BCD\u0BD7\u0C00\u0C04\u0C3E-\u0C40\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C81\u0CBC\u0CBF\u0CC2\u0CC6\u0CCC\u0CCD\u0CD5\u0CD6\u0CE2\u0CE3\u0D00\u0D01\u0D3B\u0D3C\u0D3E\u0D41-\u0D44\u0D4D\u0D57\u0D62\u0D63\u0D81\u0DCA\u0DCF\u0DD2-\u0DD4\u0DD6\u0DDF\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EBC\u0EC8-\u0ECD\u0F18\u0F19\u0F35\u0F37\u0F39\u0F71-\u0F7E\u0F80-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102D-\u1030\u1032-\u1037\u1039\u103A\u103D\u103E\u1058\u1059\u105E-\u1060\u1071-\u1074\u1082\u1085\u1086\u108D\u109D\u135D-\u135F\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17B4\u17B5\u17B7-\u17BD\u17C6\u17C9-\u17D3\u17DD\u180B-\u180D\u1885\u1886\u18A9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193B\u1A17\u1A18\u1A1B\u1A56\u1A58-\u1A5E\u1A60\u1A62\u1A65-\u1A6C\u1A73-\u1A7C\u1A7F\u1AB0-\u1AC0\u1B00-\u1B03\u1B34-\u1B3A\u1B3C\u1B42\u1B6B-\u1B73\u1B80\u1B81\u1BA2-\u1BA5\u1BA8\u1BA9\u1BAB-\u1BAD\u1BE6\u1BE8\u1BE9\u1BED\u1BEF-\u1BF1\u1C2C-\u1C33\u1C36\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE0\u1CE2-\u1CE8\u1CED\u1CF4\u1CF8\u1CF9\u1DC0-\u1DF9\u1DFB-\u1DFF\u200C\u20D0-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302F\u3099\u309A\uA66F-\uA672\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA825\uA826\uA82C\uA8C4\uA8C5\uA8E0-\uA8F1\uA8FF\uA926-\uA92D\uA947-\uA951\uA980-\uA982\uA9B3\uA9B6-\uA9B9\uA9BC\uA9BD\uA9E5\uAA29-\uAA2E\uAA31\uAA32\uAA35\uAA36\uAA43\uAA4C\uAA7C\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEC\uAAED\uAAF6\uABE5\uABE8\uABED\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F\uFF9E\uFF9F]|\uD800[\uDDFD\uDEE0\uDF76-\uDF7A]|\uD802[\uDE01-\uDE03\uDE05\uDE06\uDE0C-\uDE0F\uDE38-\uDE3A\uDE3F\uDEE5\uDEE6]|\uD803[\uDD24-\uDD27\uDEAB\uDEAC\uDF46-\uDF50]|\uD804[\uDC01\uDC38-\uDC46\uDC7F-\uDC81\uDCB3-\uDCB6\uDCB9\uDCBA\uDD00-\uDD02\uDD27-\uDD2B\uDD2D-\uDD34\uDD73\uDD80\uDD81\uDDB6-\uDDBE\uDDC9-\uDDCC\uDDCF\uDE2F-\uDE31\uDE34\uDE36\uDE37\uDE3E\uDEDF\uDEE3-\uDEEA\uDF00\uDF01\uDF3B\uDF3C\uDF3E\uDF40\uDF57\uDF66-\uDF6C\uDF70-\uDF74]|\uD805[\uDC38-\uDC3F\uDC42-\uDC44\uDC46\uDC5E\uDCB0\uDCB3-\uDCB8\uDCBA\uDCBD\uDCBF\uDCC0\uDCC2\uDCC3\uDDAF\uDDB2-\uDDB5\uDDBC\uDDBD\uDDBF\uDDC0\uDDDC\uDDDD\uDE33-\uDE3A\uDE3D\uDE3F\uDE40\uDEAB\uDEAD\uDEB0-\uDEB5\uDEB7\uDF1D-\uDF1F\uDF22-\uDF25\uDF27-\uDF2B]|\uD806[\uDC2F-\uDC37\uDC39\uDC3A\uDD30\uDD3B\uDD3C\uDD3E\uDD43\uDDD4-\uDDD7\uDDDA\uDDDB\uDDE0\uDE01-\uDE0A\uDE33-\uDE38\uDE3B-\uDE3E\uDE47\uDE51-\uDE56\uDE59-\uDE5B\uDE8A-\uDE96\uDE98\uDE99]|\uD807[\uDC30-\uDC36\uDC38-\uDC3D\uDC3F\uDC92-\uDCA7\uDCAA-\uDCB0\uDCB2\uDCB3\uDCB5\uDCB6\uDD31-\uDD36\uDD3A\uDD3C\uDD3D\uDD3F-\uDD45\uDD47\uDD90\uDD91\uDD95\uDD97\uDEF3\uDEF4]|\uD81A[\uDEF0-\uDEF4\uDF30-\uDF36]|\uD81B[\uDF4F\uDF8F-\uDF92\uDFE4]|\uD82F[\uDC9D\uDC9E]|\uD834[\uDD65\uDD67-\uDD69\uDD6E-\uDD72\uDD7B-\uDD82\uDD85-\uDD8B\uDDAA-\uDDAD\uDE42-\uDE44]|\uD836[\uDE00-\uDE36\uDE3B-\uDE6C\uDE75\uDE84\uDE9B-\uDE9F\uDEA1-\uDEAF]|\uD838[\uDC00-\uDC06\uDC08-\uDC18\uDC1B-\uDC21\uDC23\uDC24\uDC26-\uDC2A\uDD30-\uDD36\uDEEC-\uDEEF]|\uD83A[\uDCD0-\uDCD6\uDD44-\uDD4A]|\uD83C[\uDFFB-\uDFFF]|\uDB40[\uDC20-\uDC7F\uDD00-\uDDEF])*\u200D$/,bE=e=>e.search(kJ)!==-1,NJ=/(?:\uD83C[\uDDE6-\uDDFF])+$/g,VJ=e=>{var t=e.match(NJ);if(t===null)return!1;var r=t[0].length/2;return r%2===1},LJ={delete(e,t){e.delete(t)},insertFragment(e,t,r){e.insertFragment(t,r)},insertText(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};C.withoutNormalizing(e,()=>{var{voids:n=!1}=r,{at:o=v2(e)}=r;if(T.isPath(o)&&(o=C.range(e,o)),O.isRange(o))if(O.isCollapsed(o))o=o.anchor;else{var a=O.end(o);if(!n&&C.void(e,{at:a}))return;var s=O.start(o),u=C.pointRef(e,s),l=C.pointRef(e,a);k.delete(e,{at:o,voids:n});var c=u.unref(),p=l.unref();o=c||p,k.setSelection(e,{anchor:o,focus:o})}if(!(!n&&C.void(e,{at:o})||C.elementReadOnly(e,{at:o}))){var{path:d,offset:h}=o;t.length>0&&e.apply({type:"insert_text",path:d,offset:h,text:t})}})}};function CE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function ed(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?CE(Object(r),!0).forEach(function(n){Vt(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):CE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var k=ed(ed(ed(ed({},nJ),oJ),iJ),LJ),$J=(e,t)=>{for(var r of C.pathRefs(e))QY.transform(r,t);for(var n of C.pointRefs(e))eJ.transform(n,t);for(var o of C.rangeRefs(e))tJ.transform(o,t);var a=td.get(e)||[],s=rd.get(e)||new Set,u,l,c=v=>{if(v){var m=v.join(",");l.has(m)||(l.add(m),u.push(v))}};if(T.operationCanTransformPath(t)){u=[],l=new Set;for(var p of a){var d=T.transform(p,t);c(d)}}else u=a,l=s;var h=e.getDirtyPaths(t);for(var g of h)c(g);td.set(e,u),rd.set(e,l),k.transform(e,t),e.operations.push(t),C.normalize(e,{operation:t}),t.type==="set_selection"&&(e.marks=null),qu.get(e)||(qu.set(e,!0),Promise.resolve().then(()=>{qu.set(e,!1),e.onChange({operation:t}),e.operations=[]}))},zJ=(e,t)=>{switch(t.type){case"insert_text":case"remove_text":case"set_node":{var{path:r}=t;return T.levels(r)}case"insert_node":{var{node:n,path:o}=t,a=T.levels(o),s=J.isText(n)?[]:Array.from(W.nodes(n),M=>{var[,G]=M;return o.concat(G)});return[...a,...s]}case"merge_node":{var{path:u}=t,l=T.ancestors(u),c=T.previous(u);return[...l,c]}case"move_node":{var{path:p,newPath:d}=t;if(T.equals(p,d))return[];var h=[],g=[];for(var v of T.ancestors(p)){var m=T.transform(v,t);h.push(m)}for(var b of T.ancestors(d)){var y=T.transform(b,t);g.push(y)}var x=g[g.length-1],w=d[d.length-1],S=x.concat(w);return[...h,...g,S]}case"remove_node":{var{path:E}=t,D=T.ancestors(E);return[...D]}case"split_node":{var{path:P}=t,R=T.levels(P),F=T.next(P);return[...R,F]}default:return[]}},HJ=e=>{var{selection:t}=e;return t?W.fragment(e,t):[]},GJ=(e,t)=>{var[r,n]=t;if(!J.isText(r)){if(K.isElement(r)&&r.children.length===0){var o={text:""};k.insertNodes(e,o,{at:n.concat(0),voids:!0});return}for(var a=C.isEditor(r)?!1:K.isElement(r)&&(e.isInline(r)||r.children.length===0||J.isText(r.children[0])||e.isInline(r.children[0])),s=0,u=0;u<r.children.length;u++,s++){var l=W.get(e,n);if(!J.isText(l)){var c=l.children[s],p=l.children[s-1],d=u===r.children.length-1,h=J.isText(c)||K.isElement(c)&&e.isInline(c);if(h!==a)k.removeNodes(e,{at:n.concat(s),voids:!0}),s--;else if(K.isElement(c)){if(e.isInline(c)){if(p==null||!J.isText(p)){var g={text:""};k.insertNodes(e,g,{at:n.concat(s),voids:!0}),s++}else if(d){var v={text:""};k.insertNodes(e,v,{at:n.concat(s+1),voids:!0}),s++}}}else p!=null&&J.isText(p)&&(J.equals(c,p,{loose:!0})?(k.mergeNodes(e,{at:n.concat(s),voids:!0}),s--):p.text===""?(k.removeNodes(e,{at:n.concat(s-1),voids:!0}),s--):c.text===""&&(k.removeNodes(e,{at:n.concat(s),voids:!0}),s--))}}}},jJ=(e,t)=>{var{iteration:r,initialDirtyPathsLength:n}=t,o=n*42;if(r>o)throw new Error("Could not completely normalize the editor after ".concat(o," iterations! This is usually due to incorrect normalization logic that leaves a node in an invalid state."));return!0},_J=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{voids:n=!1,mode:o="lowest",at:a=t.selection,match:s}=r;if(a){var u=C.path(t,a),l=o==="lowest";for(var[c,p]of C.levels(t,{at:u,voids:n,match:s,reverse:l}))if(!J.isText(c)){if(O.isRange(a)){if(T.isAncestor(p,a.anchor.path)&&T.isAncestor(p,a.focus.path))return[c,p]}else if(!T.equals(u,p))return[c,p]}}};function xE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function wE(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?xE(Object(r),!0).forEach(function(n){Vt(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):xE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var WJ=(e,t,r)=>{var{selection:n}=e;if(n){var o=(d,h)=>{if(!J.isText(d))return!1;var[g,v]=C.parent(e,h);return!e.isVoid(g)||e.markableVoid(g)},a=O.isExpanded(n),s=!1;if(!a){var[u,l]=C.node(e,n);if(u&&o(u,l)){var[c]=C.parent(e,l);s=c&&e.markableVoid(c)}}if(a||s)k.setNodes(e,{[t]:r},{match:o,split:!0,voids:!0});else{var p=wE(wE({},C.marks(e)||{}),{},{[t]:r});e.marks=p,qu.get(e)||e.onChange()}}};function SE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function DE(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?SE(Object(r),!0).forEach(function(n){Vt(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):SE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var UJ=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},o=C.point(t,r,{edge:"end"}),a=C.end(t,[]),s={anchor:o,focus:a},{distance:u=1}=n,l=0,c;for(var p of C.positions(t,DE(DE({},n),{},{at:s}))){if(l>u)break;l!==0&&(c=p),l++}return c};function EE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function PE(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?EE(Object(r),!0).forEach(function(n){Vt(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):EE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var KJ=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},o=C.start(t,[]),a=C.point(t,r,{edge:"start"}),s={anchor:o,focus:a},{distance:u=1}=n,l=0,c;for(var p of C.positions(t,PE(PE({},n),{},{at:s,reverse:!0}))){if(l>u)break;l!==0&&(c=p),l++}return c},qJ=(e,t)=>{var{selection:r}=e;r&&O.isCollapsed(r)&&k.delete(e,{unit:t,reverse:!0})},XJ=(e,t)=>{var{selection:r}=e;r&&O.isCollapsed(r)&&k.delete(e,{unit:t})},YJ=function(t){var{direction:r="forward"}=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{selection:n}=t;n&&O.isExpanded(n)&&k.delete(t,{reverse:r==="backward"})},JJ=(e,t)=>[C.start(e,t),C.end(e,t)];function TE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function AE(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?TE(Object(r),!0).forEach(function(n){Vt(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):TE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var ZJ=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return C.above(t,AE(AE({},r),{},{match:n=>K.isElement(n)&&C.isElementReadOnly(t,n)}))},QJ=(e,t)=>C.point(e,t,{edge:"end"}),eZ=(e,t)=>{var r=C.path(e,t,{edge:"start"});return C.node(e,r)},tZ=(e,t)=>{var r=C.range(e,t);return W.fragment(e,r)};function RE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function FE(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?RE(Object(r),!0).forEach(function(n){Vt(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):RE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var rZ=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return C.above(t,FE(FE({},r),{},{match:n=>K.isElement(n)&&C.isVoid(t,n)}))},nZ=(e,t)=>t.children.some(r=>K.isElement(r)&&C.isBlock(e,r)),oZ=(e,t)=>t.children.some(r=>J.isText(r)||C.isInline(e,r)),iZ=(e,t)=>W.has(e,t),aZ=(e,t)=>t.children.every(r=>J.isText(r)),sZ=e=>{k.splitNodes(e,{always:!0})},uZ=(e,t,r)=>{k.insertNodes(e,t,r)},lZ=e=>{k.splitNodes(e,{always:!0})};function BE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function cZ(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?BE(Object(r),!0).forEach(function(n){Vt(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):BE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var fZ=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{selection:o,marks:a}=t;if(o){if(a){var s=cZ({text:r},a);k.insertNodes(t,s,{at:n.at,voids:n.voids})}else k.insertText(t,r,n);t.marks=null}},pZ=(e,t)=>!e.isInline(t),dZ=(e,t,r)=>C.isStart(e,t,r)||C.isEnd(e,t,r),mZ=(e,t)=>{var{children:r}=t,[n]=r;return r.length===0||r.length===1&&J.isText(n)&&n.text===""&&!e.isVoid(t)},hZ=(e,t,r)=>{var n=C.end(e,r);return ge.equals(t,n)},gZ=e=>{var t=VE.get(e);return t===void 0?!0:t},vZ=(e,t,r)=>{if(t.offset!==0)return!1;var n=C.start(e,r);return ge.equals(t,n)},yZ=(e,t)=>{var r=C.path(e,t,{edge:"end"});return C.node(e,r)},bZ=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},o=C.path(t,r,n),a=W.leaf(t,o);return[a,o]};function*CZ(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{at:r=e.selection,reverse:n=!1,voids:o=!1}=t,{match:a}=t;if(a==null&&(a=()=>!0),!!r){var s=[],u=C.path(e,r);for(var[l,c]of W.levels(e,u))if(a(l,c)&&(s.push([l,c]),!o&&K.isElement(l)&&C.isVoid(e,l)))break;n&&s.reverse(),yield*s}}var xZ=["text"],wZ=["text"],SZ=function(t){var{marks:r,selection:n}=t;if(!n)return null;if(r)return r;if(O.isExpanded(n)){var[o]=C.nodes(t,{match:J.isText});if(o){var[a]=o,s=Hn(a,xZ);return s}else return{}}var{anchor:u}=n,{path:l}=u,[c]=C.leaf(t,l);if(u.offset===0){var p=C.previous(t,{at:l,match:J.isText}),d=C.above(t,{match:y=>K.isElement(y)&&C.isVoid(t,y)&&t.markableVoid(y)});if(!d){var h=C.above(t,{match:y=>K.isElement(y)&&C.isBlock(t,y)});if(p&&h){var[g,v]=p,[,m]=h;T.isAncestor(m,v)&&(c=g)}}}var b=Hn(c,wZ);return b},DZ=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{mode:n="lowest",voids:o=!1}=r,{match:a,at:s=t.selection}=r;if(s){var u=C.after(t,s,{voids:o});if(u){var[,l]=C.last(t,[]),c=[u.path,l];if(T.isPath(s)&&s.length===0)throw new Error("Cannot get the next node from the root node!");if(a==null)if(T.isPath(s)){var[p]=C.parent(t,s);a=h=>p.children.includes(h)}else a=()=>!0;var[d]=C.nodes(t,{at:c,match:a,mode:n,voids:o});return d}}},EZ=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},o=C.path(t,r,n),a=W.get(t,o);return[a,o]};function*PZ(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{at:r=e.selection,mode:n="all",universal:o=!1,reverse:a=!1,voids:s=!1,ignoreNonSelectable:u=!1}=t,{match:l}=t;if(l||(l=()=>!0),!!r){var c,p;if(pJ.isSpan(r))c=r[0],p=r[1];else{var d=C.path(e,r,{edge:"start"}),h=C.path(e,r,{edge:"end"});c=a?h:d,p=a?d:h}var g=W.nodes(e,{reverse:a,from:c,to:p,pass:S=>{var[E]=S;return K.isElement(E)?!!(!s&&(C.isVoid(e,E)||C.isElementReadOnly(e,E))||u&&!C.isSelectable(e,E)):!1}}),v=[],m;for(var[b,y]of g)if(!(u&&K.isElement(b)&&!C.isSelectable(e,b))){var x=m&&T.compare(y,m[1])===0;if(!(n==="highest"&&x)){if(!l(b,y)){if(o&&!x&&J.isText(b))return;continue}if(n==="lowest"&&x){m=[b,y];continue}var w=n==="lowest"?m:[b,y];w&&(o?v.push(w):yield w),m=[b,y]}}n==="lowest"&&m&&(o?v.push(m):yield m),o&&(yield*v)}}var TZ=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{force:n=!1,operation:o}=r,a=p=>td.get(p)||[],s=p=>rd.get(p)||new Set,u=p=>{var d=a(p).pop(),h=d.join(",");return s(p).delete(h),d};if(C.isNormalizing(t)){if(n){var l=Array.from(W.nodes(t),p=>{var[,d]=p;return d}),c=new Set(l.map(p=>p.join(",")));td.set(t,l),rd.set(t,c)}a(t).length!==0&&C.withoutNormalizing(t,()=>{for(var p of a(t))if(W.has(t,p)){var d=C.node(t,p),[h,g]=d;K.isElement(h)&&h.children.length===0&&t.normalizeNode(d,{operation:o})}for(var v=a(t),m=v.length,b=0;v.length!==0;){if(!t.shouldNormalize({dirtyPaths:v,iteration:b,initialDirtyPathsLength:m,operation:o}))return;var y=u(t);if(W.has(t,y)){var x=C.node(t,y);t.normalizeNode(x,{operation:o})}b++,v=a(t)}})}},AZ=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},o=C.path(t,r,n),a=T.parent(o),s=C.node(t,a);return s},RZ=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{affinity:o="forward"}=n,a={current:r,affinity:o,unref(){var{current:u}=a,l=C.pathRefs(t);return l.delete(a),a.current=null,u}},s=C.pathRefs(t);return s.add(a),a},FZ=e=>{var t=aE.get(e);return t||(t=new Set,aE.set(e,t)),t},BZ=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{depth:o,edge:a}=n;if(T.isPath(r)){if(a==="start"){var[,s]=W.first(t,r);r=s}else if(a==="end"){var[,u]=W.last(t,r);r=u}}return O.isRange(r)&&(a==="start"?r=O.start(r):a==="end"?r=O.end(r):r=T.common(r.anchor.path,r.focus.path)),ge.isPoint(r)&&(r=r.path),o!=null&&(r=r.slice(0,o)),r},OZ=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{affinity:o="forward"}=n,a={current:r,affinity:o,unref(){var{current:u}=a,l=C.pointRefs(t);return l.delete(a),a.current=null,u}},s=C.pointRefs(t);return s.add(a),a},MZ=e=>{var t=sE.get(e);return t||(t=new Set,sE.set(e,t)),t},IZ=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{edge:o="start"}=n;if(T.isPath(r)){var a;if(o==="end"){var[,s]=W.last(t,r);a=s}else{var[,u]=W.first(t,r);a=u}var l=W.get(t,a);if(!J.isText(l))throw new Error("Cannot get the ".concat(o," point in the node at path [").concat(r,"] because it has no ").concat(o," text node."));return{path:a,offset:o==="end"?l.text.length:0}}if(O.isRange(r)){var[c,p]=O.edges(r);return o==="start"?c:p}return r};function*kZ(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{at:r=e.selection,unit:n="offset",reverse:o=!1,voids:a=!1,ignoreNonSelectable:s=!1}=t;if(!r)return;var u=C.range(e,r),[l,c]=O.edges(u),p=o?c:l,d=!1,h="",g=0,v=0,m=0;for(var[b,y]of C.nodes(e,{at:r,reverse:o,voids:a,ignoreNonSelectable:s})){if(K.isElement(b)){if(!a&&(e.isVoid(b)||e.isElementReadOnly(b))){yield C.start(e,y);continue}if(e.isInline(b))continue;if(C.hasInlines(e,b)){var x=T.isAncestor(y,c.path)?c:C.end(e,y),w=T.isAncestor(y,l.path)?l:C.start(e,y);h=C.string(e,{anchor:w,focus:x},{voids:a}),d=!0}}if(J.isText(b)){var S=T.equals(y,p.path);for(S?(v=o?p.offset:b.text.length-p.offset,m=p.offset):(v=b.text.length,m=o?v:0),(S||d||n==="offset")&&(yield{path:y,offset:m},d=!1);;){if(g===0){if(h==="")break;g=E(h,n,o),h=b2(h,g,o)[1]}if(m=o?m-g:m+g,v=v-g,v<0){g=-v;break}g=0,yield{path:y,offset:m}}}}function E(D,P,R){return P==="character"?y2(D,R):P==="word"?yJ(D,R):P==="line"||P==="block"?D.length:1}}var NZ=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{mode:n="lowest",voids:o=!1}=r,{match:a,at:s=t.selection}=r;if(s){var u=C.before(t,s,{voids:o});if(u){var[,l]=C.first(t,[]),c=[u.path,l];if(T.isPath(s)&&s.length===0)throw new Error("Cannot get the previous node from the root node!");if(a==null)if(T.isPath(s)){var[p]=C.parent(t,s);a=h=>p.children.includes(h)}else a=()=>!0;var[d]=C.nodes(t,{reverse:!0,at:c,match:a,mode:n,voids:o});return d}}},VZ=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{affinity:o="forward"}=n,a={current:r,affinity:o,unref(){var{current:u}=a,l=C.rangeRefs(t);return l.delete(a),a.current=null,u}},s=C.rangeRefs(t);return s.add(a),a},LZ=e=>{var t=uE.get(e);return t||(t=new Set,uE.set(e,t)),t},$Z=(e,t,r)=>{if(O.isRange(t)&&!r)return t;var n=C.start(e,t),o=C.end(e,r||t);return{anchor:n,focus:o}};function OE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function zZ(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?OE(Object(r),!0).forEach(function(n){Vt(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):OE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var HZ=(e,t)=>{var{selection:r}=e;if(r){var n=(p,d)=>{if(!J.isText(p))return!1;var[h,g]=C.parent(e,d);return!e.isVoid(h)||e.markableVoid(h)},o=O.isExpanded(r),a=!1;if(!o){var[s,u]=C.node(e,r);if(s&&n(s,u)){var[l]=C.parent(e,u);a=l&&e.markableVoid(l)}}if(o||a)k.unsetNodes(e,t,{match:n,split:!0,voids:!0});else{var c=zZ({},C.marks(e)||{});delete c[t],e.marks=c,qu.get(e)||e.onChange()}}},GZ=(e,t)=>{VE.set(e,t)},jZ=(e,t)=>C.point(e,t,{edge:"start"}),_Z=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{voids:o=!1}=n,a=C.range(t,r),[s,u]=O.edges(a),l="";for(var[c,p]of C.nodes(t,{at:a,match:J.isText,voids:o})){var d=c.text;T.equals(p,u.path)&&(d=d.slice(0,u.offset)),T.equals(p,s.path)&&(d=d.slice(s.offset)),l+=d}return l},WZ=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{voids:o=!1}=n,[a,s]=O.edges(r);if(a.offset!==0||s.offset!==0||O.isCollapsed(r)||T.hasPrevious(s.path))return r;var u=C.above(t,{at:s,match:v=>K.isElement(v)&&C.isBlock(t,v),voids:o}),l=u?u[1]:[],c=C.start(t,a),p={anchor:c,focus:s},d=!0;for(var[h,g]of C.nodes(t,{at:p,match:J.isText,reverse:!0,voids:o})){if(d){d=!1;continue}if(h.text!==""||T.isBefore(g,l)){s={path:g,offset:h.text.length};break}}return{anchor:a,focus:s}},UZ=(e,t)=>{var r=C.isNormalizing(e);C.setNormalizing(e,!1);try{t()}finally{C.setNormalizing(e,r)}C.normalize(e)},KZ=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};C.withoutNormalizing(t,()=>{var n,o,{reverse:a=!1,unit:s="character",distance:u=1,voids:l=!1}=r,{at:c=t.selection,hanging:p=!1}=r;if(c){var d=!1;if(O.isRange(c)&&O.isCollapsed(c)&&(d=!0,c=c.anchor),ge.isPoint(c)){var h=C.void(t,{at:c,mode:"highest"});if(!l&&h){var[,g]=h;c=g}else{var v={unit:s,distance:u},m=a?C.before(t,c,v)||C.start(t,[]):C.after(t,c,v)||C.end(t,[]);c={anchor:c,focus:m},p=!0}}if(T.isPath(c)){k.removeNodes(t,{at:c,voids:l});return}if(!O.isCollapsed(c)){if(!p){var[,b]=O.edges(c),y=C.end(t,[]);ge.equals(b,y)||(c=C.unhangRange(t,c,{voids:l}))}var[x,w]=O.edges(c),S=C.above(t,{match:xe=>K.isElement(xe)&&C.isBlock(t,xe),at:x,voids:l}),E=C.above(t,{match:xe=>K.isElement(xe)&&C.isBlock(t,xe),at:w,voids:l}),D=S&&E&&!T.equals(S[1],E[1]),P=T.equals(x.path,w.path),R=l?null:(n=C.void(t,{at:x,mode:"highest"}))!==null&&n!==void 0?n:C.elementReadOnly(t,{at:x,mode:"highest"}),F=l?null:(o=C.void(t,{at:w,mode:"highest"}))!==null&&o!==void 0?o:C.elementReadOnly(t,{at:w,mode:"highest"});if(R){var M=C.before(t,x);M&&S&&T.isAncestor(S[1],M.path)&&(x=M)}if(F){var G=C.after(t,w);G&&E&&T.isAncestor(E[1],G.path)&&(w=G)}var N=[],L;for(var I of C.nodes(t,{at:c,voids:l})){var[V,Y]=I;L&&T.compare(Y,L)===0||(!l&&K.isElement(V)&&(C.isVoid(t,V)||C.isElementReadOnly(t,V))||!T.isCommon(Y,x.path)&&!T.isCommon(Y,w.path))&&(N.push(I),L=Y)}var Q=Array.from(N,xe=>{var[,gt]=xe;return C.pathRef(t,gt)}),re=C.pointRef(t,x),H=C.pointRef(t,w),le="";if(!P&&!R){var ve=re.current,[me]=C.leaf(t,ve),{path:Ge}=ve,{offset:A}=x,_=me.text.slice(A);_.length>0&&(t.apply({type:"remove_text",path:Ge,offset:A,text:_}),le=_)}if(Q.reverse().map(xe=>xe.unref()).filter(xe=>xe!==null).forEach(xe=>k.removeNodes(t,{at:xe,voids:l})),!F){var z=H.current,[j]=C.leaf(t,z),{path:ue}=z,oe=P?x.offset:0,he=j.text.slice(oe,w.offset);he.length>0&&(t.apply({type:"remove_text",path:ue,offset:oe,text:he}),le=he)}!P&&D&&H.current&&re.current&&k.mergeNodes(t,{at:H.current,hanging:!0,voids:l}),d&&a&&s==="character"&&le.length>1&&le.match(/[\u0E00-\u0E7F]+/)&&k.insertText(t,le.slice(0,le.length-u));var Ce=re.unref(),Se=H.unref(),Ee=a?Ce||Se:Se||Ce;r.at==null&&Ee&&k.select(t,Ee)}}})},qZ=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};C.withoutNormalizing(t,()=>{var{hanging:o=!1,voids:a=!1}=n,{at:s=v2(t)}=n;if(r.length){if(O.isRange(s))if(o||(s=C.unhangRange(t,s,{voids:a})),O.isCollapsed(s))s=s.anchor;else{var[,u]=O.edges(s);if(!a&&C.void(t,{at:u}))return;var l=C.pointRef(t,u);k.delete(t,{at:s}),s=l.unref()}else T.isPath(s)&&(s=C.start(t,s));if(!(!a&&C.void(t,{at:s}))){var c=C.above(t,{at:s,match:A=>K.isElement(A)&&C.isInline(t,A),mode:"highest",voids:a});if(c){var[,p]=c;if(C.isEnd(t,s,p)){var d=C.after(t,p);s=d}else if(C.isStart(t,s,p)){var h=C.before(t,p);s=h}}var g=C.above(t,{match:A=>K.isElement(A)&&C.isBlock(t,A),at:s,voids:a}),[,v]=g,m=C.isStart(t,s,v),b=C.isEnd(t,s,v),y=m&&b,x=!m||m&&b,w=!b,[,S]=W.first({children:r},[]),[,E]=W.last({children:r},[]),D=[],P=A=>{var[_,z]=A,j=z.length===0;return j?!1:y?!0:!(x&&T.isAncestor(z,S)&&K.isElement(_)&&!t.isVoid(_)&&!t.isInline(_)||w&&T.isAncestor(z,E)&&K.isElement(_)&&!t.isVoid(_)&&!t.isInline(_))};for(var R of W.nodes({children:r},{pass:P}))P(R)&&D.push(R);var F=[],M=[],G=[],N=!0,L=!1;for(var[I]of D)K.isElement(I)&&!t.isInline(I)?(N=!1,L=!0,M.push(I)):N?F.push(I):G.push(I);var[V]=C.nodes(t,{at:s,match:A=>J.isText(A)||C.isInline(t,A),mode:"highest",voids:a}),[,Y]=V,Q=C.isStart(t,s,Y),re=C.isEnd(t,s,Y),H=C.pathRef(t,b&&!G.length?T.next(v):v),le=C.pathRef(t,re?T.next(Y):Y);k.splitNodes(t,{at:s,match:A=>L?K.isElement(A)&&C.isBlock(t,A):J.isText(A)||C.isInline(t,A),mode:L?"lowest":"highest",always:L&&(!m||F.length>0)&&(!b||G.length>0),voids:a});var ve=C.pathRef(t,!Q||Q&&re?T.next(Y):Y);if(k.insertNodes(t,F,{at:ve.current,match:A=>J.isText(A)||C.isInline(t,A),mode:"highest",voids:a}),y&&!F.length&&M.length&&!G.length&&k.delete(t,{at:v,voids:a}),k.insertNodes(t,M,{at:H.current,match:A=>K.isElement(A)&&C.isBlock(t,A),mode:"lowest",voids:a}),k.insertNodes(t,G,{at:le.current,match:A=>J.isText(A)||C.isInline(t,A),mode:"highest",voids:a}),!n.at){var me;if(G.length>0&&le.current?me=T.previous(le.current):M.length>0&&H.current?me=T.previous(H.current):ve.current&&(me=T.previous(ve.current)),me){var Ge=C.end(t,me);k.select(t,Ge)}}ve.unref(),H.unref(),le.unref()}}})},XZ=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{edge:n="anchor"}=r,{selection:o}=t;if(o){if(n==="anchor")k.select(t,o.anchor);else if(n==="focus")k.select(t,o.focus);else if(n==="start"){var[a]=O.edges(o);k.select(t,a)}else if(n==="end"){var[,s]=O.edges(o);k.select(t,s)}}else return},YZ=e=>{var{selection:t}=e;t&&e.apply({type:"set_selection",properties:t,newProperties:null})},JZ=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{selection:n}=t,{distance:o=1,unit:a="character",reverse:s=!1}=r,{edge:u=null}=r;if(n){u==="start"&&(u=O.isBackward(n)?"focus":"anchor"),u==="end"&&(u=O.isBackward(n)?"anchor":"focus");var{anchor:l,focus:c}=n,p={distance:o,unit:a,ignoreNonSelectable:!0},d={};if(u==null||u==="anchor"){var h=s?C.before(t,l,p):C.after(t,l,p);h&&(d.anchor=h)}if(u==null||u==="focus"){var g=s?C.before(t,c,p):C.after(t,c,p);g&&(d.focus=g)}k.setSelection(t,d)}},ZZ=(e,t)=>{var{selection:r}=e;if(t=C.range(e,t),r){k.setSelection(e,t);return}if(!O.isRange(t))throw new Error("When setting the selection and the current selection is `null` you must provide at least an `anchor` and `focus`, but you passed: ".concat(it.stringify(t)));e.apply({type:"set_selection",properties:r,newProperties:t})};function ME(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function IE(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?ME(Object(r),!0).forEach(function(n){Vt(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):ME(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var QZ=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{selection:o}=t,{edge:a="both"}=n;if(o){a==="start"&&(a=O.isBackward(o)?"focus":"anchor"),a==="end"&&(a=O.isBackward(o)?"anchor":"focus");var{anchor:s,focus:u}=o,l=a==="anchor"?s:u;k.setSelection(t,{[a==="anchor"?"anchor":"focus"]:IE(IE({},l),r)})}},eQ=(e,t)=>{var{selection:r}=e,n={},o={};if(r){for(var a in t)(a==="anchor"&&t.anchor!=null&&!ge.equals(t.anchor,r.anchor)||a==="focus"&&t.focus!=null&&!ge.equals(t.focus,r.focus)||a!=="anchor"&&a!=="focus"&&t[a]!==r[a])&&(n[a]=r[a],o[a]=t[a]);Object.keys(n).length>0&&e.apply({type:"set_selection",properties:n,newProperties:o})}},tQ=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};C.withoutNormalizing(t,()=>{var{hanging:o=!1,voids:a=!1,mode:s="lowest"}=n,{at:u,match:l,select:c}=n;if(W.isNode(r)&&(r=[r]),r.length!==0){var[p]=r;if(u||(u=v2(t),c=!0),c==null&&(c=!1),O.isRange(u))if(o||(u=C.unhangRange(t,u,{voids:a})),O.isCollapsed(u))u=u.anchor;else{var[,d]=O.edges(u),h=C.pointRef(t,d);k.delete(t,{at:u}),u=h.unref()}if(ge.isPoint(u)){l==null&&(J.isText(p)?l=P=>J.isText(P):t.isInline(p)?l=P=>J.isText(P)||C.isInline(t,P):l=P=>K.isElement(P)&&C.isBlock(t,P));var[g]=C.nodes(t,{at:u.path,match:l,mode:s,voids:a});if(g){var[,v]=g,m=C.pathRef(t,v),b=C.isEnd(t,u,v);k.splitNodes(t,{at:u,match:l,mode:s,voids:a});var y=m.unref();u=b?T.next(y):y}else return}var x=T.parent(u),w=u[u.length-1];if(!(!a&&C.void(t,{at:x}))){for(var S of r){var E=x.concat(w);w++,t.apply({type:"insert_node",path:E,node:S}),u=T.next(u)}if(u=T.previous(u),c){var D=C.end(t,u);D&&k.select(t,D)}}}})},rQ=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};C.withoutNormalizing(t,()=>{var{at:n=t.selection,mode:o="lowest",voids:a=!1}=r,{match:s}=r;if(s==null&&(s=T.isPath(n)?is(t,n):S=>K.isElement(S)&&C.isBlock(t,S)),!!n){var u=C.nodes(t,{at:n,match:s,mode:o,voids:a}),l=Array.from(u,S=>{var[,E]=S;return C.pathRef(t,E)});for(var c of l){var p=c.unref();if(p.length<2)throw new Error("Cannot lift node at a path [".concat(p,"] because it has a depth of less than `2`."));var d=C.node(t,T.parent(p)),[h,g]=d,v=p[p.length-1],{length:m}=h.children;if(m===1){var b=T.next(g);k.moveNodes(t,{at:p,to:b,voids:a}),k.removeNodes(t,{at:g,voids:a})}else if(v===0)k.moveNodes(t,{at:p,to:g,voids:a});else if(v===m-1){var y=T.next(g);k.moveNodes(t,{at:p,to:y,voids:a})}else{var x=T.next(p),w=T.next(g);k.splitNodes(t,{at:x,voids:a}),k.moveNodes(t,{at:p,to:w,voids:a})}}}})},nQ=["text"],oQ=["children"],$E=(e,t)=>{if(K.isElement(t)){var r=t;return C.isVoid(e,t)?!0:r.children.length===1?$E(e,r.children[0]):!1}else return!C.isEditor(t)},iQ=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};C.withoutNormalizing(t,()=>{var{match:n,at:o=t.selection}=r,{hanging:a=!1,voids:s=!1,mode:u="lowest"}=r;if(o){if(n==null)if(T.isPath(o)){var[l]=C.parent(t,o);n=M=>l.children.includes(M)}else n=M=>K.isElement(M)&&C.isBlock(t,M);if(!a&&O.isRange(o)&&(o=C.unhangRange(t,o,{voids:s})),O.isRange(o))if(O.isCollapsed(o))o=o.anchor;else{var[,c]=O.edges(o),p=C.pointRef(t,c);k.delete(t,{at:o}),o=p.unref(),r.at==null&&k.select(t,o)}var[d]=C.nodes(t,{at:o,match:n,voids:s,mode:u}),h=C.previous(t,{at:o,match:n,voids:s,mode:u});if(!(!d||!h)){var[g,v]=d,[m,b]=h;if(!(v.length===0||b.length===0)){var y=T.next(b),x=T.common(v,b),w=T.isSibling(v,b),S=Array.from(C.levels(t,{at:v}),M=>{var[G]=M;return G}).slice(x.length).slice(0,-1),E=C.above(t,{at:v,mode:"highest",match:M=>S.includes(M)&&$E(t,M)}),D=E&&C.pathRef(t,E[1]),P,R;if(J.isText(g)&&J.isText(m)){var F=Hn(g,nQ);R=m.text.length,P=F}else if(K.isElement(g)&&K.isElement(m)){var F=Hn(g,oQ);R=m.children.length,P=F}else throw new Error("Cannot merge the node at path [".concat(v,"] with the previous sibling because it is not the same kind: ").concat(it.stringify(g)," ").concat(it.stringify(m)));w||k.moveNodes(t,{at:v,to:y,voids:s}),D&&k.removeNodes(t,{at:D.current,voids:s}),K.isElement(m)&&C.isEmpty(t,m)||J.isText(m)&&m.text===""&&b[b.length-1]!==0?k.removeNodes(t,{at:b,voids:s}):t.apply({type:"merge_node",path:y,position:R,properties:P}),D&&D.unref()}}}})},aQ=(e,t)=>{C.withoutNormalizing(e,()=>{var{to:r,at:n=e.selection,mode:o="lowest",voids:a=!1}=t,{match:s}=t;if(n){s==null&&(s=T.isPath(n)?is(e,n):g=>K.isElement(g)&&C.isBlock(e,g));var u=C.pathRef(e,r),l=C.nodes(e,{at:n,match:s,mode:o,voids:a}),c=Array.from(l,g=>{var[,v]=g;return C.pathRef(e,v)});for(var p of c){var d=p.unref(),h=u.current;d.length!==0&&e.apply({type:"move_node",path:d,newPath:h}),u.current&&T.isSibling(h,d)&&T.isAfter(h,d)&&(u.current=T.next(u.current))}u.unref()}})},sQ=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};C.withoutNormalizing(t,()=>{var{hanging:n=!1,voids:o=!1,mode:a="lowest"}=r,{at:s=t.selection,match:u}=r;if(s){u==null&&(u=T.isPath(s)?is(t,s):g=>K.isElement(g)&&C.isBlock(t,g)),!n&&O.isRange(s)&&(s=C.unhangRange(t,s,{voids:o}));var l=C.nodes(t,{at:s,match:u,mode:a,voids:o}),c=Array.from(l,g=>{var[,v]=g;return C.pathRef(t,v)});for(var p of c){var d=p.unref();if(d){var[h]=C.node(t,d);t.apply({type:"remove_node",path:d,node:h})}}}})},uQ=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};C.withoutNormalizing(t,()=>{var{match:o,at:a=t.selection,compare:s,merge:u}=n,{hanging:l=!1,mode:c="lowest",split:p=!1,voids:d=!1}=n;if(a){if(o==null&&(o=T.isPath(a)?is(t,a):R=>K.isElement(R)&&C.isBlock(t,R)),!l&&O.isRange(a)&&(a=C.unhangRange(t,a,{voids:d})),p&&O.isRange(a)){if(O.isCollapsed(a)&&C.leaf(t,a.anchor)[0].text.length>0)return;var h=C.rangeRef(t,a,{affinity:"inward"}),[g,v]=O.edges(a),m=c==="lowest"?"lowest":"highest",b=C.isEnd(t,v,v.path);k.splitNodes(t,{at:v,match:o,mode:m,voids:d,always:!b});var y=C.isStart(t,g,g.path);k.splitNodes(t,{at:g,match:o,mode:m,voids:d,always:!y}),a=h.unref(),n.at==null&&k.select(t,a)}s||(s=(R,F)=>R!==F);for(var[x,w]of C.nodes(t,{at:a,match:o,mode:c,voids:d})){var S={},E={};if(w.length!==0){var D=!1;for(var P in r)P==="children"||P==="text"||s(r[P],x[P])&&(D=!0,x.hasOwnProperty(P)&&(S[P]=x[P]),u?r[P]!=null&&(E[P]=u(x[P],r[P])):r[P]!=null&&(E[P]=r[P]));D&&t.apply({type:"set_node",path:w,properties:S,newProperties:E})}}}})},lQ=(e,t)=>{if(O.isCollapsed(t))return t.anchor;var[,r]=O.edges(t),n=C.pointRef(e,r);return k.delete(e,{at:t}),n.unref()},cQ=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};C.withoutNormalizing(t,()=>{var{mode:n="lowest",voids:o=!1}=r,{match:a,at:s=t.selection,height:u=0,always:l=!1}=r;if(a==null&&(a=H=>K.isElement(H)&&C.isBlock(t,H)),O.isRange(s)&&(s=lQ(t,s)),T.isPath(s)){var c=s,p=C.point(t,c),[d]=C.parent(t,c);a=H=>H===d,u=p.path.length-c.length+1,s=p,l=!0}if(s){var h=C.pointRef(t,s,{affinity:"backward"}),g;try{var[v]=C.nodes(t,{at:s,match:a,mode:n,voids:o});if(!v)return;var m=C.void(t,{at:s,mode:"highest"}),b=0;if(!o&&m){var[y,x]=m;if(K.isElement(y)&&t.isInline(y)){var w=C.after(t,x);if(!w){var S={text:""},E=T.next(x);k.insertNodes(t,S,{at:E,voids:o}),w=C.point(t,E)}s=w,l=!0}var D=s.path.length-x.length;u=D+1,l=!0}g=C.pointRef(t,s);var P=s.path.length-u,[,R]=v,F=s.path.slice(0,P),M=u===0?s.offset:s.path[P]+b;for(var[G,N]of C.levels(t,{at:F,reverse:!0,voids:o})){var L=!1;if(N.length<R.length||N.length===0||!o&&K.isElement(G)&&C.isVoid(t,G))break;var I=h.current,V=C.isEnd(t,I,N);if(l||!h||!C.isEdge(t,I,N)){L=!0;var Y=W.extractProps(G);t.apply({type:"split_node",path:N,position:M,properties:Y})}M=N[N.length-1]+(L||V?1:0)}if(r.at==null){var Q=g.current||C.end(t,[]);k.select(t,Q)}}finally{var re;h.unref(),(re=g)===null||re===void 0||re.unref()}}})},fQ=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};Array.isArray(r)||(r=[r]);var o={};for(var a of r)o[a]=null;k.setNodes(t,o,n)},pQ=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};C.withoutNormalizing(t,()=>{var{mode:n="lowest",split:o=!1,voids:a=!1}=r,{at:s=t.selection,match:u}=r;if(s){u==null&&(u=T.isPath(s)?is(t,s):g=>K.isElement(g)&&C.isBlock(t,g)),T.isPath(s)&&(s=C.range(t,s));var l=O.isRange(s)?C.rangeRef(t,s):null,c=C.nodes(t,{at:s,match:u,mode:n,voids:a}),p=Array.from(c,g=>{var[,v]=g;return C.pathRef(t,v)}).reverse(),d=function(v){var m=v.unref(),[b]=C.node(t,m),y=C.range(t,m);o&&l&&(y=O.intersection(l.current,y)),k.liftNodes(t,{at:y,match:x=>K.isAncestor(b)&&b.children.includes(x),voids:a})};for(var h of p)d(h);l&&l.unref()}})};function kE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function NE(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?kE(Object(r),!0).forEach(function(n){Vt(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):kE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var dQ=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};C.withoutNormalizing(t,()=>{var{mode:o="lowest",split:a=!1,voids:s=!1}=n,{match:u,at:l=t.selection}=n;if(l){if(u==null&&(T.isPath(l)?u=is(t,l):t.isInline(r)?u=y=>K.isElement(y)&&C.isInline(t,y)||J.isText(y):u=y=>K.isElement(y)&&C.isBlock(t,y)),a&&O.isRange(l)){var[c,p]=O.edges(l),d=C.rangeRef(t,l,{affinity:"inward"});k.splitNodes(t,{at:p,match:u,voids:s}),k.splitNodes(t,{at:c,match:u,voids:s}),l=d.unref(),n.at==null&&k.select(t,l)}var h=Array.from(C.nodes(t,{at:l,match:t.isInline(r)?y=>K.isElement(y)&&C.isBlock(t,y):y=>C.isEditor(y),mode:"lowest",voids:s}));for(var[,g]of h){var v=O.isRange(l)?O.intersection(l,C.range(t,g)):l;if(v){var m=Array.from(C.nodes(t,{at:v,match:u,mode:o,voids:s}));if(m.length>0){var b=function(){var[y]=m,x=m[m.length-1],[,w]=y,[,S]=x;if(w.length===0&&S.length===0)return"continue";var E=T.equals(w,S)?T.parent(w):T.common(w,S),D=C.range(t,w,S),P=C.node(t,E),[R]=P,F=E.length+1,M=T.next(S.slice(0,F)),G=NE(NE({},r),{},{children:[]});k.insertNodes(t,G,{at:M,voids:s}),k.moveNodes(t,{at:D,match:N=>K.isAncestor(R)&&R.children.includes(N),to:M.concat(0),voids:s})}();if(b==="continue")continue}}}}})},nd=()=>{var e={children:[],operations:[],selection:null,marks:null,isElementReadOnly:()=>!1,isInline:()=>!1,isSelectable:()=>!0,isVoid:()=>!1,markableVoid:()=>!1,onChange:()=>{},apply:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return $J(e,...n)},addMark:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return WJ(e,...n)},deleteBackward:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return qJ(e,...n)},deleteForward:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return XJ(e,...n)},deleteFragment:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return YJ(e,...n)},getFragment:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return HJ(e,...n)},insertBreak:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return sZ(e,...n)},insertSoftBreak:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return lZ(e,...n)},insertFragment:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return qZ(e,...n)},insertNode:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return uZ(e,...n)},insertText:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return fZ(e,...n)},normalizeNode:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return GJ(e,...n)},removeMark:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return HZ(e,...n)},getDirtyPaths:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return zJ(e,...n)},shouldNormalize:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return jJ(e,...n)},above:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return _J(e,...n)},after:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return UJ(e,...n)},before:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return KJ(e,...n)},collapse:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return XZ(e,...n)},delete:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return KZ(e,...n)},deselect:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return YZ(e,...n)},edges:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return JJ(e,...n)},elementReadOnly:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return ZJ(e,...n)},end:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return QJ(e,...n)},first:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return eZ(e,...n)},fragment:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return tZ(e,...n)},getMarks:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return SZ(e,...n)},hasBlocks:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return nZ(e,...n)},hasInlines:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return oZ(e,...n)},hasPath:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return iZ(e,...n)},hasTexts:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return aZ(e,...n)},insertNodes:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return tQ(e,...n)},isBlock:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return pZ(e,...n)},isEdge:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return dZ(e,...n)},isEmpty:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return mZ(e,...n)},isEnd:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return hZ(e,...n)},isNormalizing:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return gZ(e,...n)},isStart:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return vZ(e,...n)},last:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return yZ(e,...n)},leaf:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return bZ(e,...n)},levels:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return CZ(e,...n)},liftNodes:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return rQ(e,...n)},mergeNodes:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return iQ(e,...n)},move:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return JZ(e,...n)},moveNodes:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return aQ(e,...n)},next:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return DZ(e,...n)},node:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return EZ(e,...n)},nodes:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return PZ(e,...n)},normalize:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return TZ(e,...n)},parent:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return AZ(e,...n)},path:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return BZ(e,...n)},pathRef:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return RZ(e,...n)},pathRefs:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return FZ(e,...n)},point:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return IZ(e,...n)},pointRef:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return OZ(e,...n)},pointRefs:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return MZ(e,...n)},positions:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return kZ(e,...n)},previous:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return NZ(e,...n)},range:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return $Z(e,...n)},rangeRef:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return VZ(e,...n)},rangeRefs:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return LZ(e,...n)},removeNodes:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return sQ(e,...n)},select:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return ZZ(e,...n)},setNodes:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return uQ(e,...n)},setNormalizing:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return GZ(e,...n)},setPoint:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return QZ(e,...n)},setSelection:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return eQ(e,...n)},splitNodes:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return cQ(e,...n)},start:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return jZ(e,...n)},string:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return _Z(e,...n)},unhangRange:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return WZ(e,...n)},unsetNodes:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return fQ(e,...n)},unwrapNodes:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return pQ(e,...n)},void:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return rZ(e,...n)},withoutNormalizing:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return UZ(e,...n)},wrapNodes:function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return dQ(e,...n)}};return e};i();i();i();i();i();i();i();var Er=[];var zE=function(){return Er.some(function(e){return e.activeTargets.length>0})};i();var HE=function(){return Er.some(function(e){return e.skippedTargets.length>0})};i();var GE="ResizeObserver loop completed with undelivered notifications.",jE=function(){var e;typeof ErrorEvent=="function"?e=new ErrorEvent("error",{message:GE}):(e=document.createEvent("Event"),e.initEvent("error",!1,!1),e.message=GE),window.dispatchEvent(e)};i();i();i();i();var Ei;(function(e){e.BORDER_BOX="border-box",e.CONTENT_BOX="content-box",e.DEVICE_PIXEL_CONTENT_BOX="device-pixel-content-box"})(Ei||(Ei={}));i();i();var Hr=function(e){return Object.freeze(e)};var C2=function(){function e(t,r){this.inlineSize=t,this.blockSize=r,Hr(this)}return e}();i();var x2=function(){function e(t,r,n,o){return this.x=t,this.y=r,this.width=n,this.height=o,this.top=this.y,this.left=this.x,this.bottom=this.top+this.height,this.right=this.left+this.width,Hr(this)}return e.prototype.toJSON=function(){var t=this,r=t.x,n=t.y,o=t.top,a=t.right,s=t.bottom,u=t.left,l=t.width,c=t.height;return{x:r,y:n,top:o,right:a,bottom:s,left:u,width:l,height:c}},e.fromRect=function(t){return new e(t.x,t.y,t.width,t.height)},e}();i();var Xu=function(e){return e instanceof SVGElement&&"getBBox"in e},od=function(e){if(Xu(e)){var t=e.getBBox(),r=t.width,n=t.height;return!r&&!n}var o=e,a=o.offsetWidth,s=o.offsetHeight;return!(a||s||e.getClientRects().length)},w2=function(e){var t;if(e instanceof Element)return!0;var r=(t=e?.ownerDocument)===null||t===void 0?void 0:t.defaultView;return!!(r&&e instanceof r.Element)},_E=function(e){switch(e.tagName){case"INPUT":if(e.type!=="image")break;case"VIDEO":case"AUDIO":case"EMBED":case"OBJECT":case"CANVAS":case"IFRAME":case"IMG":return!0}return!1};i();var Pi=typeof window<"u"?window:{};var id=new WeakMap,WE=/auto|scroll/,mQ=/^tb|vertical/,hQ=/msie|trident/i.test(Pi.navigator&&Pi.navigator.userAgent),an=function(e){return parseFloat(e||"0")},as=function(e,t,r){return e===void 0&&(e=0),t===void 0&&(t=0),r===void 0&&(r=!1),new C2((r?t:e)||0,(r?e:t)||0)},UE=Hr({devicePixelContentBoxSize:as(),borderBoxSize:as(),contentBoxSize:as(),contentRect:new x2(0,0,0,0)}),S2=function(e,t){if(t===void 0&&(t=!1),id.has(e)&&!t)return id.get(e);if(od(e))return id.set(e,UE),UE;var r=getComputedStyle(e),n=Xu(e)&&e.ownerSVGElement&&e.getBBox(),o=!hQ&&r.boxSizing==="border-box",a=mQ.test(r.writingMode||""),s=!n&&WE.test(r.overflowY||""),u=!n&&WE.test(r.overflowX||""),l=n?0:an(r.paddingTop),c=n?0:an(r.paddingRight),p=n?0:an(r.paddingBottom),d=n?0:an(r.paddingLeft),h=n?0:an(r.borderTopWidth),g=n?0:an(r.borderRightWidth),v=n?0:an(r.borderBottomWidth),m=n?0:an(r.borderLeftWidth),b=d+c,y=l+p,x=m+g,w=h+v,S=u?e.offsetHeight-w-e.clientHeight:0,E=s?e.offsetWidth-x-e.clientWidth:0,D=o?b+x:0,P=o?y+w:0,R=n?n.width:an(r.width)-D-E,F=n?n.height:an(r.height)-P-S,M=R+b+E+x,G=F+y+S+w,N=Hr({devicePixelContentBoxSize:as(Math.round(R*devicePixelRatio),Math.round(F*devicePixelRatio),a),borderBoxSize:as(M,G,a),contentBoxSize:as(R,F,a),contentRect:new x2(d,l,R,F)});return id.set(e,N),N},ad=function(e,t,r){var n=S2(e,r),o=n.borderBoxSize,a=n.contentBoxSize,s=n.devicePixelContentBoxSize;switch(t){case Ei.DEVICE_PIXEL_CONTENT_BOX:return s;case Ei.BORDER_BOX:return o;default:return a}};var D2=function(){function e(t){var r=S2(t);this.target=t,this.contentRect=r.contentRect,this.borderBoxSize=Hr([r.borderBoxSize]),this.contentBoxSize=Hr([r.contentBoxSize]),this.devicePixelContentBoxSize=Hr([r.devicePixelContentBoxSize])}return e}();i();var sd=function(e){if(od(e))return 1/0;for(var t=0,r=e.parentNode;r;)t+=1,r=r.parentNode;return t};var KE=function(){var e=1/0,t=[];Er.forEach(function(s){if(s.activeTargets.length!==0){var u=[];s.activeTargets.forEach(function(c){var p=new D2(c.target),d=sd(c.target);u.push(p),c.lastReportedSize=ad(c.target,c.observedBox),d<e&&(e=d)}),t.push(function(){s.callback.call(s.observer,u,s.observer)}),s.activeTargets.splice(0,s.activeTargets.length)}});for(var r=0,n=t;r<n.length;r++){var o=n[r];o()}return e};i();var E2=function(e){Er.forEach(function(r){r.activeTargets.splice(0,r.activeTargets.length),r.skippedTargets.splice(0,r.skippedTargets.length),r.observationTargets.forEach(function(o){o.isActive()&&(sd(o.target)>e?r.activeTargets.push(o):r.skippedTargets.push(o))})})};var qE=function(){var e=0;for(E2(e);zE();)e=KE(),E2(e);return HE()&&jE(),e>0};i();i();var P2,XE=[],gQ=function(){return XE.splice(0).forEach(function(e){return e()})},YE=function(e){if(!P2){var t=0,r=document.createTextNode(""),n={characterData:!0};new MutationObserver(function(){return gQ()}).observe(r,n),P2=function(){r.textContent="".concat(t?t--:t++)}}XE.push(e),P2()};var JE=function(e){YE(function(){requestAnimationFrame(e)})};var ud=0,vQ=function(){return!!ud},yQ=250,bQ={attributes:!0,characterData:!0,childList:!0,subtree:!0},ZE=["resize","load","transitionend","animationend","animationstart","animationiteration","keyup","keydown","mouseup","mousedown","mouseover","mouseout","blur","focus"],QE=function(e){return e===void 0&&(e=0),Date.now()+e},T2=!1,CQ=function(){function e(){var t=this;this.stopped=!0,this.listener=function(){return t.schedule()}}return e.prototype.run=function(t){var r=this;if(t===void 0&&(t=yQ),!T2){T2=!0;var n=QE(t);JE(function(){var o=!1;try{o=qE()}finally{if(T2=!1,t=n-QE(),!vQ())return;o?r.run(1e3):t>0?r.run(t):r.start()}})}},e.prototype.schedule=function(){this.stop(),this.run()},e.prototype.observe=function(){var t=this,r=function(){return t.observer&&t.observer.observe(document.body,bQ)};document.body?r():Pi.addEventListener("DOMContentLoaded",r)},e.prototype.start=function(){var t=this;this.stopped&&(this.stopped=!1,this.observer=new MutationObserver(this.listener),this.observe(),ZE.forEach(function(r){return Pi.addEventListener(r,t.listener,!0)}))},e.prototype.stop=function(){var t=this;this.stopped||(this.observer&&this.observer.disconnect(),ZE.forEach(function(r){return Pi.removeEventListener(r,t.listener,!0)}),this.stopped=!0)},e}(),ld=new CQ,A2=function(e){!ud&&e>0&&ld.start(),ud+=e,!ud&&ld.stop()};i();var xQ=function(e){return!Xu(e)&&!_E(e)&&getComputedStyle(e).display==="inline"},eP=function(){function e(t,r){this.target=t,this.observedBox=r||Ei.CONTENT_BOX,this.lastReportedSize={inlineSize:0,blockSize:0}}return e.prototype.isActive=function(){var t=ad(this.target,this.observedBox,!0);return xQ(this.target)&&(this.lastReportedSize=t),this.lastReportedSize.inlineSize!==t.inlineSize||this.lastReportedSize.blockSize!==t.blockSize},e}();i();var tP=function(){function e(t,r){this.activeTargets=[],this.skippedTargets=[],this.observationTargets=[],this.observer=t,this.callback=r}return e}();var cd=new WeakMap,rP=function(e,t){for(var r=0;r<e.length;r+=1)if(e[r].target===t)return r;return-1},Yu=function(){function e(){}return e.connect=function(t,r){var n=new tP(t,r);cd.set(t,n)},e.observe=function(t,r,n){var o=cd.get(t),a=o.observationTargets.length===0;rP(o.observationTargets,r)<0&&(a&&Er.push(o),o.observationTargets.push(new eP(r,n&&n.box)),A2(1),ld.schedule())},e.unobserve=function(t,r){var n=cd.get(t),o=rP(n.observationTargets,r),a=n.observationTargets.length===1;o>=0&&(a&&Er.splice(Er.indexOf(n),1),n.observationTargets.splice(o,1),A2(-1))},e.disconnect=function(t){var r=this,n=cd.get(t);n.observationTargets.slice().forEach(function(o){return r.unobserve(t,o.target)}),n.activeTargets.splice(0,n.activeTargets.length)},e}();var R2=function(){function e(t){if(arguments.length===0)throw new TypeError("Failed to construct 'ResizeObserver': 1 argument required, but only 0 present.");if(typeof t!="function")throw new TypeError("Failed to construct 'ResizeObserver': The callback provided as parameter 1 is not a function.");Yu.connect(this,t)}return e.prototype.observe=function(t,r){if(arguments.length===0)throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!w2(t))throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': parameter 1 is not of type 'Element");Yu.observe(this,t,r)},e.prototype.unobserve=function(t){if(arguments.length===0)throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!w2(t))throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': parameter 1 is not of type 'Element");Yu.unobserve(this,t)},e.prototype.disconnect=function(){Yu.disconnect(this)},e.toString=function(){return"function ResizeObserver () { [polyfill code] }"},e}();var md=U(sP());import BQ from"react-dom";function bd(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function OQ(e,t){if(e==null)return{};var r={},n=Object.keys(e),o,a;for(a=0;a<n.length;a++)o=n[a],!(t.indexOf(o)>=0)&&(r[o]=e[o]);return r}function ls(e,t){if(e==null)return{};var r=OQ(e,t),n,o;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(o=0;o<a.length;o++)n=a[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}var H2=Bi(null),Lo=()=>{var e=fs(H2);if(!e)throw new Error("The `useSlateStatic` hook must be used inside the <Slate> component's context.");return e},SP=parseInt(de.version.split(".")[0],10),MQ=typeof navigator<"u"&&typeof window<"u"&&/iPad|iPhone|iPod/.test(navigator.userAgent)&&!window.MSStream,uP=typeof navigator<"u"&&/Mac OS X/.test(navigator.userAgent),Qt=typeof navigator<"u"&&/Android/.test(navigator.userAgent),Qu=typeof navigator<"u"&&/^(?!.*Seamonkey)(?=.*Firefox).*/i.test(navigator.userAgent),Zu=typeof navigator<"u"&&/AppleWebKit(?!.*Chrome)/i.test(navigator.userAgent),IQ=typeof navigator<"u"&&/Edge?\/(?:[0-6][0-9]|[0-7][0-8])(?:\.)/i.test(navigator.userAgent),DP=typeof navigator<"u"&&/Chrome/i.test(navigator.userAgent),kQ=typeof navigator<"u"&&/Chrome?\/(?:[0-7][0-5]|[0-6][0-9])(?:\.)/i.test(navigator.userAgent),NQ=Qt&&typeof navigator<"u"&&/Chrome?\/(?:[0-5]?\d)(?:\.)/i.test(navigator.userAgent),VQ=typeof navigator<"u"&&/^(?!.*Seamonkey)(?=.*Firefox\/(?:[0-7][0-9]|[0-8][0-6])(?:\.)).*/i.test(navigator.userAgent),LQ=typeof navigator<"u"&&/.*UCBrowser/.test(navigator.userAgent),$Q=typeof navigator<"u"&&/.*Wechat/.test(navigator.userAgent)&&!/.*MacWechat/.test(navigator.userAgent),hd=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",Io=(!kQ||!NQ)&&!IQ&&typeof globalThis<"u"&&globalThis.InputEvent&&typeof globalThis.InputEvent.prototype.getTargetRanges=="function",G2=new WeakMap,j2=new WeakMap,EP=new WeakMap,gd=new WeakMap,M2=new WeakMap,tl=new WeakMap,Ri=new WeakMap,vd=new WeakMap,Cd=new WeakMap,I2=new WeakMap,Ti=new WeakMap,Ai=new WeakMap,el=new WeakMap,k2=new WeakMap,_2=new WeakMap,Gr=new WeakMap,Gn=new WeakMap,Zt=new WeakMap,ko=new WeakMap,No=new WeakMap,PP=new WeakMap,cs=Symbol("placeholder"),TP=Symbol("mark-placeholder"),zQ=globalThis.Text,W2=e=>e&&e.ownerDocument&&e.ownerDocument.defaultView||null,HQ=e=>Vo(e)&&e.nodeType===8,Pr=e=>Vo(e)&&e.nodeType===1,Vo=e=>{var t=W2(e);return!!t&&e instanceof t.Node},N2=e=>{var t=e&&e.anchorNode&&W2(e.anchorNode);return!!t&&e instanceof t.Selection},AP=e=>Vo(e)&&e.nodeType===3,GQ=e=>e.clipboardData&&e.clipboardData.getData("text/plain")!==""&&e.clipboardData.types.length===1,jQ=e=>{var[t,r]=e;if(Pr(t)&&t.childNodes.length){var n=r===t.childNodes.length,o=n?r-1:r;for([t,o]=RP(t,o,n?"backward":"forward"),n=o<r;Pr(t)&&t.childNodes.length;){var a=n?t.childNodes.length-1:0;t=WQ(t,a,n?"backward":"forward")}r=n&&t.textContent!=null?t.textContent.length:0}return[t,r]},_Q=e=>{for(var t=e&&e.parentNode;t;){if(t.toString()==="[object ShadowRoot]")return!0;t=t.parentNode}return!1},RP=(e,t,r)=>{for(var{childNodes:n}=e,o=n[t],a=t,s=!1,u=!1;(HQ(o)||Pr(o)&&o.childNodes.length===0||Pr(o)&&o.getAttribute("contenteditable")==="false")&&!(s&&u);){if(a>=n.length){s=!0,a=t-1,r="backward";continue}if(a<0){u=!0,a=t+1,r="forward";continue}o=n[a],t=a,a+=r==="forward"?1:-1}return[o,t]},WQ=(e,t,r)=>{var[n]=RP(e,t,r);return n},FP=e=>{var t="";if(AP(e)&&e.nodeValue)return e.nodeValue;if(Pr(e)){for(var r of Array.from(e.childNodes))t+=FP(r);var n=getComputedStyle(e).getPropertyValue("display");(n==="block"||n==="list"||e.tagName==="BR")&&(t+=`
1825
1825
  `)}return t},UQ=/data-slate-fragment="(.+?)"/m,KQ=e=>{var t=e.getData("text/html"),[,r]=t.match(UQ)||[];return r},U2=(e,t,r)=>{var{target:n}=t;if(Pr(n)&&n.matches('[contentEditable="false"]'))return!1;var{document:o}=$.getWindow(e);if(o.contains(n))return $.hasDOMNode(e,n,{editable:!0});var a=r.find(s=>{var{addedNodes:u,removedNodes:l}=s;for(var c of u)if(c===n||c.contains(n))return!0;for(var p of l)if(p===n||p.contains(n))return!0});return!a||a===t?!1:U2(e,a,r)},qQ=0,V2=class{constructor(){this.id="".concat(qQ++)}},$={androidPendingDiffs:e=>Zt.get(e),androidScheduleFlush:e=>{var t;(t=_2.get(e))===null||t===void 0||t()},blur:e=>{var t=$.toDOMNode(e,e),r=$.findDocumentOrShadowRoot(e);Ti.set(e,!1),r.activeElement===t&&t.blur()},deselect:e=>{var{selection:t}=e,r=$.findDocumentOrShadowRoot(e),n=r.getSelection();n&&n.rangeCount>0&&n.removeAllRanges(),t&&k.deselect(e)},findDocumentOrShadowRoot:e=>{var t=$.toDOMNode(e,e),r=t.getRootNode();return(r instanceof Document||r instanceof ShadowRoot)&&r.getSelection!=null?r:t.ownerDocument},findEventRange:(e,t)=>{"nativeEvent"in t&&(t=t.nativeEvent);var{clientX:r,clientY:n,target:o}=t;if(r==null||n==null)throw new Error("Cannot resolve a Slate range from a DOM event: ".concat(t));var a=$.toSlateNode(e,t.target),s=$.findPath(e,a);if(K.isElement(a)&&C.isVoid(e,a)){var u=o.getBoundingClientRect(),l=e.isInline(a)?r-u.left<u.left+u.width-r:n-u.top<u.top+u.height-n,c=C.point(e,s,{edge:l?"start":"end"}),p=l?C.before(e,c):C.after(e,c);if(p){var d=C.range(e,p);return d}}var h,{document:g}=$.getWindow(e);if(g.caretRangeFromPoint)h=g.caretRangeFromPoint(r,n);else{var v=g.caretPositionFromPoint(r,n);v&&(h=g.createRange(),h.setStart(v.offsetNode,v.offset),h.setEnd(v.offsetNode,v.offset))}if(!h)throw new Error("Cannot resolve a Slate range from a DOM event: ".concat(t));var m=$.toSlateRange(e,h,{exactMatch:!1,suppressThrow:!1});return m},findKey:(e,t)=>{var r=vd.get(t);return r||(r=new V2,vd.set(t,r)),r},findPath:(e,t)=>{for(var r=[],n=t;;){var o=j2.get(n);if(o==null){if(C.isEditor(n))return r;break}var a=G2.get(n);if(a==null)break;r.unshift(a),n=o}throw new Error("Unable to find the path for Slate node: ".concat(it.stringify(t)))},focus:e=>{var t=$.toDOMNode(e,e),r=$.findDocumentOrShadowRoot(e);if(Ti.set(e,!0),r.activeElement!==t){if(e.selection&&r instanceof Document){var n=r.getSelection(),o=$.toDOMRange(e,e.selection);n?.removeAllRanges(),n?.addRange(o)}t.focus({preventScroll:!0})}},getWindow:e=>{var t=EP.get(e);if(!t)throw new Error("Unable to find a host window element for this editor");return t},hasDOMNode:function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{editable:o=!1}=n,a=$.toDOMNode(t,t),s;try{s=Pr(r)?r:r.parentElement}catch(u){if(!u.message.includes('Permission denied to access property "nodeType"'))throw u}return s?s.closest("[data-slate-editor]")===a&&(!o||s.isContentEditable?!0:typeof s.isContentEditable=="boolean"&&s.closest('[contenteditable="false"]')===a||!!s.getAttribute("data-slate-zero-width")):!1},hasEditableTarget:(e,t)=>Vo(t)&&$.hasDOMNode(e,t,{editable:!0}),hasRange:(e,t)=>{var{anchor:r,focus:n}=t;return C.hasPath(e,r.path)&&C.hasPath(e,n.path)},hasSelectableTarget:(e,t)=>$.hasEditableTarget(e,t)||$.isTargetInsideNonReadonlyVoid(e,t),hasTarget:(e,t)=>Vo(t)&&$.hasDOMNode(e,t),insertData:(e,t)=>{e.insertData(t)},insertFragmentData:(e,t)=>e.insertFragmentData(t),insertTextData:(e,t)=>e.insertTextData(t),isComposing:e=>!!Ai.get(e),isFocused:e=>!!Ti.get(e),isReadOnly:e=>!!I2.get(e),isTargetInsideNonReadonlyVoid:(e,t)=>{if(I2.get(e))return!1;var r=$.hasTarget(e,t)&&$.toSlateNode(e,t);return K.isElement(r)&&C.isVoid(e,r)},setFragmentData:(e,t,r)=>e.setFragmentData(t,r),toDOMNode:(e,t)=>{var r=Cd.get(e),n=C.isEditor(t)?gd.get(e):r?.get($.findKey(e,t));if(!n)throw new Error("Cannot resolve a DOM node from Slate node: ".concat(it.stringify(t)));return n},toDOMPoint:(e,t)=>{var[r]=C.node(e,t.path),n=$.toDOMNode(e,r),o;C.void(e,{at:t})&&(t={path:t.path,offset:0});for(var a="[data-slate-string], [data-slate-zero-width]",s=Array.from(n.querySelectorAll(a)),u=0,l=0;l<s.length;l++){var c=s[l],p=c.childNodes[0];if(!(p==null||p.textContent==null)){var{length:d}=p.textContent,h=c.getAttribute("data-slate-length"),g=h==null?d:parseInt(h,10),v=u+g,m=s[l+1];if(t.offset===v&&m!==null&&m!==void 0&&m.hasAttribute("data-slate-mark-placeholder")){var b,y=m.childNodes[0];o=[y instanceof zQ?y:m,(b=m.textContent)!==null&&b!==void 0&&b.startsWith("\uFEFF")?1:0];break}if(t.offset<=v){var x=Math.min(d,Math.max(0,t.offset-u));o=[p,x];break}u=v}}if(!o)throw new Error("Cannot resolve a DOM point from Slate point: ".concat(it.stringify(t)));return o},toDOMRange:(e,t)=>{var{anchor:r,focus:n}=t,o=O.isBackward(t),a=$.toDOMPoint(e,r),s=O.isCollapsed(t)?a:$.toDOMPoint(e,n),u=$.getWindow(e),l=u.document.createRange(),[c,p]=o?s:a,[d,h]=o?a:s,g=Pr(c)?c:c.parentElement,v=!!g.getAttribute("data-slate-zero-width"),m=Pr(d)?d:d.parentElement,b=!!m.getAttribute("data-slate-zero-width");return l.setStart(c,v?1:p),l.setEnd(d,b?1:h),l},toSlateNode:(e,t)=>{var r=Pr(t)?t:t.parentElement;r&&!r.hasAttribute("data-slate-node")&&(r=r.closest("[data-slate-node]"));var n=r?tl.get(r):null;if(!n)throw new Error("Cannot resolve a Slate node from DOM node: ".concat(r));return n},toSlatePoint:(e,t,r)=>{var{exactMatch:n,suppressThrow:o}=r,[a,s]=n?t:jQ(t),u=a.parentNode,l=null,c=0;if(u){var p,d,h=$.toDOMNode(e,e),g=u.closest('[data-slate-void="true"]'),v=g&&h.contains(g)?g:null,m=u.closest("[data-slate-leaf]"),b=null;if(m){if(l=m.closest('[data-slate-node="text"]'),l){var y=$.getWindow(e),x=y.document.createRange();x.setStart(l,0),x.setEnd(a,s);var w=x.cloneContents(),S=[...Array.prototype.slice.call(w.querySelectorAll("[data-slate-zero-width]")),...Array.prototype.slice.call(w.querySelectorAll("[contenteditable=false]"))];S.forEach(I=>{if(Qt&&!n&&I.hasAttribute("data-slate-zero-width")&&I.textContent.length>0&&I.textContext!=="\uFEFF"){I.textContent.startsWith("\uFEFF")&&(I.textContent=I.textContent.slice(1));return}I.parentNode.removeChild(I)}),c=w.textContent.length,b=l}}else if(v){for(var E=v.querySelectorAll("[data-slate-leaf]"),D=0;D<E.length;D++){var P=E[D];if($.hasDOMNode(e,P)){m=P;break}}m?(l=m.closest('[data-slate-node="text"]'),b=m,c=b.textContent.length,b.querySelectorAll("[data-slate-zero-width]").forEach(I=>{c-=I.textContent.length})):c=1}b&&c===b.textContent.length&&Qt&&b.getAttribute("data-slate-zero-width")==="z"&&(p=b.textContent)!==null&&p!==void 0&&p.startsWith("\uFEFF")&&(u.hasAttribute("data-slate-zero-width")||Qu&&(d=b.textContent)!==null&&d!==void 0&&d.endsWith(`
1826
1826
 
1827
- `))&&c--}if(Qt&&!l&&!n){var R=u.hasAttribute("data-slate-node")?u:u.closest("[data-slate-node]");if(R&&$.hasDOMNode(e,R,{editable:!0})){var F=$.toSlateNode(e,R),{path:M,offset:G}=C.start(e,$.findPath(e,F));return R.querySelector("[data-slate-leaf]")||(G=s),{path:M,offset:G}}}if(!l){if(o)return null;throw new Error("Cannot resolve a Slate point from DOM point: ".concat(t))}var N=$.toSlateNode(e,l),L=$.findPath(e,N);return{path:L,offset:c}},toSlateRange:(e,t,r)=>{var{exactMatch:n,suppressThrow:o}=r,a=N2(t)?t.anchorNode:t.startContainer,s,u,l,c,p;if(a)if(N2(t)){if(Qu&&t.rangeCount>1){l=t.focusNode;var d=t.getRangeAt(0),h=t.getRangeAt(t.rangeCount-1);if(l instanceof HTMLTableRowElement&&d.startContainer instanceof HTMLTableRowElement&&h.startContainer instanceof HTMLTableRowElement){let E=function(D){return D.childElementCount>0?E(D.children[0]):D};var g=d.startContainer,v=h.startContainer,m=E(g.children[d.startOffset]),b=E(v.children[h.startOffset]);c=0,b.childNodes.length>0?s=b.childNodes[0]:s=b,m.childNodes.length>0?l=m.childNodes[0]:l=m,b instanceof HTMLElement?u=b.innerHTML.length:u=0}else d.startContainer===l?(s=h.endContainer,u=h.endOffset,c=d.startOffset):(s=d.startContainer,u=d.endOffset,c=h.startOffset)}else s=t.anchorNode,u=t.anchorOffset,l=t.focusNode,c=t.focusOffset;DP&&_Q(s)||Qu?p=t.anchorNode===t.focusNode&&t.anchorOffset===t.focusOffset:p=t.isCollapsed}else s=t.startContainer,u=t.startOffset,l=t.endContainer,c=t.endOffset,p=t.collapsed;if(s==null||l==null||u==null||c==null)throw new Error("Cannot resolve a Slate range from DOM range: ".concat(t));if("getAttribute"in l&&l.getAttribute("contenteditable")==="false"&&l.getAttribute("data-slate-void")!=="true"){var y;l=s,c=((y=s.textContent)===null||y===void 0?void 0:y.length)||0}var x=$.toSlatePoint(e,[s,u],{exactMatch:n,suppressThrow:o});if(!x)return null;var w=p?x:$.toSlatePoint(e,[l,c],{exactMatch:n,suppressThrow:o});if(!w)return null;var S={anchor:x,focus:w};return O.isExpanded(S)&&O.isForward(S)&&Pr(l)&&C.void(e,{at:S.focus,mode:"highest"})&&(S=C.unhangRange(e,S,{voids:!0})),S}};function XQ(e,t){var{path:r,diff:n}=t;if(!C.hasPath(e,r))return!1;var o=W.get(e,r);if(!J.isText(o))return!1;if(n.start!==o.text.length||n.text.length===0)return o.text.slice(n.start,n.start+n.text.length)===n.text;var a=T.next(r);if(!C.hasPath(e,a))return!1;var s=W.get(e,a);return J.isText(s)&&s.text.startsWith(n.text)}function BP(e){for(var t=arguments.length,r=new Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];return r.reduce((o,a)=>o.slice(0,a.start)+a.text+o.slice(a.end),e)}function YQ(e,t){for(var r=Math.min(e.length,t.length),n=0;n<r;n++)if(e.charAt(n)!==t.charAt(n))return n;return r}function JQ(e,t,r){for(var n=Math.min(e.length,t.length,r),o=0;o<n;o++)if(e.charAt(e.length-o-1)!==t.charAt(t.length-o-1))return o;return n}function OP(e,t){var{start:r,end:n,text:o}=t,a=e.slice(r,n),s=YQ(a,o),u=Math.min(a.length-s,o.length-s),l=JQ(a,o,u),c={start:r+s,end:n-l,text:o.slice(s,o.length-l)};return c.start===c.end&&c.text.length===0?null:c}function ZQ(e,t,r){var n=Math.min(t.start,r.start),o=Math.max(0,Math.min(t.start+t.text.length,r.end)-r.start),a=BP(e,t,r),s=Math.max(r.start+r.text.length,t.start+t.text.length+(t.start+t.text.length>r.start?r.text.length:0)-o),u=a.slice(n,s),l=Math.max(t.end,r.end-t.text.length+(t.end-t.start));return OP(e,{start:n,end:l,text:u})}function QQ(e){var{path:t,diff:r}=e;return{anchor:{path:t,offset:r.start},focus:{path:t,offset:r.end}}}function L2(e,t){var{path:r,offset:n}=t;if(!C.hasPath(e,r))return null;var o=W.get(e,r);if(!J.isText(o))return null;var a=C.above(e,{match:u=>K.isElement(u)&&C.isBlock(e,u),at:r});if(!a)return null;for(;n>o.text.length;){var s=C.next(e,{at:r,match:J.isText});if(!s||!T.isDescendant(s[1],a[1]))return null;n-=o.text.length,o=s[0],r=s[1]}return{path:r,offset:n}}function lP(e,t){var r=L2(e,t.anchor);if(!r)return null;if(O.isCollapsed(t))return{anchor:r,focus:r};var n=L2(e,t.focus);return n?{anchor:r,focus:n}:null}function $2(e,t,r){var n=Zt.get(e),o=n?.find(p=>{var{path:d}=p;return T.equals(d,t.path)});if(!o||t.offset<=o.diff.start)return ge.transform(t,r,{affinity:"backward"});var{diff:a}=o;if(t.offset<=a.start+a.text.length){var s={path:t.path,offset:a.start},u=ge.transform(s,r,{affinity:"backward"});return u?{path:u.path,offset:u.offset+t.offset-a.start}:null}var l={path:t.path,offset:t.offset-a.text.length+a.end-a.start},c=ge.transform(l,r,{affinity:"backward"});return c?r.type==="split_node"&&T.equals(r.path,t.path)&&l.offset<r.position&&a.start<r.position?c:{path:c.path,offset:c.offset+a.text.length-a.end+a.start}:null}function cP(e,t,r){var n=$2(e,t.anchor,r);if(!n)return null;if(O.isCollapsed(t))return{anchor:n,focus:n};var o=$2(e,t.focus,r);return o?{anchor:n,focus:o}:null}function eee(e,t){var{path:r,diff:n,id:o}=e;switch(t.type){case"insert_text":return!T.equals(t.path,r)||t.offset>=n.end?e:t.offset<=n.start?{diff:{start:t.text.length+n.start,end:t.text.length+n.end,text:n.text},id:o,path:r}:{diff:{start:n.start,end:n.end+t.text.length,text:n.text},id:o,path:r};case"remove_text":return!T.equals(t.path,r)||t.offset>=n.end?e:t.offset+t.text.length<=n.start?{diff:{start:n.start-t.text.length,end:n.end-t.text.length,text:n.text},id:o,path:r}:{diff:{start:n.start,end:n.end-t.text.length,text:n.text},id:o,path:r};case"split_node":return!T.equals(t.path,r)||t.position>=n.end?{diff:n,id:o,path:T.transform(r,t,{affinity:"backward"})}:t.position>n.start?{diff:{start:n.start,end:Math.min(t.position,n.end),text:n.text},id:o,path:r}:{diff:{start:n.start-t.position,end:n.end-t.position,text:n.text},id:o,path:T.transform(r,t,{affinity:"forward"})};case"merge_node":return T.equals(t.path,r)?{diff:{start:n.start+t.position,end:n.end+t.position,text:n.text},id:o,path:T.transform(r,t)}:{diff:n,id:o,path:T.transform(r,t)}}var a=T.transform(r,t);return a?{diff:n,path:a,id:o}:null}function fP(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function pd(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?fP(Object(r),!0).forEach(function(n){bd(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):fP(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var tee=25,ree=200,nee=function(){},oee=e=>e?.constructor.name==="DataTransfer";function iee(e){var{editor:t,scheduleOnDOMSelectionChange:r,onDOMSelectionChange:n}=e,o=!1,a=null,s=null,u=null,l=0,c=!1,p=()=>{var N=No.get(t);if(No.delete(t),N){var{selection:L}=t,I=lP(t,N);I&&(!L||!O.equals(I,L))&&k.select(t,I)}},d=()=>{var N=ko.get(t);if(ko.delete(t),!!N){if(N.at){var L=ge.isPoint(N.at)?L2(t,N.at):lP(t,N.at);if(!L)return;var I=C.range(t,L);(!t.selection||!O.equals(t.selection,I))&&k.select(t,L)}N.run()}},h=()=>{if(s&&(clearTimeout(s),s=null),u&&(clearTimeout(u),u=null),!S()&&!w()){p();return}o||(o=!0,setTimeout(()=>o=!1)),w()&&(o="action");var N=t.selection&&C.rangeRef(t,t.selection,{affinity:"forward"});Gn.set(t,t.marks),nee("flush",ko.get(t),Zt.get(t));for(var L=S(),I;I=(V=Zt.get(t))===null||V===void 0?void 0:V[0];){var V,Y,Q=Gr.get(t);Q!==void 0&&(Gr.delete(t),t.marks=Q),Q&&c===!1&&(c=null);var re=QQ(I);(!t.selection||!O.equals(t.selection,re))&&k.select(t,re),I.diff.text?C.insertText(t,I.diff.text):C.deleteFragment(t),Zt.set(t,(Y=Zt.get(t))===null||Y===void 0?void 0:Y.filter(ve=>{var{id:me}=ve;return me!==I.id})),XQ(t,I)||(L=!1,ko.delete(t),Gn.delete(t),o="action",No.delete(t),r.cancel(),n.cancel(),N?.unref())}var H=N?.unref();if(H&&!No.get(t)&&(!t.selection||!O.equals(H,t.selection))&&k.select(t,H),w()){d();return}L&&r(),r.flush(),n.flush(),p();var le=Gn.get(t);Gn.delete(t),le!==void 0&&(t.marks=le,t.onChange())},g=N=>{a&&clearTimeout(a),a=setTimeout(()=>{Ai.set(t,!1),h()},tee)},v=N=>{Ai.set(t,!0),a&&(clearTimeout(a),a=null)},m=function(){var L=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1,I=M2.get(t);if(I){if(S()||L){I.style.display="none";return}I.style.removeProperty("display")}},b=(N,L)=>{var I,V=(I=Zt.get(t))!==null&&I!==void 0?I:[];Zt.set(t,V);var Y=W.leaf(t,N),Q=V.findIndex(le=>T.equals(le.path,N));if(Q<0){var re=OP(Y.text,L);re&&V.push({path:N,diff:L,id:l++}),m();return}var H=ZQ(Y.text,V[Q].diff,L);if(!H){V.splice(Q,1),m();return}V[Q]=pd(pd({},V[Q]),{},{diff:H})},y=function(L){var{at:I}=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};c=!1,No.delete(t),r.cancel(),n.cancel(),w()&&h(),ko.set(t,{at:I,run:L}),u=setTimeout(h)},x=N=>{var L;s&&(clearTimeout(s),s=null);var{inputType:I}=N,V=null,Y=N.dataTransfer||N.data||void 0;c!==!1&&I!=="insertText"&&I!=="insertCompositionText"&&(c=!1);var[Q]=N.getTargetRanges();Q&&(V=$.toSlateRange(t,Q,{exactMatch:!1,suppressThrow:!0}));var re=$.getWindow(t),H=re.getSelection();if(!V&&H&&(Q=H,V=$.toSlateRange(t,H,{exactMatch:!1,suppressThrow:!0})),V=(L=V)!==null&&L!==void 0?L:t.selection,!!V){var le=!0;if(I.startsWith("delete")){if(O.isExpanded(V)){var[ve,me]=O.edges(V),Ge=W.leaf(t,ve.path);if(Ge.text.length===ve.offset&&me.offset===0){var A=C.next(t,{at:ve.path,match:J.isText});A&&T.equals(A[1],me.path)&&(V={anchor:me,focus:me})}}var _=I.endsWith("Backward")?"backward":"forward",[z,j]=O.edges(V),[ue,oe]=C.leaf(t,z.path),he={text:"",start:z.offset,end:j.offset},Ce=Zt.get(t),Se=Ce?.find(Pe=>T.equals(Pe.path,oe)),Ee=Se?[Se.diff,he]:[he],xe=BP(ue.text,...Ee);if(xe.length===0&&(le=!1),O.isExpanded(V)){if(le&&T.equals(V.anchor.path,V.focus.path)){var ht={path:V.anchor.path,offset:z.offset},gt=C.range(t,ht,ht);return P(gt),b(V.anchor.path,{text:"",end:j.offset,start:z.offset})}return y(()=>C.deleteFragment(t,{direction:_}),{at:V})}}switch(I){case"deleteByComposition":case"deleteByCut":case"deleteByDrag":return y(()=>C.deleteFragment(t),{at:V});case"deleteContent":case"deleteContentForward":{var{anchor:je}=V;if(le&&O.isCollapsed(V)){var or=W.leaf(t,je.path);if(je.offset<or.text.length)return b(je.path,{text:"",start:je.offset,end:je.offset+1})}return y(()=>C.deleteForward(t),{at:V})}case"deleteContentBackward":{var Ht,{anchor:St}=V,ir=N2(Q)?Q.isCollapsed:!!((Ht=Q)!==null&&Ht!==void 0&&Ht.collapsed);return le&&ir&&O.isCollapsed(V)&&St.offset>0?b(St.path,{text:"",start:St.offset-1,end:St.offset}):y(()=>C.deleteBackward(t),{at:V})}case"deleteEntireSoftLine":return y(()=>{C.deleteBackward(t,{unit:"line"}),C.deleteForward(t,{unit:"line"})},{at:V});case"deleteHardLineBackward":return y(()=>C.deleteBackward(t,{unit:"block"}),{at:V});case"deleteSoftLineBackward":return y(()=>C.deleteBackward(t,{unit:"line"}),{at:V});case"deleteHardLineForward":return y(()=>C.deleteForward(t,{unit:"block"}),{at:V});case"deleteSoftLineForward":return y(()=>C.deleteForward(t,{unit:"line"}),{at:V});case"deleteWordBackward":return y(()=>C.deleteBackward(t,{unit:"word"}),{at:V});case"deleteWordForward":return y(()=>C.deleteForward(t,{unit:"word"}),{at:V});case"insertLineBreak":return y(()=>C.insertSoftBreak(t),{at:V});case"insertParagraph":return y(()=>C.insertBreak(t),{at:V});case"insertCompositionText":case"deleteCompositionText":case"insertFromComposition":case"insertFromDrop":case"insertFromPaste":case"insertFromYank":case"insertReplacementText":case"insertText":{if(oee(Y))return y(()=>$.insertData(t,Y),{at:V});var B=Y??"";if(Gr.get(t)&&(B=B.replace("\uFEFF","")),I==="insertText"&&/.*\n.*\n$/.test(B)&&(B=B.slice(0,-1)),B.includes(`
1827
+ `))&&c--}if(Qt&&!l&&!n){var R=u.hasAttribute("data-slate-node")?u:u.closest("[data-slate-node]");if(R&&$.hasDOMNode(e,R,{editable:!0})){var F=$.toSlateNode(e,R),{path:M,offset:G}=C.start(e,$.findPath(e,F));return R.querySelector("[data-slate-leaf]")||(G=s),{path:M,offset:G}}}if(!l){if(o)return null;throw new Error("Cannot resolve a Slate point from DOM point: ".concat(t))}var N=$.toSlateNode(e,l),L=$.findPath(e,N);return{path:L,offset:c}},toSlateRange:(e,t,r)=>{var{exactMatch:n,suppressThrow:o}=r,a=N2(t)?t.anchorNode:t.startContainer,s,u,l,c,p;if(a)if(N2(t)){if(Qu&&t.rangeCount>1){l=t.focusNode;var d=t.getRangeAt(0),h=t.getRangeAt(t.rangeCount-1);if(l instanceof HTMLTableRowElement&&d.startContainer instanceof HTMLTableRowElement&&h.startContainer instanceof HTMLTableRowElement){let E=function(D){return D.childElementCount>0?E(D.children[0]):D};var g=d.startContainer,v=h.startContainer,m=E(g.children[d.startOffset]),b=E(v.children[h.startOffset]);c=0,b.childNodes.length>0?s=b.childNodes[0]:s=b,m.childNodes.length>0?l=m.childNodes[0]:l=m,b instanceof HTMLElement?u=b.innerHTML.length:u=0}else d.startContainer===l?(s=h.endContainer,u=h.endOffset,c=d.startOffset):(s=d.startContainer,u=d.endOffset,c=h.startOffset)}else s=t.anchorNode,u=t.anchorOffset,l=t.focusNode,c=t.focusOffset;DP&&_Q(s)||Qu?p=t.anchorNode===t.focusNode&&t.anchorOffset===t.focusOffset:p=t.isCollapsed}else s=t.startContainer,u=t.startOffset,l=t.endContainer,c=t.endOffset,p=t.collapsed;if(s==null||l==null||u==null||c==null)throw new Error("Cannot resolve a Slate range from DOM range: ".concat(t));if("getAttribute"in l&&l.getAttribute("contenteditable")==="false"&&l.getAttribute("data-slate-void")!=="true"){var y;l=s,c=((y=s.textContent)===null||y===void 0?void 0:y.length)||0}var x=$.toSlatePoint(e,[s,u],{exactMatch:n,suppressThrow:o});if(!x)return null;var w=p?x:$.toSlatePoint(e,[l,c],{exactMatch:n,suppressThrow:o});if(!w)return null;var S={anchor:x,focus:w};return O.isExpanded(S)&&O.isForward(S)&&Pr(l)&&C.void(e,{at:S.focus,mode:"highest"})&&(S=C.unhangRange(e,S,{voids:!0})),S}};function XQ(e,t){var{path:r,diff:n}=t;if(!C.hasPath(e,r))return!1;var o=W.get(e,r);if(!J.isText(o))return!1;if(n.start!==o.text.length||n.text.length===0)return o.text.slice(n.start,n.start+n.text.length)===n.text;var a=T.next(r);if(!C.hasPath(e,a))return!1;var s=W.get(e,a);return J.isText(s)&&s.text.startsWith(n.text)}function BP(e){for(var t=arguments.length,r=new Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];return r.reduce((o,a)=>o.slice(0,a.start)+a.text+o.slice(a.end),e)}function YQ(e,t){for(var r=Math.min(e.length,t.length),n=0;n<r;n++)if(e.charAt(n)!==t.charAt(n))return n;return r}function JQ(e,t,r){for(var n=Math.min(e.length,t.length,r),o=0;o<n;o++)if(e.charAt(e.length-o-1)!==t.charAt(t.length-o-1))return o;return n}function OP(e,t){var{start:r,end:n,text:o}=t,a=e.slice(r,n),s=YQ(a,o),u=Math.min(a.length-s,o.length-s),l=JQ(a,o,u),c={start:r+s,end:n-l,text:o.slice(s,o.length-l)};return c.start===c.end&&c.text.length===0?null:c}function ZQ(e,t,r){var n=Math.min(t.start,r.start),o=Math.max(0,Math.min(t.start+t.text.length,r.end)-r.start),a=BP(e,t,r),s=Math.max(r.start+r.text.length,t.start+t.text.length+(t.start+t.text.length>r.start?r.text.length:0)-o),u=a.slice(n,s),l=Math.max(t.end,r.end-t.text.length+(t.end-t.start));return OP(e,{start:n,end:l,text:u})}function QQ(e){var{path:t,diff:r}=e;return{anchor:{path:t,offset:r.start},focus:{path:t,offset:r.end}}}function L2(e,t){var{path:r,offset:n}=t;if(!C.hasPath(e,r))return null;var o=W.get(e,r);if(!J.isText(o))return null;var a=C.above(e,{match:u=>K.isElement(u)&&C.isBlock(e,u),at:r});if(!a)return null;for(;n>o.text.length;){var s=C.next(e,{at:r,match:J.isText});if(!s||!T.isDescendant(s[1],a[1]))return null;n-=o.text.length,o=s[0],r=s[1]}return{path:r,offset:n}}function lP(e,t){var r=L2(e,t.anchor);if(!r)return null;if(O.isCollapsed(t))return{anchor:r,focus:r};var n=L2(e,t.focus);return n?{anchor:r,focus:n}:null}function $2(e,t,r){var n=Zt.get(e),o=n?.find(p=>{var{path:d}=p;return T.equals(d,t.path)});if(!o||t.offset<=o.diff.start)return ge.transform(t,r,{affinity:"backward"});var{diff:a}=o;if(t.offset<=a.start+a.text.length){var s={path:t.path,offset:a.start},u=ge.transform(s,r,{affinity:"backward"});return u?{path:u.path,offset:u.offset+t.offset-a.start}:null}var l={path:t.path,offset:t.offset-a.text.length+a.end-a.start},c=ge.transform(l,r,{affinity:"backward"});return c?r.type==="split_node"&&T.equals(r.path,t.path)&&l.offset<r.position&&a.start<r.position?c:{path:c.path,offset:c.offset+a.text.length-a.end+a.start}:null}function cP(e,t,r){var n=$2(e,t.anchor,r);if(!n)return null;if(O.isCollapsed(t))return{anchor:n,focus:n};var o=$2(e,t.focus,r);return o?{anchor:n,focus:o}:null}function eee(e,t){var{path:r,diff:n,id:o}=e;switch(t.type){case"insert_text":return!T.equals(t.path,r)||t.offset>=n.end?e:t.offset<=n.start?{diff:{start:t.text.length+n.start,end:t.text.length+n.end,text:n.text},id:o,path:r}:{diff:{start:n.start,end:n.end+t.text.length,text:n.text},id:o,path:r};case"remove_text":return!T.equals(t.path,r)||t.offset>=n.end?e:t.offset+t.text.length<=n.start?{diff:{start:n.start-t.text.length,end:n.end-t.text.length,text:n.text},id:o,path:r}:{diff:{start:n.start,end:n.end-t.text.length,text:n.text},id:o,path:r};case"split_node":return!T.equals(t.path,r)||t.position>=n.end?{diff:n,id:o,path:T.transform(r,t,{affinity:"backward"})}:t.position>n.start?{diff:{start:n.start,end:Math.min(t.position,n.end),text:n.text},id:o,path:r}:{diff:{start:n.start-t.position,end:n.end-t.position,text:n.text},id:o,path:T.transform(r,t,{affinity:"forward"})};case"merge_node":return T.equals(t.path,r)?{diff:{start:n.start+t.position,end:n.end+t.position,text:n.text},id:o,path:T.transform(r,t)}:{diff:n,id:o,path:T.transform(r,t)}}var a=T.transform(r,t);return a?{diff:n,path:a,id:o}:null}function fP(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function pd(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?fP(Object(r),!0).forEach(function(n){bd(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):fP(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var tee=25,ree=200,nee=function(){},oee=e=>e?.constructor.name==="DataTransfer";function iee(e){var{editor:t,scheduleOnDOMSelectionChange:r,onDOMSelectionChange:n}=e,o=!1,a=null,s=null,u=null,l=0,c=!1,p=()=>{var N=No.get(t);if(No.delete(t),N){var{selection:L}=t,I=lP(t,N);I&&(!L||!O.equals(I,L))&&k.select(t,I)}},d=()=>{var N=ko.get(t);if(ko.delete(t),!!N){if(N.at){var L=ge.isPoint(N.at)?L2(t,N.at):lP(t,N.at);if(!L)return;var I=C.range(t,L);(!t.selection||!O.equals(t.selection,I))&&k.select(t,L)}N.run()}},h=()=>{if(s&&(clearTimeout(s),s=null),u&&(clearTimeout(u),u=null),!S()&&!w()){p();return}o||(o=!0,setTimeout(()=>o=!1)),w()&&(o="action");var N=t.selection&&C.rangeRef(t,t.selection,{affinity:"forward"});Gn.set(t,t.marks),nee("flush",ko.get(t),Zt.get(t));for(var L=S(),I;I=(V=Zt.get(t))===null||V===void 0?void 0:V[0];){var V,Y,Q=Gr.get(t);Q!==void 0&&(Gr.delete(t),t.marks=Q),Q&&c===!1&&(c=null);var re=QQ(I);(!t.selection||!O.equals(t.selection,re))&&k.select(t,re),I.diff.text?C.insertText(t,I.diff.text):C.deleteFragment(t),Zt.set(t,(Y=Zt.get(t))===null||Y===void 0?void 0:Y.filter(ve=>{var{id:me}=ve;return me!==I.id})),XQ(t,I)||(L=!1,ko.delete(t),Gn.delete(t),o="action",No.delete(t),r.cancel(),n.cancel(),N?.unref())}var H=N?.unref();if(H&&!No.get(t)&&(!t.selection||!O.equals(H,t.selection))&&k.select(t,H),w()){d();return}L&&r(),r.flush(),n.flush(),p();var le=Gn.get(t);Gn.delete(t),le!==void 0&&(t.marks=le,t.onChange())},g=N=>{a&&clearTimeout(a),a=setTimeout(()=>{Ai.set(t,!1),h()},tee)},v=N=>{Ai.set(t,!0),a&&(clearTimeout(a),a=null)},m=function(){var L=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1,I=M2.get(t);if(I){if(S()||L){I.style.display="none";return}I.style.removeProperty("display")}},b=(N,L)=>{var I,V=(I=Zt.get(t))!==null&&I!==void 0?I:[];Zt.set(t,V);var Y=W.leaf(t,N),Q=V.findIndex(le=>T.equals(le.path,N));if(Q<0){var re=OP(Y.text,L);re&&V.push({path:N,diff:L,id:l++}),m();return}var H=ZQ(Y.text,V[Q].diff,L);if(!H){V.splice(Q,1),m();return}V[Q]=pd(pd({},V[Q]),{},{diff:H})},y=function(L){var{at:I}=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};c=!1,No.delete(t),r.cancel(),n.cancel(),w()&&h(),ko.set(t,{at:I,run:L}),u=setTimeout(h)},x=N=>{var L;s&&(clearTimeout(s),s=null);var{inputType:I}=N,V=null,Y=N.dataTransfer||N.data||void 0;c!==!1&&I!=="insertText"&&I!=="insertCompositionText"&&(c=!1);var[Q]=N.getTargetRanges();Q&&(V=$.toSlateRange(t,Q,{exactMatch:!1,suppressThrow:!0}));var re=$.getWindow(t),H=re.getSelection();if(!V&&H&&(Q=H,V=$.toSlateRange(t,H,{exactMatch:!1,suppressThrow:!0})),V=(L=V)!==null&&L!==void 0?L:t.selection,!!V){var le=!0;if(I.startsWith("delete")){if(O.isExpanded(V)){var[ve,me]=O.edges(V),Ge=W.leaf(t,ve.path);if(Ge.text.length===ve.offset&&me.offset===0){var A=C.next(t,{at:ve.path,match:J.isText});A&&T.equals(A[1],me.path)&&(V={anchor:me,focus:me})}}var _=I.endsWith("Backward")?"backward":"forward",[z,j]=O.edges(V),[ue,oe]=C.leaf(t,z.path),he={text:"",start:z.offset,end:j.offset},Ce=Zt.get(t),Se=Ce?.find(Pe=>T.equals(Pe.path,oe)),Ee=Se?[Se.diff,he]:[he],xe=BP(ue.text,...Ee);if(xe.length===0&&(le=!1),O.isExpanded(V)){if(le&&T.equals(V.anchor.path,V.focus.path)){var gt={path:V.anchor.path,offset:z.offset},vt=C.range(t,gt,gt);return P(vt),b(V.anchor.path,{text:"",end:j.offset,start:z.offset})}return y(()=>C.deleteFragment(t,{direction:_}),{at:V})}}switch(I){case"deleteByComposition":case"deleteByCut":case"deleteByDrag":return y(()=>C.deleteFragment(t),{at:V});case"deleteContent":case"deleteContentForward":{var{anchor:je}=V;if(le&&O.isCollapsed(V)){var or=W.leaf(t,je.path);if(je.offset<or.text.length)return b(je.path,{text:"",start:je.offset,end:je.offset+1})}return y(()=>C.deleteForward(t),{at:V})}case"deleteContentBackward":{var Ht,{anchor:St}=V,ir=N2(Q)?Q.isCollapsed:!!((Ht=Q)!==null&&Ht!==void 0&&Ht.collapsed);return le&&ir&&O.isCollapsed(V)&&St.offset>0?b(St.path,{text:"",start:St.offset-1,end:St.offset}):y(()=>C.deleteBackward(t),{at:V})}case"deleteEntireSoftLine":return y(()=>{C.deleteBackward(t,{unit:"line"}),C.deleteForward(t,{unit:"line"})},{at:V});case"deleteHardLineBackward":return y(()=>C.deleteBackward(t,{unit:"block"}),{at:V});case"deleteSoftLineBackward":return y(()=>C.deleteBackward(t,{unit:"line"}),{at:V});case"deleteHardLineForward":return y(()=>C.deleteForward(t,{unit:"block"}),{at:V});case"deleteSoftLineForward":return y(()=>C.deleteForward(t,{unit:"line"}),{at:V});case"deleteWordBackward":return y(()=>C.deleteBackward(t,{unit:"word"}),{at:V});case"deleteWordForward":return y(()=>C.deleteForward(t,{unit:"word"}),{at:V});case"insertLineBreak":return y(()=>C.insertSoftBreak(t),{at:V});case"insertParagraph":return y(()=>C.insertBreak(t),{at:V});case"insertCompositionText":case"deleteCompositionText":case"insertFromComposition":case"insertFromDrop":case"insertFromPaste":case"insertFromYank":case"insertReplacementText":case"insertText":{if(oee(Y))return y(()=>$.insertData(t,Y),{at:V});var B=Y??"";if(Gr.get(t)&&(B=B.replace("\uFEFF","")),I==="insertText"&&/.*\n.*\n$/.test(B)&&(B=B.slice(0,-1)),B.includes(`
1828
1828
  `))return y(()=>{var Pe=B.split(`
1829
- `);Pe.forEach((vt,eo)=>{vt&&C.insertText(t,vt),eo!==Pe.length-1&&C.insertSoftBreak(t)})},{at:V});if(T.equals(V.anchor.path,V.focus.path)){var[X,te]=O.edges(V),q={start:X.offset,end:te.offset,text:B};if(B&&c&&I==="insertCompositionText"){var se=c.start+c.text.search(/\S|$/),we=q.start+q.text.search(/\S|$/);we===se+1&&q.end===c.start+c.text.length?(q.start-=1,c=null,M()):c=!1}else I==="insertText"?c===null?c=q:c&&O.isCollapsed(V)&&c.end+c.text.length===X.offset?c=pd(pd({},c),{},{text:c.text+B}):c=!1:c=!1;if(le){b(X.path,q);return}}return y(()=>C.insertText(t,B),{at:V})}}}},w=()=>!!ko.get(t),S=()=>{var N;return!!((N=Zt.get(t))!==null&&N!==void 0&&N.length)},E=()=>w()||S(),D=()=>o,P=N=>{No.set(t,N),s&&(clearTimeout(s),s=null);var{selection:L}=t;if(N){var I=!L||!T.equals(L.anchor.path,N.anchor.path),V=!L||!T.equals(L.anchor.path.slice(0,-1),N.anchor.path.slice(0,-1));(I&&c||V)&&(c=!1),(I||S())&&(s=setTimeout(h,ree))}},R=()=>{(w()||!S())&&h()},F=N=>{S()||(m(!0),setTimeout(m))},M=()=>{w()||(u=setTimeout(h))},G=N=>{if(!(S()||w())&&N.some(I=>U2(t,I,N))){var L;(L=PP.get(t))===null||L===void 0||L()}};return{flush:h,scheduleFlush:M,hasPendingDiffs:S,hasPendingAction:w,hasPendingChanges:E,isFlushing:D,handleUserSelect:P,handleCompositionEnd:g,handleCompositionStart:v,handleDOMBeforeInput:x,handleKeyDown:F,handleDomMutations:G,handleInput:R}}function aee(){var e=gr(!1);return jn(()=>(e.current=!0,()=>{e.current=!1}),[]),e.current}var rl=hd?PQ:jn;function see(e,t,r){var[n]=Fi(()=>new MutationObserver(t));rl(()=>{n.takeRecords()}),jn(()=>{if(!e.current)throw new Error("Failed to attach MutationObserver, `node` is undefined");return n.observe(e.current,r),()=>n.disconnect()},[n,e,r])}var uee=["node"];function pP(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function lee(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?pP(Object(r),!0).forEach(function(n){bd(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):pP(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var cee={subtree:!0,childList:!0,characterData:!0},fee=Qt?e=>{var{node:t}=e,r=ls(e,uee);if(!Qt)return null;var n=Lo(),o=aee(),[a]=Fi(()=>iee(lee({editor:n},r)));return see(t,a.handleDomMutations,cee),_2.set(n,a.scheduleFlush),o&&a.flush(),a}:()=>null,pee=["anchor","focus"],dee=["anchor","focus"],mee=(e,t)=>Object.keys(e).length===Object.keys(t).length&&Object.keys(e).every(r=>t.hasOwnProperty(r)&&e[r]===t[r]),MP=(e,t)=>{var r=ls(e,pee),n=ls(t,dee);return e[cs]===t[cs]&&mee(r,n)},hee=(e,t)=>{if(e.length!==t.length)return!1;for(var r=0;r<e.length;r++){var n=e[r],o=t[r];if(!O.equals(n,o)||!MP(n,o))return!1}return!0},gee=(e,t)=>{if(e.length!==t.length)return!1;for(var r=0;r<e.length;r++){var n=e[r],o=t[r];if(n.anchor.offset!==o.anchor.offset||n.focus.offset!==o.focus.offset||!MP(n,o))return!1}return!0},vee=e=>{var{isLast:t,leaf:r,parent:n,text:o}=e,a=Lo(),s=$.findPath(a,o),u=T.parent(s),l=r[TP]===!0;return a.isVoid(n)?de.createElement(O2,{length:W.string(n).length}):r.text===""&&n.children[n.children.length-1]===o&&!a.isInline(n)&&C.string(a,u)===""?de.createElement(O2,{isLineBreak:!0,isMarkPlaceholder:l}):r.text===""?de.createElement(O2,{isMarkPlaceholder:l}):t&&r.text.slice(-1)===`
1829
+ `);Pe.forEach((yt,eo)=>{yt&&C.insertText(t,yt),eo!==Pe.length-1&&C.insertSoftBreak(t)})},{at:V});if(T.equals(V.anchor.path,V.focus.path)){var[X,te]=O.edges(V),q={start:X.offset,end:te.offset,text:B};if(B&&c&&I==="insertCompositionText"){var se=c.start+c.text.search(/\S|$/),we=q.start+q.text.search(/\S|$/);we===se+1&&q.end===c.start+c.text.length?(q.start-=1,c=null,M()):c=!1}else I==="insertText"?c===null?c=q:c&&O.isCollapsed(V)&&c.end+c.text.length===X.offset?c=pd(pd({},c),{},{text:c.text+B}):c=!1:c=!1;if(le){b(X.path,q);return}}return y(()=>C.insertText(t,B),{at:V})}}}},w=()=>!!ko.get(t),S=()=>{var N;return!!((N=Zt.get(t))!==null&&N!==void 0&&N.length)},E=()=>w()||S(),D=()=>o,P=N=>{No.set(t,N),s&&(clearTimeout(s),s=null);var{selection:L}=t;if(N){var I=!L||!T.equals(L.anchor.path,N.anchor.path),V=!L||!T.equals(L.anchor.path.slice(0,-1),N.anchor.path.slice(0,-1));(I&&c||V)&&(c=!1),(I||S())&&(s=setTimeout(h,ree))}},R=()=>{(w()||!S())&&h()},F=N=>{S()||(m(!0),setTimeout(m))},M=()=>{w()||(u=setTimeout(h))},G=N=>{if(!(S()||w())&&N.some(I=>U2(t,I,N))){var L;(L=PP.get(t))===null||L===void 0||L()}};return{flush:h,scheduleFlush:M,hasPendingDiffs:S,hasPendingAction:w,hasPendingChanges:E,isFlushing:D,handleUserSelect:P,handleCompositionEnd:g,handleCompositionStart:v,handleDOMBeforeInput:x,handleKeyDown:F,handleDomMutations:G,handleInput:R}}function aee(){var e=gr(!1);return jn(()=>(e.current=!0,()=>{e.current=!1}),[]),e.current}var rl=hd?PQ:jn;function see(e,t,r){var[n]=Fi(()=>new MutationObserver(t));rl(()=>{n.takeRecords()}),jn(()=>{if(!e.current)throw new Error("Failed to attach MutationObserver, `node` is undefined");return n.observe(e.current,r),()=>n.disconnect()},[n,e,r])}var uee=["node"];function pP(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function lee(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?pP(Object(r),!0).forEach(function(n){bd(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):pP(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var cee={subtree:!0,childList:!0,characterData:!0},fee=Qt?e=>{var{node:t}=e,r=ls(e,uee);if(!Qt)return null;var n=Lo(),o=aee(),[a]=Fi(()=>iee(lee({editor:n},r)));return see(t,a.handleDomMutations,cee),_2.set(n,a.scheduleFlush),o&&a.flush(),a}:()=>null,pee=["anchor","focus"],dee=["anchor","focus"],mee=(e,t)=>Object.keys(e).length===Object.keys(t).length&&Object.keys(e).every(r=>t.hasOwnProperty(r)&&e[r]===t[r]),MP=(e,t)=>{var r=ls(e,pee),n=ls(t,dee);return e[cs]===t[cs]&&mee(r,n)},hee=(e,t)=>{if(e.length!==t.length)return!1;for(var r=0;r<e.length;r++){var n=e[r],o=t[r];if(!O.equals(n,o)||!MP(n,o))return!1}return!0},gee=(e,t)=>{if(e.length!==t.length)return!1;for(var r=0;r<e.length;r++){var n=e[r],o=t[r];if(n.anchor.offset!==o.anchor.offset||n.focus.offset!==o.focus.offset||!MP(n,o))return!1}return!0},vee=e=>{var{isLast:t,leaf:r,parent:n,text:o}=e,a=Lo(),s=$.findPath(a,o),u=T.parent(s),l=r[TP]===!0;return a.isVoid(n)?de.createElement(O2,{length:W.string(n).length}):r.text===""&&n.children[n.children.length-1]===o&&!a.isInline(n)&&C.string(a,u)===""?de.createElement(O2,{isLineBreak:!0,isMarkPlaceholder:l}):r.text===""?de.createElement(O2,{isMarkPlaceholder:l}):t&&r.text.slice(-1)===`
1830
1830
  `?de.createElement(dP,{isTrailing:!0,text:r.text}):de.createElement(dP,{text:r.text})},dP=e=>{var{text:t,isTrailing:r=!1}=e,n=gr(null),o=()=>"".concat(t??"").concat(r?`
1831
- `:""),[a]=Fi(o);return rl(()=>{var s=o();n.current&&n.current.textContent!==s&&(n.current.textContent=s)}),de.createElement(yee,{ref:n},a)},yee=TQ(AQ((e,t)=>de.createElement("span",{"data-slate-string":!0,ref:t},e.children))),O2=e=>{var{length:t=0,isLineBreak:r=!1,isMarkPlaceholder:n=!1}=e,o={"data-slate-zero-width":r?"n":"z","data-slate-length":t};return n&&(o["data-slate-mark-placeholder"]=!0),de.createElement("span",Object.assign({},o),!Qt||!r?"\uFEFF":null,r?de.createElement("br",null):null)};function bee(e,t){e.current&&(e.current.disconnect(),t&&(e.current=null))}function mP(e){e.current&&(clearTimeout(e.current),e.current=null)}var Cee=e=>{var{leaf:t,isLast:r,text:n,parent:o,renderPlaceholder:a,renderLeaf:s=x=>de.createElement(wee,Object.assign({},x))}=e,u=Lo(),l=gr(null),c=gr(null),[p,d]=Fi(!1),h=gr(null),g=ke(x=>{if(bee(l,x==null),x==null){var w;M2.delete(u),(w=t.onPlaceholderResize)===null||w===void 0||w.call(t,null)}else{if(M2.set(u,x),!l.current){var S=window.ResizeObserver||R2;l.current=new S(()=>{var E;(E=t.onPlaceholderResize)===null||E===void 0||E.call(t,x)})}l.current.observe(x),c.current=x}},[c,t,u]),v=de.createElement(vee,{isLast:r,leaf:t,parent:o,text:n}),m=t[cs];if(jn(()=>(m?h.current||(h.current=setTimeout(()=>{d(!0),h.current=null},300)):(mP(h),d(!1)),()=>mP(h)),[m,d]),m&&p){var b={children:t.placeholder,attributes:{"data-slate-placeholder":!0,style:{position:"absolute",top:0,pointerEvents:"none",width:"100%",maxWidth:"100%",display:"block",opacity:"0.333",userSelect:"none",textDecoration:"none",WebkitUserModify:Zu?"inherit":void 0},contentEditable:!1,ref:g}};v=de.createElement(de.Fragment,null,a(b),v)}var y={"data-slate-leaf":!0};return s({attributes:y,children:v,leaf:t,text:n})},xee=de.memo(Cee,(e,t)=>t.parent===e.parent&&t.isLast===e.isLast&&t.renderLeaf===e.renderLeaf&&t.renderPlaceholder===e.renderPlaceholder&&t.text===e.text&&J.equals(t.leaf,e.leaf)&&t.leaf[cs]===e.leaf[cs]),wee=e=>{var{attributes:t,children:r}=e;return de.createElement("span",Object.assign({},t),r)},See=e=>{for(var{decorations:t,isLast:r,parent:n,renderPlaceholder:o,renderLeaf:a,text:s}=e,u=Lo(),l=gr(null),c=J.decorations(s,t),p=$.findKey(u,s),d=[],h=0;h<c.length;h++){var g=c[h];d.push(de.createElement(xee,{isLast:r&&h===c.length-1,key:"".concat(p.id,"-").concat(h),renderPlaceholder:o,leaf:g,text:s,parent:n,renderLeaf:a}))}var v=ke(m=>{var b=Cd.get(u);m?(b?.set(p,m),Ri.set(s,m),tl.set(m,s)):(b?.delete(p),Ri.delete(s),l.current&&tl.delete(l.current)),l.current=m},[l,u,p,s]);return de.createElement("span",{"data-slate-node":"text",ref:v},d)},IP=de.memo(See,(e,t)=>t.parent===e.parent&&t.isLast===e.isLast&&t.renderLeaf===e.renderLeaf&&t.renderPlaceholder===e.renderPlaceholder&&t.text===e.text&&gee(t.decorations,e.decorations)),Dee=e=>{var{decorations:t,element:r,renderElement:n=x=>de.createElement(Pee,Object.assign({},x)),renderPlaceholder:o,renderLeaf:a,selection:s}=e,u=Lo(),l=Aee(),c=u.isInline(r),p=$.findKey(u,r),d=ke(x=>{var w=Cd.get(u);x?(w?.set(p,x),Ri.set(r,x),tl.set(x,r)):(w?.delete(p),Ri.delete(r))},[u,p,r]),h=LP({decorations:t,node:r,renderElement:n,renderPlaceholder:o,renderLeaf:a,selection:s}),g={"data-slate-node":"element",ref:d};if(c&&(g["data-slate-inline"]=!0),!c&&C.hasInlines(u,r)){var v=W.string(r),m=(0,z2.default)(v);m==="rtl"&&(g.dir=m)}if(C.isVoid(u,r)){g["data-slate-void"]=!0,!l&&c&&(g.contentEditable=!1);var b=c?"span":"div",[[y]]=W.texts(r);h=de.createElement(b,{"data-slate-spacer":!0,style:{height:"0",color:"transparent",outline:"none",position:"absolute"}},de.createElement(IP,{renderPlaceholder:o,decorations:[],isLast:!1,parent:r,text:y})),G2.set(y,0),j2.set(y,r)}return n({attributes:g,children:h,element:r})},Eee=de.memo(Dee,(e,t)=>e.element===t.element&&e.renderElement===t.renderElement&&e.renderLeaf===t.renderLeaf&&e.renderPlaceholder===t.renderPlaceholder&&hee(e.decorations,t.decorations)&&(e.selection===t.selection||!!e.selection&&!!t.selection&&O.equals(e.selection,t.selection))),Pee=e=>{var{attributes:t,children:r,element:n}=e,o=Lo(),a=o.isInline(n)?"span":"div";return de.createElement(a,Object.assign({},t,{style:{position:"relative"}}),r)},kP=Bi(()=>[]),Tee=()=>fs(kP),NP=Bi(!1),VP=()=>fs(NP),LP=e=>{for(var{decorations:t,node:r,renderElement:n,renderPlaceholder:o,renderLeaf:a,selection:s}=e,u=Tee(),l=Lo(),c=$.findPath(l,r),p=[],d=K.isElement(r)&&!l.isInline(r)&&C.hasInlines(l,r),h=0;h<r.children.length;h++){var g=c.concat(h),v=r.children[h],m=$.findKey(l,v),b=C.range(l,g),y=s&&O.intersection(b,s),x=u([v,g]);for(var w of t){var S=O.intersection(w,b);S&&x.push(S)}K.isElement(v)?p.push(de.createElement(NP.Provider,{key:"provider-".concat(m.id),value:!!y},de.createElement(Eee,{decorations:x,element:v,key:m.id,renderElement:n,renderPlaceholder:o,renderLeaf:a,selection:y}))):p.push(de.createElement(IP,{decorations:x,key:m.id,isLast:d&&h===r.children.length-1,parent:r,renderPlaceholder:o,renderLeaf:a,text:v})),G2.set(v,h),j2.set(v,r)}return p},$P=Bi(!1),Aee=()=>fs($P),zP=Bi(null),xd=()=>{var e=fs(zP);if(!e)throw new Error("The `useSlate` hook must be used inside the <Slate> component's context.");var{editor:t}=e;return t};function Ree(){var e=Lo(),t=gr(!1),r=gr(0),n=ke(()=>{if(!t.current){t.current=!0;var o=$.getWindow(e);o.cancelAnimationFrame(r.current),r.current=o.requestAnimationFrame(()=>{t.current=!1})}},[e]);return jn(()=>()=>cancelAnimationFrame(r.current),[]),{receivedUserInput:t,onUserInput:n}}var Fee=3,Bee={bold:"mod+b",compose:["down","left","right","up","backspace","enter"],moveBackward:"left",moveForward:"right",moveWordBackward:"ctrl+left",moveWordForward:"ctrl+right",deleteBackward:"shift?+backspace",deleteForward:"shift?+delete",extendBackward:"shift+left",extendForward:"shift+right",italic:"mod+i",insertSoftBreak:"shift+enter",splitBlock:"enter",undo:"mod+z"},Oee={moveLineBackward:"opt+up",moveLineForward:"opt+down",moveWordBackward:"opt+left",moveWordForward:"opt+right",deleteBackward:["ctrl+backspace","ctrl+h"],deleteForward:["ctrl+delete","ctrl+d"],deleteLineBackward:"cmd+shift?+backspace",deleteLineForward:["cmd+shift?+delete","ctrl+k"],deleteWordBackward:"opt+shift?+backspace",deleteWordForward:"opt+shift?+delete",extendLineBackward:"opt+shift+up",extendLineForward:"opt+shift+down",redo:"cmd+shift+z",transposeCharacter:"ctrl+t"},Mee={deleteWordBackward:"ctrl+shift?+backspace",deleteWordForward:"ctrl+shift?+delete",redo:["ctrl+y","ctrl+shift+z"]},He=e=>{var t=Bee[e],r=Oee[e],n=Mee[e],o=t&&(0,md.isHotkey)(t),a=r&&(0,md.isHotkey)(r),s=n&&(0,md.isHotkey)(n);return u=>!!(o&&o(u)||uP&&a&&a(u)||!uP&&s&&s(u))},_e={isBold:He("bold"),isCompose:He("compose"),isMoveBackward:He("moveBackward"),isMoveForward:He("moveForward"),isDeleteBackward:He("deleteBackward"),isDeleteForward:He("deleteForward"),isDeleteLineBackward:He("deleteLineBackward"),isDeleteLineForward:He("deleteLineForward"),isDeleteWordBackward:He("deleteWordBackward"),isDeleteWordForward:He("deleteWordForward"),isExtendBackward:He("extendBackward"),isExtendForward:He("extendForward"),isExtendLineBackward:He("extendLineBackward"),isExtendLineForward:He("extendLineForward"),isItalic:He("italic"),isMoveLineBackward:He("moveLineBackward"),isMoveLineForward:He("moveLineForward"),isMoveWordBackward:He("moveWordBackward"),isMoveWordForward:He("moveWordForward"),isRedo:He("redo"),isSoftBreak:He("insertSoftBreak"),isSplitBlock:He("splitBlock"),isTransposeCharacter:He("transposeCharacter"),isUndo:He("undo")},Iee=(e,t)=>{var r=[],n=()=>{r=[]},o=s=>{if(t.current){var u=s.filter(l=>U2(e,l,s));r.push(...u)}};function a(){r.length>0&&(r.reverse().forEach(s=>{s.type!=="characterData"&&(s.removedNodes.forEach(u=>{s.target.insertBefore(u,s.nextSibling)}),s.addedNodes.forEach(u=>{s.target.removeChild(u)}))}),n())}return{registerMutations:o,restoreDOM:a,clear:n}},kee={subtree:!0,childList:!0,characterData:!0,characterDataOldValue:!0},yd=class extends RQ{constructor(){super(...arguments),this.context=null,this.manager=null,this.mutationObserver=null}observe(){var t,{node:r}=this.props;if(!r.current)throw new Error("Failed to attach MutationObserver, `node` is undefined");(t=this.mutationObserver)===null||t===void 0||t.observe(r.current,kee)}componentDidMount(){var{receivedUserInput:t}=this.props,r=this.context;this.manager=Iee(r,t),this.mutationObserver=new MutationObserver(this.manager.registerMutations),this.observe()}getSnapshotBeforeUpdate(){var t,r,n,o=(t=this.mutationObserver)===null||t===void 0?void 0:t.takeRecords();if(o!=null&&o.length){var a;(a=this.manager)===null||a===void 0||a.registerMutations(o)}return(r=this.mutationObserver)===null||r===void 0||r.disconnect(),(n=this.manager)===null||n===void 0||n.restoreDOM(),null}componentDidUpdate(){var t;(t=this.manager)===null||t===void 0||t.clear(),this.observe()}componentWillUnmount(){var t;(t=this.mutationObserver)===null||t===void 0||t.disconnect()}render(){return this.props.children}};yd.contextType=H2;var Nee=Qt?yd:e=>{var{children:t}=e;return de.createElement(de.Fragment,null,t)},Vee=["autoFocus","decorate","onDOMBeforeInput","placeholder","readOnly","renderElement","renderLeaf","renderPlaceholder","scrollSelectionIntoView","style","as","disableDefaultStyles"],Lee=["text"];function hP(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function ss(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?hP(Object(r),!0).forEach(function(n){bd(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):hP(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var $ee=e=>de.createElement(de.Fragment,null,LP(e)),HP=e=>{var t=ke(A=>de.createElement(zee,Object.assign({},A)),[]),{autoFocus:r,decorate:n=Hee,onDOMBeforeInput:o,placeholder:a,readOnly:s=!1,renderElement:u,renderLeaf:l,renderPlaceholder:c=t,scrollSelectionIntoView:p=Gee,style:d={},as:h="div",disableDefaultStyles:g=!1}=e,v=ls(e,Vee),m=xd(),[b,y]=Fi(!1),x=gr(null),w=gr([]),[S,E]=Fi(),{onUserInput:D,receivedUserInput:P}=Ree(),[,R]=FQ(A=>A+1,0);PP.set(m,R),I2.set(m,s);var F=dd(()=>({isDraggingInternally:!1,isUpdatingSelection:!1,latestElement:null,hasMarkPlaceholder:!1}),[]);jn(()=>{x.current&&r&&x.current.focus()},[r]);var M=gr(),G=dd(()=>(0,wP.default)(()=>{var A=M.current;if((Qt||!$.isComposing(m))&&(!F.isUpdatingSelection||A!=null&&A.isFlushing())&&!F.isDraggingInternally){var _=$.findDocumentOrShadowRoot(m),{activeElement:z}=_,j=$.toDOMNode(m,m),ue=_.getSelection();if(z===j?(F.latestElement=z,Ti.set(m,!0)):Ti.delete(m),!ue)return k.deselect(m);var{anchorNode:oe,focusNode:he}=ue,Ce=$.hasEditableTarget(m,oe)||$.isTargetInsideNonReadonlyVoid(m,oe),Se=$.hasEditableTarget(m,he)||$.isTargetInsideNonReadonlyVoid(m,he);if(Ce&&Se){var Ee=$.toSlateRange(m,ue,{exactMatch:!1,suppressThrow:!0});Ee&&(!$.isComposing(m)&&!(A!=null&&A.hasPendingChanges())&&!(A!=null&&A.isFlushing())?k.select(m,Ee):A?.handleUserSelect(Ee))}s&&(!Ce||!Se)&&k.deselect(m)}},100),[m,s,F]),N=dd(()=>(0,xP.default)(G,0),[G]);M.current=fee({node:x,onDOMSelectionChange:G,scheduleOnDOMSelectionChange:N}),rl(()=>{var A,_,z;x.current&&(z=W2(x.current))?(EP.set(m,z),gd.set(m,x.current),Ri.set(m,x.current),tl.set(x.current,m)):Ri.delete(m);var{selection:j}=m,ue=$.findDocumentOrShadowRoot(m),oe=ue.getSelection();if(!(!oe||!$.isFocused(m)||(A=M.current)!==null&&A!==void 0&&A.hasPendingAction())){var he=xe=>{var ht=oe.type!=="None";if(!(!j&&!ht)){var gt=oe.focusNode,je;if(Qu&&oe.rangeCount>1){var or=oe.getRangeAt(0),Ht=oe.getRangeAt(oe.rangeCount-1);or.startContainer===gt?je=Ht.endContainer:je=or.startContainer}else je=oe.anchorNode;var St=gd.get(m),ir=!1;if(St.contains(je)&&St.contains(gt)&&(ir=!0),ht&&ir&&j&&!xe){var B=$.toSlateRange(m,oe,{exactMatch:!0,suppressThrow:!0});if(B&&O.equals(B,j)){var X,te;if(!F.hasMarkPlaceholder||(X=je)!==null&&X!==void 0&&(te=X.parentElement)!==null&&te!==void 0&&te.hasAttribute("data-slate-mark-placeholder"))return}}if(j&&!$.hasRange(m,j)){m.selection=$.toSlateRange(m,oe,{exactMatch:!1,suppressThrow:!0});return}F.isUpdatingSelection=!0;var q=j&&$.toDOMRange(m,j);return q?($.isComposing(m)&&!Qt?oe.collapseToEnd():O.isBackward(j)?oe.setBaseAndExtent(q.endContainer,q.endOffset,q.startContainer,q.startOffset):oe.setBaseAndExtent(q.startContainer,q.startOffset,q.endContainer,q.endOffset),p(m,q)):oe.removeAllRanges(),q}};oe.rangeCount<=1&&he();var Ce=((_=M.current)===null||_===void 0?void 0:_.isFlushing())==="action";if(!Qt||!Ce){setTimeout(()=>{F.isUpdatingSelection=!1});return}var Se=null,Ee=requestAnimationFrame(()=>{if(Ce){var xe=ht=>{try{var gt=$.toDOMNode(m,m);gt.focus(),he(ht)}catch{}};xe(),Se=setTimeout(()=>{xe(!0),F.isUpdatingSelection=!1})}});return()=>{cancelAnimationFrame(Ee),Se&&clearTimeout(Se)}}});var L=ke(A=>{if(D(),!s&&$.hasEditableTarget(m,A.target)&&!jee(A,o)){var _;if(M.current)return M.current.handleDOMBeforeInput(A);N.flush(),G.flush();var{selection:z}=m,{inputType:j}=A,ue=A.dataTransfer||A.data||void 0,oe=j==="insertCompositionText"||j==="deleteCompositionText";if(oe&&$.isComposing(m))return;var he=!1;if(j==="insertText"&&z&&O.isCollapsed(z)&&A.data&&A.data.length===1&&/[a-z ]/i.test(A.data)&&z.anchor.offset!==0){var Ce,Se;he=!0,m.marks&&(he=!1);var{anchor:Ee}=z,[xe,ht]=$.toDOMPoint(m,Ee),gt=(Ce=xe.parentElement)===null||Ce===void 0?void 0:Ce.closest("a"),je=$.getWindow(m);if(he&&gt&&$.hasDOMNode(m,gt)){var or,Ht=je?.document.createTreeWalker(gt,NodeFilter.SHOW_TEXT).lastChild();Ht===xe&&((or=Ht.textContent)===null||or===void 0?void 0:or.length)===ht&&(he=!1)}if(he&&xe.parentElement&&(je==null||(Se=je.getComputedStyle(xe.parentElement))===null||Se===void 0?void 0:Se.whiteSpace)==="pre"){var St=C.above(m,{at:Ee.path,match:se=>K.isElement(se)&&C.isBlock(m,se)});St&&W.string(St[0]).includes(" ")&&(he=!1)}}if(!j.startsWith("delete")||j.startsWith("deleteBy")){var[ir]=A.getTargetRanges();if(ir){var B=$.toSlateRange(m,ir,{exactMatch:!1,suppressThrow:!1});if(!z||!O.equals(z,B)){he=!1;var X=!oe&&m.selection&&C.rangeRef(m,m.selection);k.select(m,B),X&&el.set(m,X)}}}if(oe)return;if(he||A.preventDefault(),z&&O.isExpanded(z)&&j.startsWith("delete")){var te=j.endsWith("Backward")?"backward":"forward";C.deleteFragment(m,{direction:te});return}switch(j){case"deleteByComposition":case"deleteByCut":case"deleteByDrag":{C.deleteFragment(m);break}case"deleteContent":case"deleteContentForward":{C.deleteForward(m);break}case"deleteContentBackward":{C.deleteBackward(m);break}case"deleteEntireSoftLine":{C.deleteBackward(m,{unit:"line"}),C.deleteForward(m,{unit:"line"});break}case"deleteHardLineBackward":{C.deleteBackward(m,{unit:"block"});break}case"deleteSoftLineBackward":{C.deleteBackward(m,{unit:"line"});break}case"deleteHardLineForward":{C.deleteForward(m,{unit:"block"});break}case"deleteSoftLineForward":{C.deleteForward(m,{unit:"line"});break}case"deleteWordBackward":{C.deleteBackward(m,{unit:"word"});break}case"deleteWordForward":{C.deleteForward(m,{unit:"word"});break}case"insertLineBreak":C.insertSoftBreak(m);break;case"insertParagraph":{C.insertBreak(m);break}case"insertFromComposition":case"insertFromDrop":case"insertFromPaste":case"insertFromYank":case"insertReplacementText":case"insertText":{j==="insertFromComposition"&&$.isComposing(m)&&(y(!1),Ai.set(m,!1)),ue?.constructor.name==="DataTransfer"?$.insertData(m,ue):typeof ue=="string"&&(he?w.current.push(()=>C.insertText(m,ue)):C.insertText(m,ue));break}}var q=(_=el.get(m))===null||_===void 0?void 0:_.unref();el.delete(m),q&&(!m.selection||!O.equals(m.selection,q))&&k.select(m,q)}},[m,G,D,o,s,N]),I=ke(A=>{A==null?(G.cancel(),N.cancel(),gd.delete(m),Ri.delete(m),x.current&&Io&&x.current.removeEventListener("beforeinput",L)):Io&&A.addEventListener("beforeinput",L),x.current=A},[G,N,m,L]);rl(()=>{var A=$.getWindow(m);return A.document.addEventListener("selectionchange",N),()=>{A.document.removeEventListener("selectionchange",N)}},[N]);var V=n([m,[]]),Y=a&&m.children.length===1&&Array.from(W.texts(m)).length===1&&W.string(m)===""&&!b,Q=ke(A=>{if(A&&Y){var _;E((_=A.getBoundingClientRect())===null||_===void 0?void 0:_.height)}else E(void 0)},[Y]);if(Y){var re=C.start(m,[]);V.push({[cs]:!0,placeholder:a,onPlaceholderResize:Q,anchor:re,focus:re})}var{marks:H}=m;if(F.hasMarkPlaceholder=!1,m.selection&&O.isCollapsed(m.selection)&&H){var{anchor:le}=m.selection,ve=W.leaf(m,le.path),me=ls(ve,Lee);if(!J.equals(ve,H,{loose:!0})){F.hasMarkPlaceholder=!0;var Ge=Object.fromEntries(Object.keys(me).map(A=>[A,null]));V.push(ss(ss(ss({[TP]:!0},Ge),H),{},{anchor:le,focus:le}))}}return jn(()=>{setTimeout(()=>{var{selection:A}=m;if(A){var{anchor:_}=A,z=W.leaf(m,_.path);if(H&&!J.equals(z,H,{loose:!0})){Gr.set(m,H);return}}Gr.delete(m)})}),de.createElement($P.Provider,{value:s},de.createElement(kP.Provider,{value:n},de.createElement(Nee,{node:x,receivedUserInput:P},de.createElement(h,Object.assign({role:s?void 0:"textbox","aria-multiline":s?void 0:!0},v,{spellCheck:Io||!hd?v.spellCheck:!1,autoCorrect:Io||!hd?v.autoCorrect:"false",autoCapitalize:Io||!hd?v.autoCapitalize:"false","data-slate-editor":!0,"data-slate-node":"value",contentEditable:!s,zindex:-1,suppressContentEditableWarning:!0,ref:I,style:ss(ss({},g?{}:ss({position:"relative",whiteSpace:"pre-wrap",wordWrap:"break-word"},S?{minHeight:S}:{})),d),onBeforeInput:ke(A=>{if(!Io&&!s&&!Lt(A,v.onBeforeInput)&&$.hasSelectableTarget(m,A.target)&&(A.preventDefault(),!$.isComposing(m))){var _=A.data;C.insertText(m,_)}},[v.onBeforeInput,m,s]),onInput:ke(A=>{if(!Lt(A,v.onInput)){if(M.current){M.current.handleInput();return}for(var _ of w.current)_();w.current=[]}},[v.onInput]),onBlur:ke(A=>{if(!(s||F.isUpdatingSelection||!$.hasSelectableTarget(m,A.target)||Lt(A,v.onBlur))){var _=$.findDocumentOrShadowRoot(m);if(F.latestElement!==_.activeElement){var{relatedTarget:z}=A,j=$.toDOMNode(m,m);if(z!==j&&!(Pr(z)&&z.hasAttribute("data-slate-spacer"))){if(z!=null&&Vo(z)&&$.hasDOMNode(m,z)){var ue=$.toSlateNode(m,z);if(K.isElement(ue)&&!m.isVoid(ue))return}if(Zu){var oe=_.getSelection();oe?.removeAllRanges()}Ti.delete(m)}}}},[s,F.isUpdatingSelection,F.latestElement,m,v.onBlur]),onClick:ke(A=>{if($.hasTarget(m,A.target)&&!Lt(A,v.onClick)&&Vo(A.target)){var _=$.toSlateNode(m,A.target),z=$.findPath(m,_);if(!C.hasPath(m,z)||W.get(m,z)!==_)return;if(A.detail===Fee&&z.length>=1){var j=z;if(!(K.isElement(_)&&C.isBlock(m,_))){var ue,oe=C.above(m,{match:gt=>K.isElement(gt)&&C.isBlock(m,gt),at:z});j=(ue=oe?.[1])!==null&&ue!==void 0?ue:z.slice(0,1)}var he=C.range(m,j);k.select(m,he);return}if(s)return;var Ce=C.start(m,z),Se=C.end(m,z),Ee=C.void(m,{at:Ce}),xe=C.void(m,{at:Se});if(Ee&&xe&&T.equals(Ee[1],xe[1])){var ht=C.range(m,Ce);k.select(m,ht)}}},[m,v.onClick,s]),onCompositionEnd:ke(A=>{if($.hasSelectableTarget(m,A.target)){var _;if($.isComposing(m)&&(y(!1),Ai.set(m,!1)),(_=M.current)===null||_===void 0||_.handleCompositionEnd(A),Lt(A,v.onCompositionEnd)||Qt)return;if(!Zu&&!VQ&&!MQ&&!$Q&&!LQ&&A.data){var z=Gr.get(m);Gr.delete(m),z!==void 0&&(Gn.set(m,m.marks),m.marks=z),C.insertText(m,A.data);var j=Gn.get(m);Gn.delete(m),j!==void 0&&(m.marks=j)}}},[v.onCompositionEnd,m]),onCompositionUpdate:ke(A=>{$.hasSelectableTarget(m,A.target)&&!Lt(A,v.onCompositionUpdate)&&($.isComposing(m)||(y(!0),Ai.set(m,!0)))},[v.onCompositionUpdate,m]),onCompositionStart:ke(A=>{if($.hasSelectableTarget(m,A.target)){var _;if((_=M.current)===null||_===void 0||_.handleCompositionStart(A),Lt(A,v.onCompositionStart)||Qt)return;y(!0);var{selection:z}=m;if(z){if(O.isExpanded(z)){C.deleteFragment(m);return}var j=C.above(m,{match:he=>K.isElement(he)&&C.isInline(m,he),mode:"highest"});if(j){var[,ue]=j;if(C.isEnd(m,z.anchor,ue)){var oe=C.after(m,ue);k.setSelection(m,{anchor:oe,focus:oe})}}}}},[v.onCompositionStart,m]),onCopy:ke(A=>{$.hasSelectableTarget(m,A.target)&&!Lt(A,v.onCopy)&&!gP(A)&&(A.preventDefault(),$.setFragmentData(m,A.clipboardData,"copy"))},[v.onCopy,m]),onCut:ke(A=>{if(!s&&$.hasSelectableTarget(m,A.target)&&!Lt(A,v.onCut)&&!gP(A)){A.preventDefault(),$.setFragmentData(m,A.clipboardData,"cut");var{selection:_}=m;if(_)if(O.isExpanded(_))C.deleteFragment(m);else{var z=W.parent(m,_.anchor.path);C.isVoid(m,z)&&k.delete(m)}}},[s,m,v.onCut]),onDragOver:ke(A=>{if($.hasTarget(m,A.target)&&!Lt(A,v.onDragOver)){var _=$.toSlateNode(m,A.target);K.isElement(_)&&C.isVoid(m,_)&&A.preventDefault()}},[v.onDragOver,m]),onDragStart:ke(A=>{if(!s&&$.hasTarget(m,A.target)&&!Lt(A,v.onDragStart)){var _=$.toSlateNode(m,A.target),z=$.findPath(m,_),j=K.isElement(_)&&C.isVoid(m,_)||C.void(m,{at:z,voids:!0});if(j){var ue=C.range(m,z);k.select(m,ue)}F.isDraggingInternally=!0,$.setFragmentData(m,A.dataTransfer,"drag")}},[s,m,v.onDragStart,F]),onDrop:ke(A=>{if(!s&&$.hasTarget(m,A.target)&&!Lt(A,v.onDrop)){A.preventDefault();var _=m.selection,z=$.findEventRange(m,A),j=A.dataTransfer;k.select(m,z),F.isDraggingInternally&&_&&!O.equals(_,z)&&!C.void(m,{at:z,voids:!0})&&k.delete(m,{at:_}),$.insertData(m,j),$.isFocused(m)||$.focus(m)}F.isDraggingInternally=!1},[s,m,v.onDrop,F]),onDragEnd:ke(A=>{!s&&F.isDraggingInternally&&v.onDragEnd&&$.hasTarget(m,A.target)&&v.onDragEnd(A),F.isDraggingInternally=!1},[s,F,v,m]),onFocus:ke(A=>{if(!s&&!F.isUpdatingSelection&&$.hasEditableTarget(m,A.target)&&!Lt(A,v.onFocus)){var _=$.toDOMNode(m,m),z=$.findDocumentOrShadowRoot(m);if(F.latestElement=z.activeElement,Qu&&A.target!==_){_.focus();return}Ti.set(m,!0)}},[s,F,m,v.onFocus]),onKeyDown:ke(A=>{if(!s&&$.hasEditableTarget(m,A.target)){var _;(_=M.current)===null||_===void 0||_.handleKeyDown(A);var{nativeEvent:z}=A;if($.isComposing(m)&&z.isComposing===!1&&(Ai.set(m,!1),y(!1)),Lt(A,v.onKeyDown)||$.isComposing(m))return;var{selection:j}=m,ue=m.children[j!==null?j.focus.path[0]:0],oe=(0,z2.default)(W.string(ue))==="rtl";if(_e.isRedo(z)){A.preventDefault();var he=m;typeof he.redo=="function"&&he.redo();return}if(_e.isUndo(z)){A.preventDefault();var Ce=m;typeof Ce.undo=="function"&&Ce.undo();return}if(_e.isMoveLineBackward(z)){A.preventDefault(),k.move(m,{unit:"line",reverse:!0});return}if(_e.isMoveLineForward(z)){A.preventDefault(),k.move(m,{unit:"line"});return}if(_e.isExtendLineBackward(z)){A.preventDefault(),k.move(m,{unit:"line",edge:"focus",reverse:!0});return}if(_e.isExtendLineForward(z)){A.preventDefault(),k.move(m,{unit:"line",edge:"focus"});return}if(_e.isMoveBackward(z)){A.preventDefault(),j&&O.isCollapsed(j)?k.move(m,{reverse:!oe}):k.collapse(m,{edge:"start"});return}if(_e.isMoveForward(z)){A.preventDefault(),j&&O.isCollapsed(j)?k.move(m,{reverse:oe}):k.collapse(m,{edge:"end"});return}if(_e.isMoveWordBackward(z)){A.preventDefault(),j&&O.isExpanded(j)&&k.collapse(m,{edge:"focus"}),k.move(m,{unit:"word",reverse:!oe});return}if(_e.isMoveWordForward(z)){A.preventDefault(),j&&O.isExpanded(j)&&k.collapse(m,{edge:"focus"}),k.move(m,{unit:"word",reverse:oe});return}if(Io){if((DP||Zu)&&j&&(_e.isDeleteBackward(z)||_e.isDeleteForward(z))&&O.isCollapsed(j)){var Se=W.parent(m,j.anchor.path);if(K.isElement(Se)&&C.isVoid(m,Se)&&(C.isInline(m,Se)||C.isBlock(m,Se))){A.preventDefault(),C.deleteBackward(m,{unit:"block"});return}}}else{if(_e.isBold(z)||_e.isItalic(z)||_e.isTransposeCharacter(z)){A.preventDefault();return}if(_e.isSoftBreak(z)){A.preventDefault(),C.insertSoftBreak(m);return}if(_e.isSplitBlock(z)){A.preventDefault(),C.insertBreak(m);return}if(_e.isDeleteBackward(z)){A.preventDefault(),j&&O.isExpanded(j)?C.deleteFragment(m,{direction:"backward"}):C.deleteBackward(m);return}if(_e.isDeleteForward(z)){A.preventDefault(),j&&O.isExpanded(j)?C.deleteFragment(m,{direction:"forward"}):C.deleteForward(m);return}if(_e.isDeleteLineBackward(z)){A.preventDefault(),j&&O.isExpanded(j)?C.deleteFragment(m,{direction:"backward"}):C.deleteBackward(m,{unit:"line"});return}if(_e.isDeleteLineForward(z)){A.preventDefault(),j&&O.isExpanded(j)?C.deleteFragment(m,{direction:"forward"}):C.deleteForward(m,{unit:"line"});return}if(_e.isDeleteWordBackward(z)){A.preventDefault(),j&&O.isExpanded(j)?C.deleteFragment(m,{direction:"backward"}):C.deleteBackward(m,{unit:"word"});return}if(_e.isDeleteWordForward(z)){A.preventDefault(),j&&O.isExpanded(j)?C.deleteFragment(m,{direction:"forward"}):C.deleteForward(m,{unit:"word"});return}}}},[s,m,v.onKeyDown]),onPaste:ke(A=>{!s&&$.hasEditableTarget(m,A.target)&&!Lt(A,v.onPaste)&&(!Io||GQ(A.nativeEvent)||Zu)&&(A.preventDefault(),$.insertData(m,A.clipboardData))},[s,m,v.onPaste])}),de.createElement($ee,{decorations:V,node:m,renderElement:u,renderPlaceholder:c,renderLeaf:l,selection:m.selection})))))},zee=e=>{var{attributes:t,children:r}=e;return de.createElement("span",Object.assign({},t),r,Qt&&de.createElement("br",null))},Hee=()=>[],Gee=(e,t)=>{if(t.getBoundingClientRect&&(!e.selection||e.selection&&O.isCollapsed(e.selection))){var r=t.startContainer.parentElement;r.getBoundingClientRect=t.getBoundingClientRect.bind(t),qD(r,{scrollMode:"if-needed"}),delete r.getBoundingClientRect}},Lt=(e,t)=>{if(!t)return!1;var r=t(e);return r??(e.isDefaultPrevented()||e.isPropagationStopped())},gP=e=>Vo(e.target)&&(e.target instanceof HTMLInputElement||e.target instanceof HTMLTextAreaElement),jee=(e,t)=>{if(!t)return!1;var r=t(e);return r??e.defaultPrevented},GP=Bi(!1),jP=()=>fs(GP);var _ee=Bi({});function Wee(e){var t=gr([]).current,r=gr({editor:e}).current,n=ke(a=>{r.editor=a,t.forEach(s=>s(a))},[t,r]),o=dd(()=>({getSlate:()=>r.editor,addEventListener:a=>(t.push(a),()=>{t.splice(t.indexOf(a),1)})}),[t,r]);return{selectorContext:o,onChange:n}}var Uee=["editor","children","onChange","initialValue"],_P=e=>{var{editor:t,children:r,onChange:n,initialValue:o}=e,a=ls(e,Uee),[s,u]=de.useState(()=>{if(!W.isNodeList(o))throw new Error("[Slate] initialValue is invalid! Expected a list of elements but got: ".concat(it.stringify(o)));if(!C.isEditor(t))throw new Error("[Slate] editor is invalid! You passed: ".concat(it.stringify(t)));return t.children=o,Object.assign(t,a),{v:0,editor:t}}),{selectorContext:l,onChange:c}=Wee(t),p=ke(()=>{n&&n(t.children),u(g=>({v:g.v+1,editor:t})),c(t)},[t,c,n]);jn(()=>(k2.set(t,p),()=>{k2.set(t,()=>{})}),[t,p]);var[d,h]=Fi($.isFocused(t));return jn(()=>{h($.isFocused(t))},[t]),rl(()=>{var g=()=>h($.isFocused(t));return SP>=17?(document.addEventListener("focusin",g),document.addEventListener("focusout",g),()=>{document.removeEventListener("focusin",g),document.removeEventListener("focusout",g)}):(document.addEventListener("focus",g,!0),document.addEventListener("blur",g,!0),()=>{document.removeEventListener("focus",g,!0),document.removeEventListener("blur",g,!0)})},[]),de.createElement(_ee.Provider,{value:l},de.createElement(zP.Provider,{value:s},de.createElement(H2.Provider,{value:s.editor},de.createElement(GP.Provider,{value:d},r))))};var vP=(e,t)=>{var r=(t.top+t.bottom)/2;return e.top<=r&&e.bottom>=r},yP=(e,t,r)=>{var n=$.toDOMRange(e,t).getBoundingClientRect(),o=$.toDOMRange(e,r).getBoundingClientRect();return vP(n,o)&&vP(o,n)},Kee=(e,t)=>{var r=C.range(e,O.end(t)),n=Array.from(C.positions(e,{at:t})),o=0,a=n.length,s=Math.floor(a/2);if(yP(e,C.range(e,n[o]),r))return C.range(e,n[o],r);if(n.length<2)return C.range(e,n[n.length-1],r);for(;s!==n.length&&s!==o;)yP(e,C.range(e,n[s]),r)?a=s:o=s,s=Math.floor((o+a)/2);return C.range(e,n[a],r)};function bP(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function CP(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?bP(Object(r),!0).forEach(function(n){bd(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):bP(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var WP=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"x-slate-fragment",n=t,{apply:o,onChange:a,deleteBackward:s,addMark:u,removeMark:l}=n;return Cd.set(n,new WeakMap),n.addMark=(c,p)=>{var d,h;(d=_2.get(n))===null||d===void 0||d(),!Gr.get(n)&&(h=Zt.get(n))!==null&&h!==void 0&&h.length&&Gr.set(n,null),Gn.delete(n),u(c,p)},n.removeMark=c=>{var p;!Gr.get(n)&&(p=Zt.get(n))!==null&&p!==void 0&&p.length&&Gr.set(n,null),Gn.delete(n),l(c)},n.deleteBackward=c=>{if(c!=="line")return s(c);if(n.selection&&O.isCollapsed(n.selection)){var p=C.above(n,{match:v=>K.isElement(v)&&C.isBlock(n,v),at:n.selection});if(p){var[,d]=p,h=C.range(n,d,n.selection.anchor),g=Kee(n,h);O.isCollapsed(g)||k.delete(n,{at:g})}}},n.apply=c=>{var p=[],d=[],h=Zt.get(n);if(h!=null&&h.length){var g=h.map(I=>eee(I,c)).filter(Boolean);Zt.set(n,g)}var v=No.get(n);v&&No.set(n,cP(n,v,c));var m=ko.get(n);if(m!=null&&m.at){var b=ge.isPoint(m?.at)?$2(n,m.at,c):cP(n,m.at,c);ko.set(n,b?CP(CP({},m),{},{at:b}):null)}switch(c.type){case"insert_text":case"remove_text":case"set_node":case"split_node":{p.push(...us(n,c.path));break}case"set_selection":{var y;(y=el.get(n))===null||y===void 0||y.unref(),el.delete(n);break}case"insert_node":case"remove_node":{p.push(...us(n,T.parent(c.path)));break}case"merge_node":{var x=T.previous(c.path);p.push(...us(n,x));break}case"move_node":{var w=T.common(T.parent(c.path),T.parent(c.newPath));p.push(...us(n,w));var S;T.isBefore(c.path,c.newPath)?(p.push(...us(n,T.parent(c.path))),S=c.newPath):(p.push(...us(n,T.parent(c.newPath))),S=c.path);var E=W.get(t,T.parent(S)),D=$.findKey(n,E),P=C.pathRef(n,T.parent(S));d.push([P,D]);break}}o(c);for(var[R,F]of p){var[M]=C.node(n,R);vd.set(M,F)}for(var[G,N]of d)if(G.current){var[L]=C.node(n,G.current);vd.set(L,N)}},n.setFragmentData=c=>{var{selection:p}=n;if(p){var[d,h]=O.edges(p),g=C.void(n,{at:d.path}),v=C.void(n,{at:h.path});if(!(O.isCollapsed(p)&&!g)){var m=$.toDOMRange(n,p),b=m.cloneContents(),y=b.childNodes[0];if(b.childNodes.forEach(M=>{M.textContent&&M.textContent.trim()!==""&&(y=M)}),v){var[x]=v,w=m.cloneRange(),S=$.toDOMNode(n,x);w.setEndAfter(S),b=w.cloneContents()}if(g&&(y=b.querySelector("[data-slate-spacer]")),Array.from(b.querySelectorAll("[data-slate-zero-width]")).forEach(M=>{var G=M.getAttribute("data-slate-zero-width")==="n";M.textContent=G?`
1831
+ `:""),[a]=Fi(o);return rl(()=>{var s=o();n.current&&n.current.textContent!==s&&(n.current.textContent=s)}),de.createElement(yee,{ref:n},a)},yee=TQ(AQ((e,t)=>de.createElement("span",{"data-slate-string":!0,ref:t},e.children))),O2=e=>{var{length:t=0,isLineBreak:r=!1,isMarkPlaceholder:n=!1}=e,o={"data-slate-zero-width":r?"n":"z","data-slate-length":t};return n&&(o["data-slate-mark-placeholder"]=!0),de.createElement("span",Object.assign({},o),!Qt||!r?"\uFEFF":null,r?de.createElement("br",null):null)};function bee(e,t){e.current&&(e.current.disconnect(),t&&(e.current=null))}function mP(e){e.current&&(clearTimeout(e.current),e.current=null)}var Cee=e=>{var{leaf:t,isLast:r,text:n,parent:o,renderPlaceholder:a,renderLeaf:s=x=>de.createElement(wee,Object.assign({},x))}=e,u=Lo(),l=gr(null),c=gr(null),[p,d]=Fi(!1),h=gr(null),g=ke(x=>{if(bee(l,x==null),x==null){var w;M2.delete(u),(w=t.onPlaceholderResize)===null||w===void 0||w.call(t,null)}else{if(M2.set(u,x),!l.current){var S=window.ResizeObserver||R2;l.current=new S(()=>{var E;(E=t.onPlaceholderResize)===null||E===void 0||E.call(t,x)})}l.current.observe(x),c.current=x}},[c,t,u]),v=de.createElement(vee,{isLast:r,leaf:t,parent:o,text:n}),m=t[cs];if(jn(()=>(m?h.current||(h.current=setTimeout(()=>{d(!0),h.current=null},300)):(mP(h),d(!1)),()=>mP(h)),[m,d]),m&&p){var b={children:t.placeholder,attributes:{"data-slate-placeholder":!0,style:{position:"absolute",top:0,pointerEvents:"none",width:"100%",maxWidth:"100%",display:"block",opacity:"0.333",userSelect:"none",textDecoration:"none",WebkitUserModify:Zu?"inherit":void 0},contentEditable:!1,ref:g}};v=de.createElement(de.Fragment,null,a(b),v)}var y={"data-slate-leaf":!0};return s({attributes:y,children:v,leaf:t,text:n})},xee=de.memo(Cee,(e,t)=>t.parent===e.parent&&t.isLast===e.isLast&&t.renderLeaf===e.renderLeaf&&t.renderPlaceholder===e.renderPlaceholder&&t.text===e.text&&J.equals(t.leaf,e.leaf)&&t.leaf[cs]===e.leaf[cs]),wee=e=>{var{attributes:t,children:r}=e;return de.createElement("span",Object.assign({},t),r)},See=e=>{for(var{decorations:t,isLast:r,parent:n,renderPlaceholder:o,renderLeaf:a,text:s}=e,u=Lo(),l=gr(null),c=J.decorations(s,t),p=$.findKey(u,s),d=[],h=0;h<c.length;h++){var g=c[h];d.push(de.createElement(xee,{isLast:r&&h===c.length-1,key:"".concat(p.id,"-").concat(h),renderPlaceholder:o,leaf:g,text:s,parent:n,renderLeaf:a}))}var v=ke(m=>{var b=Cd.get(u);m?(b?.set(p,m),Ri.set(s,m),tl.set(m,s)):(b?.delete(p),Ri.delete(s),l.current&&tl.delete(l.current)),l.current=m},[l,u,p,s]);return de.createElement("span",{"data-slate-node":"text",ref:v},d)},IP=de.memo(See,(e,t)=>t.parent===e.parent&&t.isLast===e.isLast&&t.renderLeaf===e.renderLeaf&&t.renderPlaceholder===e.renderPlaceholder&&t.text===e.text&&gee(t.decorations,e.decorations)),Dee=e=>{var{decorations:t,element:r,renderElement:n=x=>de.createElement(Pee,Object.assign({},x)),renderPlaceholder:o,renderLeaf:a,selection:s}=e,u=Lo(),l=Aee(),c=u.isInline(r),p=$.findKey(u,r),d=ke(x=>{var w=Cd.get(u);x?(w?.set(p,x),Ri.set(r,x),tl.set(x,r)):(w?.delete(p),Ri.delete(r))},[u,p,r]),h=LP({decorations:t,node:r,renderElement:n,renderPlaceholder:o,renderLeaf:a,selection:s}),g={"data-slate-node":"element",ref:d};if(c&&(g["data-slate-inline"]=!0),!c&&C.hasInlines(u,r)){var v=W.string(r),m=(0,z2.default)(v);m==="rtl"&&(g.dir=m)}if(C.isVoid(u,r)){g["data-slate-void"]=!0,!l&&c&&(g.contentEditable=!1);var b=c?"span":"div",[[y]]=W.texts(r);h=de.createElement(b,{"data-slate-spacer":!0,style:{height:"0",color:"transparent",outline:"none",position:"absolute"}},de.createElement(IP,{renderPlaceholder:o,decorations:[],isLast:!1,parent:r,text:y})),G2.set(y,0),j2.set(y,r)}return n({attributes:g,children:h,element:r})},Eee=de.memo(Dee,(e,t)=>e.element===t.element&&e.renderElement===t.renderElement&&e.renderLeaf===t.renderLeaf&&e.renderPlaceholder===t.renderPlaceholder&&hee(e.decorations,t.decorations)&&(e.selection===t.selection||!!e.selection&&!!t.selection&&O.equals(e.selection,t.selection))),Pee=e=>{var{attributes:t,children:r,element:n}=e,o=Lo(),a=o.isInline(n)?"span":"div";return de.createElement(a,Object.assign({},t,{style:{position:"relative"}}),r)},kP=Bi(()=>[]),Tee=()=>fs(kP),NP=Bi(!1),VP=()=>fs(NP),LP=e=>{for(var{decorations:t,node:r,renderElement:n,renderPlaceholder:o,renderLeaf:a,selection:s}=e,u=Tee(),l=Lo(),c=$.findPath(l,r),p=[],d=K.isElement(r)&&!l.isInline(r)&&C.hasInlines(l,r),h=0;h<r.children.length;h++){var g=c.concat(h),v=r.children[h],m=$.findKey(l,v),b=C.range(l,g),y=s&&O.intersection(b,s),x=u([v,g]);for(var w of t){var S=O.intersection(w,b);S&&x.push(S)}K.isElement(v)?p.push(de.createElement(NP.Provider,{key:"provider-".concat(m.id),value:!!y},de.createElement(Eee,{decorations:x,element:v,key:m.id,renderElement:n,renderPlaceholder:o,renderLeaf:a,selection:y}))):p.push(de.createElement(IP,{decorations:x,key:m.id,isLast:d&&h===r.children.length-1,parent:r,renderPlaceholder:o,renderLeaf:a,text:v})),G2.set(v,h),j2.set(v,r)}return p},$P=Bi(!1),Aee=()=>fs($P),zP=Bi(null),xd=()=>{var e=fs(zP);if(!e)throw new Error("The `useSlate` hook must be used inside the <Slate> component's context.");var{editor:t}=e;return t};function Ree(){var e=Lo(),t=gr(!1),r=gr(0),n=ke(()=>{if(!t.current){t.current=!0;var o=$.getWindow(e);o.cancelAnimationFrame(r.current),r.current=o.requestAnimationFrame(()=>{t.current=!1})}},[e]);return jn(()=>()=>cancelAnimationFrame(r.current),[]),{receivedUserInput:t,onUserInput:n}}var Fee=3,Bee={bold:"mod+b",compose:["down","left","right","up","backspace","enter"],moveBackward:"left",moveForward:"right",moveWordBackward:"ctrl+left",moveWordForward:"ctrl+right",deleteBackward:"shift?+backspace",deleteForward:"shift?+delete",extendBackward:"shift+left",extendForward:"shift+right",italic:"mod+i",insertSoftBreak:"shift+enter",splitBlock:"enter",undo:"mod+z"},Oee={moveLineBackward:"opt+up",moveLineForward:"opt+down",moveWordBackward:"opt+left",moveWordForward:"opt+right",deleteBackward:["ctrl+backspace","ctrl+h"],deleteForward:["ctrl+delete","ctrl+d"],deleteLineBackward:"cmd+shift?+backspace",deleteLineForward:["cmd+shift?+delete","ctrl+k"],deleteWordBackward:"opt+shift?+backspace",deleteWordForward:"opt+shift?+delete",extendLineBackward:"opt+shift+up",extendLineForward:"opt+shift+down",redo:"cmd+shift+z",transposeCharacter:"ctrl+t"},Mee={deleteWordBackward:"ctrl+shift?+backspace",deleteWordForward:"ctrl+shift?+delete",redo:["ctrl+y","ctrl+shift+z"]},He=e=>{var t=Bee[e],r=Oee[e],n=Mee[e],o=t&&(0,md.isHotkey)(t),a=r&&(0,md.isHotkey)(r),s=n&&(0,md.isHotkey)(n);return u=>!!(o&&o(u)||uP&&a&&a(u)||!uP&&s&&s(u))},_e={isBold:He("bold"),isCompose:He("compose"),isMoveBackward:He("moveBackward"),isMoveForward:He("moveForward"),isDeleteBackward:He("deleteBackward"),isDeleteForward:He("deleteForward"),isDeleteLineBackward:He("deleteLineBackward"),isDeleteLineForward:He("deleteLineForward"),isDeleteWordBackward:He("deleteWordBackward"),isDeleteWordForward:He("deleteWordForward"),isExtendBackward:He("extendBackward"),isExtendForward:He("extendForward"),isExtendLineBackward:He("extendLineBackward"),isExtendLineForward:He("extendLineForward"),isItalic:He("italic"),isMoveLineBackward:He("moveLineBackward"),isMoveLineForward:He("moveLineForward"),isMoveWordBackward:He("moveWordBackward"),isMoveWordForward:He("moveWordForward"),isRedo:He("redo"),isSoftBreak:He("insertSoftBreak"),isSplitBlock:He("splitBlock"),isTransposeCharacter:He("transposeCharacter"),isUndo:He("undo")},Iee=(e,t)=>{var r=[],n=()=>{r=[]},o=s=>{if(t.current){var u=s.filter(l=>U2(e,l,s));r.push(...u)}};function a(){r.length>0&&(r.reverse().forEach(s=>{s.type!=="characterData"&&(s.removedNodes.forEach(u=>{s.target.insertBefore(u,s.nextSibling)}),s.addedNodes.forEach(u=>{s.target.removeChild(u)}))}),n())}return{registerMutations:o,restoreDOM:a,clear:n}},kee={subtree:!0,childList:!0,characterData:!0,characterDataOldValue:!0},yd=class extends RQ{constructor(){super(...arguments),this.context=null,this.manager=null,this.mutationObserver=null}observe(){var t,{node:r}=this.props;if(!r.current)throw new Error("Failed to attach MutationObserver, `node` is undefined");(t=this.mutationObserver)===null||t===void 0||t.observe(r.current,kee)}componentDidMount(){var{receivedUserInput:t}=this.props,r=this.context;this.manager=Iee(r,t),this.mutationObserver=new MutationObserver(this.manager.registerMutations),this.observe()}getSnapshotBeforeUpdate(){var t,r,n,o=(t=this.mutationObserver)===null||t===void 0?void 0:t.takeRecords();if(o!=null&&o.length){var a;(a=this.manager)===null||a===void 0||a.registerMutations(o)}return(r=this.mutationObserver)===null||r===void 0||r.disconnect(),(n=this.manager)===null||n===void 0||n.restoreDOM(),null}componentDidUpdate(){var t;(t=this.manager)===null||t===void 0||t.clear(),this.observe()}componentWillUnmount(){var t;(t=this.mutationObserver)===null||t===void 0||t.disconnect()}render(){return this.props.children}};yd.contextType=H2;var Nee=Qt?yd:e=>{var{children:t}=e;return de.createElement(de.Fragment,null,t)},Vee=["autoFocus","decorate","onDOMBeforeInput","placeholder","readOnly","renderElement","renderLeaf","renderPlaceholder","scrollSelectionIntoView","style","as","disableDefaultStyles"],Lee=["text"];function hP(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function ss(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?hP(Object(r),!0).forEach(function(n){bd(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):hP(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var $ee=e=>de.createElement(de.Fragment,null,LP(e)),HP=e=>{var t=ke(A=>de.createElement(zee,Object.assign({},A)),[]),{autoFocus:r,decorate:n=Hee,onDOMBeforeInput:o,placeholder:a,readOnly:s=!1,renderElement:u,renderLeaf:l,renderPlaceholder:c=t,scrollSelectionIntoView:p=Gee,style:d={},as:h="div",disableDefaultStyles:g=!1}=e,v=ls(e,Vee),m=xd(),[b,y]=Fi(!1),x=gr(null),w=gr([]),[S,E]=Fi(),{onUserInput:D,receivedUserInput:P}=Ree(),[,R]=FQ(A=>A+1,0);PP.set(m,R),I2.set(m,s);var F=dd(()=>({isDraggingInternally:!1,isUpdatingSelection:!1,latestElement:null,hasMarkPlaceholder:!1}),[]);jn(()=>{x.current&&r&&x.current.focus()},[r]);var M=gr(),G=dd(()=>(0,wP.default)(()=>{var A=M.current;if((Qt||!$.isComposing(m))&&(!F.isUpdatingSelection||A!=null&&A.isFlushing())&&!F.isDraggingInternally){var _=$.findDocumentOrShadowRoot(m),{activeElement:z}=_,j=$.toDOMNode(m,m),ue=_.getSelection();if(z===j?(F.latestElement=z,Ti.set(m,!0)):Ti.delete(m),!ue)return k.deselect(m);var{anchorNode:oe,focusNode:he}=ue,Ce=$.hasEditableTarget(m,oe)||$.isTargetInsideNonReadonlyVoid(m,oe),Se=$.hasEditableTarget(m,he)||$.isTargetInsideNonReadonlyVoid(m,he);if(Ce&&Se){var Ee=$.toSlateRange(m,ue,{exactMatch:!1,suppressThrow:!0});Ee&&(!$.isComposing(m)&&!(A!=null&&A.hasPendingChanges())&&!(A!=null&&A.isFlushing())?k.select(m,Ee):A?.handleUserSelect(Ee))}s&&(!Ce||!Se)&&k.deselect(m)}},100),[m,s,F]),N=dd(()=>(0,xP.default)(G,0),[G]);M.current=fee({node:x,onDOMSelectionChange:G,scheduleOnDOMSelectionChange:N}),rl(()=>{var A,_,z;x.current&&(z=W2(x.current))?(EP.set(m,z),gd.set(m,x.current),Ri.set(m,x.current),tl.set(x.current,m)):Ri.delete(m);var{selection:j}=m,ue=$.findDocumentOrShadowRoot(m),oe=ue.getSelection();if(!(!oe||!$.isFocused(m)||(A=M.current)!==null&&A!==void 0&&A.hasPendingAction())){var he=xe=>{var gt=oe.type!=="None";if(!(!j&&!gt)){var vt=oe.focusNode,je;if(Qu&&oe.rangeCount>1){var or=oe.getRangeAt(0),Ht=oe.getRangeAt(oe.rangeCount-1);or.startContainer===vt?je=Ht.endContainer:je=or.startContainer}else je=oe.anchorNode;var St=gd.get(m),ir=!1;if(St.contains(je)&&St.contains(vt)&&(ir=!0),gt&&ir&&j&&!xe){var B=$.toSlateRange(m,oe,{exactMatch:!0,suppressThrow:!0});if(B&&O.equals(B,j)){var X,te;if(!F.hasMarkPlaceholder||(X=je)!==null&&X!==void 0&&(te=X.parentElement)!==null&&te!==void 0&&te.hasAttribute("data-slate-mark-placeholder"))return}}if(j&&!$.hasRange(m,j)){m.selection=$.toSlateRange(m,oe,{exactMatch:!1,suppressThrow:!0});return}F.isUpdatingSelection=!0;var q=j&&$.toDOMRange(m,j);return q?($.isComposing(m)&&!Qt?oe.collapseToEnd():O.isBackward(j)?oe.setBaseAndExtent(q.endContainer,q.endOffset,q.startContainer,q.startOffset):oe.setBaseAndExtent(q.startContainer,q.startOffset,q.endContainer,q.endOffset),p(m,q)):oe.removeAllRanges(),q}};oe.rangeCount<=1&&he();var Ce=((_=M.current)===null||_===void 0?void 0:_.isFlushing())==="action";if(!Qt||!Ce){setTimeout(()=>{F.isUpdatingSelection=!1});return}var Se=null,Ee=requestAnimationFrame(()=>{if(Ce){var xe=gt=>{try{var vt=$.toDOMNode(m,m);vt.focus(),he(gt)}catch{}};xe(),Se=setTimeout(()=>{xe(!0),F.isUpdatingSelection=!1})}});return()=>{cancelAnimationFrame(Ee),Se&&clearTimeout(Se)}}});var L=ke(A=>{if(D(),!s&&$.hasEditableTarget(m,A.target)&&!jee(A,o)){var _;if(M.current)return M.current.handleDOMBeforeInput(A);N.flush(),G.flush();var{selection:z}=m,{inputType:j}=A,ue=A.dataTransfer||A.data||void 0,oe=j==="insertCompositionText"||j==="deleteCompositionText";if(oe&&$.isComposing(m))return;var he=!1;if(j==="insertText"&&z&&O.isCollapsed(z)&&A.data&&A.data.length===1&&/[a-z ]/i.test(A.data)&&z.anchor.offset!==0){var Ce,Se;he=!0,m.marks&&(he=!1);var{anchor:Ee}=z,[xe,gt]=$.toDOMPoint(m,Ee),vt=(Ce=xe.parentElement)===null||Ce===void 0?void 0:Ce.closest("a"),je=$.getWindow(m);if(he&&vt&&$.hasDOMNode(m,vt)){var or,Ht=je?.document.createTreeWalker(vt,NodeFilter.SHOW_TEXT).lastChild();Ht===xe&&((or=Ht.textContent)===null||or===void 0?void 0:or.length)===gt&&(he=!1)}if(he&&xe.parentElement&&(je==null||(Se=je.getComputedStyle(xe.parentElement))===null||Se===void 0?void 0:Se.whiteSpace)==="pre"){var St=C.above(m,{at:Ee.path,match:se=>K.isElement(se)&&C.isBlock(m,se)});St&&W.string(St[0]).includes(" ")&&(he=!1)}}if(!j.startsWith("delete")||j.startsWith("deleteBy")){var[ir]=A.getTargetRanges();if(ir){var B=$.toSlateRange(m,ir,{exactMatch:!1,suppressThrow:!1});if(!z||!O.equals(z,B)){he=!1;var X=!oe&&m.selection&&C.rangeRef(m,m.selection);k.select(m,B),X&&el.set(m,X)}}}if(oe)return;if(he||A.preventDefault(),z&&O.isExpanded(z)&&j.startsWith("delete")){var te=j.endsWith("Backward")?"backward":"forward";C.deleteFragment(m,{direction:te});return}switch(j){case"deleteByComposition":case"deleteByCut":case"deleteByDrag":{C.deleteFragment(m);break}case"deleteContent":case"deleteContentForward":{C.deleteForward(m);break}case"deleteContentBackward":{C.deleteBackward(m);break}case"deleteEntireSoftLine":{C.deleteBackward(m,{unit:"line"}),C.deleteForward(m,{unit:"line"});break}case"deleteHardLineBackward":{C.deleteBackward(m,{unit:"block"});break}case"deleteSoftLineBackward":{C.deleteBackward(m,{unit:"line"});break}case"deleteHardLineForward":{C.deleteForward(m,{unit:"block"});break}case"deleteSoftLineForward":{C.deleteForward(m,{unit:"line"});break}case"deleteWordBackward":{C.deleteBackward(m,{unit:"word"});break}case"deleteWordForward":{C.deleteForward(m,{unit:"word"});break}case"insertLineBreak":C.insertSoftBreak(m);break;case"insertParagraph":{C.insertBreak(m);break}case"insertFromComposition":case"insertFromDrop":case"insertFromPaste":case"insertFromYank":case"insertReplacementText":case"insertText":{j==="insertFromComposition"&&$.isComposing(m)&&(y(!1),Ai.set(m,!1)),ue?.constructor.name==="DataTransfer"?$.insertData(m,ue):typeof ue=="string"&&(he?w.current.push(()=>C.insertText(m,ue)):C.insertText(m,ue));break}}var q=(_=el.get(m))===null||_===void 0?void 0:_.unref();el.delete(m),q&&(!m.selection||!O.equals(m.selection,q))&&k.select(m,q)}},[m,G,D,o,s,N]),I=ke(A=>{A==null?(G.cancel(),N.cancel(),gd.delete(m),Ri.delete(m),x.current&&Io&&x.current.removeEventListener("beforeinput",L)):Io&&A.addEventListener("beforeinput",L),x.current=A},[G,N,m,L]);rl(()=>{var A=$.getWindow(m);return A.document.addEventListener("selectionchange",N),()=>{A.document.removeEventListener("selectionchange",N)}},[N]);var V=n([m,[]]),Y=a&&m.children.length===1&&Array.from(W.texts(m)).length===1&&W.string(m)===""&&!b,Q=ke(A=>{if(A&&Y){var _;E((_=A.getBoundingClientRect())===null||_===void 0?void 0:_.height)}else E(void 0)},[Y]);if(Y){var re=C.start(m,[]);V.push({[cs]:!0,placeholder:a,onPlaceholderResize:Q,anchor:re,focus:re})}var{marks:H}=m;if(F.hasMarkPlaceholder=!1,m.selection&&O.isCollapsed(m.selection)&&H){var{anchor:le}=m.selection,ve=W.leaf(m,le.path),me=ls(ve,Lee);if(!J.equals(ve,H,{loose:!0})){F.hasMarkPlaceholder=!0;var Ge=Object.fromEntries(Object.keys(me).map(A=>[A,null]));V.push(ss(ss(ss({[TP]:!0},Ge),H),{},{anchor:le,focus:le}))}}return jn(()=>{setTimeout(()=>{var{selection:A}=m;if(A){var{anchor:_}=A,z=W.leaf(m,_.path);if(H&&!J.equals(z,H,{loose:!0})){Gr.set(m,H);return}}Gr.delete(m)})}),de.createElement($P.Provider,{value:s},de.createElement(kP.Provider,{value:n},de.createElement(Nee,{node:x,receivedUserInput:P},de.createElement(h,Object.assign({role:s?void 0:"textbox","aria-multiline":s?void 0:!0},v,{spellCheck:Io||!hd?v.spellCheck:!1,autoCorrect:Io||!hd?v.autoCorrect:"false",autoCapitalize:Io||!hd?v.autoCapitalize:"false","data-slate-editor":!0,"data-slate-node":"value",contentEditable:!s,zindex:-1,suppressContentEditableWarning:!0,ref:I,style:ss(ss({},g?{}:ss({position:"relative",whiteSpace:"pre-wrap",wordWrap:"break-word"},S?{minHeight:S}:{})),d),onBeforeInput:ke(A=>{if(!Io&&!s&&!Lt(A,v.onBeforeInput)&&$.hasSelectableTarget(m,A.target)&&(A.preventDefault(),!$.isComposing(m))){var _=A.data;C.insertText(m,_)}},[v.onBeforeInput,m,s]),onInput:ke(A=>{if(!Lt(A,v.onInput)){if(M.current){M.current.handleInput();return}for(var _ of w.current)_();w.current=[]}},[v.onInput]),onBlur:ke(A=>{if(!(s||F.isUpdatingSelection||!$.hasSelectableTarget(m,A.target)||Lt(A,v.onBlur))){var _=$.findDocumentOrShadowRoot(m);if(F.latestElement!==_.activeElement){var{relatedTarget:z}=A,j=$.toDOMNode(m,m);if(z!==j&&!(Pr(z)&&z.hasAttribute("data-slate-spacer"))){if(z!=null&&Vo(z)&&$.hasDOMNode(m,z)){var ue=$.toSlateNode(m,z);if(K.isElement(ue)&&!m.isVoid(ue))return}if(Zu){var oe=_.getSelection();oe?.removeAllRanges()}Ti.delete(m)}}}},[s,F.isUpdatingSelection,F.latestElement,m,v.onBlur]),onClick:ke(A=>{if($.hasTarget(m,A.target)&&!Lt(A,v.onClick)&&Vo(A.target)){var _=$.toSlateNode(m,A.target),z=$.findPath(m,_);if(!C.hasPath(m,z)||W.get(m,z)!==_)return;if(A.detail===Fee&&z.length>=1){var j=z;if(!(K.isElement(_)&&C.isBlock(m,_))){var ue,oe=C.above(m,{match:vt=>K.isElement(vt)&&C.isBlock(m,vt),at:z});j=(ue=oe?.[1])!==null&&ue!==void 0?ue:z.slice(0,1)}var he=C.range(m,j);k.select(m,he);return}if(s)return;var Ce=C.start(m,z),Se=C.end(m,z),Ee=C.void(m,{at:Ce}),xe=C.void(m,{at:Se});if(Ee&&xe&&T.equals(Ee[1],xe[1])){var gt=C.range(m,Ce);k.select(m,gt)}}},[m,v.onClick,s]),onCompositionEnd:ke(A=>{if($.hasSelectableTarget(m,A.target)){var _;if($.isComposing(m)&&(y(!1),Ai.set(m,!1)),(_=M.current)===null||_===void 0||_.handleCompositionEnd(A),Lt(A,v.onCompositionEnd)||Qt)return;if(!Zu&&!VQ&&!MQ&&!$Q&&!LQ&&A.data){var z=Gr.get(m);Gr.delete(m),z!==void 0&&(Gn.set(m,m.marks),m.marks=z),C.insertText(m,A.data);var j=Gn.get(m);Gn.delete(m),j!==void 0&&(m.marks=j)}}},[v.onCompositionEnd,m]),onCompositionUpdate:ke(A=>{$.hasSelectableTarget(m,A.target)&&!Lt(A,v.onCompositionUpdate)&&($.isComposing(m)||(y(!0),Ai.set(m,!0)))},[v.onCompositionUpdate,m]),onCompositionStart:ke(A=>{if($.hasSelectableTarget(m,A.target)){var _;if((_=M.current)===null||_===void 0||_.handleCompositionStart(A),Lt(A,v.onCompositionStart)||Qt)return;y(!0);var{selection:z}=m;if(z){if(O.isExpanded(z)){C.deleteFragment(m);return}var j=C.above(m,{match:he=>K.isElement(he)&&C.isInline(m,he),mode:"highest"});if(j){var[,ue]=j;if(C.isEnd(m,z.anchor,ue)){var oe=C.after(m,ue);k.setSelection(m,{anchor:oe,focus:oe})}}}}},[v.onCompositionStart,m]),onCopy:ke(A=>{$.hasSelectableTarget(m,A.target)&&!Lt(A,v.onCopy)&&!gP(A)&&(A.preventDefault(),$.setFragmentData(m,A.clipboardData,"copy"))},[v.onCopy,m]),onCut:ke(A=>{if(!s&&$.hasSelectableTarget(m,A.target)&&!Lt(A,v.onCut)&&!gP(A)){A.preventDefault(),$.setFragmentData(m,A.clipboardData,"cut");var{selection:_}=m;if(_)if(O.isExpanded(_))C.deleteFragment(m);else{var z=W.parent(m,_.anchor.path);C.isVoid(m,z)&&k.delete(m)}}},[s,m,v.onCut]),onDragOver:ke(A=>{if($.hasTarget(m,A.target)&&!Lt(A,v.onDragOver)){var _=$.toSlateNode(m,A.target);K.isElement(_)&&C.isVoid(m,_)&&A.preventDefault()}},[v.onDragOver,m]),onDragStart:ke(A=>{if(!s&&$.hasTarget(m,A.target)&&!Lt(A,v.onDragStart)){var _=$.toSlateNode(m,A.target),z=$.findPath(m,_),j=K.isElement(_)&&C.isVoid(m,_)||C.void(m,{at:z,voids:!0});if(j){var ue=C.range(m,z);k.select(m,ue)}F.isDraggingInternally=!0,$.setFragmentData(m,A.dataTransfer,"drag")}},[s,m,v.onDragStart,F]),onDrop:ke(A=>{if(!s&&$.hasTarget(m,A.target)&&!Lt(A,v.onDrop)){A.preventDefault();var _=m.selection,z=$.findEventRange(m,A),j=A.dataTransfer;k.select(m,z),F.isDraggingInternally&&_&&!O.equals(_,z)&&!C.void(m,{at:z,voids:!0})&&k.delete(m,{at:_}),$.insertData(m,j),$.isFocused(m)||$.focus(m)}F.isDraggingInternally=!1},[s,m,v.onDrop,F]),onDragEnd:ke(A=>{!s&&F.isDraggingInternally&&v.onDragEnd&&$.hasTarget(m,A.target)&&v.onDragEnd(A),F.isDraggingInternally=!1},[s,F,v,m]),onFocus:ke(A=>{if(!s&&!F.isUpdatingSelection&&$.hasEditableTarget(m,A.target)&&!Lt(A,v.onFocus)){var _=$.toDOMNode(m,m),z=$.findDocumentOrShadowRoot(m);if(F.latestElement=z.activeElement,Qu&&A.target!==_){_.focus();return}Ti.set(m,!0)}},[s,F,m,v.onFocus]),onKeyDown:ke(A=>{if(!s&&$.hasEditableTarget(m,A.target)){var _;(_=M.current)===null||_===void 0||_.handleKeyDown(A);var{nativeEvent:z}=A;if($.isComposing(m)&&z.isComposing===!1&&(Ai.set(m,!1),y(!1)),Lt(A,v.onKeyDown)||$.isComposing(m))return;var{selection:j}=m,ue=m.children[j!==null?j.focus.path[0]:0],oe=(0,z2.default)(W.string(ue))==="rtl";if(_e.isRedo(z)){A.preventDefault();var he=m;typeof he.redo=="function"&&he.redo();return}if(_e.isUndo(z)){A.preventDefault();var Ce=m;typeof Ce.undo=="function"&&Ce.undo();return}if(_e.isMoveLineBackward(z)){A.preventDefault(),k.move(m,{unit:"line",reverse:!0});return}if(_e.isMoveLineForward(z)){A.preventDefault(),k.move(m,{unit:"line"});return}if(_e.isExtendLineBackward(z)){A.preventDefault(),k.move(m,{unit:"line",edge:"focus",reverse:!0});return}if(_e.isExtendLineForward(z)){A.preventDefault(),k.move(m,{unit:"line",edge:"focus"});return}if(_e.isMoveBackward(z)){A.preventDefault(),j&&O.isCollapsed(j)?k.move(m,{reverse:!oe}):k.collapse(m,{edge:"start"});return}if(_e.isMoveForward(z)){A.preventDefault(),j&&O.isCollapsed(j)?k.move(m,{reverse:oe}):k.collapse(m,{edge:"end"});return}if(_e.isMoveWordBackward(z)){A.preventDefault(),j&&O.isExpanded(j)&&k.collapse(m,{edge:"focus"}),k.move(m,{unit:"word",reverse:!oe});return}if(_e.isMoveWordForward(z)){A.preventDefault(),j&&O.isExpanded(j)&&k.collapse(m,{edge:"focus"}),k.move(m,{unit:"word",reverse:oe});return}if(Io){if((DP||Zu)&&j&&(_e.isDeleteBackward(z)||_e.isDeleteForward(z))&&O.isCollapsed(j)){var Se=W.parent(m,j.anchor.path);if(K.isElement(Se)&&C.isVoid(m,Se)&&(C.isInline(m,Se)||C.isBlock(m,Se))){A.preventDefault(),C.deleteBackward(m,{unit:"block"});return}}}else{if(_e.isBold(z)||_e.isItalic(z)||_e.isTransposeCharacter(z)){A.preventDefault();return}if(_e.isSoftBreak(z)){A.preventDefault(),C.insertSoftBreak(m);return}if(_e.isSplitBlock(z)){A.preventDefault(),C.insertBreak(m);return}if(_e.isDeleteBackward(z)){A.preventDefault(),j&&O.isExpanded(j)?C.deleteFragment(m,{direction:"backward"}):C.deleteBackward(m);return}if(_e.isDeleteForward(z)){A.preventDefault(),j&&O.isExpanded(j)?C.deleteFragment(m,{direction:"forward"}):C.deleteForward(m);return}if(_e.isDeleteLineBackward(z)){A.preventDefault(),j&&O.isExpanded(j)?C.deleteFragment(m,{direction:"backward"}):C.deleteBackward(m,{unit:"line"});return}if(_e.isDeleteLineForward(z)){A.preventDefault(),j&&O.isExpanded(j)?C.deleteFragment(m,{direction:"forward"}):C.deleteForward(m,{unit:"line"});return}if(_e.isDeleteWordBackward(z)){A.preventDefault(),j&&O.isExpanded(j)?C.deleteFragment(m,{direction:"backward"}):C.deleteBackward(m,{unit:"word"});return}if(_e.isDeleteWordForward(z)){A.preventDefault(),j&&O.isExpanded(j)?C.deleteFragment(m,{direction:"forward"}):C.deleteForward(m,{unit:"word"});return}}}},[s,m,v.onKeyDown]),onPaste:ke(A=>{!s&&$.hasEditableTarget(m,A.target)&&!Lt(A,v.onPaste)&&(!Io||GQ(A.nativeEvent)||Zu)&&(A.preventDefault(),$.insertData(m,A.clipboardData))},[s,m,v.onPaste])}),de.createElement($ee,{decorations:V,node:m,renderElement:u,renderPlaceholder:c,renderLeaf:l,selection:m.selection})))))},zee=e=>{var{attributes:t,children:r}=e;return de.createElement("span",Object.assign({},t),r,Qt&&de.createElement("br",null))},Hee=()=>[],Gee=(e,t)=>{if(t.getBoundingClientRect&&(!e.selection||e.selection&&O.isCollapsed(e.selection))){var r=t.startContainer.parentElement;r.getBoundingClientRect=t.getBoundingClientRect.bind(t),qD(r,{scrollMode:"if-needed"}),delete r.getBoundingClientRect}},Lt=(e,t)=>{if(!t)return!1;var r=t(e);return r??(e.isDefaultPrevented()||e.isPropagationStopped())},gP=e=>Vo(e.target)&&(e.target instanceof HTMLInputElement||e.target instanceof HTMLTextAreaElement),jee=(e,t)=>{if(!t)return!1;var r=t(e);return r??e.defaultPrevented},GP=Bi(!1),jP=()=>fs(GP);var _ee=Bi({});function Wee(e){var t=gr([]).current,r=gr({editor:e}).current,n=ke(a=>{r.editor=a,t.forEach(s=>s(a))},[t,r]),o=dd(()=>({getSlate:()=>r.editor,addEventListener:a=>(t.push(a),()=>{t.splice(t.indexOf(a),1)})}),[t,r]);return{selectorContext:o,onChange:n}}var Uee=["editor","children","onChange","initialValue"],_P=e=>{var{editor:t,children:r,onChange:n,initialValue:o}=e,a=ls(e,Uee),[s,u]=de.useState(()=>{if(!W.isNodeList(o))throw new Error("[Slate] initialValue is invalid! Expected a list of elements but got: ".concat(it.stringify(o)));if(!C.isEditor(t))throw new Error("[Slate] editor is invalid! You passed: ".concat(it.stringify(t)));return t.children=o,Object.assign(t,a),{v:0,editor:t}}),{selectorContext:l,onChange:c}=Wee(t),p=ke(()=>{n&&n(t.children),u(g=>({v:g.v+1,editor:t})),c(t)},[t,c,n]);jn(()=>(k2.set(t,p),()=>{k2.set(t,()=>{})}),[t,p]);var[d,h]=Fi($.isFocused(t));return jn(()=>{h($.isFocused(t))},[t]),rl(()=>{var g=()=>h($.isFocused(t));return SP>=17?(document.addEventListener("focusin",g),document.addEventListener("focusout",g),()=>{document.removeEventListener("focusin",g),document.removeEventListener("focusout",g)}):(document.addEventListener("focus",g,!0),document.addEventListener("blur",g,!0),()=>{document.removeEventListener("focus",g,!0),document.removeEventListener("blur",g,!0)})},[]),de.createElement(_ee.Provider,{value:l},de.createElement(zP.Provider,{value:s},de.createElement(H2.Provider,{value:s.editor},de.createElement(GP.Provider,{value:d},r))))};var vP=(e,t)=>{var r=(t.top+t.bottom)/2;return e.top<=r&&e.bottom>=r},yP=(e,t,r)=>{var n=$.toDOMRange(e,t).getBoundingClientRect(),o=$.toDOMRange(e,r).getBoundingClientRect();return vP(n,o)&&vP(o,n)},Kee=(e,t)=>{var r=C.range(e,O.end(t)),n=Array.from(C.positions(e,{at:t})),o=0,a=n.length,s=Math.floor(a/2);if(yP(e,C.range(e,n[o]),r))return C.range(e,n[o],r);if(n.length<2)return C.range(e,n[n.length-1],r);for(;s!==n.length&&s!==o;)yP(e,C.range(e,n[s]),r)?a=s:o=s,s=Math.floor((o+a)/2);return C.range(e,n[a],r)};function bP(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function CP(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?bP(Object(r),!0).forEach(function(n){bd(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):bP(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var WP=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"x-slate-fragment",n=t,{apply:o,onChange:a,deleteBackward:s,addMark:u,removeMark:l}=n;return Cd.set(n,new WeakMap),n.addMark=(c,p)=>{var d,h;(d=_2.get(n))===null||d===void 0||d(),!Gr.get(n)&&(h=Zt.get(n))!==null&&h!==void 0&&h.length&&Gr.set(n,null),Gn.delete(n),u(c,p)},n.removeMark=c=>{var p;!Gr.get(n)&&(p=Zt.get(n))!==null&&p!==void 0&&p.length&&Gr.set(n,null),Gn.delete(n),l(c)},n.deleteBackward=c=>{if(c!=="line")return s(c);if(n.selection&&O.isCollapsed(n.selection)){var p=C.above(n,{match:v=>K.isElement(v)&&C.isBlock(n,v),at:n.selection});if(p){var[,d]=p,h=C.range(n,d,n.selection.anchor),g=Kee(n,h);O.isCollapsed(g)||k.delete(n,{at:g})}}},n.apply=c=>{var p=[],d=[],h=Zt.get(n);if(h!=null&&h.length){var g=h.map(I=>eee(I,c)).filter(Boolean);Zt.set(n,g)}var v=No.get(n);v&&No.set(n,cP(n,v,c));var m=ko.get(n);if(m!=null&&m.at){var b=ge.isPoint(m?.at)?$2(n,m.at,c):cP(n,m.at,c);ko.set(n,b?CP(CP({},m),{},{at:b}):null)}switch(c.type){case"insert_text":case"remove_text":case"set_node":case"split_node":{p.push(...us(n,c.path));break}case"set_selection":{var y;(y=el.get(n))===null||y===void 0||y.unref(),el.delete(n);break}case"insert_node":case"remove_node":{p.push(...us(n,T.parent(c.path)));break}case"merge_node":{var x=T.previous(c.path);p.push(...us(n,x));break}case"move_node":{var w=T.common(T.parent(c.path),T.parent(c.newPath));p.push(...us(n,w));var S;T.isBefore(c.path,c.newPath)?(p.push(...us(n,T.parent(c.path))),S=c.newPath):(p.push(...us(n,T.parent(c.newPath))),S=c.path);var E=W.get(t,T.parent(S)),D=$.findKey(n,E),P=C.pathRef(n,T.parent(S));d.push([P,D]);break}}o(c);for(var[R,F]of p){var[M]=C.node(n,R);vd.set(M,F)}for(var[G,N]of d)if(G.current){var[L]=C.node(n,G.current);vd.set(L,N)}},n.setFragmentData=c=>{var{selection:p}=n;if(p){var[d,h]=O.edges(p),g=C.void(n,{at:d.path}),v=C.void(n,{at:h.path});if(!(O.isCollapsed(p)&&!g)){var m=$.toDOMRange(n,p),b=m.cloneContents(),y=b.childNodes[0];if(b.childNodes.forEach(M=>{M.textContent&&M.textContent.trim()!==""&&(y=M)}),v){var[x]=v,w=m.cloneRange(),S=$.toDOMNode(n,x);w.setEndAfter(S),b=w.cloneContents()}if(g&&(y=b.querySelector("[data-slate-spacer]")),Array.from(b.querySelectorAll("[data-slate-zero-width]")).forEach(M=>{var G=M.getAttribute("data-slate-zero-width")==="n";M.textContent=G?`
1832
1832
  `:""}),AP(y)){var E=y.ownerDocument.createElement("span");E.style.whiteSpace="pre",E.appendChild(y),b.appendChild(E),y=E}var D=n.getFragment(),P=JSON.stringify(D),R=window.btoa(encodeURIComponent(P));y.setAttribute("data-slate-fragment",R),c.setData("application/".concat(r),R);var F=b.ownerDocument.createElement("div");return F.appendChild(b),F.setAttribute("hidden","true"),b.ownerDocument.body.appendChild(F),c.setData("text/html",F.innerHTML),c.setData("text/plain",FP(F)),b.ownerDocument.body.removeChild(F),c}}},n.insertData=c=>{n.insertFragmentData(c)||n.insertTextData(c)},n.insertFragmentData=c=>{var p=c.getData("application/".concat(r))||KQ(c);if(p){var d=decodeURIComponent(window.atob(p)),h=JSON.parse(d);return n.insertFragment(h),!0}return!1},n.insertTextData=c=>{var p=c.getData("text/plain");if(p){var d=p.split(/\r\n|\r|\n/),h=!1;for(var g of d)h&&k.splitNodes(n,{always:!0}),n.insertText(g),h=!0;return!0}return!1},n.onChange=c=>{var p=SP<18?BQ.unstable_batchedUpdates:d=>d();p(()=>{var d=k2.get(n);d&&d(),a(c)})},n},us=(e,t)=>{var r=[];for(var[n,o]of C.levels(e,{at:t})){var a=$.findKey(e,n);r.push([o,a])}return r};i();var qee={isHistory(e){return Xe(e)&&Array.isArray(e.redos)&&Array.isArray(e.undos)&&(e.redos.length===0||zn.isOperationList(e.redos[0].operations))&&(e.undos.length===0||zn.isOperationList(e.undos[0].operations))}};var K2=new WeakMap,q2=new WeakMap,ps={isHistoryEditor(e){return qee.isHistory(e.history)&&C.isEditor(e)},isMerging(e){return q2.get(e)},isSaving(e){return K2.get(e)},redo(e){e.redo()},undo(e){e.undo()},withoutMerging(e,t){var r=ps.isMerging(e);q2.set(e,!1),t(),q2.set(e,r)},withoutSaving(e,t){var r=ps.isSaving(e);K2.set(e,!1),t(),K2.set(e,r)}},UP=e=>{var t=e,{apply:r}=t;return t.history={undos:[],redos:[]},t.redo=()=>{var{history:n}=t,{redos:o}=n;if(o.length>0){var a=o[o.length-1];a.selectionBefore&&k.setSelection(t,a.selectionBefore),ps.withoutSaving(t,()=>{C.withoutNormalizing(t,()=>{for(var s of a.operations)t.apply(s)})}),n.redos.pop(),t.writeHistory("undos",a)}},t.undo=()=>{var{history:n}=t,{undos:o}=n;if(o.length>0){var a=o[o.length-1];ps.withoutSaving(t,()=>{C.withoutNormalizing(t,()=>{var s=a.operations.map(zn.inverse).reverse();for(var u of s)t.apply(u);a.selectionBefore&&k.setSelection(t,a.selectionBefore)})}),t.writeHistory("redos",a),n.undos.pop()}},t.apply=n=>{var{operations:o,history:a}=t,{undos:s}=a,u=s[s.length-1],l=u&&u.operations[u.operations.length-1],c=ps.isSaving(t),p=ps.isMerging(t);if(c==null&&(c=Yee(n)),c){if(p==null&&(u==null?p=!1:o.length!==0?p=!0:p=Xee(n,l)),u&&p)u.operations.push(n);else{var d={operations:[n],selectionBefore:t.selection};t.writeHistory("undos",d)}for(;s.length>100;)s.shift();a.redos=[]}r(n)},t.writeHistory=(n,o)=>{t.history[n].push(o)},t},Xee=(e,t)=>!!(t&&e.type==="insert_text"&&t.type==="insert_text"&&e.offset===t.offset+t.text.length&&T.equals(e.path,t.path)||t&&e.type==="remove_text"&&t.type==="remove_text"&&e.offset+e.text.length===t.offset&&T.equals(e.path,t.path)),Yee=(e,t)=>e.type!=="set_selection";var qT=U(JP()),$t=U(Z()),XT=U(up());i();i();function il(e){"@babel/helpers - typeof";return il=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},il(e)}function ete(e,t){if(il(e)!=="object"||e===null)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(il(n)!=="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function tte(e){var t=ete(e,"string");return il(t)==="symbol"?t:String(t)}function ds(e,t,r){return t=tte(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var eT=new WeakMap,tT=new WeakMap,al=class{},ms=class extends al{constructor(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};super(),ds(this,"offset",void 0),ds(this,"path",void 0);var{offset:r,path:n}=t;this.offset=r,this.path=n}},hs=class extends al{constructor(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};super(),ds(this,"offset",void 0),ds(this,"path",void 0);var{offset:r,path:n}=t;this.offset=r,this.path=n}},rte=(e,t)=>{var r=e.text.length;eT.set(e,[r,t])},nte=e=>eT.get(e),ote=(e,t)=>{var r=e.text.length;tT.set(e,[r,t])},ite=e=>tT.get(e);function ZP(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function Z2(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?ZP(Object(r),!0).forEach(function(n){ds(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):ZP(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var Sd=new WeakSet,Dd=e=>{var t=[],r=o=>{if(o!=null){var a=t[t.length-1];if(typeof o=="string"){var s={text:o};Sd.add(s),o=s}if(J.isText(o)){var u=o;J.isText(a)&&Sd.has(a)&&Sd.has(u)&&J.equals(a,u,{loose:!0})?a.text+=u.text:t.push(u)}else if(K.isElement(o))t.push(o);else if(o instanceof al){var l=t[t.length-1];J.isText(l)||(r(""),l=t[t.length-1]),o instanceof ms?rte(l,o):o instanceof hs&&ote(l,o)}else throw new Error("Unexpected hyperscript child object: ".concat(o))}};for(var n of e.flat(1/0))r(n);return t};function ate(e,t,r){return new ms(t)}function ste(e,t,r){return[new ms(t),new hs(t)]}function rT(e,t,r){return Z2(Z2({},t),{},{children:Dd(r)})}function ute(e,t,r){return new hs(t)}function lte(e,t,r){return Dd(r)}function cte(e,t,r){var n=r.find(a=>a instanceof ms),o=r.find(a=>a instanceof hs);if(!n||n.offset==null||n.path==null)throw new Error("The <selection> hyperscript tag must have an <anchor> tag as a child with `path` and `offset` attributes defined.");if(!o||o.offset==null||o.path==null)throw new Error("The <selection> hyperscript tag must have a <focus> tag as a child with `path` and `offset` attributes defined.");return Z2({anchor:{offset:n.offset,path:n.path},focus:{offset:o.offset,path:o.path}},t)}function fte(e,t,r){var n=Dd(r);if(n.length>1)throw new Error("The <text> hyperscript tag must only contain a single node's worth of children.");var[o]=n;if(o==null&&(o={text:""}),!J.isText(o))throw new Error(`
1833
1833
  The <text> hyperscript tag can only contain text content as children.`);return Sd.delete(o),Object.assign(o,t),o}var pte=e=>(t,r,n)=>{var o=[],a;for(var s of n)O.isRange(s)?a=s:o.push(s);var u=Dd(o),l={},c=e();Object.assign(c,r),c.children=u;for(var[p,d]of W.texts(c)){var h=nte(p),g=ite(p);if(h!=null){var[v]=h;l.anchor={path:d,offset:v}}if(g!=null){var[m]=g;l.focus={path:d,offset:m}}}if(l.anchor&&!l.focus)throw new Error("Slate hyperscript ranges must have both `<anchor />` and `<focus />` defined if one is defined, but you only defined `<anchor />`. For collapsed selections, use `<cursor />` instead.");if(!l.anchor&&l.focus)throw new Error("Slate hyperscript ranges must have both `<anchor />` and `<focus />` defined if one is defined, but you only defined `<focus />`. For collapsed selections, use `<cursor />` instead.");return a!=null?c.selection=a:O.isRange(l)&&(c.selection=l),c};function QP(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function ol(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?QP(Object(r),!0).forEach(function(n){ds(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):QP(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var dte={anchor:ate,cursor:ste,editor:pte(nd),element:rT,focus:ute,fragment:lte,selection:cte,text:fte},mte=function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},{elements:r={}}=t,n=gte(r),o=ol(ol(ol({},dte),n),t.creators),a=hte(o);return a},hte=e=>{var t=function(n,o){for(var a=arguments.length,s=new Array(a>2?a-2:0),u=2;u<a;u++)s[u-2]=arguments[u];var l=e[n];if(!l)throw new Error("No hyperscript creator found for tag: <".concat(n,">"));o==null&&(o={}),Xe(o)||(s=[o].concat(s),o={}),s=s.filter(p=>!!p).flat();var c=l(n,o,s);return c};return t},gte=e=>{var t={},r=function(){var a=e[n];if(typeof a!="object")throw new Error("Properties specified for a hyperscript shorthand should be an object, but for the custom element <".concat(n,"> tag you passed: ").concat(a));t[n]=(s,u,l)=>rT("element",ol(ol({},a),u),l)};for(var n in e)r();return t},gs=mte();var Fe=U(Z());i();var vte=/["'&<>]/;var Ed=e=>{let t=`${e}`,r=vte.exec(t);if(!r)return t;let n="",o="",a=0,s=0;for(a=r.index;a<t.length;a++){let u=t.charCodeAt(a);u===34?n="&quot;":u===38?n="&amp;":u===39?n="&#39;":u===60?n="&lt;":u===62?n="&gt;":n="",n!==""&&(s!==a&&(o+=t.substring(s,a)),s=a+1,o+=n)}return s!==a?o+t.substring(s,a):o};var eg={text:""},yte=e=>e.type!=="image",bte=e=>e.type==="image"&&e.url===void 0,Cte=e=>(0,Fe.isNotNil)(e.children)&&e.children.length===1,xte=e=>J.isText(e)&&e.text?.trim()==="",wte=e=>Cte(e)&&xte(e.children[0]),Ste=e=>e.every(t=>(0,Fe.isNil)(t)),Dte=e=>Ste(e)?null:e.join(""),nT=(e,t)=>{let r=e;return r.children&&(r.children=r.children.map(n=>({...nT(n,t),...t}))),r},Ete=e=>{let r=[Ed(e.text)];return(0,Fe.isNotNil)(e.bold)&&e.bold&&(r.push("</strong>"),r.unshift("<strong>")),(0,Fe.isNotNil)(e.italic)&&e.italic&&(r.push("</em>"),r.unshift("<em>")),(0,Fe.isNotNil)(e.underline)&&e.underline&&(r.push("</u>"),r.unshift("<u>")),(0,Fe.isNotNil)(e.strikethrough)&&e.strikethrough&&(r.push("</s>"),r.unshift("<s>")),(0,Fe.isNotNil)(e.code)&&e.code&&(r.push("</code>"),r.unshift("<code>")),r.join("")},oT=e=>{if(yte(e)&&wte(e)||bte(e))return null;if(J.isText(e))return Ete(e);let t=(0,Fe.isNotNil)(e.children)?e.children.map(r=>oT(r)).join(""):"";switch(e.type){case"span":return`<span>${t}</span>`;case"blockquote":return`<blockquote>${t}</blockquote>`;case"paragraph":return`<p>${t}</p>`;case"heading-one":return`<h1>${t}</h1>`;case"heading-two":return`<h2>${t}</h2>`;case"heading-three":return`<h3>${t}</h3>`;case"heading-four":return`<h4>${t}</h4>`;case"heading-five":return`<h5>${t}</h5>`;case"heading-six":return`<h6>${t}</h6>`;case"link":return`<a rel="noopener noreferrer" target="_blank" href="${Ed(e.url)}">${t}</a>`;case"numbered-list":return`<ol>${t}</ol>`;case"bulleted-list":return`<ul>${t}</ul>`;case"list-item":return`<li>${t}</li>`;case"image":return`<img src="${Ed(e.url)}" />`;case"code":return`<code>${t}</code>`;default:return t}},vs=e=>{let t=e.map(r=>oT(r));return Dte(t)},Q2={SPAN:()=>({type:"span"}),A:e=>({type:"link",url:e.getAttribute("href")}),BLOCKQUOTE:()=>({type:"blockquote"}),H1:()=>({type:"heading-one"}),H2:()=>({type:"heading-two"}),H3:()=>({type:"heading-three"}),H4:()=>({type:"heading-four"}),H5:()=>({type:"heading-five"}),H6:()=>({type:"heading-six"}),LI:()=>({type:"list-item"}),OL:()=>({type:"numbered-list"}),P:()=>({type:"paragraph"}),UL:()=>({type:"bulleted-list"}),IMG:e=>({type:"image",url:e.getAttribute("src")}),CODE:()=>({type:"code"})},iT={DEL:()=>({strikethrough:!0}),S:()=>({strikethrough:!0}),EM:()=>({italic:!0}),I:()=>({italic:!0}),STRONG:()=>({bold:!0}),U:()=>({underline:!0}),CODE:()=>({code:!0})},aT=e=>e.nodeType===3,Pte=e=>e.nodeType===1,sT=e=>e.nodeName==="CODE",uT=(e,t)=>sT(e)&&(0,Fe.isNotNil)(t[0])&&!t[0].match(/\n/g),Tte=(e,t)=>!uT(e,t)&&(0,Fe.isNotNil)(Q2[e.nodeName]),Ate=(e,t)=>uT(e,t)||(0,Fe.isNotNil)(iT[e.nodeName]),Rte=e=>(0,Fe.isNotNil)(e)&&!(0,Fe.isString)(e)&&e.text?.trim()==="",Fte=(e,t)=>{let{nodeName:r}=t;if(r!=="IMG"&&e.length===1&&!(0,Fe.isString)(e[0])&&(0,Fe.isNotNil)(e[0].text)&&e[0].text?.trim()==="")return gs("element",Q2.P(),eg);let n=Q2[r](t);return gs("element",n,e)},Bte=(e,t)=>{let{nodeName:r}=t,n=iT[r]();return e.map(o=>!(0,Fe.isString)(o)&&(0,Fe.isNotNil)(o)&&(0,Fe.isNotNil)(o.children)?nT(o,n):Rte(o)?gs("text",{},eg):gs("text",n,o))},Ote=e=>e.nodeName==="BLOCKQUOTE"||e.nodeName==="OL"||e.nodeName==="UL",Mte=(e,t)=>{let r=[];return sT(e)?r=[...e.childNodes].map(n=>aT(n)?n.textContent:n.outerHTML):Ote(e)?r=[...e.childNodes].filter(n=>n.textContent?.trim()!=="").flatMap(t):r=[...e.childNodes].flatMap(t),r},lT=e=>{if(aT(e))return e.nodeValue?.trim()===""?null:e.textContent;if(e.nodeName==="BR")return`
1834
1834
  `;if(!Pte(e))return null;let t=Mte(e,lT),r=t.length>0&&t[0]!=null?t:[eg];return e.nodeName==="BODY"?gs("fragment",{},r):Tte(e,t)?Fte(r,e):Ate(e,r)?Bte(r,e):t},Pd=e=>{if(!e)return;let t=new DOMParser().parseFromString(e,"text/html").body,r=lT(t);if((0,Fe.isNotNil)(r)&&(0,Fe.isArray)(r)&&(0,Fe.isNotNil)(r[0])&&(0,Fe.isNotNil)(r[0].text))return[{type:"paragraph",children:[{text:r[0].text}]}];let n=(0,Fe.isArray)(r)?r[r.length-1]:void 0;return(0,Fe.isArray)(r)&&K.isElement(n)&&n.type!=="paragraph"?[...r,{type:"paragraph",children:[{text:""}]}]:r};i();var bs=U(Z());import{jsx as ys}from"react/jsx-runtime";var cT=({attributes:e={"data-slate-leaf":!0},children:t,leaf:r={}})=>{let n=t;return(0,bs.isNotNil)(r.bold)&&(n=ys("strong",{children:n})),(0,bs.isNotNil)(r.italic)&&(n=ys("em",{children:n})),(0,bs.isNotNil)(r.underline)&&(n=ys("u",{children:n})),(0,bs.isNotNil)(r.strikethrough)&&(n=ys("s",{children:n})),(0,bs.isNotNil)(r.code)&&(n=ys("code",{children:n})),ys("span",{...e,children:n})};i();import ln,{css as pT}from"styled-components";import{jsx as vr,jsxs as jte}from"react/jsx-runtime";var fT=ln.span`
@@ -1870,7 +1870,7 @@ var zO=Object.create;var Nl=Object.defineProperty;var HO=Object.getOwnPropertyDe
1870
1870
  font-weight: 300;
1871
1871
  `,Gte=ln.span`
1872
1872
  font-weight: 400;
1873
- `,mT=({attributes:e={"data-slate-node":"element",ref:void 0},children:t=void 0,element:r={}})=>{let n=VP(),o=jP();switch(r.type){case"span":return vr(Gte,{...e,children:t});case"blockquote":return vr("blockquote",{...e,children:t});case"bulleted-list":return vr(Nte,{...e,children:t});case"heading-one":return vr(Vte,{...e,children:t});case"heading-two":return vr(Lte,{...e,children:t});case"heading-three":case"heading-four":case"heading-five":case"heading-six":return vr($te,{...e,children:t});case"list-item":return vr("li",{...e,children:t});case"numbered-list":return vr(kte,{...e,children:t});case"image":return jte(fT,{...e,children:[vr(fT,{contentEditable:!1,children:vr(Ite,{alt:"",contentEditable:!1,focused:o,selected:n,src:r.url})}),t]});case"link":return vr(Hte,{...e,href:r.url,rel:"noopener noreferrer",target:"_blank",children:t});case"code":return vr("code",{...e,children:t});default:return vr(zte,{...e,children:t})}};i();import Yte from"styled-components";var jT=U(Z());i();i();var Wn=U(Z());i();var Td=U(Z()),Ad=(e,t)=>{let[r]=C.nodes(e,{match:n=>K.isElement(n)&&n.type===t});return!!r},hT=new Set(["numbered-list","bulleted-list"]),$o=(e,t)=>{let r=Ad(e,t),n=hT.has(t);k.unwrapNodes(e,{match:a=>K.isElement(a)&&(0,Td.isNotNil)(a.type)&&hT.has(a.type),split:!0});let o=n?"list-item":t;if(k.setNodes(e,{type:r?"paragraph":o}),!r&&n){let a={type:t,children:[]};k.wrapNodes(e,a)}},Rd=(e,t)=>{let r=C.marks(e);return(0,Td.isNonEmptyString)(r&&Object.keys(r).find(n=>n===t))},_n=(e,t)=>{Rd(e,t)?C.removeMark(e,t):C.addMark(e,t,!0)};var gT={text:""},_te=["jpg","png","gif","tiff","bmp","dcm"],Wte=e=>{if(!no(e))return!1;let t=_te.find(r=>e.includes(r));return(0,Wn.isNotUndefined)(t)&&!!t},rg=(e,t)=>{if(!t){$o(e,"image");return}if(!Wte(t)){$o(e,"image");return}let r={type:"image",url:t,children:[gT]};k.insertNodes(e,r)},ng=e=>{let{normalizeNode:t,isVoid:r}=e;return e.isVoid=n=>n.type==="image"?!0:r(n),e.normalizeNode=([n,o])=>{if(K.isElement(n)&&n.type==="image"&&n.url!==void 0){let a={type:"paragraph",children:[gT]},s=(0,Wn.isNotUndefined)(o[0])?o[0]+1:1;k.insertNodes(e,a,{at:[s]}),k.move(e)}K.isElement(n)&&n.type==="image"&&n.url===void 0&&(0,Wn.isNotUndefined)(n.children)&&(0,Wn.isNotUndefined)(n.children[0])&&(0,Wn.isNotUndefined)(n.children[0].text)&&n.children[0].text.trim()!==""&&k.setNodes(e,{type:"span"},{match:a=>K.isElement(a)&&a.type==="image"&&a.url===void 0&&(0,Wn.isNotUndefined)(a.children)&&J.isText(a.children[0])&&(0,Wn.isNotNil)(a.children[0].text)&&a.children[0].text.trim()!=="",split:!0,at:o,mode:"highest"}),t([n,o])},e};i();var vT=U(Z());var Ute=e=>!!/^#.+$/i.test(e),yT=e=>{let[t]=C.nodes(e,{match:r=>K.isElement(r)&&r.type==="link"});return!!t},bT=e=>{k.unwrapNodes(e,{match:t=>K.isElement(t)&&t.type==="link"})},og=(e,t)=>{yT(e)&&bT(e);let{selection:r}=e,n=r&&O.isCollapsed(r),o={type:"link",url:t,children:n===!0?[{text:t}]:[]};n===!0?k.insertNodes(e,o):(k.wrapNodes(e,o,{split:!0}),k.collapse(e,{edge:"end"}))},ig=e=>{let{insertData:t,insertText:r,isInline:n,normalizeNode:o}=e;return e.isInline=a=>a.type==="link"?!0:n(a),e.insertText=a=>{a&&no(a)?og(e,a):r(a)},e.insertData=a=>{let s=a.getData("text/plain");s&&no(s)?og(e,s):t(a)},e.normalizeNode=([a,s])=>{K.isElement(a)&&a.type==="link"&&W.string(a)===""&&(k.unwrapNodes(e,{at:s}),k.select(e,T.next(s))),o([a,s])},e},ag=e=>{if(yT(e))bT(e);else{let t=prompt("Enter the URL of the link:");if(!(0,vT.isNonEmptyString)(t)){_n(e,"link");return}if(t.includes(" ")){alert("The URL provided had spaces. Try again without spaces."),_n(e,"link");return}if(!no(t)&&!Ute(t)){alert("The URL provided looks invalid. Try again. Make sure to include the protocol (ex. https://) in the URL."),_n(e,"link");return}e.selection&&og(e,t)}};i();var CT={...C,isBlck:C.isBlock},Kte={type:"paragraph",children:[{text:"",marks:[]}]},qte=e=>e.length===1?e[e.length-1]?.text?.trim()==="":e.find(r=>r.type==="link")?.children[0]?.text?.trim()==="",sg=e=>{let{selection:t}=e,r=t&&O.isCollapsed(t),n=e.children[t.anchor.path[0]],o=n.type==="bulleted-list"||n.type==="numbered-list",a=CT.above(e,{match:s=>CT.isBlck(e,s)});(r??!1)&&o&&qte(a[0].children)&&(k.removeNodes(e,{hanging:!0}),k.insertNodes(e,Kte),k.unwrapNodes(e,{match:({type:s})=>s==="bulleted-list"||s==="numbered-list",all:!0,split:!0}))};i();var ft=Object.freeze({BOLD:"BOLD",ITALIC:"ITALIC",UNDERLINE:"UNDERLINE",STRIKETHROUGH:"STRIKETHROUGH",HEADING_1:"HEADING_1",HEADING_2:"HEADING_2",BLOCKQUOTE:"BLOCKQUOTE",NUMBERED_LIST:"NUMBERED_LIST",BULLETED_LIST:"BULLETED_LIST",LINK:"LINK",IMAGE:"IMAGE"});i();i();var Fd=U(Z());i();var ug={"block-quote":"BlockQuote",bold:"Bold","bulleted-list":"BulletedList",heading:"Heading","heading-two":"HeadingTwo",image:"Image",italic:"Italic",link:"Link","numbered-list":"NumberedList",strikethrough:"Strikethrough",underline:"Underline"};var lg={};$1(lg,{BlockQuote:()=>wT,Bold:()=>DT,BulletedList:()=>PT,Heading:()=>AT,HeadingTwo:()=>FT,Image:()=>OT,Italic:()=>IT,Link:()=>NT,NumberedList:()=>LT,Strikethrough:()=>zT,Underline:()=>GT});i();i();import{jsx as xT}from"react/jsx-runtime";var wT=e=>xT("svg",{...e,children:xT("path",{d:"M4.2125 11.0375C4.35417 11.1792 4.53333 11.25 4.75 11.25H19.25C19.4667 11.25 19.6458 11.1792 19.7875 11.0375C19.9292 10.8958 20 10.7167 20 10.5C20 10.2833 19.9292 10.1042 19.7875 9.9625C19.6458 9.82083 19.4667 9.75 19.25 9.75H4.75C4.53333 9.75 4.35417 9.82083 4.2125 9.9625C4.07083 10.1042 4 10.2833 4 10.5C4 10.7167 4.07083 10.8958 4.2125 11.0375ZM4.2125 14.0375C4.35417 14.1792 4.53333 14.25 4.75 14.25H12.975C13.1917 14.25 13.3708 14.1792 13.5125 14.0375C13.6542 13.8958 13.725 13.7167 13.725 13.5C13.725 13.2833 13.6542 13.1042 13.5125 12.9625C13.3708 12.8208 13.1917 12.75 12.975 12.75H4.75C4.53333 12.75 4.35417 12.8208 4.2125 12.9625C4.07083 13.1042 4 13.2833 4 13.5C4 13.7167 4.07083 13.8958 4.2125 14.0375ZM1.5 10C1.22386 10 1 10.2239 1 10.5V14C1 14.2761 1.22386 14.5 1.5 14.5C1.77614 14.5 2 14.2761 2 14V10.5C2 10.2239 1.77614 10 1.5 10Z",fill:"currentColor"})});i();import{jsx as ST}from"react/jsx-runtime";var DT=e=>ST("svg",{...e,children:ST("path",{d:"M16.9995 11.7C18.354 10.743 19.302 9.17101 19.302 7.71451C19.302 4.48501 16.86 1.99951 13.722 1.99951H4.998V22.0005H14.823C17.7375 22.0005 19.998 19.5705 19.998 16.5855C19.998 14.415 18.798 12.5565 16.998 11.7H16.9995ZM9.186 5.57101H13.371C14.5305 5.57101 15.465 6.52801 15.465 7.71451C15.465 8.89951 14.5305 9.85651 13.3725 9.85651H9.186V5.57101ZM14.07 18.429H9.186V14.1435H14.07C15.228 14.1435 16.1625 15.1005 16.1625 16.2855C16.1625 17.4705 15.228 18.429 14.07 18.429V18.429Z",fill:"currentColor"})});i();import{jsx as ET}from"react/jsx-runtime";var PT=e=>ET("svg",{...e,children:ET("path",{d:"M4.0005 10.5C3.1695 10.5 2.5005 11.1705 2.5005 12C2.5005 12.8295 3.1695 13.5 4.0005 13.5C4.83 13.5 5.5005 12.8295 5.5005 12C5.5005 11.1705 4.83 10.5 4.0005 10.5ZM4.0005 4.5C3.1695 4.5 2.5005 5.1705 2.5005 6C2.5005 6.8295 3.1695 7.5 4.0005 7.5C4.83 7.5 5.5005 6.8295 5.5005 6C5.5005 5.1705 4.83 4.5 4.0005 4.5ZM4.0005 16.5C3.1695 16.5 2.5005 17.1795 2.5005 18C2.5005 18.8205 3.18 19.5 4.0005 19.5C4.8195 19.5 5.5005 18.8205 5.5005 18C5.5005 17.1795 4.83 16.5 4.0005 16.5ZM7.0005 19.0005H21V16.9995H7.0005V19.0005ZM7.0005 13.0005H21V10.9995H7.0005V13.0005ZM7.0005 4.9995V7.0005H21V4.9995H7.0005Z",fill:"currentColor"})});i();import{jsx as TT}from"react/jsx-runtime";var AT=e=>TT("svg",{...e,children:TT("path",{d:"M7.9995 3V6.7995H14.154V22.0005H17.8455V6.7995H24V3H7.9995ZM0 12.9H3.666V22.0005H7.335V12.9H11.001V9H0V12.9Z",fill:"currentColor"})});i();import{jsx as RT}from"react/jsx-runtime";var FT=e=>RT("svg",{...e,children:RT("path",{d:"M3 17V7H4.5V11.25H9V7H10.5V17H9V12.75H4.5V17H3ZM13.5 17V12.75C13.5 12.3333 13.6458 11.9792 13.9375 11.6875C14.2292 11.3958 14.5833 11.25 15 11.25H19.5V8.5H13.5V7H19.5C19.9167 7 20.2708 7.14583 20.5625 7.4375C20.8542 7.72917 21 8.08333 21 8.5V11.25C21 11.6667 20.8542 12.0208 20.5625 12.3125C20.2708 12.6042 19.9167 12.75 19.5 12.75H15V15.5H21V17H13.5Z",fill:"currentColor"})});i();import{jsx as BT}from"react/jsx-runtime";var OT=e=>BT("svg",{...e,children:BT("path",{d:"M21 19.0005V4.9995C21 3.9 20.1 3 19.0005 3H4.9995C3.9 3 3 3.9 3 4.9995V19.0005C3 20.1 3.9 21 4.9995 21H19.0005C20.1 21 21 20.1 21 19.0005ZM8.5005 13.5L10.9995 16.5105L14.5005 12L19.0005 18H4.9995L8.5005 13.5Z",fill:"currentColor"})});i();import{jsx as MT}from"react/jsx-runtime";var IT=e=>MT("svg",{...e,children:MT("path",{d:"M8.8335 1.99951V6.28501H12.0555L7.0695 17.715H3V22.0005H14.667V17.715H11.4435L16.431 6.28501H20.5005V1.99951H8.8335Z",fill:"currentColor"})});i();import{jsx as kT}from"react/jsx-runtime";var NT=e=>kT("svg",{...e,children:kT("path",{d:"M2.28 12C2.28 9.948 3.948 8.28 6 8.28H10.8V6H6C2.688 6 0 8.688 0 12C0 15.312 2.688 18 6 18H10.8V15.72H6C3.948 15.72 2.28 14.052 2.28 12ZM7.2 13.2H16.8V10.8H7.2V13.2ZM18 6H13.2V8.28H18C20.052 8.28 21.72 9.948 21.72 12C21.72 14.052 20.052 15.72 18 15.72H13.2V18H18C21.312 18 24 15.312 24 12C24 8.688 21.312 6 18 6Z",fill:"currentColor"})});i();import{jsx as VT}from"react/jsx-runtime";var LT=e=>VT("svg",{...e,children:VT("path",{d:"M3.425 20C3.30833 20 3.20833 19.9583 3.125 19.875C3.04167 19.7917 3 19.6917 3 19.575C3 19.4583 3.04167 19.3583 3.125 19.275C3.20833 19.1917 3.30833 19.15 3.425 19.15H5.1V18.5H4.475C4.35833 18.5 4.25833 18.4583 4.175 18.375C4.09167 18.2917 4.05 18.1917 4.05 18.075C4.05 17.9583 4.09167 17.8583 4.175 17.775C4.25833 17.6917 4.35833 17.65 4.475 17.65H5.1V17H3.425C3.30833 17 3.20833 16.9583 3.125 16.875C3.04167 16.7917 3 16.6917 3 16.575C3 16.4583 3.04167 16.3583 3.125 16.275C3.20833 16.1917 3.30833 16.15 3.425 16.15H5.525C5.64167 16.15 5.74167 16.1917 5.825 16.275C5.90833 16.3583 5.95 16.4583 5.95 16.575V19.575C5.95 19.6917 5.90833 19.7917 5.825 19.875C5.74167 19.9583 5.64167 20 5.525 20H3.425ZM4.475 7.9C4.35833 7.9 4.25833 7.85833 4.175 7.775C4.09167 7.69167 4.05 7.59167 4.05 7.475V4.85H3.425C3.30833 4.85 3.20833 4.80833 3.125 4.725C3.04167 4.64167 3 4.54167 3 4.425C3 4.30833 3.04167 4.20833 3.125 4.125C3.20833 4.04167 3.30833 4 3.425 4H4.475C4.59167 4 4.69167 4.04167 4.775 4.125C4.85833 4.20833 4.9 4.30833 4.9 4.425V7.475C4.9 7.59167 4.85833 7.69167 4.775 7.775C4.69167 7.85833 4.59167 7.9 4.475 7.9V7.9ZM3.425 13.925C3.30833 13.925 3.20833 13.8833 3.125 13.8C3.04167 13.7167 3 13.6167 3 13.5V13.275C3 13.2583 3.03333 13.1667 3.1 13L4.875 10.925H3.425C3.30833 10.925 3.20833 10.8833 3.125 10.8C3.04167 10.7167 3 10.6167 3 10.5C3 10.3833 3.04167 10.2833 3.125 10.2C3.20833 10.1167 3.30833 10.075 3.425 10.075H5.525C5.64167 10.075 5.74167 10.1167 5.825 10.2C5.90833 10.2833 5.95 10.3833 5.95 10.5V10.725C5.95 10.7417 5.91667 10.8333 5.85 11L4.05 13.075H5.525C5.64167 13.075 5.74167 13.1167 5.825 13.2C5.90833 13.2833 5.95 13.3833 5.95 13.5C5.95 13.6167 5.90833 13.7167 5.825 13.8C5.74167 13.8833 5.64167 13.925 5.525 13.925H3.425ZM8.975 18.775C8.75833 18.775 8.57917 18.7042 8.4375 18.5625C8.29583 18.4208 8.225 18.2417 8.225 18.025C8.225 17.8083 8.29583 17.6292 8.4375 17.4875C8.57917 17.3458 8.75833 17.275 8.975 17.275H20.25C20.4667 17.275 20.6458 17.3458 20.7875 17.4875C20.9292 17.6292 21 17.8083 21 18.025C21 18.2417 20.9292 18.4208 20.7875 18.5625C20.6458 18.7042 20.4667 18.775 20.25 18.775H8.975ZM8.975 12.7C8.75833 12.7 8.57917 12.6292 8.4375 12.4875C8.29583 12.3458 8.225 12.1667 8.225 11.95C8.225 11.7333 8.29583 11.5542 8.4375 11.4125C8.57917 11.2708 8.75833 11.2 8.975 11.2H20.25C20.4667 11.2 20.6458 11.2708 20.7875 11.4125C20.9292 11.5542 21 11.7333 21 11.95C21 12.1667 20.9292 12.3458 20.7875 12.4875C20.6458 12.6292 20.4667 12.7 20.25 12.7H8.975ZM8.975 6.625C8.75833 6.625 8.57917 6.55417 8.4375 6.4125C8.29583 6.27083 8.225 6.09167 8.225 5.875C8.225 5.65833 8.29583 5.47917 8.4375 5.3375C8.57917 5.19583 8.75833 5.125 8.975 5.125H20.25C20.4667 5.125 20.6458 5.19583 20.7875 5.3375C20.9292 5.47917 21 5.65833 21 5.875C21 6.09167 20.9292 6.27083 20.7875 6.4125C20.6458 6.55417 20.4667 6.625 20.25 6.625H8.975Z",fill:"currentColor"})});i();import{jsx as $T}from"react/jsx-runtime";var zT=e=>$T("svg",{...e,children:$T("path",{d:"M2 13.75V12.25H22V13.75H2ZM10.75 10.75V6.5H5V4H19V6.5H13.25V10.75H10.75ZM10.75 20V15.25H13.25V20H10.75Z",fill:"currentColor"})});i();import{jsx as HT}from"react/jsx-runtime";var GT=e=>HT("svg",{...e,children:HT("path",{d:"M5 21V19.5H19V21H5ZM12 17C10.3167 17 8.89583 16.425 7.7375 15.275C6.57917 14.125 6 12.7167 6 11.05V3H8V11.1C8 12.2 8.38333 13.125 9.15 13.875C9.91667 14.625 10.8667 15 12 15C13.1333 15 14.0833 14.625 14.85 13.875C15.6167 13.125 16 12.2 16 11.1V3H18V11.05C18 12.7167 17.4208 14.125 16.2625 15.275C15.1042 16.425 13.6833 17 12 17Z",fill:"currentColor"})});import{jsx as Xte}from"react/jsx-runtime";var Bd={sm:"12",md:"16",lg:"24",xl:"32",xxl:"48"},er=({color:e="currentColor",size:t="lg",style:r,type:n,...o})=>{if((0,Fd.isNil)(n))throw new Error("An Icon component requires a `type` prop to be provided");if((0,Fd.isNil)(ug[n]))throw new Error(`Type "${n}" does not exist, please update type prop in Icon component.`);if((0,Fd.isNil)(Bd[t]))throw new Error(`Size "${t}" does not exist, please update size prop in Icon component.`);let a=lg[ug[n]],s={verticalAlign:"middle",...r};return Xte(a,{"aria-hidden":"true",color:e,height:`${Bd[t]}px`,role:"presentation",style:s,viewBox:"0 0 24 24",width:`${Bd[t]}px`,xmlns:"http://www.w3.org/2000/svg",...o})};er.displayName="Icon_VHS";import{jsx as We,jsxs as ere}from"react/jsx-runtime";var Jte=Yte.div`
1873
+ `,mT=({attributes:e={"data-slate-node":"element",ref:void 0},children:t=void 0,element:r={}})=>{let n=VP(),o=jP();switch(r.type){case"span":return vr(Gte,{...e,children:t});case"blockquote":return vr("blockquote",{...e,children:t});case"bulleted-list":return vr(Nte,{...e,children:t});case"heading-one":return vr(Vte,{...e,children:t});case"heading-two":return vr(Lte,{...e,children:t});case"heading-three":case"heading-four":case"heading-five":case"heading-six":return vr($te,{...e,children:t});case"list-item":return vr("li",{...e,children:t});case"numbered-list":return vr(kte,{...e,children:t});case"image":return jte(fT,{...e,children:[vr(fT,{contentEditable:!1,children:vr(Ite,{alt:"",contentEditable:!1,focused:o,selected:n,src:r.url})}),t]});case"link":return vr(Hte,{...e,href:r.url,rel:"noopener noreferrer",target:"_blank",children:t});case"code":return vr("code",{...e,children:t});default:return vr(zte,{...e,children:t})}};i();import Yte from"styled-components";var jT=U(Z());i();i();var Wn=U(Z());i();var Td=U(Z()),Ad=(e,t)=>{let[r]=C.nodes(e,{match:n=>K.isElement(n)&&n.type===t});return!!r},hT=new Set(["numbered-list","bulleted-list"]),$o=(e,t)=>{let r=Ad(e,t),n=hT.has(t);k.unwrapNodes(e,{match:a=>K.isElement(a)&&(0,Td.isNotNil)(a.type)&&hT.has(a.type),split:!0});let o=n?"list-item":t;if(k.setNodes(e,{type:r?"paragraph":o}),!r&&n){let a={type:t,children:[]};k.wrapNodes(e,a)}},Rd=(e,t)=>{let r=C.marks(e);return(0,Td.isNonEmptyString)(r&&Object.keys(r).find(n=>n===t))},_n=(e,t)=>{Rd(e,t)?C.removeMark(e,t):C.addMark(e,t,!0)};var gT={text:""},_te=["jpg","png","gif","tiff","bmp","dcm"],Wte=e=>{if(!no(e))return!1;let t=_te.find(r=>e.includes(r));return(0,Wn.isNotUndefined)(t)&&!!t},rg=(e,t)=>{if(!t){$o(e,"image");return}if(!Wte(t)){$o(e,"image");return}let r={type:"image",url:t,children:[gT]};k.insertNodes(e,r)},ng=e=>{let{normalizeNode:t,isVoid:r}=e;return e.isVoid=n=>n.type==="image"?!0:r(n),e.normalizeNode=([n,o])=>{if(K.isElement(n)&&n.type==="image"&&n.url!==void 0){let a={type:"paragraph",children:[gT]},s=(0,Wn.isNotUndefined)(o[0])?o[0]+1:1;k.insertNodes(e,a,{at:[s]}),k.move(e)}K.isElement(n)&&n.type==="image"&&n.url===void 0&&(0,Wn.isNotUndefined)(n.children)&&(0,Wn.isNotUndefined)(n.children[0])&&(0,Wn.isNotUndefined)(n.children[0].text)&&n.children[0].text.trim()!==""&&k.setNodes(e,{type:"span"},{match:a=>K.isElement(a)&&a.type==="image"&&a.url===void 0&&(0,Wn.isNotUndefined)(a.children)&&J.isText(a.children[0])&&(0,Wn.isNotNil)(a.children[0].text)&&a.children[0].text.trim()!=="",split:!0,at:o,mode:"highest"}),t([n,o])},e};i();var vT=U(Z());var Ute=e=>!!/^#.+$/i.test(e),yT=e=>{let[t]=C.nodes(e,{match:r=>K.isElement(r)&&r.type==="link"});return!!t},bT=e=>{k.unwrapNodes(e,{match:t=>K.isElement(t)&&t.type==="link"})},og=(e,t)=>{yT(e)&&bT(e);let{selection:r}=e,n=r&&O.isCollapsed(r),o={type:"link",url:t,children:n===!0?[{text:t}]:[]};n===!0?k.insertNodes(e,o):(k.wrapNodes(e,o,{split:!0}),k.collapse(e,{edge:"end"}))},ig=e=>{let{insertData:t,insertText:r,isInline:n,normalizeNode:o}=e;return e.isInline=a=>a.type==="link"?!0:n(a),e.insertText=a=>{a&&no(a)?og(e,a):r(a)},e.insertData=a=>{let s=a.getData("text/plain");s&&no(s)?og(e,s):t(a)},e.normalizeNode=([a,s])=>{K.isElement(a)&&a.type==="link"&&W.string(a)===""&&(k.unwrapNodes(e,{at:s}),k.select(e,T.next(s))),o([a,s])},e},ag=e=>{if(yT(e))bT(e);else{let t=prompt("Enter the URL of the link:");if(!(0,vT.isNonEmptyString)(t)){_n(e,"link");return}if(t.includes(" ")){alert("The URL provided had spaces. Try again without spaces."),_n(e,"link");return}if(!no(t)&&!Ute(t)){alert("The URL provided looks invalid. Try again. Make sure to include the protocol (ex. https://) in the URL."),_n(e,"link");return}e.selection&&og(e,t)}};i();var CT={...C,isBlck:C.isBlock},Kte={type:"paragraph",children:[{text:"",marks:[]}]},qte=e=>e.length===1?e[e.length-1]?.text?.trim()==="":e.find(r=>r.type==="link")?.children[0]?.text?.trim()==="",sg=e=>{let{selection:t}=e,r=t&&O.isCollapsed(t),n=e.children[t.anchor.path[0]],o=n.type==="bulleted-list"||n.type==="numbered-list",a=CT.above(e,{match:s=>CT.isBlck(e,s)});(r??!1)&&o&&qte(a[0].children)&&(k.removeNodes(e,{hanging:!0}),k.insertNodes(e,Kte),k.unwrapNodes(e,{match:({type:s})=>s==="bulleted-list"||s==="numbered-list",all:!0,split:!0}))};i();var pt=Object.freeze({BOLD:"BOLD",ITALIC:"ITALIC",UNDERLINE:"UNDERLINE",STRIKETHROUGH:"STRIKETHROUGH",HEADING_1:"HEADING_1",HEADING_2:"HEADING_2",BLOCKQUOTE:"BLOCKQUOTE",NUMBERED_LIST:"NUMBERED_LIST",BULLETED_LIST:"BULLETED_LIST",LINK:"LINK",IMAGE:"IMAGE"});i();i();var Fd=U(Z());i();var ug={"block-quote":"BlockQuote",bold:"Bold","bulleted-list":"BulletedList",heading:"Heading","heading-two":"HeadingTwo",image:"Image",italic:"Italic",link:"Link","numbered-list":"NumberedList",strikethrough:"Strikethrough",underline:"Underline"};var lg={};$1(lg,{BlockQuote:()=>wT,Bold:()=>DT,BulletedList:()=>PT,Heading:()=>AT,HeadingTwo:()=>FT,Image:()=>OT,Italic:()=>IT,Link:()=>NT,NumberedList:()=>LT,Strikethrough:()=>zT,Underline:()=>GT});i();i();import{jsx as xT}from"react/jsx-runtime";var wT=e=>xT("svg",{...e,children:xT("path",{d:"M4.2125 11.0375C4.35417 11.1792 4.53333 11.25 4.75 11.25H19.25C19.4667 11.25 19.6458 11.1792 19.7875 11.0375C19.9292 10.8958 20 10.7167 20 10.5C20 10.2833 19.9292 10.1042 19.7875 9.9625C19.6458 9.82083 19.4667 9.75 19.25 9.75H4.75C4.53333 9.75 4.35417 9.82083 4.2125 9.9625C4.07083 10.1042 4 10.2833 4 10.5C4 10.7167 4.07083 10.8958 4.2125 11.0375ZM4.2125 14.0375C4.35417 14.1792 4.53333 14.25 4.75 14.25H12.975C13.1917 14.25 13.3708 14.1792 13.5125 14.0375C13.6542 13.8958 13.725 13.7167 13.725 13.5C13.725 13.2833 13.6542 13.1042 13.5125 12.9625C13.3708 12.8208 13.1917 12.75 12.975 12.75H4.75C4.53333 12.75 4.35417 12.8208 4.2125 12.9625C4.07083 13.1042 4 13.2833 4 13.5C4 13.7167 4.07083 13.8958 4.2125 14.0375ZM1.5 10C1.22386 10 1 10.2239 1 10.5V14C1 14.2761 1.22386 14.5 1.5 14.5C1.77614 14.5 2 14.2761 2 14V10.5C2 10.2239 1.77614 10 1.5 10Z",fill:"currentColor"})});i();import{jsx as ST}from"react/jsx-runtime";var DT=e=>ST("svg",{...e,children:ST("path",{d:"M16.9995 11.7C18.354 10.743 19.302 9.17101 19.302 7.71451C19.302 4.48501 16.86 1.99951 13.722 1.99951H4.998V22.0005H14.823C17.7375 22.0005 19.998 19.5705 19.998 16.5855C19.998 14.415 18.798 12.5565 16.998 11.7H16.9995ZM9.186 5.57101H13.371C14.5305 5.57101 15.465 6.52801 15.465 7.71451C15.465 8.89951 14.5305 9.85651 13.3725 9.85651H9.186V5.57101ZM14.07 18.429H9.186V14.1435H14.07C15.228 14.1435 16.1625 15.1005 16.1625 16.2855C16.1625 17.4705 15.228 18.429 14.07 18.429V18.429Z",fill:"currentColor"})});i();import{jsx as ET}from"react/jsx-runtime";var PT=e=>ET("svg",{...e,children:ET("path",{d:"M4.0005 10.5C3.1695 10.5 2.5005 11.1705 2.5005 12C2.5005 12.8295 3.1695 13.5 4.0005 13.5C4.83 13.5 5.5005 12.8295 5.5005 12C5.5005 11.1705 4.83 10.5 4.0005 10.5ZM4.0005 4.5C3.1695 4.5 2.5005 5.1705 2.5005 6C2.5005 6.8295 3.1695 7.5 4.0005 7.5C4.83 7.5 5.5005 6.8295 5.5005 6C5.5005 5.1705 4.83 4.5 4.0005 4.5ZM4.0005 16.5C3.1695 16.5 2.5005 17.1795 2.5005 18C2.5005 18.8205 3.18 19.5 4.0005 19.5C4.8195 19.5 5.5005 18.8205 5.5005 18C5.5005 17.1795 4.83 16.5 4.0005 16.5ZM7.0005 19.0005H21V16.9995H7.0005V19.0005ZM7.0005 13.0005H21V10.9995H7.0005V13.0005ZM7.0005 4.9995V7.0005H21V4.9995H7.0005Z",fill:"currentColor"})});i();import{jsx as TT}from"react/jsx-runtime";var AT=e=>TT("svg",{...e,children:TT("path",{d:"M7.9995 3V6.7995H14.154V22.0005H17.8455V6.7995H24V3H7.9995ZM0 12.9H3.666V22.0005H7.335V12.9H11.001V9H0V12.9Z",fill:"currentColor"})});i();import{jsx as RT}from"react/jsx-runtime";var FT=e=>RT("svg",{...e,children:RT("path",{d:"M3 17V7H4.5V11.25H9V7H10.5V17H9V12.75H4.5V17H3ZM13.5 17V12.75C13.5 12.3333 13.6458 11.9792 13.9375 11.6875C14.2292 11.3958 14.5833 11.25 15 11.25H19.5V8.5H13.5V7H19.5C19.9167 7 20.2708 7.14583 20.5625 7.4375C20.8542 7.72917 21 8.08333 21 8.5V11.25C21 11.6667 20.8542 12.0208 20.5625 12.3125C20.2708 12.6042 19.9167 12.75 19.5 12.75H15V15.5H21V17H13.5Z",fill:"currentColor"})});i();import{jsx as BT}from"react/jsx-runtime";var OT=e=>BT("svg",{...e,children:BT("path",{d:"M21 19.0005V4.9995C21 3.9 20.1 3 19.0005 3H4.9995C3.9 3 3 3.9 3 4.9995V19.0005C3 20.1 3.9 21 4.9995 21H19.0005C20.1 21 21 20.1 21 19.0005ZM8.5005 13.5L10.9995 16.5105L14.5005 12L19.0005 18H4.9995L8.5005 13.5Z",fill:"currentColor"})});i();import{jsx as MT}from"react/jsx-runtime";var IT=e=>MT("svg",{...e,children:MT("path",{d:"M8.8335 1.99951V6.28501H12.0555L7.0695 17.715H3V22.0005H14.667V17.715H11.4435L16.431 6.28501H20.5005V1.99951H8.8335Z",fill:"currentColor"})});i();import{jsx as kT}from"react/jsx-runtime";var NT=e=>kT("svg",{...e,children:kT("path",{d:"M2.28 12C2.28 9.948 3.948 8.28 6 8.28H10.8V6H6C2.688 6 0 8.688 0 12C0 15.312 2.688 18 6 18H10.8V15.72H6C3.948 15.72 2.28 14.052 2.28 12ZM7.2 13.2H16.8V10.8H7.2V13.2ZM18 6H13.2V8.28H18C20.052 8.28 21.72 9.948 21.72 12C21.72 14.052 20.052 15.72 18 15.72H13.2V18H18C21.312 18 24 15.312 24 12C24 8.688 21.312 6 18 6Z",fill:"currentColor"})});i();import{jsx as VT}from"react/jsx-runtime";var LT=e=>VT("svg",{...e,children:VT("path",{d:"M3.425 20C3.30833 20 3.20833 19.9583 3.125 19.875C3.04167 19.7917 3 19.6917 3 19.575C3 19.4583 3.04167 19.3583 3.125 19.275C3.20833 19.1917 3.30833 19.15 3.425 19.15H5.1V18.5H4.475C4.35833 18.5 4.25833 18.4583 4.175 18.375C4.09167 18.2917 4.05 18.1917 4.05 18.075C4.05 17.9583 4.09167 17.8583 4.175 17.775C4.25833 17.6917 4.35833 17.65 4.475 17.65H5.1V17H3.425C3.30833 17 3.20833 16.9583 3.125 16.875C3.04167 16.7917 3 16.6917 3 16.575C3 16.4583 3.04167 16.3583 3.125 16.275C3.20833 16.1917 3.30833 16.15 3.425 16.15H5.525C5.64167 16.15 5.74167 16.1917 5.825 16.275C5.90833 16.3583 5.95 16.4583 5.95 16.575V19.575C5.95 19.6917 5.90833 19.7917 5.825 19.875C5.74167 19.9583 5.64167 20 5.525 20H3.425ZM4.475 7.9C4.35833 7.9 4.25833 7.85833 4.175 7.775C4.09167 7.69167 4.05 7.59167 4.05 7.475V4.85H3.425C3.30833 4.85 3.20833 4.80833 3.125 4.725C3.04167 4.64167 3 4.54167 3 4.425C3 4.30833 3.04167 4.20833 3.125 4.125C3.20833 4.04167 3.30833 4 3.425 4H4.475C4.59167 4 4.69167 4.04167 4.775 4.125C4.85833 4.20833 4.9 4.30833 4.9 4.425V7.475C4.9 7.59167 4.85833 7.69167 4.775 7.775C4.69167 7.85833 4.59167 7.9 4.475 7.9V7.9ZM3.425 13.925C3.30833 13.925 3.20833 13.8833 3.125 13.8C3.04167 13.7167 3 13.6167 3 13.5V13.275C3 13.2583 3.03333 13.1667 3.1 13L4.875 10.925H3.425C3.30833 10.925 3.20833 10.8833 3.125 10.8C3.04167 10.7167 3 10.6167 3 10.5C3 10.3833 3.04167 10.2833 3.125 10.2C3.20833 10.1167 3.30833 10.075 3.425 10.075H5.525C5.64167 10.075 5.74167 10.1167 5.825 10.2C5.90833 10.2833 5.95 10.3833 5.95 10.5V10.725C5.95 10.7417 5.91667 10.8333 5.85 11L4.05 13.075H5.525C5.64167 13.075 5.74167 13.1167 5.825 13.2C5.90833 13.2833 5.95 13.3833 5.95 13.5C5.95 13.6167 5.90833 13.7167 5.825 13.8C5.74167 13.8833 5.64167 13.925 5.525 13.925H3.425ZM8.975 18.775C8.75833 18.775 8.57917 18.7042 8.4375 18.5625C8.29583 18.4208 8.225 18.2417 8.225 18.025C8.225 17.8083 8.29583 17.6292 8.4375 17.4875C8.57917 17.3458 8.75833 17.275 8.975 17.275H20.25C20.4667 17.275 20.6458 17.3458 20.7875 17.4875C20.9292 17.6292 21 17.8083 21 18.025C21 18.2417 20.9292 18.4208 20.7875 18.5625C20.6458 18.7042 20.4667 18.775 20.25 18.775H8.975ZM8.975 12.7C8.75833 12.7 8.57917 12.6292 8.4375 12.4875C8.29583 12.3458 8.225 12.1667 8.225 11.95C8.225 11.7333 8.29583 11.5542 8.4375 11.4125C8.57917 11.2708 8.75833 11.2 8.975 11.2H20.25C20.4667 11.2 20.6458 11.2708 20.7875 11.4125C20.9292 11.5542 21 11.7333 21 11.95C21 12.1667 20.9292 12.3458 20.7875 12.4875C20.6458 12.6292 20.4667 12.7 20.25 12.7H8.975ZM8.975 6.625C8.75833 6.625 8.57917 6.55417 8.4375 6.4125C8.29583 6.27083 8.225 6.09167 8.225 5.875C8.225 5.65833 8.29583 5.47917 8.4375 5.3375C8.57917 5.19583 8.75833 5.125 8.975 5.125H20.25C20.4667 5.125 20.6458 5.19583 20.7875 5.3375C20.9292 5.47917 21 5.65833 21 5.875C21 6.09167 20.9292 6.27083 20.7875 6.4125C20.6458 6.55417 20.4667 6.625 20.25 6.625H8.975Z",fill:"currentColor"})});i();import{jsx as $T}from"react/jsx-runtime";var zT=e=>$T("svg",{...e,children:$T("path",{d:"M2 13.75V12.25H22V13.75H2ZM10.75 10.75V6.5H5V4H19V6.5H13.25V10.75H10.75ZM10.75 20V15.25H13.25V20H10.75Z",fill:"currentColor"})});i();import{jsx as HT}from"react/jsx-runtime";var GT=e=>HT("svg",{...e,children:HT("path",{d:"M5 21V19.5H19V21H5ZM12 17C10.3167 17 8.89583 16.425 7.7375 15.275C6.57917 14.125 6 12.7167 6 11.05V3H8V11.1C8 12.2 8.38333 13.125 9.15 13.875C9.91667 14.625 10.8667 15 12 15C13.1333 15 14.0833 14.625 14.85 13.875C15.6167 13.125 16 12.2 16 11.1V3H18V11.05C18 12.7167 17.4208 14.125 16.2625 15.275C15.1042 16.425 13.6833 17 12 17Z",fill:"currentColor"})});import{jsx as Xte}from"react/jsx-runtime";var Bd={sm:"12",md:"16",lg:"24",xl:"32",xxl:"48"},er=({color:e="currentColor",size:t="lg",style:r,type:n,...o})=>{if((0,Fd.isNil)(n))throw new Error("An Icon component requires a `type` prop to be provided");if((0,Fd.isNil)(ug[n]))throw new Error(`Type "${n}" does not exist, please update type prop in Icon component.`);if((0,Fd.isNil)(Bd[t]))throw new Error(`Size "${t}" does not exist, please update size prop in Icon component.`);let a=lg[ug[n]],s={verticalAlign:"middle",...r};return Xte(a,{"aria-hidden":"true",color:e,height:`${Bd[t]}px`,role:"presentation",style:s,viewBox:"0 0 24 24",width:`${Bd[t]}px`,xmlns:"http://www.w3.org/2000/svg",...o})};er.displayName="Icon_VHS";import{jsx as We,jsxs as ere}from"react/jsx-runtime";var Jte=Yte.div`
1874
1874
  background: white;
1875
1875
  border-bottom: 1px solid ${({theme:e})=>e.color.grey400};
1876
1876
  display: flex;
@@ -1884,7 +1884,7 @@ var zO=Object.create;var Nl=Object.defineProperty;var HO=Object.getOwnPropertyDe
1884
1884
  * did not add to theme because it doesn't interact with any other components
1885
1885
  */
1886
1886
  z-index: 1;
1887
- `,jr=({format:e="",icon:t,disabled:r=!1,onCustomClick:n,buttonType:o="block"})=>{let a=xd(),s=Oe("brandBlue500"),u=o==="block"?Ad(a,e):Rd(a,e);return We(Bo,{"aria-pressed":u,colorOverride:u?s:void 0,disabled:r,icon:t,label:e,onClick:p=>{p.preventDefault(),o==="block"?$o(a,e):_n(a,e),n&&n(p)},preventTooltip:!0})},Zte=e=>{if(!e.selection)return"";let t=W.fragment(e,e.selection);return t[0]?W.string(t[0]):""},Qte=e=>Zte(e).trim()==="",_T=({enabledFormats:e=["BOLD","ITALIC","HEADING_1","LINK","BULLETED_LIST","IMAGE"],disabled:t=!1})=>{let r=xd();return ere(Jte,{children:[e.includes(ft.BOLD)&&We(jr,{buttonType:"mark",disabled:t,format:"bold",icon:We(er,{type:"bold"})}),e.includes(ft.ITALIC)&&We(jr,{buttonType:"mark",disabled:t,format:"italic",icon:We(er,{type:"italic"})}),e.includes(ft.HEADING_1)&&We(jr,{buttonType:"block",disabled:t,format:"heading-one",icon:We(er,{type:"heading"})}),e.includes(ft.HEADING_2)&&We(jr,{buttonType:"block",disabled:t,format:"heading-two",icon:We(er,{type:"heading-two"})}),e.includes(ft.BULLETED_LIST)&&We(jr,{buttonType:"block",disabled:t,format:"bulleted-list",icon:We(er,{type:"bulleted-list"})}),e.includes(ft.NUMBERED_LIST)&&We(jr,{buttonType:"block",disabled:t,format:"numbered-list",icon:We(er,{type:"numbered-list"})}),e.includes(ft.BLOCKQUOTE)&&We(jr,{buttonType:"block",disabled:t,format:"blockquote",icon:We(er,{type:"block-quote"})}),e.includes(ft.UNDERLINE)&&We(jr,{buttonType:"mark",disabled:t,format:"underline",icon:We(er,{type:"underline"})}),e.includes(ft.STRIKETHROUGH)&&We(jr,{buttonType:"mark",disabled:t,format:"strikethrough",icon:We(er,{type:"strikethrough"})}),e.includes(ft.LINK)&&We(jr,{buttonType:"mark",disabled:t||Qte(r),format:"link",icon:We(er,{type:"link"}),onCustomClick:n=>{n.preventDefault(),ag(r)}}),e.includes(ft.IMAGE)&&We(jr,{buttonType:"block",disabled:t,format:"image",icon:We(er,{type:"image"}),onCustomClick:n=>{n.preventDefault();let o=prompt("Enter the URL of the image:");(0,jT.isNonEmptyString)(o)&&rg(r,o)}})]})};import{jsx as sl,jsxs as sre}from"react/jsx-runtime";var nre=KT(HP)`
1887
+ `,jr=({format:e="",icon:t,disabled:r=!1,onCustomClick:n,buttonType:o="block"})=>{let a=xd(),s=Oe("brandBlue500"),u=o==="block"?Ad(a,e):Rd(a,e);return We(Bo,{"aria-pressed":u,colorOverride:u?s:void 0,disabled:r,icon:t,label:e,onClick:p=>{p.preventDefault(),o==="block"?$o(a,e):_n(a,e),n&&n(p)},preventTooltip:!0})},Zte=e=>{if(!e.selection)return"";let t=W.fragment(e,e.selection);return t[0]?W.string(t[0]):""},Qte=e=>Zte(e).trim()==="",_T=({enabledFormats:e=["BOLD","ITALIC","HEADING_1","LINK","BULLETED_LIST","IMAGE"],disabled:t=!1})=>{let r=xd();return ere(Jte,{children:[e.includes(pt.BOLD)&&We(jr,{buttonType:"mark",disabled:t,format:"bold",icon:We(er,{type:"bold"})}),e.includes(pt.ITALIC)&&We(jr,{buttonType:"mark",disabled:t,format:"italic",icon:We(er,{type:"italic"})}),e.includes(pt.HEADING_1)&&We(jr,{buttonType:"block",disabled:t,format:"heading-one",icon:We(er,{type:"heading"})}),e.includes(pt.HEADING_2)&&We(jr,{buttonType:"block",disabled:t,format:"heading-two",icon:We(er,{type:"heading-two"})}),e.includes(pt.BULLETED_LIST)&&We(jr,{buttonType:"block",disabled:t,format:"bulleted-list",icon:We(er,{type:"bulleted-list"})}),e.includes(pt.NUMBERED_LIST)&&We(jr,{buttonType:"block",disabled:t,format:"numbered-list",icon:We(er,{type:"numbered-list"})}),e.includes(pt.BLOCKQUOTE)&&We(jr,{buttonType:"block",disabled:t,format:"blockquote",icon:We(er,{type:"block-quote"})}),e.includes(pt.UNDERLINE)&&We(jr,{buttonType:"mark",disabled:t,format:"underline",icon:We(er,{type:"underline"})}),e.includes(pt.STRIKETHROUGH)&&We(jr,{buttonType:"mark",disabled:t,format:"strikethrough",icon:We(er,{type:"strikethrough"})}),e.includes(pt.LINK)&&We(jr,{buttonType:"mark",disabled:t||Qte(r),format:"link",icon:We(er,{type:"link"}),onCustomClick:n=>{n.preventDefault(),ag(r)}}),e.includes(pt.IMAGE)&&We(jr,{buttonType:"block",disabled:t,format:"image",icon:We(er,{type:"image"}),onCustomClick:n=>{n.preventDefault();let o=prompt("Enter the URL of the image:");(0,jT.isNonEmptyString)(o)&&rg(r,o)}})]})};import{jsx as sl,jsxs as sre}from"react/jsx-runtime";var nre=KT(HP)`
1888
1888
  color: ${({theme:e})=>e.color.grey900};
1889
1889
  outline: none; /* prevent blue accessibility outline from appearing on focus */
1890
1890
  `,ore="300px",ire=KT.div`
@@ -1901,9 +1901,9 @@ var zO=Object.create;var Nl=Object.defineProperty;var HO=Object.getOwnPropertyDe
1901
1901
  strong {
1902
1902
  font-weight: ${({theme:e})=>e.font.weight.bold};
1903
1903
  }
1904
- `,WT={"mod+b":"bold","mod+i":"italic","mod+u":"underline"},are={text:""},UT=[{type:"paragraph",children:[are]}],Od=({enabledFormats:e=Object.values(ft),value:t=UT,onChange:r,onBlur:n,placeholder:o="Enter some rich text...",disabled:a=!1,ariaLabelledBy:s,useExternalValue:u,"data-testid":l="vhs-rich-text-editor",height:c,...p})=>{let d=cg(y=>sl(mT,{...y}),[]),h=cg(y=>sl(cT,{...y}),[]),g=tre(()=>ng(ig(UP(WP(nd())))),[]),v=y=>{if((0,$t.isNil)(y)||(0,$t.isNil)(y[0])||(0,$t.isNil)(y[0].children))return!1;let{text:x}=y[0].children[0];return(0,$t.isNonEmptyString)(x)};rre(()=>{let y=(0,XT.default)(t,UT),x=vs(t),w=vs(g.children);(y||v(t)&&u&&x!==w)&&(g.children=t,g.selection=null,g.onChange())},[t,g,u]);let m=y=>{let x=g.children;(0,$t.isNotNil)(n)&&n(x)},b=cg(()=>{let{selection:y}=g;if((0,$t.isNil)(y)||(0,$t.isNil)(y.anchor.path[0]))return;let x=g.children[y.anchor.path[0]];if(K.isElement(x)&&x.type==="image"){$o(g,"image"),k.removeNodes(g,{at:y}),k.move(g,{reverse:!0});let w=g.children.filter(S=>S.type==="span")[0];K.isElement(w)&&w.type==="span"&&(0,$t.isNotNil)(w.children)&&(0,$t.isNotNil)(w.children[0])&&(0,$t.isNotNil)(w.children[0].text)&&w.children[0].text.trim()!==""&&k.setNodes(g,{type:"paragraph"},{match:S=>S.type==="span"&&(0,$t.isNotNil)(S.children)&&J.isText(S.children[0])&&(0,$t.isNotNil)(S.children[0].text)&&S.children[0].text.trim()!=="",split:!0,mode:"highest"})}},[g]);return sl(ire,{"data-testid":l,disabled:a,height:c,onClick:()=>$.focus(g),children:sre(_P,{editor:g,initialValue:t,onChange:r,...p,children:[sl(_T,{disabled:a,enabledFormats:e}),sl(nre,{"aria-labelledby":s,autoFocus:!1,"data-testid":"editor-content",onBlur:m,onKeyDown:y=>{Object.keys(WT).forEach(x=>{(0,qT.default)(x,y)&&(y.preventDefault(),_n(g,WT[x]))}),y.key==="Enter"&&!y.shiftKey&&sg(g),(y.key==="Backspace"||y.key==="Clear"||y.key==="Delete")&&b()},placeholder:o,readOnly:a,renderElement:d,renderLeaf:h,spellCheck:!0})]})})};Od.displayName="RichTextEditor_VHS";import{jsx as fg}from"react/jsx-runtime";var fre=cre.div`
1904
+ `,WT={"mod+b":"bold","mod+i":"italic","mod+u":"underline"},are={text:""},UT=[{type:"paragraph",children:[are]}],Od=({enabledFormats:e=Object.values(pt),value:t=UT,onChange:r,onBlur:n,placeholder:o="Enter some rich text...",disabled:a=!1,ariaLabelledBy:s,useExternalValue:u,"data-testid":l="vhs-rich-text-editor",height:c,...p})=>{let d=cg(y=>sl(mT,{...y}),[]),h=cg(y=>sl(cT,{...y}),[]),g=tre(()=>ng(ig(UP(WP(nd())))),[]),v=y=>{if((0,$t.isNil)(y)||(0,$t.isNil)(y[0])||(0,$t.isNil)(y[0].children))return!1;let{text:x}=y[0].children[0];return(0,$t.isNonEmptyString)(x)};rre(()=>{let y=(0,XT.default)(t,UT),x=vs(t),w=vs(g.children);(y||v(t)&&u&&x!==w)&&(g.children=t,g.selection=null,g.onChange())},[t,g,u]);let m=y=>{let x=g.children;(0,$t.isNotNil)(n)&&n(x)},b=cg(()=>{let{selection:y}=g;if((0,$t.isNil)(y)||(0,$t.isNil)(y.anchor.path[0]))return;let x=g.children[y.anchor.path[0]];if(K.isElement(x)&&x.type==="image"){$o(g,"image"),k.removeNodes(g,{at:y}),k.move(g,{reverse:!0});let w=g.children.filter(S=>S.type==="span")[0];K.isElement(w)&&w.type==="span"&&(0,$t.isNotNil)(w.children)&&(0,$t.isNotNil)(w.children[0])&&(0,$t.isNotNil)(w.children[0].text)&&w.children[0].text.trim()!==""&&k.setNodes(g,{type:"paragraph"},{match:S=>S.type==="span"&&(0,$t.isNotNil)(S.children)&&J.isText(S.children[0])&&(0,$t.isNotNil)(S.children[0].text)&&S.children[0].text.trim()!=="",split:!0,mode:"highest"})}},[g]);return sl(ire,{"data-testid":l,disabled:a,height:c,onClick:()=>$.focus(g),children:sre(_P,{editor:g,initialValue:t,onChange:r,...p,children:[sl(_T,{disabled:a,enabledFormats:e}),sl(nre,{"aria-labelledby":s,autoFocus:!1,"data-testid":"editor-content",onBlur:m,onKeyDown:y=>{Object.keys(WT).forEach(x=>{(0,qT.default)(x,y)&&(y.preventDefault(),_n(g,WT[x]))}),y.key==="Enter"&&!y.shiftKey&&sg(g),(y.key==="Backspace"||y.key==="Clear"||y.key==="Delete")&&b()},placeholder:o,readOnly:a,renderElement:d,renderLeaf:h,spellCheck:!0})]})})};Od.displayName="RichTextEditor_VHS";import{jsx as fg}from"react/jsx-runtime";var fre=cre.div`
1905
1905
  margin-top: ${({theme:e})=>e.spacing.space02};
1906
- `,Md=({field:{name:e,value:t,onChange:r},form:{errors:n},label:o,labelDescription:a,labelProps:s={},placeholder:u="",disabled:l=!1,enabledFormats:c=Object.values(ft),useExternalValue:p=!1,height:d=void 0,...h})=>{let[g,v]=ure(Pd(ur(t))),m=(0,YT.isNotUndefined)(o)?`${e}-label-id`:void 0;return lre(()=>{p&&v(Pd(ur(t)))},[p,t]),fg(Jt,{disabled:l,error:n[e],label:o,labelDescription:a,labelId:m,labelProps:s,name:e,children:fg(fre,{"data-testid":`richTextEditor-${e}`,children:fg(Od,{ariaLabelledBy:m,disabled:l,enabledFormats:c,height:d,onChange:b=>{v(b);let y=vs(b)??"";r(e)(y)},placeholder:u,useExternalValue:p,value:g,...h})})})};Md.displayName="FormConnectorRichTextEditor_VHS";import{jsx as JT}from"react/jsx-runtime";var dre=ZT.fieldset`
1906
+ `,Md=({field:{name:e,value:t,onChange:r},form:{errors:n},label:o,labelDescription:a,labelProps:s={},placeholder:u="",disabled:l=!1,enabledFormats:c=Object.values(pt),useExternalValue:p=!1,height:d=void 0,...h})=>{let[g,v]=ure(Pd(ur(t))),m=(0,YT.isNotUndefined)(o)?`${e}-label-id`:void 0;return lre(()=>{p&&v(Pd(ur(t)))},[p,t]),fg(Jt,{disabled:l,error:n[e],label:o,labelDescription:a,labelId:m,labelProps:s,name:e,children:fg(fre,{"data-testid":`richTextEditor-${e}`,children:fg(Od,{ariaLabelledBy:m,disabled:l,enabledFormats:c,height:d,onChange:b=>{v(b);let y=vs(b)??"";r(e)(y)},placeholder:u,useExternalValue:p,value:g,...h})})})};Md.displayName="FormConnectorRichTextEditor_VHS";import{jsx as JT}from"react/jsx-runtime";var dre=ZT.fieldset`
1907
1907
  border: 0;
1908
1908
  flex-grow: 1;
1909
1909
  margin: ${({theme:e})=>`0 0 ${e.spacing.space05}`};
@@ -2083,7 +2083,7 @@ var zO=Object.create;var Nl=Object.defineProperty;var HO=Object.getOwnPropertyDe
2083
2083
  which in turn throws off perfect centering */
2084
2084
  vertical-align: bottom;
2085
2085
  }
2086
- `,dA=({placement:e="left",align:t="top",gap:r="1.5rem",item:n,children:o,...a})=>Kre(pA,{...a,children:[(0,fA.isNotNil)(n)?cA(Ure,{align:t,gap:r,placement:e,children:n}):null,cA(Wre,{align:t,children:o})]});dA.displayName="MediaObject_VHS";i();import{useState as Iie}from"react";import v1,{css as kie,keyframes as pB}from"styled-components";i();import*as st from"react";i();function ye(e,t,{checkForDefaultPrevented:r=!0}={}){return function(o){if(e?.(o),r===!1||!o.defaultPrevented)return t?.(o)}}i();import*as mA from"react";function qre(e,t){typeof e=="function"?e(t):e!=null&&(e.current=t)}function Oi(...e){return t=>e.forEach(r=>qre(r,t))}function Ye(...e){return mA.useCallback(Oi(...e),e)}i();import*as Un from"react";import{jsx as Xre}from"react/jsx-runtime";function cn(e,t=[]){let r=[];function n(a,s){let u=Un.createContext(s),l=r.length;r=[...r,s];function c(d){let{scope:h,children:g,...v}=d,m=h?.[e][l]||u,b=Un.useMemo(()=>v,Object.values(v));return Xre(m.Provider,{value:b,children:g})}function p(d,h){let g=h?.[e][l]||u,v=Un.useContext(g);if(v)return v;if(s!==void 0)return s;throw new Error(`\`${d}\` must be used within \`${a}\``)}return c.displayName=a+"Provider",[c,p]}let o=()=>{let a=r.map(s=>Un.createContext(s));return function(u){let l=u?.[e]||a;return Un.useMemo(()=>({[`__scope${e}`]:{...u,[e]:l}}),[u,l])}};return o.scopeName=e,[n,Yre(o,...t)]}function Yre(...e){let t=e[0];if(e.length===1)return t;let r=()=>{let n=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(a){let s=n.reduce((u,{useScope:l,scopeName:c})=>{let d=l(a)[`__scope${c}`];return{...u,...d}},{});return Un.useMemo(()=>({[`__scope${t.scopeName}`]:s}),[s])}};return r.scopeName=t.scopeName,r}i();import*as zo from"react";i();import*as ws from"react";function at(e){let t=ws.useRef(e);return ws.useEffect(()=>{t.current=e}),ws.useMemo(()=>(...r)=>t.current?.(...r),[])}function ll({prop:e,defaultProp:t,onChange:r=()=>{}}){let[n,o]=Jre({defaultProp:t,onChange:r}),a=e!==void 0,s=a?e:n,u=at(r),l=zo.useCallback(c=>{if(a){let d=typeof c=="function"?c(e):c;d!==e&&u(d)}else o(c)},[a,e,o,u]);return[s,l]}function Jre({defaultProp:e,onChange:t}){let r=zo.useState(e),[n]=r,o=zo.useRef(n),a=at(t);return zo.useEffect(()=>{o.current!==n&&(a(n),o.current=n)},[n,o,a]),r}i();import*as hA from"react";import*as gA from"react-dom";i();import*as xt from"react";import{Fragment as Zre,jsx as gg}from"react/jsx-runtime";var Ho=xt.forwardRef((e,t)=>{let{children:r,...n}=e,o=xt.Children.toArray(r),a=o.find(ene);if(a){let s=a.props.children,u=o.map(l=>l===a?xt.Children.count(s)>1?xt.Children.only(null):xt.isValidElement(s)?s.props.children:null:l);return gg(vg,{...n,ref:t,children:xt.isValidElement(s)?xt.cloneElement(s,void 0,u):null})}return gg(vg,{...n,ref:t,children:r})});Ho.displayName="Slot";var vg=xt.forwardRef((e,t)=>{let{children:r,...n}=e;if(xt.isValidElement(r)){let o=rne(r);return xt.cloneElement(r,{...tne(n,r.props),ref:t?Oi(t,o):o})}return xt.Children.count(r)>1?xt.Children.only(null):null});vg.displayName="SlotClone";var Qre=({children:e})=>gg(Zre,{children:e});function ene(e){return xt.isValidElement(e)&&e.type===Qre}function tne(e,t){let r={...t};for(let n in t){let o=e[n],a=t[n];/^on[A-Z]/.test(n)?o&&a?r[n]=(...u)=>{a(...u),o(...u)}:o&&(r[n]=o):n==="style"?r[n]={...o,...a}:n==="className"&&(r[n]=[o,a].filter(Boolean).join(" "))}return{...e,...r}}function rne(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,r=t&&"isReactWarning"in t&&t.isReactWarning;return r?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,r=t&&"isReactWarning"in t&&t.isReactWarning,r?e.props.ref:e.props.ref||e.ref)}import{jsx as nne}from"react/jsx-runtime";var one=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"],Ue=one.reduce((e,t)=>{let r=hA.forwardRef((n,o)=>{let{asChild:a,...s}=n,u=a?Ho:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),nne(u,{...s,ref:o})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function Vd(e,t){e&&gA.flushSync(()=>e.dispatchEvent(t))}i();import*as ne from"react";i();import Mi from"react";import{jsx as yg}from"react/jsx-runtime";function Ld(e){let t=e+"CollectionProvider",[r,n]=cn(t),[o,a]=r(t,{collectionRef:{current:null},itemMap:new Map}),s=g=>{let{scope:v,children:m}=g,b=Mi.useRef(null),y=Mi.useRef(new Map).current;return yg(o,{scope:v,itemMap:y,collectionRef:b,children:m})};s.displayName=t;let u=e+"CollectionSlot",l=Mi.forwardRef((g,v)=>{let{scope:m,children:b}=g,y=a(u,m),x=Ye(v,y.collectionRef);return yg(Ho,{ref:x,children:b})});l.displayName=u;let c=e+"CollectionItemSlot",p="data-radix-collection-item",d=Mi.forwardRef((g,v)=>{let{scope:m,children:b,...y}=g,x=Mi.useRef(null),w=Ye(v,x),S=a(c,m);return Mi.useEffect(()=>(S.itemMap.set(x,{ref:x,...y}),()=>void S.itemMap.delete(x))),yg(Ho,{[p]:"",ref:w,children:b})});d.displayName=c;function h(g){let v=a(e+"CollectionConsumer",g);return Mi.useCallback(()=>{let b=v.collectionRef.current;if(!b)return[];let y=Array.from(b.querySelectorAll(`[${p}]`));return Array.from(v.itemMap.values()).sort((S,E)=>y.indexOf(S.ref.current)-y.indexOf(E.ref.current))},[v.collectionRef,v.itemMap])}return[{Provider:s,Slot:l,ItemSlot:d},h,n]}i();import*as $d from"react";import{jsx as Bot}from"react/jsx-runtime";var ine=$d.createContext(void 0);function zd(e){let t=$d.useContext(ine);return e||t||"ltr"}i();import*as Ke from"react";i();import*as vA from"react";function yA(e,t=globalThis?.document){let r=at(e);vA.useEffect(()=>{let n=o=>{o.key==="Escape"&&r(o)};return t.addEventListener("keydown",n,{capture:!0}),()=>t.removeEventListener("keydown",n,{capture:!0})},[r,t])}import{jsx as xA}from"react/jsx-runtime";var ane="DismissableLayer",bg="dismissableLayer.update",sne="dismissableLayer.pointerDownOutside",une="dismissableLayer.focusOutside",bA,wA=Ke.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),Cg=Ke.forwardRef((e,t)=>{let{disableOutsidePointerEvents:r=!1,onEscapeKeyDown:n,onPointerDownOutside:o,onFocusOutside:a,onInteractOutside:s,onDismiss:u,...l}=e,c=Ke.useContext(wA),[p,d]=Ke.useState(null),h=p?.ownerDocument??globalThis?.document,[,g]=Ke.useState({}),v=Ye(t,P=>d(P)),m=Array.from(c.layers),[b]=[...c.layersWithOutsidePointerEventsDisabled].slice(-1),y=m.indexOf(b),x=p?m.indexOf(p):-1,w=c.layersWithOutsidePointerEventsDisabled.size>0,S=x>=y,E=fne(P=>{let R=P.target,F=[...c.branches].some(M=>M.contains(R));!S||F||(o?.(P),s?.(P),P.defaultPrevented||u?.())},h),D=pne(P=>{let R=P.target;[...c.branches].some(M=>M.contains(R))||(a?.(P),s?.(P),P.defaultPrevented||u?.())},h);return yA(P=>{x===c.layers.size-1&&(n?.(P),!P.defaultPrevented&&u&&(P.preventDefault(),u()))},h),Ke.useEffect(()=>{if(p)return r&&(c.layersWithOutsidePointerEventsDisabled.size===0&&(bA=h.body.style.pointerEvents,h.body.style.pointerEvents="none"),c.layersWithOutsidePointerEventsDisabled.add(p)),c.layers.add(p),CA(),()=>{r&&c.layersWithOutsidePointerEventsDisabled.size===1&&(h.body.style.pointerEvents=bA)}},[p,h,r,c]),Ke.useEffect(()=>()=>{p&&(c.layers.delete(p),c.layersWithOutsidePointerEventsDisabled.delete(p),CA())},[p,c]),Ke.useEffect(()=>{let P=()=>g({});return document.addEventListener(bg,P),()=>document.removeEventListener(bg,P)},[]),xA(Ue.div,{...l,ref:v,style:{pointerEvents:w?S?"auto":"none":void 0,...e.style},onFocusCapture:ye(e.onFocusCapture,D.onFocusCapture),onBlurCapture:ye(e.onBlurCapture,D.onBlurCapture),onPointerDownCapture:ye(e.onPointerDownCapture,E.onPointerDownCapture)})});Cg.displayName=ane;var lne="DismissableLayerBranch",cne=Ke.forwardRef((e,t)=>{let r=Ke.useContext(wA),n=Ke.useRef(null),o=Ye(t,n);return Ke.useEffect(()=>{let a=n.current;if(a)return r.branches.add(a),()=>{r.branches.delete(a)}},[r.branches]),xA(Ue.div,{...e,ref:o})});cne.displayName=lne;function fne(e,t=globalThis?.document){let r=at(e),n=Ke.useRef(!1),o=Ke.useRef(()=>{});return Ke.useEffect(()=>{let a=u=>{if(u.target&&!n.current){let c=function(){SA(sne,r,p,{discrete:!0})};var l=c;let p={originalEvent:u};u.pointerType==="touch"?(t.removeEventListener("click",o.current),o.current=c,t.addEventListener("click",o.current,{once:!0})):c()}else t.removeEventListener("click",o.current);n.current=!1},s=window.setTimeout(()=>{t.addEventListener("pointerdown",a)},0);return()=>{window.clearTimeout(s),t.removeEventListener("pointerdown",a),t.removeEventListener("click",o.current)}},[t,r]),{onPointerDownCapture:()=>n.current=!0}}function pne(e,t=globalThis?.document){let r=at(e),n=Ke.useRef(!1);return Ke.useEffect(()=>{let o=a=>{a.target&&!n.current&&SA(une,r,{originalEvent:a},{discrete:!1})};return t.addEventListener("focusin",o),()=>t.removeEventListener("focusin",o)},[t,r]),{onFocusCapture:()=>n.current=!0,onBlurCapture:()=>n.current=!1}}function CA(){let e=new CustomEvent(bg);document.dispatchEvent(e)}function SA(e,t,r,{discrete:n}){let o=r.originalEvent.target,a=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:r});t&&o.addEventListener(e,t,{once:!0}),n?Vd(o,a):o.dispatchEvent(a)}i();import*as EA from"react";var xg=0;function PA(){EA.useEffect(()=>{let e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??DA()),document.body.insertAdjacentElement("beforeend",e[1]??DA()),xg++,()=>{xg===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),xg--}},[])}function DA(){let e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.cssText="outline: none; opacity: 0; position: fixed; pointer-events: none",e}i();import*as Tr from"react";import{jsx as dne}from"react/jsx-runtime";var wg="focusScope.autoFocusOnMount",Sg="focusScope.autoFocusOnUnmount",TA={bubbles:!1,cancelable:!0},mne="FocusScope",Dg=Tr.forwardRef((e,t)=>{let{loop:r=!1,trapped:n=!1,onMountAutoFocus:o,onUnmountAutoFocus:a,...s}=e,[u,l]=Tr.useState(null),c=at(o),p=at(a),d=Tr.useRef(null),h=Ye(t,m=>l(m)),g=Tr.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;Tr.useEffect(()=>{if(n){let x=function(D){if(g.paused||!u)return;let P=D.target;u.contains(P)?d.current=P:Go(d.current,{select:!0})},w=function(D){if(g.paused||!u)return;let P=D.relatedTarget;P!==null&&(u.contains(P)||Go(d.current,{select:!0}))},S=function(D){if(document.activeElement===document.body)for(let R of D)R.removedNodes.length>0&&Go(u)};var m=x,b=w,y=S;document.addEventListener("focusin",x),document.addEventListener("focusout",w);let E=new MutationObserver(S);return u&&E.observe(u,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",x),document.removeEventListener("focusout",w),E.disconnect()}}},[n,u,g.paused]),Tr.useEffect(()=>{if(u){RA.add(g);let m=document.activeElement;if(!u.contains(m)){let y=new CustomEvent(wg,TA);u.addEventListener(wg,c),u.dispatchEvent(y),y.defaultPrevented||(hne(Cne(BA(u)),{select:!0}),document.activeElement===m&&Go(u))}return()=>{u.removeEventListener(wg,c),setTimeout(()=>{let y=new CustomEvent(Sg,TA);u.addEventListener(Sg,p),u.dispatchEvent(y),y.defaultPrevented||Go(m??document.body,{select:!0}),u.removeEventListener(Sg,p),RA.remove(g)},0)}}},[u,c,p,g]);let v=Tr.useCallback(m=>{if(!r&&!n||g.paused)return;let b=m.key==="Tab"&&!m.altKey&&!m.ctrlKey&&!m.metaKey,y=document.activeElement;if(b&&y){let x=m.currentTarget,[w,S]=gne(x);w&&S?!m.shiftKey&&y===S?(m.preventDefault(),r&&Go(w,{select:!0})):m.shiftKey&&y===w&&(m.preventDefault(),r&&Go(S,{select:!0})):y===x&&m.preventDefault()}},[r,n,g.paused]);return dne(Ue.div,{tabIndex:-1,...s,ref:h,onKeyDown:v})});Dg.displayName=mne;function hne(e,{select:t=!1}={}){let r=document.activeElement;for(let n of e)if(Go(n,{select:t}),document.activeElement!==r)return}function gne(e){let t=BA(e),r=AA(t,e),n=AA(t.reverse(),e);return[r,n]}function BA(e){let t=[],r=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:n=>{let o=n.tagName==="INPUT"&&n.type==="hidden";return n.disabled||n.hidden||o?NodeFilter.FILTER_SKIP:n.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;r.nextNode();)t.push(r.currentNode);return t}function AA(e,t){for(let r of e)if(!vne(r,{upTo:t}))return r}function vne(e,{upTo:t}){if(getComputedStyle(e).visibility==="hidden")return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display==="none")return!0;e=e.parentElement}return!1}function yne(e){return e instanceof HTMLInputElement&&"select"in e}function Go(e,{select:t=!1}={}){if(e&&e.focus){let r=document.activeElement;e.focus({preventScroll:!0}),e!==r&&yne(e)&&t&&e.select()}}var RA=bne();function bne(){let e=[];return{add(t){let r=e[0];t!==r&&r?.pause(),e=FA(e,t),e.unshift(t)},remove(t){e=FA(e,t),e[0]?.resume()}}}function FA(e,t){let r=[...e],n=r.indexOf(t);return n!==-1&&r.splice(n,1),r}function Cne(e){return e.filter(t=>t.tagName!=="A")}i();import*as Hd from"react";i();import*as OA from"react";var Ar=globalThis?.document?OA.useLayoutEffect:()=>{};var xne=Hd.useId||(()=>{}),wne=0;function jo(e){let[t,r]=Hd.useState(xne());return Ar(()=>{e||r(n=>n??String(wne++))},[e]),e||(t?`radix-${t}`:"")}i();import*as yr from"react";i();i();i();i();var MA=["top","right","bottom","left"];var Rr=Math.min,zt=Math.max,fl=Math.round,pl=Math.floor,Kn=e=>({x:e,y:e}),Sne={left:"right",right:"left",bottom:"top",top:"bottom"},Dne={start:"end",end:"start"};function jd(e,t,r){return zt(e,Rr(t,r))}function fn(e,t){return typeof e=="function"?e(t):e}function pn(e){return e.split("-")[0]}function Ii(e){return e.split("-")[1]}function _d(e){return e==="x"?"y":"x"}function Wd(e){return e==="y"?"height":"width"}function qn(e){return["top","bottom"].includes(pn(e))?"y":"x"}function Ud(e){return _d(qn(e))}function IA(e,t,r){r===void 0&&(r=!1);let n=Ii(e),o=Ud(e),a=Wd(o),s=o==="x"?n===(r?"end":"start")?"right":"left":n==="start"?"bottom":"top";return t.reference[a]>t.floating[a]&&(s=cl(s)),[s,cl(s)]}function kA(e){let t=cl(e);return[Gd(e),t,Gd(t)]}function Gd(e){return e.replace(/start|end/g,t=>Dne[t])}function Ene(e,t,r){let n=["left","right"],o=["right","left"],a=["top","bottom"],s=["bottom","top"];switch(e){case"top":case"bottom":return r?t?o:n:t?n:o;case"left":case"right":return t?a:s;default:return[]}}function NA(e,t,r,n){let o=Ii(e),a=Ene(pn(e),r==="start",n);return o&&(a=a.map(s=>s+"-"+o),t&&(a=a.concat(a.map(Gd)))),a}function cl(e){return e.replace(/left|right|bottom|top/g,t=>Sne[t])}function Pne(e){return{top:0,right:0,bottom:0,left:0,...e}}function Eg(e){return typeof e!="number"?Pne(e):{top:e,right:e,bottom:e,left:e}}function ki(e){let{x:t,y:r,width:n,height:o}=e;return{width:n,height:o,top:r,left:t,right:t+n,bottom:r+o,x:t,y:r}}function VA(e,t,r){let{reference:n,floating:o}=e,a=qn(t),s=Ud(t),u=Wd(s),l=pn(t),c=a==="y",p=n.x+n.width/2-o.width/2,d=n.y+n.height/2-o.height/2,h=n[u]/2-o[u]/2,g;switch(l){case"top":g={x:p,y:n.y-o.height};break;case"bottom":g={x:p,y:n.y+n.height};break;case"right":g={x:n.x+n.width,y:d};break;case"left":g={x:n.x-o.width,y:d};break;default:g={x:n.x,y:n.y}}switch(Ii(t)){case"start":g[s]-=h*(r&&c?-1:1);break;case"end":g[s]+=h*(r&&c?-1:1);break}return g}var zA=async(e,t,r)=>{let{placement:n="bottom",strategy:o="absolute",middleware:a=[],platform:s}=r,u=a.filter(Boolean),l=await(s.isRTL==null?void 0:s.isRTL(t)),c=await s.getElementRects({reference:e,floating:t,strategy:o}),{x:p,y:d}=VA(c,n,l),h=n,g={},v=0;for(let m=0;m<u.length;m++){let{name:b,fn:y}=u[m],{x,y:w,data:S,reset:E}=await y({x:p,y:d,initialPlacement:n,placement:h,strategy:o,middlewareData:g,rects:c,platform:s,elements:{reference:e,floating:t}});p=x??p,d=w??d,g={...g,[b]:{...g[b],...S}},E&&v<=50&&(v++,typeof E=="object"&&(E.placement&&(h=E.placement),E.rects&&(c=E.rects===!0?await s.getElementRects({reference:e,floating:t,strategy:o}):E.rects),{x:p,y:d}=VA(c,h,l)),m=-1)}return{x:p,y:d,placement:h,strategy:o,middlewareData:g}};async function Ss(e,t){var r;t===void 0&&(t={});let{x:n,y:o,platform:a,rects:s,elements:u,strategy:l}=e,{boundary:c="clippingAncestors",rootBoundary:p="viewport",elementContext:d="floating",altBoundary:h=!1,padding:g=0}=fn(t,e),v=Eg(g),b=u[h?d==="floating"?"reference":"floating":d],y=ki(await a.getClippingRect({element:(r=await(a.isElement==null?void 0:a.isElement(b)))==null||r?b:b.contextElement||await(a.getDocumentElement==null?void 0:a.getDocumentElement(u.floating)),boundary:c,rootBoundary:p,strategy:l})),x=d==="floating"?{x:n,y:o,width:s.floating.width,height:s.floating.height}:s.reference,w=await(a.getOffsetParent==null?void 0:a.getOffsetParent(u.floating)),S=await(a.isElement==null?void 0:a.isElement(w))?await(a.getScale==null?void 0:a.getScale(w))||{x:1,y:1}:{x:1,y:1},E=ki(a.convertOffsetParentRelativeRectToViewportRelativeRect?await a.convertOffsetParentRelativeRectToViewportRelativeRect({elements:u,rect:x,offsetParent:w,strategy:l}):x);return{top:(y.top-E.top+v.top)/S.y,bottom:(E.bottom-y.bottom+v.bottom)/S.y,left:(y.left-E.left+v.left)/S.x,right:(E.right-y.right+v.right)/S.x}}var HA=e=>({name:"arrow",options:e,async fn(t){let{x:r,y:n,placement:o,rects:a,platform:s,elements:u,middlewareData:l}=t,{element:c,padding:p=0}=fn(e,t)||{};if(c==null)return{};let d=Eg(p),h={x:r,y:n},g=Ud(o),v=Wd(g),m=await s.getDimensions(c),b=g==="y",y=b?"top":"left",x=b?"bottom":"right",w=b?"clientHeight":"clientWidth",S=a.reference[v]+a.reference[g]-h[g]-a.floating[v],E=h[g]-a.reference[g],D=await(s.getOffsetParent==null?void 0:s.getOffsetParent(c)),P=D?D[w]:0;(!P||!await(s.isElement==null?void 0:s.isElement(D)))&&(P=u.floating[w]||a.floating[v]);let R=S/2-E/2,F=P/2-m[v]/2-1,M=Rr(d[y],F),G=Rr(d[x],F),N=M,L=P-m[v]-G,I=P/2-m[v]/2+R,V=jd(N,I,L),Y=!l.arrow&&Ii(o)!=null&&I!==V&&a.reference[v]/2-(I<N?M:G)-m[v]/2<0,Q=Y?I<N?I-N:I-L:0;return{[g]:h[g]+Q,data:{[g]:V,centerOffset:I-V-Q,...Y&&{alignmentOffset:Q}},reset:Y}}});var GA=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var r,n;let{placement:o,middlewareData:a,rects:s,initialPlacement:u,platform:l,elements:c}=t,{mainAxis:p=!0,crossAxis:d=!0,fallbackPlacements:h,fallbackStrategy:g="bestFit",fallbackAxisSideDirection:v="none",flipAlignment:m=!0,...b}=fn(e,t);if((r=a.arrow)!=null&&r.alignmentOffset)return{};let y=pn(o),x=qn(u),w=pn(u)===u,S=await(l.isRTL==null?void 0:l.isRTL(c.floating)),E=h||(w||!m?[cl(u)]:kA(u)),D=v!=="none";!h&&D&&E.push(...NA(u,m,v,S));let P=[u,...E],R=await Ss(t,b),F=[],M=((n=a.flip)==null?void 0:n.overflows)||[];if(p&&F.push(R[y]),d){let I=IA(o,s,S);F.push(R[I[0]],R[I[1]])}if(M=[...M,{placement:o,overflows:F}],!F.every(I=>I<=0)){var G,N;let I=(((G=a.flip)==null?void 0:G.index)||0)+1,V=P[I];if(V)return{data:{index:I,overflows:M},reset:{placement:V}};let Y=(N=M.filter(Q=>Q.overflows[0]<=0).sort((Q,re)=>Q.overflows[1]-re.overflows[1])[0])==null?void 0:N.placement;if(!Y)switch(g){case"bestFit":{var L;let Q=(L=M.filter(re=>{if(D){let H=qn(re.placement);return H===x||H==="y"}return!0}).map(re=>[re.placement,re.overflows.filter(H=>H>0).reduce((H,le)=>H+le,0)]).sort((re,H)=>re[1]-H[1])[0])==null?void 0:L[0];Q&&(Y=Q);break}case"initialPlacement":Y=u;break}if(o!==Y)return{reset:{placement:Y}}}return{}}}};function LA(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function $A(e){return MA.some(t=>e[t]>=0)}var jA=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){let{rects:r}=t,{strategy:n="referenceHidden",...o}=fn(e,t);switch(n){case"referenceHidden":{let a=await Ss(t,{...o,elementContext:"reference"}),s=LA(a,r.reference);return{data:{referenceHiddenOffsets:s,referenceHidden:$A(s)}}}case"escaped":{let a=await Ss(t,{...o,altBoundary:!0}),s=LA(a,r.floating);return{data:{escapedOffsets:s,escaped:$A(s)}}}default:return{}}}}};async function Tne(e,t){let{placement:r,platform:n,elements:o}=e,a=await(n.isRTL==null?void 0:n.isRTL(o.floating)),s=pn(r),u=Ii(r),l=qn(r)==="y",c=["left","top"].includes(s)?-1:1,p=a&&l?-1:1,d=fn(t,e),{mainAxis:h,crossAxis:g,alignmentAxis:v}=typeof d=="number"?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:0,crossAxis:0,alignmentAxis:null,...d};return u&&typeof v=="number"&&(g=u==="end"?v*-1:v),l?{x:g*p,y:h*c}:{x:h*c,y:g*p}}var _A=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var r,n;let{x:o,y:a,placement:s,middlewareData:u}=t,l=await Tne(t,e);return s===((r=u.offset)==null?void 0:r.placement)&&(n=u.arrow)!=null&&n.alignmentOffset?{}:{x:o+l.x,y:a+l.y,data:{...l,placement:s}}}}},WA=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){let{x:r,y:n,placement:o}=t,{mainAxis:a=!0,crossAxis:s=!1,limiter:u={fn:b=>{let{x:y,y:x}=b;return{x:y,y:x}}},...l}=fn(e,t),c={x:r,y:n},p=await Ss(t,l),d=qn(pn(o)),h=_d(d),g=c[h],v=c[d];if(a){let b=h==="y"?"top":"left",y=h==="y"?"bottom":"right",x=g+p[b],w=g-p[y];g=jd(x,g,w)}if(s){let b=d==="y"?"top":"left",y=d==="y"?"bottom":"right",x=v+p[b],w=v-p[y];v=jd(x,v,w)}let m=u.fn({...t,[h]:g,[d]:v});return{...m,data:{x:m.x-r,y:m.y-n}}}}},UA=function(e){return e===void 0&&(e={}),{options:e,fn(t){let{x:r,y:n,placement:o,rects:a,middlewareData:s}=t,{offset:u=0,mainAxis:l=!0,crossAxis:c=!0}=fn(e,t),p={x:r,y:n},d=qn(o),h=_d(d),g=p[h],v=p[d],m=fn(u,t),b=typeof m=="number"?{mainAxis:m,crossAxis:0}:{mainAxis:0,crossAxis:0,...m};if(l){let w=h==="y"?"height":"width",S=a.reference[h]-a.floating[w]+b.mainAxis,E=a.reference[h]+a.reference[w]-b.mainAxis;g<S?g=S:g>E&&(g=E)}if(c){var y,x;let w=h==="y"?"width":"height",S=["top","left"].includes(pn(o)),E=a.reference[d]-a.floating[w]+(S&&((y=s.offset)==null?void 0:y[d])||0)+(S?0:b.crossAxis),D=a.reference[d]+a.reference[w]+(S?0:((x=s.offset)==null?void 0:x[d])||0)-(S?b.crossAxis:0);v<E?v=E:v>D&&(v=D)}return{[h]:g,[d]:v}}}},KA=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){let{placement:r,rects:n,platform:o,elements:a}=t,{apply:s=()=>{},...u}=fn(e,t),l=await Ss(t,u),c=pn(r),p=Ii(r),d=qn(r)==="y",{width:h,height:g}=n.floating,v,m;c==="top"||c==="bottom"?(v=c,m=p===(await(o.isRTL==null?void 0:o.isRTL(a.floating))?"start":"end")?"left":"right"):(m=c,v=p==="end"?"top":"bottom");let b=g-l.top-l.bottom,y=h-l.left-l.right,x=Rr(g-l[v],b),w=Rr(h-l[m],y),S=!t.middlewareData.shift,E=x,D=w;if(d?D=p||S?Rr(w,y):y:E=p||S?Rr(x,b):b,S&&!p){let R=zt(l.left,0),F=zt(l.right,0),M=zt(l.top,0),G=zt(l.bottom,0);d?D=h-2*(R!==0||F!==0?R+F:zt(l.left,l.right)):E=g-2*(M!==0||G!==0?M+G:zt(l.top,l.bottom))}await s({...t,availableWidth:D,availableHeight:E});let P=await o.getDimensions(a.floating);return h!==P.width||g!==P.height?{reset:{rects:!0}}:{}}}};i();function Vi(e){return XA(e)?(e.nodeName||"").toLowerCase():"#document"}function tr(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function dn(e){var t;return(t=(XA(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function XA(e){return e instanceof Node||e instanceof tr(e).Node}function Fr(e){return e instanceof Element||e instanceof tr(e).Element}function _r(e){return e instanceof HTMLElement||e instanceof tr(e).HTMLElement}function qA(e){return typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof tr(e).ShadowRoot}function Ds(e){let{overflow:t,overflowX:r,overflowY:n,display:o}=Br(e);return/auto|scroll|overlay|hidden|clip/.test(t+n+r)&&!["inline","contents"].includes(o)}function YA(e){return["table","td","th"].includes(Vi(e))}function dl(e){return[":popover-open",":modal"].some(t=>{try{return e.matches(t)}catch{return!1}})}function Kd(e){let t=qd(),r=Fr(e)?Br(e):e;return r.transform!=="none"||r.perspective!=="none"||(r.containerType?r.containerType!=="normal":!1)||!t&&(r.backdropFilter?r.backdropFilter!=="none":!1)||!t&&(r.filter?r.filter!=="none":!1)||["transform","perspective","filter"].some(n=>(r.willChange||"").includes(n))||["paint","layout","strict","content"].some(n=>(r.contain||"").includes(n))}function JA(e){let t=Xn(e);for(;_r(t)&&!Li(t);){if(Kd(t))return t;if(dl(t))return null;t=Xn(t)}return null}function qd(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function Li(e){return["html","body","#document"].includes(Vi(e))}function Br(e){return tr(e).getComputedStyle(e)}function ml(e){return Fr(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Xn(e){if(Vi(e)==="html")return e;let t=e.assignedSlot||e.parentNode||qA(e)&&e.host||dn(e);return qA(t)?t.host:t}function ZA(e){let t=Xn(e);return Li(t)?e.ownerDocument?e.ownerDocument.body:e.body:_r(t)&&Ds(t)?t:ZA(t)}function Ni(e,t,r){var n;t===void 0&&(t=[]),r===void 0&&(r=!0);let o=ZA(e),a=o===((n=e.ownerDocument)==null?void 0:n.body),s=tr(o);return a?t.concat(s,s.visualViewport||[],Ds(o)?o:[],s.frameElement&&r?Ni(s.frameElement):[]):t.concat(o,Ni(o,[],r))}function tR(e){let t=Br(e),r=parseFloat(t.width)||0,n=parseFloat(t.height)||0,o=_r(e),a=o?e.offsetWidth:r,s=o?e.offsetHeight:n,u=fl(r)!==a||fl(n)!==s;return u&&(r=a,n=s),{width:r,height:n,$:u}}function Tg(e){return Fr(e)?e:e.contextElement}function Es(e){let t=Tg(e);if(!_r(t))return Kn(1);let r=t.getBoundingClientRect(),{width:n,height:o,$:a}=tR(t),s=(a?fl(r.width):r.width)/n,u=(a?fl(r.height):r.height)/o;return(!s||!Number.isFinite(s))&&(s=1),(!u||!Number.isFinite(u))&&(u=1),{x:s,y:u}}var Ane=Kn(0);function rR(e){let t=tr(e);return!qd()||!t.visualViewport?Ane:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function Rne(e,t,r){return t===void 0&&(t=!1),!r||t&&r!==tr(e)?!1:t}function $i(e,t,r,n){t===void 0&&(t=!1),r===void 0&&(r=!1);let o=e.getBoundingClientRect(),a=Tg(e),s=Kn(1);t&&(n?Fr(n)&&(s=Es(n)):s=Es(e));let u=Rne(a,r,n)?rR(a):Kn(0),l=(o.left+u.x)/s.x,c=(o.top+u.y)/s.y,p=o.width/s.x,d=o.height/s.y;if(a){let h=tr(a),g=n&&Fr(n)?tr(n):n,v=h,m=v.frameElement;for(;m&&n&&g!==v;){let b=Es(m),y=m.getBoundingClientRect(),x=Br(m),w=y.left+(m.clientLeft+parseFloat(x.paddingLeft))*b.x,S=y.top+(m.clientTop+parseFloat(x.paddingTop))*b.y;l*=b.x,c*=b.y,p*=b.x,d*=b.y,l+=w,c+=S,v=tr(m),m=v.frameElement}}return ki({width:p,height:d,x:l,y:c})}function Fne(e){let{elements:t,rect:r,offsetParent:n,strategy:o}=e,a=o==="fixed",s=dn(n),u=t?dl(t.floating):!1;if(n===s||u&&a)return r;let l={scrollLeft:0,scrollTop:0},c=Kn(1),p=Kn(0),d=_r(n);if((d||!d&&!a)&&((Vi(n)!=="body"||Ds(s))&&(l=ml(n)),_r(n))){let h=$i(n);c=Es(n),p.x=h.x+n.clientLeft,p.y=h.y+n.clientTop}return{width:r.width*c.x,height:r.height*c.y,x:r.x*c.x-l.scrollLeft*c.x+p.x,y:r.y*c.y-l.scrollTop*c.y+p.y}}function Bne(e){return Array.from(e.getClientRects())}function nR(e){return $i(dn(e)).left+ml(e).scrollLeft}function One(e){let t=dn(e),r=ml(e),n=e.ownerDocument.body,o=zt(t.scrollWidth,t.clientWidth,n.scrollWidth,n.clientWidth),a=zt(t.scrollHeight,t.clientHeight,n.scrollHeight,n.clientHeight),s=-r.scrollLeft+nR(e),u=-r.scrollTop;return Br(n).direction==="rtl"&&(s+=zt(t.clientWidth,n.clientWidth)-o),{width:o,height:a,x:s,y:u}}function Mne(e,t){let r=tr(e),n=dn(e),o=r.visualViewport,a=n.clientWidth,s=n.clientHeight,u=0,l=0;if(o){a=o.width,s=o.height;let c=qd();(!c||c&&t==="fixed")&&(u=o.offsetLeft,l=o.offsetTop)}return{width:a,height:s,x:u,y:l}}function Ine(e,t){let r=$i(e,!0,t==="fixed"),n=r.top+e.clientTop,o=r.left+e.clientLeft,a=_r(e)?Es(e):Kn(1),s=e.clientWidth*a.x,u=e.clientHeight*a.y,l=o*a.x,c=n*a.y;return{width:s,height:u,x:l,y:c}}function QA(e,t,r){let n;if(t==="viewport")n=Mne(e,r);else if(t==="document")n=One(dn(e));else if(Fr(t))n=Ine(t,r);else{let o=rR(e);n={...t,x:t.x-o.x,y:t.y-o.y}}return ki(n)}function oR(e,t){let r=Xn(e);return r===t||!Fr(r)||Li(r)?!1:Br(r).position==="fixed"||oR(r,t)}function kne(e,t){let r=t.get(e);if(r)return r;let n=Ni(e,[],!1).filter(u=>Fr(u)&&Vi(u)!=="body"),o=null,a=Br(e).position==="fixed",s=a?Xn(e):e;for(;Fr(s)&&!Li(s);){let u=Br(s),l=Kd(s);!l&&u.position==="fixed"&&(o=null),(a?!l&&!o:!l&&u.position==="static"&&!!o&&["absolute","fixed"].includes(o.position)||Ds(s)&&!l&&oR(e,s))?n=n.filter(p=>p!==s):o=u,s=Xn(s)}return t.set(e,n),n}function Nne(e){let{element:t,boundary:r,rootBoundary:n,strategy:o}=e,s=[...r==="clippingAncestors"?dl(t)?[]:kne(t,this._c):[].concat(r),n],u=s[0],l=s.reduce((c,p)=>{let d=QA(t,p,o);return c.top=zt(d.top,c.top),c.right=Rr(d.right,c.right),c.bottom=Rr(d.bottom,c.bottom),c.left=zt(d.left,c.left),c},QA(t,u,o));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}}function Vne(e){let{width:t,height:r}=tR(e);return{width:t,height:r}}function Lne(e,t,r){let n=_r(t),o=dn(t),a=r==="fixed",s=$i(e,!0,a,t),u={scrollLeft:0,scrollTop:0},l=Kn(0);if(n||!n&&!a)if((Vi(t)!=="body"||Ds(o))&&(u=ml(t)),n){let d=$i(t,!0,a,t);l.x=d.x+t.clientLeft,l.y=d.y+t.clientTop}else o&&(l.x=nR(o));let c=s.left+u.scrollLeft-l.x,p=s.top+u.scrollTop-l.y;return{x:c,y:p,width:s.width,height:s.height}}function Pg(e){return Br(e).position==="static"}function eR(e,t){return!_r(e)||Br(e).position==="fixed"?null:t?t(e):e.offsetParent}function iR(e,t){let r=tr(e);if(dl(e))return r;if(!_r(e)){let o=Xn(e);for(;o&&!Li(o);){if(Fr(o)&&!Pg(o))return o;o=Xn(o)}return r}let n=eR(e,t);for(;n&&YA(n)&&Pg(n);)n=eR(n,t);return n&&Li(n)&&Pg(n)&&!Kd(n)?r:n||JA(e)||r}var $ne=async function(e){let t=this.getOffsetParent||iR,r=this.getDimensions,n=await r(e.floating);return{reference:Lne(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:n.width,height:n.height}}};function zne(e){return Br(e).direction==="rtl"}var aR={convertOffsetParentRelativeRectToViewportRelativeRect:Fne,getDocumentElement:dn,getClippingRect:Nne,getOffsetParent:iR,getElementRects:$ne,getClientRects:Bne,getDimensions:Vne,getScale:Es,isElement:Fr,isRTL:zne};function Hne(e,t){let r=null,n,o=dn(e);function a(){var u;clearTimeout(n),(u=r)==null||u.disconnect(),r=null}function s(u,l){u===void 0&&(u=!1),l===void 0&&(l=1),a();let{left:c,top:p,width:d,height:h}=e.getBoundingClientRect();if(u||t(),!d||!h)return;let g=pl(p),v=pl(o.clientWidth-(c+d)),m=pl(o.clientHeight-(p+h)),b=pl(c),x={rootMargin:-g+"px "+-v+"px "+-m+"px "+-b+"px",threshold:zt(0,Rr(1,l))||1},w=!0;function S(E){let D=E[0].intersectionRatio;if(D!==l){if(!w)return s();D?s(!1,D):n=setTimeout(()=>{s(!1,1e-7)},1e3)}w=!1}try{r=new IntersectionObserver(S,{...x,root:o.ownerDocument})}catch{r=new IntersectionObserver(S,x)}r.observe(e)}return s(!0),a}function Ag(e,t,r,n){n===void 0&&(n={});let{ancestorScroll:o=!0,ancestorResize:a=!0,elementResize:s=typeof ResizeObserver=="function",layoutShift:u=typeof IntersectionObserver=="function",animationFrame:l=!1}=n,c=Tg(e),p=o||a?[...c?Ni(c):[],...Ni(t)]:[];p.forEach(y=>{o&&y.addEventListener("scroll",r,{passive:!0}),a&&y.addEventListener("resize",r)});let d=c&&u?Hne(c,r):null,h=-1,g=null;s&&(g=new ResizeObserver(y=>{let[x]=y;x&&x.target===c&&g&&(g.unobserve(t),cancelAnimationFrame(h),h=requestAnimationFrame(()=>{var w;(w=g)==null||w.observe(t)})),r()}),c&&!l&&g.observe(c),g.observe(t));let v,m=l?$i(e):null;l&&b();function b(){let y=$i(e);m&&(y.x!==m.x||y.y!==m.y||y.width!==m.width||y.height!==m.height)&&r(),m=y,v=requestAnimationFrame(b)}return r(),()=>{var y;p.forEach(x=>{o&&x.removeEventListener("scroll",r),a&&x.removeEventListener("resize",r)}),d?.(),(y=g)==null||y.disconnect(),g=null,l&&cancelAnimationFrame(v)}}var sR=_A;var uR=WA,lR=GA,cR=KA,fR=jA,Rg=HA;var pR=UA,Fg=(e,t,r)=>{let n=new Map,o={platform:aR,...r},a={...o.platform,_c:n};return zA(e,t,{...o,platform:a})};import*as nt from"react";import{useLayoutEffect as Gne,useEffect as jne}from"react";import*as hR from"react-dom";var Xd=typeof document<"u"?Gne:jne;function Yd(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 r,n,o;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(r=e.length,r!==t.length)return!1;for(n=r;n--!==0;)if(!Yd(e[n],t[n]))return!1;return!0}if(o=Object.keys(e),r=o.length,r!==Object.keys(t).length)return!1;for(n=r;n--!==0;)if(!{}.hasOwnProperty.call(t,o[n]))return!1;for(n=r;n--!==0;){let a=o[n];if(!(a==="_owner"&&e.$$typeof)&&!Yd(e[a],t[a]))return!1}return!0}return e!==e&&t!==t}function gR(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function dR(e,t){let r=gR(e);return Math.round(t*r)/r}function mR(e){let t=nt.useRef(e);return Xd(()=>{t.current=e}),t}function vR(e){e===void 0&&(e={});let{placement:t="bottom",strategy:r="absolute",middleware:n=[],platform:o,elements:{reference:a,floating:s}={},transform:u=!0,whileElementsMounted:l,open:c}=e,[p,d]=nt.useState({x:0,y:0,strategy:r,placement:t,middlewareData:{},isPositioned:!1}),[h,g]=nt.useState(n);Yd(h,n)||g(n);let[v,m]=nt.useState(null),[b,y]=nt.useState(null),x=nt.useCallback(Q=>{Q!==D.current&&(D.current=Q,m(Q))},[]),w=nt.useCallback(Q=>{Q!==P.current&&(P.current=Q,y(Q))},[]),S=a||v,E=s||b,D=nt.useRef(null),P=nt.useRef(null),R=nt.useRef(p),F=l!=null,M=mR(l),G=mR(o),N=nt.useCallback(()=>{if(!D.current||!P.current)return;let Q={placement:t,strategy:r,middleware:h};G.current&&(Q.platform=G.current),Fg(D.current,P.current,Q).then(re=>{let H={...re,isPositioned:!0};L.current&&!Yd(R.current,H)&&(R.current=H,hR.flushSync(()=>{d(H)}))})},[h,t,r,G]);Xd(()=>{c===!1&&R.current.isPositioned&&(R.current.isPositioned=!1,d(Q=>({...Q,isPositioned:!1})))},[c]);let L=nt.useRef(!1);Xd(()=>(L.current=!0,()=>{L.current=!1}),[]),Xd(()=>{if(S&&(D.current=S),E&&(P.current=E),S&&E){if(M.current)return M.current(S,E,N);N()}},[S,E,N,M,F]);let I=nt.useMemo(()=>({reference:D,floating:P,setReference:x,setFloating:w}),[x,w]),V=nt.useMemo(()=>({reference:S,floating:E}),[S,E]),Y=nt.useMemo(()=>{let Q={position:r,left:0,top:0};if(!V.floating)return Q;let re=dR(V.floating,p.x),H=dR(V.floating,p.y);return u?{...Q,transform:"translate("+re+"px, "+H+"px)",...gR(V.floating)>=1.5&&{willChange:"transform"}}:{position:r,left:re,top:H}},[r,u,V.floating,p.x,p.y]);return nt.useMemo(()=>({...p,update:N,refs:I,elements:V,floatingStyles:Y}),[p,N,I,V,Y])}var _ne=e=>{function t(r){return{}.hasOwnProperty.call(r,"current")}return{name:"arrow",options:e,fn(r){let{element:n,padding:o}=typeof e=="function"?e(r):e;return n&&t(n)?n.current!=null?Rg({element:n.current,padding:o}).fn(r):{}:n?Rg({element:n,padding:o}).fn(r):{}}}},yR=(e,t)=>({...sR(e),options:[e,t]}),bR=(e,t)=>({...uR(e),options:[e,t]}),CR=(e,t)=>({...pR(e),options:[e,t]}),xR=(e,t)=>({...lR(e),options:[e,t]}),wR=(e,t)=>({...cR(e),options:[e,t]});var SR=(e,t)=>({...fR(e),options:[e,t]});var DR=(e,t)=>({..._ne(e),options:[e,t]});i();import*as PR from"react";import{jsx as ER}from"react/jsx-runtime";var Wne="Arrow",TR=PR.forwardRef((e,t)=>{let{children:r,width:n=10,height:o=5,...a}=e;return ER(Ue.svg,{...a,ref:t,width:n,height:o,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?r:ER("polygon",{points:"0,0 30,0 15,10"})})});TR.displayName=Wne;var AR=TR;i();import*as RR from"react";function FR(e){let[t,r]=RR.useState(void 0);return Ar(()=>{if(e){r({width:e.offsetWidth,height:e.offsetHeight});let n=new ResizeObserver(o=>{if(!Array.isArray(o)||!o.length)return;let a=o[0],s,u;if("borderBoxSize"in a){let l=a.borderBoxSize,c=Array.isArray(l)?l[0]:l;s=c.inlineSize,u=c.blockSize}else s=e.offsetWidth,u=e.offsetHeight;r({width:s,height:u})});return n.observe(e,{box:"border-box"}),()=>n.unobserve(e)}else r(void 0)},[e]),t}import{jsx as zi}from"react/jsx-runtime";var Bg="Popper",[BR,Og]=cn(Bg),[Kne,OR]=BR(Bg),MR=e=>{let{__scopePopper:t,children:r}=e,[n,o]=yr.useState(null);return zi(Kne,{scope:t,anchor:n,onAnchorChange:o,children:r})};MR.displayName=Bg;var IR="PopperAnchor",kR=yr.forwardRef((e,t)=>{let{__scopePopper:r,virtualRef:n,...o}=e,a=OR(IR,r),s=yr.useRef(null),u=Ye(t,s);return yr.useEffect(()=>{a.onAnchorChange(n?.current||s.current)}),n?null:zi(Ue.div,{...o,ref:u})});kR.displayName=IR;var Mg="PopperContent",[qne,Xne]=BR(Mg),NR=yr.forwardRef((e,t)=>{let{__scopePopper:r,side:n="bottom",sideOffset:o=0,align:a="center",alignOffset:s=0,arrowPadding:u=0,avoidCollisions:l=!0,collisionBoundary:c=[],collisionPadding:p=0,sticky:d="partial",hideWhenDetached:h=!1,updatePositionStrategy:g="optimized",onPlaced:v,...m}=e,b=OR(Mg,r),[y,x]=yr.useState(null),w=Ye(t,j=>x(j)),[S,E]=yr.useState(null),D=FR(S),P=D?.width??0,R=D?.height??0,F=n+(a!=="center"?"-"+a:""),M=typeof p=="number"?p:{top:0,right:0,bottom:0,left:0,...p},G=Array.isArray(c)?c:[c],N=G.length>0,L={padding:M,boundary:G.filter(Jne),altBoundary:N},{refs:I,floatingStyles:V,placement:Y,isPositioned:Q,middlewareData:re}=vR({strategy:"fixed",placement:F,whileElementsMounted:(...j)=>Ag(...j,{animationFrame:g==="always"}),elements:{reference:b.anchor},middleware:[yR({mainAxis:o+R,alignmentAxis:s}),l&&bR({mainAxis:!0,crossAxis:!1,limiter:d==="partial"?CR():void 0,...L}),l&&xR({...L}),wR({...L,apply:({elements:j,rects:ue,availableWidth:oe,availableHeight:he})=>{let{width:Ce,height:Se}=ue.reference,Ee=j.floating.style;Ee.setProperty("--radix-popper-available-width",`${oe}px`),Ee.setProperty("--radix-popper-available-height",`${he}px`),Ee.setProperty("--radix-popper-anchor-width",`${Ce}px`),Ee.setProperty("--radix-popper-anchor-height",`${Se}px`)}}),S&&DR({element:S,padding:u}),Zne({arrowWidth:P,arrowHeight:R}),h&&SR({strategy:"referenceHidden",...L})]}),[H,le]=$R(Y),ve=at(v);Ar(()=>{Q&&ve?.()},[Q,ve]);let me=re.arrow?.x,Ge=re.arrow?.y,A=re.arrow?.centerOffset!==0,[_,z]=yr.useState();return Ar(()=>{y&&z(window.getComputedStyle(y).zIndex)},[y]),zi("div",{ref:I.setFloating,"data-radix-popper-content-wrapper":"",style:{...V,transform:Q?V.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:_,"--radix-popper-transform-origin":[re.transformOrigin?.x,re.transformOrigin?.y].join(" "),...re.hide?.referenceHidden&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:zi(qne,{scope:r,placedSide:H,onArrowChange:E,arrowX:me,arrowY:Ge,shouldHideArrow:A,children:zi(Ue.div,{"data-side":H,"data-align":le,...m,ref:w,style:{...m.style,animation:Q?void 0:"none"}})})})});NR.displayName=Mg;var VR="PopperArrow",Yne={top:"bottom",right:"left",bottom:"top",left:"right"},LR=yr.forwardRef(function(t,r){let{__scopePopper:n,...o}=t,a=Xne(VR,n),s=Yne[a.placedSide];return zi("span",{ref:a.onArrowChange,style:{position:"absolute",left:a.arrowX,top:a.arrowY,[s]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[a.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[a.placedSide],visibility:a.shouldHideArrow?"hidden":void 0},children:zi(AR,{...o,ref:r,style:{...o.style,display:"block"}})})});LR.displayName=VR;function Jne(e){return e!==null}var Zne=e=>({name:"transformOrigin",options:e,fn(t){let{placement:r,rects:n,middlewareData:o}=t,s=o.arrow?.centerOffset!==0,u=s?0:e.arrowWidth,l=s?0:e.arrowHeight,[c,p]=$R(r),d={start:"0%",center:"50%",end:"100%"}[p],h=(o.arrow?.x??0)+u/2,g=(o.arrow?.y??0)+l/2,v="",m="";return c==="bottom"?(v=s?d:`${h}px`,m=`${-l}px`):c==="top"?(v=s?d:`${h}px`,m=`${n.floating.height+l}px`):c==="right"?(v=`${-l}px`,m=s?d:`${g}px`):c==="left"&&(v=`${n.floating.width+l}px`,m=s?d:`${g}px`),{data:{x:v,y:m}}}});function $R(e){let[t,r="center"]=e.split("-");return[t,r]}var Ig=MR,zR=kR,HR=NR,GR=LR;i();import*as Jd from"react";import eoe from"react-dom";import{jsx as toe}from"react/jsx-runtime";var roe="Portal",kg=Jd.forwardRef((e,t)=>{let{container:r,...n}=e,[o,a]=Jd.useState(!1);Ar(()=>a(!0),[]);let s=r||o&&globalThis?.document?.body;return s?eoe.createPortal(toe(Ue.div,{...n,ref:t}),s):null});kg.displayName=roe;i();import*as rr from"react";import*as jR from"react-dom";import*as _R from"react";function noe(e,t){return _R.useReducer((r,n)=>t[r][n]??r,e)}var Ps=e=>{let{present:t,children:r}=e,n=ooe(t),o=typeof r=="function"?r({present:n.isPresent}):rr.Children.only(r),a=Ye(n.ref,ioe(o));return typeof r=="function"||n.isPresent?rr.cloneElement(o,{ref:a}):null};Ps.displayName="Presence";function ooe(e){let[t,r]=rr.useState(),n=rr.useRef({}),o=rr.useRef(e),a=rr.useRef("none"),s=e?"mounted":"unmounted",[u,l]=noe(s,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return rr.useEffect(()=>{let c=Zd(n.current);a.current=u==="mounted"?c:"none"},[u]),Ar(()=>{let c=n.current,p=o.current;if(p!==e){let h=a.current,g=Zd(c);e?l("MOUNT"):g==="none"||c?.display==="none"?l("UNMOUNT"):l(p&&h!==g?"ANIMATION_OUT":"UNMOUNT"),o.current=e}},[e,l]),Ar(()=>{if(t){let c=d=>{let g=Zd(n.current).includes(d.animationName);d.target===t&&g&&jR.flushSync(()=>l("ANIMATION_END"))},p=d=>{d.target===t&&(a.current=Zd(n.current))};return t.addEventListener("animationstart",p),t.addEventListener("animationcancel",c),t.addEventListener("animationend",c),()=>{t.removeEventListener("animationstart",p),t.removeEventListener("animationcancel",c),t.removeEventListener("animationend",c)}}else l("ANIMATION_END")},[t,l]),{isPresent:["mounted","unmountSuspended"].includes(u),ref:rr.useCallback(c=>{c&&(n.current=getComputedStyle(c)),r(c)},[])}}function Zd(e){return e?.animationName||"none"}function ioe(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,r=t&&"isReactWarning"in t&&t.isReactWarning;return r?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,r=t&&"isReactWarning"in t&&t.isReactWarning,r?e.props.ref:e.props.ref||e.ref)}i();import*as pt from"react";import{jsx as Hi}from"react/jsx-runtime";var Ng="rovingFocusGroup.onEntryFocus",aoe={bubbles:!1,cancelable:!0},Qd="RovingFocusGroup",[Vg,WR,soe]=Ld(Qd),[uoe,Lg]=cn(Qd,[soe]),[loe,coe]=uoe(Qd),UR=pt.forwardRef((e,t)=>Hi(Vg.Provider,{scope:e.__scopeRovingFocusGroup,children:Hi(Vg.Slot,{scope:e.__scopeRovingFocusGroup,children:Hi(foe,{...e,ref:t})})}));UR.displayName=Qd;var foe=pt.forwardRef((e,t)=>{let{__scopeRovingFocusGroup:r,orientation:n,loop:o=!1,dir:a,currentTabStopId:s,defaultCurrentTabStopId:u,onCurrentTabStopIdChange:l,onEntryFocus:c,preventScrollOnEntryFocus:p=!1,...d}=e,h=pt.useRef(null),g=Ye(t,h),v=zd(a),[m=null,b]=ll({prop:s,defaultProp:u,onChange:l}),[y,x]=pt.useState(!1),w=at(c),S=WR(r),E=pt.useRef(!1),[D,P]=pt.useState(0);return pt.useEffect(()=>{let R=h.current;if(R)return R.addEventListener(Ng,w),()=>R.removeEventListener(Ng,w)},[w]),Hi(loe,{scope:r,orientation:n,dir:v,loop:o,currentTabStopId:m,onItemFocus:pt.useCallback(R=>b(R),[b]),onItemShiftTab:pt.useCallback(()=>x(!0),[]),onFocusableItemAdd:pt.useCallback(()=>P(R=>R+1),[]),onFocusableItemRemove:pt.useCallback(()=>P(R=>R-1),[]),children:Hi(Ue.div,{tabIndex:y||D===0?-1:0,"data-orientation":n,...d,ref:g,style:{outline:"none",...e.style},onMouseDown:ye(e.onMouseDown,()=>{E.current=!0}),onFocus:ye(e.onFocus,R=>{let F=!E.current;if(R.target===R.currentTarget&&F&&!y){let M=new CustomEvent(Ng,aoe);if(R.currentTarget.dispatchEvent(M),!M.defaultPrevented){let G=S().filter(Y=>Y.focusable),N=G.find(Y=>Y.active),L=G.find(Y=>Y.id===m),V=[N,L,...G].filter(Boolean).map(Y=>Y.ref.current);XR(V,p)}}E.current=!1}),onBlur:ye(e.onBlur,()=>x(!1))})})}),KR="RovingFocusGroupItem",qR=pt.forwardRef((e,t)=>{let{__scopeRovingFocusGroup:r,focusable:n=!0,active:o=!1,tabStopId:a,...s}=e,u=jo(),l=a||u,c=coe(KR,r),p=c.currentTabStopId===l,d=WR(r),{onFocusableItemAdd:h,onFocusableItemRemove:g}=c;return pt.useEffect(()=>{if(n)return h(),()=>g()},[n,h,g]),Hi(Vg.ItemSlot,{scope:r,id:l,focusable:n,active:o,children:Hi(Ue.span,{tabIndex:p?0:-1,"data-orientation":c.orientation,...s,ref:t,onMouseDown:ye(e.onMouseDown,v=>{n?c.onItemFocus(l):v.preventDefault()}),onFocus:ye(e.onFocus,()=>c.onItemFocus(l)),onKeyDown:ye(e.onKeyDown,v=>{if(v.key==="Tab"&&v.shiftKey){c.onItemShiftTab();return}if(v.target!==v.currentTarget)return;let m=moe(v,c.orientation,c.dir);if(m!==void 0){if(v.metaKey||v.ctrlKey||v.altKey||v.shiftKey)return;v.preventDefault();let y=d().filter(x=>x.focusable).map(x=>x.ref.current);if(m==="last")y.reverse();else if(m==="prev"||m==="next"){m==="prev"&&y.reverse();let x=y.indexOf(v.currentTarget);y=c.loop?hoe(y,x+1):y.slice(x+1)}setTimeout(()=>XR(y))}})})})});qR.displayName=KR;var poe={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function doe(e,t){return t!=="rtl"?e:e==="ArrowLeft"?"ArrowRight":e==="ArrowRight"?"ArrowLeft":e}function moe(e,t,r){let n=doe(e.key,r);if(!(t==="vertical"&&["ArrowLeft","ArrowRight"].includes(n))&&!(t==="horizontal"&&["ArrowUp","ArrowDown"].includes(n)))return poe[n]}function XR(e,t=!1){let r=document.activeElement;for(let n of e)if(n===r||(n.focus({preventScroll:t}),document.activeElement!==r))return}function hoe(e,t){return e.map((r,n)=>e[(t+n)%e.length])}var YR=UR,JR=qR;i();var voe=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},Ts=new WeakMap,e1=new WeakMap,t1={},$g=0,ZR=function(e){return e&&(e.host||ZR(e.parentNode))},yoe=function(e,t){return t.map(function(r){if(e.contains(r))return r;var n=ZR(r);return n&&e.contains(n)?n:(console.error("aria-hidden",r,"in not contained inside",e,". Doing nothing"),null)}).filter(function(r){return!!r})},boe=function(e,t,r,n){var o=yoe(t,Array.isArray(e)?e:[e]);t1[r]||(t1[r]=new WeakMap);var a=t1[r],s=[],u=new Set,l=new Set(o),c=function(d){!d||u.has(d)||(u.add(d),c(d.parentNode))};o.forEach(c);var p=function(d){!d||l.has(d)||Array.prototype.forEach.call(d.children,function(h){if(u.has(h))p(h);else try{var g=h.getAttribute(n),v=g!==null&&g!=="false",m=(Ts.get(h)||0)+1,b=(a.get(h)||0)+1;Ts.set(h,m),a.set(h,b),s.push(h),m===1&&v&&e1.set(h,!0),b===1&&h.setAttribute(r,"true"),v||h.setAttribute(n,"true")}catch(y){console.error("aria-hidden: cannot operate on ",h,y)}})};return p(t),u.clear(),$g++,function(){s.forEach(function(d){var h=Ts.get(d)-1,g=a.get(d)-1;Ts.set(d,h),a.set(d,g),h||(e1.has(d)||d.removeAttribute(n),e1.delete(d)),g||d.removeAttribute(r)}),$g--,$g||(Ts=new WeakMap,Ts=new WeakMap,e1=new WeakMap,t1={})}},QR=function(e,t,r){r===void 0&&(r="data-aria-hidden");var n=Array.from(Array.isArray(e)?e:[e]),o=t||voe(e);return o?(n.push.apply(n,Array.from(o.querySelectorAll("[aria-live]"))),boe(n,o,r,"aria-hidden")):function(){return null}};i();i();i();var mn=function(){return mn=Object.assign||function(t){for(var r,n=1,o=arguments.length;n<o;n++){r=arguments[n];for(var a in r)Object.prototype.hasOwnProperty.call(r,a)&&(t[a]=r[a])}return t},mn.apply(this,arguments)};function eF(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]]);return r}function tF(e,t,r){if(r||arguments.length===2)for(var n=0,o=t.length,a;n<o;n++)(a||!(n in t))&&(a||(a=Array.prototype.slice.call(t,0,n)),a[n]=t[n]);return e.concat(a||Array.prototype.slice.call(t))}import*as a1 from"react";i();import*as Rt from"react";i();var Gi="right-scroll-bar-position",ji="width-before-scroll-bar",zg="with-scroll-bars-hidden",Hg="--removed-body-scroll-bar-size";i();i();function r1(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}i();import{useState as Coe}from"react";function rF(e,t){var r=Coe(function(){return{value:e,callback:t,facade:{get current(){return r.value},set current(n){var o=r.value;o!==n&&(r.value=n,r.callback(n,o))}}}})[0];return r.callback=t,r.facade}i();import*as n1 from"react";var xoe=typeof window<"u"?n1.useLayoutEffect:n1.useEffect,nF=new WeakMap;function Gg(e,t){var r=rF(t||null,function(n){return e.forEach(function(o){return r1(o,n)})});return xoe(function(){var n=nF.get(r);if(n){var o=new Set(n),a=new Set(e),s=r.current;o.forEach(function(u){a.has(u)||r1(u,null)}),a.forEach(function(u){o.has(u)||r1(u,s)})}nF.set(r,e)},[e]),r}i();i();i();var As=function(){return As=Object.assign||function(t){for(var r,n=1,o=arguments.length;n<o;n++){r=arguments[n];for(var a in r)Object.prototype.hasOwnProperty.call(r,a)&&(t[a]=r[a])}return t},As.apply(this,arguments)};function oF(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]]);return r}i();function woe(e){return e}function Soe(e,t){t===void 0&&(t=woe);var r=[],n=!1,o={read:function(){if(n)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return r.length?r[r.length-1]:e},useMedium:function(a){var s=t(a,n);return r.push(s),function(){r=r.filter(function(u){return u!==s})}},assignSyncMedium:function(a){for(n=!0;r.length;){var s=r;r=[],s.forEach(a)}r={push:function(u){return a(u)},filter:function(){return r}}},assignMedium:function(a){n=!0;var s=[];if(r.length){var u=r;r=[],u.forEach(a),s=r}var l=function(){var p=s;s=[],p.forEach(a)},c=function(){return Promise.resolve().then(l)};c(),r={push:function(p){s.push(p),c()},filter:function(p){return s=s.filter(p),r}}}};return o}function jg(e){e===void 0&&(e={});var t=Soe(null);return t.options=As({async:!0,ssr:!1},e),t}i();import*as iF from"react";var aF=function(e){var t=e.sideCar,r=oF(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var n=t.read();if(!n)throw new Error("Sidecar medium not found");return iF.createElement(n,As({},r))};aF.isSideCarExport=!0;function _g(e,t){return e.useMedium(t),aF}var o1=jg();var Wg=function(){},hl=Rt.forwardRef(function(e,t){var r=Rt.useRef(null),n=Rt.useState({onScrollCapture:Wg,onWheelCapture:Wg,onTouchMoveCapture:Wg}),o=n[0],a=n[1],s=e.forwardProps,u=e.children,l=e.className,c=e.removeScrollBar,p=e.enabled,d=e.shards,h=e.sideCar,g=e.noIsolation,v=e.inert,m=e.allowPinchZoom,b=e.as,y=b===void 0?"div":b,x=e.gapMode,w=eF(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noIsolation","inert","allowPinchZoom","as","gapMode"]),S=h,E=Gg([r,t]),D=mn(mn({},w),o);return Rt.createElement(Rt.Fragment,null,p&&Rt.createElement(S,{sideCar:o1,removeScrollBar:c,shards:d,noIsolation:g,inert:v,setCallbacks:a,allowPinchZoom:!!m,lockRef:r,gapMode:x}),s?Rt.cloneElement(Rt.Children.only(u),mn(mn({},D),{ref:E})):Rt.createElement(y,mn({},D,{className:l,ref:E}),u))});hl.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};hl.classNames={fullWidth:ji,zeroRight:Gi};i();i();import*as $e from"react";i();i();import*as Fs from"react";i();i();i();import*as lF from"react";i();i();var sF;var uF=function(){if(sF)return sF;if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function Doe(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=uF();return t&&e.setAttribute("nonce",t),e}function Eoe(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function Poe(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var Ug=function(){var e=0,t=null;return{add:function(r){e==0&&(t=Doe())&&(Eoe(t,r),Poe(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}};var Kg=function(){var e=Ug();return function(t,r){lF.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&r])}};var gl=function(){var e=Kg(),t=function(r){var n=r.styles,o=r.dynamic;return e(n,o),null};return t};i();var Toe={left:0,top:0,right:0,gap:0},qg=function(e){return parseInt(e||"",10)||0},Aoe=function(e){var t=window.getComputedStyle(document.body),r=t[e==="padding"?"paddingLeft":"marginLeft"],n=t[e==="padding"?"paddingTop":"marginTop"],o=t[e==="padding"?"paddingRight":"marginRight"];return[qg(r),qg(n),qg(o)]},Xg=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return Toe;var t=Aoe(e),r=document.documentElement.clientWidth,n=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,n-r+t[2]-t[0])}};var Roe=gl(),Rs="data-scroll-locked",Foe=function(e,t,r,n){var o=e.left,a=e.top,s=e.right,u=e.gap;return r===void 0&&(r="margin"),`
2086
+ `,dA=({placement:e="left",align:t="top",gap:r="1.5rem",item:n,children:o,...a})=>Kre(pA,{...a,children:[(0,fA.isNotNil)(n)?cA(Ure,{align:t,gap:r,placement:e,children:n}):null,cA(Wre,{align:t,children:o})]});dA.displayName="MediaObject_VHS";i();import{useState as Iie}from"react";import v1,{css as kie,keyframes as pB}from"styled-components";i();import*as st from"react";i();function ye(e,t,{checkForDefaultPrevented:r=!0}={}){return function(o){if(e?.(o),r===!1||!o.defaultPrevented)return t?.(o)}}i();import*as mA from"react";function qre(e,t){typeof e=="function"?e(t):e!=null&&(e.current=t)}function Oi(...e){return t=>e.forEach(r=>qre(r,t))}function Ye(...e){return mA.useCallback(Oi(...e),e)}i();import*as Un from"react";import{jsx as Xre}from"react/jsx-runtime";function cn(e,t=[]){let r=[];function n(a,s){let u=Un.createContext(s),l=r.length;r=[...r,s];function c(d){let{scope:h,children:g,...v}=d,m=h?.[e][l]||u,b=Un.useMemo(()=>v,Object.values(v));return Xre(m.Provider,{value:b,children:g})}function p(d,h){let g=h?.[e][l]||u,v=Un.useContext(g);if(v)return v;if(s!==void 0)return s;throw new Error(`\`${d}\` must be used within \`${a}\``)}return c.displayName=a+"Provider",[c,p]}let o=()=>{let a=r.map(s=>Un.createContext(s));return function(u){let l=u?.[e]||a;return Un.useMemo(()=>({[`__scope${e}`]:{...u,[e]:l}}),[u,l])}};return o.scopeName=e,[n,Yre(o,...t)]}function Yre(...e){let t=e[0];if(e.length===1)return t;let r=()=>{let n=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(a){let s=n.reduce((u,{useScope:l,scopeName:c})=>{let d=l(a)[`__scope${c}`];return{...u,...d}},{});return Un.useMemo(()=>({[`__scope${t.scopeName}`]:s}),[s])}};return r.scopeName=t.scopeName,r}i();import*as zo from"react";i();import*as ws from"react";function at(e){let t=ws.useRef(e);return ws.useEffect(()=>{t.current=e}),ws.useMemo(()=>(...r)=>t.current?.(...r),[])}function ll({prop:e,defaultProp:t,onChange:r=()=>{}}){let[n,o]=Jre({defaultProp:t,onChange:r}),a=e!==void 0,s=a?e:n,u=at(r),l=zo.useCallback(c=>{if(a){let d=typeof c=="function"?c(e):c;d!==e&&u(d)}else o(c)},[a,e,o,u]);return[s,l]}function Jre({defaultProp:e,onChange:t}){let r=zo.useState(e),[n]=r,o=zo.useRef(n),a=at(t);return zo.useEffect(()=>{o.current!==n&&(a(n),o.current=n)},[n,o,a]),r}i();import*as hA from"react";import*as gA from"react-dom";i();import*as wt from"react";import{Fragment as Zre,jsx as gg}from"react/jsx-runtime";var Ho=wt.forwardRef((e,t)=>{let{children:r,...n}=e,o=wt.Children.toArray(r),a=o.find(ene);if(a){let s=a.props.children,u=o.map(l=>l===a?wt.Children.count(s)>1?wt.Children.only(null):wt.isValidElement(s)?s.props.children:null:l);return gg(vg,{...n,ref:t,children:wt.isValidElement(s)?wt.cloneElement(s,void 0,u):null})}return gg(vg,{...n,ref:t,children:r})});Ho.displayName="Slot";var vg=wt.forwardRef((e,t)=>{let{children:r,...n}=e;if(wt.isValidElement(r)){let o=rne(r);return wt.cloneElement(r,{...tne(n,r.props),ref:t?Oi(t,o):o})}return wt.Children.count(r)>1?wt.Children.only(null):null});vg.displayName="SlotClone";var Qre=({children:e})=>gg(Zre,{children:e});function ene(e){return wt.isValidElement(e)&&e.type===Qre}function tne(e,t){let r={...t};for(let n in t){let o=e[n],a=t[n];/^on[A-Z]/.test(n)?o&&a?r[n]=(...u)=>{a(...u),o(...u)}:o&&(r[n]=o):n==="style"?r[n]={...o,...a}:n==="className"&&(r[n]=[o,a].filter(Boolean).join(" "))}return{...e,...r}}function rne(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,r=t&&"isReactWarning"in t&&t.isReactWarning;return r?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,r=t&&"isReactWarning"in t&&t.isReactWarning,r?e.props.ref:e.props.ref||e.ref)}import{jsx as nne}from"react/jsx-runtime";var one=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"],Ue=one.reduce((e,t)=>{let r=hA.forwardRef((n,o)=>{let{asChild:a,...s}=n,u=a?Ho:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),nne(u,{...s,ref:o})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function Vd(e,t){e&&gA.flushSync(()=>e.dispatchEvent(t))}i();import*as ne from"react";i();import Mi from"react";import{jsx as yg}from"react/jsx-runtime";function Ld(e){let t=e+"CollectionProvider",[r,n]=cn(t),[o,a]=r(t,{collectionRef:{current:null},itemMap:new Map}),s=g=>{let{scope:v,children:m}=g,b=Mi.useRef(null),y=Mi.useRef(new Map).current;return yg(o,{scope:v,itemMap:y,collectionRef:b,children:m})};s.displayName=t;let u=e+"CollectionSlot",l=Mi.forwardRef((g,v)=>{let{scope:m,children:b}=g,y=a(u,m),x=Ye(v,y.collectionRef);return yg(Ho,{ref:x,children:b})});l.displayName=u;let c=e+"CollectionItemSlot",p="data-radix-collection-item",d=Mi.forwardRef((g,v)=>{let{scope:m,children:b,...y}=g,x=Mi.useRef(null),w=Ye(v,x),S=a(c,m);return Mi.useEffect(()=>(S.itemMap.set(x,{ref:x,...y}),()=>void S.itemMap.delete(x))),yg(Ho,{[p]:"",ref:w,children:b})});d.displayName=c;function h(g){let v=a(e+"CollectionConsumer",g);return Mi.useCallback(()=>{let b=v.collectionRef.current;if(!b)return[];let y=Array.from(b.querySelectorAll(`[${p}]`));return Array.from(v.itemMap.values()).sort((S,E)=>y.indexOf(S.ref.current)-y.indexOf(E.ref.current))},[v.collectionRef,v.itemMap])}return[{Provider:s,Slot:l,ItemSlot:d},h,n]}i();import*as $d from"react";import{jsx as Bot}from"react/jsx-runtime";var ine=$d.createContext(void 0);function zd(e){let t=$d.useContext(ine);return e||t||"ltr"}i();import*as Ke from"react";i();import*as vA from"react";function yA(e,t=globalThis?.document){let r=at(e);vA.useEffect(()=>{let n=o=>{o.key==="Escape"&&r(o)};return t.addEventListener("keydown",n,{capture:!0}),()=>t.removeEventListener("keydown",n,{capture:!0})},[r,t])}import{jsx as xA}from"react/jsx-runtime";var ane="DismissableLayer",bg="dismissableLayer.update",sne="dismissableLayer.pointerDownOutside",une="dismissableLayer.focusOutside",bA,wA=Ke.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),Cg=Ke.forwardRef((e,t)=>{let{disableOutsidePointerEvents:r=!1,onEscapeKeyDown:n,onPointerDownOutside:o,onFocusOutside:a,onInteractOutside:s,onDismiss:u,...l}=e,c=Ke.useContext(wA),[p,d]=Ke.useState(null),h=p?.ownerDocument??globalThis?.document,[,g]=Ke.useState({}),v=Ye(t,P=>d(P)),m=Array.from(c.layers),[b]=[...c.layersWithOutsidePointerEventsDisabled].slice(-1),y=m.indexOf(b),x=p?m.indexOf(p):-1,w=c.layersWithOutsidePointerEventsDisabled.size>0,S=x>=y,E=fne(P=>{let R=P.target,F=[...c.branches].some(M=>M.contains(R));!S||F||(o?.(P),s?.(P),P.defaultPrevented||u?.())},h),D=pne(P=>{let R=P.target;[...c.branches].some(M=>M.contains(R))||(a?.(P),s?.(P),P.defaultPrevented||u?.())},h);return yA(P=>{x===c.layers.size-1&&(n?.(P),!P.defaultPrevented&&u&&(P.preventDefault(),u()))},h),Ke.useEffect(()=>{if(p)return r&&(c.layersWithOutsidePointerEventsDisabled.size===0&&(bA=h.body.style.pointerEvents,h.body.style.pointerEvents="none"),c.layersWithOutsidePointerEventsDisabled.add(p)),c.layers.add(p),CA(),()=>{r&&c.layersWithOutsidePointerEventsDisabled.size===1&&(h.body.style.pointerEvents=bA)}},[p,h,r,c]),Ke.useEffect(()=>()=>{p&&(c.layers.delete(p),c.layersWithOutsidePointerEventsDisabled.delete(p),CA())},[p,c]),Ke.useEffect(()=>{let P=()=>g({});return document.addEventListener(bg,P),()=>document.removeEventListener(bg,P)},[]),xA(Ue.div,{...l,ref:v,style:{pointerEvents:w?S?"auto":"none":void 0,...e.style},onFocusCapture:ye(e.onFocusCapture,D.onFocusCapture),onBlurCapture:ye(e.onBlurCapture,D.onBlurCapture),onPointerDownCapture:ye(e.onPointerDownCapture,E.onPointerDownCapture)})});Cg.displayName=ane;var lne="DismissableLayerBranch",cne=Ke.forwardRef((e,t)=>{let r=Ke.useContext(wA),n=Ke.useRef(null),o=Ye(t,n);return Ke.useEffect(()=>{let a=n.current;if(a)return r.branches.add(a),()=>{r.branches.delete(a)}},[r.branches]),xA(Ue.div,{...e,ref:o})});cne.displayName=lne;function fne(e,t=globalThis?.document){let r=at(e),n=Ke.useRef(!1),o=Ke.useRef(()=>{});return Ke.useEffect(()=>{let a=u=>{if(u.target&&!n.current){let c=function(){SA(sne,r,p,{discrete:!0})};var l=c;let p={originalEvent:u};u.pointerType==="touch"?(t.removeEventListener("click",o.current),o.current=c,t.addEventListener("click",o.current,{once:!0})):c()}else t.removeEventListener("click",o.current);n.current=!1},s=window.setTimeout(()=>{t.addEventListener("pointerdown",a)},0);return()=>{window.clearTimeout(s),t.removeEventListener("pointerdown",a),t.removeEventListener("click",o.current)}},[t,r]),{onPointerDownCapture:()=>n.current=!0}}function pne(e,t=globalThis?.document){let r=at(e),n=Ke.useRef(!1);return Ke.useEffect(()=>{let o=a=>{a.target&&!n.current&&SA(une,r,{originalEvent:a},{discrete:!1})};return t.addEventListener("focusin",o),()=>t.removeEventListener("focusin",o)},[t,r]),{onFocusCapture:()=>n.current=!0,onBlurCapture:()=>n.current=!1}}function CA(){let e=new CustomEvent(bg);document.dispatchEvent(e)}function SA(e,t,r,{discrete:n}){let o=r.originalEvent.target,a=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:r});t&&o.addEventListener(e,t,{once:!0}),n?Vd(o,a):o.dispatchEvent(a)}i();import*as EA from"react";var xg=0;function PA(){EA.useEffect(()=>{let e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??DA()),document.body.insertAdjacentElement("beforeend",e[1]??DA()),xg++,()=>{xg===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),xg--}},[])}function DA(){let e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.cssText="outline: none; opacity: 0; position: fixed; pointer-events: none",e}i();import*as Tr from"react";import{jsx as dne}from"react/jsx-runtime";var wg="focusScope.autoFocusOnMount",Sg="focusScope.autoFocusOnUnmount",TA={bubbles:!1,cancelable:!0},mne="FocusScope",Dg=Tr.forwardRef((e,t)=>{let{loop:r=!1,trapped:n=!1,onMountAutoFocus:o,onUnmountAutoFocus:a,...s}=e,[u,l]=Tr.useState(null),c=at(o),p=at(a),d=Tr.useRef(null),h=Ye(t,m=>l(m)),g=Tr.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;Tr.useEffect(()=>{if(n){let x=function(D){if(g.paused||!u)return;let P=D.target;u.contains(P)?d.current=P:Go(d.current,{select:!0})},w=function(D){if(g.paused||!u)return;let P=D.relatedTarget;P!==null&&(u.contains(P)||Go(d.current,{select:!0}))},S=function(D){if(document.activeElement===document.body)for(let R of D)R.removedNodes.length>0&&Go(u)};var m=x,b=w,y=S;document.addEventListener("focusin",x),document.addEventListener("focusout",w);let E=new MutationObserver(S);return u&&E.observe(u,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",x),document.removeEventListener("focusout",w),E.disconnect()}}},[n,u,g.paused]),Tr.useEffect(()=>{if(u){RA.add(g);let m=document.activeElement;if(!u.contains(m)){let y=new CustomEvent(wg,TA);u.addEventListener(wg,c),u.dispatchEvent(y),y.defaultPrevented||(hne(Cne(BA(u)),{select:!0}),document.activeElement===m&&Go(u))}return()=>{u.removeEventListener(wg,c),setTimeout(()=>{let y=new CustomEvent(Sg,TA);u.addEventListener(Sg,p),u.dispatchEvent(y),y.defaultPrevented||Go(m??document.body,{select:!0}),u.removeEventListener(Sg,p),RA.remove(g)},0)}}},[u,c,p,g]);let v=Tr.useCallback(m=>{if(!r&&!n||g.paused)return;let b=m.key==="Tab"&&!m.altKey&&!m.ctrlKey&&!m.metaKey,y=document.activeElement;if(b&&y){let x=m.currentTarget,[w,S]=gne(x);w&&S?!m.shiftKey&&y===S?(m.preventDefault(),r&&Go(w,{select:!0})):m.shiftKey&&y===w&&(m.preventDefault(),r&&Go(S,{select:!0})):y===x&&m.preventDefault()}},[r,n,g.paused]);return dne(Ue.div,{tabIndex:-1,...s,ref:h,onKeyDown:v})});Dg.displayName=mne;function hne(e,{select:t=!1}={}){let r=document.activeElement;for(let n of e)if(Go(n,{select:t}),document.activeElement!==r)return}function gne(e){let t=BA(e),r=AA(t,e),n=AA(t.reverse(),e);return[r,n]}function BA(e){let t=[],r=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:n=>{let o=n.tagName==="INPUT"&&n.type==="hidden";return n.disabled||n.hidden||o?NodeFilter.FILTER_SKIP:n.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;r.nextNode();)t.push(r.currentNode);return t}function AA(e,t){for(let r of e)if(!vne(r,{upTo:t}))return r}function vne(e,{upTo:t}){if(getComputedStyle(e).visibility==="hidden")return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display==="none")return!0;e=e.parentElement}return!1}function yne(e){return e instanceof HTMLInputElement&&"select"in e}function Go(e,{select:t=!1}={}){if(e&&e.focus){let r=document.activeElement;e.focus({preventScroll:!0}),e!==r&&yne(e)&&t&&e.select()}}var RA=bne();function bne(){let e=[];return{add(t){let r=e[0];t!==r&&r?.pause(),e=FA(e,t),e.unshift(t)},remove(t){e=FA(e,t),e[0]?.resume()}}}function FA(e,t){let r=[...e],n=r.indexOf(t);return n!==-1&&r.splice(n,1),r}function Cne(e){return e.filter(t=>t.tagName!=="A")}i();import*as Hd from"react";i();import*as OA from"react";var Ar=globalThis?.document?OA.useLayoutEffect:()=>{};var xne=Hd.useId||(()=>{}),wne=0;function jo(e){let[t,r]=Hd.useState(xne());return Ar(()=>{e||r(n=>n??String(wne++))},[e]),e||(t?`radix-${t}`:"")}i();import*as yr from"react";i();i();i();i();var MA=["top","right","bottom","left"];var Rr=Math.min,zt=Math.max,fl=Math.round,pl=Math.floor,Kn=e=>({x:e,y:e}),Sne={left:"right",right:"left",bottom:"top",top:"bottom"},Dne={start:"end",end:"start"};function jd(e,t,r){return zt(e,Rr(t,r))}function fn(e,t){return typeof e=="function"?e(t):e}function pn(e){return e.split("-")[0]}function Ii(e){return e.split("-")[1]}function _d(e){return e==="x"?"y":"x"}function Wd(e){return e==="y"?"height":"width"}function qn(e){return["top","bottom"].includes(pn(e))?"y":"x"}function Ud(e){return _d(qn(e))}function IA(e,t,r){r===void 0&&(r=!1);let n=Ii(e),o=Ud(e),a=Wd(o),s=o==="x"?n===(r?"end":"start")?"right":"left":n==="start"?"bottom":"top";return t.reference[a]>t.floating[a]&&(s=cl(s)),[s,cl(s)]}function kA(e){let t=cl(e);return[Gd(e),t,Gd(t)]}function Gd(e){return e.replace(/start|end/g,t=>Dne[t])}function Ene(e,t,r){let n=["left","right"],o=["right","left"],a=["top","bottom"],s=["bottom","top"];switch(e){case"top":case"bottom":return r?t?o:n:t?n:o;case"left":case"right":return t?a:s;default:return[]}}function NA(e,t,r,n){let o=Ii(e),a=Ene(pn(e),r==="start",n);return o&&(a=a.map(s=>s+"-"+o),t&&(a=a.concat(a.map(Gd)))),a}function cl(e){return e.replace(/left|right|bottom|top/g,t=>Sne[t])}function Pne(e){return{top:0,right:0,bottom:0,left:0,...e}}function Eg(e){return typeof e!="number"?Pne(e):{top:e,right:e,bottom:e,left:e}}function ki(e){let{x:t,y:r,width:n,height:o}=e;return{width:n,height:o,top:r,left:t,right:t+n,bottom:r+o,x:t,y:r}}function VA(e,t,r){let{reference:n,floating:o}=e,a=qn(t),s=Ud(t),u=Wd(s),l=pn(t),c=a==="y",p=n.x+n.width/2-o.width/2,d=n.y+n.height/2-o.height/2,h=n[u]/2-o[u]/2,g;switch(l){case"top":g={x:p,y:n.y-o.height};break;case"bottom":g={x:p,y:n.y+n.height};break;case"right":g={x:n.x+n.width,y:d};break;case"left":g={x:n.x-o.width,y:d};break;default:g={x:n.x,y:n.y}}switch(Ii(t)){case"start":g[s]-=h*(r&&c?-1:1);break;case"end":g[s]+=h*(r&&c?-1:1);break}return g}var zA=async(e,t,r)=>{let{placement:n="bottom",strategy:o="absolute",middleware:a=[],platform:s}=r,u=a.filter(Boolean),l=await(s.isRTL==null?void 0:s.isRTL(t)),c=await s.getElementRects({reference:e,floating:t,strategy:o}),{x:p,y:d}=VA(c,n,l),h=n,g={},v=0;for(let m=0;m<u.length;m++){let{name:b,fn:y}=u[m],{x,y:w,data:S,reset:E}=await y({x:p,y:d,initialPlacement:n,placement:h,strategy:o,middlewareData:g,rects:c,platform:s,elements:{reference:e,floating:t}});p=x??p,d=w??d,g={...g,[b]:{...g[b],...S}},E&&v<=50&&(v++,typeof E=="object"&&(E.placement&&(h=E.placement),E.rects&&(c=E.rects===!0?await s.getElementRects({reference:e,floating:t,strategy:o}):E.rects),{x:p,y:d}=VA(c,h,l)),m=-1)}return{x:p,y:d,placement:h,strategy:o,middlewareData:g}};async function Ss(e,t){var r;t===void 0&&(t={});let{x:n,y:o,platform:a,rects:s,elements:u,strategy:l}=e,{boundary:c="clippingAncestors",rootBoundary:p="viewport",elementContext:d="floating",altBoundary:h=!1,padding:g=0}=fn(t,e),v=Eg(g),b=u[h?d==="floating"?"reference":"floating":d],y=ki(await a.getClippingRect({element:(r=await(a.isElement==null?void 0:a.isElement(b)))==null||r?b:b.contextElement||await(a.getDocumentElement==null?void 0:a.getDocumentElement(u.floating)),boundary:c,rootBoundary:p,strategy:l})),x=d==="floating"?{x:n,y:o,width:s.floating.width,height:s.floating.height}:s.reference,w=await(a.getOffsetParent==null?void 0:a.getOffsetParent(u.floating)),S=await(a.isElement==null?void 0:a.isElement(w))?await(a.getScale==null?void 0:a.getScale(w))||{x:1,y:1}:{x:1,y:1},E=ki(a.convertOffsetParentRelativeRectToViewportRelativeRect?await a.convertOffsetParentRelativeRectToViewportRelativeRect({elements:u,rect:x,offsetParent:w,strategy:l}):x);return{top:(y.top-E.top+v.top)/S.y,bottom:(E.bottom-y.bottom+v.bottom)/S.y,left:(y.left-E.left+v.left)/S.x,right:(E.right-y.right+v.right)/S.x}}var HA=e=>({name:"arrow",options:e,async fn(t){let{x:r,y:n,placement:o,rects:a,platform:s,elements:u,middlewareData:l}=t,{element:c,padding:p=0}=fn(e,t)||{};if(c==null)return{};let d=Eg(p),h={x:r,y:n},g=Ud(o),v=Wd(g),m=await s.getDimensions(c),b=g==="y",y=b?"top":"left",x=b?"bottom":"right",w=b?"clientHeight":"clientWidth",S=a.reference[v]+a.reference[g]-h[g]-a.floating[v],E=h[g]-a.reference[g],D=await(s.getOffsetParent==null?void 0:s.getOffsetParent(c)),P=D?D[w]:0;(!P||!await(s.isElement==null?void 0:s.isElement(D)))&&(P=u.floating[w]||a.floating[v]);let R=S/2-E/2,F=P/2-m[v]/2-1,M=Rr(d[y],F),G=Rr(d[x],F),N=M,L=P-m[v]-G,I=P/2-m[v]/2+R,V=jd(N,I,L),Y=!l.arrow&&Ii(o)!=null&&I!==V&&a.reference[v]/2-(I<N?M:G)-m[v]/2<0,Q=Y?I<N?I-N:I-L:0;return{[g]:h[g]+Q,data:{[g]:V,centerOffset:I-V-Q,...Y&&{alignmentOffset:Q}},reset:Y}}});var GA=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var r,n;let{placement:o,middlewareData:a,rects:s,initialPlacement:u,platform:l,elements:c}=t,{mainAxis:p=!0,crossAxis:d=!0,fallbackPlacements:h,fallbackStrategy:g="bestFit",fallbackAxisSideDirection:v="none",flipAlignment:m=!0,...b}=fn(e,t);if((r=a.arrow)!=null&&r.alignmentOffset)return{};let y=pn(o),x=qn(u),w=pn(u)===u,S=await(l.isRTL==null?void 0:l.isRTL(c.floating)),E=h||(w||!m?[cl(u)]:kA(u)),D=v!=="none";!h&&D&&E.push(...NA(u,m,v,S));let P=[u,...E],R=await Ss(t,b),F=[],M=((n=a.flip)==null?void 0:n.overflows)||[];if(p&&F.push(R[y]),d){let I=IA(o,s,S);F.push(R[I[0]],R[I[1]])}if(M=[...M,{placement:o,overflows:F}],!F.every(I=>I<=0)){var G,N;let I=(((G=a.flip)==null?void 0:G.index)||0)+1,V=P[I];if(V)return{data:{index:I,overflows:M},reset:{placement:V}};let Y=(N=M.filter(Q=>Q.overflows[0]<=0).sort((Q,re)=>Q.overflows[1]-re.overflows[1])[0])==null?void 0:N.placement;if(!Y)switch(g){case"bestFit":{var L;let Q=(L=M.filter(re=>{if(D){let H=qn(re.placement);return H===x||H==="y"}return!0}).map(re=>[re.placement,re.overflows.filter(H=>H>0).reduce((H,le)=>H+le,0)]).sort((re,H)=>re[1]-H[1])[0])==null?void 0:L[0];Q&&(Y=Q);break}case"initialPlacement":Y=u;break}if(o!==Y)return{reset:{placement:Y}}}return{}}}};function LA(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function $A(e){return MA.some(t=>e[t]>=0)}var jA=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){let{rects:r}=t,{strategy:n="referenceHidden",...o}=fn(e,t);switch(n){case"referenceHidden":{let a=await Ss(t,{...o,elementContext:"reference"}),s=LA(a,r.reference);return{data:{referenceHiddenOffsets:s,referenceHidden:$A(s)}}}case"escaped":{let a=await Ss(t,{...o,altBoundary:!0}),s=LA(a,r.floating);return{data:{escapedOffsets:s,escaped:$A(s)}}}default:return{}}}}};async function Tne(e,t){let{placement:r,platform:n,elements:o}=e,a=await(n.isRTL==null?void 0:n.isRTL(o.floating)),s=pn(r),u=Ii(r),l=qn(r)==="y",c=["left","top"].includes(s)?-1:1,p=a&&l?-1:1,d=fn(t,e),{mainAxis:h,crossAxis:g,alignmentAxis:v}=typeof d=="number"?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:0,crossAxis:0,alignmentAxis:null,...d};return u&&typeof v=="number"&&(g=u==="end"?v*-1:v),l?{x:g*p,y:h*c}:{x:h*c,y:g*p}}var _A=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var r,n;let{x:o,y:a,placement:s,middlewareData:u}=t,l=await Tne(t,e);return s===((r=u.offset)==null?void 0:r.placement)&&(n=u.arrow)!=null&&n.alignmentOffset?{}:{x:o+l.x,y:a+l.y,data:{...l,placement:s}}}}},WA=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){let{x:r,y:n,placement:o}=t,{mainAxis:a=!0,crossAxis:s=!1,limiter:u={fn:b=>{let{x:y,y:x}=b;return{x:y,y:x}}},...l}=fn(e,t),c={x:r,y:n},p=await Ss(t,l),d=qn(pn(o)),h=_d(d),g=c[h],v=c[d];if(a){let b=h==="y"?"top":"left",y=h==="y"?"bottom":"right",x=g+p[b],w=g-p[y];g=jd(x,g,w)}if(s){let b=d==="y"?"top":"left",y=d==="y"?"bottom":"right",x=v+p[b],w=v-p[y];v=jd(x,v,w)}let m=u.fn({...t,[h]:g,[d]:v});return{...m,data:{x:m.x-r,y:m.y-n}}}}},UA=function(e){return e===void 0&&(e={}),{options:e,fn(t){let{x:r,y:n,placement:o,rects:a,middlewareData:s}=t,{offset:u=0,mainAxis:l=!0,crossAxis:c=!0}=fn(e,t),p={x:r,y:n},d=qn(o),h=_d(d),g=p[h],v=p[d],m=fn(u,t),b=typeof m=="number"?{mainAxis:m,crossAxis:0}:{mainAxis:0,crossAxis:0,...m};if(l){let w=h==="y"?"height":"width",S=a.reference[h]-a.floating[w]+b.mainAxis,E=a.reference[h]+a.reference[w]-b.mainAxis;g<S?g=S:g>E&&(g=E)}if(c){var y,x;let w=h==="y"?"width":"height",S=["top","left"].includes(pn(o)),E=a.reference[d]-a.floating[w]+(S&&((y=s.offset)==null?void 0:y[d])||0)+(S?0:b.crossAxis),D=a.reference[d]+a.reference[w]+(S?0:((x=s.offset)==null?void 0:x[d])||0)-(S?b.crossAxis:0);v<E?v=E:v>D&&(v=D)}return{[h]:g,[d]:v}}}},KA=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){let{placement:r,rects:n,platform:o,elements:a}=t,{apply:s=()=>{},...u}=fn(e,t),l=await Ss(t,u),c=pn(r),p=Ii(r),d=qn(r)==="y",{width:h,height:g}=n.floating,v,m;c==="top"||c==="bottom"?(v=c,m=p===(await(o.isRTL==null?void 0:o.isRTL(a.floating))?"start":"end")?"left":"right"):(m=c,v=p==="end"?"top":"bottom");let b=g-l.top-l.bottom,y=h-l.left-l.right,x=Rr(g-l[v],b),w=Rr(h-l[m],y),S=!t.middlewareData.shift,E=x,D=w;if(d?D=p||S?Rr(w,y):y:E=p||S?Rr(x,b):b,S&&!p){let R=zt(l.left,0),F=zt(l.right,0),M=zt(l.top,0),G=zt(l.bottom,0);d?D=h-2*(R!==0||F!==0?R+F:zt(l.left,l.right)):E=g-2*(M!==0||G!==0?M+G:zt(l.top,l.bottom))}await s({...t,availableWidth:D,availableHeight:E});let P=await o.getDimensions(a.floating);return h!==P.width||g!==P.height?{reset:{rects:!0}}:{}}}};i();function Vi(e){return XA(e)?(e.nodeName||"").toLowerCase():"#document"}function tr(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function dn(e){var t;return(t=(XA(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function XA(e){return e instanceof Node||e instanceof tr(e).Node}function Fr(e){return e instanceof Element||e instanceof tr(e).Element}function _r(e){return e instanceof HTMLElement||e instanceof tr(e).HTMLElement}function qA(e){return typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof tr(e).ShadowRoot}function Ds(e){let{overflow:t,overflowX:r,overflowY:n,display:o}=Br(e);return/auto|scroll|overlay|hidden|clip/.test(t+n+r)&&!["inline","contents"].includes(o)}function YA(e){return["table","td","th"].includes(Vi(e))}function dl(e){return[":popover-open",":modal"].some(t=>{try{return e.matches(t)}catch{return!1}})}function Kd(e){let t=qd(),r=Fr(e)?Br(e):e;return r.transform!=="none"||r.perspective!=="none"||(r.containerType?r.containerType!=="normal":!1)||!t&&(r.backdropFilter?r.backdropFilter!=="none":!1)||!t&&(r.filter?r.filter!=="none":!1)||["transform","perspective","filter"].some(n=>(r.willChange||"").includes(n))||["paint","layout","strict","content"].some(n=>(r.contain||"").includes(n))}function JA(e){let t=Xn(e);for(;_r(t)&&!Li(t);){if(Kd(t))return t;if(dl(t))return null;t=Xn(t)}return null}function qd(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function Li(e){return["html","body","#document"].includes(Vi(e))}function Br(e){return tr(e).getComputedStyle(e)}function ml(e){return Fr(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Xn(e){if(Vi(e)==="html")return e;let t=e.assignedSlot||e.parentNode||qA(e)&&e.host||dn(e);return qA(t)?t.host:t}function ZA(e){let t=Xn(e);return Li(t)?e.ownerDocument?e.ownerDocument.body:e.body:_r(t)&&Ds(t)?t:ZA(t)}function Ni(e,t,r){var n;t===void 0&&(t=[]),r===void 0&&(r=!0);let o=ZA(e),a=o===((n=e.ownerDocument)==null?void 0:n.body),s=tr(o);return a?t.concat(s,s.visualViewport||[],Ds(o)?o:[],s.frameElement&&r?Ni(s.frameElement):[]):t.concat(o,Ni(o,[],r))}function tR(e){let t=Br(e),r=parseFloat(t.width)||0,n=parseFloat(t.height)||0,o=_r(e),a=o?e.offsetWidth:r,s=o?e.offsetHeight:n,u=fl(r)!==a||fl(n)!==s;return u&&(r=a,n=s),{width:r,height:n,$:u}}function Tg(e){return Fr(e)?e:e.contextElement}function Es(e){let t=Tg(e);if(!_r(t))return Kn(1);let r=t.getBoundingClientRect(),{width:n,height:o,$:a}=tR(t),s=(a?fl(r.width):r.width)/n,u=(a?fl(r.height):r.height)/o;return(!s||!Number.isFinite(s))&&(s=1),(!u||!Number.isFinite(u))&&(u=1),{x:s,y:u}}var Ane=Kn(0);function rR(e){let t=tr(e);return!qd()||!t.visualViewport?Ane:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function Rne(e,t,r){return t===void 0&&(t=!1),!r||t&&r!==tr(e)?!1:t}function $i(e,t,r,n){t===void 0&&(t=!1),r===void 0&&(r=!1);let o=e.getBoundingClientRect(),a=Tg(e),s=Kn(1);t&&(n?Fr(n)&&(s=Es(n)):s=Es(e));let u=Rne(a,r,n)?rR(a):Kn(0),l=(o.left+u.x)/s.x,c=(o.top+u.y)/s.y,p=o.width/s.x,d=o.height/s.y;if(a){let h=tr(a),g=n&&Fr(n)?tr(n):n,v=h,m=v.frameElement;for(;m&&n&&g!==v;){let b=Es(m),y=m.getBoundingClientRect(),x=Br(m),w=y.left+(m.clientLeft+parseFloat(x.paddingLeft))*b.x,S=y.top+(m.clientTop+parseFloat(x.paddingTop))*b.y;l*=b.x,c*=b.y,p*=b.x,d*=b.y,l+=w,c+=S,v=tr(m),m=v.frameElement}}return ki({width:p,height:d,x:l,y:c})}function Fne(e){let{elements:t,rect:r,offsetParent:n,strategy:o}=e,a=o==="fixed",s=dn(n),u=t?dl(t.floating):!1;if(n===s||u&&a)return r;let l={scrollLeft:0,scrollTop:0},c=Kn(1),p=Kn(0),d=_r(n);if((d||!d&&!a)&&((Vi(n)!=="body"||Ds(s))&&(l=ml(n)),_r(n))){let h=$i(n);c=Es(n),p.x=h.x+n.clientLeft,p.y=h.y+n.clientTop}return{width:r.width*c.x,height:r.height*c.y,x:r.x*c.x-l.scrollLeft*c.x+p.x,y:r.y*c.y-l.scrollTop*c.y+p.y}}function Bne(e){return Array.from(e.getClientRects())}function nR(e){return $i(dn(e)).left+ml(e).scrollLeft}function One(e){let t=dn(e),r=ml(e),n=e.ownerDocument.body,o=zt(t.scrollWidth,t.clientWidth,n.scrollWidth,n.clientWidth),a=zt(t.scrollHeight,t.clientHeight,n.scrollHeight,n.clientHeight),s=-r.scrollLeft+nR(e),u=-r.scrollTop;return Br(n).direction==="rtl"&&(s+=zt(t.clientWidth,n.clientWidth)-o),{width:o,height:a,x:s,y:u}}function Mne(e,t){let r=tr(e),n=dn(e),o=r.visualViewport,a=n.clientWidth,s=n.clientHeight,u=0,l=0;if(o){a=o.width,s=o.height;let c=qd();(!c||c&&t==="fixed")&&(u=o.offsetLeft,l=o.offsetTop)}return{width:a,height:s,x:u,y:l}}function Ine(e,t){let r=$i(e,!0,t==="fixed"),n=r.top+e.clientTop,o=r.left+e.clientLeft,a=_r(e)?Es(e):Kn(1),s=e.clientWidth*a.x,u=e.clientHeight*a.y,l=o*a.x,c=n*a.y;return{width:s,height:u,x:l,y:c}}function QA(e,t,r){let n;if(t==="viewport")n=Mne(e,r);else if(t==="document")n=One(dn(e));else if(Fr(t))n=Ine(t,r);else{let o=rR(e);n={...t,x:t.x-o.x,y:t.y-o.y}}return ki(n)}function oR(e,t){let r=Xn(e);return r===t||!Fr(r)||Li(r)?!1:Br(r).position==="fixed"||oR(r,t)}function kne(e,t){let r=t.get(e);if(r)return r;let n=Ni(e,[],!1).filter(u=>Fr(u)&&Vi(u)!=="body"),o=null,a=Br(e).position==="fixed",s=a?Xn(e):e;for(;Fr(s)&&!Li(s);){let u=Br(s),l=Kd(s);!l&&u.position==="fixed"&&(o=null),(a?!l&&!o:!l&&u.position==="static"&&!!o&&["absolute","fixed"].includes(o.position)||Ds(s)&&!l&&oR(e,s))?n=n.filter(p=>p!==s):o=u,s=Xn(s)}return t.set(e,n),n}function Nne(e){let{element:t,boundary:r,rootBoundary:n,strategy:o}=e,s=[...r==="clippingAncestors"?dl(t)?[]:kne(t,this._c):[].concat(r),n],u=s[0],l=s.reduce((c,p)=>{let d=QA(t,p,o);return c.top=zt(d.top,c.top),c.right=Rr(d.right,c.right),c.bottom=Rr(d.bottom,c.bottom),c.left=zt(d.left,c.left),c},QA(t,u,o));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}}function Vne(e){let{width:t,height:r}=tR(e);return{width:t,height:r}}function Lne(e,t,r){let n=_r(t),o=dn(t),a=r==="fixed",s=$i(e,!0,a,t),u={scrollLeft:0,scrollTop:0},l=Kn(0);if(n||!n&&!a)if((Vi(t)!=="body"||Ds(o))&&(u=ml(t)),n){let d=$i(t,!0,a,t);l.x=d.x+t.clientLeft,l.y=d.y+t.clientTop}else o&&(l.x=nR(o));let c=s.left+u.scrollLeft-l.x,p=s.top+u.scrollTop-l.y;return{x:c,y:p,width:s.width,height:s.height}}function Pg(e){return Br(e).position==="static"}function eR(e,t){return!_r(e)||Br(e).position==="fixed"?null:t?t(e):e.offsetParent}function iR(e,t){let r=tr(e);if(dl(e))return r;if(!_r(e)){let o=Xn(e);for(;o&&!Li(o);){if(Fr(o)&&!Pg(o))return o;o=Xn(o)}return r}let n=eR(e,t);for(;n&&YA(n)&&Pg(n);)n=eR(n,t);return n&&Li(n)&&Pg(n)&&!Kd(n)?r:n||JA(e)||r}var $ne=async function(e){let t=this.getOffsetParent||iR,r=this.getDimensions,n=await r(e.floating);return{reference:Lne(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:n.width,height:n.height}}};function zne(e){return Br(e).direction==="rtl"}var aR={convertOffsetParentRelativeRectToViewportRelativeRect:Fne,getDocumentElement:dn,getClippingRect:Nne,getOffsetParent:iR,getElementRects:$ne,getClientRects:Bne,getDimensions:Vne,getScale:Es,isElement:Fr,isRTL:zne};function Hne(e,t){let r=null,n,o=dn(e);function a(){var u;clearTimeout(n),(u=r)==null||u.disconnect(),r=null}function s(u,l){u===void 0&&(u=!1),l===void 0&&(l=1),a();let{left:c,top:p,width:d,height:h}=e.getBoundingClientRect();if(u||t(),!d||!h)return;let g=pl(p),v=pl(o.clientWidth-(c+d)),m=pl(o.clientHeight-(p+h)),b=pl(c),x={rootMargin:-g+"px "+-v+"px "+-m+"px "+-b+"px",threshold:zt(0,Rr(1,l))||1},w=!0;function S(E){let D=E[0].intersectionRatio;if(D!==l){if(!w)return s();D?s(!1,D):n=setTimeout(()=>{s(!1,1e-7)},1e3)}w=!1}try{r=new IntersectionObserver(S,{...x,root:o.ownerDocument})}catch{r=new IntersectionObserver(S,x)}r.observe(e)}return s(!0),a}function Ag(e,t,r,n){n===void 0&&(n={});let{ancestorScroll:o=!0,ancestorResize:a=!0,elementResize:s=typeof ResizeObserver=="function",layoutShift:u=typeof IntersectionObserver=="function",animationFrame:l=!1}=n,c=Tg(e),p=o||a?[...c?Ni(c):[],...Ni(t)]:[];p.forEach(y=>{o&&y.addEventListener("scroll",r,{passive:!0}),a&&y.addEventListener("resize",r)});let d=c&&u?Hne(c,r):null,h=-1,g=null;s&&(g=new ResizeObserver(y=>{let[x]=y;x&&x.target===c&&g&&(g.unobserve(t),cancelAnimationFrame(h),h=requestAnimationFrame(()=>{var w;(w=g)==null||w.observe(t)})),r()}),c&&!l&&g.observe(c),g.observe(t));let v,m=l?$i(e):null;l&&b();function b(){let y=$i(e);m&&(y.x!==m.x||y.y!==m.y||y.width!==m.width||y.height!==m.height)&&r(),m=y,v=requestAnimationFrame(b)}return r(),()=>{var y;p.forEach(x=>{o&&x.removeEventListener("scroll",r),a&&x.removeEventListener("resize",r)}),d?.(),(y=g)==null||y.disconnect(),g=null,l&&cancelAnimationFrame(v)}}var sR=_A;var uR=WA,lR=GA,cR=KA,fR=jA,Rg=HA;var pR=UA,Fg=(e,t,r)=>{let n=new Map,o={platform:aR,...r},a={...o.platform,_c:n};return zA(e,t,{...o,platform:a})};import*as nt from"react";import{useLayoutEffect as Gne,useEffect as jne}from"react";import*as hR from"react-dom";var Xd=typeof document<"u"?Gne:jne;function Yd(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 r,n,o;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(r=e.length,r!==t.length)return!1;for(n=r;n--!==0;)if(!Yd(e[n],t[n]))return!1;return!0}if(o=Object.keys(e),r=o.length,r!==Object.keys(t).length)return!1;for(n=r;n--!==0;)if(!{}.hasOwnProperty.call(t,o[n]))return!1;for(n=r;n--!==0;){let a=o[n];if(!(a==="_owner"&&e.$$typeof)&&!Yd(e[a],t[a]))return!1}return!0}return e!==e&&t!==t}function gR(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function dR(e,t){let r=gR(e);return Math.round(t*r)/r}function mR(e){let t=nt.useRef(e);return Xd(()=>{t.current=e}),t}function vR(e){e===void 0&&(e={});let{placement:t="bottom",strategy:r="absolute",middleware:n=[],platform:o,elements:{reference:a,floating:s}={},transform:u=!0,whileElementsMounted:l,open:c}=e,[p,d]=nt.useState({x:0,y:0,strategy:r,placement:t,middlewareData:{},isPositioned:!1}),[h,g]=nt.useState(n);Yd(h,n)||g(n);let[v,m]=nt.useState(null),[b,y]=nt.useState(null),x=nt.useCallback(Q=>{Q!==D.current&&(D.current=Q,m(Q))},[]),w=nt.useCallback(Q=>{Q!==P.current&&(P.current=Q,y(Q))},[]),S=a||v,E=s||b,D=nt.useRef(null),P=nt.useRef(null),R=nt.useRef(p),F=l!=null,M=mR(l),G=mR(o),N=nt.useCallback(()=>{if(!D.current||!P.current)return;let Q={placement:t,strategy:r,middleware:h};G.current&&(Q.platform=G.current),Fg(D.current,P.current,Q).then(re=>{let H={...re,isPositioned:!0};L.current&&!Yd(R.current,H)&&(R.current=H,hR.flushSync(()=>{d(H)}))})},[h,t,r,G]);Xd(()=>{c===!1&&R.current.isPositioned&&(R.current.isPositioned=!1,d(Q=>({...Q,isPositioned:!1})))},[c]);let L=nt.useRef(!1);Xd(()=>(L.current=!0,()=>{L.current=!1}),[]),Xd(()=>{if(S&&(D.current=S),E&&(P.current=E),S&&E){if(M.current)return M.current(S,E,N);N()}},[S,E,N,M,F]);let I=nt.useMemo(()=>({reference:D,floating:P,setReference:x,setFloating:w}),[x,w]),V=nt.useMemo(()=>({reference:S,floating:E}),[S,E]),Y=nt.useMemo(()=>{let Q={position:r,left:0,top:0};if(!V.floating)return Q;let re=dR(V.floating,p.x),H=dR(V.floating,p.y);return u?{...Q,transform:"translate("+re+"px, "+H+"px)",...gR(V.floating)>=1.5&&{willChange:"transform"}}:{position:r,left:re,top:H}},[r,u,V.floating,p.x,p.y]);return nt.useMemo(()=>({...p,update:N,refs:I,elements:V,floatingStyles:Y}),[p,N,I,V,Y])}var _ne=e=>{function t(r){return{}.hasOwnProperty.call(r,"current")}return{name:"arrow",options:e,fn(r){let{element:n,padding:o}=typeof e=="function"?e(r):e;return n&&t(n)?n.current!=null?Rg({element:n.current,padding:o}).fn(r):{}:n?Rg({element:n,padding:o}).fn(r):{}}}},yR=(e,t)=>({...sR(e),options:[e,t]}),bR=(e,t)=>({...uR(e),options:[e,t]}),CR=(e,t)=>({...pR(e),options:[e,t]}),xR=(e,t)=>({...lR(e),options:[e,t]}),wR=(e,t)=>({...cR(e),options:[e,t]});var SR=(e,t)=>({...fR(e),options:[e,t]});var DR=(e,t)=>({..._ne(e),options:[e,t]});i();import*as PR from"react";import{jsx as ER}from"react/jsx-runtime";var Wne="Arrow",TR=PR.forwardRef((e,t)=>{let{children:r,width:n=10,height:o=5,...a}=e;return ER(Ue.svg,{...a,ref:t,width:n,height:o,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?r:ER("polygon",{points:"0,0 30,0 15,10"})})});TR.displayName=Wne;var AR=TR;i();import*as RR from"react";function FR(e){let[t,r]=RR.useState(void 0);return Ar(()=>{if(e){r({width:e.offsetWidth,height:e.offsetHeight});let n=new ResizeObserver(o=>{if(!Array.isArray(o)||!o.length)return;let a=o[0],s,u;if("borderBoxSize"in a){let l=a.borderBoxSize,c=Array.isArray(l)?l[0]:l;s=c.inlineSize,u=c.blockSize}else s=e.offsetWidth,u=e.offsetHeight;r({width:s,height:u})});return n.observe(e,{box:"border-box"}),()=>n.unobserve(e)}else r(void 0)},[e]),t}import{jsx as zi}from"react/jsx-runtime";var Bg="Popper",[BR,Og]=cn(Bg),[Kne,OR]=BR(Bg),MR=e=>{let{__scopePopper:t,children:r}=e,[n,o]=yr.useState(null);return zi(Kne,{scope:t,anchor:n,onAnchorChange:o,children:r})};MR.displayName=Bg;var IR="PopperAnchor",kR=yr.forwardRef((e,t)=>{let{__scopePopper:r,virtualRef:n,...o}=e,a=OR(IR,r),s=yr.useRef(null),u=Ye(t,s);return yr.useEffect(()=>{a.onAnchorChange(n?.current||s.current)}),n?null:zi(Ue.div,{...o,ref:u})});kR.displayName=IR;var Mg="PopperContent",[qne,Xne]=BR(Mg),NR=yr.forwardRef((e,t)=>{let{__scopePopper:r,side:n="bottom",sideOffset:o=0,align:a="center",alignOffset:s=0,arrowPadding:u=0,avoidCollisions:l=!0,collisionBoundary:c=[],collisionPadding:p=0,sticky:d="partial",hideWhenDetached:h=!1,updatePositionStrategy:g="optimized",onPlaced:v,...m}=e,b=OR(Mg,r),[y,x]=yr.useState(null),w=Ye(t,j=>x(j)),[S,E]=yr.useState(null),D=FR(S),P=D?.width??0,R=D?.height??0,F=n+(a!=="center"?"-"+a:""),M=typeof p=="number"?p:{top:0,right:0,bottom:0,left:0,...p},G=Array.isArray(c)?c:[c],N=G.length>0,L={padding:M,boundary:G.filter(Jne),altBoundary:N},{refs:I,floatingStyles:V,placement:Y,isPositioned:Q,middlewareData:re}=vR({strategy:"fixed",placement:F,whileElementsMounted:(...j)=>Ag(...j,{animationFrame:g==="always"}),elements:{reference:b.anchor},middleware:[yR({mainAxis:o+R,alignmentAxis:s}),l&&bR({mainAxis:!0,crossAxis:!1,limiter:d==="partial"?CR():void 0,...L}),l&&xR({...L}),wR({...L,apply:({elements:j,rects:ue,availableWidth:oe,availableHeight:he})=>{let{width:Ce,height:Se}=ue.reference,Ee=j.floating.style;Ee.setProperty("--radix-popper-available-width",`${oe}px`),Ee.setProperty("--radix-popper-available-height",`${he}px`),Ee.setProperty("--radix-popper-anchor-width",`${Ce}px`),Ee.setProperty("--radix-popper-anchor-height",`${Se}px`)}}),S&&DR({element:S,padding:u}),Zne({arrowWidth:P,arrowHeight:R}),h&&SR({strategy:"referenceHidden",...L})]}),[H,le]=$R(Y),ve=at(v);Ar(()=>{Q&&ve?.()},[Q,ve]);let me=re.arrow?.x,Ge=re.arrow?.y,A=re.arrow?.centerOffset!==0,[_,z]=yr.useState();return Ar(()=>{y&&z(window.getComputedStyle(y).zIndex)},[y]),zi("div",{ref:I.setFloating,"data-radix-popper-content-wrapper":"",style:{...V,transform:Q?V.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:_,"--radix-popper-transform-origin":[re.transformOrigin?.x,re.transformOrigin?.y].join(" "),...re.hide?.referenceHidden&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:zi(qne,{scope:r,placedSide:H,onArrowChange:E,arrowX:me,arrowY:Ge,shouldHideArrow:A,children:zi(Ue.div,{"data-side":H,"data-align":le,...m,ref:w,style:{...m.style,animation:Q?void 0:"none"}})})})});NR.displayName=Mg;var VR="PopperArrow",Yne={top:"bottom",right:"left",bottom:"top",left:"right"},LR=yr.forwardRef(function(t,r){let{__scopePopper:n,...o}=t,a=Xne(VR,n),s=Yne[a.placedSide];return zi("span",{ref:a.onArrowChange,style:{position:"absolute",left:a.arrowX,top:a.arrowY,[s]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[a.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[a.placedSide],visibility:a.shouldHideArrow?"hidden":void 0},children:zi(AR,{...o,ref:r,style:{...o.style,display:"block"}})})});LR.displayName=VR;function Jne(e){return e!==null}var Zne=e=>({name:"transformOrigin",options:e,fn(t){let{placement:r,rects:n,middlewareData:o}=t,s=o.arrow?.centerOffset!==0,u=s?0:e.arrowWidth,l=s?0:e.arrowHeight,[c,p]=$R(r),d={start:"0%",center:"50%",end:"100%"}[p],h=(o.arrow?.x??0)+u/2,g=(o.arrow?.y??0)+l/2,v="",m="";return c==="bottom"?(v=s?d:`${h}px`,m=`${-l}px`):c==="top"?(v=s?d:`${h}px`,m=`${n.floating.height+l}px`):c==="right"?(v=`${-l}px`,m=s?d:`${g}px`):c==="left"&&(v=`${n.floating.width+l}px`,m=s?d:`${g}px`),{data:{x:v,y:m}}}});function $R(e){let[t,r="center"]=e.split("-");return[t,r]}var Ig=MR,zR=kR,HR=NR,GR=LR;i();import*as Jd from"react";import eoe from"react-dom";import{jsx as toe}from"react/jsx-runtime";var roe="Portal",kg=Jd.forwardRef((e,t)=>{let{container:r,...n}=e,[o,a]=Jd.useState(!1);Ar(()=>a(!0),[]);let s=r||o&&globalThis?.document?.body;return s?eoe.createPortal(toe(Ue.div,{...n,ref:t}),s):null});kg.displayName=roe;i();import*as rr from"react";import*as jR from"react-dom";import*as _R from"react";function noe(e,t){return _R.useReducer((r,n)=>t[r][n]??r,e)}var Ps=e=>{let{present:t,children:r}=e,n=ooe(t),o=typeof r=="function"?r({present:n.isPresent}):rr.Children.only(r),a=Ye(n.ref,ioe(o));return typeof r=="function"||n.isPresent?rr.cloneElement(o,{ref:a}):null};Ps.displayName="Presence";function ooe(e){let[t,r]=rr.useState(),n=rr.useRef({}),o=rr.useRef(e),a=rr.useRef("none"),s=e?"mounted":"unmounted",[u,l]=noe(s,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return rr.useEffect(()=>{let c=Zd(n.current);a.current=u==="mounted"?c:"none"},[u]),Ar(()=>{let c=n.current,p=o.current;if(p!==e){let h=a.current,g=Zd(c);e?l("MOUNT"):g==="none"||c?.display==="none"?l("UNMOUNT"):l(p&&h!==g?"ANIMATION_OUT":"UNMOUNT"),o.current=e}},[e,l]),Ar(()=>{if(t){let c=d=>{let g=Zd(n.current).includes(d.animationName);d.target===t&&g&&jR.flushSync(()=>l("ANIMATION_END"))},p=d=>{d.target===t&&(a.current=Zd(n.current))};return t.addEventListener("animationstart",p),t.addEventListener("animationcancel",c),t.addEventListener("animationend",c),()=>{t.removeEventListener("animationstart",p),t.removeEventListener("animationcancel",c),t.removeEventListener("animationend",c)}}else l("ANIMATION_END")},[t,l]),{isPresent:["mounted","unmountSuspended"].includes(u),ref:rr.useCallback(c=>{c&&(n.current=getComputedStyle(c)),r(c)},[])}}function Zd(e){return e?.animationName||"none"}function ioe(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,r=t&&"isReactWarning"in t&&t.isReactWarning;return r?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,r=t&&"isReactWarning"in t&&t.isReactWarning,r?e.props.ref:e.props.ref||e.ref)}i();import*as dt from"react";import{jsx as Hi}from"react/jsx-runtime";var Ng="rovingFocusGroup.onEntryFocus",aoe={bubbles:!1,cancelable:!0},Qd="RovingFocusGroup",[Vg,WR,soe]=Ld(Qd),[uoe,Lg]=cn(Qd,[soe]),[loe,coe]=uoe(Qd),UR=dt.forwardRef((e,t)=>Hi(Vg.Provider,{scope:e.__scopeRovingFocusGroup,children:Hi(Vg.Slot,{scope:e.__scopeRovingFocusGroup,children:Hi(foe,{...e,ref:t})})}));UR.displayName=Qd;var foe=dt.forwardRef((e,t)=>{let{__scopeRovingFocusGroup:r,orientation:n,loop:o=!1,dir:a,currentTabStopId:s,defaultCurrentTabStopId:u,onCurrentTabStopIdChange:l,onEntryFocus:c,preventScrollOnEntryFocus:p=!1,...d}=e,h=dt.useRef(null),g=Ye(t,h),v=zd(a),[m=null,b]=ll({prop:s,defaultProp:u,onChange:l}),[y,x]=dt.useState(!1),w=at(c),S=WR(r),E=dt.useRef(!1),[D,P]=dt.useState(0);return dt.useEffect(()=>{let R=h.current;if(R)return R.addEventListener(Ng,w),()=>R.removeEventListener(Ng,w)},[w]),Hi(loe,{scope:r,orientation:n,dir:v,loop:o,currentTabStopId:m,onItemFocus:dt.useCallback(R=>b(R),[b]),onItemShiftTab:dt.useCallback(()=>x(!0),[]),onFocusableItemAdd:dt.useCallback(()=>P(R=>R+1),[]),onFocusableItemRemove:dt.useCallback(()=>P(R=>R-1),[]),children:Hi(Ue.div,{tabIndex:y||D===0?-1:0,"data-orientation":n,...d,ref:g,style:{outline:"none",...e.style},onMouseDown:ye(e.onMouseDown,()=>{E.current=!0}),onFocus:ye(e.onFocus,R=>{let F=!E.current;if(R.target===R.currentTarget&&F&&!y){let M=new CustomEvent(Ng,aoe);if(R.currentTarget.dispatchEvent(M),!M.defaultPrevented){let G=S().filter(Y=>Y.focusable),N=G.find(Y=>Y.active),L=G.find(Y=>Y.id===m),V=[N,L,...G].filter(Boolean).map(Y=>Y.ref.current);XR(V,p)}}E.current=!1}),onBlur:ye(e.onBlur,()=>x(!1))})})}),KR="RovingFocusGroupItem",qR=dt.forwardRef((e,t)=>{let{__scopeRovingFocusGroup:r,focusable:n=!0,active:o=!1,tabStopId:a,...s}=e,u=jo(),l=a||u,c=coe(KR,r),p=c.currentTabStopId===l,d=WR(r),{onFocusableItemAdd:h,onFocusableItemRemove:g}=c;return dt.useEffect(()=>{if(n)return h(),()=>g()},[n,h,g]),Hi(Vg.ItemSlot,{scope:r,id:l,focusable:n,active:o,children:Hi(Ue.span,{tabIndex:p?0:-1,"data-orientation":c.orientation,...s,ref:t,onMouseDown:ye(e.onMouseDown,v=>{n?c.onItemFocus(l):v.preventDefault()}),onFocus:ye(e.onFocus,()=>c.onItemFocus(l)),onKeyDown:ye(e.onKeyDown,v=>{if(v.key==="Tab"&&v.shiftKey){c.onItemShiftTab();return}if(v.target!==v.currentTarget)return;let m=moe(v,c.orientation,c.dir);if(m!==void 0){if(v.metaKey||v.ctrlKey||v.altKey||v.shiftKey)return;v.preventDefault();let y=d().filter(x=>x.focusable).map(x=>x.ref.current);if(m==="last")y.reverse();else if(m==="prev"||m==="next"){m==="prev"&&y.reverse();let x=y.indexOf(v.currentTarget);y=c.loop?hoe(y,x+1):y.slice(x+1)}setTimeout(()=>XR(y))}})})})});qR.displayName=KR;var poe={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function doe(e,t){return t!=="rtl"?e:e==="ArrowLeft"?"ArrowRight":e==="ArrowRight"?"ArrowLeft":e}function moe(e,t,r){let n=doe(e.key,r);if(!(t==="vertical"&&["ArrowLeft","ArrowRight"].includes(n))&&!(t==="horizontal"&&["ArrowUp","ArrowDown"].includes(n)))return poe[n]}function XR(e,t=!1){let r=document.activeElement;for(let n of e)if(n===r||(n.focus({preventScroll:t}),document.activeElement!==r))return}function hoe(e,t){return e.map((r,n)=>e[(t+n)%e.length])}var YR=UR,JR=qR;i();var voe=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},Ts=new WeakMap,e1=new WeakMap,t1={},$g=0,ZR=function(e){return e&&(e.host||ZR(e.parentNode))},yoe=function(e,t){return t.map(function(r){if(e.contains(r))return r;var n=ZR(r);return n&&e.contains(n)?n:(console.error("aria-hidden",r,"in not contained inside",e,". Doing nothing"),null)}).filter(function(r){return!!r})},boe=function(e,t,r,n){var o=yoe(t,Array.isArray(e)?e:[e]);t1[r]||(t1[r]=new WeakMap);var a=t1[r],s=[],u=new Set,l=new Set(o),c=function(d){!d||u.has(d)||(u.add(d),c(d.parentNode))};o.forEach(c);var p=function(d){!d||l.has(d)||Array.prototype.forEach.call(d.children,function(h){if(u.has(h))p(h);else try{var g=h.getAttribute(n),v=g!==null&&g!=="false",m=(Ts.get(h)||0)+1,b=(a.get(h)||0)+1;Ts.set(h,m),a.set(h,b),s.push(h),m===1&&v&&e1.set(h,!0),b===1&&h.setAttribute(r,"true"),v||h.setAttribute(n,"true")}catch(y){console.error("aria-hidden: cannot operate on ",h,y)}})};return p(t),u.clear(),$g++,function(){s.forEach(function(d){var h=Ts.get(d)-1,g=a.get(d)-1;Ts.set(d,h),a.set(d,g),h||(e1.has(d)||d.removeAttribute(n),e1.delete(d)),g||d.removeAttribute(r)}),$g--,$g||(Ts=new WeakMap,Ts=new WeakMap,e1=new WeakMap,t1={})}},QR=function(e,t,r){r===void 0&&(r="data-aria-hidden");var n=Array.from(Array.isArray(e)?e:[e]),o=t||voe(e);return o?(n.push.apply(n,Array.from(o.querySelectorAll("[aria-live]"))),boe(n,o,r,"aria-hidden")):function(){return null}};i();i();i();var mn=function(){return mn=Object.assign||function(t){for(var r,n=1,o=arguments.length;n<o;n++){r=arguments[n];for(var a in r)Object.prototype.hasOwnProperty.call(r,a)&&(t[a]=r[a])}return t},mn.apply(this,arguments)};function eF(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]]);return r}function tF(e,t,r){if(r||arguments.length===2)for(var n=0,o=t.length,a;n<o;n++)(a||!(n in t))&&(a||(a=Array.prototype.slice.call(t,0,n)),a[n]=t[n]);return e.concat(a||Array.prototype.slice.call(t))}import*as a1 from"react";i();import*as Rt from"react";i();var Gi="right-scroll-bar-position",ji="width-before-scroll-bar",zg="with-scroll-bars-hidden",Hg="--removed-body-scroll-bar-size";i();i();function r1(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}i();import{useState as Coe}from"react";function rF(e,t){var r=Coe(function(){return{value:e,callback:t,facade:{get current(){return r.value},set current(n){var o=r.value;o!==n&&(r.value=n,r.callback(n,o))}}}})[0];return r.callback=t,r.facade}i();import*as n1 from"react";var xoe=typeof window<"u"?n1.useLayoutEffect:n1.useEffect,nF=new WeakMap;function Gg(e,t){var r=rF(t||null,function(n){return e.forEach(function(o){return r1(o,n)})});return xoe(function(){var n=nF.get(r);if(n){var o=new Set(n),a=new Set(e),s=r.current;o.forEach(function(u){a.has(u)||r1(u,null)}),a.forEach(function(u){o.has(u)||r1(u,s)})}nF.set(r,e)},[e]),r}i();i();i();var As=function(){return As=Object.assign||function(t){for(var r,n=1,o=arguments.length;n<o;n++){r=arguments[n];for(var a in r)Object.prototype.hasOwnProperty.call(r,a)&&(t[a]=r[a])}return t},As.apply(this,arguments)};function oF(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]]);return r}i();function woe(e){return e}function Soe(e,t){t===void 0&&(t=woe);var r=[],n=!1,o={read:function(){if(n)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return r.length?r[r.length-1]:e},useMedium:function(a){var s=t(a,n);return r.push(s),function(){r=r.filter(function(u){return u!==s})}},assignSyncMedium:function(a){for(n=!0;r.length;){var s=r;r=[],s.forEach(a)}r={push:function(u){return a(u)},filter:function(){return r}}},assignMedium:function(a){n=!0;var s=[];if(r.length){var u=r;r=[],u.forEach(a),s=r}var l=function(){var p=s;s=[],p.forEach(a)},c=function(){return Promise.resolve().then(l)};c(),r={push:function(p){s.push(p),c()},filter:function(p){return s=s.filter(p),r}}}};return o}function jg(e){e===void 0&&(e={});var t=Soe(null);return t.options=As({async:!0,ssr:!1},e),t}i();import*as iF from"react";var aF=function(e){var t=e.sideCar,r=oF(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var n=t.read();if(!n)throw new Error("Sidecar medium not found");return iF.createElement(n,As({},r))};aF.isSideCarExport=!0;function _g(e,t){return e.useMedium(t),aF}var o1=jg();var Wg=function(){},hl=Rt.forwardRef(function(e,t){var r=Rt.useRef(null),n=Rt.useState({onScrollCapture:Wg,onWheelCapture:Wg,onTouchMoveCapture:Wg}),o=n[0],a=n[1],s=e.forwardProps,u=e.children,l=e.className,c=e.removeScrollBar,p=e.enabled,d=e.shards,h=e.sideCar,g=e.noIsolation,v=e.inert,m=e.allowPinchZoom,b=e.as,y=b===void 0?"div":b,x=e.gapMode,w=eF(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noIsolation","inert","allowPinchZoom","as","gapMode"]),S=h,E=Gg([r,t]),D=mn(mn({},w),o);return Rt.createElement(Rt.Fragment,null,p&&Rt.createElement(S,{sideCar:o1,removeScrollBar:c,shards:d,noIsolation:g,inert:v,setCallbacks:a,allowPinchZoom:!!m,lockRef:r,gapMode:x}),s?Rt.cloneElement(Rt.Children.only(u),mn(mn({},D),{ref:E})):Rt.createElement(y,mn({},D,{className:l,ref:E}),u))});hl.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};hl.classNames={fullWidth:ji,zeroRight:Gi};i();i();import*as $e from"react";i();i();import*as Fs from"react";i();i();i();import*as lF from"react";i();i();var sF;var uF=function(){if(sF)return sF;if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function Doe(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=uF();return t&&e.setAttribute("nonce",t),e}function Eoe(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function Poe(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var Ug=function(){var e=0,t=null;return{add:function(r){e==0&&(t=Doe())&&(Eoe(t,r),Poe(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}};var Kg=function(){var e=Ug();return function(t,r){lF.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&r])}};var gl=function(){var e=Kg(),t=function(r){var n=r.styles,o=r.dynamic;return e(n,o),null};return t};i();var Toe={left:0,top:0,right:0,gap:0},qg=function(e){return parseInt(e||"",10)||0},Aoe=function(e){var t=window.getComputedStyle(document.body),r=t[e==="padding"?"paddingLeft":"marginLeft"],n=t[e==="padding"?"paddingTop":"marginTop"],o=t[e==="padding"?"paddingRight":"marginRight"];return[qg(r),qg(n),qg(o)]},Xg=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return Toe;var t=Aoe(e),r=document.documentElement.clientWidth,n=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,n-r+t[2]-t[0])}};var Roe=gl(),Rs="data-scroll-locked",Foe=function(e,t,r,n){var o=e.left,a=e.top,s=e.right,u=e.gap;return r===void 0&&(r="margin"),`
2087
2087
  .`.concat(zg,` {
2088
2088
  overflow: hidden `).concat(n,`;
2089
2089
  padding-right: `).concat(u,"px ").concat(n,`;
@@ -2123,7 +2123,7 @@ var zO=Object.create;var Nl=Object.defineProperty;var HO=Object.getOwnPropertyDe
2123
2123
  `)},cF=function(){var e=parseInt(document.body.getAttribute(Rs)||"0",10);return isFinite(e)?e:0},Boe=function(){Fs.useEffect(function(){return document.body.setAttribute(Rs,(cF()+1).toString()),function(){var e=cF()-1;e<=0?document.body.removeAttribute(Rs):document.body.setAttribute(Rs,e.toString())}},[])},Yg=function(e){var t=e.noRelative,r=e.noImportant,n=e.gapMode,o=n===void 0?"margin":n;Boe();var a=Fs.useMemo(function(){return Xg(o)},[o]);return Fs.createElement(Roe,{styles:Foe(a,!t,o,r?"":"!important")})};i();var Jg=!1;if(typeof window<"u")try{vl=Object.defineProperty({},"passive",{get:function(){return Jg=!0,!0}}),window.addEventListener("test",vl,vl),window.removeEventListener("test",vl,vl)}catch{Jg=!1}var vl,_i=Jg?{passive:!1}:!1;i();var Ooe=function(e){return e.tagName==="TEXTAREA"},fF=function(e,t){var r=window.getComputedStyle(e);return r[t]!=="hidden"&&!(r.overflowY===r.overflowX&&!Ooe(e)&&r[t]==="visible")},Moe=function(e){return fF(e,"overflowY")},Ioe=function(e){return fF(e,"overflowX")},Zg=function(e,t){var r=t.ownerDocument,n=t;do{typeof ShadowRoot<"u"&&n instanceof ShadowRoot&&(n=n.host);var o=pF(e,n);if(o){var a=dF(e,n),s=a[1],u=a[2];if(s>u)return!0}n=n.parentNode}while(n&&n!==r.body);return!1},koe=function(e){var t=e.scrollTop,r=e.scrollHeight,n=e.clientHeight;return[t,r,n]},Noe=function(e){var t=e.scrollLeft,r=e.scrollWidth,n=e.clientWidth;return[t,r,n]},pF=function(e,t){return e==="v"?Moe(t):Ioe(t)},dF=function(e,t){return e==="v"?koe(t):Noe(t)},Voe=function(e,t){return e==="h"&&t==="rtl"?-1:1},mF=function(e,t,r,n,o){var a=Voe(e,window.getComputedStyle(t).direction),s=a*n,u=r.target,l=t.contains(u),c=!1,p=s>0,d=0,h=0;do{var g=dF(e,u),v=g[0],m=g[1],b=g[2],y=m-b-a*v;(v||y)&&pF(e,u)&&(d+=y,h+=v),u instanceof ShadowRoot?u=u.host:u=u.parentNode}while(!l&&u!==document.body||l&&(t.contains(u)||t===u));return(p&&(o&&Math.abs(d)<1||!o&&s>d)||!p&&(o&&Math.abs(h)<1||!o&&-s>h))&&(c=!0),c};var i1=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},hF=function(e){return[e.deltaX,e.deltaY]},gF=function(e){return e&&"current"in e?e.current:e},Loe=function(e,t){return e[0]===t[0]&&e[1]===t[1]},$oe=function(e){return`
2124
2124
  .block-interactivity-`.concat(e,` {pointer-events: none;}
2125
2125
  .allow-interactivity-`).concat(e,` {pointer-events: all;}
2126
- `)},zoe=0,Bs=[];function vF(e){var t=$e.useRef([]),r=$e.useRef([0,0]),n=$e.useRef(),o=$e.useState(zoe++)[0],a=$e.useState(gl)[0],s=$e.useRef(e);$e.useEffect(function(){s.current=e},[e]),$e.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(o));var m=tF([e.lockRef.current],(e.shards||[]).map(gF),!0).filter(Boolean);return m.forEach(function(b){return b.classList.add("allow-interactivity-".concat(o))}),function(){document.body.classList.remove("block-interactivity-".concat(o)),m.forEach(function(b){return b.classList.remove("allow-interactivity-".concat(o))})}}},[e.inert,e.lockRef.current,e.shards]);var u=$e.useCallback(function(m,b){if("touches"in m&&m.touches.length===2)return!s.current.allowPinchZoom;var y=i1(m),x=r.current,w="deltaX"in m?m.deltaX:x[0]-y[0],S="deltaY"in m?m.deltaY:x[1]-y[1],E,D=m.target,P=Math.abs(w)>Math.abs(S)?"h":"v";if("touches"in m&&P==="h"&&D.type==="range")return!1;var R=Zg(P,D);if(!R)return!0;if(R?E=P:(E=P==="v"?"h":"v",R=Zg(P,D)),!R)return!1;if(!n.current&&"changedTouches"in m&&(w||S)&&(n.current=E),!E)return!0;var F=n.current||E;return mF(F,b,m,F==="h"?w:S,!0)},[]),l=$e.useCallback(function(m){var b=m;if(!(!Bs.length||Bs[Bs.length-1]!==a)){var y="deltaY"in b?hF(b):i1(b),x=t.current.filter(function(E){return E.name===b.type&&(E.target===b.target||b.target===E.shadowParent)&&Loe(E.delta,y)})[0];if(x&&x.should){b.cancelable&&b.preventDefault();return}if(!x){var w=(s.current.shards||[]).map(gF).filter(Boolean).filter(function(E){return E.contains(b.target)}),S=w.length>0?u(b,w[0]):!s.current.noIsolation;S&&b.cancelable&&b.preventDefault()}}},[]),c=$e.useCallback(function(m,b,y,x){var w={name:m,delta:b,target:y,should:x,shadowParent:Hoe(y)};t.current.push(w),setTimeout(function(){t.current=t.current.filter(function(S){return S!==w})},1)},[]),p=$e.useCallback(function(m){r.current=i1(m),n.current=void 0},[]),d=$e.useCallback(function(m){c(m.type,hF(m),m.target,u(m,e.lockRef.current))},[]),h=$e.useCallback(function(m){c(m.type,i1(m),m.target,u(m,e.lockRef.current))},[]);$e.useEffect(function(){return Bs.push(a),e.setCallbacks({onScrollCapture:d,onWheelCapture:d,onTouchMoveCapture:h}),document.addEventListener("wheel",l,_i),document.addEventListener("touchmove",l,_i),document.addEventListener("touchstart",p,_i),function(){Bs=Bs.filter(function(m){return m!==a}),document.removeEventListener("wheel",l,_i),document.removeEventListener("touchmove",l,_i),document.removeEventListener("touchstart",p,_i)}},[]);var g=e.removeScrollBar,v=e.inert;return $e.createElement($e.Fragment,null,v?$e.createElement(a,{styles:$oe(o)}):null,g?$e.createElement(Yg,{gapMode:e.gapMode}):null)}function Hoe(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}var yF=_g(o1,vF);var bF=a1.forwardRef(function(e,t){return a1.createElement(hl,mn({},e,{ref:t,sideCar:yF}))});bF.classNames=hl.classNames;var Qg=bF;import{jsx as fe}from"react/jsx-runtime";var e5=["Enter"," "],Goe=["ArrowDown","PageUp","Home"],xF=["ArrowUp","PageDown","End"],joe=[...Goe,...xF],_oe={ltr:[...e5,"ArrowRight"],rtl:[...e5,"ArrowLeft"]},Woe={ltr:["ArrowLeft"],rtl:["ArrowRight"]},xl="Menu",[bl,Uoe,Koe]=Ld(xl),[Wi,t5]=cn(xl,[Koe,Og,Lg]),wl=Og(),wF=Lg(),[SF,_o]=Wi(xl),[qoe,Sl]=Wi(xl),DF=e=>{let{__scopeMenu:t,open:r=!1,children:n,dir:o,onOpenChange:a,modal:s=!0}=e,u=wl(t),[l,c]=ne.useState(null),p=ne.useRef(!1),d=at(a),h=zd(o);return ne.useEffect(()=>{let g=()=>{p.current=!0,document.addEventListener("pointerdown",v,{capture:!0,once:!0}),document.addEventListener("pointermove",v,{capture:!0,once:!0})},v=()=>p.current=!1;return document.addEventListener("keydown",g,{capture:!0}),()=>{document.removeEventListener("keydown",g,{capture:!0}),document.removeEventListener("pointerdown",v,{capture:!0}),document.removeEventListener("pointermove",v,{capture:!0})}},[]),fe(Ig,{...u,children:fe(SF,{scope:t,open:r,onOpenChange:d,content:l,onContentChange:c,children:fe(qoe,{scope:t,onClose:ne.useCallback(()=>d(!1),[d]),isUsingKeyboardRef:p,dir:h,modal:s,children:n})})})};DF.displayName=xl;var Xoe="MenuAnchor",r5=ne.forwardRef((e,t)=>{let{__scopeMenu:r,...n}=e,o=wl(r);return fe(zR,{...o,...n,ref:t})});r5.displayName=Xoe;var n5="MenuPortal",[Yoe,EF]=Wi(n5,{forceMount:void 0}),PF=e=>{let{__scopeMenu:t,forceMount:r,children:n,container:o}=e,a=_o(n5,t);return fe(Yoe,{scope:t,forceMount:r,children:fe(Ps,{present:r||a.open,children:fe(kg,{asChild:!0,container:o,children:n})})})};PF.displayName=n5;var Or="MenuContent",[Joe,o5]=Wi(Or),TF=ne.forwardRef((e,t)=>{let r=EF(Or,e.__scopeMenu),{forceMount:n=r.forceMount,...o}=e,a=_o(Or,e.__scopeMenu),s=Sl(Or,e.__scopeMenu);return fe(bl.Provider,{scope:e.__scopeMenu,children:fe(Ps,{present:n||a.open,children:fe(bl.Slot,{scope:e.__scopeMenu,children:s.modal?fe(Zoe,{...o,ref:t}):fe(Qoe,{...o,ref:t})})})})}),Zoe=ne.forwardRef((e,t)=>{let r=_o(Or,e.__scopeMenu),n=ne.useRef(null),o=Ye(t,n);return ne.useEffect(()=>{let a=n.current;if(a)return QR(a)},[]),fe(i5,{...e,ref:o,trapFocus:r.open,disableOutsidePointerEvents:r.open,disableOutsideScroll:!0,onFocusOutside:ye(e.onFocusOutside,a=>a.preventDefault(),{checkForDefaultPrevented:!1}),onDismiss:()=>r.onOpenChange(!1)})}),Qoe=ne.forwardRef((e,t)=>{let r=_o(Or,e.__scopeMenu);return fe(i5,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,onDismiss:()=>r.onOpenChange(!1)})}),i5=ne.forwardRef((e,t)=>{let{__scopeMenu:r,loop:n=!1,trapFocus:o,onOpenAutoFocus:a,onCloseAutoFocus:s,disableOutsidePointerEvents:u,onEntryFocus:l,onEscapeKeyDown:c,onPointerDownOutside:p,onFocusOutside:d,onInteractOutside:h,onDismiss:g,disableOutsideScroll:v,...m}=e,b=_o(Or,r),y=Sl(Or,r),x=wl(r),w=wF(r),S=Uoe(r),[E,D]=ne.useState(null),P=ne.useRef(null),R=Ye(t,P,b.onContentChange),F=ne.useRef(0),M=ne.useRef(""),G=ne.useRef(0),N=ne.useRef(null),L=ne.useRef("right"),I=ne.useRef(0),V=v?Qg:ne.Fragment,Y=v?{as:Ho,allowPinchZoom:!0}:void 0,Q=H=>{let le=M.current+H,ve=S().filter(j=>!j.disabled),me=document.activeElement,Ge=ve.find(j=>j.ref.current===me)?.textValue,A=ve.map(j=>j.textValue),_=fie(A,le,Ge),z=ve.find(j=>j.textValue===_)?.ref.current;(function j(ue){M.current=ue,window.clearTimeout(F.current),ue!==""&&(F.current=window.setTimeout(()=>j(""),1e3))})(le),z&&setTimeout(()=>z.focus())};ne.useEffect(()=>()=>window.clearTimeout(F.current),[]),PA();let re=ne.useCallback(H=>L.current===N.current?.side&&die(H,N.current?.area),[]);return fe(Joe,{scope:r,searchRef:M,onItemEnter:ne.useCallback(H=>{re(H)&&H.preventDefault()},[re]),onItemLeave:ne.useCallback(H=>{re(H)||(P.current?.focus(),D(null))},[re]),onTriggerLeave:ne.useCallback(H=>{re(H)&&H.preventDefault()},[re]),pointerGraceTimerRef:G,onPointerGraceIntentChange:ne.useCallback(H=>{N.current=H},[]),children:fe(V,{...Y,children:fe(Dg,{asChild:!0,trapped:o,onMountAutoFocus:ye(a,H=>{H.preventDefault(),P.current?.focus({preventScroll:!0})}),onUnmountAutoFocus:s,children:fe(Cg,{asChild:!0,disableOutsidePointerEvents:u,onEscapeKeyDown:c,onPointerDownOutside:p,onFocusOutside:d,onInteractOutside:h,onDismiss:g,children:fe(YR,{asChild:!0,...w,dir:y.dir,orientation:"vertical",loop:n,currentTabStopId:E,onCurrentTabStopIdChange:D,onEntryFocus:ye(l,H=>{y.isUsingKeyboardRef.current||H.preventDefault()}),preventScrollOnEntryFocus:!0,children:fe(HR,{role:"menu","aria-orientation":"vertical","data-state":_F(b.open),"data-radix-menu-content":"",dir:y.dir,...x,...m,ref:R,style:{outline:"none",...m.style},onKeyDown:ye(m.onKeyDown,H=>{let ve=H.target.closest("[data-radix-menu-content]")===H.currentTarget,me=H.ctrlKey||H.altKey||H.metaKey,Ge=H.key.length===1;ve&&(H.key==="Tab"&&H.preventDefault(),!me&&Ge&&Q(H.key));let A=P.current;if(H.target!==A||!joe.includes(H.key))return;H.preventDefault();let z=S().filter(j=>!j.disabled).map(j=>j.ref.current);xF.includes(H.key)&&z.reverse(),lie(z)}),onBlur:ye(e.onBlur,H=>{H.currentTarget.contains(H.target)||(window.clearTimeout(F.current),M.current="")}),onPointerMove:ye(e.onPointerMove,Cl(H=>{let le=H.target,ve=I.current!==H.clientX;if(H.currentTarget.contains(le)&&ve){let me=H.clientX>I.current?"right":"left";L.current=me,I.current=H.clientX}}))})})})})})})});TF.displayName=Or;var eie="MenuGroup",a5=ne.forwardRef((e,t)=>{let{__scopeMenu:r,...n}=e;return fe(Ue.div,{role:"group",...n,ref:t})});a5.displayName=eie;var tie="MenuLabel",AF=ne.forwardRef((e,t)=>{let{__scopeMenu:r,...n}=e;return fe(Ue.div,{...n,ref:t})});AF.displayName=tie;var s1="MenuItem",CF="menu.itemSelect",l1=ne.forwardRef((e,t)=>{let{disabled:r=!1,onSelect:n,...o}=e,a=ne.useRef(null),s=Sl(s1,e.__scopeMenu),u=o5(s1,e.__scopeMenu),l=Ye(t,a),c=ne.useRef(!1),p=()=>{let d=a.current;if(!r&&d){let h=new CustomEvent(CF,{bubbles:!0,cancelable:!0});d.addEventListener(CF,g=>n?.(g),{once:!0}),Vd(d,h),h.defaultPrevented?c.current=!1:s.onClose()}};return fe(RF,{...o,ref:l,disabled:r,onClick:ye(e.onClick,p),onPointerDown:d=>{e.onPointerDown?.(d),c.current=!0},onPointerUp:ye(e.onPointerUp,d=>{c.current||d.currentTarget?.click()}),onKeyDown:ye(e.onKeyDown,d=>{let h=u.searchRef.current!=="";r||h&&d.key===" "||e5.includes(d.key)&&(d.currentTarget.click(),d.preventDefault())})})});l1.displayName=s1;var RF=ne.forwardRef((e,t)=>{let{__scopeMenu:r,disabled:n=!1,textValue:o,...a}=e,s=o5(s1,r),u=wF(r),l=ne.useRef(null),c=Ye(t,l),[p,d]=ne.useState(!1),[h,g]=ne.useState("");return ne.useEffect(()=>{let v=l.current;v&&g((v.textContent??"").trim())},[a.children]),fe(bl.ItemSlot,{scope:r,disabled:n,textValue:o??h,children:fe(JR,{asChild:!0,...u,focusable:!n,children:fe(Ue.div,{role:"menuitem","data-highlighted":p?"":void 0,"aria-disabled":n||void 0,"data-disabled":n?"":void 0,...a,ref:c,onPointerMove:ye(e.onPointerMove,Cl(v=>{n?s.onItemLeave(v):(s.onItemEnter(v),v.defaultPrevented||v.currentTarget.focus({preventScroll:!0}))})),onPointerLeave:ye(e.onPointerLeave,Cl(v=>s.onItemLeave(v))),onFocus:ye(e.onFocus,()=>d(!0)),onBlur:ye(e.onBlur,()=>d(!1))})})})}),rie="MenuCheckboxItem",FF=ne.forwardRef((e,t)=>{let{checked:r=!1,onCheckedChange:n,...o}=e;return fe(kF,{scope:e.__scopeMenu,checked:r,children:fe(l1,{role:"menuitemcheckbox","aria-checked":u1(r)?"mixed":r,...o,ref:t,"data-state":l5(r),onSelect:ye(o.onSelect,()=>n?.(u1(r)?!0:!r),{checkForDefaultPrevented:!1})})})});FF.displayName=rie;var BF="MenuRadioGroup",[nie,oie]=Wi(BF,{value:void 0,onValueChange:()=>{}}),OF=ne.forwardRef((e,t)=>{let{value:r,onValueChange:n,...o}=e,a=at(n);return fe(nie,{scope:e.__scopeMenu,value:r,onValueChange:a,children:fe(a5,{...o,ref:t})})});OF.displayName=BF;var MF="MenuRadioItem",IF=ne.forwardRef((e,t)=>{let{value:r,...n}=e,o=oie(MF,e.__scopeMenu),a=r===o.value;return fe(kF,{scope:e.__scopeMenu,checked:a,children:fe(l1,{role:"menuitemradio","aria-checked":a,...n,ref:t,"data-state":l5(a),onSelect:ye(n.onSelect,()=>o.onValueChange?.(r),{checkForDefaultPrevented:!1})})})});IF.displayName=MF;var s5="MenuItemIndicator",[kF,iie]=Wi(s5,{checked:!1}),NF=ne.forwardRef((e,t)=>{let{__scopeMenu:r,forceMount:n,...o}=e,a=iie(s5,r);return fe(Ps,{present:n||u1(a.checked)||a.checked===!0,children:fe(Ue.span,{...o,ref:t,"data-state":l5(a.checked)})})});NF.displayName=s5;var aie="MenuSeparator",VF=ne.forwardRef((e,t)=>{let{__scopeMenu:r,...n}=e;return fe(Ue.div,{role:"separator","aria-orientation":"horizontal",...n,ref:t})});VF.displayName=aie;var sie="MenuArrow",LF=ne.forwardRef((e,t)=>{let{__scopeMenu:r,...n}=e,o=wl(r);return fe(GR,{...o,...n,ref:t})});LF.displayName=sie;var u5="MenuSub",[uie,$F]=Wi(u5),zF=e=>{let{__scopeMenu:t,children:r,open:n=!1,onOpenChange:o}=e,a=_o(u5,t),s=wl(t),[u,l]=ne.useState(null),[c,p]=ne.useState(null),d=at(o);return ne.useEffect(()=>(a.open===!1&&d(!1),()=>d(!1)),[a.open,d]),fe(Ig,{...s,children:fe(SF,{scope:t,open:n,onOpenChange:d,content:c,onContentChange:p,children:fe(uie,{scope:t,contentId:jo(),triggerId:jo(),trigger:u,onTriggerChange:l,children:r})})})};zF.displayName=u5;var yl="MenuSubTrigger",HF=ne.forwardRef((e,t)=>{let r=_o(yl,e.__scopeMenu),n=Sl(yl,e.__scopeMenu),o=$F(yl,e.__scopeMenu),a=o5(yl,e.__scopeMenu),s=ne.useRef(null),{pointerGraceTimerRef:u,onPointerGraceIntentChange:l}=a,c={__scopeMenu:e.__scopeMenu},p=ne.useCallback(()=>{s.current&&window.clearTimeout(s.current),s.current=null},[]);return ne.useEffect(()=>p,[p]),ne.useEffect(()=>{let d=u.current;return()=>{window.clearTimeout(d),l(null)}},[u,l]),fe(r5,{asChild:!0,...c,children:fe(RF,{id:o.triggerId,"aria-haspopup":"menu","aria-expanded":r.open,"aria-controls":o.contentId,"data-state":_F(r.open),...e,ref:Oi(t,o.onTriggerChange),onClick:d=>{e.onClick?.(d),!(e.disabled||d.defaultPrevented)&&(d.currentTarget.focus(),r.open||r.onOpenChange(!0))},onPointerMove:ye(e.onPointerMove,Cl(d=>{a.onItemEnter(d),!d.defaultPrevented&&!e.disabled&&!r.open&&!s.current&&(a.onPointerGraceIntentChange(null),s.current=window.setTimeout(()=>{r.onOpenChange(!0),p()},100))})),onPointerLeave:ye(e.onPointerLeave,Cl(d=>{p();let h=r.content?.getBoundingClientRect();if(h){let g=r.content?.dataset.side,v=g==="right",m=v?-5:5,b=h[v?"left":"right"],y=h[v?"right":"left"];a.onPointerGraceIntentChange({area:[{x:d.clientX+m,y:d.clientY},{x:b,y:h.top},{x:y,y:h.top},{x:y,y:h.bottom},{x:b,y:h.bottom}],side:g}),window.clearTimeout(u.current),u.current=window.setTimeout(()=>a.onPointerGraceIntentChange(null),300)}else{if(a.onTriggerLeave(d),d.defaultPrevented)return;a.onPointerGraceIntentChange(null)}})),onKeyDown:ye(e.onKeyDown,d=>{let h=a.searchRef.current!=="";e.disabled||h&&d.key===" "||_oe[n.dir].includes(d.key)&&(r.onOpenChange(!0),r.content?.focus(),d.preventDefault())})})})});HF.displayName=yl;var GF="MenuSubContent",jF=ne.forwardRef((e,t)=>{let r=EF(Or,e.__scopeMenu),{forceMount:n=r.forceMount,...o}=e,a=_o(Or,e.__scopeMenu),s=Sl(Or,e.__scopeMenu),u=$F(GF,e.__scopeMenu),l=ne.useRef(null),c=Ye(t,l);return fe(bl.Provider,{scope:e.__scopeMenu,children:fe(Ps,{present:n||a.open,children:fe(bl.Slot,{scope:e.__scopeMenu,children:fe(i5,{id:u.contentId,"aria-labelledby":u.triggerId,...o,ref:c,align:"start",side:s.dir==="rtl"?"left":"right",disableOutsidePointerEvents:!1,disableOutsideScroll:!1,trapFocus:!1,onOpenAutoFocus:p=>{s.isUsingKeyboardRef.current&&l.current?.focus(),p.preventDefault()},onCloseAutoFocus:p=>p.preventDefault(),onFocusOutside:ye(e.onFocusOutside,p=>{p.target!==u.trigger&&a.onOpenChange(!1)}),onEscapeKeyDown:ye(e.onEscapeKeyDown,p=>{s.onClose(),p.preventDefault()}),onKeyDown:ye(e.onKeyDown,p=>{let d=p.currentTarget.contains(p.target),h=Woe[s.dir].includes(p.key);d&&h&&(a.onOpenChange(!1),u.trigger?.focus(),p.preventDefault())})})})})})});jF.displayName=GF;function _F(e){return e?"open":"closed"}function u1(e){return e==="indeterminate"}function l5(e){return u1(e)?"indeterminate":e?"checked":"unchecked"}function lie(e){let t=document.activeElement;for(let r of e)if(r===t||(r.focus(),document.activeElement!==t))return}function cie(e,t){return e.map((r,n)=>e[(t+n)%e.length])}function fie(e,t,r){let o=t.length>1&&Array.from(t).every(c=>c===t[0])?t[0]:t,a=r?e.indexOf(r):-1,s=cie(e,Math.max(a,0));o.length===1&&(s=s.filter(c=>c!==r));let l=s.find(c=>c.toLowerCase().startsWith(o.toLowerCase()));return l!==r?l:void 0}function pie(e,t){let{x:r,y:n}=e,o=!1;for(let a=0,s=t.length-1;a<t.length;s=a++){let u=t[a].x,l=t[a].y,c=t[s].x,p=t[s].y;l>n!=p>n&&r<(c-u)*(n-l)/(p-l)+u&&(o=!o)}return o}function die(e,t){if(!t)return!1;let r={x:e.clientX,y:e.clientY};return pie(r,t)}function Cl(e){return t=>t.pointerType==="mouse"?e(t):void 0}var WF=DF,UF=r5,KF=PF,qF=TF,XF=a5,YF=AF,JF=l1,ZF=FF,QF=OF,eB=IF,tB=NF,rB=VF,nB=LF,oB=zF,iB=HF,aB=jF;import{jsx as dt}from"react/jsx-runtime";var c5="DropdownMenu",[hie,wut]=cn(c5,[t5]),Ft=t5(),[gie,sB]=hie(c5),f5=e=>{let{__scopeDropdownMenu:t,children:r,dir:n,open:o,defaultOpen:a,onOpenChange:s,modal:u=!0}=e,l=Ft(t),c=st.useRef(null),[p=!1,d]=ll({prop:o,defaultProp:a,onChange:s});return dt(gie,{scope:t,triggerId:jo(),triggerRef:c,contentId:jo(),open:p,onOpenChange:d,onOpenToggle:st.useCallback(()=>d(h=>!h),[d]),modal:u,children:dt(WF,{...l,open:p,onOpenChange:d,dir:n,modal:u,children:r})})};f5.displayName=c5;var uB="DropdownMenuTrigger",p5=st.forwardRef((e,t)=>{let{__scopeDropdownMenu:r,disabled:n=!1,...o}=e,a=sB(uB,r),s=Ft(r);return dt(UF,{asChild:!0,...s,children:dt(Ue.button,{type:"button",id:a.triggerId,"aria-haspopup":"menu","aria-expanded":a.open,"aria-controls":a.open?a.contentId:void 0,"data-state":a.open?"open":"closed","data-disabled":n?"":void 0,disabled:n,...o,ref:Oi(t,a.triggerRef),onPointerDown:ye(e.onPointerDown,u=>{!n&&u.button===0&&u.ctrlKey===!1&&(a.onOpenToggle(),a.open||u.preventDefault())}),onKeyDown:ye(e.onKeyDown,u=>{n||(["Enter"," "].includes(u.key)&&a.onOpenToggle(),u.key==="ArrowDown"&&a.onOpenChange(!0),["Enter"," ","ArrowDown"].includes(u.key)&&u.preventDefault())})})})});p5.displayName=uB;var vie="DropdownMenuPortal",c1=e=>{let{__scopeDropdownMenu:t,...r}=e,n=Ft(t);return dt(KF,{...n,...r})};c1.displayName=vie;var lB="DropdownMenuContent",d5=st.forwardRef((e,t)=>{let{__scopeDropdownMenu:r,...n}=e,o=sB(lB,r),a=Ft(r),s=st.useRef(!1);return dt(qF,{id:o.contentId,"aria-labelledby":o.triggerId,...a,...n,ref:t,onCloseAutoFocus:ye(e.onCloseAutoFocus,u=>{s.current||o.triggerRef.current?.focus(),s.current=!1,u.preventDefault()}),onInteractOutside:ye(e.onInteractOutside,u=>{let l=u.detail.originalEvent,c=l.button===0&&l.ctrlKey===!0,p=l.button===2||c;(!o.modal||p)&&(s.current=!0)}),style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});d5.displayName=lB;var yie="DropdownMenuGroup",m5=st.forwardRef((e,t)=>{let{__scopeDropdownMenu:r,...n}=e,o=Ft(r);return dt(XF,{...o,...n,ref:t})});m5.displayName=yie;var bie="DropdownMenuLabel",h5=st.forwardRef((e,t)=>{let{__scopeDropdownMenu:r,...n}=e,o=Ft(r);return dt(YF,{...o,...n,ref:t})});h5.displayName=bie;var Cie="DropdownMenuItem",f1=st.forwardRef((e,t)=>{let{__scopeDropdownMenu:r,...n}=e,o=Ft(r);return dt(JF,{...o,...n,ref:t})});f1.displayName=Cie;var xie="DropdownMenuCheckboxItem",g5=st.forwardRef((e,t)=>{let{__scopeDropdownMenu:r,...n}=e,o=Ft(r);return dt(ZF,{...o,...n,ref:t})});g5.displayName=xie;var wie="DropdownMenuRadioGroup",v5=st.forwardRef((e,t)=>{let{__scopeDropdownMenu:r,...n}=e,o=Ft(r);return dt(QF,{...o,...n,ref:t})});v5.displayName=wie;var Sie="DropdownMenuRadioItem",y5=st.forwardRef((e,t)=>{let{__scopeDropdownMenu:r,...n}=e,o=Ft(r);return dt(eB,{...o,...n,ref:t})});y5.displayName=Sie;var Die="DropdownMenuItemIndicator",p1=st.forwardRef((e,t)=>{let{__scopeDropdownMenu:r,...n}=e,o=Ft(r);return dt(tB,{...o,...n,ref:t})});p1.displayName=Die;var Eie="DropdownMenuSeparator",Pie=st.forwardRef((e,t)=>{let{__scopeDropdownMenu:r,...n}=e,o=Ft(r);return dt(rB,{...o,...n,ref:t})});Pie.displayName=Eie;var Tie="DropdownMenuArrow",Aie=st.forwardRef((e,t)=>{let{__scopeDropdownMenu:r,...n}=e,o=Ft(r);return dt(nB,{...o,...n,ref:t})});Aie.displayName=Tie;var cB=e=>{let{__scopeDropdownMenu:t,children:r,open:n,onOpenChange:o,defaultOpen:a}=e,s=Ft(t),[u=!1,l]=ll({prop:n,defaultProp:a,onChange:o});return dt(oB,{...s,open:u,onOpenChange:l,children:r})},Rie="DropdownMenuSubTrigger",b5=st.forwardRef((e,t)=>{let{__scopeDropdownMenu:r,...n}=e,o=Ft(r);return dt(iB,{...o,...n,ref:t})});b5.displayName=Rie;var Fie="DropdownMenuSubContent",C5=st.forwardRef((e,t)=>{let{__scopeDropdownMenu:r,...n}=e,o=Ft(r);return dt(aB,{...o,...n,ref:t,style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});C5.displayName=Fie;var El=U(Z());i();var wt=U(Z());import Os,{css as Bie}from"styled-components";import{jsx as Je,jsxs as Wr}from"react/jsx-runtime";var fB="0.08",Oie=Bie`
2126
+ `)},zoe=0,Bs=[];function vF(e){var t=$e.useRef([]),r=$e.useRef([0,0]),n=$e.useRef(),o=$e.useState(zoe++)[0],a=$e.useState(gl)[0],s=$e.useRef(e);$e.useEffect(function(){s.current=e},[e]),$e.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(o));var m=tF([e.lockRef.current],(e.shards||[]).map(gF),!0).filter(Boolean);return m.forEach(function(b){return b.classList.add("allow-interactivity-".concat(o))}),function(){document.body.classList.remove("block-interactivity-".concat(o)),m.forEach(function(b){return b.classList.remove("allow-interactivity-".concat(o))})}}},[e.inert,e.lockRef.current,e.shards]);var u=$e.useCallback(function(m,b){if("touches"in m&&m.touches.length===2)return!s.current.allowPinchZoom;var y=i1(m),x=r.current,w="deltaX"in m?m.deltaX:x[0]-y[0],S="deltaY"in m?m.deltaY:x[1]-y[1],E,D=m.target,P=Math.abs(w)>Math.abs(S)?"h":"v";if("touches"in m&&P==="h"&&D.type==="range")return!1;var R=Zg(P,D);if(!R)return!0;if(R?E=P:(E=P==="v"?"h":"v",R=Zg(P,D)),!R)return!1;if(!n.current&&"changedTouches"in m&&(w||S)&&(n.current=E),!E)return!0;var F=n.current||E;return mF(F,b,m,F==="h"?w:S,!0)},[]),l=$e.useCallback(function(m){var b=m;if(!(!Bs.length||Bs[Bs.length-1]!==a)){var y="deltaY"in b?hF(b):i1(b),x=t.current.filter(function(E){return E.name===b.type&&(E.target===b.target||b.target===E.shadowParent)&&Loe(E.delta,y)})[0];if(x&&x.should){b.cancelable&&b.preventDefault();return}if(!x){var w=(s.current.shards||[]).map(gF).filter(Boolean).filter(function(E){return E.contains(b.target)}),S=w.length>0?u(b,w[0]):!s.current.noIsolation;S&&b.cancelable&&b.preventDefault()}}},[]),c=$e.useCallback(function(m,b,y,x){var w={name:m,delta:b,target:y,should:x,shadowParent:Hoe(y)};t.current.push(w),setTimeout(function(){t.current=t.current.filter(function(S){return S!==w})},1)},[]),p=$e.useCallback(function(m){r.current=i1(m),n.current=void 0},[]),d=$e.useCallback(function(m){c(m.type,hF(m),m.target,u(m,e.lockRef.current))},[]),h=$e.useCallback(function(m){c(m.type,i1(m),m.target,u(m,e.lockRef.current))},[]);$e.useEffect(function(){return Bs.push(a),e.setCallbacks({onScrollCapture:d,onWheelCapture:d,onTouchMoveCapture:h}),document.addEventListener("wheel",l,_i),document.addEventListener("touchmove",l,_i),document.addEventListener("touchstart",p,_i),function(){Bs=Bs.filter(function(m){return m!==a}),document.removeEventListener("wheel",l,_i),document.removeEventListener("touchmove",l,_i),document.removeEventListener("touchstart",p,_i)}},[]);var g=e.removeScrollBar,v=e.inert;return $e.createElement($e.Fragment,null,v?$e.createElement(a,{styles:$oe(o)}):null,g?$e.createElement(Yg,{gapMode:e.gapMode}):null)}function Hoe(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}var yF=_g(o1,vF);var bF=a1.forwardRef(function(e,t){return a1.createElement(hl,mn({},e,{ref:t,sideCar:yF}))});bF.classNames=hl.classNames;var Qg=bF;import{jsx as fe}from"react/jsx-runtime";var e5=["Enter"," "],Goe=["ArrowDown","PageUp","Home"],xF=["ArrowUp","PageDown","End"],joe=[...Goe,...xF],_oe={ltr:[...e5,"ArrowRight"],rtl:[...e5,"ArrowLeft"]},Woe={ltr:["ArrowLeft"],rtl:["ArrowRight"]},xl="Menu",[bl,Uoe,Koe]=Ld(xl),[Wi,t5]=cn(xl,[Koe,Og,Lg]),wl=Og(),wF=Lg(),[SF,_o]=Wi(xl),[qoe,Sl]=Wi(xl),DF=e=>{let{__scopeMenu:t,open:r=!1,children:n,dir:o,onOpenChange:a,modal:s=!0}=e,u=wl(t),[l,c]=ne.useState(null),p=ne.useRef(!1),d=at(a),h=zd(o);return ne.useEffect(()=>{let g=()=>{p.current=!0,document.addEventListener("pointerdown",v,{capture:!0,once:!0}),document.addEventListener("pointermove",v,{capture:!0,once:!0})},v=()=>p.current=!1;return document.addEventListener("keydown",g,{capture:!0}),()=>{document.removeEventListener("keydown",g,{capture:!0}),document.removeEventListener("pointerdown",v,{capture:!0}),document.removeEventListener("pointermove",v,{capture:!0})}},[]),fe(Ig,{...u,children:fe(SF,{scope:t,open:r,onOpenChange:d,content:l,onContentChange:c,children:fe(qoe,{scope:t,onClose:ne.useCallback(()=>d(!1),[d]),isUsingKeyboardRef:p,dir:h,modal:s,children:n})})})};DF.displayName=xl;var Xoe="MenuAnchor",r5=ne.forwardRef((e,t)=>{let{__scopeMenu:r,...n}=e,o=wl(r);return fe(zR,{...o,...n,ref:t})});r5.displayName=Xoe;var n5="MenuPortal",[Yoe,EF]=Wi(n5,{forceMount:void 0}),PF=e=>{let{__scopeMenu:t,forceMount:r,children:n,container:o}=e,a=_o(n5,t);return fe(Yoe,{scope:t,forceMount:r,children:fe(Ps,{present:r||a.open,children:fe(kg,{asChild:!0,container:o,children:n})})})};PF.displayName=n5;var Or="MenuContent",[Joe,o5]=Wi(Or),TF=ne.forwardRef((e,t)=>{let r=EF(Or,e.__scopeMenu),{forceMount:n=r.forceMount,...o}=e,a=_o(Or,e.__scopeMenu),s=Sl(Or,e.__scopeMenu);return fe(bl.Provider,{scope:e.__scopeMenu,children:fe(Ps,{present:n||a.open,children:fe(bl.Slot,{scope:e.__scopeMenu,children:s.modal?fe(Zoe,{...o,ref:t}):fe(Qoe,{...o,ref:t})})})})}),Zoe=ne.forwardRef((e,t)=>{let r=_o(Or,e.__scopeMenu),n=ne.useRef(null),o=Ye(t,n);return ne.useEffect(()=>{let a=n.current;if(a)return QR(a)},[]),fe(i5,{...e,ref:o,trapFocus:r.open,disableOutsidePointerEvents:r.open,disableOutsideScroll:!0,onFocusOutside:ye(e.onFocusOutside,a=>a.preventDefault(),{checkForDefaultPrevented:!1}),onDismiss:()=>r.onOpenChange(!1)})}),Qoe=ne.forwardRef((e,t)=>{let r=_o(Or,e.__scopeMenu);return fe(i5,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,onDismiss:()=>r.onOpenChange(!1)})}),i5=ne.forwardRef((e,t)=>{let{__scopeMenu:r,loop:n=!1,trapFocus:o,onOpenAutoFocus:a,onCloseAutoFocus:s,disableOutsidePointerEvents:u,onEntryFocus:l,onEscapeKeyDown:c,onPointerDownOutside:p,onFocusOutside:d,onInteractOutside:h,onDismiss:g,disableOutsideScroll:v,...m}=e,b=_o(Or,r),y=Sl(Or,r),x=wl(r),w=wF(r),S=Uoe(r),[E,D]=ne.useState(null),P=ne.useRef(null),R=Ye(t,P,b.onContentChange),F=ne.useRef(0),M=ne.useRef(""),G=ne.useRef(0),N=ne.useRef(null),L=ne.useRef("right"),I=ne.useRef(0),V=v?Qg:ne.Fragment,Y=v?{as:Ho,allowPinchZoom:!0}:void 0,Q=H=>{let le=M.current+H,ve=S().filter(j=>!j.disabled),me=document.activeElement,Ge=ve.find(j=>j.ref.current===me)?.textValue,A=ve.map(j=>j.textValue),_=fie(A,le,Ge),z=ve.find(j=>j.textValue===_)?.ref.current;(function j(ue){M.current=ue,window.clearTimeout(F.current),ue!==""&&(F.current=window.setTimeout(()=>j(""),1e3))})(le),z&&setTimeout(()=>z.focus())};ne.useEffect(()=>()=>window.clearTimeout(F.current),[]),PA();let re=ne.useCallback(H=>L.current===N.current?.side&&die(H,N.current?.area),[]);return fe(Joe,{scope:r,searchRef:M,onItemEnter:ne.useCallback(H=>{re(H)&&H.preventDefault()},[re]),onItemLeave:ne.useCallback(H=>{re(H)||(P.current?.focus(),D(null))},[re]),onTriggerLeave:ne.useCallback(H=>{re(H)&&H.preventDefault()},[re]),pointerGraceTimerRef:G,onPointerGraceIntentChange:ne.useCallback(H=>{N.current=H},[]),children:fe(V,{...Y,children:fe(Dg,{asChild:!0,trapped:o,onMountAutoFocus:ye(a,H=>{H.preventDefault(),P.current?.focus({preventScroll:!0})}),onUnmountAutoFocus:s,children:fe(Cg,{asChild:!0,disableOutsidePointerEvents:u,onEscapeKeyDown:c,onPointerDownOutside:p,onFocusOutside:d,onInteractOutside:h,onDismiss:g,children:fe(YR,{asChild:!0,...w,dir:y.dir,orientation:"vertical",loop:n,currentTabStopId:E,onCurrentTabStopIdChange:D,onEntryFocus:ye(l,H=>{y.isUsingKeyboardRef.current||H.preventDefault()}),preventScrollOnEntryFocus:!0,children:fe(HR,{role:"menu","aria-orientation":"vertical","data-state":_F(b.open),"data-radix-menu-content":"",dir:y.dir,...x,...m,ref:R,style:{outline:"none",...m.style},onKeyDown:ye(m.onKeyDown,H=>{let ve=H.target.closest("[data-radix-menu-content]")===H.currentTarget,me=H.ctrlKey||H.altKey||H.metaKey,Ge=H.key.length===1;ve&&(H.key==="Tab"&&H.preventDefault(),!me&&Ge&&Q(H.key));let A=P.current;if(H.target!==A||!joe.includes(H.key))return;H.preventDefault();let z=S().filter(j=>!j.disabled).map(j=>j.ref.current);xF.includes(H.key)&&z.reverse(),lie(z)}),onBlur:ye(e.onBlur,H=>{H.currentTarget.contains(H.target)||(window.clearTimeout(F.current),M.current="")}),onPointerMove:ye(e.onPointerMove,Cl(H=>{let le=H.target,ve=I.current!==H.clientX;if(H.currentTarget.contains(le)&&ve){let me=H.clientX>I.current?"right":"left";L.current=me,I.current=H.clientX}}))})})})})})})});TF.displayName=Or;var eie="MenuGroup",a5=ne.forwardRef((e,t)=>{let{__scopeMenu:r,...n}=e;return fe(Ue.div,{role:"group",...n,ref:t})});a5.displayName=eie;var tie="MenuLabel",AF=ne.forwardRef((e,t)=>{let{__scopeMenu:r,...n}=e;return fe(Ue.div,{...n,ref:t})});AF.displayName=tie;var s1="MenuItem",CF="menu.itemSelect",l1=ne.forwardRef((e,t)=>{let{disabled:r=!1,onSelect:n,...o}=e,a=ne.useRef(null),s=Sl(s1,e.__scopeMenu),u=o5(s1,e.__scopeMenu),l=Ye(t,a),c=ne.useRef(!1),p=()=>{let d=a.current;if(!r&&d){let h=new CustomEvent(CF,{bubbles:!0,cancelable:!0});d.addEventListener(CF,g=>n?.(g),{once:!0}),Vd(d,h),h.defaultPrevented?c.current=!1:s.onClose()}};return fe(RF,{...o,ref:l,disabled:r,onClick:ye(e.onClick,p),onPointerDown:d=>{e.onPointerDown?.(d),c.current=!0},onPointerUp:ye(e.onPointerUp,d=>{c.current||d.currentTarget?.click()}),onKeyDown:ye(e.onKeyDown,d=>{let h=u.searchRef.current!=="";r||h&&d.key===" "||e5.includes(d.key)&&(d.currentTarget.click(),d.preventDefault())})})});l1.displayName=s1;var RF=ne.forwardRef((e,t)=>{let{__scopeMenu:r,disabled:n=!1,textValue:o,...a}=e,s=o5(s1,r),u=wF(r),l=ne.useRef(null),c=Ye(t,l),[p,d]=ne.useState(!1),[h,g]=ne.useState("");return ne.useEffect(()=>{let v=l.current;v&&g((v.textContent??"").trim())},[a.children]),fe(bl.ItemSlot,{scope:r,disabled:n,textValue:o??h,children:fe(JR,{asChild:!0,...u,focusable:!n,children:fe(Ue.div,{role:"menuitem","data-highlighted":p?"":void 0,"aria-disabled":n||void 0,"data-disabled":n?"":void 0,...a,ref:c,onPointerMove:ye(e.onPointerMove,Cl(v=>{n?s.onItemLeave(v):(s.onItemEnter(v),v.defaultPrevented||v.currentTarget.focus({preventScroll:!0}))})),onPointerLeave:ye(e.onPointerLeave,Cl(v=>s.onItemLeave(v))),onFocus:ye(e.onFocus,()=>d(!0)),onBlur:ye(e.onBlur,()=>d(!1))})})})}),rie="MenuCheckboxItem",FF=ne.forwardRef((e,t)=>{let{checked:r=!1,onCheckedChange:n,...o}=e;return fe(kF,{scope:e.__scopeMenu,checked:r,children:fe(l1,{role:"menuitemcheckbox","aria-checked":u1(r)?"mixed":r,...o,ref:t,"data-state":l5(r),onSelect:ye(o.onSelect,()=>n?.(u1(r)?!0:!r),{checkForDefaultPrevented:!1})})})});FF.displayName=rie;var BF="MenuRadioGroup",[nie,oie]=Wi(BF,{value:void 0,onValueChange:()=>{}}),OF=ne.forwardRef((e,t)=>{let{value:r,onValueChange:n,...o}=e,a=at(n);return fe(nie,{scope:e.__scopeMenu,value:r,onValueChange:a,children:fe(a5,{...o,ref:t})})});OF.displayName=BF;var MF="MenuRadioItem",IF=ne.forwardRef((e,t)=>{let{value:r,...n}=e,o=oie(MF,e.__scopeMenu),a=r===o.value;return fe(kF,{scope:e.__scopeMenu,checked:a,children:fe(l1,{role:"menuitemradio","aria-checked":a,...n,ref:t,"data-state":l5(a),onSelect:ye(n.onSelect,()=>o.onValueChange?.(r),{checkForDefaultPrevented:!1})})})});IF.displayName=MF;var s5="MenuItemIndicator",[kF,iie]=Wi(s5,{checked:!1}),NF=ne.forwardRef((e,t)=>{let{__scopeMenu:r,forceMount:n,...o}=e,a=iie(s5,r);return fe(Ps,{present:n||u1(a.checked)||a.checked===!0,children:fe(Ue.span,{...o,ref:t,"data-state":l5(a.checked)})})});NF.displayName=s5;var aie="MenuSeparator",VF=ne.forwardRef((e,t)=>{let{__scopeMenu:r,...n}=e;return fe(Ue.div,{role:"separator","aria-orientation":"horizontal",...n,ref:t})});VF.displayName=aie;var sie="MenuArrow",LF=ne.forwardRef((e,t)=>{let{__scopeMenu:r,...n}=e,o=wl(r);return fe(GR,{...o,...n,ref:t})});LF.displayName=sie;var u5="MenuSub",[uie,$F]=Wi(u5),zF=e=>{let{__scopeMenu:t,children:r,open:n=!1,onOpenChange:o}=e,a=_o(u5,t),s=wl(t),[u,l]=ne.useState(null),[c,p]=ne.useState(null),d=at(o);return ne.useEffect(()=>(a.open===!1&&d(!1),()=>d(!1)),[a.open,d]),fe(Ig,{...s,children:fe(SF,{scope:t,open:n,onOpenChange:d,content:c,onContentChange:p,children:fe(uie,{scope:t,contentId:jo(),triggerId:jo(),trigger:u,onTriggerChange:l,children:r})})})};zF.displayName=u5;var yl="MenuSubTrigger",HF=ne.forwardRef((e,t)=>{let r=_o(yl,e.__scopeMenu),n=Sl(yl,e.__scopeMenu),o=$F(yl,e.__scopeMenu),a=o5(yl,e.__scopeMenu),s=ne.useRef(null),{pointerGraceTimerRef:u,onPointerGraceIntentChange:l}=a,c={__scopeMenu:e.__scopeMenu},p=ne.useCallback(()=>{s.current&&window.clearTimeout(s.current),s.current=null},[]);return ne.useEffect(()=>p,[p]),ne.useEffect(()=>{let d=u.current;return()=>{window.clearTimeout(d),l(null)}},[u,l]),fe(r5,{asChild:!0,...c,children:fe(RF,{id:o.triggerId,"aria-haspopup":"menu","aria-expanded":r.open,"aria-controls":o.contentId,"data-state":_F(r.open),...e,ref:Oi(t,o.onTriggerChange),onClick:d=>{e.onClick?.(d),!(e.disabled||d.defaultPrevented)&&(d.currentTarget.focus(),r.open||r.onOpenChange(!0))},onPointerMove:ye(e.onPointerMove,Cl(d=>{a.onItemEnter(d),!d.defaultPrevented&&!e.disabled&&!r.open&&!s.current&&(a.onPointerGraceIntentChange(null),s.current=window.setTimeout(()=>{r.onOpenChange(!0),p()},100))})),onPointerLeave:ye(e.onPointerLeave,Cl(d=>{p();let h=r.content?.getBoundingClientRect();if(h){let g=r.content?.dataset.side,v=g==="right",m=v?-5:5,b=h[v?"left":"right"],y=h[v?"right":"left"];a.onPointerGraceIntentChange({area:[{x:d.clientX+m,y:d.clientY},{x:b,y:h.top},{x:y,y:h.top},{x:y,y:h.bottom},{x:b,y:h.bottom}],side:g}),window.clearTimeout(u.current),u.current=window.setTimeout(()=>a.onPointerGraceIntentChange(null),300)}else{if(a.onTriggerLeave(d),d.defaultPrevented)return;a.onPointerGraceIntentChange(null)}})),onKeyDown:ye(e.onKeyDown,d=>{let h=a.searchRef.current!=="";e.disabled||h&&d.key===" "||_oe[n.dir].includes(d.key)&&(r.onOpenChange(!0),r.content?.focus(),d.preventDefault())})})})});HF.displayName=yl;var GF="MenuSubContent",jF=ne.forwardRef((e,t)=>{let r=EF(Or,e.__scopeMenu),{forceMount:n=r.forceMount,...o}=e,a=_o(Or,e.__scopeMenu),s=Sl(Or,e.__scopeMenu),u=$F(GF,e.__scopeMenu),l=ne.useRef(null),c=Ye(t,l);return fe(bl.Provider,{scope:e.__scopeMenu,children:fe(Ps,{present:n||a.open,children:fe(bl.Slot,{scope:e.__scopeMenu,children:fe(i5,{id:u.contentId,"aria-labelledby":u.triggerId,...o,ref:c,align:"start",side:s.dir==="rtl"?"left":"right",disableOutsidePointerEvents:!1,disableOutsideScroll:!1,trapFocus:!1,onOpenAutoFocus:p=>{s.isUsingKeyboardRef.current&&l.current?.focus(),p.preventDefault()},onCloseAutoFocus:p=>p.preventDefault(),onFocusOutside:ye(e.onFocusOutside,p=>{p.target!==u.trigger&&a.onOpenChange(!1)}),onEscapeKeyDown:ye(e.onEscapeKeyDown,p=>{s.onClose(),p.preventDefault()}),onKeyDown:ye(e.onKeyDown,p=>{let d=p.currentTarget.contains(p.target),h=Woe[s.dir].includes(p.key);d&&h&&(a.onOpenChange(!1),u.trigger?.focus(),p.preventDefault())})})})})})});jF.displayName=GF;function _F(e){return e?"open":"closed"}function u1(e){return e==="indeterminate"}function l5(e){return u1(e)?"indeterminate":e?"checked":"unchecked"}function lie(e){let t=document.activeElement;for(let r of e)if(r===t||(r.focus(),document.activeElement!==t))return}function cie(e,t){return e.map((r,n)=>e[(t+n)%e.length])}function fie(e,t,r){let o=t.length>1&&Array.from(t).every(c=>c===t[0])?t[0]:t,a=r?e.indexOf(r):-1,s=cie(e,Math.max(a,0));o.length===1&&(s=s.filter(c=>c!==r));let l=s.find(c=>c.toLowerCase().startsWith(o.toLowerCase()));return l!==r?l:void 0}function pie(e,t){let{x:r,y:n}=e,o=!1;for(let a=0,s=t.length-1;a<t.length;s=a++){let u=t[a].x,l=t[a].y,c=t[s].x,p=t[s].y;l>n!=p>n&&r<(c-u)*(n-l)/(p-l)+u&&(o=!o)}return o}function die(e,t){if(!t)return!1;let r={x:e.clientX,y:e.clientY};return pie(r,t)}function Cl(e){return t=>t.pointerType==="mouse"?e(t):void 0}var WF=DF,UF=r5,KF=PF,qF=TF,XF=a5,YF=AF,JF=l1,ZF=FF,QF=OF,eB=IF,tB=NF,rB=VF,nB=LF,oB=zF,iB=HF,aB=jF;import{jsx as mt}from"react/jsx-runtime";var c5="DropdownMenu",[hie,wut]=cn(c5,[t5]),Ft=t5(),[gie,sB]=hie(c5),f5=e=>{let{__scopeDropdownMenu:t,children:r,dir:n,open:o,defaultOpen:a,onOpenChange:s,modal:u=!0}=e,l=Ft(t),c=st.useRef(null),[p=!1,d]=ll({prop:o,defaultProp:a,onChange:s});return mt(gie,{scope:t,triggerId:jo(),triggerRef:c,contentId:jo(),open:p,onOpenChange:d,onOpenToggle:st.useCallback(()=>d(h=>!h),[d]),modal:u,children:mt(WF,{...l,open:p,onOpenChange:d,dir:n,modal:u,children:r})})};f5.displayName=c5;var uB="DropdownMenuTrigger",p5=st.forwardRef((e,t)=>{let{__scopeDropdownMenu:r,disabled:n=!1,...o}=e,a=sB(uB,r),s=Ft(r);return mt(UF,{asChild:!0,...s,children:mt(Ue.button,{type:"button",id:a.triggerId,"aria-haspopup":"menu","aria-expanded":a.open,"aria-controls":a.open?a.contentId:void 0,"data-state":a.open?"open":"closed","data-disabled":n?"":void 0,disabled:n,...o,ref:Oi(t,a.triggerRef),onPointerDown:ye(e.onPointerDown,u=>{!n&&u.button===0&&u.ctrlKey===!1&&(a.onOpenToggle(),a.open||u.preventDefault())}),onKeyDown:ye(e.onKeyDown,u=>{n||(["Enter"," "].includes(u.key)&&a.onOpenToggle(),u.key==="ArrowDown"&&a.onOpenChange(!0),["Enter"," ","ArrowDown"].includes(u.key)&&u.preventDefault())})})})});p5.displayName=uB;var vie="DropdownMenuPortal",c1=e=>{let{__scopeDropdownMenu:t,...r}=e,n=Ft(t);return mt(KF,{...n,...r})};c1.displayName=vie;var lB="DropdownMenuContent",d5=st.forwardRef((e,t)=>{let{__scopeDropdownMenu:r,...n}=e,o=sB(lB,r),a=Ft(r),s=st.useRef(!1);return mt(qF,{id:o.contentId,"aria-labelledby":o.triggerId,...a,...n,ref:t,onCloseAutoFocus:ye(e.onCloseAutoFocus,u=>{s.current||o.triggerRef.current?.focus(),s.current=!1,u.preventDefault()}),onInteractOutside:ye(e.onInteractOutside,u=>{let l=u.detail.originalEvent,c=l.button===0&&l.ctrlKey===!0,p=l.button===2||c;(!o.modal||p)&&(s.current=!0)}),style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});d5.displayName=lB;var yie="DropdownMenuGroup",m5=st.forwardRef((e,t)=>{let{__scopeDropdownMenu:r,...n}=e,o=Ft(r);return mt(XF,{...o,...n,ref:t})});m5.displayName=yie;var bie="DropdownMenuLabel",h5=st.forwardRef((e,t)=>{let{__scopeDropdownMenu:r,...n}=e,o=Ft(r);return mt(YF,{...o,...n,ref:t})});h5.displayName=bie;var Cie="DropdownMenuItem",f1=st.forwardRef((e,t)=>{let{__scopeDropdownMenu:r,...n}=e,o=Ft(r);return mt(JF,{...o,...n,ref:t})});f1.displayName=Cie;var xie="DropdownMenuCheckboxItem",g5=st.forwardRef((e,t)=>{let{__scopeDropdownMenu:r,...n}=e,o=Ft(r);return mt(ZF,{...o,...n,ref:t})});g5.displayName=xie;var wie="DropdownMenuRadioGroup",v5=st.forwardRef((e,t)=>{let{__scopeDropdownMenu:r,...n}=e,o=Ft(r);return mt(QF,{...o,...n,ref:t})});v5.displayName=wie;var Sie="DropdownMenuRadioItem",y5=st.forwardRef((e,t)=>{let{__scopeDropdownMenu:r,...n}=e,o=Ft(r);return mt(eB,{...o,...n,ref:t})});y5.displayName=Sie;var Die="DropdownMenuItemIndicator",p1=st.forwardRef((e,t)=>{let{__scopeDropdownMenu:r,...n}=e,o=Ft(r);return mt(tB,{...o,...n,ref:t})});p1.displayName=Die;var Eie="DropdownMenuSeparator",Pie=st.forwardRef((e,t)=>{let{__scopeDropdownMenu:r,...n}=e,o=Ft(r);return mt(rB,{...o,...n,ref:t})});Pie.displayName=Eie;var Tie="DropdownMenuArrow",Aie=st.forwardRef((e,t)=>{let{__scopeDropdownMenu:r,...n}=e,o=Ft(r);return mt(nB,{...o,...n,ref:t})});Aie.displayName=Tie;var cB=e=>{let{__scopeDropdownMenu:t,children:r,open:n,onOpenChange:o,defaultOpen:a}=e,s=Ft(t),[u=!1,l]=ll({prop:n,defaultProp:a,onChange:o});return mt(oB,{...s,open:u,onOpenChange:l,children:r})},Rie="DropdownMenuSubTrigger",b5=st.forwardRef((e,t)=>{let{__scopeDropdownMenu:r,...n}=e,o=Ft(r);return mt(iB,{...o,...n,ref:t})});b5.displayName=Rie;var Fie="DropdownMenuSubContent",C5=st.forwardRef((e,t)=>{let{__scopeDropdownMenu:r,...n}=e,o=Ft(r);return mt(aB,{...o,...n,ref:t,style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});C5.displayName=Fie;var El=U(Z());i();var ut=U(Z());import Os,{css as Bie}from"styled-components";import{jsx as Je,jsxs as Wr}from"react/jsx-runtime";var fB="0.08",Oie=Bie`
2127
2127
  &:hover {
2128
2128
  background-color: ${({theme:e})=>e.color.red100};
2129
2129
  color: ${({theme:e})=>e.color.red600};
@@ -2186,14 +2186,14 @@ var zO=Object.create;var Nl=Object.defineProperty;var HO=Object.getOwnPropertyDe
2186
2186
  grid-row: span 2;
2187
2187
  text-align: center;
2188
2188
  width: 0;
2189
- `,Mut=({children:e,label:t,description:r,badge:n,icon:o,renderAs:a,href:s,variant:u="primary",...l})=>{let c=a;return(0,wt.isUndefined)(a)&&(c=(0,wt.isNotUndefined)(s)?"a":"div"),Je(f1,{style:{outline:"none"},...l,asChild:!0,children:Je(d1,{as:c,href:s,variant:u,children:(0,wt.isNotUndefined)(e)?e:Wr(m1,{children:[(0,wt.isNotUndefined)(o)&&Je(g1,{children:o}),Wr(h1,{children:[t," ",n]}),(0,wt.isNotUndefined)(r)?Je(dr,{variant:"caption",children:r}):null]})})})},Iut=({children:e,label:t,description:r,badge:n,icon:o,indicator:a=Je(De,{size:"sm",type:"checkmark"}),...s})=>Je(g5,{...s,asChild:!0,children:Wr(d1,{children:[(0,wt.isNotUndefined)(e)?e:Wr(m1,{children:[(0,wt.isNotUndefined)(o)?Je(g1,{children:o}):Je(x5,{}),Wr(h1,{children:[t," ",n]}),(0,wt.isNotUndefined)(r)?Je(dr,{variant:"caption",children:r}):null]}),Je(p1,{children:a})]})}),kut=({children:e,label:t,badge:r,description:n,icon:o,indicator:a=Je(De,{size:"sm",type:"checkmark"}),...s})=>Je(y5,{...s,asChild:!0,children:Wr(d1,{children:[(0,wt.isNotUndefined)(e)?e:Wr(m1,{children:[(0,wt.isNotUndefined)(o)?Je(g1,{children:o}):Je(x5,{}),Wr(h1,{children:[t," ",r]})," ",(0,wt.isNotUndefined)(n)?Je(dr,{variant:"caption",children:n}):null]}),Je(p1,{children:a})]})}),Mie=Os(b5)`
2189
+ `,Mut=({children:e,label:t,description:r,badge:n,icon:o,renderAs:a,href:s,target:u,variant:l="primary",...c})=>{let p=a;return(0,ut.isUndefined)(a)&&(p=(0,ut.isNotUndefined)(s)?"a":"div"),Je(f1,{style:{outline:"none"},...c,asChild:!0,children:Je(d1,{as:p,href:s,variant:l,...p==="a"&&(0,ut.isNonEmptyString)(u)?{target:u}:{},children:(0,ut.isNotUndefined)(e)?e:Wr(m1,{children:[(0,ut.isNotUndefined)(o)&&Je(g1,{children:o}),Wr(h1,{children:[t," ",n]}),(0,ut.isNotUndefined)(r)?Je(dr,{variant:"caption",children:r}):null]})})})},Iut=({children:e,label:t,description:r,badge:n,icon:o,indicator:a=Je(De,{size:"sm",type:"checkmark"}),...s})=>Je(g5,{...s,asChild:!0,children:Wr(d1,{children:[(0,ut.isNotUndefined)(e)?e:Wr(m1,{children:[(0,ut.isNotUndefined)(o)?Je(g1,{children:o}):Je(x5,{}),Wr(h1,{children:[t," ",n]}),(0,ut.isNotUndefined)(r)?Je(dr,{variant:"caption",children:r}):null]}),Je(p1,{children:a})]})}),kut=({children:e,label:t,badge:r,description:n,icon:o,indicator:a=Je(De,{size:"sm",type:"checkmark"}),...s})=>Je(y5,{...s,asChild:!0,children:Wr(d1,{children:[(0,ut.isNotUndefined)(e)?e:Wr(m1,{children:[(0,ut.isNotUndefined)(o)?Je(g1,{children:o}):Je(x5,{}),Wr(h1,{children:[t," ",r]})," ",(0,ut.isNotUndefined)(n)?Je(dr,{variant:"caption",children:n}):null]}),Je(p1,{children:a})]})}),Mie=Os(b5)`
2190
2190
  outline: none;
2191
2191
 
2192
2192
  &[data-state='open'],
2193
2193
  &[data-highlighted] {
2194
2194
  background-color: ${({theme:e})=>e.color.grey200};
2195
2195
  }
2196
- `,w5=({children:e,label:t,badge:r,description:n,icon:o,onClick:a})=>{let{isSmAndUp:s}=Mn();return Je(s?Mie:f1,{onClick:l=>{(0,wt.isNotUndefined)(a)&&a(l)},children:Wr(d1,{children:[(0,wt.isNotUndefined)(e)?e:Wr(m1,{children:[(0,wt.isNotUndefined)(o)?Je(g1,{children:o}):Je(x5,{}),Wr(h1,{children:[t," ",r]}),(0,wt.isNotUndefined)(n)?Je(dr,{variant:"caption",children:n}):null]}),Je(De,{size:"md",type:"caret-right"})]})})};import{jsx as Ur,jsxs as S5}from"react/jsx-runtime";var Dl="8px",Nie=pB`
2196
+ `,w5=({children:e,label:t,badge:r,description:n,icon:o,onClick:a})=>{let{isSmAndUp:s}=Mn();return Je(s?Mie:f1,{onClick:l=>{(0,ut.isNotUndefined)(a)&&a(l)},children:Wr(d1,{children:[(0,ut.isNotUndefined)(e)?e:Wr(m1,{children:[(0,ut.isNotUndefined)(o)?Je(g1,{children:o}):Je(x5,{}),Wr(h1,{children:[t," ",r]}),(0,ut.isNotUndefined)(n)?Je(dr,{variant:"caption",children:n}):null]}),Je(De,{size:"md",type:"caret-right"})]})})};import{jsx as Ur,jsxs as S5}from"react/jsx-runtime";var Dl="8px",Nie=pB`
2197
2197
  from {
2198
2198
  opacity: 0;
2199
2199
  transform: scale(.97) translateY(-8px);
@@ -2698,7 +2698,7 @@ var zO=Object.create;var Nl=Object.defineProperty;var HO=Object.getOwnPropertyDe
2698
2698
  visibility: hidden;
2699
2699
  width: calc(100% + 40px);
2700
2700
  }
2701
- `,yO=({align:e="left",buttonVariant:t="secondary",earliestDate:r,latestDate:n,format:o=Zae,fullWidth:a=!1,footerText:s,onChange:u,presets:l=[],range:c={end:new Date,start:new Date},shouldPreventFuture:p=!1,...d})=>{let[h,g]=Il(c),[v,m]=Il(!1),[b,y]=Il(!0),[x,w]=Il("end"),[S,E]=Il([]),D=On();return gO(()=>{g(c)},[c]),gO(()=>{let R=()=>{m(!1),g(c)};return v&&window.addEventListener("click",R),()=>{window.removeEventListener("click",R)}},[v,c,g]),Ki(tse,{"data-testid":"rangeselector-test-identifer",onClick:R=>R.stopPropagation(),children:[Bt(rse,{...d,"data-testid":"trigger",fullWidth:a,icon:Bt(De,{size:"sm",type:"caret-down"}),iconPosition:"end",inputButtonOverride:t==="input",onClick:()=>m(!v),textAlign:"left",variant:t==="input"?"tertiary":t,children:o(c)}),v?Ki(ise,{align:e,hasPresets:!!l.length,children:[Ki(ase,{children:[!!l.length&&Bt(Nd,{"data-testid":"presets",style:{marginBottom:0,borderRight:`1px solid ${D.color.grey400}`,padding:"12px"},variant:"unbulleted",children:l.map(({label:R,value:F,tooltipText:M})=>Bt(xs,{children:Bt(nse,{"data-testid":R?.replaceAll(" ","_"),isActive:Qae(h,F),onClick:()=>{g(F)},children:Ki(lse,{"data-title":`${R}___`,children:[R," ",M!==void 0?Bt(Jae,{tooltipText:M}):null]})})},R))}),Bt(sse,{children:Ki(ese,{children:[Bt(O1,{earliestDate:r,latestDate:n,onChange:R=>{g(R)},onErrorChange:E,onSelectedRangePartChange:w,range:h,shouldPreventFuture:p,width:"100%"}),Bt(P1,{earliestDate:r,latestDate:n,onChange:R=>{g(R)},onIsValidChange:y,range:h,rangePartToShow:x,shouldPreventFuture:p})]})})]}),Bt(ose,{}),Ki(use,{children:[Bt("div",{children:s}),Ki(Fo,{align:"right",children:[Bt(et,{onClick:()=>{g(c),m(!1)},style:{marginLeft:0},variant:"secondary",children:"Cancel"}),Bt(et,{"data-testid":"apply-button",disabled:!!S.length||!b,onMouseUp:()=>{u&&u(h),m(!1)},children:"Apply"})]})]})]}):null]})};yO.displayName="RangeSelector_VHS";i();i();import G5,{css as cse}from"styled-components";i();i();i();i();function M1(e,t){return M1=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,n){return r.__proto__=n,r},M1(e,t)}function bO(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,M1(e,t)}import Ns from"react";function V5(e){return e&&e.stopPropagation&&e.stopPropagation(),e&&e.preventDefault&&e.preventDefault(),!1}function L5(e){return e==null?[]:Array.isArray(e)?e.slice():[e]}function I1(e){return e!==null&&e.length===1?e[0]:e.slice()}function k1(e){Object.keys(e).forEach(t=>{typeof document<"u"&&document.addEventListener(t,e[t],!1)})}function qi(e,t){return $5(function(r,n){let o=r;return o<=n.min&&(o=n.min),o>=n.max&&(o=n.max),o}(e,t),t)}function $5(e,t){let r=(e-t.min)%t.step,n=e-r;return 2*Math.abs(r)>=t.step&&(n+=r>0?t.step:-t.step),parseFloat(n.toFixed(5))}var z5=function(e){function t(n){var o;(o=e.call(this,n)||this).onKeyUp=()=>{o.onEnd()},o.onMouseUp=()=>{o.onEnd(o.getMouseEventMap())},o.onTouchEnd=u=>{u.preventDefault(),o.onEnd(o.getTouchEventMap())},o.onBlur=()=>{o.setState({index:-1},o.onEnd(o.getKeyDownEventMap()))},o.onMouseMove=u=>{o.setState({pending:!0});let l=o.getMousePosition(u),c=o.getDiffPosition(l[0]),p=o.getValueFromPosition(c);o.move(p)},o.onTouchMove=u=>{if(u.touches.length>1)return;o.setState({pending:!0});let l=o.getTouchPosition(u);if(o.isScrolling===void 0){let d=l[0]-o.startPosition[0],h=l[1]-o.startPosition[1];o.isScrolling=Math.abs(h)>Math.abs(d)}if(o.isScrolling)return void o.setState({index:-1});let c=o.getDiffPosition(l[0]),p=o.getValueFromPosition(c);o.move(p)},o.onKeyDown=u=>{if(!(u.ctrlKey||u.shiftKey||u.altKey||u.metaKey))switch(o.setState({pending:!0}),u.key){case"ArrowLeft":case"ArrowDown":case"Left":case"Down":u.preventDefault(),o.moveDownByStep();break;case"ArrowRight":case"ArrowUp":case"Right":case"Up":u.preventDefault(),o.moveUpByStep();break;case"Home":u.preventDefault(),o.move(o.props.min);break;case"End":u.preventDefault(),o.move(o.props.max);break;case"PageDown":u.preventDefault(),o.moveDownByStep(o.props.pageFn(o.props.step));break;case"PageUp":u.preventDefault(),o.moveUpByStep(o.props.pageFn(o.props.step))}},o.onSliderMouseDown=u=>{if(!o.props.disabled&&u.button!==2){if(o.setState({pending:!0}),!o.props.snapDragDisabled){let l=o.getMousePosition(u);o.forceValueFromPosition(l[0],c=>{o.start(c,l[0]),k1(o.getMouseEventMap())})}V5(u)}},o.onSliderClick=u=>{if(!o.props.disabled&&o.props.onSliderClick&&!o.hasMoved){let l=o.getMousePosition(u),c=qi(o.calcValue(o.calcOffsetFromPosition(l[0])),o.props);o.props.onSliderClick(c)}},o.createOnKeyDown=u=>l=>{o.props.disabled||(o.start(u),k1(o.getKeyDownEventMap()),V5(l))},o.createOnMouseDown=u=>l=>{if(o.props.disabled||l.button===2)return;o.setState({pending:!0});let c=o.getMousePosition(l);o.start(u,c[0]),k1(o.getMouseEventMap()),V5(l)},o.createOnTouchStart=u=>l=>{if(o.props.disabled||l.touches.length>1)return;o.setState({pending:!0});let c=o.getTouchPosition(l);o.startPosition=c,o.isScrolling=void 0,o.start(u,c[0]),k1(o.getTouchEventMap()),function(p){p.stopPropagation&&p.stopPropagation()}(l)},o.handleResize=()=>{let u=window.setTimeout(()=>{o.pendingResizeTimeouts.shift(),o.resize()},0);o.pendingResizeTimeouts.push(u)},o.renderThumb=(u,l)=>{let c=o.props.thumbClassName+" "+o.props.thumbClassName+"-"+l+" "+(o.state.index===l?o.props.thumbActiveClassName:""),p={ref:h=>{o["thumb"+l]=h},key:o.props.thumbClassName+"-"+l,className:c,style:u,onMouseDown:o.createOnMouseDown(l),onTouchStart:o.createOnTouchStart(l),onFocus:o.createOnKeyDown(l),tabIndex:0,role:"slider","aria-orientation":o.props.orientation,"aria-valuenow":o.state.value[l],"aria-valuemin":o.props.min,"aria-valuemax":o.props.max,"aria-label":Array.isArray(o.props.ariaLabel)?o.props.ariaLabel[l]:o.props.ariaLabel,"aria-labelledby":Array.isArray(o.props.ariaLabelledby)?o.props.ariaLabelledby[l]:o.props.ariaLabelledby,"aria-disabled":o.props.disabled},d={index:l,value:I1(o.state.value),valueNow:o.state.value[l]};return o.props.ariaValuetext&&(p["aria-valuetext"]=typeof o.props.ariaValuetext=="string"?o.props.ariaValuetext:o.props.ariaValuetext(d)),o.props.renderThumb(p,d)},o.renderTrack=(u,l,c)=>{let p={key:o.props.trackClassName+"-"+u,className:o.props.trackClassName+" "+o.props.trackClassName+"-"+u,style:o.buildTrackStyle(l,o.state.upperBound-c)},d={index:u,value:I1(o.state.value)};return o.props.renderTrack(p,d)};let a=L5(n.value);a.length||(a=L5(n.defaultValue)),o.pendingResizeTimeouts=[];let s=[];for(let u=0;u<a.length;u+=1)a[u]=qi(a[u],n),s.push(u);return o.resizeObserver=null,o.resizeElementRef=Ns.createRef(),o.state={index:-1,upperBound:0,sliderLength:0,value:a,zIndices:s},o}bO(t,e);var r=t.prototype;return r.componentDidMount=function(){typeof window<"u"&&(this.resizeObserver=new ResizeObserver(this.handleResize),this.resizeObserver.observe(this.resizeElementRef.current),this.resize())},t.getDerivedStateFromProps=function(n,o){let a=L5(n.value);return a.length?o.pending?null:{value:a.map(s=>qi(s,n))}:null},r.componentDidUpdate=function(){this.state.upperBound===0&&this.resize()},r.componentWillUnmount=function(){this.clearPendingResizeTimeouts(),this.resizeObserver&&this.resizeObserver.disconnect()},r.onEnd=function(n){n&&function(o){Object.keys(o).forEach(a=>{typeof document<"u"&&document.removeEventListener(a,o[a],!1)})}(n),this.hasMoved&&this.fireChangeEvent("onAfterChange"),this.setState({pending:!1}),this.hasMoved=!1},r.getValue=function(){return I1(this.state.value)},r.getClosestIndex=function(n){let o=Number.MAX_VALUE,a=-1,{value:s}=this.state,u=s.length;for(let l=0;l<u;l+=1){let c=this.calcOffset(s[l]),p=Math.abs(n-c);p<o&&(o=p,a=l)}return a},r.getMousePosition=function(n){return[n["page"+this.axisKey()],n["page"+this.orthogonalAxisKey()]]},r.getTouchPosition=function(n){let o=n.touches[0];return[o["page"+this.axisKey()],o["page"+this.orthogonalAxisKey()]]},r.getKeyDownEventMap=function(){return{keydown:this.onKeyDown,keyup:this.onKeyUp,focusout:this.onBlur}},r.getMouseEventMap=function(){return{mousemove:this.onMouseMove,mouseup:this.onMouseUp}},r.getTouchEventMap=function(){return{touchmove:this.onTouchMove,touchend:this.onTouchEnd}},r.getValueFromPosition=function(n){let o=n/(this.state.sliderLength-this.state.thumbSize)*(this.props.max-this.props.min);return qi(this.state.startValue+o,this.props)},r.getDiffPosition=function(n){let o=n-this.state.startPosition;return this.props.invert&&(o*=-1),o},r.resize=function(){let{slider:n,thumb0:o}=this;if(!n||!o)return;let a=this.sizeKey(),s=n.getBoundingClientRect(),u=n[a],l=s[this.posMaxKey()],c=s[this.posMinKey()],p=o.getBoundingClientRect()[a.replace("client","").toLowerCase()],d=u-p,h=Math.abs(l-c);this.state.upperBound===d&&this.state.sliderLength===h&&this.state.thumbSize===p||this.setState({upperBound:d,sliderLength:h,thumbSize:p})},r.calcOffset=function(n){let o=this.props.max-this.props.min;return o===0?0:(n-this.props.min)/o*this.state.upperBound},r.calcValue=function(n){return n/this.state.upperBound*(this.props.max-this.props.min)+this.props.min},r.calcOffsetFromPosition=function(n){let{slider:o}=this,a=o.getBoundingClientRect(),s=a[this.posMaxKey()],u=a[this.posMinKey()],l=n-(window["page"+this.axisKey()+"Offset"]+(this.props.invert?s:u));return this.props.invert&&(l=this.state.sliderLength-l),l-=this.state.thumbSize/2,l},r.forceValueFromPosition=function(n,o){let a=this.calcOffsetFromPosition(n),s=this.getClosestIndex(a),u=qi(this.calcValue(a),this.props),l=this.state.value.slice();l[s]=u;for(let c=0;c<l.length-1;c+=1)if(l[c+1]-l[c]<this.props.minDistance)return;this.fireChangeEvent("onBeforeChange"),this.hasMoved=!0,this.setState({value:l},()=>{o(s),this.fireChangeEvent("onChange")})},r.clearPendingResizeTimeouts=function(){do{let n=this.pendingResizeTimeouts.shift();clearTimeout(n)}while(this.pendingResizeTimeouts.length)},r.start=function(n,o){let a=this["thumb"+n];a&&a.focus();let{zIndices:s}=this.state;s.splice(s.indexOf(n),1),s.push(n),this.setState(u=>({startValue:u.value[n],startPosition:o!==void 0?o:u.startPosition,index:n,zIndices:s}))},r.moveUpByStep=function(n){n===void 0&&(n=this.props.step);let o=this.state.value[this.state.index],a=qi(this.props.invert&&this.props.orientation==="horizontal"?o-n:o+n,this.props);this.move(Math.min(a,this.props.max))},r.moveDownByStep=function(n){n===void 0&&(n=this.props.step);let o=this.state.value[this.state.index],a=qi(this.props.invert&&this.props.orientation==="horizontal"?o+n:o-n,this.props);this.move(Math.max(a,this.props.min))},r.move=function(n){let o=this.state.value.slice(),{index:a}=this.state,{length:s}=o,u=o[a];if(n===u)return;this.hasMoved||this.fireChangeEvent("onBeforeChange"),this.hasMoved=!0;let{pearling:l,max:c,min:p,minDistance:d}=this.props;if(!l){if(a>0){let h=o[a-1];n<h+d&&(n=h+d)}if(a<s-1){let h=o[a+1];n>h-d&&(n=h-d)}}o[a]=n,l&&s>1&&(n>u?(this.pushSucceeding(o,d,a),function(h,g,v,m){for(let b=0;b<h;b+=1){let y=m-b*v;g[h-1-b]>y&&(g[h-1-b]=y)}}(s,o,d,c)):n<u&&(this.pushPreceding(o,d,a),function(h,g,v,m){for(let b=0;b<h;b+=1){let y=m+b*v;g[b]<y&&(g[b]=y)}}(s,o,d,p))),this.setState({value:o},this.fireChangeEvent.bind(this,"onChange"))},r.pushSucceeding=function(n,o,a){let s,u;for(s=a,u=n[s]+o;n[s+1]!==null&&u>n[s+1];s+=1,u=n[s]+o)n[s+1]=$5(u,this.props)},r.pushPreceding=function(n,o,a){for(let s=a,u=n[s]-o;n[s-1]!==null&&u<n[s-1];s-=1,u=n[s]-o)n[s-1]=$5(u,this.props)},r.axisKey=function(){return this.props.orientation==="vertical"?"Y":"X"},r.orthogonalAxisKey=function(){return this.props.orientation==="vertical"?"X":"Y"},r.posMinKey=function(){return this.props.orientation==="vertical"?this.props.invert?"bottom":"top":this.props.invert?"right":"left"},r.posMaxKey=function(){return this.props.orientation==="vertical"?this.props.invert?"top":"bottom":this.props.invert?"left":"right"},r.sizeKey=function(){return this.props.orientation==="vertical"?"clientHeight":"clientWidth"},r.fireChangeEvent=function(n){this.props[n]&&this.props[n](I1(this.state.value),this.state.index)},r.buildThumbStyle=function(n,o){let a={position:"absolute",touchAction:"none",willChange:this.state.index>=0?this.posMinKey():void 0,zIndex:this.state.zIndices.indexOf(o)+1};return a[this.posMinKey()]=n+"px",a},r.buildTrackStyle=function(n,o){let a={position:"absolute",willChange:this.state.index>=0?this.posMinKey()+","+this.posMaxKey():void 0};return a[this.posMinKey()]=n,a[this.posMaxKey()]=o,a},r.buildMarkStyle=function(n){var o;return(o={position:"absolute"})[this.posMinKey()]=n,o},r.renderThumbs=function(n){let{length:o}=n,a=[];for(let u=0;u<o;u+=1)a[u]=this.buildThumbStyle(n[u],u);let s=[];for(let u=0;u<o;u+=1)s[u]=this.renderThumb(a[u],u);return s},r.renderTracks=function(n){let o=[],a=n.length-1;o.push(this.renderTrack(0,0,n[0]));for(let s=0;s<a;s+=1)o.push(this.renderTrack(s+1,n[s],n[s+1]));return o.push(this.renderTrack(a+1,n[a],this.state.upperBound)),o},r.renderMarks=function(){let{marks:n}=this.props,o=this.props.max-this.props.min+1;return typeof n=="boolean"?n=Array.from({length:o}).map((a,s)=>s):typeof n=="number"&&(n=Array.from({length:o}).map((a,s)=>s).filter(a=>a%n==0)),n.map(parseFloat).sort((a,s)=>a-s).map(a=>{let s=this.calcOffset(a),u={key:a,className:this.props.markClassName,style:this.buildMarkStyle(s)};return this.props.renderMark(u)})},r.render=function(){let n=[],{value:o}=this.state,a=o.length;for(let c=0;c<a;c+=1)n[c]=this.calcOffset(o[c],c);let s=this.props.withTracks?this.renderTracks(n):null,u=this.renderThumbs(n),l=this.props.marks?this.renderMarks():null;return Ns.createElement("div",{ref:c=>{this.slider=c,this.resizeElementRef.current=c},style:{position:"relative"},className:this.props.className+(this.props.disabled?" disabled":""),onMouseDown:this.onSliderMouseDown,onClick:this.onSliderClick},s,u,l)},t}(Ns.Component);z5.displayName="ReactSlider",z5.defaultProps={min:0,max:100,step:1,pageFn:e=>10*e,minDistance:0,defaultValue:0,orientation:"horizontal",className:"slider",thumbClassName:"thumb",thumbActiveClassName:"active",trackClassName:"track",markClassName:"mark",withTracks:!0,pearling:!1,disabled:!1,snapDragDisabled:!1,invert:!1,marks:[],renderThumb:e=>Ns.createElement("div",e),renderTrack:e=>Ns.createElement("div",e),renderMark:e=>Ns.createElement("span",e)};var H5=z5;var mt=U(Z());import{jsx as kl}from"react/jsx-runtime";var CO="4px",fse=cse`
2701
+ `,yO=({align:e="left",buttonVariant:t="secondary",earliestDate:r,latestDate:n,format:o=Zae,fullWidth:a=!1,footerText:s,onChange:u,presets:l=[],range:c={end:new Date,start:new Date},shouldPreventFuture:p=!1,...d})=>{let[h,g]=Il(c),[v,m]=Il(!1),[b,y]=Il(!0),[x,w]=Il("end"),[S,E]=Il([]),D=On();return gO(()=>{g(c)},[c]),gO(()=>{let R=()=>{m(!1),g(c)};return v&&window.addEventListener("click",R),()=>{window.removeEventListener("click",R)}},[v,c,g]),Ki(tse,{"data-testid":"rangeselector-test-identifer",onClick:R=>R.stopPropagation(),children:[Bt(rse,{...d,"data-testid":"trigger",fullWidth:a,icon:Bt(De,{size:"sm",type:"caret-down"}),iconPosition:"end",inputButtonOverride:t==="input",onClick:()=>m(!v),textAlign:"left",variant:t==="input"?"tertiary":t,children:o(c)}),v?Ki(ise,{align:e,hasPresets:!!l.length,children:[Ki(ase,{children:[!!l.length&&Bt(Nd,{"data-testid":"presets",style:{marginBottom:0,borderRight:`1px solid ${D.color.grey400}`,padding:"12px"},variant:"unbulleted",children:l.map(({label:R,value:F,tooltipText:M})=>Bt(xs,{children:Bt(nse,{"data-testid":R?.replaceAll(" ","_"),isActive:Qae(h,F),onClick:()=>{g(F)},children:Ki(lse,{"data-title":`${R}___`,children:[R," ",M!==void 0?Bt(Jae,{tooltipText:M}):null]})})},R))}),Bt(sse,{children:Ki(ese,{children:[Bt(O1,{earliestDate:r,latestDate:n,onChange:R=>{g(R)},onErrorChange:E,onSelectedRangePartChange:w,range:h,shouldPreventFuture:p,width:"100%"}),Bt(P1,{earliestDate:r,latestDate:n,onChange:R=>{g(R)},onIsValidChange:y,range:h,rangePartToShow:x,shouldPreventFuture:p})]})})]}),Bt(ose,{}),Ki(use,{children:[Bt("div",{children:s}),Ki(Fo,{align:"right",children:[Bt(et,{onClick:()=>{g(c),m(!1)},style:{marginLeft:0},variant:"secondary",children:"Cancel"}),Bt(et,{"data-testid":"apply-button",disabled:!!S.length||!b,onMouseUp:()=>{u&&u(h),m(!1)},children:"Apply"})]})]})]}):null]})};yO.displayName="RangeSelector_VHS";i();i();import G5,{css as cse}from"styled-components";i();i();i();i();function M1(e,t){return M1=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,n){return r.__proto__=n,r},M1(e,t)}function bO(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,M1(e,t)}import Ns from"react";function V5(e){return e&&e.stopPropagation&&e.stopPropagation(),e&&e.preventDefault&&e.preventDefault(),!1}function L5(e){return e==null?[]:Array.isArray(e)?e.slice():[e]}function I1(e){return e!==null&&e.length===1?e[0]:e.slice()}function k1(e){Object.keys(e).forEach(t=>{typeof document<"u"&&document.addEventListener(t,e[t],!1)})}function qi(e,t){return $5(function(r,n){let o=r;return o<=n.min&&(o=n.min),o>=n.max&&(o=n.max),o}(e,t),t)}function $5(e,t){let r=(e-t.min)%t.step,n=e-r;return 2*Math.abs(r)>=t.step&&(n+=r>0?t.step:-t.step),parseFloat(n.toFixed(5))}var z5=function(e){function t(n){var o;(o=e.call(this,n)||this).onKeyUp=()=>{o.onEnd()},o.onMouseUp=()=>{o.onEnd(o.getMouseEventMap())},o.onTouchEnd=u=>{u.preventDefault(),o.onEnd(o.getTouchEventMap())},o.onBlur=()=>{o.setState({index:-1},o.onEnd(o.getKeyDownEventMap()))},o.onMouseMove=u=>{o.setState({pending:!0});let l=o.getMousePosition(u),c=o.getDiffPosition(l[0]),p=o.getValueFromPosition(c);o.move(p)},o.onTouchMove=u=>{if(u.touches.length>1)return;o.setState({pending:!0});let l=o.getTouchPosition(u);if(o.isScrolling===void 0){let d=l[0]-o.startPosition[0],h=l[1]-o.startPosition[1];o.isScrolling=Math.abs(h)>Math.abs(d)}if(o.isScrolling)return void o.setState({index:-1});let c=o.getDiffPosition(l[0]),p=o.getValueFromPosition(c);o.move(p)},o.onKeyDown=u=>{if(!(u.ctrlKey||u.shiftKey||u.altKey||u.metaKey))switch(o.setState({pending:!0}),u.key){case"ArrowLeft":case"ArrowDown":case"Left":case"Down":u.preventDefault(),o.moveDownByStep();break;case"ArrowRight":case"ArrowUp":case"Right":case"Up":u.preventDefault(),o.moveUpByStep();break;case"Home":u.preventDefault(),o.move(o.props.min);break;case"End":u.preventDefault(),o.move(o.props.max);break;case"PageDown":u.preventDefault(),o.moveDownByStep(o.props.pageFn(o.props.step));break;case"PageUp":u.preventDefault(),o.moveUpByStep(o.props.pageFn(o.props.step))}},o.onSliderMouseDown=u=>{if(!o.props.disabled&&u.button!==2){if(o.setState({pending:!0}),!o.props.snapDragDisabled){let l=o.getMousePosition(u);o.forceValueFromPosition(l[0],c=>{o.start(c,l[0]),k1(o.getMouseEventMap())})}V5(u)}},o.onSliderClick=u=>{if(!o.props.disabled&&o.props.onSliderClick&&!o.hasMoved){let l=o.getMousePosition(u),c=qi(o.calcValue(o.calcOffsetFromPosition(l[0])),o.props);o.props.onSliderClick(c)}},o.createOnKeyDown=u=>l=>{o.props.disabled||(o.start(u),k1(o.getKeyDownEventMap()),V5(l))},o.createOnMouseDown=u=>l=>{if(o.props.disabled||l.button===2)return;o.setState({pending:!0});let c=o.getMousePosition(l);o.start(u,c[0]),k1(o.getMouseEventMap()),V5(l)},o.createOnTouchStart=u=>l=>{if(o.props.disabled||l.touches.length>1)return;o.setState({pending:!0});let c=o.getTouchPosition(l);o.startPosition=c,o.isScrolling=void 0,o.start(u,c[0]),k1(o.getTouchEventMap()),function(p){p.stopPropagation&&p.stopPropagation()}(l)},o.handleResize=()=>{let u=window.setTimeout(()=>{o.pendingResizeTimeouts.shift(),o.resize()},0);o.pendingResizeTimeouts.push(u)},o.renderThumb=(u,l)=>{let c=o.props.thumbClassName+" "+o.props.thumbClassName+"-"+l+" "+(o.state.index===l?o.props.thumbActiveClassName:""),p={ref:h=>{o["thumb"+l]=h},key:o.props.thumbClassName+"-"+l,className:c,style:u,onMouseDown:o.createOnMouseDown(l),onTouchStart:o.createOnTouchStart(l),onFocus:o.createOnKeyDown(l),tabIndex:0,role:"slider","aria-orientation":o.props.orientation,"aria-valuenow":o.state.value[l],"aria-valuemin":o.props.min,"aria-valuemax":o.props.max,"aria-label":Array.isArray(o.props.ariaLabel)?o.props.ariaLabel[l]:o.props.ariaLabel,"aria-labelledby":Array.isArray(o.props.ariaLabelledby)?o.props.ariaLabelledby[l]:o.props.ariaLabelledby,"aria-disabled":o.props.disabled},d={index:l,value:I1(o.state.value),valueNow:o.state.value[l]};return o.props.ariaValuetext&&(p["aria-valuetext"]=typeof o.props.ariaValuetext=="string"?o.props.ariaValuetext:o.props.ariaValuetext(d)),o.props.renderThumb(p,d)},o.renderTrack=(u,l,c)=>{let p={key:o.props.trackClassName+"-"+u,className:o.props.trackClassName+" "+o.props.trackClassName+"-"+u,style:o.buildTrackStyle(l,o.state.upperBound-c)},d={index:u,value:I1(o.state.value)};return o.props.renderTrack(p,d)};let a=L5(n.value);a.length||(a=L5(n.defaultValue)),o.pendingResizeTimeouts=[];let s=[];for(let u=0;u<a.length;u+=1)a[u]=qi(a[u],n),s.push(u);return o.resizeObserver=null,o.resizeElementRef=Ns.createRef(),o.state={index:-1,upperBound:0,sliderLength:0,value:a,zIndices:s},o}bO(t,e);var r=t.prototype;return r.componentDidMount=function(){typeof window<"u"&&(this.resizeObserver=new ResizeObserver(this.handleResize),this.resizeObserver.observe(this.resizeElementRef.current),this.resize())},t.getDerivedStateFromProps=function(n,o){let a=L5(n.value);return a.length?o.pending?null:{value:a.map(s=>qi(s,n))}:null},r.componentDidUpdate=function(){this.state.upperBound===0&&this.resize()},r.componentWillUnmount=function(){this.clearPendingResizeTimeouts(),this.resizeObserver&&this.resizeObserver.disconnect()},r.onEnd=function(n){n&&function(o){Object.keys(o).forEach(a=>{typeof document<"u"&&document.removeEventListener(a,o[a],!1)})}(n),this.hasMoved&&this.fireChangeEvent("onAfterChange"),this.setState({pending:!1}),this.hasMoved=!1},r.getValue=function(){return I1(this.state.value)},r.getClosestIndex=function(n){let o=Number.MAX_VALUE,a=-1,{value:s}=this.state,u=s.length;for(let l=0;l<u;l+=1){let c=this.calcOffset(s[l]),p=Math.abs(n-c);p<o&&(o=p,a=l)}return a},r.getMousePosition=function(n){return[n["page"+this.axisKey()],n["page"+this.orthogonalAxisKey()]]},r.getTouchPosition=function(n){let o=n.touches[0];return[o["page"+this.axisKey()],o["page"+this.orthogonalAxisKey()]]},r.getKeyDownEventMap=function(){return{keydown:this.onKeyDown,keyup:this.onKeyUp,focusout:this.onBlur}},r.getMouseEventMap=function(){return{mousemove:this.onMouseMove,mouseup:this.onMouseUp}},r.getTouchEventMap=function(){return{touchmove:this.onTouchMove,touchend:this.onTouchEnd}},r.getValueFromPosition=function(n){let o=n/(this.state.sliderLength-this.state.thumbSize)*(this.props.max-this.props.min);return qi(this.state.startValue+o,this.props)},r.getDiffPosition=function(n){let o=n-this.state.startPosition;return this.props.invert&&(o*=-1),o},r.resize=function(){let{slider:n,thumb0:o}=this;if(!n||!o)return;let a=this.sizeKey(),s=n.getBoundingClientRect(),u=n[a],l=s[this.posMaxKey()],c=s[this.posMinKey()],p=o.getBoundingClientRect()[a.replace("client","").toLowerCase()],d=u-p,h=Math.abs(l-c);this.state.upperBound===d&&this.state.sliderLength===h&&this.state.thumbSize===p||this.setState({upperBound:d,sliderLength:h,thumbSize:p})},r.calcOffset=function(n){let o=this.props.max-this.props.min;return o===0?0:(n-this.props.min)/o*this.state.upperBound},r.calcValue=function(n){return n/this.state.upperBound*(this.props.max-this.props.min)+this.props.min},r.calcOffsetFromPosition=function(n){let{slider:o}=this,a=o.getBoundingClientRect(),s=a[this.posMaxKey()],u=a[this.posMinKey()],l=n-(window["page"+this.axisKey()+"Offset"]+(this.props.invert?s:u));return this.props.invert&&(l=this.state.sliderLength-l),l-=this.state.thumbSize/2,l},r.forceValueFromPosition=function(n,o){let a=this.calcOffsetFromPosition(n),s=this.getClosestIndex(a),u=qi(this.calcValue(a),this.props),l=this.state.value.slice();l[s]=u;for(let c=0;c<l.length-1;c+=1)if(l[c+1]-l[c]<this.props.minDistance)return;this.fireChangeEvent("onBeforeChange"),this.hasMoved=!0,this.setState({value:l},()=>{o(s),this.fireChangeEvent("onChange")})},r.clearPendingResizeTimeouts=function(){do{let n=this.pendingResizeTimeouts.shift();clearTimeout(n)}while(this.pendingResizeTimeouts.length)},r.start=function(n,o){let a=this["thumb"+n];a&&a.focus();let{zIndices:s}=this.state;s.splice(s.indexOf(n),1),s.push(n),this.setState(u=>({startValue:u.value[n],startPosition:o!==void 0?o:u.startPosition,index:n,zIndices:s}))},r.moveUpByStep=function(n){n===void 0&&(n=this.props.step);let o=this.state.value[this.state.index],a=qi(this.props.invert&&this.props.orientation==="horizontal"?o-n:o+n,this.props);this.move(Math.min(a,this.props.max))},r.moveDownByStep=function(n){n===void 0&&(n=this.props.step);let o=this.state.value[this.state.index],a=qi(this.props.invert&&this.props.orientation==="horizontal"?o+n:o-n,this.props);this.move(Math.max(a,this.props.min))},r.move=function(n){let o=this.state.value.slice(),{index:a}=this.state,{length:s}=o,u=o[a];if(n===u)return;this.hasMoved||this.fireChangeEvent("onBeforeChange"),this.hasMoved=!0;let{pearling:l,max:c,min:p,minDistance:d}=this.props;if(!l){if(a>0){let h=o[a-1];n<h+d&&(n=h+d)}if(a<s-1){let h=o[a+1];n>h-d&&(n=h-d)}}o[a]=n,l&&s>1&&(n>u?(this.pushSucceeding(o,d,a),function(h,g,v,m){for(let b=0;b<h;b+=1){let y=m-b*v;g[h-1-b]>y&&(g[h-1-b]=y)}}(s,o,d,c)):n<u&&(this.pushPreceding(o,d,a),function(h,g,v,m){for(let b=0;b<h;b+=1){let y=m+b*v;g[b]<y&&(g[b]=y)}}(s,o,d,p))),this.setState({value:o},this.fireChangeEvent.bind(this,"onChange"))},r.pushSucceeding=function(n,o,a){let s,u;for(s=a,u=n[s]+o;n[s+1]!==null&&u>n[s+1];s+=1,u=n[s]+o)n[s+1]=$5(u,this.props)},r.pushPreceding=function(n,o,a){for(let s=a,u=n[s]-o;n[s-1]!==null&&u<n[s-1];s-=1,u=n[s]-o)n[s-1]=$5(u,this.props)},r.axisKey=function(){return this.props.orientation==="vertical"?"Y":"X"},r.orthogonalAxisKey=function(){return this.props.orientation==="vertical"?"X":"Y"},r.posMinKey=function(){return this.props.orientation==="vertical"?this.props.invert?"bottom":"top":this.props.invert?"right":"left"},r.posMaxKey=function(){return this.props.orientation==="vertical"?this.props.invert?"top":"bottom":this.props.invert?"left":"right"},r.sizeKey=function(){return this.props.orientation==="vertical"?"clientHeight":"clientWidth"},r.fireChangeEvent=function(n){this.props[n]&&this.props[n](I1(this.state.value),this.state.index)},r.buildThumbStyle=function(n,o){let a={position:"absolute",touchAction:"none",willChange:this.state.index>=0?this.posMinKey():void 0,zIndex:this.state.zIndices.indexOf(o)+1};return a[this.posMinKey()]=n+"px",a},r.buildTrackStyle=function(n,o){let a={position:"absolute",willChange:this.state.index>=0?this.posMinKey()+","+this.posMaxKey():void 0};return a[this.posMinKey()]=n,a[this.posMaxKey()]=o,a},r.buildMarkStyle=function(n){var o;return(o={position:"absolute"})[this.posMinKey()]=n,o},r.renderThumbs=function(n){let{length:o}=n,a=[];for(let u=0;u<o;u+=1)a[u]=this.buildThumbStyle(n[u],u);let s=[];for(let u=0;u<o;u+=1)s[u]=this.renderThumb(a[u],u);return s},r.renderTracks=function(n){let o=[],a=n.length-1;o.push(this.renderTrack(0,0,n[0]));for(let s=0;s<a;s+=1)o.push(this.renderTrack(s+1,n[s],n[s+1]));return o.push(this.renderTrack(a+1,n[a],this.state.upperBound)),o},r.renderMarks=function(){let{marks:n}=this.props,o=this.props.max-this.props.min+1;return typeof n=="boolean"?n=Array.from({length:o}).map((a,s)=>s):typeof n=="number"&&(n=Array.from({length:o}).map((a,s)=>s).filter(a=>a%n==0)),n.map(parseFloat).sort((a,s)=>a-s).map(a=>{let s=this.calcOffset(a),u={key:a,className:this.props.markClassName,style:this.buildMarkStyle(s)};return this.props.renderMark(u)})},r.render=function(){let n=[],{value:o}=this.state,a=o.length;for(let c=0;c<a;c+=1)n[c]=this.calcOffset(o[c],c);let s=this.props.withTracks?this.renderTracks(n):null,u=this.renderThumbs(n),l=this.props.marks?this.renderMarks():null;return Ns.createElement("div",{ref:c=>{this.slider=c,this.resizeElementRef.current=c},style:{position:"relative"},className:this.props.className+(this.props.disabled?" disabled":""),onMouseDown:this.onSliderMouseDown,onClick:this.onSliderClick},s,u,l)},t}(Ns.Component);z5.displayName="ReactSlider",z5.defaultProps={min:0,max:100,step:1,pageFn:e=>10*e,minDistance:0,defaultValue:0,orientation:"horizontal",className:"slider",thumbClassName:"thumb",thumbActiveClassName:"active",trackClassName:"track",markClassName:"mark",withTracks:!0,pearling:!1,disabled:!1,snapDragDisabled:!1,invert:!1,marks:[],renderThumb:e=>Ns.createElement("div",e),renderTrack:e=>Ns.createElement("div",e),renderMark:e=>Ns.createElement("span",e)};var H5=z5;var ht=U(Z());import{jsx as kl}from"react/jsx-runtime";var CO="4px",fse=cse`
2702
2702
  opacity: 0.5;
2703
2703
 
2704
2704
  & * {
@@ -2738,7 +2738,7 @@ var zO=Object.create;var Nl=Object.defineProperty;var HO=Object.getOwnPropertyDe
2738
2738
  background: ${({isFilledTrack:e,theme:t})=>e?t.color.brandBlue500:t.color.grey400};
2739
2739
  border-radius: 999px;
2740
2740
  height: ${CO};
2741
- `,xO=({ariaLabel:e,ariaLabelledby:t,ariaValuetext:r,disabled:n=!1,defaultValue:o=0,max:a=100,min:s=0,onChange:u,step:l=1,value:c,"data-testid":p,...d})=>{(0,mt.isNonEmptyString)(e)||(0,mt.isNonEmptyString)(t)||console.warn("VHS Slider: Sliders are required to have an accessible name. Add a label using the ariaLabel or ariaLabelledby prop.");let h=(0,mt.isNotNil)(p)?p:"vhs-slider";return kl(pse,{...d,"data-testid":h,disabled:n,children:kl(H5,{ariaLabel:(0,mt.isString)(e)||(0,mt.isNonEmptyArray)(e)?e:void 0,ariaLabelledby:(0,mt.isString)(t)||(0,mt.isNonEmptyArray)(t)?t:void 0,ariaValuetext:(0,mt.isFunction)(r)?g=>r(g):r,defaultValue:(0,mt.isNumber)(o)||(0,mt.isNonEmptyArray)(o)?o:void 0,disabled:n,marks:l,max:a,min:s,onChange:u,renderMark:g=>{let{key:v,...m}=g;return kl("div",{...m,"data-testid":`${h}-mark-${g.key+s}`},v)},renderThumb:(g,v)=>{let{key:m,...b}=g;return kl(dse,{...b,"data-testid":`${h}-thumb-${v.index}`},m)},renderTrack:(g,v)=>{let{key:m,...b}=g;return kl(hse,{...b,"data-testid":`${h}-track-${v.index}`,isFilledTrack:mse(v)},m)},step:l,value:(0,mt.isNumber)(c)||(0,mt.isNonEmptyArray)(c)?c:void 0})})};xO.displayName="Slider_VHS";i();i();import{forwardRef as gse}from"react";import vse from"styled-components";import{jsx as bse}from"react/jsx-runtime";var yse=vse.div`
2741
+ `,xO=({ariaLabel:e,ariaLabelledby:t,ariaValuetext:r,disabled:n=!1,defaultValue:o=0,max:a=100,min:s=0,onChange:u,step:l=1,value:c,"data-testid":p,...d})=>{(0,ht.isNonEmptyString)(e)||(0,ht.isNonEmptyString)(t)||console.warn("VHS Slider: Sliders are required to have an accessible name. Add a label using the ariaLabel or ariaLabelledby prop.");let h=(0,ht.isNotNil)(p)?p:"vhs-slider";return kl(pse,{...d,"data-testid":h,disabled:n,children:kl(H5,{ariaLabel:(0,ht.isString)(e)||(0,ht.isNonEmptyArray)(e)?e:void 0,ariaLabelledby:(0,ht.isString)(t)||(0,ht.isNonEmptyArray)(t)?t:void 0,ariaValuetext:(0,ht.isFunction)(r)?g=>r(g):r,defaultValue:(0,ht.isNumber)(o)||(0,ht.isNonEmptyArray)(o)?o:void 0,disabled:n,marks:l,max:a,min:s,onChange:u,renderMark:g=>{let{key:v,...m}=g;return kl("div",{...m,"data-testid":`${h}-mark-${g.key+s}`},v)},renderThumb:(g,v)=>{let{key:m,...b}=g;return kl(dse,{...b,"data-testid":`${h}-thumb-${v.index}`},m)},renderTrack:(g,v)=>{let{key:m,...b}=g;return kl(hse,{...b,"data-testid":`${h}-track-${v.index}`,isFilledTrack:mse(v)},m)},step:l,value:(0,ht.isNumber)(c)||(0,ht.isNonEmptyArray)(c)?c:void 0})})};xO.displayName="Slider_VHS";i();i();import{forwardRef as gse}from"react";import vse from"styled-components";import{jsx as bse}from"react/jsx-runtime";var yse=vse.div`
2742
2742
  display: flex;
2743
2743
  flex-direction: ${({direction:e})=>e==="horizontal"?"row":"column"};
2744
2744
  gap: ${({gap:e,theme:t})=>t.spacing[e]};
@@ -2967,7 +2967,7 @@ var zO=Object.create;var Nl=Object.defineProperty;var HO=Object.getOwnPropertyDe
2967
2967
  ${({hoverColor:e})=>e!==void 0?`fill: ${e}`:null};
2968
2968
  }
2969
2969
  }
2970
- `,IO=({description:e=void 0,height:t=100,hoverColor:r=void 0,href:n=void 0,iconOnly:o=!1,title:a="Wistia Logo",variant:s="standard",...u})=>{let l="#2949e5",c="#000934",p="#ffffff",d={standard:{brandmark:l,logotype:c},dark:{brandmark:c,logotype:c},light:{brandmark:p,logotype:p}},h=d[s].brandmark,g=d[s].logotype,v=Hse(zse,{height:t,hoverColor:r,role:"img",viewBox:$se(o),xmlns:"http://www.w3.org/2000/svg",...u,children:[Qn("title",{children:a}),(0,MO.isNotNil)(e)?Qn("desc",{children:e}):null,Vse(h,o),Lse(g,o)]});return n!==void 0?Qn("a",{href:n,children:v}):v};IO.displayName="WistiaLogoNew_VHS";export{Gw as ActionModal,Kw as Avatar,tn as Backdrop,Yw as BackgroundImage,Qw as Badge,Vu as Banner,aS as Box,sS as Breakline,et as Button,Fo as ButtonGroup,gS as ButtonLink,Ep as Checkbox,Rp as CheckboxGroup,Iut as CheckboxMenuItem,DS as ClickArea,TS as CloseButton,VS as CollapsibleGroup,Op as Divider,Dw as Ellipsis,LS as FileSelect,WS as Form,KS as FormButtons,QT as FormField,Tp as FormFieldError,Mp as FormGlobalError,tA as FullScreenModal,De as Icon,Bo as IconButton,rA as Image,ts as Input,oA as KeyboardShortcut,Pp as Label,Ap as LabelDescription,yp as Link,iA as LinkButton,Nd as List,xs as ListItem,dA as MediaObject,Gie as Menu,FB as MenuButton,Mut as MenuItem,qut as MenuLabel,Xut as MenuRadioGroup,ect as Modal,Ya as ModalBase,lct as ModalBody,fct as ModalCloseButton,$B as ModalContent,cct as ModalFooter,uct as ModalHeader,HB as Paper,_B as ProgressBar,Gp as Radio,jp as RadioGroup,kut as RadioMenuItem,yO as RangeSelector,P1 as RangeSelectorCalendar,O1 as RangeSelectorInput,Od as RichTextEditor,lp as ScreenReaderOnly,wi as Select,xO as Slider,wO as Stack,Yut as SubMenu,w5 as SubMenuTrigger,EO as Switch,dr as Text,TO as Thumbnail,Fse as ThumbnailCollage,yf as Toast,S0 as ToastProvider,Ja as Tooltip,mp as Truncate,pBe as VHSProvider,BO as WistiaLogo,IO as WistiaLogoNew,Vs as copyToClipboard,Ile as datetimeHelpers,PW as ellipsisFlexParentStyle,Dr as ellipsisStyle,Cr as getBackgroundGradient,_le as getSemiRandomBackgroundGradient,pf as iconSizeMap,Rl as isValidRange,Ne as mq,ife as objectHelpers,Pd as rteDeserializeHTML,ft as rteFormatTypes,vs as rteSerializeToHTML,Mu as screenReaderOnlyStyle,jfe as stringHelpers,A0 as useBoolean,YL as useClipboard,R0 as useElementObserver,B0 as useEvent,k0 as useFocusTrap,l$ as useForceUpdate,hi as useFormikContext,K_ as useIsHovered,ap as useKey,nh as useKeyPress,ih as useKeyPressOnce,eW as useLocalStorage,Au as useMergedRefs,Mn as useMq,Ru as useOnClickOutside,ah as usePreventScroll,Fu as usePreviousValue,On as useTheme,Oe as useThemeColor,Hu as useToast,l0 as useWindowSize};
2970
+ `,IO=({description:e=void 0,height:t=100,hoverColor:r=void 0,href:n=void 0,iconOnly:o=!1,title:a="Wistia Logo",variant:s="standard",...u})=>{let l="#2949e5",c="#000934",p="#ffffff",d={standard:{brandmark:l,logotype:c},dark:{brandmark:c,logotype:c},light:{brandmark:p,logotype:p}},h=d[s].brandmark,g=d[s].logotype,v=Hse(zse,{height:t,hoverColor:r,role:"img",viewBox:$se(o),xmlns:"http://www.w3.org/2000/svg",...u,children:[Qn("title",{children:a}),(0,MO.isNotNil)(e)?Qn("desc",{children:e}):null,Vse(h,o),Lse(g,o)]});return n!==void 0?Qn("a",{href:n,children:v}):v};IO.displayName="WistiaLogoNew_VHS";export{Gw as ActionModal,Kw as Avatar,tn as Backdrop,Yw as BackgroundImage,Qw as Badge,Vu as Banner,aS as Box,sS as Breakline,et as Button,Fo as ButtonGroup,gS as ButtonLink,Ep as Checkbox,Rp as CheckboxGroup,Iut as CheckboxMenuItem,DS as ClickArea,TS as CloseButton,VS as CollapsibleGroup,Op as Divider,Dw as Ellipsis,LS as FileSelect,WS as Form,KS as FormButtons,QT as FormField,Tp as FormFieldError,Mp as FormGlobalError,tA as FullScreenModal,De as Icon,Bo as IconButton,rA as Image,ts as Input,oA as KeyboardShortcut,Pp as Label,Ap as LabelDescription,yp as Link,iA as LinkButton,Nd as List,xs as ListItem,dA as MediaObject,Gie as Menu,FB as MenuButton,Mut as MenuItem,qut as MenuLabel,Xut as MenuRadioGroup,ect as Modal,Ya as ModalBase,lct as ModalBody,fct as ModalCloseButton,$B as ModalContent,cct as ModalFooter,uct as ModalHeader,HB as Paper,_B as ProgressBar,Gp as Radio,jp as RadioGroup,kut as RadioMenuItem,yO as RangeSelector,P1 as RangeSelectorCalendar,O1 as RangeSelectorInput,Od as RichTextEditor,lp as ScreenReaderOnly,wi as Select,xO as Slider,wO as Stack,Yut as SubMenu,w5 as SubMenuTrigger,EO as Switch,dr as Text,TO as Thumbnail,Fse as ThumbnailCollage,yf as Toast,S0 as ToastProvider,Ja as Tooltip,mp as Truncate,pBe as VHSProvider,BO as WistiaLogo,IO as WistiaLogoNew,Vs as copyToClipboard,Ile as datetimeHelpers,PW as ellipsisFlexParentStyle,Dr as ellipsisStyle,Cr as getBackgroundGradient,_le as getSemiRandomBackgroundGradient,pf as iconSizeMap,Rl as isValidRange,Ne as mq,ife as objectHelpers,Pd as rteDeserializeHTML,pt as rteFormatTypes,vs as rteSerializeToHTML,Mu as screenReaderOnlyStyle,jfe as stringHelpers,A0 as useBoolean,YL as useClipboard,R0 as useElementObserver,B0 as useEvent,k0 as useFocusTrap,l$ as useForceUpdate,hi as useFormikContext,K_ as useIsHovered,ap as useKey,nh as useKeyPress,ih as useKeyPressOnce,eW as useLocalStorage,Au as useMergedRefs,Mn as useMq,Ru as useOnClickOutside,ah as usePreventScroll,Fu as usePreviousValue,On as useTheme,Oe as useThemeColor,Hu as useToast,l0 as useWindowSize};
2971
2971
  /*! Bundled license information:
2972
2972
 
2973
2973
  react-is/cjs/react-is.production.min.js: