PageSourceSearch

https://bezdomnosc.pl/_next/static/chunks/89921-9f25b5e9ca85fc00.js

js bezdomnosc.pl collected 2026-10-07 21:38:08 UTC 334,291 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2447,8809,30252,89921],{2339:(e,t,n)=>{"use strict";n.r(t),n.d(t,{default:()=>r});let r=(0,n(37341).A)("ChevronDown",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]])},2447:(e,t,n)=>{"use strict";n.r(t),n.d(t,{default:()=>r});let r=(0,n(37341).A)("Heading1",[["path",{d:"M4 12h8",key:"17cfdx"}],["path",{d:"M4 18V6",key:"1rz3zl"}],["path",{d:"M12 18V6",key:"zqpxq5"}],["path",{d:"m17 12 3-2v8",key:"1hhhft"}]])},6357:(e,t,n)=>{"use strict";n.d(t,{B:()=>r});let r="undefined"!=typeof window},6809:(e,t,n)=>{"use strict";var r=n(15045);n.o(r,"usePathname")&&n.d(t,{usePathname:function(){return r.usePathname}}),n.o(r,"useRouter")&&n.d(t,{useRouter:function(){return r.useRouter}})},8809:(e,t,n)=>{"use strict";n.r(t),n.d(t,{default:()=>r});let r=(0,n(37341).A)("Sun",[["circle",{cx:"12",cy:"12",r:"4",key:"4exip2"}],["path",{d:"M12 2v2",key:"tus03m"}],["path",{d:"M12 20v2",key:"1lh1kg"}],["path",{d:"m4.93 4.93 1.41 1.41",key:"149t6j"}],["path",{d:"m17.66 17.66 1.41 1.41",key:"ptbguv"}],["path",{d:"M2 12h2",key:"1t8f8n"}],["path",{d:"M20 12h2",key:"1q8mjw"}],["path",{d:"m6.34 17.66-1.41 1.41",key:"1m8zz5"}],["path",{d:"m19.07 4.93-1.41 1.41",key:"1shlcs"}]])},9021:(e,t,n)=>{"use strict";n.d(t,{Ci:()=>s,Gt:()=>i,WG:()=>o,uv:()=>l});var r=n(23470);let{schedule:i,cancel:o,state:l,steps:s}=(0,n(85633).I)("undefined"!=typeof requestAnimationFrame?requestAnimationFrame:r.l,!0)},9519:(e,t,n)=>{"use strict";var r=n(88389).Buffer;let i=void 0!==r,o=/"(?:_|\\u005[Ff])(?:_|\\u005[Ff])(?:p|\\u0070)(?:r|\\u0072)(?:o|\\u006[Ff])(?:t|\\u0074)(?:o|\\u006[Ff])(?:_|\\u005[Ff])(?:_|\\u005[Ff])"\s*:/,l=/"(?:c|\\u0063)(?:o|\\u006[Ff])(?:n|\\u006[Ee])(?:s|\\u0073)(?:t|\\u0074)(?:r|\\u0072)(?:u|\\u0075)(?:c|\\u0063)(?:t|\\u0074)(?:o|\\u006[Ff])(?:r|\\u0072)"\s*:/;function s(e,t,n){null==n&&null!==t&&"object"==typeof t&&(n=t,t=void 0),i&&r.isBuffer(e)&&(e=e.toString()),e&&65279===e.charCodeAt(0)&&(e=e.slice(1));let s=JSON.parse(e,t);if(null===s||"object"!=typeof s)return s;let u=n&&n.protoAction||"error",c=n&&n.constructorAction||"error";if("ignore"===u&&"ignore"===c)return s;if("ignore"!==u&&"ignore"!==c){if(!1===o.test(e)&&!1===l.test(e))return s}else if("ignore"!==u&&"ignore"===c){if(!1===o.test(e))return s}else if(!1===l.test(e))return s;return a(s,{protoAction:u,constructorAction:c,safe:n&&n.safe})}function a(e,{protoAction:t="error",constructorAction:n="error",safe:r}={}){let i=[e];for(;i.length;){let e=i;for(let o of(i=[],e)){if("ignore"!==t&&Object.prototype.hasOwnProperty.call(o,"__proto__")){if(!0===r)return null;if("error"===t)throw SyntaxError("Object contains forbidden prototype property");delete o.__proto__}if("ignore"!==n&&Object.prototype.hasOwnProperty.call(o,"constructor")&&Object.prototype.hasOwnProperty.call(o.constructor,"prototype")){if(!0===r)return null;if("error"===n)throw SyntaxError("Object contains forbidden prototype property");delete o.constructor}for(let e in o){let t=o[e];t&&"object"==typeof t&&i.push(t)}}}return e}function u(e,t,n){let r=Error.stackTraceLimit;Error.stackTraceLimit=0;try{return s(e,t,n)}finally{Error.stackTraceLimit=r}}e.exports=u,e.exports.default=u,e.exports.parse=u,e.exports.safeParse=function(e,t){let n=Error.stackTraceLimit;Error.stackTraceLimit=0;try{return s(e,t,{safe:!0})}catch(e){return null}finally{Error.stackTraceLimit=n}},e.exports.scan=a},10389:(e,t,n)=>{"use strict";n.r(t),n.d(t,{default:()=>r});let r=(0,n(37341).A)("FileText",[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z",key:"1rqfz7"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]])},12213:(e,t,n)=>{"use strict";n.r(t),n.d(t,{default:()=>r});let r=(0,n(37341).A)("Link",[["path",{d:"M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71",key:"1cjeqo"}],["path",{d:"M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71",key:"19qd67"}]])},17933:(e,t,n)=>{"use strict";n.d(t,{E:()=>i});var r=n(32144);let i=n(6357).B?r.useLayoutEffect:r.useEffect},18518:(e,t,n)=>{"use strict";n.d(t,{b:()=>u});var r=n(90354),i=n(81697),o=n(32144),l=n(23037),s=n(70880);let a=o.Fragment,u=(0,s.FX)(function(e,t){let{...n}=e,{isFocusVisible:u,focusProps:c}=(0,r.o)(),{isHovered:d,hoverProps:h}=(0,i.M)({isDisabled:!1}),{pressed:p,pressProps:f}=(0,l.Z)({disabled:!1}),m=(0,s.v6)({ref:t},c,h,f),g=(0,o.useMemo)(()=>({hover:d,focus:u,active:p}),[d,u,p]);return(0,s.Ci)()({ourProps:m,theirProps:n,slot:g,defaultTag:a,name:"DataInteractive"})})},22031:(e,t,n)=>{"use strict";n.d(t,{T:()=>i});var r=n(30775);function i(e){return r._.isServer?null:e instanceof Node?e.ownerDocument:null!=e&&e.hasOwnProperty("current")&&e.current instanceof Node?e.current.ownerDocument:document}},23037:(e,t,n)=>{"use strict";n.d(t,{Z:()=>s});var r=n(32144),i=n(22031),o=n(42624),l=n(72755);function s(){let{disabled:e=!1}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=(0,r.useRef)(null),[n,s]=(0,r.useState)(!1),a=(0,o.L)(),u=(0,l._)(()=>{t.current=null,s(!1),a.dispose()}),c=(0,l._)(e=>{if(a.dispose(),null===t.current){t.current=e.currentTarget,s(!0);{let n=(0,i.T)(e.currentTarget);a.addEventListener(n,"pointerup",u,!1),a.addEventListener(n,"pointermove",e=>{if(t.current){var n,r;let i,o;s((i=e.width/2,o=e.height/2,n={top:e.clientY-o,right:e.clientX+i,bottom:e.clientY+o,left
1:e.clientX-i},r=t.current.getBoundingClientRect(),!(!n||!r||n.right<r.left||n.left>r.right||n.bottom<r.top||n.top>r.bottom)))}},!1),a.addEventListener(n,"pointercancel",u,!1)}}});return{pressed:n,pressProps:e?{}:{onPointerDown:c,onPointerUp:u,onClick:u}}}},23470:(e,t,n)=>{"use strict";n.d(t,{l:()=>r});let r=e=>e},25786:(e,t,n)=>{"use strict";let r;function i(e){return null!==e&&"object"==typeof e&&"function"==typeof e.start}n.d(t,{P:()=>i4});let o=e=>Array.isArray(e);function l(e,t){if(!Array.isArray(t))return!1;let n=t.length;if(n!==e.length)return!1;for(let r=0;r<n;r++)if(t[r]!==e[r])return!1;return!0}function s(e){return"string"==typeof e||Array.isArray(e)}function a(e){let t=[{},{}];return null==e||e.values.forEach((e,n)=>{t[0][n]=e.get(),t[1][n]=e.getVelocity()}),t}function u(e,t,n,r){if("function"==typeof t){let[i,o]=a(r);t=t(void 0!==n?n:e.custom,i,o)}if("string"==typeof t&&(t=e.variants&&e.variants[t]),"function"==typeof t){let[i,o]=a(r);t=t(void 0!==n?n:e.custom,i,o)}return t}function c(e,t,n){let r=e.getProps();return u(r,t,void 0!==n?n:r.custom,e)}let d=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],h=["initial",...d],p=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],f=new Set(p),m=e=>1e3*e,g={type:"spring",stiffness:500,damping:25,restSpeed:10},v={type:"keyframes",duration:.8},y={type:"keyframes",ease:[.25,.1,.35,1],duration:.3};function x(e,t){return e[t]||e.default||e}var b,w,E=n(55025);let k={current:!1},S=e=>null!==e;function T(e,{repeat:t,repeatType:n="loop"},r){let i=e.filter(S),o=t&&"loop"!==n&&t%2==1?0:i.length-1;return o&&void 0!==r?r:i[o]}var C=n(9021);let P=e=>/^0[^.\s]+$/u.test(e);var A=n(23470);let R=A.l,_=A.l,I=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e),D=e=>t=>"string"==typeof t&&t.startsWith(e),L=D("--"),M=D("var(--"),F=e=>!!M(e)&&O.test(e.split("/*")[0].trim()),O=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu,j=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u,N=(e,t,n)=>n>t?t:n<e?e:n,V={test:e=>"number"==typeof e,parse:parseFloat,transform:e=>e},B={...V,transform:e=>N(0,1,e)},U={...V,default:1},z=e=>Math.round(1e5*e)/1e5,H=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu,W=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu,q=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu;function Y(e){return"string"==typeof e}let G=e=>({test:t=>Y(t)&&t.endsWith(e)&&1===t.split(" ").length,parse:parseFloat,transform:t=>`${t}${e}`}),$=G("deg"),X=G("%"),K=G("px"),J=G("vh"),Z=G("vw"),Q={...X,parse:e=>X.parse(e)/100,transform:e=>X.transform(100*e)},ee=new Set(["width","height","top","left","right","bottom","x","y","translateX","translateY"]),et=e=>e===V||e===K,en=(e,t)=>parseFloat(e.split(", ")[t]),er=(e,t)=>(n,{transform:r})=>{if("none"===r||!r)return 0;let i=r.match(/^matrix3d\((.+)\)$/u);if(i)return en(i[1],t);{let t=r.match(/^matrix\((.+)\)$/u);return t?en(t[1],e):0}},ei=new Set(["x","y","z"]),eo=p.filter(e=>!ei.has(e)),el={width:({x:e},{paddingLeft:t="0",paddingRight:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),height:({y:e},{paddingTop:t="0",paddingBottom:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),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:er(4,13),y:er(5,14)};el.translateX=el.x,el.translateY=el.y;let es=e=>t=>t.test(e),ea=[V,K,X,$,Z,J,{test:e=>"auto"===e,parse:e=>e}],eu=e=>ea.find(es(e)),ec=new Set,ed=!1,eh=!1;function ep(){if(eh){let e=Array.from(ec).filter(e=>e.needsMeasurement),t=new Set(e.map(e=>e.element)),n=new Map;t.forEach(e=>{let t=function(e){let t=[];return eo.forEach(n=>{let r=e.getValue(n);void 0!==r&&(t.push([n,r.get()]),r.set(+!!n.startsWith("scale")))}),t}(e);t.length&&(n.set(e,t),e.render())}),e.forEach(e=>e.measureInitialState()),t.forEach(e=>{e.render();let t=n.get(e);t&&t.forEach(([t,n])=>{var r;null==(r=e.getValue(t))||r.set(n)})}
1),e.forEach(e=>e.measureEndState()),e.forEach(e=>{void 0!==e.suspendedScrollY&&window.scrollTo(0,e.suspendedScrollY)})}eh=!1,ed=!1,ec.forEach(e=>e.complete()),ec.clear()}function ef(){ec.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(eh=!0)})}class em{constructor(e,t,n,r,i,o=!1){this.isComplete=!1,this.isAsync=!1,this.needsMeasurement=!1,this.isScheduled=!1,this.unresolvedKeyframes=[...e],this.onComplete=t,this.name=n,this.motionValue=r,this.element=i,this.isAsync=o}scheduleResolve(){this.isScheduled=!0,this.isAsync?(ec.add(this),ed||(ed=!0,C.Gt.read(ef),C.Gt.resolveKeyframes(ep))):(this.readKeyframes(),this.complete())}readKeyframes(){let{unresolvedKeyframes:e,name:t,element:n,motionValue:r}=this;for(let i=0;i<e.length;i++)if(null===e[i])if(0===i){let i=null==r?void 0:r.get(),o=e[e.length-1];if(void 0!==i)e[0]=i;else if(n&&t){let r=n.readValue(t,o);null!=r&&(e[0]=r)}void 0===e[0]&&(e[0]=o),r&&void 0===i&&r.set(e[0])}else e[i]=e[i-1]}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(){this.isComplete=!0,this.onComplete(this.unresolvedKeyframes,this.finalKeyframe),ec.delete(this)}cancel(){this.isComplete||(this.isScheduled=!1,ec.delete(this))}resume(){this.isComplete||this.scheduleResolve()}}let eg=(e,t)=>n=>!!(Y(n)&&q.test(n)&&n.startsWith(e)||t&&null!=n&&Object.prototype.hasOwnProperty.call(n,t)),ev=(e,t,n)=>r=>{if(!Y(r))return r;let[i,o,l,s]=r.match(H);return{[e]:parseFloat(i),[t]:parseFloat(o),[n]:parseFloat(l),alpha:void 0!==s?parseFloat(s):1}},ey={...V,transform:e=>Math.round(N(0,255,e))},ex={test:eg("rgb","red"),parse:ev("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:r=1})=>"rgba("+ey.transform(e)+", "+ey.transform(t)+", "+ey.transform(n)+", "+z(B.transform(r))+")"},eb={test:eg("#"),parse:function(e){let t="",n="",r="",i="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),r=e.substring(5,7),i=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),r=e.substring(3,4),i=e.substring(4,5),t+=t,n+=n,r+=r,i+=i),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:i?parseInt(i,16)/255:1}},transform:ex.transform},ew={test:eg("hsl","hue"),parse:ev("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:r=1})=>"hsla("+Math.round(e)+", "+X.transform(z(t))+", "+X.transform(z(n))+", "+z(B.transform(r))+")"},eE={test:e=>ex.test(e)||eb.test(e)||ew.test(e),parse:e=>ex.test(e)?ex.parse(e):ew.test(e)?ew.parse(e):eb.parse(e),transform:e=>Y(e)?e:e.hasOwnProperty("red")?ex.transform(e):ew.transform(e)},ek="number",eS="color",eT=/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 eC(e){let t=e.toString(),n=[],r={color:[],number:[],var:[]},i=[],o=0,l=t.replace(eT,e=>(eE.test(e)?(r.color.push(o),i.push(eS),n.push(eE.parse(e))):e.startsWith("var(")?(r.var.push(o),i.push("var"),n.push(e)):(r.number.push(o),i.push(ek),n.push(parseFloat(e))),++o,"${}")).split("${}");return{values:n,split:l,indexes:r,types:i}}function eP(e){return eC(e).values}function eA(e){let{split:t,types:n}=eC(e),r=t.length;return e=>{let i="";for(let o=0;o<r;o++)if(i+=t[o],void 0!==e[o]){let t=n[o];t===ek?i+=z(e[o]):t===eS?i+=eE.transform(e[o]):i+=e[o]}return i}}let eR=e=>"number"==typeof e?0:e,e_={test:function(e){var t,n;return isNaN(e)&&Y(e)&&((null==(t=e.match(H))?void 0:t.length)||0)+((null==(n=e.match(W))?void 0:n.length)||0)>0},parse:eP,createTransformer:eA,getAnimatableNone:function(e){let t=eP(e);return eA(e)(t.map(eR))}},eI=new Set(["brightness","contrast","saturate","opacity"]);function eD(e){let[t,n]=e.slice(0,-1).split("(");if("drop-shadow"===t)return e;let[r]=n.match(H)||[];if(!r)return e;let i=n.replace(r,""),o=+!!eI.has(t);return r!==n&&(o*=100),t+"("+o+i+")"}let eL=/\b([a-z-]*)\(.*?\)/gu,eM={...e_,getAnimatableNone:e=>{let t=e.match(eL);return t?t.map(eD).join(" "):e}},eF={...V,transform:Math.round},eO={borderWidth:K,borderTopWidth:K,borderRightWidth:K,borderBottomWidth:K,borderLeftWidth:K,borderRadius:K,radius:K,borderTopLeftRadius:K,borderTopRightRadius:K,borderBottomRightRadius:K,borderBottomLeftRadius:K,width:K,maxWidth:K,height:K,maxHeight:K,size:K,top:K,right:K,bottom:K,left:K,padding:K,paddingTop:K,paddingRight:K,paddingBottom:K,paddingLeft:K,margin:K,marginTop:K,marginRight:K,marginBottom:K,marginLeft:K,rotate:$,rotateX:$,rotateY:$,rotateZ:$,scale:U,scaleX:U,scaleY:U,scaleZ:U,skew:$,skewX:$,
1skewY:$,distance:K,translateX:K,translateY:K,translateZ:K,x:K,y:K,z:K,perspective:K,transformPerspective:K,opacity:B,originX:Q,originY:Q,originZ:K,zIndex:eF,backgroundPositionX:K,backgroundPositionY:K,fillOpacity:B,strokeOpacity:B,numOctaves:eF},ej={...eO,color:eE,backgroundColor:eE,outlineColor:eE,fill:eE,stroke:eE,borderColor:eE,borderTopColor:eE,borderRightColor:eE,borderBottomColor:eE,borderLeftColor:eE,filter:eM,WebkitFilter:eM},eN=e=>ej[e];function eV(e,t){let n=eN(e);return n!==eM&&(n=e_),n.getAnimatableNone?n.getAnimatableNone(t):void 0}let eB=new Set(["auto","none","0"]);class eU extends em{constructor(e,t,n,r,i){super(e,t,n,r,i,!0)}readKeyframes(){let{unresolvedKeyframes:e,element:t,name:n}=this;if(!t||!t.current)return;super.readKeyframes();for(let n=0;n<e.length;n++){let r=e[n];if("string"==typeof r&&F(r=r.trim())){let i=function e(t,n,r=1){_(r<=4,`Max CSS variable fallback depth detected in property "${t}". This may indicate a circular fallback dependency.`);let[i,o]=function(e){let t=j.exec(e);if(!t)return[,];let[,n,r,i]=t;return[`--${null!=n?n:r}`,i]}(t);if(!i)return;let l=window.getComputedStyle(n).getPropertyValue(i);if(l){let e=l.trim();return I(e)?parseFloat(e):e}return F(o)?e(o,n,r+1):o}(r,t.current);void 0!==i&&(e[n]=i),n===e.length-1&&(this.finalKeyframe=r)}}if(this.resolveNoneKeyframes(),!ee.has(n)||2!==e.length)return;let[r,i]=e,o=eu(r),l=eu(i);if(o!==l)if(et(o)&&et(l))for(let t=0;t<e.length;t++){let n=e[t];"string"==typeof n&&(e[t]=parseFloat(n))}else this.needsMeasurement=!0}resolveNoneKeyframes(){let{unresolvedKeyframes:e,name:t}=this,n=[];for(let t=0;t<e.length;t++){var r;("number"==typeof(r=e[t])?0===r:null===r||"none"===r||"0"===r||P(r))&&n.push(t)}n.length&&function(e,t,n){let r,i=0;for(;i<e.length&&!r;){let t=e[i];"string"==typeof t&&!eB.has(t)&&eC(t).values.length&&(r=e[i]),i++}if(r&&n)for(let i of t)e[i]=eV(n,r)}(e,n,t)}measureInitialState(){let{element:e,unresolvedKeyframes:t,name:n}=this;if(!e||!e.current)return;"height"===n&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=el[n](e.measureViewportBox(),window.getComputedStyle(e.current)),t[0]=this.measuredOrigin;let r=t[t.length-1];void 0!==r&&e.getValue(n,r).jump(r,!1)}measureEndState(){var e;let{element:t,name:n,unresolvedKeyframes:r}=this;if(!t||!t.current)return;let i=t.getValue(n);i&&i.jump(this.measuredOrigin,!1);let o=r.length-1,l=r[o];r[o]=el[n](t.measureViewportBox(),window.getComputedStyle(t.current)),null!==l&&void 0===this.finalKeyframe&&(this.finalKeyframe=l),(null==(e=this.removedTransforms)?void 0:e.length)&&this.removedTransforms.forEac
1h(([e,n])=>{t.getValue(e).set(n)}),this.resolveNoneKeyframes()}}function ez(e){let t;return()=>(void 0===t&&(t=e()),t)}function eH(){r=void 0}let eW={now:()=>(void 0===r&&eW.set(C.uv.isProcessing||E.W.useManualTiming?C.uv.timestamp:performance.now()),r),set:e=>{r=e,queueMicrotask(eH)}},eq=(e,t)=>"zIndex"!==t&&!!("number"==typeof e||Array.isArray(e)||"string"==typeof e&&(e_.test(e)||"0"===e)&&!e.startsWith("url("));class eY{constructor({autoplay:e=!0,delay:t=0,type:n="keyframes",repeat:r=0,repeatDelay:i=0,repeatType:o="loop",...l}){this.isStopped=!1,this.hasAttemptedResolve=!1,this.createdAt=eW.now(),this.options={autoplay:e,delay:t,type:n,repeat:r,repeatDelay:i,repeatType:o,...l},this.updateFinishedPromise()}calcStartTime(){return this.resolvedAt&&this.resolvedAt-this.createdAt>40?this.resolvedAt:this.createdAt}get resolved(){return this._resolved||this.hasAttemptedResolve||(ef(),ep()),this._resolved}onKeyframesResolved(e,t){this.resolvedAt=eW.now(),this.hasAttemptedResolve=!0;let{name:n,type:r,velocity:i,delay:o,onComplete:l,onUpdate:s,isGenerator:a}=this.options;if(!a&&!function(e,t,n,r){let i=e[0];if(null===i)return!1;if("display"===t||"visibility"===t)return!0;let o=e[e.length-1],l=eq(i,t),s=eq(o,t);return R(l===s,`You are trying to animate ${t} from "${i}" to "${o}". ${i} is not an animatable value - to enable this animation set ${i} to a value animatable to ${o} via the \`style\` property.`),!!l&&!!s&&(function(e){let t=e[0];if(1===e.length)return!0;for(let n=0;n<e.length;n++)if(e[n]!==t)return!0}(e)||"spring"===n&&r)}(e,n,r,i))if(k.current||!o){null==s||s(T(e,this.options,t)),null==l||l(),this.resolveFinishedPromise();return}else this.options.duration=0;let u=this.initPlayback(e,t);!1!==u&&(this._resolved={keyframes:e,finalKeyframe:t,...u},this.onPostResolved())}onPostResolved(){}then(e,t){return this.currentFinishedPromise.then(e,t)}updateFinishedPromise(){this.currentFinishedPromise=new Promise(e=>{this.resolveFinishedPromise=e})}}function eG(e,t,n){var r,i;let o=Math.max(t-5,0);return r=n-e(o),(i=t-o)?1e3/i*r:0}function e$(e,t){return e*Math.sqrt(1-t*t)}let eX=["duration","bounce"],eK=["stiffness","damping","mass"];function eJ(e,t){return t.some(t=>void 0!==e[t])}function eZ({keyframes:e,restDelta:t,restSpeed:n,...r}){let i,o=e[0],l=e[e.length-1],s={done:!1,value:o},{stiffness:a,damping:u,mass:c,duration:d,velocity:h,isResolvedFromDuration:p}=function(e){let t={velocity:0,stiffness:100,damping:10,mass:1,isResolvedFromDuration:!1,...e};if(!eJ(e,eK)&&eJ(e,eX)){let n=function({duration:e=800,bounce:t=.25,velocity:n=0,mass:r=1}){let i,o;R(e<=m(10),"Spring duration must be 10 seconds or less");let l=1-t;l=N(.05,1,l),e=N(.01,10,e/1e3),l<1?(i=t=>{let r=t*l,i=r*e;return .001-(r-n)/e$(t,l)*Math.exp(-i)},o=t=>{let r=t*l*e,o=Math.pow(l,2)*Math.pow(t,2)*e,s=Math.exp(-r),a=e$(Math.pow(t,2),l);return(r*n+n-o)*s*(-i(t)+.001>0?-1:1)/a}):(i=t=>-.001+Math.exp(-t*e)*((t-n)*e+1),o=t=>e*e*(n-t)*Math.exp(-t*e));let s=function(e,t,n){let r=n;for(let n=1;n<12;n++)r-=e(r)/t(r);return r}(i,o,5/e);if(e=m(e),isNaN(s))return{stiffness:100,damping:10,duration:e};{let t=Math.pow(s,2)*r;return{stiffness:t,damping:2*l*Math.sqrt(r*t),duration:e}}}(e);(t={...t,...n,mass:1}).isResolvedFromDuration=!0}return t}({...r,velocity:-((r.velocity||0)/1e3)}),f=h||0,g=u/(2*Math.sqrt(a*c)),v=l-o,y=Math.sqrt(a/c)/1e3,x=5>Math.abs(v);if(n||(n=x?.01:2),t||(t=x?.005:.5),g<1){let e=e$(y,g);i=t=>l-Math.exp(-g*y*t)*((f+g*y*v)/e*Math.sin(e*t)+v*Math.cos(e*t))}else if(1===g)i=e=>l-Math.exp(-y*e)*(v+(f+y*v)*e);else{let e=y*Math.sqrt(g*g-1);i=t=>{let n=Math.exp(-g*y*t),r=Math.min(e*t,300);return l-n*((f+g*y*v)*Math.sinh(r)+e*v*Math.cosh(r))/e}}return{calculatedDuration:p&&d||null,next:e=>{let r=i(e);if(p)s.done=e>=d;else{let o=0;g<1&&(o=0===e?m(f):eG(i,e,r));let a=Math.abs(l-r)<=t;s.done=Math.abs(o)<=n&&a}return s.value=s.done?l:r,s}}}function eQ({keyframes:e,velocity:t=0,power:n=.8,timeConstant:r=325,bounceDamping:i=10,bounceStiffness:o=500,modifyTarget:l,min:s,max:a,restDelta:u=.5,restSpeed:c}){let d,h,p=e[0],f={done:!1,value:p},m=n*t,g=p+m,v=void 0===l?g:l(g);v!==g&&(m=v-p);let y=e=>-m*Math.exp(-e/r),x=e=>v+y(e),b=e=>{let t=y(e),n=x(e);f.done=Math.abs(t)<=u,f.value=f.done?v:n},w=e=>{let t;if(t=f.value,void 0!==s&&t<s||void 0!==a&&t>a){var n;d=e,h=eZ({keyframes:[f.value,(n=f.value,void 0===s?a:void 0===a||Math.abs(s-n)<Math.abs(a-n)?s:a)],velocity:eG(x,e,f.value),damping:i,stiffness:o,restDelta:u,restSpeed:c})}};return w(0),{calculatedDuration:null,next:e=>{let t=!1;
1return(h||void 0!==d||(t=!0,b(e),w(e)),void 0!==d&&e>=d)?h.next(e-d):(t||b(e),f)}}}let e0=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e;function e1(e,t,n,r){return e===t&&n===r?A.l:i=>0===i||1===i?i:e0(function(e,t,n,r,i){let o,l,s=0;do(o=e0(l=t+(n-t)/2,r,i)-e)>0?n=l:t=l;while(Math.abs(o)>1e-7&&++s<12);return l}(i,0,1,e,n),t,r)}let e2=e1(.42,0,1,1),e4=e1(0,0,.58,1),e3=e1(.42,0,.58,1),e5=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,e6=e=>t=>1-e(1-t),e9=e=>1-Math.sin(Math.acos(e)),e7=e6(e9),e8=e5(e9),te=e1(.33,1.53,.69,.99),tt=e6(te),tn=e5(tt),tr={linear:A.l,easeIn:e2,easeInOut:e3,easeOut:e4,circIn:e9,circInOut:e8,circOut:e7,backIn:tt,backInOut:tn,backOut:te,anticipate:e=>(e*=2)<1?.5*tt(e):.5*(2-Math.pow(2,-10*(e-1)))},ti=e=>{if(Array.isArray(e)){_(4===e.length,"Cubic bezier arrays must contain four numerical values.");let[t,n,r,i]=e;return e1(t,n,r,i)}return"string"==typeof e?(_(void 0!==tr[e],`Invalid easing type '${e}'`),tr[e]):e},to=(e,t)=>n=>t(e(n)),tl=(...e)=>e.reduce(to),ts=(e,t,n)=>{let r=t-e;return 0===r?1:(n-e)/r},ta=(e,t,n)=>e+(t-e)*n;function tu(e,t,n){return(n<0&&(n+=1),n>1&&(n-=1),n<1/6)?e+(t-e)*6*n:n<.5?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function tc(e,t){return n=>n>0?t:e}let td=(e,t,n)=>{let r=e*e,i=n*(t*t-r)+r;return i<0?0:Math.sqrt(i)},th=[eb,ex,ew];function tp(e){let t=th.find(t=>t.test(e));if(R(!!t,`'${e}' is not an animatable color. Use the equivalent color code instead.`),!t)return!1;let n=t.parse(e);return t===ew&&(n=function({hue:e,saturation:t,lightness:n,alpha:r}){e/=360,n/=100;let i=0,o=0,l=0;if(t/=100){let r=n<.5?n*(1+t):n+t-n*t,s=2*n-r;i=tu(s,r,e+1/3),o=tu(s,r,e),l=tu(s,r,e-1/3)}else i=o=l=n;return{red:Math.round(255*i),green:Math.round(255*o),blue:Math.round(255*l),alpha:r}}(n)),n}let tf=(e,t)=>{let n=tp(e),r=tp(t);if(!n||!r)return tc(e,t);let i={...n};return e=>(i.red=td(n.red,r.red,e),i.green=td(n.green,r.green,e),i.blue=td(n.blue,r.blue,e),i.alpha=ta(n.alpha,r.alpha,e),ex.transform(i))},tm=new Set(["none","hidden"]);function tg(e,t){return n=>ta(e,t,n)}function tv(e){return"number"==typeof e?tg:"string"==typeof e?F(e)?tc:eE.test(e)?tf:tb:Array.isArray(e)?ty:"object"==typeof e?eE.test(e)?tf:tx:tc}function ty(e,t){let n=[...e],r=n.length,i=e.map((e,n)=>tv(e)(e,t[n]));return e=>{for(let t=0;t<r;t++)n[t]=i[t](e);return n}}function tx(e,t){let n={...e,...t},r={};for(let i in n)void 0!==e[i]&&void 0!==t[i]&&(r[i]=tv(e[i])(e[i],t[i]));return e=>{for(let t in r)n[t]=r[t](e);return n}}let tb=(e,t)=>{let n=e_.createTransformer(t),r=eC(e),i=eC(t);return r.indexes.var.length===i.indexes.var.length&&r.indexes.color.length===i.indexes.color.length&&r.indexes.number.length>=i.indexes.number.length?tm.has(e)&&!i.values.length||tm.has(t)&&!r.values.length?function(e,t){return tm.has(e)?n=>n<=0?e:t:n=>n>=1?t:e}(e,t):tl(ty(function(e,t){var n;let r=[],i={color:0,var:0,number:0};for(let o=0;o<t.values.length;o++){let l=t.types[o],s=e.indexes[l][i[l]],a=null!=(n=e.values[s])?n:0;r[o]=a,i[l]++}return r}(r,i),i.values),n):(R(!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.`),tc(e,t))};function tw(e,t,n){return"number"==typeof e&&"number"==typeof t&&"number"==typeof n?ta(e,t,n):tv(e)(e,t)}function tE({duration:e=300,keyframes:t,times:n,ease:r="easeInOut"}){var i;let o=Array.isArray(r)&&"number"!=typeof r[0]?r.map(ti):ti(r),l={done:!1,value:t[0]},s=function(e,t,{clamp:n=!0,ease:r,mixer:i}={}){let o=e.length;if(_(o===t.length,"Both input and output ranges must be the same length"),1===o)return()=>t[0];if(2===o&&e[0]===e[1])return()=>t[1];e[0]>e[o-1]&&(e=[...e].reverse(),t=[...t].reverse());let l=function(e,t,n){let r=[],i=n||tw,o=e.length-1;for(let n=0;n<o;n++){let o=i(e[n],e[n+1]);t&&(o=tl(Array.isArray(t)?t[n]||A.l:t,o)),r.push(o)}return r}(t,r,i),s=l.length,a=t=>{let n=0;if(s>1)for(;n<e.length-2&&!(t<e[n+1]);n++);let r=ts(e[n],e[n+1],t);return l[n](r)};return n?t=>a(N(e[0],e[o-1],t)):a}((i=n&&n.length===t.length?n:function(e){let t=[0];return!function(e,t){let n=e[e.length-1];for(let r=1;r<=t;r++){let i=ts(0,t,r);e.push(ta(n,1,i))}}(t,e.length-1),t}(t),i.map(t=>t*e)),t,{ease:Array.isArray(o)?o:t.map(()=>o||e3).splice(0,t.length-1)});return{calculatedDuration:e,next:t=>(l.value=s(t),l.done=t>=e,l)}}let tk=e=>{let t=({timestamp:t})=>e(t);return{start:()=>C.Gt.update(t,!0),stop:()=>(0,C.WG)(t),now:()=>C.uv.isProcessing?C.uv.timestamp:eW.now()}}
1,tS={decay:eQ,inertia:eQ,tween:tE,keyframes:tE,spring:eZ},tT=e=>e/100;class tC extends eY{constructor(e){super(e),this.holdTime=null,this.cancelTime=null,this.currentTime=0,this.playbackSpeed=1,this.pendingPlayState="running",this.startTime=null,this.state="idle",this.stop=()=>{let{onStop:e}=this.options;e&&e(),this.resolver.cancel(),this.isStopped=!0,"idle"!==this.state&&this.teardown()};let{name:t,motionValue:n,element:r,keyframes:i}=this.options,o=(null==r?void 0:r.KeyframeResolver)||em,l=(e,t)=>this.onKeyframesResolved(e,t);this.resolver=new o(i,l,t,n,r),this.resolver.scheduleResolve()}initPlayback(e){let t,n,{type:r="keyframes",repeat:i=0,repeatDelay:o=0,repeatType:l,velocity:s=0}=this.options,a=tS[r]||tE;a!==tE&&"number"!=typeof e[0]&&(t=tl(tT,tw(e[0],e[1])),e=[0,100]);let u=a({...this.options,keyframes:e});"mirror"===l&&(n=a({...this.options,keyframes:[...e].reverse(),velocity:-s})),null===u.calculatedDuration&&(u.calculatedDuration=function(e){let t=0,n=e.next(t);for(;!n.done&&t<2e4;)t+=50,n=e.next(t);return t>=2e4?1/0:t}(u));let{calculatedDuration:c}=u,d=c+o;return{generator:u,mirroredGenerator:n,mapPercentToKeyframes:t,calculatedDuration:c,resolvedDuration:d,totalDuration:d*(i+1)-o}}onPostResolved(){let{autoplay:e=!0}=this.options;this.play(),"paused"!==this.pendingPlayState&&e?this.state=this.pendingPlayState:this.pause()}tick(e,t=!1){let{resolved:n}=this;if(!n){let{keyframes:e}=this.options;return{done:!0,value:e[e.length-1]}}let{finalKeyframe:r,generator:i,mirroredGenerator:o,mapPercentToKeyframes:l,keyframes:s,calculatedDuration:a,totalDuration:u,resolvedDuration:c}=n;if(null===this.startTime)return i.next(0);let{delay:d,repeat:h,repeatType:p,repeatDelay:f,onUpdate:m}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,e):this.speed<0&&(this.startTime=Math.min(e-u/this.speed,this.startTime)),t?this.currentTime=e:null!==this.holdTime?this.currentTime=this.holdTime:this.currentTime=Math.round(e-this.startTime)*this.speed;let g=this.currentTime-d*(this.speed>=0?1:-1),v=this.speed>=0?g<0:g>u;this.currentTime=Math.max(g,0),"finished"===this.state&&null===this.holdTime&&(this.currentTime=u);let y=this.currentTime,x=i;if(h){let e=Math.min(this.currentTime,u)/c,t=Math.floor(e),n=e%1;!n&&e>=1&&(n=1),1===n&&t--,(t=Math.min(t,h+1))%2&&("reverse"===p?(n=1-n,f&&(n-=f/c)):"mirror"===p&&(x=o)),y=N(0,1,n)*c}let b=v?{done:!1,value:s[0]}:x.next(y);l&&(b.value=l(b.value));let{done:w}=b;v||null===a||(w=this.speed>=0?this.currentTime>=u:this.currentTime<=0);let E=null===this.holdTime&&("finished"===this.state||"running"===this.state&&w);return E&&void 0!==r&&(b.value=T(s,this.options,r)),m&&m(b.value),E&&this.finish(),b}get duration(){let{resolved:e}=this;return e?e.calculatedDuration/1e3:0}get time(){return this.currentTime/1e3}set time(e){e=m(e),this.currentTime=e,null!==this.holdTime||0===this.speed?this.holdTime=e:this.driver&&(this.startTime=this.driver.now()-e/this.speed)}get speed(){return this.playbackSpeed}set speed(e){let t=this.playbackSpeed!==e;this.playbackSpeed=e,t&&(this.time=this.currentTime/1e3)}play(){if(this.resolver.isScheduled||this.resolver.resume(),!this._resolved){this.pendingPlayState="running";return}if(this.isStopped)return;let{driver:e=tk,onPlay:t,startTime:n}=this.options;this.driver||(this.driver=e(e=>this.tick(e))),t&&t();let r=this.driver.now();null!==this.holdTime?this.startTime=r-this.holdTime:this.startTime?"finished"===this.state&&(this.startTime=r):this.startTime=null!=n?n:this.calcStartTime(),"finished"===this.state&&this.updateFinishedPromise(),this.cancelTime=this.startTime,this.holdTime=null,this.state="running",this.driver.start()}pause(){var e;if(!this._resolved){this.pendingPlayState="paused";return}this.state="paused",this.holdTime=null!=(e=this.currentTime)?e:0}complete(){"running"!==this.state&&this.play(),this.pendingPlayState=this.state="finished",this.holdTime=null}finish(){this.teardown(),this.state="finished";let{onComplete:e}=this.options;e&&e()}cancel(){null!==this.cancelTime&&this.tick(this.cancelTime),this.teardown(),this.updateFinishedPromise()}teardown(){this.state="idle",this.stopDriver(),this.resolveFinishedProm
1ise(),this.updateFinishedPromise(),this.startTime=this.cancelTime=null,this.resolver.cancel()}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(e){return this.startTime=0,this.tick(e,!0)}}let tP=new Set(["opacity","clipPath","filter","transform"]),tA=e=>Array.isArray(e)&&"number"==typeof e[0],tR=([e,t,n,r])=>`cubic-bezier(${e}, ${t}, ${n}, ${r})`,t_={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:tR([0,.65,.55,1]),circOut:tR([.55,0,1,.45]),backIn:tR([.31,.01,.66,-.59]),backOut:tR([.33,1.53,.69,.99])};function tI(e){return tD(e)||t_.easeOut}function tD(e){if(e)return tA(e)?tR(e):Array.isArray(e)?e.map(tI):t_[e]}let tL=ez(()=>Object.hasOwnProperty.call(Element.prototype,"animate"));class tM extends eY{constructor(e){super(e);let{name:t,motionValue:n,element:r,keyframes:i}=this.options;this.resolver=new eU(i,(e,t)=>this.onKeyframesResolved(e,t),t,n,r),this.resolver.scheduleResolve()}initPlayback(e,t){var n,r;let{duration:i=300,times:o,ease:l,type:s,motionValue:a,name:u,startTime:c}=this.options;if(!(null==(n=a.owner)?void 0:n.current))return!1;if("spring"===(r=this.options).type||!function e(t){return!!(!t||"string"==typeof t&&t in t_||tA(t)||Array.isArray(t)&&t.every(e))}(r.ease)){let{onComplete:t,onUpdate:n,motionValue:r,element:a,...u}=this.options,c=function(e,t){let n=new tC({...t,keyframes:e,repeat:0,delay:0,isGenerator:!0}),r={done:!1,value:e[0]},i=[],o=0;for(;!r.done&&o<2e4;)i.push((r=n.sample(o)).value),o+=10;return{times:void 0,keyframes:i,duration:o-10,ease:"linear"}}(e,u);1===(e=c.keyframes).length&&(e[1]=e[0]),i=c.duration,o=c.times,l=c.ease,s="keyframes"}let d=function(e,t,n,{delay:r=0,duration:i=300,repeat:o=0,repeatType:l="loop",ease:s,times:a}={}){let u={[t]:n};a&&(u.offset=a);let c=tD(s);return Array.isArray(c)&&(u.easing=c),e.animate(u,{delay:r,duration:i,easing:Array.isArray(c)?"linear":c,fill:"both",iterations:o+1,direction:"reverse"===l?"alternate":"normal"})}(a.owner.current,u,e,{...this.options,duration:i,times:o,ease:l});return d.startTime=null!=c?c:this.calcStartTime(),this.pendingTimeline?(d.timeline=this.pendingTimeline,this.pendingTimeline=void 0):d.onfinish=()=>{let{onComplete:n}=this.options;a.set(T(e,this.options,t)),n&&n(),this.cancel(),this.resolveFinishedPromise()},{animation:d,duration:i,times:o,type:s,ease:l,keyframes:e}}get duration(){let{resolved:e}=this;if(!e)return 0;let{duration:t}=e;return t/1e3}get time(){let{resolved:e}=this;if(!e)return 0;let{animation:t}=e;return(t.currentTime||0)/1e3}set time(e){let{resolved:t}=this;if(!t)return;let{animation:n}=t;n.currentTime=m(e)}get speed(){let{resolved:e}=this;if(!e)return 1;let{animation:t}=e;return t.playbackRate}set speed(e){let{resolved:t}=this;if(!t)return;let{animation:n}=t;n.playbackRate=e}get state(){let{resolved:e}=this;if(!e)return"idle";let{animation:t}=e;return t.playState}get startTime(){let{resolved:e}=this;if(!e)return null;let{animation:t}=e;return t.startTime}attachTimeline(e){if(this._resolved){let{resolved:t}=this;if(!t)return A.l;let{animation:n}=t;n.timeline=e,n.onfinish=null}else this.pendingTimeline=e;return A.l}play(){if(this.isStopped)return;let{resolved:e}=this;if(!e)return;let{animation:t}=e;"finished"===t.playState&&this.updateFinishedPromise(),t.play()}pause(){let{resolved:e}=this;if(!e)return;let{animation:t}=e;t.pause()}stop(){if(this.resolver.cancel(),this.isStopped=!0,"idle"===this.state)return;this.resolveFinishedPromise(),this.updateFinishedPromise();let{resolved:e}=this;if(!e)return;let{animation:t,keyframes:n,duration:r,type:i,ease:o,times:l}=e;if("idle"===t.playState||"finished"===t.playState)return;if(this.time){let{motionValue:e,onUpdate:t,onComplete:s,element:a,...u}=this.options,c=new tC({...u,keyframes:n,duration:r,type:i,ease:o,times:l,isGenerator:!0}),d=m(this.time);e.setWithVelocity(c.sample(d-10).value,c.sample(d).value,10)}let{onStop:s}=this.options;s&&s(),this.cancel()}complete(){let{resolved:e}=this;e&&e.animation.finish()}cancel(){let{resolved:e}=this;e&&e.animation.cancel()}static supports(e){let{motionValue:t,name:n,repeatDelay:r,repeatType:i,damping:o,type:l}=e;return tL()&&n&&tP.has(n)&&t&&t.owner&&t.owner.current instanceof HTMLElement&&!t.owner.getProps().onUp
1date&&!r&&"mirror"!==i&&0!==o&&"inertia"!==l}}let tF=ez(()=>void 0!==window.ScrollTimeline);class tO{constructor(e){this.stop=()=>this.runAll("stop"),this.animations=e.filter(Boolean)}then(e,t){return Promise.all(this.animations).then(e).catch(t)}getAll(e){return this.animations[0][e]}setAll(e,t){for(let n=0;n<this.animations.length;n++)this.animations[n][e]=t}attachTimeline(e){let t=this.animations.map(t=>{if(tF()&&t.attachTimeline)t.attachTimeline(e);else{let n;t.pause();let r=()=>{var r;let{currentTime:i}=e,o=(null===i?0:i.value)/100;n!==o&&(r=o,t.time=t.duration*r),n=o};return C.Gt.update(r,!0),()=>(0,C.WG)(r)}});return()=>{t.forEach((e,t)=>{e&&e(),this.animations[t].stop()})}}get time(){return this.getAll("time")}set time(e){this.setAll("time",e)}get speed(){return this.getAll("speed")}set speed(e){this.setAll("speed",e)}get startTime(){return this.getAll("startTime")}get duration(){let e=0;for(let t=0;t<this.animations.length;t++)e=Math.max(e,this.animations[t].duration);return e}runAll(e){this.animations.forEach(t=>t[e]())}play(){this.runAll("play")}pause(){this.runAll("pause")}cancel(){this.runAll("cancel")}complete(){this.runAll("complete")}}let tj=(e,t,n,r={},i,o,l)=>s=>{let a=x(r,e)||{},u=a.delay||r.delay||0,{elapsed:c=0}=r;c-=m(u);let d={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:t.getVelocity(),...a,delay:-c,onUpdate:e=>{t.set(e),a.onUpdate&&a.onUpdate(e)},onComplete:()=>{s(),a.onComplete&&a.onComplete(),l&&l()},onStop:l,name:e,motionValue:t,element:o?void 0:i};!function({when:e,delay:t,delayChildren:n,staggerChildren:r,staggerDirection:i,repeat:o,repeatType:l,repeatDelay:s,from:a,elapsed:u,...c}){return!!Object.keys(c).length}(a)&&(d={...d,...((e,{keyframes:t})=>t.length>2?v:f.has(e)?e.startsWith("scale")?{type:"spring",stiffness:550,damping:0===t[1]?2*Math.sqrt(550):30,restSpeed:10}:g:y)(e,d)}),d.duration&&(d.duration=m(d.duration)),d.repeatDelay&&(d.repeatDelay=m(d.repeatDelay)),void 0!==d.from&&(d.keyframes[0]=d.from);let h=!1;if(!1!==d.type&&(0!==d.duration||d.repeatDelay)||(d.duration=0,0===d.delay&&(h=!0)),(k.current||E.W.skipAnimations)&&(h=!0,d.duration=0,d.delay=0),h&&!o&&void 0!==t.get()){let e=T(d.keyframes,a);if(void 0!==e)return C.Gt.update(()=>{d.onUpdate(e),d.onComplete()}),new tO([])}return!o&&tM.supports(d)?new tM(d):new tC(d)},tN=e=>o(e)?e[e.length-1]||0:e;function tV(e,t){-1===e.indexOf(t)&&e.push(t)}function tB(e,t){let n=e.indexOf(t);n>-1&&e.splice(n,1)}class tU{constructor(){this.subscriptions=[]}add(e){return tV(this.subscriptions,e),()=>tB(this.subscriptions,e)}notify(e,t,n){let r=this.subscriptions.length;if(r)if(1===r)this.subscriptions[0](e,t,n);else for(let i=0;i<r;i++){let r=this.subscriptions[i];r&&r(e,t,n)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}let tz={current:void 0};class tH{constructor(e,t={}){this.version="12.0.0-alpha.1",this.canTrackVelocity=null,this.events={},this.updateAndNotify=(e,t=!0)=>{let n=eW.now();this.updatedAt!==n&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(e),this.current!==this.prev&&this.events.change&&this.events.change.notify(this.current),t&&this.events.renderRequest&&this.events.renderRequest.notify(this.current)},this.hasAnimated=!1,this.setCurrent(e),this.owner=t.owner}setCurrent(e){this.current=e,this.updatedAt=eW.now(),null===this.canTrackVelocity&&void 0!==e&&(this.canTrackVelocity=!isNaN(parseFloat(this.current)))}setPrevFrameValue(e=this.current){this.prevFrameValue=e,this.prevUpdatedAt=this.updatedAt}onChange(e){return this.on("change",e)}on(e,t){this.events[e]||(this.events[e]=new tU);let n=this.events[e].add(t);return"change"===e?()=>{n(),C.Gt.read(()=>{this.events.change.getSize()||this.stop()})}:n}clearListeners(){for(let e in this.events)this.events[e].clear()}attach(e,t){this.passiveEffect=e,this.stopPassiveEffect=t}set(e,t=!0){t&&this.passiveEffect?this.passiveEffect(e,this.updateAndNotify):this.updateAndNotify(e,t)}setWithVelocity(e,t,n){this.set(t),this.prev=void 0,this.prevFrameValue=e,this.prevUpdatedAt=this.updatedAt-n}jump(e,t=!0){this.updateAndNotify(e),this.prev=e,this.prevUpdatedAt=this.prevFrameValue=void 0,t&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}get(){return tz.current&&tz.current.push(this),this.current}getPrevious(){return this.prev}getVelocity(){var e;let t=eW.now();if(!this.canTrackVelocity||void 0===this.prevFrameValue||t-this.updatedAt>30)return 0;let n=Math.min(this.updatedAt-this.prevUpdatedAt,30);return e=parseFloat(this.current)-parseFloat(this.prevFrameValue),n?1e3/n*e:0}start(e){return this.stop(),new Promise(t=>{this.hasAnimated=!0,this.animation=e(t),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 tW(e,t){return new tH(e,t)}let tq=e=>e.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),tY="data-"+tq("framerAppearId");function tG(e){return f.has(e)?"transform":tP.has(e)?tq(e):void 0}class t$ extends tH{constructor(){super(...arguments),this.output=[],this.counts=new Map}add(e){let t=tG(e);if(!t)return;let n=this.counts.get(t)||0;this.counts.set(t,n+1),0===n&&(this.output.push(t),this.update());let r=!1;return()=>{if(r)return;r=!0;let e=this.counts.get(t)-1;this.counts.set(t,e),0===e&&(tB(this.output,t),this.update())}}update(){this.set(this.output.length?this.output.join(", "):"auto")}}let tX=e=>!!(e&&e.getVelocity);function tK(e,t){var n,r;if(!e.applyWillChange)return;let i=e.getValue("willChange");if(i||(null==(n=e.props.style)?void 0:n.willChange)||(i=new t$("auto"),e.addValue("willChange",i
1)),tX(r=i)&&r.add)return i.add(t)}function tJ(e,t,{delay:n=0,transitionOverride:r,type:i}={}){var o;let{transition:l=e.getDefaultTransition(),transitionEnd:s,...a}=t;r&&(l=r);let u=[],d=i&&e.animationState&&e.animationState.getState()[i];for(let t in a){let r=e.getValue(t,null!=(o=e.latestValues[t])?o:null),i=a[t];if(void 0===i||d&&function({protectedKeys:e,needsAnimating:t},n){let r=e.hasOwnProperty(n)&&!0!==t[n];return t[n]=!1,r}(d,t))continue;let s={delay:n,...x(l||{},t)},c=!1;if(window.MotionHandoffAnimation){let n=e.props[tY];if(n){let e=window.MotionHandoffAnimation(n,t,C.Gt);null!==e&&(s.startTime=e,c=!0)}}r.start(tj(t,r,i,e.shouldReduceMotion&&f.has(t)?{type:!1}:s,e,c,tK(e,t)));let h=r.animation;h&&u.push(h)}return s&&Promise.all(u).then(()=>{C.Gt.update(()=>{s&&function(e,t){let{transitionEnd:n={},transition:r={},...i}=c(e,t)||{};for(let t in i={...i,...n}){let n=tN(i[t]);e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,tW(n))}}(e,s)})}),u}function tZ(e,t,n={}){var r;let i=c(e,t,"exit"===n.type?null==(r=e.presenceContext)?void 0:r.custom:void 0),{transition:o=e.getDefaultTransition()||{}}=i||{};n.transitionOverride&&(o=n.transitionOverride);let l=i?()=>Promise.all(tJ(e,i,n)):()=>Promise.resolve(),s=e.variantChildren&&e.variantChildren.size?(r=0)=>{let{delayChildren:i=0,staggerChildren:l,staggerDirection:s}=o;return function(e,t,n=0,r=0,i=1,o){let l=[],s=(e.variantChildren.size-1)*r,a=1===i?(e=0)=>e*r:(e=0)=>s-e*r;return Array.from(e.variantChildren).sort(tQ).forEach((e,r)=>{e.notify("AnimationStart",t),l.push(tZ(e,t,{...o,delay:n+a(r)}).then(()=>e.notify("AnimationComplete",t)))}),Promise.all(l)}(e,t,i+r,l,s,n)}:()=>Promise.resolve(),{when:a}=o;if(!a)return Promise.all([l(),s(n.delay)]);{let[e,t]="beforeChildren"===a?[l,s]:[s,l];return e().then(()=>t())}}function tQ(e,t){return e.sortNodePosition(t)}let t0=[...d].reverse(),t1=d.length;function t2(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function t4(){return{animate:t2(!0),whileInView:t2(),whileHover:t2(),whileTap:t2(),whileDrag:t2(),whileFocus:t2(),exit:t2()}}class t3{constructor(e){this.isMounted=!1,this.node=e}update(){}}class t5 extends t3{constructor(e){super(e),e.animationState||(e.animationState=function(e){let t=t=>Promise.all(t.map(({animation:t,options:n})=>(function(e,t,n={}){let r;if(e.notify("AnimationStart",t),Array.isArray(t))r=Promise.all(t.map(t=>tZ(e,t,n)));else if("string"==typeof t)r=tZ(e,t,n);else{let i="function"==typeof t?c(e,t,n.custom):t;r=Promise.all(tJ(e,i,n))}return r.then(()=>{e.notify("AnimationComplete",t)})})(e,t,n))),n=t4(),r=!0,a=t=>(n,r)=>{var i;let o=c(e,r,"exit"===t?null==(i=e.presenceContext)?void 0:i.custom:void 0);if(o){let{transition:e,transitionEnd:t,...r}=o;n={...n,...r,...t}}return n};function u(u){let c=e.getProps(),d=e.getVariantContext(!0)||{},h=[],p=new Set,f={},m=1/0;for(let t=0;t<t1;t++){var g,v;let y=t0[t],x=n[y],b=void 0!==c[y]?c[y]:d[y],w=s(b),E=y===u?x.isActive:null;!1===E&&(m=t);let k=b===d[y]&&b!==c[y]&&w;if(k&&r&&e.manuallyAnimateOnMount&&(k=!1),x.protectedKeys={...f},!x.isActive&&null===E||!b&&!x.prevProp||i(b)||"boolean"==typeof b)continue;let S=(g=x.prevProp,("string"==typeof(v=b)?v!==g:!!Array.isArray(v)&&!l(v,g))||y===u&&x.isActive&&!k&&w||t>m&&w),T=!1,C=Array.isArray(b)?b:[b],P=C.reduce(a(y),{});!1===E&&(P={});let{prevResolvedValues:A={}}=x,R={...A,...P},_=t=>{S=!0,p.has(t)&&(T=!0,p.delete(t)),x.needsAnimating[t]=!0;let n=e.getValue(t);n&&(n.liveStyle=!1)};for(let e in R){let t=P[e],n=A[e];if(!f.hasOwnProperty(e))(o(t)&&o(n)?l(t,n):t===n)?void 0!==t&&p.has(e)?_(e):x.protectedKeys[e]=!0:null!=t?_(e):p.add(e)}x.prevProp=b,x.prevResolvedValues=P,x.isActive&&(f={...f,...P}),r&&e.blockInitialAnimation&&(S=!1),S&&(!k||T)&&h.push(...C.map(e=>({animation:e,options:{type:y}})))}if(p.size){let t={};p.forEach(n=>{let r=e.getBaseTarget(n),i=e.getValue(n);i&&(i.liveStyle=!0),t[n]=null!=r?r:null}),h.push({animation:t})}let y=!!h.length;return r&&(!1===c.initial||c.initial===c.animate)&&!e.manuallyAnimateOnMount&&(y=!1),r=!1,y?t(h):Promise.resolve()}return{animateChanges:u,setActive:function(t,r){var i;if(n[t].isActive===r)return Promise.resolve();
1null==(i=e.variantChildren)||i.forEach(e=>{var n;return null==(n=e.animationState)?void 0:n.setActive(t,r)}),n[t].isActive=r;let o=u(t);for(let e in n)n[e].protectedKeys={};return o},setAnimateFunction:function(n){t=n(e)},getState:()=>n,reset:()=>{n=t4(),r=!0}}}(e))}updateAnimationControlsSubscription(){let{animate:e}=this.node.getProps();i(e)&&(this.unmountControls=e.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){let{animate:e}=this.node.getProps(),{animate:t}=this.node.prevProps||{};e!==t&&this.updateAnimationControlsSubscription()}unmount(){var e;this.node.animationState.reset(),null==(e=this.unmountControls)||e.call(this)}}let t6=0;class t9 extends t3{constructor(){super(...arguments),this.id=t6++}update(){if(!this.node.presenceContext)return;let{isPresent:e,onExitComplete:t}=this.node.presenceContext,{isPresent:n}=this.node.prevPresenceContext||{};if(!this.node.animationState||e===n)return;let r=this.node.animationState.setActive("exit",!e);t&&!e&&r.then(()=>t(this.id))}mount(){let{register:e}=this.node.presenceContext||{};e&&(this.unmount=e(this.id))}unmount(){}}let t7=e=>"mouse"===e.pointerType?"number"!=typeof e.button||e.button<=0:!1!==e.isPrimary;function t8(e,t="page"){return{point:{x:e[`${t}X`],y:e[`${t}Y`]}}}function ne(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n)}function nt(e,t,n,r){return ne(e,t,e=>t7(e)&&n(e,t8(e)),r)}let nn=(e,t)=>Math.abs(e-t);class nr{constructor(e,t,{transformPagePoint:n,contextWindow:r,dragSnapToOrigin:i=!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 e=nl(this.lastMoveEventInfo,this.history),t=null!==this.startEvent,n=function(e,t){return Math.sqrt(nn(e.x,t.x)**2+nn(e.y,t.y)**2)}(e.offset,{x:0,y:0})>=3;if(!t&&!n)return;let{point:r}=e,{timestamp:i}=C.uv;this.history.push({...r,timestamp:i});let{onStart:o,onMove:l}=this.handlers;t||(o&&o(this.lastMoveEvent,e),this.startEvent=this.lastMoveEvent),l&&l(this.lastMoveEvent,e)},this.handlePointerMove=(e,t)=>{this.lastMoveEvent=e,this.lastMoveEventInfo=ni(t,this.transformPagePoint),C.Gt.update(this.updatePoint,!0)},this.handlePointerUp=(e,t)=>{this.end();let{onEnd:n,onSessionEnd:r,resumeAnimation:i}=this.handlers;if(this.dragSnapToOrigin&&i&&i(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;let o=nl("pointercancel"===e.type?this.lastMoveEventInfo:ni(t,this.transformPagePoint),this.history);this.startEvent&&n&&n(e,o),r&&r(e,o)},!t7(e))return;this.dragSnapToOrigin=i,this.handlers=t,this.transformPagePoint=n,this.contextWindow=r||window;let o=ni(t8(e),this.transformPagePoint),{point:l}=o,{timestamp:s}=C.uv;this.history=[{...l,timestamp:s}];let{onSessionStart:a}=t;a&&a(e,nl(o,this.history)),this.removeListeners=tl(nt(this.contextWindow,"pointermove",this.handlePointerMove),nt(this.contextWindow,"pointerup",this.handlePointerUp),nt(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(e){this.handlers=e}end(){this.removeListeners&&this.removeListeners(),(0,C.WG)(this.updatePoint)}}function ni(e,t){return t?{point:t(e.point)}:e}function no(e,t){return{x:e.x-t.x,y:e.y-t.y}}function nl({point:e},t){return{point:e,delta:no(e,ns(t)),offset:no(e,t[0]),velocity:function(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null,i=ns(e);for(;n>=0&&(r=e[n],!(i.timestamp-r.timestamp>m(.1)));)n--;if(!r)return{x:0,y:0};let o=(i.timestamp-r.timestamp)/1e3;if(0===o)return{x:0,y:0};let l={x:(i.x-r.x)/o,y:(i.y-r.y)/o};return l.x===1/0&&(l.x=0),l.y===1/0&&(l.y=0),l}(t,.1)}}function ns(e){return e[e.length-1]}function na(e){let t=null;return()=>null===t&&(t=e,()=>{t=null})}let nu=na("dragHorizontal"),nc=na("dragVertical");function nd(e){let t=!1;if("y"===e)t=nc();else if("x"===e)t=nu();else{let e=nu(),n=nc();e&&n?t=()=>{e(),n()}:(e&&e(),n&&n())}return t}function nh(){let e=nd(!0);return!e||(e(),!1)}function np(e){return e&&"object"==typeof e&&Object.prototype.hasOwnProperty.call(e,"current")}function nf(e){return e.max-e.min}function nm(e,t,n,r=.5){e.origin=r,e.originPoint=ta(t.min,t.max,e.origin),e.scale=nf(n)/nf(t),e.translate=ta(n.min,n.max,e.origin)-e.originPoint,(e.scale>=.9999&&e.scale<=1.0001||isNaN(e.scale))&&(e.scale=1),(e.translate>=-.01&&e.translate<=.01||isNaN(e.translate))&&(e.translate=0)}function ng(e,t,n,r){nm(e.x,t.x,n.x,r?r.originX:void 0),nm(e.y,t.y,n.y,r?r.originY:void 0)}function nv(e,t,n){e.min=n.min+t.min,e.max=e.min+nf(t)}
1function ny(e,t,n){e.min=t.min-n.min,e.max=e.min+nf(t)}function nx(e,t,n){ny(e.x,t.x,n.x),ny(e.y,t.y,n.y)}function nb(e,t,n){return{min:void 0!==t?e.min+t:void 0,max:void 0!==n?e.max+n-(e.max-e.min):void 0}}function nw(e,t){let n=t.min-e.min,r=t.max-e.max;return t.max-t.min<e.max-e.min&&([n,r]=[r,n]),{min:n,max:r}}function nE(e,t,n){return{min:nk(e,t),max:nk(e,n)}}function nk(e,t){return"number"==typeof e?e:e[t]||0}let nS=()=>({translate:0,scale:1,origin:0,originPoint:0}),nT=()=>({x:nS(),y:nS()}),nC=()=>({min:0,max:0}),nP=()=>({x:nC(),y:nC()});function nA(e){return[e("x"),e("y")]}function nR({top:e,left:t,right:n,bottom:r}){return{x:{min:t,max:n},y:{min:e,max:r}}}function n_(e){return void 0===e||1===e}function nI({scale:e,scaleX:t,scaleY:n}){return!n_(e)||!n_(t)||!n_(n)}function nD(e){return nI(e)||nL(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function nL(e){var t,n;return(t=e.x)&&"0%"!==t||(n=e.y)&&"0%"!==n}function nM(e,t,n,r,i){return void 0!==i&&(e=r+i*(e-r)),r+n*(e-r)+t}function nF(e,t=0,n=1,r,i){e.min=nM(e.min,t,n,r,i),e.max=nM(e.max,t,n,r,i)}function nO(e,{x:t,y:n}){nF(e.x,t.translate,t.scale,t.originPoint),nF(e.y,n.translate,n.scale,n.originPoint)}function nj(e,t){e.min=e.min+t,e.max=e.max+t}function nN(e,t,n,r,i=.5){let o=ta(e.min,e.max,i);nF(e,t,n,o,r)}function nV(e,t){nN(e.x,t.x,t.scaleX,t.scale,t.originX),nN(e.y,t.y,t.scaleY,t.scale,t.originY)}function nB(e,t){return nR(function(e,t){if(!t)return e;let n=t({x:e.left,y:e.top}),r=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:r.y,right:r.x}}(e.getBoundingClientRect(),t))}let nU=({current:e})=>e?e.ownerDocument.defaultView:null,nz=new WeakMap;class nH{constructor(e){this.openGlobalLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=nP(),this.visualElement=e}start(e,{snapToCursor:t=!1}={}){let{presenceContext:n}=this.visualElement;if(n&&!1===n.isPresent)return;let r=e=>{let{dragSnapToOrigin:n}=this.getProps();n?this.pauseAnimation():this.stopAnimation(),t&&this.snapToCursor(t8(e,"page").point)},i=(e,t)=>{var n;let{drag:r,dragPropagation:i,onDragStart:o}=this.getProps();if(r&&!i&&(this.openGlobalLock&&this.openGlobalLock(),this.openGlobalLock=nd(r),!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),nA(e=>{let t=this.getAxisMotionValue(e).get()||0;if(X.test(t)){let{projection:n}=this.visualElement;if(n&&n.layout){let r=n.layout.layoutBox[e];r&&(t=nf(r)*(parseFloat(t)/100))}}this.originPoint[e]=t}),o&&C.Gt.postRender(()=>o(e,t)),null==(n=this.removeWillChange)||n.call(this),this.removeWillChange=tK(this.visualElement,"transform");let{animationState:l}=this.visualElement;l&&l.setActive("whileDrag",!0)},o=(e,t)=>{let{dragPropagation:n,dragDirectionLock:r,onDirectionLock:i,onDrag:o}=this.getProps();if(!n&&!this.openGlobalLock)return;let{offset:l}=t;if(r&&null===this.currentDirection){this.currentDirection=function(e,t=10){let n=null;return Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x"),n}(l),null!==this.currentDirection&&i&&i(this.currentDirection);return}this.updateAxis("x",t.point,l),this.updateAxis("y",t.point,l),this.visualElement.render(),o&&o(e,t)},l=(e,t)=>this.stop(e,t),s=()=>nA(e=>{var t;return"paused"===this.getAnimationState(e)&&(null==(t=this.getAxisMotionValue(e).animation)?void 0:t.play())}),{dragSnapToOrigin:a}=this.getProps();this.panSession=new nr(e,{onSessionStart:r,onStart:i,onMove:o,onSessionEnd:l,resumeAnimation:s},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:a,contextWindow:nU(this.visualElement)})}stop(e,t){var n;null==(n=this.removeWillChange)||n.call(this);let r=this.isDragging;if(this.cancel(),!r)return;let{velocity:i}=t;this.startAnimation(i);let{onDragEnd:o}=this.getProps();o&&C.Gt.postRender(()=>o(e,t))}cancel(){this.isDragging=!1;let{projection:e,animationState:t}=this.visualElement;e&&(e.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;let{dragPropagation:n}=this.getProps();!n&&this.openGlobalLock&&(this.openGlobalLock(),this.openGlobalLock=null),t&&t.setActive("whileDrag",!1)}updateAxis(e,t,n){let{drag:r}=this.getProps();if(!n||!nW(e,r,this.currentDirection))return;let i=this.getAxisMotionValue(e),o=this.originPoint[e]+n[e];this.constraints&&this.constraints[e]&&(o=function(e,{min:t,max:n},r){return void 0!==t&&e<t?e=r?ta(t,e,r.min):Math.max(e,t):void 0!==n&&e>n&&(e=r?ta(n,e,r.max):Math.min(e,n)),e}(o,this.constraints[e],this.elastic[e])),i.set(o)}resolveConstraints(){var e;let{dragConstraints:t,dragElastic:n}=this.getProps(),r=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):null==(e=this.visualElement.projection)?void 0:e.layout,i=this.constraints;t&&np(t)?this.constraints||(this.constraints=this.resolveRefConstraints()):t&&r?this.constraints=function(e,{top:t,left:n,bottom:r,right:i}){return{x:nb(e.x,n,i),y:nb(e.y,t,r)}}(r.layoutBox,t):this.constraints=!1,this.elastic=function(e=.35){return!1===e?e=0:!0===e&&(e=.35),{x:nE(e,"left","right"),y:nE(e,"to
1p","bottom")}}(n),i!==this.constraints&&r&&this.constraints&&!this.hasMutatedConstraints&&nA(e=>{!1!==this.constraints&&this.getAxisMotionValue(e)&&(this.constraints[e]=function(e,t){let n={};return void 0!==t.min&&(n.min=t.min-e.min),void 0!==t.max&&(n.max=t.max-e.min),n}(r.layoutBox[e],this.constraints[e]))})}resolveRefConstraints(){var e;let{dragConstraints:t,onMeasureDragConstraints:n}=this.getProps();if(!t||!np(t))return!1;let r=t.current;_(null!==r,"If `dragConstraints` is set as a React ref, that ref must be passed to another component's `ref` prop.");let{projection:i}=this.visualElement;if(!i||!i.layout)return!1;let o=function(e,t,n){let r=nB(e,n),{scroll:i}=t;return i&&(nj(r.x,i.offset.x),nj(r.y,i.offset.y)),r}(r,i.root,this.visualElement.getTransformPagePoint()),l=(e=i.layout.layoutBox,{x:nw(e.x,o.x),y:nw(e.y,o.y)});if(n){let e=n(function({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}(l));this.hasMutatedConstraints=!!e,e&&(l=nR(e))}return l}startAnimation(e){let{drag:t,dragMomentum:n,dragElastic:r,dragTransition:i,dragSnapToOrigin:o,onDragTransitionEnd:l}=this.getProps(),s=this.constraints||{};return Promise.all(nA(l=>{if(!nW(l,t,this.currentDirection))return;let a=s&&s[l]||{};o&&(a={min:0,max:0});let u={type:"inertia",velocity:n?e[l]:0,bounceStiffness:r?200:1e6,bounceDamping:r?40:1e7,timeConstant:750,restDelta:1,restSpeed:10,...i,...a};return this.startAxisValueAnimation(l,u)})).then(l)}startAxisValueAnimation(e,t){let n=this.getAxisMotionValue(e);return n.start(tj(e,n,0,t,this.visualElement,!1,tK(this.visualElement,e)))}stopAnimation(){nA(e=>this.getAxisMotionValue(e).stop())}pauseAnimation(){nA(e=>{var t;return null==(t=this.getAxisMotionValue(e).animation)?void 0:t.pause()})}getAnimationState(e){var t;return null==(t=this.getAxisMotionValue(e).animation)?void 0:t.state}getAxisMotionValue(e){let t=`_drag${e.toUpperCase()}`,n=this.visualElement.getProps();return n[t]||this.visualElement.getValue(e,(n.initial?n.initial[e]:void 0)||0)}snapToCursor(e){nA(t=>{let{drag:n}=this.getProps();if(!nW(t,n,this.currentDirection))return;let{projection:r}=this.visualElement,i=this.getAxisMotionValue(t);if(r&&r.layout){let{min:n,max:o}=r.layout.layoutBox[t];i.set(e[t]-ta(n,o,.5))}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;let{drag:e,dragConstraints:t}=this.getProps(),{projection:n}=this.visualElement;if(!np(t)||!n||!this.constraints)return;this.stopAnimation();let r={x:0,y:0};nA(e=>{let t=this.getAxisMotionValue(e);if(t&&!1!==this.constraints){let n=t.get();r[e]=function(e,t){let n=.5,r=nf(e),i=nf(t);return i>r?n=ts(t.min,t.max-r,e.min):r>i&&(n=ts(e.min,e.max-i,t.min)),N(0,1,n)}({min:n,max:n},this.constraints[e])}});let{transformTemplate:i}=this.visualElement.getProps();this.visualElement.current.style.transform=i?i({},""):"none",n.root&&n.root.updateScroll(),n.updateLayout(),this.resolveConstraints(),nA(t=>{if(!nW(t,e,null))return;let n=this.getAxisMotionValue(t),{min:i,max:o}=this.constraints[t];n.set(ta(i,o,r[t]))})}addListeners(){if(!this.visualElement.current)return;nz.set(this.visualElement,this);let e=nt(this.visualElement.current,"pointerdown",e=>{let{drag:t,dragListener:n=!0}=this.getProps();t&&n&&this.start(e)}),t=()=>{let{dragConstraints:e}=this.getProps();np(e)&&e.current&&(this.constraints=this.resolveRefConstraints())},{projection:n}=this.visualElement,r=n.addEventListener("measure",t);n&&!n.layout&&(n.root&&n.root.updateScroll(),n.updateLayout()),C.Gt.read(t);let i=ne(window,"resize",()=>this.scalePositionWithinConstraints()),o=n.addEventListener("didUpdate",({delta:e,hasLayoutChanged:t})=>{this.isDragging&&t&&(nA(t=>{let n=this.getAxisMotionValue(t);n&&(this.originPoint[t]+=e[t].translate,n.set(n.get()+e[t].translate))}),this.visualElement.render())});return()=>{i(),e(),r(),o&&o()}}getProps(){let e=this.visualElement.getProps(),{drag:t=!1,dragDirectionLock:n=!1,dragPropagation:r=!1,dragConstraints:i=!1,dragElastic:o=.35,dragMomentum:l=!0}=e;return{...e,drag:t,dragDirectionLock:n,dragPropagation:r,dragConstraints:i,dragElastic:o,dragMomentum:l}}}function nW(e,t,n){return(!0===t||t===e)&&(null===n||n===e)}class nq extends t3{constructor(e){super(e),this.removeGroupControls=A.l,this.removeListeners=A.l,this.controls=new nH(e)}mount(){let{dragControls:e}=this.node.getProps();e&&(this.removeGroupControls=e.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||A.l}unmount(){this.removeGroupControls(),this.removeListeners()}}let nY=e=>(t,n)=>{e&&C.Gt.postRender(()=>e(t,n))};
1class nG extends t3{constructor(){super(...arguments),this.removePointerDownListener=A.l}onPointerDown(e){this.session=new nr(e,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:nU(this.node)})}createPanHandlers(){let{onPanSessionStart:e,onPanStart:t,onPan:n,onPanEnd:r}=this.node.getProps();return{onSessionStart:nY(e),onStart:nY(t),onMove:n,onEnd:(e,t)=>{delete this.session,r&&C.Gt.postRender(()=>r(e,t))}}}mount(){this.removePointerDownListener=nt(this.node.current,"pointerdown",e=>this.onPointerDown(e))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}var n$=n(11612),nX=n(32144);let nK=(0,nX.createContext)(null);var nJ=n(86436);let nZ=(0,nX.createContext)({}),nQ={hasAnimatedSinceResize:!0,hasEverUpdated:!1};function n0(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}let n1={correct:(e,t)=>{if(!t.target)return e;if("string"==typeof e)if(!K.test(e))return e;else e=parseFloat(e);let n=n0(e,t.target.x),r=n0(e,t.target.y);return`${n}% ${r}%`}},n2={},{schedule:n4,cancel:n3}=(0,n(85633).I)(queueMicrotask,!1);class n5 extends nX.Component{componentDidMount(){let{visualElement:e,layoutGroup:t,switchLayoutGroup:n,layoutId:r}=this.props,{projection:i}=e;Object.assign(n2,n9),i&&(t.group&&t.group.add(i),n&&n.register&&r&&n.register(i),i.root.didUpdate(),i.addEventListener("animationComplete",()=>{this.safeToRemove()}),i.setOptions({...i.options,onExitComplete:()=>this.safeToRemove()})),nQ.hasEverUpdated=!0}getSnapshotBeforeUpdate(e){let{layoutDependency:t,visualElement:n,drag:r,isPresent:i}=this.props,o=n.projection;return o&&(o.isPresent=i,r||e.layoutDependency!==t||void 0===t?o.willUpdate():this.safeToRemove(),e.isPresent!==i&&(i?o.promote():o.relegate()||C.Gt.postRender(()=>{let e=o.getStack();e&&e.members.length||this.safeToRemove()}))),null}componentDidUpdate(){let{projection:e}=this.props.visualElement;e&&(e.root.didUpdate(),n4.postRender(()=>{!e.currentAnimation&&e.isLead()&&this.safeToRemove()}))}componentWillUnmount(){let{visualElement:e,layoutGroup:t,switchLayoutGroup:n}=this.props,{projection:r}=e;r&&(r.scheduleCheckAfterUnmount(),t&&t.group&&t.group.remove(r),n&&n.deregister&&n.deregister(r))}safeToRemove(){let{safeToRemove:e}=this.props;e&&e()}render(){return null}}function n6(e){let[t,n]=function(){let e=(0,nX.useContext)(nK);if(null===e)return[!0,null];let{isPresent:t,onExitComplete:n,register:r}=e,i=(0,nX.useId)();(0,nX.useEffect)(()=>r(i),[]);let o=(0,nX.useCallback)(()=>n&&n(i),[i,n]);return!t&&n?[!1,o]:[!0]}(),r=(0,nX.useContext)(nJ.L);return(0,n$.jsx)(n5,{...e,layoutGroup:r,switchLayoutGroup:(0,nX.useContext)(nZ),isPresent:t,safeToRemove:n})}let n9={borderRadius:{...n1,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:n1,borderTopRightRadius:n1,borderBottomLeftRadius:n1,borderBottomRightRadius:n1,boxShadow:{correct:(e,{treeScale:t,projectionDelta:n})=>{let r=e_.parse(e);if(r.length>5)return e;let i=e_.createTransformer(e),o=+("number"!=typeof r[0]),l=n.x.scale*t.x,s=n.y.scale*t.y;r[0+o]/=l,r[1+o]/=s;let a=ta(l,s,.5);return"number"==typeof r[2+o]&&(r[2+o]/=a),"number"==typeof r[3+o]&&(r[3+o]/=a),i(r)}}},n7=["TopLeft","TopRight","BottomLeft","BottomRight"],n8=n7.length,re=e=>"string"==typeof e?parseFloat(e):e,rt=e=>"number"==typeof e||K.test(e);function rn(e,t){return void 0!==e[t]?e[t]:e.borderRadius}let rr=ro(0,.5,e7),ri=ro(.5,.95,A.l);function ro(e,t,n){return r=>r<e?0:r>t?1:n(ts(e,t,r))}function rl(e,t){e.min=t.min,e.max=t.max}function rs(e,t){rl(e.x,t.x),rl(e.y,t.y)}function ra(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}function ru(e,t,n,r,i){return e-=t,e=r+1/n*(e-r),void 0!==i&&(e=r+1/i*(e-r)),e}function rc(e,t,[n,r,i],o,l){!function(e,t=0,n=1,r=.5,i,o=e,l=e){if(X.test(t)&&(t=parseFloat(t),t=ta(l.min,l.max,t/100)-l.min),"number"!=typeof t)return;let s=ta(o.min,o.max,r);e===o&&(s-=t),e.min=ru(e.min,t,n,s,i),e.max=ru(e.max,t,n,s,i)}(e,t[n],t[r],t[i],t.scale,o,l)}let rd=["x","scaleX","originX"],rh=["y","scaleY","originY"];function rp(e,t,n,r){rc(e.x,t,rd,n?n.x:void 0,r?r.x:void 0),rc(e.y,t,rh,n?n.y:void 0,r?r.y:void 0)}function rf(e){return 0===e.translate&&1===e.scale}function rm(e){return rf(e.x)&&rf(e.y)}function rg(e,t){return e.min===t.min&&e.max===t.max}function rv(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function ry(e,t){return rv(e.x,t.x)&&rv(e.y,t.y)}function rx(e){return nf(e.x)/nf(e.y)}function rb(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}class rw{constructor(){this.members=[]}add(e){tV(this.members,e),e.scheduleRender()}remove(e){if(tB(this.members,e),e===this.prevLead&&(this.prevLead=void 0),e===this.lead){let e=this.members[this.members.length-1];e&&this.promote(e)}}relegate(e){let t,n=this.members.findIndex(t=>e===t);if(0===n)return!1;for(let e=n;e>=0;e--){let n=this.members[e];if(!1!==n.isPresent){t=n;break}}return!!t&&(this.promote(t),!0)}promote(e,t){let n=this.lead;if(e!==n&&(this.prevLead=n,this.lead=e,e.show(),n)){n.instance&&n.scheduleRender(),e.scheduleRender(),e.resumeFrom=n,t&&(e.resumeFrom.preserveOpacity=!0),n.snapshot&&(e.snapshot=n.snapshot,e.snapshot.latestValues=n.animationValues||n.latestValues),e.root&&e.root.isUpdating&&(e.isLayoutDirty=!0);let{crossfade:r}=e.options;!1===r&&n.hide()}}
1exitAnimationComplete(){this.members.forEach(e=>{let{options:t,resumingFrom:n}=e;t.onExitComplete&&t.onExitComplete(),n&&n.options.onExitComplete&&n.options.onExitComplete()})}scheduleRender(){this.members.forEach(e=>{e.instance&&e.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}let rE=(e,t)=>e.depth-t.depth;class rk{constructor(){this.children=[],this.isDirty=!1}add(e){tV(this.children,e),this.isDirty=!0}remove(e){tB(this.children,e),this.isDirty=!0}forEach(e){this.isDirty&&this.children.sort(rE),this.isDirty=!1,this.children.forEach(e)}}function rS(e){let t=tX(e)?e.get():e;return t&&"object"==typeof t&&t.mix&&t.toValue?t.toValue():t}let rT={type:"projectionFrame",totalNodes:0,resolvedTargetDeltas:0,recalculatedProjection:0},rC="undefined"!=typeof window&&void 0!==window.MotionDebug,rP=["","X","Y","Z"],rA={visibility:"hidden"},rR=0;function r_(e,t,n,r){let{latestValues:i}=t;i[e]&&(n[e]=i[e],t.setStaticValue(e,0),r&&(r[e]=0))}function rI({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:i}){return class{constructor(e={},n=null==t?void 0:t()){this.id=rR++,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,rC&&(rT.totalNodes=rT.resolvedTargetDeltas=rT.recalculatedProjection=0),this.nodes.forEach(rM),this.nodes.forEach(rU),this.nodes.forEach(rz),this.nodes.forEach(rF),rC&&window.MotionDebug.record(rT)},this.resolvedRelativeTargetAt=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=e,this.root=n?n.root||n:this,this.path=n?[...n.path,n]:[],this.parent=n,this.depth=n?n.depth+1:0;for(let e=0;e<this.path.length;e++)this.path[e].shouldResetTransform=!0;this.root===this&&(this.nodes=new rk)}addEventListener(e,t){return this.eventHandlers.has(e)||this.eventHandlers.set(e,new tU),this.eventHandlers.get(e).add(t)}notifyListeners(e,...t){let n=this.eventHandlers.get(e);n&&n.notify(...t)}hasListeners(e){return this.eventHandlers.has(e)}mount(t,n=this.root.hasTreeAnimated){if(this.instance)return;this.isSVG=t instanceof SVGElement&&"svg"!==t.tagName,this.instance=t;let{layoutId:r,layout:i,visualElement:o}=this.options;if(o&&!o.current&&o.mount(t),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),n&&(i||r)&&(this.isLayoutDirty=!0),e){let n,r=()=>this.root.updateBlockedByResize=!1;e(t,()=>{this.root.updateBlockedByResize=!0,n&&n(),n=function(e,t){let n=eW.now(),r=({timestamp:t})=>{let i=t-n;i>=250&&((0,C.WG)(r),e(i-250))};return C.Gt.read(r,!0),()=>(0,C.WG)(r)}(r,250),nQ.hasAnimatedSinceResize&&(nQ.hasAnimatedSinceResize=!1,this.nodes.forEach(rB))})}r&&this.root.registerSharedNode(r,this),!1!==this.options.animate&&o&&(r||i)&&this.addEventListener("didUpdate",({delta:e,hasLayoutChanged:t,hasRelativeTargetChanged:n,layout:r})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}let i=this.options.transition||o.getDefaultTransition()||r$,{onLayoutAnimationStart:l,onLayoutAnimationComplete:s}=o.getProps(),a=!this.targetLayout||!ry(this.targetLayout,r)||n,u=!t&&n;if(this.options.layoutRoot||this.resumeFrom&&this.resumeFrom.instance||u||t&&(a||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0),this.setAnimationOrigin(e,u);let t={...x(i,"layout"),onPlay:l,onComplete:s};(o.shouldReduceMotion||this.options.layoutRoot)&&(t.delay=0,t.type=!1),this.startAnimation(t)}else t||rB(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=r})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);let e=this.getStack();e&&e.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,(0,C.WG)(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.forEac
1h(rH),this.animationId++)}getTransformTemplate(){let{visualElement:e}=this.options;return e&&e.getProps().transformTemplate}willUpdate(e=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&function e(t){if(t.hasCheckedOptimisedAppear=!0,t.root===t)return;let{visualElement:n}=t.options;if(!n)return;let r=n.props[tY];if(window.MotionHasOptimisedAnimation(r,"transform")){let{layout:e,layoutId:n}=t.options;window.MotionCancelOptimisedAnimation(r,"transform",C.Gt,!(e||n))}let{parent:i}=t;i&&!i.hasCheckedOptimisedAppear&&e(i)}(this),this.root.isUpdating||this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let e=0;e<this.path.length;e++){let t=this.path[e];t.shouldResetTransform=!0,t.updateScroll("snapshot"),t.options.layoutRoot&&t.willUpdate(!1)}let{layoutId:t,layout:n}=this.options;if(void 0===t&&!n)return;let r=this.getTransformTemplate();this.prevTransformTemplateValue=r?r(this.latestValues,""):void 0,this.updateSnapshot(),e&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){this.unblockUpdate(),this.clearAllSnapshots(),this.nodes.forEach(rj);return}this.isUpdating||this.nodes.forEach(rN),this.isUpdating=!1,this.nodes.forEach(rV),this.nodes.forEach(rD),this.nodes.forEach(rL),this.clearAllSnapshots();let e=eW.now();C.uv.delta=N(0,1e3/60,e-C.uv.timestamp),C.uv.timestamp=e,C.uv.isProcessing=!0,C.Ci.update.process(C.uv),C.Ci.preRender.process(C.uv),C.Ci.render.process(C.uv),C.uv.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,n4.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(rO),this.sharedNodes.forEach(rW)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,C.Gt.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){C.Gt.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 e=0;e<this.path.length;e++)this.path[e].updateScroll();let e=this.layout;this.layout=this.measure(!1),this.layoutCorrected=nP(),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);let{visualElement:t}=this.options;t&&t.notify("LayoutMeasure",this.layout.layoutBox,e?e.layoutBox:void 0)}updateScroll(e="measure"){let t=!!(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===e&&(t=!1),t){let t=r(this.instance);this.scroll={animationId:this.root.animationId,phase:e,isRoot:t,offset:n(this.instance),wasRoot:this.scroll?this.scroll.isRoot:t}}}resetTransform(){if(!i)return;let e=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,t=this.projectionDelta&&!rm(this.projectionDelta),n=this.getTransformTemplate(),r=n?n(this.latestValues,""):void 0,o=r!==this.prevTransformTemplateValue;e&&(t||nD(this.latestValues)||o)&&(i(this.instance,r),this.shouldResetTransform=!1,this.scheduleRender())}measure(e=!0){var t;let n=this.measurePageBox(),r=this.removeElementScroll(n);return e&&(r=this.removeTransform(r)),rJ((t=r).x),rJ(t.y),{animationId:this.root.animationId,measuredBox:n,layoutBox:r,latestValues:{},source:this.id}}measurePageBox(){var e;let{visualElement:t}=this.options;if(!t)return nP();let n=t.measureViewportBox();if(!((null==(e=this.scroll)?void 0:e.wasRoot)||this.path.some(rQ))){let{scroll:e}=this.root;e&&(nj(n.x,e.offset.x),nj(n.y,e.offset.y))}return n}removeElementScroll(e){var t;let n=nP();if(rs(n,e),null==(t=this.scroll)?void 0:t.wasRoot)return n;for(let t=0;t<this.path.length;t++){let r=this.path[t],{scroll:i,options:o}=r;r!==this.root&&i&&o.layoutScroll&&(i.wasRoot&&rs(n,e),nj(n.x,i.offset.x),nj(n.y,i.offset.y))}return n}applyTransform(e,t=!1){let n=nP();rs(n,e);for(let e=0;e<this.path.length;e++){let r=this.path[e];!t&&r.options.layoutScroll&&r.scroll&&r!==r.root&&nV(n,{x:-r.scroll.offset.x,y:-r.scroll.offset.y}),nD(r.latestValues)&&nV(n,r.latestValues)}return nD(this.latestValues)&&nV(n,this.latestValues),n}removeTransform(e){let t=nP();rs(t,e);for(let e=0;e<this.path.length;e++){let n=this.path[e];if(!n.instance||!nD(n.latestValues))continue;nI(n.latestValues)&&n.updateSnapshot();let r=nP();rs(r,n.measurePageBox()),rp(t,n.latestValues,n.snapshot?n.snapshot.layoutBox:void 0,r)}return nD(this.latestValues)&&rp(t,this.latestValues),t}setTargetDelta(e){this.targetDelta=e,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(e){this.options={...this.options,...e,crossfade:void 0===e.crossfade||e.crossfade}}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!==C.uv.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(e=!1){var t,n,r,i;let o=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=o.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=o.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=o.isSharedProjectionDirty);let l=!!this.resumingFrom||this!==o;if(!(e||l&&this.isSharedProjectionDirty||this.isProjectionDirty||(null==(t=this.parent)?void 0:t.isProjectionDirty)||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;let{layout:s,layoutId:a}=this.options;
1if(this.layout&&(s||a)){if(this.resolvedRelativeTargetAt=C.uv.timestamp,!this.targetDelta&&!this.relativeTarget){let e=this.getClosestProjectingParent();e&&e.layout&&1!==this.animationProgress?(this.relativeParent=e,this.forceRelativeParentToResolveTarget(),this.relativeTarget=nP(),this.relativeTargetOrigin=nP(),nx(this.relativeTargetOrigin,this.layout.layoutBox,e.layout.layoutBox),rs(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}if(this.relativeTarget||this.targetDelta){if((this.target||(this.target=nP(),this.targetWithTransforms=nP()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target)?(this.forceRelativeParentToResolveTarget(),n=this.target,r=this.relativeTarget,i=this.relativeParent.target,nv(n.x,r.x,i.x),nv(n.y,r.y,i.y)):this.targetDelta?(this.resumingFrom?this.target=this.applyTransform(this.layout.layoutBox):rs(this.target,this.layout.layoutBox),nO(this.target,this.targetDelta)):rs(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget){this.attemptToResolveRelativeTarget=!1;let e=this.getClosestProjectingParent();e&&!!e.resumingFrom==!!this.resumingFrom&&!e.options.layoutScroll&&e.target&&1!==this.animationProgress?(this.relativeParent=e,this.forceRelativeParentToResolveTarget(),this.relativeTarget=nP(),this.relativeTargetOrigin=nP(),nx(this.relativeTargetOrigin,this.target,e.target),rs(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}rC&&rT.resolvedTargetDeltas++}}}getClosestProjectingParent(){if(!(!this.parent||nI(this.parent.latestValues)||nL(this.parent.latestValues)))if(this.parent.isProjecting())return this.parent;else return this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}calcProjection(){var e;let t=this.getLead(),n=!!this.resumingFrom||this!==t,r=!0;if((this.isProjectionDirty||(null==(e=this.parent)?void 0:e.isProjectionDirty))&&(r=!1),n&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(r=!1),this.resolvedRelativeTargetAt===C.uv.timestamp&&(r=!1),r)return;let{layout:i,layoutId:o}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(i||o))return;rs(this.layoutCorrected,this.layout.layoutBox);let l=this.treeScale.x,s=this.treeScale.y;!function(e,t,n,r=!1){let i,o,l=n.length;if(l){t.x=t.y=1;for(let s=0;s<l;s++){o=(i=n[s]).projectionDelta;let{visualElement:l}=i.options;(!l||!l.props.style||"contents"!==l.props.style.display)&&(r&&i.options.layoutScroll&&i.scroll&&i!==i.root&&nV(e,{x:-i.scroll.offset.x,y:-i.scroll.offset.y}),o&&(t.x*=o.x.scale,t.y*=o.y.scale,nO(e,o)),r&&nD(i.latestValues)&&nV(e,i.latestValues))}t.x<1.0000000000001&&t.x>.999999999999&&(t.x=1),t.y<1.0000000000001&&t.y>.999999999999&&(t.y=1)}}(this.layoutCorrected,this.treeScale,this.path,n),t.layout&&!t.target&&(1!==this.treeScale.x||1!==this.treeScale.y)&&(t.target=t.layout.layoutBox,t.targetWithTransforms=nP());let{target:a}=t;if(!a){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}this.projectionDelta&&this.prevProjectionDelta?(ra(this.prevProjectionDelta.x,this.projectionDelta.x),ra(this.prevProjectionDelta.y,this.projectionDelta.y)):this.createProjectionDeltas(),ng(this.projectionDelta,this.layoutCorrected,a,this.latestValues),this.treeScale.x===l&&this.treeScale.y===s&&rb(this.projectionDelta.x,this.prevProjectionDelta.x)&&rb(this.projectionDelta.y,this.prevProjectionDelta.y)||(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",a)),rC&&rT.recalculatedProjection++}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(e=!0){var t;if(null==(t=this.options.visualElement)||t.scheduleRender(),e){let e=this.getStack();e&&e.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=nT(),this.projectionDelta=nT(),this.projectionDeltaWithTransform=nT()}setAnimationOrigin(e,t=!1){let n,r=this.snapshot,i=r?r.latestValues:{},o={...this.latestValues},l=nT();this.relativeParent&&this.relativeParent.options.layoutRoot||(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!t;let s=nP(),a=(r?r.source:void 0)!==(this.layout?this.layout.source:void 0),u=this.getStack(),c=!u||u.members.length<=1,d=!!(a&&
1!c&&!0===this.options.crossfade&&!this.path.some(rG));this.animationProgress=0,this.mixTargetDelta=t=>{let r=t/1e3;if(rq(l.x,e.x,r),rq(l.y,e.y,r),this.setTargetDelta(l),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout){var u,h,p,f,m,g;nx(s,this.layout.layoutBox,this.relativeParent.layout.layoutBox),p=this.relativeTarget,f=this.relativeTargetOrigin,m=s,g=r,rY(p.x,f.x,m.x,g),rY(p.y,f.y,m.y,g),n&&(u=this.relativeTarget,h=n,rg(u.x,h.x)&&rg(u.y,h.y))&&(this.isProjectionDirty=!1),n||(n=nP()),rs(n,this.relativeTarget)}a&&(this.animationValues=o,function(e,t,n,r,i,o){i?(e.opacity=ta(0,void 0!==n.opacity?n.opacity:1,rr(r)),e.opacityExit=ta(void 0!==t.opacity?t.opacity:1,0,ri(r))):o&&(e.opacity=ta(void 0!==t.opacity?t.opacity:1,void 0!==n.opacity?n.opacity:1,r));for(let i=0;i<n8;i++){let o=`border${n7[i]}Radius`,l=rn(t,o),s=rn(n,o);(void 0!==l||void 0!==s)&&(l||(l=0),s||(s=0),0===l||0===s||rt(l)===rt(s)?(e[o]=Math.max(ta(re(l),re(s),r),0),(X.test(s)||X.test(l))&&(e[o]+="%")):e[o]=s)}(t.rotate||n.rotate)&&(e.rotate=ta(t.rotate||0,n.rotate||0,r))}(o,i,this.latestValues,r,d,c)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=r},this.mixTargetDelta(1e3*!!this.options.layoutRoot)}startAnimation(e){this.notifyListeners("animationStart"),this.currentAnimation&&this.currentAnimation.stop(),this.resumingFrom&&this.resumingFrom.currentAnimation&&this.resumingFrom.currentAnimation.stop(),this.pendingAnimation&&((0,C.WG)(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=C.Gt.update(()=>{nQ.hasAnimatedSinceResize=!0,this.currentAnimation=function(e,t,n){let r=tX(0)?0:tW(e);return r.start(tj("",r,1e3,n)),r.animation}(0,0,{...e,onUpdate:t=>{this.mixTargetDelta(t),e.onUpdate&&e.onUpdate(t)},onComplete:()=>{e.onComplete&&e.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 e=this.getStack();e&&e.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(1e3),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){let e=this.getLead(),{targetWithTransforms:t,target:n,layout:r,latestValues:i}=e;if(t&&n&&r){if(this!==e&&this.layout&&r&&rZ(this.options.animationType,this.layout.layoutBox,r.layoutBox)){n=this.target||nP();let t=nf(this.layout.layoutBox.x);n.x.min=e.target.x.min,n.x.max=n.x.min+t;let r=nf(this.layout.layoutBox.y);n.y.min=e.target.y.min,n.y.max=n.y.min+r}rs(t,n),nV(t,i),ng(this.projectionDeltaWithTransform,this.layoutCorrected,t,i)}}registerSharedNode(e,t){this.sharedNodes.has(e)||this.sharedNodes.set(e,new rw),this.sharedNodes.get(e).add(t);let n=t.options.initialPromotionConfig;t.promote({transition:n?n.transition:void 0,preserveFollowOpacity:n&&n.shouldPreserveFollowOpacity?n.shouldPreserveFollowOpacity(t):void 0})}isLead(){let e=this.getStack();return!e||e.lead===this}getLead(){var e;let{layoutId:t}=this.options;return t&&(null==(e=this.getStack())?void 0:e.lead)||this}getPrevLead(){var e;let{layoutId:t}=this.options;return t?null==(e=this.getStack())?void 0:e.prevLead:void 0}getStack(){let{layoutId:e}=this.options;if(e)return this.root.sharedNodes.get(e)}promote({needsReset:e,transition:t,preserveFollowOpacity:n}={}){let r=this.getStack();r&&r.promote(this,n),e&&(this.projectionDelta=void 0,this.needsReset=!0),t&&this.setOptions({transition:t})}relegate(){let e=this.getStack();return!!e&&e.relegate(this)}resetSkewAndRotation(){let{visualElement:e}=this.options;if(!e)return;let t=!1,{latestValues:n}=e;if((n.z||n.rotate||n.rotateX||n.rotateY||n.rotateZ||n.skewX||n.skewY)&&(t=!0),!t)return;let r={};n.z&&r_("z",e,r,this.animationValues);for(let t=0;t<rP.length;t++)r_(`rotate${rP[t]}`,e,r,this.animationValues),r_(`skew${rP[t]}`,e,r,this.animationValues);for(let t in e.render(),r)e.setStaticValue(t,r[t]),this.animationValues&&(this.animationValues[t]=r[t]);e.scheduleRender()}getProjectionStyles(e){var t,n;if(!this.instance||this.isSVG)return;if(!this.isVisible)return rA;let r={visibility:""},i=this.getTransformTemplate();if(this.needsReset)return this.needsReset=!1,r.opacity="",r.pointerEvents=rS(null==e?void 0:e.pointerEvents)||"",r.transform=i?i(this.latestValues,""):"none",r;let o=this.getLead();if(!this.projectionDelta||!this.layout||!o.target){let t={};return this.options.layoutId&&(t.opacity=void 0!==this.latestValues.opacity?this.latestValues.opacity:1,t.pointerEvents=rS(null==e?void 0:e.pointerEvents)||""),this.hasProjected&&!nD(this.latestValues)&&(t.transform=i?i({},""):"none",this.hasProjected=!1),t}let l=o.animationValues||o.latestValues;this.applyTransformsToTarget(),r.transform=function(e,t,n){let r="",i=e.x.translate/t.x,o=e.
1y.translate/t.y,l=(null==n?void 0:n.z)||0;if((i||o||l)&&(r=`translate3d(${i}px, ${o}px, ${l}px) `),(1!==t.x||1!==t.y)&&(r+=`scale(${1/t.x}, ${1/t.y}) `),n){let{transformPerspective:e,rotate:t,rotateX:i,rotateY:o,skewX:l,skewY:s}=n;e&&(r=`perspective(${e}px) ${r}`),t&&(r+=`rotate(${t}deg) `),i&&(r+=`rotateX(${i}deg) `),o&&(r+=`rotateY(${o}deg) `),l&&(r+=`skewX(${l}deg) `),s&&(r+=`skewY(${s}deg) `)}let s=e.x.scale*t.x,a=e.y.scale*t.y;return(1!==s||1!==a)&&(r+=`scale(${s}, ${a})`),r||"none"}(this.projectionDeltaWithTransform,this.treeScale,l),i&&(r.transform=i(l,r.transform));let{x:s,y:a}=this.projectionDelta;for(let e in r.transformOrigin=`${100*s.origin}% ${100*a.origin}% 0`,o.animationValues?r.opacity=o===this?null!=(n=null!=(t=l.opacity)?t:this.latestValues.opacity)?n:1:this.preserveOpacity?this.latestValues.opacity:l.opacityExit:r.opacity=o===this?void 0!==l.opacity?l.opacity:"":void 0!==l.opacityExit?l.opacityExit:0,n2){if(void 0===l[e])continue;let{correct:t,applyTo:n}=n2[e],i="none"===r.transform?l[e]:t(l[e],o);if(n){let e=n.length;for(let t=0;t<e;t++)r[n[t]]=i}else r[e]=i}return this.options.layoutId&&(r.pointerEvents=o===this?rS(null==e?void 0:e.pointerEvents)||"":"none"),r}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(e=>{var t;return null==(t=e.currentAnimation)?void 0:t.stop()}),this.root.nodes.forEach(rj),this.root.sharedNodes.clear()}}}function rD(e){e.updateLayout()}function rL(e){var t;let n=(null==(t=e.resumeFrom)?void 0:t.snapshot)||e.snapshot;if(e.isLead()&&e.layout&&n&&e.hasListeners("didUpdate")){let{layoutBox:t,measuredBox:r}=e.layout,{animationType:i}=e.options,o=n.source!==e.layout.source;"size"===i?nA(e=>{let r=o?n.measuredBox[e]:n.layoutBox[e],i=nf(r);r.min=t[e].min,r.max=r.min+i}):rZ(i,n.layoutBox,t)&&nA(r=>{let i=o?n.measuredBox[r]:n.layoutBox[r],l=nf(t[r]);i.max=i.min+l,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[r].max=e.relativeTarget[r].min+l)});let l=nT();ng(l,t,n.layoutBox);let s=nT();o?ng(s,e.applyTransform(r,!0),n.measuredBox):ng(s,t,n.layoutBox);let a=!rm(l),u=!1;if(!e.resumeFrom){let r=e.getClosestProjectingParent();if(r&&!r.resumeFrom){let{snapshot:i,layout:o}=r;if(i&&o){let l=nP();nx(l,n.layoutBox,i.layoutBox);let s=nP();nx(s,t,o.layoutBox),ry(l,s)||(u=!0),r.options.layoutRoot&&(e.relativeTarget=s,e.relativeTargetOrigin=l,e.relativeParent=r)}}}e.notifyListeners("didUpdate",{layout:t,snapshot:n,delta:s,layoutDelta:l,hasLayoutChanged:a,hasRelativeTargetChanged:u})}else if(e.isLead()){let{onExitComplete:t}=e.options;t&&t()}e.options.transition=void 0}function rM(e){rC&&rT.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 rF(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function rO(e){e.clearSnapshot()}function rj(e){e.clearMeasurements()}function rN(e){e.isLayoutDirty=!1}function rV(e){let{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function rB(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function rU(e){e.resolveTargetDelta()}function rz(e){e.calcProjection()}function rH(e){e.resetSkewAndRotation()}function rW(e){e.removeLeadSnapshot()}function rq(e,t,n){e.translate=ta(t.translate,0,n),e.scale=ta(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function rY(e,t,n,r){e.min=ta(t.min,n.min,r),e.max=ta(t.max,n.max,r)}function rG(e){return e.animationValues&&void 0!==e.animationValues.opacityExit}let r$={duration:.45,ease:[.4,0,.1,1]},rX=e=>"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),rK=rX("applewebkit/")&&!rX("chrome/")?Math.round:A.l;function rJ(e){e.min=rK(e.min),e.max=rK(e.max)}function rZ(e,t,n){return"position"===e||"preserve-aspect"===e&&!(.2>=Math.abs(rx(t)-rx(n)))}function rQ(e){var t;return e!==e.root&&(null==(t=e.scroll)?void 0:t.wasRoot)}let r0=rI({attachResizeListener:(e,t)=>ne(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),r1={current:void 0},r2=rI({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!r1.current){let e=new r0({});e.mount(window),e.setOptions({layoutScroll:!0}),r1.current=e}return r1.current},resetTransform:(e,t)=>
1{e.style.transform=void 0!==t?t:"none"},checkIsScrollRoot:e=>"fixed"===window.getComputedStyle(e).position});function r4(e,t){let n=t?"onHoverStart":"onHoverEnd";return nt(e.current,t?"pointerenter":"pointerleave",(r,i)=>{if("touch"===r.pointerType||nh())return;let o=e.getProps();e.animationState&&o.whileHover&&e.animationState.setActive("whileHover",t);let l=o[n];l&&C.Gt.postRender(()=>l(r,i))},{passive:!e.getProps()[n]})}class r3 extends t3{mount(){this.unmount=tl(r4(this.node,!0),r4(this.node,!1))}unmount(){}}class r5 extends t3{constructor(){super(...arguments),this.isActive=!1}onFocus(){let e=!1;try{e=this.node.current.matches(":focus-visible")}catch(t){e=!0}e&&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=tl(ne(this.node.current,"focus",()=>this.onFocus()),ne(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}let r6=(e,t)=>!!t&&(e===t||r6(e,t.parentElement));function r9(e,t){if(!t)return;let n=new PointerEvent("pointer"+e);t(n,t8(n))}class r7 extends t3{constructor(){super(...arguments),this.removeStartListeners=A.l,this.removeEndListeners=A.l,this.removeAccessibleListeners=A.l,this.startPointerPress=(e,t)=>{if(this.isPressing)return;this.removeEndListeners();let n=this.node.getProps(),r=nt(window,"pointerup",(e,t)=>{if(!this.checkPressEnd())return;let{onTap:n,onTapCancel:r,globalTapTarget:i}=this.node.getProps(),o=i||r6(this.node.current,e.target)?n:r;o&&C.Gt.update(()=>o(e,t))},{passive:!(n.onTap||n.onPointerUp)}),i=nt(window,"pointercancel",(e,t)=>this.cancelPress(e,t),{passive:!(n.onTapCancel||n.onPointerCancel)});this.removeEndListeners=tl(r,i),this.startPress(e,t)},this.startAccessiblePress=()=>{let e=e=>{if("Enter"!==e.key||this.isPressing)return;let t=e=>{"Enter"===e.key&&this.checkPressEnd()&&r9("up",(e,t)=>{let{onTap:n}=this.node.getProps();n&&C.Gt.postRender(()=>n(e,t))})};this.removeEndListeners(),this.removeEndListeners=ne(this.node.current,"keyup",t),r9("down",(e,t)=>{this.startPress(e,t)})},t=ne(this.node.current,"keydown",e),n=()=>{this.isPressing&&r9("cancel",(e,t)=>this.cancelPress(e,t))},r=ne(this.node.current,"blur",n);this.removeAccessibleListeners=tl(t,r)}}startPress(e,t){this.isPressing=!0;let{onTapStart:n,whileTap:r}=this.node.getProps();r&&this.node.animationState&&this.node.animationState.setActive("whileTap",!0),n&&C.Gt.postRender(()=>n(e,t))}checkPressEnd(){return this.removeEndListeners(),this.isPressing=!1,this.node.getProps().whileTap&&this.node.animationState&&this.node.animationState.setActive("whileTap",!1),!nh()}cancelPress(e,t){if(!this.checkPressEnd())return;let{onTapCancel:n}=this.node.getProps();n&&C.Gt.postRender(()=>n(e,t))}mount(){let e=this.node.getProps(),t=nt(e.globalTapTarget?window:this.node.current,"pointerdown",this.startPointerPress,{passive:!(e.onTapStart||e.onPointerStart)}),n=ne(this.node.current,"focus",this.startAccessiblePress);this.removeStartListeners=tl(t,n)}unmount(){this.removeStartListeners(),this.removeEndListeners(),this.removeAccessibleListeners()}}let r8=new WeakMap,ie=new WeakMap,it=e=>{let t=r8.get(e.target);t&&t(e)},ir=e=>{e.forEach(it)},ii={some:0,all:1};class io extends t3{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();let{viewport:e={}}=this.node.getProps(),{root:t,margin:n,amount:r="some",once:i}=e,o={root:t?t.current:void 0,rootMargin:n,threshold:"number"==typeof r?r:ii[r]},l=e=>{let{isIntersecting:t}=e;if(this.isInView===t||(this.isInView=t,i&&!t&&this.hasEnteredView))return;t&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",t);let{onViewportEnter:n,onViewportLeave:r}=this.node.getProps(),o=t?n:r;o&&o(e)};var s=this.node.current;let a=function({root:e,...t}){let n=e||document;ie.has(n)||ie.set(n,{});let r=ie.get(n),i=JSON.stringify(t);return r[i]||(r[i]=new IntersectionObserver(ir,{root:e,...t})),r[i]}(o);return r8.set(s,l),a.observe(s),()=>{r8.delete(s),a.unobserve(s)}}mount(){this.startObserver()}update(){if("undefined"==typeof IntersectionObserver)return;let{props:e,prevProps:t}=this.node;["amount","margin","root"].some(function({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}(e,t))&&this.startObserver()}unmount(){}}let il=(0,nX.createContext)({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"}),is=(0,nX.createContext)({});var ia=n(17933);let iu=(0,nX.createContext)({strict:!1}),ic=!1;function id(){window.MotionHandoffIsComplete=!0}function ih(e){return i(e.animate)||h.some(t=>s(e[t]))}function ip(e){return!!(ih(e)||e.variants)}function im(e){return Array.isArray(e)?e.join(" "):e}let ig={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"]},iv={};for(let e in ig)iv[e]={isEnabled:t=>ig[e].some(e=>!!t[e])};var iy=n(6357);let ix=Symbol.for("motionComponentSymbol"),ib=["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 iw(e){if("string"!=typeof e||e.includes("-"));else if(ib.indexOf(e)>-1||/[A-Z]/u.test(e))return!0;return!1}function iE(e,{style:t,vars:n},r,i){for(let o in Object.assign(e.style,t,i&&i.getProjectionStyles(r)),n)e.style.setProperty(o,n[o])}let ik=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 iS(e,t,n,r){for(let n in iE(e,t,void 0,r),t.attrs)e.setAttribute(ik.has(n)?n:tq(n),t.attrs[n])}function iT(e,{layout:t,layoutId:n}){return f.has(e)||e.startsWith("origin")||(t||void 0!==n)&&(!!n2[e]||"opacity"===e)}function iC(e,t,n){var r;let{style:i}=e,o={};for(let l in i)(tX(i[l])||t.style&&tX(t.style[l])||iT(l,e)||(null==(r=null==n?void 0:n.getValue(l))?void 0:r.liveStyle)!==void 0)&&(o[l]=i[l]);return n&&i&&"string"==typeof i.willChange&&(n.applyWillChange=!1),o}function iP(e,t,n){let r=iC(e,t,n);for(let n in e)(tX(e[n])||tX(t[n]))&&(r[-1!==p.indexOf(n)?"attr"+n.charAt(0).toUpperCase()+n.substring(1):n]=e[n]);return r}let iA=e=>(t,n)=>{let r=(0,nX.useContext)(is),o=(0,nX.useContext)(nK),l=()=>(function({applyWillChange:e=!1,scrapeMotionValuesFromProps:t,createRenderState:n,onMount:r},o,l,s,a){let u={latestValues:function(e,t,n,r,o){var l;let s={},a=[],u=r&&(null==(l=e.style)?void 0:l.willChange)===void 0,c=o(e,{});for(let e in c)s[e]=rS(c[e]);let{initial:d,animate:h}=e,p=ih(e),f=ip(e);
1t&&f&&!p&&!1!==e.inherit&&(void 0===d&&(d=t.initial),void 0===h&&(h=t.animate));let m=!!n&&!1===n.initial,g=(m=m||!1===d)?h:d;return g&&"boolean"!=typeof g&&!i(g)&&iR(e,g,(e,t)=>{for(let t in e){let n=e[t];if(Array.isArray(n)){let e=m?n.length-1:0;n=n[e]}null!==n&&(s[t]=n)}for(let e in t)s[e]=t[e]}),u&&(h&&!1!==d&&!i(h)&&iR(e,h,e=>{for(let t in e){let e=tG(t);e&&tV(a,e)}}),a.length&&(s.willChange=a.join(","))),s}(o,l,s,!a&&e,t),renderState:n()};return r&&(u.mount=e=>r(o,e,u)),u})(e,t,r,o,n);return n?l():function(e){let t=(0,nX.useRef)(null);return null===t.current&&(t.current=e()),t.current}(l)};function iR(e,t,n){let r=Array.isArray(t)?t:[t];for(let t=0;t<r.length;t++){let i=u(e,r[t]);if(i){let{transitionEnd:e,transition:t,...r}=i;n(r,e)}}}let i_=()=>({style:{},transform:{},transformOrigin:{},vars:{}}),iI=()=>({...i_(),attrs:{}}),iD=(e,t)=>t&&"number"==typeof e?t.transform(e):e,iL={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},iM=p.length;function iF(e,t,n){let{style:r,vars:i,transformOrigin:o}=e,l=!1,s=!1;for(let e in t){let n=t[e];if(f.has(e)){l=!0;continue}if(L(e)){i[e]=n;continue}{let t=iD(n,eO[e]);e.startsWith("origin")?(s=!0,o[e]=t):r[e]=t}}if(!t.transform&&(l||n?r.transform=function(e,t,n){let r="",i=!0;for(let o=0;o<iM;o++){let l=p[o],s=e[l];if(void 0===s)continue;let a=!0;if(!(a="number"==typeof s?s===+!!l.startsWith("scale"):0===parseFloat(s))||n){let e=iD(s,eO[l]);if(!a){i=!1;let t=iL[l]||l;r+=`${t}(${e}) `}n&&(t[l]=e)}}return r=r.trim(),n?r=n(t,i?"":r):i&&(r="none"),r}(t,e.transform,n):r.transform&&(r.transform="none")),s){let{originX:e="50%",originY:t="50%",originZ:n=0}=o;r.transformOrigin=`${e} ${t} ${n}`}}function iO(e,t,n){return"string"==typeof e?e:K.transform(t+n*e)}let ij={offset:"stroke-dashoffset",array:"stroke-dasharray"},iN={offset:"strokeDashoffset",array:"strokeDasharray"};function iV(e,{attrX:t,attrY:n,attrScale:r,originX:i,originY:o,pathLength:l,pathSpacing:s=1,pathOffset:a=0,...u},c,d){if(iF(e,u,d),c){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};let{attrs:h,style:p,dimensions:f}=e;h.transform&&(f&&(p.transform=h.transform),delete h.transform),f&&(void 0!==i||void 0!==o||p.transform)&&(p.transformOrigin=function(e,t,n){let r=iO(t,e.x,e.width),i=iO(n,e.y,e.height);return`${r} ${i}`}(f,void 0!==i?i:.5,void 0!==o?o:.5)),void 0!==t&&(h.x=t),void 0!==n&&(h.y=n),void 0!==r&&(h.scale=r),void 0!==l&&function(e,t,n=1,r=0,i=!0){e.pathLength=1;let o=i?ij:iN;e[o.offset]=K.transform(-r);let l=K.transform(t),s=K.transform(n);e[o.array]=`${l} ${s}`}(h,l,s,a,!1)}let iB=e=>"string"==typeof e&&"svg"===e.toLowerCase(),iU={useVisualState:iA({scrapeMotionValuesFromProps:iP,createRenderState:iI,onMount:(e,t,{renderState:n,latestValues:r})=>{C.Gt.read(()=>{try{n.dimensions="function"==typeof t.getBBox?t.getBBox():t.getBoundingClientRect()}catch(e){n.dimensions={x:0,y:0,width:0,height:0}}}),C.Gt.render(()=>{iV(n,r,iB(t.tagName),e.transformTemplate),iS(t,n)})}})},iz={useVisualState:iA({applyWillChange:!0,scrapeMotionValuesFromProps:iC,createRenderState:i_})};function iH(e,t,n){for(let r in t)tX(t[r])||iT(r,n)||(e[r]=t[r])}let iW=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 iq(e){return e.startsWith("while")||e.startsWith("drag")&&"draggable"!==e||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||iW.has(e)}let iY=e=>!iq(e);try{!function(e){e&&(iY=t=>t.startsWith("on")?!iq(t):e(t))}(require("@emotion/is-prop-valid").default)}catch(e){}let iG={current:null},i$={current:!1},iX=new WeakMap,iK=[...ea,eE,e_],iJ=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"],iZ=h.length;class iQ{scrapeMotionValuesFromProps(e,t,n){return{}}constructor({parent:e,props:t,presenceContext:n,reducedMotionConfig:r,blockInitialAnimation:i,visualState:o},l={}){this.applyWillChange=!1,this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=em,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,C.Gt.render(this.render,!1,!0))};let{latestValues:s,renderState:a}=o;this.latestValues=s,this.baseTarget={...s},this.initialValues=t.initial?{...s}:{},this.renderState=a,this.parent=e,this.props=t,this.presenceContext=n,this.depth=e?e.depth+1:0,this.reducedMotionConfig=r,this.options=l,this.blockInitialAnimation=!!i,this.isControllingVariants=ih(t),this.isVariantNode=ip(t),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(e&&e.current);let{willChange:u,...c}=this.scrapeMotionValuesFromProps(t,{},this);for(let e in c){let t=c[e];void 0!==s[e]&&tX(t)&&t.set(s[e],!1)}}mount(e){this.current=e,iX.set(e,this),this.projection&&!this.projection.instance&&this.projection.mount(e),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEac
1h((e,t)=>this.bindToMotionValue(t,e)),i$.current||function(){if(i$.current=!0,iy.B)if(window.matchMedia){let e=window.matchMedia("(prefers-reduced-motion)"),t=()=>iG.current=e.matches;e.addListener(t),t()}else iG.current=!1}(),this.shouldReduceMotion="never"!==this.reducedMotionConfig&&("always"===this.reducedMotionConfig||iG.current),this.parent&&this.parent.children.add(this),this.update(this.props,this.presenceContext)}unmount(){for(let e in iX.delete(this.current),this.projection&&this.projection.unmount(),(0,C.WG)(this.notifyUpdate),(0,C.WG)(this.render),this.valueSubscriptions.forEach(e=>e()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent&&this.parent.children.delete(this),this.events)this.events[e].clear();for(let e in this.features){let t=this.features[e];t&&(t.unmount(),t.isMounted=!1)}this.current=null}bindToMotionValue(e,t){let n;this.valueSubscriptions.has(e)&&this.valueSubscriptions.get(e)();let r=f.has(e),i=t.on("change",t=>{this.latestValues[e]=t,this.props.onUpdate&&C.Gt.preRender(this.notifyUpdate),r&&this.projection&&(this.projection.isTransformDirty=!0)}),o=t.on("renderRequest",this.scheduleRender);window.MotionCheckAppearSync&&(n=window.MotionCheckAppearSync(this,e,t)),this.valueSubscriptions.set(e,()=>{i(),o(),n&&n(),t.owner&&t.stop()})}sortNodePosition(e){return this.current&&this.sortInstanceNodePosition&&this.type===e.type?this.sortInstanceNodePosition(this.current,e.current):0}updateFeatures(){let e="animation";for(e in iv){let t=iv[e];
1if(!t)continue;let{isEnabled:n,Feature:r}=t;if(!this.features[e]&&r&&n(this.props)&&(this.features[e]=new r(this)),this.features[e]){let t=this.features[e];t.isMounted?t.update():(t.mount(),t.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):nP()}getStaticValue(e){return this.latestValues[e]}setStaticValue(e,t){this.latestValues[e]=t}update(e,t){(e.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=e,this.prevPresenceContext=this.presenceContext,this.presenceContext=t;for(let t=0;t<iJ.length;t++){let n=iJ[t];this.propEventSubscriptions[n]&&(this.propEventSubscriptions[n](),delete this.propEventSubscriptions[n]);let r=e["on"+n];r&&(this.propEventSubscriptions[n]=this.on(n,r))}this.prevMotionValues=function(e,t,n){for(let r in t){let i=t[r],o=n[r];if(tX(i))e.addValue(r,i);else if(tX(o))e.addValue(r,tW(i,{owner:e}));else if(o!==i)if(e.hasValue(r)){let t=e.getValue(r);!0===t.liveStyle?t.jump(i):t.hasAnimated||t.set(i)}else{let t=e.getStaticValue(r);e.addValue(r,tW(void 0!==t?t:i,{owner:e}))}}for(let r in n)void 0===t[r]&&e.removeValue(r);return t}(this,this.scrapeMotionValuesFromProps(e,this.prevProps,this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(e){return this.props.variants?this.props.variants[e]: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(e=!1){if(e)return this.parent?this.parent.getVariantContext():void 0;if(!this.isControllingVariants){let e=this.parent&&this.parent.getVariantContext()||{};return void 0!==this.props.initial&&(e.initial=this.props.initial),e}let t={};for(let e=0;e<iZ;e++){let n=h[e],r=this.props[n];(s(r)||!1===r)&&(t[n]=r)}return t}addVariantChild(e){let t=this.getClosestVariantNode();if(t)return t.variantChildren&&t.variantChildren.add(e),()=>t.variantChildren.delete(e)}addValue(e,t){let n=this.values.get(e);t!==n&&(n&&this.removeValue(e),this.bindToMotionValue(e,t),this.values.set(e,t),this.latestValues[e]=t.get())}removeValue(e){this.values.delete(e);let t=this.valueSubscriptions.get(e);t&&(t(),this.valueSubscriptions.delete(e)),delete this.latestValues[e],this.removeValueFromRenderState(e,this.renderState)}hasValue(e){return this.values.has(e)}getValue(e,t){if(this.props.values&&this.props.values[e])return this.props.values[e];let n=this.values.get(e);return void 0===n&&void 0!==t&&(n=tW(null===t?void 0:t,{owner:this}),this.addValue(e,n)),n}readValue(e,t){var n;let r=void 0===this.latestValues[e]&&this.current?null!=(n=this.getBaseTargetFromProps(this.props,e))?n:this.readValueFromInstance(this.current,e,this.options):this.latestValues[e];if(null!=r){if("string"==typeof r&&(I(r)||P(r)))r=parseFloat(r);else{let n;n=r,!iK.find(es(n))&&e_.test(t)&&(r=eV(e,t))}this.setBaseTarget(e,tX(r)?r.get():r)}return tX(r)?r.get():r}setBaseTarget(e,t){this.baseTarget[e]=t}getBaseTarget(e){var t;let n,{initial:r}=this.props;if("string"==typeof r||"object"==typeof r){let i=u(this.props,r,null==(t=this.presenceContext)?void 0:t.custom);i&&(n=i[e])}if(r&&void 0!==n)return n;let i=this.getBaseTargetFromProps(this.props,e);return void 0===i||tX(i)?void 0!==this.initialValues[e]&&void 0===n?void 0:this.baseTarget[e]:i}on(e,t){return this.events[e]||(this.events[e]=new tU),this.events[e].add(t)}notify(e,...t){this.events[e]&&this.events[e].notify(...t)}}class i0 extends iQ{constructor(){super(...arguments),this.KeyframeResolver=eU}sortInstanceNodePosition(e,t){return 2&e.compareDocumentPosition(t)?1:-1}getBaseTargetFromProps(e,t){return e.style?e.style[t]:void 0}removeValueFromRenderState(e,{vars:t,style:n}){delete t[e],delete n[e]}}class i1 extends i0{constructor(){super(...arguments),this.type="html",this.applyWillChange=!0,this.renderInstance=iE}readValueFromInstance(e,t){if(f.has(t)){let e=eN(t);return e&&e.default||0}{let n=window.getComputedStyle(e),r=(L(t)?n.getPropertyValue(t):n[t])||0;return"string"==typeof r?r.trim():r}}measureInstanceViewportBox(e,{transformPagePoint:t}){return nB(e,t)}build(e,t,n){iF(e,t,n.transformTemplate)}scrapeMotionValuesFromProps(e,t,n){return iC(e,t,n)}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);let{children:e}=this.props;tX(e)&&(this.childSubscription=e.on("change",e=>{this.current&&(this.current.textContent=`${e}`)}))}}class i2 extends i0{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=nP}getBaseTargetFromProps(e,t){return e[t]}readValueFromInstance(e,t){if(f.has(t)){let e=eN(t);return e&&e.default||0}return t=ik.has(t)?t:tq(t),e.getAttribute(t)}scrapeMotionValuesFromProps(e,t,n){return iP(e,t,n)}
1build(e,t,n){iV(e,t,this.isSVGTag,n.transformTemplate)}renderInstance(e,t,n,r){iS(e,t,n,r)}mount(e){this.isSVGTag=iB(e.tagName),super.mount(e)}}let i4=function(e){if("undefined"==typeof Proxy)return e;let t=new Map;return new Proxy((...t)=>e(...t),{get:(n,r)=>"create"===r?e:(t.has(r)||t.set(r,e(r)),t.get(r))})}((b={animation:{Feature:t5},exit:{Feature:t9},inView:{Feature:io},tap:{Feature:r7},focus:{Feature:r5},hover:{Feature:r3},pan:{Feature:nG},drag:{Feature:nq,ProjectionNode:r2,MeasureLayout:n6},layout:{ProjectionNode:r2,MeasureLayout:n6}},w=(e,t)=>iw(e)?new i2(t):new i1(t,{allowProjection:e!==nX.Fragment}),function(e,{forwardMotionProps:t}={forwardMotionProps:!1}){return function(e){let{preloadedFeatures:t,createVisualElement:n,useRender:r,useVisualState:i,Component:o}=e;t&&function(e){for(let t in e)iv[t]={...iv[t],...e[t]}}(t);let l=(0,nX.forwardRef)(function(e,t){var l,a,u;let c,d={...(0,nX.useContext)(il),...e,layoutId:function(e){let{layoutId:t}=e,n=(0,nX.useContext)(nJ.L).id;return n&&void 0!==t?n+"-"+t:t}(e)},{isStatic:h}=d,p=function(e){let{initial:t,animate:n}=function(e,t){if(ih(e)){let{initial:t,animate:n}=e;return{initial:!1===t||s(t)?t:void 0,animate:s(n)?n:void 0}}return!1!==e.inherit?t:{}}(e,(0,nX.useContext)(is));return(0,nX.useMemo)(()=>({initial:t,animate:n}),[im(t),im(n)])}(e),f=i(e,h);if(!h&&iy.B){a=0,u=0,(0,nX.useContext)(iu).strict;let e=function(e){let{drag:t,layout:n}=iv;if(!t&&!n)return{};let r={...t,...n};return{MeasureLayout:(null==t?void 0:t.isEnabled(e))||(null==n?void 0:n.isEnabled(e))?r.MeasureLayout:void 0,ProjectionNode:r.ProjectionNode}}(d);c=e.MeasureLayout,p.visualElement=function(e,t,n,r,i){var o;let{visualElement:l}=(0,nX.useContext)(is),s=(0,nX.useContext)(iu),a=(0,nX.useContext)(nK),u=(0,nX.useContext)(il).reducedMotion,c=(0,nX.useRef)(void 0);r=r||s.renderer,!c.current&&r&&(c.current=r(e,{visualState:t,parent:l,props:n,presenceContext:a,blockInitialAnimation:!!a&&!1===a.initial,reducedMotionConfig:u}));let d=c.current,h=(0,nX.useContext)(nZ);d&&!d.projection&&i&&("html"===d.type||"svg"===d.type)&&function(e,t,n,r){let{layoutId:i,layout:o,drag:l,dragConstraints:s,layoutScroll:a,layoutRoot:u}=t;e.projection=new n(e.latestValues,t["data-framer-portal-id"]?void 0:function e(t){if(t)return!1!==t.options.allowProjection?t.projection:e(t.parent)}(e.parent)),e.projection.setOptions({layoutId:i,layout:o,alwaysMeasureLayout:!!l||s&&np(s),visualElement:e,animationType:"string"==typeof o?o:"both",initialPromotionConfig:r,layoutScroll:a,layoutRoot:u})}(c.current,n,i,h),(0,nX.useInsertionEffect)(()=>{d&&d.update(n,a)});let p=n[tY],f=(0,nX.useRef)(!!p&&!window.MotionHandoffIsComplete&&(null==(o=window.MotionHasOptimisedAnimation)?void 0:o.call(window,p)));return(0,ia.E)(()=>{d&&(d.updateFeatures(),n4.render(d.render),f.current&&d.animationState&&d.animationState.animateChanges())}),(0,nX.useEffect)(()=>{d&&(!f.current&&d.animationState&&d.animationState.animateChanges(),f.current=!1,ic||(ic=!0,queueMicrotask(id)))}),d}(o,f,d,n,e.ProjectionNode)}return(0,n$.jsxs)(is.Provider,{value:p,children:[c&&p.visualElement?(0,n$.jsx)(c,{visualElement:p.visualElement,...d}):null,r(o,e,(l=p.visualElement,(0,nX.useCallback)(e=>{e&&f.mount&&f.mount(e),l&&(e?l.mount(e):l.unmount()),t&&("function"==typeof t?t(e):np(t)&&(t.current=e))},[l])),f,h,p.visualElement)]})});return l[ix]=o,l}({...iw(e)?iU:iz,preloadedFeatures:b,useRender:function(e=!1){return(t,n,r,{latestValues:i},o)=>{let l=(iw(t)?function(e,t,n,r){let i=(0,nX.useMemo)(()=>{let n=iI();return iV(n,t,iB(r),e.transformTemplate),{...n.attrs,style:{...n.style}}},[t]);if(e.style){let t={};iH(t,e.style,e),i.style={...t,...i.style}}return i}:function(e,t){let n={},r=function(e,t){let n=e.style||{},r={};return iH(r,n,e),Object.assign(r,function({transformTemplate:e},t){return(0,nX.useMemo)(()=>{let n=i_();return iF(n,t,e),Object.assign({},n.vars,n.style)},[t])}(e,t)),r}(e,t);return e.drag&&!1!==e.dragListener&&(n.draggable=!1,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout="none",r.touchAction=!0===e.drag?"none":`pan-${"x"===e.drag?"y":"x"}
1`),void 0===e.tabIndex&&(e.onTap||e.onTapStart||e.whileTap)&&(n.tabIndex=0),n.style=r,n})(n,i,o,t),s=function(e,t,n){let r={};for(let i in e)("values"!==i||"object"!=typeof e.values)&&(iY(i)||!0===n&&iq(i)||!t&&!iq(i)||e.draggable&&i.startsWith("onDrag"))&&(r[i]=e[i]);return r}(n,"string"==typeof t,e),a=t!==nX.Fragment?{...s,...l,ref:r}:{},{children:u}=n,c=(0,nX.useMemo)(()=>tX(u)?u.get():u,[u]);return(0,nX.createElement)(t,{...a,children:c})}}(t),createVisualElement:w,Component:e})}))},28634:(e,t,n)=>{"use strict";n.d(t,{Z:()=>i});var r=n(32144);function i(e){let t=r.useRef({value:e,previous:e});return r.useMemo(()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous),[e])}},29178:(e,t,n)=>{"use strict";n.d(t,{useIsMutating:()=>s,useMutationState:()=>u});var r=n(32144),i=n(72589),o=n(5456),l=n(59011);function s(e,t){let n=(0,l.useQueryClient)(t);return u({filters:{...e,status:"pending"}},n).length}function a(e,t){return e.findAll(t.filters).map(e=>t.select?t.select(e):e.state)}function u(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0,n=(0,l.useQueryClient)(t).getMutationCache(),s=r.useRef(e),u=r.useRef(null);return u.current||(u.current=a(n,e)),r.useEffect(()=>{s.current=e}),r.useSyncExternalStore(r.useCallback(e=>n.subscribe(()=>{let t=(0,i.BH)(u.current,a(n,s.current));u.current!==t&&(u.current=t,o.j.schedule(e))}),[n]),()=>u.current,()=>u.current)}},29954:(e,t,n)=>{"use strict";n.d(t,{useIsFetching:()=>l});var r=n(32144),i=n(5456),o=n(59011);function l(e,t){let n=(0,o.useQueryClient)(t),l=n.getQueryCache();return r.useSyncExternalStore(r.useCallback(e=>l.subscribe(i.j.batchCalls(e)),[l]),()=>n.isFetching(e),()=>n.isFetching(e))}},30252:(e,t,n)=>{"use strict";n.r(t),n.d(t,{default:()=>r});let r=(0,n(37341).A)("Moon",[["path",{d:"M12 3a6 6 0 0 0 9 9 9 9 0 1 1-9-9Z",key:"a7tn18"}]])},30667:e=>{e.exports=function(e,t){let n;if("function"!=typeof e)throw TypeError(`Expected the first argument to be a \`function\`, got \`${typeof e}\`.`);let r=0;return function(...i){clearTimeout(n);let o=Date.now(),l=t-(o-r);l<=0?(r=o,e.apply(this,i)):n=setTimeout(()=>{r=Date.now(),e.apply(this,i)},l)}}},38885:e=>{"use strict";var t=Object.prototype.hasOwnProperty,n=Object.prototype.toString,r=Object.defineProperty,i=Object.getOwnPropertyDescriptor,o=function(e){return"function"==typeof Array.isArray?Array.isArray(e):"[object Array]"===n.call(e)},l=function(e){if(!e||"[object Object]"!==n.call(e))return!1;var r,i=t.call(e,"constructor"),o=e.constructor&&e.constructor.prototype&&t.call(e.constructor.prototype,"isPrototypeOf");if(e.constructor&&!i&&!o)return!1;for(r in e);return void 0===r||t.call(e,r)},s=function(e,t){r&&"__proto__"===t.name?r(e,t.name,{enumerable:!0,configurable:!0,value:t.newValue,writable:!0}):e[t.name]=t.newValue},a=function(e,n){if("__proto__"===n){if(!t.call(e,n))return;else if(i)return i(e,n).value}return e[n]};e.exports=function e(){var t,n,r,i,u,c,d=arguments[0],h=1,p=arguments.length,f=!1;for("boolean"==typeof d&&(f=d,d=arguments[1]||{},h=2),(null==d||"object"!=typeof d&&"function"!=typeof d)&&(d={});h<p;++h)if(t=arguments[h],null!=t)for(n in t)r=a(d,n),d!==(i=a(t,n))&&(f&&i&&(l(i)||(u=o(i)))?(u?(u=!1,c=r&&o(r)?r:[]):c=r&&l(r)?r:{},s(d,{name:n,newValue:e(f,c,i)})):void 0!==i&&s(d,{name:n,newValue:i}));return d}},40318:(e,t,n)=>{"use strict";function r(e){"function"==typeof queueMicrotask?queueMicrotask(e):Promise.resolve().then(e).catch(e=>setTimeout(()=>{throw e}))}n.d(t,{_:()=>r})},41821:(e,t,n)=>{"use strict";n.d(t,{HydrationBoundary:()=>l});var r=n(32144),i=n(55766),o=n(59011),l=e=>{let{children:t,options:n={},state:l,queryClient:s}=e,a=(0,o.useQueryClient)(s),[u,c]=r.useState(),d=r.useRef(n);return d.current=n,r.useMemo(()=>{if(l){if("object"!=typeof l)return;let e=a.getQueryCache(),t=l.queries||[],n=[],r=[];for(let i of t){let t=e.get(i.queryHash);if(t){let e=i.state.dataUpdatedAt>t.state.dataUpdatedAt,n=null==u?void 0:u.find(e=>e.queryHash===i.queryHash);e&&(!n||i.state.dataUpdatedAt>n.state.dataUpdatedAt)&&r.push(i)}else n.push(i)}n.length>0&&(0,i.Qv)(a,{queries:n},d.current),r.length>0&&c(e=>e?[...e,...r]:r)}},[a,u,l]),r.useEffect(()=>{u&&((0,i.Qv)(a,{queries:u},d.current),c(void 0))},[a,u]),t}},42624:(e,t,n)=>{"use strict";n.d(t,{L:()=>o});var r=n(32144),i=n(56679);function o(){let[e]=(0,r.useState)(i.e);return(0,r.useEffect)(()=>()=>
1e.dispose(),[e]),e}},44346:e=>{var t=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,n=/\n/g,r=/^\s*/,i=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,o=/^:\s*/,l=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,s=/^[;\s]*/,a=/^\s+|\s+$/g;function u(e){return e?e.replace(a,""):""}e.exports=function(e,a){if("string"!=typeof e)throw TypeError("First argument must be a string");if(!e)return[];a=a||{};var c=1,d=1;function h(e){var t=e.match(n);t&&(c+=t.length);var r=e.lastIndexOf("\n");d=~r?e.length-r:d+e.length}function p(){var e={line:c,column:d};return function(t){return t.position=new f(e),v(r),t}}function f(e){this.start=e,this.end={line:c,column:d},this.source=a.source}f.prototype.content=e;var m=[];function g(t){var n=Error(a.source+":"+c+":"+d+": "+t);if(n.reason=t,n.filename=a.source,n.line=c,n.column=d,n.source=e,a.silent)m.push(n);else throw n}function v(t){var n=t.exec(e);if(n){var r=n[0];return h(r),e=e.slice(r.length),n}}function y(e){var t;for(e=e||[];t=x();)!1!==t&&e.push(t);return e}function x(){var t=p();if("/"==e.charAt(0)&&"*"==e.charAt(1)){for(var n=2;""!=e.charAt(n)&&("*"!=e.charAt(n)||"/"!=e.charAt(n+1));)++n;if(n+=2,""===e.charAt(n-1))return g("End of comment missing");var r=e.slice(2,n-2);return d+=2,h(r),e=e.slice(n),d+=2,t({type:"comment",comment:r})}}v(r);var b,w=[];for(y(w);b=function(){var e=p(),n=v(i);if(n){if(x(),!v(o))return g("property missing ':'");var r=v(l),a=e({type:"declaration",property:u(n[0].replace(t,"")),value:r?u(r[0].replace(t,"")):""});return v(s),a}}();)!1!==b&&(w.push(b),y(w));return w}},49877:(e,t,n)=>{"use strict";n.d(t,{o:()=>nD});var r={};n.r(r),n.d(r,{boolean:()=>g,booleanish:()=>v,commaOrSpaceSeparated:()=>E,commaSeparated:()=>w,number:()=>x,overloadedBoolean:()=>y,spaceSeparated:()=>b});var i={};n.r(i),n.d(i,{attentionMarkers:()=>
1tI,contentInitial:()=>tT,disable:()=>tD,document:()=>tS,flow:()=>tP,flowInitial:()=>tC,insideSpan:()=>t_,string:()=>tA,text:()=>tR});let o=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,l=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,s={};function a(e,t){return((t||s).jsx?l:o).test(e)}let u=/[ \t\n\f\r]/g;function c(e){return""===e.replace(u,"")}class d{constructor(e,t,n){this.property=e,this.normal=t,n&&(this.space=n)}}function h(e,t){let n={},r={},i=-1;for(;++i<e.length;)Object.assign(n,e[i].property),Object.assign(r,e[i].normal);return new d(n,r,t)}function p(e){return e.toLowerCase()}d.prototype.property={},d.prototype.normal={},d.prototype.space=null;class f{constructor(e,t){this.property=e,this.attribute=t}}f.prototype.space=null,f.prototype.boolean=!1,f.prototype.booleanish=!1,f.prototype.overloadedBoolean=!1,f.prototype.number=!1,f.prototype.commaSeparated=!1,f.prototype.spaceSeparated=!1,f.prototype.commaOrSpaceSeparated=!1,f.prototype.mustUseProperty=!1,f.prototype.defined=!1;let m=0,g=k(),v=k(),y=k(),x=k(),b=k(),w=k(),E=k();function k(){return 2**++m}let S=Object.keys(r);class T extends f{constructor(e,t,n,i){let o=-1;if(super(e,t),function(e,t,n){n&&(e[t]=n)}(this,"space",i),"number"==typeof n)for(;++o<S.length;){let e=S[o];!function(e,t,n){n&&(e[t]=n)}(this,S[o],(n&r[e])===r[e])}}}T.prototype.defined=!0;let C={}.hasOwnProperty;function P(e){let t,n={},r={};for(t in e.properties)if(C.call(e.properties,t)){let i=e.properties[t],o=new T(t,e.transform(e.attributes||{},t),i,e.space);e.mustUseProperty&&e.mustUseProperty.includes(t)&&(o.mustUseProperty=!0),n[t]=o,r[p(t)]=t,r[p(o.attribute)]=t}return new d(n,r,e.space)}let A=P({space:"xlink",transform:(e,t)=>"xlink:"+t.slice(5).toLowerCase(),properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null}}),R=P({space:"xml",transform:(e,t)=>"xml:"+t.slice(3).toLowerCase(),properties:{xmlLang:null,xmlBase:null,xmlSpace:null}});function _(e,t){return t in e?e[t]:t}function I(e,t){return _(e,t.toLowerCase())}let D=P({space:"xmlns",attributes:{xmlnsxlink:"xmlns:xlink"},transform:I,properties:{xmlns:null,xmlnsXLink:null}}),L=P({transform:(e,t)=>"role"===t?t:"aria-"+t.slice(4).toLowerCase(),properties:{ariaActiveDescendant:null,ariaAtomic:v,ariaAutoComplete:null,ariaBusy:v,ariaChecked:v,ariaColCount:x,ariaColIndex:x,ariaColSpan:x,ariaControls:b,ariaCurrent:null,ariaDescribedBy:b,ariaDetails:null,ariaDisabled:v,ariaDropEffect:b,ariaErrorMessage:null,ariaExpanded:v,ariaFlowTo:b,ariaGrabbed:v,ariaHasPopup:null,ariaHidden:v,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:b,ariaLevel:x,ariaLive:null,ariaModal:v,ariaMultiLine:v,ariaMultiSelectable:v,ariaOrientation:null,ariaOwns:b,ariaPlaceholder:null,ariaPosInSet:x,ariaPressed:v,ariaReadOnly:v,ariaRelevant:null,ariaRequired:v,ariaRoleDescription:b,ariaRowCount:x,ariaRowIndex:x,ariaRowSpan:x,ariaSelected:v,ariaSetSize:x,ariaSort:null,ariaValueMax:x,ariaValueMin:x,ariaValueNow:x,ariaValueText:null,role:null}}),M=P({space:"html",attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},transform:I,mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:w,acceptCharset:b,accessKey:b,action:null,allow:null,allowFullScreen:g,allowPaymentRequest:g,allowUserMedia:g,alt:null,as:null,async:g,autoCapitalize:null,autoComplete:b,autoFocus:g,autoPlay:g,blocking:b,capture:null,charSet:null,checked:g,cite:null,className:b,cols:x,colSpan:null,content:null,contentEditable:v,controls:g,controlsList:b,coords:x|w,crossOrigin:null,data:null,dateTime:null,decoding:null,default:g,defer:g,dir:null,dirName:null,disabled:g,download:y,draggable:v,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:g,formTarget:null,headers:b,height:x,hidden:g,high:x,href:null,hrefLang:null,htmlFor:b,httpEquiv:b,id:null,imageSizes:null,imageSrcSet:null,inert:g,inputMode:null,integrity:null,is:null,isMap:g,itemId:null,itemProp:b,itemRef:b,itemScope:g,itemType:b,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:g,low:x,manifest:null,max:null,maxLength:x,media:null,method:null,min:null,minLength:x,multiple:g,muted:g,name:null,nonce:null,noModule:g,noValidate:g,onAbort:null,onAfterPrint:null,onAuxCl
1ick:null,onBeforeMatch:null,onBeforePrint:null,onBeforeToggle:null,onBeforeUnload:null,onBlur:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onContextLost:null,onContextMenu:null,onContextRestored:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnded:null,onError:null,onFocus:null,onFormData:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLanguageChange:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadEnd:null,onLoadStart:null,onMessage:null,onMessageError:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRejectionHandled:null,onReset:null,onResize:null,onScroll:null,onScrollEnd:null,onSecurityPolicyViolation:null,onSeeked:null,onSeeking:null,onSelect:null,onSlotChange:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnhandledRejection:null,onUnload:null,onVolumeChange:null,onWaiting:null,onWheel:null,open:g,optimum:x,pattern:null,ping:b,placeholder:null,playsInline:g,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:g,referrerPolicy:null,rel:b,required:g,reversed:g,rows:x,rowSpan:x,sandbox:b,scope:null,scoped:g,seamless:g,selected:g,shadowRootClonable:g,shadowRootDelegatesFocus:g,shadowRootMode:null,shape:null,size:x,sizes:null,slot:null,span:x,spellCheck:v,src:null,srcDoc:null,srcLang:null,srcSet:null,start:x,step:null,style:null,tabIndex:x,target:null,title:null,translate:null,type:null,typeMustMatch:g,useMap:null,value:v,width:x,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:b,axis:null,background:null,bgColor:null,border:x,borderColor:null,bottomMargin:x,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:g,declare:g,event:null,face:null,frame:null,frameBorder:null,hSpace:x,leftMargin:x,link:null,longDesc:null,lowSrc:null,marginHeight:x,marginWidth:x,noResize:g,noHref:g,noShade:g,noWrap:g,object:null,profile:null,prompt:null,rev:null,rightMargin:x,rules:null,scheme:null,scrolling:v,standby:null,summary:null,text:null,topMargin:x,valueType:null,version:null,vAlign:null,vLink:null,vSpace:x,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:g,disableRemotePlayback:g,prefix:null,property:null,results:x,security:null,unselectable:null}}),F=P({space:"svg",attributes:{accentHeight:"accent-height",alignmentBaseline:"alignment-baseline",arabicForm:"arabic-form",baselineShift:"baseline-shift",capHeight:"cap-height",className:"class",clipPath:"clip-path",clipRule:"clip-rule",colorInterpolation:"color-interpolation",colorInterpolationFilters:"color-interpolation-filters",colorProfile:"color-profile",colorRendering:"color-rendering",crossOrigin:"crossorigin",dataType:"datatype",dominantBaseline:"dominant-baseline",enableBackground:"enable-background",fillOpacity:"fill-opacity",fillRule:"fill-rule",floodColor:"flood-color",floodOpacity:"flood-opacity",fontFamily:"font-family",fontSize:"font-size",fontSizeAdjust:"font-size-adjust",fontStretch:"font-stretch",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",glyphName:"glyph-name",glyphOrientationHorizontal:"glyph-orientation-horizontal",glyphOrientationVertical:"glyph-orientation-vertical",hrefLang:"hreflang",horizAdvX:"horiz-adv-x",horizOriginX:"horiz-origin-x",horizOriginY:"horiz-origin-y",imageRendering:"image-rendering",letterSpacing:"letter-spacing",lightingColor:"lighting-color",markerEnd:"marker-end",markerMid:"marker-mid",markerStart:"marker-start",navDown:"nav-down",navDownLeft:"nav-down-left",navDownRight:"nav-down-right",navLeft:"nav
1-left",navNext:"nav-next",navPrev:"nav-prev",navRight:"nav-right",navUp:"nav-up",navUpLeft:"nav-up-left",navUpRight:"nav-up-right",onAbort:"onabort",onActivate:"onactivate",onAfterPrint:"onafterprint",onBeforePrint:"onbeforeprint",onBegin:"onbegin",onCancel:"oncancel",onCanPlay:"oncanplay",onCanPlayThrough:"oncanplaythrough",onChange:"onchange",onClick:"onclick",onClose:"onclose",onCopy:"oncopy",onCueChange:"oncuechange",onCut:"oncut",onDblClick:"ondblclick",onDrag:"ondrag",onDragEnd:"ondragend",onDragEnter:"ondragenter",onDragExit:"ondragexit",onDragLeave:"ondragleave",onDragOver:"ondragover",onDragStart:"ondragstart",onDrop:"ondrop",onDurationChange:"ondurationchange",onEmptied:"onemptied",onEnd:"onend",onEnded:"onended",onError:"onerror",onFocus:"onfocus",onFocusIn:"onfocusin",onFocusOut:"onfocusout",onHashChange:"onhashchange",onInput:"oninput",onInvalid:"oninvalid",onKeyDown:"onkeydown",onKeyPress:"onkeypress",onKeyUp:"onkeyup",onLoad:"onload",onLoadedData:"onloadeddata",onLoadedMetadata:"onloadedmetadata",onLoadStart:"onloadstart",onMessage:"onmessage",onMouseDown:"onmousedown",onMouseEnter:"onmouseenter",onMouseLeave:"onmouseleave",onMouseMove:"onmousemove",onMouseOut:"onmouseout",onMouseOver:"onmouseover",onMouseUp:"onmouseup",onMouseWheel:"onmousewheel",onOffline:"onoffline",onOnline:"ononline",onPageHide:"onpagehide",onPageShow:"onpageshow",onPaste:"onpaste",onPause:"onpause",onPlay:"onplay",onPlaying:"onplaying",onPopState:"onpopstate",onProgress:"onprogress",onRateChange:"onratechange",onRepeat:"onrepeat",onReset:"onreset",onResize:"onresize",onScroll:"onscroll",onSeeked:"onseeked",onSeeking:"onseeking",onSelect:"onselect",onShow:"onshow",onStalled:"onstalled",onStorage:"onstorage",onSubmit:"onsubmit",onSuspend:"onsuspend",onTimeUpdate:"ontimeupdate",onToggle:"ontoggle",onUnload:"onunload",onVolumeChange:"onvolumechange",onWaiting:"onwaiting",onZoom:"onzoom",overlinePosition:"overline-position",overlineThickness:"overline-thickness",paintOrder:"paint-order",panose1:"panose-1",pointerEvents:"pointer-events",referrerPolicy:"referrerpolicy",renderingIntent:"rendering-intent",shapeRendering:"shape-rendering",stopColor:"stop-color",stopOpacity:"stop-opacity",strikethroughPosition:"strikethrough-position",strikethroughThickness:"strikethrough-thickness",strokeDashArray:"stroke-dasharray",strokeDashOffset:"stroke-dashoffset",strokeLineCap:"stroke-linecap",strokeLineJoin:"stroke-linejoin",strokeMiterLimit:"stroke-miterlimit",strokeOpacity:"stroke-opacity",strokeWidth:"stroke-width",tabIndex:"tabindex",textAnchor:"text-anchor",textDecoration:"text-decoration",textRendering:"text-rendering",transformOrigin:"transform-origin",typeOf:"typeof",underlinePosition:"underline-position",underlineThickness:"underline-thickness",unicodeBidi:"unicode-bidi",unicodeRange:"unicode-range",unitsPerEm:"units-per-em",vAlphabetic:"v-alphabetic",vHanging:"v-hanging",vIdeographic:"v-ideographic",vMathematical:"v-mathematical",vectorEffect:"vector-effect",vertAdvY:"vert-adv-y",vertOriginX:"vert-origin-x",vertOriginY:"vert-origin-y",wordSpacing:"word-spacing",writingMode:"writing-mode",xHeight:"x-height",playbackOrder:"playbackorder",timelineBegin:"timelinebegin"},transform:_,properties:{about:E,accentHeight:x,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:x,amplitude:x,arabicForm:null,ascent:x,attributeName:null,attributeType:null,azimuth:x,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:x,by:null,calcMode:null,capHeight:x,className:b,clip:null,clipPath:null,clipPathUnits:null,clipRule:null,color:null,colorInterpolation:null,colorInterpolationFilters:null,colorProfile:null,colorRendering:null,content:null,contentScriptType:null,contentStyleType:null,crossOrigin:null,cursor:null,cx:null,cy:null,d:null,dataType:null,defaultAction:null,descent:x,diffuseConstant:x,direction:null,display:null,dur:null,divisor:x,dominantBaseline:null,download:g,dx:null,dy:null,edgeMode:null,editable:null,elevation:x,enableBackground:null,end:null,event:null,exponent:x,externalResourcesRequired:null,fill:null,fillOpacity:x,fillRule:null,filter:null,filterRes:null,filterUnits:null,floodColor:null,floodOpacity:null,focusable:null,focusHighlight:null,fontFamily:null,fontSize:null,fontSizeAdjust:null,fontStretch:null,fontStyle:null,fontVariant:null,fontWeight:null,format:null,fr:null,from:null,fx:null,fy:null,g1:w,g2:w,glyphName:w,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:x,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:x,horizOriginX:x,horizOriginY:x,id:null,ideographic:x,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:
1x,k:x,k1:x,k2:x,k3:x,k4:x,kernelMatrix:E,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:x,local:null,markerEnd:null,markerMid:null,markerStart:null,markerHeight:null,markerUnits:null,markerWidth:null,mask:null,maskContentUnits:null,maskUnits:null,mathematical:null,max:null,media:null,mediaCharacterEncoding:null,mediaContentEncodings:null,mediaSize:x,mediaTime:null,method:null,min:null,mode:null,name:null,navDown:null,navDownLeft:null,navDownRight:null,navLeft:null,navNext:null,navPrev:null,navRight:null,navUp:null,navUpLeft:null,navUpRight:null,numOctaves:null,observer:null,offset:null,onAbort:null,onActivate:null,onAfterPrint:null,onBeforePrint:null,onBegin:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnd:null,onEnded:null,onError:null,onFocus:null,onFocusIn:null,onFocusOut:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadStart:null,onMessage:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onMouseWheel:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRepeat:null,onReset:null,onResize:null,onScroll:null,onSeeked:null,onSeeking:null,onSelect:null,onShow:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnload:null,onVolumeChange:null,onWaiting:null,onZoom:null,opacity:null,operator:null,order:null,orient:null,orientation:null,origin:null,overflow:null,overlay:null,overlinePosition:x,overlineThickness:x,paintOrder:null,panose1:null,path:null,pathLength:x,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:b,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:x,pointsAtY:x,pointsAtZ:x,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:E,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:E,rev:E,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:E,requiredFeatures:E,requiredFonts:E,requiredFormats:E,resource:null,restart:null,result:null,rotate:null,rx:null,ry:null,scale:null,seed:null,shapeRendering:null,side:null,slope:null,snapshotTime:null,specularConstant:x,specularExponent:x,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:x,strikethroughThickness:x,string:null,stroke:null,strokeDashArray:E,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:x,strokeOpacity:x,strokeWidth:null,style:null,surfaceScale:x,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:E,tabIndex:x,tableValues:null,target:null,targetX:x,targetY:x,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:E,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:x,underlineThickness:x,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:x,values:null,vAlphabetic:x,vMathematical:x,vectorEffect:null,vHanging:x,vIdeographic:x,version:null,vertAdvY:x,vertOriginX:x,vertOriginY:x,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:x,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null}}),O=h([R,A,D,L,M],"html"),j=h([R,A,D,L,F],"svg"),N=/^data[-\w.:]+$/i,V=/-[a-z]/g,B=/[A-Z]/g;function U(e){return"-"+e.toLowerCase()}function z(e){return e.charAt(1).toUpperCase()}let H={classId:"classID",dataType:"datatype",itemId:"itemID",strokeDashArray:"strokeDasharray",strokeDashOffset:"strokeDashoffset",strokeLineCap:"strokeLinecap",strokeLineJoin:"strokeLinejoin",strokeMiterLimit:"strokeMiterlimit",typeOf:"typeof",xLinkActuate:"xlinkActuate",xLinkArcRole:"xlinkArcrole",xLinkHref:"xlinkHref",xLinkRole:"xlinkRole",xLinkShow:"xlinkShow",xLinkTitle:"xlinkTitle",xLinkType:"xlinkType",xmlnsXLink:"xmlnsXlink"};var W=n(92104);let q=W.default||W,Y=$("end"),G=$("start");function $(e){return function(t){let n=t&&t.position&&t.position[e]||{};if("number"==typeof n.line&&n.line>0&&"number"==typeof n.column&&n.column>0)return{line:n.line,column:n.column,offset:"number"==typeof n.offset&&n.offset>-1?n.offset:void 0}}}function X(e){return e&&"object"==typeof e?"position"in e||"type"in e?J(e.position):"start"in e||"end"in e?J(e):"line"in e||"column"in e?K(e):"":""}function K(e){return Z(e&&e.line)+":"+Z(e&&e.column)}function J(e){return K(e&&e.start)+"-"+K(e&&e.end)}function Z(e){return e&&"number"==typeof e?e:1}
1class Q extends Error{constructor(e,t,n){super(),"string"==typeof t&&(n=t,t=void 0);let r="",i={},o=!1;if(t&&(i="line"in t&&"column"in t||"start"in t&&"end"in t?{place:t}:"type"in t?{ancestors:[t],place:t.position}:{...t}),"string"==typeof e?r=e:!i.cause&&e&&(o=!0,r=e.message,i.cause=e),!i.ruleId&&!i.source&&"string"==typeof n){let e=n.indexOf(":");-1===e?i.ruleId=n:(i.source=n.slice(0,e),i.ruleId=n.slice(e+1))}if(!i.place&&i.ancestors&&i.ancestors){let e=i.ancestors[i.ancestors.length-1];e&&(i.place=e.position)}let l=i.place&&"start"in i.place?i.place.start:i.place;this.ancestors=i.ancestors||void 0,this.cause=i.cause||void 0,this.column=l?l.column:void 0,this.fatal=void 0,this.file,this.message=r,this.line=l?l.line:void 0,this.name=X(i.place)||"1:1",this.place=i.place||void 0,this.reason=this.message,this.ruleId=i.ruleId||void 0,this.source=i.source||void 0,this.stack=o&&i.cause&&"string"==typeof i.cause.stack?i.cause.stack:"",this.actual,this.expected,this.note,this.url}}Q.prototype.file="",Q.prototype.name="",Q.prototype.reason="",Q.prototype.message="",Q.prototype.stack="",Q.prototype.column=void 0,Q.prototype.line=void 0,Q.prototype.ancestors=void 0,Q.prototype.cause=void 0,Q.prototype.fatal=void 0,Q.prototype.place=void 0,Q.prototype.ruleId=void 0,Q.prototype.source=void 0;let ee={}.hasOwnProperty,et=new Map,en=/[A-Z]/g,er=/-([a-z])/g,ei=new Set(["table","tbody","thead","tfoot","tr"]),eo=new Set(["td","th"]),el="https://github.com/syntax-tree/hast-util-to-jsx-runtime";
1function es(e,t,n){return"element"===t.type?function(e,t,n){let r=e.schema;"svg"===t.tagName.toLowerCase()&&"html"===r.space&&(e.schema=j),e.ancestors.push(t);let i=ed(e,t.tagName,!1),o=function(e,t){let n,r,i={};for(r in t.properties)if("children"!==r&&ee.call(t.properties,r)){let o=function(e,t,n){let r=function(e,t){let n=p(t),r=t,i=f;if(n in e.normal)return e.property[e.normal[n]];if(n.length>4&&"data"===n.slice(0,4)&&N.test(t)){if("-"===t.charAt(4)){let e=t.slice(5).replace(V,z);r="data"+e.charAt(0).toUpperCase()+e.slice(1)}else{let e=t.slice(4);if(!V.test(e)){let n=e.replace(B,U);"-"!==n.charAt(0)&&(n="-"+n),t="data"+n}}i=T}return new i(r,t)}(e.schema,t);if(!(null==n||"number"==typeof n&&Number.isNaN(n))){if(Array.isArray(n)&&(n=r.commaSeparated?function(e,t){let n={};return(""===e[e.length-1]?[...e,""]:e).join((n.padRight?" ":"")+","+(!1===n.padLeft?"":" ")).trim()}(n):n.join(" ").trim()),"style"===r.property){let t="object"==typeof n?n:function(e,t){let n={};try{q(t,function(e,t){let r=e;"--"!==r.slice(0,2)&&("-ms-"===r.slice(0,4)&&(r="ms-"+r.slice(4)),r=r.replace(er,ep)),n[r]=t})}catch(t){if(!e.ignoreInvalidStyle){let n=new Q("Cannot parse `style` attribute",{ancestors:e.ancestors,cause:t,ruleId:"style",source:"hast-util-to-jsx-runtime"});throw n.file=e.filePath||void 0,n.url=el+"#cannot-parse-style-attribute",n}}return n}(e,String(n));return"css"===e.stylePropertyNameCase&&(t=function(e){let t,n={};for(t in e)ee.call(e,t)&&(n[function(e){let t=e.replace(en,ef);return"ms-"===t.slice(0,3)&&(t="-"+t),t}(t)]=e[t]);return n}(t)),["style",t]}return["react"===e.elementAttributeNameCase&&r.space?H[r.property]||r.property:r.attribute,n]}}(e,r,t.properties[r]);if(o){let[r,l]=o;e.tableCellAlignToStyle&&"align"===r&&"string"==typeof l&&eo.has(t.tagName)?n=l:i[r]=l}}return n&&((i.style||(i.style={}))["css"===e.stylePropertyNameCase?"text-align":"textAlign"]=n),i}(e,t),l=ec(e,t);return ei.has(t.tagName)&&(l=l.filter(function(e){return"string"!=typeof e||!("object"==typeof e?"text"===e.type&&c(e.value):c(e))})),ea(e,o,i,t),eu(o,l),e.ancestors.pop(),e.schema=r,e.create(t,i,o,n)}(e,t,n):"mdxFlowExpression"===t.type||"mdxTextExpression"===t.type?function(e,t){if(t.data&&t.data.estree&&e.evaluater){let n=t.data.estree.body[0];return n.type,e.evaluater.evaluateExpression(n.expression)}eh(e,t.position)}(e,t):"mdxJsxFlowElement"===t.type||"mdxJsxTextElement"===t.type?function(e,t,n){let r=e.schema;"svg"===t.name&&"html"===r.space&&(e.schema=j),e.ancestors.push(t);let i=null===t.name?e.Fragment:ed(e,t.name,!0),o=function(e,t){let n={};for(let r of t.attributes)if("mdxJsxExpressionAttribute"===r.type)if(r.data&&r.data.estree&&e.evaluater){let t=r.data.estree.body[0];t.type;let i=t.expression;i.type;let o=i.properties[0];o.type,Object.assign(n,e.evaluater.evaluateExpression(o.argument))}else eh(e,t.position);else{let i,o=r.name;if(r.value&&"object"==typeof r.value)if(r.value.data&&r.value.data.estree&&e.evaluater){let t=r.value.data.estree.body[0];t.type,i=e.evaluater.evaluateExpression(t.expression)}else eh(e,t.position);else i=null===r.value||r.value;n[o]=i}return n}(e,t),l=ec(e,t);return ea(e,o,i,t),eu(o,l),e.ancestors.pop(),e.schema=r,e.create(t,i,o,n)}(e,t,n):"mdxjsEsm"===t.type?function(e,t){if(t.data&&t.data.estree&&e.evaluater)return e.evaluater.evaluateProgram(t.data.estree);eh(e,t.position)}(e,t):"root"===t.type?function(e,t,n){let r={};return eu(r,ec(e,t)),e.create(t,e.Fragment,r,n)}(e,t,n):"text"===t.type?t.value:void 0}function ea(e,t,n,r){"string"!=typeof n&&n!==e.Fragment&&e.passNode&&(t.node=r)}function eu(e,t){if(t.length>0){let n=t.length>1?t:t[0];n&&(e.children=n)}}function ec(e,t){let n=[],r=-1,i=e.passKeys?new Map:et;for(;++r<t.children.length;){let o,l=t.children[r];if(e.passKeys){let e="element"===l.type?l.tagName:"mdxJsxFlowElement"===l.type||"mdxJsxTextElement"===l.type?l.name:void 0;if(e){let t=i.get(e)||0;o=e+"-"+t,i.set(e,t+1)}}let s=es(e,l,o);void 0!==s&&n.push(s)}return n}function ed(e,t,n){let r;if(n)if(t.includes(".")){let e,n=t.split("."),i=-1;for(;++i<n.length;){let t=a(n[i])?{type:"Identifier",name:n[i]}:{type:"Literal",value:n[i]};e=e?{type:"MemberExpression",object:e,property:t,computed:!!(i&&"Literal"===t.type),optional:!1}:t}r=e}else r=a(t)&&!/^[a-z]/.test(t)?{type:"Identifier",name:t}:{type:"Literal",value:t};else r={type:"Literal",value:t};if("Literal"===r.type){let t=r.value;return ee.call(e.components,t)?e.components[t]:t}if(e.evaluater)return e.evaluater.evaluateExpression(r);eh(e)}function eh(e,t){let n=new Q("Cannot handle MDX estrees without `createEvaluater`",{ancestors:e.ancestors,place:t,ruleId:"mdx-estree",source:"hast-util-to-jsx-runtime"});throw n.file=e.filePath||void 0,n.url=el+"#cannot-handle-mdx-estrees-without-createevaluater",n}function ep(e,t){return t.toUpperCase()}function ef(e){return"-"+e.toLowerCase()}let em={action:["form"],cite:["blockquote","del","ins","q"],data:["object"],formAction:["button","input"],href:["a","area","base","link"],icon:["menuitem"],itemId:null,manifest:["html"],ping:["a","area"],poster:["video"],src:["audio","embed","iframe","img","input","script","source","track","video"]};var eg=n(11612);let ev={};
1function ey(e,t,n){var r;if((r=e)&&"object"==typeof r){if("value"in e)return"html"!==e.type||n?e.value:"";if(t&&"alt"in e&&e.alt)return e.alt;if("children"in e)return ex(e.children,t,n)}return Array.isArray(e)?ex(e,t,n):""}function ex(e,t,n){let r=[],i=-1;for(;++i<e.length;)r[i]=ey(e[i],t,n);return r.join("")}function eb(e,t,n,r){let i,o=e.length,l=0;if(t=t<0?-t>o?0:o+t:t>o?o:t,n=n>0?n:0,r.length<1e4)(i=Array.from(r)).unshift(t,n),e.splice(...i);else for(n&&e.splice(t,n);l<r.length;)(i=r.slice(l,l+1e4)).unshift(t,0),e.splice(...i),l+=1e4,t+=1e4}function ew(e,t){return e.length>0?(eb(e,e.length,0,t),e):t}class eE{constructor(e){this.left=e?[...e]:[],this.right=[]}get(e){if(e<0||e>=this.left.length+this.right.length)throw RangeError("Cannot access index `"+e+"` in a splice buffer of size `"+(this.left.length+this.right.length)+"`");return e<this.left.length?this.left[e]:this.right[this.right.length-e+this.left.length-1]}get length(){return this.left.length+this.right.length}shift(){return this.setCursor(0),this.right.pop()}slice(e,t){let n=null==t?1/0:t;return n<this.left.length?this.left.slice(e,n):e>this.left.length?this.right.slice(this.right.length-n+this.left.length,this.right.length-e+this.left.length).reverse():this.left.slice(e).concat(this.right.slice(this.right.length-n+this.left.length).reverse())}splice(e,t,n){this.setCursor(Math.trunc(e));let r=this.right.splice(this.right.length-(t||0),1/0);return n&&ek(this.left,n),r.reverse()}pop(){return this.setCursor(1/0),this.left.pop()}push(e){this.setCursor(1/0),this.left.push(e)}pushMany(e){this.setCursor(1/0),ek(this.left,e)}unshift(e){this.setCursor(0),this.right.push(e)}unshiftMany(e){this.setCursor(0),ek(this.right,e.reverse())}setCursor(e){if(e!==this.left.length&&(!(e>this.left.length)||0!==this.right.length)&&(!(e<0)||0!==this.left.length))if(e<this.left.length){let t=this.left.splice(e,1/0);ek(this.right,t.reverse())}else{let t=this.right.splice(this.left.length+this.right.length-e,1/0);ek(this.left,t.reverse())}}}function ek(e,t){let n=0;if(t.length<1e4)e.push(...t);else for(;n<t.length;)e.push(...t.slice(n,n+1e4)),n+=1e4}function eS(e){let t,n,r,i,o,l,s,a={},u=-1,c=new eE(e);for(;++u<c.length;){for(;u in a;)u=a[u];if(t=c.get(u),u&&"chunkFlow"===t[1].type&&"listItemPrefix"===c.get(u-1)[1].type&&((r=0)<(l=t[1]._tokenizer.events).length&&"lineEndingBlank"===l[r][1].type&&(r+=2),r<l.length&&"content"===l[r][1].type))for(;++r<l.length&&"content"!==l[r][1].type;)"chunkText"===l[r][1].type&&(l[r][1]._isInFirstContentOfListItem=!0,r++);if("enter"===t[0])t[1].contentType&&(Object.assign(a,function(e,t){let n,r,i=e.get(t)[1],o=e.get(t)[2],l=t-1,s=[],a=i._tokenizer||o.parser[i.contentType](i.start),u=a.events,c=[],d={},h=-1,p=i,f=0,m=0,g=[0];for(;p;){for(;e.get(++l)[1]!==p;);s.push(l),!p._tokenizer&&(n=o.sliceStream(p),p.next||n.push(null),r&&a.defineSkip(p.start),p._isInFirstContentOfListItem&&(a._gfmTasklistFirstContentOfListItem=!0),a.write(n),p._isInFirstContentOfListItem&&(a._gfmTasklistFirstContentOfListItem=void 0)),r=p,p=p.next}for(p=i;++h<u.length;)"exit"===u[h][0]&&"enter"===u[h-1][0]&&u[h][1].type===u[h-1][1].type&&u[h][1].start.line!==u[h][1].end.line&&(m=h+1,g.push(m),p._tokenizer=void 0,p.previous=void 0,p=p.next);for(a.events=[],p?(p._tokenizer=void 0,p.previous=void 0):g.pop(),h=g.length;h--;){let t=u.slice(g[h],g[h+1]),n=s.pop();c.push([n,n+t.length-1]),e.splice(n,2,t)}for(c.reverse(),h=-1;++h<c.length;)d[f+c[h][0]]=f+c[h][1],f+=c[h][1]-c[h][0]-1;return d}(c,u)),u=a[u],s=!0);else if(t[1]._container){for(r=u,n=void 0;r--;)if("lineEnding"===(i=c.get(r))[1].type||"lineEndingBlank"===i[1].type)"enter"===i[0]&&(n&&(c.get(n)[1].type="lineEndingBlank"),i[1].type="lineEnding",n=r);else break;n&&(t[1].end=Object.assign({},c.get(n)[1].start),(o=c.slice(n,u)).unshift(t),c.splice(n,u-n+1,o))}}return eb(e,0,1/0,c.slice(0)),!s}let eT={}.hasOwnProperty,eC=eN(/[A-Za-z]/),eP=eN(/[\dA-Za-z]/),eA=eN(/[#-'*+\--9=?A-Z^-~]/);function eR(e){return null!==e&&(e<32||127===e)}let e_=eN(/\d/),eI=eN(/[\dA-Fa-f]/),eD=eN(/[!-/:-@[-`{-~]/);function eL(e){return null!==e&&e<-2}function eM(e){return null!==e&&(e<0||32===e)}function eF(e){return -2===e||-1===e||32===e}let eO=eN(/\p{P}|\p{S}/u),ej=eN(/\s/);function eN(e){return function(t){return null!==t&&t>-1&&e.test(String.fromCharCode(t))}}function eV(e,t,n,r){let i=r?r-1:1/0,o=0;return function(r){return eF(r)?(e.enter(n),function r(l){return eF(l)&&o++<i?(e.consume(l),r):(e.exit(n),t(l))}(r)):t(r)}}let eB={tokenize:function(e){let t,n=e.attempt(this.parser.constructs.contentInitial,function(t){return null===t?void e.consume(t):(e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),eV(e,n,"linePrefix"))},function(n){return e.enter("paragraph"),function n(r){let i=e.enter("chunkText",{contentType:"text",previous:t});return t&&(t.next=i),t=i,function t(r){if(null===r){e.exit("chunkText"),e.exit("paragraph"),e.consume(r);return}return eL(r)?(e.consume(r),e.exit("chunkText"),n):(e.consume(r),t)}(r)}(n)});return n}},eU={tokenize:function(e){let t,n,r,i=this,o=[],l=0;return s;function s(t){if(l<o.length){let n=o[l];return i.containerState=n[1],e.attempt(n[0].continuation,a,u)(t)}return u(t)}function a(e){if(l++,i.containerState._closeFlow){let n;i.containerState._closeFlow=void 0,t&&v();let r=i.events.length,o=r;for(;o--;)if("exit"===i.events[o][0]&&"chunkFlow"===i.events[o][1].type){n=i.events[o][1].end;break}g(l);let s=r;for(;s<i.events.length;)i.events[s][1].end=Object.assign({},n),s++;return eb(i.events,o+1,0,i.events.slice(r)),i.events.length=s,u(e)}return s(e)}function u(n){if(l===o.length){if(!t)return h(n);if(t.currentConstruct&&t.currentConstruct.concrete)return f(n);i.interrupt=!!(t.currentConstruct&&!t._gfmTableDynamicInterruptHack)}return i.containerState={},e.check(ez,c,d)(n)}function c(e){return t&&v(),g(l),h(e)}function d(e){return i.parser.lazy[i.now().line]=l!==o.length,r=i.now().offset,f(e)}function h(t){return i.containerState={},e.attempt(ez,p,f)(t)}function p(e){return l++,o.push([i.currentConstruct,i.containerState]),h(e)}function f(r){if(null===r){t&&v(),g(0),e.consume(r);return}return t=t||i.parser.flow(i.now()),e.enter("chunkFlow",{contentType:"flow",previous:n,_tokenizer:t}),function t(n){if(null===n){m(e.exit("chunkFlow"),!0),g(0),e.consume(n);return}return eL(n)?(e.consume(n),m(e.exit("chunkFlow")),l=0,i.interrupt=void 0,s):(e.consume(n),t)}(r)}function m(e,o){let s=i.sliceStream(e);
1if(o&&s.push(null),e.previous=n,n&&(n.next=e),n=e,t.defineSkip(e.start),t.write(s),i.parser.lazy[e.start.line]){let e,n,o=t.events.length;for(;o--;)if(t.events[o][1].start.offset<r&&(!t.events[o][1].end||t.events[o][1].end.offset>r))return;let s=i.events.length,a=s;for(;a--;)if("exit"===i.events[a][0]&&"chunkFlow"===i.events[a][1].type){if(e){n=i.events[a][1].end;break}e=!0}for(g(l),o=s;o<i.events.length;)i.events[o][1].end=Object.assign({},n),o++;eb(i.events,a+1,0,i.events.slice(s)),i.events.length=o}}function g(t){let n=o.length;for(;n-- >t;){let t=o[n];i.containerState=t[1],t[0].exit.call(i,e)}o.length=t}function v(){t.write([null]),n=void 0,t=void 0,i.containerState._closeFlow=void 0}}},ez={tokenize:function(e,t,n){return eV(e,e.attempt(this.parser.constructs.document,t,n),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}},eH={tokenize:function(e,t,n){return function(t){return eF(t)?eV(e,r,"linePrefix")(t):r(t)};function r(e){return null===e||eL(e)?t(e):n(e)}},partial:!0},eW={tokenize:function(e,t){let n;return function(t){return e.enter("content"),n=e.enter("chunkContent",{contentType:"content"}),r(t)};function r(t){return null===t?i(t):eL(t)?e.check(eq,o,i)(t):(e.consume(t),r)}function i(n){return e.exit("chunkContent"),e.exit("content"),t(n)}function o(t){return e.consume(t),e.exit("chunkContent"),n.next=e.enter("chunkContent",{contentType:"content",previous:n}),n=n.next,r}},resolve:function(e){return eS(e),e}},eq={tokenize:function(e,t,n){let r=this;return function(t){return e.exit("chunkContent"),e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),eV(e,i,"linePrefix")};function i(i){if(null===i||eL(i))return n(i);let o=r.events[r.events.length-1];return!r.parser.constructs.disable.null.includes("codeIndented")&&o&&"linePrefix"===o[1].type&&o[2].sliceSerialize(o[1],!0).length>=4?t(i):e.interrupt(r.parser.constructs.flow,n,t)(i)}},partial:!0},eY={tokenize:function(e){let t=this,n=e.attempt(eH,function(r){return null===r?void e.consume(r):(e.enter("lineEndingBlank"),e.consume(r),e.exit("lineEndingBlank"),t.currentConstruct=void 0,n)},e.attempt(this.parser.constructs.flowInitial,r,eV(e,e.attempt(this.parser.constructs.flow,r,e.attempt(eW,r)),"linePrefix")));return n;function r(r){return null===r?void e.consume(r):(e.enter("lineEnding"),e.consume(r),e.exit("lineEnding"),t.currentConstruct=void 0,n)}}},eG={resolveAll:eJ()},e$=eK("string"),eX=eK("text");function eK(e){return{tokenize:function(t){let n=this,r=this.parser.constructs[e],i=t.attempt(r,o,l);return o;function o(e){return a(e)?i(e):l(e)}function l(e){return null===e?void t.consume(e):(t.enter("data"),t.consume(e),s)}function s(e){return a(e)?(t.exit("data"),i(e)):(t.consume(e),s)}function a(e){if(null===e)return!0;let t=r[e],i=-1;if(t)for(;++i<t.length;){let e=t[i];if(!e.previous||e.previous.call(n,n.previous))return!0}return!1}},resolveAll:eJ("text"===e?eZ:void 0)}}function eJ(e){return function(t,n){let r,i=-1;for(;++i<=t.length;)void 0===r?t[i]&&"data"===t[i][1].type&&(r=i,i++):t[i]&&"data"===t[i][1].type||(i!==r+2&&(t[r][1].end=t[i-1][1].end,t.splice(r+2,i-r-2),i=r+2),r=void 0);return e?e(t,n):t}}function eZ(e,t){let n=0;for(;++n<=e.length;)if((n===e.length||"lineEnding"===e[n][1].type)&&"data"===e[n-1][1].type){let r,i=e[n-1][1],o=t.sliceStream(i),l=o.length,s=-1,a=0;for(;l--;){let e=o[l];if("string"==typeof e){for(s=e.length;32===e.charCodeAt(s-1);)a++,s--;if(s)break;s=-1}else if(-2===e)r=!0,a++;else if(-1===e);else{l++;break}}if(a){let o={type:n===e.length||r||a<2?"lineSuffix":"hardBreakTrailing",start:{line:i.end.line,column:i.end.column-a,offset:i.end.offset-a,_index:i.start._index+l,_bufferIndex:l?s:i.start._bufferIndex+s},end:Object.assign({},i.end)};i.end=Object.assign({},o.start),i.start.offset===i.end.offset?Object.assign(i,o):(e.splice(n,0,["enter",o,t],["exit",o,t]),n+=2)}n++}return e}function eQ(e,t,n){let r=[],i=-1;for(;++i<e.length;){let o=e[i].resolveAll;o&&!r.includes(o)&&(t=o(t,n),r.push(o))}return t}let e0={name:"thematicBreak",tokenize:function(e,t,n){let r,i=0;return function(o){var l;return e.enter("thematicBreak"),r=l=o,function o(l){return l===r?(e.enter("thematicBreakSequence"),function t(n){return n===r?(e.consume(n),i++,t):(e.exit("thematicBreakSequence"),eF(n)?eV(e,o,"whitespace")(n):o(n))}(l)):i>=3&&(null===l||eL(l))?(e.exit("thematicBreak"),t(l)):n(l)}(l)}}},e1={name:"list",tokenize:function(e,t,n){let r=this,i=r.events[r.events.length-1],o=i&&"linePrefix"===i[1].type?i[2].sliceSerialize(i[1],!0).length:0,l=0;return function(t){let i=r.containerState.type||(42===t||43===t||45===t?"listUnordered":"listOrdered");if("listUnordered"===i?!r.containerState.marker||t===r.containerState.marker:e_(t)){if(r.containerState.type||(r.containerState.type=i,e.enter(i,{_container:!0})),"listUnordered"===i)return e.enter("listItemPrefix"),42===t||45===t?e.check(e0,n,s)(t):s(t);if(!r.interrupt||49===t)return e.enter("listItemPrefix"),e.enter("listItemValue"),function t(i){return e_(i)&&++l<10?(e.consume(i),t):(!r.interrupt||l<2)&&(r.containerState.marker?i===r.containerState.marker:41===i||46===i)?(e.exit("listItemValue"),s(i)):n(i)}(t)}return n(t)};function s(t){return e.enter("listItemMarker"),e.consume(t),e.exit("listItemMarker"),r.containerState.marker=r.containerState.marker||t,e.check(eH,r.interrupt?n:a,e.attempt(e2,c,u))}
1function a(e){return r.containerState.initialBlankLine=!0,o++,c(e)}function u(t){return eF(t)?(e.enter("listItemPrefixWhitespace"),e.consume(t),e.exit("listItemPrefixWhitespace"),c):n(t)}function c(n){return r.containerState.size=o+r.sliceSerialize(e.exit("listItemPrefix"),!0).length,t(n)}},continuation:{tokenize:function(e,t,n){let r=this;return r.containerState._closeFlow=void 0,e.check(eH,function(n){return r.containerState.furtherBlankLines=r.containerState.furtherBlankLines||r.containerState.initialBlankLine,eV(e,t,"listItemIndent",r.containerState.size+1)(n)},function(n){return r.containerState.furtherBlankLines||!eF(n)?(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,i(n)):(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,e.attempt(e4,t,i)(n))});function i(i){return r.containerState._closeFlow=!0,r.interrupt=void 0,eV(e,e.attempt(e1,t,n),"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(i)}}},exit:function(e){e.exit(this.containerState.type)}},e2={tokenize:function(e,t,n){let r=this;return eV(e,function(e){let i=r.events[r.events.length-1];return!eF(e)&&i&&"listItemPrefixWhitespace"===i[1].type?t(e):n(e)},"listItemPrefixWhitespace",r.parser.constructs.disable.null.includes("codeIndented")?void 0:5)},partial:!0},e4={tokenize:function(e,t,n){let r=this;return eV(e,function(e){let i=r.events[r.events.length-1];return i&&"listItemIndent"===i[1].type&&i[2].sliceSerialize(i[1],!0).length===r.containerState.size?t(e):n(e)},"listItemIndent",r.containerState.size+1)},partial:!0},e3={name:"blockQuote",tokenize:function(e,t,n){let r=this;return function(t){if(62===t){let n=r.containerState;return n.open||(e.enter("blockQuote",{_container:!0}),n.open=!0),e.enter("blockQuotePrefix"),e.enter("blockQuoteMarker"),e.consume(t),e.exit("blockQuoteMarker"),i}return n(t)};function i(n){return eF(n)?(e.enter("blockQuotePrefixWhitespace"),e.consume(n),e.exit("blockQuotePrefixWhitespace"),e.exit("blockQuotePrefix"),t):(e.exit("blockQuotePrefix"),t(n))}},continuation:{tokenize:function(e,t,n){let r=this;return function(t){return eF(t)?eV(e,i,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(t):i(t)};function i(r){return e.attempt(e3,t,n)(r)}}},exit:function(e){e.exit("blockQuote")}};function e5(e,t,n,r,i,o,l,s,a){let u=a||1/0,c=0;return function(t){return 60===t?(e.enter(r),e.enter(i),e.enter(o),e.consume(t),e.exit(o),d):null===t||32===t||41===t||eR(t)?n(t):(e.enter(r),e.enter(l),e.enter(s),e.enter("chunkString",{contentType:"string"}),f(t))};function d(n){return 62===n?(e.enter(o),e.consume(n),e.exit(o),e.exit(i),e.exit(r),t):(e.enter(s),e.enter("chunkString",{contentType:"string"}),h(n))}function h(t){return 62===t?(e.exit("chunkString"),e.exit(s),d(t)):null===t||60===t||eL(t)?n(t):(e.consume(t),92===t?p:h)}function p(t){return 60===t||62===t||92===t?(e.consume(t),h):h(t)}function f(i){return!c&&(null===i||41===i||eM(i))?(e.exit("chunkString"),e.exit(s),e.exit(l),e.exit(r),t(i)):c<u&&40===i?(e.consume(i),c++,f):41===i?(e.consume(i),c--,f):null===i||32===i||40===i||eR(i)?n(i):(e.consume(i),92===i?m:f)}function m(t){return 40===t||41===t||92===t?(e.consume(t),f):f(t)}}function e6(e,t,n,r,i,o){let l,s=this,a=0;return function(t){return e.enter(r),e.enter(i),e.consume(t),e.exit(i),e.enter(o),u};function u(d){return a>999||null===d||91===d||93===d&&!l||94===d&&!a&&"_hiddenFootnoteSupport"in s.parser.constructs?n(d):93===d?(e.exit(o),e.enter(i),e.consume(d),e.exit(i),e.exit(r),t):eL(d)?(e.enter("lineEnding"),e.consume(d),e.exit("lineEnding"),u):(e.enter("chunkString",{contentType:"string"}),c(d))}function c(t){return null===t||91===t||93===t||eL(t)||a++>999?(e.exit("chunkString"),u(t)):(e.consume(t),l||(l=!eF(t)),92===t?d:c)}function d(t){return 91===t||92===t||93===t?(e.consume(t),a++,c):c(t)}}function e9(e,t,n,r,i,o){let l;return function(t){return 34===t||39===t||40===t?(e.enter(r),e.enter(i),e.consume(t),e.exit(i),l=40===t?41:t,s):n(t)};function s(n){return n===l?(e.enter(i),e.consume(n),e.exit(i),e.exit(r),t):(e.enter(o),a(n))}function a(t){return t===l?(e.exit(o),s(l)):null===t?n(t):eL(t)?(e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),eV(e,a,"linePrefix")):(e.enter("chunkString",{contentType:"string"}),u(t))}function u(t){return t===l||null===t||eL(t)?(e.exit("chunkString"),a(t)):(e.consume(t),92===t?c:u)}function c(t){return t===l||92===t?(e.consume(t),u):u(t)}}function e7(e,t){let n;return function r(i){return eL(i)?(e.enter("lineEnding"),e.consume(i),e.exit("lineEnding"),n=!0,r):eF(i)?eV(e,r,n?"linePrefix":"lineSuffix")(i):t(i)}}function e8(e){return e.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}let te={tokenize:function(e,t,n){return function(t){return eM(t)?e7(e,r)(t):n(t)};function r(t){return e9(e,i,n,"definitionTitle","definitionTitleMarker","definitionTitleString")(t)}function i(t){return eF(t)?eV(e,o,"whitespace")(t):o(t)}function o(e){return null===e||eL(e)?t(e):n(e)}},partial:!0},tt={name:"codeIndented",tokenize:function(e,t,n){let r=this;
1return function(t){return e.enter("codeIndented"),eV(e,i,"linePrefix",5)(t)};function i(t){let i=r.events[r.events.length-1];return i&&"linePrefix"===i[1].type&&i[2].sliceSerialize(i[1],!0).length>=4?function t(n){return null===n?o(n):eL(n)?e.attempt(tn,t,o)(n):(e.enter("codeFlowValue"),function n(r){return null===r||eL(r)?(e.exit("codeFlowValue"),t(r)):(e.consume(r),n)}(n))}(t):n(t)}function o(n){return e.exit("codeIndented"),t(n)}}},tn={tokenize:function(e,t,n){let r=this;return i;function i(t){return r.parser.lazy[r.now().line]?n(t):eL(t)?(e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),i):eV(e,o,"linePrefix",5)(t)}function o(e){let o=r.events[r.events.length-1];return o&&"linePrefix"===o[1].type&&o[2].sliceSerialize(o[1],!0).length>=4?t(e):eL(e)?i(e):n(e)}},partial:!0},tr={name:"setextUnderline",tokenize:function(e,t,n){let r,i=this;return function(t){var l;let s,a=i.events.length;for(;a--;)if("lineEnding"!==i.events[a][1].type&&"linePrefix"!==i.events[a][1].type&&"content"!==i.events[a][1].type){s="paragraph"===i.events[a][1].type;break}return!i.parser.lazy[i.now().line]&&(i.interrupt||s)?(e.enter("setextHeadingLine"),r=t,l=t,e.enter("setextHeadingLineSequence"),function t(n){return n===r?(e.consume(n),t):(e.exit("setextHeadingLineSequence"),eF(n)?eV(e,o,"lineSuffix")(n):o(n))}(l)):n(t)};function o(r){return null===r||eL(r)?(e.exit("setextHeadingLine"),t(r)):n(r)}},resolveTo:function(e,t){let n,r,i,o=e.length;for(;o--;)if("enter"===e[o][0]){if("content"===e[o][1].type){n=o;break}"paragraph"===e[o][1].type&&(r=o)}else"content"===e[o][1].type&&e.splice(o,1),i||"definition"!==e[o][1].type||(i=o);let l={type:"setextHeading",start:Object.assign({},e[r][1].start),end:Object.assign({},e[e.length-1][1].end)};return e[r][1].type="setextHeadingText",i?(e.splice(r,0,["enter",l,t]),e.splice(i+1,0,["exit",e[n][1],t]),e[n][1].end=Object.assign({},e[i][1].end)):e[n][1]=l,e.push(["exit",l,t]),e}},ti=["address","article","aside","base","basefont","blockquote","body","caption","center","col","colgroup","dd","details","dialog","dir","div","dl","dt","fieldset","figcaption","figure","footer","form","frame","frameset","h1","h2","h3","h4","h5","h6","head","header","hr","html","iframe","legend","li","link","main","menu","menuitem","nav","noframes","ol","optgroup","option","p","param","search","section","summary","table","tbody","td","tfoot","th","thead","title","tr","track","ul"],to=["pre","script","style","textarea"],tl={tokenize:function(e,t,n){return function(r){return e.enter("lineEnding"),e.consume(r),e.exit("lineEnding"),e.attempt(eH,t,n)}},partial:!0},ts={tokenize:function(e,t,n){let r=this;return function(t){return eL(t)?(e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),i):n(t)};function i(e){return r.parser.lazy[r.now().line]?n(e):t(e)}},partial:!0},ta={tokenize:function(e,t,n){let r=this;return function(t){return null===t?n(t):(e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),i)};function i(e){return r.parser.lazy[r.now().line]?n(e):t(e)}},partial:!0},tu={name:"codeFenced",tokenize:function(e,t,n){let r,i=this,o={tokenize:function(e,t,n){let o=0;return function(t){return e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),l};function l(t){return e.enter("codeFencedFence"),eF(t)?eV(e,a,"linePrefix",i.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(t):a(t)}function a(t){return t===r?(e.enter("codeFencedFenceSequence"),function t(i){return i===r?(o++,e.consume(i),t):o>=s?(e.exit("codeFencedFenceSequence"),eF(i)?eV(e,u,"whitespace")(i):u(i)):n(i)}(t)):n(t)}function u(r){return null===r||eL(r)?(e.exit("codeFencedFence"),t(r)):n(r)}},partial:!0},l=0,s=0;return function(t){var o=t;let u=i.events[i.events.length-1];return l=u&&"linePrefix"===u[1].type?u[2].sliceSerialize(u[1],!0).length:0,r=o,e.enter("codeFenced"),e.enter("codeFencedFence"),e.enter("codeFencedFenceSequence"),function t(i){return i===r?(s++,e.consume(i),t):s<3?n(i):(e.exit("codeFencedFenceSequence"),eF(i)?eV(e,a,"whitespace")(i):a(i))}(o)};function a(o){return null===o||eL(o)?(e.exit("codeFencedFence"),i.interrupt?t(o):e.check(ta,c,f)(o)):(e.enter("co
1deFencedFenceInfo"),e.enter("chunkString",{contentType:"string"}),function t(i){return null===i||eL(i)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),a(i)):eF(i)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),eV(e,u,"whitespace")(i)):96===i&&i===r?n(i):(e.consume(i),t)}(o))}function u(t){return null===t||eL(t)?a(t):(e.enter("codeFencedFenceMeta"),e.enter("chunkString",{contentType:"string"}),function t(i){return null===i||eL(i)?(e.exit("chunkString"),e.exit("codeFencedFenceMeta"),a(i)):96===i&&i===r?n(i):(e.consume(i),t)}(t))}function c(t){return e.attempt(o,f,d)(t)}function d(t){return e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),h}function h(t){return l>0&&eF(t)?eV(e,p,"linePrefix",l+1)(t):p(t)}function p(t){return null===t||eL(t)?e.check(ta,c,f)(t):(e.enter("codeFlowValue"),function t(n){return null===n||eL(n)?(e.exit("codeFlowValue"),p(n)):(e.consume(n),t)}(t))}function f(n){return e.exit("codeFenced"),t(n)}},concrete:!0},tc=document.createElement("i");function td(e){let t="&"+e+";";tc.innerHTML=t;let n=tc.textContent;return(59!==n.charCodeAt(n.length-1)||"semi"===e)&&n!==t&&n}let th={name:"characterReference",tokenize:function(e,t,n){let r,i,o=this,l=0;return function(t){return e.enter("characterReference"),e.enter("characterReferenceMarker"),e.consume(t),e.exit("characterReferenceMarker"),s};function s(t){return 35===t?(e.enter("characterReferenceMarkerNumeric"),e.consume(t),e.exit("characterReferenceMarkerNumeric"),a):(e.enter("characterReferenceValue"),r=31,i=eP,u(t))}function a(t){return 88===t||120===t?(e.enter("characterReferenceMarkerHexadecimal"),e.consume(t),e.exit("characterReferenceMarkerHexadecimal"),e.enter("characterReferenceValue"),r=6,i=eI,u):(e.enter("characterReferenceValue"),r=7,i=e_,u(t))}function u(s){if(59===s&&l){let r=e.exit("characterReferenceValue");return i!==eP||td(o.sliceSerialize(r))?(e.enter("characterReferenceMarker"),e.consume(s),e.exit("characterReferenceMarker"),e.exit("characterReference"),t):n(s)}return i(s)&&l++<r?(e.consume(s),u):n(s)}}},tp={name:"characterEscape",tokenize:function(e,t,n){return function(t){return e.enter("characterEscape"),e.enter("escapeMarker"),e.consume(t),e.exit("escapeMarker"),r};function r(r){return eD(r)?(e.enter("characterEscapeValue"),e.consume(r),e.exit("characterEscapeValue"),e.exit("characterEscape"),t):n(r)}}},tf={name:"lineEnding",tokenize:function(e,t){return function(n){return e.enter("lineEnding"),e.consume(n),e.exit("lineEnding"),eV(e,t,"linePrefix")}}},tm={name:"labelEnd",tokenize:function(e,t,n){let r,i,o=this,l=o.events.length;for(;l--;)if(("labelImage"===o.events[l][1].type||"labelLink"===o.events[l][1].type)&&!o.events[l][1]._balanced){r=o.events[l][1];break}return function(t){return r?r._inactive?c(t):(i=o.parser.defined.includes(e8(o.sliceSerialize({start:r.end,end:o.now()}))),e.enter("labelEnd"),e.enter("labelMarker"),e.consume(t),e.exit("labelMarker"),e.exit("labelEnd"),s):n(t)};function s(t){return 40===t?e.attempt(tg,u,i?u:c)(t):91===t?e.attempt(tv,u,i?a:c)(t):i?u(t):c(t)}function a(t){return e.attempt(ty,u,c)(t)}function u(e){return t(e)}function c(e){return r._balanced=!0,n(e)}},resolveTo:function(e,t){let n,r,i,o,l=e.length,s=0;for(;l--;)if(n=e[l][1],r){if("link"===n.type||"labelLink"===n.type&&n._inactive)break;"enter"===e[l][0]&&"labelLink"===n.type&&(n._inactive=!0)}else if(i){if("enter"===e[l][0]&&("labelImage"===n.type||"labelLink"===n.type)&&!n._balanced&&(r=l,"labelLink"!==n.type)){s=2;break}}else"labelEnd"===n.type&&(i=l);let a={type:"labelLink"===e[r][1].type?"link":"image",start:Object.assign({},e[r][1].start),end:Object.assign({},e[e.length-1][1].end)},u={type:"label",start:Object.assign({},e[r][1].start),end:Object.assign({},e[i][1].end)},c={type:"labelText",start:Object.assign({},e[r+s+2][1].end),end:Object.assign({},e[i-2][1].start)};return o=ew(o=[["enter",a,t],["enter",u,t]],e.slice(r+1,r+s+3)),o=ew(o,[["enter",c,t]]),o=ew(o,eQ(t.parser.constructs.insideSpan.null,e.slice(r+s+4,i-3),t)),o=ew(o,[["exit",c,t],e[i-2],e[i-1],["exit",u,t]]),o=ew(o,e.slice(i+1)),o=ew(o,[["exit",a,t]]),eb(e,r,e.length,o),e},resolveAll:function(e){let t=-1;for(;++t<e.length;){let n=e[t][1];("labelImage"===n.type||"labelLink"===n.type||"labelEnd"===n.type)&&(e.splice(t+1,"labelImage"===n.type?4:2),n.type="data",t++)}return e}},tg={tokenize:function(e,t,n){return function(t){return e.enter("resource"),e.enter("resourceMarker"),e.consume(t),e.exit("resourceMarker"),r};function r(t){return eM(t)?e7(e,i)(t):i(t)}function i(t){return 41===t?u(t):e5(e,o,l,"resourceDestination","resourceDestinationLiteral","resourceDestinationLiteralMarker","resourceDestinationRaw","resourceDestinationString",32)(t)}function o(t){return eM(t)?e7(e,s)(t):u(t)}function l(e){return n(e)}function s(t){return 34===t||39===t||40===t?e9(e,a,n,"resourceTitle","resourceTitleMarker","resourceTitleString")(t):u(t)}function a(t){return eM(t)?e7(e,u)(t):u(t)}function u(r){return 41===r?(e.enter("resourceMarker"),e.consume(r),e.exit("resourceMarker"),e.exit("resource"),t):n(r)}}},tv={tokenize:function(e,t,n){let r=this;return function(t){return e6.call(r,e,i,o,"reference","referenceMarker","referenceString")(t)};function i(e){return r.parser.defined.includes(e8(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)))?t(e):n(e)}function o(e){return n(e)}}},ty={tokenize:function(e,t,n){return function(t){return e.enter("reference"),e.enter("referenceMarker"),e.consume(t),e.exit("referenceMarker"),r};function r(r){return 93===r?(e.enter("referenceMarker"),e.consume(r),e.exit("referenceMarker"),e.exit("reference"),t):n(r)}}},tx={name:"labelStartImage",tokenize:function(e,t,n){let r=this;return function(t){return e.enter("labelImage"),e.enter("labelImageMarker"),e.consume(t),e.exit("labelImageMarker"),i};function i(t){return 91===t?(e.enter("labelMarker"),e.consume(t),e.exit("labelMarker"),e.exit("labelImage"),o):n(t)}function o(e){return 94===e&&"_hiddenFootnoteSupport"in r.parser.constructs?n(e):t(e)}},resolveAll:tm.resolveAll};function tb(e){return null===e||eM(e)||ej(e)?1:eO(e)?2:void 0}let tw={name:"attention",tokenize:function(e,t){let n,r=this.parser.constructs.attentionMarkers.null,i=this.previous,o=tb(i);return function(l){return n=l,e.enter("attentionSequence"),function l(s){if(s===n)return e.consume(s),l;let a=e.exit("attentionSequence"),u=tb(s),c=!u||2===u&&o||r.includes(s),d=!o||2===o&&u||r.includes(i);return a._open=!!(42===n?c:c&&(o||!d)),a._close=!!(42===n?d:d&&(u||!c)),t(s)}(l)}},resolveAll:function(e,t){let n,r,i,o,l,s,a,u,c=-1;for(;++c<e.length;)if("enter"===e[c][0]&&"attentionSequence"===e[c][1].type&&e[c][1]._close){for(n=c;n--;)if("exit"===e[n][0]&&"attentionSequence"===e[n][1].type&&e[n][1]._open&&t.sliceSerialize(e[
1n][1]).charCodeAt(0)===t.sliceSerialize(e[c][1]).charCodeAt(0)){if((e[n][1]._close||e[c][1]._open)&&(e[c][1].end.offset-e[c][1].start.offset)%3&&!((e[n][1].end.offset-e[n][1].start.offset+e[c][1].end.offset-e[c][1].start.offset)%3))continue;s=e[n][1].end.offset-e[n][1].start.offset>1&&e[c][1].end.offset-e[c][1].start.offset>1?2:1;let d=Object.assign({},e[n][1].end),h=Object.assign({},e[c][1].start);tE(d,-s),tE(h,s),o={type:s>1?"strongSequence":"emphasisSequence",start:d,end:Object.assign({},e[n][1].end)},l={type:s>1?"strongSequence":"emphasisSequence",start:Object.assign({},e[c][1].start),end:h},i={type:s>1?"strongText":"emphasisText",start:Object.assign({},e[n][1].end),end:Object.assign({},e[c][1].start)},r={type:s>1?"strong":"emphasis",start:Object.assign({},o.start),end:Object.assign({},l.end)},e[n][1].end=Object.assign({},o.start),e[c][1].start=Object.assign({},l.end),a=[],e[n][1].end.offset-e[n][1].start.offset&&(a=ew(a,[["enter",e[n][1],t],["exit",e[n][1],t]])),a=ew(a,[["enter",r,t],["enter",o,t],["exit",o,t],["enter",i,t]]),a=ew(a,eQ(t.parser.constructs.insideSpan.null,e.slice(n+1,c),t)),a=ew(a,[["exit",i,t],["enter",l,t],["exit",l,t],["exit",r,t]]),e[c][1].end.offset-e[c][1].start.offset?(u=2,a=ew(a,[["enter",e[c][1],t],["exit",e[c][1],t]])):u=0,eb(e,n-1,c-n+3,a),c=n+a.length-u-2;break}}for(c=-1;++c<e.length;)"attentionSequence"===e[c][1].type&&(e[c][1].type="data");return e}};function tE(e,t){e.column+=t,e.offset+=t,e._bufferIndex+=t}let tk={name:"labelStartLink",tokenize:function(e,t,n){let r=this;return function(t){return e.enter("labelLink"),e.enter("labelMarker"),e.consume(t),e.exit("labelMarker"),e.exit("labelLink"),i};function i(e){return 94===e&&"_hiddenFootnoteSupport"in r.parser.constructs?n(e):t(e)}},resolveAll:tm.resolveAll},tS={42:e1,43:e1,45:e1,48:e1,49:e1,50:e1,51:e1,52:e1,53:e1,54:e1,55:e1,56:e1,57:e1,62:e3},tT={91:{name:"definition",tokenize:function(e,t,n){let r,i=this;return function(t){var r;return e.enter("definition"),r=t,e6.call(i,e,o,n,"definitionLabel","definitionLabelMarker","definitionLabelString")(r)};function o(t){return(r=e8(i.sliceSerialize(i.events[i.events.length-1][1]).slice(1,-1)),58===t)?(e.enter("definitionMarker"),e.consume(t),e.exit("definitionMarker"),l):n(t)}function l(t){return eM(t)?e7(e,s)(t):s(t)}function s(t){return e5(e,a,n,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(t)}function a(t){return e.attempt(te,u,u)(t)}function u(t){return eF(t)?eV(e,c,"whitespace")(t):c(t)}function c(o){return null===o||eL(o)?(e.exit("definition"),i.parser.defined.push(r),t(o)):n(o)}}}},tC={[-2]:tt,[-1]:tt,32:tt},tP={35:{name:"headingAtx",tokenize:function(e,t,n){let r=0;return function(i){var o;return e.enter("atxHeading"),o=i,e.enter("atxHeadingSequence"),function i(o){return 35===o&&r++<6?(e.consume(o),i):null===o||eM(o)?(e.exit("atxHeadingSequence"),function n(r){return 35===r?(e.enter("atxHeadingSequence"),function t(r){return 35===r?(e.consume(r),t):(e.exit("atxHeadingSequence"),n(r))}(r)):null===r||eL(r)?(e.exit("atxHeading"),t(r)):eF(r)?eV(e,n,"whitespace")(r):(e.enter("atxHeadingText"),function t(r){return null===r||35===r||eM(r)?(e.exit("atxHeadingText"),n(r)):(e.consume(r),t)}(r))}(o)):n(o)}(o)}},resolve:function(e,t){let n,r,i=e.length-2,o=3;return"whitespace"===e[3][1].type&&(o+=2),i-2>o&&"whitespace"===e[i][1].type&&(i-=2),"atxHeadingSequence"===e[i][1].type&&(o===i-1||i-4>o&&"whitespace"===e[i-2][1].type)&&(i-=o+1===i?2:4),i>o&&(n={type:"atxHeadingText",start:e[o][1].start,end:e[i][1].end},r={type:"chunkText",start:e[o][1].start,end:e[i][1].end,contentType:"text"},eb(e,o,i-o+1,[["enter",n,t],["enter",r,t],["exit",r,t],["exit",n,t]])),e}},42:e0,45:[tr,e0],60:{name:"htmlFlow",tokenize:function(e,t,n){let r,i,o,l,s,a=this;return function(t){var n;return n=t,e.enter("htmlFlow"),e.enter("htmlFlowData"),e.consume(n),u};function u(l){return 33===l?(e.consume(l),c):47===l?(e.consume(l),i=!0,p):63===l?(e.consume(l),r=3,a.interrupt?t:D):eC(l)?(e.consume(l),o=String.fromCharCode(l),f):n(l)}function c(i){return 45===i?(e.consume(i),r=2,d):91===i?(e.consume(i),r=5,l=0,h):eC(i)?(e.consume(i),r=4,a.interrupt?t:D):n(i)}function d(r){return 45===r?(e.consume(r),a.interrupt?t:D):n(r)}function h(r){let i="CDATA[";return r===i.charCodeAt(l++)?(e.consume(r),l===i.length)?a.interrupt?t:S:h:n(r)}function p(t){return eC(t)?(e.consume(t),o=String.fromCharCode(t),f):n(t)}function f(l){if(null===l||47===l||62===l||eM(l)){let s=47===l,u=o.toLowerCase();return!s&&!i&&to.includes(u)?(r=1,a.interrupt?t(l):S(l)):ti.includes(o.toLowerCase())?(r=6,s)?(e.consume(l),m):a.interrupt?t(l):S(l):(r=7,a.interrupt&&!a.parser.lazy[a.now().line]?n(l):i?function t(n){return eF(n)?(e.consume(n),t):E(n)}(l):g(l))}return 45===l||eP(l)?(e.consume(l),o+=String.fromCharCode(l),f):n(l)}function m(r){return 62===r?(e.consume(r),a.interrupt?t:S):n(r)}function g(t){return 47===t?(e.consume(t),E):58===t||95===t||eC(t)?(e.consume(t),v):eF(t)?(e.consume(t),g):E(t)}function v(t){return 45===t||46===t||58===t||95===t||eP(t)?(e.consume(t),v):y(t)}function y(t){return 61===t?(e.consume(t),x):eF(t)?(e.consume(t),y):g(t)}function x(t){return null===t||60===t||61===t||62===t||96===t?n(t):34===t||39===t?(e.consume(t),s=t,b):eF(t)?(e.consume(t),x):function t(n){return null===n||34===n||39===n||47===n||60===n||61===n||62===n||96===n||eM(n)?y(n):(e.consume(n),t)}(t)}function b(t){return t===s?(e.consume(t),s=null,w):null===t||eL(t)?n(t):(e.consume(t),b)}function w(e){return 47===e||62===e||eF(e)?g(e):n(e)}function E(t){return 62===t?(e.consume(t),k):n(t)}function k(t){return null===t||eL(t)?S(t):eF(t)?(e.consume(t),k):n(t)}function S(t){return 45===t&&2===r?(e.consume(t),A):60===t&&1===r?(e.consume(t),R):62===t&&4===r?(e.consume(t),L):63===t&&3===r?(e.consume(t),D):93===t&&5===r?(e.consume(t),I):eL(t)&&(6===r||7===r)?(e.exit("htmlFlowData"),e.check(tl,M,T)(t)):null===t||eL(t)?(e.exit("htmlFlowData"),T(t)):(e.consume(t),S)}function T(t){return e.check(ts,C,M)(t)}function C(t){return e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),P}function P(t){return null===t||eL(t)?T(t):(e.enter("htmlFlowData"),S(t))}function A(t){return 45===t?(e.consume(t),D):S(t)}function R(t){return 47===t?(e.consume(t),o="",_):S(t)}function _(t){if(62===t){let n=o.toLowerCase();return to.includes(n)?(e.consume(t),L):S(t)}return eC(t)&&o.length<8?(e.consume(t),o+=String.fromCharCode(t),_):S(t)}function I(t){return 93===t?(e.consume(t),D):S(t)}function D(t){return 62===t?(e.consume(t),L):45===t&&2===r?(e.consume(t),D):S(t)}function L(t){return null===t||eL(t)?(e.exit("htmlFlowData"),M(t)):(e.consume(t),L)}function M(n){return e.exit("htmlFlow"),t(n)}},resolveTo:function(e){let t=e.length;for(;t--&&("enter"!==e[t][0]||"htmlFlow"!==e[t][1].type););return t>1&&"linePrefix"===e[t-2][1].type&&(e[t][1].start=e[t-2][1].start,e[t+1][1].start=e[t-2][1].start,e.splice(t-2,2)),e},concrete:!0},61:tr,95:e0,96:tu,126:tu},tA={38:th,92:tp},tR={[-5]:tf,[-4]:tf,[-3]:tf,33:tx,38:th,42:tw,60:[{name:"autolink",tokenize:function(e,t,n){let r=0;return function(t){return e.enter("autolink"),e.enter("autolinkMarker"),e.consume(t),e.exit("autolinkMarker"),e.enter("autolinkProtocol"),i};function i(t){return eC(t)?(e.consume(t),o):64===t?n(t):s(t)}function o(t){return 43===t||45===t||46===t||eP(t)?(r=1,function t(n){return 58===n?(e.consume(n),r=0,l):(43===n||45===n||46===n||eP(n))&&r++<32?(e.consume(n),t):(r=0,s(n))}(t)):s(t)}function l(r){return 62===r?(e.exit("autolinkProtocol"),e.enter("autolinkMarker"),e.consume(r),e.exit("autolinkMarker"),e.exit("autolink"),t):null===r||32===r||60===r||eR(r)?n(r):(e.consume(r),l)}function s(t){return 64===t?(e.consume(t),a):eA(t)?(e.consume(t),s):n(t)}function a(i){return eP(i)?function i(o){return 46===o?(e.consume(o),r=0,a):62===o?(e.exit("autolinkProtocol").type="autolinkEmail",e.enter("autolinkMarker"),e.consume(o),e.exit("autolinkMarker"),e.exit("autolink"),t):function t(o){if((45===o||eP(o))&&r++<63){let n=45===o?t:i;return e.consume(o),n}return n(o)}(o)}(i):n(i)}}},{name:"htmlText",tokenize:function(e,t,n){let r,i,o,l=this;return function(t){return e.enter("htmlText"),e.enter("htmlTextData"),e.consume(t),s};function s(t){return 33===t?(e.consume(t),a):47===t?(e.consume(t),b):63===t?(e.consume(t),y):eC(t)?(e.consume(t),E):n(t)}function a(t){return 45===t?(e.consume(t),u):91===t?(e.consume(t),i=0,p):eC(t)?(e.consume(t),v):n(t)}function u(t){return 45===t?(e.consume(t),h):n(t)}function c(t){return null===t?n(t):45===t?(e.consume(t),d):eL(t)?(o=c,_(t)):(e.consume(t),c)}function d(t){return 45===t?(e.consume(t),h):c(t)}function h(e){return 62===e?R(e):45===e?d(e):c(e)}function p(t){let r="CDATA[";return t===r.charCodeAt(i++)?(e.consume(t),i===r.length?f:p):n(t)}function f(t){return null===t?n(t):93===t?(e.consume(t),m):eL(t)?(o=f,_(t)):(e.consume(t),f)}function m(t){return 93===t?(e.consume(t),g):f(t)}function g(t){return 62===t?R(t):93===t?(e.consume(t),g):f(t)}function v(t){return null===t||62===t?R(t):eL(t)?(o=v,_(t)):(e.consume(t),v)}function y(t){return null===t?n(t):63===t?(e.consume(t),x):eL(t)?(o=y,_(t)):(e.consume(t),y)}function x(e){return 62===e?R(e):y(e)}function b(t){return eC(t)?(e.consume(t),w):n(t)}function w(t){return 45===t||eP(t)?(e.consume(t),w):function t(n){return eL(n)?(o=t,_(n)):eF(n)?(e.consume(n),t):R(n)}(t)}function E(t){return 45===t||eP(t)?(e.consume(t),E):47===t||62===t||eM(t)?k(t):n(t)}function k(t){return 47===t?(e.consume(t),R):58===t||95===t||eC(t)?(e.consume(t),S):eL(t)?(o=k,_(t)):eF(t)?(e.consume(t),k):R(t)}function S(t){return 45===t||46===t||58===t||95===t||eP(t)?(e.consume(t),S):function t(n){return 61===n?(e.consume(n),T):eL(n)?(o=t,_(n)):eF(n)?(e.consume(n),t):k(n)}(t)}function T(t){return null===t||60===t||61===t||62===t||96===t?n(t):34===t||39===t?(e.consume(t),r=t,C):eL(t)?(o=T,_(t)):eF(t)?(e.consume(t),T):(e.consume(t),P)}function C(t){return t===r?(e.consume(t),r=void 0,A):null===t?n(t):eL(t)?(o=C,_(t)):(e.consume(t),C)}function P(t){return null===t||34===t||39===t||60===t||61===t||96===t?n(t):47===t||62===t||eM(t)?k(t):(e.consume(t),P)}function A(e){return 47===e||62===e||eM(e)?k(e):n(e)}function R(r){return 62===r?(e.consume(r),e.exit("htmlTextData"),e.exit("htmlText"),t):n(r)}function _(t){return e.exit("htmlTextData"),e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),I}function I(t){return eF(t)?eV(e,D,"linePrefix",l.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(t):D(t)}function D(t){return e.enter("htmlTextData"),o(t)}}}],91:tk,92:[{name:"hardBreakEscape",tokenize:function(e,t,n){return function(t){return e.enter("hardBreakEscape"),e.consume(t),r};function r(r){return eL(r)?(e.exit("hardBreakEscape"),t(r)):n(r)}}},tp],93:tm,95:tw,96:{name:"codeText",tokenize:function(e,t,n){let r,i,o=0;
1return function(t){return e.enter("codeText"),e.enter("codeTextSequence"),function t(n){return 96===n?(e.consume(n),o++,t):(e.exit("codeTextSequence"),l(n))}(t)};function l(a){return null===a?n(a):32===a?(e.enter("space"),e.consume(a),e.exit("space"),l):96===a?(i=e.enter("codeTextSequence"),r=0,function n(l){return 96===l?(e.consume(l),r++,n):r===o?(e.exit("codeTextSequence"),e.exit("codeText"),t(l)):(i.type="codeTextData",s(l))}(a)):eL(a)?(e.enter("lineEnding"),e.consume(a),e.exit("lineEnding"),l):(e.enter("codeTextData"),s(a))}function s(t){return null===t||32===t||96===t||eL(t)?(e.exit("codeTextData"),l(t)):(e.consume(t),s)}},resolve:function(e){let t,n,r=e.length-4,i=3;if(("lineEnding"===e[3][1].type||"space"===e[i][1].type)&&("lineEnding"===e[r][1].type||"space"===e[r][1].type)){for(t=i;++t<r;)if("codeTextData"===e[t][1].type){e[i][1].type="codeTextPadding",e[r][1].type="codeTextPadding",i+=2,r-=2;break}}for(t=i-1,r++;++t<=r;)void 0===n?t!==r&&"lineEnding"!==e[t][1].type&&(n=t):(t===r||"lineEnding"===e[t][1].type)&&(e[n][1].type="codeTextData",t!==n+2&&(e[n][1].end=e[t-1][1].end,e.splice(n+2,t-n-2),r-=t-n-2,t=n+2),n=void 0);return e},previous:function(e){return 96!==e||"characterEscape"===this.events[this.events.length-1][1].type}}},t_={null:[tw,eG]},tI={null:[42,95]},tD={null:[]},tL=/[\0\t\n\r]/g;function tM(e,t){let n=Number.parseInt(e,t);return n<9||11===n||n>13&&n<32||n>126&&n<160||n>55295&&n<57344||n>64975&&n<65008||(65535&n)==65535||(65535&n)==65534||n>1114111?"�":String.fromCodePoint(n)}let tF=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function tO(e,t,n){if(t)return t;if(35===n.charCodeAt(0)){let e=n.charCodeAt(1),t=120===e||88===e;return tM(n.slice(t?2:1),t?16:10)}return td(n)||e}let tj={}.hasOwnProperty;function tN(e){return{line:e.line,column:e.column,offset:e.offset}}function tV(e,t){if(e)throw Error("Cannot close `"+e.type+"` ("+X({start:e.start,end:e.end})+"): a different token (`"+t.type+"`, "+X({start:t.start,end:t.end})+") is open");throw Error("Cannot close document, a token (`"+t.type+"`, "+X({start:t.start,end:t.end})+") is still open")}function tB(e){let t=this;t.parser=function(n){var r,o;let l,s,a,u;return"string"!=typeof(r={...t.data("settings"),...e,extensions:t.data("micromarkExtensions")||[],mdastExtensions:t.data("fromMarkdownExtensions")||[]})&&(o=r,r=void 0),(function(e){let t={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:r(v),autolinkProtocol:u,autolinkEmail:u,atxHeading:r(f),blockQuote:r(function(){return{type:"blockquote",children:[]}}),characterEscape:u,characterReference:u,codeFenced:r(p),codeFencedFenceInfo:i,codeFencedFenceMeta:i,codeIndented:r(p,i),codeText:r(function(){return{type:"inlineCode",value:""}},i),codeTextData:u,data:u,codeFlowValue:u,definition:r(function(){return{type:"definition",identifier:"",label:null,title:null,url:""}}),definitionDestinationString:i,definitionLabelString:i,definitionTitleString:i,emphasis:r(function(){return{type:"emphasis",children:[]}}),hardBreakEscape:r(m),hardBreakTrailing:r(m),htmlFlow:r(g,i),htmlFlowData:u,htmlText:r(g,i),htmlTextData:u,image:r(function(){return{type:"image",title:null,url:"",alt:null}}),label:i,link:r(v),listItem:r(function(e){return{type:"listItem",spread:e._spread,checked:null,children:[]}}),listItemValue:function(e){this.data.expectingFirstListItemValue&&(this.stack[this.stack.length-2].start=Number.parseInt(this.sliceSerialize(e),10),this.data.expectingFirstListItemValue=void 0)},listOrdered:r(y,function(){this.data.expectingFirstListItemValue=!0}),listUnordered:r(y),paragraph:r(function(){return{type:"paragraph",children:[]}}),reference:function(){this.data.referenceType="collapsed"},referenceString:i,resourceDestinationString:i,resourceTitleString:i,setextHeading:r(f),strong:r(function(){return{type:"strong",children:[]}}),thematicBreak:r(function(){return{type:"thematicBreak"}})},exit:{atxHeading:l(),atxHeadingSequence:function(e){let t=this.stack[this.stack.length-1];t.depth||(t.depth=this.sliceSerialize(e).length)},autolink:l(),autolinkEmail:function(e){c.call(this,e),this.stack[this.stack.length-1].url="mailto:"+this.sliceSerialize(e)},autolinkProtocol:function(e){c.call(this,e),this.stack[this.stack.length-1].url=this.sliceSerialize(e)},blockQuote:l(),characterEscapeValue:c,characterReferenceMarkerHexadecimal:h,characterReferenceMarkerNumeric:h,characterReferenceValue:function(e){let t,n=this.sliceSerialize(e),r=this.data.characterReferenceType;r?(t=tM(n,"characterReferenceMarkerNumeric"===r?10:16),this.data.characterReferenceType=void 0):t=td(n);let i=this.stack[this.stack.length-1];i.value+=t},characterReference:function(e){this.stack.pop().position.end=tN(e.end)},codeFenced:l(function(){let e=this.resume();this.stack[this.stack.length-1].value=e.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,""),this.data.flowCodeInside=void 0}),codeFencedFence:function(){this.data.flowCodeInside||(this.buffer(),this.data.flowCodeInside=!0)},codeFencedFenceInfo:function(){let e=this.resume();this.stack[this.stack.length-1].lang=e},codeFencedFenceMeta:function(){let e=this.resume();this.stack[this.stack.length-1].meta=e},codeFlowValue:c,codeIndented:l(function(){let e=this.resume();this.stack[this.stack.length-1].value=e.replace(/(\r?\n|\r)$/g,"")}),codeText:l(function(){let e=this.resume();this.stack[this.stack.length-1].value=e}),codeTextData:c,data:c,definition:l(),definitionDestinationString:function(){let e=this.resume();this.stack[this.stack.length-1].url=e},definitionLabelString:function(e){let t=this.resume(),n=this.stack[this.stack.length-1];n.label=t,n.identifier=e8(this.sliceSerialize(e)).toLowerCase()},definitionTitleString:function(){let e=this.resume();this.stack[this.stack.length-1].title=e},emphasis:l(),hardBreakEscape:l(d),hardBreakTrailing:l(d),htmlFlow:l(function(){let e=this.resume();this.stack[this.stack.length-1].value=e}),htmlFlowData:c,htmlText:l(function(){let e=this.resume();this.stack[this.stack.length-1].value=e}),htmlTextData:c,image:l(function(){let e=this.stack[this.stack.length-1];if(this.data.inReference){let t=this.data.referenceType||"shortcut";e.type+="Reference",e.referenceType=t,delete e.url,delete e.title}else delete e.identifier,delete e.label;this.data.referenceType=void 0}),label:function(){let e=this.stack[this.stack.length-1],t=this.resume(),n=this.stack[this.stack.length-1];this.data.inReference=!0,"link"===n.type?n.children=e.children:n.alt=t},labelText:function(e){let t=this.sliceSerialize(e),n=this.stack[this.stack.length-2];n.label=t.replace(tF,tO),n.identifier=e8(t).toLowerCase()},lineEnding:function(e){let n=this.stack[this.stack.length-1];if(this.data.atHardBreak){n.children[n.children.length-1].position.end=tN(e.end),this.data.atHardBreak=void 0;return}!this.data.setextHeadingSlurpLineEnding&&t.canContainEols.includes(n.t
1ype)&&(u.call(this,e),c.call(this,e))},link:l(function(){let e=this.stack[this.stack.length-1];if(this.data.inReference){let t=this.data.referenceType||"shortcut";e.type+="Reference",e.referenceType=t,delete e.url,delete e.title}else delete e.identifier,delete e.label;this.data.referenceType=void 0}),listItem:l(),listOrdered:l(),listUnordered:l(),paragraph:l(),referenceString:function(e){let t=this.resume(),n=this.stack[this.stack.length-1];n.label=t,n.identifier=e8(this.sliceSerialize(e)).toLowerCase(),this.data.referenceType="full"},resourceDestinationString:function(){let e=this.resume();this.stack[this.stack.length-1].url=e},resourceTitleString:function(){let e=this.resume();this.stack[this.stack.length-1].title=e},resource:function(){this.data.inReference=void 0},setextHeading:l(function(){this.data.setextHeadingSlurpLineEnding=void 0}),setextHeadingLineSequence:function(e){this.stack[this.stack.length-1].depth=61===this.sliceSerialize(e).codePointAt(0)?1:2},setextHeadingText:function(){this.data.setextHeadingSlurpLineEnding=!0},strong:l(),thematicBreak:l()}};!function e(t,n){let r=-1;for(;++r<n.length;){let i=n[r];Array.isArray(i)?e(t,i):function(e,t){let n;for(n in t)if(tj.call(t,n))switch(n){case"canContainEols":{let r=t[n];r&&e[n].push(...r);break}case"transforms":{let r=t[n];r&&e[n].push(...r);break}case"enter":case"exit":{let r=t[n];r&&Object.assign(e[n],r)}}}(t,i)}}(t,(e||{}).mdastExtensions||[]);let n={};return function(e){let r={type:"root",children:[]},l={stack:[r],tokenStack:[],config:t,enter:o,exit:s,buffer:i,resume:a,data:n},u=[],c=-1;for(;++c<e.length;)("listOrdered"===e[c][1].type||"listUnordered"===e[c][1].type)&&("enter"===e[c][0]?u.push(c):c=function(e,t,n){let r,i,o,l,s=t-1,a=-1,u=!1;for(;++s<=n;){let t=e[s];switch(t[1].type){case"listUnordered":case"listOrdered":case"blockQuote":"enter"===t[0]?a++:a--,l=void 0;break;case"lineEndingBlank":"enter"===t[0]&&(!r||l||a||o||(o=s),l=void 0);break;case"linePrefix":case"listItemValue":case"listItemMarker":case"listItemPrefix":case"listItemPrefixWhitespace":break;default:l=void 0}if(!a&&"enter"===t[0]&&"listItemPrefix"===t[1].type||-1===a&&"exit"===t[0]&&("listUnordered"===t[1].type||"listOrdered"===t[1].type)){if(r){let l=s;for(i=void 0;l--;){let t=e[l];if("lineEnding"===t[1].type||"lineEndingBlank"===t[1].type){if("exit"===t[0])continue;i&&(e[i][1].type="lineEndingBlank",u=!0),t[1].type="lineEnding",i=l}else if("linePrefix"===t[1].type||"blockQuotePrefix"===t[1].type||"blockQuotePrefixWhitespace"===t[1].type||"blockQuoteMarker"===t[1].type||"listItemIndent"===t[1].type);else break}o&&(!i||o<i)&&(r._spread=!0),r.end=Object.assign({},i?e[i][1].start:t[1].end),e.splice(i||s,0,["exit",r,t[2]]),s++,n++}if("listItemPrefix"===t[1].type){let i={type:"listItem",_spread:!1,start:Object.assign({},t[1].start),end:void 0};r=i,e.splice(s,0,["enter",i,t[2]]),s++,n++,o=void 0,l=!0}}}return e[t][1]._spread=u,n}(e,u.pop(),c));for(c=-1;++c<e.length;){let n=t[e[c][0]];tj.call(n,e[c][1].type)&&n[e[c][1].type].call(Object.assign({sliceSerialize:e[c][2].sliceSerialize},l),e[c][1])}if(l.tokenStack.length>0){let e=l.tokenStack[l.tokenStack.length-1];(e[1]||tV).call(l,void 0,e[0])}for(r.position={start:tN(e.length>0?e[0][1].start:{line:1,column:1,offset:0}),end:tN(e.length>0?e[e.length-2][1].end:{line:1,column:1,offset:0})},c=-1;++c<t.transforms.length;)r=t.transforms[c](r)||r;return r};function r(e,t){return function(n){o.call(this,e(n),n),t&&t.call(this,n)}}function i(){this.stack.push({type:"fragment",children:[]})}function o(e,t,n){this.stack[this.stack.length-1].children.push(e),this.stack.push(e),this.tokenStack.push([t,n||void 0]),e.position={start:tN(t.start),end:void 0}}function l(e){return function(t){e&&e.call(this,t),s.call(this,t)}}function s(e,t){let n=this.stack.pop(),r=this.tokenStack.pop();if(r)r[0].type!==e.type&&(t?t.call(this,e,r[0]):(r[1]||tV).call(this,e,r[0]));else throw Error("Cannot close `"+e.type+"` ("+X({start:e.start,end:e.end})+"): it’s not open");n.position.end=tN(e.end)}function a(){return ey(this.stack.pop(),"boolean"!=typeof ev.includeImageAlt||ev.includeImageAlt,"boolean"!=typeof ev.includeHtml||ev.includeHtml)}function u(e){let t=this.stack[this.stack.length-1].children,n=t[t.length-1];n&&"text"===n.type||((n={type:"text",value:""}).position={start:tN(e.start),end:void 0},t.push(n)),this.stack.push(n)}function c(e){let t=this.stack.pop();t.value+=this.sliceSerialize(e),t.position.end=tN(e.end)}function d(){this.data.atHardBreak=!0}function h(e){this.data.characterReferenceType=e.type}function p(){return{type:"code",lang:null,meta:null,value:""}}function f(){return{type:"heading",depth:0,children:[]}}function m(){return{type:"break"}}function g(){return{type:"html",value:""}}function v(){return{type:"link",title:null,url:"",children:[]}}function y(e){return{type:"list",ordered:"listOrdered"===e.type,start:null,spread:e._spread,children:[]}}})(o)(function(e){for(;!eS(e););return e}((function(e){let t={defined:[],lazy:{},constructs:function(e){let t={},n=-1;for(;++n<e.length;)!function(e,t){let n;for(n in t){let r,i=(eT.call(e,n)?e[n]:void 0)||(e[n]={}),o=t[n];if(o)for(r in o){eT.call(i,r)||(i[r]=[]);let e=o[r];!function(e,t){let n=-1,r=[];for(;++n<t.length;)("after"===t[n].add?e:r).push(t[n]);eb(e,0,0,r)}(i[r],Array.isArray(e)?e:e?[e]:[])}}}(t,e[n]);return t}([i,...(e||{}).extensions||[]]),content:n(eB),document:n(eU),flow:n(eY),string:n(e$),text:n(eX)};return t;function n(e){return function(n){return function(e,t,n){let r=Object.assign(n?Object.assign({},n):{line:1,column:1,offset:0},{_index:0,_bufferIndex:-1}),i={},o=[],l=[],s=[],a={consume:function(e){eL(e)?(r.line++,r.column=1,r.offset+=-3===e?2:1,g()):-1!==e&&(r.column++,r.offset++),r._bufferIndex<0?r._index++:(r._bufferIndex++,r._bufferIndex===l[r._index].length&&(r._bufferIndex=-1,r._index++)),u.previous=e}
1,enter:function(e,t){let n=t||{};return n.type=e,n.start=h(),u.events.push(["enter",n,u]),s.push(n),n},exit:function(e){let t=s.pop();return t.end=h(),u.events.push(["exit",t,u]),t},attempt:f(function(e,t){m(e,t.from)}),check:f(p),interrupt:f(p,{interrupt:!0})},u={previous:null,code:null,containerState:{},events:[],parser:e,sliceStream:d,sliceSerialize:function(e,t){return function(e,t){let n,r=-1,i=[];for(;++r<e.length;){let o,l=e[r];if("string"==typeof l)o=l;else switch(l){case -5:o="\r";break;case -4:o="\n";break;case -3:o="\r\n";break;case -2:o=t?" ":"	";break;case -1:if(!t&&n)continue;o=" ";break;default:o=String.fromCharCode(l)}n=-2===l,i.push(o)}return i.join("")}(d(e),t)},now:h,defineSkip:function(e){i[e.line]=e.column,g()},write:function(e){return(l=ew(l,e),function(){let e;for(;r._index<l.length;){let n=l[r._index];if("string"==typeof n)for(e=r._index,r._bufferIndex<0&&(r._bufferIndex=0);r._index===e&&r._bufferIndex<n.length;){var t;t=n.charCodeAt(r._bufferIndex),c=c(t)}else c=c(n)}}(),null!==l[l.length-1])?[]:(m(t,0),u.events=eQ(o,u.events,u),u.events)}},c=t.tokenize.call(u,a);return t.resolveAll&&o.push(t),u;function d(e){return function(e,t){let n,r=t.start._index,i=t.start._bufferIndex,o=t.end._index,l=t.end._bufferIndex;if(r===o)n=[e[r].slice(i,l)];else{if(n=e.slice(r,o),i>-1){let e=n[0];"string"==typeof e?n[0]=e.slice(i):n.shift()}l>0&&n.push(e[o].slice(0,l))}return n}(l,e)}function h(){let{line:e,column:t,offset:n,_index:i,_bufferIndex:o}=r;return{line:e,column:t,offset:n,_index:i,_bufferIndex:o}}function p(e,t){t.restore()}function f(e,t){return function(n,i,o){var l;let c,d,p,f;return Array.isArray(n)?m(n):"tokenize"in n?m([n]):(l=n,function(e){let t=null!==e&&l[e],n=null!==e&&l.null;return m([...Array.isArray(t)?t:t?[t]:[],...Array.isArray(n)?n:n?[n]:[]])(e)});function m(e){return(c=e,d=0,0===e.length)?o:v(e[d])}function v(e){return function(n){return(f=function(){let e=h(),t=u.previous,n=u.currentConstruct,i=u.events.length,o=Array.from(s);return{restore:function(){r=e,u.previous=t,u.currentConstruct=n,u.events.length=i,s=o,g()},from:i}}(),p=e,e.partial||(u.currentConstruct=e),e.name&&u.parser.constructs.disable.null.includes(e.name))?x(n):e.tokenize.call(t?Object.assign(Object.create(u),t):u,a,y,x)(n)}}function y(t){return e(p,f),i}function x(e){return(f.restore(),++d<c.length)?v(c[d]):o}}}function m(e,t){e.resolveAll&&!o.includes(e)&&o.push(e),e.resolve&&eb(u.events,t,u.events.length-t,e.resolve(u.events.slice(t),u)),e.resolveTo&&(u.events=e.resolveTo(u.events,u))}function g(){r.line in i&&r.column<2&&(r.column=i[r.line],r.offset+=i[r.line]-1)}}(t,e,n)}}})(o).document().write((s=1,a="",u=!0,function(e,t,n){let r,i,o,c,d,h=[];for(e=a+("string"==typeof e?e.toString():new TextDecoder(t||void 0).decode(e)),o=0,a="",u&&(65279===e.charCodeAt(0)&&o++,u=void 0);o<e.length;){if(tL.lastIndex=o,c=(r=tL.exec(e))&&void 0!==r.index?r.index:e.length,d=e.charCodeAt(c),!r){a=e.slice(o);break}if(10===d&&o===c&&l)h.push(-3),l=void 0;else switch(l&&(h.push(-5),l=void 0),o<c&&(h.push(e.slice(o,c)),s+=c-o),d){case 0:h.push(65533),s++;break;case 9:for(i=4*Math.ceil(s/4),h.push(-2);s++<i;)h.push(-1);break;case 10:h.push(-4),s=1;break;default:l=!0,s=1}o=c+1}return n&&(l&&h.push(-5),a&&h.push(a),h.push(null)),h})(n,r,!0))))}}let tU="object"==typeof self?self:globalThis,tz=e=>((e,t)=>{let n=(t,n)=>(e.set(n,t),t),r=i=>{if(e.has(i))return e.get(i);let[o,l]=t[i];switch(o){case 0:case -1:return n(l,i);case 1:{let e=n([],i);for(let t of l)e.push(r(t));return e}case 2:{let e=n({},i);for(let[t,n]of l)e[r(t)]=r(n);return e}case 3:return n(new Date(l),i);case 4:{let{source:e,flags:t}=l;return n(new RegExp(e,t),i)}case 5:{let e=n(new Map,i);for(let[t,n]of l)e.set(r(t),r(n));return e}case 6:{let e=n(new Set,i);for(let t of l)e.add(r(t));return e}case 7:{let{name:e,message:t}=l;return n(new tU[e](t),i)}case 8:return n(BigInt(l),i);case"BigInt":return n(Object(BigInt(l)),i)}return n(new tU[o](l),i)};return r})(new Map,e)(0),{toString:tH}={},{keys:tW}=Object,tq=e=>{let t=typeof e;if("object"!==t||!e)return[0,t];let n=tH.call(e).slice(8,-1);switch(n){case"Array":return[1,""];case"Object":return[2,""];case"Date":return[3,""];case"RegExp":return[4,""];case"Map":return[5,""];case"Set":return[6,""]}return n.includes("Array")?[1,n]:n.includes("Error")?[7,n]:[2,n]},tY=([e,t])=>0===e&&("function"===t||"symbol"===t),tG=(e,{json:t,lossy:n}={})=>{let r=[];return((e,t,n,r)=>{let i=(e,t)=>{let i=r.push(e)-1;return n.set(t,i),i},o=r=>{if(n.has(r))return n.get(r);let[l,s]=tq(r);switch(l){case 0:{let t=r;switch(s){case"bigint":l=8,t=r.toString();break;case"function":case"symbol":if(e)throw TypeError("unable to serialize "+s);t=null;break;case"undefined":return i([-1],r)}return i([l,t],r)}case 1:{if(s)return i([s,[...r]],r);let e=[],t=i([l,e],r);for(let t of r)e.push(o(t));return t}case 2:{if(s)switch(s){case"BigInt":return i([s,r.toString()],r);case"Boolean":case"Number":case"String":return i([s,r.valueOf()],r)}if(t&&"toJSON"in r)return o(r.toJSON());let n=[],a=i([l,n],r);for(let t of tW(r))(e||!tY(tq(r[t])))&&n.push([o(t),o(r[t])]);return a}case 3:return i([l,r.toISOString()],r);case 4:{let{source:e,flags:t}=r;return i([l,{source:e,flags:t}],r)}case 5:{let t=[],n=i([l,t],r);
1for(let[n,i]of r)(e||!(tY(tq(n))||tY(tq(i))))&&t.push([o(n),o(i)]);return n}case 6:{let t=[],n=i([l,t],r);for(let n of r)(e||!tY(tq(n)))&&t.push(o(n));return n}}let{message:a}=r;return i([l,{name:s,message:a}],r)};return o})(!(t||n),!!t,new Map,r)(e),r},t$="function"==typeof structuredClone?(e,t)=>t&&("json"in t||"lossy"in t)?tz(tG(e,t)):structuredClone(e):(e,t)=>tz(tG(e,t));function tX(e){let t=[],n=-1,r=0,i=0;for(;++n<e.length;){let o=e.charCodeAt(n),l="";if(37===o&&eP(e.charCodeAt(n+1))&&eP(e.charCodeAt(n+2)))i=2;else if(o<128)/[!#$&-;=?-Z_a-z~]/.test(String.fromCharCode(o))||(l=String.fromCharCode(o));else if(o>55295&&o<57344){let t=e.charCodeAt(n+1);o<56320&&t>56319&&t<57344?(l=String.fromCharCode(o,t),i=1):l="�"}else l=String.fromCharCode(o);l&&(t.push(e.slice(r,n),encodeURIComponent(l)),r=n+i+1,l=""),i&&(n+=i,i=0)}return t.join("")+e.slice(r)}function tK(e,t){let n=[{type:"text",value:"↩"}];return t>1&&n.push({type:"element",tagName:"sup",properties:{},children:[{type:"text",value:String(t)}]}),n}function tJ(e,t){return"Back to reference "+(e+1)+(t>1?"-"+t:"")}let tZ=function(e){var t,n;if(null==e)return t0;if("function"==typeof e)return tQ(e);if("object"==typeof e){return Array.isArray(e)?function(e){let t=[],n=-1;for(;++n<e.length;)t[n]=tZ(e[n]);return tQ(function(...e){let n=-1;for(;++n<t.length;)if(t[n].apply(this,e))return!0;return!1})}(e):(t=e,tQ(function(e){let n;for(n in t)if(e[n]!==t[n])return!1;return!0}))}if("string"==typeof e){return n=e,tQ(function(e){return e&&e.type===n})}throw Error("Expected function, string, or object as test")};function tQ(e){return function(t,n,r){return!!(function(e){return null!==e&&"object"==typeof e&&"type"in e}(t)&&e.call(this,t,"number"==typeof n?n:void 0,r||void 0))}}function t0(){return!0}let t1=[];function t2(e,t,n,r){let i,o,l,s;"function"==typeof t&&"function"!=typeof n?(o=void 0,l=t,i=n):(o=t,l=n,i=r);var a=o,u=function(e,t){let n=t[t.length-1],r=n?n.children.indexOf(e):void 0;return l(e,r,n)},c=i;"function"==typeof a&&"function"!=typeof u?(c=u,u=a):s=a;let d=tZ(s),h=c?-1:1;(function e(t,n,r){let i=t&&"object"==typeof t?t:{};if("string"==typeof i.type){let e="string"==typeof i.tagName?i.tagName:"string"==typeof i.name?i.name:void 0;Object.defineProperty(o,"name",{value:"node ("+t.type+(e?"<"+e+">":"")+")"})}return o;function o(){var i;let o,l,s,p=t1;if((!a||d(t,n,r[r.length-1]||void 0))&&!1===(p=Array.isArray(i=u(t,r))?i:"number"==typeof i?[!0,i]:null==i?t1:[i])[0])return p;if("children"in t&&t.children&&t.children&&"skip"!==p[0])for(l=(c?t.children.length:-1)+h,s=r.concat(t);l>-1&&l<t.children.length;){if(!1===(o=e(t.children[l],l,s)())[0])return o;l="number"==typeof o[1]?o[1]:l+h}return p}})(e,void 0,[])()}function t4(e,t){let n=t.referenceType,r="]";if("collapsed"===n?r+="[]":"full"===n&&(r+="["+(t.label||t.identifier)+"]"),"imageReference"===t.type)return[{type:"text",value:"!["+t.alt+r}];let i=e.all(t),o=i[0];o&&"text"===o.type?o.value="["+o.value:i.unshift({type:"text",value:"["});let l=i[i.length-1];return l&&"text"===l.type?l.value+=r:i.push({type:"text",value:r}),i}function t3(e){let t=e.spread;return null==t?e.children.length>1:t}function t5(e,t,n){let r=0,i=e.length;if(t){let t=e.codePointAt(r);for(;9===t||32===t;)r++,t=e.codePointAt(r)}if(n){let t=e.codePointAt(i-1);for(;9===t||32===t;)i--,t=e.codePointAt(i-1)}return i>r?e.slice(r,i):""}let t6={blockquote:function(e,t){let n={type:"element",tagName:"blockquote",properties:{},children:e.wrap(e.all(t),!0)};return e.patch(t,n),e.applyData(t,n)},break:function(e,t){let n={type:"element",tagName:"br",properties:{},children:[]};return e.patch(t,n),[e.applyData(t,n),{type:"text",value:"\n"}]},code:function(e,t){let n=t.value?t.value+"\n":"",r={};t.lang&&(r.className=["language-"+t.lang]);let i={type:"element",tagName:"code",properties:r,children:[{type:"text",value:n}]};return t.meta&&(i.data={meta:t.meta}),e.patch(t,i),i={type:"element",tagName:"pre",properties:{},children:[i=e.applyData(t,i)]},e.patch(t,i),i},delete:function(e,t){let n={type:"element",tagName:"del",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)},emphasis:function(e,t){let n={type:"element",tagName:"em",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}
1,footnoteReference:function(e,t){let n,r="string"==typeof e.options.clobberPrefix?e.options.clobberPrefix:"user-content-",i=String(t.identifier).toUpperCase(),o=tX(i.toLowerCase()),l=e.footnoteOrder.indexOf(i),s=e.footnoteCounts.get(i);void 0===s?(s=0,e.footnoteOrder.push(i),n=e.footnoteOrder.length):n=l+1,s+=1,e.footnoteCounts.set(i,s);let a={type:"element",tagName:"a",properties:{href:"#"+r+"fn-"+o,id:r+"fnref-"+o+(s>1?"-"+s:""),dataFootnoteRef:!0,ariaDescribedBy:["footnote-label"]},children:[{type:"text",value:String(n)}]};e.patch(t,a);let u={type:"element",tagName:"sup",properties:{},children:[a]};return e.patch(t,u),e.applyData(t,u)},heading:function(e,t){let n={type:"element",tagName:"h"+t.depth,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)},html:function(e,t){if(e.options.allowDangerousHtml){let n={type:"raw",value:t.value};return e.patch(t,n),e.applyData(t,n)}},imageReference:function(e,t){let n=String(t.identifier).toUpperCase(),r=e.definitionById.get(n);if(!r)return t4(e,t);let i={src:tX(r.url||""),alt:t.alt};null!==r.title&&void 0!==r.title&&(i.title=r.title);let o={type:"element",tagName:"img",properties:i,children:[]};return e.patch(t,o),e.applyData(t,o)},image:function(e,t){let n={src:tX(t.url)};null!==t.alt&&void 0!==t.alt&&(n.alt=t.alt),null!==t.title&&void 0!==t.title&&(n.title=t.title);let r={type:"element",tagName:"img",properties:n,children:[]};return e.patch(t,r),e.applyData(t,r)},inlineCode:function(e,t){let n={type:"text",value:t.value.replace(/\r?\n|\r/g," ")};e.patch(t,n);let r={type:"element",tagName:"code",properties:{},children:[n]};return e.patch(t,r),e.applyData(t,r)},linkReference:function(e,t){let n=String(t.identifier).toUpperCase(),r=e.definitionById.get(n);if(!r)return t4(e,t);let i={href:tX(r.url||"")};null!==r.title&&void 0!==r.title&&(i.title=r.title);let o={type:"element",tagName:"a",properties:i,children:e.all(t)};return e.patch(t,o),e.applyData(t,o)},link:function(e,t){let n={href:tX(t.url)};null!==t.title&&void 0!==t.title&&(n.title=t.title);let r={type:"element",tagName:"a",properties:n,children:e.all(t)};return e.patch(t,r),e.applyData(t,r)},listItem:function(e,t,n){let r=e.all(t),i=n?function(e){let t=!1;if("list"===e.type){t=e.spread||!1;let n=e.children,r=-1;for(;!t&&++r<n.length;)t=t3(n[r])}return t}(n):t3(t),o={},l=[];if("boolean"==typeof t.checked){let e,n=r[0];n&&"element"===n.type&&"p"===n.tagName?e=n:(e={type:"element",tagName:"p",properties:{},children:[]},r.unshift(e)),e.children.length>0&&e.children.unshift({type:"text",value:" "}),e.children.unshift({type:"element",tagName:"input",properties:{type:"checkbox",checked:t.checked,disabled:!0},children:[]}),o.className=["task-list-item"]}let s=-1;for(;++s<r.length;){let e=r[s];(i||0!==s||"element"!==e.type||"p"!==e.tagName)&&l.push({type:"text",value:"\n"}),"element"!==e.type||"p"!==e.tagName||i?l.push(e):l.push(...e.children)}let a=r[r.length-1];a&&(i||"element"!==a.type||"p"!==a.tagName)&&l.push({type:"text",value:"\n"});let u={type:"element",tagName:"li",properties:o,children:l};return e.patch(t,u),e.applyData(t,u)},list:function(e,t){let n={},r=e.all(t),i=-1;for("number"==typeof t.start&&1!==t.start&&(n.start=t.start);++i<r.length;){let e=r[i];if("element"===e.type&&"li"===e.tagName&&e.properties&&Array.isArray(e.properties.className)&&e.properties.className.includes("task-list-item")){n.className=["contains-task-list"];break}}let o={type:"element",tagName:t.ordered?"ol":"ul",properties:n,children:e.wrap(r,!0)};return e.patch(t,o),e.applyData(t,o)},paragraph:function(e,t){let n={type:"element",tagName:"p",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)},root:function(e,t){let n={type:"root",children:e.wrap(e.all(t))};return e.patch(t,n),e.applyData(t,n)},strong:function(e,t){let n={type:"element",tagName:"strong",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)},table:function(e,t){let n=e.all(t),r=n.shift(),i=[];if(r){let n={type:"element",tagName:"thead",properties:{},children:e.wrap([r],!0)};e.patch(t.children[0],n),i.push(n)}if(n.length>0){let r={type:"element",tagName:"tbody",properties:{},children:e.wrap(n,!0)},o=G(t.children[1]),l=Y(t.children[t.children.length-1]);o&&l&&(r.position={start:o,end:l}),i.push(r)}let o={type:"element",tagName:"table",properties:{}
1,children:e.wrap(i,!0)};return e.patch(t,o),e.applyData(t,o)},tableCell:function(e,t){let n={type:"element",tagName:"td",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)},tableRow:function(e,t,n){let r=n?n.children:void 0,i=0===(r?r.indexOf(t):1)?"th":"td",o=n&&"table"===n.type?n.align:void 0,l=o?o.length:t.children.length,s=-1,a=[];for(;++s<l;){let n=t.children[s],r={},l=o?o[s]:void 0;l&&(r.align=l);let u={type:"element",tagName:i,properties:r,children:[]};n&&(u.children=e.all(n),e.patch(n,u),u=e.applyData(n,u)),a.push(u)}let u={type:"element",tagName:"tr",properties:{},children:e.wrap(a,!0)};return e.patch(t,u),e.applyData(t,u)},text:function(e,t){let n={type:"text",value:function(e){let t=String(e),n=/\r?\n|\r/g,r=n.exec(t),i=0,o=[];for(;r;)o.push(t5(t.slice(i,r.index),i>0,!0),r[0]),i=r.index+r[0].length,r=n.exec(t);return o.push(t5(t.slice(i),i>0,!1)),o.join("")}(String(t.value))};return e.patch(t,n),e.applyData(t,n)},thematicBreak:function(e,t){let n={type:"element",tagName:"hr",properties:{},children:[]};return e.patch(t,n),e.applyData(t,n)},toml:t9,yaml:t9,definition:t9,footnoteDefinition:t9};function t9(){}let t7={}.hasOwnProperty,t8={};function ne(e,t){e.position&&(t.position=function(e){let t=G(e),n=Y(e);if(t&&n)return{start:t,end:n}}(e))}function nt(e,t){let n=t;if(e&&e.data){let t=e.data.hName,r=e.data.hChildren,i=e.data.hProperties;"string"==typeof t&&("element"===n.type?n.tagName=t:n={type:"element",tagName:t,properties:{},children:"children"in n?n.children:[n]}),"element"===n.type&&i&&Object.assign(n.properties,t$(i)),"children"in n&&n.children&&null!=r&&(n.children=r)}return n}function nn(e,t){let n=[],r=-1;for(t&&n.push({type:"text",value:"\n"});++r<e.length;)r&&n.push({type:"text",value:"\n"}),n.push(e[r]);return t&&e.length>0&&n.push({type:"text",value:"\n"}),n}function nr(e){let t=0,n=e.charCodeAt(t);for(;9===n||32===n;)t++,n=e.charCodeAt(t);return e.slice(t)}function ni(e,t){let n=function(e,t){let n=t||t8,r=new Map,i=new Map,o={all:function(e){let t=[];if("children"in e){let n=e.children,r=-1;for(;++r<n.length;){let i=o.one(n[r],e);if(i){if(r&&"break"===n[r-1].type&&(Array.isArray(i)||"text"!==i.type||(i.value=nr(i.value)),!Array.isArray(i)&&"element"===i.type)){let e=i.children[0];e&&"text"===e.type&&(e.value=nr(e.value))}Array.isArray(i)?t.push(...i):t.push(i)}}}return t},applyData:nt,definitionById:r,footnoteById:i,footnoteCounts:new Map,footnoteOrder:[],handlers:{...t6,...n.handlers},one:function(e,t){let n=e.type,r=o.handlers[n];if(t7.call(o.handlers,n)&&r)return r(o,e,t);if(o.options.passThrough&&o.options.passThrough.includes(n)){if("children"in e){let{children:t,...n}=e,r=t$(n);return r.children=o.all(e),r}return t$(e)}return(o.options.unknownHandler||function(e,t){let n=t.data||{},r="value"in t&&!(t7.call(n,"hProperties")||t7.call(n,"hChildren"))?{type:"text",value:t.value}:{type:"element",tagName:"div",properties:{},children:e.all(t)};return e.patch(t,r),e.applyData(t,r)})(o,e,t)},options:n,patch:ne,wrap:nn};return t2(e,function(e){if("definition"===e.type||"footnoteDefinition"===e.type){let t="definition"===e.type?r:i,n=String(e.identifier).toUpperCase();t.has(n)||t.set(n,e)}}),o}(e,t),r=n.one(e,void 0),i=function(e){let t="string"==typeof e.options.clobberPrefix?e.options.clobberPrefix:"user-content-",n=e.options.footnoteBackContent||tK,r=e.options.footnoteBackLabel||tJ,i=e.options.footnoteLabel||"Footnotes",o=e.options.footnoteLabelTagName||"h2",l=e.options.footnoteLabelProperties||{className:["sr-only"]},s=[],a=-1;for(;++a<e.footnoteOrder.length;){let i=e.footnoteById.get(e.footnoteOrder[a]);if(!i)continue;let o=e.all(i),l=String(i.identifier).toUpperCase(),u=tX(l.toLowerCase()),c=0,d=[],h=e.footnoteCounts.get(l);for(;void 0!==h&&++c<=h;){d.length>0&&d.push({type:"text",value:" "});let e="string"==typeof n?n:n(a,c);"string"==typeof e&&(e={type:"text",value:e}),d.push({type:"element",tagName:"a",properties:{href:"#"+t+"fnref-"+u+(c>1?"-"+c:""),dataFootnoteBackref:"",ariaLabel:"string"==typeof r?r:r(a,c),className:["data-footnote-backref"]},children:Array.isArray(e)?e:[e]})}let p=o[o.length-1];if(p&&"element"===p.type&&"p"===p.tagName){let e=p.children[p.children.length-1];e&&"text"===e.type?e.value+=" ":p.children.push({type:"text",value:" "}),p.children.push(...d)}else o.push(...d);let f={type:"element",tagName:"li",properties:{id:t+"fn-"+u},children:e.wrap(o,!0)};e.patch(i,f),s.push(f)}if(0!==s.length)return{type:"element",tagName:"section",properties:{dataFootnotes:!0,className:["footnotes"]},children:[{type:"element",tagName:o,properties:{...t$(l),id:"footnote-label"},children:[{type:"text",value:i}]},{type:"text",value:"\n"},{type:"element",tagName:"ol",properties:{},children:e.wrap(s,!0)}
1,{type:"text",value:"\n"}]}}(n),o=Array.isArray(r)?{type:"root",children:r}:r||{type:"root",children:[]};return i&&o.children.push({type:"text",value:"\n"},i),o}function no(e,t){return e&&"run"in e?async function(n,r){let i=ni(n,{file:r,...t});await e.run(i,r)}:function(n,r){return ni(n,{file:r,...e||t})}}function nl(e){if(e)throw e}var ns=n(38885);function na(e){if("object"!=typeof e||null===e)return!1;let t=Object.getPrototypeOf(e);return(null===t||t===Object.prototype||null===Object.getPrototypeOf(t))&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)}let nu={basename:function(e,t){let n;if(void 0!==t&&"string"!=typeof t)throw TypeError('"ext" argument must be a string');nc(e);let r=0,i=-1,o=e.length;if(void 0===t||0===t.length||t.length>e.length){for(;o--;)if(47===e.codePointAt(o)){if(n){r=o+1;break}}else i<0&&(n=!0,i=o+1);return i<0?"":e.slice(r,i)}if(t===e)return"";let l=-1,s=t.length-1;for(;o--;)if(47===e.codePointAt(o)){if(n){r=o+1;break}}else l<0&&(n=!0,l=o+1),s>-1&&(e.codePointAt(o)===t.codePointAt(s--)?s<0&&(i=o):(s=-1,i=l));return r===i?i=l:i<0&&(i=e.length),e.slice(r,i)},dirname:function(e){let t;if(nc(e),0===e.length)return".";let n=-1,r=e.length;for(;--r;)if(47===e.codePointAt(r)){if(t){n=r;break}}else t||(t=!0);return n<0?47===e.codePointAt(0)?"/":".":1===n&&47===e.codePointAt(0)?"//":e.slice(0,n)},extname:function(e){let t;nc(e);let n=e.length,r=-1,i=0,o=-1,l=0;for(;n--;){let s=e.codePointAt(n);if(47===s){if(t){i=n+1;break}continue}r<0&&(t=!0,r=n+1),46===s?o<0?o=n:1!==l&&(l=1):o>-1&&(l=-1)}return o<0||r<0||0===l||1===l&&o===r-1&&o===i+1?"":e.slice(o,r)},join:function(...e){let t,n=-1;for(;++n<e.length;)nc(e[n]),e[n]&&(t=void 0===t?e[n]:t+"/"+e[n]);return void 0===t?".":function(e){nc(e);let t=47===e.codePointAt(0),n=function(e,t){let n,r,i="",o=0,l=-1,s=0,a=-1;for(;++a<=e.length;){if(a<e.length)n=e.codePointAt(a);else if(47===n)break;else n=47;if(47===n){if(l===a-1||1===s);else if(l!==a-1&&2===s){if(i.length<2||2!==o||46!==i.codePointAt(i.length-1)||46!==i.codePointAt(i.length-2)){if(i.length>2){if((r=i.lastIndexOf("/"))!==i.length-1){r<0?(i="",o=0):o=(i=i.slice(0,r)).length-1-i.lastIndexOf("/"),l=a,s=0;continue}}else if(i.length>0){i="",o=0,l=a,s=0;continue}}t&&(i=i.length>0?i+"/..":"..",o=2)}else i.length>0?i+="/"+e.slice(l+1,a):i=e.slice(l+1,a),o=a-l-1;l=a,s=0}else 46===n&&s>-1?s++:s=-1}return i}(e,!t);return 0!==n.length||t||(n="."),n.length>0&&47===e.codePointAt(e.length-1)&&(n+="/"),t?"/"+n:n}(t)},sep:"/"};function nc(e){if("string"!=typeof e)throw TypeError("Path must be a string. Received "+JSON.stringify(e))}let nd={cwd:function(){return"/"}};function nh(e){return!!(null!==e&&"object"==typeof e&&"href"in e&&e.href&&"protocol"in e&&e.protocol&&void 0===e.auth)}let np=["history","path","basename","stem","extname","dirname"];class nf{constructor(e){let t,n;t=e?nh(e)?{path:e}:"string"==typeof e||function(e){return!!(e&&"object"==typeof e&&"byteLength"in e&&"byteOffset"in e)}(e)?{value:e}:e:{},this.cwd="cwd"in t?"":nd.cwd(),this.data={},this.history=[],this.messages=[],this.value,this.map,this.result,this.stored;let r=-1;for(;++r<np.length;){let e=np[r];e in t&&void 0!==t[e]&&null!==t[e]&&(this[e]="history"===e?[...t[e]]:t[e])}for(n in t)np.includes(n)||(this[n]=t[n])}get basename(){return"string"==typeof this.path?nu.basename(this.path):void 0}set basename(e){ng(e,"basename"),nm(e,"basename"),this.path=nu.join(this.dirname||"",e)}get dirname(){return"string"==typeof this.path?nu.dirname(this.path):void 0}set dirname(e){nv(this.basename,"dirname"),this.path=nu.join(e||"",this.basename)}get extname(){return"string"==typeof this.path?nu.extname(this.path):void 0}set extname(e){if(nm(e,"extname"),nv(this.dirname,"extname"),e){if(46!==e.codePointAt(0))throw Error("`extname` must start with `.`");if(e.includes(".",1))throw Error("`extname` cannot contain multiple dots")}this.path=nu.join(this.dirname,this.stem+(e||""))}get path(){return this.history[this.history.length-1]}set path(e){nh(e)&&(e=function(e){if("string"==typeof e)e=new URL(e);else if(!nh(e)){let t=TypeError('The "path" argument must be of type string or an instance of URL. Received `'+e+"`");throw t.code="ERR_INVALID_ARG_TYPE",t}if("file:"!==e.protocol){let e=TypeError("The URL must be of scheme file");throw e.code="ERR_INVALID_URL_SCHEME",e}return function(e){if(""!==e.hostname){let e=TypeError('File URL host must be "localhost" or empty on darwin');throw e.code="ERR_INVALID_FILE_URL_HOST",e}let t=e.pathname,n=-1;for(;++n<t.length;)if(37===t.codePointAt(n)&&50===t.codePointAt(n+1)){let e=t.codePointAt(n+2);if(70===e||102===e){let e=TypeError("File URL path must not include encoded / characters");throw e.code="ERR_INVALID_FILE_URL_PATH",e}}return decodeURIComponent(t)}(e)}(e)),ng(e,"path"),this.path!==e&&this.history.push(e)}get stem(){return"string"==typeof this.path?nu.basename(this.path,this.extname):void 0}set stem(e){ng(e,"stem"),nm(e,"stem"),this.path=nu.join(this.dirname||"",e+(this.extname||""))}fail(e,t,n){let r=this.message(e,t,n);throw r.fatal=!0,r}info(e,t,n){let r=this.message(e,t,n);return r.fatal=void 0,r}message(e,t,n){let r=new Q(e,t,n);return this.path&&(r.name=this.path+":"+r.name,r.file=this.path),r.fatal=!1,this.messages.push(r),r}toString(e){return void 0===this.value?"":"string"==typeof this.value?this.value:new TextDecoder(e||void 0).decode(this.value)}}function nm(e,t){if(e&&e.includes(nu.sep))throw Error("`"+t+"` cannot be a path: did not expect `"+nu.sep+"`")}function ng(e,t){if(!e)throw Error("`"+t+"` cannot be empty")}function nv(e,t){if(!e)throw Error("Setting `"+t+"` requires `path` to be set too")}let ny=function(e){let t=this.constructor.prototype,n=t[e],r=function(){return n.apply(r,arguments)};return Object.setPrototypeOf(r,t),r},nx={}.hasOwnProperty;
1class nb extends ny{constructor(){super("copy"),this.Compiler=void 0,this.Parser=void 0,this.attachers=[],this.compiler=void 0,this.freezeIndex=-1,this.frozen=void 0,this.namespace={},this.parser=void 0,this.transformers=function(){let e=[],t={run:function(...t){let n=-1,r=t.pop();if("function"!=typeof r)throw TypeError("Expected function as last argument, not "+r);!function i(o,...l){let s=e[++n],a=-1;if(o)return void r(o);for(;++a<t.length;)(null===l[a]||void 0===l[a])&&(l[a]=t[a]);t=l,s?(function(e,t){let n;return function(...t){let o,l=e.length>t.length;l&&t.push(r);try{o=e.apply(this,t)}catch(e){if(l&&n)throw e;return r(e)}l||(o&&o.then&&"function"==typeof o.then?o.then(i,r):o instanceof Error?r(o):i(o))};function r(e,...i){n||(n=!0,t(e,...i))}function i(e){r(null,e)}})(s,i)(...l):r(null,...l)}(null,...t)},use:function(n){if("function"!=typeof n)throw TypeError("Expected `middelware` to be a function, not "+n);return e.push(n),t}};return t}()}copy(){let e=new nb,t=-1;for(;++t<this.attachers.length;){let n=this.attachers[t];e.use(...n)}return e.data(ns(!0,{},this.namespace)),e}data(e,t){return"string"==typeof e?2==arguments.length?(nS("data",this.frozen),this.namespace[e]=t,this):nx.call(this.namespace,e)&&this.namespace[e]||void 0:e?(nS("data",this.frozen),this.namespace=e,this):this.namespace}freeze(){if(this.frozen)return this;for(;++this.freezeIndex<this.attachers.length;){let[e,...t]=this.attachers[this.freezeIndex];if(!1===t[0])continue;!0===t[0]&&(t[0]=void 0);let n=e.call(this,...t);"function"==typeof n&&this.transformers.use(n)}return this.frozen=!0,this.freezeIndex=1/0,this}parse(e){this.freeze();let t=nP(e),n=this.parser||this.Parser;return nE("parse",n),n(String(t),t)}process(e,t){let n=this;return this.freeze(),nE("process",this.parser||this.Parser),nk("process",this.compiler||this.Compiler),t?r(void 0,t):new Promise(r);function r(r,i){let o=nP(e),l=n.parse(o);function s(e,n){e||!n?i(e):r?r(n):t(void 0,n)}n.run(l,o,function(e,t,r){var i,o;if(e||!t||!r)return s(e);let l=n.stringify(t,r);"string"==typeof(i=l)||(o=i)&&"object"==typeof o&&"byteLength"in o&&"byteOffset"in o?r.value=l:r.result=l,s(e,r)})}}processSync(e){let t,n=!1;return this.freeze(),nE("processSync",this.parser||this.Parser),nk("processSync",this.compiler||this.Compiler),this.process(e,function(e,r){n=!0,nl(e),t=r}),nC("processSync","process",n),t}run(e,t,n){nT(e),this.freeze();let r=this.transformers;return n||"function"!=typeof t||(n=t,t=void 0),n?i(void 0,n):new Promise(i);function i(i,o){let l=nP(t);r.run(e,l,function(t,r,l){let s=r||e;t?o(t):i?i(s):n(void 0,s,l)})}}runSync(e,t){let n,r=!1;return this.run(e,t,function(e,t){nl(e),n=t,r=!0}),nC("runSync","run",r),n}stringify(e,t){this.freeze();let n=nP(t),r=this.compiler||this.Compiler;return nk("stringify",r),nT(e),r(e,n)}use(e,...t){let n=this.attachers,r=this.namespace;if(nS("use",this.frozen),null==e);else if("function"==typeof e)l(e,t);else if("object"==typeof e)Array.isArray(e)?o(e):i(e);else throw TypeError("Expected usable value, not `"+e+"`");return this;function i(e){if(!("plugins"in e)&&!("settings"in e))throw Error("Expected usable value but received an empty preset, which is probably a mistake: presets typically come with `plugins` and sometimes with `settings`, but this has neither");o(e.plugins),e.settings&&(r.settings=ns(!0,r.settings,e.settings))}function o(e){let t=-1;if(null==e);else if(Array.isArray(e))for(;++t<e.length;){var n=e[t];if("function"==typeof n)l(n,[]);else if("object"==typeof n)if(Array.isArray(n)){let[e,...t]=n;l(e,t)}else i(n);else throw TypeError("Expected usable value, not `"+n+"`")}else throw TypeError("Expected a list of plugins, not `"+e+"`")}function l(e,t){let r=-1,i=-1;for(;++r<n.length;)if(n[r][0]===e){i=r;break}if(-1===i)n.push([e,...t]);else if(t.length>0){let[r,...o]=t,l=n[i][1];na(l)&&na(r)&&(r=ns(!0,l,r)),n[i]=[e,r,...o]}}}}let nw=new nb().freeze();function nE(e,t){if("function"!=typeof t)throw TypeError("Cannot `"+e+"` without `parser`")}function nk(e,t){if("function"!=typeof t)throw TypeError("Cannot `"+e+"` without `compiler`")}function nS(e,t){if(t)throw Error("Cannot call `"+e+"` on a frozen processor.\nCreate a new processor first, by calling it: use `processor()` instead of `processor`.")}function nT(e){if(!na(e)||"string"!=typeof e.type)throw TypeError("Expected node, got `"+e+"`")}function nC(e,t,n){if(!n)throw Error("`"+e+"` finished async. Use `"+t+"` instead")}function nP(e){var t;return(t=e)&&"object"==typeof t&&"message"in t&&"messages"in t?e:new nf(e)}let nA=[],nR={allowDangerousHtml:!0},n_=/^(https?|ircs?|mailto|xmpp)$/i,nI=[{from:"astPlugins",id:"remove-buggy-html-in-markdown-parser"},{from:"allowDangerousHtml",id:"remove-buggy-html-in-markdown-parser"},{from:"allowNode",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"allowElement"},{from:"allowedTypes",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"allowedElements"},{from:"disallowedTypes",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"disallowedElements"},{from:"escapeHtml",id:"remove-buggy-html-in-markdown-parser"},{from:"includeElementIndex",id:"#remove-includeelementindex"},{from:"includeNodeIndex",id:"change-includenodeindex-to-includeelementindex"},{from:"linkTarget",id:"remove-linktarget"},{from:"plugins",id:"change-plugins-to-remarkplugins",to:"remarkPlugins"},{from:"rawSourcePos",id:"#remove-rawsourcepos"},{from:"renderers",id:"change-renderers-to-components",to:"components"},{from:"source",id:"change-source-to-children",to:"children"},{from:"sourcePos",id:"#remove-sourcepos"},{from:"transformImageUri",id:"#add-urltransform",to:"urlTransform"},{from:"transformLinkUri",id:"#add-urltransform",to:"urlTransform"}];function nD(e){let t=e.allowedElements,n=e.allowElement,r=e.children||"",i=e.className,o=e.components,l=e.disallowedElements,s=e.rehypePlugins||nA,a=e.remarkPlugins||nA,u=e.remarkRehypeOptions?{...e.remarkRehypeOptions,...nR}
1:nR,c=e.skipHtml,d=e.unwrapDisallowed,h=e.urlTransform||nL,p=nw().use(tB).use(a).use(no,u).use(s),f=new nf;for(let t of("string"==typeof r&&(f.value=r),nI))Object.hasOwn(e,t.from)&&(t.from,t.to&&t.to,t.id);let m=p.parse(f),g=p.runSync(m,f);return i&&(g={type:"element",tagName:"div",properties:{className:i},children:"root"===g.type?g.children:[g]}),t2(g,function(e,r,i){if("raw"===e.type&&i&&"number"==typeof r)return c?i.children.splice(r,1):i.children[r]={type:"text",value:e.value},r;if("element"===e.type){let t;for(t in em)if(Object.hasOwn(em,t)&&Object.hasOwn(e.properties,t)){let n=e.properties[t],r=em[t];(null===r||r.includes(e.tagName))&&(e.properties[t]=h(String(n||""),t,e))}}if("element"===e.type){let o=t?!t.includes(e.tagName):!!l&&l.includes(e.tagName);if(!o&&n&&"number"==typeof r&&(o=!n(e,r,i)),o&&i&&"number"==typeof r)return d&&e.children?i.children.splice(r,1,...e.children):i.children.splice(r,1),r}}),function(e,t){var n,r,i,o;let l;if(!t||void 0===t.Fragment)throw TypeError("Expected `Fragment` in options");let s=t.filePath||void 0;if(t.development){if("function"!=typeof t.jsxDEV)throw TypeError("Expected `jsxDEV` in options when `development: true`");n=s,r=t.jsxDEV,l=function(e,t,i,o){let l=Array.isArray(i.children),s=G(e);return r(t,i,o,l,{columnNumber:s?s.column-1:void 0,fileName:n,lineNumber:s?s.line:void 0},void 0)}}else{if("function"!=typeof t.jsx)throw TypeError("Expected `jsx` in production options");
1if("function"!=typeof t.jsxs)throw TypeError("Expected `jsxs` in production options");i=t.jsx,o=t.jsxs,l=function(e,t,n,r){let l=Array.isArray(n.children)?o:i;return r?l(t,n,r):l(t,n)}}let a={Fragment:t.Fragment,ancestors:[],components:t.components||{},create:l,elementAttributeNameCase:t.elementAttributeNameCase||"react",evaluater:t.createEvaluater?t.createEvaluater():void 0,filePath:s,ignoreInvalidStyle:t.ignoreInvalidStyle||!1,passKeys:!1!==t.passKeys,passNode:t.passNode||!1,schema:"svg"===t.space?j:O,stylePropertyNameCase:t.stylePropertyNameCase||"dom",tableCellAlignToStyle:!1!==t.tableCellAlignToStyle},u=es(a,e,void 0);return u&&"string"!=typeof u?u:a.create(e,a.Fragment,{children:u||void 0},void 0)}(g,{Fragment:eg.Fragment,components:o,ignoreInvalidStyle:!0,jsx:eg.jsx,jsxs:eg.jsxs,passKeys:!0,passNode:!0})}function nL(e){let t=e.indexOf(":"),n=e.indexOf("?"),r=e.indexOf("#"),i=e.indexOf("/");return t<0||i>-1&&t>i||n>-1&&t>n||r>-1&&t>r||n_.test(e.slice(0,t))?e:""}},54503:(e,t,n)=>{"use strict";n.d(t,{A:()=>r});var r=(0,n(57011).A)("outline","robot","IconRobot",[["path",{d:"M6 4m0 2a2 2 0 0 1 2 -2h8a2 2 0 0 1 2 2v4a2 2 0 0 1 -2 2h-8a2 2 0 0 1 -2 -2z",key:"svg-0"}],["path",{d:"M12 2v2",key:"svg-1"}],["path",{d:"M9 12v9",key:"svg-2"}],["path",{d:"M15 12v9",key:"svg-3"}],["path",{d:"M5 16l4 -2",key:"svg-4"}],["path",{d:"M15 14l4 2",key:"svg-5"}],["path",{d:"M9 18h6",key:"svg-6"}],["path",{d:"M10 8v.01",key:"svg-7"}],["path",{d:"M14 8v.01",key:"svg-8"}]])},55025:(e,t,n)=>{"use strict";n.d(t,{W:()=>r});let r={skipAnimations:!1,useManualTiming:!1}},55764:(e,t,n)=>{"use strict";n.d(t,{$:()=>u});var r=n(90354),i=n(81697),o=n(32144),l=n(23037),s=n(85792),a=n(70880);let u=(0,a.FX)(function(e,t){var n;let u=(0,s._)(),{disabled:c=u||!1,autoFocus:d=!1,...h}=e,{isFocusVisible:p,focusProps:f}=(0,r.o)({autoFocus:d}),{isHovered:m,hoverProps:g}=(0,i.M)({isDisabled:c}),{pressed:v,pressProps:y}=(0,l.Z)({disabled:c}),x=(0,a.v6)({ref:t,type:null!=(n=h.type)?n:"button",disabled:c||void 0,autoFocus:d},f,g,y),b=(0,o.useMemo)(()=>({disabled:c,hover:m,focus:p,active:v,autofocus:d}),[c,m,p,v,d]);return(0,a.Ci)()({ourProps:x,theirProps:h,slot:b,defaultTag:"button",name:"Button"})})},56679:(e,t,n)=>{"use strict";n.d(t,{e:()=>function e(){let t=[],n={addEventListener:(e,t,r,i)=>(e.addEventListener(t,r,i),n.add(()=>e.removeEventListener(t,r,i))),requestAnimationFrame(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];let i=requestAnimationFrame(...t);return n.add(()=>cancelAnimationFrame(i))},nextFrame(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];return n.requestAnimationFrame(()=>n.requestAnimationFrame(...t))},setTimeout(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];let i=setTimeout(...t);return n.add(()=>clearTimeout(i))},microTask(){for(var e=arguments.length,t=Array(e),i=0;i<e;i++)t[i]=arguments[i];let o={current:!0};return(0,r._)(()=>{o.current&&t[0]()}),n.add(()=>{o.current=!1})},style(e,t,n){let r=e.style.getPropertyValue(t);return Object.assign(e.style,{[t]:n}),this.add(()=>{Object.assign(e.style,{[t]:r})})},group(t){let n=e();return t(n),this.add(()=>n.dispose())},add:e=>(t.includes(e)||t.push(e),()=>{let n=t.indexOf(e);if(n>=0)for(let e of t.splice(n,1))e()}),dispose(){for(let e of t.splice(0))e()}};return n}});var r=n(40318)},57011:(e,t,n)=>{"use strict";n.d(t,{A:()=>o});var r=n(32144),i={outline:{xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"},filled:{xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"currentColor",stroke:"none"}};let o=(e,t,n,o)=>{let l=(0,r.forwardRef)((n,l)=>{let{color:s="currentColor",size:a=24,stroke:u=2,title:c,className:d,children:h,...p}=n;return(0,r.createElement)("svg",{ref:l,...i[e],width:a,height:a,className:["tabler-icon","tabler-icon-".concat(t),d].join(" "),..."filled"===e?{fill:s}:{strokeWidth:u,stroke:s},...p},[c&&(0,r.createElement)("title",{key:"svg-title"},c),...o.map(e=>{let[t,n]=e;return(0,r.createElement)(t,n)}),...Array.isArray(h)?h:[h]])});return l.displayName="".concat(n),l}}
1,62293:(e,t,n)=>{"use strict";n.d(t,{LM:()=>$,OK:()=>X,VM:()=>k,bL:()=>G,lr:()=>M});var r=n(32144),i=n(40675),o=n(94185),l=n(11623),s=n(40558),a=n(97842),u=n(40460),c=n(7136),d=n(80244),h=n(14558),p=n(11612),f="ScrollArea",[m,g]=(0,l.A)(f),[v,y]=m(f),x=r.forwardRef((e,t)=>{let{__scopeScrollArea:n,type:o="hover",dir:l,scrollHideDelay:a=600,...c}=e,[d,h]=r.useState(null),[f,m]=r.useState(null),[g,y]=r.useState(null),[x,b]=r.useState(null),[w,E]=r.useState(null),[k,S]=r.useState(0),[T,C]=r.useState(0),[P,A]=r.useState(!1),[R,_]=r.useState(!1),I=(0,s.s)(t,e=>h(e)),D=(0,u.jH)(l);return(0,p.jsx)(v,{scope:n,type:o,dir:D,scrollHideDelay:a,scrollArea:d,viewport:f,onViewportChange:m,content:g,onContentChange:y,scrollbarX:x,onScrollbarXChange:b,scrollbarXEnabled:P,onScrollbarXEnabledChange:A,scrollbarY:w,onScrollbarYChange:E,scrollbarYEnabled:R,onScrollbarYEnabledChange:_,onCornerWidthChange:S,onCornerHeightChange:C,children:(0,p.jsx)(i.sG.div,{dir:D,...c,ref:I,style:{position:"relative","--radix-scroll-area-corner-width":k+"px","--radix-scroll-area-corner-height":T+"px",...e.style}})})});x.displayName=f;var b="ScrollAreaViewport",w=r.forwardRef((e,t)=>{let{__scopeScrollArea:n,children:o,asChild:l,nonce:a,...u}=e,c=y(b,n),d=r.useRef(null),h=(0,s.s)(t,d,c.onViewportChange);return(0,p.jsxs)(p.Fragment,{children:[(0,p.jsx)("style",{dangerouslySetInnerHTML:{__html:"\n[data-radix-scroll-area-viewport] {\n  scrollbar-width: none;\n  -ms-overflow-style: none;\n  -webkit-overflow-scrolling: touch;\n}\n[data-radix-scroll-area-viewport]::-webkit-scrollbar {\n  display: none;\n}\n:where([data-radix-scroll-area-viewport]) {\n  display: flex;\n  flex-direction: column;\n  align-items: stretch;\n}\n:where([data-radix-scroll-area-content]) {\n  flex-grow: 1;\n}\n"},nonce:a}),(0,p.jsx)(i.sG.div,{"data-radix-scroll-area-viewport":"",...u,asChild:l,ref:h,style:{overflowX:c.scrollbarXEnabled?"scroll":"hidden",overflowY:c.scrollbarYEnabled?"scroll":"hidden",...e.style},children:function(e,t){let{asChild:n,children:i}=e;if(!n)return"function"==typeof t?t(i):t;let o=r.Children.only(i);return r.cloneElement(o,{children:"function"==typeof t?t(o.props.children):t})}({asChild:l,children:o},e=>(0,p.jsx)("div",{"data-radix-scroll-area-content":"",ref:c.onContentChange,style:{minWidth:c.scrollbarXEnabled?"fit-content":void 0},children:e}))})]})});w.displayName=b;var E="ScrollAreaScrollbar",k=r.forwardRef((e,t)=>{let{forceMount:n,...i}=e,o=y(E,e.__scopeScrollArea),{onScrollbarXEnabledChange:l,onScrollbarYEnabledChange:s}=o,a="horizontal"===e.orientation;return r.useEffect(()=>(a?l(!0):s(!0),()=>{a?l(!1):s(!1)}),[a,l,s]),"hover"===o.type?(0,p.jsx)(S,{...i,ref:t,forceMount:n}):"scroll"===o.type?(0,p.jsx)(T,{...i,ref:t,forceMount:n}):"auto"===o.type?(0,p.jsx)(C,{...i,ref:t,forceMount:n}):"always"===o.type?(0,p.jsx)(P,{...i,ref:t}):null});k.displayName=E;var S=r.forwardRef((e,t)=>{let{forceMount:n,...i}=e,l=y(E,e.__scopeScrollArea),[s,a]=r.useState(!1);return r.useEffect(()=>{let e=l.scrollArea,t=0;if(e){let n=()=>{window.clearTimeout(t),a(!0)},r=()=>{t=window.setTimeout(()=>a(!1),l.scrollHideDelay)};return e.addEventListener("pointerenter",n),e.addEventListener("pointerleave",r),()=>{window.clearTimeout(t),e.removeEventListener("pointerenter",n),e.removeEventListener("pointerleave",r)}}},[l.scrollArea,l.scrollHideDelay]),(0,p.jsx)(o.C,{present:n||s,children:(0,p.jsx)(C,{"data-state":s?"visible":"hidden",...i,ref:t})})}),T=r.forwardRef((e,t)=>{var n;let{forceMount:i,...l}=e,s=y(E,e.__scopeScrollArea),a="horizontal"===e.orientation,u=q(()=>d("SCROLL_END"),100),[c,d]=(n={hidden:{SCROLL:"scrolling"},scrolling:{SCROLL_END:"idle",POINTER_ENTER:"interacting"},interacting:{SCROLL:"interacting",POINTER_LEAVE:"idle"},idle:{HIDE:"hidden",SCROLL:"scrolling",POINTER_ENTER:"interacting"}},r.useReducer((e,t)=>{let r=n[e][t];return null!=r?r:e},"hidden"));return r.useEffect(()=>{if("idle"===c){let e=window.setTimeout(()=>d("HIDE"),s.scrollHideDelay);return()=>window.clearTimeout(e)}},[c,s.scrollHideDelay,d]),r.useEffect(()=>{let e=s.viewport,t=a?"scrollLeft":"scrollTop";if(e){let n=e[t],r=()=>{let r=e[t];n!==r&&(d("SCROLL"),u()),n=r};return e.addEventListener("scroll",r),()=>e.removeEventListener("scroll",r)}}
1,[s.viewport,a,d,u]),(0,p.jsx)(o.C,{present:i||"hidden"!==c,children:(0,p.jsx)(P,{"data-state":"hidden"===c?"hidden":"visible",...l,ref:t,onPointerEnter:(0,h.m)(e.onPointerEnter,()=>d("POINTER_ENTER")),onPointerLeave:(0,h.m)(e.onPointerLeave,()=>d("POINTER_LEAVE"))})})}),C=r.forwardRef((e,t)=>{let n=y(E,e.__scopeScrollArea),{forceMount:i,...l}=e,[s,a]=r.useState(!1),u="horizontal"===e.orientation,c=q(()=>{if(n.viewport){let e=n.viewport.offsetWidth<n.viewport.scrollWidth,t=n.viewport.offsetHeight<n.viewport.scrollHeight;a(u?e:t)}},10);return Y(n.viewport,c),Y(n.content,c),(0,p.jsx)(o.C,{present:i||s,children:(0,p.jsx)(P,{"data-state":s?"visible":"hidden",...l,ref:t})})}),P=r.forwardRef((e,t)=>{let{orientation:n="vertical",...i}=e,o=y(E,e.__scopeScrollArea),l=r.useRef(null),s=r.useRef(0),[a,u]=r.useState({content:0,viewport:0,scrollbar:{size:0,paddingStart:0,paddingEnd:0}}),c=B(a.viewport,a.content),d={...i,sizes:a,onSizesChange:u,hasThumb:!!(c>0&&c<1),onThumbChange:e=>l.current=e,onThumbPointerUp:()=>s.current=0,onThumbPointerDown:e=>s.current=e};function h(e,t){return function(e,t,n){let r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"ltr",i=U(n),o=t||i/2,l=n.scrollbar.paddingStart+o,s=n.scrollbar.size-n.scrollbar.paddingEnd-(i-o),a=n.content-n.viewport;return H([l,s],"ltr"===r?[0,a]:[-1*a,0])(e)}(e,s.current,a,t)}return"horizontal"===n?(0,p.jsx)(A,{...d,ref:t,onThumbPositionChange:()=>{if(o.viewport&&l.current){let e=z(o.viewport.scrollLeft,a,o.dir);l.current.style.transform="translate3d(".concat(e,"px, 0, 0)")}},onWheelScroll:e=>{o.viewport&&(o.viewport.scrollLeft=e)},onDragScroll:e=>{o.viewport&&(o.viewport.scrollLeft=h(e,o.dir))}}):"vertical"===n?(0,p.jsx)(R,{...d,ref:t,onThumbPositionChange:()=>{if(o.viewport&&l.current){let e=z(o.viewport.scrollTop,a);l.current.style.transform="translate3d(0, ".concat(e,"px, 0)")}},onWheelScroll:e=>{o.viewport&&(o.viewport.scrollTop=e)},onDragScroll:e=>{o.viewport&&(o.viewport.scrollTop=h(e))}}):null}),A=r.forwardRef((e,t)=>{let{sizes:n,onSizesChange:i,...o}=e,l=y(E,e.__scopeScrollArea),[a,u]=r.useState(),c=r.useRef(null),d=(0,s.s)(t,c,l.onScrollbarXChange);return r.useEffect(()=>{c.current&&u(getComputedStyle(c.current))},[c]),(0,p.jsx)(D,{"data-orientation":"horizontal",...o,ref:d,sizes:n,style:{bottom:0,left:"rtl"===l.dir?"var(--radix-scroll-area-corner-width)":0,right:"ltr"===l.dir?"var(--radix-scroll-area-corner-width)":0,"--radix-scroll-area-thumb-width":U(n)+"px",...e.style},onThumbPointerDown:t=>e.onThumbPointerDown(t.x),onDragScroll:t=>e.onDragScroll(t.x),onWheelScroll:(t,n)=>{if(l.viewport){let r=l.viewport.scrollLeft+t.deltaX;e.onWheelScroll(r),function(e,t){return e>0&&e<t}(r,n)&&t.preventDefault()}},onResize:()=>{c.current&&l.viewport&&a&&i({content:l.viewport.scrollWidth,viewport:l.viewport.offsetWidth,scrollbar:{size:c.current.clientWidth,paddingStart:V(a.paddingLeft),paddingEnd:V(a.paddingRight)}})}})}),R=r.forwardRef((e,t)=>{let{sizes:n,onSizesChange:i,...o}=e,l=y(E,e.__scopeScrollArea),[a,u]=r.useState(),c=r.useRef(null),d=(0,s.s)(t,c,l.onScrollbarYChange);return r.useEffect(()=>{c.current&&u(getComputedStyle(c.current))},[c]),(0,p.jsx)(D,{"data-orientation":"vertical",...o,ref:d,sizes:n,style:{top:0,right:"ltr"===l.dir?0:void 0,left:"rtl"===l.dir?0:void 0,bottom:"var(--radix-scroll-area-corner-height)","--radix-scroll-area-thumb-height":U(n)+"px",...e.style},onThumbPointerDown:t=>e.onThumbPointerDown(t.y),onDragScroll:t=>e.onDragScroll(t.y),onWheelScroll:(t,n)=>{if(l.viewport){let r=l.viewport.scrollTop+t.deltaY;e.onWheelScroll(r),function(e,t){return e>0&&e<t}(r,n)&&t.preventDefault()}},onResize:()=>{c.current&&l.viewport&&a&&i({content:l.viewport.scrollHeight,viewport:l.viewport.offsetHeight,scrollbar:{size:c.current.clientHeight,paddingStart:V(a.paddingTop),paddingEnd:V(a.paddingBottom)}})}})}),[_,I]=m(E),D=r.forwardRef((e,t)=>{let{__scopeScrollArea:n,sizes:o,hasThumb:l,onThumbChange:u,onThumbPointerUp:c,onThumbPointerDown:d,onThumbPositionChange:f,onDragScroll:m,onWheelScroll:g,onResize:v,...x}=e,b=y(E,n),[w,k]=r.useState(null),S=(0,s.s)(t,e=>k(e)),T=r.useRef(null),C=r.useRef(""),P=b.viewport,A=o.content-o.viewport,R=(0,a.c)(g),I=(0,a.c)(f),D=q(v,10);function L(e){T.current&&m({x:e.clientX-T.current.left,y:e.clientY-T.current.top})}return r.useEffect(()=>{let e=e=>{let t=e.target;(null==w?void 0:w.contains(t))&&R(e,A)};return document.addEventListener("wheel",e,{passive:!1}),()=>document.removeEventListener("wheel",e,{passive:!1})},[P,w,A,R]),r.useEffect(I,[o,I]),Y(w,D),Y(b.content,D),(0,p.jsx)(_,{scope:n,scrollbar:w,hasThumb:l,onThumbChange:(0,a.c)(u),onThumbPointerUp:(0,a.c)(c),onThumbPositionChange:I,onThumbPointerDown:(0,a.c)(d),children:(0,p.jsx)(i.sG.div,{...x,ref:S,style:{position:"absolute",...x.style},onPointerDown:(0,h.m)(e.onPointerDown,e=>{0===e.button&&(e.target.setPointerCapture(e.pointerId),T.current=w.getBoundingClientRect(),C.current=document.body.style.webkitUserSelect,document.body.style.webkitUserSelect="none",b.viewport&&(b.viewport.style.scrollBehavior="auto"),L(e))}),onPointerMove:(0,h.m)(e.onPointerMove,L),onPointerUp:(0,h.m)(e.onPointerUp,e=>{let t=e.target;t.hasPointerCapture(e.pointerId)&&t.releasePointerCapture(e.pointerId),document.body.style.webkitUserSelect=C.current,b.viewport&&(b.viewport.style.scrollBehavior=""),T.current=null})})})}),L="ScrollAreaThumb",M=r.forwardRef((e,t)=>
1{let{forceMount:n,...r}=e,i=I(L,e.__scopeScrollArea);return(0,p.jsx)(o.C,{present:n||i.hasThumb,children:(0,p.jsx)(F,{ref:t,...r})})}),F=r.forwardRef((e,t)=>{let{__scopeScrollArea:n,style:o,...l}=e,a=y(L,n),u=I(L,n),{onThumbPositionChange:c}=u,d=(0,s.s)(t,e=>u.onThumbChange(e)),f=r.useRef(),m=q(()=>{f.current&&(f.current(),f.current=void 0)},100);return r.useEffect(()=>{let e=a.viewport;if(e){let t=()=>{m(),f.current||(f.current=W(e,c),c())};return c(),e.addEventListener("scroll",t),()=>e.removeEventListener("scroll",t)}},[a.viewport,m,c]),(0,p.jsx)(i.sG.div,{"data-state":u.hasThumb?"visible":"hidden",...l,ref:d,style:{width:"var(--radix-scroll-area-thumb-width)",height:"var(--radix-scroll-area-thumb-height)",...o},onPointerDownCapture:(0,h.m)(e.onPointerDownCapture,e=>{let t=e.target.getBoundingClientRect(),n=e.clientX-t.left,r=e.clientY-t.top;u.onThumbPointerDown({x:n,y:r})}),onPointerUp:(0,h.m)(e.onPointerUp,u.onThumbPointerUp)})});M.displayName=L;var O="ScrollAreaCorner",j=r.forwardRef((e,t)=>{let n=y(O,e.__scopeScrollArea),r=!!(n.scrollbarX&&n.scrollbarY);return"scroll"!==n.type&&r?(0,p.jsx)(N,{...e,ref:t}):null});j.displayName=O;var N=r.forwardRef((e,t)=>{let{__scopeScrollArea:n,...o}=e,l=y(O,n),[s,a]=r.useState(0),[u,c]=r.useState(0),d=!!(s&&u);return Y(l.scrollbarX,()=>{var e;let t=(null==(e=l.scrollbarX)?void 0:e.offsetHeight)||0;l.onCornerHeightChange(t),c(t)}),Y(l.scrollbarY,()=>{var e;let t=(null==(e=l.scrollbarY)?void 0:e.offsetWidth)||0;l.onCornerWidthChange(t),a(t)}),d?(0,p.jsx)(i.sG.div,{...o,ref:t,style:{width:s,height:u,position:"absolute",right:"ltr"===l.dir?0:void 0,left:"rtl"===l.dir?0:void 0,bottom:0,...e.style}}):null});function V(e){return e?parseInt(e,10):0}function B(e,t){let n=e/t;return isNaN(n)?0:n}function U(e){let t=B(e.viewport,e.content),n=e.scrollbar.paddingStart+e.scrollbar.paddingEnd;return Math.max((e.scrollbar.size-n)*t,18)}function z(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"ltr",r=U(t),i=t.scrollbar.paddingStart+t.scrollbar.paddingEnd,o=t.scrollbar.size-i,l=t.content-t.viewport,s=(0,d.q)(e,"ltr"===n?[0,l]:[-1*l,0]);return H([0,l],[0,o-r])(s)}function H(e,t){return n=>{if(e[0]===e[1]||t[0]===t[1])return t[0];let r=(t[1]-t[0])/(e[1]-e[0]);return t[0]+r*(n-e[0])}}var W=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:()=>{},n={left:e.scrollLeft,top:e.scrollTop},r=0;return!function i(){let o={left:e.scrollLeft,top:e.scrollTop},l=n.left!==o.left,s=n.top!==o.top;(l||s)&&t(),n=o,r=window.requestAnimationFrame(i)}(),()=>window.cancelAnimationFrame(r)};function q(e,t){let n=(0,a.c)(e),i=r.useRef(0);return r.useEffect(()=>()=>window.clearTimeout(i.current),[]),r.useCallback(()=>{window.clearTimeout(i.current),i.current=window.setTimeout(n,t)},[n,t])}function Y(e,t){let n=(0,a.c)(t);(0,c.N)(()=>{let t=0;if(e){let r=new ResizeObserver(()=>{cancelAnimationFrame(t),t=window.requestAnimationFrame(n)});return r.observe(e),()=>{window.cancelAnimationFrame(t),r.unobserve(e)}}},[e,n])}var G=x,$=w,X=j},66666:(e,t,n)=>{"use strict";n.d(t,{J:()=>s});var r=n(32144),i=n(88050),o=n(70880),l=n(55764);let s=(0,o.FX)(function(e,t){let n=(0,i.g)();return r.createElement(l.$,{ref:t,...(0,o.v6)({onClick:n},e)})})},67978:(e,t,n)=>{"use strict";n.d(t,{lG:()=>eG,Xi:()=>eY,Lj:()=>eq});var r,i,o=n(32144),l=n.t(o,2),s=(e=>(e.Space=" ",e.Enter="Enter",e.Escape="Escape",e.Backspace="Backspace",e.Delete="Delete",e.ArrowLeft="ArrowLeft",e.ArrowUp="ArrowUp",e.ArrowRight="ArrowRight",e.ArrowDown="ArrowDown",e.Home="Home",e.End="End",e.PageUp="PageUp",e.PageDown="PageDown",e.Tab="Tab",e))(s||{}),a=n(37738);function u(e,t,n,r){let i=(0,a.Y)(n);(0,o.useEffect)(()=>{function n(e){i.current(e)}return(e=null!=e?e:window).addEventListener(t,n,r),()=>e.removeEventListener(t,n,r)},[e,t,r])}class c extends Map{get(e){let t=super.get(e);return void 0===t&&(t=this.factory(e),this.set(e,t)),t}constructor(e){super(),this.factory=e}}function d(e,t){let n=e(),r=new Set;return{getSnapshot:()=>n,subscribe:e=>(r.add(e),()=>r.delete(e)),dispatch(e){for(var i=arguments.length,o=Array(i>1?i-1:0),l=1;l<i;l++)o[l-1]=arguments[l];let s=t[e].call(n,...o);
1s&&(n=s,r.forEach(e=>e()))}}}var h=n(85385);function p(e){return(0,o.useSyncExternalStore)(e.subscribe,e.getSnapshot,e.getSnapshot)}let f=new c(()=>d(()=>[],{ADD(e){return this.includes(e)?this:[...this,e]},REMOVE(e){let t=this.indexOf(e);if(-1===t)return this;let n=this.slice();return n.splice(t,1),n}}));function m(e,t){let n=f.get(t),r=(0,o.useId)(),i=p(n);if((0,h.s)(()=>{if(e)return n.dispatch("ADD",r),()=>n.dispatch("REMOVE",r)},[n,e]),!e)return!1;let l=i.indexOf(r),s=i.length;return -1===l&&(l=s,s+=1),l===s-1}var g=n(72755),v=n(56679),y=n(22031);let x=new Map,b=new Map;function w(e){var t;let n=null!=(t=b.get(e))?t:0;return b.set(e,n+1),0!==n||(x.set(e,{"aria-hidden":e.getAttribute("aria-hidden"),inert:e.inert}),e.setAttribute("aria-hidden","true"),e.inert=!0),()=>(function(e){var t;let n=null!=(t=b.get(e))?t:1;if(1===n?b.delete(e):b.set(e,n-1),1!==n)return;let r=x.get(e);r&&(null===r["aria-hidden"]?e.removeAttribute("aria-hidden"):e.setAttribute("aria-hidden",r["aria-hidden"]),e.inert=r.inert,x.delete(e))})(e)}var E=n(63689);let k=["[contentEditable=true]","[tabindex]","a[href]","area[href]","button:not([disabled])","iframe","input:not([disabled])","select:not([disabled])","textarea:not([disabled])"].map(e=>"".concat(e,":not([tabindex='-1'])")).join(","),S=["[data-autofocus]"].map(e=>"".concat(e,":not([tabindex='-1'])")).join(",");var T=(e=>(e[e.First=1]="First",e[e.Previous=2]="Previous",e[e.Next=4]="Next",e[e.Last=8]="Last",e[e.WrapAround=16]="WrapAround",e[e.NoScroll=32]="NoScroll",e[e.AutoFocus=64]="AutoFocus",e))(T||{}),C=(e=>(e[e.Error=0]="Error",e[e.Overflow=1]="Overflow",e[e.Success=2]="Success",e[e.Underflow=3]="Underflow",e))(C||{}),P=(e=>(e[e.Previous=-1]="Previous",e[e.Next=1]="Next",e))(P||{}),A=(e=>(e[e.Strict=0]="Strict",e[e.Loose=1]="Loose",e))(A||{}),R=(e=>(e[e.Keyboard=0]="Keyboard",e[e.Mouse=1]="Mouse",e))(R||{});function _(e){null==e||e.focus({preventScroll:!0})}function I(e,t){var n,r,i;let{sorted:o=!0,relativeTo:l=null,skipElements:s=[]}=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},a=Array.isArray(e)?e.length>0?e[0].ownerDocument:document:e.ownerDocument,u=Array.isArray(e)?o?function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e=>e;return e.slice().sort((e,n)=>{let r=t(e),i=t(n);if(null===r||null===i)return 0;let o=r.compareDocumentPosition(i);return o&Node.DOCUMENT_POSITION_FOLLOWING?-1:o&Node.DOCUMENT_POSITION_PRECEDING?1:0})}(e):e:64&t?function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:document.body;return null==e?[]:Array.from(e.querySelectorAll(S)).sort((e,t)=>Math.sign((e.tabIndex||Number.MAX_SAFE_INTEGER)-(t.tabIndex||Number.MAX_SAFE_INTEGER)))}(e):function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:document.body;return null==e?[]:Array.from(e.querySelectorAll(k)).sort((e,t)=>Math.sign((e.tabIndex||Number.MAX_SAFE_INTEGER)-(t.tabIndex||Number.MAX_SAFE_INTEGER)))}(e);s.length>0&&u.length>1&&(u=u.filter(e=>!s.some(t=>null!=t&&"current"in t?(null==t?void 0:t.current)===e:t===e))),l=null!=l?l:a.activeElement;let c=(()=>{if(5&t)return 1;if(10&t)return -1;throw Error("Missing Focus.First, Focus.Previous, Focus.Next or Focus.Last")})(),d=(()=>{if(1&t)return 0;if(2&t)return Math.max(0,u.indexOf(l))-1;if(4&t)return Math.max(0,u.indexOf(l))+1;if(8&t)return u.length-1;throw Error("Missing Focus.First, Focus.Previous, Focus.Next or Focus.Last")})(),h=32&t?{preventScroll:!0}:{},p=0,f=u.length,m;do{if(p>=f||p+f<=0)return 0;let e=d+p;if(16&t)e=(e+f)%f;else{if(e<0)return 3;if(e>=f)return 1}null==(m=u[e])||m.focus(h),p+=c}while(m!==a.activeElement);return 6&t&&null!=(i=null==(r=null==(n=m)?void 0:n.matches)?void 0:r.call(n,"textarea,input"))&&i&&m.select(),2}function D(){return/iPhone/gi.test(window.navigator.platform)||/Mac/gi.test(window.navigator.platform)&&window.navigator.maxTouchPoints>0}function L(e,t,n,r){let i=(0,a.Y)(n);(0,o.useEffect)(()=>{if(e)return document.addEventListener(t,n,r),()=>document.removeEventListener(t,n,r);function n(e){i.current(e)}},[e,t,r])}function M(e,t,n,r){let i=(0,a.Y)(n);(0,o.useEffect)(()=>
1{if(e)return window.addEventListener(t,n,r),()=>window.removeEventListener(t,n,r);function n(e){i.current(e)}},[e,t,r])}function F(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return(0,o.useMemo)(()=>(0,y.T)(...t),[...t])}"undefined"!=typeof window&&"undefined"!=typeof document&&(document.addEventListener("keydown",e=>{e.metaKey||e.altKey||e.ctrlKey||(document.documentElement.dataset.headlessuiFocusVisible="")},!0),document.addEventListener("click",e=>{1===e.detail?delete document.documentElement.dataset.headlessuiFocusVisible:0===e.detail&&(document.documentElement.dataset.headlessuiFocusVisible="")},!0));var O=n(67264);let j=(0,o.createContext)(null);function N(e){let{children:t,node:n}=e,[r,i]=(0,o.useState)(null),l=V(null!=n?n:r);return o.createElement(j.Provider,{value:l},t,null===l&&o.createElement(O.j,{features:O.u.Hidden,ref:e=>{var t,n;if(e){for(let r of null!=(n=null==(t=(0,y.T)(e))?void 0:t.querySelectorAll("html > *, body > *"))?n:[])if(r!==document.body&&r!==document.head&&r instanceof HTMLElement&&null!=r&&r.contains(e)){i(r);break}}}}))}function V(){var e;let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;return null!=(e=(0,o.useContext)(j))?e:t}let B=d(()=>new Map,{PUSH(e,t){var n;let r=null!=(n=this.get(e))?n:{doc:e,count:0,d:(0,v.e)(),meta:new Set};return r.count++,r.meta.add(t),this.set(e,r),this},POP(e,t){let n=this.get(e);return n&&(n.count--,n.meta.delete(t)),this},SCROLL_PREVENT(e){let t,{doc:n,d:r,meta:i}=e,o={doc:n,d:r,meta:function(e){let t={};for(let n of e)Object.assign(t,n(t));return t}(i)},l=[D()?{before(e){let{doc:t,d:n,meta:r}=e;function i(e){return r.containers.flatMap(e=>e()).some(t=>t.contains(e))}n.microTask(()=>{var e;if("auto"!==window.getComputedStyle(t.documentElement).scrollBehavior){let e=(0,v.e)();e.style(t.documentElement,"scrollBehavior","auto"),n.add(()=>n.microTask(()=>e.dispose()))}let r=null!=(e=window.scrollY)?e:window.pageYOffset,o=null;n.addEventListener(t,"click",e=>{if(e.target instanceof HTMLElement)try{let n=e.target.closest("a");if(!n)return;let{hash:r}=new URL(n.href),l=t.querySelector(r);l&&!i(l)&&(o=l)}catch(e){}},!0),n.addEventListener(t,"touchstart",e=>{if(e.target instanceof HTMLElement)if(i(e.target)){let t=e.target;for(;t.parentElement&&i(t.parentElement);)t=t.parentElement;n.style(t,"overscrollBehavior","contain")}else n.style(e.target,"touchAction","none")}),n.addEventListener(t,"touchmove",e=>{if(e.target instanceof HTMLElement&&"INPUT"!==e.target.tagName)if(i(e.target)){let t=e.target;for(;t.parentElement&&""!==t.dataset.headlessuiPortal&&!(t.scrollHeight>t.clientHeight||t.scrollWidth>t.clientWidth);)t=t.parentElement;""===t.dataset.headlessuiPortal&&e.preventDefault()}else e.preventDefault()},{passive:!1}),n.add(()=>{var e;r!==(null!=(e=window.scrollY)?e:window.pageYOffset)&&window.scrollTo(0,r),o&&o.isConnected&&(o.scrollIntoView({block:"nearest"}),o=null)})})}}:{},{before(e){var n;let{doc:r}=e,i=r.documentElement;t=Math.max(0,(null!=(n=r.defaultView)?n:window).innerWidth-i.clientWidth)},after(e){let{doc:n,d:r}=e,i=n.documentElement,o=Math.max(0,i.clientWidth-i.offsetWidth),l=Math.max(0,t-o);r.style(i,"paddingRight","".concat(l,"px"))}},{before(e){let{doc:t,d:n}=e;n.style(t.documentElement,"overflow","hidden")}}];l.forEach(e=>{let{before:t}=e;return null==t?void 0:t(o)}),l.forEach(e=>{let{after:t}=e;return null==t?void 0:t(o)})},SCROLL_ALLOW(e){let{d:t}=e;t.dispose()},TEARDOWN(e){let{doc:t}=e;this.delete(t)}});B.subscribe(()=>{let e=B.getSnapshot(),t=new Map;for(let[n]of e)t.set(n,n.documentElement.style.overflow);for(let n of e.values()){let e="hidden"===t.get(n.doc),r=0!==n.count;(r&&!e||!r&&e)&&B.dispatch(n.count>0?"SCROLL_PREVENT":"SCROLL_ALLOW",n),0===n.count&&B.dispatch("TEARDOWN",n)}});var U=n(30775);function z(){let e,t=(e="undefined"==typeof document,(0,l.useSyncExternalStore)(()=>()=>{},()=>!1,()=>!e)),[n,r]=o.useState(U._.isHandoffComplete);return n&&!1===U._.isHandoffComplete&&r(!1),o.useEffect(()=>{!0!==n&&r(!0)},[n]),o.useEffect(()=>U._.handoff(),[]),!t&&n}var H=n(43199),W=n(88050);let q=(0,o.createContext)(null);q.displayName="OpenClosedContext";var Y=(e=>(e[e.Open=1]="Open",e[e.Closed=2]="Closed",e[e.Closing=4]="Closing",e[e.Opening=8]="Opening",e))(Y||{});function G(){return(0,o.useContext)(q)}function $(e){let{value:t,children:n}=e;return o.createElement(q.Provider,{value:t},n)}function X(e){let{children:t}=e;return o.createElement(q.Provider,{value:null},t)}let K=(0,o.createContext)(!1);function J(e){return o.createElement(K.Provider,{value:e.force},e.children)}var Z=n(70880),Q=n(87690),ee=n(42624);function et(){let e=(0,o.useRef)(!1);return(0,h.s)(()=>(e.current=!0,()=>{e.current=!1}),[]),e}var en=n(40318);function er(e){let t=(0,g._)(e),n=(0,o.useRef)(!1);(0,o.useEffect)(()=>(n.current=!1,()=>{n.current=!0,(0,en._)(()=>{n.current&&t()})}),[t])}var ei=(e=>(e[e.Forwards=0]="Forwards",e[e.Backwards=1]="Backwards",e))(ei||{});function eo(e,t){let n=(0,o.useRef)([]),r=(0,g._)(e);(0,o.useEffect)(()=>{let e=[...n.current];for(let[i,o]of t.entries())if(n.current[i]!==o){let i=r(t,e);return n.current=t,i}},[r,...t])}let el=[];function es(e){if(!e)return new Set;if("function"==typeof e)return new Set(e());let t=new Set;for(let n of e.current)n.current instanceof HTMLElement&&t.add(n.current);return t}!function(e){function t(){"loading"!==document.readyState&&(e(),document.removeEventListener("DOMContentLoaded",t))}"undefined"!=typeof window&&"undefined"!=typeof document&&(document.addEventListener("DOMContentLoaded",t),t())}(()=>{function e(e){if(!(e.target instanceof HTMLElement)||e.target===document.body||el[0]===e.target)return;let t=e.target;t=t.closest(k),el.unshift(null!=t?t:e.target),(el=el.filter(e=>null!=e&&e.isConnected)).splice(10)}window.addEventListener("click",e,{capture:!0}),window.addEventListener("mousedown",e,{capture:!0}),window.addEventListener("focus",e,{capture:!0}),document.body.addEventListener("click",e,{capture:!0}),document.body.addEventListener("mousedown",e,{capture:!0}),document.body.addEventListener("focus",e,{capture:!0})});var ea=(e=>(e[e.None=0]="None",e[e.InitialFocus=1]="InitialFocus",e[e.TabLock=2]="TabLock",e[e.FocusLock=4]="FocusLock",e[e.Re
1storeFocus=8]="RestoreFocus",e[e.AutoFocus=16]="AutoFocus",e))(ea||{});let eu=Object.assign((0,Z.FX)(function(e,t){let n,r=(0,o.useRef)(null),i=(0,H.P)(r,t),{initialFocus:l,initialFocusFallback:s,containers:a,features:c=15,...d}=e;z()||(c=0);let h=F(r);!function(e,t){let{ownerDocument:n}=t,r=!!(8&e),i=function(){let e=!(arguments.length>0)||void 0===arguments[0]||arguments[0],t=(0,o.useRef)(el.slice());return eo((e,n)=>{let[r]=e,[i]=n;!0===i&&!1===r&&(0,en._)(()=>{t.current.splice(0)}),!1===i&&!0===r&&(t.current=el.slice())},[e,el,t]),(0,g._)(()=>{var e;return null!=(e=t.current.find(e=>null!=e&&e.isConnected))?e:null})}(r);eo(()=>{r||(null==n?void 0:n.activeElement)===(null==n?void 0:n.body)&&_(i())},[r]),er(()=>{r&&_(i())})}(c,{ownerDocument:h});let p=function(e,t){let{ownerDocument:n,container:r,initialFocus:i,initialFocusFallback:l}=t,s=(0,o.useRef)(null),a=m(!!(1&e),"focus-trap#initial-focus"),u=et();return eo(()=>{if(0===e)return;if(!a){null!=l&&l.current&&_(l.current);return}let t=r.current;t&&(0,en._)(()=>{if(!u.current)return;let r=null==n?void 0:n.activeElement;if(null!=i&&i.current){if((null==i?void 0:i.current)===r){s.current=r;return}}else if(t.contains(r)){s.current=r;return}if(null!=i&&i.current)_(i.current);else{if(16&e){if(I(t,T.First|T.AutoFocus)!==C.Error)return}else if(I(t,T.First)!==C.Error)return;if(null!=l&&l.current&&(_(l.current),(null==n?void 0:n.activeElement)===l.current))return;console.warn("There are no focusable elements inside the <FocusTrap />")}s.current=null==n?void 0:n.activeElement})},[l,a,e]),s}(c,{ownerDocument:h,container:r,initialFocus:l,initialFocusFallback:s});!function(e,t){let{ownerDocument:n,container:r,containers:i,previousActiveElement:o}=t,l=et(),s=!!(4&e);u(null==n?void 0:n.defaultView,"focus",e=>{if(!s||!l.current)return;let t=es(i);r.current instanceof HTMLElement&&t.add(r.current);let n=o.current;if(!n)return;let a=e.target;a&&a instanceof HTMLElement?ec(t,a)?(o.current=a,_(a)):(e.preventDefault(),e.stopPropagation(),_(n)):_(o.current)},!0)}(c,{ownerDocument:h,container:r,containers:a,previousActiveElement:p});let f=(n=(0,o.useRef)(0),M(!0,"keydown",e=>{"Tab"===e.key&&(n.current=+!!e.shiftKey)},!0),n),v=(0,g._)(e=>{let t=r.current;t&&(0,E.Y)(f.current,{[ei.Forwards]:()=>{I(t,T.First,{skipElements:[e.relatedTarget,s]})},[ei.Backwards]:()=>{I(t,T.Last,{skipElements:[e.relatedTarget,s]})}})}),y=m(!!(2&c),"focus-trap#tab-lock"),x=(0,ee.L)(),b=(0,o.useRef)(!1),w=(0,Z.Ci)();return o.createElement(o.Fragment,null,y&&o.createElement(O.j,{as:"button",type:"button","data-headlessui-focus-guard":!0,onFocus:v,features:O.u.Focusable}),w({ourProps:{ref:i,onKeyDown(e){"Tab"==e.key&&(b.current=!0,x.requestAnimationFrame(()=>{b.current=!1}))},onBlur(e){if(!(4&c))return;let t=es(a);r.current instanceof HTMLElement&&t.add(r.current);let n=e.relatedTarget;n instanceof HTMLElement&&"true"!==n.dataset.headlessuiFocusGuard&&(ec(t,n)||(b.current?I(r.current,(0,E.Y)(f.current,{[ei.Forwards]:()=>T.Next,[ei.Backwards]:()=>T.Previous})|T.WrapAround,{relativeTo:e.target}):e.target instanceof HTMLElement&&_(e.target)))}},theirProps:d,defaultTag:"div",name:"FocusTrap"}),y&&o.createElement(O.j,{as:"button",type:"button","data-headlessui-focus-guard":!0,onFocus:v,features:O.u.Focusable}))}),{features:ea});function ec(e,t){for(let n of e)if(n.contains(t))return!0;return!1}var ed=n(2241);let eh=o.Fragment,ep=(0,Z.FX)(function(e,t){let n=(0,o.useRef)(null),r=(0,H.P)((0,H.a)(e=>{n.current=e}),t),i=F(n),l=function(e){let t=(0,o.useContext)(K),n=(0,o.useContext)(em),r=F(e),[i,l]=(0,o.useState)(()=>{var e;if(!t&&null!==n)return null!=(e=n.current)?e:null;if(U._.isServer)return null;let i=null==r?void 0:r.getElementById("headlessui-portal-root");if(i)return i;if(null===r)return null;let o=r.createElement("div");return o.setAttribute("id","headlessui-portal-root"),r.body.appendChild(o)});return(0,o.useEffect)(()=>{null!==i&&(null!=r&&r.body.contains(i)||null==r||r.body.appendChild(i))},[i,r]),(0,o.useEffect)(()=>{t||null!==n&&l(n.current)},[n,l,t]),i}(n),[s]=(0,o.useState)(()=>{var e;return U._.isServer?null:null!=(e=null==i?void 0:i.createElement("div"))?e:null}),a=(0,o.useContext)(eg),u=z();(0,h.s)(()=>{!l||!s||l.contains(s)||(s.setAttribute("data-headlessui-portal",""),l.appendChild(s))},[l,s]),(0,h.s)(()=>
1{if(s&&a)return a.register(s)},[a,s]),er(()=>{var e;l&&s&&(s instanceof Node&&l.contains(s)&&l.removeChild(s),l.childNodes.length<=0&&(null==(e=l.parentElement)||e.removeChild(l)))});let c=(0,Z.Ci)();return u&&l&&s?(0,ed.createPortal)(c({ourProps:{ref:r},theirProps:e,slot:{},defaultTag:eh,name:"Portal"}),s):null}),ef=o.Fragment,em=(0,o.createContext)(null),eg=(0,o.createContext)(null),ev=(0,Z.FX)(function(e,t){let n=(0,H.P)(t),{enabled:r=!0,...i}=e,l=(0,Z.Ci)();return r?o.createElement(ep,{...i,ref:n}):l({ourProps:{ref:n},theirProps:i,slot:{},defaultTag:eh,name:"Portal"})}),ey=(0,Z.FX)(function(e,t){let{target:n,...r}=e,i={ref:(0,H.P)(t)},l=(0,Z.Ci)();return o.createElement(em.Provider,{value:n},l({ourProps:i,theirProps:r,defaultTag:ef,name:"Popover.Group"}))}),ex=Object.assign(ev,{Group:ey});var eb=n(37811);void 0!==eb&&"undefined"!=typeof globalThis&&"undefined"!=typeof Element&&(null==(r=null==eb?void 0:eb.env)?void 0:r.NODE_ENV)==="test"&&void 0===(null==(i=null==Element?void 0:Element.prototype)?void 0:i.getAnimations)&&(Element.prototype.getAnimations=function(){return console.warn("Headless UI has polyfilled `Element.prototype.getAnimations` for your tests.\nPlease install a proper polyfill e.g. `jsdom-testing-mocks`, to silence these warnings.\n\nExample usage:\n```js\nimport { mockAnimationsApi } from 'jsdom-testing-mocks'\nmockAnimationsApi()\n```"),[]});var ew=(e=>(e[e.None=0]="None",e[e.Closed=1]="Closed",e[e.Enter=2]="Enter",e[e.Leave=4]="Leave",e))(ew||{}),eE=n(18837);function ek(e){var t;return!!(e.enter||e.enterFrom||e.enterTo||e.leave||e.leaveFrom||e.leaveTo)||(null!=(t=e.as)?t:eR)!==o.Fragment||1===o.Children.count(e.children)}let eS=(0,o.createContext)(null);eS.displayName="TransitionContext";var eT=(e=>(e.Visible="visible",e.Hidden="hidden",e))(eT||{});let eC=(0,o.createContext)(null);function eP(e){return"children"in e?eP(e.children):e.current.filter(e=>{let{el:t}=e;return null!==t.current}).filter(e=>{let{state:t}=e;return"visible"===t}).length>0}function eA(e,t){let n=(0,a.Y)(e),r=(0,o.useRef)([]),i=et(),l=(0,ee.L)(),s=(0,g._)(function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Z.mK.Hidden,o=r.current.findIndex(t=>{let{el:n}=t;return n===e});-1!==o&&((0,E.Y)(t,{[Z.mK.Unmount](){r.current.splice(o,1)},[Z.mK.Hidden](){r.current[o].state="hidden"}}),l.microTask(()=>{var e;!eP(r)&&i.current&&(null==(e=n.current)||e.call(n))}))}),u=(0,g._)(e=>{let t=r.current.find(t=>{let{el:n}=t;return n===e});return t?"visible"!==t.state&&(t.state="visible"):r.current.push({el:e,state:"visible"}),()=>s(e,Z.mK.Unmount)}),c=(0,o.useRef)([]),d=(0,o.useRef)(Promise.resolve()),h=(0,o.useRef)({enter:[],leave:[]}),p=(0,g._)((e,n,r)=>{c.current.splice(0),t&&(t.chains.current[n]=t.chains.current[n].filter(t=>{let[n]=t;return n!==e})),null==t||t.chains.current[n].push([e,new Promise(e=>{c.current.push(e)})]),null==t||t.chains.current[n].push([e,new Promise(e=>{Promise.all(h.current[n].map(e=>{let[t,n]=e;return n})).then(()=>e())}
1)]),"enter"===n?d.current=d.current.then(()=>null==t?void 0:t.wait.current).then(()=>r(n)):r(n)}),f=(0,g._)((e,t,n)=>{Promise.all(h.current[t].splice(0).map(e=>{let[t,n]=e;return n})).then(()=>{var e;null==(e=c.current.shift())||e()}).then(()=>n(t))});return(0,o.useMemo)(()=>({children:r,register:u,unregister:s,onStart:p,onStop:f,wait:d,chains:h}),[u,s,r,p,f,h,d])}eC.displayName="NestingContext";let eR=o.Fragment,e_=Z.Ac.RenderStrategy,eI=(0,Z.FX)(function(e,t){let{show:n,appear:r=!1,unmount:i=!0,...l}=e,s=(0,o.useRef)(null),a=ek(e),u=(0,H.P)(...a?[s,t]:null===t?[]:[t]);z();let c=G();if(void 0===n&&null!==c&&(n=(c&Y.Open)===Y.Open),void 0===n)throw Error("A <Transition /> is used but it is missing a `show={true | false}` prop.");let[d,p]=(0,o.useState)(n?"visible":"hidden"),f=eA(()=>{n||p("hidden")}),[m,v]=(0,o.useState)(!0),y=(0,o.useRef)([n]);(0,h.s)(()=>{!1!==m&&y.current[y.current.length-1]!==n&&(y.current.push(n),v(!1))},[y,n]);let x=(0,o.useMemo)(()=>({show:n,appear:r,initial:m}),[n,r,m]);(0,h.s)(()=>{n?p("visible"):eP(f)||null===s.current||p("hidden")},[n,f]);let b={unmount:i},w=(0,g._)(()=>{var t;m&&v(!1),null==(t=e.beforeEnter)||t.call(e)}),E=(0,g._)(()=>{var t;m&&v(!1),null==(t=e.beforeLeave)||t.call(e)}),k=(0,Z.Ci)();return o.createElement(eC.Provider,{value:f},o.createElement(eS.Provider,{value:x},k({ourProps:{...b,as:o.Fragment,children:o.createElement(eD,{ref:u,...b,...l,beforeEnter:w,beforeLeave:E})},theirProps:{},defaultTag:o.Fragment,features:e_,visible:"visible"===d,name:"Transition"})))}),eD=(0,Z.FX)(function(e,t){var n,r;let{transition:i=!0,beforeEnter:l,afterEnter:s,beforeLeave:a,afterLeave:u,enter:c,enterFrom:d,enterTo:p,entered:f,leave:m,leaveFrom:y,leaveTo:x,...b}=e,[w,k]=(0,o.useState)(null),S=(0,o.useRef)(null),T=ek(e),C=(0,H.P)(...T?[S,t,k]:null===t?[]:[t]),P=null==(n=b.unmount)||n?Z.mK.Unmount:Z.mK.Hidden,{show:A,appear:R,initial:_}=function(){let e=(0,o.useContext)(eS);if(null===e)throw Error("A <Transition.Child /> is used but it is missing a parent <Transition /> or <Transition.Root />.");return e}(),[I,D]=(0,o.useState)(A?"visible":"hidden"),L=function(){let e=(0,o.useContext)(eC);if(null===e)throw Error("A <Transition.Child /> is used but it is missing a parent <Transition /> or <Transition.Root />.");return e}(),{register:M,unregister:F}=L;(0,h.s)(()=>M(S),[M,S]),(0,h.s)(()=>{if(P===Z.mK.Hidden&&S.current)return A&&"visible"!==I?void D("visible"):(0,E.Y)(I,{hidden:()=>F(S),visible:()=>M(S)})},[I,S,M,F,A,P]);let O=z();(0,h.s)(()=>{if(T&&O&&"visible"===I&&null===S.current)throw Error("Did you forget to passthrough the `ref` to the actual DOM node?")},[S,I,O,T]);let j=_&&!R,N=R&&A&&_,V=(0,o.useRef)(!1),B=eA(()=>{V.current||(D("hidden"),F(S))},L),U=(0,g._)(e=>{V.current=!0,B.onStart(S,e?"enter":"leave",e=>{"enter"===e?null==l||l():"leave"===e&&(null==a||a())})}),W=(0,g._)(e=>{let t=e?"enter":"leave";V.current=!1,B.onStop(S,t,e=>{"enter"===e?null==s||s():"leave"===e&&(null==u||u())}),"leave"!==t||eP(B)||(D("hidden"),F(S))});(0,o.useEffect)(()=>{T&&i||(U(A),W(A))},[A,T,i]);let[,q]=function(e,t,n,r){let[i,l]=(0,o.useState)(n),{hasFlag:s,addFlag:a,removeFlag:u}=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,[t,n]=(0,o.useState)(e),r=(0,o.useCallback)(e=>n(e),[t]),i=(0,o.useCallback)(e=>n(t=>t|e),[t]),l=(0,o.useCallback)(e=>(t&e)===e,[t]);return{flags:t,setFlag:r,addFlag:i,hasFlag:l,removeFlag:(0,o.useCallback)(e=>n(t=>t&~e),[n]),toggleFlag:(0,o.useCallback)(e=>n(t=>t^e),[n])}}(e&&i?3:0),c=(0,o.useRef)(!1),d=(0,o.useRef)(!1),p=(0,ee.L)();return(0,h.s)(()=>{var i;if(e){if(n&&l(!0),!t){n&&a(3);return}return null==(i=null==r?void 0:r.start)||i.call(r,n),function(e,t){let{prepare:n,run:r,done:i,inFlight:o}=t,l=(0,v.e)();return function(e,t){let{inFlight:n,prepare:r}=t;if(null!=n&&n.current)return r();let i=e.style.transition;e.style.transition="none",r(),e.offsetHeight,e.style.transition=i}(e,{prepare:n,inFlight:o}),l.nextFrame(()=>{r(),l.requestAnimationFrame(()=>{l.add(function(e,t){var n,r;let i=(0,v.e)();if(!e)return i.dispose;let o=!1;i.add(()=>{o=!0});let l=null!=(r=null==(n=e.getAnimations)?void 0:n.call(e).filter(e=>e instanceof CSSTransition))?r:[];return 0===l.length?t():Promise.allSettled(l.map(e=>e.finished)).then(()=>{o||t()}),i.dispose}(e,i))})}),l.dispose}(t,{inFlight:c,prepare(){d.current?d.current=!1:d.current=c.current,c.current=!0,d.current||(n?(a(3),u(4)):(a(4),u(2)))},run(){d.current?n?(u(3),a(4)):(u(4),a(3)):n?u(1):a(1)},done(){var e;d.current&&"function"==typeof t.getAnimations&&t.getAnimations().length>0||(c.current=!1,u(7),n||l(!1),null==(e=null==r?void 0:r.end)||e.call(r,n))}})}},[e,n,t,p]),e?[i,{closed:s(1),enter:s(2),leave:s(4),transition:s(2)||s(4)}]:[n,{closed:void 0,enter:void 0,leave:void 0,transition:void 0}]}(!(!i||!T||!O||j),w,A,{start:U,end:W}),G=(0,Z.oE)({ref:C,className:(null==(r=(0,eE.x)(b.className,N&&c,N&&d,q.enter&&c,q.enter&&q.closed&&d,q.enter&&!q.closed&&p,q.leave&&m,q.leave&&!q.closed&&y,q.leave&&q.closed&&x,!q.transition&&A&&f))?void 0:r.trim())||void 0,...function(e){let t={};for(let n in e)!0===e[n]&&(t["data-".concat(n)]="");return t}(q)}),X=0;"visible"===I&&(X|=Y.Open),"hidden"===I&&(X|=Y.Closed),q.enter&&(X|=Y.Opening),q.leave&&(X|=Y.Closing);let K=(0,Z.Ci)();return o.createElement(eC.Provider,{value:B},o.createElement($,{value:X},K({ourProps:G,theirProps:b,defaultTag:eR,features:e_,visible:"visible"===I,name:"Transition.Child"})))}),eL=(0,Z.FX)(function(e,t){let n=null!==(0,o.useContext)(eS),r=null!==G();return o.createElement(o.Fragment,null,!n&&r?o.createElement(eI,{ref:t,...e}):o.createElement(eD,{ref:t,...e}))}),eM=Object.assign(eI,{Child:eL,Root:eI});var eF=(e=>(e[e.Open=0]="Open",e[e.Closed=1]="Closed",e))(eF||{}
1),eO=(e=>(e[e.SetTitleId=0]="SetTitleId",e))(eO||{});let ej={0:(e,t)=>e.titleId===t.id?e:{...e,titleId:t.id}},eN=(0,o.createContext)(null);function eV(e){let t=(0,o.useContext)(eN);if(null===t){let t=Error("<".concat(e," /> is missing a parent <Dialog /> component."));throw Error.captureStackTrace&&Error.captureStackTrace(t,eV),t}return t}function eB(e,t){return(0,E.Y)(t.type,ej,e,t)}eN.displayName="DialogContext";let eU=(0,Z.FX)(function(e,t){let n,r,i,l,c,d,f,x,b,S,T,C=(0,o.useId)(),{id:P="headlessui-dialog-".concat(C),open:R,onClose:_,initialFocus:I,role:O="dialog",autoFocus:j=!0,__demoMode:N=!1,unmount:U=!1,...q}=e,$=(0,o.useRef)(!1);O="dialog"===O||"alertdialog"===O?O:($.current||($.current=!0,console.warn("Invalid role [".concat(O,"] passed to <Dialog />. Only `dialog` and and `alertdialog` are supported. Using `dialog` instead."))),"dialog");let K=G();void 0===R&&null!==K&&(R=(K&Y.Open)===Y.Open);let ee=(0,o.useRef)(null),et=(0,H.P)(ee,t),en=F(ee),er=+!R,[ei,eo]=(0,o.useReducer)(eB,{titleId:null,descriptionId:null,panelRef:(0,o.createRef)()}),el=(0,g._)(()=>_(!1)),es=(0,g._)(e=>eo({type:0,id:e})),ec=!!z()&&0===er,[ed,eh]=(n=(0,o.useContext)(eg),r=(0,o.useRef)([]),i=(0,g._)(e=>(r.current.push(e),n&&n.register(e),()=>l(e))),l=(0,g._)(e=>{let t=r.current.indexOf(e);-1!==t&&r.current.splice(t,1),n&&n.unregister(e)}),c=(0,o.useMemo)(()=>({register:i,unregister:l,portals:r}),[i,l,r]),[r,(0,o.useMemo)(()=>function(e){let{children:t}=e;return o.createElement(eg.Provider,{value:c},t)},[c])]),ep=V(),{resolveContainers:ef}=function(){let{defaultContainers:e=[],portals:t,mainTreeNode:n}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},r=F(n),i=(0,g._)(()=>{var i,o;let l=[];for(let t of e)null!==t&&(t instanceof HTMLElement?l.push(t):"current"in t&&t.current instanceof HTMLElement&&l.push(t.current));if(null!=t&&t.current)for(let e of t.current)l.push(e);for(let e of null!=(i=null==r?void 0:r.querySelectorAll("html > *, body > *"))?i:[])e!==document.body&&e!==document.head&&e instanceof HTMLElement&&"headlessui-portal-root"!==e.id&&(n&&(e.contains(n)||e.contains(null==(o=null==n?void 0:n.getRootNode())?void 0:o.host))||l.some(t=>e.contains(t))||l.push(e));return l});
1return{resolveContainers:i,contains:(0,g._)(e=>i().some(t=>t.contains(e)))}}({mainTreeNode:ep,portals:ed,defaultContainers:[{get current(){var em;return null!=(em=ei.panelRef.current)?em:ee.current}}]}),ev=null!==K&&(K&Y.Closing)===Y.Closing;(function(e){let{allowed:t,disallowed:n}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=m(e,"inert-others");(0,h.s)(()=>{var e,i;if(!r)return;let o=(0,v.e)();for(let t of null!=(e=null==n?void 0:n())?e:[])t&&o.add(w(t));let l=null!=(i=null==t?void 0:t())?i:[];for(let e of l){if(!e)continue;let t=(0,y.T)(e);if(!t)continue;let n=e.parentElement;for(;n&&n!==t.body;){for(let e of n.children)l.some(t=>e.contains(t))||o.add(w(e));n=n.parentElement}}return o.dispose},[r,t,n])})(!N&&!ev&&ec,{allowed:(0,g._)(()=>{var e,t;return[null!=(t=null==(e=ee.current)?void 0:e.closest("[data-headlessui-portal]"))?t:null]}),disallowed:(0,g._)(()=>{var e;return[null!=(e=null==ep?void 0:ep.closest("body > *:not(#headlessui-portal-root)"))?e:null]})}),d=m(ec,"outside-click"),f=(0,a.Y)(e=>{e.preventDefault(),el()}),x=(0,o.useCallback)(function(e,t){if(e.defaultPrevented)return;let n=t(e);if(null!==n&&n.getRootNode().contains(n)&&n.isConnected){for(let t of function e(t){return"function"==typeof t?e(t()):Array.isArray(t)||t instanceof Set?t:[t]}(ef))if(null!==t&&(t.contains(n)||e.composed&&e.composedPath().includes(t)))return;return function(e){var t;let n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return e!==(null==(t=(0,y.T)(e))?void 0:t.body)&&(0,E.Y)(n,{0:()=>e.matches(k),1(){let t=e;for(;null!==t;){if(t.matches(k))return!0;t=t.parentElement}return!1}})}(n,A.Loose)||-1===n.tabIndex||e.preventDefault(),f.current(e,n)}},[f,ef]),b=(0,o.useRef)(null),L(d,"pointerdown",e=>{var t,n;b.current=(null==(n=null==(t=e.composedPath)?void 0:t.call(e))?void 0:n[0])||e.target},!0),L(d,"mousedown",e=>{var t,n;b.current=(null==(n=null==(t=e.composedPath)?void 0:t.call(e))?void 0:n[0])||e.target},!0),L(d,"click",e=>{D()||/Android/gi.test(window.navigator.userAgent)||b.current&&(x(e,()=>b.current),b.current=null)},!0),S=(0,o.useRef)({x:0,y:0}),L(d,"touchstart",e=>{S.current.x=e.touches[0].clientX,S.current.y=e.touches[0].clientY},!0),L(d,"touchend",e=>{let t={x:e.changedTouches[0].clientX,y:e.changedTouches[0].clientY};if(!(Math.abs(t.x-S.current.x)>=30||Math.abs(t.y-S.current.y)>=30))return x(e,()=>e.target instanceof HTMLElement?e.target:null)},!0),M(d,"blur",e=>x(e,()=>window.document.activeElement instanceof HTMLIFrameElement?window.document.activeElement:null),!0),function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"undefined"!=typeof document?document.defaultView:null,n=arguments.length>2?arguments[2]:void 0,r=m(e,"escape");u(t,"keydown",e=>{r&&(e.defaultPrevented||e.key===s.Escape&&n(e))})}(ec,null==en?void 0:en.defaultView,e=>{e.preventDefault(),e.stopPropagation(),document.activeElement&&"blur"in document.activeElement&&"function"==typeof document.activeElement.blur&&document.activeElement.blur(),el()}),function(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:()=>[document.body];!function(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:()=>({containers:[]}),r=p(B),i=t?r.get(t):void 0;i&&i.count,(0,h.s)(()=>{if(!(!t||!e))return B.dispatch("PUSH",t,n),()=>B.dispatch("POP",t,n)},[e,t])}(m(e,"scroll-lock"),t,e=>{var t;return{containers:[...null!=(t=e.containers)?t:[],n]}})}(!N&&!ev&&ec,en,ef),T=(0,a.Y)(e=>{let t=e.getBoundingClientRect();0===t.x&&0===t.y&&0===t.width&&0===t.height&&el()}),(0,o.useEffect)(()=>{if(!ec)return;let e=null===ee?null:ee instanceof HTMLElement?ee:ee.current;if(!e)return;let t=(0,v.e)();if("undefined"!=typeof ResizeObserver){let n=new ResizeObserver(()=>T.current(e));n.observe(e),t.add(()=>n.disconnect())}if("undefined"!=typeof IntersectionObserver){let n=new IntersectionObserver(()=>T.current(e));n.observe(e),t.add(()=>n.disconnect())}return()=>t.dispose()},[ee,T,ec]);let[eb,ew]=(0,Q.rU)(),eE=(0,o.useMemo)(()=>[{dialogState:er,close:el,setTitleId:es,unmount:U},ei],[er,ei,el,es,U]),ek=(0,o.useMemo)(()=>({open:0===er}),[er]),eS={ref:et,id:P,role:O,tabIndex:-1,"aria-modal":N?void 0:0===er||void 0,"aria-labelledby":ei.titleId,"aria-describedby":eb,unmount:U},eT=!function(){var e;let[t]=(0,o.useState)(()=>"undefined"!=typeof window&&"function"==typeof window.matchMedia?window.matchMedia("(pointer: coarse)"):null),[n,r]=(0,o.useState)(null!=(e=null==t?void 0:t.matches)&&e);return(0,h.s)(()=>
1{if(t)return t.addEventListener("change",e),()=>t.removeEventListener("change",e);function e(e){r(e.matches)}},[t]),n}(),eC=ea.None;ec&&!N&&(eC|=ea.RestoreFocus,eC|=ea.TabLock,j&&(eC|=ea.AutoFocus),eT&&(eC|=ea.InitialFocus));let eP=(0,Z.Ci)();return o.createElement(X,null,o.createElement(J,{force:!0},o.createElement(ex,null,o.createElement(eN.Provider,{value:eE},o.createElement(ey,{target:ee},o.createElement(J,{force:!1},o.createElement(ew,{slot:ek},o.createElement(eh,null,o.createElement(eu,{initialFocus:I,initialFocusFallback:ee,containers:ef,features:eC},o.createElement(W.e,{value:el},eP({ourProps:eS,theirProps:q,slot:ek,defaultTag:ez,features:eH,visible:0===er,name:"Dialog"})))))))))))}),ez="div",eH=Z.Ac.RenderStrategy|Z.Ac.Static,eW=(0,Z.FX)(function(e,t){let{transition:n=!1,open:r,...i}=e,l=G(),s=e.hasOwnProperty("open")||null!==l,a=e.hasOwnProperty("onClose");if(!s&&!a)throw Error("You have to provide an `open` and an `onClose` prop to the `Dialog` component.");if(!s)throw Error("You provided an `onClose` prop to the `Dialog`, but forgot an `open` prop.");if(!a)throw Error("You provided an `open` prop to the `Dialog`, but forgot an `onClose` prop.");if(!l&&"boolean"!=typeof e.open)throw Error("You provided an `open` prop to the `Dialog`, but the value is not a boolean. Received: ".concat(e.open));if("function"!=typeof e.onClose)throw Error("You provided an `onClose` prop to the `Dialog`, but the value is not a function. Received: ".concat(e.onClose));return(void 0!==r||n)&&!i.static?o.createElement(N,null,o.createElement(eM,{show:r,transition:n,unmount:i.unmount},o.createElement(eU,{ref:t,...i}))):o.createElement(N,null,o.createElement(eU,{ref:t,open:r,...i}))}),eq=(0,Z.FX)(function(e,t){let n=(0,o.useId)(),{id:r="headlessui-dialog-panel-".concat(n),transition:i=!1,...l}=e,[{dialogState:s,unmount:a},u]=eV("Dialog.Panel"),c=(0,H.P)(t,u.panelRef),d=(0,o.useMemo)(()=>({open:0===s}),[s]),h=(0,g._)(e=>{e.stopPropagation()}),p=i?eL:o.Fragment,f=(0,Z.Ci)();return o.createElement(p,{...i?{unmount:a}:{}},f({ourProps:{ref:c,id:r,onClick:h},theirProps:l,slot:d,defaultTag:"div",name:"Dialog.Panel"}))}),eY=(0,Z.FX)(function(e,t){let{transition:n=!1,...r}=e,[{dialogState:i,unmount:l}]=eV("Dialog.Backdrop"),s=(0,o.useMemo)(()=>({open:0===i}),[i]),a=n?eL:o.Fragment,u=(0,Z.Ci)();return o.createElement(a,{...n?{unmount:l}:{}},u({ourProps:{ref:t,"aria-hidden":!0},theirProps:r,slot:s,defaultTag:"div",name:"Dialog.Backdrop"}))}),eG=Object.assign(eW,{Panel:eq,Title:(0,Z.FX)(function(e,t){let n=(0,o.useId)(),{id:r="headlessui-dialog-title-".concat(n),...i}=e,[{dialogState:l,setTitleId:s}]=eV("Dialog.Title"),a=(0,H.P)(t);(0,o.useEffect)(()=>(s(r),()=>s(null)),[r,s]);let u=(0,o.useMemo)(()=>({open:0===l}),[l]);return(0,Z.Ci)()({ourProps:{ref:a,id:r},theirProps:i,slot:u,defaultTag:"h2",name:"Dialog.Title"})}),Description:Q.VY})},71970:(e,t,n)=>{"use strict";n.d(t,{CC:()=>H,Q6:()=>W,bL:()=>z,zi:()=>q});var r=n(32144),i=n(80244),o=n(14558),l=n(40558),s=n(11623),a=n(82306),u=n(40460),c=n(28634),d=n(44362),h=n(40675),p=n(28712),f=n(11612),m=["PageUp","PageDown"],g=["ArrowUp","ArrowDown","ArrowLeft","ArrowRight"],v={"from-left":["Home","PageDown","ArrowDown","ArrowLeft"],"from-right":["Home","PageDown","ArrowDown","ArrowRight"],"from-bottom":["Home","PageDown","ArrowDown","ArrowLeft"],"from-top":["Home","PageDown","ArrowUp","ArrowLeft"]},y="Slider",[x,b,w]=(0,p.N)(y),[E,k]=(0,s.A)(y,[w]),[S,T]=E(y),C=r.forwardRef((e,t)=>{let{name:n,min:l=0,max:s=100,step:u=1,orientation:c="horizontal",disabled:d=!1,minStepsBetweenThumbs:h=0,defaultValue:p=[l],value:v,onValueChange:y=()=>{},onValueCommit:b=()=>{},inverted:w=!1,form:E,...k}=e,T=r.useRef(new Set),C=r.useRef(0),P="horizontal"===c,[A=[],I]=(0,a.i)({prop:v,defaultProp:p,onChange:e=>{var t;null==(t=[...T.current][C.current])||t.focus(),y(e)}}),D=r.useRef(A);function L(e,t){let{commit:n}=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{commit:!1},r=(String(u).split(".")[1]||"").length,o=function(e,t){let n=Math.pow(10,t);return Math.round(e*n)/n}(Math.round((e-l)/u)*u+l,r),a=(0,i.q)(o,[l,s]);I(function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],r=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1?arguments[1]:void 0,n=arguments.length>2?arguments[2]:void 0,r=[...e];return r[n]=t,r.sort((e,t)=>
1e-t)}(e,a,t);if(!function(e,t){if(t>0)return Math.min(...e.slice(0,-1).map((t,n)=>e[n+1]-t))>=t;return!0}(r,h*u))return e;{C.current=r.indexOf(a);let t=String(r)!==String(e);return t&&n&&b(r),t?r:e}})}return(0,f.jsx)(S,{scope:e.__scopeSlider,name:n,disabled:d,min:l,max:s,valueIndexToChangeRef:C,thumbs:T.current,values:A,orientation:c,form:E,children:(0,f.jsx)(x.Provider,{scope:e.__scopeSlider,children:(0,f.jsx)(x.Slot,{scope:e.__scopeSlider,children:(0,f.jsx)(P?R:_,{"aria-disabled":d,"data-disabled":d?"":void 0,...k,ref:t,onPointerDown:(0,o.m)(k.onPointerDown,()=>{d||(D.current=A)}),min:l,max:s,inverted:w,onSlideStart:d?void 0:function(e){let t=function(e,t){if(1===e.length)return 0;let n=e.map(e=>Math.abs(e-t)),r=Math.min(...n);return n.indexOf(r)}(A,e);L(e,t)},onSlideMove:d?void 0:function(e){L(e,C.current)},onSlideEnd:d?void 0:function(){let e=D.current[C.current];A[C.current]!==e&&b(A)},onHomeKeyDown:()=>!d&&L(l,0,{commit:!0}),onEndKeyDown:()=>!d&&L(s,A.length-1,{commit:!0}),onStepKeyDown:e=>{let{event:t,direction:n}=e;if(!d){let e=m.includes(t.key)||t.shiftKey&&g.includes(t.key),r=C.current;L(A[r]+u*(e?10:1)*n,r,{commit:!0})}}})})})})});C.displayName=y;var[P,A]=E(y,{startEdge:"left",endEdge:"right",size:"width",direction:1}),R=r.forwardRef((e,t)=>{let{min:n,max:i,dir:o,inverted:s,onSlideStart:a,onSlideMove:c,onSlideEnd:d,onStepKeyDown:h,...p}=e,[m,g]=r.useState(null),y=(0,l.s)(t,e=>g(e)),x=r.useRef(),b=(0,u.jH)(o),w="ltr"===b,E=w&&!s||!w&&s;function k(e){let t=x.current||m.getBoundingClientRect(),r=U([0,t.width],E?[n,i]:[i,n]);return x.current=t,r(e-t.left)}return(0,f.jsx)(P,{scope:e.__scopeSlider,startEdge:E?"left":"right",endEdge:E?"right":"left",direction:E?1:-1,size:"width",children:(0,f.jsx)(I,{dir:b,"data-orientation":"horizontal",...p,ref:y,style:{...p.style,"--radix-slider-thumb-transform":"translateX(-50%)"},onSlideStart:e=>{let t=k(e.clientX);null==a||a(t)},onSlideMove:e=>{let t=k(e.clientX);null==c||c(t)},onSlideEnd:()=>{x.current=void 0,null==d||d()},onStepKeyDown:e=>{let t=v[E?"from-left":"from-right"].includes(e.key);null==h||h({event:e,direction:t?-1:1})}})})}),_=r.forwardRef((e,t)=>{let{min:n,max:i,inverted:o,onSlideStart:s,onSlideMove:a,onSlideEnd:u,onStepKeyDown:c,...d}=e,h=r.useRef(null),p=(0,l.s)(t,h),m=r.useRef(),g=!o;function y(e){let t=m.current||h.current.getBoundingClientRect(),r=U([0,t.height],g?[i,n]:[n,i]);return m.current=t,r(e-t.top)}return(0,f.jsx)(P,{scope:e.__scopeSlider,startEdge:g?"bottom":"top",endEdge:g?"top":"bottom",size:"height",direction:g?1:-1,children:(0,f.jsx)(I,{"data-orientation":"vertical",...d,ref:p,style:{...d.style,"--radix-slider-thumb-transform":"translateY(50%)"},onSlideStart:e=>{let t=y(e.clientY);null==s||s(t)},onSlideMove:e=>{let t=y(e.clientY);null==a||a(t)},onSlideEnd:()=>{m.current=void 0,null==u||u()},onStepKeyDown:e=>{let t=v[g?"from-bottom":"from-top"].includes(e.key);null==c||c({event:e,direction:t?-1:1})}})})}),I=r.forwardRef((e,t)=>{let{__scopeSlider:n,onSlideStart:r,onSlideMove:i,onSlideEnd:l,onHomeKeyDown:s,onEndKeyDown:a,onStepKeyDown:u,...c}=e,d=T(y,n);return(0,f.jsx)(h.sG.span,{...c,ref:t,onKeyDown:(0,o.m)(e.onKeyDown,e=>{"Home"===e.key?(s(e),e.preventDefault()):"End"===e.key?(a(e),e.preventDefault()):m.concat(g).includes(e.key)&&(u(e),e.preventDefault())}),onPointerDown:(0,o.m)(e.onPointerDown,e=>{let t=e.target;t.setPointerCapture(e.pointerId),e.preventDefault(),d.thumbs.has(t)?t.focus():r(e)}),onPointerMove:(0,o.m)(e.onPointerMove,e=>{e.target.hasPointerCapture(e.pointerId)&&i(e)}),onPointerUp:(0,o.m)(e.onPointerUp,e=>{let t=e.target;t.hasPointerCapture(e.pointerId)&&(t.releasePointerCapture(e.pointerId),l(e))})})}),D="SliderTrack",L=r.forwardRef((e,t)=>{let{__scopeSlider:n,...r}=e,i=T(D,n);return(0,f.jsx)(h.sG.span,{"data-disabled":i.disabled?"":void 0,"data-orientation":i.orientation,...r,ref:t})});L.displayName=D;var M="SliderRange",F=r.forwardRef((e,t)=>{let{__scopeSlider:n,...i}=e,o=T(M,n),s=A(M,n),a=r.useRef(null),u=(0,l.s)(t,a),c=o.values.length,d=o.values.map(e=>B(e,o.min,o.max)),p=c>1?Math.min(...d):0,m=100-Math.max(...d);return(0,f.jsx)(h.sG.span,{"data-orientation":o.orientation,"data-disabled":o.disabled?"":void 0,...i,ref:u,style:{...e.style,[s.startEdge]:p+"%",[s.endEdge]:m+"%"}})});F.displayName=M;var O="SliderThumb",j=r.forwardRef((e,t)=>
1{let n=b(e.__scopeSlider),[i,o]=r.useState(null),s=(0,l.s)(t,e=>o(e)),a=r.useMemo(()=>i?n().findIndex(e=>e.ref.current===i):-1,[n,i]);return(0,f.jsx)(N,{...e,ref:s,index:a})}),N=r.forwardRef((e,t)=>{let{__scopeSlider:n,index:i,name:s,...a}=e,u=T(O,n),c=A(O,n),[p,m]=r.useState(null),g=(0,l.s)(t,e=>m(e)),v=!p||u.form||!!p.closest("form"),y=(0,d.X)(p),b=u.values[i],w=void 0===b?0:B(b,u.min,u.max),E=function(e,t){return t>2?"Value ".concat(e+1," of ").concat(t):2===t?["Minimum","Maximum"][e]:void 0}(i,u.values.length),k=null==y?void 0:y[c.size],S=k?function(e,t,n){let r=e/2,i=U([0,50],[0,r]);return(r-i(t)*n)*n}(k,w,c.direction):0;return r.useEffect(()=>{if(p)return u.thumbs.add(p),()=>{u.thumbs.delete(p)}},[p,u.thumbs]),(0,f.jsxs)("span",{style:{transform:"var(--radix-slider-thumb-transform)",position:"absolute",[c.startEdge]:"calc(".concat(w,"% + ").concat(S,"px)")},children:[(0,f.jsx)(x.ItemSlot,{scope:e.__scopeSlider,children:(0,f.jsx)(h.sG.span,{role:"slider","aria-label":e["aria-label"]||E,"aria-valuemin":u.min,"aria-valuenow":b,"aria-valuemax":u.max,"aria-orientation":u.orientation,"data-orientation":u.orientation,"data-disabled":u.disabled?"":void 0,tabIndex:u.disabled?void 0:0,...a,ref:g,style:void 0===b?{display:"none"}:e.style,onFocus:(0,o.m)(e.onFocus,()=>{u.valueIndexToChangeRef.current=i})})}),v&&(0,f.jsx)(V,{name:null!=s?s:u.name?u.name+(u.values.length>1?"[]":""):void 0,form:u.form,value:b},i)]})});j.displayName=O;var V=e=>{let{value:t,...n}=e,i=r.useRef(null),o=(0,c.Z)(t);return r.useEffect(()=>{let e=i.current,n=Object.getOwnPropertyDescriptor(window.HTMLInputElement.prototype,"value").set;if(o!==t&&n){let r=new Event("input",{bubbles:!0});n.call(e,t),e.dispatchEvent(r)}},[o,t]),(0,f.jsx)("input",{style:{display:"none"},...n,ref:i,defaultValue:t})};function B(e,t,n){return(0,i.q)(100/(n-t)*(e-t),[0,100])}function U(e,t){return n=>{if(e[0]===e[1]||t[0]===t[1])return t[0];let r=(t[1]-t[0])/(e[1]-e[0]);return t[0]+r*(n-e[0])}}var z=C,H=L,W=F,q=j},72636:(e,t,n)=>{"use strict";let r;n.d(t,{Y_:()=>eO});var i,o,l=n(32144),s="vercel.ai.error",a=Symbol.for(s),u=class e extends Error{constructor({name:e,message:t,cause:n}){super(t),this[i]=!0,this.name=e,this.cause=n}static isInstance(t){return e.hasMarker(t,s)}static hasMarker(e,t){let n=Symbol.for(t);return null!=e&&"object"==typeof e&&n in e&&"boolean"==typeof e[n]&&!0===e[n]}toJSON(){return{name:this.name,message:this.message}}};i=a;var c=u,d=(Symbol.for("vercel.ai.error.AI_APICallError"),Symbol.for("vercel.ai.error.AI_EmptyResponseBodyError"),"AI_InvalidArgumentError"),h=`vercel.ai.error.${d}`,p=Symbol.for(h),f=class extends c{constructor({message:e,cause:t,argument:n}){super({name:d,message:e,cause:t}),this[o]=!0,this.argument=n}static isInstance(e){return c.hasMarker(e,h)}};o=p,Symbol.for("vercel.ai.error.AI_InvalidPromptError"),Symbol.for("vercel.ai.error.AI_InvalidResponseDataError"),Symbol.for("vercel.ai.error.AI_JSONParseError"),Symbol.for("vercel.ai.error.AI_LoadAPIKeyError"),Symbol.for("vercel.ai.error.AI_LoadSettingError"),Symbol.for("vercel.ai.error.AI_NoContentGeneratedError"),Symbol.for("vercel.ai.error.AI_NoSuchModelError"),Symbol.for("vercel.ai.error.AI_TooManyEmbeddingValuesForCallError"),Symbol.for("vercel.ai.error.AI_TypeValidationError"),Symbol.for("vercel.ai.error.AI_UnsupportedFunctionalityError");var m=n(9519);n(37811);var g=(({prefix:e,size:t=7,alphabet:n="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz",separator:r="-"}={})=>{let i=((e,t=21)=>(n=t)=>{let r="",i=n;for(;i--;)r+=e[Math.random()*e.length|0];return r})(n,t);if(null==e)return i;if(n.includes(r))throw new f({argument:"separator",message:`The separator "${r}" must not be part of the alphabet "${n}".`});return t=>`${e}${r}${i(t)}`})();Symbol.for("vercel.ai.validator");var{btoa:v,atob:y}=globalThis;Symbol("Let zodToJsonSchema decide on which parser to use");var x={code:"0",name:"text",parse:e=>{if("string"!=typeof e)throw Error('"text" parts expect a string value.');return{type:"text",value:e}}},b={code:"1",name:"function_call",parse:e=>{if(null==e||"object"!=typeof e||!("function_call"in e)||"object"!=typeof e.function_call||null==e.function_call||!("name"in e.function_call)||!("arguments"in e.function_call)||"string"!=typeof e.function_call.name||"string"!=typeof e.function_call.arguments)throw Error('"function_call" parts expect an object with a "function_call" property.');return{type:"function_call",value:e}}},w={code:"2",name:"data",parse:e=>{if(!Array.isArray(e))throw Error('"data" parts expect an array value.');return{type:"data",value:e}}},E={code:"3",name:"error",parse:e=>{if("string"!=typeof e)throw Error('"error" parts expect a string value.');return{type:"error",value:e}}},k={code:"4",name:"assistant_message",parse:e=>{if(null==e||"object"!=typeof e||!("id"in e)||!("role"in e)||!("content"in e)||"string"!=typeof e.id||"string"!=typeof e.role||"assistant"!==e.role||!Array.isArray(e.content)||!e.content.every(e=>null!=e&&"object"==typeof e&&"type"in e&&"text"===e.type&&"text"in e&&null!=e.text&&"object"==typeof e.text&&"value"in e.text&&"string"==typeof e.text.value))throw Error('"assistant_message" parts expect an object with an "id", "role", and "content" property.');return{type:"assistant_message",value:e}}},S={code:"5",name:"assistant_control_data",parse:e=>{if(null==e||"object"!=typeof e||!("threadId"in e)||!("messageId"in e)||"string"!=typeof e.threadId||"string"!=typeof e.messageId)throw Error('"assistant_control_data" parts expect an object with a "threadId" and "messageId" property.');return{type:"assistant_control_data",value:{threadId:e.threadId,messageId:e.messageId}}}},T={code:"6",name:"data_message",parse:e=>{if(null==e||"object"!=typeof e||!("role"in e)||!("data"in e)||"string"!=typeof e.role||"data"!==e.role)throw Error('"data_message" parts expect an object with a "role" and "data" property.');return{type:"data_message",value:e}}},C={code:"7",name:"tool_calls",parse:e=>{if(null==e||"object"!=typeof e||!("tool_calls"in e)||"object"!=typeof e.tool_calls||null==e.tool_calls||!Array.isArray(e.tool_calls)||e.tool_calls.some(e=>null==e||"object"!=typeof e||!("id"in e)||"string"!=typeof e.id||!("type"in e)||"string"!=typeof e.type||!("function"in e)||null==e.function||"object"!=typeof e.function||!("arguments"in e.function)||"string"!=typeof e.function.name||"string"!=typeof e.function.arguments))throw Error('"tool_calls" parts expect an object with a ToolCallPayload.');return{type:"tool_calls",value:e}}},P={code:"8",name:"message_annotations",parse:e=>{if(!Array.isArray(e))throw Error('"message_annotations" parts expect an array value.');return{type:"message_annotations",value:e}}},A={code:"9",name:"tool_call",parse:e=>{if(null==e||"object"!=typeof e||!("toolCallId"in e)||"string"!=typeof e.toolCallId||!("toolName"in e)||"string"!=typeof e.toolName||!("args"in e)||"object"!=typeof e.args)throw Error('"tool_call" parts expect an object with a "toolCallId", "toolName", and "args" property.');return{type:"tool_call",value:e}}},R={code:"a",name:"tool_result",parse:e=>{if(null==e||"object"!=typeof e||!("toolCallId"in e)||"string"!=typeof e.toolCallId||!("result"in e))throw Error('"tool_result" parts expect an object with a "toolCallId" and a "result" property.');return{type:"tool_result",value:e}}},_={code:"b",name:"tool_call_streaming_start",parse:e=>{if(null==e||"object"!=typeof e||!("toolCallId"in e)||"string"!=typeof e.toolCallId||!("toolName"in e)||"string"!=typeof e.toolName)throw Error('"tool_call_streaming_start" parts expect an object with a "toolCallId" and "toolName" property.');return{type:"tool_call_streaming_start",value:e}}},I={code:"c",name:"tool_call_delta",parse:e=>{if(null==e||"object"!=typeof e||!("toolCallId"in e)||"string"!=typeof e.toolCallId||!("argsTextDelta"in e)||"string"!=typeof e.argsTextDelta)throw Error('"tool_call_delta" parts expect an object with a "toolCallId" and "argsTextDelta" property.');return{type:"tool_call_delta",value:e}}},D={code:"d",name:"finish_message",parse:e=>{if(null==e||"object"!=typeof e||!("finishReason"in e)||"string"!=typeof e.finishReason)throw Error('"finish_message" parts expect an object with a "finishReason" property.');let t={finishReason:e.finishReason};return"usage"in e&&null!=e.usage&&"object"==typeof e.usage&&"promptTokens"in e.usage&&"completionTokens"in e.usage&&(t.usage={promptTokens:"number"==typeof e.usage.promptTokens?e.usage.promptTokens:NaN,completionTokens:"number"==typeof e.usage.completionTokens?e.usage.completionTokens:NaN}),{type:"finish_message",value:t}}},L={code:"e",name:"finish_step",parse:e=>{if(null==e||"object"!=typeof e||!("finishReason"in e)||"string"!=typeof e.finishReason)throw Error('"finish_step" parts expect an object with a "finishReason" property.');let t={finishReason:e.finishReason,isContinued:!1};return"usage"in e&&null!=e.usage&&"object"==typeof e.usage&&"promptTokens"in e.usage&&"completionTokens"in e.usage&&(t.usage={promptTokens:"number"==typeof e.usage.promptTokens?e.usage.promptTokens:NaN,completionTokens:"number"==typeof e.usage.completionTokens?e.usage.completionTokens:NaN}),"isContinued"in e&&"boolean"==typeof e.isContinued&&(t.isContinued=e.isContinued),{type:"finish_step",value:t}}},M=[x,b,w,E,k,S,T,C,P,A,R,_,I,D,L],F={[x.code]:x,[b.code]:b,[w.code]:w,[E.code]:E,[k.code]:k,[S.code]:S,[T.code]:T,[C.c
1ode]:C,[P.code]:P,[A.code]:A,[R.code]:R,[_.code]:_,[I.code]:I,[D.code]:D,[L.code]:L};x.name,x.code,b.name,b.code,w.name,w.code,E.name,E.code,k.name,k.code,S.name,S.code,T.name,T.code,C.name,C.code,P.name,P.code,A.name,A.code,R.name,R.code,_.name,_.code,I.name,I.code,D.name,D.code,L.name,L.code;var O=M.map(e=>e.code),j=e=>{let t=e.indexOf(":");if(-1===t)throw Error("Failed to parse stream string. No separator found.");let n=e.slice(0,t);if(!O.includes(n))throw Error(`Failed to parse stream string. Invalid code ${n}.`);let r=JSON.parse(e.slice(t+1));return F[n].parse(r)};async function*N(e,{isAborted:t}={}){let n=new TextDecoder,r=[],i=0;for(;;){let{value:o}=await e.read();if(o&&(r.push(o),i+=o.length,10!==o[o.length-1]))continue;if(0===r.length)break;let l=function(e,t){let n=new Uint8Array(t),r=0;for(let t of e)n.set(t,r),r+=t.length;return e.length=0,n}(r,i);for(let e of(i=0,n.decode(l,{stream:!0}).split("\n").filter(e=>""!==e).map(j)))yield e;if(null==t?void 0:t()){e.cancel();break}}}function V(e,t){return e&&t&&t.length?{...e,annotations:[...t]}:e}async function B({reader:e,abortControllerRef:t,update:n,onToolCall:r,onFinish:i,generateId:o=g,getCurrentDate:l=()=>new Date}){var s;let a,u,c=l(),d={},h=[],p=[],f={},v={completionTokens:NaN,promptTokens:NaN,totalTokens:NaN},y="unknown";for await(let{type:i,value:l}of N(e,{isAborted:()=>(null==t?void 0:t.current)===null})){if("error"===i)throw Error(l);if("finish_step"===i){l.isContinued||(a={});continue}if("finish_message"===i){if(y=l.finishReason,null!=l.usage){let{completionTokens:e,promptTokens:t}=l.usage;v={completionTokens:e,promptTokens:t,totalTokens:e+t}}continue}if(null!=a&&("text"===i||"tool_call"===i||"tool_call_streaming_start"===i||"tool_call_delta"===i||"tool_result"===i)&&(d.text&&h.push(d.text),d.function_call&&h.push(d.function_call),d.tool_calls&&h.push(d.tool_calls),d=a,a=void 0),"text"===i&&(d.text?d.text={...d.text,content:(d.text.content||"")+l}:d.text={id:o(),role:"assistant",content:l,createdAt:c}),"tool_call_streaming_start"===i)null==d.text&&(d.text={id:o(),role:"assistant",content:"",createdAt:c}),null==d.text.toolInvocations&&(d.text.toolInvocations=[]),f[l.toolCallId]={text:"",toolName:l.toolName,prefixMapIndex:d.text.toolInvocations.length},d.text.toolInvocations.push({state:"partial-call",toolCallId:l.toolCallId,toolName:l.toolName,args:void 0});else if("tool_call_delta"===i){let e=f[l.toolCallId];e.text+=l.argsTextDelta;let{value:t}=function(e){if(void 0===e)return{value:void 0,state:"undefined-input"};try{return{value:m.parse(e),state:"successful-parse"}}catch(t){try{return{value:m.parse(function(e){let t=["ROOT"],n=-1,r=null;function i(e,i,o){switch(e){case'"':n=i,t.pop(),t.push(o),t.push("INSIDE_STRING");break;case"f":case"t":case"n":n=i,r=i,t.pop(),t.push(o),t.push("INSIDE_LITERAL");break;case"-":t.pop(),t.push(o),t.push("INSIDE_NUMBER");break;case"0":case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":n=i,t.pop(),t.push(o),t.push("INSIDE_NUMBER");break;case"{":n=i,t.pop(),t.push(o),t.push("INSIDE_OBJECT_START");break;case"[":n=i,t.pop(),t.push(o),t.push("INSIDE_ARRAY_START")}}function o(e,r){switch(e){case",":t.pop(),t.push("INSIDE_OBJECT_AFTER_COMMA");break;case"}":n=r,t.pop()}}function l(e,r){switch(e){case",":t.pop(),t.push("INSIDE_ARRAY_AFTER_COMMA");break;case"]":n=r,t.pop()}}for(let s=0;s<e.length;s++){let a=e[s];switch(t[t.length-1]){case"ROOT":i(a,s,"FINISH");break;case"INSIDE_OBJECT_START":switch(a){case'"':t.pop(),t.push("INSIDE_OBJECT_KEY");break;case"}":n=s,t.pop()}break;case"INSIDE_OBJECT_AFTER_COMMA":'"'===a&&(t.pop(),t.push("INSIDE_OBJECT_KEY"));break;case"INSIDE_OBJECT_KEY":'"'===a&&(t.pop(),t.push("INSIDE_OBJECT_AFTER_KEY"));break;case"INSIDE_OBJECT_AFTER_KEY":":"===a&&(t.pop(),t.push("INSIDE_OBJECT_BEFORE_VALUE"));break;case"INSIDE_OBJECT_BEFORE_VALUE":i(a,s,"INSIDE_OBJECT_AFTER_VALUE");break;case"INSIDE_OBJECT_AFTER_VALUE":o(a,s);break;case"INSIDE_STRING":switch(a){case'"':t.pop(),n=s;break;case"\\":t.push("INSIDE_STRING_ESCAPE");break;default:n=s}break;case"INSIDE_ARRAY_START":"]"===a?(n=s,t.pop()):(n=s,i(a,s,"INSIDE_ARRAY_AFTER_VALUE"));break;case"INSIDE_ARRAY_AFTER_VALUE":switch(a){case",":t.pop(),t.push("INSIDE_ARRAY_AFTER_COMMA");break;case"]":n=s,t.pop();break;default:n=s}break;case"INSIDE_ARRAY_AFTER_COMMA":i(a,s,"INSIDE_ARRAY_AFTER_VALUE");break;case"INSIDE_STRING_ESCAPE":t.pop(),n=s;break;case"INSIDE_NUMBER":switch(a){case"0":case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":n=s;break;case"e":case"E":case"-":case".":break;case",":t.pop(),"INSIDE_ARRAY_AFTER_VALUE"===t[t.length-1]&&l(a,s),"INSIDE_OBJECT_AFTER_VALUE"===t[t.length-1]&&o(a,s);break;case"}":t.pop(),"INSIDE_OBJECT_AFTER_VALUE"===t[t.length-1]&&o(a,s);break;case"]":t.pop(),"INSIDE_ARRAY_AFTER_VALUE"===t[t.length-1]&&l(a,s);break;default:t.pop()}break;case"INSIDE_LITERAL":{let i=e.substring(r,s+1);"false".startsWith(i)||"true".startsWith(i)||"null".startsWith(i)?n=s:(t.pop(),"INSIDE_OBJECT_AFTER_VALUE"===t[t.length-1]?o(a,s):"INSIDE_ARRAY_AFTER_VALUE"===t[t.length-1]&&l(a,s))}}}let s=e.slice(0,n+1);for(let n=t.length-1;n>=0;n--)switch(t[n]){case"INSIDE_STRING":s+='"';break;case"INSIDE_OBJECT_KEY":case"INSIDE_OBJECT_AFTER_KEY":case"INSIDE_OBJECT_AFTER_COMMA":case"INSIDE_OBJECT_START":case"INSIDE_OBJECT_BEFORE_VALUE":case"INSIDE_OBJECT_AFTER_VALUE":s+="}";break;case"INSIDE_ARRAY_START":case"INSIDE_ARRAY_AFTER_COMMA":case"INSIDE_ARRAY_AFTER_VALUE":s+="]";break;case"INSIDE_LITERAL":{let t=e.substring(r,e.length);"true".startsWith(t)?s+="true".slice(t.length):"false".startsWith(t)?s+="false".slice(t.length):"null".startsWith(t)&&(s+="null".slice(t.length))}}return s}(e)),state:"repaired-parse"}}catch(e){}}return{value:void 0,state:"failed-parse"}}(e.text);d.text.toolInvocations[e.prefixMapIndex]={state:"partial-call",toolCallId:l.toolCallId,toolName:e.toolName,args:t},d.text.internalUpdateId=o()}else if("tool_call"===i){if(null!=f[l.toolCallId]?d.text.toolInvocations[f[l.toolCallId].prefixMapIndex]={state:"call",...l}:(null==d.text&&(d.text={id:o(),role:"assistant",content:"",createdAt:c}),null==d.text.toolInvocations&&(d.text.toolInvocations=[]),d.text.toolInvocations.push({state:"call",...l})),d.text.internalUpdateId=o(),r){let e=await r({toolCall:l});null!=e&&(d.text.toolInvocations[d.text.toolInvocations.length-1]={state:"result",...l,result:e})}}else if("tool_result"===i){let e=null==(s=d.text)?void 0:s.toolInvocations;if(null==e)throw Error("tool_result must be preceded by a tool_call");let t=e.findIndex(e=>e.toolCallId===l.toolCallId);if(-1===t)throw Error("tool_result must be preceded by a tool_call with the same toolCallId");e[t]={...e[t],state:"result",...l}}let e=null;"function_call"===i&&(d.function_call={id:o(),role:"assistant",content:"",function_call:l.function_call,name:l.function_call.name,createdAt:c},e=d.function_call);let t=null;"tool_calls"===i&&(d.tool_calls={id:o(),role:"assistant",content:"",tool_calls:l.tool_calls,createdAt:c},t=d.tool_calls),"data"===i&&p.push(...l);let g=d.text;"message_annotations"===i&&(u?u.push(...l):u=[...l],e=V(d.function_call,u),t=V(d.tool_calls,u),g=V(d.text,u),null!=d.text&&(d.text.internalUpdateId=o())),(null==u?void 0:u.length)&&(d.text&&(d.text.annotations=[...u]),d.function_call&&(d.function_call.annotations=[...u]),d.tool_calls&&(d.tool_calls.annotations=[...u])),n([...h,...[e,t,g].filter(
1Boolean).map(e=>({...V(e,u)}))],[...p])}return null==i||i({message:d.text,finishReason:y,usage:v}),{messages:[d.text,d.function_call,d.tool_calls].filter(Boolean),data:p}}async function U({api:e,body:t,streamProtocol:n="data",credentials:r,headers:i,abortController:o,restoreMessagesOnFailure:l,onResponse:s,onUpdate:a,onFinish:u,onToolCall:c,generateId:d,fetch:h=fetch}){var p,f;let m=await h(e,{method:"POST",body:JSON.stringify(t),headers:{"Content-Type":"application/json",...i},signal:null==(p=null==o?void 0:o())?void 0:p.signal,credentials:r}).catch(e=>{throw l(),e});if(s)try{await s(m)}catch(e){throw e}if(!m.ok)throw l(),Error(null!=(f=await m.text())?f:"Failed to fetch the chat response.");if(!m.body)throw Error("The response body is empty.");let g=m.body.getReader();switch(n){case"text":{let e=function(e){let t=new TextDecoder;return function(e){return e?t.decode(e,{stream:!0}):""}}(),t={id:d(),createdAt:new Date,role:"assistant",content:""};for(;;){let{done:n,value:r}=await g.read();if(n)break;if(t.content+=e(r),a([{...t}],[]),(null==o?void 0:o())===null){g.cancel();break}}return null==u||u(t,{usage:{completionTokens:NaN,promptTokens:NaN,totalTokens:NaN},finishReason:"unknown"}),{messages:[t],data:[]}}case"data":return await B({reader:g,abortControllerRef:null!=o?{current:o()}:void 0,update:a,onToolCall:c,onFinish({message:e,finishReason:t,usage:n}){u&&null!=e&&u(e,{usage:n,finishReason:t})},generateId:d});default:throw Error(`Unknown stream protocol: ${n}`)}}async function z({getStreamedResponse:e,experimental_onFunctionCall:t,experimental_onToolCall:n,updateChatRequest:r,getCurrentMessages:i}){for(;;){let o=await e();if("messages"in o){let e=!1;for(let l of o.messages)if(void 0!==l.function_call&&"string"!=typeof l.function_call||void 0!==l.tool_calls&&"string"!=typeof l.tool_calls){if(e=!0,t){let n=l.function_call;if("object"!=typeof n){console.warn("experimental_onFunctionCall should not be defined when using tools");continue}let o=await t(i(),n);if(void 0===o){e=!1;break}r(o)}if(n){let t=l.tool_calls;if(!Array.isArray(t)||t.some(e=>"object"!=typeof e)){console.warn("experimental_onToolCall should not be defined when using tools");continue}let o=await n(i(),t);if(void 0===o){e=!1;break}r(o)}}if(!e)break}else{let e=function(e){for(let t of e.messages){if(void 0!==t.tool_calls)for(let e of t.tool_calls)"object"==typeof e&&e.function.arguments&&"string"!=typeof e.function.arguments&&(e.function.arguments=JSON.stringify(e.function.arguments));void 0!==t.function_call&&"object"==typeof t.function_call&&t.function_call.arguments&&"string"!=typeof t.function_call.arguments&&(t.function_call.arguments=JSON.stringify(t.function_call.arguments))}};if((void 0===o.function_call||"string"==typeof o.function_call)&&(void 0===o.tool_calls||"string"==typeof o.tool_calls))break;if(t){let n=o.function_call;if("object"!=typeof n){console.warn("experimental_onFunctionCall should not be defined when using tools");continue}let l=await t(i(),n);if(void 0===l)break;e(l),r(l)}if(n){let t=o.tool_calls;if("object"!=typeof t){console.warn("experimental_onToolCall should not be defined when using functions");continue}let l=await n(i(),t);if(void 0===l)break;e(l),r(l)}}}}Symbol.for("vercel.ai.schema");var H=n(33336);let W=()=>{},q=W(),Y=Object,G=e=>e===q,$=(e,t)=>({...e,...t}),X=new WeakMap,K=0,J=e=>{let t,n,r=typeof e,i=e&&e.constructor,o=i==Date;if(Y(e)!==e||o||i==RegExp)t=o?e.toJSON():"symbol"==r?e.toString():"string"==r?JSON.stringify(e):""+e;else{if(t=X.get(e))return t;if(t=++K+"~",X.set(e,t),i==Array){for(n=0,t="@";n<e.length;n++)t+=J(e[n])+",";X.set(e,t)}if(i==Y){t="#";let r=Y.keys(e).sort();for(;!G(n=r.pop());)G(e[n])||(t+=n+":"+J(e[n])+",");X.set(e,t)}}return t},Z=new WeakMap,Q={},ee={},et="undefined",en=typeof window!=et,er=typeof document!=et,ei=(e,t)=>{let n=Z.get(e);return[()=>!G(t)&&e.get(t)||Q,r=>{if(!G(t)){let i=e.get(t);t in ee||(ee[t]=i),n[5](t,$(i,r),i||Q)}},n[6],()=>!G(t)&&t in ee?ee[t]:!G(t)&&e.get(t)||Q]},eo=!0,[el,es]=en&&window.addEventListener?[window.addEventListener.bind(window),window.removeEventListener.bind(window)]:[W,W],ea={initFocus:e=>(er&&document.addEventListener("visibilitychange",e),el("focus",e),()=>{er&&document.removeEventListener("visibilitychange",e),es("focus",e)}),initReconnect:e=>{let t=()=>{eo=!0,e()},n=()=>{eo=!1};
1return el("online",t),el("offline",n),()=>{es("online",t),es("offline",n)}}},eu=!l.useId,ec=!en||"Deno"in window,ed=ec?l.useEffect:l.useLayoutEffect,eh="undefined"!=typeof navigator&&navigator.connection,ep=!ec&&eh&&(["slow-2g","2g"].includes(eh.effectiveType)||eh.saveData),ef=e=>{if("function"==typeof e)try{e=e()}catch(t){e=""}let t=e;return[e="string"==typeof e?e:(Array.isArray(e)?e.length:e)?J(e):"",t]},em=0,eg=()=>++em;var ev={ERROR_REVALIDATE_EVENT:3,FOCUS_EVENT:0,MUTATE_EVENT:2,RECONNECT_EVENT:1};async function ey(...e){let[t,n,r,i]=e,o=$({populateCache:!0,throwOnError:!0},"boolean"==typeof i?{revalidate:i}:i||{}),l=o.populateCache,s=o.rollbackOnError,a=o.optimisticData,u=o.throwOnError;if("function"==typeof n){let e=[];for(let r of t.keys())!/^\$(inf|sub)\$/.test(r)&&n(t.get(r)._k)&&e.push(r);return Promise.all(e.map(c))}return c(n);async function c(n){let i,[c]=ef(n);if(!c)return;let[d,h]=ei(t,c),[p,f,m,g]=Z.get(t),v=()=>{let e=p[c];return("function"==typeof o.revalidate?o.revalidate(d().data,n):!1!==o.revalidate)&&(delete m[c],delete g[c],e&&e[0])?e[0](2).then(()=>d().data):d().data};if(e.length<3)return v();let y=r,x=eg();f[c]=[x,0];let b=!G(a),w=d(),E=w.data,k=w._c,S=G(k)?E:k;if(b&&h({data:a="function"==typeof a?a(S,E):a,_c:S}),"function"==typeof y)try{y=y(S)}catch(e){i=e}if(y&&"function"==typeof y.then){let e;if(y=await y.catch(e=>{i=e}),x!==f[c][0]){if(i)throw i;return y}i&&b&&(e=i,"function"==typeof s?s(e):!1!==s)&&(l=!0,h({data:S,_c:q}))}if(l&&!i&&("function"==typeof l?h({data:l(y,S),error:q,_c:q}):h({data:y,error:q,_c:q})),f[c][1]=eg(),Promise.resolve(v()).then(()=>{h({_c:q})}),i){if(u)throw i;return}return y}}let ex=(e,t)=>{for(let n in e)e[n][0]&&e[n][0](t)},eb=(e,t)=>{if(!Z.has(e)){let n=$(ea,t),r={},i=ey.bind(q,e),o=W,l={},s=(e,t)=>{let n=l[e]||[];return l[e]=n,n.push(t),()=>n.splice(n.indexOf(t),1)},a=(t,n,r)=>{e.set(t,n);let i=l[t];if(i)for(let e of i)e(n,r)},u=()=>{if(!Z.has(e)&&(Z.set(e,[r,{},{},{},i,a,s]),!ec)){let t=n.initFocus(setTimeout.bind(q,ex.bind(q,r,0))),i=n.initReconnect(setTimeout.bind(q,ex.bind(q,r,1)));o=()=>{t&&t(),i&&i(),Z.delete(e)}}};return u(),[e,i,u,o]}return[e,Z.get(e)[4]]},[ew,eE]=eb(new Map),ek=$({onLoadingSlow:W,onSuccess:W,onError:W,onErrorRetry:(e,t,n,r,i)=>{let o=n.errorRetryCount,l=i.retryCount,s=~~((Math.random()+.5)*(1<<(l<8?l:8)))*n.errorRetryInterval;(G(o)||!(l>o))&&setTimeout(r,s,i)},onDiscarded:W,revalidateOnFocus:!0,revalidateOnReconnect:!0,revalidateIfStale:!0,shouldRetryOnError:!0,errorRetryInterval:ep?1e4:5e3,focusThrottleInterval:5e3,dedupingInterval:2e3,loadingTimeout:ep?5e3:3e3,compare:(e,t)=>J(e)==J(t),isPaused:()=>!1,cache:ew,mutate:eE,fallback:{}},{isOnline:()=>eo,isVisible:()=>{let e=er&&document.visibilityState;return G(e)||"hidden"!==e}}),eS=(e,t)=>{let n=$(e,t);if(t){let{use:r,fallback:i}=e,{use:o,fallback:l}=t;r&&o&&(n.use=r.concat(o)),i&&l&&(n.fallback=$(i,l))}return n},eT=(0,l.createContext)({}),eC=en&&window.__SWR_DEVTOOLS_USE__,eP=(eC?window.__SWR_DEVTOOLS_USE__:[]).concat(e=>(t,n,r)=>{let i=n&&((...e)=>{let[r]=ef(t),[,,,i]=Z.get(ew);if(r.startsWith("$inf$"))return n(...e);let o=i[r];return G(o)?n(...e):(delete i[r],o)});return e(t,i,r)});eC&&(window.__SWR_DEVTOOLS_REACT__=l);let eA=l.use||(e=>{if("pending"===e.status)throw e;if("fulfilled"===e.status)return e.value;if("rejected"===e.status)throw e.reason;throw e.status="pending",e.then(t=>{e.status="fulfilled",e.value=t},t=>{e.status="rejected",e.reason=t}),e}),eR={dedupe:!0};Y.defineProperty(e=>{let{value:t}=e,n=(0,l.useContext)(eT),r="function"==typeof t,i=(0,l.useMemo)(()=>r?t(n):t,[r,n,t]),o=(0,l.useMemo)(()=>r?i:eS(n,i),[r,n,i]),s=i&&i.provider,a=(0,l.useRef)(q);s&&!a.current&&(a.current=eb(s(o.cache||ew),i));let u=a.current;return u&&(o.cache=u[0],o.mutate=u[1]),ed(()=>{if(u)return u[2]&&u[2](),u[3]},[]),(0,l.createElement)(eT.Provider,$(e,{value:o}))},"defaultValue",{value:ek});let e_=(r=(e,t,n)=>{let{cache:r,compare:i,suspense:o,fallbackData:s,revalidateOnMount:a,revalidateIfStale:u,refreshInterval:c,refreshWhenHidden:d,refreshWhenOffline:h,keepPreviousData:p}=n,[f,m,g,v]=Z.get(r),[y,x]=ef(e),b=(0,l.useRef)(!1),w=(0,l.useRef)(!1),E=(0,l.useRef)(y),
1k=(0,l.useRef)(t),S=(0,l.useRef)(n),T=()=>S.current.isVisible()&&S.current.isOnline(),[C,P,A,R]=ei(r,y),_=(0,l.useRef)({}).current,I=G(s)?n.fallback[y]:s,D=(e,t)=>{for(let n in _)if("data"===n){if(!i(e[n],t[n])&&(!G(e[n])||!i(U,t[n])))return!1}else if(t[n]!==e[n])return!1;return!0},L=(0,l.useMemo)(()=>{let e=!!y&&!!t&&(G(a)?!S.current.isPaused()&&!o&&(!!G(u)||u):a),n=t=>{let n=$(t);return(delete n._k,e)?{isValidating:!0,isLoading:!0,...n}:n},r=C(),i=R(),l=n(r),s=r===i?l:n(i),c=l;return[()=>{let e=n(C());return D(e,c)?(c.data=e.data,c.isLoading=e.isLoading,c.isValidating=e.isValidating,c.error=e.error,c):(c=e,e)},()=>s]},[r,y]),M=(0,H.useSyncExternalStore)((0,l.useCallback)(e=>A(y,(t,n)=>{D(n,t)||e()}),[r,y]),L[0],L[1]),F=!b.current,O=f[y]&&f[y].length>0,j=M.data,N=G(j)?I:j,V=M.error,B=(0,l.useRef)(N),U=p?G(j)?B.current:j:N,z=(!O||!!G(V))&&(F&&!G(a)?a:!S.current.isPaused()&&(o?!G(N)&&u:G(N)||u)),W=!!(y&&t&&F&&z),Y=G(M.isValidating)?W:M.isValidating,X=G(M.isLoading)?W:M.isLoading,K=(0,l.useCallback)(async e=>{let t,r,o=k.current;if(!y||!o||w.current||S.current.isPaused())return!1;let l=!0,s=e||{},a=!g[y]||!s.dedupe,u=()=>eu?!w.current&&y===E.current&&b.current:y===E.current,c={isValidating:!1,isLoading:!1},d=()=>{P(c)},h=()=>{let e=g[y];e&&e[1]===r&&delete g[y]},p={isValidating:!0};G(C().data)&&(p.isLoading=!0);try{if(a&&(P(p),n.loadingTimeout&&G(C().data)&&setTimeout(()=>{l&&u()&&S.current.onLoadingSlow(y,n)},n.loadingTimeout),g[y]=[o(x),eg()]),[t,r]=g[y],t=await t,a&&setTimeout(h,n.dedupingInterval),!g[y]||g[y][1]!==r)return a&&u()&&S.current.onDiscarded(y),!1;c.error=q;let e=m[y];if(!G(e)&&(r<=e[0]||r<=e[1]||0===e[1]))return d(),a&&u()&&S.current.onDiscarded(y),!1;let s=C().data;c.data=i(s,t)?s:t,a&&u()&&S.current.onSuccess(t,y,n)}catch(n){h();let e=S.current,{shouldRetryOnError:t}=e;!e.isPaused()&&(c.error=n,a&&u())&&(e.onError(n,y,e),(!0===t||"function"==typeof t&&t(n))&&(!S.current.revalidateOnFocus||!S.current.revalidateOnReconnect||T())&&e.onErrorRetry(n,y,e,e=>{let t=f[y];t&&t[0]&&t[0](ev.ERROR_REVALIDATE_EVENT,e)},{retryCount:(s.retryCount||0)+1,dedupe:!0}))}return l=!1,d(),!0},[y,r]),J=(0,l.useCallback)((...e)=>ey(r,E.current,...e),[]);if(ed(()=>{k.current=t,S.current=n,G(j)||(B.current=j)}),ed(()=>{if(!y)return;let e=K.bind(q,eR),t=0,n=((e,t,n)=>{let r=t[e]||(t[e]=[]);return r.push(n),()=>{let e=r.indexOf(n);e>=0&&(r[e]=r[r.length-1],r.pop())}})(y,f,(n,r={})=>{if(n==ev.FOCUS_EVENT){let n=Date.now();S.current.revalidateOnFocus&&n>t&&T()&&(t=n+S.current.focusThrottleInterval,e())}else if(n==ev.RECONNECT_EVENT)S.current.revalidateOnReconnect&&T()&&e();else if(n==ev.MUTATE_EVENT)return K();else if(n==ev.ERROR_REVALIDATE_EVENT)return K(r)});return w.current=!1,E.current=y,b.current=!0,P({_k:x}),z&&(G(N)||ec?e():(e=>en&&typeof window.requestAnimationFrame!=et?window.requestAnimationFrame(e):setTimeout(e,1))(e)),()=>{w.current=!0,n()}},[y]),ed(()=>{let e;function t(){let t="function"==typeof c?c(C().data):c;t&&-1!==e&&(e=setTimeout(n,t))}function n(){!C().error&&(d||S.current.isVisible())&&(h||S.current.isOnline())?K(eR).then(t):t()}return t(),()=>{e&&(clearTimeout(e),e=-1)}},[c,d,h,y]),(0,l.useDebugValue)(U),o&&G(N)&&y){if(!eu&&ec)throw Error("Fallback data is required when using suspense in SSR.");k.current=t,S.current=n,w.current=!1;let e=v[y];if(G(e)||eA(J(e)),G(V)){let e=K(eR);G(U)||(e.status="fulfilled",e.value=!0),eA(e)}else throw V}return{mutate:J,get data(){return _.data=!0,U},get error(){return _.error=!0,V},get isValidating(){return _.isValidating=!0,Y},get isLoading(){return _.isLoading=!0,X}}},function(...e){let t=$(ek,(0,l.useContext)(eT)),[n,i,o]="function"==typeof e[1]?[e[0],e[1],e[2]||{}]:[e[0],null,(null===e[1]?e[2]:e[1])||{}],s=eS(t,o),a=r,{use:u}=s,c=(u||[]).concat(eP);for(let e=c.length;e--;)a=c[e](a);return a(n,i||s.fetcher||null,s)});var eI=n(30667);function eD(e,t){return null!=t?eI(e,t):e}var eL=async(e,t,n,r,i,o,l,s,a,u,c,d,h,p,f,m,g)=>{var v;let y=l.current;n(t.messages,!1);let x=p?t.messages:t.messages.map(({role:e,content:t,experimental_attachments:n,name:r,data:i,annotations:o,toolInvocations:l,function_call:s,tool_calls:a,tool_call_id:u})=>({role:e,content:t,...void 0!==n&&{experimental_attachments:n},...void 0!==r&&{name:r},...void 0!==i&&{data:i},...void 0!==o&&{annotations:o},...void 0!==l&&{toolInvocations:l},tool_call_id:u,...void 0!==s&&{function_call:s},...void 0!==a&&{tool_calls:a}})),b=i.current;return await U({api:e,body:null!=(v=null==f?void 0:f({messages:t.messages,requestData:t.data,requestBody:t.body}))?v:{messages:x,data:t.data,...o.current.body,...t.body,...void 0!==t.functions&&{functions:t.functions},...void 0!==t.function_call&&{function_call:t.function_call},...void 0!==t.tools&&{tools:t.tools},...void 0!==t.tool_choice&&{tool_choice:t.tool_choice}},streamProtocol:u,credentials:o.current.credentials,headers:{...o.current.headers,...t.headers},abortController:()=>s.current,restoreMessagesOnFailure(){g||n(y,!1)}
1,onResponse:d,onUpdate(e,i){n([...t.messages,...e],!1),r([...null!=b?b:[],...null!=i?i:[]],!1)},onToolCall:h,onFinish:c,generateId:a,fetch:m})};function eM(e){return"assistant"===e.role&&e.toolInvocations&&e.toolInvocations.length>0&&e.toolInvocations.every(e=>"result"in e)}async function eF(e){if(null==e)return[];if(e instanceof FileList)return Promise.all(Array.from(e).map(async e=>{let{name:t,type:n}=e;return{name:t,contentType:n,url:await new Promise((t,n)=>{let r=new FileReader;r.onload=e=>{var n;t(null==(n=e.target)?void 0:n.result)},r.onerror=e=>n(e),r.readAsDataURL(e)})}}));if(Array.isArray(e))return e;throw Error("Invalid attachments type")}var eO=function({api:e="/api/chat",id:t,initialMessages:n,initialInput:r="",sendExtraMessageFields:i,experimental_onFunctionCall:o,experimental_onToolCall:s,onToolCall:a,experimental_prepareRequestBody:u,experimental_maxAutomaticRoundtrips:c=0,maxAutomaticRoundtrips:d=c,maxToolRoundtrips:h=d,maxSteps:p=null!=h?h+1:1,streamMode:f,streamProtocol:m,onResponse:v,onFinish:y,onError:x,credentials:b,headers:w,body:E,generateId:k=g,fetch:S,keepLastMessageOnError:T=!1,experimental_throttle:C}={}){f&&(null!=m||(m="text"===f?"text":void 0));let P=(0,l.useId)(),A=null!=t?t:P,R="string"==typeof e?[e,A]:A,[_]=(0,l.useState)([]),{data:I,mutate:D}=e_([R,"messages"],null,{fallbackData:null!=n?n:_}),L=(0,l.useRef)(I||[]);(0,l.useEffect)(()=>{L.current=I||[]},[I]);let{data:M,mutate:F}=e_([R,"streamData"],null),O=(0,l.useRef)(M);(0,l.useEffect)(()=>{O.current=M},[M]);let{data:j=!1,mutate:N}=e_([R,"loading"],null),{data:V,mutate:B}=e_([R,"error"],null),U=(0,l.useRef)(null),H=(0,l.useRef)({credentials:b,headers:w,body:E});(0,l.useEffect)(()=>{H.current={credentials:b,headers:w,body:E}},[b,w,E]);let W=(0,l.useCallback)(async t=>{let n=L.current.length;try{N(!0),B(void 0),U.current=new AbortController,await z({getStreamedResponse:()=>eL(e,t,eD(D,C),eD(F,C),O,H,L,U,k,m,y,v,a,i,u,S,T),experimental_onFunctionCall:o,experimental_onToolCall:s,updateChatRequest:e=>{t=e},getCurrentMessages:()=>L.current}),U.current=null}catch(e){if("AbortError"===e.name)return U.current=null,null;x&&e instanceof Error&&x(e),B(e)}finally{N(!1)}let r=L.current,l=r[r.length-1];r.length>n&&null!=l&&p>1&&eM(l)&&function(e){let t=0;for(let n=e.length-1;n>=0;n--)if("assistant"===e[n].role)t++;else break;return t}(r)<p&&await W({messages:r})}
1,[D,N,e,H,v,y,x,B,F,O,m,i,o,s,u,a,p,L,U,k,S,T,C]),q=(0,l.useCallback)(async(e,{options:t,functions:n,function_call:r,tools:i,tool_choice:o,data:l,headers:s,body:a,experimental_attachments:u}={})=>{var c,d;e.id||(e.id=k());let h=await eF(u),p={headers:null!=s?s:null==t?void 0:t.headers,body:null!=a?a:null==t?void 0:t.body};return W({messages:L.current.concat({...e,id:null!=(c=e.id)?c:k(),createdAt:null!=(d=e.createdAt)?d:new Date,experimental_attachments:h.length>0?h:void 0}),options:p,headers:p.headers,body:p.body,data:l,...void 0!==n&&{functions:n},...void 0!==r&&{function_call:r},...void 0!==i&&{tools:i},...void 0!==o&&{tool_choice:o}})},[W,k]),Y=(0,l.useCallback)(async({options:e,functions:t,function_call:n,tools:r,tool_choice:i,data:o,headers:l,body:s}={})=>{if(0===L.current.length)return null;let a={headers:null!=l?l:null==e?void 0:e.headers,body:null!=s?s:null==e?void 0:e.body};return"assistant"===L.current[L.current.length-1].role?W({messages:L.current.slice(0,-1),options:a,headers:a.headers,body:a.body,data:o,...void 0!==t&&{functions:t},...void 0!==n&&{function_call:n},...void 0!==r&&{tools:r},...void 0!==i&&{tool_choice:i}}):W({messages:L.current,options:a,headers:a.headers,body:a.body,data:o,...void 0!==t&&{functions:t},...void 0!==n&&{function_call:n},...void 0!==r&&{tools:r},...void 0!==i&&{tool_choice:i}})},[W]),G=(0,l.useCallback)(()=>{U.current&&(U.current.abort(),U.current=null)},[]),$=(0,l.useCallback)(e=>{"function"==typeof e&&(e=e(L.current)),D(e,!1),L.current=e},[D]),X=(0,l.useCallback)(e=>{"function"==typeof e&&(e=e(O.current)),F(e,!1),O.current=e},[F]),[K,J]=(0,l.useState)(r),Z=(0,l.useCallback)(async(e,t={},n)=>{var r,i,o,l,s;if(null==(r=null==e?void 0:e.preventDefault)||r.call(e),!K&&!t.allowEmptySubmit)return;n&&(H.current={...H.current,...n});let a=await eF(t.experimental_attachments),u={headers:null!=(o=t.headers)?o:null==(i=t.options)?void 0:i.headers,body:null!=(s=t.body)?s:null==(l=t.options)?void 0:l.body};W({messages:K||a.length||!t.allowEmptySubmit?L.current.concat({id:k(),createdAt:new Date,role:"user",content:K,experimental_attachments:a.length>0?a:void 0}):L.current,options:u,headers:u.headers,body:u.body,data:t.data}),J("")},[K,k,W]),Q=({toolCallId:e,result:t})=>{let n=L.current.map((n,r,i)=>r===i.length-1&&"assistant"===n.role&&n.toolInvocations?{...n,toolInvocations:n.toolInvocations.map(n=>n.toolCallId===e?{...n,result:t}:n)}:n);D(n,!1),eM(n[n.length-1])&&W({messages:n})};return{messages:I||[],setMessages:$,data:M,setData:X,error:V,append:q,reload:Y,stop:G,input:K,setInput:J,handleInputChange:e=>{J(e.target.value)},handleSubmit:Z,isLoading:j,addToolResult:Q,experimental_addToolResult:Q}}},73846:(e,t,n)=>{"use strict";n.d(t,{UC:()=>I,bL:()=>R,l9:()=>_});var r,i=n(32144),o=n(14558),l=n(11623),s=n(82306),a=n(40558),u=n(66809),c=(n(16628),n(94185)),d=n(40675),h=n(52825),p=n(11612),f="HoverCard",[m,g]=(0,l.A)(f,[u.Bk]),v=(0,u.Bk)(),[y,x]=m(f),b=e=>{let{__scopeHoverCard:t,children:n,open:r,defaultOpen:o,onOpenChange:l,openDelay:a=700,closeDelay:c=300}=e,d=v(t),h=i.useRef(0),f=i.useRef(0),m=i.useRef(!1),g=i.useRef(!1),[x=!1,b]=(0,s.i)({prop:r,defaultProp:o,onChange:l}),w=i.useCallback(()=>{clearTimeout(f.current),h.current=window.setTimeout(()=>b(!0),a)},[a,b]),E=i.useCallback(()=>{clearTimeout(h.current),m.current||g.current||(f.current=window.setTimeout(()=>b(!1),c))},[c,b]),k=i.useCallback(()=>b(!1),[b]);return i.useEffect(()=>()=>{clearTimeout(h.current),clearTimeout(f.current)},[]),(0,p.jsx)(y,{scope:t,open:x,onOpenChange:b,onOpen:w,onClose:E,onDismiss:k,hasSelectionRef:m,isPointerDownOnContentRef:g,children:(0,p.jsx)(u.bL,{...d,children:n})})};b.displayName=f;var w="HoverCardTrigger",E=i.forwardRef((e,t)=>{let{__scopeHoverCard:n,...r}=e,i=x(w,n),l=v(n);return(0,p.jsx)(u.Mz,{asChild:!0,...l,children:(0,p.jsx)(d.sG.a,{"data-state":i.open?"open":"closed",...r,ref:t,onPointerEnter:(0,o.m)(e.onPointerEnter,A(i.onOpen)),onPointerLeave:(0,o.m)(e.onPointerLeave,A(i.onClose)),onFocus:(0,o.m)(e.onFocus,i.onOpen),onBlur:(0,o.m)(e.onBlur,i.onClose),onTouchStart:(0,o.m)(e.onTouchStart,e=>e.preventDefault())})})});E.displayName=w;var[k,S]=m("HoverCardPortal",{forceMount:void 0}),T="HoverCardContent",C=i.forwardRef((e,t)=>
1{let n=S(T,e.__scopeHoverCard),{forceMount:r=n.forceMount,...i}=e,l=x(T,e.__scopeHoverCard);return(0,p.jsx)(c.C,{present:r||l.open,children:(0,p.jsx)(P,{"data-state":l.open?"open":"closed",...i,onPointerEnter:(0,o.m)(e.onPointerEnter,A(l.onOpen)),onPointerLeave:(0,o.m)(e.onPointerLeave,A(l.onClose)),ref:t})})});C.displayName=T;var P=i.forwardRef((e,t)=>{let{__scopeHoverCard:n,onEscapeKeyDown:l,onPointerDownOutside:s,onFocusOutside:c,onInteractOutside:d,...f}=e,m=x(T,n),g=v(n),y=i.useRef(null),b=(0,a.s)(t,y),[w,E]=i.useState(!1);return i.useEffect(()=>{if(w){let e=document.body;return r=e.style.userSelect||e.style.webkitUserSelect,e.style.userSelect="none",e.style.webkitUserSelect="none",()=>{e.style.userSelect=r,e.style.webkitUserSelect=r}}},[w]),i.useEffect(()=>{if(y.current){let e=()=>{E(!1),m.isPointerDownOnContentRef.current=!1,setTimeout(()=>{var e;(null==(e=document.getSelection())?void 0:e.toString())!==""&&(m.hasSelectionRef.current=!0)})};return document.addEventListener("pointerup",e),()=>{document.removeEventListener("pointerup",e),m.hasSelectionRef.current=!1,m.isPointerDownOnContentRef.current=!1}}},[m.isPointerDownOnContentRef,m.hasSelectionRef]),i.useEffect(()=>{y.current&&(function(e){let t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:e=>e.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP});for(;n.nextNode();)t.push(n.currentNode);return t})(y.current).forEach(e=>e.setAttribute("tabindex","-1"))}),(0,p.jsx)(h.qW,{asChild:!0,disableOutsidePointerEvents:!1,onInteractOutside:d,onEscapeKeyDown:l,onPointerDownOutside:s,onFocusOutside:(0,o.m)(c,e=>{e.preventDefault()}),onDismiss:m.onDismiss,children:(0,p.jsx)(u.UC,{...g,...f,onPointerDown:(0,o.m)(f.onPointerDown,e=>{e.currentTarget.contains(e.target)&&E(!0),m.hasSelectionRef.current=!1,m.isPointerDownOnContentRef.current=!0}),ref:b,style:{...f.style,userSelect:w?"text":void 0,WebkitUserSelect:w?"text":void 0,"--radix-hover-card-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-hover-card-content-available-width":"var(--radix-popper-available-width)","--radix-hover-card-content-available-height":"var(--radix-popper-available-height)","--radix-hover-card-trigger-width":"var(--radix-popper-anchor-width)","--radix-hover-card-trigger-height":"var(--radix-popper-anchor-height)"}})})});function A(e){return t=>"touch"===t.pointerType?void 0:e()}i.forwardRef((e,t)=>{let{__scopeHoverCard:n,...r}=e,i=v(n);return(0,p.jsx)(u.i3,{...i,...r,ref:t})}).displayName="HoverCardArrow";var R=b,_=E,I=C},76845:(e,t,n)=>{"use strict";n.d(t,{bL:()=>E,zi:()=>k});var r=n(32144),i=n(14558),o=n(40558),l=n(11623),s=n(82306),a=n(28634),u=n(44362),c=n(40675),d=n(11612),h="Switch",[p,f]=(0,l.A)(h),[m,g]=p(h),v=r.forwardRef((e,t)=>{let{__scopeSwitch:n,name:l,checked:a,defaultChecked:u,required:h,disabled:p,value:f="on",onCheckedChange:g,form:v,...y}=e,[x,E]=r.useState(null),k=(0,o.s)(t,e=>E(e)),S=r.useRef(!1),T=!x||v||!!x.closest("form"),[C=!1,P]=(0,s.i)({prop:a,defaultProp:u,onChange:g});return(0,d.jsxs)(m,{scope:n,checked:C,disabled:p,children:[(0,d.jsx)(c.sG.button,{type:"button",role:"switch","aria-checked":C,"aria-required":h,"data-state":w(C),"data-disabled":p?"":void 0,disabled:p,value:f,...y,ref:k,onClick:(0,i.m)(e.onClick,e=>{P(e=>!e),T&&(S.current=e.isPropagationStopped(),S.current||e.stopPropagation())})}),T&&(0,d.jsx)(b,{control:x,bubbles:!S.current,name:l,value:f,checked:C,required:h,disabled:p,form:v,style:{transform:"translateX(-100%)"}})]})});v.displayName=h;var y="SwitchThumb",x=r.forwardRef((e,t)=>{let{__scopeSwitch:n,...r}=e,i=g(y,n);return(0,d.jsx)(c.sG.span,{"data-state":w(i.checked),"data-disabled":i.disabled?"":void 0,...r,ref:t})});x.displayName=y;var b=e=>{let{control:t,checked:n,bubbles:i=!0,...o}=e,l=r.useRef(null),s=(0,a.Z)(n),c=(0,u.X)(t);return r.useEffect(()=>{let e=l.current,t=Object.getOwnPropertyDescriptor(window.HTMLInputElement.prototype,"checked").set;if(s!==n&&t){let r=new Event("click",{bubbles:i});t.call(e,n),e.dispatchEvent(r)}},[s,n,i]),(0,d.jsx)("input",{type:"checkbox","aria-hidden":!0,defaultChecked:n,...o,tabIndex:-1,ref:l,style:{...e.style,...c,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})};function w(e){return e?"checked":"unchecked"}var E=v,k=x},80244:(e,t,n)=>{"use strict";function r(e,[t,n]){return Math.min(n,Math.max(t,e))}n.d(t,{q:()=>r})},84017:(e,t,n)=>{"use strict";n.d(t,{UC:()=>el,Y9:()=>ei,q7:()=>er,bL:()=>en,l9:()=>eo});var r=n(32144),i=n(11623),o=n(28712),l=n(40558),s=n(14558),a=n(82306),u=n(40675),c=n(7136),d=n(94185),h=n(68862),p=n(11612),f="Collapsible",[m,g]=(0,i.A)(f),[v,y]=m(f),x=r.forwardRef((e,t)=>
1{let{__scopeCollapsible:n,open:i,defaultOpen:o,disabled:l,onOpenChange:s,...c}=e,[d=!1,f]=(0,a.i)({prop:i,defaultProp:o,onChange:s});return(0,p.jsx)(v,{scope:n,disabled:l,contentId:(0,h.B)(),open:d,onOpenToggle:r.useCallback(()=>f(e=>!e),[f]),children:(0,p.jsx)(u.sG.div,{"data-state":T(d),"data-disabled":l?"":void 0,...c,ref:t})})});x.displayName=f;var b="CollapsibleTrigger",w=r.forwardRef((e,t)=>{let{__scopeCollapsible:n,...r}=e,i=y(b,n);return(0,p.jsx)(u.sG.button,{type:"button","aria-controls":i.contentId,"aria-expanded":i.open||!1,"data-state":T(i.open),"data-disabled":i.disabled?"":void 0,disabled:i.disabled,...r,ref:t,onClick:(0,s.m)(e.onClick,i.onOpenToggle)})});w.displayName=b;var E="CollapsibleContent",k=r.forwardRef((e,t)=>{let{forceMount:n,...r}=e,i=y(E,e.__scopeCollapsible);return(0,p.jsx)(d.C,{present:n||i.open,children:e=>{let{present:n}=e;return(0,p.jsx)(S,{...r,ref:t,present:n})}})});k.displayName=E;var S=r.forwardRef((e,t)=>{let{__scopeCollapsible:n,present:i,children:o,...s}=e,a=y(E,n),[d,h]=r.useState(i),f=r.useRef(null),m=(0,l.s)(t,f),g=r.useRef(0),v=g.current,x=r.useRef(0),b=x.current,w=a.open||d,k=r.useRef(w),S=r.useRef();return r.useEffect(()=>{let e=requestAnimationFrame(()=>k.current=!1);return()=>cancelAnimationFrame(e)},[]),(0,c.N)(()=>{let e=f.current;if(e){S.current=S.current||{transitionDuration:e.style.transitionDuration,animationName:e.style.animationName},e.style.transitionDuration="0s",e.style.animationName="none";let t=e.getBoundingClientRect();g.current=t.height,x.current=t.width,k.current||(e.style.transitionDuration=S.current.transitionDuration,e.style.animationName=S.current.animationName),h(i)}},[a.open,i]),(0,p.jsx)(u.sG.div,{"data-state":T(a.open),"data-disabled":a.disabled?"":void 0,id:a.contentId,hidden:!w,...s,ref:m,style:{"--radix-collapsible-content-height":v?"".concat(v,"px"):void 0,"--radix-collapsible-content-width":b?"".concat(b,"px"):void 0,...e.style},children:w&&o})});function T(e){return e?"open":"closed"}var C=n(40460),P="Accordion",A=["Home","End","ArrowDown","ArrowUp","ArrowLeft","ArrowRight"],[R,_,I]=(0,o.N)(P),[D,L]=(0,i.A)(P,[I,g]),M=g(),F=r.forwardRef((e,t)=>{let{type:n,...r}=e;return(0,p.jsx)(R.Provider,{scope:e.__scopeAccordion,children:"multiple"===n?(0,p.jsx)(U,{...r,ref:t}):(0,p.jsx)(B,{...r,ref:t})})});F.displayName=P;var[O,j]=D(P),[N,V]=D(P,{collapsible:!1}),B=r.forwardRef((e,t)=>{let{value:n,defaultValue:i,onValueChange:o=()=>{},collapsible:l=!1,...s}=e,[u,c]=(0,a.i)({prop:n,defaultProp:i,onChange:o});return(0,p.jsx)(O,{scope:e.__scopeAccordion,value:u?[u]:[],onItemOpen:c,onItemClose:r.useCallback(()=>l&&c(""),[l,c]),children:(0,p.jsx)(N,{scope:e.__scopeAccordion,collapsible:l,children:(0,p.jsx)(W,{...s,ref:t})})})}),U=r.forwardRef((e,t)=>{let{value:n,defaultValue:i,onValueChange:o=()=>{},...l}=e,[s=[],u]=(0,a.i)({prop:n,defaultProp:i,onChange:o}),c=r.useCallback(e=>u(function(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return[...t,e]}),[u]),d=r.useCallback(e=>u(function(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return t.filter(t=>t!==e)}),[u]);return(0,p.jsx)(O,{scope:e.__scopeAccordion,value:s,onItemOpen:c,onItemClose:d,children:(0,p.jsx)(N,{scope:e.__scopeAccordion,collapsible:!0,children:(0,p.jsx)(W,{...l,ref:t})})})}),[z,H]=D(P),W=r.forwardRef((e,t)=>{let{__scopeAccordion:n,disabled:i,dir:o,orientation:a="vertical",...c}=e,d=r.useRef(null),h=(0,l.s)(d,t),f=_(n),m="ltr"===(0,C.jH)(o),g=(0,s.m)(e.onKeyDown,e=>{var t;if(!A.includes(e.key))return;let n=e.target,r=f().filter(e=>{var t;return!(null==(t=e.ref.current)?void 0:t.disabled)}),i=r.findIndex(e=>e.ref.current===n),o=r.length;if(-1===i)return;e.preventDefault();let l=i,s=o-1,u=()=>{(l=i+1)>s&&(l=0)},c=()=>{(l=i-1)<0&&(l=s)};switch(e.key){case"Home":l=0;break;case"End":l=s;break;case"ArrowRight":"horizontal"===a&&(m?u():c());break;case"ArrowDown":"vertical"===a&&u();break;case"ArrowLeft":"horizontal"===a&&(m?c():u());break;case"ArrowUp":"vertical"===a&&c()}null==(t=r[l%o].ref.current)||t.focus()});return(0,p.jsx)(z,{scope:n,disabled:i,direction:o,orientation:a,children:(0,p.jsx)(R.Slot,{scope:n,children:(0,p.jsx)(u.sG.div,{...c,"data-orientation":a,ref:h,onKeyDown:i?void 0:g})})})}),q="AccordionItem",[Y,G]=D(q),$=r.forwardRef((e,t)=>
1{let{__scopeAccordion:n,value:r,...i}=e,o=H(q,n),l=j(q,n),s=M(n),a=(0,h.B)(),u=r&&l.value.includes(r)||!1,c=o.disabled||e.disabled;return(0,p.jsx)(Y,{scope:n,open:u,disabled:c,triggerId:a,children:(0,p.jsx)(x,{"data-orientation":o.orientation,"data-state":et(u),...s,...i,ref:t,disabled:c,open:u,onOpenChange:e=>{e?l.onItemOpen(r):l.onItemClose(r)}})})});$.displayName=q;var X="AccordionHeader",K=r.forwardRef((e,t)=>{let{__scopeAccordion:n,...r}=e,i=H(P,n),o=G(X,n);return(0,p.jsx)(u.sG.h3,{"data-orientation":i.orientation,"data-state":et(o.open),"data-disabled":o.disabled?"":void 0,...r,ref:t})});K.displayName=X;var J="AccordionTrigger",Z=r.forwardRef((e,t)=>{let{__scopeAccordion:n,...r}=e,i=H(P,n),o=G(J,n),l=V(J,n),s=M(n);return(0,p.jsx)(R.ItemSlot,{scope:n,children:(0,p.jsx)(w,{"aria-disabled":o.open&&!l.collapsible||void 0,"data-orientation":i.orientation,id:o.triggerId,...s,...r,ref:t})})});Z.displayName=J;var Q="AccordionContent",ee=r.forwardRef((e,t)=>{let{__scopeAccordion:n,...r}=e,i=H(P,n),o=G(Q,n),l=M(n);return(0,p.jsx)(k,{role:"region","aria-labelledby":o.triggerId,"data-orientation":i.orientation,...l,...r,ref:t,style:{"--radix-accordion-content-height":"var(--radix-collapsible-content-height)","--radix-accordion-content-width":"var(--radix-collapsible-content-width)",...e.style}})});function et(e){return e?"open":"closed"}ee.displayName=Q;var en=F,er=$,ei=K,eo=Z,el=ee},84147:(e,t,n)=>{"use strict";n.d(t,{o:()=>c});var r=n(11612),i=n(32144),o=n(86436);let l=(0,i.createContext)(null);var s=n(17933),a=n(9021);let u=e=>!e.isLayoutDirty&&e.willUpdate(!1),c=e=>{let{children:t,id:n,inherit:c=!0}=e,d=(0,i.useContext)(o.L),h=(0,i.useContext)(l),[p,f]=function(){let e=function(){let e=(0,i.useRef)(!1);return(0,s.E)(()=>(e.current=!0,()=>{e.current=!1}),[]),e}(),[t,n]=(0,i.useState)(0),r=(0,i.useCallback)(()=>{e.current&&n(t+1)},[t]);return[(0,i.useCallback)(()=>a.Gt.postRender(r),[r]),t]}(),m=(0,i.useRef)(null),g=d.id||h;null===m.current&&((e=>!0==(!0===e)||"id"===e)(c)&&g&&(n=n?g+"-"+n:g),m.current={id:n,group:!0===c&&d.group||function(){let e=new Set,t=new WeakMap,n=()=>e.forEach(u);return{add:r=>{e.add(r),t.set(r,r.addEventListener("willUpdate",n))},remove:r=>{e.delete(r);let i=t.get(r);i&&(i(),t.delete(r)),n()},dirty:n}}()});let v=(0,i.useMemo)(()=>({...m.current,forceRender:p}),[f]);return(0,r.jsx)(o.L.Provider,{value:v,children:t})}},85633:(e,t,n)=>{"use strict";n.d(t,{I:()=>o});var r=n(55025);let i=["read","resolveKeyframes","update","preRender","render","postRender"];function o(e,t){let n=!1,o=!0,l={delta:0,timestamp:0,isProcessing:!1},s=()=>n=!0,a=i.reduce((e,t)=>(e[t]=function(e){let t=new Set,n=new Set,r=!1,i=!1,o=new WeakSet,l={delta:0,timestamp:0,isProcessing:!1};function s(t){o.has(t)&&(a.schedule(t),e()),t(l)}let a={schedule:(e,i=!1,l=!1)=>{let s=l&&r?t:n;return i&&o.add(e),s.has(e)||s.add(e),e},cancel:e=>{n.delete(e),o.delete(e)},process:e=>{if(l=e,r){i=!0;return}r=!0,[t,n]=[n,t],n.clear(),t.forEach(s),r=!1,i&&(i=!1,a.process(e))}};return a}(s),e),{}),{read:u,resolveKeyframes:c,update:d,preRender:h,render:p,postRender:f}=a,m=()=>{let i=r.W.useManualTiming?l.timestamp:performance.now();n=!1,l.delta=o?1e3/60:Math.max(Math.min(i-l.timestamp,40),1),l.timestamp=i,l.isProcessing=!0,u.process(l),c.process(l),d.process(l),h.process(l),p.process(l),f.process(l),l.isProcessing=!1,n&&t&&(o=!1,e(m))};return{schedule:i.reduce((t,r)=>{let i=a[r];return t[r]=(t,r=!1,s=!1)=>(!n&&(n=!0,o=!0,l.isProcessing||e(m)),i.schedule(t,r,s)),t},{}),cancel:e=>{for(let t=0;t<i.length;t++)a[i[t]].cancel(e)},state:l,steps:a}}},86436:(e,t,n)=>{"use strict";n.d(t,{L:()=>r});let r=(0,n(32144).createContext)({})},87763:(e,t,n)=>{"use strict";function r(e,t,n){void 0===t&&(t=50),void 0===n&&(n={});var r,i,o,l=null!=(r=n.isImmediate)&&r,s=null!=(i=n.callback)&&i,a=n.maxWait,u=Date.now(),c=[],d=function(){var n=[].slice.call(arguments),r=this;return new Promise(function(i,d){var h=l&&void 0===o;if(void 0!==o&&clearTimeout(o),o=setTimeout(function(){if(o=void 0,u=Date.now(),!l){var t=e.apply(r,n);s&&s(t),c.forEach(function(e){return(0,e.resolve)(t)}),c=[]}},function(){if(void 0!==a){var e=Date.now()-u;if(e+t>=a)return a-e}return t}()),h){var p=e.apply(r,n);return s&&s(p),i(p)}c.push({resolve:i,reject:d})})};return d.cancel=function(e){void 0!==o&&clearTimeout(o),c.forEac
1h(function(t){return(0,t.reject)(e)}),c=[]},d}n.d(t,{s:()=>r})},88050:(e,t,n)=>{"use strict";n.d(t,{e:()=>l,g:()=>o});var r=n(32144);let i=(0,r.createContext)(()=>{});function o(){return(0,r.useContext)(i)}function l(e){let{value:t,children:n}=e;return r.createElement(i.Provider,{value:t},n)}},92104:function(e,t,n){"use strict";var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){var n=null;if(!e||"string"!=typeof e)return n;var r=(0,i.default)(e),o="function"==typeof t;return r.forEach(function(e){if("declaration"===e.type){var r=e.property,i=e.value;o?t(r,i,e):i&&((n=n||{})[r]=i)}}),n};var i=r(n(44346))}}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.