diff --git a/backend/public/pilot.js b/backend/public/pilot.js index 717add36e..5e6e587b5 100644 --- a/backend/public/pilot.js +++ b/backend/public/pilot.js @@ -1,4 +1,4 @@ -function Tw(e,t){for(var n=0;nr[o]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const o of document.querySelectorAll('link[rel="modulepreload"]'))r(o);new MutationObserver(o=>{for(const i of o)if(i.type==="childList")for(const l of i.addedNodes)l.tagName==="LINK"&&l.rel==="modulepreload"&&r(l)}).observe(document,{childList:!0,subtree:!0});function n(o){const i={};return o.integrity&&(i.integrity=o.integrity),o.referrerPolicy&&(i.referrerPolicy=o.referrerPolicy),o.crossOrigin==="use-credentials"?i.credentials="include":o.crossOrigin==="anonymous"?i.credentials="omit":i.credentials="same-origin",i}function r(o){if(o.ep)return;o.ep=!0;const i=n(o);fetch(o.href,i)}})();function $r(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var kg={exports:{}},ka={},Sg={exports:{}},ce={};/** +function Lw(e,t){for(var n=0;nr[o]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const o of document.querySelectorAll('link[rel="modulepreload"]'))r(o);new MutationObserver(o=>{for(const i of o)if(i.type==="childList")for(const l of i.addedNodes)l.tagName==="LINK"&&l.rel==="modulepreload"&&r(l)}).observe(document,{childList:!0,subtree:!0});function n(o){const i={};return o.integrity&&(i.integrity=o.integrity),o.referrerPolicy&&(i.referrerPolicy=o.referrerPolicy),o.crossOrigin==="use-credentials"?i.credentials="include":o.crossOrigin==="anonymous"?i.credentials="omit":i.credentials="same-origin",i}function r(o){if(o.ep)return;o.ep=!0;const i=n(o);fetch(o.href,i)}})();function _r(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Pg={exports:{}},Ea={},Og={exports:{}},ce={};/** * @license React * react.production.min.js * @@ -6,7 +6,7 @@ function Tw(e,t){for(var n=0;n>>1,F=D[Z];if(0>>1;Zo(Q,S))Oo(ne,Q)?(D[Z]=ne,D[O]=S,Z=O):(D[Z]=Q,D[U]=S,Z=U);else if(Oo(ne,S))D[Z]=ne,D[O]=S,Z=O;else break e}}return V}function o(D,V){var S=D.sortIndex-V.sortIndex;return S!==0?S:D.id-V.id}if(typeof performance=="object"&&typeof performance.now=="function"){var i=performance;e.unstable_now=function(){return i.now()}}else{var l=Date,a=l.now();e.unstable_now=function(){return l.now()-a}}var s=[],u=[],c=1,p=null,d=3,f=!1,h=!1,m=!1,w=typeof setTimeout=="function"?setTimeout:null,g=typeof clearTimeout=="function"?clearTimeout:null,y=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function v(D){for(var V=n(u);V!==null;){if(V.callback===null)r(u);else if(V.startTime<=D)r(u),V.sortIndex=V.expirationTime,t(s,V);else break;V=n(u)}}function C(D){if(m=!1,v(D),!h)if(n(s)!==null)h=!0,q(E);else{var V=n(u);V!==null&&K(C,V.startTime-D)}}function E(D,V){h=!1,m&&(m=!1,g(A),A=-1),f=!0;var S=d;try{for(v(V),p=n(s);p!==null&&(!(p.expirationTime>V)||D&&!z());){var Z=p.callback;if(typeof Z=="function"){p.callback=null,d=p.priorityLevel;var F=Z(p.expirationTime<=V);V=e.unstable_now(),typeof F=="function"?p.callback=F:p===n(s)&&r(s),v(V)}else r(s);p=n(s)}if(p!==null)var x=!0;else{var U=n(u);U!==null&&K(C,U.startTime-V),x=!1}return x}finally{p=null,d=S,f=!1}}var k=!1,T=null,A=-1,N=5,P=-1;function z(){return!(e.unstable_now()-PD||125Z?(D.sortIndex=S,t(u,D),n(s)===null&&D===n(u)&&(m?(g(A),A=-1):m=!0,K(C,S-Z))):(D.sortIndex=F,t(s,D),h||f||(h=!0,q(E))),D},e.unstable_shouldYield=z,e.unstable_wrapCallback=function(D){var V=d;return function(){var S=d;d=V;try{return D.apply(this,arguments)}finally{d=S}}}})(zg);Lg.exports=zg;var Kw=Lg.exports;/** + */(function(e){function t(z,G){var S=z.length;z.push(G);e:for(;0>>1,I=z[X];if(0>>1;Xo(Y,S))Ao(ne,Y)?(z[X]=ne,z[A]=S,X=A):(z[X]=Y,z[U]=S,X=U);else if(Ao(ne,S))z[X]=ne,z[A]=S,X=A;else break e}}return G}function o(z,G){var S=z.sortIndex-G.sortIndex;return S!==0?S:z.id-G.id}if(typeof performance=="object"&&typeof performance.now=="function"){var i=performance;e.unstable_now=function(){return i.now()}}else{var l=Date,a=l.now();e.unstable_now=function(){return l.now()-a}}var s=[],u=[],p=1,c=null,d=3,f=!1,h=!1,m=!1,w=typeof setTimeout=="function"?setTimeout:null,g=typeof clearTimeout=="function"?clearTimeout:null,y=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function v(z){for(var G=n(u);G!==null;){if(G.callback===null)r(u);else if(G.startTime<=z)r(u),G.sortIndex=G.expirationTime,t(s,G);else break;G=n(u)}}function C(z){if(m=!1,v(z),!h)if(n(s)!==null)h=!0,Q(E);else{var G=n(u);G!==null&&te(C,G.startTime-z)}}function E(z,G){h=!1,m&&(m=!1,g(T),T=-1),f=!0;var S=d;try{for(v(G),c=n(s);c!==null&&(!(c.expirationTime>G)||z&&!_());){var X=c.callback;if(typeof X=="function"){c.callback=null,d=c.priorityLevel;var I=X(c.expirationTime<=G);G=e.unstable_now(),typeof I=="function"?c.callback=I:c===n(s)&&r(s),v(G)}else r(s);c=n(s)}if(c!==null)var b=!0;else{var U=n(u);U!==null&&te(C,U.startTime-G),b=!1}return b}finally{c=null,d=S,f=!1}}var k=!1,O=null,T=-1,N=5,P=-1;function _(){return!(e.unstable_now()-Pz||125X?(z.sortIndex=S,t(u,z),n(s)===null&&z===n(u)&&(m?(g(T),T=-1):m=!0,te(C,S-X))):(z.sortIndex=I,t(s,z),h||f||(h=!0,Q(E))),z},e.unstable_shouldYield=_,e.unstable_wrapCallback=function(z){var G=d;return function(){var S=d;d=G;try{return z.apply(this,arguments)}finally{d=S}}}})(Fg);Ig.exports=Fg;var nx=Ig.exports;/** * @license React * react-dom.production.min.js * @@ -30,19 +30,17 @@ function Tw(e,t){for(var n=0;n"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Cu=Object.prototype.hasOwnProperty,Xw=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,Lf={},zf={};function Zw(e){return Cu.call(zf,e)?!0:Cu.call(Lf,e)?!1:Xw.test(e)?zf[e]=!0:(Lf[e]=!0,!1)}function Jw(e,t,n,r){if(n!==null&&n.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return r?!1:n!==null?!n.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function ex(e,t,n,r){if(t===null||typeof t>"u"||Jw(e,t,n,r))return!0;if(r)return!1;if(n!==null)switch(n.type){case 3:return!t;case 4:return t===!1;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}function ut(e,t,n,r,o,i,l){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=r,this.attributeNamespace=o,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=i,this.removeEmptyString=l}var Ze={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){Ze[e]=new ut(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];Ze[t]=new ut(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){Ze[e]=new ut(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){Ze[e]=new ut(e,2,!1,e,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){Ze[e]=new ut(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){Ze[e]=new ut(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){Ze[e]=new ut(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){Ze[e]=new ut(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){Ze[e]=new ut(e,5,!1,e.toLowerCase(),null,!1,!1)});var Qc=/[\-:]([a-z])/g;function Kc(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var t=e.replace(Qc,Kc);Ze[t]=new ut(t,1,!1,e,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(Qc,Kc);Ze[t]=new ut(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(Qc,Kc);Ze[t]=new ut(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){Ze[e]=new ut(e,1,!1,e.toLowerCase(),null,!1,!1)});Ze.xlinkHref=new ut("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){Ze[e]=new ut(e,1,!1,e.toLowerCase(),null,!0,!0)});function Xc(e,t,n,r){var o=Ze.hasOwnProperty(t)?Ze[t]:null;(o!==null?o.type!==0:r||!(2"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Ou=Object.prototype.hasOwnProperty,rx=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,zf={},Nf={};function ox(e){return Ou.call(Nf,e)?!0:Ou.call(zf,e)?!1:rx.test(e)?Nf[e]=!0:(zf[e]=!0,!1)}function ix(e,t,n,r){if(n!==null&&n.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return r?!1:n!==null?!n.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function lx(e,t,n,r){if(t===null||typeof t>"u"||ix(e,t,n,r))return!0;if(r)return!1;if(n!==null)switch(n.type){case 3:return!t;case 4:return t===!1;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}function ct(e,t,n,r,o,i,l){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=r,this.attributeNamespace=o,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=i,this.removeEmptyString=l}var Je={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){Je[e]=new ct(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];Je[t]=new ct(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){Je[e]=new ct(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){Je[e]=new ct(e,2,!1,e,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){Je[e]=new ct(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){Je[e]=new ct(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){Je[e]=new ct(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){Je[e]=new ct(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){Je[e]=new ct(e,5,!1,e.toLowerCase(),null,!1,!1)});var Zc=/[\-:]([a-z])/g;function Jc(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var t=e.replace(Zc,Jc);Je[t]=new ct(t,1,!1,e,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(Zc,Jc);Je[t]=new ct(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(Zc,Jc);Je[t]=new ct(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){Je[e]=new ct(e,1,!1,e.toLowerCase(),null,!1,!1)});Je.xlinkHref=new ct("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){Je[e]=new ct(e,1,!1,e.toLowerCase(),null,!0,!0)});function ep(e,t,n,r){var o=Je.hasOwnProperty(t)?Je[t]:null;(o!==null?o.type!==0:r||!(2a||o[l]!==i[a]){var s=` -`+o[l].replace(" at new "," at ");return e.displayName&&s.includes("")&&(s=s.replace("",e.displayName)),s}while(1<=l&&0<=a);break}}}finally{Ps=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?Wo(e):""}function tx(e){switch(e.tag){case 5:return Wo(e.type);case 16:return Wo("Lazy");case 13:return Wo("Suspense");case 19:return Wo("SuspenseList");case 0:case 2:case 15:return e=Ts(e.type,!1),e;case 11:return e=Ts(e.type.render,!1),e;case 1:return e=Ts(e.type,!0),e;default:return""}}function Ou(e){if(e==null)return null;if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case Ur:return"Fragment";case Br:return"Portal";case Eu:return"Profiler";case Zc:return"StrictMode";case Pu:return"Suspense";case Tu:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case Fg:return(e.displayName||"Context")+".Consumer";case Ig:return(e._context.displayName||"Context")+".Provider";case Jc:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case ep:return t=e.displayName||null,t!==null?t:Ou(e.type)||"Memo";case Bn:t=e._payload,e=e._init;try{return Ou(e(t))}catch{}}return null}function nx(e){var t=e.type;switch(e.tag){case 24:return"Cache";case 9:return(t.displayName||"Context")+".Consumer";case 10:return(t._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return e=t.render,e=e.displayName||e.name||"",t.displayName||(e!==""?"ForwardRef("+e+")":"ForwardRef");case 7:return"Fragment";case 5:return t;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return Ou(t);case 8:return t===Zc?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t}return null}function rr(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function Mg(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function rx(e){var t=Mg(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),r=""+e[t];if(!e.hasOwnProperty(t)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var o=n.get,i=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return o.call(this)},set:function(l){r=""+l,i.call(this,l)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(l){r=""+l},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function Gi(e){e._valueTracker||(e._valueTracker=rx(e))}function Bg(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=Mg(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function Bl(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}function Au(e,t){var n=t.checked;return Le({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function Nf(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=rr(t.value!=null?t.value:n),e._wrapperState={initialChecked:r,initialValue:n,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function Ug(e,t){t=t.checked,t!=null&&Xc(e,"checked",t,!1)}function _u(e,t){Ug(e,t);var n=rr(t.value),r=t.type;if(n!=null)r==="number"?(n===0&&e.value===""||e.value!=n)&&(e.value=""+n):e.value!==""+n&&(e.value=""+n);else if(r==="submit"||r==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?$u(e,t.type,n):t.hasOwnProperty("defaultValue")&&$u(e,t.type,rr(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function If(e,t,n){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var r=t.type;if(!(r!=="submit"&&r!=="reset"||t.value!==void 0&&t.value!==null))return;t=""+e._wrapperState.initialValue,n||t===e.value||(e.value=t),e.defaultValue=t}n=e.name,n!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,n!==""&&(e.name=n)}function $u(e,t,n){(t!=="number"||Bl(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var Vo=Array.isArray;function eo(e,t,n,r){if(e=e.options,t){t={};for(var o=0;o"+t.valueOf().toString()+"",t=qi.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function si(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var Yo={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},ox=["Webkit","ms","Moz","O"];Object.keys(Yo).forEach(function(e){ox.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),Yo[t]=Yo[e]})});function Gg(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||Yo.hasOwnProperty(e)&&Yo[e]?(""+t).trim():t+"px"}function qg(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,o=Gg(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,o):e[n]=o}}var ix=Le({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function zu(e,t){if(t){if(ix[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(I(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(I(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(I(61))}if(t.style!=null&&typeof t.style!="object")throw Error(I(62))}}function Du(e,t){if(e.indexOf("-")===-1)return typeof t.is=="string";switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var Nu=null;function tp(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var Iu=null,to=null,no=null;function Mf(e){if(e=Li(e)){if(typeof Iu!="function")throw Error(I(280));var t=e.stateNode;t&&(t=Ta(t),Iu(e.stateNode,e.type,t))}}function Yg(e){to?no?no.push(e):no=[e]:to=e}function Qg(){if(to){var e=to,t=no;if(no=to=null,Mf(e),t)for(e=0;e>>=0,e===0?32:31-(gx(e)/yx|0)|0}var Yi=64,Qi=4194304;function Go(e){switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return e&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return e&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return e}}function Vl(e,t){var n=e.pendingLanes;if(n===0)return 0;var r=0,o=e.suspendedLanes,i=e.pingedLanes,l=n&268435455;if(l!==0){var a=l&~o;a!==0?r=Go(a):(i&=l,i!==0&&(r=Go(i)))}else l=n&~o,l!==0?r=Go(l):i!==0&&(r=Go(i));if(r===0)return 0;if(t!==0&&t!==r&&!(t&o)&&(o=r&-r,i=t&-t,o>=i||o===16&&(i&4194240)!==0))return t;if(r&4&&(r|=n&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=r;0n;n++)t.push(e);return t}function $i(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-Kt(t),e[t]=n}function bx(e,t){var n=e.pendingLanes&~t;e.pendingLanes=t,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=t,e.mutableReadLanes&=t,e.entangledLanes&=t,t=e.entanglements;var r=e.eventTimes;for(e=e.expirationTimes;0=Ko),Qf=String.fromCharCode(32),Kf=!1;function my(e,t){switch(e){case"keyup":return Qx.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function gy(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var Hr=!1;function Xx(e,t){switch(e){case"compositionend":return gy(t);case"keypress":return t.which!==32?null:(Kf=!0,Qf);case"textInput":return e=t.data,e===Qf&&Kf?null:e;default:return null}}function Zx(e,t){if(Hr)return e==="compositionend"||!up&&my(e,t)?(e=dy(),kl=lp=Vn=null,Hr=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1=t)return{node:n,offset:t-e};e=r}e:{for(;n;){if(n.nextSibling){n=n.nextSibling;break e}n=n.parentNode}n=void 0}n=ed(n)}}function xy(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?xy(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function by(){for(var e=window,t=Bl();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=Bl(e.document)}return t}function cp(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}function ab(e){var t=by(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&xy(n.ownerDocument.documentElement,n)){if(r!==null&&cp(n)){if(t=r.start,e=r.end,e===void 0&&(e=t),"selectionStart"in n)n.selectionStart=t,n.selectionEnd=Math.min(e,n.value.length);else if(e=(t=n.ownerDocument||document)&&t.defaultView||window,e.getSelection){e=e.getSelection();var o=n.textContent.length,i=Math.min(r.start,o);r=r.end===void 0?i:Math.min(r.end,o),!e.extend&&i>r&&(o=r,r=i,i=o),o=td(n,i);var l=td(n,r);o&&l&&(e.rangeCount!==1||e.anchorNode!==o.node||e.anchorOffset!==o.offset||e.focusNode!==l.node||e.focusOffset!==l.offset)&&(t=t.createRange(),t.setStart(o.node,o.offset),e.removeAllRanges(),i>r?(e.addRange(t),e.extend(l.node,l.offset)):(t.setEnd(l.node,l.offset),e.addRange(t)))}}for(t=[],e=n;e=e.parentNode;)e.nodeType===1&&t.push({element:e,left:e.scrollLeft,top:e.scrollTop});for(typeof n.focus=="function"&&n.focus(),n=0;n=document.documentMode,Wr=null,Hu=null,Zo=null,Wu=!1;function nd(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;Wu||Wr==null||Wr!==Bl(r)||(r=Wr,"selectionStart"in r&&cp(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),Zo&&hi(Zo,r)||(Zo=r,r=Yl(Hu,"onSelect"),0qr||(e.current=Ku[qr],Ku[qr]=null,qr--)}function Ee(e,t){qr++,Ku[qr]=e.current,e.current=t}var or={},rt=cr(or),ht=cr(!1),Cr=or;function uo(e,t){var n=e.type.contextTypes;if(!n)return or;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var o={},i;for(i in n)o[i]=t[i];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=o),o}function mt(e){return e=e.childContextTypes,e!=null}function Kl(){Oe(ht),Oe(rt)}function ud(e,t,n){if(rt.current!==or)throw Error(I(168));Ee(rt,t),Ee(ht,n)}function _y(e,t,n){var r=e.stateNode;if(t=t.childContextTypes,typeof r.getChildContext!="function")return n;r=r.getChildContext();for(var o in r)if(!(o in t))throw Error(I(108,nx(e)||"Unknown",o));return Le({},n,r)}function Xl(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||or,Cr=rt.current,Ee(rt,e),Ee(ht,ht.current),!0}function cd(e,t,n){var r=e.stateNode;if(!r)throw Error(I(169));n?(e=_y(e,t,Cr),r.__reactInternalMemoizedMergedChildContext=e,Oe(ht),Oe(rt),Ee(rt,e)):Oe(ht),Ee(ht,n)}var vn=null,Oa=!1,Bs=!1;function $y(e){vn===null?vn=[e]:vn.push(e)}function wb(e){Oa=!0,$y(e)}function pr(){if(!Bs&&vn!==null){Bs=!0;var e=0,t=ve;try{var n=vn;for(ve=1;e>=l,o-=l,wn=1<<32-Kt(t)+o|n<A?(N=T,T=null):N=T.sibling;var P=d(g,T,v[A],C);if(P===null){T===null&&(T=N);break}e&&T&&P.alternate===null&&t(g,T),y=i(P,y,A),k===null?E=P:k.sibling=P,k=P,T=N}if(A===v.length)return n(g,T),Ae&&mr(g,A),E;if(T===null){for(;AA?(N=T,T=null):N=T.sibling;var z=d(g,T,P.value,C);if(z===null){T===null&&(T=N);break}e&&T&&z.alternate===null&&t(g,T),y=i(z,y,A),k===null?E=z:k.sibling=z,k=z,T=N}if(P.done)return n(g,T),Ae&&mr(g,A),E;if(T===null){for(;!P.done;A++,P=v.next())P=p(g,P.value,C),P!==null&&(y=i(P,y,A),k===null?E=P:k.sibling=P,k=P);return Ae&&mr(g,A),E}for(T=r(g,T);!P.done;A++,P=v.next())P=f(T,g,A,P.value,C),P!==null&&(e&&P.alternate!==null&&T.delete(P.key===null?A:P.key),y=i(P,y,A),k===null?E=P:k.sibling=P,k=P);return e&&T.forEach(function(_){return t(g,_)}),Ae&&mr(g,A),E}function w(g,y,v,C){if(typeof v=="object"&&v!==null&&v.type===Ur&&v.key===null&&(v=v.props.children),typeof v=="object"&&v!==null){switch(v.$$typeof){case Vi:e:{for(var E=v.key,k=y;k!==null;){if(k.key===E){if(E=v.type,E===Ur){if(k.tag===7){n(g,k.sibling),y=o(k,v.props.children),y.return=g,g=y;break e}}else if(k.elementType===E||typeof E=="object"&&E!==null&&E.$$typeof===Bn&&yd(E)===k.type){n(g,k.sibling),y=o(k,v.props),y.ref=Io(g,k,v),y.return=g,g=y;break e}n(g,k);break}else t(g,k);k=k.sibling}v.type===Ur?(y=Sr(v.props.children,g.mode,C,v.key),y.return=g,g=y):(C=_l(v.type,v.key,v.props,null,g.mode,C),C.ref=Io(g,y,v),C.return=g,g=C)}return l(g);case Br:e:{for(k=v.key;y!==null;){if(y.key===k)if(y.tag===4&&y.stateNode.containerInfo===v.containerInfo&&y.stateNode.implementation===v.implementation){n(g,y.sibling),y=o(y,v.children||[]),y.return=g,g=y;break e}else{n(g,y);break}else t(g,y);y=y.sibling}y=Qs(v,g.mode,C),y.return=g,g=y}return l(g);case Bn:return k=v._init,w(g,y,k(v._payload),C)}if(Vo(v))return h(g,y,v,C);if(Ro(v))return m(g,y,v,C);nl(g,v)}return typeof v=="string"&&v!==""||typeof v=="number"?(v=""+v,y!==null&&y.tag===6?(n(g,y.sibling),y=o(y,v),y.return=g,g=y):(n(g,y),y=Ys(v,g.mode,C),y.return=g,g=y),l(g)):n(g,y)}return w}var po=jy(!0),My=jy(!1),zi={},sn=cr(zi),vi=cr(zi),wi=cr(zi);function xr(e){if(e===zi)throw Error(I(174));return e}function wp(e,t){switch(Ee(wi,t),Ee(vi,e),Ee(sn,zi),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:Lu(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=Lu(t,e)}Oe(sn),Ee(sn,t)}function fo(){Oe(sn),Oe(vi),Oe(wi)}function By(e){xr(wi.current);var t=xr(sn.current),n=Lu(t,e.type);t!==n&&(Ee(vi,e),Ee(sn,n))}function xp(e){vi.current===e&&(Oe(sn),Oe(vi))}var $e=cr(0);function ra(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||n.data==="$?"||n.data==="$!"))return t}else if(t.tag===19&&t.memoizedProps.revealOrder!==void 0){if(t.flags&128)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var Us=[];function bp(){for(var e=0;en?n:4,e(!0);var r=Hs.transition;Hs.transition={};try{e(!1),t()}finally{ve=n,Hs.transition=r}}function r0(){return It().memoizedState}function Sb(e,t,n){var r=Jn(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},o0(e))i0(t,n);else if(n=Dy(e,t,n,r),n!==null){var o=at();Xt(n,e,r,o),l0(n,t,r)}}function Cb(e,t,n){var r=Jn(e),o={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(o0(e))i0(t,o);else{var i=e.alternate;if(e.lanes===0&&(i===null||i.lanes===0)&&(i=t.lastRenderedReducer,i!==null))try{var l=t.lastRenderedState,a=i(l,n);if(o.hasEagerState=!0,o.eagerState=a,Jt(a,l)){var s=t.interleaved;s===null?(o.next=o,yp(t)):(o.next=s.next,s.next=o),t.interleaved=o;return}}catch{}finally{}n=Dy(e,t,o,r),n!==null&&(o=at(),Xt(n,e,r,o),l0(n,t,r))}}function o0(e){var t=e.alternate;return e===Re||t!==null&&t===Re}function i0(e,t){Jo=oa=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function l0(e,t,n){if(n&4194240){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,rp(e,n)}}var ia={readContext:Nt,useCallback:Je,useContext:Je,useEffect:Je,useImperativeHandle:Je,useInsertionEffect:Je,useLayoutEffect:Je,useMemo:Je,useReducer:Je,useRef:Je,useState:Je,useDebugValue:Je,useDeferredValue:Je,useTransition:Je,useMutableSource:Je,useSyncExternalStore:Je,useId:Je,unstable_isNewReconciler:!1},Eb={readContext:Nt,useCallback:function(e,t){return tn().memoizedState=[e,t===void 0?null:t],e},useContext:Nt,useEffect:wd,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,Pl(4194308,4,Zy.bind(null,t,e),n)},useLayoutEffect:function(e,t){return Pl(4194308,4,e,t)},useInsertionEffect:function(e,t){return Pl(4,2,e,t)},useMemo:function(e,t){var n=tn();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=tn();return t=n!==void 0?n(t):t,r.memoizedState=r.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},r.queue=e,e=e.dispatch=Sb.bind(null,Re,e),[r.memoizedState,e]},useRef:function(e){var t=tn();return e={current:e},t.memoizedState=e},useState:vd,useDebugValue:Pp,useDeferredValue:function(e){return tn().memoizedState=e},useTransition:function(){var e=vd(!1),t=e[0];return e=kb.bind(null,e[1]),tn().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var r=Re,o=tn();if(Ae){if(n===void 0)throw Error(I(407));n=n()}else{if(n=t(),Ye===null)throw Error(I(349));Pr&30||Wy(r,t,n)}o.memoizedState=n;var i={value:n,getSnapshot:t};return o.queue=i,wd(Gy.bind(null,r,i,e),[e]),r.flags|=2048,ki(9,Vy.bind(null,r,i,n,t),void 0,null),n},useId:function(){var e=tn(),t=Ye.identifierPrefix;if(Ae){var n=xn,r=wn;n=(r&~(1<<32-Kt(r)-1)).toString(32)+n,t=":"+t+"R"+n,n=xi++,0")&&(s=s.replace("",e.displayName)),s}while(1<=l&&0<=a);break}}}finally{As=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?Vo(e):""}function ax(e){switch(e.tag){case 5:return Vo(e.type);case 16:return Vo("Lazy");case 13:return Vo("Suspense");case 19:return Vo("SuspenseList");case 0:case 2:case 15:return e=$s(e.type,!1),e;case 11:return e=$s(e.type.render,!1),e;case 1:return e=$s(e.type,!0),e;default:return""}}function _u(e){if(e==null)return null;if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case Hr:return"Fragment";case Ur:return"Portal";case Tu:return"Profiler";case tp:return"StrictMode";case Au:return"Suspense";case $u:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case Ug:return(e.displayName||"Context")+".Consumer";case Bg:return(e._context.displayName||"Context")+".Provider";case np:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case rp:return t=e.displayName||null,t!==null?t:_u(e.type)||"Memo";case Bn:t=e._payload,e=e._init;try{return _u(e(t))}catch{}}return null}function sx(e){var t=e.type;switch(e.tag){case 24:return"Cache";case 9:return(t.displayName||"Context")+".Consumer";case 10:return(t._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return e=t.render,e=e.displayName||e.name||"",t.displayName||(e!==""?"ForwardRef("+e+")":"ForwardRef");case 7:return"Fragment";case 5:return t;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return _u(t);case 8:return t===tp?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t}return null}function rr(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function Wg(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function ux(e){var t=Wg(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),r=""+e[t];if(!e.hasOwnProperty(t)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var o=n.get,i=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return o.call(this)},set:function(l){r=""+l,i.call(this,l)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(l){r=""+l},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function Yi(e){e._valueTracker||(e._valueTracker=ux(e))}function Vg(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=Wg(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function Wl(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}function Ru(e,t){var n=t.checked;return De({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function Ff(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=rr(t.value!=null?t.value:n),e._wrapperState={initialChecked:r,initialValue:n,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function Gg(e,t){t=t.checked,t!=null&&ep(e,"checked",t,!1)}function Lu(e,t){Gg(e,t);var n=rr(t.value),r=t.type;if(n!=null)r==="number"?(n===0&&e.value===""||e.value!=n)&&(e.value=""+n):e.value!==""+n&&(e.value=""+n);else if(r==="submit"||r==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?Du(e,t.type,n):t.hasOwnProperty("defaultValue")&&Du(e,t.type,rr(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function jf(e,t,n){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var r=t.type;if(!(r!=="submit"&&r!=="reset"||t.value!==void 0&&t.value!==null))return;t=""+e._wrapperState.initialValue,n||t===e.value||(e.value=t),e.defaultValue=t}n=e.name,n!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,n!==""&&(e.name=n)}function Du(e,t,n){(t!=="number"||Wl(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var Go=Array.isArray;function to(e,t,n,r){if(e=e.options,t){t={};for(var o=0;o"+t.valueOf().toString()+"",t=Qi.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function ui(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var Qo={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},cx=["Webkit","ms","Moz","O"];Object.keys(Qo).forEach(function(e){cx.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),Qo[t]=Qo[e]})});function Kg(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||Qo.hasOwnProperty(e)&&Qo[e]?(""+t).trim():t+"px"}function Xg(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,o=Kg(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,o):e[n]=o}}var px=De({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function Iu(e,t){if(t){if(px[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(F(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(F(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(F(61))}if(t.style!=null&&typeof t.style!="object")throw Error(F(62))}}function Fu(e,t){if(e.indexOf("-")===-1)return typeof t.is=="string";switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var ju=null;function op(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var Mu=null,no=null,ro=null;function Uf(e){if(e=Di(e)){if(typeof Mu!="function")throw Error(F(280));var t=e.stateNode;t&&(t=$a(t),Mu(e.stateNode,e.type,t))}}function Zg(e){no?ro?ro.push(e):ro=[e]:no=e}function Jg(){if(no){var e=no,t=ro;if(ro=no=null,Uf(e),t)for(e=0;e>>=0,e===0?32:31-(kx(e)/Sx|0)|0}var Ki=64,Xi=4194304;function qo(e){switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return e&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return e&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return e}}function Yl(e,t){var n=e.pendingLanes;if(n===0)return 0;var r=0,o=e.suspendedLanes,i=e.pingedLanes,l=n&268435455;if(l!==0){var a=l&~o;a!==0?r=qo(a):(i&=l,i!==0&&(r=qo(i)))}else l=n&~o,l!==0?r=qo(l):i!==0&&(r=qo(i));if(r===0)return 0;if(t!==0&&t!==r&&!(t&o)&&(o=r&-r,i=t&-t,o>=i||o===16&&(i&4194240)!==0))return t;if(r&4&&(r|=n&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=r;0n;n++)t.push(e);return t}function Ri(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-Kt(t),e[t]=n}function Ox(e,t){var n=e.pendingLanes&~t;e.pendingLanes=t,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=t,e.mutableReadLanes&=t,e.entangledLanes&=t,t=e.entanglements;var r=e.eventTimes;for(e=e.expirationTimes;0=Xo),Xf=String.fromCharCode(32),Zf=!1;function wy(e,t){switch(e){case"keyup":return tb.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function xy(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var Wr=!1;function rb(e,t){switch(e){case"compositionend":return xy(t);case"keypress":return t.which!==32?null:(Zf=!0,Xf);case"textInput":return e=t.data,e===Xf&&Zf?null:e;default:return null}}function ob(e,t){if(Wr)return e==="compositionend"||!fp&&wy(e,t)?(e=yy(),Cl=up=Vn=null,Wr=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1=t)return{node:n,offset:t-e};e=r}e:{for(;n;){if(n.nextSibling){n=n.nextSibling;break e}n=n.parentNode}n=void 0}n=nd(n)}}function Cy(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Cy(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function Ey(){for(var e=window,t=Wl();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=Wl(e.document)}return t}function dp(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}function db(e){var t=Ey(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&Cy(n.ownerDocument.documentElement,n)){if(r!==null&&dp(n)){if(t=r.start,e=r.end,e===void 0&&(e=t),"selectionStart"in n)n.selectionStart=t,n.selectionEnd=Math.min(e,n.value.length);else if(e=(t=n.ownerDocument||document)&&t.defaultView||window,e.getSelection){e=e.getSelection();var o=n.textContent.length,i=Math.min(r.start,o);r=r.end===void 0?i:Math.min(r.end,o),!e.extend&&i>r&&(o=r,r=i,i=o),o=rd(n,i);var l=rd(n,r);o&&l&&(e.rangeCount!==1||e.anchorNode!==o.node||e.anchorOffset!==o.offset||e.focusNode!==l.node||e.focusOffset!==l.offset)&&(t=t.createRange(),t.setStart(o.node,o.offset),e.removeAllRanges(),i>r?(e.addRange(t),e.extend(l.node,l.offset)):(t.setEnd(l.node,l.offset),e.addRange(t)))}}for(t=[],e=n;e=e.parentNode;)e.nodeType===1&&t.push({element:e,left:e.scrollLeft,top:e.scrollTop});for(typeof n.focus=="function"&&n.focus(),n=0;n=document.documentMode,Vr=null,Gu=null,Jo=null,qu=!1;function od(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;qu||Vr==null||Vr!==Wl(r)||(r=Vr,"selectionStart"in r&&dp(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),Jo&&mi(Jo,r)||(Jo=r,r=Xl(Gu,"onSelect"),0Yr||(e.current=Ju[Yr],Ju[Yr]=null,Yr--)}function Ce(e,t){Yr++,Ju[Yr]=e.current,e.current=t}var or={},ot=ur(or),ht=ur(!1),Cr=or;function co(e,t){var n=e.type.contextTypes;if(!n)return or;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var o={},i;for(i in n)o[i]=t[i];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=o),o}function mt(e){return e=e.childContextTypes,e!=null}function Jl(){Ae(ht),Ae(ot)}function pd(e,t,n){if(ot.current!==or)throw Error(F(168));Ce(ot,t),Ce(ht,n)}function Dy(e,t,n){var r=e.stateNode;if(t=t.childContextTypes,typeof r.getChildContext!="function")return n;r=r.getChildContext();for(var o in r)if(!(o in t))throw Error(F(108,sx(e)||"Unknown",o));return De({},n,r)}function ea(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||or,Cr=ot.current,Ce(ot,e),Ce(ht,ht.current),!0}function fd(e,t,n){var r=e.stateNode;if(!r)throw Error(F(169));n?(e=Dy(e,t,Cr),r.__reactInternalMemoizedMergedChildContext=e,Ae(ht),Ae(ot),Ce(ot,e)):Ae(ht),Ce(ht,n)}var vn=null,_a=!1,Ws=!1;function zy(e){vn===null?vn=[e]:vn.push(e)}function Eb(e){_a=!0,zy(e)}function cr(){if(!Ws&&vn!==null){Ws=!0;var e=0,t=ve;try{var n=vn;for(ve=1;e>=l,o-=l,wn=1<<32-Kt(t)+o|n<T?(N=O,O=null):N=O.sibling;var P=d(g,O,v[T],C);if(P===null){O===null&&(O=N);break}e&&O&&P.alternate===null&&t(g,O),y=i(P,y,T),k===null?E=P:k.sibling=P,k=P,O=N}if(T===v.length)return n(g,O),$e&&mr(g,T),E;if(O===null){for(;TT?(N=O,O=null):N=O.sibling;var _=d(g,O,P.value,C);if(_===null){O===null&&(O=N);break}e&&O&&_.alternate===null&&t(g,O),y=i(_,y,T),k===null?E=_:k.sibling=_,k=_,O=N}if(P.done)return n(g,O),$e&&mr(g,T),E;if(O===null){for(;!P.done;T++,P=v.next())P=c(g,P.value,C),P!==null&&(y=i(P,y,T),k===null?E=P:k.sibling=P,k=P);return $e&&mr(g,T),E}for(O=r(g,O);!P.done;T++,P=v.next())P=f(O,g,T,P.value,C),P!==null&&(e&&P.alternate!==null&&O.delete(P.key===null?T:P.key),y=i(P,y,T),k===null?E=P:k.sibling=P,k=P);return e&&O.forEach(function(R){return t(g,R)}),$e&&mr(g,T),E}function w(g,y,v,C){if(typeof v=="object"&&v!==null&&v.type===Hr&&v.key===null&&(v=v.props.children),typeof v=="object"&&v!==null){switch(v.$$typeof){case qi:e:{for(var E=v.key,k=y;k!==null;){if(k.key===E){if(E=v.type,E===Hr){if(k.tag===7){n(g,k.sibling),y=o(k,v.props.children),y.return=g,g=y;break e}}else if(k.elementType===E||typeof E=="object"&&E!==null&&E.$$typeof===Bn&&wd(E)===k.type){n(g,k.sibling),y=o(k,v.props),y.ref=Fo(g,k,v),y.return=g,g=y;break e}n(g,k);break}else t(g,k);k=k.sibling}v.type===Hr?(y=Sr(v.props.children,g.mode,C,v.key),y.return=g,g=y):(C=Rl(v.type,v.key,v.props,null,g.mode,C),C.ref=Fo(g,y,v),C.return=g,g=C)}return l(g);case Ur:e:{for(k=v.key;y!==null;){if(y.key===k)if(y.tag===4&&y.stateNode.containerInfo===v.containerInfo&&y.stateNode.implementation===v.implementation){n(g,y.sibling),y=o(y,v.children||[]),y.return=g,g=y;break e}else{n(g,y);break}else t(g,y);y=y.sibling}y=Zs(v,g.mode,C),y.return=g,g=y}return l(g);case Bn:return k=v._init,w(g,y,k(v._payload),C)}if(Go(v))return h(g,y,v,C);if(Lo(v))return m(g,y,v,C);ol(g,v)}return typeof v=="string"&&v!==""||typeof v=="number"?(v=""+v,y!==null&&y.tag===6?(n(g,y.sibling),y=o(y,v),y.return=g,g=y):(n(g,y),y=Xs(v,g.mode,C),y.return=g,g=y),l(g)):n(g,y)}return w}var fo=Hy(!0),Wy=Hy(!1),zi={},sn=ur(zi),wi=ur(zi),xi=ur(zi);function xr(e){if(e===zi)throw Error(F(174));return e}function kp(e,t){switch(Ce(xi,t),Ce(wi,e),Ce(sn,zi),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:Nu(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=Nu(t,e)}Ae(sn),Ce(sn,t)}function ho(){Ae(sn),Ae(wi),Ae(xi)}function Vy(e){xr(xi.current);var t=xr(sn.current),n=Nu(t,e.type);t!==n&&(Ce(wi,e),Ce(sn,n))}function Sp(e){wi.current===e&&(Ae(sn),Ae(wi))}var Re=ur(0);function la(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||n.data==="$?"||n.data==="$!"))return t}else if(t.tag===19&&t.memoizedProps.revealOrder!==void 0){if(t.flags&128)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var Vs=[];function Cp(){for(var e=0;en?n:4,e(!0);var r=Gs.transition;Gs.transition={};try{e(!1),t()}finally{ve=n,Gs.transition=r}}function a0(){return It().memoizedState}function Ab(e,t,n){var r=Jn(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},s0(e))u0(t,n);else if(n=jy(e,t,n,r),n!==null){var o=st();Xt(n,e,r,o),c0(n,t,r)}}function $b(e,t,n){var r=Jn(e),o={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(s0(e))u0(t,o);else{var i=e.alternate;if(e.lanes===0&&(i===null||i.lanes===0)&&(i=t.lastRenderedReducer,i!==null))try{var l=t.lastRenderedState,a=i(l,n);if(o.hasEagerState=!0,o.eagerState=a,Jt(a,l)){var s=t.interleaved;s===null?(o.next=o,xp(t)):(o.next=s.next,s.next=o),t.interleaved=o;return}}catch{}finally{}n=jy(e,t,o,r),n!==null&&(o=st(),Xt(n,e,r,o),c0(n,t,r))}}function s0(e){var t=e.alternate;return e===Le||t!==null&&t===Le}function u0(e,t){ei=aa=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function c0(e,t,n){if(n&4194240){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,lp(e,n)}}var sa={readContext:Nt,useCallback:et,useContext:et,useEffect:et,useImperativeHandle:et,useInsertionEffect:et,useLayoutEffect:et,useMemo:et,useReducer:et,useRef:et,useState:et,useDebugValue:et,useDeferredValue:et,useTransition:et,useMutableSource:et,useSyncExternalStore:et,useId:et,unstable_isNewReconciler:!1},_b={readContext:Nt,useCallback:function(e,t){return nn().memoizedState=[e,t===void 0?null:t],e},useContext:Nt,useEffect:bd,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,Tl(4194308,4,n0.bind(null,t,e),n)},useLayoutEffect:function(e,t){return Tl(4194308,4,e,t)},useInsertionEffect:function(e,t){return Tl(4,2,e,t)},useMemo:function(e,t){var n=nn();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=nn();return t=n!==void 0?n(t):t,r.memoizedState=r.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},r.queue=e,e=e.dispatch=Ab.bind(null,Le,e),[r.memoizedState,e]},useRef:function(e){var t=nn();return e={current:e},t.memoizedState=e},useState:xd,useDebugValue:Ap,useDeferredValue:function(e){return nn().memoizedState=e},useTransition:function(){var e=xd(!1),t=e[0];return e=Tb.bind(null,e[1]),nn().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var r=Le,o=nn();if($e){if(n===void 0)throw Error(F(407));n=n()}else{if(n=t(),Ye===null)throw Error(F(349));Pr&30||Yy(r,t,n)}o.memoizedState=n;var i={value:n,getSnapshot:t};return o.queue=i,bd(Ky.bind(null,r,i,e),[e]),r.flags|=2048,Si(9,Qy.bind(null,r,i,n,t),void 0,null),n},useId:function(){var e=nn(),t=Ye.identifierPrefix;if($e){var n=xn,r=wn;n=(r&~(1<<32-Kt(r)-1)).toString(32)+n,t=":"+t+"R"+n,n=bi++,0<\/script>",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=l.createElement(n,{is:r.is}):(e=l.createElement(n),n==="select"&&(l=e,r.multiple?l.multiple=!0:r.size&&(l.size=r.size))):e=l.createElementNS(e,n),e[rn]=t,e[yi]=r,m0(e,t,!1,!1),t.stateNode=e;e:{switch(l=Du(n,r),n){case"dialog":Te("cancel",e),Te("close",e),o=r;break;case"iframe":case"object":case"embed":Te("load",e),o=r;break;case"video":case"audio":for(o=0;omo&&(t.flags|=128,r=!0,Fo(i,!1),t.lanes=4194304)}else{if(!r)if(e=ra(l),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),Fo(i,!0),i.tail===null&&i.tailMode==="hidden"&&!l.alternate&&!Ae)return et(t),null}else 2*Me()-i.renderingStartTime>mo&&n!==1073741824&&(t.flags|=128,r=!0,Fo(i,!1),t.lanes=4194304);i.isBackwards?(l.sibling=t.child,t.child=l):(n=i.last,n!==null?n.sibling=l:t.child=l,i.last=l)}return i.tail!==null?(t=i.tail,i.rendering=t,i.tail=t.sibling,i.renderingStartTime=Me(),t.sibling=null,n=$e.current,Ee($e,r?n&1|2:n&1),t):(et(t),null);case 22:case 23:return Rp(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?wt&1073741824&&(et(t),t.subtreeFlags&6&&(t.flags|=8192)):et(t),null;case 24:return null;case 25:return null}throw Error(I(156,t.tag))}function Lb(e,t){switch(fp(t),t.tag){case 1:return mt(t.type)&&Kl(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return fo(),Oe(ht),Oe(rt),bp(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return xp(t),null;case 13:if(Oe($e),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(I(340));co()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return Oe($e),null;case 4:return fo(),null;case 10:return gp(t.type._context),null;case 22:case 23:return Rp(),null;case 24:return null;default:return null}}var ol=!1,tt=!1,zb=typeof WeakSet=="function"?WeakSet:Set,G=null;function Xr(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){Ie(e,t,r)}else n.current=null}function sc(e,t,n){try{n()}catch(r){Ie(e,t,r)}}var Od=!1;function Db(e,t){if(Vu=Gl,e=by(),cp(e)){if("selectionStart"in e)var n={start:e.selectionStart,end:e.selectionEnd};else e:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var o=r.anchorOffset,i=r.focusNode;r=r.focusOffset;try{n.nodeType,i.nodeType}catch{n=null;break e}var l=0,a=-1,s=-1,u=0,c=0,p=e,d=null;t:for(;;){for(var f;p!==n||o!==0&&p.nodeType!==3||(a=l+o),p!==i||r!==0&&p.nodeType!==3||(s=l+r),p.nodeType===3&&(l+=p.nodeValue.length),(f=p.firstChild)!==null;)d=p,p=f;for(;;){if(p===e)break t;if(d===n&&++u===o&&(a=l),d===i&&++c===r&&(s=l),(f=p.nextSibling)!==null)break;p=d,d=p.parentNode}p=f}n=a===-1||s===-1?null:{start:a,end:s}}else n=null}n=n||{start:0,end:0}}else n=null;for(Gu={focusedElem:e,selectionRange:n},Gl=!1,G=t;G!==null;)if(t=G,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,G=e;else for(;G!==null;){t=G;try{var h=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(h!==null){var m=h.memoizedProps,w=h.memoizedState,g=t.stateNode,y=g.getSnapshotBeforeUpdate(t.elementType===t.type?m:qt(t.type,m),w);g.__reactInternalSnapshotBeforeUpdate=y}break;case 3:var v=t.stateNode.containerInfo;v.nodeType===1?v.textContent="":v.nodeType===9&&v.documentElement&&v.removeChild(v.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(I(163))}}catch(C){Ie(t,t.return,C)}if(e=t.sibling,e!==null){e.return=t.return,G=e;break}G=t.return}return h=Od,Od=!1,h}function ei(e,t,n){var r=t.updateQueue;if(r=r!==null?r.lastEffect:null,r!==null){var o=r=r.next;do{if((o.tag&e)===e){var i=o.destroy;o.destroy=void 0,i!==void 0&&sc(t,n,i)}o=o.next}while(o!==r)}}function $a(e,t){if(t=t.updateQueue,t=t!==null?t.lastEffect:null,t!==null){var n=t=t.next;do{if((n.tag&e)===e){var r=n.create;n.destroy=r()}n=n.next}while(n!==t)}}function uc(e){var t=e.ref;if(t!==null){var n=e.stateNode;switch(e.tag){case 5:e=n;break;default:e=n}typeof t=="function"?t(e):t.current=e}}function v0(e){var t=e.alternate;t!==null&&(e.alternate=null,v0(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[rn],delete t[yi],delete t[Qu],delete t[yb],delete t[vb])),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function w0(e){return e.tag===5||e.tag===3||e.tag===4}function Ad(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||w0(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function cc(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.nodeType===8?n.parentNode.insertBefore(e,t):n.insertBefore(e,t):(n.nodeType===8?(t=n.parentNode,t.insertBefore(e,n)):(t=n,t.appendChild(e)),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=Ql));else if(r!==4&&(e=e.child,e!==null))for(cc(e,t,n),e=e.sibling;e!==null;)cc(e,t,n),e=e.sibling}function pc(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(e=e.child,e!==null))for(pc(e,t,n),e=e.sibling;e!==null;)pc(e,t,n),e=e.sibling}var Ke=null,Yt=!1;function Nn(e,t,n){for(n=n.child;n!==null;)x0(e,t,n),n=n.sibling}function x0(e,t,n){if(an&&typeof an.onCommitFiberUnmount=="function")try{an.onCommitFiberUnmount(Sa,n)}catch{}switch(n.tag){case 5:tt||Xr(n,t);case 6:var r=Ke,o=Yt;Ke=null,Nn(e,t,n),Ke=r,Yt=o,Ke!==null&&(Yt?(e=Ke,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):Ke.removeChild(n.stateNode));break;case 18:Ke!==null&&(Yt?(e=Ke,n=n.stateNode,e.nodeType===8?Ms(e.parentNode,n):e.nodeType===1&&Ms(e,n),fi(e)):Ms(Ke,n.stateNode));break;case 4:r=Ke,o=Yt,Ke=n.stateNode.containerInfo,Yt=!0,Nn(e,t,n),Ke=r,Yt=o;break;case 0:case 11:case 14:case 15:if(!tt&&(r=n.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){o=r=r.next;do{var i=o,l=i.destroy;i=i.tag,l!==void 0&&(i&2||i&4)&&sc(n,t,l),o=o.next}while(o!==r)}Nn(e,t,n);break;case 1:if(!tt&&(Xr(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(a){Ie(n,t,a)}Nn(e,t,n);break;case 21:Nn(e,t,n);break;case 22:n.mode&1?(tt=(r=tt)||n.memoizedState!==null,Nn(e,t,n),tt=r):Nn(e,t,n);break;default:Nn(e,t,n)}}function _d(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new zb),t.forEach(function(r){var o=Wb.bind(null,e,r);n.has(r)||(n.add(r),r.then(o,o))})}}function Wt(e,t){var n=t.deletions;if(n!==null)for(var r=0;ro&&(o=l),r&=~i}if(r=o,r=Me()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*Ib(r/1960))-r,10e?16:e,Gn===null)var r=!1;else{if(e=Gn,Gn=null,sa=0,ge&6)throw Error(I(331));var o=ge;for(ge|=4,G=e.current;G!==null;){var i=G,l=i.child;if(G.flags&16){var a=i.deletions;if(a!==null){for(var s=0;sMe()-_p?kr(e,0):Ap|=n),gt(e,t)}function O0(e,t){t===0&&(e.mode&1?(t=Qi,Qi<<=1,!(Qi&130023424)&&(Qi=4194304)):t=1);var n=at();e=Pn(e,t),e!==null&&($i(e,t,n),gt(e,n))}function Hb(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),O0(e,n)}function Wb(e,t){var n=0;switch(e.tag){case 13:var r=e.stateNode,o=e.memoizedState;o!==null&&(n=o.retryLane);break;case 19:r=e.stateNode;break;default:throw Error(I(314))}r!==null&&r.delete(t),O0(e,n)}var A0;A0=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||ht.current)dt=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return dt=!1,$b(e,t,n);dt=!!(e.flags&131072)}else dt=!1,Ae&&t.flags&1048576&&Ry(t,Jl,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;Tl(e,t),e=t.pendingProps;var o=uo(t,rt.current);oo(t,n),o=Sp(null,t,r,e,o,n);var i=Cp();return t.flags|=1,typeof o=="object"&&o!==null&&typeof o.render=="function"&&o.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,mt(r)?(i=!0,Xl(t)):i=!1,t.memoizedState=o.state!==null&&o.state!==void 0?o.state:null,vp(t),o.updater=Aa,t.stateNode=o,o._reactInternals=t,tc(t,r,e,n),t=oc(null,t,r,!0,i,n)):(t.tag=0,Ae&&i&&pp(t),it(null,t,o,n),t=t.child),t;case 16:r=t.elementType;e:{switch(Tl(e,t),e=t.pendingProps,o=r._init,r=o(r._payload),t.type=r,o=t.tag=Gb(r),e=qt(r,e),o){case 0:t=rc(null,t,r,e,n);break e;case 1:t=Ed(null,t,r,e,n);break e;case 11:t=Sd(null,t,r,e,n);break e;case 14:t=Cd(null,t,r,qt(r.type,e),n);break e}throw Error(I(306,r,""))}return t;case 0:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:qt(r,o),rc(e,t,r,o,n);case 1:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:qt(r,o),Ed(e,t,r,o,n);case 3:e:{if(f0(t),e===null)throw Error(I(387));r=t.pendingProps,i=t.memoizedState,o=i.element,Ny(e,t),na(t,r,null,n);var l=t.memoizedState;if(r=l.element,i.isDehydrated)if(i={element:r,isDehydrated:!1,cache:l.cache,pendingSuspenseBoundaries:l.pendingSuspenseBoundaries,transitions:l.transitions},t.updateQueue.baseState=i,t.memoizedState=i,t.flags&256){o=ho(Error(I(423)),t),t=Pd(e,t,r,n,o);break e}else if(r!==o){o=ho(Error(I(424)),t),t=Pd(e,t,r,n,o);break e}else for(bt=Kn(t.stateNode.containerInfo.firstChild),kt=t,Ae=!0,Qt=null,n=My(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(co(),r===o){t=Tn(e,t,n);break e}it(e,t,r,n)}t=t.child}return t;case 5:return By(t),e===null&&Zu(t),r=t.type,o=t.pendingProps,i=e!==null?e.memoizedProps:null,l=o.children,qu(r,o)?l=null:i!==null&&qu(r,i)&&(t.flags|=32),p0(e,t),it(e,t,l,n),t.child;case 6:return e===null&&Zu(t),null;case 13:return d0(e,t,n);case 4:return wp(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=po(t,null,r,n):it(e,t,r,n),t.child;case 11:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:qt(r,o),Sd(e,t,r,o,n);case 7:return it(e,t,t.pendingProps,n),t.child;case 8:return it(e,t,t.pendingProps.children,n),t.child;case 12:return it(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(r=t.type._context,o=t.pendingProps,i=t.memoizedProps,l=o.value,Ee(ea,r._currentValue),r._currentValue=l,i!==null)if(Jt(i.value,l)){if(i.children===o.children&&!ht.current){t=Tn(e,t,n);break e}}else for(i=t.child,i!==null&&(i.return=t);i!==null;){var a=i.dependencies;if(a!==null){l=i.child;for(var s=a.firstContext;s!==null;){if(s.context===r){if(i.tag===1){s=kn(-1,n&-n),s.tag=2;var u=i.updateQueue;if(u!==null){u=u.shared;var c=u.pending;c===null?s.next=s:(s.next=c.next,c.next=s),u.pending=s}}i.lanes|=n,s=i.alternate,s!==null&&(s.lanes|=n),Ju(i.return,n,t),a.lanes|=n;break}s=s.next}}else if(i.tag===10)l=i.type===t.type?null:i.child;else if(i.tag===18){if(l=i.return,l===null)throw Error(I(341));l.lanes|=n,a=l.alternate,a!==null&&(a.lanes|=n),Ju(l,n,t),l=i.sibling}else l=i.child;if(l!==null)l.return=i;else for(l=i;l!==null;){if(l===t){l=null;break}if(i=l.sibling,i!==null){i.return=l.return,l=i;break}l=l.return}i=l}it(e,t,o.children,n),t=t.child}return t;case 9:return o=t.type,r=t.pendingProps.children,oo(t,n),o=Nt(o),r=r(o),t.flags|=1,it(e,t,r,n),t.child;case 14:return r=t.type,o=qt(r,t.pendingProps),o=qt(r.type,o),Cd(e,t,r,o,n);case 15:return u0(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:qt(r,o),Tl(e,t),t.tag=1,mt(r)?(e=!0,Xl(t)):e=!1,oo(t,n),Fy(t,r,o),tc(t,r,o,n),oc(null,t,r,!0,e,n);case 19:return h0(e,t,n);case 22:return c0(e,t,n)}throw Error(I(156,t.tag))};function _0(e,t){return ny(e,t)}function Vb(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Lt(e,t,n,r){return new Vb(e,t,n,r)}function zp(e){return e=e.prototype,!(!e||!e.isReactComponent)}function Gb(e){if(typeof e=="function")return zp(e)?1:0;if(e!=null){if(e=e.$$typeof,e===Jc)return 11;if(e===ep)return 14}return 2}function er(e,t){var n=e.alternate;return n===null?(n=Lt(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&14680064,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n}function _l(e,t,n,r,o,i){var l=2;if(r=e,typeof e=="function")zp(e)&&(l=1);else if(typeof e=="string")l=5;else e:switch(e){case Ur:return Sr(n.children,o,i,t);case Zc:l=8,o|=8;break;case Eu:return e=Lt(12,n,t,o|2),e.elementType=Eu,e.lanes=i,e;case Pu:return e=Lt(13,n,t,o),e.elementType=Pu,e.lanes=i,e;case Tu:return e=Lt(19,n,t,o),e.elementType=Tu,e.lanes=i,e;case jg:return La(n,o,i,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case Ig:l=10;break e;case Fg:l=9;break e;case Jc:l=11;break e;case ep:l=14;break e;case Bn:l=16,r=null;break e}throw Error(I(130,e==null?e:typeof e,""))}return t=Lt(l,n,t,o),t.elementType=e,t.type=r,t.lanes=i,t}function Sr(e,t,n,r){return e=Lt(7,e,r,t),e.lanes=n,e}function La(e,t,n,r){return e=Lt(22,e,r,t),e.elementType=jg,e.lanes=n,e.stateNode={isHidden:!1},e}function Ys(e,t,n){return e=Lt(6,e,null,t),e.lanes=n,e}function Qs(e,t,n){return t=Lt(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function qb(e,t,n,r,o){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=As(0),this.expirationTimes=As(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=As(0),this.identifierPrefix=r,this.onRecoverableError=o,this.mutableSourceEagerHydrationData=null}function Dp(e,t,n,r,o,i,l,a,s){return e=new qb(e,t,n,a,s),t===1?(t=1,i===!0&&(t|=8)):t=0,i=Lt(3,null,null,t),e.current=i,i.stateNode=e,i.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},vp(i),e}function Yb(e,t,n){var r=3"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(z0)}catch(e){console.error(e)}}z0(),Rg.exports=Pt;var Fa=Rg.exports,Fd=Fa;Su.createRoot=Fd.createRoot,Su.hydrateRoot=Fd.hydrateRoot;const Jb='@import"https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap";*,:before,:after{box-sizing:border-box;border-width:0;border-style:solid;border-color:currentColor}:before,:after{--tw-content: ""}html{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji";font-feature-settings:normal;font-variation-settings:normal}body{margin:0;line-height:inherit}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}button,input,optgroup,select,textarea{font-family:inherit;font-feature-settings:inherit;font-variation-settings:inherit;font-size:100%;font-weight:inherit;line-height:inherit;color:inherit;margin:0;padding:0}button,select{text-transform:none}button,[type=button],[type=reset],[type=submit]{-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dl,dd,h1,h2,h3,h4,h5,h6,hr,figure,p,pre{margin:0}fieldset{margin:0;padding:0}legend{padding:0}ol,ul,menu{list-style:none;margin:0;padding:0}dialog{padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{opacity:1;color:#9ca3af}input::placeholder,textarea::placeholder{opacity:1;color:#9ca3af}button,[role=button]{cursor:pointer}:disabled{cursor:default}img,svg,video,canvas,audio,iframe,embed,object{display:block;vertical-align:middle}img,video{max-width:100%;height:auto}[hidden]{display:none}*{scrollbar-color:initial;scrollbar-width:initial}:root{--opencopilot-primary-clr: #703ea8;--opencopilot-accent-clr: #f8f7f8;--opencopilot-accnet-2-clr: #817f81;--opencopilot-primary-light-clr: rgba(0, 87, 255, .1)}*,:before,:after{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: }::backdrop{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: }.opencopilot-fixed{position:fixed}.opencopilot-absolute{position:absolute}.opencopilot-relative{position:relative}.opencopilot-inset-0{top:0;right:0;bottom:0;left:0}.opencopilot-bottom-0{bottom:0}.opencopilot-right-0{right:0}.opencopilot-top-0{top:0}.\\!opencopilot-z-\\[100000\\]{z-index:100000!important}.opencopilot-z-50{z-index:50}.opencopilot-z-\\[10000000\\]{z-index:10000000}.opencopilot-z-\\[100\\]{z-index:100}.opencopilot-z-\\[50000\\]{z-index:50000}.opencopilot-clear-both{clear:both}.opencopilot-m-0{margin:0}.opencopilot-mb-3{margin-bottom:.75rem}.opencopilot-mb-auto{margin-bottom:auto}.opencopilot-mt-auto{margin-top:auto}.opencopilot-block{display:block}.opencopilot-flex{display:flex}.opencopilot-grid{display:grid}.opencopilot-hidden{display:none}.opencopilot-aspect-square{aspect-ratio:1 / 1}.opencopilot-h-7{height:1.75rem}.opencopilot-h-fit{height:-moz-fit-content;height:fit-content}.opencopilot-h-full{height:100%}.opencopilot-h-screen{height:100vh}.opencopilot-max-h-\\[200px\\]{max-height:200px}.opencopilot-max-h-full{max-height:100%}.opencopilot-w-7{width:1.75rem}.opencopilot-w-fit{width:-moz-fit-content;width:fit-content}.opencopilot-w-full{width:100%}.opencopilot-w-screen{width:100vw}.opencopilot-min-w-fit{min-width:-moz-fit-content;min-width:fit-content}.opencopilot-max-w-\\[15rem\\]{max-width:15rem}.opencopilot-max-w-full{max-width:100%}.opencopilot-max-w-lg{max-width:32rem}.opencopilot-flex-1{flex:1 1 0%}.opencopilot-shrink-0{flex-shrink:0}.opencopilot-select-none{-webkit-user-select:none;-moz-user-select:none;user-select:none}.opencopilot-resize-none{resize:none}.opencopilot-flex-col{flex-direction:column}.opencopilot-flex-col-reverse{flex-direction:column-reverse}.opencopilot-flex-wrap{flex-wrap:wrap}.opencopilot-items-start{align-items:flex-start}.opencopilot-items-center{align-items:center}.opencopilot-justify-center{justify-content:center}.opencopilot-justify-between{justify-content:space-between}.opencopilot-gap-1{gap:.25rem}.opencopilot-gap-2{gap:.5rem}.opencopilot-gap-3{gap:.75rem}.opencopilot-gap-4{gap:1rem}.opencopilot-space-y-1>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.25rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.25rem * var(--tw-space-y-reverse))}.opencopilot-space-y-1\\.5>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.375rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.375rem * var(--tw-space-y-reverse))}.opencopilot-space-y-2>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.5rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.5rem * var(--tw-space-y-reverse))}.opencopilot-overflow-auto{overflow:auto}.opencopilot-overflow-hidden{overflow:hidden}.opencopilot-overflow-y-auto{overflow-y:auto}.opencopilot-scroll-smooth{scroll-behavior:smooth}.opencopilot-whitespace-nowrap{white-space:nowrap}.opencopilot-whitespace-pre-wrap{white-space:pre-wrap}.opencopilot-rounded-2xl{border-radius:1rem}.opencopilot-rounded-full{border-radius:9999px}.opencopilot-rounded-lg{border-radius:.5rem}.opencopilot-rounded-md{border-radius:.375rem}.opencopilot-rounded-sm{border-radius:.125rem}.opencopilot-rounded-t-lg{border-top-left-radius:.5rem;border-top-right-radius:.5rem}.opencopilot-border{border-width:1px}.opencopilot-border-b{border-bottom-width:1px}.opencopilot-border-none{border-style:none}.opencopilot-border-accent2{border-color:var(--opencopilot-accent-2-clr)}.opencopilot-border-primary-light{border-color:var(--opencopilot-primary-light-clr)}.opencopilot-border-rose-500{--tw-border-opacity: 1;border-color:rgb(244 63 94 / var(--tw-border-opacity))}.opencopilot-border-transparent{border-color:transparent}.opencopilot-border-b-black\\/10{border-bottom-color:#0000001a}.opencopilot-bg-accent{background-color:var(--opencopilot-accent-clr)}.opencopilot-bg-black\\/50{background-color:#00000080}.opencopilot-bg-primary{background-color:var(--opencopilot-primary-clr)}.opencopilot-bg-rose-500{--tw-bg-opacity: 1;background-color:rgb(244 63 94 / var(--tw-bg-opacity))}.opencopilot-bg-transparent{background-color:transparent}.opencopilot-bg-white{--tw-bg-opacity: 1;background-color:rgb(255 255 255 / var(--tw-bg-opacity))}.opencopilot-fill-current{fill:currentColor}.opencopilot-object-cover{-o-object-fit:cover;object-fit:cover}.opencopilot-p-0{padding:0}.opencopilot-p-0\\.5{padding:.125rem}.opencopilot-p-2{padding:.5rem}.opencopilot-p-3{padding:.75rem}.opencopilot-p-6{padding:1.5rem}.opencopilot-px-1{padding-left:.25rem;padding-right:.25rem}.opencopilot-px-2{padding-left:.5rem;padding-right:.5rem}.opencopilot-px-2\\.5{padding-left:.625rem;padding-right:.625rem}.opencopilot-px-4{padding-left:1rem;padding-right:1rem}.opencopilot-py-1{padding-top:.25rem;padding-bottom:.25rem}.opencopilot-py-1\\.5{padding-top:.375rem;padding-bottom:.375rem}.opencopilot-py-2{padding-top:.5rem;padding-bottom:.5rem}.opencopilot-ps-\\[52px\\]{padding-inline-start:52px}.opencopilot-text-center{text-align:center}.opencopilot-font-inter{font-family:Inter,sans-serif,system-ui}.opencopilot-text-2xl{font-size:1.5rem;line-height:2rem}.opencopilot-text-\\[14px\\]{font-size:14px}.opencopilot-text-lg{font-size:1.125rem;line-height:1.75rem}.opencopilot-text-sm{font-size:.875rem;line-height:1.25rem}.opencopilot-text-xl{font-size:1.25rem;line-height:1.75rem}.opencopilot-text-xs{font-size:.75rem;line-height:1rem}.opencopilot-font-medium{font-weight:500}.opencopilot-font-normal{font-weight:400}.opencopilot-font-semibold{font-weight:600}.opencopilot-lowercase{text-transform:lowercase}.opencopilot-leading-none{line-height:1}.opencopilot-leading-tight{line-height:1.25}.opencopilot-tracking-tight{letter-spacing:-.025em}.opencopilot-text-\\[\\#5e5c5e\\]{--tw-text-opacity: 1;color:rgb(94 92 94 / var(--tw-text-opacity))}.opencopilot-text-accent{color:var(--opencopilot-accent-clr)}.opencopilot-text-accent2{color:var(--opencopilot-accent-2-clr)}.opencopilot-text-black{--tw-text-opacity: 1;color:rgb(0 0 0 / var(--tw-text-opacity))}.opencopilot-text-primary{color:var(--opencopilot-primary-clr)}.opencopilot-text-rose-500{--tw-text-opacity: 1;color:rgb(244 63 94 / var(--tw-text-opacity))}.opencopilot-text-white{--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity))}.opencopilot-opacity-0{opacity:0}.opencopilot-opacity-100{opacity:1}.opencopilot-shadow{--tw-shadow: 0 1px 3px 0 rgb(0 0 0 / .1), 0 1px 2px -1px rgb(0 0 0 / .1);--tw-shadow-colored: 0 1px 3px 0 var(--tw-shadow-color), 0 1px 2px -1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.opencopilot-shadow-lg{--tw-shadow: 0 10px 15px -3px rgb(0 0 0 / .1), 0 4px 6px -4px rgb(0 0 0 / .1);--tw-shadow-colored: 0 10px 15px -3px var(--tw-shadow-color), 0 4px 6px -4px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.opencopilot-shadow-none{--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.opencopilot-outline-none{outline:2px solid transparent;outline-offset:2px}.opencopilot-backdrop-blur-sm{--tw-backdrop-blur: blur(4px);-webkit-backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia)}.opencopilot-transition-all{transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.opencopilot-transition-opacity{transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.opencopilot-transition-transform{transition-property:transform;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.opencopilot-duration-300{transition-duration:.3s}.opencopilot-ease-in{transition-timing-function:cubic-bezier(.4,0,1,1)}.opencopilot-ease-out{transition-timing-function:cubic-bezier(0,0,.2,1)}@keyframes enter{0%{opacity:var(--tw-enter-opacity, 1);transform:translate3d(var(--tw-enter-translate-x, 0),var(--tw-enter-translate-y, 0),0) scale3d(var(--tw-enter-scale, 1),var(--tw-enter-scale, 1),var(--tw-enter-scale, 1)) rotate(var(--tw-enter-rotate, 0))}}@keyframes exit{to{opacity:var(--tw-exit-opacity, 1);transform:translate3d(var(--tw-exit-translate-x, 0),var(--tw-exit-translate-y, 0),0) scale3d(var(--tw-exit-scale, 1),var(--tw-exit-scale, 1),var(--tw-exit-scale, 1)) rotate(var(--tw-exit-rotate, 0))}}.opencopilot-animate-in{animation-name:enter;animation-duration:.15s;--tw-enter-opacity: initial;--tw-enter-scale: initial;--tw-enter-rotate: initial;--tw-enter-translate-x: initial;--tw-enter-translate-y: initial}.opencopilot-animate-out{animation-name:exit;animation-duration:.15s;--tw-exit-opacity: initial;--tw-exit-scale: initial;--tw-exit-rotate: initial;--tw-exit-translate-x: initial;--tw-exit-translate-y: initial}.opencopilot-fade-in,.opencopilot-fade-in-0{--tw-enter-opacity: 0}.opencopilot-fade-out{--tw-exit-opacity: 0}.opencopilot-slide-in-from-bottom-5{--tw-enter-translate-y: 1.25rem}.opencopilot-slide-in-from-top-1{--tw-enter-translate-y: -.25rem}.opencopilot-duration-300{animation-duration:.3s}.opencopilot-ease-in{animation-timing-function:cubic-bezier(.4,0,1,1)}.opencopilot-ease-out{animation-timing-function:cubic-bezier(0,0,.2,1)}.opencopilot-scrollbar-thin{scrollbar-color:var(--scrollbar-thumb, initial) var(--scrollbar-track, initial)}.opencopilot-scrollbar-thin::-webkit-scrollbar-track{background-color:var(--scrollbar-track);border-radius:var(--scrollbar-track-radius)}.opencopilot-scrollbar-thin::-webkit-scrollbar-track:hover{background-color:var(--scrollbar-track-hover, var(--scrollbar-track))}.opencopilot-scrollbar-thin::-webkit-scrollbar-track:active{background-color:var(--scrollbar-track-active, var(--scrollbar-track-hover, var(--scrollbar-track)))}.opencopilot-scrollbar-thin::-webkit-scrollbar-thumb{background-color:var(--scrollbar-thumb);border-radius:var(--scrollbar-thumb-radius)}.opencopilot-scrollbar-thin::-webkit-scrollbar-thumb:hover{background-color:var(--scrollbar-thumb-hover, var(--scrollbar-thumb))}.opencopilot-scrollbar-thin::-webkit-scrollbar-thumb:active{background-color:var(--scrollbar-thumb-active, var(--scrollbar-thumb-hover, var(--scrollbar-thumb)))}.opencopilot-scrollbar-thin::-webkit-scrollbar-corner{background-color:var(--scrollbar-corner);border-radius:var(--scrollbar-corner-radius)}.opencopilot-scrollbar-thin::-webkit-scrollbar-corner:hover{background-color:var(--scrollbar-corner-hover, var(--scrollbar-corner))}.opencopilot-scrollbar-thin::-webkit-scrollbar-corner:active{background-color:var(--scrollbar-corner-active, var(--scrollbar-corner-hover, var(--scrollbar-corner)))}.opencopilot-scrollbar-thin{scrollbar-width:thin}.opencopilot-scrollbar-thin::-webkit-scrollbar{display:block;width:8px;height:8px}.opencopilot-prose{color:var(--tw-prose-body);max-width:65ch}.opencopilot-prose :where(p):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:1.25em;margin-bottom:1.25em}.opencopilot-prose :where([class~=lead]):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){color:var(--tw-prose-lead);font-size:1.25em;line-height:1.6;margin-top:1.2em;margin-bottom:1.2em}.opencopilot-prose :where(a):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){color:var(--tw-prose-links);text-decoration:underline;font-weight:500}.opencopilot-prose :where(strong):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){color:var(--tw-prose-bold);font-weight:600}.opencopilot-prose :where(a strong):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){color:inherit}.opencopilot-prose :where(blockquote strong):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){color:inherit}.opencopilot-prose :where(thead th strong):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){color:inherit}.opencopilot-prose :where(ol):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){list-style-type:decimal;margin-top:1.25em;margin-bottom:1.25em;padding-left:1.625em}.opencopilot-prose :where(ol[type=A]):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){list-style-type:upper-alpha}.opencopilot-prose :where(ol[type=a]):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){list-style-type:lower-alpha}.opencopilot-prose :where(ol[type=A s]):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){list-style-type:upper-alpha}.opencopilot-prose :where(ol[type=a s]):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){list-style-type:lower-alpha}.opencopilot-prose :where(ol[type=I]):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){list-style-type:upper-roman}.opencopilot-prose :where(ol[type=i]):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){list-style-type:lower-roman}.opencopilot-prose :where(ol[type=I s]):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){list-style-type:upper-roman}.opencopilot-prose :where(ol[type=i s]):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){list-style-type:lower-roman}.opencopilot-prose :where(ol[type="1"]):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){list-style-type:decimal}.opencopilot-prose :where(ul):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){list-style-type:disc;margin-top:1.25em;margin-bottom:1.25em;padding-left:1.625em}.opencopilot-prose :where(ol>li):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *))::marker{font-weight:400;color:var(--tw-prose-counters)}.opencopilot-prose :where(ul>li):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *))::marker{color:var(--tw-prose-bullets)}.opencopilot-prose :where(dt):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){color:var(--tw-prose-headings);font-weight:600;margin-top:1.25em}.opencopilot-prose :where(hr):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){border-color:var(--tw-prose-hr);border-top-width:1px;margin-top:3em;margin-bottom:3em}.opencopilot-prose :where(blockquote):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){font-weight:500;font-style:italic;color:var(--tw-prose-quotes);border-left-width:.25rem;border-left-color:var(--tw-prose-quote-borders);quotes:"“""”""‘""’";margin-top:1.6em;margin-bottom:1.6em;padding-left:1em}.opencopilot-prose :where(blockquote p:first-of-type):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)):before{content:open-quote}.opencopilot-prose :where(blockquote p:last-of-type):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)):after{content:close-quote}.opencopilot-prose :where(h1):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){color:var(--tw-prose-headings);font-weight:800;font-size:2.25em;margin-top:0;margin-bottom:.8888889em;line-height:1.1111111}.opencopilot-prose :where(h1 strong):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){font-weight:900;color:inherit}.opencopilot-prose :where(h2):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){color:var(--tw-prose-headings);font-weight:700;font-size:1.5em;margin-top:2em;margin-bottom:1em;line-height:1.3333333}.opencopilot-prose :where(h2 strong):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){font-weight:800;color:inherit}.opencopilot-prose :where(h3):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){color:var(--tw-prose-headings);font-weight:600;font-size:1.25em;margin-top:1.6em;margin-bottom:.6em;line-height:1.6}.opencopilot-prose :where(h3 strong):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){font-weight:700;color:inherit}.opencopilot-prose :where(h4):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){color:var(--tw-prose-headings);font-weight:600;margin-top:1.5em;margin-bottom:.5em;line-height:1.5}.opencopilot-prose :where(h4 strong):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){font-weight:700;color:inherit}.opencopilot-prose :where(img):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:2em;margin-bottom:2em}.opencopilot-prose :where(picture):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){display:block;margin-top:2em;margin-bottom:2em}.opencopilot-prose :where(kbd):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){font-weight:500;font-family:inherit;color:var(--tw-prose-kbd);box-shadow:0 0 0 1px rgb(var(--tw-prose-kbd-shadows) / 10%),0 3px 0 rgb(var(--tw-prose-kbd-shadows) / 10%);font-size:.875em;border-radius:.3125rem;padding:.1875em .375em}.opencopilot-prose :where(code):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){color:var(--tw-prose-code);font-weight:600;font-size:.875em}.opencopilot-prose :where(code):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)):before{content:"`"}.opencopilot-prose :where(code):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)):after{content:"`"}.opencopilot-prose :where(a code):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){color:inherit}.opencopilot-prose :where(h1 code):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){color:inherit}.opencopilot-prose :where(h2 code):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){color:inherit;font-size:.875em}.opencopilot-prose :where(h3 code):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){color:inherit;font-size:.9em}.opencopilot-prose :where(h4 code):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){color:inherit}.opencopilot-prose :where(blockquote code):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){color:inherit}.opencopilot-prose :where(thead th code):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){color:inherit}.opencopilot-prose :where(pre):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){color:var(--tw-prose-pre-code);background-color:var(--tw-prose-pre-bg);overflow-x:auto;font-weight:400;font-size:.875em;line-height:1.7142857;margin-top:1.7142857em;margin-bottom:1.7142857em;border-radius:.375rem;padding:.8571429em 1.1428571em}.opencopilot-prose :where(pre code):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){background-color:transparent;border-width:0;border-radius:0;padding:0;font-weight:inherit;color:inherit;font-size:inherit;font-family:inherit;line-height:inherit}.opencopilot-prose :where(pre code):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)):before{content:none}.opencopilot-prose :where(pre code):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)):after{content:none}.opencopilot-prose :where(table):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){width:100%;table-layout:auto;text-align:left;margin-top:2em;margin-bottom:2em;font-size:.875em;line-height:1.7142857}.opencopilot-prose :where(thead):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){border-bottom-width:1px;border-bottom-color:var(--tw-prose-th-borders)}.opencopilot-prose :where(thead th):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){color:var(--tw-prose-headings);font-weight:600;vertical-align:bottom;padding-right:.5714286em;padding-bottom:.5714286em;padding-left:.5714286em}.opencopilot-prose :where(tbody tr):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){border-bottom-width:1px;border-bottom-color:var(--tw-prose-td-borders)}.opencopilot-prose :where(tbody tr:last-child):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){border-bottom-width:0}.opencopilot-prose :where(tbody td):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){vertical-align:baseline}.opencopilot-prose :where(tfoot):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){border-top-width:1px;border-top-color:var(--tw-prose-th-borders)}.opencopilot-prose :where(tfoot td):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){vertical-align:top}.opencopilot-prose :where(figure>*):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:0;margin-bottom:0}.opencopilot-prose :where(figcaption):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){color:var(--tw-prose-captions);font-size:.875em;line-height:1.4285714;margin-top:.8571429em}.opencopilot-prose{--tw-prose-body: #374151;--tw-prose-headings: #111827;--tw-prose-lead: #4b5563;--tw-prose-links: #111827;--tw-prose-bold: #111827;--tw-prose-counters: #6b7280;--tw-prose-bullets: #d1d5db;--tw-prose-hr: #e5e7eb;--tw-prose-quotes: #111827;--tw-prose-quote-borders: #e5e7eb;--tw-prose-captions: #6b7280;--tw-prose-kbd: #111827;--tw-prose-kbd-shadows: 17 24 39;--tw-prose-code: #111827;--tw-prose-pre-code: #e5e7eb;--tw-prose-pre-bg: #1f2937;--tw-prose-th-borders: #d1d5db;--tw-prose-td-borders: #e5e7eb;--tw-prose-invert-body: #d1d5db;--tw-prose-invert-headings: #fff;--tw-prose-invert-lead: #9ca3af;--tw-prose-invert-links: #fff;--tw-prose-invert-bold: #fff;--tw-prose-invert-counters: #9ca3af;--tw-prose-invert-bullets: #4b5563;--tw-prose-invert-hr: #374151;--tw-prose-invert-quotes: #f3f4f6;--tw-prose-invert-quote-borders: #374151;--tw-prose-invert-captions: #9ca3af;--tw-prose-invert-kbd: #fff;--tw-prose-invert-kbd-shadows: 255 255 255;--tw-prose-invert-code: #fff;--tw-prose-invert-pre-code: #d1d5db;--tw-prose-invert-pre-bg: rgb(0 0 0 / 50%);--tw-prose-invert-th-borders: #4b5563;--tw-prose-invert-td-borders: #374151;font-size:1rem;line-height:1.75}.opencopilot-prose :where(picture>img):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:0;margin-bottom:0}.opencopilot-prose :where(video):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:2em;margin-bottom:2em}.opencopilot-prose :where(li):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:.5em;margin-bottom:.5em}.opencopilot-prose :where(ol>li):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){padding-left:.375em}.opencopilot-prose :where(ul>li):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){padding-left:.375em}.opencopilot-prose :where(.opencopilot-prose>ul>li p):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:.75em;margin-bottom:.75em}.opencopilot-prose :where(.opencopilot-prose>ul>li>*:first-child):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:1.25em}.opencopilot-prose :where(.opencopilot-prose>ul>li>*:last-child):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-bottom:1.25em}.opencopilot-prose :where(.opencopilot-prose>ol>li>*:first-child):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:1.25em}.opencopilot-prose :where(.opencopilot-prose>ol>li>*:last-child):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-bottom:1.25em}.opencopilot-prose :where(ul ul,ul ol,ol ul,ol ol):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:.75em;margin-bottom:.75em}.opencopilot-prose :where(dl):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:1.25em;margin-bottom:1.25em}.opencopilot-prose :where(dd):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:.5em;padding-left:1.625em}.opencopilot-prose :where(hr+*):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:0}.opencopilot-prose :where(h2+*):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:0}.opencopilot-prose :where(h3+*):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:0}.opencopilot-prose :where(h4+*):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:0}.opencopilot-prose :where(thead th:first-child):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){padding-left:0}.opencopilot-prose :where(thead th:last-child):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){padding-right:0}.opencopilot-prose :where(tbody td,tfoot td):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){padding:.5714286em}.opencopilot-prose :where(tbody td:first-child,tfoot td:first-child):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){padding-left:0}.opencopilot-prose :where(tbody td:last-child,tfoot td:last-child):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){padding-right:0}.opencopilot-prose :where(figure):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:2em;margin-bottom:2em}.opencopilot-prose :where(.opencopilot-prose>:first-child):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:0}.opencopilot-prose :where(.opencopilot-prose>:last-child):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-bottom:0}.opencopilot-prose-sm{font-size:.875rem;line-height:1.7142857}.opencopilot-prose-sm :where(p):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:1.1428571em;margin-bottom:1.1428571em}.opencopilot-prose-sm :where([class~=lead]):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){font-size:1.2857143em;line-height:1.5555556;margin-top:.8888889em;margin-bottom:.8888889em}.opencopilot-prose-sm :where(blockquote):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:1.3333333em;margin-bottom:1.3333333em;padding-left:1.1111111em}.opencopilot-prose-sm :where(h1):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){font-size:2.1428571em;margin-top:0;margin-bottom:.8em;line-height:1.2}.opencopilot-prose-sm :where(h2):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){font-size:1.4285714em;margin-top:1.6em;margin-bottom:.8em;line-height:1.4}.opencopilot-prose-sm :where(h3):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){font-size:1.2857143em;margin-top:1.5555556em;margin-bottom:.4444444em;line-height:1.5555556}.opencopilot-prose-sm :where(h4):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:1.4285714em;margin-bottom:.5714286em;line-height:1.4285714}.opencopilot-prose-sm :where(img):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:1.7142857em;margin-bottom:1.7142857em}.opencopilot-prose-sm :where(picture):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:1.7142857em;margin-bottom:1.7142857em}.opencopilot-prose-sm :where(picture>img):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:0;margin-bottom:0}.opencopilot-prose-sm :where(video):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:1.7142857em;margin-bottom:1.7142857em}.opencopilot-prose-sm :where(kbd):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){font-size:.8571429em;border-radius:.3125rem;padding:.1428571em .3571429em}.opencopilot-prose-sm :where(code):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){font-size:.8571429em}.opencopilot-prose-sm :where(h2 code):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){font-size:.9em}.opencopilot-prose-sm :where(h3 code):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){font-size:.8888889em}.opencopilot-prose-sm :where(pre):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){font-size:.8571429em;line-height:1.6666667;margin-top:1.6666667em;margin-bottom:1.6666667em;border-radius:.25rem;padding:.6666667em 1em}.opencopilot-prose-sm :where(ol):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:1.1428571em;margin-bottom:1.1428571em;padding-left:1.5714286em}.opencopilot-prose-sm :where(ul):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:1.1428571em;margin-bottom:1.1428571em;padding-left:1.5714286em}.opencopilot-prose-sm :where(li):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:.2857143em;margin-bottom:.2857143em}.opencopilot-prose-sm :where(ol>li):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){padding-left:.4285714em}.opencopilot-prose-sm :where(ul>li):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){padding-left:.4285714em}.opencopilot-prose-sm :where(.opencopilot-prose-sm>ul>li p):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:.5714286em;margin-bottom:.5714286em}.opencopilot-prose-sm :where(.opencopilot-prose-sm>ul>li>*:first-child):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:1.1428571em}.opencopilot-prose-sm :where(.opencopilot-prose-sm>ul>li>*:last-child):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-bottom:1.1428571em}.opencopilot-prose-sm :where(.opencopilot-prose-sm>ol>li>*:first-child):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:1.1428571em}.opencopilot-prose-sm :where(.opencopilot-prose-sm>ol>li>*:last-child):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-bottom:1.1428571em}.opencopilot-prose-sm :where(ul ul,ul ol,ol ul,ol ol):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:.5714286em;margin-bottom:.5714286em}.opencopilot-prose-sm :where(dl):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:1.1428571em;margin-bottom:1.1428571em}.opencopilot-prose-sm :where(dt):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:1.1428571em}.opencopilot-prose-sm :where(dd):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:.2857143em;padding-left:1.5714286em}.opencopilot-prose-sm :where(hr):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:2.8571429em;margin-bottom:2.8571429em}.opencopilot-prose-sm :where(hr+*):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:0}.opencopilot-prose-sm :where(h2+*):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:0}.opencopilot-prose-sm :where(h3+*):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:0}.opencopilot-prose-sm :where(h4+*):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:0}.opencopilot-prose-sm :where(table):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){font-size:.8571429em;line-height:1.5}.opencopilot-prose-sm :where(thead th):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){padding-right:1em;padding-bottom:.6666667em;padding-left:1em}.opencopilot-prose-sm :where(thead th:first-child):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){padding-left:0}.opencopilot-prose-sm :where(thead th:last-child):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){padding-right:0}.opencopilot-prose-sm :where(tbody td,tfoot td):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){padding:.6666667em 1em}.opencopilot-prose-sm :where(tbody td:first-child,tfoot td:first-child):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){padding-left:0}.opencopilot-prose-sm :where(tbody td:last-child,tfoot td:last-child):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){padding-right:0}.opencopilot-prose-sm :where(figure):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:1.7142857em;margin-bottom:1.7142857em}.opencopilot-prose-sm :where(figure>*):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:0;margin-bottom:0}.opencopilot-prose-sm :where(figcaption):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){font-size:.8571429em;line-height:1.3333333;margin-top:.6666667em}.opencopilot-prose-sm :where(.opencopilot-prose-sm>:first-child):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-top:0}.opencopilot-prose-sm :where(.opencopilot-prose-sm>:last-child):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *)){margin-bottom:0}.opencopilot-prose-slate{--tw-prose-body: #334155;--tw-prose-headings: #0f172a;--tw-prose-lead: #475569;--tw-prose-links: #0f172a;--tw-prose-bold: #0f172a;--tw-prose-counters: #64748b;--tw-prose-bullets: #cbd5e1;--tw-prose-hr: #e2e8f0;--tw-prose-quotes: #0f172a;--tw-prose-quote-borders: #e2e8f0;--tw-prose-captions: #64748b;--tw-prose-kbd: #0f172a;--tw-prose-kbd-shadows: 15 23 42;--tw-prose-code: #0f172a;--tw-prose-pre-code: #e2e8f0;--tw-prose-pre-bg: #1e293b;--tw-prose-th-borders: #cbd5e1;--tw-prose-td-borders: #e2e8f0;--tw-prose-invert-body: #cbd5e1;--tw-prose-invert-headings: #fff;--tw-prose-invert-lead: #94a3b8;--tw-prose-invert-links: #fff;--tw-prose-invert-bold: #fff;--tw-prose-invert-counters: #94a3b8;--tw-prose-invert-bullets: #475569;--tw-prose-invert-hr: #334155;--tw-prose-invert-quotes: #f1f5f9;--tw-prose-invert-quote-borders: #334155;--tw-prose-invert-captions: #94a3b8;--tw-prose-invert-kbd: #fff;--tw-prose-invert-kbd-shadows: 255 255 255;--tw-prose-invert-code: #fff;--tw-prose-invert-pre-code: #cbd5e1;--tw-prose-invert-pre-bg: rgb(0 0 0 / 50%);--tw-prose-invert-th-borders: #475569;--tw-prose-invert-td-borders: #334155}@keyframes fade-in-bottom{0%{transform:translateY(50px);opacity:0}to{transform:translateY(0);opacity:1}}.fade-in-bottom{animation:fade-in-bottom .4s cubic-bezier(.39,.575,.565,1) both}.flex-center{display:flex;align-items:center;justify-content:center}@keyframes fade-in-top{0%{transform:translateY(-50px);opacity:0}to{transform:translateY(0);opacity:1}}.fade-in-top{animation:fade-in-top .6s cubic-bezier(.39,.575,.565,1) both}@keyframes fade-in{0%{opacity:0}to{opacity:1}}.fade-in{animation:fade-in 1.2s cubic-bezier(.39,.575,.565,1) both}em-emoji-picker{--background-rgb: 85, 170, 255;--border-radius: 10px;--category-icon-size: 24px;--font-family: inherit;--font-size: 14px;min-height:250px;max-height:300px}.PopoverContent{transform-origin:var(--radix-popover-content-transform-origin);animation:scaleIn .5s ease-out}@keyframes scaleIn{0%{opacity:0;transform:scale(0)}to{opacity:1;transform:scale(1)}}.PopoverContent{animation-duration:.6s;animation-timing-function:cubic-bezier(.16,1,.3,1)}.PopoverContent[data-side=top]{animation-name:slideUp}.PopoverContent[data-side=bottom]{animation-name:slideDown}@keyframes slideDown{0%{opacity:0;transform:translateY(-10px)}to{opacity:1;transform:translateY(0)}}@keyframes slideUp{0%{opacity:0;transform:translateY(10px)}to{opacity:1;transform:translateY(0)}}@keyframes fade-in-right{0%{transform:translate(50px);opacity:0}to{transform:translate(0);opacity:1}}.fade-in-right{animation:fade-in-right .6s both}@keyframes scale-out-br{0%{transform:scale(1);transform-origin:100% 100%;opacity:1}to{transform:scale(0);transform-origin:100% 100%;opacity:1}}.scale-out-br{animation:scale-out-br .5s ease-in-out forwards}.placeholder\\:opencopilot-align-middle::-moz-placeholder{vertical-align:middle}.placeholder\\:opencopilot-align-middle::placeholder{vertical-align:middle}.placeholder\\:opencopilot-text-xs::-moz-placeholder{font-size:.75rem;line-height:1rem}.placeholder\\:opencopilot-text-xs::placeholder{font-size:.75rem;line-height:1rem}.last-of-type\\:opencopilot-mb-10:last-of-type{margin-bottom:2.5rem}.focus-within\\:opencopilot-ring-1:focus-within{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.focus-within\\:opencopilot-ring-primary:focus-within{--tw-ring-color: var(--opencopilot-primary-clr)}.opencopilot-group:last-of-type .group-last-of-type\\:opencopilot-inline{display:inline}.data-\\[state\\=open\\]\\:opencopilot-animate-in[data-state=open]{animation-name:enter;animation-duration:.15s;--tw-enter-opacity: initial;--tw-enter-scale: initial;--tw-enter-rotate: initial;--tw-enter-translate-x: initial;--tw-enter-translate-y: initial}.data-\\[state\\=closed\\]\\:opencopilot-animate-out[data-state=closed]{animation-name:exit;animation-duration:.15s;--tw-exit-opacity: initial;--tw-exit-scale: initial;--tw-exit-rotate: initial;--tw-exit-translate-x: initial;--tw-exit-translate-y: initial}.data-\\[state\\=closed\\]\\:opencopilot-fade-out-0[data-state=closed]{--tw-exit-opacity: 0}.data-\\[state\\=open\\]\\:opencopilot-fade-in-0[data-state=open]{--tw-enter-opacity: 0}.data-\\[state\\=closed\\]\\:opencopilot-slide-in-from-top-0[data-state=closed]{--tw-enter-translate-y: -0px}.data-\\[state\\=open\\]\\:opencopilot-slide-in-from-bottom[data-state=open]{--tw-enter-translate-y: 100%}.prose-headings\\:opencopilot-my-1 :is(:where(h1,h2,h3,h4,h5,h6,th):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *))){margin-top:.25rem;margin-bottom:.25rem}.prose-h1\\:opencopilot-font-medium :is(:where(h1):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *))){font-weight:500}.prose-h2\\:opencopilot-font-normal :is(:where(h2):not(:where([class~=opencopilot-not-prose],[class~=opencopilot-not-prose] *))){font-weight:400}.hover\\:opencopilot-scale-110:hover{--tw-scale-x: 1.1;--tw-scale-y: 1.1;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.hover\\:opencopilot-shadow:hover{--tw-shadow: 0 1px 3px 0 rgb(0 0 0 / .1), 0 1px 2px -1px rgb(0 0 0 / .1);--tw-shadow-colored: 0 1px 3px 0 var(--tw-shadow-color), 0 1px 2px -1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.focus\\:opencopilot-border-none:focus{border-style:none}.focus\\:opencopilot-outline-none:focus{outline:2px solid transparent;outline-offset:2px}.focus-visible\\:opencopilot-outline-none:focus-visible{outline:2px solid transparent;outline-offset:2px}.disabled\\:opencopilot-pointer-events-none:disabled{pointer-events:none}.disabled\\:opencopilot-cursor-not-allowed:disabled{cursor:not-allowed}.disabled\\:opencopilot-opacity-40:disabled{opacity:.4}@media (min-width: 640px){.sm\\:opencopilot-w-96{width:24rem}.sm\\:opencopilot-flex-row{flex-direction:row}.sm\\:opencopilot-justify-end{justify-content:flex-end}.sm\\:opencopilot-space-x-2>:not([hidden])~:not([hidden]){--tw-space-x-reverse: 0;margin-right:calc(.5rem * var(--tw-space-x-reverse));margin-left:calc(.5rem * calc(1 - var(--tw-space-x-reverse)))}.sm\\:opencopilot-rounded-xl{border-radius:.75rem}.sm\\:opencopilot-text-left{text-align:left}}\n',D0=b.createContext(void 0);function ek({children:e,data:t}){return L.jsx(D0.Provider,{value:t,children:e})}function jp(){const e=b.useContext(D0);if(!e)throw new Error("useConfigData must be used within a ConfigDataProvider");return e}function tk(e){const[t,n]=b.useState(!!e),r=b.useCallback(()=>n(o=>!o),[]);return[t,r,n]}const N0=b.createContext(void 0);function I0(){const e=b.useContext(N0);if(!e)throw new Error("useAppContext must be used within an AppProvider");return e}function nk({children:e}){const t=tk(!1);return L.jsx(N0.Provider,{value:t,children:e})}function F0(e,t){return function(){return e.apply(t,arguments)}}const{toString:rk}=Object.prototype,{getPrototypeOf:Mp}=Object,ja=(e=>t=>{const n=rk.call(t);return e[n]||(e[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),cn=e=>(e=e.toLowerCase(),t=>ja(t)===e),Ma=e=>t=>typeof t===e,{isArray:Co}=Array,Ci=Ma("undefined");function ok(e){return e!==null&&!Ci(e)&&e.constructor!==null&&!Ci(e.constructor)&&Dt(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const j0=cn("ArrayBuffer");function ik(e){let t;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&j0(e.buffer),t}const lk=Ma("string"),Dt=Ma("function"),M0=Ma("number"),Ba=e=>e!==null&&typeof e=="object",ak=e=>e===!0||e===!1,$l=e=>{if(ja(e)!=="object")return!1;const t=Mp(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)},sk=cn("Date"),uk=cn("File"),ck=cn("Blob"),pk=cn("FileList"),fk=e=>Ba(e)&&Dt(e.pipe),dk=e=>{let t;return e&&(typeof FormData=="function"&&e instanceof FormData||Dt(e.append)&&((t=ja(e))==="formdata"||t==="object"&&Dt(e.toString)&&e.toString()==="[object FormData]"))},hk=cn("URLSearchParams"),mk=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Di(e,t,{allOwnKeys:n=!1}={}){if(e===null||typeof e>"u")return;let r,o;if(typeof e!="object"&&(e=[e]),Co(e))for(r=0,o=e.length;r0;)if(o=n[r],t===o.toLowerCase())return o;return null}const U0=(()=>typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global)(),H0=e=>!Ci(e)&&e!==U0;function gc(){const{caseless:e}=H0(this)&&this||{},t={},n=(r,o)=>{const i=e&&B0(t,o)||o;$l(t[i])&&$l(r)?t[i]=gc(t[i],r):$l(r)?t[i]=gc({},r):Co(r)?t[i]=r.slice():t[i]=r};for(let r=0,o=arguments.length;r(Di(t,(o,i)=>{n&&Dt(o)?e[i]=F0(o,n):e[i]=o},{allOwnKeys:r}),e),yk=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),vk=(e,t,n,r)=>{e.prototype=Object.create(t.prototype,r),e.prototype.constructor=e,Object.defineProperty(e,"super",{value:t.prototype}),n&&Object.assign(e.prototype,n)},wk=(e,t,n,r)=>{let o,i,l;const a={};if(t=t||{},e==null)return t;do{for(o=Object.getOwnPropertyNames(e),i=o.length;i-- >0;)l=o[i],(!r||r(l,e,t))&&!a[l]&&(t[l]=e[l],a[l]=!0);e=n!==!1&&Mp(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},xk=(e,t,n)=>{e=String(e),(n===void 0||n>e.length)&&(n=e.length),n-=t.length;const r=e.indexOf(t,n);return r!==-1&&r===n},bk=e=>{if(!e)return null;if(Co(e))return e;let t=e.length;if(!M0(t))return null;const n=new Array(t);for(;t-- >0;)n[t]=e[t];return n},kk=(e=>t=>e&&t instanceof e)(typeof Uint8Array<"u"&&Mp(Uint8Array)),Sk=(e,t)=>{const r=(e&&e[Symbol.iterator]).call(e);let o;for(;(o=r.next())&&!o.done;){const i=o.value;t.call(e,i[0],i[1])}},Ck=(e,t)=>{let n;const r=[];for(;(n=e.exec(t))!==null;)r.push(n);return r},Ek=cn("HTMLFormElement"),Pk=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,r,o){return r.toUpperCase()+o}),jd=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),Tk=cn("RegExp"),W0=(e,t)=>{const n=Object.getOwnPropertyDescriptors(e),r={};Di(n,(o,i)=>{let l;(l=t(o,i,e))!==!1&&(r[i]=l||o)}),Object.defineProperties(e,r)},Ok=e=>{W0(e,(t,n)=>{if(Dt(e)&&["arguments","caller","callee"].indexOf(n)!==-1)return!1;const r=e[n];if(Dt(r)){if(t.enumerable=!1,"writable"in t){t.writable=!1;return}t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+n+"'")})}})},Ak=(e,t)=>{const n={},r=o=>{o.forEach(i=>{n[i]=!0})};return Co(e)?r(e):r(String(e).split(t)),n},_k=()=>{},$k=(e,t)=>(e=+e,Number.isFinite(e)?e:t),Ks="abcdefghijklmnopqrstuvwxyz",Md="0123456789",V0={DIGIT:Md,ALPHA:Ks,ALPHA_DIGIT:Ks+Ks.toUpperCase()+Md},Rk=(e=16,t=V0.ALPHA_DIGIT)=>{let n="";const{length:r}=t;for(;e--;)n+=t[Math.random()*r|0];return n};function Lk(e){return!!(e&&Dt(e.append)&&e[Symbol.toStringTag]==="FormData"&&e[Symbol.iterator])}const zk=e=>{const t=new Array(10),n=(r,o)=>{if(Ba(r)){if(t.indexOf(r)>=0)return;if(!("toJSON"in r)){t[o]=r;const i=Co(r)?[]:{};return Di(r,(l,a)=>{const s=n(l,o+1);!Ci(s)&&(i[a]=s)}),t[o]=void 0,i}}return r};return n(e,0)},Dk=cn("AsyncFunction"),Nk=e=>e&&(Ba(e)||Dt(e))&&Dt(e.then)&&Dt(e.catch),R={isArray:Co,isArrayBuffer:j0,isBuffer:ok,isFormData:dk,isArrayBufferView:ik,isString:lk,isNumber:M0,isBoolean:ak,isObject:Ba,isPlainObject:$l,isUndefined:Ci,isDate:sk,isFile:uk,isBlob:ck,isRegExp:Tk,isFunction:Dt,isStream:fk,isURLSearchParams:hk,isTypedArray:kk,isFileList:pk,forEach:Di,merge:gc,extend:gk,trim:mk,stripBOM:yk,inherits:vk,toFlatObject:wk,kindOf:ja,kindOfTest:cn,endsWith:xk,toArray:bk,forEachEntry:Sk,matchAll:Ck,isHTMLForm:Ek,hasOwnProperty:jd,hasOwnProp:jd,reduceDescriptors:W0,freezeMethods:Ok,toObjectSet:Ak,toCamelCase:Pk,noop:_k,toFiniteNumber:$k,findKey:B0,global:U0,isContextDefined:H0,ALPHABET:V0,generateString:Rk,isSpecCompliantForm:Lk,toJSONObject:zk,isAsyncFn:Dk,isThenable:Nk};function he(e,t,n,r,o){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=e,this.name="AxiosError",t&&(this.code=t),n&&(this.config=n),r&&(this.request=r),o&&(this.response=o)}R.inherits(he,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:R.toJSONObject(this.config),code:this.code,status:this.response&&this.response.status?this.response.status:null}}});const G0=he.prototype,q0={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(e=>{q0[e]={value:e}});Object.defineProperties(he,q0);Object.defineProperty(G0,"isAxiosError",{value:!0});he.from=(e,t,n,r,o,i)=>{const l=Object.create(G0);return R.toFlatObject(e,l,function(s){return s!==Error.prototype},a=>a!=="isAxiosError"),he.call(l,e.message,t,n,r,o),l.cause=e,l.name=e.name,i&&Object.assign(l,i),l};const Ik=null;function yc(e){return R.isPlainObject(e)||R.isArray(e)}function Y0(e){return R.endsWith(e,"[]")?e.slice(0,-2):e}function Bd(e,t,n){return e?e.concat(t).map(function(o,i){return o=Y0(o),!n&&i?"["+o+"]":o}).join(n?".":""):t}function Fk(e){return R.isArray(e)&&!e.some(yc)}const jk=R.toFlatObject(R,{},null,function(t){return/^is[A-Z]/.test(t)});function Ua(e,t,n){if(!R.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,n=R.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(m,w){return!R.isUndefined(w[m])});const r=n.metaTokens,o=n.visitor||c,i=n.dots,l=n.indexes,s=(n.Blob||typeof Blob<"u"&&Blob)&&R.isSpecCompliantForm(t);if(!R.isFunction(o))throw new TypeError("visitor must be a function");function u(h){if(h===null)return"";if(R.isDate(h))return h.toISOString();if(!s&&R.isBlob(h))throw new he("Blob is not supported. Use a Buffer instead.");return R.isArrayBuffer(h)||R.isTypedArray(h)?s&&typeof Blob=="function"?new Blob([h]):Buffer.from(h):h}function c(h,m,w){let g=h;if(h&&!w&&typeof h=="object"){if(R.endsWith(m,"{}"))m=r?m:m.slice(0,-2),h=JSON.stringify(h);else if(R.isArray(h)&&Fk(h)||(R.isFileList(h)||R.endsWith(m,"[]"))&&(g=R.toArray(h)))return m=Y0(m),g.forEach(function(v,C){!(R.isUndefined(v)||v===null)&&t.append(l===!0?Bd([m],C,i):l===null?m:m+"[]",u(v))}),!1}return yc(h)?!0:(t.append(Bd(w,m,i),u(h)),!1)}const p=[],d=Object.assign(jk,{defaultVisitor:c,convertValue:u,isVisitable:yc});function f(h,m){if(!R.isUndefined(h)){if(p.indexOf(h)!==-1)throw Error("Circular reference detected in "+m.join("."));p.push(h),R.forEach(h,function(g,y){(!(R.isUndefined(g)||g===null)&&o.call(t,g,R.isString(y)?y.trim():y,m,d))===!0&&f(g,m?m.concat(y):[y])}),p.pop()}}if(!R.isObject(e))throw new TypeError("data must be an object");return f(e),t}function Ud(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(r){return t[r]})}function Bp(e,t){this._pairs=[],e&&Ua(e,this,t)}const Q0=Bp.prototype;Q0.append=function(t,n){this._pairs.push([t,n])};Q0.toString=function(t){const n=t?function(r){return t.call(this,r,Ud)}:Ud;return this._pairs.map(function(o){return n(o[0])+"="+n(o[1])},"").join("&")};function Mk(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function K0(e,t,n){if(!t)return e;const r=n&&n.encode||Mk,o=n&&n.serialize;let i;if(o?i=o(t,n):i=R.isURLSearchParams(t)?t.toString():new Bp(t,n).toString(r),i){const l=e.indexOf("#");l!==-1&&(e=e.slice(0,l)),e+=(e.indexOf("?")===-1?"?":"&")+i}return e}class Bk{constructor(){this.handlers=[]}use(t,n,r){return this.handlers.push({fulfilled:t,rejected:n,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(t){this.handlers[t]&&(this.handlers[t]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(t){R.forEach(this.handlers,function(r){r!==null&&t(r)})}}const Hd=Bk,X0={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},Uk=typeof URLSearchParams<"u"?URLSearchParams:Bp,Hk=typeof FormData<"u"?FormData:null,Wk=typeof Blob<"u"?Blob:null,Vk=(()=>{let e;return typeof navigator<"u"&&((e=navigator.product)==="ReactNative"||e==="NativeScript"||e==="NS")?!1:typeof window<"u"&&typeof document<"u"})(),Gk=(()=>typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function")(),ln={isBrowser:!0,classes:{URLSearchParams:Uk,FormData:Hk,Blob:Wk},isStandardBrowserEnv:Vk,isStandardBrowserWebWorkerEnv:Gk,protocols:["http","https","file","blob","url","data"]};function qk(e,t){return Ua(e,new ln.classes.URLSearchParams,Object.assign({visitor:function(n,r,o,i){return ln.isNode&&R.isBuffer(n)?(this.append(r,n.toString("base64")),!1):i.defaultVisitor.apply(this,arguments)}},t))}function Yk(e){return R.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function Qk(e){const t={},n=Object.keys(e);let r;const o=n.length;let i;for(r=0;r=n.length;return l=!l&&R.isArray(o)?o.length:l,s?(R.hasOwnProp(o,l)?o[l]=[o[l],r]:o[l]=r,!a):((!o[l]||!R.isObject(o[l]))&&(o[l]=[]),t(n,r,o[l],i)&&R.isArray(o[l])&&(o[l]=Qk(o[l])),!a)}if(R.isFormData(e)&&R.isFunction(e.entries)){const n={};return R.forEachEntry(e,(r,o)=>{t(Yk(r),o,n,0)}),n}return null}function Kk(e,t,n){if(R.isString(e))try{return(t||JSON.parse)(e),R.trim(e)}catch(r){if(r.name!=="SyntaxError")throw r}return(n||JSON.stringify)(e)}const Up={transitional:X0,adapter:["xhr","http"],transformRequest:[function(t,n){const r=n.getContentType()||"",o=r.indexOf("application/json")>-1,i=R.isObject(t);if(i&&R.isHTMLForm(t)&&(t=new FormData(t)),R.isFormData(t))return o&&o?JSON.stringify(Z0(t)):t;if(R.isArrayBuffer(t)||R.isBuffer(t)||R.isStream(t)||R.isFile(t)||R.isBlob(t))return t;if(R.isArrayBufferView(t))return t.buffer;if(R.isURLSearchParams(t))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let a;if(i){if(r.indexOf("application/x-www-form-urlencoded")>-1)return qk(t,this.formSerializer).toString();if((a=R.isFileList(t))||r.indexOf("multipart/form-data")>-1){const s=this.env&&this.env.FormData;return Ua(a?{"files[]":t}:t,s&&new s,this.formSerializer)}}return i||o?(n.setContentType("application/json",!1),Kk(t)):t}],transformResponse:[function(t){const n=this.transitional||Up.transitional,r=n&&n.forcedJSONParsing,o=this.responseType==="json";if(t&&R.isString(t)&&(r&&!this.responseType||o)){const l=!(n&&n.silentJSONParsing)&&o;try{return JSON.parse(t)}catch(a){if(l)throw a.name==="SyntaxError"?he.from(a,he.ERR_BAD_RESPONSE,this,null,this.response):a}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:ln.classes.FormData,Blob:ln.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};R.forEach(["delete","get","head","post","put","patch"],e=>{Up.headers[e]={}});const Hp=Up,Xk=R.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),Zk=e=>{const t={};let n,r,o;return e&&e.split(` -`).forEach(function(l){o=l.indexOf(":"),n=l.substring(0,o).trim().toLowerCase(),r=l.substring(o+1).trim(),!(!n||t[n]&&Xk[n])&&(n==="set-cookie"?t[n]?t[n].push(r):t[n]=[r]:t[n]=t[n]?t[n]+", "+r:r)}),t},Wd=Symbol("internals");function Mo(e){return e&&String(e).trim().toLowerCase()}function Rl(e){return e===!1||e==null?e:R.isArray(e)?e.map(Rl):String(e)}function Jk(e){const t=Object.create(null),n=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=n.exec(e);)t[r[1]]=r[2];return t}const eS=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function Xs(e,t,n,r,o){if(R.isFunction(r))return r.call(this,t,n);if(o&&(t=n),!!R.isString(t)){if(R.isString(r))return t.indexOf(r)!==-1;if(R.isRegExp(r))return r.test(t)}}function tS(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(t,n,r)=>n.toUpperCase()+r)}function nS(e,t){const n=R.toCamelCase(" "+t);["get","set","has"].forEach(r=>{Object.defineProperty(e,r+n,{value:function(o,i,l){return this[r].call(this,t,o,i,l)},configurable:!0})})}class Ha{constructor(t){t&&this.set(t)}set(t,n,r){const o=this;function i(a,s,u){const c=Mo(s);if(!c)throw new Error("header name must be a non-empty string");const p=R.findKey(o,c);(!p||o[p]===void 0||u===!0||u===void 0&&o[p]!==!1)&&(o[p||s]=Rl(a))}const l=(a,s)=>R.forEach(a,(u,c)=>i(u,c,s));return R.isPlainObject(t)||t instanceof this.constructor?l(t,n):R.isString(t)&&(t=t.trim())&&!eS(t)?l(Zk(t),n):t!=null&&i(n,t,r),this}get(t,n){if(t=Mo(t),t){const r=R.findKey(this,t);if(r){const o=this[r];if(!n)return o;if(n===!0)return Jk(o);if(R.isFunction(n))return n.call(this,o,r);if(R.isRegExp(n))return n.exec(o);throw new TypeError("parser must be boolean|regexp|function")}}}has(t,n){if(t=Mo(t),t){const r=R.findKey(this,t);return!!(r&&this[r]!==void 0&&(!n||Xs(this,this[r],r,n)))}return!1}delete(t,n){const r=this;let o=!1;function i(l){if(l=Mo(l),l){const a=R.findKey(r,l);a&&(!n||Xs(r,r[a],a,n))&&(delete r[a],o=!0)}}return R.isArray(t)?t.forEach(i):i(t),o}clear(t){const n=Object.keys(this);let r=n.length,o=!1;for(;r--;){const i=n[r];(!t||Xs(this,this[i],i,t,!0))&&(delete this[i],o=!0)}return o}normalize(t){const n=this,r={};return R.forEach(this,(o,i)=>{const l=R.findKey(r,i);if(l){n[l]=Rl(o),delete n[i];return}const a=t?tS(i):String(i).trim();a!==i&&delete n[i],n[a]=Rl(o),r[a]=!0}),this}concat(...t){return this.constructor.concat(this,...t)}toJSON(t){const n=Object.create(null);return R.forEach(this,(r,o)=>{r!=null&&r!==!1&&(n[o]=t&&R.isArray(r)?r.join(", "):r)}),n}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([t,n])=>t+": "+n).join(` -`)}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(t){return t instanceof this?t:new this(t)}static concat(t,...n){const r=new this(t);return n.forEach(o=>r.set(o)),r}static accessor(t){const r=(this[Wd]=this[Wd]={accessors:{}}).accessors,o=this.prototype;function i(l){const a=Mo(l);r[a]||(nS(o,l),r[a]=!0)}return R.isArray(t)?t.forEach(i):i(t),this}}Ha.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);R.reduceDescriptors(Ha.prototype,({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(r){this[n]=r}}});R.freezeMethods(Ha);const Sn=Ha;function Zs(e,t){const n=this||Hp,r=t||n,o=Sn.from(r.headers);let i=r.data;return R.forEach(e,function(a){i=a.call(n,i,o.normalize(),t?t.status:void 0)}),o.normalize(),i}function J0(e){return!!(e&&e.__CANCEL__)}function Ni(e,t,n){he.call(this,e??"canceled",he.ERR_CANCELED,t,n),this.name="CanceledError"}R.inherits(Ni,he,{__CANCEL__:!0});function rS(e,t,n){const r=n.config.validateStatus;!n.status||!r||r(n.status)?e(n):t(new he("Request failed with status code "+n.status,[he.ERR_BAD_REQUEST,he.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n))}const oS=ln.isStandardBrowserEnv?function(){return{write:function(n,r,o,i,l,a){const s=[];s.push(n+"="+encodeURIComponent(r)),R.isNumber(o)&&s.push("expires="+new Date(o).toGMTString()),R.isString(i)&&s.push("path="+i),R.isString(l)&&s.push("domain="+l),a===!0&&s.push("secure"),document.cookie=s.join("; ")},read:function(n){const r=document.cookie.match(new RegExp("(^|;\\s*)("+n+")=([^;]*)"));return r?decodeURIComponent(r[3]):null},remove:function(n){this.write(n,"",Date.now()-864e5)}}}():function(){return{write:function(){},read:function(){return null},remove:function(){}}}();function iS(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function lS(e,t){return t?e.replace(/\/+$/,"")+"/"+t.replace(/^\/+/,""):e}function e1(e,t){return e&&!iS(t)?lS(e,t):t}const aS=ln.isStandardBrowserEnv?function(){const t=/(msie|trident)/i.test(navigator.userAgent),n=document.createElement("a");let r;function o(i){let l=i;return t&&(n.setAttribute("href",l),l=n.href),n.setAttribute("href",l),{href:n.href,protocol:n.protocol?n.protocol.replace(/:$/,""):"",host:n.host,search:n.search?n.search.replace(/^\?/,""):"",hash:n.hash?n.hash.replace(/^#/,""):"",hostname:n.hostname,port:n.port,pathname:n.pathname.charAt(0)==="/"?n.pathname:"/"+n.pathname}}return r=o(window.location.href),function(l){const a=R.isString(l)?o(l):l;return a.protocol===r.protocol&&a.host===r.host}}():function(){return function(){return!0}}();function sS(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}function uS(e,t){e=e||10;const n=new Array(e),r=new Array(e);let o=0,i=0,l;return t=t!==void 0?t:1e3,function(s){const u=Date.now(),c=r[i];l||(l=u),n[o]=s,r[o]=u;let p=i,d=0;for(;p!==o;)d+=n[p++],p=p%e;if(o=(o+1)%e,o===i&&(i=(i+1)%e),u-l{const i=o.loaded,l=o.lengthComputable?o.total:void 0,a=i-n,s=r(a),u=i<=l;n=i;const c={loaded:i,total:l,progress:l?i/l:void 0,bytes:a,rate:s||void 0,estimated:s&&l&&u?(l-i)/s:void 0,event:o};c[t?"download":"upload"]=!0,e(c)}}const cS=typeof XMLHttpRequest<"u",pS=cS&&function(e){return new Promise(function(n,r){let o=e.data;const i=Sn.from(e.headers).normalize(),l=e.responseType;let a;function s(){e.cancelToken&&e.cancelToken.unsubscribe(a),e.signal&&e.signal.removeEventListener("abort",a)}let u;R.isFormData(o)&&(ln.isStandardBrowserEnv||ln.isStandardBrowserWebWorkerEnv?i.setContentType(!1):i.getContentType(/^\s*multipart\/form-data/)?R.isString(u=i.getContentType())&&i.setContentType(u.replace(/^\s*(multipart\/form-data);+/,"$1")):i.setContentType("multipart/form-data"));let c=new XMLHttpRequest;if(e.auth){const h=e.auth.username||"",m=e.auth.password?unescape(encodeURIComponent(e.auth.password)):"";i.set("Authorization","Basic "+btoa(h+":"+m))}const p=e1(e.baseURL,e.url);c.open(e.method.toUpperCase(),K0(p,e.params,e.paramsSerializer),!0),c.timeout=e.timeout;function d(){if(!c)return;const h=Sn.from("getAllResponseHeaders"in c&&c.getAllResponseHeaders()),w={data:!l||l==="text"||l==="json"?c.responseText:c.response,status:c.status,statusText:c.statusText,headers:h,config:e,request:c};rS(function(y){n(y),s()},function(y){r(y),s()},w),c=null}if("onloadend"in c?c.onloadend=d:c.onreadystatechange=function(){!c||c.readyState!==4||c.status===0&&!(c.responseURL&&c.responseURL.indexOf("file:")===0)||setTimeout(d)},c.onabort=function(){c&&(r(new he("Request aborted",he.ECONNABORTED,e,c)),c=null)},c.onerror=function(){r(new he("Network Error",he.ERR_NETWORK,e,c)),c=null},c.ontimeout=function(){let m=e.timeout?"timeout of "+e.timeout+"ms exceeded":"timeout exceeded";const w=e.transitional||X0;e.timeoutErrorMessage&&(m=e.timeoutErrorMessage),r(new he(m,w.clarifyTimeoutError?he.ETIMEDOUT:he.ECONNABORTED,e,c)),c=null},ln.isStandardBrowserEnv){const h=(e.withCredentials||aS(p))&&e.xsrfCookieName&&oS.read(e.xsrfCookieName);h&&i.set(e.xsrfHeaderName,h)}o===void 0&&i.setContentType(null),"setRequestHeader"in c&&R.forEach(i.toJSON(),function(m,w){c.setRequestHeader(w,m)}),R.isUndefined(e.withCredentials)||(c.withCredentials=!!e.withCredentials),l&&l!=="json"&&(c.responseType=e.responseType),typeof e.onDownloadProgress=="function"&&c.addEventListener("progress",Vd(e.onDownloadProgress,!0)),typeof e.onUploadProgress=="function"&&c.upload&&c.upload.addEventListener("progress",Vd(e.onUploadProgress)),(e.cancelToken||e.signal)&&(a=h=>{c&&(r(!h||h.type?new Ni(null,e,c):h),c.abort(),c=null)},e.cancelToken&&e.cancelToken.subscribe(a),e.signal&&(e.signal.aborted?a():e.signal.addEventListener("abort",a)));const f=sS(p);if(f&&ln.protocols.indexOf(f)===-1){r(new he("Unsupported protocol "+f+":",he.ERR_BAD_REQUEST,e));return}c.send(o||null)})},vc={http:Ik,xhr:pS};R.forEach(vc,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch{}Object.defineProperty(e,"adapterName",{value:t})}});const Gd=e=>`- ${e}`,fS=e=>R.isFunction(e)||e===null||e===!1,t1={getAdapter:e=>{e=R.isArray(e)?e:[e];const{length:t}=e;let n,r;const o={};for(let i=0;i`adapter ${a} `+(s===!1?"is not supported by the environment":"is not available in the build"));let l=t?i.length>1?`since : -`+i.map(Gd).join(` -`):" "+Gd(i[0]):"as no adapter specified";throw new he("There is no suitable adapter to dispatch the request "+l,"ERR_NOT_SUPPORT")}return r},adapters:vc};function Js(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new Ni(null,e)}function qd(e){return Js(e),e.headers=Sn.from(e.headers),e.data=Zs.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),t1.getAdapter(e.adapter||Hp.adapter)(e).then(function(r){return Js(e),r.data=Zs.call(e,e.transformResponse,r),r.headers=Sn.from(r.headers),r},function(r){return J0(r)||(Js(e),r&&r.response&&(r.response.data=Zs.call(e,e.transformResponse,r.response),r.response.headers=Sn.from(r.response.headers))),Promise.reject(r)})}const Yd=e=>e instanceof Sn?e.toJSON():e;function go(e,t){t=t||{};const n={};function r(u,c,p){return R.isPlainObject(u)&&R.isPlainObject(c)?R.merge.call({caseless:p},u,c):R.isPlainObject(c)?R.merge({},c):R.isArray(c)?c.slice():c}function o(u,c,p){if(R.isUndefined(c)){if(!R.isUndefined(u))return r(void 0,u,p)}else return r(u,c,p)}function i(u,c){if(!R.isUndefined(c))return r(void 0,c)}function l(u,c){if(R.isUndefined(c)){if(!R.isUndefined(u))return r(void 0,u)}else return r(void 0,c)}function a(u,c,p){if(p in t)return r(u,c);if(p in e)return r(void 0,u)}const s={url:i,method:i,data:i,baseURL:l,transformRequest:l,transformResponse:l,paramsSerializer:l,timeout:l,timeoutMessage:l,withCredentials:l,adapter:l,responseType:l,xsrfCookieName:l,xsrfHeaderName:l,onUploadProgress:l,onDownloadProgress:l,decompress:l,maxContentLength:l,maxBodyLength:l,beforeRedirect:l,transport:l,httpAgent:l,httpsAgent:l,cancelToken:l,socketPath:l,responseEncoding:l,validateStatus:a,headers:(u,c)=>o(Yd(u),Yd(c),!0)};return R.forEach(Object.keys(Object.assign({},e,t)),function(c){const p=s[c]||o,d=p(e[c],t[c],c);R.isUndefined(d)&&p!==a||(n[c]=d)}),n}const n1="1.5.1",Wp={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{Wp[e]=function(r){return typeof r===e||"a"+(t<1?"n ":" ")+e}});const Qd={};Wp.transitional=function(t,n,r){function o(i,l){return"[Axios v"+n1+"] Transitional option '"+i+"'"+l+(r?". "+r:"")}return(i,l,a)=>{if(t===!1)throw new he(o(l," has been removed"+(n?" in "+n:"")),he.ERR_DEPRECATED);return n&&!Qd[l]&&(Qd[l]=!0,console.warn(o(l," has been deprecated since v"+n+" and will be removed in the near future"))),t?t(i,l,a):!0}};function dS(e,t,n){if(typeof e!="object")throw new he("options must be an object",he.ERR_BAD_OPTION_VALUE);const r=Object.keys(e);let o=r.length;for(;o-- >0;){const i=r[o],l=t[i];if(l){const a=e[i],s=a===void 0||l(a,i,e);if(s!==!0)throw new he("option "+i+" must be "+s,he.ERR_BAD_OPTION_VALUE);continue}if(n!==!0)throw new he("Unknown option "+i,he.ERR_BAD_OPTION)}}const wc={assertOptions:dS,validators:Wp},In=wc.validators;class pa{constructor(t){this.defaults=t,this.interceptors={request:new Hd,response:new Hd}}request(t,n){typeof t=="string"?(n=n||{},n.url=t):n=t||{},n=go(this.defaults,n);const{transitional:r,paramsSerializer:o,headers:i}=n;r!==void 0&&wc.assertOptions(r,{silentJSONParsing:In.transitional(In.boolean),forcedJSONParsing:In.transitional(In.boolean),clarifyTimeoutError:In.transitional(In.boolean)},!1),o!=null&&(R.isFunction(o)?n.paramsSerializer={serialize:o}:wc.assertOptions(o,{encode:In.function,serialize:In.function},!0)),n.method=(n.method||this.defaults.method||"get").toLowerCase();let l=i&&R.merge(i.common,i[n.method]);i&&R.forEach(["delete","get","head","post","put","patch","common"],h=>{delete i[h]}),n.headers=Sn.concat(l,i);const a=[];let s=!0;this.interceptors.request.forEach(function(m){typeof m.runWhen=="function"&&m.runWhen(n)===!1||(s=s&&m.synchronous,a.unshift(m.fulfilled,m.rejected))});const u=[];this.interceptors.response.forEach(function(m){u.push(m.fulfilled,m.rejected)});let c,p=0,d;if(!s){const h=[qd.bind(this),void 0];for(h.unshift.apply(h,a),h.push.apply(h,u),d=h.length,c=Promise.resolve(n);p{if(!r._listeners)return;let i=r._listeners.length;for(;i-- >0;)r._listeners[i](o);r._listeners=null}),this.promise.then=o=>{let i;const l=new Promise(a=>{r.subscribe(a),i=a}).then(o);return l.cancel=function(){r.unsubscribe(i)},l},t(function(i,l,a){r.reason||(r.reason=new Ni(i,l,a),n(r.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}unsubscribe(t){if(!this._listeners)return;const n=this._listeners.indexOf(t);n!==-1&&this._listeners.splice(n,1)}static source(){let t;return{token:new Vp(function(o){t=o}),cancel:t}}}const hS=Vp;function mS(e){return function(n){return e.apply(null,n)}}function gS(e){return R.isObject(e)&&e.isAxiosError===!0}const xc={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(xc).forEach(([e,t])=>{xc[t]=e});const yS=xc;function r1(e){const t=new Ll(e),n=F0(Ll.prototype.request,t);return R.extend(n,Ll.prototype,t,{allOwnKeys:!0}),R.extend(n,t,null,{allOwnKeys:!0}),n.create=function(o){return r1(go(e,o))},n}const He=r1(Hp);He.Axios=Ll;He.CanceledError=Ni;He.CancelToken=hS;He.isCancel=J0;He.VERSION=n1;He.toFormData=Ua;He.AxiosError=he;He.Cancel=He.CanceledError;He.all=function(t){return Promise.all(t)};He.spread=mS;He.isAxiosError=gS;He.mergeConfig=go;He.AxiosHeaders=Sn;He.formToJSON=e=>Z0(R.isHTMLForm(e)?new FormData(e):e);He.getAdapter=t1.getAdapter;He.HttpStatusCode=yS;He.default=He;const vS=He,Kd="@openchatai:session_id";function wS(){const[e,t]=b.useState(void 0);return b.useEffect(()=>{const n=localStorage.getItem(Kd);if(n)t(n);else{const r=Math.random().toString(36).substring(2,15);localStorage.setItem(Kd,r),t(r)}},[]),{sessionId:e,setSessionId:t}}function xS(e,t){const n=vS.create({baseURL:e,headers:{"X-Session-Id":t}});return n.interceptors.request.use(r=>(r.data={...r.data,session_id:t},r)),n}const o1=b.createContext(void 0);function bS({children:e}){const t=jp(),{sessionId:n}=wS(),r=b.useMemo(()=>xS(t==null?void 0:t.apiUrl,n),[t,n]);return t!=null&&t.token?r.defaults.headers["X-Bot-Token"]=t==null?void 0:t.token:console.warn("No token!"),L.jsx(o1.Provider,{value:{axiosInstance:r},children:e})}const i1=()=>{const e=b.useContext(o1);if(!e)throw new Error("useAxiosInstance must be used within a AxiosProvider");return e},l1=b.createContext(void 0);function kS({children:e}){const{axiosInstance:t}=i1(),[n,r]=b.useState(),[o,i]=b.useState(!0);async function l(){i(!0),t.get("/chat/init").then(({data:a})=>r(a)).finally(()=>i(!1))}return b.useEffect(()=>{l()},[]),L.jsx(l1.Provider,{value:{data:n,loading:o,refetch:l},children:e})}const a1=()=>{const e=b.useContext(l1);return e||console.warn("Error loading initial data...."),e};function SS({children:e,options:t}){return L.jsx(ek,{data:t,children:L.jsx(nk,{children:L.jsx(bS,{children:L.jsx(kS,{children:e})})})})}function CS(){for(var e=0,t,n,r="";ee&&(t=0,r=n,n=new Map)}return{get:function(l){var a=n.get(l);if(a!==void 0)return a;if((a=r.get(l))!==void 0)return o(l,a),a},set:function(l,a){n.has(l)?n.set(l,a):o(l,a)}}}var c1="!";function $S(e){var t=e.separator||":",n=t.length===1,r=t[0],o=t.length;return function(l){for(var a=[],s=0,u=0,c,p=0;pu?c-u:void 0;return{modifiers:a,hasImportantModifier:h,baseClassName:m,maybePostfixModifierPosition:w}}}function RS(e){if(e.length<=1)return e;var t=[],n=[];return e.forEach(function(r){var o=r[0]==="[";o?(t.push.apply(t,n.sort().concat([r])),n=[]):n.push(r)}),t.push.apply(t,n.sort()),t}function LS(e){return{cache:_S(e.cacheSize),splitModifiers:$S(e),...ES(e)}}var zS=/\s+/;function DS(e,t){var n=t.splitModifiers,r=t.getClassGroupId,o=t.getConflictingClassGroupIds,i=new Set;return e.trim().split(zS).map(function(l){var a=n(l),s=a.modifiers,u=a.hasImportantModifier,c=a.baseClassName,p=a.maybePostfixModifierPosition,d=r(p?c.substring(0,p):c),f=!!p;if(!d){if(!p)return{isTailwindClass:!1,originalClassName:l};if(d=r(c),!d)return{isTailwindClass:!1,originalClassName:l};f=!1}var h=RS(s).join(":"),m=u?h+c1:h;return{isTailwindClass:!0,modifierId:m,classGroupId:d,originalClassName:l,hasPostfixModifier:f}}).reverse().filter(function(l){if(!l.isTailwindClass)return!0;var a=l.modifierId,s=l.classGroupId,u=l.hasPostfixModifier,c=a+s;return i.has(c)?!1:(i.add(c),o(s,u).forEach(function(p){return i.add(a+p)}),!0)}).reverse().map(function(l){return l.originalClassName}).join(" ")}function NS(){for(var e=arguments.length,t=new Array(e),n=0;ne.forEach(n=>t2(n,t))}function pn(...e){return b.useCallback(m1(...e),e)}function qp(e,t=[]){let n=[];function r(i,l){const a=b.createContext(l),s=n.length;n=[...n,l];function u(p){const{scope:d,children:f,...h}=p,m=(d==null?void 0:d[e][s])||a,w=b.useMemo(()=>h,Object.values(h));return b.createElement(m.Provider,{value:w},f)}function c(p,d){const f=(d==null?void 0:d[e][s])||a,h=b.useContext(f);if(h)return h;if(l!==void 0)return l;throw new Error(`\`${p}\` must be used within \`${i}\``)}return u.displayName=i+"Provider",[u,c]}const o=()=>{const i=n.map(l=>b.createContext(l));return function(a){const s=(a==null?void 0:a[e])||i;return b.useMemo(()=>({[`__scope${e}`]:{...a,[e]:s}}),[a,s])}};return o.scopeName=e,[r,n2(o,...t)]}function n2(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(i){const l=r.reduce((a,{useScope:s,scopeName:u})=>{const p=s(i)[`__scope${u}`];return{...a,...p}},{});return b.useMemo(()=>({[`__scope${t.scopeName}`]:l}),[l])}};return n.scopeName=t.scopeName,n}const yo=globalThis!=null&&globalThis.document?b.useLayoutEffect:()=>{},r2=Hw["useId".toString()]||(()=>{});let o2=0;function zl(e){const[t,n]=b.useState(r2());return yo(()=>{e||n(r=>r??String(o2++))},[e]),e||(t?`radix-${t}`:"")}function ir(e){const t=b.useRef(e);return b.useEffect(()=>{t.current=e}),b.useMemo(()=>(...n)=>{var r;return(r=t.current)===null||r===void 0?void 0:r.call(t,...n)},[])}function g1({prop:e,defaultProp:t,onChange:n=()=>{}}){const[r,o]=i2({defaultProp:t,onChange:n}),i=e!==void 0,l=i?e:r,a=ir(n),s=b.useCallback(u=>{if(i){const p=typeof u=="function"?u(e):u;p!==e&&a(p)}else o(u)},[i,e,o,a]);return[l,s]}function i2({defaultProp:e,onChange:t}){const n=b.useState(e),[r]=n,o=b.useRef(r),i=ir(t);return b.useEffect(()=>{o.current!==r&&(i(r),o.current=r)},[r,o,i]),n}const Yp=b.forwardRef((e,t)=>{const{children:n,...r}=e,o=b.Children.toArray(n),i=o.find(l2);if(i){const l=i.props.children,a=o.map(s=>s===i?b.Children.count(l)>1?b.Children.only(null):b.isValidElement(l)?l.props.children:null:s);return b.createElement(Sc,ye({},r,{ref:t}),b.isValidElement(l)?b.cloneElement(l,void 0,a):null)}return b.createElement(Sc,ye({},r,{ref:t}),n)});Yp.displayName="Slot";const Sc=b.forwardRef((e,t)=>{const{children:n,...r}=e;return b.isValidElement(n)?b.cloneElement(n,{...a2(r,n.props),ref:t?m1(t,n.ref):n.ref}):b.Children.count(n)>1?b.Children.only(null):null});Sc.displayName="SlotClone";const y1=({children:e})=>b.createElement(b.Fragment,null,e);function l2(e){return b.isValidElement(e)&&e.type===y1}function a2(e,t){const n={...t};for(const r in t){const o=e[r],i=t[r];/^on[A-Z]/.test(r)?o&&i?n[r]=(...a)=>{i(...a),o(...a)}:o&&(n[r]=o):r==="style"?n[r]={...o,...i}:r==="className"&&(n[r]=[o,i].filter(Boolean).join(" "))}return{...e,...n}}const s2=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"],jt=s2.reduce((e,t)=>{const n=b.forwardRef((r,o)=>{const{asChild:i,...l}=r,a=i?Yp:t;return b.useEffect(()=>{window[Symbol.for("radix-ui")]=!0},[]),b.createElement(a,ye({},l,{ref:o}))});return n.displayName=`Primitive.${t}`,{...e,[t]:n}},{});function u2(e,t){e&&Fa.flushSync(()=>e.dispatchEvent(t))}function c2(e,t=globalThis==null?void 0:globalThis.document){const n=ir(e);b.useEffect(()=>{const r=o=>{o.key==="Escape"&&n(o)};return t.addEventListener("keydown",r),()=>t.removeEventListener("keydown",r)},[n,t])}const Cc="dismissableLayer.update",p2="dismissableLayer.pointerDownOutside",f2="dismissableLayer.focusOutside";let th;const d2=b.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),v1=b.forwardRef((e,t)=>{var n;const{disableOutsidePointerEvents:r=!1,onEscapeKeyDown:o,onPointerDownOutside:i,onFocusOutside:l,onInteractOutside:a,onDismiss:s,...u}=e,c=b.useContext(d2),[p,d]=b.useState(null),f=(n=p==null?void 0:p.ownerDocument)!==null&&n!==void 0?n:globalThis==null?void 0:globalThis.document,[,h]=b.useState({}),m=pn(t,A=>d(A)),w=Array.from(c.layers),[g]=[...c.layersWithOutsidePointerEventsDisabled].slice(-1),y=w.indexOf(g),v=p?w.indexOf(p):-1,C=c.layersWithOutsidePointerEventsDisabled.size>0,E=v>=y,k=h2(A=>{const N=A.target,P=[...c.branches].some(z=>z.contains(N));!E||P||(i==null||i(A),a==null||a(A),A.defaultPrevented||s==null||s())},f),T=m2(A=>{const N=A.target;[...c.branches].some(z=>z.contains(N))||(l==null||l(A),a==null||a(A),A.defaultPrevented||s==null||s())},f);return c2(A=>{v===c.layers.size-1&&(o==null||o(A),!A.defaultPrevented&&s&&(A.preventDefault(),s()))},f),b.useEffect(()=>{if(p)return r&&(c.layersWithOutsidePointerEventsDisabled.size===0&&(th=f.body.style.pointerEvents,f.body.style.pointerEvents="none"),c.layersWithOutsidePointerEventsDisabled.add(p)),c.layers.add(p),nh(),()=>{r&&c.layersWithOutsidePointerEventsDisabled.size===1&&(f.body.style.pointerEvents=th)}},[p,f,r,c]),b.useEffect(()=>()=>{p&&(c.layers.delete(p),c.layersWithOutsidePointerEventsDisabled.delete(p),nh())},[p,c]),b.useEffect(()=>{const A=()=>h({});return document.addEventListener(Cc,A),()=>document.removeEventListener(Cc,A)},[]),b.createElement(jt.div,ye({},u,{ref:m,style:{pointerEvents:C?E?"auto":"none":void 0,...e.style},onFocusCapture:ft(e.onFocusCapture,T.onFocusCapture),onBlurCapture:ft(e.onBlurCapture,T.onBlurCapture),onPointerDownCapture:ft(e.onPointerDownCapture,k.onPointerDownCapture)}))});function h2(e,t=globalThis==null?void 0:globalThis.document){const n=ir(e),r=b.useRef(!1),o=b.useRef(()=>{});return b.useEffect(()=>{const i=a=>{if(a.target&&!r.current){let c=function(){w1(p2,n,u,{discrete:!0})};var s=c;const u={originalEvent:a};a.pointerType==="touch"?(t.removeEventListener("click",o.current),o.current=c,t.addEventListener("click",o.current,{once:!0})):c()}else t.removeEventListener("click",o.current);r.current=!1},l=window.setTimeout(()=>{t.addEventListener("pointerdown",i)},0);return()=>{window.clearTimeout(l),t.removeEventListener("pointerdown",i),t.removeEventListener("click",o.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function m2(e,t=globalThis==null?void 0:globalThis.document){const n=ir(e),r=b.useRef(!1);return b.useEffect(()=>{const o=i=>{i.target&&!r.current&&w1(f2,n,{originalEvent:i},{discrete:!1})};return t.addEventListener("focusin",o),()=>t.removeEventListener("focusin",o)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function nh(){const e=new CustomEvent(Cc);document.dispatchEvent(e)}function w1(e,t,n,{discrete:r}){const o=n.originalEvent.target,i=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&o.addEventListener(e,t,{once:!0}),r?u2(o,i):o.dispatchEvent(i)}const eu="focusScope.autoFocusOnMount",tu="focusScope.autoFocusOnUnmount",rh={bubbles:!1,cancelable:!0},g2=b.forwardRef((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:o,onUnmountAutoFocus:i,...l}=e,[a,s]=b.useState(null),u=ir(o),c=ir(i),p=b.useRef(null),d=pn(t,m=>s(m)),f=b.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;b.useEffect(()=>{if(r){let y=function(k){if(f.paused||!a)return;const T=k.target;a.contains(T)?p.current=T:Mn(p.current,{select:!0})},v=function(k){if(f.paused||!a)return;const T=k.relatedTarget;T!==null&&(a.contains(T)||Mn(p.current,{select:!0}))},C=function(k){if(document.activeElement===document.body)for(const A of k)A.removedNodes.length>0&&Mn(a)};var m=y,w=v,g=C;document.addEventListener("focusin",y),document.addEventListener("focusout",v);const E=new MutationObserver(C);return a&&E.observe(a,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",y),document.removeEventListener("focusout",v),E.disconnect()}}},[r,a,f.paused]),b.useEffect(()=>{if(a){ih.add(f);const m=document.activeElement;if(!a.contains(m)){const g=new CustomEvent(eu,rh);a.addEventListener(eu,u),a.dispatchEvent(g),g.defaultPrevented||(y2(k2(x1(a)),{select:!0}),document.activeElement===m&&Mn(a))}return()=>{a.removeEventListener(eu,u),setTimeout(()=>{const g=new CustomEvent(tu,rh);a.addEventListener(tu,c),a.dispatchEvent(g),g.defaultPrevented||Mn(m??document.body,{select:!0}),a.removeEventListener(tu,c),ih.remove(f)},0)}}},[a,u,c,f]);const h=b.useCallback(m=>{if(!n&&!r||f.paused)return;const w=m.key==="Tab"&&!m.altKey&&!m.ctrlKey&&!m.metaKey,g=document.activeElement;if(w&&g){const y=m.currentTarget,[v,C]=v2(y);v&&C?!m.shiftKey&&g===C?(m.preventDefault(),n&&Mn(v,{select:!0})):m.shiftKey&&g===v&&(m.preventDefault(),n&&Mn(C,{select:!0})):g===y&&m.preventDefault()}},[n,r,f.paused]);return b.createElement(jt.div,ye({tabIndex:-1},l,{ref:d,onKeyDown:h}))});function y2(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(Mn(r,{select:t}),document.activeElement!==n)return}function v2(e){const t=x1(e),n=oh(t,e),r=oh(t.reverse(),e);return[n,r]}function x1(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const o=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||o?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function oh(e,t){for(const n of e)if(!w2(n,{upTo:t}))return n}function w2(e,{upTo:t}){if(getComputedStyle(e).visibility==="hidden")return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display==="none")return!0;e=e.parentElement}return!1}function x2(e){return e instanceof HTMLInputElement&&"select"in e}function Mn(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&x2(e)&&t&&e.select()}}const ih=b2();function b2(){let e=[];return{add(t){const n=e[0];t!==n&&(n==null||n.pause()),e=lh(e,t),e.unshift(t)},remove(t){var n;e=lh(e,t),(n=e[0])===null||n===void 0||n.resume()}}}function lh(e,t){const n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function k2(e){return e.filter(t=>t.tagName!=="A")}function S2(e,t){return b.useReducer((n,r)=>{const o=t[n][r];return o??n},e)}const Wa=e=>{const{present:t,children:n}=e,r=C2(t),o=typeof n=="function"?n({present:r.isPresent}):b.Children.only(n),i=pn(r.ref,o.ref);return typeof n=="function"||r.isPresent?b.cloneElement(o,{ref:i}):null};Wa.displayName="Presence";function C2(e){const[t,n]=b.useState(),r=b.useRef({}),o=b.useRef(e),i=b.useRef("none"),l=e?"mounted":"unmounted",[a,s]=S2(l,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return b.useEffect(()=>{const u=sl(r.current);i.current=a==="mounted"?u:"none"},[a]),yo(()=>{const u=r.current,c=o.current;if(c!==e){const d=i.current,f=sl(u);e?s("MOUNT"):f==="none"||(u==null?void 0:u.display)==="none"?s("UNMOUNT"):s(c&&d!==f?"ANIMATION_OUT":"UNMOUNT"),o.current=e}},[e,s]),yo(()=>{if(t){const u=p=>{const f=sl(r.current).includes(p.animationName);p.target===t&&f&&Fa.flushSync(()=>s("ANIMATION_END"))},c=p=>{p.target===t&&(i.current=sl(r.current))};return t.addEventListener("animationstart",c),t.addEventListener("animationcancel",u),t.addEventListener("animationend",u),()=>{t.removeEventListener("animationstart",c),t.removeEventListener("animationcancel",u),t.removeEventListener("animationend",u)}}else s("ANIMATION_END")},[t,s]),{isPresent:["mounted","unmountSuspended"].includes(a),ref:b.useCallback(u=>{u&&(r.current=getComputedStyle(u)),n(u)},[])}}function sl(e){return(e==null?void 0:e.animationName)||"none"}let nu=0;function E2(){b.useEffect(()=>{var e,t;const n=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",(e=n[0])!==null&&e!==void 0?e:ah()),document.body.insertAdjacentElement("beforeend",(t=n[1])!==null&&t!==void 0?t:ah()),nu++,()=>{nu===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(r=>r.remove()),nu--}},[])}function ah(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.cssText="outline: none; opacity: 0; position: fixed; pointer-events: none",e}var on=function(){return on=Object.assign||function(t){for(var n,r=1,o=arguments.length;r"u")return U2;var t=H2(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},V2=C1(),G2=function(e,t,n,r){var o=e.left,i=e.top,l=e.right,a=e.gap;return n===void 0&&(n="margin"),` - .`.concat(T2,` { +`+i.stack}return{value:e,source:t,stack:o,digest:null}}function Qs(e,t,n){return{value:e,source:null,stack:n??null,digest:t??null}}function ic(e,t){try{console.error(t.value)}catch(n){setTimeout(function(){throw n})}}var Db=typeof WeakMap=="function"?WeakMap:Map;function p0(e,t,n){n=kn(-1,n),n.tag=3,n.payload={element:null};var r=t.value;return n.callback=function(){ca||(ca=!0,mc=r),ic(e,t)},n}function f0(e,t,n){n=kn(-1,n),n.tag=3;var r=e.type.getDerivedStateFromError;if(typeof r=="function"){var o=t.value;n.payload=function(){return r(o)},n.callback=function(){ic(e,t)}}var i=e.stateNode;return i!==null&&typeof i.componentDidCatch=="function"&&(n.callback=function(){ic(e,t),typeof r!="function"&&(Zn===null?Zn=new Set([this]):Zn.add(this));var l=t.stack;this.componentDidCatch(t.value,{componentStack:l!==null?l:""})}),n}function kd(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new Db;var o=new Set;r.set(t,o)}else o=r.get(t),o===void 0&&(o=new Set,r.set(t,o));o.has(n)||(o.add(n),e=Yb.bind(null,e,t,n),t.then(e,e))}function Sd(e){do{var t;if((t=e.tag===13)&&(t=e.memoizedState,t=t!==null?t.dehydrated!==null:!0),t)return e;e=e.return}while(e!==null);return null}function Cd(e,t,n,r,o){return e.mode&1?(e.flags|=65536,e.lanes=o,e):(e===t?e.flags|=65536:(e.flags|=128,n.flags|=131072,n.flags&=-52805,n.tag===1&&(n.alternate===null?n.tag=17:(t=kn(-1,1),t.tag=2,Xn(n,t,1))),n.lanes|=1),e)}var zb=Rn.ReactCurrentOwner,dt=!1;function lt(e,t,n,r){t.child=e===null?Wy(t,null,n,r):fo(t,e.child,n,r)}function Ed(e,t,n,r,o){n=n.render;var i=t.ref;return io(t,o),r=Pp(e,t,n,r,i,o),n=Op(),e!==null&&!dt?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~o,On(e,t,o)):($e&&n&&hp(t),t.flags|=1,lt(e,t,r,o),t.child)}function Pd(e,t,n,r,o){if(e===null){var i=n.type;return typeof i=="function"&&!Ip(i)&&i.defaultProps===void 0&&n.compare===null&&n.defaultProps===void 0?(t.tag=15,t.type=i,d0(e,t,i,r,o)):(e=Rl(n.type,null,r,t,t.mode,o),e.ref=t.ref,e.return=t,t.child=e)}if(i=e.child,!(e.lanes&o)){var l=i.memoizedProps;if(n=n.compare,n=n!==null?n:mi,n(l,r)&&e.ref===t.ref)return On(e,t,o)}return t.flags|=1,e=er(i,r),e.ref=t.ref,e.return=t,t.child=e}function d0(e,t,n,r,o){if(e!==null){var i=e.memoizedProps;if(mi(i,r)&&e.ref===t.ref)if(dt=!1,t.pendingProps=r=i,(e.lanes&o)!==0)e.flags&131072&&(dt=!0);else return t.lanes=e.lanes,On(e,t,o)}return lc(e,t,n,r,o)}function h0(e,t,n){var r=t.pendingProps,o=r.children,i=e!==null?e.memoizedState:null;if(r.mode==="hidden")if(!(t.mode&1))t.memoizedState={baseLanes:0,cachePool:null,transitions:null},Ce(Jr,wt),wt|=n;else{if(!(n&1073741824))return e=i!==null?i.baseLanes|n:n,t.lanes=t.childLanes=1073741824,t.memoizedState={baseLanes:e,cachePool:null,transitions:null},t.updateQueue=null,Ce(Jr,wt),wt|=e,null;t.memoizedState={baseLanes:0,cachePool:null,transitions:null},r=i!==null?i.baseLanes:n,Ce(Jr,wt),wt|=r}else i!==null?(r=i.baseLanes|n,t.memoizedState=null):r=n,Ce(Jr,wt),wt|=r;return lt(e,t,o,n),t.child}function m0(e,t){var n=t.ref;(e===null&&n!==null||e!==null&&e.ref!==n)&&(t.flags|=512,t.flags|=2097152)}function lc(e,t,n,r,o){var i=mt(n)?Cr:ot.current;return i=co(t,i),io(t,o),n=Pp(e,t,n,r,i,o),r=Op(),e!==null&&!dt?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~o,On(e,t,o)):($e&&r&&hp(t),t.flags|=1,lt(e,t,n,o),t.child)}function Od(e,t,n,r,o){if(mt(n)){var i=!0;ea(t)}else i=!1;if(io(t,o),t.stateNode===null)Al(e,t),Uy(t,n,r),oc(t,n,r,o),r=!0;else if(e===null){var l=t.stateNode,a=t.memoizedProps;l.props=a;var s=l.context,u=n.contextType;typeof u=="object"&&u!==null?u=Nt(u):(u=mt(n)?Cr:ot.current,u=co(t,u));var p=n.getDerivedStateFromProps,c=typeof p=="function"||typeof l.getSnapshotBeforeUpdate=="function";c||typeof l.UNSAFE_componentWillReceiveProps!="function"&&typeof l.componentWillReceiveProps!="function"||(a!==r||s!==u)&&vd(t,l,r,u),Un=!1;var d=t.memoizedState;l.state=d,ia(t,r,l,o),s=t.memoizedState,a!==r||d!==s||ht.current||Un?(typeof p=="function"&&(rc(t,n,p,r),s=t.memoizedState),(a=Un||yd(t,n,a,r,d,s,u))?(c||typeof l.UNSAFE_componentWillMount!="function"&&typeof l.componentWillMount!="function"||(typeof l.componentWillMount=="function"&&l.componentWillMount(),typeof l.UNSAFE_componentWillMount=="function"&&l.UNSAFE_componentWillMount()),typeof l.componentDidMount=="function"&&(t.flags|=4194308)):(typeof l.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=r,t.memoizedState=s),l.props=r,l.state=s,l.context=u,r=a):(typeof l.componentDidMount=="function"&&(t.flags|=4194308),r=!1)}else{l=t.stateNode,My(e,t),a=t.memoizedProps,u=t.type===t.elementType?a:Gt(t.type,a),l.props=u,c=t.pendingProps,d=l.context,s=n.contextType,typeof s=="object"&&s!==null?s=Nt(s):(s=mt(n)?Cr:ot.current,s=co(t,s));var f=n.getDerivedStateFromProps;(p=typeof f=="function"||typeof l.getSnapshotBeforeUpdate=="function")||typeof l.UNSAFE_componentWillReceiveProps!="function"&&typeof l.componentWillReceiveProps!="function"||(a!==c||d!==s)&&vd(t,l,r,s),Un=!1,d=t.memoizedState,l.state=d,ia(t,r,l,o);var h=t.memoizedState;a!==c||d!==h||ht.current||Un?(typeof f=="function"&&(rc(t,n,f,r),h=t.memoizedState),(u=Un||yd(t,n,u,r,d,h,s)||!1)?(p||typeof l.UNSAFE_componentWillUpdate!="function"&&typeof l.componentWillUpdate!="function"||(typeof l.componentWillUpdate=="function"&&l.componentWillUpdate(r,h,s),typeof l.UNSAFE_componentWillUpdate=="function"&&l.UNSAFE_componentWillUpdate(r,h,s)),typeof l.componentDidUpdate=="function"&&(t.flags|=4),typeof l.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof l.componentDidUpdate!="function"||a===e.memoizedProps&&d===e.memoizedState||(t.flags|=4),typeof l.getSnapshotBeforeUpdate!="function"||a===e.memoizedProps&&d===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=h),l.props=r,l.state=h,l.context=s,r=u):(typeof l.componentDidUpdate!="function"||a===e.memoizedProps&&d===e.memoizedState||(t.flags|=4),typeof l.getSnapshotBeforeUpdate!="function"||a===e.memoizedProps&&d===e.memoizedState||(t.flags|=1024),r=!1)}return ac(e,t,n,r,i,o)}function ac(e,t,n,r,o,i){m0(e,t);var l=(t.flags&128)!==0;if(!r&&!l)return o&&fd(t,n,!1),On(e,t,i);r=t.stateNode,zb.current=t;var a=l&&typeof n.getDerivedStateFromError!="function"?null:r.render();return t.flags|=1,e!==null&&l?(t.child=fo(t,e.child,null,i),t.child=fo(t,null,a,i)):lt(e,t,a,i),t.memoizedState=r.state,o&&fd(t,n,!0),t.child}function g0(e){var t=e.stateNode;t.pendingContext?pd(e,t.pendingContext,t.pendingContext!==t.context):t.context&&pd(e,t.context,!1),kp(e,t.containerInfo)}function Td(e,t,n,r,o){return po(),gp(o),t.flags|=256,lt(e,t,n,r),t.child}var sc={dehydrated:null,treeContext:null,retryLane:0};function uc(e){return{baseLanes:e,cachePool:null,transitions:null}}function y0(e,t,n){var r=t.pendingProps,o=Re.current,i=!1,l=(t.flags&128)!==0,a;if((a=l)||(a=e!==null&&e.memoizedState===null?!1:(o&2)!==0),a?(i=!0,t.flags&=-129):(e===null||e.memoizedState!==null)&&(o|=1),Ce(Re,o&1),e===null)return tc(t),e=t.memoizedState,e!==null&&(e=e.dehydrated,e!==null)?(t.mode&1?e.data==="$!"?t.lanes=8:t.lanes=1073741824:t.lanes=1,null):(l=r.children,e=r.fallback,i?(r=t.mode,i=t.child,l={mode:"hidden",children:l},!(r&1)&&i!==null?(i.childLanes=0,i.pendingProps=l):i=Na(l,r,0,null),e=Sr(e,r,n,null),i.return=t,e.return=t,i.sibling=e,t.child=i,t.child.memoizedState=uc(n),t.memoizedState=sc,e):$p(t,l));if(o=e.memoizedState,o!==null&&(a=o.dehydrated,a!==null))return Nb(e,t,l,r,a,o,n);if(i){i=r.fallback,l=t.mode,o=e.child,a=o.sibling;var s={mode:"hidden",children:r.children};return!(l&1)&&t.child!==o?(r=t.child,r.childLanes=0,r.pendingProps=s,t.deletions=null):(r=er(o,s),r.subtreeFlags=o.subtreeFlags&14680064),a!==null?i=er(a,i):(i=Sr(i,l,n,null),i.flags|=2),i.return=t,r.return=t,r.sibling=i,t.child=r,r=i,i=t.child,l=e.child.memoizedState,l=l===null?uc(n):{baseLanes:l.baseLanes|n,cachePool:null,transitions:l.transitions},i.memoizedState=l,i.childLanes=e.childLanes&~n,t.memoizedState=sc,r}return i=e.child,e=i.sibling,r=er(i,{mode:"visible",children:r.children}),!(t.mode&1)&&(r.lanes=n),r.return=t,r.sibling=null,e!==null&&(n=t.deletions,n===null?(t.deletions=[e],t.flags|=16):n.push(e)),t.child=r,t.memoizedState=null,r}function $p(e,t){return t=Na({mode:"visible",children:t},e.mode,0,null),t.return=e,e.child=t}function il(e,t,n,r){return r!==null&&gp(r),fo(t,e.child,null,n),e=$p(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function Nb(e,t,n,r,o,i,l){if(n)return t.flags&256?(t.flags&=-257,r=Qs(Error(F(422))),il(e,t,l,r)):t.memoizedState!==null?(t.child=e.child,t.flags|=128,null):(i=r.fallback,o=t.mode,r=Na({mode:"visible",children:r.children},o,0,null),i=Sr(i,o,l,null),i.flags|=2,r.return=t,i.return=t,r.sibling=i,t.child=r,t.mode&1&&fo(t,e.child,null,l),t.child.memoizedState=uc(l),t.memoizedState=sc,i);if(!(t.mode&1))return il(e,t,l,null);if(o.data==="$!"){if(r=o.nextSibling&&o.nextSibling.dataset,r)var a=r.dgst;return r=a,i=Error(F(419)),r=Qs(i,r,void 0),il(e,t,l,r)}if(a=(l&e.childLanes)!==0,dt||a){if(r=Ye,r!==null){switch(l&-l){case 4:o=2;break;case 16:o=8;break;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:o=32;break;case 536870912:o=268435456;break;default:o=0}o=o&(r.suspendedLanes|l)?0:o,o!==0&&o!==i.retryLane&&(i.retryLane=o,Pn(e,o),Xt(r,e,o,-1))}return Np(),r=Qs(Error(F(421))),il(e,t,l,r)}return o.data==="$?"?(t.flags|=128,t.child=e.child,t=Qb.bind(null,e),o._reactRetry=t,null):(e=i.treeContext,bt=Kn(o.nextSibling),kt=t,$e=!0,Yt=null,e!==null&&($t[_t++]=wn,$t[_t++]=xn,$t[_t++]=Er,wn=e.id,xn=e.overflow,Er=t),t=$p(t,r.children),t.flags|=4096,t)}function Ad(e,t,n){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),nc(e.return,t,n)}function Ks(e,t,n,r,o){var i=e.memoizedState;i===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:o}:(i.isBackwards=t,i.rendering=null,i.renderingStartTime=0,i.last=r,i.tail=n,i.tailMode=o)}function v0(e,t,n){var r=t.pendingProps,o=r.revealOrder,i=r.tail;if(lt(e,t,r.children,n),r=Re.current,r&2)r=r&1|2,t.flags|=128;else{if(e!==null&&e.flags&128)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&Ad(e,n,t);else if(e.tag===19)Ad(e,n,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;e.sibling===null;){if(e.return===null||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}r&=1}if(Ce(Re,r),!(t.mode&1))t.memoizedState=null;else switch(o){case"forwards":for(n=t.child,o=null;n!==null;)e=n.alternate,e!==null&&la(e)===null&&(o=n),n=n.sibling;n=o,n===null?(o=t.child,t.child=null):(o=n.sibling,n.sibling=null),Ks(t,!1,o,n,i);break;case"backwards":for(n=null,o=t.child,t.child=null;o!==null;){if(e=o.alternate,e!==null&&la(e)===null){t.child=o;break}e=o.sibling,o.sibling=n,n=o,o=e}Ks(t,!0,n,null,i);break;case"together":Ks(t,!1,null,null,void 0);break;default:t.memoizedState=null}return t.child}function Al(e,t){!(t.mode&1)&&e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2)}function On(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),Or|=t.lanes,!(n&t.childLanes))return null;if(e!==null&&t.child!==e.child)throw Error(F(153));if(t.child!==null){for(e=t.child,n=er(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=er(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function Ib(e,t,n){switch(t.tag){case 3:g0(t),po();break;case 5:Vy(t);break;case 1:mt(t.type)&&ea(t);break;case 4:kp(t,t.stateNode.containerInfo);break;case 10:var r=t.type._context,o=t.memoizedProps.value;Ce(ra,r._currentValue),r._currentValue=o;break;case 13:if(r=t.memoizedState,r!==null)return r.dehydrated!==null?(Ce(Re,Re.current&1),t.flags|=128,null):n&t.child.childLanes?y0(e,t,n):(Ce(Re,Re.current&1),e=On(e,t,n),e!==null?e.sibling:null);Ce(Re,Re.current&1);break;case 19:if(r=(n&t.childLanes)!==0,e.flags&128){if(r)return v0(e,t,n);t.flags|=128}if(o=t.memoizedState,o!==null&&(o.rendering=null,o.tail=null,o.lastEffect=null),Ce(Re,Re.current),r)break;return null;case 22:case 23:return t.lanes=0,h0(e,t,n)}return On(e,t,n)}var w0,cc,x0,b0;w0=function(e,t){for(var n=t.child;n!==null;){if(n.tag===5||n.tag===6)e.appendChild(n.stateNode);else if(n.tag!==4&&n.child!==null){n.child.return=n,n=n.child;continue}if(n===t)break;for(;n.sibling===null;){if(n.return===null||n.return===t)return;n=n.return}n.sibling.return=n.return,n=n.sibling}};cc=function(){};x0=function(e,t,n,r){var o=e.memoizedProps;if(o!==r){e=t.stateNode,xr(sn.current);var i=null;switch(n){case"input":o=Ru(e,o),r=Ru(e,r),i=[];break;case"select":o=De({},o,{value:void 0}),r=De({},r,{value:void 0}),i=[];break;case"textarea":o=zu(e,o),r=zu(e,r),i=[];break;default:typeof o.onClick!="function"&&typeof r.onClick=="function"&&(e.onclick=Zl)}Iu(n,r);var l;n=null;for(u in o)if(!r.hasOwnProperty(u)&&o.hasOwnProperty(u)&&o[u]!=null)if(u==="style"){var a=o[u];for(l in a)a.hasOwnProperty(l)&&(n||(n={}),n[l]="")}else u!=="dangerouslySetInnerHTML"&&u!=="children"&&u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&u!=="autoFocus"&&(si.hasOwnProperty(u)?i||(i=[]):(i=i||[]).push(u,null));for(u in r){var s=r[u];if(a=o!=null?o[u]:void 0,r.hasOwnProperty(u)&&s!==a&&(s!=null||a!=null))if(u==="style")if(a){for(l in a)!a.hasOwnProperty(l)||s&&s.hasOwnProperty(l)||(n||(n={}),n[l]="");for(l in s)s.hasOwnProperty(l)&&a[l]!==s[l]&&(n||(n={}),n[l]=s[l])}else n||(i||(i=[]),i.push(u,n)),n=s;else u==="dangerouslySetInnerHTML"?(s=s?s.__html:void 0,a=a?a.__html:void 0,s!=null&&a!==s&&(i=i||[]).push(u,s)):u==="children"?typeof s!="string"&&typeof s!="number"||(i=i||[]).push(u,""+s):u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&(si.hasOwnProperty(u)?(s!=null&&u==="onScroll"&&Oe("scroll",e),i||a===s||(i=[])):(i=i||[]).push(u,s))}n&&(i=i||[]).push("style",n);var u=i;(t.updateQueue=u)&&(t.flags|=4)}};b0=function(e,t,n,r){n!==r&&(t.flags|=4)};function jo(e,t){if(!$e)switch(e.tailMode){case"hidden":t=e.tail;for(var n=null;t!==null;)t.alternate!==null&&(n=t),t=t.sibling;n===null?e.tail=null:n.sibling=null;break;case"collapsed":n=e.tail;for(var r=null;n!==null;)n.alternate!==null&&(r=n),n=n.sibling;r===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:r.sibling=null}}function tt(e){var t=e.alternate!==null&&e.alternate.child===e.child,n=0,r=0;if(t)for(var o=e.child;o!==null;)n|=o.lanes|o.childLanes,r|=o.subtreeFlags&14680064,r|=o.flags&14680064,o.return=e,o=o.sibling;else for(o=e.child;o!==null;)n|=o.lanes|o.childLanes,r|=o.subtreeFlags,r|=o.flags,o.return=e,o=o.sibling;return e.subtreeFlags|=r,e.childLanes=n,t}function Fb(e,t,n){var r=t.pendingProps;switch(mp(t),t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return tt(t),null;case 1:return mt(t.type)&&Jl(),tt(t),null;case 3:return r=t.stateNode,ho(),Ae(ht),Ae(ot),Cp(),r.pendingContext&&(r.context=r.pendingContext,r.pendingContext=null),(e===null||e.child===null)&&(rl(t)?t.flags|=4:e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,Yt!==null&&(vc(Yt),Yt=null))),cc(e,t),tt(t),null;case 5:Sp(t);var o=xr(xi.current);if(n=t.type,e!==null&&t.stateNode!=null)x0(e,t,n,r,o),e.ref!==t.ref&&(t.flags|=512,t.flags|=2097152);else{if(!r){if(t.stateNode===null)throw Error(F(166));return tt(t),null}if(e=xr(sn.current),rl(t)){r=t.stateNode,n=t.type;var i=t.memoizedProps;switch(r[on]=t,r[vi]=i,e=(t.mode&1)!==0,n){case"dialog":Oe("cancel",r),Oe("close",r);break;case"iframe":case"object":case"embed":Oe("load",r);break;case"video":case"audio":for(o=0;o<\/script>",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=l.createElement(n,{is:r.is}):(e=l.createElement(n),n==="select"&&(l=e,r.multiple?l.multiple=!0:r.size&&(l.size=r.size))):e=l.createElementNS(e,n),e[on]=t,e[vi]=r,w0(e,t,!1,!1),t.stateNode=e;e:{switch(l=Fu(n,r),n){case"dialog":Oe("cancel",e),Oe("close",e),o=r;break;case"iframe":case"object":case"embed":Oe("load",e),o=r;break;case"video":case"audio":for(o=0;ogo&&(t.flags|=128,r=!0,jo(i,!1),t.lanes=4194304)}else{if(!r)if(e=la(l),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),jo(i,!0),i.tail===null&&i.tailMode==="hidden"&&!l.alternate&&!$e)return tt(t),null}else 2*Me()-i.renderingStartTime>go&&n!==1073741824&&(t.flags|=128,r=!0,jo(i,!1),t.lanes=4194304);i.isBackwards?(l.sibling=t.child,t.child=l):(n=i.last,n!==null?n.sibling=l:t.child=l,i.last=l)}return i.tail!==null?(t=i.tail,i.rendering=t,i.tail=t.sibling,i.renderingStartTime=Me(),t.sibling=null,n=Re.current,Ce(Re,r?n&1|2:n&1),t):(tt(t),null);case 22:case 23:return zp(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?wt&1073741824&&(tt(t),t.subtreeFlags&6&&(t.flags|=8192)):tt(t),null;case 24:return null;case 25:return null}throw Error(F(156,t.tag))}function jb(e,t){switch(mp(t),t.tag){case 1:return mt(t.type)&&Jl(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return ho(),Ae(ht),Ae(ot),Cp(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return Sp(t),null;case 13:if(Ae(Re),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(F(340));po()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return Ae(Re),null;case 4:return ho(),null;case 10:return wp(t.type._context),null;case 22:case 23:return zp(),null;case 24:return null;default:return null}}var ll=!1,nt=!1,Mb=typeof WeakSet=="function"?WeakSet:Set,V=null;function Zr(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){Ne(e,t,r)}else n.current=null}function pc(e,t,n){try{n()}catch(r){Ne(e,t,r)}}var $d=!1;function Bb(e,t){if(Yu=Ql,e=Ey(),dp(e)){if("selectionStart"in e)var n={start:e.selectionStart,end:e.selectionEnd};else e:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var o=r.anchorOffset,i=r.focusNode;r=r.focusOffset;try{n.nodeType,i.nodeType}catch{n=null;break e}var l=0,a=-1,s=-1,u=0,p=0,c=e,d=null;t:for(;;){for(var f;c!==n||o!==0&&c.nodeType!==3||(a=l+o),c!==i||r!==0&&c.nodeType!==3||(s=l+r),c.nodeType===3&&(l+=c.nodeValue.length),(f=c.firstChild)!==null;)d=c,c=f;for(;;){if(c===e)break t;if(d===n&&++u===o&&(a=l),d===i&&++p===r&&(s=l),(f=c.nextSibling)!==null)break;c=d,d=c.parentNode}c=f}n=a===-1||s===-1?null:{start:a,end:s}}else n=null}n=n||{start:0,end:0}}else n=null;for(Qu={focusedElem:e,selectionRange:n},Ql=!1,V=t;V!==null;)if(t=V,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,V=e;else for(;V!==null;){t=V;try{var h=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(h!==null){var m=h.memoizedProps,w=h.memoizedState,g=t.stateNode,y=g.getSnapshotBeforeUpdate(t.elementType===t.type?m:Gt(t.type,m),w);g.__reactInternalSnapshotBeforeUpdate=y}break;case 3:var v=t.stateNode.containerInfo;v.nodeType===1?v.textContent="":v.nodeType===9&&v.documentElement&&v.removeChild(v.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(F(163))}}catch(C){Ne(t,t.return,C)}if(e=t.sibling,e!==null){e.return=t.return,V=e;break}V=t.return}return h=$d,$d=!1,h}function ti(e,t,n){var r=t.updateQueue;if(r=r!==null?r.lastEffect:null,r!==null){var o=r=r.next;do{if((o.tag&e)===e){var i=o.destroy;o.destroy=void 0,i!==void 0&&pc(t,n,i)}o=o.next}while(o!==r)}}function Da(e,t){if(t=t.updateQueue,t=t!==null?t.lastEffect:null,t!==null){var n=t=t.next;do{if((n.tag&e)===e){var r=n.create;n.destroy=r()}n=n.next}while(n!==t)}}function fc(e){var t=e.ref;if(t!==null){var n=e.stateNode;switch(e.tag){case 5:e=n;break;default:e=n}typeof t=="function"?t(e):t.current=e}}function k0(e){var t=e.alternate;t!==null&&(e.alternate=null,k0(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[on],delete t[vi],delete t[Zu],delete t[Sb],delete t[Cb])),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function S0(e){return e.tag===5||e.tag===3||e.tag===4}function _d(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||S0(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function dc(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.nodeType===8?n.parentNode.insertBefore(e,t):n.insertBefore(e,t):(n.nodeType===8?(t=n.parentNode,t.insertBefore(e,n)):(t=n,t.appendChild(e)),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=Zl));else if(r!==4&&(e=e.child,e!==null))for(dc(e,t,n),e=e.sibling;e!==null;)dc(e,t,n),e=e.sibling}function hc(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(e=e.child,e!==null))for(hc(e,t,n),e=e.sibling;e!==null;)hc(e,t,n),e=e.sibling}var Ke=null,qt=!1;function Nn(e,t,n){for(n=n.child;n!==null;)C0(e,t,n),n=n.sibling}function C0(e,t,n){if(an&&typeof an.onCommitFiberUnmount=="function")try{an.onCommitFiberUnmount(Pa,n)}catch{}switch(n.tag){case 5:nt||Zr(n,t);case 6:var r=Ke,o=qt;Ke=null,Nn(e,t,n),Ke=r,qt=o,Ke!==null&&(qt?(e=Ke,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):Ke.removeChild(n.stateNode));break;case 18:Ke!==null&&(qt?(e=Ke,n=n.stateNode,e.nodeType===8?Hs(e.parentNode,n):e.nodeType===1&&Hs(e,n),di(e)):Hs(Ke,n.stateNode));break;case 4:r=Ke,o=qt,Ke=n.stateNode.containerInfo,qt=!0,Nn(e,t,n),Ke=r,qt=o;break;case 0:case 11:case 14:case 15:if(!nt&&(r=n.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){o=r=r.next;do{var i=o,l=i.destroy;i=i.tag,l!==void 0&&(i&2||i&4)&&pc(n,t,l),o=o.next}while(o!==r)}Nn(e,t,n);break;case 1:if(!nt&&(Zr(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(a){Ne(n,t,a)}Nn(e,t,n);break;case 21:Nn(e,t,n);break;case 22:n.mode&1?(nt=(r=nt)||n.memoizedState!==null,Nn(e,t,n),nt=r):Nn(e,t,n);break;default:Nn(e,t,n)}}function Rd(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new Mb),t.forEach(function(r){var o=Kb.bind(null,e,r);n.has(r)||(n.add(r),r.then(o,o))})}}function Ht(e,t){var n=t.deletions;if(n!==null)for(var r=0;ro&&(o=l),r&=~i}if(r=o,r=Me()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*Hb(r/1960))-r,10e?16:e,Gn===null)var r=!1;else{if(e=Gn,Gn=null,pa=0,me&6)throw Error(F(331));var o=me;for(me|=4,V=e.current;V!==null;){var i=V,l=i.child;if(V.flags&16){var a=i.deletions;if(a!==null){for(var s=0;sMe()-Lp?kr(e,0):Rp|=n),gt(e,t)}function R0(e,t){t===0&&(e.mode&1?(t=Xi,Xi<<=1,!(Xi&130023424)&&(Xi=4194304)):t=1);var n=st();e=Pn(e,t),e!==null&&(Ri(e,t,n),gt(e,n))}function Qb(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),R0(e,n)}function Kb(e,t){var n=0;switch(e.tag){case 13:var r=e.stateNode,o=e.memoizedState;o!==null&&(n=o.retryLane);break;case 19:r=e.stateNode;break;default:throw Error(F(314))}r!==null&&r.delete(t),R0(e,n)}var L0;L0=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||ht.current)dt=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return dt=!1,Ib(e,t,n);dt=!!(e.flags&131072)}else dt=!1,$e&&t.flags&1048576&&Ny(t,na,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;Al(e,t),e=t.pendingProps;var o=co(t,ot.current);io(t,n),o=Pp(null,t,r,e,o,n);var i=Op();return t.flags|=1,typeof o=="object"&&o!==null&&typeof o.render=="function"&&o.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,mt(r)?(i=!0,ea(t)):i=!1,t.memoizedState=o.state!==null&&o.state!==void 0?o.state:null,bp(t),o.updater=Ra,t.stateNode=o,o._reactInternals=t,oc(t,r,e,n),t=ac(null,t,r,!0,i,n)):(t.tag=0,$e&&i&&hp(t),lt(null,t,o,n),t=t.child),t;case 16:r=t.elementType;e:{switch(Al(e,t),e=t.pendingProps,o=r._init,r=o(r._payload),t.type=r,o=t.tag=Zb(r),e=Gt(r,e),o){case 0:t=lc(null,t,r,e,n);break e;case 1:t=Od(null,t,r,e,n);break e;case 11:t=Ed(null,t,r,e,n);break e;case 14:t=Pd(null,t,r,Gt(r.type,e),n);break e}throw Error(F(306,r,""))}return t;case 0:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:Gt(r,o),lc(e,t,r,o,n);case 1:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:Gt(r,o),Od(e,t,r,o,n);case 3:e:{if(g0(t),e===null)throw Error(F(387));r=t.pendingProps,i=t.memoizedState,o=i.element,My(e,t),ia(t,r,null,n);var l=t.memoizedState;if(r=l.element,i.isDehydrated)if(i={element:r,isDehydrated:!1,cache:l.cache,pendingSuspenseBoundaries:l.pendingSuspenseBoundaries,transitions:l.transitions},t.updateQueue.baseState=i,t.memoizedState=i,t.flags&256){o=mo(Error(F(423)),t),t=Td(e,t,r,n,o);break e}else if(r!==o){o=mo(Error(F(424)),t),t=Td(e,t,r,n,o);break e}else for(bt=Kn(t.stateNode.containerInfo.firstChild),kt=t,$e=!0,Yt=null,n=Wy(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(po(),r===o){t=On(e,t,n);break e}lt(e,t,r,n)}t=t.child}return t;case 5:return Vy(t),e===null&&tc(t),r=t.type,o=t.pendingProps,i=e!==null?e.memoizedProps:null,l=o.children,Ku(r,o)?l=null:i!==null&&Ku(r,i)&&(t.flags|=32),m0(e,t),lt(e,t,l,n),t.child;case 6:return e===null&&tc(t),null;case 13:return y0(e,t,n);case 4:return kp(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=fo(t,null,r,n):lt(e,t,r,n),t.child;case 11:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:Gt(r,o),Ed(e,t,r,o,n);case 7:return lt(e,t,t.pendingProps,n),t.child;case 8:return lt(e,t,t.pendingProps.children,n),t.child;case 12:return lt(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(r=t.type._context,o=t.pendingProps,i=t.memoizedProps,l=o.value,Ce(ra,r._currentValue),r._currentValue=l,i!==null)if(Jt(i.value,l)){if(i.children===o.children&&!ht.current){t=On(e,t,n);break e}}else for(i=t.child,i!==null&&(i.return=t);i!==null;){var a=i.dependencies;if(a!==null){l=i.child;for(var s=a.firstContext;s!==null;){if(s.context===r){if(i.tag===1){s=kn(-1,n&-n),s.tag=2;var u=i.updateQueue;if(u!==null){u=u.shared;var p=u.pending;p===null?s.next=s:(s.next=p.next,p.next=s),u.pending=s}}i.lanes|=n,s=i.alternate,s!==null&&(s.lanes|=n),nc(i.return,n,t),a.lanes|=n;break}s=s.next}}else if(i.tag===10)l=i.type===t.type?null:i.child;else if(i.tag===18){if(l=i.return,l===null)throw Error(F(341));l.lanes|=n,a=l.alternate,a!==null&&(a.lanes|=n),nc(l,n,t),l=i.sibling}else l=i.child;if(l!==null)l.return=i;else for(l=i;l!==null;){if(l===t){l=null;break}if(i=l.sibling,i!==null){i.return=l.return,l=i;break}l=l.return}i=l}lt(e,t,o.children,n),t=t.child}return t;case 9:return o=t.type,r=t.pendingProps.children,io(t,n),o=Nt(o),r=r(o),t.flags|=1,lt(e,t,r,n),t.child;case 14:return r=t.type,o=Gt(r,t.pendingProps),o=Gt(r.type,o),Pd(e,t,r,o,n);case 15:return d0(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:Gt(r,o),Al(e,t),t.tag=1,mt(r)?(e=!0,ea(t)):e=!1,io(t,n),Uy(t,r,o),oc(t,r,o,n),ac(null,t,r,!0,e,n);case 19:return v0(e,t,n);case 22:return h0(e,t,n)}throw Error(F(156,t.tag))};function D0(e,t){return ly(e,t)}function Xb(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Lt(e,t,n,r){return new Xb(e,t,n,r)}function Ip(e){return e=e.prototype,!(!e||!e.isReactComponent)}function Zb(e){if(typeof e=="function")return Ip(e)?1:0;if(e!=null){if(e=e.$$typeof,e===np)return 11;if(e===rp)return 14}return 2}function er(e,t){var n=e.alternate;return n===null?(n=Lt(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&14680064,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n}function Rl(e,t,n,r,o,i){var l=2;if(r=e,typeof e=="function")Ip(e)&&(l=1);else if(typeof e=="string")l=5;else e:switch(e){case Hr:return Sr(n.children,o,i,t);case tp:l=8,o|=8;break;case Tu:return e=Lt(12,n,t,o|2),e.elementType=Tu,e.lanes=i,e;case Au:return e=Lt(13,n,t,o),e.elementType=Au,e.lanes=i,e;case $u:return e=Lt(19,n,t,o),e.elementType=$u,e.lanes=i,e;case Hg:return Na(n,o,i,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case Bg:l=10;break e;case Ug:l=9;break e;case np:l=11;break e;case rp:l=14;break e;case Bn:l=16,r=null;break e}throw Error(F(130,e==null?e:typeof e,""))}return t=Lt(l,n,t,o),t.elementType=e,t.type=r,t.lanes=i,t}function Sr(e,t,n,r){return e=Lt(7,e,r,t),e.lanes=n,e}function Na(e,t,n,r){return e=Lt(22,e,r,t),e.elementType=Hg,e.lanes=n,e.stateNode={isHidden:!1},e}function Xs(e,t,n){return e=Lt(6,e,null,t),e.lanes=n,e}function Zs(e,t,n){return t=Lt(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function Jb(e,t,n,r,o){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=Rs(0),this.expirationTimes=Rs(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Rs(0),this.identifierPrefix=r,this.onRecoverableError=o,this.mutableSourceEagerHydrationData=null}function Fp(e,t,n,r,o,i,l,a,s){return e=new Jb(e,t,n,a,s),t===1?(t=1,i===!0&&(t|=8)):t=0,i=Lt(3,null,null,t),e.current=i,i.stateNode=e,i.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},bp(i),e}function ek(e,t,n){var r=3"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(F0)}catch(e){console.error(e)}}F0(),Ng.exports=Pt;var Ba=Ng.exports,Md=Ba;Pu.createRoot=Md.createRoot,Pu.hydrateRoot=Md.hydrateRoot;const ik='@import"https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap";*,:before,:after{box-sizing:border-box;border-width:0;border-style:solid;border-color:currentColor}:before,:after{--tw-content: ""}html{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji";font-feature-settings:normal;font-variation-settings:normal}body{margin:0;line-height:inherit}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}button,input,optgroup,select,textarea{font-family:inherit;font-feature-settings:inherit;font-variation-settings:inherit;font-size:100%;font-weight:inherit;line-height:inherit;color:inherit;margin:0;padding:0}button,select{text-transform:none}button,[type=button],[type=reset],[type=submit]{-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dl,dd,h1,h2,h3,h4,h5,h6,hr,figure,p,pre{margin:0}fieldset{margin:0;padding:0}legend{padding:0}ol,ul,menu{list-style:none;margin:0;padding:0}dialog{padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{opacity:1;color:#9ca3af}input::placeholder,textarea::placeholder{opacity:1;color:#9ca3af}button,[role=button]{cursor:pointer}:disabled{cursor:default}img,svg,video,canvas,audio,iframe,embed,object{display:block;vertical-align:middle}img,video{max-width:100%;height:auto}[hidden]{display:none}*{scrollbar-color:initial;scrollbar-width:initial}:root{--opencopilot-primary-clr: #703ea8;--opencopilot-accent-clr: #f8f7f8;--opencopilot-accnet-2-clr: #817f81;--opencopilot-primary-light-clr: rgba(0, 87, 255, .1)}*,:before,:after{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: }::backdrop{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: }.opencopilot-fixed{position:fixed}.opencopilot-absolute{position:absolute}.opencopilot-relative{position:relative}.opencopilot-inset-0{top:0;right:0;bottom:0;left:0}.opencopilot-bottom-0{bottom:0}.opencopilot-right-0{right:0}.opencopilot-top-0{top:0}.\\!opencopilot-z-\\[100000\\]{z-index:100000!important}.opencopilot-z-50{z-index:50}.opencopilot-z-\\[10000000\\]{z-index:10000000}.opencopilot-z-\\[100\\]{z-index:100}.opencopilot-z-\\[50000\\]{z-index:50000}.opencopilot-clear-both{clear:both}.opencopilot-m-0{margin:0}.opencopilot-mx-auto{margin-left:auto;margin-right:auto}.opencopilot-mb-3{margin-bottom:.75rem}.opencopilot-mb-auto{margin-bottom:auto}.opencopilot-mt-auto{margin-top:auto}.opencopilot-block{display:block}.opencopilot-flex{display:flex}.opencopilot-grid{display:grid}.opencopilot-hidden{display:none}.opencopilot-aspect-square{aspect-ratio:1 / 1}.opencopilot-h-7{height:1.75rem}.opencopilot-h-fit{height:-moz-fit-content;height:fit-content}.opencopilot-h-full{height:100%}.opencopilot-h-screen{height:100vh}.opencopilot-max-h-full{max-height:100%}.opencopilot-w-7{width:1.75rem}.opencopilot-w-fit{width:-moz-fit-content;width:fit-content}.opencopilot-w-full{width:100%}.opencopilot-w-screen{width:100vw}.opencopilot-min-w-fit{min-width:-moz-fit-content;min-width:fit-content}.opencopilot-max-w-\\[15rem\\]{max-width:15rem}.opencopilot-max-w-full{max-width:100%}.opencopilot-max-w-lg{max-width:32rem}.opencopilot-flex-1{flex:1 1 0%}.opencopilot-shrink-0{flex-shrink:0}.opencopilot-select-none{-webkit-user-select:none;-moz-user-select:none;user-select:none}.opencopilot-resize-none{resize:none}.opencopilot-flex-col{flex-direction:column}.opencopilot-flex-col-reverse{flex-direction:column-reverse}.opencopilot-flex-wrap{flex-wrap:wrap}.opencopilot-items-start{align-items:flex-start}.opencopilot-items-center{align-items:center}.opencopilot-justify-center{justify-content:center}.opencopilot-justify-between{justify-content:space-between}.opencopilot-gap-1{gap:.25rem}.opencopilot-gap-2{gap:.5rem}.opencopilot-gap-3{gap:.75rem}.opencopilot-gap-4{gap:1rem}.opencopilot-space-y-1>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.25rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.25rem * var(--tw-space-y-reverse))}.opencopilot-space-y-1\\.5>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.375rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.375rem * var(--tw-space-y-reverse))}.opencopilot-space-y-2>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.5rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.5rem * var(--tw-space-y-reverse))}.opencopilot-justify-self-end{justify-self:end}.opencopilot-overflow-auto{overflow:auto}.opencopilot-overflow-hidden{overflow:hidden}.opencopilot-overflow-x-auto{overflow-x:auto}.opencopilot-overflow-y-auto{overflow-y:auto}.opencopilot-overflow-x-hidden{overflow-x:hidden}.opencopilot-scroll-smooth{scroll-behavior:smooth}.opencopilot-whitespace-nowrap{white-space:nowrap}.opencopilot-whitespace-pre-wrap{white-space:pre-wrap}.opencopilot-rounded-2xl{border-radius:1rem}.opencopilot-rounded-full{border-radius:9999px}.opencopilot-rounded-lg{border-radius:.5rem}.opencopilot-rounded-md{border-radius:.375rem}.opencopilot-rounded-sm{border-radius:.125rem}.opencopilot-rounded-t-lg{border-top-left-radius:.5rem;border-top-right-radius:.5rem}.opencopilot-border{border-width:1px}.opencopilot-border-b{border-bottom-width:1px}.opencopilot-border-none{border-style:none}.opencopilot-border-primary-light{border-color:var(--opencopilot-primary-light-clr)}.opencopilot-border-rose-500{--tw-border-opacity: 1;border-color:rgb(244 63 94 / var(--tw-border-opacity))}.opencopilot-border-transparent{border-color:transparent}.opencopilot-border-b-black\\/10{border-bottom-color:#0000001a}.opencopilot-bg-accent{background-color:var(--opencopilot-accent-clr)}.opencopilot-bg-black\\/50{background-color:#00000080}.opencopilot-bg-primary{background-color:var(--opencopilot-primary-clr)}.opencopilot-bg-rose-500{--tw-bg-opacity: 1;background-color:rgb(244 63 94 / var(--tw-bg-opacity))}.opencopilot-bg-transparent{background-color:transparent}.opencopilot-bg-white{--tw-bg-opacity: 1;background-color:rgb(255 255 255 / var(--tw-bg-opacity))}.opencopilot-fill-current{fill:currentColor}.opencopilot-object-cover{-o-object-fit:cover;object-fit:cover}.opencopilot-p-0{padding:0}.opencopilot-p-0\\.5{padding:.125rem}.opencopilot-p-2{padding:.5rem}.opencopilot-p-3{padding:.75rem}.opencopilot-p-6{padding:1.5rem}.opencopilot-px-2{padding-left:.5rem;padding-right:.5rem}.opencopilot-px-2\\.5{padding-left:.625rem;padding-right:.625rem}.opencopilot-px-4{padding-left:1rem;padding-right:1rem}.opencopilot-py-1{padding-top:.25rem;padding-bottom:.25rem}.opencopilot-py-1\\.5{padding-top:.375rem;padding-bottom:.375rem}.opencopilot-py-2{padding-top:.5rem;padding-bottom:.5rem}.opencopilot-ps-10{padding-inline-start:2.5rem}.opencopilot-text-center{text-align:center}.opencopilot-font-inter{font-family:Inter,sans-serif,system-ui}.opencopilot-text-2xl{font-size:1.5rem;line-height:2rem}.opencopilot-text-\\[14px\\]{font-size:14px}.opencopilot-text-lg{font-size:1.125rem;line-height:1.75rem}.opencopilot-text-sm{font-size:.875rem;line-height:1.25rem}.opencopilot-text-xl{font-size:1.25rem;line-height:1.75rem}.opencopilot-text-xs{font-size:.75rem;line-height:1rem}.opencopilot-font-medium{font-weight:500}.opencopilot-font-normal{font-weight:400}.opencopilot-font-semibold{font-weight:600}.opencopilot-lowercase{text-transform:lowercase}.opencopilot-leading-none{line-height:1}.opencopilot-leading-tight{line-height:1.25}.opencopilot-tracking-tight{letter-spacing:-.025em}.opencopilot-text-\\[\\#5e5c5e\\]{--tw-text-opacity: 1;color:rgb(94 92 94 / var(--tw-text-opacity))}.opencopilot-text-accent{color:var(--opencopilot-accent-clr)}.opencopilot-text-accent2{color:var(--opencopilot-accent-2-clr)}.opencopilot-text-black{--tw-text-opacity: 1;color:rgb(0 0 0 / var(--tw-text-opacity))}.opencopilot-text-emerald-500{--tw-text-opacity: 1;color:rgb(16 185 129 / var(--tw-text-opacity))}.opencopilot-text-primary{color:var(--opencopilot-primary-clr)}.opencopilot-text-rose-500{--tw-text-opacity: 1;color:rgb(244 63 94 / var(--tw-text-opacity))}.opencopilot-text-white{--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity))}.opencopilot-opacity-0{opacity:0}.opencopilot-opacity-100{opacity:1}.opencopilot-shadow{--tw-shadow: 0 1px 3px 0 rgb(0 0 0 / .1), 0 1px 2px -1px rgb(0 0 0 / .1);--tw-shadow-colored: 0 1px 3px 0 var(--tw-shadow-color), 0 1px 2px -1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.opencopilot-shadow-lg{--tw-shadow: 0 10px 15px -3px rgb(0 0 0 / .1), 0 4px 6px -4px rgb(0 0 0 / .1);--tw-shadow-colored: 0 10px 15px -3px var(--tw-shadow-color), 0 4px 6px -4px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.opencopilot-shadow-none{--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.opencopilot-outline-none{outline:2px solid transparent;outline-offset:2px}.opencopilot-ring-1{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.opencopilot-ring-\\[\\#334155\\]\\/60{--tw-ring-color: rgb(51 65 85 / .6)}.opencopilot-backdrop-blur-sm{--tw-backdrop-blur: blur(4px);-webkit-backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia)}.opencopilot-transition-all{transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.opencopilot-transition-colors{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.opencopilot-transition-opacity{transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.opencopilot-transition-transform{transition-property:transform;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.opencopilot-duration-300{transition-duration:.3s}.opencopilot-ease-in{transition-timing-function:cubic-bezier(.4,0,1,1)}.opencopilot-ease-out{transition-timing-function:cubic-bezier(0,0,.2,1)}@keyframes enter{0%{opacity:var(--tw-enter-opacity, 1);transform:translate3d(var(--tw-enter-translate-x, 0),var(--tw-enter-translate-y, 0),0) scale3d(var(--tw-enter-scale, 1),var(--tw-enter-scale, 1),var(--tw-enter-scale, 1)) rotate(var(--tw-enter-rotate, 0))}}@keyframes exit{to{opacity:var(--tw-exit-opacity, 1);transform:translate3d(var(--tw-exit-translate-x, 0),var(--tw-exit-translate-y, 0),0) scale3d(var(--tw-exit-scale, 1),var(--tw-exit-scale, 1),var(--tw-exit-scale, 1)) rotate(var(--tw-exit-rotate, 0))}}.opencopilot-animate-in{animation-name:enter;animation-duration:.15s;--tw-enter-opacity: initial;--tw-enter-scale: initial;--tw-enter-rotate: initial;--tw-enter-translate-x: initial;--tw-enter-translate-y: initial}.opencopilot-animate-out{animation-name:exit;animation-duration:.15s;--tw-exit-opacity: initial;--tw-exit-scale: initial;--tw-exit-rotate: initial;--tw-exit-translate-x: initial;--tw-exit-translate-y: initial}.opencopilot-fade-in,.opencopilot-fade-in-0{--tw-enter-opacity: 0}.opencopilot-fade-out{--tw-exit-opacity: 0}.opencopilot-slide-in-from-bottom-5{--tw-enter-translate-y: 1.25rem}.opencopilot-slide-in-from-top-1{--tw-enter-translate-y: -.25rem}.opencopilot-duration-300{animation-duration:.3s}.opencopilot-ease-in{animation-timing-function:cubic-bezier(.4,0,1,1)}.opencopilot-ease-out{animation-timing-function:cubic-bezier(0,0,.2,1)}.opencopilot-scrollbar-thin{scrollbar-color:var(--scrollbar-thumb, initial) var(--scrollbar-track, initial)}.opencopilot-scrollbar-thin::-webkit-scrollbar-track{background-color:var(--scrollbar-track);border-radius:var(--scrollbar-track-radius)}.opencopilot-scrollbar-thin::-webkit-scrollbar-track:hover{background-color:var(--scrollbar-track-hover, var(--scrollbar-track))}.opencopilot-scrollbar-thin::-webkit-scrollbar-track:active{background-color:var(--scrollbar-track-active, var(--scrollbar-track-hover, var(--scrollbar-track)))}.opencopilot-scrollbar-thin::-webkit-scrollbar-thumb{background-color:var(--scrollbar-thumb);border-radius:var(--scrollbar-thumb-radius)}.opencopilot-scrollbar-thin::-webkit-scrollbar-thumb:hover{background-color:var(--scrollbar-thumb-hover, var(--scrollbar-thumb))}.opencopilot-scrollbar-thin::-webkit-scrollbar-thumb:active{background-color:var(--scrollbar-thumb-active, var(--scrollbar-thumb-hover, var(--scrollbar-thumb)))}.opencopilot-scrollbar-thin::-webkit-scrollbar-corner{background-color:var(--scrollbar-corner);border-radius:var(--scrollbar-corner-radius)}.opencopilot-scrollbar-thin::-webkit-scrollbar-corner:hover{background-color:var(--scrollbar-corner-hover, var(--scrollbar-corner))}.opencopilot-scrollbar-thin::-webkit-scrollbar-corner:active{background-color:var(--scrollbar-corner-active, var(--scrollbar-corner-hover, var(--scrollbar-corner)))}.opencopilot-scrollbar-thin{scrollbar-width:thin}.opencopilot-scrollbar-thin::-webkit-scrollbar{display:block;width:8px;height:8px}.opencopilot-prose{color:var(--tw-prose-body);max-width:65ch}.opencopilot-prose :where(p):not(:where([class~=opencopilot-not-prose] *)){margin-top:1.25em;margin-bottom:1.25em}.opencopilot-prose :where([class~=lead]):not(:where([class~=opencopilot-not-prose] *)){color:var(--tw-prose-lead);font-size:1.25em;line-height:1.6;margin-top:1.2em;margin-bottom:1.2em}.opencopilot-prose :where(a):not(:where([class~=opencopilot-not-prose] *)){color:var(--tw-prose-links);text-decoration:underline;font-weight:500}.opencopilot-prose :where(strong):not(:where([class~=opencopilot-not-prose] *)){color:var(--tw-prose-bold);font-weight:600}.opencopilot-prose :where(a strong):not(:where([class~=opencopilot-not-prose] *)){color:inherit}.opencopilot-prose :where(blockquote strong):not(:where([class~=opencopilot-not-prose] *)){color:inherit}.opencopilot-prose :where(thead th strong):not(:where([class~=opencopilot-not-prose] *)){color:inherit}.opencopilot-prose :where(ol):not(:where([class~=opencopilot-not-prose] *)){list-style-type:decimal;margin-top:1.25em;margin-bottom:1.25em;padding-left:1.625em}.opencopilot-prose :where(ol[type=A]):not(:where([class~=opencopilot-not-prose] *)){list-style-type:upper-alpha}.opencopilot-prose :where(ol[type=a]):not(:where([class~=opencopilot-not-prose] *)){list-style-type:lower-alpha}.opencopilot-prose :where(ol[type=A s]):not(:where([class~=opencopilot-not-prose] *)){list-style-type:upper-alpha}.opencopilot-prose :where(ol[type=a s]):not(:where([class~=opencopilot-not-prose] *)){list-style-type:lower-alpha}.opencopilot-prose :where(ol[type=I]):not(:where([class~=opencopilot-not-prose] *)){list-style-type:upper-roman}.opencopilot-prose :where(ol[type=i]):not(:where([class~=opencopilot-not-prose] *)){list-style-type:lower-roman}.opencopilot-prose :where(ol[type=I s]):not(:where([class~=opencopilot-not-prose] *)){list-style-type:upper-roman}.opencopilot-prose :where(ol[type=i s]):not(:where([class~=opencopilot-not-prose] *)){list-style-type:lower-roman}.opencopilot-prose :where(ol[type="1"]):not(:where([class~=opencopilot-not-prose] *)){list-style-type:decimal}.opencopilot-prose :where(ul):not(:where([class~=opencopilot-not-prose] *)){list-style-type:disc;margin-top:1.25em;margin-bottom:1.25em;padding-left:1.625em}.opencopilot-prose :where(ol>li):not(:where([class~=opencopilot-not-prose] *))::marker{font-weight:400;color:var(--tw-prose-counters)}.opencopilot-prose :where(ul>li):not(:where([class~=opencopilot-not-prose] *))::marker{color:var(--tw-prose-bullets)}.opencopilot-prose :where(hr):not(:where([class~=opencopilot-not-prose] *)){border-color:var(--tw-prose-hr);border-top-width:1px;margin-top:3em;margin-bottom:3em}.opencopilot-prose :where(blockquote):not(:where([class~=opencopilot-not-prose] *)){font-weight:500;font-style:italic;color:var(--tw-prose-quotes);border-left-width:.25rem;border-left-color:var(--tw-prose-quote-borders);quotes:"“""”""‘""’";margin-top:1.6em;margin-bottom:1.6em;padding-left:1em}.opencopilot-prose :where(blockquote p:first-of-type):not(:where([class~=opencopilot-not-prose] *)):before{content:open-quote}.opencopilot-prose :where(blockquote p:last-of-type):not(:where([class~=opencopilot-not-prose] *)):after{content:close-quote}.opencopilot-prose :where(h1):not(:where([class~=opencopilot-not-prose] *)){color:var(--tw-prose-headings);font-weight:800;font-size:2.25em;margin-top:0;margin-bottom:.8888889em;line-height:1.1111111}.opencopilot-prose :where(h1 strong):not(:where([class~=opencopilot-not-prose] *)){font-weight:900;color:inherit}.opencopilot-prose :where(h2):not(:where([class~=opencopilot-not-prose] *)){color:var(--tw-prose-headings);font-weight:700;font-size:1.5em;margin-top:2em;margin-bottom:1em;line-height:1.3333333}.opencopilot-prose :where(h2 strong):not(:where([class~=opencopilot-not-prose] *)){font-weight:800;color:inherit}.opencopilot-prose :where(h3):not(:where([class~=opencopilot-not-prose] *)){color:var(--tw-prose-headings);font-weight:600;font-size:1.25em;margin-top:1.6em;margin-bottom:.6em;line-height:1.6}.opencopilot-prose :where(h3 strong):not(:where([class~=opencopilot-not-prose] *)){font-weight:700;color:inherit}.opencopilot-prose :where(h4):not(:where([class~=opencopilot-not-prose] *)){color:var(--tw-prose-headings);font-weight:600;margin-top:1.5em;margin-bottom:.5em;line-height:1.5}.opencopilot-prose :where(h4 strong):not(:where([class~=opencopilot-not-prose] *)){font-weight:700;color:inherit}.opencopilot-prose :where(img):not(:where([class~=opencopilot-not-prose] *)){margin-top:2em;margin-bottom:2em}.opencopilot-prose :where(figure>*):not(:where([class~=opencopilot-not-prose] *)){margin-top:0;margin-bottom:0}.opencopilot-prose :where(figcaption):not(:where([class~=opencopilot-not-prose] *)){color:var(--tw-prose-captions);font-size:.875em;line-height:1.4285714;margin-top:.8571429em}.opencopilot-prose :where(code):not(:where([class~=opencopilot-not-prose] *)){color:var(--tw-prose-code);font-weight:600;font-size:.875em}.opencopilot-prose :where(code):not(:where([class~=opencopilot-not-prose] *)):before{content:"`"}.opencopilot-prose :where(code):not(:where([class~=opencopilot-not-prose] *)):after{content:"`"}.opencopilot-prose :where(a code):not(:where([class~=opencopilot-not-prose] *)){color:inherit}.opencopilot-prose :where(h1 code):not(:where([class~=opencopilot-not-prose] *)){color:inherit}.opencopilot-prose :where(h2 code):not(:where([class~=opencopilot-not-prose] *)){color:inherit;font-size:.875em}.opencopilot-prose :where(h3 code):not(:where([class~=opencopilot-not-prose] *)){color:inherit;font-size:.9em}.opencopilot-prose :where(h4 code):not(:where([class~=opencopilot-not-prose] *)){color:inherit}.opencopilot-prose :where(blockquote code):not(:where([class~=opencopilot-not-prose] *)){color:inherit}.opencopilot-prose :where(thead th code):not(:where([class~=opencopilot-not-prose] *)){color:inherit}.opencopilot-prose :where(pre):not(:where([class~=opencopilot-not-prose] *)){color:var(--tw-prose-pre-code);background-color:var(--tw-prose-pre-bg);overflow-x:auto;font-weight:400;font-size:.875em;line-height:1.7142857;margin-top:1.7142857em;margin-bottom:1.7142857em;border-radius:.375rem;padding:.8571429em 1.1428571em}.opencopilot-prose :where(pre code):not(:where([class~=opencopilot-not-prose] *)){background-color:transparent;border-width:0;border-radius:0;padding:0;font-weight:inherit;color:inherit;font-size:inherit;font-family:inherit;line-height:inherit}.opencopilot-prose :where(pre code):not(:where([class~=opencopilot-not-prose] *)):before{content:none}.opencopilot-prose :where(pre code):not(:where([class~=opencopilot-not-prose] *)):after{content:none}.opencopilot-prose :where(table):not(:where([class~=opencopilot-not-prose] *)){width:100%;table-layout:auto;text-align:left;margin-top:2em;margin-bottom:2em;font-size:.875em;line-height:1.7142857}.opencopilot-prose :where(thead):not(:where([class~=opencopilot-not-prose] *)){border-bottom-width:1px;border-bottom-color:var(--tw-prose-th-borders)}.opencopilot-prose :where(thead th):not(:where([class~=opencopilot-not-prose] *)){color:var(--tw-prose-headings);font-weight:600;vertical-align:bottom;padding-right:.5714286em;padding-bottom:.5714286em;padding-left:.5714286em}.opencopilot-prose :where(tbody tr):not(:where([class~=opencopilot-not-prose] *)){border-bottom-width:1px;border-bottom-color:var(--tw-prose-td-borders)}.opencopilot-prose :where(tbody tr:last-child):not(:where([class~=opencopilot-not-prose] *)){border-bottom-width:0}.opencopilot-prose :where(tbody td):not(:where([class~=opencopilot-not-prose] *)){vertical-align:baseline}.opencopilot-prose :where(tfoot):not(:where([class~=opencopilot-not-prose] *)){border-top-width:1px;border-top-color:var(--tw-prose-th-borders)}.opencopilot-prose :where(tfoot td):not(:where([class~=opencopilot-not-prose] *)){vertical-align:top}.opencopilot-prose{--tw-prose-body: #374151;--tw-prose-headings: #111827;--tw-prose-lead: #4b5563;--tw-prose-links: #111827;--tw-prose-bold: #111827;--tw-prose-counters: #6b7280;--tw-prose-bullets: #d1d5db;--tw-prose-hr: #e5e7eb;--tw-prose-quotes: #111827;--tw-prose-quote-borders: #e5e7eb;--tw-prose-captions: #6b7280;--tw-prose-code: #111827;--tw-prose-pre-code: #e5e7eb;--tw-prose-pre-bg: #1f2937;--tw-prose-th-borders: #d1d5db;--tw-prose-td-borders: #e5e7eb;--tw-prose-invert-body: #d1d5db;--tw-prose-invert-headings: #fff;--tw-prose-invert-lead: #9ca3af;--tw-prose-invert-links: #fff;--tw-prose-invert-bold: #fff;--tw-prose-invert-counters: #9ca3af;--tw-prose-invert-bullets: #4b5563;--tw-prose-invert-hr: #374151;--tw-prose-invert-quotes: #f3f4f6;--tw-prose-invert-quote-borders: #374151;--tw-prose-invert-captions: #9ca3af;--tw-prose-invert-code: #fff;--tw-prose-invert-pre-code: #d1d5db;--tw-prose-invert-pre-bg: rgb(0 0 0 / 50%);--tw-prose-invert-th-borders: #4b5563;--tw-prose-invert-td-borders: #374151;font-size:1rem;line-height:1.75}.opencopilot-prose :where(video):not(:where([class~=opencopilot-not-prose] *)){margin-top:2em;margin-bottom:2em}.opencopilot-prose :where(figure):not(:where([class~=opencopilot-not-prose] *)){margin-top:2em;margin-bottom:2em}.opencopilot-prose :where(li):not(:where([class~=opencopilot-not-prose] *)){margin-top:.5em;margin-bottom:.5em}.opencopilot-prose :where(ol>li):not(:where([class~=opencopilot-not-prose] *)){padding-left:.375em}.opencopilot-prose :where(ul>li):not(:where([class~=opencopilot-not-prose] *)){padding-left:.375em}.opencopilot-prose :where(.opencopilot-prose>ul>li p):not(:where([class~=opencopilot-not-prose] *)){margin-top:.75em;margin-bottom:.75em}.opencopilot-prose :where(.opencopilot-prose>ul>li>*:first-child):not(:where([class~=opencopilot-not-prose] *)){margin-top:1.25em}.opencopilot-prose :where(.opencopilot-prose>ul>li>*:last-child):not(:where([class~=opencopilot-not-prose] *)){margin-bottom:1.25em}.opencopilot-prose :where(.opencopilot-prose>ol>li>*:first-child):not(:where([class~=opencopilot-not-prose] *)){margin-top:1.25em}.opencopilot-prose :where(.opencopilot-prose>ol>li>*:last-child):not(:where([class~=opencopilot-not-prose] *)){margin-bottom:1.25em}.opencopilot-prose :where(ul ul,ul ol,ol ul,ol ol):not(:where([class~=opencopilot-not-prose] *)){margin-top:.75em;margin-bottom:.75em}.opencopilot-prose :where(hr+*):not(:where([class~=opencopilot-not-prose] *)){margin-top:0}.opencopilot-prose :where(h2+*):not(:where([class~=opencopilot-not-prose] *)){margin-top:0}.opencopilot-prose :where(h3+*):not(:where([class~=opencopilot-not-prose] *)){margin-top:0}.opencopilot-prose :where(h4+*):not(:where([class~=opencopilot-not-prose] *)){margin-top:0}.opencopilot-prose :where(thead th:first-child):not(:where([class~=opencopilot-not-prose] *)){padding-left:0}.opencopilot-prose :where(thead th:last-child):not(:where([class~=opencopilot-not-prose] *)){padding-right:0}.opencopilot-prose :where(tbody td,tfoot td):not(:where([class~=opencopilot-not-prose] *)){padding:.5714286em}.opencopilot-prose :where(tbody td:first-child,tfoot td:first-child):not(:where([class~=opencopilot-not-prose] *)){padding-left:0}.opencopilot-prose :where(tbody td:last-child,tfoot td:last-child):not(:where([class~=opencopilot-not-prose] *)){padding-right:0}.opencopilot-prose :where(.opencopilot-prose>:first-child):not(:where([class~=opencopilot-not-prose] *)){margin-top:0}.opencopilot-prose :where(.opencopilot-prose>:last-child):not(:where([class~=opencopilot-not-prose] *)){margin-bottom:0}.opencopilot-prose-sm{font-size:.875rem;line-height:1.7142857}.opencopilot-prose-sm :where(p):not(:where([class~=opencopilot-not-prose] *)){margin-top:1.1428571em;margin-bottom:1.1428571em}.opencopilot-prose-sm :where([class~=lead]):not(:where([class~=opencopilot-not-prose] *)){font-size:1.2857143em;line-height:1.5555556;margin-top:.8888889em;margin-bottom:.8888889em}.opencopilot-prose-sm :where(blockquote):not(:where([class~=opencopilot-not-prose] *)){margin-top:1.3333333em;margin-bottom:1.3333333em;padding-left:1.1111111em}.opencopilot-prose-sm :where(h1):not(:where([class~=opencopilot-not-prose] *)){font-size:2.1428571em;margin-top:0;margin-bottom:.8em;line-height:1.2}.opencopilot-prose-sm :where(h2):not(:where([class~=opencopilot-not-prose] *)){font-size:1.4285714em;margin-top:1.6em;margin-bottom:.8em;line-height:1.4}.opencopilot-prose-sm :where(h3):not(:where([class~=opencopilot-not-prose] *)){font-size:1.2857143em;margin-top:1.5555556em;margin-bottom:.4444444em;line-height:1.5555556}.opencopilot-prose-sm :where(h4):not(:where([class~=opencopilot-not-prose] *)){margin-top:1.4285714em;margin-bottom:.5714286em;line-height:1.4285714}.opencopilot-prose-sm :where(img):not(:where([class~=opencopilot-not-prose] *)){margin-top:1.7142857em;margin-bottom:1.7142857em}.opencopilot-prose-sm :where(video):not(:where([class~=opencopilot-not-prose] *)){margin-top:1.7142857em;margin-bottom:1.7142857em}.opencopilot-prose-sm :where(figure):not(:where([class~=opencopilot-not-prose] *)){margin-top:1.7142857em;margin-bottom:1.7142857em}.opencopilot-prose-sm :where(figure>*):not(:where([class~=opencopilot-not-prose] *)){margin-top:0;margin-bottom:0}.opencopilot-prose-sm :where(figcaption):not(:where([class~=opencopilot-not-prose] *)){font-size:.8571429em;line-height:1.3333333;margin-top:.6666667em}.opencopilot-prose-sm :where(code):not(:where([class~=opencopilot-not-prose] *)){font-size:.8571429em}.opencopilot-prose-sm :where(h2 code):not(:where([class~=opencopilot-not-prose] *)){font-size:.9em}.opencopilot-prose-sm :where(h3 code):not(:where([class~=opencopilot-not-prose] *)){font-size:.8888889em}.opencopilot-prose-sm :where(pre):not(:where([class~=opencopilot-not-prose] *)){font-size:.8571429em;line-height:1.6666667;margin-top:1.6666667em;margin-bottom:1.6666667em;border-radius:.25rem;padding:.6666667em 1em}.opencopilot-prose-sm :where(ol):not(:where([class~=opencopilot-not-prose] *)){margin-top:1.1428571em;margin-bottom:1.1428571em;padding-left:1.5714286em}.opencopilot-prose-sm :where(ul):not(:where([class~=opencopilot-not-prose] *)){margin-top:1.1428571em;margin-bottom:1.1428571em;padding-left:1.5714286em}.opencopilot-prose-sm :where(li):not(:where([class~=opencopilot-not-prose] *)){margin-top:.2857143em;margin-bottom:.2857143em}.opencopilot-prose-sm :where(ol>li):not(:where([class~=opencopilot-not-prose] *)){padding-left:.4285714em}.opencopilot-prose-sm :where(ul>li):not(:where([class~=opencopilot-not-prose] *)){padding-left:.4285714em}.opencopilot-prose-sm :where(.opencopilot-prose-sm>ul>li p):not(:where([class~=opencopilot-not-prose] *)){margin-top:.5714286em;margin-bottom:.5714286em}.opencopilot-prose-sm :where(.opencopilot-prose-sm>ul>li>*:first-child):not(:where([class~=opencopilot-not-prose] *)){margin-top:1.1428571em}.opencopilot-prose-sm :where(.opencopilot-prose-sm>ul>li>*:last-child):not(:where([class~=opencopilot-not-prose] *)){margin-bottom:1.1428571em}.opencopilot-prose-sm :where(.opencopilot-prose-sm>ol>li>*:first-child):not(:where([class~=opencopilot-not-prose] *)){margin-top:1.1428571em}.opencopilot-prose-sm :where(.opencopilot-prose-sm>ol>li>*:last-child):not(:where([class~=opencopilot-not-prose] *)){margin-bottom:1.1428571em}.opencopilot-prose-sm :where(ul ul,ul ol,ol ul,ol ol):not(:where([class~=opencopilot-not-prose] *)){margin-top:.5714286em;margin-bottom:.5714286em}.opencopilot-prose-sm :where(hr):not(:where([class~=opencopilot-not-prose] *)){margin-top:2.8571429em;margin-bottom:2.8571429em}.opencopilot-prose-sm :where(hr+*):not(:where([class~=opencopilot-not-prose] *)){margin-top:0}.opencopilot-prose-sm :where(h2+*):not(:where([class~=opencopilot-not-prose] *)){margin-top:0}.opencopilot-prose-sm :where(h3+*):not(:where([class~=opencopilot-not-prose] *)){margin-top:0}.opencopilot-prose-sm :where(h4+*):not(:where([class~=opencopilot-not-prose] *)){margin-top:0}.opencopilot-prose-sm :where(table):not(:where([class~=opencopilot-not-prose] *)){font-size:.8571429em;line-height:1.5}.opencopilot-prose-sm :where(thead th):not(:where([class~=opencopilot-not-prose] *)){padding-right:1em;padding-bottom:.6666667em;padding-left:1em}.opencopilot-prose-sm :where(thead th:first-child):not(:where([class~=opencopilot-not-prose] *)){padding-left:0}.opencopilot-prose-sm :where(thead th:last-child):not(:where([class~=opencopilot-not-prose] *)){padding-right:0}.opencopilot-prose-sm :where(tbody td,tfoot td):not(:where([class~=opencopilot-not-prose] *)){padding:.6666667em 1em}.opencopilot-prose-sm :where(tbody td:first-child,tfoot td:first-child):not(:where([class~=opencopilot-not-prose] *)){padding-left:0}.opencopilot-prose-sm :where(tbody td:last-child,tfoot td:last-child):not(:where([class~=opencopilot-not-prose] *)){padding-right:0}.opencopilot-prose-sm :where(.opencopilot-prose-sm>:first-child):not(:where([class~=opencopilot-not-prose] *)){margin-top:0}.opencopilot-prose-sm :where(.opencopilot-prose-sm>:last-child):not(:where([class~=opencopilot-not-prose] *)){margin-bottom:0}.opencopilot-prose-slate{--tw-prose-body: #334155;--tw-prose-headings: #0f172a;--tw-prose-lead: #475569;--tw-prose-links: #0f172a;--tw-prose-bold: #0f172a;--tw-prose-counters: #64748b;--tw-prose-bullets: #cbd5e1;--tw-prose-hr: #e2e8f0;--tw-prose-quotes: #0f172a;--tw-prose-quote-borders: #e2e8f0;--tw-prose-captions: #64748b;--tw-prose-code: #0f172a;--tw-prose-pre-code: #e2e8f0;--tw-prose-pre-bg: #1e293b;--tw-prose-th-borders: #cbd5e1;--tw-prose-td-borders: #e2e8f0;--tw-prose-invert-body: #cbd5e1;--tw-prose-invert-headings: #fff;--tw-prose-invert-lead: #94a3b8;--tw-prose-invert-links: #fff;--tw-prose-invert-bold: #fff;--tw-prose-invert-counters: #94a3b8;--tw-prose-invert-bullets: #475569;--tw-prose-invert-hr: #334155;--tw-prose-invert-quotes: #f1f5f9;--tw-prose-invert-quote-borders: #334155;--tw-prose-invert-captions: #94a3b8;--tw-prose-invert-code: #fff;--tw-prose-invert-pre-code: #cbd5e1;--tw-prose-invert-pre-bg: rgb(0 0 0 / 50%);--tw-prose-invert-th-borders: #475569;--tw-prose-invert-td-borders: #334155}@keyframes fade-in-bottom{0%{transform:translateY(50px);opacity:0}to{transform:translateY(0);opacity:1}}.fade-in-bottom{animation:fade-in-bottom .4s cubic-bezier(.39,.575,.565,1) both}.flex-center{display:flex;align-items:center;justify-content:center}@keyframes fade-in-top{0%{transform:translateY(-50px);opacity:0}to{transform:translateY(0);opacity:1}}.fade-in-top{animation:fade-in-top .6s cubic-bezier(.39,.575,.565,1) both}@keyframes fade-in{0%{opacity:0}to{opacity:1}}.fade-in{animation:fade-in 1.2s cubic-bezier(.39,.575,.565,1) both}em-emoji-picker{--background-rgb: 85, 170, 255;--border-radius: 10px;--category-icon-size: 24px;--font-family: inherit;--font-size: 14px;min-height:250px;max-height:300px}.PopoverContent{transform-origin:var(--radix-popover-content-transform-origin);animation:scaleIn .5s ease-out}@keyframes scaleIn{0%{opacity:0;transform:scale(0)}to{opacity:1;transform:scale(1)}}.PopoverContent{animation-duration:.6s;animation-timing-function:cubic-bezier(.16,1,.3,1)}.PopoverContent[data-side=top]{animation-name:slideUp}.PopoverContent[data-side=bottom]{animation-name:slideDown}@keyframes slideDown{0%{opacity:0;transform:translateY(-10px)}to{opacity:1;transform:translateY(0)}}@keyframes slideUp{0%{opacity:0;transform:translateY(10px)}to{opacity:1;transform:translateY(0)}}@keyframes fade-in-right{0%{transform:translate(50px);opacity:0}to{transform:translate(0);opacity:1}}.fade-in-right{animation:fade-in-right .6s both}@keyframes scale-out-br{0%{transform:scale(1);transform-origin:100% 100%;opacity:1}to{transform:scale(0);transform-origin:100% 100%;opacity:1}}.scale-out-br{animation:scale-out-br .5s ease-in-out forwards}.placeholder\\:opencopilot-align-middle::-moz-placeholder{vertical-align:middle}.placeholder\\:opencopilot-align-middle::placeholder{vertical-align:middle}.placeholder\\:opencopilot-text-xs::-moz-placeholder{font-size:.75rem;line-height:1rem}.placeholder\\:opencopilot-text-xs::placeholder{font-size:.75rem;line-height:1rem}.last-of-type\\:opencopilot-mb-10:last-of-type{margin-bottom:2.5rem}.focus-within\\:opencopilot-ring-primary:focus-within{--tw-ring-color: var(--opencopilot-primary-clr)}.data-\\[state\\=open\\]\\:opencopilot-animate-in[data-state=open]{animation-name:enter;animation-duration:.15s;--tw-enter-opacity: initial;--tw-enter-scale: initial;--tw-enter-rotate: initial;--tw-enter-translate-x: initial;--tw-enter-translate-y: initial}.data-\\[state\\=closed\\]\\:opencopilot-animate-out[data-state=closed]{animation-name:exit;animation-duration:.15s;--tw-exit-opacity: initial;--tw-exit-scale: initial;--tw-exit-rotate: initial;--tw-exit-translate-x: initial;--tw-exit-translate-y: initial}.data-\\[state\\=closed\\]\\:opencopilot-fade-out-0[data-state=closed]{--tw-exit-opacity: 0}.data-\\[state\\=open\\]\\:opencopilot-fade-in-0[data-state=open]{--tw-enter-opacity: 0}.data-\\[state\\=closed\\]\\:opencopilot-slide-in-from-top-0[data-state=closed]{--tw-enter-translate-y: -0px}.data-\\[state\\=open\\]\\:opencopilot-slide-in-from-bottom[data-state=open]{--tw-enter-translate-y: 100%}.prose-headings\\:opencopilot-my-1 :is(:where(h1,h2,h3,h4,h5,h6,th):not(:where([class~=opencopilot-not-prose] *))){margin-top:.25rem;margin-bottom:.25rem}.prose-h1\\:opencopilot-font-medium :is(:where(h1):not(:where([class~=opencopilot-not-prose] *))){font-weight:500}.prose-h2\\:opencopilot-font-normal :is(:where(h2):not(:where([class~=opencopilot-not-prose] *))){font-weight:400}.hover\\:opencopilot-scale-110:hover{--tw-scale-x: 1.1;--tw-scale-y: 1.1;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.hover\\:opencopilot-shadow:hover{--tw-shadow: 0 1px 3px 0 rgb(0 0 0 / .1), 0 1px 2px -1px rgb(0 0 0 / .1);--tw-shadow-colored: 0 1px 3px 0 var(--tw-shadow-color), 0 1px 2px -1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.focus\\:opencopilot-border-none:focus{border-style:none}.focus\\:opencopilot-outline-none:focus{outline:2px solid transparent;outline-offset:2px}.focus-visible\\:opencopilot-outline-none:focus-visible{outline:2px solid transparent;outline-offset:2px}.disabled\\:opencopilot-pointer-events-none:disabled{pointer-events:none}.disabled\\:opencopilot-cursor-not-allowed:disabled{cursor:not-allowed}.disabled\\:opencopilot-opacity-40:disabled{opacity:.4}@media (min-width: 640px){.sm\\:opencopilot-w-96{width:24rem}.sm\\:opencopilot-flex-row{flex-direction:row}.sm\\:opencopilot-justify-end{justify-content:flex-end}.sm\\:opencopilot-space-x-2>:not([hidden])~:not([hidden]){--tw-space-x-reverse: 0;margin-right:calc(.5rem * var(--tw-space-x-reverse));margin-left:calc(.5rem * calc(1 - var(--tw-space-x-reverse)))}.sm\\:opencopilot-rounded-xl{border-radius:.75rem}.sm\\:opencopilot-text-left{text-align:left}}\n',j0=x.createContext(void 0);function lk({children:e,data:t}){return L.jsx(j0.Provider,{value:t,children:e})}function Ua(){const e=x.useContext(j0);if(!e)throw new Error("useConfigData must be used within a ConfigDataProvider");return e}function ak(e){const[t,n]=x.useState(!!e),r=x.useCallback(()=>n(o=>!o),[]);return[t,r,n]}const M0=x.createContext(void 0);function B0(){const e=x.useContext(M0);if(!e)throw new Error("useAppContext must be used within an AppProvider");return e}function sk({children:e}){const t=ak(!1);return L.jsx(M0.Provider,{value:t,children:e})}function U0(e,t){return function(){return e.apply(t,arguments)}}const{toString:uk}=Object.prototype,{getPrototypeOf:Up}=Object,Ha=(e=>t=>{const n=uk.call(t);return e[n]||(e[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),pn=e=>(e=e.toLowerCase(),t=>Ha(t)===e),Wa=e=>t=>typeof t===e,{isArray:Eo}=Array,Ei=Wa("undefined");function ck(e){return e!==null&&!Ei(e)&&e.constructor!==null&&!Ei(e.constructor)&&zt(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const H0=pn("ArrayBuffer");function pk(e){let t;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&H0(e.buffer),t}const fk=Wa("string"),zt=Wa("function"),W0=Wa("number"),Va=e=>e!==null&&typeof e=="object",dk=e=>e===!0||e===!1,Ll=e=>{if(Ha(e)!=="object")return!1;const t=Up(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)},hk=pn("Date"),mk=pn("File"),gk=pn("Blob"),yk=pn("FileList"),vk=e=>Va(e)&&zt(e.pipe),wk=e=>{let t;return e&&(typeof FormData=="function"&&e instanceof FormData||zt(e.append)&&((t=Ha(e))==="formdata"||t==="object"&&zt(e.toString)&&e.toString()==="[object FormData]"))},xk=pn("URLSearchParams"),bk=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Ni(e,t,{allOwnKeys:n=!1}={}){if(e===null||typeof e>"u")return;let r,o;if(typeof e!="object"&&(e=[e]),Eo(e))for(r=0,o=e.length;r0;)if(o=n[r],t===o.toLowerCase())return o;return null}const G0=(()=>typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global)(),q0=e=>!Ei(e)&&e!==G0;function wc(){const{caseless:e}=q0(this)&&this||{},t={},n=(r,o)=>{const i=e&&V0(t,o)||o;Ll(t[i])&&Ll(r)?t[i]=wc(t[i],r):Ll(r)?t[i]=wc({},r):Eo(r)?t[i]=r.slice():t[i]=r};for(let r=0,o=arguments.length;r(Ni(t,(o,i)=>{n&&zt(o)?e[i]=U0(o,n):e[i]=o},{allOwnKeys:r}),e),Sk=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),Ck=(e,t,n,r)=>{e.prototype=Object.create(t.prototype,r),e.prototype.constructor=e,Object.defineProperty(e,"super",{value:t.prototype}),n&&Object.assign(e.prototype,n)},Ek=(e,t,n,r)=>{let o,i,l;const a={};if(t=t||{},e==null)return t;do{for(o=Object.getOwnPropertyNames(e),i=o.length;i-- >0;)l=o[i],(!r||r(l,e,t))&&!a[l]&&(t[l]=e[l],a[l]=!0);e=n!==!1&&Up(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},Pk=(e,t,n)=>{e=String(e),(n===void 0||n>e.length)&&(n=e.length),n-=t.length;const r=e.indexOf(t,n);return r!==-1&&r===n},Ok=e=>{if(!e)return null;if(Eo(e))return e;let t=e.length;if(!W0(t))return null;const n=new Array(t);for(;t-- >0;)n[t]=e[t];return n},Tk=(e=>t=>e&&t instanceof e)(typeof Uint8Array<"u"&&Up(Uint8Array)),Ak=(e,t)=>{const r=(e&&e[Symbol.iterator]).call(e);let o;for(;(o=r.next())&&!o.done;){const i=o.value;t.call(e,i[0],i[1])}},$k=(e,t)=>{let n;const r=[];for(;(n=e.exec(t))!==null;)r.push(n);return r},_k=pn("HTMLFormElement"),Rk=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,r,o){return r.toUpperCase()+o}),Bd=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),Lk=pn("RegExp"),Y0=(e,t)=>{const n=Object.getOwnPropertyDescriptors(e),r={};Ni(n,(o,i)=>{let l;(l=t(o,i,e))!==!1&&(r[i]=l||o)}),Object.defineProperties(e,r)},Dk=e=>{Y0(e,(t,n)=>{if(zt(e)&&["arguments","caller","callee"].indexOf(n)!==-1)return!1;const r=e[n];if(zt(r)){if(t.enumerable=!1,"writable"in t){t.writable=!1;return}t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+n+"'")})}})},zk=(e,t)=>{const n={},r=o=>{o.forEach(i=>{n[i]=!0})};return Eo(e)?r(e):r(String(e).split(t)),n},Nk=()=>{},Ik=(e,t)=>(e=+e,Number.isFinite(e)?e:t),Js="abcdefghijklmnopqrstuvwxyz",Ud="0123456789",Q0={DIGIT:Ud,ALPHA:Js,ALPHA_DIGIT:Js+Js.toUpperCase()+Ud},Fk=(e=16,t=Q0.ALPHA_DIGIT)=>{let n="";const{length:r}=t;for(;e--;)n+=t[Math.random()*r|0];return n};function jk(e){return!!(e&&zt(e.append)&&e[Symbol.toStringTag]==="FormData"&&e[Symbol.iterator])}const Mk=e=>{const t=new Array(10),n=(r,o)=>{if(Va(r)){if(t.indexOf(r)>=0)return;if(!("toJSON"in r)){t[o]=r;const i=Eo(r)?[]:{};return Ni(r,(l,a)=>{const s=n(l,o+1);!Ei(s)&&(i[a]=s)}),t[o]=void 0,i}}return r};return n(e,0)},Bk=pn("AsyncFunction"),Uk=e=>e&&(Va(e)||zt(e))&&zt(e.then)&&zt(e.catch),D={isArray:Eo,isArrayBuffer:H0,isBuffer:ck,isFormData:wk,isArrayBufferView:pk,isString:fk,isNumber:W0,isBoolean:dk,isObject:Va,isPlainObject:Ll,isUndefined:Ei,isDate:hk,isFile:mk,isBlob:gk,isRegExp:Lk,isFunction:zt,isStream:vk,isURLSearchParams:xk,isTypedArray:Tk,isFileList:yk,forEach:Ni,merge:wc,extend:kk,trim:bk,stripBOM:Sk,inherits:Ck,toFlatObject:Ek,kindOf:Ha,kindOfTest:pn,endsWith:Pk,toArray:Ok,forEachEntry:Ak,matchAll:$k,isHTMLForm:_k,hasOwnProperty:Bd,hasOwnProp:Bd,reduceDescriptors:Y0,freezeMethods:Dk,toObjectSet:zk,toCamelCase:Rk,noop:Nk,toFiniteNumber:Ik,findKey:V0,global:G0,isContextDefined:q0,ALPHABET:Q0,generateString:Fk,isSpecCompliantForm:jk,toJSONObject:Mk,isAsyncFn:Bk,isThenable:Uk};function he(e,t,n,r,o){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=e,this.name="AxiosError",t&&(this.code=t),n&&(this.config=n),r&&(this.request=r),o&&(this.response=o)}D.inherits(he,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:D.toJSONObject(this.config),code:this.code,status:this.response&&this.response.status?this.response.status:null}}});const K0=he.prototype,X0={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(e=>{X0[e]={value:e}});Object.defineProperties(he,X0);Object.defineProperty(K0,"isAxiosError",{value:!0});he.from=(e,t,n,r,o,i)=>{const l=Object.create(K0);return D.toFlatObject(e,l,function(s){return s!==Error.prototype},a=>a!=="isAxiosError"),he.call(l,e.message,t,n,r,o),l.cause=e,l.name=e.name,i&&Object.assign(l,i),l};const Hk=null;function xc(e){return D.isPlainObject(e)||D.isArray(e)}function Z0(e){return D.endsWith(e,"[]")?e.slice(0,-2):e}function Hd(e,t,n){return e?e.concat(t).map(function(o,i){return o=Z0(o),!n&&i?"["+o+"]":o}).join(n?".":""):t}function Wk(e){return D.isArray(e)&&!e.some(xc)}const Vk=D.toFlatObject(D,{},null,function(t){return/^is[A-Z]/.test(t)});function Ga(e,t,n){if(!D.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,n=D.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(m,w){return!D.isUndefined(w[m])});const r=n.metaTokens,o=n.visitor||p,i=n.dots,l=n.indexes,s=(n.Blob||typeof Blob<"u"&&Blob)&&D.isSpecCompliantForm(t);if(!D.isFunction(o))throw new TypeError("visitor must be a function");function u(h){if(h===null)return"";if(D.isDate(h))return h.toISOString();if(!s&&D.isBlob(h))throw new he("Blob is not supported. Use a Buffer instead.");return D.isArrayBuffer(h)||D.isTypedArray(h)?s&&typeof Blob=="function"?new Blob([h]):Buffer.from(h):h}function p(h,m,w){let g=h;if(h&&!w&&typeof h=="object"){if(D.endsWith(m,"{}"))m=r?m:m.slice(0,-2),h=JSON.stringify(h);else if(D.isArray(h)&&Wk(h)||(D.isFileList(h)||D.endsWith(m,"[]"))&&(g=D.toArray(h)))return m=Z0(m),g.forEach(function(v,C){!(D.isUndefined(v)||v===null)&&t.append(l===!0?Hd([m],C,i):l===null?m:m+"[]",u(v))}),!1}return xc(h)?!0:(t.append(Hd(w,m,i),u(h)),!1)}const c=[],d=Object.assign(Vk,{defaultVisitor:p,convertValue:u,isVisitable:xc});function f(h,m){if(!D.isUndefined(h)){if(c.indexOf(h)!==-1)throw Error("Circular reference detected in "+m.join("."));c.push(h),D.forEach(h,function(g,y){(!(D.isUndefined(g)||g===null)&&o.call(t,g,D.isString(y)?y.trim():y,m,d))===!0&&f(g,m?m.concat(y):[y])}),c.pop()}}if(!D.isObject(e))throw new TypeError("data must be an object");return f(e),t}function Wd(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(r){return t[r]})}function Hp(e,t){this._pairs=[],e&&Ga(e,this,t)}const J0=Hp.prototype;J0.append=function(t,n){this._pairs.push([t,n])};J0.toString=function(t){const n=t?function(r){return t.call(this,r,Wd)}:Wd;return this._pairs.map(function(o){return n(o[0])+"="+n(o[1])},"").join("&")};function Gk(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function e1(e,t,n){if(!t)return e;const r=n&&n.encode||Gk,o=n&&n.serialize;let i;if(o?i=o(t,n):i=D.isURLSearchParams(t)?t.toString():new Hp(t,n).toString(r),i){const l=e.indexOf("#");l!==-1&&(e=e.slice(0,l)),e+=(e.indexOf("?")===-1?"?":"&")+i}return e}class qk{constructor(){this.handlers=[]}use(t,n,r){return this.handlers.push({fulfilled:t,rejected:n,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(t){this.handlers[t]&&(this.handlers[t]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(t){D.forEach(this.handlers,function(r){r!==null&&t(r)})}}const Vd=qk,t1={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},Yk=typeof URLSearchParams<"u"?URLSearchParams:Hp,Qk=typeof FormData<"u"?FormData:null,Kk=typeof Blob<"u"?Blob:null,Xk=(()=>{let e;return typeof navigator<"u"&&((e=navigator.product)==="ReactNative"||e==="NativeScript"||e==="NS")?!1:typeof window<"u"&&typeof document<"u"})(),Zk=(()=>typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function")(),Qt={isBrowser:!0,classes:{URLSearchParams:Yk,FormData:Qk,Blob:Kk},isStandardBrowserEnv:Xk,isStandardBrowserWebWorkerEnv:Zk,protocols:["http","https","file","blob","url","data"]};function Jk(e,t){return Ga(e,new Qt.classes.URLSearchParams,Object.assign({visitor:function(n,r,o,i){return Qt.isNode&&D.isBuffer(n)?(this.append(r,n.toString("base64")),!1):i.defaultVisitor.apply(this,arguments)}},t))}function eS(e){return D.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function tS(e){const t={},n=Object.keys(e);let r;const o=n.length;let i;for(r=0;r=n.length;return l=!l&&D.isArray(o)?o.length:l,s?(D.hasOwnProp(o,l)?o[l]=[o[l],r]:o[l]=r,!a):((!o[l]||!D.isObject(o[l]))&&(o[l]=[]),t(n,r,o[l],i)&&D.isArray(o[l])&&(o[l]=tS(o[l])),!a)}if(D.isFormData(e)&&D.isFunction(e.entries)){const n={};return D.forEachEntry(e,(r,o)=>{t(eS(r),o,n,0)}),n}return null}function nS(e,t,n){if(D.isString(e))try{return(t||JSON.parse)(e),D.trim(e)}catch(r){if(r.name!=="SyntaxError")throw r}return(n||JSON.stringify)(e)}const Wp={transitional:t1,adapter:Qt.isNode?"http":"xhr",transformRequest:[function(t,n){const r=n.getContentType()||"",o=r.indexOf("application/json")>-1,i=D.isObject(t);if(i&&D.isHTMLForm(t)&&(t=new FormData(t)),D.isFormData(t))return o&&o?JSON.stringify(n1(t)):t;if(D.isArrayBuffer(t)||D.isBuffer(t)||D.isStream(t)||D.isFile(t)||D.isBlob(t))return t;if(D.isArrayBufferView(t))return t.buffer;if(D.isURLSearchParams(t))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let a;if(i){if(r.indexOf("application/x-www-form-urlencoded")>-1)return Jk(t,this.formSerializer).toString();if((a=D.isFileList(t))||r.indexOf("multipart/form-data")>-1){const s=this.env&&this.env.FormData;return Ga(a?{"files[]":t}:t,s&&new s,this.formSerializer)}}return i||o?(n.setContentType("application/json",!1),nS(t)):t}],transformResponse:[function(t){const n=this.transitional||Wp.transitional,r=n&&n.forcedJSONParsing,o=this.responseType==="json";if(t&&D.isString(t)&&(r&&!this.responseType||o)){const l=!(n&&n.silentJSONParsing)&&o;try{return JSON.parse(t)}catch(a){if(l)throw a.name==="SyntaxError"?he.from(a,he.ERR_BAD_RESPONSE,this,null,this.response):a}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:Qt.classes.FormData,Blob:Qt.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};D.forEach(["delete","get","head","post","put","patch"],e=>{Wp.headers[e]={}});const Vp=Wp,rS=D.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),oS=e=>{const t={};let n,r,o;return e&&e.split(` +`).forEach(function(l){o=l.indexOf(":"),n=l.substring(0,o).trim().toLowerCase(),r=l.substring(o+1).trim(),!(!n||t[n]&&rS[n])&&(n==="set-cookie"?t[n]?t[n].push(r):t[n]=[r]:t[n]=t[n]?t[n]+", "+r:r)}),t},Gd=Symbol("internals");function Bo(e){return e&&String(e).trim().toLowerCase()}function Dl(e){return e===!1||e==null?e:D.isArray(e)?e.map(Dl):String(e)}function iS(e){const t=Object.create(null),n=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=n.exec(e);)t[r[1]]=r[2];return t}const lS=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function eu(e,t,n,r,o){if(D.isFunction(r))return r.call(this,t,n);if(o&&(t=n),!!D.isString(t)){if(D.isString(r))return t.indexOf(r)!==-1;if(D.isRegExp(r))return r.test(t)}}function aS(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(t,n,r)=>n.toUpperCase()+r)}function sS(e,t){const n=D.toCamelCase(" "+t);["get","set","has"].forEach(r=>{Object.defineProperty(e,r+n,{value:function(o,i,l){return this[r].call(this,t,o,i,l)},configurable:!0})})}class qa{constructor(t){t&&this.set(t)}set(t,n,r){const o=this;function i(a,s,u){const p=Bo(s);if(!p)throw new Error("header name must be a non-empty string");const c=D.findKey(o,p);(!c||o[c]===void 0||u===!0||u===void 0&&o[c]!==!1)&&(o[c||s]=Dl(a))}const l=(a,s)=>D.forEach(a,(u,p)=>i(u,p,s));return D.isPlainObject(t)||t instanceof this.constructor?l(t,n):D.isString(t)&&(t=t.trim())&&!lS(t)?l(oS(t),n):t!=null&&i(n,t,r),this}get(t,n){if(t=Bo(t),t){const r=D.findKey(this,t);if(r){const o=this[r];if(!n)return o;if(n===!0)return iS(o);if(D.isFunction(n))return n.call(this,o,r);if(D.isRegExp(n))return n.exec(o);throw new TypeError("parser must be boolean|regexp|function")}}}has(t,n){if(t=Bo(t),t){const r=D.findKey(this,t);return!!(r&&this[r]!==void 0&&(!n||eu(this,this[r],r,n)))}return!1}delete(t,n){const r=this;let o=!1;function i(l){if(l=Bo(l),l){const a=D.findKey(r,l);a&&(!n||eu(r,r[a],a,n))&&(delete r[a],o=!0)}}return D.isArray(t)?t.forEach(i):i(t),o}clear(t){const n=Object.keys(this);let r=n.length,o=!1;for(;r--;){const i=n[r];(!t||eu(this,this[i],i,t,!0))&&(delete this[i],o=!0)}return o}normalize(t){const n=this,r={};return D.forEach(this,(o,i)=>{const l=D.findKey(r,i);if(l){n[l]=Dl(o),delete n[i];return}const a=t?aS(i):String(i).trim();a!==i&&delete n[i],n[a]=Dl(o),r[a]=!0}),this}concat(...t){return this.constructor.concat(this,...t)}toJSON(t){const n=Object.create(null);return D.forEach(this,(r,o)=>{r!=null&&r!==!1&&(n[o]=t&&D.isArray(r)?r.join(", "):r)}),n}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([t,n])=>t+": "+n).join(` +`)}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(t){return t instanceof this?t:new this(t)}static concat(t,...n){const r=new this(t);return n.forEach(o=>r.set(o)),r}static accessor(t){const r=(this[Gd]=this[Gd]={accessors:{}}).accessors,o=this.prototype;function i(l){const a=Bo(l);r[a]||(sS(o,l),r[a]=!0)}return D.isArray(t)?t.forEach(i):i(t),this}}qa.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);D.reduceDescriptors(qa.prototype,({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(r){this[n]=r}}});D.freezeMethods(qa);const Sn=qa;function tu(e,t){const n=this||Vp,r=t||n,o=Sn.from(r.headers);let i=r.data;return D.forEach(e,function(a){i=a.call(n,i,o.normalize(),t?t.status:void 0)}),o.normalize(),i}function r1(e){return!!(e&&e.__CANCEL__)}function Ii(e,t,n){he.call(this,e??"canceled",he.ERR_CANCELED,t,n),this.name="CanceledError"}D.inherits(Ii,he,{__CANCEL__:!0});function uS(e,t,n){const r=n.config.validateStatus;!n.status||!r||r(n.status)?e(n):t(new he("Request failed with status code "+n.status,[he.ERR_BAD_REQUEST,he.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n))}const cS=Qt.isStandardBrowserEnv?function(){return{write:function(n,r,o,i,l,a){const s=[];s.push(n+"="+encodeURIComponent(r)),D.isNumber(o)&&s.push("expires="+new Date(o).toGMTString()),D.isString(i)&&s.push("path="+i),D.isString(l)&&s.push("domain="+l),a===!0&&s.push("secure"),document.cookie=s.join("; ")},read:function(n){const r=document.cookie.match(new RegExp("(^|;\\s*)("+n+")=([^;]*)"));return r?decodeURIComponent(r[3]):null},remove:function(n){this.write(n,"",Date.now()-864e5)}}}():function(){return{write:function(){},read:function(){return null},remove:function(){}}}();function pS(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function fS(e,t){return t?e.replace(/\/+$/,"")+"/"+t.replace(/^\/+/,""):e}function o1(e,t){return e&&!pS(t)?fS(e,t):t}const dS=Qt.isStandardBrowserEnv?function(){const t=/(msie|trident)/i.test(navigator.userAgent),n=document.createElement("a");let r;function o(i){let l=i;return t&&(n.setAttribute("href",l),l=n.href),n.setAttribute("href",l),{href:n.href,protocol:n.protocol?n.protocol.replace(/:$/,""):"",host:n.host,search:n.search?n.search.replace(/^\?/,""):"",hash:n.hash?n.hash.replace(/^#/,""):"",hostname:n.hostname,port:n.port,pathname:n.pathname.charAt(0)==="/"?n.pathname:"/"+n.pathname}}return r=o(window.location.href),function(l){const a=D.isString(l)?o(l):l;return a.protocol===r.protocol&&a.host===r.host}}():function(){return function(){return!0}}();function hS(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}function mS(e,t){e=e||10;const n=new Array(e),r=new Array(e);let o=0,i=0,l;return t=t!==void 0?t:1e3,function(s){const u=Date.now(),p=r[i];l||(l=u),n[o]=s,r[o]=u;let c=i,d=0;for(;c!==o;)d+=n[c++],c=c%e;if(o=(o+1)%e,o===i&&(i=(i+1)%e),u-l{const i=o.loaded,l=o.lengthComputable?o.total:void 0,a=i-n,s=r(a),u=i<=l;n=i;const p={loaded:i,total:l,progress:l?i/l:void 0,bytes:a,rate:s||void 0,estimated:s&&l&&u?(l-i)/s:void 0,event:o};p[t?"download":"upload"]=!0,e(p)}}const gS=typeof XMLHttpRequest<"u",yS=gS&&function(e){return new Promise(function(n,r){let o=e.data;const i=Sn.from(e.headers).normalize(),l=e.responseType;let a;function s(){e.cancelToken&&e.cancelToken.unsubscribe(a),e.signal&&e.signal.removeEventListener("abort",a)}D.isFormData(o)&&(Qt.isStandardBrowserEnv||Qt.isStandardBrowserWebWorkerEnv?i.setContentType(!1):i.setContentType("multipart/form-data;",!1));let u=new XMLHttpRequest;if(e.auth){const f=e.auth.username||"",h=e.auth.password?unescape(encodeURIComponent(e.auth.password)):"";i.set("Authorization","Basic "+btoa(f+":"+h))}const p=o1(e.baseURL,e.url);u.open(e.method.toUpperCase(),e1(p,e.params,e.paramsSerializer),!0),u.timeout=e.timeout;function c(){if(!u)return;const f=Sn.from("getAllResponseHeaders"in u&&u.getAllResponseHeaders()),m={data:!l||l==="text"||l==="json"?u.responseText:u.response,status:u.status,statusText:u.statusText,headers:f,config:e,request:u};uS(function(g){n(g),s()},function(g){r(g),s()},m),u=null}if("onloadend"in u?u.onloadend=c:u.onreadystatechange=function(){!u||u.readyState!==4||u.status===0&&!(u.responseURL&&u.responseURL.indexOf("file:")===0)||setTimeout(c)},u.onabort=function(){u&&(r(new he("Request aborted",he.ECONNABORTED,e,u)),u=null)},u.onerror=function(){r(new he("Network Error",he.ERR_NETWORK,e,u)),u=null},u.ontimeout=function(){let h=e.timeout?"timeout of "+e.timeout+"ms exceeded":"timeout exceeded";const m=e.transitional||t1;e.timeoutErrorMessage&&(h=e.timeoutErrorMessage),r(new he(h,m.clarifyTimeoutError?he.ETIMEDOUT:he.ECONNABORTED,e,u)),u=null},Qt.isStandardBrowserEnv){const f=(e.withCredentials||dS(p))&&e.xsrfCookieName&&cS.read(e.xsrfCookieName);f&&i.set(e.xsrfHeaderName,f)}o===void 0&&i.setContentType(null),"setRequestHeader"in u&&D.forEach(i.toJSON(),function(h,m){u.setRequestHeader(m,h)}),D.isUndefined(e.withCredentials)||(u.withCredentials=!!e.withCredentials),l&&l!=="json"&&(u.responseType=e.responseType),typeof e.onDownloadProgress=="function"&&u.addEventListener("progress",qd(e.onDownloadProgress,!0)),typeof e.onUploadProgress=="function"&&u.upload&&u.upload.addEventListener("progress",qd(e.onUploadProgress)),(e.cancelToken||e.signal)&&(a=f=>{u&&(r(!f||f.type?new Ii(null,e,u):f),u.abort(),u=null)},e.cancelToken&&e.cancelToken.subscribe(a),e.signal&&(e.signal.aborted?a():e.signal.addEventListener("abort",a)));const d=hS(p);if(d&&Qt.protocols.indexOf(d)===-1){r(new he("Unsupported protocol "+d+":",he.ERR_BAD_REQUEST,e));return}u.send(o||null)})},zl={http:Hk,xhr:yS};D.forEach(zl,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch{}Object.defineProperty(e,"adapterName",{value:t})}});const i1={getAdapter:e=>{e=D.isArray(e)?e:[e];const{length:t}=e;let n,r;for(let o=0;oe instanceof Sn?e.toJSON():e;function yo(e,t){t=t||{};const n={};function r(u,p,c){return D.isPlainObject(u)&&D.isPlainObject(p)?D.merge.call({caseless:c},u,p):D.isPlainObject(p)?D.merge({},p):D.isArray(p)?p.slice():p}function o(u,p,c){if(D.isUndefined(p)){if(!D.isUndefined(u))return r(void 0,u,c)}else return r(u,p,c)}function i(u,p){if(!D.isUndefined(p))return r(void 0,p)}function l(u,p){if(D.isUndefined(p)){if(!D.isUndefined(u))return r(void 0,u)}else return r(void 0,p)}function a(u,p,c){if(c in t)return r(u,p);if(c in e)return r(void 0,u)}const s={url:i,method:i,data:i,baseURL:l,transformRequest:l,transformResponse:l,paramsSerializer:l,timeout:l,timeoutMessage:l,withCredentials:l,adapter:l,responseType:l,xsrfCookieName:l,xsrfHeaderName:l,onUploadProgress:l,onDownloadProgress:l,decompress:l,maxContentLength:l,maxBodyLength:l,beforeRedirect:l,transport:l,httpAgent:l,httpsAgent:l,cancelToken:l,socketPath:l,responseEncoding:l,validateStatus:a,headers:(u,p)=>o(Qd(u),Qd(p),!0)};return D.forEach(Object.keys(Object.assign({},e,t)),function(p){const c=s[p]||o,d=c(e[p],t[p],p);D.isUndefined(d)&&c!==a||(n[p]=d)}),n}const l1="1.5.0",Gp={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{Gp[e]=function(r){return typeof r===e||"a"+(t<1?"n ":" ")+e}});const Kd={};Gp.transitional=function(t,n,r){function o(i,l){return"[Axios v"+l1+"] Transitional option '"+i+"'"+l+(r?". "+r:"")}return(i,l,a)=>{if(t===!1)throw new he(o(l," has been removed"+(n?" in "+n:"")),he.ERR_DEPRECATED);return n&&!Kd[l]&&(Kd[l]=!0,console.warn(o(l," has been deprecated since v"+n+" and will be removed in the near future"))),t?t(i,l,a):!0}};function vS(e,t,n){if(typeof e!="object")throw new he("options must be an object",he.ERR_BAD_OPTION_VALUE);const r=Object.keys(e);let o=r.length;for(;o-- >0;){const i=r[o],l=t[i];if(l){const a=e[i],s=a===void 0||l(a,i,e);if(s!==!0)throw new he("option "+i+" must be "+s,he.ERR_BAD_OPTION_VALUE);continue}if(n!==!0)throw new he("Unknown option "+i,he.ERR_BAD_OPTION)}}const bc={assertOptions:vS,validators:Gp},In=bc.validators;class ha{constructor(t){this.defaults=t,this.interceptors={request:new Vd,response:new Vd}}request(t,n){typeof t=="string"?(n=n||{},n.url=t):n=t||{},n=yo(this.defaults,n);const{transitional:r,paramsSerializer:o,headers:i}=n;r!==void 0&&bc.assertOptions(r,{silentJSONParsing:In.transitional(In.boolean),forcedJSONParsing:In.transitional(In.boolean),clarifyTimeoutError:In.transitional(In.boolean)},!1),o!=null&&(D.isFunction(o)?n.paramsSerializer={serialize:o}:bc.assertOptions(o,{encode:In.function,serialize:In.function},!0)),n.method=(n.method||this.defaults.method||"get").toLowerCase();let l=i&&D.merge(i.common,i[n.method]);i&&D.forEach(["delete","get","head","post","put","patch","common"],h=>{delete i[h]}),n.headers=Sn.concat(l,i);const a=[];let s=!0;this.interceptors.request.forEach(function(m){typeof m.runWhen=="function"&&m.runWhen(n)===!1||(s=s&&m.synchronous,a.unshift(m.fulfilled,m.rejected))});const u=[];this.interceptors.response.forEach(function(m){u.push(m.fulfilled,m.rejected)});let p,c=0,d;if(!s){const h=[Yd.bind(this),void 0];for(h.unshift.apply(h,a),h.push.apply(h,u),d=h.length,p=Promise.resolve(n);c{if(!r._listeners)return;let i=r._listeners.length;for(;i-- >0;)r._listeners[i](o);r._listeners=null}),this.promise.then=o=>{let i;const l=new Promise(a=>{r.subscribe(a),i=a}).then(o);return l.cancel=function(){r.unsubscribe(i)},l},t(function(i,l,a){r.reason||(r.reason=new Ii(i,l,a),n(r.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}unsubscribe(t){if(!this._listeners)return;const n=this._listeners.indexOf(t);n!==-1&&this._listeners.splice(n,1)}static source(){let t;return{token:new qp(function(o){t=o}),cancel:t}}}const wS=qp;function xS(e){return function(n){return e.apply(null,n)}}function bS(e){return D.isObject(e)&&e.isAxiosError===!0}const kc={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(kc).forEach(([e,t])=>{kc[t]=e});const kS=kc;function a1(e){const t=new Nl(e),n=U0(Nl.prototype.request,t);return D.extend(n,Nl.prototype,t,{allOwnKeys:!0}),D.extend(n,t,null,{allOwnKeys:!0}),n.create=function(o){return a1(yo(e,o))},n}const We=a1(Vp);We.Axios=Nl;We.CanceledError=Ii;We.CancelToken=wS;We.isCancel=r1;We.VERSION=l1;We.toFormData=Ga;We.AxiosError=he;We.Cancel=We.CanceledError;We.all=function(t){return Promise.all(t)};We.spread=xS;We.isAxiosError=bS;We.mergeConfig=yo;We.AxiosHeaders=Sn;We.formToJSON=e=>n1(D.isHTMLForm(e)?new FormData(e):e);We.getAdapter=i1.getAdapter;We.HttpStatusCode=kS;We.default=We;const SS=We,Xd="@openchatai:session_id";function CS(){const[e,t]=x.useState(void 0);return x.useEffect(()=>{const n=localStorage.getItem(Xd);if(n)t(n);else{const r=Math.random().toString(36).substring(2,15);localStorage.setItem(Xd,r),t(r)}},[]),{sessionId:e,setSessionId:t}}function ES(e,t){const n=SS.create({baseURL:e,headers:{"X-Session-Id":t}});return n.interceptors.request.use(r=>(r.data={...r.data,session_id:t},r)),n}const s1=x.createContext(void 0);function PS({children:e}){const t=Ua(),{sessionId:n}=CS(),r=x.useMemo(()=>ES(t==null?void 0:t.apiUrl,n),[t,n]);return t!=null&&t.token?r.defaults.headers["X-Bot-Token"]=t==null?void 0:t.token:console.warn("No token!"),L.jsx(s1.Provider,{value:{axiosInstance:r},children:e})}const u1=()=>{const e=x.useContext(s1);if(!e)throw new Error("useAxiosInstance must be used within a AxiosProvider");return e},c1=x.createContext({});function OS({children:e}){const{axiosInstance:t}=u1(),[n,r]=x.useState(),[o,i]=x.useState(!0);async function l(){i(!0),t.get("/chat/init").then(({data:a})=>r(a)).finally(()=>i(!1))}return x.useEffect(()=>{l()},[]),L.jsx(c1.Provider,{value:{data:n,loading:o,refetch:l},children:e})}const p1=()=>{const e=x.useContext(c1);return e||console.warn("Error loading initial data...."),e};function TS({children:e,options:t}){return L.jsx(lk,{data:t,children:L.jsx(sk,{children:L.jsx(PS,{children:L.jsx(OS,{children:e})})})})}function AS(){for(var e=0,t,n,r="";ee&&(t=0,r=n,n=new Map)}return{get:function(l){var a=n.get(l);if(a!==void 0)return a;if((a=r.get(l))!==void 0)return o(l,a),a},set:function(l,a){n.has(l)?n.set(l,a):o(l,a)}}}var h1="!";function NS(e){var t=e.separator||":",n=t.length===1,r=t[0],o=t.length;return function(l){for(var a=[],s=0,u=0,p,c=0;cu?p-u:void 0;return{modifiers:a,hasImportantModifier:h,baseClassName:m,maybePostfixModifierPosition:w}}}function IS(e){if(e.length<=1)return e;var t=[],n=[];return e.forEach(function(r){var o=r[0]==="[";o?(t.push.apply(t,n.sort().concat([r])),n=[]):n.push(r)}),t.push.apply(t,n.sort()),t}function FS(e){return{cache:zS(e.cacheSize),splitModifiers:NS(e),...$S(e)}}var jS=/\s+/;function MS(e,t){var n=t.splitModifiers,r=t.getClassGroupId,o=t.getConflictingClassGroupIds,i=new Set;return e.trim().split(jS).map(function(l){var a=n(l),s=a.modifiers,u=a.hasImportantModifier,p=a.baseClassName,c=a.maybePostfixModifierPosition,d=r(c?p.substring(0,c):p),f=!!c;if(!d){if(!c)return{isTailwindClass:!1,originalClassName:l};if(d=r(p),!d)return{isTailwindClass:!1,originalClassName:l};f=!1}var h=IS(s).join(":"),m=u?h+h1:h;return{isTailwindClass:!0,modifierId:m,classGroupId:d,originalClassName:l,hasPostfixModifier:f}}).reverse().filter(function(l){if(!l.isTailwindClass)return!0;var a=l.modifierId,s=l.classGroupId,u=l.hasPostfixModifier,p=a+s;return i.has(p)?!1:(i.add(p),o(s,u).forEach(function(c){return i.add(a+c)}),!0)}).reverse().map(function(l){return l.originalClassName}).join(" ")}function BS(){for(var e=arguments.length,t=new Array(e),n=0;ne.forEach(n=>l2(n,t))}function en(...e){return x.useCallback(w1(...e),e)}function Qp(e,t=[]){let n=[];function r(i,l){const a=x.createContext(l),s=n.length;n=[...n,l];function u(c){const{scope:d,children:f,...h}=c,m=(d==null?void 0:d[e][s])||a,w=x.useMemo(()=>h,Object.values(h));return x.createElement(m.Provider,{value:w},f)}function p(c,d){const f=(d==null?void 0:d[e][s])||a,h=x.useContext(f);if(h)return h;if(l!==void 0)return l;throw new Error(`\`${c}\` must be used within \`${i}\``)}return u.displayName=i+"Provider",[u,p]}const o=()=>{const i=n.map(l=>x.createContext(l));return function(a){const s=(a==null?void 0:a[e])||i;return x.useMemo(()=>({[`__scope${e}`]:{...a,[e]:s}}),[a,s])}};return o.scopeName=e,[r,a2(o,...t)]}function a2(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(i){const l=r.reduce((a,{useScope:s,scopeName:u})=>{const c=s(i)[`__scope${u}`];return{...a,...c}},{});return x.useMemo(()=>({[`__scope${t.scopeName}`]:l}),[l])}};return n.scopeName=t.scopeName,n}const vo=globalThis!=null&&globalThis.document?x.useLayoutEffect:()=>{},s2=Qw["useId".toString()]||(()=>{});let u2=0;function Il(e){const[t,n]=x.useState(s2());return vo(()=>{e||n(r=>r??String(u2++))},[e]),e||(t?`radix-${t}`:"")}function un(e){const t=x.useRef(e);return x.useEffect(()=>{t.current=e}),x.useMemo(()=>(...n)=>{var r;return(r=t.current)===null||r===void 0?void 0:r.call(t,...n)},[])}function x1({prop:e,defaultProp:t,onChange:n=()=>{}}){const[r,o]=c2({defaultProp:t,onChange:n}),i=e!==void 0,l=i?e:r,a=un(n),s=x.useCallback(u=>{if(i){const c=typeof u=="function"?u(e):u;c!==e&&a(c)}else o(u)},[i,e,o,a]);return[l,s]}function c2({defaultProp:e,onChange:t}){const n=x.useState(e),[r]=n,o=x.useRef(r),i=un(t);return x.useEffect(()=>{o.current!==r&&(i(r),o.current=r)},[r,o,i]),n}const Kp=x.forwardRef((e,t)=>{const{children:n,...r}=e,o=x.Children.toArray(n),i=o.find(p2);if(i){const l=i.props.children,a=o.map(s=>s===i?x.Children.count(l)>1?x.Children.only(null):x.isValidElement(l)?l.props.children:null:s);return x.createElement(Ec,ge({},r,{ref:t}),x.isValidElement(l)?x.cloneElement(l,void 0,a):null)}return x.createElement(Ec,ge({},r,{ref:t}),n)});Kp.displayName="Slot";const Ec=x.forwardRef((e,t)=>{const{children:n,...r}=e;return x.isValidElement(n)?x.cloneElement(n,{...f2(r,n.props),ref:t?w1(t,n.ref):n.ref}):x.Children.count(n)>1?x.Children.only(null):null});Ec.displayName="SlotClone";const b1=({children:e})=>x.createElement(x.Fragment,null,e);function p2(e){return x.isValidElement(e)&&e.type===b1}function f2(e,t){const n={...t};for(const r in t){const o=e[r],i=t[r];/^on[A-Z]/.test(r)?o&&i?n[r]=(...a)=>{i(...a),o(...a)}:o&&(n[r]=o):r==="style"?n[r]={...o,...i}:r==="className"&&(n[r]=[o,i].filter(Boolean).join(" "))}return{...e,...n}}const d2=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"],Tt=d2.reduce((e,t)=>{const n=x.forwardRef((r,o)=>{const{asChild:i,...l}=r,a=i?Kp:t;return x.useEffect(()=>{window[Symbol.for("radix-ui")]=!0},[]),x.createElement(a,ge({},l,{ref:o}))});return n.displayName=`Primitive.${t}`,{...e,[t]:n}},{});function k1(e,t){e&&Ba.flushSync(()=>e.dispatchEvent(t))}function S1(e,t=globalThis==null?void 0:globalThis.document){const n=un(e);x.useEffect(()=>{const r=o=>{o.key==="Escape"&&n(o)};return t.addEventListener("keydown",r),()=>t.removeEventListener("keydown",r)},[n,t])}const Pc="dismissableLayer.update",h2="dismissableLayer.pointerDownOutside",m2="dismissableLayer.focusOutside";let nh;const g2=x.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),y2=x.forwardRef((e,t)=>{var n;const{disableOutsidePointerEvents:r=!1,onEscapeKeyDown:o,onPointerDownOutside:i,onFocusOutside:l,onInteractOutside:a,onDismiss:s,...u}=e,p=x.useContext(g2),[c,d]=x.useState(null),f=(n=c==null?void 0:c.ownerDocument)!==null&&n!==void 0?n:globalThis==null?void 0:globalThis.document,[,h]=x.useState({}),m=en(t,T=>d(T)),w=Array.from(p.layers),[g]=[...p.layersWithOutsidePointerEventsDisabled].slice(-1),y=w.indexOf(g),v=c?w.indexOf(c):-1,C=p.layersWithOutsidePointerEventsDisabled.size>0,E=v>=y,k=v2(T=>{const N=T.target,P=[...p.branches].some(_=>_.contains(N));!E||P||(i==null||i(T),a==null||a(T),T.defaultPrevented||s==null||s())},f),O=w2(T=>{const N=T.target;[...p.branches].some(_=>_.contains(N))||(l==null||l(T),a==null||a(T),T.defaultPrevented||s==null||s())},f);return S1(T=>{v===p.layers.size-1&&(o==null||o(T),!T.defaultPrevented&&s&&(T.preventDefault(),s()))},f),x.useEffect(()=>{if(c)return r&&(p.layersWithOutsidePointerEventsDisabled.size===0&&(nh=f.body.style.pointerEvents,f.body.style.pointerEvents="none"),p.layersWithOutsidePointerEventsDisabled.add(c)),p.layers.add(c),rh(),()=>{r&&p.layersWithOutsidePointerEventsDisabled.size===1&&(f.body.style.pointerEvents=nh)}},[c,f,r,p]),x.useEffect(()=>()=>{c&&(p.layers.delete(c),p.layersWithOutsidePointerEventsDisabled.delete(c),rh())},[c,p]),x.useEffect(()=>{const T=()=>h({});return document.addEventListener(Pc,T),()=>document.removeEventListener(Pc,T)},[]),x.createElement(Tt.div,ge({},u,{ref:m,style:{pointerEvents:C?E?"auto":"none":void 0,...e.style},onFocusCapture:Xe(e.onFocusCapture,O.onFocusCapture),onBlurCapture:Xe(e.onBlurCapture,O.onBlurCapture),onPointerDownCapture:Xe(e.onPointerDownCapture,k.onPointerDownCapture)}))});function v2(e,t=globalThis==null?void 0:globalThis.document){const n=un(e),r=x.useRef(!1),o=x.useRef(()=>{});return x.useEffect(()=>{const i=a=>{if(a.target&&!r.current){let p=function(){C1(h2,n,u,{discrete:!0})};var s=p;const u={originalEvent:a};a.pointerType==="touch"?(t.removeEventListener("click",o.current),o.current=p,t.addEventListener("click",o.current,{once:!0})):p()}else t.removeEventListener("click",o.current);r.current=!1},l=window.setTimeout(()=>{t.addEventListener("pointerdown",i)},0);return()=>{window.clearTimeout(l),t.removeEventListener("pointerdown",i),t.removeEventListener("click",o.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function w2(e,t=globalThis==null?void 0:globalThis.document){const n=un(e),r=x.useRef(!1);return x.useEffect(()=>{const o=i=>{i.target&&!r.current&&C1(m2,n,{originalEvent:i},{discrete:!1})};return t.addEventListener("focusin",o),()=>t.removeEventListener("focusin",o)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function rh(){const e=new CustomEvent(Pc);document.dispatchEvent(e)}function C1(e,t,n,{discrete:r}){const o=n.originalEvent.target,i=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&o.addEventListener(e,t,{once:!0}),r?k1(o,i):o.dispatchEvent(i)}const ru="focusScope.autoFocusOnMount",ou="focusScope.autoFocusOnUnmount",oh={bubbles:!1,cancelable:!0},x2=x.forwardRef((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:o,onUnmountAutoFocus:i,...l}=e,[a,s]=x.useState(null),u=un(o),p=un(i),c=x.useRef(null),d=en(t,m=>s(m)),f=x.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;x.useEffect(()=>{if(r){let y=function(k){if(f.paused||!a)return;const O=k.target;a.contains(O)?c.current=O:Mn(c.current,{select:!0})},v=function(k){if(f.paused||!a)return;const O=k.relatedTarget;O!==null&&(a.contains(O)||Mn(c.current,{select:!0}))},C=function(k){if(document.activeElement===document.body)for(const T of k)T.removedNodes.length>0&&Mn(a)};var m=y,w=v,g=C;document.addEventListener("focusin",y),document.addEventListener("focusout",v);const E=new MutationObserver(C);return a&&E.observe(a,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",y),document.removeEventListener("focusout",v),E.disconnect()}}},[r,a,f.paused]),x.useEffect(()=>{if(a){lh.add(f);const m=document.activeElement;if(!a.contains(m)){const g=new CustomEvent(ru,oh);a.addEventListener(ru,u),a.dispatchEvent(g),g.defaultPrevented||(b2(P2(E1(a)),{select:!0}),document.activeElement===m&&Mn(a))}return()=>{a.removeEventListener(ru,u),setTimeout(()=>{const g=new CustomEvent(ou,oh);a.addEventListener(ou,p),a.dispatchEvent(g),g.defaultPrevented||Mn(m??document.body,{select:!0}),a.removeEventListener(ou,p),lh.remove(f)},0)}}},[a,u,p,f]);const h=x.useCallback(m=>{if(!n&&!r||f.paused)return;const w=m.key==="Tab"&&!m.altKey&&!m.ctrlKey&&!m.metaKey,g=document.activeElement;if(w&&g){const y=m.currentTarget,[v,C]=k2(y);v&&C?!m.shiftKey&&g===C?(m.preventDefault(),n&&Mn(v,{select:!0})):m.shiftKey&&g===v&&(m.preventDefault(),n&&Mn(C,{select:!0})):g===y&&m.preventDefault()}},[n,r,f.paused]);return x.createElement(Tt.div,ge({tabIndex:-1},l,{ref:d,onKeyDown:h}))});function b2(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(Mn(r,{select:t}),document.activeElement!==n)return}function k2(e){const t=E1(e),n=ih(t,e),r=ih(t.reverse(),e);return[n,r]}function E1(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const o=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||o?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function ih(e,t){for(const n of e)if(!S2(n,{upTo:t}))return n}function S2(e,{upTo:t}){if(getComputedStyle(e).visibility==="hidden")return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display==="none")return!0;e=e.parentElement}return!1}function C2(e){return e instanceof HTMLInputElement&&"select"in e}function Mn(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&C2(e)&&t&&e.select()}}const lh=E2();function E2(){let e=[];return{add(t){const n=e[0];t!==n&&(n==null||n.pause()),e=ah(e,t),e.unshift(t)},remove(t){var n;e=ah(e,t),(n=e[0])===null||n===void 0||n.resume()}}}function ah(e,t){const n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function P2(e){return e.filter(t=>t.tagName!=="A")}function O2(e,t){return x.useReducer((n,r)=>{const o=t[n][r];return o??n},e)}const Ya=e=>{const{present:t,children:n}=e,r=T2(t),o=typeof n=="function"?n({present:r.isPresent}):x.Children.only(n),i=en(r.ref,o.ref);return typeof n=="function"||r.isPresent?x.cloneElement(o,{ref:i}):null};Ya.displayName="Presence";function T2(e){const[t,n]=x.useState(),r=x.useRef({}),o=x.useRef(e),i=x.useRef("none"),l=e?"mounted":"unmounted",[a,s]=O2(l,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return x.useEffect(()=>{const u=cl(r.current);i.current=a==="mounted"?u:"none"},[a]),vo(()=>{const u=r.current,p=o.current;if(p!==e){const d=i.current,f=cl(u);e?s("MOUNT"):f==="none"||(u==null?void 0:u.display)==="none"?s("UNMOUNT"):s(p&&d!==f?"ANIMATION_OUT":"UNMOUNT"),o.current=e}},[e,s]),vo(()=>{if(t){const u=c=>{const f=cl(r.current).includes(c.animationName);c.target===t&&f&&Ba.flushSync(()=>s("ANIMATION_END"))},p=c=>{c.target===t&&(i.current=cl(r.current))};return t.addEventListener("animationstart",p),t.addEventListener("animationcancel",u),t.addEventListener("animationend",u),()=>{t.removeEventListener("animationstart",p),t.removeEventListener("animationcancel",u),t.removeEventListener("animationend",u)}}else s("ANIMATION_END")},[t,s]),{isPresent:["mounted","unmountSuspended"].includes(a),ref:x.useCallback(u=>{u&&(r.current=getComputedStyle(u)),n(u)},[])}}function cl(e){return(e==null?void 0:e.animationName)||"none"}let iu=0;function A2(){x.useEffect(()=>{var e,t;const n=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",(e=n[0])!==null&&e!==void 0?e:sh()),document.body.insertAdjacentElement("beforeend",(t=n[1])!==null&&t!==void 0?t:sh()),iu++,()=>{iu===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(r=>r.remove()),iu--}},[])}function sh(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.cssText="outline: none; opacity: 0; position: fixed; pointer-events: none",e}var ln=function(){return ln=Object.assign||function(t){for(var n,r=1,o=arguments.length;r"u")return G2;var t=q2(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},Q2=A1(),K2=function(e,t,n,r){var o=e.left,i=e.top,l=e.right,a=e.gap;return n===void 0&&(n="margin"),` + .`.concat(_2,` { overflow: hidden `).concat(r,`; padding-right: `).concat(a,"px ").concat(r,`; } @@ -59,29 +57,29 @@ Error generating stack: `+i.message+` `),n==="padding"&&"padding-right: ".concat(a,"px ").concat(r,";")].filter(Boolean).join(""),` } - .`).concat(Dl,` { + .`).concat(Fl,` { right: `).concat(a,"px ").concat(r,`; } - .`).concat(Nl,` { + .`).concat(jl,` { margin-right: `).concat(a,"px ").concat(r,`; } - .`).concat(Dl," .").concat(Dl,` { + .`).concat(Fl," .").concat(Fl,` { right: 0 `).concat(r,`; } - .`).concat(Nl," .").concat(Nl,` { + .`).concat(jl," .").concat(jl,` { margin-right: 0 `).concat(r,`; } body { - `).concat(O2,": ").concat(a,`px; + `).concat(R2,": ").concat(a,`px; } -`)},q2=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,o=r===void 0?"margin":r,i=b.useMemo(function(){return W2(o)},[o]);return b.createElement(V2,{styles:G2(i,!t,o,n?"":"!important")})},Ec=!1;if(typeof window<"u")try{var ul=Object.defineProperty({},"passive",{get:function(){return Ec=!0,!0}});window.addEventListener("test",ul,ul),window.removeEventListener("test",ul,ul)}catch{Ec=!1}var Ir=Ec?{passive:!1}:!1,Y2=function(e){return e.tagName==="TEXTAREA"},E1=function(e,t){var n=window.getComputedStyle(e);return n[t]!=="hidden"&&!(n.overflowY===n.overflowX&&!Y2(e)&&n[t]==="visible")},Q2=function(e){return E1(e,"overflowY")},K2=function(e){return E1(e,"overflowX")},uh=function(e,t){var n=t;do{typeof ShadowRoot<"u"&&n instanceof ShadowRoot&&(n=n.host);var r=P1(e,n);if(r){var o=T1(e,n),i=o[1],l=o[2];if(i>l)return!0}n=n.parentNode}while(n&&n!==document.body);return!1},X2=function(e){var t=e.scrollTop,n=e.scrollHeight,r=e.clientHeight;return[t,n,r]},Z2=function(e){var t=e.scrollLeft,n=e.scrollWidth,r=e.clientWidth;return[t,n,r]},P1=function(e,t){return e==="v"?Q2(t):K2(t)},T1=function(e,t){return e==="v"?X2(t):Z2(t)},J2=function(e,t){return e==="h"&&t==="rtl"?-1:1},eC=function(e,t,n,r,o){var i=J2(e,window.getComputedStyle(t).direction),l=i*r,a=n.target,s=t.contains(a),u=!1,c=l>0,p=0,d=0;do{var f=T1(e,a),h=f[0],m=f[1],w=f[2],g=m-w-i*h;(h||g)&&P1(e,a)&&(p+=g,d+=h),a=a.parentNode}while(!s&&a!==document.body||s&&(t.contains(a)||t===a));return(c&&(o&&p===0||!o&&l>p)||!c&&(o&&d===0||!o&&-l>d))&&(u=!0),u},cl=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},ch=function(e){return[e.deltaX,e.deltaY]},ph=function(e){return e&&"current"in e?e.current:e},tC=function(e,t){return e[0]===t[0]&&e[1]===t[1]},nC=function(e){return` +`)},X2=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,o=r===void 0?"margin":r,i=x.useMemo(function(){return Y2(o)},[o]);return x.createElement(Q2,{styles:K2(i,!t,o,n?"":"!important")})},Oc=!1;if(typeof window<"u")try{var pl=Object.defineProperty({},"passive",{get:function(){return Oc=!0,!0}});window.addEventListener("test",pl,pl),window.removeEventListener("test",pl,pl)}catch{Oc=!1}var Fr=Oc?{passive:!1}:!1,Z2=function(e){return e.tagName==="TEXTAREA"},$1=function(e,t){var n=window.getComputedStyle(e);return n[t]!=="hidden"&&!(n.overflowY===n.overflowX&&!Z2(e)&&n[t]==="visible")},J2=function(e){return $1(e,"overflowY")},eC=function(e){return $1(e,"overflowX")},ch=function(e,t){var n=t;do{typeof ShadowRoot<"u"&&n instanceof ShadowRoot&&(n=n.host);var r=_1(e,n);if(r){var o=R1(e,n),i=o[1],l=o[2];if(i>l)return!0}n=n.parentNode}while(n&&n!==document.body);return!1},tC=function(e){var t=e.scrollTop,n=e.scrollHeight,r=e.clientHeight;return[t,n,r]},nC=function(e){var t=e.scrollLeft,n=e.scrollWidth,r=e.clientWidth;return[t,n,r]},_1=function(e,t){return e==="v"?J2(t):eC(t)},R1=function(e,t){return e==="v"?tC(t):nC(t)},rC=function(e,t){return e==="h"&&t==="rtl"?-1:1},oC=function(e,t,n,r,o){var i=rC(e,window.getComputedStyle(t).direction),l=i*r,a=n.target,s=t.contains(a),u=!1,p=l>0,c=0,d=0;do{var f=R1(e,a),h=f[0],m=f[1],w=f[2],g=m-w-i*h;(h||g)&&_1(e,a)&&(c+=g,d+=h),a=a.parentNode}while(!s&&a!==document.body||s&&(t.contains(a)||t===a));return(p&&(o&&c===0||!o&&l>c)||!p&&(o&&d===0||!o&&-l>d))&&(u=!0),u},fl=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},ph=function(e){return[e.deltaX,e.deltaY]},fh=function(e){return e&&"current"in e?e.current:e},iC=function(e,t){return e[0]===t[0]&&e[1]===t[1]},lC=function(e){return` .block-interactivity-`.concat(e,` {pointer-events: none;} .allow-interactivity-`).concat(e,` {pointer-events: all;} -`)},rC=0,Fr=[];function oC(e){var t=b.useRef([]),n=b.useRef([0,0]),r=b.useRef(),o=b.useState(rC++)[0],i=b.useState(function(){return C1()})[0],l=b.useRef(e);b.useEffect(function(){l.current=e},[e]),b.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(o));var m=P2([e.lockRef.current],(e.shards||[]).map(ph),!0).filter(Boolean);return m.forEach(function(w){return w.classList.add("allow-interactivity-".concat(o))}),function(){document.body.classList.remove("block-interactivity-".concat(o)),m.forEach(function(w){return w.classList.remove("allow-interactivity-".concat(o))})}}},[e.inert,e.lockRef.current,e.shards]);var a=b.useCallback(function(m,w){if("touches"in m&&m.touches.length===2)return!l.current.allowPinchZoom;var g=cl(m),y=n.current,v="deltaX"in m?m.deltaX:y[0]-g[0],C="deltaY"in m?m.deltaY:y[1]-g[1],E,k=m.target,T=Math.abs(v)>Math.abs(C)?"h":"v";if("touches"in m&&T==="h"&&k.type==="range")return!1;var A=uh(T,k);if(!A)return!0;if(A?E=T:(E=T==="v"?"h":"v",A=uh(T,k)),!A)return!1;if(!r.current&&"changedTouches"in m&&(v||C)&&(r.current=E),!E)return!0;var N=r.current||E;return eC(N,w,m,N==="h"?v:C,!0)},[]),s=b.useCallback(function(m){var w=m;if(!(!Fr.length||Fr[Fr.length-1]!==i)){var g="deltaY"in w?ch(w):cl(w),y=t.current.filter(function(E){return E.name===w.type&&E.target===w.target&&tC(E.delta,g)})[0];if(y&&y.should){w.cancelable&&w.preventDefault();return}if(!y){var v=(l.current.shards||[]).map(ph).filter(Boolean).filter(function(E){return E.contains(w.target)}),C=v.length>0?a(w,v[0]):!l.current.noIsolation;C&&w.cancelable&&w.preventDefault()}}},[]),u=b.useCallback(function(m,w,g,y){var v={name:m,delta:w,target:g,should:y};t.current.push(v),setTimeout(function(){t.current=t.current.filter(function(C){return C!==v})},1)},[]),c=b.useCallback(function(m){n.current=cl(m),r.current=void 0},[]),p=b.useCallback(function(m){u(m.type,ch(m),m.target,a(m,e.lockRef.current))},[]),d=b.useCallback(function(m){u(m.type,cl(m),m.target,a(m,e.lockRef.current))},[]);b.useEffect(function(){return Fr.push(i),e.setCallbacks({onScrollCapture:p,onWheelCapture:p,onTouchMoveCapture:d}),document.addEventListener("wheel",s,Ir),document.addEventListener("touchmove",s,Ir),document.addEventListener("touchstart",c,Ir),function(){Fr=Fr.filter(function(m){return m!==i}),document.removeEventListener("wheel",s,Ir),document.removeEventListener("touchmove",s,Ir),document.removeEventListener("touchstart",c,Ir)}},[]);var f=e.removeScrollBar,h=e.inert;return b.createElement(b.Fragment,null,h?b.createElement(i,{styles:nC(o)}):null,f?b.createElement(q2,{gapMode:"margin"}):null)}const iC=D2(S1,oC);var O1=b.forwardRef(function(e,t){return b.createElement(Va,on({},e,{ref:t,sideCar:iC}))});O1.classNames=Va.classNames;const lC=O1;var aC=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},jr=new WeakMap,pl=new WeakMap,fl={},iu=0,A1=function(e){return e&&(e.host||A1(e.parentNode))},sC=function(e,t){return t.map(function(n){if(e.contains(n))return n;var r=A1(n);return r&&e.contains(r)?r:(console.error("aria-hidden",n,"in not contained inside",e,". Doing nothing"),null)}).filter(function(n){return!!n})},uC=function(e,t,n,r){var o=sC(t,Array.isArray(e)?e:[e]);fl[n]||(fl[n]=new WeakMap);var i=fl[n],l=[],a=new Set,s=new Set(o),u=function(p){!p||a.has(p)||(a.add(p),u(p.parentNode))};o.forEach(u);var c=function(p){!p||s.has(p)||Array.prototype.forEach.call(p.children,function(d){if(a.has(d))c(d);else{var f=d.getAttribute(r),h=f!==null&&f!=="false",m=(jr.get(d)||0)+1,w=(i.get(d)||0)+1;jr.set(d,m),i.set(d,w),l.push(d),m===1&&h&&pl.set(d,!0),w===1&&d.setAttribute(n,"true"),h||d.setAttribute(r,"true")}})};return c(t),a.clear(),iu++,function(){l.forEach(function(p){var d=jr.get(p)-1,f=i.get(p)-1;jr.set(p,d),i.set(p,f),d||(pl.has(p)||p.removeAttribute(r),pl.delete(p)),f||p.removeAttribute(n)}),iu--,iu||(jr=new WeakMap,jr=new WeakMap,pl=new WeakMap,fl={})}},cC=function(e,t,n){n===void 0&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),o=t||aC(e);return o?(r.push.apply(r,Array.from(o.querySelectorAll("[aria-live]"))),uC(r,o,n,"aria-hidden")):function(){return null}};const _1="Dialog",[$1,e$]=qp(_1),[pC,fn]=$1(_1),fC=e=>{const{__scopeDialog:t,children:n,open:r,defaultOpen:o,onOpenChange:i,modal:l=!0}=e,a=b.useRef(null),s=b.useRef(null),[u=!1,c]=g1({prop:r,defaultProp:o,onChange:i});return b.createElement(pC,{scope:t,triggerRef:a,contentRef:s,contentId:zl(),titleId:zl(),descriptionId:zl(),open:u,onOpenChange:c,onOpenToggle:b.useCallback(()=>c(p=>!p),[c]),modal:l},n)},dC="DialogTrigger",hC=b.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=fn(dC,n),i=pn(t,o.triggerRef);return b.createElement(jt.button,ye({type:"button","aria-haspopup":"dialog","aria-expanded":o.open,"aria-controls":o.contentId,"data-state":Qp(o.open)},r,{ref:i,onClick:ft(e.onClick,o.onOpenToggle)}))}),mC="DialogPortal",[t$,R1]=$1(mC,{forceMount:void 0}),Pc="DialogOverlay",gC=b.forwardRef((e,t)=>{const n=R1(Pc,e.__scopeDialog),{forceMount:r=n.forceMount,...o}=e,i=fn(Pc,e.__scopeDialog);return i.modal?b.createElement(Wa,{present:r||i.open},b.createElement(yC,ye({},o,{ref:t}))):null}),yC=b.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=fn(Pc,n);return b.createElement(lC,{as:Yp,allowPinchZoom:!0,shards:[o.contentRef]},b.createElement(jt.div,ye({"data-state":Qp(o.open)},r,{ref:t,style:{pointerEvents:"auto",...r.style}})))}),Ei="DialogContent",vC=b.forwardRef((e,t)=>{const n=R1(Ei,e.__scopeDialog),{forceMount:r=n.forceMount,...o}=e,i=fn(Ei,e.__scopeDialog);return b.createElement(Wa,{present:r||i.open},i.modal?b.createElement(wC,ye({},o,{ref:t})):b.createElement(xC,ye({},o,{ref:t})))}),wC=b.forwardRef((e,t)=>{const n=fn(Ei,e.__scopeDialog),r=b.useRef(null),o=pn(t,n.contentRef,r);return b.useEffect(()=>{const i=r.current;if(i)return cC(i)},[]),b.createElement(L1,ye({},e,{ref:o,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:ft(e.onCloseAutoFocus,i=>{var l;i.preventDefault(),(l=n.triggerRef.current)===null||l===void 0||l.focus()}),onPointerDownOutside:ft(e.onPointerDownOutside,i=>{const l=i.detail.originalEvent,a=l.button===0&&l.ctrlKey===!0;(l.button===2||a)&&i.preventDefault()}),onFocusOutside:ft(e.onFocusOutside,i=>i.preventDefault())}))}),xC=b.forwardRef((e,t)=>{const n=fn(Ei,e.__scopeDialog),r=b.useRef(!1),o=b.useRef(!1);return b.createElement(L1,ye({},e,{ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:i=>{var l;if((l=e.onCloseAutoFocus)===null||l===void 0||l.call(e,i),!i.defaultPrevented){var a;r.current||(a=n.triggerRef.current)===null||a===void 0||a.focus(),i.preventDefault()}r.current=!1,o.current=!1},onInteractOutside:i=>{var l,a;(l=e.onInteractOutside)===null||l===void 0||l.call(e,i),i.defaultPrevented||(r.current=!0,i.detail.originalEvent.type==="pointerdown"&&(o.current=!0));const s=i.target;((a=n.triggerRef.current)===null||a===void 0?void 0:a.contains(s))&&i.preventDefault(),i.detail.originalEvent.type==="focusin"&&o.current&&i.preventDefault()}}))}),L1=b.forwardRef((e,t)=>{const{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:o,onCloseAutoFocus:i,...l}=e,a=fn(Ei,n),s=b.useRef(null),u=pn(t,s);return E2(),b.createElement(b.Fragment,null,b.createElement(g2,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:o,onUnmountAutoFocus:i},b.createElement(v1,ye({role:"dialog",id:a.contentId,"aria-describedby":a.descriptionId,"aria-labelledby":a.titleId,"data-state":Qp(a.open)},l,{ref:u,onDismiss:()=>a.onOpenChange(!1)}))),!1)}),bC="DialogTitle",kC=b.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=fn(bC,n);return b.createElement(jt.h2,ye({id:o.titleId},r,{ref:t}))}),SC="DialogDescription",CC=b.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=fn(SC,n);return b.createElement(jt.p,ye({id:o.descriptionId},r,{ref:t}))}),EC="DialogClose",PC=b.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=fn(EC,n);return b.createElement(jt.button,ye({type:"button"},r,{ref:t,onClick:ft(e.onClick,()=>o.onOpenChange(!1))}))});function Qp(e){return e?"open":"closed"}const TC=fC,OC=hC,AC=gC,z1=vC,D1=kC,N1=CC,_C=PC,$C=TC,fh=_C,RC=OC,LC=AC,I1=b.forwardRef(({className:e,children:t,...n},r)=>L.jsx(LC,{className:"opencopilot-absolute opencopilot-inset-0 opencopilot-z-50 opencopilot-bg-black/50 opencopilot-backdrop-blur-sm data-[state=open]:opencopilot-animate-in data-[state=closed]:opencopilot-animate-out data-[state=closed]:opencopilot-fade-out-0 data-[state=open]:opencopilot-fade-in-0",children:L.jsx(z1,{ref:r,className:On("opencopilot-rounded-t-lg opencopilot-z-[100] opencopilot-absolute opencopilot-bottom-0 opencopilot-duration-300 opencopilot-w-full opencopilot-grid opencopilot-max-w-lg opencopilot-bg-white opencopilot-gap-4 opencopilot-shadow-lg opencopilot-p-6 opencopilot-animate-in data-[state=closed]:opencopilot-animate-out data-[state=closed]:opencopilot-fade-out-0 data-[state=open]:opencopilot-fade-in-0 data-[state=closed]:slide-out-to-bottom data-[state=open]:opencopilot-slide-in-from-bottom",e),...n,children:t})}));I1.displayName=z1.displayName;const F1=({className:e,...t})=>L.jsx("div",{className:On("opencopilot-flex opencopilot-flex-col opencopilot-space-y-1.5 opencopilot-text-center sm:opencopilot-text-left",e),...t});F1.displayName="DialogHeader";const zC=b.forwardRef(({className:e,...t},n)=>L.jsx(D1,{ref:n,className:On("opencopilot-text-lg opencopilot-font-semibold opencopilot-leading-none opencopilot-tracking-tight",e),...t}));zC.displayName=D1.displayName;const DC=b.forwardRef(({className:e,...t},n)=>L.jsx(N1,{ref:n,className:On("opencopilot-text-sm opencopilot-text-muted-foreground",e),...t}));DC.displayName=N1.displayName;function NC(){const[,,e]=I0();return L.jsx("header",{className:"opencopilot-fade-in-top opencopilot-border-b opencopilot-border-b-black/10 opencopilot-w-full",children:L.jsx("div",{className:"opencopilot-p-3",children:L.jsxs("div",{className:"opencopilot-w-full opencopilot-flex opencopilot-items-center opencopilot-justify-between",children:[L.jsx("div",{children:L.jsx("h1",{className:"opencopilot-font-semibold opencopilot-text-sm",children:"OpenPilot"})}),L.jsx("div",{className:"opencopilot-flex opencopilot-items-center opencopilot-gap-3",children:L.jsxs($C,{children:[L.jsx(RC,{children:L.jsx(e2,{size:19})}),L.jsxs(I1,{children:[L.jsx(F1,{children:"Are you sure?"}),L.jsxs("div",{className:"opencopilot-space-y-1",children:[L.jsx(fh,{onClick:()=>{setTimeout(()=>{e(!1)},100)},className:"opencopilot-block opencopilot-w-full opencopilot-px-2 opencopilot-text-white opencopilot-shadow opencopilot-py-1 opencopilot-border opencopilot-border-transparent opencopilot-rounded-md opencopilot-bg-rose-500",children:L.jsx("span",{children:"Exit"})}),L.jsx(fh,{className:"opencopilot-block opencopilot-w-full opencopilot-px-2 opencopilot-shadow opencopilot-py-1 opencopilot-border opencopilot-border-accent2 opencopilot-rounded-md opencopilot-text-black",children:L.jsx("span",{children:"Cancel"})})]})]})]})})]})})})}var IC=function(e){return{display:e?"flex":"none"}},FC="#4fa94d",jC={"aria-busy":!0,role:"status"},dh=globalThis&&globalThis.__assign||function(){return dh=Object.assign||function(e){for(var t,n=1,r=arguments.length;nMath.abs(C)?"h":"v";if("touches"in m&&O==="h"&&k.type==="range")return!1;var T=ch(O,k);if(!T)return!0;if(T?E=O:(E=O==="v"?"h":"v",T=ch(O,k)),!T)return!1;if(!r.current&&"changedTouches"in m&&(v||C)&&(r.current=E),!E)return!0;var N=r.current||E;return oC(N,w,m,N==="h"?v:C,!0)},[]),s=x.useCallback(function(m){var w=m;if(!(!jr.length||jr[jr.length-1]!==i)){var g="deltaY"in w?ph(w):fl(w),y=t.current.filter(function(E){return E.name===w.type&&E.target===w.target&&iC(E.delta,g)})[0];if(y&&y.should){w.cancelable&&w.preventDefault();return}if(!y){var v=(l.current.shards||[]).map(fh).filter(Boolean).filter(function(E){return E.contains(w.target)}),C=v.length>0?a(w,v[0]):!l.current.noIsolation;C&&w.cancelable&&w.preventDefault()}}},[]),u=x.useCallback(function(m,w,g,y){var v={name:m,delta:w,target:g,should:y};t.current.push(v),setTimeout(function(){t.current=t.current.filter(function(C){return C!==v})},1)},[]),p=x.useCallback(function(m){n.current=fl(m),r.current=void 0},[]),c=x.useCallback(function(m){u(m.type,ph(m),m.target,a(m,e.lockRef.current))},[]),d=x.useCallback(function(m){u(m.type,fl(m),m.target,a(m,e.lockRef.current))},[]);x.useEffect(function(){return jr.push(i),e.setCallbacks({onScrollCapture:c,onWheelCapture:c,onTouchMoveCapture:d}),document.addEventListener("wheel",s,Fr),document.addEventListener("touchmove",s,Fr),document.addEventListener("touchstart",p,Fr),function(){jr=jr.filter(function(m){return m!==i}),document.removeEventListener("wheel",s,Fr),document.removeEventListener("touchmove",s,Fr),document.removeEventListener("touchstart",p,Fr)}},[]);var f=e.removeScrollBar,h=e.inert;return x.createElement(x.Fragment,null,h?x.createElement(i,{styles:lC(o)}):null,f?x.createElement(X2,{gapMode:"margin"}):null)}const uC=j2(T1,sC);var L1=x.forwardRef(function(e,t){return x.createElement(Qa,ln({},e,{ref:t,sideCar:uC}))});L1.classNames=Qa.classNames;const cC=L1;var pC=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},Mr=new WeakMap,dl=new WeakMap,hl={},su=0,D1=function(e){return e&&(e.host||D1(e.parentNode))},fC=function(e,t){return t.map(function(n){if(e.contains(n))return n;var r=D1(n);return r&&e.contains(r)?r:(console.error("aria-hidden",n,"in not contained inside",e,". Doing nothing"),null)}).filter(function(n){return!!n})},dC=function(e,t,n,r){var o=fC(t,Array.isArray(e)?e:[e]);hl[n]||(hl[n]=new WeakMap);var i=hl[n],l=[],a=new Set,s=new Set(o),u=function(c){!c||a.has(c)||(a.add(c),u(c.parentNode))};o.forEach(u);var p=function(c){!c||s.has(c)||Array.prototype.forEach.call(c.children,function(d){if(a.has(d))p(d);else{var f=d.getAttribute(r),h=f!==null&&f!=="false",m=(Mr.get(d)||0)+1,w=(i.get(d)||0)+1;Mr.set(d,m),i.set(d,w),l.push(d),m===1&&h&&dl.set(d,!0),w===1&&d.setAttribute(n,"true"),h||d.setAttribute(r,"true")}})};return p(t),a.clear(),su++,function(){l.forEach(function(c){var d=Mr.get(c)-1,f=i.get(c)-1;Mr.set(c,d),i.set(c,f),d||(dl.has(c)||c.removeAttribute(r),dl.delete(c)),f||c.removeAttribute(n)}),su--,su||(Mr=new WeakMap,Mr=new WeakMap,dl=new WeakMap,hl={})}},hC=function(e,t,n){n===void 0&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),o=t||pC(e);return o?(r.push.apply(r,Array.from(o.querySelectorAll("[aria-live]"))),dC(r,o,n,"aria-hidden")):function(){return null}};const z1="Dialog",[N1,h_]=Qp(z1),[mC,fn]=N1(z1),gC=e=>{const{__scopeDialog:t,children:n,open:r,defaultOpen:o,onOpenChange:i,modal:l=!0}=e,a=x.useRef(null),s=x.useRef(null),[u=!1,p]=x1({prop:r,defaultProp:o,onChange:i});return x.createElement(mC,{scope:t,triggerRef:a,contentRef:s,contentId:Il(),titleId:Il(),descriptionId:Il(),open:u,onOpenChange:p,onOpenToggle:x.useCallback(()=>p(c=>!c),[p]),modal:l},n)},yC="DialogTrigger",vC=x.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=fn(yC,n),i=en(t,o.triggerRef);return x.createElement(Tt.button,ge({type:"button","aria-haspopup":"dialog","aria-expanded":o.open,"aria-controls":o.contentId,"data-state":Xp(o.open)},r,{ref:i,onClick:Xe(e.onClick,o.onOpenToggle)}))}),wC="DialogPortal",[m_,I1]=N1(wC,{forceMount:void 0}),Tc="DialogOverlay",xC=x.forwardRef((e,t)=>{const n=I1(Tc,e.__scopeDialog),{forceMount:r=n.forceMount,...o}=e,i=fn(Tc,e.__scopeDialog);return i.modal?x.createElement(Ya,{present:r||i.open},x.createElement(bC,ge({},o,{ref:t}))):null}),bC=x.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=fn(Tc,n);return x.createElement(cC,{as:Kp,allowPinchZoom:!0,shards:[o.contentRef]},x.createElement(Tt.div,ge({"data-state":Xp(o.open)},r,{ref:t,style:{pointerEvents:"auto",...r.style}})))}),Pi="DialogContent",kC=x.forwardRef((e,t)=>{const n=I1(Pi,e.__scopeDialog),{forceMount:r=n.forceMount,...o}=e,i=fn(Pi,e.__scopeDialog);return x.createElement(Ya,{present:r||i.open},i.modal?x.createElement(SC,ge({},o,{ref:t})):x.createElement(CC,ge({},o,{ref:t})))}),SC=x.forwardRef((e,t)=>{const n=fn(Pi,e.__scopeDialog),r=x.useRef(null),o=en(t,n.contentRef,r);return x.useEffect(()=>{const i=r.current;if(i)return hC(i)},[]),x.createElement(F1,ge({},e,{ref:o,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:Xe(e.onCloseAutoFocus,i=>{var l;i.preventDefault(),(l=n.triggerRef.current)===null||l===void 0||l.focus()}),onPointerDownOutside:Xe(e.onPointerDownOutside,i=>{const l=i.detail.originalEvent,a=l.button===0&&l.ctrlKey===!0;(l.button===2||a)&&i.preventDefault()}),onFocusOutside:Xe(e.onFocusOutside,i=>i.preventDefault())}))}),CC=x.forwardRef((e,t)=>{const n=fn(Pi,e.__scopeDialog),r=x.useRef(!1),o=x.useRef(!1);return x.createElement(F1,ge({},e,{ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:i=>{var l;if((l=e.onCloseAutoFocus)===null||l===void 0||l.call(e,i),!i.defaultPrevented){var a;r.current||(a=n.triggerRef.current)===null||a===void 0||a.focus(),i.preventDefault()}r.current=!1,o.current=!1},onInteractOutside:i=>{var l,a;(l=e.onInteractOutside)===null||l===void 0||l.call(e,i),i.defaultPrevented||(r.current=!0,i.detail.originalEvent.type==="pointerdown"&&(o.current=!0));const s=i.target;((a=n.triggerRef.current)===null||a===void 0?void 0:a.contains(s))&&i.preventDefault(),i.detail.originalEvent.type==="focusin"&&o.current&&i.preventDefault()}}))}),F1=x.forwardRef((e,t)=>{const{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:o,onCloseAutoFocus:i,...l}=e,a=fn(Pi,n),s=x.useRef(null),u=en(t,s);return A2(),x.createElement(x.Fragment,null,x.createElement(x2,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:o,onUnmountAutoFocus:i},x.createElement(y2,ge({role:"dialog",id:a.contentId,"aria-describedby":a.descriptionId,"aria-labelledby":a.titleId,"data-state":Xp(a.open)},l,{ref:u,onDismiss:()=>a.onOpenChange(!1)}))),!1)}),EC="DialogTitle",PC=x.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=fn(EC,n);return x.createElement(Tt.h2,ge({id:o.titleId},r,{ref:t}))}),OC="DialogDescription",TC=x.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=fn(OC,n);return x.createElement(Tt.p,ge({id:o.descriptionId},r,{ref:t}))}),AC="DialogClose",$C=x.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=fn(AC,n);return x.createElement(Tt.button,ge({type:"button"},r,{ref:t,onClick:Xe(e.onClick,()=>o.onOpenChange(!1))}))});function Xp(e){return e?"open":"closed"}const _C=gC,RC=vC,LC=xC,j1=kC,M1=PC,B1=TC,DC=$C,zC=_C,dh=DC,NC=RC,IC=LC,U1=x.forwardRef(({className:e,children:t,...n},r)=>L.jsx(IC,{className:"opencopilot-absolute opencopilot-inset-0 opencopilot-z-50 opencopilot-bg-black/50 opencopilot-backdrop-blur-sm data-[state=open]:opencopilot-animate-in data-[state=closed]:opencopilot-animate-out data-[state=closed]:opencopilot-fade-out-0 data-[state=open]:opencopilot-fade-in-0",children:L.jsx(j1,{ref:r,className:Tn("opencopilot-rounded-t-lg opencopilot-z-[100] opencopilot-absolute opencopilot-bottom-0 opencopilot-duration-300 opencopilot-w-full opencopilot-grid opencopilot-max-w-lg opencopilot-bg-white opencopilot-gap-4 opencopilot-shadow-lg opencopilot-p-6 opencopilot-animate-in data-[state=closed]:opencopilot-animate-out data-[state=closed]:opencopilot-fade-out-0 data-[state=open]:opencopilot-fade-in-0 data-[state=closed]:slide-out-to-bottom data-[state=open]:opencopilot-slide-in-from-bottom",e),...n,children:t})}));U1.displayName=j1.displayName;const H1=({className:e,...t})=>L.jsx("div",{className:Tn("opencopilot-flex opencopilot-flex-col opencopilot-space-y-1.5 opencopilot-text-center sm:opencopilot-text-left",e),...t});H1.displayName="DialogHeader";const FC=x.forwardRef(({className:e,...t},n)=>L.jsx(M1,{ref:n,className:Tn("opencopilot-text-lg opencopilot-font-semibold opencopilot-leading-none opencopilot-tracking-tight",e),...t}));FC.displayName=M1.displayName;const jC=x.forwardRef(({className:e,...t},n)=>L.jsx(B1,{ref:n,className:Tn("opencopilot-text-sm opencopilot-text-muted-foreground",e),...t}));jC.displayName=B1.displayName;function MC(){const[,,e]=B0();return L.jsx("header",{className:"opencopilot-fade-in-top opencopilot-border-b opencopilot-border-b-black/10 opencopilot-w-full",children:L.jsx("div",{className:"opencopilot-p-3",children:L.jsxs("div",{className:"opencopilot-w-full opencopilot-flex opencopilot-items-center opencopilot-justify-between",children:[L.jsx("div",{children:L.jsx("h1",{className:"opencopilot-font-semibold opencopilot-text-sm",children:"OpenPilot"})}),L.jsx("div",{className:"opencopilot-flex opencopilot-items-center opencopilot-gap-3",children:L.jsxs(zC,{children:[L.jsx(NC,{children:L.jsx(i2,{size:19})}),L.jsxs(U1,{children:[L.jsx(H1,{className:"opencopilot-mx-auto",children:"Are you sure?"}),L.jsxs("div",{className:"opencopilot-space-y-1.5",children:[L.jsx(dh,{onClick:()=>{setTimeout(()=>{e(!1)},100)},className:"opencopilot-block opencopilot-w-full opencopilot-px-2 opencopilot-text-white opencopilot-shadow opencopilot-py-1 opencopilot-border opencopilot-border-transparent opencopilot-rounded-md opencopilot-bg-rose-500",children:L.jsx("span",{children:"Exit"})}),L.jsx(dh,{className:"opencopilot-block opencopilot-w-full opencopilot-px-2 opencopilot-py-1 opencopilot-rounded-md opencopilot-text-black",children:L.jsx("span",{children:"Cancel"})})]})]})]})})]})})})}var BC=function(e){return{display:e?"flex":"none"}},UC="#4fa94d",HC={"aria-busy":!0,role:"status"},hh=globalThis&&globalThis.__assign||function(){return hh=Object.assign||function(e){for(var t,n=1,r=arguments.length;npe)&&(Ne=(te=te.replace(" ",":")).length),0Q&&(Q=(x=x.trim()).charCodeAt(0)),Q){case 38:return x.replace(g,"$1"+F.trim());case 58:return F.trim()+x.replace(g,"$1"+F.trim());default:if(0<1*U&&0B.charCodeAt(8))break;case 115:O=O.replace(B,"-webkit-"+B)+";"+O;break;case 207:case 102:O=O.replace(B,"-webkit-"+(102U.charCodeAt(0)&&(U=U.trim()),Z=U,U=[Z],0pe)&&(Ee=(ee=ee.replace(" ",":")).length),0Y&&(Y=(b=b.trim()).charCodeAt(0)),Y){case 38:return b.replace(g,"$1"+I.trim());case 58:return I.trim()+b.replace(g,"$1"+I.trim());default:if(0<1*U&&0B.charCodeAt(8))break;case 115:A=A.replace(B,"-webkit-"+B)+";"+A;break;case 207:case 102:A=A.replace(B,"-webkit-"+(102U.charCodeAt(0)&&(U=U.trim()),X=U,U=[X],01?t-1:0),r=1;r0?" Args: "+n.join(", "):""))}var cE=function(){function e(n){this.groupSizes=new Uint32Array(512),this.length=512,this.tag=n}var t=e.prototype;return t.indexOfGroup=function(n){for(var r=0,o=0;o=this.groupSizes.length){for(var o=this.groupSizes,i=o.length,l=i;n>=l;)(l<<=1)<0&&Fi(16,""+n);this.groupSizes=new Uint32Array(l),this.groupSizes.set(o),this.length=l;for(var a=i;a=this.length||this.groupSizes[n]===0)return r;for(var o=this.groupSizes[n],i=this.indexOfGroup(n),l=i+o,a=i;a=oi&&(oi=t+1),Il.set(e,t),da.set(t,e)},dE="style["+vo+'][data-styled-version="5.3.11"]',hE=new RegExp("^"+vo+'\\.g(\\d+)\\[id="([\\w\\d-]+)"\\].*?"([^"]*)'),mE=function(e,t,n){for(var r,o=n.split(","),i=0,l=o.length;i=0;u--){var c=s[u];if(c&&c.nodeType===1&&c.hasAttribute(vo))return c}}(n),i=o!==void 0?o.nextSibling:null;r.setAttribute(vo,"active"),r.setAttribute("data-styled-version","5.3.11");var l=yE();return l&&r.setAttribute("nonce",l),n.insertBefore(r,i),r},vE=function(){function e(n){var r=this.element=V1(n);r.appendChild(document.createTextNode("")),this.sheet=function(o){if(o.sheet)return o.sheet;for(var i=document.styleSheets,l=0,a=i.length;l=0){var o=document.createTextNode(r),i=this.nodes[n];return this.element.insertBefore(o,i||null),this.length++,!0}return!1},t.deleteRule=function(n){this.element.removeChild(this.nodes[n]),this.length--},t.getRule=function(n){return n0&&(p+=d+",")}),i+=""+u+c+'{content:"'+p+`"}/*!sc*/ -`}}}return i}(this)},e}(),kE=/(a)(d)/gi,Ph=function(e){return String.fromCharCode(e+(e>25?39:97))};function Oc(e){var t,n="";for(t=Math.abs(e);t>52;t=t/52|0)n=Ph(t%52)+n;return(Ph(t%52)+n).replace(kE,"$1-$2")}var Jr=function(e,t){for(var n=t.length;n;)e=33*e^t.charCodeAt(--n);return e},q1=function(e){return Jr(5381,e)};function SE(e){for(var t=0;t>>0);if(!n.hasNameForId(o,a)){var s=r(l,"."+a,void 0,o);n.insertRules(o,a,s)}i.push(a),this.staticRulesId=a}else{for(var u=this.rules.length,c=Jr(this.baseHash,r.hash),p="",d=0;d>>0);if(!n.hasNameForId(o,w)){var g=r(p,"."+w,void 0,o);n.insertRules(o,w,g)}i.push(w)}}return i.join(" ")},e}(),PE=/^\s*\/\/.*$/gm,TE=[":","[",".","#"];function OE(e){var t,n,r,o,i=e===void 0?nr:e,l=i.options,a=l===void 0?nr:l,s=i.plugins,u=s===void 0?fa:s,c=new WC(a),p=[],d=function(m){function w(g){if(g)try{m(g+"}")}catch{}}return function(g,y,v,C,E,k,T,A,N,P){switch(g){case 1:if(N===0&&y.charCodeAt(0)===64)return m(y+";"),"";break;case 2:if(A===0)return y+"/*|*/";break;case 3:switch(A){case 102:case 112:return m(v[0]+y),"";default:return y+(P===0?"/*|*/":"")}case-2:y.split("/*|*/}").forEach(w)}}}(function(m){p.push(m)}),f=function(m,w,g){return w===0&&TE.indexOf(g[n.length])!==-1||g.match(o)?m:"."+t};function h(m,w,g,y){y===void 0&&(y="&");var v=m.replace(PE,""),C=w&&g?g+" "+w+" { "+v+" }":v;return t=y,n=w,r=new RegExp("\\"+n+"\\b","g"),o=new RegExp("(\\"+n+"\\b){2,}"),c(g||!w?"":w,C)}return c.use([].concat(u,[function(m,w,g){m===2&&g.length&&g[0].lastIndexOf(n)>0&&(g[0]=g[0].replace(r,f))},d,function(m){if(m===-2){var w=p;return p=[],w}}])),h.hash=u.length?u.reduce(function(m,w){return w.name||Fi(15),Jr(m,w.name)},5381).toString():"",h}var Y1=ae.createContext();Y1.Consumer;var Q1=ae.createContext(),AE=(Q1.Consumer,new G1),Ac=OE();function _E(){return b.useContext(Y1)||AE}function $E(){return b.useContext(Q1)||Ac}var K1=function(){function e(t,n){var r=this;this.inject=function(o,i){i===void 0&&(i=Ac);var l=r.name+i.hash;o.hasNameForId(r.id,l)||o.insertRules(r.id,l,i(r.rules,l,"@keyframes"))},this.toString=function(){return Fi(12,String(r.name))},this.name=t,this.id="sc-keyframes-"+t,this.rules=n}return e.prototype.getName=function(t){return t===void 0&&(t=Ac),this.name+t.hash},e}(),RE=/([A-Z])/,LE=/([A-Z])/g,zE=/^ms-/,DE=function(e){return"-"+e.toLowerCase()};function Th(e){return RE.test(e)?e.replace(LE,DE).replace(zE,"-ms-"):e}var Oh=function(e){return e==null||e===!1||e===""};function wo(e,t,n,r){if(Array.isArray(e)){for(var o,i=[],l=0,a=e.length;l1?t-1:0),r=1;r?@[\\\]^`{|}~-]+/g,FE=/(^-|-$)/g;function lu(e){return e.replace(IE,"-").replace(FE,"")}var Z1=function(e){return Oc(q1(e)>>>0)};function hl(e){return typeof e=="string"&&!0}var _c=function(e){return typeof e=="function"||typeof e=="object"&&e!==null&&!Array.isArray(e)},jE=function(e){return e!=="__proto__"&&e!=="constructor"&&e!=="prototype"};function ME(e,t,n){var r=e[n];_c(t)&&_c(r)?J1(r,t):e[n]=t}function J1(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r=0||(P[A]=k[A]);return P}(t,["componentId"]),E=v&&v+"-"+(hl(y)?y:lu(Ch(y)));return tv(y,bn({},C,{attrs:d,componentId:E}),n)},Object.defineProperty(h,"defaultProps",{get:function(){return this._foldedDefaultProps},set:function(y){this._foldedDefaultProps=r?J1({},e.defaultProps,y):y}}),Object.defineProperty(h,"toString",{value:function(){return"."+h.styledComponentId}}),o&&sE(h,e,{attrs:!0,componentStyle:!0,displayName:!0,foldedComponentIds:!0,shouldForwardProp:!0,styledComponentId:!0,target:!0,withComponent:!0}),h}var $c=function(e){return function t(n,r,o){if(o===void 0&&(o=nr),!Zp.isValidElementType(r))return Fi(1,String(r));var i=function(){return n(r,o,X1.apply(void 0,arguments))};return i.withConfig=function(l){return t(n,r,bn({},o,{},l))},i.attrs=function(l){return t(n,r,bn({},o,{attrs:Array.prototype.concat(o.attrs,l).filter(Boolean)}))},i}(tv,e)};["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","marquee","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","marker","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","textPath","tspan"].forEach(function(e){$c[e]=$c(e)});function af(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r1?t-1:0),r=1;r0?" Args: "+n.join(", "):""))}var hE=function(){function e(n){this.groupSizes=new Uint32Array(512),this.length=512,this.tag=n}var t=e.prototype;return t.indexOfGroup=function(n){for(var r=0,o=0;o=this.groupSizes.length){for(var o=this.groupSizes,i=o.length,l=i;n>=l;)(l<<=1)<0&&Fi(16,""+n);this.groupSizes=new Uint32Array(l),this.groupSizes.set(o),this.length=l;for(var a=i;a=this.length||this.groupSizes[n]===0)return r;for(var o=this.groupSizes[n],i=this.indexOfGroup(n),l=i+o,a=i;a=ii&&(ii=t+1),Ml.set(e,t),ga.set(t,e)},yE="style["+wo+'][data-styled-version="5.3.11"]',vE=new RegExp("^"+wo+'\\.g(\\d+)\\[id="([\\w\\d-]+)"\\].*?"([^"]*)'),wE=function(e,t,n){for(var r,o=n.split(","),i=0,l=o.length;i=0;u--){var p=s[u];if(p&&p.nodeType===1&&p.hasAttribute(wo))return p}}(n),i=o!==void 0?o.nextSibling:null;r.setAttribute(wo,"active"),r.setAttribute("data-styled-version","5.3.11");var l=bE();return l&&r.setAttribute("nonce",l),n.insertBefore(r,i),r},kE=function(){function e(n){var r=this.element=K1(n);r.appendChild(document.createTextNode("")),this.sheet=function(o){if(o.sheet)return o.sheet;for(var i=document.styleSheets,l=0,a=i.length;l=0){var o=document.createTextNode(r),i=this.nodes[n];return this.element.insertBefore(o,i||null),this.length++,!0}return!1},t.deleteRule=function(n){this.element.removeChild(this.nodes[n]),this.length--},t.getRule=function(n){return n0&&(c+=d+",")}),i+=""+u+p+'{content:"'+c+`"}/*!sc*/ +`}}}return i}(this)},e}(),PE=/(a)(d)/gi,Oh=function(e){return String.fromCharCode(e+(e>25?39:97))};function $c(e){var t,n="";for(t=Math.abs(e);t>52;t=t/52|0)n=Oh(t%52)+n;return(Oh(t%52)+n).replace(PE,"$1-$2")}var eo=function(e,t){for(var n=t.length;n;)e=33*e^t.charCodeAt(--n);return e},Z1=function(e){return eo(5381,e)};function OE(e){for(var t=0;t>>0);if(!n.hasNameForId(o,a)){var s=r(l,"."+a,void 0,o);n.insertRules(o,a,s)}i.push(a),this.staticRulesId=a}else{for(var u=this.rules.length,p=eo(this.baseHash,r.hash),c="",d=0;d>>0);if(!n.hasNameForId(o,w)){var g=r(c,"."+w,void 0,o);n.insertRules(o,w,g)}i.push(w)}}return i.join(" ")},e}(),$E=/^\s*\/\/.*$/gm,_E=[":","[",".","#"];function RE(e){var t,n,r,o,i=e===void 0?nr:e,l=i.options,a=l===void 0?nr:l,s=i.plugins,u=s===void 0?ma:s,p=new YC(a),c=[],d=function(m){function w(g){if(g)try{m(g+"}")}catch{}}return function(g,y,v,C,E,k,O,T,N,P){switch(g){case 1:if(N===0&&y.charCodeAt(0)===64)return m(y+";"),"";break;case 2:if(T===0)return y+"/*|*/";break;case 3:switch(T){case 102:case 112:return m(v[0]+y),"";default:return y+(P===0?"/*|*/":"")}case-2:y.split("/*|*/}").forEach(w)}}}(function(m){c.push(m)}),f=function(m,w,g){return w===0&&_E.indexOf(g[n.length])!==-1||g.match(o)?m:"."+t};function h(m,w,g,y){y===void 0&&(y="&");var v=m.replace($E,""),C=w&&g?g+" "+w+" { "+v+" }":v;return t=y,n=w,r=new RegExp("\\"+n+"\\b","g"),o=new RegExp("(\\"+n+"\\b){2,}"),p(g||!w?"":w,C)}return p.use([].concat(u,[function(m,w,g){m===2&&g.length&&g[0].lastIndexOf(n)>0&&(g[0]=g[0].replace(r,f))},d,function(m){if(m===-2){var w=c;return c=[],w}}])),h.hash=u.length?u.reduce(function(m,w){return w.name||Fi(15),eo(m,w.name)},5381).toString():"",h}var J1=le.createContext();J1.Consumer;var ev=le.createContext(),LE=(ev.Consumer,new X1),_c=RE();function DE(){return x.useContext(J1)||LE}function zE(){return x.useContext(ev)||_c}var tv=function(){function e(t,n){var r=this;this.inject=function(o,i){i===void 0&&(i=_c);var l=r.name+i.hash;o.hasNameForId(r.id,l)||o.insertRules(r.id,l,i(r.rules,l,"@keyframes"))},this.toString=function(){return Fi(12,String(r.name))},this.name=t,this.id="sc-keyframes-"+t,this.rules=n}return e.prototype.getName=function(t){return t===void 0&&(t=_c),this.name+t.hash},e}(),NE=/([A-Z])/,IE=/([A-Z])/g,FE=/^ms-/,jE=function(e){return"-"+e.toLowerCase()};function Th(e){return NE.test(e)?e.replace(IE,jE).replace(FE,"-ms-"):e}var Ah=function(e){return e==null||e===!1||e===""};function xo(e,t,n,r){if(Array.isArray(e)){for(var o,i=[],l=0,a=e.length;l1?t-1:0),r=1;r?@[\\\]^`{|}~-]+/g,UE=/(^-|-$)/g;function uu(e){return e.replace(BE,"-").replace(UE,"")}var rv=function(e){return $c(Z1(e)>>>0)};function gl(e){return typeof e=="string"&&!0}var Rc=function(e){return typeof e=="function"||typeof e=="object"&&e!==null&&!Array.isArray(e)},HE=function(e){return e!=="__proto__"&&e!=="constructor"&&e!=="prototype"};function WE(e,t,n){var r=e[n];Rc(t)&&Rc(r)?ov(r,t):e[n]=t}function ov(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r=0||(P[T]=k[T]);return P}(t,["componentId"]),E=v&&v+"-"+(gl(y)?y:uu(Eh(y)));return lv(y,bn({},C,{attrs:d,componentId:E}),n)},Object.defineProperty(h,"defaultProps",{get:function(){return this._foldedDefaultProps},set:function(y){this._foldedDefaultProps=r?ov({},e.defaultProps,y):y}}),Object.defineProperty(h,"toString",{value:function(){return"."+h.styledComponentId}}),o&&fE(h,e,{attrs:!0,componentStyle:!0,displayName:!0,foldedComponentIds:!0,shouldForwardProp:!0,styledComponentId:!0,target:!0,withComponent:!0}),h}var Lc=function(e){return function t(n,r,o){if(o===void 0&&(o=nr),!ef.isValidElementType(r))return Fi(1,String(r));var i=function(){return n(r,o,nv.apply(void 0,arguments))};return i.withConfig=function(l){return t(n,r,bn({},o,{},l))},i.attrs=function(l){return t(n,r,bn({},o,{attrs:Array.prototype.concat(o.attrs,l).filter(Boolean)}))},i}(lv,e)};["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","marquee","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","marker","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","textPath","tspan"].forEach(function(e){Lc[e]=Lc(e)});function uf(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r0&&arguments[0]!==void 0?arguments[0]:{};if(typeof r[t]<"u")return r[t];if(t&&t.indexOf(".")>0){for(var o=t.split("."),i=o.length,l=r[o[0]],a=1;l!=null&&a0&&arguments[0]!==void 0?arguments[0]:{};if(typeof r[t]<"u")return r[t];if(t&&t.indexOf(".")>0){for(var o=t.split("."),i=o.length,l=r[o[0]],a=1;l!=null&&a({x:e,y:e}),qE={left:"right",right:"left",bottom:"top",top:"bottom"},YE={start:"end",end:"start"};function Rc(e,t,n){return xt(e,lr(t,n))}function An(e,t){return typeof e=="function"?e(t):e}function _n(e){return e.split("-")[0]}function Eo(e){return e.split("-")[1]}function cf(e){return e==="x"?"y":"x"}function pf(e){return e==="y"?"height":"width"}function Po(e){return["top","bottom"].includes(_n(e))?"y":"x"}function ff(e){return cf(Po(e))}function QE(e,t,n){n===void 0&&(n=!1);const r=Eo(e),o=ff(e),i=pf(o);let l=o==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[i]>t.floating[i]&&(l=ma(l)),[l,ma(l)]}function KE(e){const t=ma(e);return[Lc(e),t,Lc(t)]}function Lc(e){return e.replace(/start|end/g,t=>YE[t])}function XE(e,t,n){const r=["left","right"],o=["right","left"],i=["top","bottom"],l=["bottom","top"];switch(e){case"top":case"bottom":return n?t?o:r:t?r:o;case"left":case"right":return t?i:l;default:return[]}}function ZE(e,t,n,r){const o=Eo(e);let i=XE(_n(e),n==="start",r);return o&&(i=i.map(l=>l+"-"+o),t&&(i=i.concat(i.map(Lc)))),i}function ma(e){return e.replace(/left|right|bottom|top/g,t=>qE[t])}function JE(e){return{top:0,right:0,bottom:0,left:0,...e}}function rv(e){return typeof e!="number"?JE(e):{top:e,right:e,bottom:e,left:e}}function ga(e){return{...e,top:e.y,left:e.x,right:e.x+e.width,bottom:e.y+e.height}}function cm(e,t,n){let{reference:r,floating:o}=e;const i=Po(t),l=ff(t),a=pf(l),s=_n(t),u=i==="y",c=r.x+r.width/2-o.width/2,p=r.y+r.height/2-o.height/2,d=r[a]/2-o[a]/2;let f;switch(s){case"top":f={x:c,y:r.y-o.height};break;case"bottom":f={x:c,y:r.y+r.height};break;case"right":f={x:r.x+r.width,y:p};break;case"left":f={x:r.x-o.width,y:p};break;default:f={x:r.x,y:r.y}}switch(Eo(t)){case"start":f[l]-=d*(n&&u?-1:1);break;case"end":f[l]+=d*(n&&u?-1:1);break}return f}const e5=async(e,t,n)=>{const{placement:r="bottom",strategy:o="absolute",middleware:i=[],platform:l}=n,a=i.filter(Boolean),s=await(l.isRTL==null?void 0:l.isRTL(t));let u=await l.getElementRects({reference:e,floating:t,strategy:o}),{x:c,y:p}=cm(u,r,s),d=r,f={},h=0;for(let m=0;m({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:o,rects:i,platform:l,elements:a,middlewareData:s}=t,{element:u,padding:c=0}=An(e,t)||{};if(u==null)return{};const p=rv(c),d={x:n,y:r},f=ff(o),h=pf(f),m=await l.getDimensions(u),w=f==="y",g=w?"top":"left",y=w?"bottom":"right",v=w?"clientHeight":"clientWidth",C=i.reference[h]+i.reference[f]-d[f]-i.floating[h],E=d[f]-i.reference[f],k=await(l.getOffsetParent==null?void 0:l.getOffsetParent(u));let T=k?k[v]:0;(!T||!await(l.isElement==null?void 0:l.isElement(k)))&&(T=a.floating[v]||i.floating[h]);const A=C/2-E/2,N=T/2-m[h]/2-1,P=lr(p[g],N),z=lr(p[y],N),_=P,Y=T-m[h]-z,H=T/2-m[h]/2+A,W=Rc(_,H,Y),q=!s.arrow&&Eo(o)!=null&&H!=W&&i.reference[h]/2-(H<_?P:z)-m[h]/2<0,K=q?H<_?H-_:H-Y:0;return{[f]:d[f]+K,data:{[f]:W,centerOffset:H-W-K,...q&&{alignmentOffset:K}},reset:q}}}),t5=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:o,middlewareData:i,rects:l,initialPlacement:a,platform:s,elements:u}=t,{mainAxis:c=!0,crossAxis:p=!0,fallbackPlacements:d,fallbackStrategy:f="bestFit",fallbackAxisSideDirection:h="none",flipAlignment:m=!0,...w}=An(e,t);if((n=i.arrow)!=null&&n.alignmentOffset)return{};const g=_n(o),y=_n(a)===a,v=await(s.isRTL==null?void 0:s.isRTL(u.floating)),C=d||(y||!m?[ma(a)]:KE(a));!d&&h!=="none"&&C.push(...ZE(a,m,h,v));const E=[a,...C],k=await Ti(t,w),T=[];let A=((r=i.flip)==null?void 0:r.overflows)||[];if(c&&T.push(k[g]),p){const _=QE(o,l,v);T.push(k[_[0]],k[_[1]])}if(A=[...A,{placement:o,overflows:T}],!T.every(_=>_<=0)){var N,P;const _=(((N=i.flip)==null?void 0:N.index)||0)+1,Y=E[_];if(Y)return{data:{index:_,overflows:A},reset:{placement:Y}};let H=(P=A.filter(W=>W.overflows[0]<=0).sort((W,q)=>W.overflows[1]-q.overflows[1])[0])==null?void 0:P.placement;if(!H)switch(f){case"bestFit":{var z;const W=(z=A.map(q=>[q.placement,q.overflows.filter(K=>K>0).reduce((K,D)=>K+D,0)]).sort((q,K)=>q[1]-K[1])[0])==null?void 0:z[0];W&&(H=W);break}case"initialPlacement":H=a;break}if(o!==H)return{reset:{placement:H}}}return{}}}};function fm(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function dm(e){return GE.some(t=>e[t]>=0)}const n5=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n}=t,{strategy:r="referenceHidden",...o}=An(e,t);switch(r){case"referenceHidden":{const i=await Ti(t,{...o,elementContext:"reference"}),l=fm(i,n.reference);return{data:{referenceHiddenOffsets:l,referenceHidden:dm(l)}}}case"escaped":{const i=await Ti(t,{...o,altBoundary:!0}),l=fm(i,n.floating);return{data:{escapedOffsets:l,escaped:dm(l)}}}default:return{}}}}};async function r5(e,t){const{placement:n,platform:r,elements:o}=e,i=await(r.isRTL==null?void 0:r.isRTL(o.floating)),l=_n(n),a=Eo(n),s=Po(n)==="y",u=["left","top"].includes(l)?-1:1,c=i&&s?-1:1,p=An(t,e);let{mainAxis:d,crossAxis:f,alignmentAxis:h}=typeof p=="number"?{mainAxis:p,crossAxis:0,alignmentAxis:null}:{mainAxis:0,crossAxis:0,alignmentAxis:null,...p};return a&&typeof h=="number"&&(f=a==="end"?h*-1:h),s?{x:f*c,y:d*u}:{x:d*u,y:f*c}}const o5=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){const{x:n,y:r}=t,o=await r5(t,e);return{x:n+o.x,y:r+o.y,data:o}}}},i5=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:o}=t,{mainAxis:i=!0,crossAxis:l=!1,limiter:a={fn:w=>{let{x:g,y}=w;return{x:g,y}}},...s}=An(e,t),u={x:n,y:r},c=await Ti(t,s),p=Po(_n(o)),d=cf(p);let f=u[d],h=u[p];if(i){const w=d==="y"?"top":"left",g=d==="y"?"bottom":"right",y=f+c[w],v=f-c[g];f=Rc(y,f,v)}if(l){const w=p==="y"?"top":"left",g=p==="y"?"bottom":"right",y=h+c[w],v=h-c[g];h=Rc(y,h,v)}const m=a.fn({...t,[d]:f,[p]:h});return{...m,data:{x:m.x-n,y:m.y-r}}}}},l5=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:o,rects:i,middlewareData:l}=t,{offset:a=0,mainAxis:s=!0,crossAxis:u=!0}=An(e,t),c={x:n,y:r},p=Po(o),d=cf(p);let f=c[d],h=c[p];const m=An(a,t),w=typeof m=="number"?{mainAxis:m,crossAxis:0}:{mainAxis:0,crossAxis:0,...m};if(s){const v=d==="y"?"height":"width",C=i.reference[d]-i.floating[v]+w.mainAxis,E=i.reference[d]+i.reference[v]-w.mainAxis;fE&&(f=E)}if(u){var g,y;const v=d==="y"?"width":"height",C=["top","left"].includes(_n(o)),E=i.reference[p]-i.floating[v]+(C&&((g=l.offset)==null?void 0:g[p])||0)+(C?0:w.crossAxis),k=i.reference[p]+i.reference[v]+(C?0:((y=l.offset)==null?void 0:y[p])||0)-(C?w.crossAxis:0);hk&&(h=k)}return{[d]:f,[p]:h}}}},a5=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){const{placement:n,rects:r,platform:o,elements:i}=t,{apply:l=()=>{},...a}=An(e,t),s=await Ti(t,a),u=_n(n),c=Eo(n),p=Po(n)==="y",{width:d,height:f}=r.floating;let h,m;u==="top"||u==="bottom"?(h=u,m=c===(await(o.isRTL==null?void 0:o.isRTL(i.floating))?"start":"end")?"left":"right"):(m=u,h=c==="end"?"top":"bottom");const w=f-s[h],g=d-s[m],y=!t.middlewareData.shift;let v=w,C=g;if(p){const k=d-s.left-s.right;C=c||y?lr(g,k):k}else{const k=f-s.top-s.bottom;v=c||y?lr(w,k):k}if(y&&!c){const k=xt(s.left,0),T=xt(s.right,0),A=xt(s.top,0),N=xt(s.bottom,0);p?C=d-2*(k!==0||T!==0?k+T:xt(s.left,s.right)):v=f-2*(A!==0||N!==0?A+N:xt(s.top,s.bottom))}await l({...t,availableWidth:C,availableHeight:v});const E=await o.getDimensions(i.floating);return d!==E.width||f!==E.height?{reset:{rects:!0}}:{}}}};function sr(e){return ov(e)?(e.nodeName||"").toLowerCase():"#document"}function St(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Ln(e){var t;return(t=(ov(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function ov(e){return e instanceof Node||e instanceof St(e).Node}function $n(e){return e instanceof Element||e instanceof St(e).Element}function un(e){return e instanceof HTMLElement||e instanceof St(e).HTMLElement}function hm(e){return typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof St(e).ShadowRoot}function Mi(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=Ft(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!["inline","contents"].includes(o)}function s5(e){return["table","td","th"].includes(sr(e))}function df(e){const t=hf(),n=Ft(e);return n.transform!=="none"||n.perspective!=="none"||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||["transform","perspective","filter"].some(r=>(n.willChange||"").includes(r))||["paint","layout","strict","content"].some(r=>(n.contain||"").includes(r))}function u5(e){let t=xo(e);for(;un(t)&&!fs(t);){if(df(t))return t;t=xo(t)}return null}function hf(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function fs(e){return["html","body","#document"].includes(sr(e))}function Ft(e){return St(e).getComputedStyle(e)}function ds(e){return $n(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.pageXOffset,scrollTop:e.pageYOffset}}function xo(e){if(sr(e)==="html")return e;const t=e.assignedSlot||e.parentNode||hm(e)&&e.host||Ln(e);return hm(t)?t.host:t}function iv(e){const t=xo(e);return fs(t)?e.ownerDocument?e.ownerDocument.body:e.body:un(t)&&Mi(t)?t:iv(t)}function Oi(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const o=iv(e),i=o===((r=e.ownerDocument)==null?void 0:r.body),l=St(o);return i?t.concat(l,l.visualViewport||[],Mi(o)?o:[],l.frameElement&&n?Oi(l.frameElement):[]):t.concat(o,Oi(o,[],n))}function lv(e){const t=Ft(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=un(e),i=o?e.offsetWidth:n,l=o?e.offsetHeight:r,a=ha(n)!==i||ha(r)!==l;return a&&(n=i,r=l),{width:n,height:r,$:a}}function mf(e){return $n(e)?e:e.contextElement}function lo(e){const t=mf(e);if(!un(t))return ar(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:i}=lv(t);let l=(i?ha(n.width):n.width)/r,a=(i?ha(n.height):n.height)/o;return(!l||!Number.isFinite(l))&&(l=1),(!a||!Number.isFinite(a))&&(a=1),{x:l,y:a}}const c5=ar(0);function av(e){const t=St(e);return!hf()||!t.visualViewport?c5:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function p5(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==St(e)?!1:t}function Ar(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const o=e.getBoundingClientRect(),i=mf(e);let l=ar(1);t&&(r?$n(r)&&(l=lo(r)):l=lo(e));const a=p5(i,n,r)?av(i):ar(0);let s=(o.left+a.x)/l.x,u=(o.top+a.y)/l.y,c=o.width/l.x,p=o.height/l.y;if(i){const d=St(i),f=r&&$n(r)?St(r):r;let h=d.frameElement;for(;h&&r&&f!==d;){const m=lo(h),w=h.getBoundingClientRect(),g=Ft(h),y=w.left+(h.clientLeft+parseFloat(g.paddingLeft))*m.x,v=w.top+(h.clientTop+parseFloat(g.paddingTop))*m.y;s*=m.x,u*=m.y,c*=m.x,p*=m.y,s+=y,u+=v,h=St(h).frameElement}}return ga({width:c,height:p,x:s,y:u})}function f5(e){let{rect:t,offsetParent:n,strategy:r}=e;const o=un(n),i=Ln(n);if(n===i)return t;let l={scrollLeft:0,scrollTop:0},a=ar(1);const s=ar(0);if((o||!o&&r!=="fixed")&&((sr(n)!=="body"||Mi(i))&&(l=ds(n)),un(n))){const u=Ar(n);a=lo(n),s.x=u.x+n.clientLeft,s.y=u.y+n.clientTop}return{width:t.width*a.x,height:t.height*a.y,x:t.x*a.x-l.scrollLeft*a.x+s.x,y:t.y*a.y-l.scrollTop*a.y+s.y}}function d5(e){return Array.from(e.getClientRects())}function sv(e){return Ar(Ln(e)).left+ds(e).scrollLeft}function h5(e){const t=Ln(e),n=ds(e),r=e.ownerDocument.body,o=xt(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),i=xt(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let l=-n.scrollLeft+sv(e);const a=-n.scrollTop;return Ft(r).direction==="rtl"&&(l+=xt(t.clientWidth,r.clientWidth)-o),{width:o,height:i,x:l,y:a}}function m5(e,t){const n=St(e),r=Ln(e),o=n.visualViewport;let i=r.clientWidth,l=r.clientHeight,a=0,s=0;if(o){i=o.width,l=o.height;const u=hf();(!u||u&&t==="fixed")&&(a=o.offsetLeft,s=o.offsetTop)}return{width:i,height:l,x:a,y:s}}function g5(e,t){const n=Ar(e,!0,t==="fixed"),r=n.top+e.clientTop,o=n.left+e.clientLeft,i=un(e)?lo(e):ar(1),l=e.clientWidth*i.x,a=e.clientHeight*i.y,s=o*i.x,u=r*i.y;return{width:l,height:a,x:s,y:u}}function mm(e,t,n){let r;if(t==="viewport")r=m5(e,n);else if(t==="document")r=h5(Ln(e));else if($n(t))r=g5(t,n);else{const o=av(e);r={...t,x:t.x-o.x,y:t.y-o.y}}return ga(r)}function uv(e,t){const n=xo(e);return n===t||!$n(n)||fs(n)?!1:Ft(n).position==="fixed"||uv(n,t)}function y5(e,t){const n=t.get(e);if(n)return n;let r=Oi(e,[],!1).filter(a=>$n(a)&&sr(a)!=="body"),o=null;const i=Ft(e).position==="fixed";let l=i?xo(e):e;for(;$n(l)&&!fs(l);){const a=Ft(l),s=df(l);!s&&a.position==="fixed"&&(o=null),(i?!s&&!o:!s&&a.position==="static"&&!!o&&["absolute","fixed"].includes(o.position)||Mi(l)&&!s&&uv(e,l))?r=r.filter(c=>c!==l):o=a,l=xo(l)}return t.set(e,r),r}function v5(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const l=[...n==="clippingAncestors"?y5(t,this._c):[].concat(n),r],a=l[0],s=l.reduce((u,c)=>{const p=mm(t,c,o);return u.top=xt(p.top,u.top),u.right=lr(p.right,u.right),u.bottom=lr(p.bottom,u.bottom),u.left=xt(p.left,u.left),u},mm(t,a,o));return{width:s.right-s.left,height:s.bottom-s.top,x:s.left,y:s.top}}function w5(e){return lv(e)}function x5(e,t,n){const r=un(t),o=Ln(t),i=n==="fixed",l=Ar(e,!0,i,t);let a={scrollLeft:0,scrollTop:0};const s=ar(0);if(r||!r&&!i)if((sr(t)!=="body"||Mi(o))&&(a=ds(t)),r){const u=Ar(t,!0,i,t);s.x=u.x+t.clientLeft,s.y=u.y+t.clientTop}else o&&(s.x=sv(o));return{x:l.left+a.scrollLeft-s.x,y:l.top+a.scrollTop-s.y,width:l.width,height:l.height}}function gm(e,t){return!un(e)||Ft(e).position==="fixed"?null:t?t(e):e.offsetParent}function cv(e,t){const n=St(e);if(!un(e))return n;let r=gm(e,t);for(;r&&s5(r)&&Ft(r).position==="static";)r=gm(r,t);return r&&(sr(r)==="html"||sr(r)==="body"&&Ft(r).position==="static"&&!df(r))?n:r||u5(e)||n}const b5=async function(e){let{reference:t,floating:n,strategy:r}=e;const o=this.getOffsetParent||cv,i=this.getDimensions;return{reference:x5(t,await o(n),r),floating:{x:0,y:0,...await i(n)}}};function k5(e){return Ft(e).direction==="rtl"}const S5={convertOffsetParentRelativeRectToViewportRelativeRect:f5,getDocumentElement:Ln,getClippingRect:v5,getOffsetParent:cv,getElementRects:b5,getClientRects:d5,getDimensions:w5,getScale:lo,isElement:$n,isRTL:k5};function C5(e,t){let n=null,r;const o=Ln(e);function i(){clearTimeout(r),n&&n.disconnect(),n=null}function l(a,s){a===void 0&&(a=!1),s===void 0&&(s=1),i();const{left:u,top:c,width:p,height:d}=e.getBoundingClientRect();if(a||t(),!p||!d)return;const f=ml(c),h=ml(o.clientWidth-(u+p)),m=ml(o.clientHeight-(c+d)),w=ml(u),y={rootMargin:-f+"px "+-h+"px "+-m+"px "+-w+"px",threshold:xt(0,lr(1,s))||1};let v=!0;function C(E){const k=E[0].intersectionRatio;if(k!==s){if(!v)return l();k?l(!1,k):r=setTimeout(()=>{l(!1,1e-7)},100)}v=!1}try{n=new IntersectionObserver(C,{...y,root:o.ownerDocument})}catch{n=new IntersectionObserver(C,y)}n.observe(e)}return l(!0),i}function E5(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:o=!0,ancestorResize:i=!0,elementResize:l=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:s=!1}=r,u=mf(e),c=o||i?[...u?Oi(u):[],...Oi(t)]:[];c.forEach(g=>{o&&g.addEventListener("scroll",n,{passive:!0}),i&&g.addEventListener("resize",n)});const p=u&&a?C5(u,n):null;let d=-1,f=null;l&&(f=new ResizeObserver(g=>{let[y]=g;y&&y.target===u&&f&&(f.unobserve(t),cancelAnimationFrame(d),d=requestAnimationFrame(()=>{f&&f.observe(t)})),n()}),u&&!s&&f.observe(u),f.observe(t));let h,m=s?Ar(e):null;s&&w();function w(){const g=Ar(e);m&&(g.x!==m.x||g.y!==m.y||g.width!==m.width||g.height!==m.height)&&n(),m=g,h=requestAnimationFrame(w)}return n(),()=>{c.forEach(g=>{o&&g.removeEventListener("scroll",n),i&&g.removeEventListener("resize",n)}),p&&p(),f&&f.disconnect(),f=null,s&&cancelAnimationFrame(h)}}const P5=(e,t,n)=>{const r=new Map,o={platform:S5,...n},i={...o.platform,_c:r};return e5(e,t,{...o,platform:i})},T5=e=>{function t(n){return{}.hasOwnProperty.call(n,"current")}return{name:"arrow",options:e,fn(n){const{element:r,padding:o}=typeof e=="function"?e(n):e;return r&&t(r)?r.current!=null?pm({element:r.current,padding:o}).fn(n):{}:r?pm({element:r,padding:o}).fn(n):{}}}};var Fl=typeof document<"u"?b.useLayoutEffect:b.useEffect;function ya(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let n,r,o;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(n=e.length,n!=t.length)return!1;for(r=n;r--!==0;)if(!ya(e[r],t[r]))return!1;return!0}if(o=Object.keys(e),n=o.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,o[r]))return!1;for(r=n;r--!==0;){const i=o[r];if(!(i==="_owner"&&e.$$typeof)&&!ya(e[i],t[i]))return!1}return!0}return e!==e&&t!==t}function pv(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function ym(e,t){const n=pv(e);return Math.round(t*n)/n}function vm(e){const t=b.useRef(e);return Fl(()=>{t.current=e}),t}function O5(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:o,elements:{reference:i,floating:l}={},transform:a=!0,whileElementsMounted:s,open:u}=e,[c,p]=b.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[d,f]=b.useState(r);ya(d,r)||f(r);const[h,m]=b.useState(null),[w,g]=b.useState(null),y=b.useCallback(q=>{q!=k.current&&(k.current=q,m(q))},[m]),v=b.useCallback(q=>{q!==T.current&&(T.current=q,g(q))},[g]),C=i||h,E=l||w,k=b.useRef(null),T=b.useRef(null),A=b.useRef(c),N=vm(s),P=vm(o),z=b.useCallback(()=>{if(!k.current||!T.current)return;const q={placement:t,strategy:n,middleware:d};P.current&&(q.platform=P.current),P5(k.current,T.current,q).then(K=>{const D={...K,isPositioned:!0};_.current&&!ya(A.current,D)&&(A.current=D,Fa.flushSync(()=>{p(D)}))})},[d,t,n,P]);Fl(()=>{u===!1&&A.current.isPositioned&&(A.current.isPositioned=!1,p(q=>({...q,isPositioned:!1})))},[u]);const _=b.useRef(!1);Fl(()=>(_.current=!0,()=>{_.current=!1}),[]),Fl(()=>{if(C&&(k.current=C),E&&(T.current=E),C&&E){if(N.current)return N.current(C,E,z);z()}},[C,E,z,N]);const Y=b.useMemo(()=>({reference:k,floating:T,setReference:y,setFloating:v}),[y,v]),H=b.useMemo(()=>({reference:C,floating:E}),[C,E]),W=b.useMemo(()=>{const q={position:n,left:0,top:0};if(!H.floating)return q;const K=ym(H.floating,c.x),D=ym(H.floating,c.y);return a?{...q,transform:"translate("+K+"px, "+D+"px)",...pv(H.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:K,top:D}},[n,a,H.floating,c.x,c.y]);return b.useMemo(()=>({...c,update:z,refs:Y,elements:H,floatingStyles:W}),[c,z,Y,H,W])}const A5=b.forwardRef((e,t)=>{const{children:n,width:r=10,height:o=5,...i}=e;return b.createElement(jt.svg,ye({},i,{ref:t,width:r,height:o,viewBox:"0 0 30 10",preserveAspectRatio:"none"}),e.asChild?n:b.createElement("polygon",{points:"0,0 30,0 15,10"}))}),_5=A5;function $5(e){const[t,n]=b.useState(void 0);return yo(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const r=new ResizeObserver(o=>{if(!Array.isArray(o)||!o.length)return;const i=o[0];let l,a;if("borderBoxSize"in i){const s=i.borderBoxSize,u=Array.isArray(s)?s[0]:s;l=u.inlineSize,a=u.blockSize}else l=e.offsetWidth,a=e.offsetHeight;n({width:l,height:a})});return r.observe(e,{box:"border-box"}),()=>r.unobserve(e)}else n(void 0)},[e]),t}const fv="Popper",[dv,hv]=qp(fv),[R5,mv]=dv(fv),L5=e=>{const{__scopePopper:t,children:n}=e,[r,o]=b.useState(null);return b.createElement(R5,{scope:t,anchor:r,onAnchorChange:o},n)},z5="PopperAnchor",D5=b.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...o}=e,i=mv(z5,n),l=b.useRef(null),a=pn(t,l);return b.useEffect(()=>{i.onAnchorChange((r==null?void 0:r.current)||l.current)}),r?null:b.createElement(jt.div,ye({},o,{ref:a}))}),gv="PopperContent",[N5,I5]=dv(gv),F5=b.forwardRef((e,t)=>{var n,r,o,i,l,a,s,u;const{__scopePopper:c,side:p="bottom",sideOffset:d=0,align:f="center",alignOffset:h=0,arrowPadding:m=0,avoidCollisions:w=!0,collisionBoundary:g=[],collisionPadding:y=0,sticky:v="partial",hideWhenDetached:C=!1,updatePositionStrategy:E="optimized",onPlaced:k,...T}=e,A=mv(gv,c),[N,P]=b.useState(null),z=pn(t,ie=>P(ie)),[_,Y]=b.useState(null),H=$5(_),W=(n=H==null?void 0:H.width)!==null&&n!==void 0?n:0,q=(r=H==null?void 0:H.height)!==null&&r!==void 0?r:0,K=p+(f!=="center"?"-"+f:""),D=typeof y=="number"?y:{top:0,right:0,bottom:0,left:0,...y},V=Array.isArray(g)?g:[g],S=V.length>0,Z={padding:D,boundary:V.filter(U5),altBoundary:S},{refs:F,floatingStyles:x,placement:U,isPositioned:Q,middlewareData:O}=O5({strategy:"fixed",placement:K,whileElementsMounted:(...ie)=>E5(...ie,{animationFrame:E==="always"}),elements:{reference:A.anchor},middleware:[o5({mainAxis:d+q,alignmentAxis:h}),w&&i5({mainAxis:!0,crossAxis:!1,limiter:v==="partial"?l5():void 0,...Z}),w&&t5({...Z}),a5({...Z,apply:({elements:ie,rects:ze,availableWidth:fe,availableHeight:De})=>{const{width:hn,height:Ne}=ze.reference,At=ie.floating.style;At.setProperty("--radix-popper-available-width",`${fe}px`),At.setProperty("--radix-popper-available-height",`${De}px`),At.setProperty("--radix-popper-anchor-width",`${hn}px`),At.setProperty("--radix-popper-anchor-height",`${Ne}px`)}}),_&&T5({element:_,padding:m}),H5({arrowWidth:W,arrowHeight:q}),C&&n5({strategy:"referenceHidden",...Z})]}),[ne,B]=yv(U),de=ir(k);yo(()=>{Q&&(de==null||de())},[Q,de]);const le=(o=O.arrow)===null||o===void 0?void 0:o.x,pe=(i=O.arrow)===null||i===void 0?void 0:i.y,ee=((l=O.arrow)===null||l===void 0?void 0:l.centerOffset)!==0,[Fe,Ge]=b.useState();return yo(()=>{N&&Ge(window.getComputedStyle(N).zIndex)},[N]),b.createElement("div",{ref:F.setFloating,"data-radix-popper-content-wrapper":"",style:{...x,transform:Q?x.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:Fe,"--radix-popper-transform-origin":[(a=O.transformOrigin)===null||a===void 0?void 0:a.x,(s=O.transformOrigin)===null||s===void 0?void 0:s.y].join(" ")},dir:e.dir},b.createElement(N5,{scope:c,placedSide:ne,onArrowChange:Y,arrowX:le,arrowY:pe,shouldHideArrow:ee},b.createElement(jt.div,ye({"data-side":ne,"data-align":B},T,{ref:z,style:{...T.style,animation:Q?void 0:"none",opacity:(u=O.hide)!==null&&u!==void 0&&u.referenceHidden?0:void 0}}))))}),j5="PopperArrow",M5={top:"bottom",right:"left",bottom:"top",left:"right"},B5=b.forwardRef(function(t,n){const{__scopePopper:r,...o}=t,i=I5(j5,r),l=M5[i.placedSide];return b.createElement("span",{ref:i.onArrowChange,style:{position:"absolute",left:i.arrowX,top:i.arrowY,[l]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[i.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[i.placedSide],visibility:i.shouldHideArrow?"hidden":void 0}},b.createElement(_5,ye({},o,{ref:n,style:{...o.style,display:"block"}})))});function U5(e){return e!==null}const H5=e=>({name:"transformOrigin",options:e,fn(t){var n,r,o,i,l;const{placement:a,rects:s,middlewareData:u}=t,p=((n=u.arrow)===null||n===void 0?void 0:n.centerOffset)!==0,d=p?0:e.arrowWidth,f=p?0:e.arrowHeight,[h,m]=yv(a),w={start:"0%",center:"50%",end:"100%"}[m],g=((r=(o=u.arrow)===null||o===void 0?void 0:o.x)!==null&&r!==void 0?r:0)+d/2,y=((i=(l=u.arrow)===null||l===void 0?void 0:l.y)!==null&&i!==void 0?i:0)+f/2;let v="",C="";return h==="bottom"?(v=p?w:`${g}px`,C=`${-f}px`):h==="top"?(v=p?w:`${g}px`,C=`${s.floating.height+f}px`):h==="right"?(v=`${-f}px`,C=p?w:`${y}px`):h==="left"&&(v=`${s.floating.width+f}px`,C=p?w:`${y}px`),{data:{x:v,y:C}}}});function yv(e){const[t,n="center"]=e.split("-");return[t,n]}const W5=L5,V5=D5,G5=F5,q5=B5,Y5=b.forwardRef((e,t)=>b.createElement(jt.span,ye({},e,{ref:t,style:{position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal",...e.style}}))),Q5=Y5,[hs,n$]=qp("Tooltip",[hv]),ms=hv(),K5="TooltipProvider",X5=700,zc="tooltip.open",[Z5,gf]=hs(K5),J5=e=>{const{__scopeTooltip:t,delayDuration:n=X5,skipDelayDuration:r=300,disableHoverableContent:o=!1,children:i}=e,[l,a]=b.useState(!0),s=b.useRef(!1),u=b.useRef(0);return b.useEffect(()=>{const c=u.current;return()=>window.clearTimeout(c)},[]),b.createElement(Z5,{scope:t,isOpenDelayed:l,delayDuration:n,onOpen:b.useCallback(()=>{window.clearTimeout(u.current),a(!1)},[]),onClose:b.useCallback(()=>{window.clearTimeout(u.current),u.current=window.setTimeout(()=>a(!0),r)},[r]),isPointerInTransitRef:s,onPointerInTransitChange:b.useCallback(c=>{s.current=c},[]),disableHoverableContent:o},i)},yf="Tooltip",[e4,gs]=hs(yf),t4=e=>{const{__scopeTooltip:t,children:n,open:r,defaultOpen:o=!1,onOpenChange:i,disableHoverableContent:l,delayDuration:a}=e,s=gf(yf,e.__scopeTooltip),u=ms(t),[c,p]=b.useState(null),d=zl(),f=b.useRef(0),h=l??s.disableHoverableContent,m=a??s.delayDuration,w=b.useRef(!1),[g=!1,y]=g1({prop:r,defaultProp:o,onChange:T=>{T?(s.onOpen(),document.dispatchEvent(new CustomEvent(zc))):s.onClose(),i==null||i(T)}}),v=b.useMemo(()=>g?w.current?"delayed-open":"instant-open":"closed",[g]),C=b.useCallback(()=>{window.clearTimeout(f.current),w.current=!1,y(!0)},[y]),E=b.useCallback(()=>{window.clearTimeout(f.current),y(!1)},[y]),k=b.useCallback(()=>{window.clearTimeout(f.current),f.current=window.setTimeout(()=>{w.current=!0,y(!0)},m)},[m,y]);return b.useEffect(()=>()=>window.clearTimeout(f.current),[]),b.createElement(W5,u,b.createElement(e4,{scope:t,contentId:d,open:g,stateAttribute:v,trigger:c,onTriggerChange:p,onTriggerEnter:b.useCallback(()=>{s.isOpenDelayed?k():C()},[s.isOpenDelayed,k,C]),onTriggerLeave:b.useCallback(()=>{h?E():window.clearTimeout(f.current)},[E,h]),onOpen:C,onClose:E,disableHoverableContent:h},n))},wm="TooltipTrigger",n4=b.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,o=gs(wm,n),i=gf(wm,n),l=ms(n),a=b.useRef(null),s=pn(t,a,o.onTriggerChange),u=b.useRef(!1),c=b.useRef(!1),p=b.useCallback(()=>u.current=!1,[]);return b.useEffect(()=>()=>document.removeEventListener("pointerup",p),[p]),b.createElement(V5,ye({asChild:!0},l),b.createElement(jt.button,ye({"aria-describedby":o.open?o.contentId:void 0,"data-state":o.stateAttribute},r,{ref:s,onPointerMove:ft(e.onPointerMove,d=>{d.pointerType!=="touch"&&!c.current&&!i.isPointerInTransitRef.current&&(o.onTriggerEnter(),c.current=!0)}),onPointerLeave:ft(e.onPointerLeave,()=>{o.onTriggerLeave(),c.current=!1}),onPointerDown:ft(e.onPointerDown,()=>{u.current=!0,document.addEventListener("pointerup",p,{once:!0})}),onFocus:ft(e.onFocus,()=>{u.current||o.onOpen()}),onBlur:ft(e.onBlur,o.onClose),onClick:ft(e.onClick,o.onClose)})))}),r4="TooltipPortal",[r$,o4]=hs(r4,{forceMount:void 0}),Ai="TooltipContent",i4=b.forwardRef((e,t)=>{const n=o4(Ai,e.__scopeTooltip),{forceMount:r=n.forceMount,side:o="top",...i}=e,l=gs(Ai,e.__scopeTooltip);return b.createElement(Wa,{present:r||l.open},l.disableHoverableContent?b.createElement(vv,ye({side:o},i,{ref:t})):b.createElement(l4,ye({side:o},i,{ref:t})))}),l4=b.forwardRef((e,t)=>{const n=gs(Ai,e.__scopeTooltip),r=gf(Ai,e.__scopeTooltip),o=b.useRef(null),i=pn(t,o),[l,a]=b.useState(null),{trigger:s,onClose:u}=n,c=o.current,{onPointerInTransitChange:p}=r,d=b.useCallback(()=>{a(null),p(!1)},[p]),f=b.useCallback((h,m)=>{const w=h.currentTarget,g={x:h.clientX,y:h.clientY},y=p4(g,w.getBoundingClientRect()),v=f4(g,y),C=d4(m.getBoundingClientRect()),E=m4([...v,...C]);a(E),p(!0)},[p]);return b.useEffect(()=>()=>d(),[d]),b.useEffect(()=>{if(s&&c){const h=w=>f(w,c),m=w=>f(w,s);return s.addEventListener("pointerleave",h),c.addEventListener("pointerleave",m),()=>{s.removeEventListener("pointerleave",h),c.removeEventListener("pointerleave",m)}}},[s,c,f,d]),b.useEffect(()=>{if(l){const h=m=>{const w=m.target,g={x:m.clientX,y:m.clientY},y=(s==null?void 0:s.contains(w))||(c==null?void 0:c.contains(w)),v=!h4(g,l);y?d():v&&(d(),u())};return document.addEventListener("pointermove",h),()=>document.removeEventListener("pointermove",h)}},[s,c,l,u,d]),b.createElement(vv,ye({},e,{ref:i}))}),[a4,s4]=hs(yf,{isInside:!1}),vv=b.forwardRef((e,t)=>{const{__scopeTooltip:n,children:r,"aria-label":o,onEscapeKeyDown:i,onPointerDownOutside:l,...a}=e,s=gs(Ai,n),u=ms(n),{onClose:c}=s;return b.useEffect(()=>(document.addEventListener(zc,c),()=>document.removeEventListener(zc,c)),[c]),b.useEffect(()=>{if(s.trigger){const p=d=>{const f=d.target;f!=null&&f.contains(s.trigger)&&c()};return window.addEventListener("scroll",p,{capture:!0}),()=>window.removeEventListener("scroll",p,{capture:!0})}},[s.trigger,c]),b.createElement(v1,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:i,onPointerDownOutside:l,onFocusOutside:p=>p.preventDefault(),onDismiss:c},b.createElement(G5,ye({"data-state":s.stateAttribute},u,a,{ref:t,style:{...a.style,"--radix-tooltip-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-tooltip-content-available-width":"var(--radix-popper-available-width)","--radix-tooltip-content-available-height":"var(--radix-popper-available-height)","--radix-tooltip-trigger-width":"var(--radix-popper-anchor-width)","--radix-tooltip-trigger-height":"var(--radix-popper-anchor-height)"}}),b.createElement(y1,null,r),b.createElement(a4,{scope:n,isInside:!0},b.createElement(Q5,{id:s.contentId,role:"tooltip"},o||r))))}),u4="TooltipArrow",c4=b.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,o=ms(n);return s4(u4,n).isInside?null:b.createElement(q5,ye({},o,r,{ref:t}))});function p4(e,t){const n=Math.abs(t.top-e.y),r=Math.abs(t.bottom-e.y),o=Math.abs(t.right-e.x),i=Math.abs(t.left-e.x);switch(Math.min(n,r,o,i)){case i:return"left";case o:return"right";case n:return"top";case r:return"bottom";default:throw new Error("unreachable")}}function f4(e,t,n=5){const r=[];switch(t){case"top":r.push({x:e.x-n,y:e.y+n},{x:e.x+n,y:e.y+n});break;case"bottom":r.push({x:e.x-n,y:e.y-n},{x:e.x+n,y:e.y-n});break;case"left":r.push({x:e.x+n,y:e.y-n},{x:e.x+n,y:e.y+n});break;case"right":r.push({x:e.x-n,y:e.y-n},{x:e.x-n,y:e.y+n});break}return r}function d4(e){const{top:t,right:n,bottom:r,left:o}=e;return[{x:o,y:t},{x:n,y:t},{x:n,y:r},{x:o,y:r}]}function h4(e,t){const{x:n,y:r}=e;let o=!1;for(let i=0,l=t.length-1;ir!=c>r&&n<(u-a)*(r-s)/(c-s)+a&&(o=!o)}return o}function m4(e){const t=e.slice();return t.sort((n,r)=>n.xr.x?1:n.yr.y?1:0),g4(t)}function g4(e){if(e.length<=1)return e.slice();const t=[];for(let r=0;r=2;){const i=t[t.length-1],l=t[t.length-2];if((i.x-l.x)*(o.y-l.y)>=(i.y-l.y)*(o.x-l.x))t.pop();else break}t.push(o)}t.pop();const n=[];for(let r=e.length-1;r>=0;r--){const o=e[r];for(;n.length>=2;){const i=n[n.length-1],l=n[n.length-2];if((i.x-l.x)*(o.y-l.y)>=(i.y-l.y)*(o.x-l.x))n.pop();else break}n.push(o)}return n.pop(),t.length===1&&n.length===1&&t[0].x===n[0].x&&t[0].y===n[0].y?t:t.concat(n)}const y4=J5,v4=t4,w4=n4,wv=i4,x4=c4,vf=w4;function ys({children:e}){return L.jsx(y4,{children:L.jsx(v4,{children:e})})}ys.displayName="ToolTip";const vs=b.forwardRef(({className:e,children:t,sideOffset:n=0,arrowClassName:r,...o},i)=>L.jsx(wv,{ref:i,sideOffset:n,dir:"auto",className:On("opencopilot-text-primary opencopilot-font-medium opencopilot-bg-accent opencopilot-z-[50000] opencopilot-overflow-hidden opencopilot-shadow opencopilot-min-w-fit opencopilot-max-w-[15rem] opencopilot-select-none opencopilot-rounded-sm opencopilot-p-0.5 opencopilot-text-xs opencopilot-px-1 opencopilot-leading-none","opencopilot-animate-in opencopilot-fade-in-0 opencopilot-slide-in-from-bottom-5 data-[state=closed]:animate-out data-[state=closed]:opencopilot-slide-in-from-top-0",e),...o,children:L.jsxs(L.Fragment,{children:[t,L.jsx(x4,{className:On("opencopilot-fill-current opencopilot-text-accent opencopilot-animate-in opencopilot-slide-in-from-top-1 opencopilot-ease-out data-[state=closed]:opencopilot-animate-out",r)})]})}));vs.displayName=wv.displayName;function wf({text:e,every:t,onFinish:n,shouldStart:r=!0}){const[o,i]=b.useState(""),[l,a]=b.useState(0),[s,u]=b.useState(!1),c=t||1e-5;return b.useEffect(()=>{if(r)if(l{i(e.substring(0,l+1)),a(d=>d+1)},c);return()=>{clearInterval(p)}}else u(!0),typeof n=="function"&&n()},[e,l,c,n,r]),{displayText:o,isComplete:s,text:e}}const xm=["http","https","mailto","tel"];function b4(e){const t=(e||"").trim(),n=t.charAt(0);if(n==="#"||n==="/")return t;const r=t.indexOf(":");if(r===-1)return t;let o=-1;for(;++oo||(o=t.indexOf("#"),o!==-1&&r>o)?t:"javascript:void(0)"}/*! +`])));var Yh,Qh,Kh,Xh=globalThis&&globalThis.__assign||function(){return Xh=Object.assign||function(e){for(var t,n=1,r=arguments.length;n{var n;const{disableOutsidePointerEvents:r=!1,onEscapeKeyDown:o,onPointerDownOutside:i,onFocusOutside:l,onInteractOutside:a,onDismiss:s,...u}=e,p=x.useContext(ZE),[c,d]=x.useState(null),f=(n=c==null?void 0:c.ownerDocument)!==null&&n!==void 0?n:globalThis==null?void 0:globalThis.document,[,h]=x.useState({}),m=en(t,T=>d(T)),w=Array.from(p.layers),[g]=[...p.layersWithOutsidePointerEventsDisabled].slice(-1),y=w.indexOf(g),v=c?w.indexOf(c):-1,C=p.layersWithOutsidePointerEventsDisabled.size>0,E=v>=y,k=e5(T=>{const N=T.target,P=[...p.branches].some(_=>_.contains(N));!E||P||(i==null||i(T),a==null||a(T),T.defaultPrevented||s==null||s())},f),O=t5(T=>{const N=T.target;[...p.branches].some(_=>_.contains(N))||(l==null||l(T),a==null||a(T),T.defaultPrevented||s==null||s())},f);return S1(T=>{v===p.layers.size-1&&(o==null||o(T),!T.defaultPrevented&&s&&(T.preventDefault(),s()))},f),x.useEffect(()=>{if(c)return r&&(p.layersWithOutsidePointerEventsDisabled.size===0&&(pm=f.body.style.pointerEvents,f.body.style.pointerEvents="none"),p.layersWithOutsidePointerEventsDisabled.add(c)),p.layers.add(c),fm(),()=>{r&&p.layersWithOutsidePointerEventsDisabled.size===1&&(f.body.style.pointerEvents=pm)}},[c,f,r,p]),x.useEffect(()=>()=>{c&&(p.layers.delete(c),p.layersWithOutsidePointerEventsDisabled.delete(c),fm())},[c,p]),x.useEffect(()=>{const T=()=>h({});return document.addEventListener(Dc,T),()=>document.removeEventListener(Dc,T)},[]),x.createElement(Tt.div,ge({},u,{ref:m,style:{pointerEvents:C?E?"auto":"none":void 0,...e.style},onFocusCapture:Xe(e.onFocusCapture,O.onFocusCapture),onBlurCapture:Xe(e.onBlurCapture,O.onBlurCapture),onPointerDownCapture:Xe(e.onPointerDownCapture,k.onPointerDownCapture)}))});function e5(e,t=globalThis==null?void 0:globalThis.document){const n=un(e),r=x.useRef(!1),o=x.useRef(()=>{});return x.useEffect(()=>{const i=a=>{if(a.target&&!r.current){let p=function(){sv(KE,n,u,{discrete:!0})};var s=p;const u={originalEvent:a};a.pointerType==="touch"?(t.removeEventListener("click",o.current),o.current=p,t.addEventListener("click",o.current,{once:!0})):p()}r.current=!1},l=window.setTimeout(()=>{t.addEventListener("pointerdown",i)},0);return()=>{window.clearTimeout(l),t.removeEventListener("pointerdown",i),t.removeEventListener("click",o.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function t5(e,t=globalThis==null?void 0:globalThis.document){const n=un(e),r=x.useRef(!1);return x.useEffect(()=>{const o=i=>{i.target&&!r.current&&sv(XE,n,{originalEvent:i},{discrete:!1})};return t.addEventListener("focusin",o),()=>t.removeEventListener("focusin",o)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function fm(){const e=new CustomEvent(Dc);document.dispatchEvent(e)}function sv(e,t,n,{discrete:r}){const o=n.originalEvent.target,i=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&o.addEventListener(e,t,{once:!0}),r?k1(o,i):o.dispatchEvent(i)}const n5=["top","right","bottom","left"],ir=Math.min,xt=Math.max,ya=Math.round,yl=Math.floor,lr=e=>({x:e,y:e}),r5={left:"right",right:"left",bottom:"top",top:"bottom"},o5={start:"end",end:"start"};function zc(e,t,n){return xt(e,ir(t,n))}function An(e,t){return typeof e=="function"?e(t):e}function $n(e){return e.split("-")[0]}function Po(e){return e.split("-")[1]}function ff(e){return e==="x"?"y":"x"}function df(e){return e==="y"?"height":"width"}function Oo(e){return["top","bottom"].includes($n(e))?"y":"x"}function hf(e){return ff(Oo(e))}function i5(e,t,n){n===void 0&&(n=!1);const r=Po(e),o=hf(e),i=df(o);let l=o==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[i]>t.floating[i]&&(l=va(l)),[l,va(l)]}function l5(e){const t=va(e);return[Nc(e),t,Nc(t)]}function Nc(e){return e.replace(/start|end/g,t=>o5[t])}function a5(e,t,n){const r=["left","right"],o=["right","left"],i=["top","bottom"],l=["bottom","top"];switch(e){case"top":case"bottom":return n?t?o:r:t?r:o;case"left":case"right":return t?i:l;default:return[]}}function s5(e,t,n,r){const o=Po(e);let i=a5($n(e),n==="start",r);return o&&(i=i.map(l=>l+"-"+o),t&&(i=i.concat(i.map(Nc)))),i}function va(e){return e.replace(/left|right|bottom|top/g,t=>r5[t])}function u5(e){return{top:0,right:0,bottom:0,left:0,...e}}function uv(e){return typeof e!="number"?u5(e):{top:e,right:e,bottom:e,left:e}}function wa(e){return{...e,top:e.y,left:e.x,right:e.x+e.width,bottom:e.y+e.height}}function dm(e,t,n){let{reference:r,floating:o}=e;const i=Oo(t),l=hf(t),a=df(l),s=$n(t),u=i==="y",p=r.x+r.width/2-o.width/2,c=r.y+r.height/2-o.height/2,d=r[a]/2-o[a]/2;let f;switch(s){case"top":f={x:p,y:r.y-o.height};break;case"bottom":f={x:p,y:r.y+r.height};break;case"right":f={x:r.x+r.width,y:c};break;case"left":f={x:r.x-o.width,y:c};break;default:f={x:r.x,y:r.y}}switch(Po(t)){case"start":f[l]-=d*(n&&u?-1:1);break;case"end":f[l]+=d*(n&&u?-1:1);break}return f}const c5=async(e,t,n)=>{const{placement:r="bottom",strategy:o="absolute",middleware:i=[],platform:l}=n,a=i.filter(Boolean),s=await(l.isRTL==null?void 0:l.isRTL(t));let u=await l.getElementRects({reference:e,floating:t,strategy:o}),{x:p,y:c}=dm(u,r,s),d=r,f={},h=0;for(let m=0;m({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:o,rects:i,platform:l,elements:a}=t,{element:s,padding:u=0}=An(e,t)||{};if(s==null)return{};const p=uv(u),c={x:n,y:r},d=hf(o),f=df(d),h=await l.getDimensions(s),m=d==="y",w=m?"top":"left",g=m?"bottom":"right",y=m?"clientHeight":"clientWidth",v=i.reference[f]+i.reference[d]-c[d]-i.floating[f],C=c[d]-i.reference[d],E=await(l.getOffsetParent==null?void 0:l.getOffsetParent(s));let k=E?E[y]:0;(!k||!await(l.isElement==null?void 0:l.isElement(E)))&&(k=a.floating[y]||i.floating[f]);const O=v/2-C/2,T=k/2-h[f]/2-1,N=ir(p[w],T),P=ir(p[g],T),_=N,R=k-h[f]-P,H=k/2-h[f]/2+O,q=zc(_,H,R),Q=Po(o)!=null&&H!=q&&i.reference[f]/2-(H<_?N:P)-h[f]/2<0?H<_?_-H:R-H:0;return{[d]:c[d]-Q,data:{[d]:q,centerOffset:H-q+Q}}}}),p5=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n;const{placement:r,middlewareData:o,rects:i,initialPlacement:l,platform:a,elements:s}=t,{mainAxis:u=!0,crossAxis:p=!0,fallbackPlacements:c,fallbackStrategy:d="bestFit",fallbackAxisSideDirection:f="none",flipAlignment:h=!0,...m}=An(e,t),w=$n(r),g=$n(l)===l,y=await(a.isRTL==null?void 0:a.isRTL(s.floating)),v=c||(g||!h?[va(l)]:l5(l));!c&&f!=="none"&&v.push(...s5(l,h,f,y));const C=[l,...v],E=await Ti(t,m),k=[];let O=((n=o.flip)==null?void 0:n.overflows)||[];if(u&&k.push(E[w]),p){const _=i5(r,i,y);k.push(E[_[0]],E[_[1]])}if(O=[...O,{placement:r,overflows:k}],!k.every(_=>_<=0)){var T,N;const _=(((T=o.flip)==null?void 0:T.index)||0)+1,R=C[_];if(R)return{data:{index:_,overflows:O},reset:{placement:R}};let H=(N=O.filter(q=>q.overflows[0]<=0).sort((q,W)=>q.overflows[1]-W.overflows[1])[0])==null?void 0:N.placement;if(!H)switch(d){case"bestFit":{var P;const q=(P=O.map(W=>[W.placement,W.overflows.filter(Q=>Q>0).reduce((Q,te)=>Q+te,0)]).sort((W,Q)=>W[1]-Q[1])[0])==null?void 0:P[0];q&&(H=q);break}case"initialPlacement":H=l;break}if(r!==H)return{reset:{placement:H}}}return{}}}};function mm(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function gm(e){return n5.some(t=>e[t]>=0)}const f5=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n}=t,{strategy:r="referenceHidden",...o}=An(e,t);switch(r){case"referenceHidden":{const i=await Ti(t,{...o,elementContext:"reference"}),l=mm(i,n.reference);return{data:{referenceHiddenOffsets:l,referenceHidden:gm(l)}}}case"escaped":{const i=await Ti(t,{...o,altBoundary:!0}),l=mm(i,n.floating);return{data:{escapedOffsets:l,escaped:gm(l)}}}default:return{}}}}};async function d5(e,t){const{placement:n,platform:r,elements:o}=e,i=await(r.isRTL==null?void 0:r.isRTL(o.floating)),l=$n(n),a=Po(n),s=Oo(n)==="y",u=["left","top"].includes(l)?-1:1,p=i&&s?-1:1,c=An(t,e);let{mainAxis:d,crossAxis:f,alignmentAxis:h}=typeof c=="number"?{mainAxis:c,crossAxis:0,alignmentAxis:null}:{mainAxis:0,crossAxis:0,alignmentAxis:null,...c};return a&&typeof h=="number"&&(f=a==="end"?h*-1:h),s?{x:f*p,y:d*u}:{x:d*u,y:f*p}}const h5=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){const{x:n,y:r}=t,o=await d5(t,e);return{x:n+o.x,y:r+o.y,data:o}}}},m5=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:o}=t,{mainAxis:i=!0,crossAxis:l=!1,limiter:a={fn:w=>{let{x:g,y}=w;return{x:g,y}}},...s}=An(e,t),u={x:n,y:r},p=await Ti(t,s),c=Oo($n(o)),d=ff(c);let f=u[d],h=u[c];if(i){const w=d==="y"?"top":"left",g=d==="y"?"bottom":"right",y=f+p[w],v=f-p[g];f=zc(y,f,v)}if(l){const w=c==="y"?"top":"left",g=c==="y"?"bottom":"right",y=h+p[w],v=h-p[g];h=zc(y,h,v)}const m=a.fn({...t,[d]:f,[c]:h});return{...m,data:{x:m.x-n,y:m.y-r}}}}},g5=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:o,rects:i,middlewareData:l}=t,{offset:a=0,mainAxis:s=!0,crossAxis:u=!0}=An(e,t),p={x:n,y:r},c=Oo(o),d=ff(c);let f=p[d],h=p[c];const m=An(a,t),w=typeof m=="number"?{mainAxis:m,crossAxis:0}:{mainAxis:0,crossAxis:0,...m};if(s){const v=d==="y"?"height":"width",C=i.reference[d]-i.floating[v]+w.mainAxis,E=i.reference[d]+i.reference[v]-w.mainAxis;fE&&(f=E)}if(u){var g,y;const v=d==="y"?"width":"height",C=["top","left"].includes($n(o)),E=i.reference[c]-i.floating[v]+(C&&((g=l.offset)==null?void 0:g[c])||0)+(C?0:w.crossAxis),k=i.reference[c]+i.reference[v]+(C?0:((y=l.offset)==null?void 0:y[c])||0)-(C?w.crossAxis:0);hk&&(h=k)}return{[d]:f,[c]:h}}}},y5=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){const{placement:n,rects:r,platform:o,elements:i}=t,{apply:l=()=>{},...a}=An(e,t),s=await Ti(t,a),u=$n(n),p=Po(n),c=Oo(n)==="y",{width:d,height:f}=r.floating;let h,m;u==="top"||u==="bottom"?(h=u,m=p===(await(o.isRTL==null?void 0:o.isRTL(i.floating))?"start":"end")?"left":"right"):(m=u,h=p==="end"?"top":"bottom");const w=f-s[h],g=d-s[m],y=!t.middlewareData.shift;let v=w,C=g;if(c){const k=d-s.left-s.right;C=p||y?ir(g,k):k}else{const k=f-s.top-s.bottom;v=p||y?ir(w,k):k}if(y&&!p){const k=xt(s.left,0),O=xt(s.right,0),T=xt(s.top,0),N=xt(s.bottom,0);c?C=d-2*(k!==0||O!==0?k+O:xt(s.left,s.right)):v=f-2*(T!==0||N!==0?T+N:xt(s.top,s.bottom))}await l({...t,availableWidth:C,availableHeight:v});const E=await o.getDimensions(i.floating);return d!==E.width||f!==E.height?{reset:{rects:!0}}:{}}}};function ar(e){return cv(e)?(e.nodeName||"").toLowerCase():"#document"}function St(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Ln(e){var t;return(t=(cv(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function cv(e){return e instanceof Node||e instanceof St(e).Node}function _n(e){return e instanceof Element||e instanceof St(e).Element}function cn(e){return e instanceof HTMLElement||e instanceof St(e).HTMLElement}function ym(e){return typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof St(e).ShadowRoot}function Mi(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=Ft(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!["inline","contents"].includes(o)}function v5(e){return["table","td","th"].includes(ar(e))}function mf(e){const t=gf(),n=Ft(e);return n.transform!=="none"||n.perspective!=="none"||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||["transform","perspective","filter"].some(r=>(n.willChange||"").includes(r))||["paint","layout","strict","content"].some(r=>(n.contain||"").includes(r))}function w5(e){let t=bo(e);for(;cn(t)&&!gs(t);){if(mf(t))return t;t=bo(t)}return null}function gf(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function gs(e){return["html","body","#document"].includes(ar(e))}function Ft(e){return St(e).getComputedStyle(e)}function ys(e){return _n(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.pageXOffset,scrollTop:e.pageYOffset}}function bo(e){if(ar(e)==="html")return e;const t=e.assignedSlot||e.parentNode||ym(e)&&e.host||Ln(e);return ym(t)?t.host:t}function pv(e){const t=bo(e);return gs(t)?e.ownerDocument?e.ownerDocument.body:e.body:cn(t)&&Mi(t)?t:pv(t)}function xa(e,t){var n;t===void 0&&(t=[]);const r=pv(e),o=r===((n=e.ownerDocument)==null?void 0:n.body),i=St(r);return o?t.concat(i,i.visualViewport||[],Mi(r)?r:[]):t.concat(r,xa(r))}function fv(e){const t=Ft(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=cn(e),i=o?e.offsetWidth:n,l=o?e.offsetHeight:r,a=ya(n)!==i||ya(r)!==l;return a&&(n=i,r=l),{width:n,height:r,$:a}}function yf(e){return _n(e)?e:e.contextElement}function ao(e){const t=yf(e);if(!cn(t))return lr(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:i}=fv(t);let l=(i?ya(n.width):n.width)/r,a=(i?ya(n.height):n.height)/o;return(!l||!Number.isFinite(l))&&(l=1),(!a||!Number.isFinite(a))&&(a=1),{x:l,y:a}}const x5=lr(0);function dv(e){const t=St(e);return!gf()||!t.visualViewport?x5:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function b5(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==St(e)?!1:t}function Ar(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const o=e.getBoundingClientRect(),i=yf(e);let l=lr(1);t&&(r?_n(r)&&(l=ao(r)):l=ao(e));const a=b5(i,n,r)?dv(i):lr(0);let s=(o.left+a.x)/l.x,u=(o.top+a.y)/l.y,p=o.width/l.x,c=o.height/l.y;if(i){const d=St(i),f=r&&_n(r)?St(r):r;let h=d.frameElement;for(;h&&r&&f!==d;){const m=ao(h),w=h.getBoundingClientRect(),g=Ft(h),y=w.left+(h.clientLeft+parseFloat(g.paddingLeft))*m.x,v=w.top+(h.clientTop+parseFloat(g.paddingTop))*m.y;s*=m.x,u*=m.y,p*=m.x,c*=m.y,s+=y,u+=v,h=St(h).frameElement}}return wa({width:p,height:c,x:s,y:u})}function k5(e){let{rect:t,offsetParent:n,strategy:r}=e;const o=cn(n),i=Ln(n);if(n===i)return t;let l={scrollLeft:0,scrollTop:0},a=lr(1);const s=lr(0);if((o||!o&&r!=="fixed")&&((ar(n)!=="body"||Mi(i))&&(l=ys(n)),cn(n))){const u=Ar(n);a=ao(n),s.x=u.x+n.clientLeft,s.y=u.y+n.clientTop}return{width:t.width*a.x,height:t.height*a.y,x:t.x*a.x-l.scrollLeft*a.x+s.x,y:t.y*a.y-l.scrollTop*a.y+s.y}}function S5(e){return Array.from(e.getClientRects())}function hv(e){return Ar(Ln(e)).left+ys(e).scrollLeft}function C5(e){const t=Ln(e),n=ys(e),r=e.ownerDocument.body,o=xt(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),i=xt(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let l=-n.scrollLeft+hv(e);const a=-n.scrollTop;return Ft(r).direction==="rtl"&&(l+=xt(t.clientWidth,r.clientWidth)-o),{width:o,height:i,x:l,y:a}}function E5(e,t){const n=St(e),r=Ln(e),o=n.visualViewport;let i=r.clientWidth,l=r.clientHeight,a=0,s=0;if(o){i=o.width,l=o.height;const u=gf();(!u||u&&t==="fixed")&&(a=o.offsetLeft,s=o.offsetTop)}return{width:i,height:l,x:a,y:s}}function P5(e,t){const n=Ar(e,!0,t==="fixed"),r=n.top+e.clientTop,o=n.left+e.clientLeft,i=cn(e)?ao(e):lr(1),l=e.clientWidth*i.x,a=e.clientHeight*i.y,s=o*i.x,u=r*i.y;return{width:l,height:a,x:s,y:u}}function vm(e,t,n){let r;if(t==="viewport")r=E5(e,n);else if(t==="document")r=C5(Ln(e));else if(_n(t))r=P5(t,n);else{const o=dv(e);r={...t,x:t.x-o.x,y:t.y-o.y}}return wa(r)}function mv(e,t){const n=bo(e);return n===t||!_n(n)||gs(n)?!1:Ft(n).position==="fixed"||mv(n,t)}function O5(e,t){const n=t.get(e);if(n)return n;let r=xa(e).filter(a=>_n(a)&&ar(a)!=="body"),o=null;const i=Ft(e).position==="fixed";let l=i?bo(e):e;for(;_n(l)&&!gs(l);){const a=Ft(l),s=mf(l);!s&&a.position==="fixed"&&(o=null),(i?!s&&!o:!s&&a.position==="static"&&!!o&&["absolute","fixed"].includes(o.position)||Mi(l)&&!s&&mv(e,l))?r=r.filter(p=>p!==l):o=a,l=bo(l)}return t.set(e,r),r}function T5(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const l=[...n==="clippingAncestors"?O5(t,this._c):[].concat(n),r],a=l[0],s=l.reduce((u,p)=>{const c=vm(t,p,o);return u.top=xt(c.top,u.top),u.right=ir(c.right,u.right),u.bottom=ir(c.bottom,u.bottom),u.left=xt(c.left,u.left),u},vm(t,a,o));return{width:s.right-s.left,height:s.bottom-s.top,x:s.left,y:s.top}}function A5(e){return fv(e)}function $5(e,t,n){const r=cn(t),o=Ln(t),i=n==="fixed",l=Ar(e,!0,i,t);let a={scrollLeft:0,scrollTop:0};const s=lr(0);if(r||!r&&!i)if((ar(t)!=="body"||Mi(o))&&(a=ys(t)),r){const u=Ar(t,!0,i,t);s.x=u.x+t.clientLeft,s.y=u.y+t.clientTop}else o&&(s.x=hv(o));return{x:l.left+a.scrollLeft-s.x,y:l.top+a.scrollTop-s.y,width:l.width,height:l.height}}function wm(e,t){return!cn(e)||Ft(e).position==="fixed"?null:t?t(e):e.offsetParent}function gv(e,t){const n=St(e);if(!cn(e))return n;let r=wm(e,t);for(;r&&v5(r)&&Ft(r).position==="static";)r=wm(r,t);return r&&(ar(r)==="html"||ar(r)==="body"&&Ft(r).position==="static"&&!mf(r))?n:r||w5(e)||n}const _5=async function(e){let{reference:t,floating:n,strategy:r}=e;const o=this.getOffsetParent||gv,i=this.getDimensions;return{reference:$5(t,await o(n),r),floating:{x:0,y:0,...await i(n)}}};function R5(e){return Ft(e).direction==="rtl"}const L5={convertOffsetParentRelativeRectToViewportRelativeRect:k5,getDocumentElement:Ln,getClippingRect:T5,getOffsetParent:gv,getElementRects:_5,getClientRects:S5,getDimensions:A5,getScale:ao,isElement:_n,isRTL:R5};function D5(e,t){let n=null,r;const o=Ln(e);function i(){clearTimeout(r),n&&n.disconnect(),n=null}function l(a,s){a===void 0&&(a=!1),s===void 0&&(s=1),i();const{left:u,top:p,width:c,height:d}=e.getBoundingClientRect();if(a||t(),!c||!d)return;const f=yl(p),h=yl(o.clientWidth-(u+c)),m=yl(o.clientHeight-(p+d)),w=yl(u),y={rootMargin:-f+"px "+-h+"px "+-m+"px "+-w+"px",threshold:xt(0,ir(1,s))||1};let v=!0;function C(E){const k=E[0].intersectionRatio;if(k!==s){if(!v)return l();k?l(!1,k):r=setTimeout(()=>{l(!1,1e-7)},100)}v=!1}try{n=new IntersectionObserver(C,{...y,root:o.ownerDocument})}catch{n=new IntersectionObserver(C,y)}n.observe(e)}return l(!0),i}function z5(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:o=!0,ancestorResize:i=!0,elementResize:l=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:s=!1}=r,u=yf(e),p=o||i?[...u?xa(u):[],...xa(t)]:[];p.forEach(g=>{o&&g.addEventListener("scroll",n,{passive:!0}),i&&g.addEventListener("resize",n)});const c=u&&a?D5(u,n):null;let d=-1,f=null;l&&(f=new ResizeObserver(g=>{let[y]=g;y&&y.target===u&&f&&(f.unobserve(t),cancelAnimationFrame(d),d=requestAnimationFrame(()=>{f&&f.observe(t)})),n()}),u&&!s&&f.observe(u),f.observe(t));let h,m=s?Ar(e):null;s&&w();function w(){const g=Ar(e);m&&(g.x!==m.x||g.y!==m.y||g.width!==m.width||g.height!==m.height)&&n(),m=g,h=requestAnimationFrame(w)}return n(),()=>{p.forEach(g=>{o&&g.removeEventListener("scroll",n),i&&g.removeEventListener("resize",n)}),c&&c(),f&&f.disconnect(),f=null,s&&cancelAnimationFrame(h)}}const N5=(e,t,n)=>{const r=new Map,o={platform:L5,...n},i={...o.platform,_c:r};return c5(e,t,{...o,platform:i})},I5=e=>{function t(n){return{}.hasOwnProperty.call(n,"current")}return{name:"arrow",options:e,fn(n){const{element:r,padding:o}=typeof e=="function"?e(n):e;return r&&t(r)?r.current!=null?hm({element:r.current,padding:o}).fn(n):{}:r?hm({element:r,padding:o}).fn(n):{}}}};var Bl=typeof document<"u"?x.useLayoutEffect:x.useEffect;function ba(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let n,r,o;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(n=e.length,n!=t.length)return!1;for(r=n;r--!==0;)if(!ba(e[r],t[r]))return!1;return!0}if(o=Object.keys(e),n=o.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,o[r]))return!1;for(r=n;r--!==0;){const i=o[r];if(!(i==="_owner"&&e.$$typeof)&&!ba(e[i],t[i]))return!1}return!0}return e!==e&&t!==t}function yv(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function xm(e,t){const n=yv(e);return Math.round(t*n)/n}function bm(e){const t=x.useRef(e);return Bl(()=>{t.current=e}),t}function F5(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:o,elements:{reference:i,floating:l}={},transform:a=!0,whileElementsMounted:s,open:u}=e,[p,c]=x.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[d,f]=x.useState(r);ba(d,r)||f(r);const[h,m]=x.useState(null),[w,g]=x.useState(null),y=x.useCallback(Q=>{Q!=k.current&&(k.current=Q,m(Q))},[m]),v=x.useCallback(Q=>{Q!==O.current&&(O.current=Q,g(Q))},[g]),C=i||h,E=l||w,k=x.useRef(null),O=x.useRef(null),T=x.useRef(p),N=bm(s),P=bm(o),_=x.useCallback(()=>{if(!k.current||!O.current)return;const Q={placement:t,strategy:n,middleware:d};P.current&&(Q.platform=P.current),N5(k.current,O.current,Q).then(te=>{const z={...te,isPositioned:!0};R.current&&!ba(T.current,z)&&(T.current=z,Ba.flushSync(()=>{c(z)}))})},[d,t,n,P]);Bl(()=>{u===!1&&T.current.isPositioned&&(T.current.isPositioned=!1,c(Q=>({...Q,isPositioned:!1})))},[u]);const R=x.useRef(!1);Bl(()=>(R.current=!0,()=>{R.current=!1}),[]),Bl(()=>{if(C&&(k.current=C),E&&(O.current=E),C&&E){if(N.current)return N.current(C,E,_);_()}},[C,E,_,N]);const H=x.useMemo(()=>({reference:k,floating:O,setReference:y,setFloating:v}),[y,v]),q=x.useMemo(()=>({reference:C,floating:E}),[C,E]),W=x.useMemo(()=>{const Q={position:n,left:0,top:0};if(!q.floating)return Q;const te=xm(q.floating,p.x),z=xm(q.floating,p.y);return a?{...Q,transform:"translate("+te+"px, "+z+"px)",...yv(q.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:te,top:z}},[n,a,q.floating,p.x,p.y]);return x.useMemo(()=>({...p,update:_,refs:H,elements:q,floatingStyles:W}),[p,_,H,q,W])}const j5=x.forwardRef((e,t)=>{const{children:n,width:r=10,height:o=5,...i}=e;return x.createElement(Tt.svg,ge({},i,{ref:t,width:r,height:o,viewBox:"0 0 30 10",preserveAspectRatio:"none"}),e.asChild?n:x.createElement("polygon",{points:"0,0 30,0 15,10"}))}),M5=j5;function B5(e){const[t,n]=x.useState(void 0);return vo(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const r=new ResizeObserver(o=>{if(!Array.isArray(o)||!o.length)return;const i=o[0];let l,a;if("borderBoxSize"in i){const s=i.borderBoxSize,u=Array.isArray(s)?s[0]:s;l=u.inlineSize,a=u.blockSize}else l=e.offsetWidth,a=e.offsetHeight;n({width:l,height:a})});return r.observe(e,{box:"border-box"}),()=>r.unobserve(e)}else n(void 0)},[e]),t}const vv="Popper",[wv,xv]=Qp(vv),[U5,bv]=wv(vv),H5=e=>{const{__scopePopper:t,children:n}=e,[r,o]=x.useState(null);return x.createElement(U5,{scope:t,anchor:r,onAnchorChange:o},n)},W5="PopperAnchor",V5=x.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...o}=e,i=bv(W5,n),l=x.useRef(null),a=en(t,l);return x.useEffect(()=>{i.onAnchorChange((r==null?void 0:r.current)||l.current)}),r?null:x.createElement(Tt.div,ge({},o,{ref:a}))}),kv="PopperContent",[G5,q5]=wv(kv),Y5=x.forwardRef((e,t)=>{var n,r,o,i,l,a,s,u;const{__scopePopper:p,side:c="bottom",sideOffset:d=0,align:f="center",alignOffset:h=0,arrowPadding:m=0,collisionBoundary:w=[],collisionPadding:g=0,sticky:y="partial",hideWhenDetached:v=!1,avoidCollisions:C=!0,onPlaced:E,...k}=e,O=bv(kv,p),[T,N]=x.useState(null),P=en(t,Be=>N(Be)),[_,R]=x.useState(null),H=B5(_),q=(n=H==null?void 0:H.width)!==null&&n!==void 0?n:0,W=(r=H==null?void 0:H.height)!==null&&r!==void 0?r:0,Q=c+(f!=="center"?"-"+f:""),te=typeof g=="number"?g:{top:0,right:0,bottom:0,left:0,...g},z=Array.isArray(w)?w:[w],G=z.length>0,S={padding:te,boundary:z.filter(Z5),altBoundary:G},{refs:X,floatingStyles:I,placement:b,isPositioned:U,middlewareData:Y}=F5({strategy:"fixed",placement:Q,whileElementsMounted:z5,elements:{reference:O.anchor},middleware:[h5({mainAxis:d+W,alignmentAxis:h}),C&&m5({mainAxis:!0,crossAxis:!1,limiter:y==="partial"?g5():void 0,...S}),C&&p5({...S}),y5({...S,apply:({elements:Be,rects:se,availableWidth:Fe,availableHeight:fe})=>{const{width:ze,height:hn}=se.reference,Ee=Be.floating.style;Ee.setProperty("--radix-popper-available-width",`${Fe}px`),Ee.setProperty("--radix-popper-available-height",`${fe}px`),Ee.setProperty("--radix-popper-anchor-width",`${ze}px`),Ee.setProperty("--radix-popper-anchor-height",`${hn}px`)}}),_&&I5({element:_,padding:m}),J5({arrowWidth:q,arrowHeight:W}),v&&f5({strategy:"referenceHidden"})]}),[A,ne]=Sv(b),B=un(E);vo(()=>{U&&(B==null||B())},[U,B]);const ye=(o=Y.arrow)===null||o===void 0?void 0:o.x,ie=(i=Y.arrow)===null||i===void 0?void 0:i.y,pe=((l=Y.arrow)===null||l===void 0?void 0:l.centerOffset)!==0,[J,Ie]=x.useState();return vo(()=>{T&&Ie(window.getComputedStyle(T).zIndex)},[T]),x.createElement("div",{ref:X.setFloating,"data-radix-popper-content-wrapper":"",style:{...I,transform:U?I.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:J,"--radix-popper-transform-origin":[(a=Y.transformOrigin)===null||a===void 0?void 0:a.x,(s=Y.transformOrigin)===null||s===void 0?void 0:s.y].join(" ")},dir:e.dir},x.createElement(G5,{scope:p,placedSide:A,onArrowChange:R,arrowX:ye,arrowY:ie,shouldHideArrow:pe},x.createElement(Tt.div,ge({"data-side":A,"data-align":ne},k,{ref:P,style:{...k.style,animation:U?void 0:"none",opacity:(u=Y.hide)!==null&&u!==void 0&&u.referenceHidden?0:void 0}}))))}),Q5="PopperArrow",K5={top:"bottom",right:"left",bottom:"top",left:"right"},X5=x.forwardRef(function(t,n){const{__scopePopper:r,...o}=t,i=q5(Q5,r),l=K5[i.placedSide];return x.createElement("span",{ref:i.onArrowChange,style:{position:"absolute",left:i.arrowX,top:i.arrowY,[l]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[i.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[i.placedSide],visibility:i.shouldHideArrow?"hidden":void 0}},x.createElement(M5,ge({},o,{ref:n,style:{...o.style,display:"block"}})))});function Z5(e){return e!==null}const J5=e=>({name:"transformOrigin",options:e,fn(t){var n,r,o,i,l;const{placement:a,rects:s,middlewareData:u}=t,c=((n=u.arrow)===null||n===void 0?void 0:n.centerOffset)!==0,d=c?0:e.arrowWidth,f=c?0:e.arrowHeight,[h,m]=Sv(a),w={start:"0%",center:"50%",end:"100%"}[m],g=((r=(o=u.arrow)===null||o===void 0?void 0:o.x)!==null&&r!==void 0?r:0)+d/2,y=((i=(l=u.arrow)===null||l===void 0?void 0:l.y)!==null&&i!==void 0?i:0)+f/2;let v="",C="";return h==="bottom"?(v=c?w:`${g}px`,C=`${-f}px`):h==="top"?(v=c?w:`${g}px`,C=`${s.floating.height+f}px`):h==="right"?(v=`${-f}px`,C=c?w:`${y}px`):h==="left"&&(v=`${s.floating.width+f}px`,C=c?w:`${y}px`),{data:{x:v,y:C}}}});function Sv(e){const[t,n="center"]=e.split("-");return[t,n]}const e4=H5,t4=V5,n4=Y5,r4=X5,o4=x.forwardRef((e,t)=>x.createElement(Tt.span,ge({},e,{ref:t,style:{position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal",...e.style}}))),i4=o4,[vs,g_]=Qp("Tooltip",[xv]),ws=xv(),l4="TooltipProvider",a4=700,Ic="tooltip.open",[s4,vf]=vs(l4),u4=e=>{const{__scopeTooltip:t,delayDuration:n=a4,skipDelayDuration:r=300,disableHoverableContent:o=!1,children:i}=e,[l,a]=x.useState(!0),s=x.useRef(!1),u=x.useRef(0);return x.useEffect(()=>{const p=u.current;return()=>window.clearTimeout(p)},[]),x.createElement(s4,{scope:t,isOpenDelayed:l,delayDuration:n,onOpen:x.useCallback(()=>{window.clearTimeout(u.current),a(!1)},[]),onClose:x.useCallback(()=>{window.clearTimeout(u.current),u.current=window.setTimeout(()=>a(!0),r)},[r]),isPointerInTransitRef:s,onPointerInTransitChange:x.useCallback(p=>{s.current=p},[]),disableHoverableContent:o},i)},wf="Tooltip",[c4,xs]=vs(wf),p4=e=>{const{__scopeTooltip:t,children:n,open:r,defaultOpen:o=!1,onOpenChange:i,disableHoverableContent:l,delayDuration:a}=e,s=vf(wf,e.__scopeTooltip),u=ws(t),[p,c]=x.useState(null),d=Il(),f=x.useRef(0),h=l??s.disableHoverableContent,m=a??s.delayDuration,w=x.useRef(!1),[g=!1,y]=x1({prop:r,defaultProp:o,onChange:O=>{O?(s.onOpen(),document.dispatchEvent(new CustomEvent(Ic))):s.onClose(),i==null||i(O)}}),v=x.useMemo(()=>g?w.current?"delayed-open":"instant-open":"closed",[g]),C=x.useCallback(()=>{window.clearTimeout(f.current),w.current=!1,y(!0)},[y]),E=x.useCallback(()=>{window.clearTimeout(f.current),y(!1)},[y]),k=x.useCallback(()=>{window.clearTimeout(f.current),f.current=window.setTimeout(()=>{w.current=!0,y(!0)},m)},[m,y]);return x.useEffect(()=>()=>window.clearTimeout(f.current),[]),x.createElement(e4,u,x.createElement(c4,{scope:t,contentId:d,open:g,stateAttribute:v,trigger:p,onTriggerChange:c,onTriggerEnter:x.useCallback(()=>{s.isOpenDelayed?k():C()},[s.isOpenDelayed,k,C]),onTriggerLeave:x.useCallback(()=>{h?E():window.clearTimeout(f.current)},[E,h]),onOpen:C,onClose:E,disableHoverableContent:h},n))},km="TooltipTrigger",f4=x.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,o=xs(km,n),i=vf(km,n),l=ws(n),a=x.useRef(null),s=en(t,a,o.onTriggerChange),u=x.useRef(!1),p=x.useRef(!1),c=x.useCallback(()=>u.current=!1,[]);return x.useEffect(()=>()=>document.removeEventListener("pointerup",c),[c]),x.createElement(t4,ge({asChild:!0},l),x.createElement(Tt.button,ge({"aria-describedby":o.open?o.contentId:void 0,"data-state":o.stateAttribute},r,{ref:s,onPointerMove:Xe(e.onPointerMove,d=>{d.pointerType!=="touch"&&!p.current&&!i.isPointerInTransitRef.current&&(o.onTriggerEnter(),p.current=!0)}),onPointerLeave:Xe(e.onPointerLeave,()=>{o.onTriggerLeave(),p.current=!1}),onPointerDown:Xe(e.onPointerDown,()=>{u.current=!0,document.addEventListener("pointerup",c,{once:!0})}),onFocus:Xe(e.onFocus,()=>{u.current||o.onOpen()}),onBlur:Xe(e.onBlur,o.onClose),onClick:Xe(e.onClick,o.onClose)})))}),d4="TooltipPortal",[y_,h4]=vs(d4,{forceMount:void 0}),Ai="TooltipContent",m4=x.forwardRef((e,t)=>{const n=h4(Ai,e.__scopeTooltip),{forceMount:r=n.forceMount,side:o="top",...i}=e,l=xs(Ai,e.__scopeTooltip);return x.createElement(Ya,{present:r||l.open},l.disableHoverableContent?x.createElement(Cv,ge({side:o},i,{ref:t})):x.createElement(g4,ge({side:o},i,{ref:t})))}),g4=x.forwardRef((e,t)=>{const n=xs(Ai,e.__scopeTooltip),r=vf(Ai,e.__scopeTooltip),o=x.useRef(null),i=en(t,o),[l,a]=x.useState(null),{trigger:s,onClose:u}=n,p=o.current,{onPointerInTransitChange:c}=r,d=x.useCallback(()=>{a(null),c(!1)},[c]),f=x.useCallback((h,m)=>{const w=h.currentTarget,g={x:h.clientX,y:h.clientY},y=b4(g,w.getBoundingClientRect()),v=k4(g,y),C=S4(m.getBoundingClientRect()),E=E4([...v,...C]);a(E),c(!0)},[c]);return x.useEffect(()=>()=>d(),[d]),x.useEffect(()=>{if(s&&p){const h=w=>f(w,p),m=w=>f(w,s);return s.addEventListener("pointerleave",h),p.addEventListener("pointerleave",m),()=>{s.removeEventListener("pointerleave",h),p.removeEventListener("pointerleave",m)}}},[s,p,f,d]),x.useEffect(()=>{if(l){const h=m=>{const w=m.target,g={x:m.clientX,y:m.clientY},y=(s==null?void 0:s.contains(w))||(p==null?void 0:p.contains(w)),v=!C4(g,l);y?d():v&&(d(),u())};return document.addEventListener("pointermove",h),()=>document.removeEventListener("pointermove",h)}},[s,p,l,u,d]),x.createElement(Cv,ge({},e,{ref:i}))}),[y4,v4]=vs(wf,{isInside:!1}),Cv=x.forwardRef((e,t)=>{const{__scopeTooltip:n,children:r,"aria-label":o,onEscapeKeyDown:i,onPointerDownOutside:l,...a}=e,s=xs(Ai,n),u=ws(n),{onClose:p}=s;return x.useEffect(()=>(document.addEventListener(Ic,p),()=>document.removeEventListener(Ic,p)),[p]),x.useEffect(()=>{if(s.trigger){const c=d=>{const f=d.target;f!=null&&f.contains(s.trigger)&&p()};return window.addEventListener("scroll",c,{capture:!0}),()=>window.removeEventListener("scroll",c,{capture:!0})}},[s.trigger,p]),x.createElement(JE,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:i,onPointerDownOutside:l,onFocusOutside:c=>c.preventDefault(),onDismiss:p},x.createElement(n4,ge({"data-state":s.stateAttribute},u,a,{ref:t,style:{...a.style,"--radix-tooltip-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-tooltip-content-available-width":"var(--radix-popper-available-width)","--radix-tooltip-content-available-height":"var(--radix-popper-available-height)","--radix-tooltip-trigger-width":"var(--radix-popper-anchor-width)","--radix-tooltip-trigger-height":"var(--radix-popper-anchor-height)"}}),x.createElement(b1,null,r),x.createElement(y4,{scope:n,isInside:!0},x.createElement(i4,{id:s.contentId,role:"tooltip"},o||r))))}),w4="TooltipArrow",x4=x.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,o=ws(n);return v4(w4,n).isInside?null:x.createElement(r4,ge({},o,r,{ref:t}))});function b4(e,t){const n=Math.abs(t.top-e.y),r=Math.abs(t.bottom-e.y),o=Math.abs(t.right-e.x),i=Math.abs(t.left-e.x);switch(Math.min(n,r,o,i)){case i:return"left";case o:return"right";case n:return"top";case r:return"bottom";default:throw new Error("unreachable")}}function k4(e,t,n=5){const r=[];switch(t){case"top":r.push({x:e.x-n,y:e.y+n},{x:e.x+n,y:e.y+n});break;case"bottom":r.push({x:e.x-n,y:e.y-n},{x:e.x+n,y:e.y-n});break;case"left":r.push({x:e.x+n,y:e.y-n},{x:e.x+n,y:e.y+n});break;case"right":r.push({x:e.x-n,y:e.y-n},{x:e.x-n,y:e.y+n});break}return r}function S4(e){const{top:t,right:n,bottom:r,left:o}=e;return[{x:o,y:t},{x:n,y:t},{x:n,y:r},{x:o,y:r}]}function C4(e,t){const{x:n,y:r}=e;let o=!1;for(let i=0,l=t.length-1;ir!=p>r&&n<(u-a)*(r-s)/(p-s)+a&&(o=!o)}return o}function E4(e){const t=e.slice();return t.sort((n,r)=>n.xr.x?1:n.yr.y?1:0),P4(t)}function P4(e){if(e.length<=1)return e.slice();const t=[];for(let r=0;r=2;){const i=t[t.length-1],l=t[t.length-2];if((i.x-l.x)*(o.y-l.y)>=(i.y-l.y)*(o.x-l.x))t.pop();else break}t.push(o)}t.pop();const n=[];for(let r=e.length-1;r>=0;r--){const o=e[r];for(;n.length>=2;){const i=n[n.length-1],l=n[n.length-2];if((i.x-l.x)*(o.y-l.y)>=(i.y-l.y)*(o.x-l.x))n.pop();else break}n.push(o)}return n.pop(),t.length===1&&n.length===1&&t[0].x===n[0].x&&t[0].y===n[0].y?t:t.concat(n)}const O4=u4,T4=p4,A4=f4,Ev=m4,$4=x4,bs=A4;function Bi({children:e}){return L.jsx(O4,{children:L.jsx(T4,{children:e})})}Bi.displayName="ToolTip";const Ui=x.forwardRef(({className:e,children:t,sideOffset:n=0,arrowClassName:r,...o},i)=>L.jsx(Ev,{ref:i,sideOffset:n,dir:"auto",className:Tn("opencopilot-text-primary opencopilot-font-medium opencopilot-px-2 opencopilot-bg-accent opencopilot-z-[50000] opencopilot-py-1 opencopilot-overflow-hidden opencopilot-shadow opencopilot-min-w-fit opencopilot-max-w-[15rem] opencopilot-select-none opencopilot-rounded-sm opencopilot-p-0.5 opencopilot-text-xs opencopilot-leading-none","opencopilot-animate-in opencopilot-fade-in-0 opencopilot-slide-in-from-bottom-5 data-[state=closed]:animate-out data-[state=closed]:opencopilot-slide-in-from-top-0",e),...o,children:L.jsxs(L.Fragment,{children:[t,L.jsx($4,{className:Tn("opencopilot-fill-current opencopilot-text-accent opencopilot-animate-in opencopilot-slide-in-from-top-1 opencopilot-ease-out data-[state=closed]:opencopilot-animate-out",r)})]})}));Ui.displayName=Ev.displayName;function xf({text:e,every:t,onFinish:n,shouldStart:r=!0}){const[o,i]=x.useState(""),[l,a]=x.useState(0),[s,u]=x.useState(!1),p=t||1e-5;return x.useEffect(()=>{if(r)if(l{i(e.substring(0,l+1)),a(d=>d+1)},p);return()=>{clearInterval(c)}}else u(!0),typeof n=="function"&&n()},[e,l,p,n,r]),{displayText:o,isComplete:s,text:e}}const Sm=["http","https","mailto","tel"];function _4(e){const t=(e||"").trim(),n=t.charAt(0);if(n==="#"||n==="/")return t;const r=t.indexOf(":");if(r===-1)return t;let o=-1;for(;++oo||(o=t.indexOf("#"),o!==-1&&r>o)?t:"javascript:void(0)"}/*! * Determine if an object is a Buffer * * @author Feross Aboukhadijeh * @license MIT - */var k4=function(t){return t!=null&&t.constructor!=null&&typeof t.constructor.isBuffer=="function"&&t.constructor.isBuffer(t)};const xv=$r(k4);function ii(e){return!e||typeof e!="object"?"":"position"in e||"type"in e?bm(e.position):"start"in e||"end"in e?bm(e):"line"in e||"column"in e?Dc(e):""}function Dc(e){return km(e&&e.line)+":"+km(e&&e.column)}function bm(e){return Dc(e&&e.start)+"-"+Dc(e&&e.end)}function km(e){return e&&typeof e=="number"?e:1}class Bt extends Error{constructor(t,n,r){const o=[null,null];let i={start:{line:null,column:null},end:{line:null,column:null}};if(super(),typeof n=="string"&&(r=n,n=void 0),typeof r=="string"){const l=r.indexOf(":");l===-1?o[1]=r:(o[0]=r.slice(0,l),o[1]=r.slice(l+1))}n&&("type"in n||"position"in n?n.position&&(i=n.position):"start"in n||"end"in n?i=n:("line"in n||"column"in n)&&(i.start=n)),this.name=ii(n)||"1:1",this.message=typeof t=="object"?t.message:t,this.stack="",typeof t=="object"&&t.stack&&(this.stack=t.stack),this.reason=this.message,this.fatal,this.line=i.start.line,this.column=i.start.column,this.position=i,this.source=o[0],this.ruleId=o[1],this.file,this.actual,this.expected,this.url,this.note}}Bt.prototype.file="";Bt.prototype.name="";Bt.prototype.reason="";Bt.prototype.message="";Bt.prototype.stack="";Bt.prototype.fatal=null;Bt.prototype.column=null;Bt.prototype.line=null;Bt.prototype.source=null;Bt.prototype.ruleId=null;Bt.prototype.position=null;const nn={basename:S4,dirname:C4,extname:E4,join:P4,sep:"/"};function S4(e,t){if(t!==void 0&&typeof t!="string")throw new TypeError('"ext" argument must be a string');Bi(e);let n=0,r=-1,o=e.length,i;if(t===void 0||t.length===0||t.length>e.length){for(;o--;)if(e.charCodeAt(o)===47){if(i){n=o+1;break}}else r<0&&(i=!0,r=o+1);return r<0?"":e.slice(n,r)}if(t===e)return"";let l=-1,a=t.length-1;for(;o--;)if(e.charCodeAt(o)===47){if(i){n=o+1;break}}else l<0&&(i=!0,l=o+1),a>-1&&(e.charCodeAt(o)===t.charCodeAt(a--)?a<0&&(r=o):(a=-1,r=l));return n===r?r=l:r<0&&(r=e.length),e.slice(n,r)}function C4(e){if(Bi(e),e.length===0)return".";let t=-1,n=e.length,r;for(;--n;)if(e.charCodeAt(n)===47){if(r){t=n;break}}else r||(r=!0);return t<0?e.charCodeAt(0)===47?"/":".":t===1&&e.charCodeAt(0)===47?"//":e.slice(0,t)}function E4(e){Bi(e);let t=e.length,n=-1,r=0,o=-1,i=0,l;for(;t--;){const a=e.charCodeAt(t);if(a===47){if(l){r=t+1;break}continue}n<0&&(l=!0,n=t+1),a===46?o<0?o=t:i!==1&&(i=1):o>-1&&(i=-1)}return o<0||n<0||i===0||i===1&&o===n-1&&o===r+1?"":e.slice(o,n)}function P4(...e){let t=-1,n;for(;++t0&&e.charCodeAt(e.length-1)===47&&(n+="/"),t?"/"+n:n}function O4(e,t){let n="",r=0,o=-1,i=0,l=-1,a,s;for(;++l<=e.length;){if(l2){if(s=n.lastIndexOf("/"),s!==n.length-1){s<0?(n="",r=0):(n=n.slice(0,s),r=n.length-1-n.lastIndexOf("/")),o=l,i=0;continue}}else if(n.length>0){n="",r=0,o=l,i=0;continue}}t&&(n=n.length>0?n+"/..":"..",r=2)}else n.length>0?n+="/"+e.slice(o+1,l):n=e.slice(o+1,l),r=l-o-1;o=l,i=0}else a===46&&i>-1?i++:i=-1}return n}function Bi(e){if(typeof e!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}const A4={cwd:_4};function _4(){return"/"}function Nc(e){return e!==null&&typeof e=="object"&&e.href&&e.origin}function $4(e){if(typeof e=="string")e=new URL(e);else if(!Nc(e)){const t=new TypeError('The "path" argument must be of type string or an instance of URL. Received `'+e+"`");throw t.code="ERR_INVALID_ARG_TYPE",t}if(e.protocol!=="file:"){const t=new TypeError("The URL must be of scheme file");throw t.code="ERR_INVALID_URL_SCHEME",t}return R4(e)}function R4(e){if(e.hostname!==""){const r=new TypeError('File URL host must be "localhost" or empty on darwin');throw r.code="ERR_INVALID_FILE_URL_HOST",r}const t=e.pathname;let n=-1;for(;++n"u"||jl.call(t,o)},Am=function(t,n){Em&&n.name==="__proto__"?Em(t,n.name,{enumerable:!0,configurable:!0,value:n.newValue,writable:!0}):t[n.name]=n.newValue},_m=function(t,n){if(n==="__proto__")if(jl.call(t,n)){if(Pm)return Pm(t,n).value}else return;return t[n]},z4=function e(){var t,n,r,o,i,l,a=arguments[0],s=1,u=arguments.length,c=!1;for(typeof a=="boolean"&&(c=a,a=arguments[1]||{},s=2),(a==null||typeof a!="object"&&typeof a!="function")&&(a={});sl.length;let s;a&&l.push(o);try{s=e.apply(this,l)}catch(u){const c=u;if(a&&n)throw c;return o(c)}a||(s instanceof Promise?s.then(i,o):s instanceof Error?o(s):i(s))}function o(l,...a){n||(n=!0,t(l,...a))}function i(l){o(null,l)}}const I4=Cv().freeze(),Sv={}.hasOwnProperty;function Cv(){const e=D4(),t=[];let n={},r,o=-1;return i.data=l,i.Parser=void 0,i.Compiler=void 0,i.freeze=a,i.attachers=t,i.use=s,i.parse=u,i.stringify=c,i.run=p,i.runSync=d,i.process=f,i.processSync=h,i;function i(){const m=Cv();let w=-1;for(;++w{if(k||!T||!A)E(k);else{const N=i.stringify(T,A);N==null||(M4(N)?A.value=N:A.result=N),E(k,A)}});function E(k,T){k||!T?v(k):y?y(T):w(null,T)}}}function h(m){let w;i.freeze(),pu("processSync",i.Parser),fu("processSync",i.Compiler);const g=Ho(m);return i.process(g,y),zm("processSync","process",w),g;function y(v){w=!0,Cm(v)}}}function Rm(e,t){return typeof e=="function"&&e.prototype&&(F4(e.prototype)||t in e.prototype)}function F4(e){let t;for(t in e)if(Sv.call(e,t))return!0;return!1}function pu(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `Parser`")}function fu(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `Compiler`")}function du(e,t){if(t)throw new Error("Cannot call `"+e+"` on a frozen processor.\nCreate a new processor first, by calling it: use `processor()` instead of `processor`.")}function Lm(e){if(!Ic(e)||typeof e.type!="string")throw new TypeError("Expected node, got `"+e+"`")}function zm(e,t,n){if(!n)throw new Error("`"+e+"` finished async. Use `"+t+"` instead")}function Ho(e){return j4(e)?e:new bv(e)}function j4(e){return!!(e&&typeof e=="object"&&"message"in e&&"messages"in e)}function M4(e){return typeof e=="string"||xv(e)}const B4={};function U4(e,t){const n=t||B4,r=typeof n.includeImageAlt=="boolean"?n.includeImageAlt:!0,o=typeof n.includeHtml=="boolean"?n.includeHtml:!0;return Ev(e,r,o)}function Ev(e,t,n){if(H4(e)){if("value"in e)return e.type==="html"&&!n?"":e.value;if(t&&"alt"in e&&e.alt)return e.alt;if("children"in e)return Dm(e.children,t,n)}return Array.isArray(e)?Dm(e,t,n):""}function Dm(e,t,n){const r=[];let o=-1;for(;++oo?0:o+t:t=t>o?o:t,n=n>0?n:0,r.length<1e4)l=Array.from(r),l.unshift(t,n),e.splice(...l);else for(n&&e.splice(t,n);i0?(Ct(e,e.length,0,t),e):t}const Nm={}.hasOwnProperty;function Pv(e){const t={};let n=-1;for(;++nl))return;const T=t.events.length;let A=T,N,P;for(;A--;)if(t.events[A][0]==="exit"&&t.events[A][1].type==="chunkFlow"){if(N){P=t.events[A][1].end;break}N=!0}for(g(r),k=T;kv;){const E=n[C];t.containerState=E[1],E[0].exit.call(t,e)}n.length=v}function y(){o.write([null]),i=void 0,o=void 0,t.containerState._closeFlow=void 0}}function eP(e,t,n){return me(e,e.attempt(this.parser.constructs.document,t,n),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}function wa(e){if(e===null||Se(e)||_r(e))return 1;if(ws(e))return 2}function xs(e,t,n){const r=[];let o=-1;for(;++o1&&e[n][1].end.offset-e[n][1].start.offset>1?2:1;const p=Object.assign({},e[r][1].end),d=Object.assign({},e[n][1].start);Fm(p,-s),Fm(d,s),l={type:s>1?"strongSequence":"emphasisSequence",start:p,end:Object.assign({},e[r][1].end)},a={type:s>1?"strongSequence":"emphasisSequence",start:Object.assign({},e[n][1].start),end:d},i={type:s>1?"strongText":"emphasisText",start:Object.assign({},e[r][1].end),end:Object.assign({},e[n][1].start)},o={type:s>1?"strong":"emphasis",start:Object.assign({},l.start),end:Object.assign({},a.end)},e[r][1].end=Object.assign({},l.start),e[n][1].start=Object.assign({},a.end),u=[],e[r][1].end.offset-e[r][1].start.offset&&(u=Rt(u,[["enter",e[r][1],t],["exit",e[r][1],t]])),u=Rt(u,[["enter",o,t],["enter",l,t],["exit",l,t],["enter",i,t]]),u=Rt(u,xs(t.parser.constructs.insideSpan.null,e.slice(r+1,n),t)),u=Rt(u,[["exit",i,t],["enter",a,t],["exit",a,t],["exit",o,t]]),e[n][1].end.offset-e[n][1].start.offset?(c=2,u=Rt(u,[["enter",e[n][1],t],["exit",e[n][1],t]])):c=0,Ct(e,r-1,n-r+3,u),n=r+u.length-c-2;break}}for(n=-1;++n0&&se(k)?me(e,y,"linePrefix",i+1)(k):y(k)}function y(k){return k===null||X(k)?e.check(Mm,m,C)(k):(e.enter("codeFlowValue"),v(k))}function v(k){return k===null||X(k)?(e.exit("codeFlowValue"),y(k)):(e.consume(k),v)}function C(k){return e.exit("codeFenced"),t(k)}function E(k,T,A){let N=0;return P;function P(W){return k.enter("lineEnding"),k.consume(W),k.exit("lineEnding"),z}function z(W){return k.enter("codeFencedFence"),se(W)?me(k,_,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(W):_(W)}function _(W){return W===a?(k.enter("codeFencedFenceSequence"),Y(W)):A(W)}function Y(W){return W===a?(N++,k.consume(W),Y):N>=l?(k.exit("codeFencedFenceSequence"),se(W)?me(k,H,"whitespace")(W):H(W)):A(W)}function H(W){return W===null||X(W)?(k.exit("codeFencedFence"),T(W)):A(W)}}}function fP(e,t,n){const r=this;return o;function o(l){return l===null?n(l):(e.enter("lineEnding"),e.consume(l),e.exit("lineEnding"),i)}function i(l){return r.parser.lazy[r.now().line]?n(l):t(l)}}const hu={name:"codeIndented",tokenize:hP},dP={tokenize:mP,partial:!0};function hP(e,t,n){const r=this;return o;function o(u){return e.enter("codeIndented"),me(e,i,"linePrefix",4+1)(u)}function i(u){const c=r.events[r.events.length-1];return c&&c[1].type==="linePrefix"&&c[2].sliceSerialize(c[1],!0).length>=4?l(u):n(u)}function l(u){return u===null?s(u):X(u)?e.attempt(dP,l,s)(u):(e.enter("codeFlowValue"),a(u))}function a(u){return u===null||X(u)?(e.exit("codeFlowValue"),l(u)):(e.consume(u),a)}function s(u){return e.exit("codeIndented"),t(u)}}function mP(e,t,n){const r=this;return o;function o(l){return r.parser.lazy[r.now().line]?n(l):X(l)?(e.enter("lineEnding"),e.consume(l),e.exit("lineEnding"),o):me(e,i,"linePrefix",4+1)(l)}function i(l){const a=r.events[r.events.length-1];return a&&a[1].type==="linePrefix"&&a[2].sliceSerialize(a[1],!0).length>=4?t(l):X(l)?o(l):n(l)}}const gP={name:"codeText",tokenize:wP,resolve:yP,previous:vP};function yP(e){let t=e.length-4,n=3,r,o;if((e[n][1].type==="lineEnding"||e[n][1].type==="space")&&(e[t][1].type==="lineEnding"||e[t][1].type==="space")){for(r=n;++r=4?t(l):e.interrupt(r.parser.constructs.flow,n,t)(l)}}function $v(e,t,n,r,o,i,l,a,s){const u=s||Number.POSITIVE_INFINITY;let c=0;return p;function p(g){return g===60?(e.enter(r),e.enter(o),e.enter(i),e.consume(g),e.exit(i),d):g===null||g===32||g===41||va(g)?n(g):(e.enter(r),e.enter(l),e.enter(a),e.enter("chunkString",{contentType:"string"}),m(g))}function d(g){return g===62?(e.enter(i),e.consume(g),e.exit(i),e.exit(o),e.exit(r),t):(e.enter(a),e.enter("chunkString",{contentType:"string"}),f(g))}function f(g){return g===62?(e.exit("chunkString"),e.exit(a),d(g)):g===null||g===60||X(g)?n(g):(e.consume(g),g===92?h:f)}function h(g){return g===60||g===62||g===92?(e.consume(g),f):f(g)}function m(g){return!c&&(g===null||g===41||Se(g))?(e.exit("chunkString"),e.exit(a),e.exit(l),e.exit(r),t(g)):c999||f===null||f===91||f===93&&!s||f===94&&!a&&"_hiddenFootnoteSupport"in l.parser.constructs?n(f):f===93?(e.exit(i),e.enter(o),e.consume(f),e.exit(o),e.exit(r),t):X(f)?(e.enter("lineEnding"),e.consume(f),e.exit("lineEnding"),c):(e.enter("chunkString",{contentType:"string"}),p(f))}function p(f){return f===null||f===91||f===93||X(f)||a++>999?(e.exit("chunkString"),c(f)):(e.consume(f),s||(s=!se(f)),f===92?d:p)}function d(f){return f===91||f===92||f===93?(e.consume(f),a++,p):p(f)}}function Lv(e,t,n,r,o,i){let l;return a;function a(d){return d===34||d===39||d===40?(e.enter(r),e.enter(o),e.consume(d),e.exit(o),l=d===40?41:d,s):n(d)}function s(d){return d===l?(e.enter(o),e.consume(d),e.exit(o),e.exit(r),t):(e.enter(i),u(d))}function u(d){return d===l?(e.exit(i),s(l)):d===null?n(d):X(d)?(e.enter("lineEnding"),e.consume(d),e.exit("lineEnding"),me(e,u,"linePrefix")):(e.enter("chunkString",{contentType:"string"}),c(d))}function c(d){return d===l||d===null||X(d)?(e.exit("chunkString"),u(d)):(e.consume(d),d===92?p:c)}function p(d){return d===l||d===92?(e.consume(d),c):c(d)}}function li(e,t){let n;return r;function r(o){return X(o)?(e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),n=!0,r):se(o)?me(e,r,n?"linePrefix":"lineSuffix")(o):t(o)}}function Zt(e){return e.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}const PP={name:"definition",tokenize:OP},TP={tokenize:AP,partial:!0};function OP(e,t,n){const r=this;let o;return i;function i(f){return e.enter("definition"),l(f)}function l(f){return Rv.call(r,e,a,n,"definitionLabel","definitionLabelMarker","definitionLabelString")(f)}function a(f){return o=Zt(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)),f===58?(e.enter("definitionMarker"),e.consume(f),e.exit("definitionMarker"),s):n(f)}function s(f){return Se(f)?li(e,u)(f):u(f)}function u(f){return $v(e,c,n,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(f)}function c(f){return e.attempt(TP,p,p)(f)}function p(f){return se(f)?me(e,d,"whitespace")(f):d(f)}function d(f){return f===null||X(f)?(e.exit("definition"),r.parser.defined.push(o),t(f)):n(f)}}function AP(e,t,n){return r;function r(a){return Se(a)?li(e,o)(a):n(a)}function o(a){return Lv(e,i,n,"definitionTitle","definitionTitleMarker","definitionTitleString")(a)}function i(a){return se(a)?me(e,l,"whitespace")(a):l(a)}function l(a){return a===null||X(a)?t(a):n(a)}}const _P={name:"hardBreakEscape",tokenize:$P};function $P(e,t,n){return r;function r(i){return e.enter("hardBreakEscape"),e.consume(i),o}function o(i){return X(i)?(e.exit("hardBreakEscape"),t(i)):n(i)}}const RP={name:"headingAtx",tokenize:zP,resolve:LP};function LP(e,t){let n=e.length-2,r=3,o,i;return e[r][1].type==="whitespace"&&(r+=2),n-2>r&&e[n][1].type==="whitespace"&&(n-=2),e[n][1].type==="atxHeadingSequence"&&(r===n-1||n-4>r&&e[n-2][1].type==="whitespace")&&(n-=r+1===n?2:4),n>r&&(o={type:"atxHeadingText",start:e[r][1].start,end:e[n][1].end},i={type:"chunkText",start:e[r][1].start,end:e[n][1].end,contentType:"text"},Ct(e,r,n-r+1,[["enter",o,t],["enter",i,t],["exit",i,t],["exit",o,t]])),e}function zP(e,t,n){let r=0;return o;function o(c){return e.enter("atxHeading"),i(c)}function i(c){return e.enter("atxHeadingSequence"),l(c)}function l(c){return c===35&&r++<6?(e.consume(c),l):c===null||Se(c)?(e.exit("atxHeadingSequence"),a(c)):n(c)}function a(c){return c===35?(e.enter("atxHeadingSequence"),s(c)):c===null||X(c)?(e.exit("atxHeading"),t(c)):se(c)?me(e,a,"whitespace")(c):(e.enter("atxHeadingText"),u(c))}function s(c){return c===35?(e.consume(c),s):(e.exit("atxHeadingSequence"),a(c))}function u(c){return c===null||c===35||Se(c)?(e.exit("atxHeadingText"),a(c)):(e.consume(c),u)}}const DP=["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"],Um=["pre","script","style","textarea"],NP={name:"htmlFlow",tokenize:MP,resolveTo:jP,concrete:!0},IP={tokenize:UP,partial:!0},FP={tokenize:BP,partial:!0};function jP(e){let t=e.length;for(;t--&&!(e[t][0]==="enter"&&e[t][1].type==="htmlFlow"););return t>1&&e[t-2][1].type==="linePrefix"&&(e[t][1].start=e[t-2][1].start,e[t+1][1].start=e[t-2][1].start,e.splice(t-2,2)),e}function MP(e,t,n){const r=this;let o,i,l,a,s;return u;function u(x){return c(x)}function c(x){return e.enter("htmlFlow"),e.enter("htmlFlowData"),e.consume(x),p}function p(x){return x===33?(e.consume(x),d):x===47?(e.consume(x),i=!0,m):x===63?(e.consume(x),o=3,r.interrupt?t:S):lt(x)?(e.consume(x),l=String.fromCharCode(x),w):n(x)}function d(x){return x===45?(e.consume(x),o=2,f):x===91?(e.consume(x),o=5,a=0,h):lt(x)?(e.consume(x),o=4,r.interrupt?t:S):n(x)}function f(x){return x===45?(e.consume(x),r.interrupt?t:S):n(x)}function h(x){const U="CDATA[";return x===U.charCodeAt(a++)?(e.consume(x),a===U.length?r.interrupt?t:_:h):n(x)}function m(x){return lt(x)?(e.consume(x),l=String.fromCharCode(x),w):n(x)}function w(x){if(x===null||x===47||x===62||Se(x)){const U=x===47,Q=l.toLowerCase();return!U&&!i&&Um.includes(Q)?(o=1,r.interrupt?t(x):_(x)):DP.includes(l.toLowerCase())?(o=6,U?(e.consume(x),g):r.interrupt?t(x):_(x)):(o=7,r.interrupt&&!r.parser.lazy[r.now().line]?n(x):i?y(x):v(x))}return x===45||nt(x)?(e.consume(x),l+=String.fromCharCode(x),w):n(x)}function g(x){return x===62?(e.consume(x),r.interrupt?t:_):n(x)}function y(x){return se(x)?(e.consume(x),y):P(x)}function v(x){return x===47?(e.consume(x),P):x===58||x===95||lt(x)?(e.consume(x),C):se(x)?(e.consume(x),v):P(x)}function C(x){return x===45||x===46||x===58||x===95||nt(x)?(e.consume(x),C):E(x)}function E(x){return x===61?(e.consume(x),k):se(x)?(e.consume(x),E):v(x)}function k(x){return x===null||x===60||x===61||x===62||x===96?n(x):x===34||x===39?(e.consume(x),s=x,T):se(x)?(e.consume(x),k):A(x)}function T(x){return x===s?(e.consume(x),s=null,N):x===null||X(x)?n(x):(e.consume(x),T)}function A(x){return x===null||x===34||x===39||x===47||x===60||x===61||x===62||x===96||Se(x)?E(x):(e.consume(x),A)}function N(x){return x===47||x===62||se(x)?v(x):n(x)}function P(x){return x===62?(e.consume(x),z):n(x)}function z(x){return x===null||X(x)?_(x):se(x)?(e.consume(x),z):n(x)}function _(x){return x===45&&o===2?(e.consume(x),q):x===60&&o===1?(e.consume(x),K):x===62&&o===4?(e.consume(x),Z):x===63&&o===3?(e.consume(x),S):x===93&&o===5?(e.consume(x),V):X(x)&&(o===6||o===7)?(e.exit("htmlFlowData"),e.check(IP,F,Y)(x)):x===null||X(x)?(e.exit("htmlFlowData"),Y(x)):(e.consume(x),_)}function Y(x){return e.check(FP,H,F)(x)}function H(x){return e.enter("lineEnding"),e.consume(x),e.exit("lineEnding"),W}function W(x){return x===null||X(x)?Y(x):(e.enter("htmlFlowData"),_(x))}function q(x){return x===45?(e.consume(x),S):_(x)}function K(x){return x===47?(e.consume(x),l="",D):_(x)}function D(x){if(x===62){const U=l.toLowerCase();return Um.includes(U)?(e.consume(x),Z):_(x)}return lt(x)&&l.length<8?(e.consume(x),l+=String.fromCharCode(x),D):_(x)}function V(x){return x===93?(e.consume(x),S):_(x)}function S(x){return x===62?(e.consume(x),Z):x===45&&o===2?(e.consume(x),S):_(x)}function Z(x){return x===null||X(x)?(e.exit("htmlFlowData"),F(x)):(e.consume(x),Z)}function F(x){return e.exit("htmlFlow"),t(x)}}function BP(e,t,n){const r=this;return o;function o(l){return X(l)?(e.enter("lineEnding"),e.consume(l),e.exit("lineEnding"),i):n(l)}function i(l){return r.parser.lazy[r.now().line]?n(l):t(l)}}function UP(e,t,n){return r;function r(o){return e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),e.attempt(Ui,t,n)}}const HP={name:"htmlText",tokenize:WP};function WP(e,t,n){const r=this;let o,i,l;return a;function a(S){return e.enter("htmlText"),e.enter("htmlTextData"),e.consume(S),s}function s(S){return S===33?(e.consume(S),u):S===47?(e.consume(S),E):S===63?(e.consume(S),v):lt(S)?(e.consume(S),A):n(S)}function u(S){return S===45?(e.consume(S),c):S===91?(e.consume(S),i=0,h):lt(S)?(e.consume(S),y):n(S)}function c(S){return S===45?(e.consume(S),f):n(S)}function p(S){return S===null?n(S):S===45?(e.consume(S),d):X(S)?(l=p,K(S)):(e.consume(S),p)}function d(S){return S===45?(e.consume(S),f):p(S)}function f(S){return S===62?q(S):S===45?d(S):p(S)}function h(S){const Z="CDATA[";return S===Z.charCodeAt(i++)?(e.consume(S),i===Z.length?m:h):n(S)}function m(S){return S===null?n(S):S===93?(e.consume(S),w):X(S)?(l=m,K(S)):(e.consume(S),m)}function w(S){return S===93?(e.consume(S),g):m(S)}function g(S){return S===62?q(S):S===93?(e.consume(S),g):m(S)}function y(S){return S===null||S===62?q(S):X(S)?(l=y,K(S)):(e.consume(S),y)}function v(S){return S===null?n(S):S===63?(e.consume(S),C):X(S)?(l=v,K(S)):(e.consume(S),v)}function C(S){return S===62?q(S):v(S)}function E(S){return lt(S)?(e.consume(S),k):n(S)}function k(S){return S===45||nt(S)?(e.consume(S),k):T(S)}function T(S){return X(S)?(l=T,K(S)):se(S)?(e.consume(S),T):q(S)}function A(S){return S===45||nt(S)?(e.consume(S),A):S===47||S===62||Se(S)?N(S):n(S)}function N(S){return S===47?(e.consume(S),q):S===58||S===95||lt(S)?(e.consume(S),P):X(S)?(l=N,K(S)):se(S)?(e.consume(S),N):q(S)}function P(S){return S===45||S===46||S===58||S===95||nt(S)?(e.consume(S),P):z(S)}function z(S){return S===61?(e.consume(S),_):X(S)?(l=z,K(S)):se(S)?(e.consume(S),z):N(S)}function _(S){return S===null||S===60||S===61||S===62||S===96?n(S):S===34||S===39?(e.consume(S),o=S,Y):X(S)?(l=_,K(S)):se(S)?(e.consume(S),_):(e.consume(S),H)}function Y(S){return S===o?(e.consume(S),o=void 0,W):S===null?n(S):X(S)?(l=Y,K(S)):(e.consume(S),Y)}function H(S){return S===null||S===34||S===39||S===60||S===61||S===96?n(S):S===47||S===62||Se(S)?N(S):(e.consume(S),H)}function W(S){return S===47||S===62||Se(S)?N(S):n(S)}function q(S){return S===62?(e.consume(S),e.exit("htmlTextData"),e.exit("htmlText"),t):n(S)}function K(S){return e.exit("htmlTextData"),e.enter("lineEnding"),e.consume(S),e.exit("lineEnding"),D}function D(S){return se(S)?me(e,V,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(S):V(S)}function V(S){return e.enter("htmlTextData"),l(S)}}const bf={name:"labelEnd",tokenize:KP,resolveTo:QP,resolveAll:YP},VP={tokenize:XP},GP={tokenize:ZP},qP={tokenize:JP};function YP(e){let t=-1;for(;++t=3&&(u===null||X(u))?(e.exit("thematicBreak"),t(u)):n(u)}function s(u){return u===o?(e.consume(u),r++,s):(e.exit("thematicBreakSequence"),se(u)?me(e,a,"whitespace")(u):a(u))}}const ct={name:"list",tokenize:s3,continuation:{tokenize:u3},exit:p3},l3={tokenize:f3,partial:!0},a3={tokenize:c3,partial:!0};function s3(e,t,n){const r=this,o=r.events[r.events.length-1];let i=o&&o[1].type==="linePrefix"?o[2].sliceSerialize(o[1],!0).length:0,l=0;return a;function a(f){const h=r.containerState.type||(f===42||f===43||f===45?"listUnordered":"listOrdered");if(h==="listUnordered"?!r.containerState.marker||f===r.containerState.marker:Fc(f)){if(r.containerState.type||(r.containerState.type=h,e.enter(h,{_container:!0})),h==="listUnordered")return e.enter("listItemPrefix"),f===42||f===45?e.check(Ml,n,u)(f):u(f);if(!r.interrupt||f===49)return e.enter("listItemPrefix"),e.enter("listItemValue"),s(f)}return n(f)}function s(f){return Fc(f)&&++l<10?(e.consume(f),s):(!r.interrupt||l<2)&&(r.containerState.marker?f===r.containerState.marker:f===41||f===46)?(e.exit("listItemValue"),u(f)):n(f)}function u(f){return e.enter("listItemMarker"),e.consume(f),e.exit("listItemMarker"),r.containerState.marker=r.containerState.marker||f,e.check(Ui,r.interrupt?n:c,e.attempt(l3,d,p))}function c(f){return r.containerState.initialBlankLine=!0,i++,d(f)}function p(f){return se(f)?(e.enter("listItemPrefixWhitespace"),e.consume(f),e.exit("listItemPrefixWhitespace"),d):n(f)}function d(f){return r.containerState.size=i+r.sliceSerialize(e.exit("listItemPrefix"),!0).length,t(f)}}function u3(e,t,n){const r=this;return r.containerState._closeFlow=void 0,e.check(Ui,o,i);function o(a){return r.containerState.furtherBlankLines=r.containerState.furtherBlankLines||r.containerState.initialBlankLine,me(e,t,"listItemIndent",r.containerState.size+1)(a)}function i(a){return r.containerState.furtherBlankLines||!se(a)?(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,l(a)):(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,e.attempt(a3,t,l)(a))}function l(a){return r.containerState._closeFlow=!0,r.interrupt=void 0,me(e,e.attempt(ct,t,n),"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(a)}}function c3(e,t,n){const r=this;return me(e,o,"listItemIndent",r.containerState.size+1);function o(i){const l=r.events[r.events.length-1];return l&&l[1].type==="listItemIndent"&&l[2].sliceSerialize(l[1],!0).length===r.containerState.size?t(i):n(i)}}function p3(e){e.exit(this.containerState.type)}function f3(e,t,n){const r=this;return me(e,o,"listItemPrefixWhitespace",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4+1);function o(i){const l=r.events[r.events.length-1];return!se(i)&&l&&l[1].type==="listItemPrefixWhitespace"?t(i):n(i)}}const Hm={name:"setextUnderline",tokenize:h3,resolveTo:d3};function d3(e,t){let n=e.length,r,o,i;for(;n--;)if(e[n][0]==="enter"){if(e[n][1].type==="content"){r=n;break}e[n][1].type==="paragraph"&&(o=n)}else e[n][1].type==="content"&&e.splice(n,1),!i&&e[n][1].type==="definition"&&(i=n);const l={type:"setextHeading",start:Object.assign({},e[o][1].start),end:Object.assign({},e[e.length-1][1].end)};return e[o][1].type="setextHeadingText",i?(e.splice(o,0,["enter",l,t]),e.splice(i+1,0,["exit",e[r][1],t]),e[r][1].end=Object.assign({},e[i][1].end)):e[r][1]=l,e.push(["exit",l,t]),e}function h3(e,t,n){const r=this;let o;return i;function i(u){let c=r.events.length,p;for(;c--;)if(r.events[c][1].type!=="lineEnding"&&r.events[c][1].type!=="linePrefix"&&r.events[c][1].type!=="content"){p=r.events[c][1].type==="paragraph";break}return!r.parser.lazy[r.now().line]&&(r.interrupt||p)?(e.enter("setextHeadingLine"),o=u,l(u)):n(u)}function l(u){return e.enter("setextHeadingLineSequence"),a(u)}function a(u){return u===o?(e.consume(u),a):(e.exit("setextHeadingLineSequence"),se(u)?me(e,s,"lineSuffix")(u):s(u))}function s(u){return u===null||X(u)?(e.exit("setextHeadingLine"),t(u)):n(u)}}const m3={tokenize:g3};function g3(e){const t=this,n=e.attempt(Ui,r,e.attempt(this.parser.constructs.flowInitial,o,me(e,e.attempt(this.parser.constructs.flow,o,e.attempt(bP,o)),"linePrefix")));return n;function r(i){if(i===null){e.consume(i);return}return e.enter("lineEndingBlank"),e.consume(i),e.exit("lineEndingBlank"),t.currentConstruct=void 0,n}function o(i){if(i===null){e.consume(i);return}return e.enter("lineEnding"),e.consume(i),e.exit("lineEnding"),t.currentConstruct=void 0,n}}const y3={resolveAll:Dv()},v3=zv("string"),w3=zv("text");function zv(e){return{tokenize:t,resolveAll:Dv(e==="text"?x3:void 0)};function t(n){const r=this,o=this.parser.constructs[e],i=n.attempt(o,l,a);return l;function l(c){return u(c)?i(c):a(c)}function a(c){if(c===null){n.consume(c);return}return n.enter("data"),n.consume(c),s}function s(c){return u(c)?(n.exit("data"),i(c)):(n.consume(c),s)}function u(c){if(c===null)return!0;const p=o[c];let d=-1;if(p)for(;++d-1){const a=l[0];typeof a=="string"?l[0]=a.slice(r):l.shift()}i>0&&l.push(e[o].slice(0,i))}return l}function S3(e,t){let n=-1;const r=[];let o;for(;++ne.length){for(;o--;)if(e.charCodeAt(o)===47){if(i){n=o+1;break}}else r<0&&(i=!0,r=o+1);return r<0?"":e.slice(n,r)}if(t===e)return"";let l=-1,a=t.length-1;for(;o--;)if(e.charCodeAt(o)===47){if(i){n=o+1;break}}else l<0&&(i=!0,l=o+1),a>-1&&(e.charCodeAt(o)===t.charCodeAt(a--)?a<0&&(r=o):(a=-1,r=l));return n===r?r=l:r<0&&(r=e.length),e.slice(n,r)}function D4(e){if(Hi(e),e.length===0)return".";let t=-1,n=e.length,r;for(;--n;)if(e.charCodeAt(n)===47){if(r){t=n;break}}else r||(r=!0);return t<0?e.charCodeAt(0)===47?"/":".":t===1&&e.charCodeAt(0)===47?"//":e.slice(0,t)}function z4(e){Hi(e);let t=e.length,n=-1,r=0,o=-1,i=0,l;for(;t--;){const a=e.charCodeAt(t);if(a===47){if(l){r=t+1;break}continue}n<0&&(l=!0,n=t+1),a===46?o<0?o=t:i!==1&&(i=1):o>-1&&(i=-1)}return o<0||n<0||i===0||i===1&&o===n-1&&o===r+1?"":e.slice(o,n)}function N4(...e){let t=-1,n;for(;++t0&&e.charCodeAt(e.length-1)===47&&(n+="/"),t?"/"+n:n}function F4(e,t){let n="",r=0,o=-1,i=0,l=-1,a,s;for(;++l<=e.length;){if(l2){if(s=n.lastIndexOf("/"),s!==n.length-1){s<0?(n="",r=0):(n=n.slice(0,s),r=n.length-1-n.lastIndexOf("/")),o=l,i=0;continue}}else if(n.length>0){n="",r=0,o=l,i=0;continue}}t&&(n=n.length>0?n+"/..":"..",r=2)}else n.length>0?n+="/"+e.slice(o+1,l):n=e.slice(o+1,l),r=l-o-1;o=l,i=0}else a===46&&i>-1?i++:i=-1}return n}function Hi(e){if(typeof e!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}const j4={cwd:M4};function M4(){return"/"}function jc(e){return e!==null&&typeof e=="object"&&e.href&&e.origin}function B4(e){if(typeof e=="string")e=new URL(e);else if(!jc(e)){const t=new TypeError('The "path" argument must be of type string or an instance of URL. Received `'+e+"`");throw t.code="ERR_INVALID_ARG_TYPE",t}if(e.protocol!=="file:"){const t=new TypeError("The URL must be of scheme file");throw t.code="ERR_INVALID_URL_SCHEME",t}return U4(e)}function U4(e){if(e.hostname!==""){const r=new TypeError('File URL host must be "localhost" or empty on darwin');throw r.code="ERR_INVALID_FILE_URL_HOST",r}const t=e.pathname;let n=-1;for(;++n"u"||Ul.call(t,o)},Rm=function(t,n){Tm&&n.name==="__proto__"?Tm(t,n.name,{enumerable:!0,configurable:!0,value:n.newValue,writable:!0}):t[n.name]=n.newValue},Lm=function(t,n){if(n==="__proto__")if(Ul.call(t,n)){if(Am)return Am(t,n).value}else return;return t[n]},W4=function e(){var t,n,r,o,i,l,a=arguments[0],s=1,u=arguments.length,p=!1;for(typeof a=="boolean"&&(p=a,a=arguments[1]||{},s=2),(a==null||typeof a!="object"&&typeof a!="function")&&(a={});sl.length;let s;a&&l.push(o);try{s=e.apply(this,l)}catch(u){const p=u;if(a&&n)throw p;return o(p)}a||(s instanceof Promise?s.then(i,o):s instanceof Error?o(s):i(s))}function o(l,...a){n||(n=!0,t(l,...a))}function i(l){o(null,l)}}const q4=$v().freeze(),Av={}.hasOwnProperty;function $v(){const e=V4(),t=[];let n={},r,o=-1;return i.data=l,i.Parser=void 0,i.Compiler=void 0,i.freeze=a,i.attachers=t,i.use=s,i.parse=u,i.stringify=p,i.run=c,i.runSync=d,i.process=f,i.processSync=h,i;function i(){const m=$v();let w=-1;for(;++w{if(k||!O||!T)E(k);else{const N=i.stringify(O,T);N==null||(K4(N)?T.value=N:T.result=N),E(k,T)}});function E(k,O){k||!O?v(k):y?y(O):w(null,O)}}}function h(m){let w;i.freeze(),hu("processSync",i.Parser),mu("processSync",i.Compiler);const g=Wo(m);return i.process(g,y),Im("processSync","process",w),g;function y(v){w=!0,Om(v)}}}function zm(e,t){return typeof e=="function"&&e.prototype&&(Y4(e.prototype)||t in e.prototype)}function Y4(e){let t;for(t in e)if(Av.call(e,t))return!0;return!1}function hu(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `Parser`")}function mu(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `Compiler`")}function gu(e,t){if(t)throw new Error("Cannot call `"+e+"` on a frozen processor.\nCreate a new processor first, by calling it: use `processor()` instead of `processor`.")}function Nm(e){if(!Mc(e)||typeof e.type!="string")throw new TypeError("Expected node, got `"+e+"`")}function Im(e,t,n){if(!n)throw new Error("`"+e+"` finished async. Use `"+t+"` instead")}function Wo(e){return Q4(e)?e:new Ov(e)}function Q4(e){return!!(e&&typeof e=="object"&&"message"in e&&"messages"in e)}function K4(e){return typeof e=="string"||Pv(e)}const X4={};function Z4(e,t){const n=t||X4,r=typeof n.includeImageAlt=="boolean"?n.includeImageAlt:!0,o=typeof n.includeHtml=="boolean"?n.includeHtml:!0;return _v(e,r,o)}function _v(e,t,n){if(J4(e)){if("value"in e)return e.type==="html"&&!n?"":e.value;if(t&&"alt"in e&&e.alt)return e.alt;if("children"in e)return Fm(e.children,t,n)}return Array.isArray(e)?Fm(e,t,n):""}function Fm(e,t,n){const r=[];let o=-1;for(;++oo?0:o+t:t=t>o?o:t,n=n>0?n:0,r.length<1e4)l=Array.from(r),l.unshift(t,n),e.splice(...l);else for(n&&e.splice(t,n);i0?(Ct(e,e.length,0,t),e):t}const jm={}.hasOwnProperty;function Rv(e){const t={};let n=-1;for(;++nl))return;const O=t.events.length;let T=O,N,P;for(;T--;)if(t.events[T][0]==="exit"&&t.events[T][1].type==="chunkFlow"){if(N){P=t.events[T][1].end;break}N=!0}for(g(r),k=O;kv;){const E=n[C];t.containerState=E[1],E[0].exit.call(t,e)}n.length=v}function y(){o.write([null]),i=void 0,o=void 0,t.containerState._closeFlow=void 0}}function cP(e,t,n){return de(e,e.attempt(this.parser.constructs.document,t,n),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}function Sa(e){if(e===null||Se(e)||$r(e))return 1;if(ks(e))return 2}function Ss(e,t,n){const r=[];let o=-1;for(;++o1&&e[n][1].end.offset-e[n][1].start.offset>1?2:1;const c=Object.assign({},e[r][1].end),d=Object.assign({},e[n][1].start);Bm(c,-s),Bm(d,s),l={type:s>1?"strongSequence":"emphasisSequence",start:c,end:Object.assign({},e[r][1].end)},a={type:s>1?"strongSequence":"emphasisSequence",start:Object.assign({},e[n][1].start),end:d},i={type:s>1?"strongText":"emphasisText",start:Object.assign({},e[r][1].end),end:Object.assign({},e[n][1].start)},o={type:s>1?"strong":"emphasis",start:Object.assign({},l.start),end:Object.assign({},a.end)},e[r][1].end=Object.assign({},l.start),e[n][1].start=Object.assign({},a.end),u=[],e[r][1].end.offset-e[r][1].start.offset&&(u=Rt(u,[["enter",e[r][1],t],["exit",e[r][1],t]])),u=Rt(u,[["enter",o,t],["enter",l,t],["exit",l,t],["enter",i,t]]),u=Rt(u,Ss(t.parser.constructs.insideSpan.null,e.slice(r+1,n),t)),u=Rt(u,[["exit",i,t],["enter",a,t],["exit",a,t],["exit",o,t]]),e[n][1].end.offset-e[n][1].start.offset?(p=2,u=Rt(u,[["enter",e[n][1],t],["exit",e[n][1],t]])):p=0,Ct(e,r-1,n-r+3,u),n=r+u.length-p-2;break}}for(n=-1;++n0&&ae(k)?de(e,y,"linePrefix",i+1)(k):y(k)}function y(k){return k===null||K(k)?e.check(Hm,m,C)(k):(e.enter("codeFlowValue"),v(k))}function v(k){return k===null||K(k)?(e.exit("codeFlowValue"),y(k)):(e.consume(k),v)}function C(k){return e.exit("codeFenced"),t(k)}function E(k,O,T){let N=0;return P;function P(W){return k.enter("lineEnding"),k.consume(W),k.exit("lineEnding"),_}function _(W){return k.enter("codeFencedFence"),ae(W)?de(k,R,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(W):R(W)}function R(W){return W===a?(k.enter("codeFencedFenceSequence"),H(W)):T(W)}function H(W){return W===a?(N++,k.consume(W),H):N>=l?(k.exit("codeFencedFenceSequence"),ae(W)?de(k,q,"whitespace")(W):q(W)):T(W)}function q(W){return W===null||K(W)?(k.exit("codeFencedFence"),O(W)):T(W)}}}function kP(e,t,n){const r=this;return o;function o(l){return l===null?n(l):(e.enter("lineEnding"),e.consume(l),e.exit("lineEnding"),i)}function i(l){return r.parser.lazy[r.now().line]?n(l):t(l)}}const yu={name:"codeIndented",tokenize:CP},SP={tokenize:EP,partial:!0};function CP(e,t,n){const r=this;return o;function o(u){return e.enter("codeIndented"),de(e,i,"linePrefix",4+1)(u)}function i(u){const p=r.events[r.events.length-1];return p&&p[1].type==="linePrefix"&&p[2].sliceSerialize(p[1],!0).length>=4?l(u):n(u)}function l(u){return u===null?s(u):K(u)?e.attempt(SP,l,s)(u):(e.enter("codeFlowValue"),a(u))}function a(u){return u===null||K(u)?(e.exit("codeFlowValue"),l(u)):(e.consume(u),a)}function s(u){return e.exit("codeIndented"),t(u)}}function EP(e,t,n){const r=this;return o;function o(l){return r.parser.lazy[r.now().line]?n(l):K(l)?(e.enter("lineEnding"),e.consume(l),e.exit("lineEnding"),o):de(e,i,"linePrefix",4+1)(l)}function i(l){const a=r.events[r.events.length-1];return a&&a[1].type==="linePrefix"&&a[2].sliceSerialize(a[1],!0).length>=4?t(l):K(l)?o(l):n(l)}}const PP={name:"codeText",tokenize:AP,resolve:OP,previous:TP};function OP(e){let t=e.length-4,n=3,r,o;if((e[n][1].type==="lineEnding"||e[n][1].type==="space")&&(e[t][1].type==="lineEnding"||e[t][1].type==="space")){for(r=n;++r=4?t(l):e.interrupt(r.parser.constructs.flow,n,t)(l)}}function Iv(e,t,n,r,o,i,l,a,s){const u=s||Number.POSITIVE_INFINITY;let p=0;return c;function c(g){return g===60?(e.enter(r),e.enter(o),e.enter(i),e.consume(g),e.exit(i),d):g===null||g===32||g===41||ka(g)?n(g):(e.enter(r),e.enter(l),e.enter(a),e.enter("chunkString",{contentType:"string"}),m(g))}function d(g){return g===62?(e.enter(i),e.consume(g),e.exit(i),e.exit(o),e.exit(r),t):(e.enter(a),e.enter("chunkString",{contentType:"string"}),f(g))}function f(g){return g===62?(e.exit("chunkString"),e.exit(a),d(g)):g===null||g===60||K(g)?n(g):(e.consume(g),g===92?h:f)}function h(g){return g===60||g===62||g===92?(e.consume(g),f):f(g)}function m(g){return!p&&(g===null||g===41||Se(g))?(e.exit("chunkString"),e.exit(a),e.exit(l),e.exit(r),t(g)):p999||f===null||f===91||f===93&&!s||f===94&&!a&&"_hiddenFootnoteSupport"in l.parser.constructs?n(f):f===93?(e.exit(i),e.enter(o),e.consume(f),e.exit(o),e.exit(r),t):K(f)?(e.enter("lineEnding"),e.consume(f),e.exit("lineEnding"),p):(e.enter("chunkString",{contentType:"string"}),c(f))}function c(f){return f===null||f===91||f===93||K(f)||a++>999?(e.exit("chunkString"),p(f)):(e.consume(f),s||(s=!ae(f)),f===92?d:c)}function d(f){return f===91||f===92||f===93?(e.consume(f),a++,c):c(f)}}function jv(e,t,n,r,o,i){let l;return a;function a(d){return d===34||d===39||d===40?(e.enter(r),e.enter(o),e.consume(d),e.exit(o),l=d===40?41:d,s):n(d)}function s(d){return d===l?(e.enter(o),e.consume(d),e.exit(o),e.exit(r),t):(e.enter(i),u(d))}function u(d){return d===l?(e.exit(i),s(l)):d===null?n(d):K(d)?(e.enter("lineEnding"),e.consume(d),e.exit("lineEnding"),de(e,u,"linePrefix")):(e.enter("chunkString",{contentType:"string"}),p(d))}function p(d){return d===l||d===null||K(d)?(e.exit("chunkString"),u(d)):(e.consume(d),d===92?c:p)}function c(d){return d===l||d===92?(e.consume(d),p):p(d)}}function ai(e,t){let n;return r;function r(o){return K(o)?(e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),n=!0,r):ae(o)?de(e,r,n?"linePrefix":"lineSuffix")(o):t(o)}}function Zt(e){return e.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}const NP={name:"definition",tokenize:FP},IP={tokenize:jP,partial:!0};function FP(e,t,n){const r=this;let o;return i;function i(f){return e.enter("definition"),l(f)}function l(f){return Fv.call(r,e,a,n,"definitionLabel","definitionLabelMarker","definitionLabelString")(f)}function a(f){return o=Zt(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)),f===58?(e.enter("definitionMarker"),e.consume(f),e.exit("definitionMarker"),s):n(f)}function s(f){return Se(f)?ai(e,u)(f):u(f)}function u(f){return Iv(e,p,n,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(f)}function p(f){return e.attempt(IP,c,c)(f)}function c(f){return ae(f)?de(e,d,"whitespace")(f):d(f)}function d(f){return f===null||K(f)?(e.exit("definition"),r.parser.defined.push(o),t(f)):n(f)}}function jP(e,t,n){return r;function r(a){return Se(a)?ai(e,o)(a):n(a)}function o(a){return jv(e,i,n,"definitionTitle","definitionTitleMarker","definitionTitleString")(a)}function i(a){return ae(a)?de(e,l,"whitespace")(a):l(a)}function l(a){return a===null||K(a)?t(a):n(a)}}const MP={name:"hardBreakEscape",tokenize:BP};function BP(e,t,n){return r;function r(i){return e.enter("hardBreakEscape"),e.consume(i),o}function o(i){return K(i)?(e.exit("hardBreakEscape"),t(i)):n(i)}}const UP={name:"headingAtx",tokenize:WP,resolve:HP};function HP(e,t){let n=e.length-2,r=3,o,i;return e[r][1].type==="whitespace"&&(r+=2),n-2>r&&e[n][1].type==="whitespace"&&(n-=2),e[n][1].type==="atxHeadingSequence"&&(r===n-1||n-4>r&&e[n-2][1].type==="whitespace")&&(n-=r+1===n?2:4),n>r&&(o={type:"atxHeadingText",start:e[r][1].start,end:e[n][1].end},i={type:"chunkText",start:e[r][1].start,end:e[n][1].end,contentType:"text"},Ct(e,r,n-r+1,[["enter",o,t],["enter",i,t],["exit",i,t],["exit",o,t]])),e}function WP(e,t,n){let r=0;return o;function o(p){return e.enter("atxHeading"),i(p)}function i(p){return e.enter("atxHeadingSequence"),l(p)}function l(p){return p===35&&r++<6?(e.consume(p),l):p===null||Se(p)?(e.exit("atxHeadingSequence"),a(p)):n(p)}function a(p){return p===35?(e.enter("atxHeadingSequence"),s(p)):p===null||K(p)?(e.exit("atxHeading"),t(p)):ae(p)?de(e,a,"whitespace")(p):(e.enter("atxHeadingText"),u(p))}function s(p){return p===35?(e.consume(p),s):(e.exit("atxHeadingSequence"),a(p))}function u(p){return p===null||p===35||Se(p)?(e.exit("atxHeadingText"),a(p)):(e.consume(p),u)}}const VP=["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"],Vm=["pre","script","style","textarea"],GP={name:"htmlFlow",tokenize:KP,resolveTo:QP,concrete:!0},qP={tokenize:ZP,partial:!0},YP={tokenize:XP,partial:!0};function QP(e){let t=e.length;for(;t--&&!(e[t][0]==="enter"&&e[t][1].type==="htmlFlow"););return t>1&&e[t-2][1].type==="linePrefix"&&(e[t][1].start=e[t-2][1].start,e[t+1][1].start=e[t-2][1].start,e.splice(t-2,2)),e}function KP(e,t,n){const r=this;let o,i,l,a,s;return u;function u(b){return p(b)}function p(b){return e.enter("htmlFlow"),e.enter("htmlFlowData"),e.consume(b),c}function c(b){return b===33?(e.consume(b),d):b===47?(e.consume(b),i=!0,m):b===63?(e.consume(b),o=3,r.interrupt?t:S):at(b)?(e.consume(b),l=String.fromCharCode(b),w):n(b)}function d(b){return b===45?(e.consume(b),o=2,f):b===91?(e.consume(b),o=5,a=0,h):at(b)?(e.consume(b),o=4,r.interrupt?t:S):n(b)}function f(b){return b===45?(e.consume(b),r.interrupt?t:S):n(b)}function h(b){const U="CDATA[";return b===U.charCodeAt(a++)?(e.consume(b),a===U.length?r.interrupt?t:R:h):n(b)}function m(b){return at(b)?(e.consume(b),l=String.fromCharCode(b),w):n(b)}function w(b){if(b===null||b===47||b===62||Se(b)){const U=b===47,Y=l.toLowerCase();return!U&&!i&&Vm.includes(Y)?(o=1,r.interrupt?t(b):R(b)):VP.includes(l.toLowerCase())?(o=6,U?(e.consume(b),g):r.interrupt?t(b):R(b)):(o=7,r.interrupt&&!r.parser.lazy[r.now().line]?n(b):i?y(b):v(b))}return b===45||rt(b)?(e.consume(b),l+=String.fromCharCode(b),w):n(b)}function g(b){return b===62?(e.consume(b),r.interrupt?t:R):n(b)}function y(b){return ae(b)?(e.consume(b),y):P(b)}function v(b){return b===47?(e.consume(b),P):b===58||b===95||at(b)?(e.consume(b),C):ae(b)?(e.consume(b),v):P(b)}function C(b){return b===45||b===46||b===58||b===95||rt(b)?(e.consume(b),C):E(b)}function E(b){return b===61?(e.consume(b),k):ae(b)?(e.consume(b),E):v(b)}function k(b){return b===null||b===60||b===61||b===62||b===96?n(b):b===34||b===39?(e.consume(b),s=b,O):ae(b)?(e.consume(b),k):T(b)}function O(b){return b===s?(e.consume(b),s=null,N):b===null||K(b)?n(b):(e.consume(b),O)}function T(b){return b===null||b===34||b===39||b===47||b===60||b===61||b===62||b===96||Se(b)?E(b):(e.consume(b),T)}function N(b){return b===47||b===62||ae(b)?v(b):n(b)}function P(b){return b===62?(e.consume(b),_):n(b)}function _(b){return b===null||K(b)?R(b):ae(b)?(e.consume(b),_):n(b)}function R(b){return b===45&&o===2?(e.consume(b),Q):b===60&&o===1?(e.consume(b),te):b===62&&o===4?(e.consume(b),X):b===63&&o===3?(e.consume(b),S):b===93&&o===5?(e.consume(b),G):K(b)&&(o===6||o===7)?(e.exit("htmlFlowData"),e.check(qP,I,H)(b)):b===null||K(b)?(e.exit("htmlFlowData"),H(b)):(e.consume(b),R)}function H(b){return e.check(YP,q,I)(b)}function q(b){return e.enter("lineEnding"),e.consume(b),e.exit("lineEnding"),W}function W(b){return b===null||K(b)?H(b):(e.enter("htmlFlowData"),R(b))}function Q(b){return b===45?(e.consume(b),S):R(b)}function te(b){return b===47?(e.consume(b),l="",z):R(b)}function z(b){if(b===62){const U=l.toLowerCase();return Vm.includes(U)?(e.consume(b),X):R(b)}return at(b)&&l.length<8?(e.consume(b),l+=String.fromCharCode(b),z):R(b)}function G(b){return b===93?(e.consume(b),S):R(b)}function S(b){return b===62?(e.consume(b),X):b===45&&o===2?(e.consume(b),S):R(b)}function X(b){return b===null||K(b)?(e.exit("htmlFlowData"),I(b)):(e.consume(b),X)}function I(b){return e.exit("htmlFlow"),t(b)}}function XP(e,t,n){const r=this;return o;function o(l){return K(l)?(e.enter("lineEnding"),e.consume(l),e.exit("lineEnding"),i):n(l)}function i(l){return r.parser.lazy[r.now().line]?n(l):t(l)}}function ZP(e,t,n){return r;function r(o){return e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),e.attempt(Wi,t,n)}}const JP={name:"htmlText",tokenize:eO};function eO(e,t,n){const r=this;let o,i,l;return a;function a(S){return e.enter("htmlText"),e.enter("htmlTextData"),e.consume(S),s}function s(S){return S===33?(e.consume(S),u):S===47?(e.consume(S),E):S===63?(e.consume(S),v):at(S)?(e.consume(S),T):n(S)}function u(S){return S===45?(e.consume(S),p):S===91?(e.consume(S),i=0,h):at(S)?(e.consume(S),y):n(S)}function p(S){return S===45?(e.consume(S),f):n(S)}function c(S){return S===null?n(S):S===45?(e.consume(S),d):K(S)?(l=c,te(S)):(e.consume(S),c)}function d(S){return S===45?(e.consume(S),f):c(S)}function f(S){return S===62?Q(S):S===45?d(S):c(S)}function h(S){const X="CDATA[";return S===X.charCodeAt(i++)?(e.consume(S),i===X.length?m:h):n(S)}function m(S){return S===null?n(S):S===93?(e.consume(S),w):K(S)?(l=m,te(S)):(e.consume(S),m)}function w(S){return S===93?(e.consume(S),g):m(S)}function g(S){return S===62?Q(S):S===93?(e.consume(S),g):m(S)}function y(S){return S===null||S===62?Q(S):K(S)?(l=y,te(S)):(e.consume(S),y)}function v(S){return S===null?n(S):S===63?(e.consume(S),C):K(S)?(l=v,te(S)):(e.consume(S),v)}function C(S){return S===62?Q(S):v(S)}function E(S){return at(S)?(e.consume(S),k):n(S)}function k(S){return S===45||rt(S)?(e.consume(S),k):O(S)}function O(S){return K(S)?(l=O,te(S)):ae(S)?(e.consume(S),O):Q(S)}function T(S){return S===45||rt(S)?(e.consume(S),T):S===47||S===62||Se(S)?N(S):n(S)}function N(S){return S===47?(e.consume(S),Q):S===58||S===95||at(S)?(e.consume(S),P):K(S)?(l=N,te(S)):ae(S)?(e.consume(S),N):Q(S)}function P(S){return S===45||S===46||S===58||S===95||rt(S)?(e.consume(S),P):_(S)}function _(S){return S===61?(e.consume(S),R):K(S)?(l=_,te(S)):ae(S)?(e.consume(S),_):N(S)}function R(S){return S===null||S===60||S===61||S===62||S===96?n(S):S===34||S===39?(e.consume(S),o=S,H):K(S)?(l=R,te(S)):ae(S)?(e.consume(S),R):(e.consume(S),q)}function H(S){return S===o?(e.consume(S),o=void 0,W):S===null?n(S):K(S)?(l=H,te(S)):(e.consume(S),H)}function q(S){return S===null||S===34||S===39||S===60||S===61||S===96?n(S):S===47||S===62||Se(S)?N(S):(e.consume(S),q)}function W(S){return S===47||S===62||Se(S)?N(S):n(S)}function Q(S){return S===62?(e.consume(S),e.exit("htmlTextData"),e.exit("htmlText"),t):n(S)}function te(S){return e.exit("htmlTextData"),e.enter("lineEnding"),e.consume(S),e.exit("lineEnding"),z}function z(S){return ae(S)?de(e,G,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(S):G(S)}function G(S){return e.enter("htmlTextData"),l(S)}}const kf={name:"labelEnd",tokenize:lO,resolveTo:iO,resolveAll:oO},tO={tokenize:aO},nO={tokenize:sO},rO={tokenize:uO};function oO(e){let t=-1;for(;++t=3&&(u===null||K(u))?(e.exit("thematicBreak"),t(u)):n(u)}function s(u){return u===o?(e.consume(u),r++,s):(e.exit("thematicBreakSequence"),ae(u)?de(e,a,"whitespace")(u):a(u))}}const pt={name:"list",tokenize:vO,continuation:{tokenize:wO},exit:bO},gO={tokenize:kO,partial:!0},yO={tokenize:xO,partial:!0};function vO(e,t,n){const r=this,o=r.events[r.events.length-1];let i=o&&o[1].type==="linePrefix"?o[2].sliceSerialize(o[1],!0).length:0,l=0;return a;function a(f){const h=r.containerState.type||(f===42||f===43||f===45?"listUnordered":"listOrdered");if(h==="listUnordered"?!r.containerState.marker||f===r.containerState.marker:Bc(f)){if(r.containerState.type||(r.containerState.type=h,e.enter(h,{_container:!0})),h==="listUnordered")return e.enter("listItemPrefix"),f===42||f===45?e.check(Hl,n,u)(f):u(f);if(!r.interrupt||f===49)return e.enter("listItemPrefix"),e.enter("listItemValue"),s(f)}return n(f)}function s(f){return Bc(f)&&++l<10?(e.consume(f),s):(!r.interrupt||l<2)&&(r.containerState.marker?f===r.containerState.marker:f===41||f===46)?(e.exit("listItemValue"),u(f)):n(f)}function u(f){return e.enter("listItemMarker"),e.consume(f),e.exit("listItemMarker"),r.containerState.marker=r.containerState.marker||f,e.check(Wi,r.interrupt?n:p,e.attempt(gO,d,c))}function p(f){return r.containerState.initialBlankLine=!0,i++,d(f)}function c(f){return ae(f)?(e.enter("listItemPrefixWhitespace"),e.consume(f),e.exit("listItemPrefixWhitespace"),d):n(f)}function d(f){return r.containerState.size=i+r.sliceSerialize(e.exit("listItemPrefix"),!0).length,t(f)}}function wO(e,t,n){const r=this;return r.containerState._closeFlow=void 0,e.check(Wi,o,i);function o(a){return r.containerState.furtherBlankLines=r.containerState.furtherBlankLines||r.containerState.initialBlankLine,de(e,t,"listItemIndent",r.containerState.size+1)(a)}function i(a){return r.containerState.furtherBlankLines||!ae(a)?(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,l(a)):(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,e.attempt(yO,t,l)(a))}function l(a){return r.containerState._closeFlow=!0,r.interrupt=void 0,de(e,e.attempt(pt,t,n),"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(a)}}function xO(e,t,n){const r=this;return de(e,o,"listItemIndent",r.containerState.size+1);function o(i){const l=r.events[r.events.length-1];return l&&l[1].type==="listItemIndent"&&l[2].sliceSerialize(l[1],!0).length===r.containerState.size?t(i):n(i)}}function bO(e){e.exit(this.containerState.type)}function kO(e,t,n){const r=this;return de(e,o,"listItemPrefixWhitespace",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4+1);function o(i){const l=r.events[r.events.length-1];return!ae(i)&&l&&l[1].type==="listItemPrefixWhitespace"?t(i):n(i)}}const Gm={name:"setextUnderline",tokenize:CO,resolveTo:SO};function SO(e,t){let n=e.length,r,o,i;for(;n--;)if(e[n][0]==="enter"){if(e[n][1].type==="content"){r=n;break}e[n][1].type==="paragraph"&&(o=n)}else e[n][1].type==="content"&&e.splice(n,1),!i&&e[n][1].type==="definition"&&(i=n);const l={type:"setextHeading",start:Object.assign({},e[o][1].start),end:Object.assign({},e[e.length-1][1].end)};return e[o][1].type="setextHeadingText",i?(e.splice(o,0,["enter",l,t]),e.splice(i+1,0,["exit",e[r][1],t]),e[r][1].end=Object.assign({},e[i][1].end)):e[r][1]=l,e.push(["exit",l,t]),e}function CO(e,t,n){const r=this;let o;return i;function i(u){let p=r.events.length,c;for(;p--;)if(r.events[p][1].type!=="lineEnding"&&r.events[p][1].type!=="linePrefix"&&r.events[p][1].type!=="content"){c=r.events[p][1].type==="paragraph";break}return!r.parser.lazy[r.now().line]&&(r.interrupt||c)?(e.enter("setextHeadingLine"),o=u,l(u)):n(u)}function l(u){return e.enter("setextHeadingLineSequence"),a(u)}function a(u){return u===o?(e.consume(u),a):(e.exit("setextHeadingLineSequence"),ae(u)?de(e,s,"lineSuffix")(u):s(u))}function s(u){return u===null||K(u)?(e.exit("setextHeadingLine"),t(u)):n(u)}}const EO={tokenize:PO};function PO(e){const t=this,n=e.attempt(Wi,r,e.attempt(this.parser.constructs.flowInitial,o,de(e,e.attempt(this.parser.constructs.flow,o,e.attempt(_P,o)),"linePrefix")));return n;function r(i){if(i===null){e.consume(i);return}return e.enter("lineEndingBlank"),e.consume(i),e.exit("lineEndingBlank"),t.currentConstruct=void 0,n}function o(i){if(i===null){e.consume(i);return}return e.enter("lineEnding"),e.consume(i),e.exit("lineEnding"),t.currentConstruct=void 0,n}}const OO={resolveAll:Bv()},TO=Mv("string"),AO=Mv("text");function Mv(e){return{tokenize:t,resolveAll:Bv(e==="text"?$O:void 0)};function t(n){const r=this,o=this.parser.constructs[e],i=n.attempt(o,l,a);return l;function l(p){return u(p)?i(p):a(p)}function a(p){if(p===null){n.consume(p);return}return n.enter("data"),n.consume(p),s}function s(p){return u(p)?(n.exit("data"),i(p)):(n.consume(p),s)}function u(p){if(p===null)return!0;const c=o[p];let d=-1;if(c)for(;++d-1){const a=l[0];typeof a=="string"?l[0]=a.slice(r):l.shift()}i>0&&l.push(e[o].slice(0,i))}return l}function LO(e,t){let n=-1;const r=[];let o;for(;++n13&&n<32||n>126&&n<160||n>55295&&n<57344||n>64975&&n<65008||(n&65535)===65535||(n&65535)===65534||n>1114111?"�":String.fromCharCode(n)}const I3=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function Iv(e){return e.replace(I3,F3)}function F3(e,t,n){if(t)return t;if(n.charCodeAt(0)===35){const o=n.charCodeAt(1),i=o===120||o===88;return Nv(n.slice(i?2:1),i?16:10)}return xf(n)||e}const Fv={}.hasOwnProperty,j3=function(e,t,n){return typeof t!="string"&&(n=t,t=void 0),M3(n)(N3(z3(n).document().write(D3()(e,t,!0))))};function M3(e){const t={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:a(Ne),autolinkProtocol:z,autolinkEmail:z,atxHeading:a(ze),blockQuote:a(pe),characterEscape:z,characterReference:z,codeFenced:a(ee),codeFencedFenceInfo:s,codeFencedFenceMeta:s,codeIndented:a(ee,s),codeText:a(Fe,s),codeTextData:z,data:z,codeFlowValue:z,definition:a(Ge),definitionDestinationString:s,definitionLabelString:s,definitionTitleString:s,emphasis:a(ie),hardBreakEscape:a(fe),hardBreakTrailing:a(fe),htmlFlow:a(De,s),htmlFlowData:z,htmlText:a(De,s),htmlTextData:z,image:a(hn),label:s,link:a(Ne),listItem:a(dr),listItemValue:h,listOrdered:a(At,f),listUnordered:a(At),paragraph:a(yt),reference:Q,referenceString:s,resourceDestinationString:s,resourceTitleString:s,setextHeading:a(ze),strong:a(te),thematicBreak:a(Ao)},exit:{atxHeading:c(),atxHeadingSequence:T,autolink:c(),autolinkEmail:le,autolinkProtocol:de,blockQuote:c(),characterEscapeValue:_,characterReferenceMarkerHexadecimal:ne,characterReferenceMarkerNumeric:ne,characterReferenceValue:B,codeFenced:c(y),codeFencedFence:g,codeFencedFenceInfo:m,codeFencedFenceMeta:w,codeFlowValue:_,codeIndented:c(v),codeText:c(K),codeTextData:_,data:_,definition:c(),definitionDestinationString:k,definitionLabelString:C,definitionTitleString:E,emphasis:c(),hardBreakEscape:c(H),hardBreakTrailing:c(H),htmlFlow:c(W),htmlFlowData:_,htmlText:c(q),htmlTextData:_,image:c(V),label:Z,labelText:S,lineEnding:Y,link:c(D),listItem:c(),listOrdered:c(),listUnordered:c(),paragraph:c(),referenceString:O,resourceDestinationString:F,resourceTitleString:x,resource:U,setextHeading:c(P),setextHeadingLineSequence:N,setextHeadingText:A,strong:c(),thematicBreak:c()}};jv(t,(e||{}).mdastExtensions||[]);const n={};return r;function r($){let j={type:"root",children:[]};const J={stack:[j],tokenStack:[],config:t,enter:u,exit:p,buffer:s,resume:d,setData:i,getData:l},be=[];let ke=-1;for(;++ke<$.length;)if($[ke][1].type==="listOrdered"||$[ke][1].type==="listUnordered")if($[ke][0]==="enter")be.push(ke);else{const Ht=be.pop();ke=o($,Ht,ke)}for(ke=-1;++ke<$.length;){const Ht=t[$[ke][0]];Fv.call(Ht,$[ke][1].type)&&Ht[$[ke][1].type].call(Object.assign({sliceSerialize:$[ke][2].sliceSerialize},J),$[ke][1])}if(J.tokenStack.length>0){const Ht=J.tokenStack[J.tokenStack.length-1];(Ht[1]||Vm).call(J,void 0,Ht[0])}for(j.position={start:jn($.length>0?$[0][1].start:{line:1,column:1,offset:0}),end:jn($.length>0?$[$.length-2][1].end:{line:1,column:1,offset:0})},ke=-1;++ke{const r=this.data("settings");return j3(n,Object.assign({},r,e,{extensions:this.data("micromarkExtensions")||[],mdastExtensions:this.data("fromMarkdownExtensions")||[]}))}})}function H3(e,t){const n={type:"element",tagName:"blockquote",properties:{},children:e.wrap(e.all(t),!0)};return e.patch(t,n),e.applyData(t,n)}function W3(e,t){const n={type:"element",tagName:"br",properties:{},children:[]};return e.patch(t,n),[e.applyData(t,n),{type:"text",value:` -`}]}function V3(e,t){const n=t.value?t.value+` -`:"",r=t.lang?t.lang.match(/^[^ \t]+(?=[ \t]|$)/):null,o={};r&&(o.className=["language-"+r]);let i={type:"element",tagName:"code",properties:o,children:[{type:"text",value:n}]};return t.meta&&(i.data={meta:t.meta}),e.patch(t,i),i=e.applyData(t,i),i={type:"element",tagName:"pre",properties:{},children:[i]},e.patch(t,i),i}function G3(e,t){const n={type:"element",tagName:"del",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function q3(e,t){const n={type:"element",tagName:"em",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function To(e){const t=[];let n=-1,r=0,o=0;for(;++n55295&&i<57344){const a=e.charCodeAt(n+1);i<56320&&a>56319&&a<57344?(l=String.fromCharCode(i,a),o=1):l="�"}else l=String.fromCharCode(i);l&&(t.push(e.slice(r,n),encodeURIComponent(l)),r=n+o+1,l=""),o&&(n+=o,o=0)}return t.join("")+e.slice(r)}function Mv(e,t){const n=String(t.identifier).toUpperCase(),r=To(n.toLowerCase()),o=e.footnoteOrder.indexOf(n);let i;o===-1?(e.footnoteOrder.push(n),e.footnoteCounts[n]=1,i=e.footnoteOrder.length):(e.footnoteCounts[n]++,i=o+1);const l=e.footnoteCounts[n],a={type:"element",tagName:"a",properties:{href:"#"+e.clobberPrefix+"fn-"+r,id:e.clobberPrefix+"fnref-"+r+(l>1?"-"+l:""),dataFootnoteRef:!0,ariaDescribedBy:["footnote-label"]},children:[{type:"text",value:String(i)}]};e.patch(t,a);const s={type:"element",tagName:"sup",properties:{},children:[a]};return e.patch(t,s),e.applyData(t,s)}function Y3(e,t){const n=e.footnoteById;let r=1;for(;r in n;)r++;const o=String(r);return n[o]={type:"footnoteDefinition",identifier:o,children:[{type:"paragraph",children:t.children}],position:t.position},Mv(e,{type:"footnoteReference",identifier:o,position:t.position})}function Q3(e,t){const n={type:"element",tagName:"h"+t.depth,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function K3(e,t){if(e.dangerous){const n={type:"raw",value:t.value};return e.patch(t,n),e.applyData(t,n)}return null}function Bv(e,t){const n=t.referenceType;let r="]";if(n==="collapsed"?r+="[]":n==="full"&&(r+="["+(t.label||t.identifier)+"]"),t.type==="imageReference")return{type:"text",value:"!["+t.alt+r};const o=e.all(t),i=o[0];i&&i.type==="text"?i.value="["+i.value:o.unshift({type:"text",value:"["});const l=o[o.length-1];return l&&l.type==="text"?l.value+=r:o.push({type:"text",value:r}),o}function X3(e,t){const n=e.definition(t.identifier);if(!n)return Bv(e,t);const r={src:To(n.url||""),alt:t.alt};n.title!==null&&n.title!==void 0&&(r.title=n.title);const o={type:"element",tagName:"img",properties:r,children:[]};return e.patch(t,o),e.applyData(t,o)}function Z3(e,t){const n={src:To(t.url)};t.alt!==null&&t.alt!==void 0&&(n.alt=t.alt),t.title!==null&&t.title!==void 0&&(n.title=t.title);const r={type:"element",tagName:"img",properties:n,children:[]};return e.patch(t,r),e.applyData(t,r)}function J3(e,t){const n={type:"text",value:t.value.replace(/\r?\n|\r/g," ")};e.patch(t,n);const r={type:"element",tagName:"code",properties:{},children:[n]};return e.patch(t,r),e.applyData(t,r)}function eT(e,t){const n=e.definition(t.identifier);if(!n)return Bv(e,t);const r={href:To(n.url||"")};n.title!==null&&n.title!==void 0&&(r.title=n.title);const o={type:"element",tagName:"a",properties:r,children:e.all(t)};return e.patch(t,o),e.applyData(t,o)}function tT(e,t){const n={href:To(t.url)};t.title!==null&&t.title!==void 0&&(n.title=t.title);const r={type:"element",tagName:"a",properties:n,children:e.all(t)};return e.patch(t,r),e.applyData(t,r)}function nT(e,t,n){const r=e.all(t),o=n?rT(n):Uv(t),i={},l=[];if(typeof t.checked=="boolean"){const c=r[0];let p;c&&c.type==="element"&&c.tagName==="p"?p=c:(p={type:"element",tagName:"p",properties:{},children:[]},r.unshift(p)),p.children.length>0&&p.children.unshift({type:"text",value:" "}),p.children.unshift({type:"element",tagName:"input",properties:{type:"checkbox",checked:t.checked,disabled:!0},children:[]}),i.className=["task-list-item"]}let a=-1;for(;++a1}function oT(e,t){const n={},r=e.all(t);let o=-1;for(typeof t.start=="number"&&t.start!==1&&(n.start=t.start);++o-1?r.offset:null}}}function uT(e,t){const n=e.all(t),r=n.shift(),o=[];if(r){const l={type:"element",tagName:"thead",properties:{},children:e.wrap([r],!0)};e.patch(t.children[0],l),o.push(l)}if(n.length>0){const l={type:"element",tagName:"tbody",properties:{},children:e.wrap(n,!0)},a=kf(t.children[1]),s=Sf(t.children[t.children.length-1]);a.line&&s.line&&(l.position={start:a,end:s}),o.push(l)}const i={type:"element",tagName:"table",properties:{},children:e.wrap(o,!0)};return e.patch(t,i),e.applyData(t,i)}function cT(e,t,n){const r=n?n.children:void 0,i=(r?r.indexOf(t):1)===0?"th":"td",l=n&&n.type==="table"?n.align:void 0,a=l?l.length:t.children.length;let s=-1;const u=[];for(;++s0,!0),r[0]),o=r.index+r[0].length,r=n.exec(t);return i.push(Ym(t.slice(o),o>0,!1)),i.join("")}function Ym(e,t,n){let r=0,o=e.length;if(t){let i=e.codePointAt(r);for(;i===Gm||i===qm;)r++,i=e.codePointAt(r)}if(n){let i=e.codePointAt(o-1);for(;i===Gm||i===qm;)o--,i=e.codePointAt(o-1)}return o>r?e.slice(r,o):""}function dT(e,t){const n={type:"text",value:fT(String(t.value))};return e.patch(t,n),e.applyData(t,n)}function hT(e,t){const n={type:"element",tagName:"hr",properties:{},children:[]};return e.patch(t,n),e.applyData(t,n)}const mT={blockquote:H3,break:W3,code:V3,delete:G3,emphasis:q3,footnoteReference:Mv,footnote:Y3,heading:Q3,html:K3,imageReference:X3,image:Z3,inlineCode:J3,linkReference:eT,link:tT,listItem:nT,list:oT,paragraph:iT,root:lT,strong:aT,table:uT,tableCell:pT,tableRow:cT,text:dT,thematicBreak:hT,toml:gl,yaml:gl,definition:gl,footnoteDefinition:gl};function gl(){return null}const Cf=function(e){if(e==null)return wT;if(typeof e=="string")return vT(e);if(typeof e=="object")return Array.isArray(e)?gT(e):yT(e);if(typeof e=="function")return bs(e);throw new Error("Expected function, string, or object as test")};function gT(e){const t=[];let n=-1;for(;++n":""))+")"})}return p;function p(){let d=[],f,h,m;if((!t||o(a,s,u[u.length-1]||null))&&(d=kT(n(a,u)),d[0]===Qm))return d;if(a.children&&d[0]!==bT)for(h=(r?a.children.length:-1)+i,m=u.concat(a);h>-1&&h{const o=Xm(r.identifier);o&&!Km.call(t,o)&&(t[o]=r)}),n;function n(r){const o=Xm(r);return o&&Km.call(t,o)?t[o]:null}}function Xm(e){return String(e||"").toUpperCase()}const xa={}.hasOwnProperty;function ET(e,t){const n=t||{},r=n.allowDangerousHtml||!1,o={};return l.dangerous=r,l.clobberPrefix=n.clobberPrefix===void 0||n.clobberPrefix===null?"user-content-":n.clobberPrefix,l.footnoteLabel=n.footnoteLabel||"Footnotes",l.footnoteLabelTagName=n.footnoteLabelTagName||"h2",l.footnoteLabelProperties=n.footnoteLabelProperties||{className:["sr-only"]},l.footnoteBackLabel=n.footnoteBackLabel||"Back to content",l.unknownHandler=n.unknownHandler,l.passThrough=n.passThrough,l.handlers={...mT,...n.handlers},l.definition=CT(e),l.footnoteById=o,l.footnoteOrder=[],l.footnoteCounts={},l.patch=PT,l.applyData=TT,l.one=a,l.all=s,l.wrap=AT,l.augment=i,Ef(e,"footnoteDefinition",u=>{const c=String(u.identifier).toUpperCase();xa.call(o,c)||(o[c]=u)}),l;function i(u,c){if(u&&"data"in u&&u.data){const p=u.data;p.hName&&(c.type!=="element"&&(c={type:"element",tagName:"",properties:{},children:[]}),c.tagName=p.hName),c.type==="element"&&p.hProperties&&(c.properties={...c.properties,...p.hProperties}),"children"in c&&c.children&&p.hChildren&&(c.children=p.hChildren)}if(u){const p="type"in u?u:{position:u};ST(p)||(c.position={start:kf(p),end:Sf(p)})}return c}function l(u,c,p,d){return Array.isArray(p)&&(d=p,p={}),i(u,{type:"element",tagName:c,properties:p||{},children:d||[]})}function a(u,c){return Vv(l,u,c)}function s(u){return Pf(l,u)}}function PT(e,t){e.position&&(t.position=sT(e))}function TT(e,t){let n=t;if(e&&e.data){const r=e.data.hName,o=e.data.hChildren,i=e.data.hProperties;typeof r=="string"&&(n.type==="element"?n.tagName=r:n={type:"element",tagName:r,properties:{},children:[]}),n.type==="element"&&i&&(n.properties={...n.properties,...i}),"children"in n&&n.children&&o!==null&&o!==void 0&&(n.children=o)}return n}function Vv(e,t,n){const r=t&&t.type;if(!r)throw new Error("Expected node, got `"+t+"`");return xa.call(e.handlers,r)?e.handlers[r](e,t,n):e.passThrough&&e.passThrough.includes(r)?"children"in t?{...t,children:Pf(e,t)}:t:e.unknownHandler?e.unknownHandler(e,t,n):OT(e,t)}function Pf(e,t){const n=[];if("children"in t){const r=t.children;let o=-1;for(;++o13&&n<32||n>126&&n<160||n>55295&&n<57344||n>64975&&n<65008||(n&65535)===65535||(n&65535)===65534||n>1114111?"�":String.fromCharCode(n)}const qO=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function Hv(e){return e.replace(qO,YO)}function YO(e,t,n){if(t)return t;if(n.charCodeAt(0)===35){const o=n.charCodeAt(1),i=o===120||o===88;return Uv(n.slice(i?2:1),i?16:10)}return bf(n)||e}const Wv={}.hasOwnProperty,QO=function(e,t,n){return typeof t!="string"&&(n=t,t=void 0),KO(n)(GO(WO(n).document().write(VO()(e,t,!0))))};function KO(e){const t={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:a(Ee),autolinkProtocol:_,autolinkEmail:_,atxHeading:a(Fe),blockQuote:a(pe),characterEscape:_,characterReference:_,codeFenced:a(J),codeFencedFenceInfo:s,codeFencedFenceMeta:s,codeIndented:a(J,s),codeText:a(Ie,s),codeTextData:_,data:_,codeFlowValue:_,definition:a(Be),definitionDestinationString:s,definitionLabelString:s,definitionTitleString:s,emphasis:a(se),hardBreakEscape:a(fe),hardBreakTrailing:a(fe),htmlFlow:a(ze,s),htmlFlowData:_,htmlText:a(ze,s),htmlTextData:_,image:a(hn),label:s,link:a(Ee),listItem:a(dr),listItemValue:h,listOrdered:a(fr,f),listUnordered:a(fr),paragraph:a(yt),reference:Y,referenceString:s,resourceDestinationString:s,resourceTitleString:s,setextHeading:a(Fe),strong:a(ee),thematicBreak:a($o)},exit:{atxHeading:p(),atxHeadingSequence:O,autolink:p(),autolinkEmail:ie,autolinkProtocol:ye,blockQuote:p(),characterEscapeValue:R,characterReferenceMarkerHexadecimal:ne,characterReferenceMarkerNumeric:ne,characterReferenceValue:B,codeFenced:p(y),codeFencedFence:g,codeFencedFenceInfo:m,codeFencedFenceMeta:w,codeFlowValue:R,codeIndented:p(v),codeText:p(te),codeTextData:R,data:R,definition:p(),definitionDestinationString:k,definitionLabelString:C,definitionTitleString:E,emphasis:p(),hardBreakEscape:p(q),hardBreakTrailing:p(q),htmlFlow:p(W),htmlFlowData:R,htmlText:p(Q),htmlTextData:R,image:p(G),label:X,labelText:S,lineEnding:H,link:p(z),listItem:p(),listOrdered:p(),listUnordered:p(),paragraph:p(),referenceString:A,resourceDestinationString:I,resourceTitleString:b,resource:U,setextHeading:p(P),setextHeadingLineSequence:N,setextHeadingText:T,strong:p(),thematicBreak:p()}};Vv(t,(e||{}).mdastExtensions||[]);const n={};return r;function r($){let j={type:"root",children:[]};const Z={stack:[j],tokenStack:[],config:t,enter:u,exit:c,buffer:s,resume:d,setData:i,getData:l},be=[];let ke=-1;for(;++ke<$.length;)if($[ke][1].type==="listOrdered"||$[ke][1].type==="listUnordered")if($[ke][0]==="enter")be.push(ke);else{const Ut=be.pop();ke=o($,Ut,ke)}for(ke=-1;++ke<$.length;){const Ut=t[$[ke][0]];Wv.call(Ut,$[ke][1].type)&&Ut[$[ke][1].type].call(Object.assign({sliceSerialize:$[ke][2].sliceSerialize},Z),$[ke][1])}if(Z.tokenStack.length>0){const Ut=Z.tokenStack[Z.tokenStack.length-1];(Ut[1]||Ym).call(Z,void 0,Ut[0])}for(j.position={start:jn($.length>0?$[0][1].start:{line:1,column:1,offset:0}),end:jn($.length>0?$[$.length-2][1].end:{line:1,column:1,offset:0})},ke=-1;++ke{const r=this.data("settings");return QO(n,Object.assign({},r,e,{extensions:this.data("micromarkExtensions")||[],mdastExtensions:this.data("fromMarkdownExtensions")||[]}))}})}function JO(e,t){const n={type:"element",tagName:"blockquote",properties:{},children:e.wrap(e.all(t),!0)};return e.patch(t,n),e.applyData(t,n)}function eT(e,t){const n={type:"element",tagName:"br",properties:{},children:[]};return e.patch(t,n),[e.applyData(t,n),{type:"text",value:` +`}]}function tT(e,t){const n=t.value?t.value+` +`:"",r=t.lang?t.lang.match(/^[^ \t]+(?=[ \t]|$)/):null,o={};r&&(o.className=["language-"+r]);let i={type:"element",tagName:"code",properties:o,children:[{type:"text",value:n}]};return t.meta&&(i.data={meta:t.meta}),e.patch(t,i),i=e.applyData(t,i),i={type:"element",tagName:"pre",properties:{},children:[i]},e.patch(t,i),i}function nT(e,t){const n={type:"element",tagName:"del",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function rT(e,t){const n={type:"element",tagName:"em",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function To(e){const t=[];let n=-1,r=0,o=0;for(;++n55295&&i<57344){const a=e.charCodeAt(n+1);i<56320&&a>56319&&a<57344?(l=String.fromCharCode(i,a),o=1):l="�"}else l=String.fromCharCode(i);l&&(t.push(e.slice(r,n),encodeURIComponent(l)),r=n+o+1,l=""),o&&(n+=o,o=0)}return t.join("")+e.slice(r)}function Gv(e,t){const n=String(t.identifier).toUpperCase(),r=To(n.toLowerCase()),o=e.footnoteOrder.indexOf(n);let i;o===-1?(e.footnoteOrder.push(n),e.footnoteCounts[n]=1,i=e.footnoteOrder.length):(e.footnoteCounts[n]++,i=o+1);const l=e.footnoteCounts[n],a={type:"element",tagName:"a",properties:{href:"#"+e.clobberPrefix+"fn-"+r,id:e.clobberPrefix+"fnref-"+r+(l>1?"-"+l:""),dataFootnoteRef:!0,ariaDescribedBy:["footnote-label"]},children:[{type:"text",value:String(i)}]};e.patch(t,a);const s={type:"element",tagName:"sup",properties:{},children:[a]};return e.patch(t,s),e.applyData(t,s)}function oT(e,t){const n=e.footnoteById;let r=1;for(;r in n;)r++;const o=String(r);return n[o]={type:"footnoteDefinition",identifier:o,children:[{type:"paragraph",children:t.children}],position:t.position},Gv(e,{type:"footnoteReference",identifier:o,position:t.position})}function iT(e,t){const n={type:"element",tagName:"h"+t.depth,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function lT(e,t){if(e.dangerous){const n={type:"raw",value:t.value};return e.patch(t,n),e.applyData(t,n)}return null}function qv(e,t){const n=t.referenceType;let r="]";if(n==="collapsed"?r+="[]":n==="full"&&(r+="["+(t.label||t.identifier)+"]"),t.type==="imageReference")return{type:"text",value:"!["+t.alt+r};const o=e.all(t),i=o[0];i&&i.type==="text"?i.value="["+i.value:o.unshift({type:"text",value:"["});const l=o[o.length-1];return l&&l.type==="text"?l.value+=r:o.push({type:"text",value:r}),o}function aT(e,t){const n=e.definition(t.identifier);if(!n)return qv(e,t);const r={src:To(n.url||""),alt:t.alt};n.title!==null&&n.title!==void 0&&(r.title=n.title);const o={type:"element",tagName:"img",properties:r,children:[]};return e.patch(t,o),e.applyData(t,o)}function sT(e,t){const n={src:To(t.url)};t.alt!==null&&t.alt!==void 0&&(n.alt=t.alt),t.title!==null&&t.title!==void 0&&(n.title=t.title);const r={type:"element",tagName:"img",properties:n,children:[]};return e.patch(t,r),e.applyData(t,r)}function uT(e,t){const n={type:"text",value:t.value.replace(/\r?\n|\r/g," ")};e.patch(t,n);const r={type:"element",tagName:"code",properties:{},children:[n]};return e.patch(t,r),e.applyData(t,r)}function cT(e,t){const n=e.definition(t.identifier);if(!n)return qv(e,t);const r={href:To(n.url||"")};n.title!==null&&n.title!==void 0&&(r.title=n.title);const o={type:"element",tagName:"a",properties:r,children:e.all(t)};return e.patch(t,o),e.applyData(t,o)}function pT(e,t){const n={href:To(t.url)};t.title!==null&&t.title!==void 0&&(n.title=t.title);const r={type:"element",tagName:"a",properties:n,children:e.all(t)};return e.patch(t,r),e.applyData(t,r)}function fT(e,t,n){const r=e.all(t),o=n?dT(n):Yv(t),i={},l=[];if(typeof t.checked=="boolean"){const p=r[0];let c;p&&p.type==="element"&&p.tagName==="p"?c=p:(c={type:"element",tagName:"p",properties:{},children:[]},r.unshift(c)),c.children.length>0&&c.children.unshift({type:"text",value:" "}),c.children.unshift({type:"element",tagName:"input",properties:{type:"checkbox",checked:t.checked,disabled:!0},children:[]}),i.className=["task-list-item"]}let a=-1;for(;++a1}function hT(e,t){const n={},r=e.all(t);let o=-1;for(typeof t.start=="number"&&t.start!==1&&(n.start=t.start);++o-1?r.offset:null}}}function wT(e,t){const n=e.all(t),r=n.shift(),o=[];if(r){const l={type:"element",tagName:"thead",properties:{},children:e.wrap([r],!0)};e.patch(t.children[0],l),o.push(l)}if(n.length>0){const l={type:"element",tagName:"tbody",properties:{},children:e.wrap(n,!0)},a=Sf(t.children[1]),s=Cf(t.children[t.children.length-1]);a.line&&s.line&&(l.position={start:a,end:s}),o.push(l)}const i={type:"element",tagName:"table",properties:{},children:e.wrap(o,!0)};return e.patch(t,i),e.applyData(t,i)}function xT(e,t,n){const r=n?n.children:void 0,i=(r?r.indexOf(t):1)===0?"th":"td",l=n&&n.type==="table"?n.align:void 0,a=l?l.length:t.children.length;let s=-1;const u=[];for(;++s0,!0),r[0]),o=r.index+r[0].length,r=n.exec(t);return i.push(Xm(t.slice(o),o>0,!1)),i.join("")}function Xm(e,t,n){let r=0,o=e.length;if(t){let i=e.codePointAt(r);for(;i===Qm||i===Km;)r++,i=e.codePointAt(r)}if(n){let i=e.codePointAt(o-1);for(;i===Qm||i===Km;)o--,i=e.codePointAt(o-1)}return o>r?e.slice(r,o):""}function ST(e,t){const n={type:"text",value:kT(String(t.value))};return e.patch(t,n),e.applyData(t,n)}function CT(e,t){const n={type:"element",tagName:"hr",properties:{},children:[]};return e.patch(t,n),e.applyData(t,n)}const ET={blockquote:JO,break:eT,code:tT,delete:nT,emphasis:rT,footnoteReference:Gv,footnote:oT,heading:iT,html:lT,imageReference:aT,image:sT,inlineCode:uT,linkReference:cT,link:pT,listItem:fT,list:hT,paragraph:mT,root:gT,strong:yT,table:wT,tableCell:bT,tableRow:xT,text:ST,thematicBreak:CT,toml:vl,yaml:vl,definition:vl,footnoteDefinition:vl};function vl(){return null}const Ef=function(e){if(e==null)return AT;if(typeof e=="string")return TT(e);if(typeof e=="object")return Array.isArray(e)?PT(e):OT(e);if(typeof e=="function")return Cs(e);throw new Error("Expected function, string, or object as test")};function PT(e){const t=[];let n=-1;for(;++n":""))+")"})}return c;function c(){let d=[],f,h,m;if((!t||o(a,s,u[u.length-1]||null))&&(d=RT(n(a,u)),d[0]===Zm))return d;if(a.children&&d[0]!==_T)for(h=(r?a.children.length:-1)+i,m=u.concat(a);h>-1&&h{const o=eg(r.identifier);o&&!Jm.call(t,o)&&(t[o]=r)}),n;function n(r){const o=eg(r);return o&&Jm.call(t,o)?t[o]:null}}function eg(e){return String(e||"").toUpperCase()}const Ca={}.hasOwnProperty;function zT(e,t){const n=t||{},r=n.allowDangerousHtml||!1,o={};return l.dangerous=r,l.clobberPrefix=n.clobberPrefix===void 0||n.clobberPrefix===null?"user-content-":n.clobberPrefix,l.footnoteLabel=n.footnoteLabel||"Footnotes",l.footnoteLabelTagName=n.footnoteLabelTagName||"h2",l.footnoteLabelProperties=n.footnoteLabelProperties||{className:["sr-only"]},l.footnoteBackLabel=n.footnoteBackLabel||"Back to content",l.unknownHandler=n.unknownHandler,l.passThrough=n.passThrough,l.handlers={...ET,...n.handlers},l.definition=DT(e),l.footnoteById=o,l.footnoteOrder=[],l.footnoteCounts={},l.patch=NT,l.applyData=IT,l.one=a,l.all=s,l.wrap=jT,l.augment=i,Pf(e,"footnoteDefinition",u=>{const p=String(u.identifier).toUpperCase();Ca.call(o,p)||(o[p]=u)}),l;function i(u,p){if(u&&"data"in u&&u.data){const c=u.data;c.hName&&(p.type!=="element"&&(p={type:"element",tagName:"",properties:{},children:[]}),p.tagName=c.hName),p.type==="element"&&c.hProperties&&(p.properties={...p.properties,...c.hProperties}),"children"in p&&p.children&&c.hChildren&&(p.children=c.hChildren)}if(u){const c="type"in u?u:{position:u};LT(c)||(p.position={start:Sf(c),end:Cf(c)})}return p}function l(u,p,c,d){return Array.isArray(c)&&(d=c,c={}),i(u,{type:"element",tagName:p,properties:c||{},children:d||[]})}function a(u,p){return Xv(l,u,p)}function s(u){return Of(l,u)}}function NT(e,t){e.position&&(t.position=vT(e))}function IT(e,t){let n=t;if(e&&e.data){const r=e.data.hName,o=e.data.hChildren,i=e.data.hProperties;typeof r=="string"&&(n.type==="element"?n.tagName=r:n={type:"element",tagName:r,properties:{},children:[]}),n.type==="element"&&i&&(n.properties={...n.properties,...i}),"children"in n&&n.children&&o!==null&&o!==void 0&&(n.children=o)}return n}function Xv(e,t,n){const r=t&&t.type;if(!r)throw new Error("Expected node, got `"+t+"`");return Ca.call(e.handlers,r)?e.handlers[r](e,t,n):e.passThrough&&e.passThrough.includes(r)?"children"in t?{...t,children:Of(e,t)}:t:e.unknownHandler?e.unknownHandler(e,t,n):FT(e,t)}function Of(e,t){const n=[];if("children"in t){const r=t.children;let o=-1;for(;++o0&&n.push({type:"text",value:` -`}),n}function _T(e){const t=[];let n=-1;for(;++n1?"-"+a:""),dataFootnoteBackref:!0,className:["data-footnote-backref"],ariaLabel:e.footnoteBackLabel},children:[{type:"text",value:"↩"}]};a>1&&p.children.push({type:"element",tagName:"sup",children:[{type:"text",value:String(a)}]}),s.length>0&&s.push({type:"text",value:" "}),s.push(p)}const u=o[o.length-1];if(u&&u.type==="element"&&u.tagName==="p"){const p=u.children[u.children.length-1];p&&p.type==="text"?p.value+=" ":u.children.push({type:"text",value:" "}),u.children.push(...s)}else o.push(...s);const c={type:"element",tagName:"li",properties:{id:e.clobberPrefix+"fn-"+l},children:e.wrap(o,!0)};e.patch(r,c),t.push(c)}if(t.length!==0)return{type:"element",tagName:"section",properties:{dataFootnotes:!0,className:["footnotes"]},children:[{type:"element",tagName:e.footnoteLabelTagName,properties:{...JSON.parse(JSON.stringify(e.footnoteLabelProperties)),id:"footnote-label"},children:[{type:"text",value:e.footnoteLabel}]},{type:"text",value:` +`}),n}function MT(e){const t=[];let n=-1;for(;++n1?"-"+a:""),dataFootnoteBackref:!0,className:["data-footnote-backref"],ariaLabel:e.footnoteBackLabel},children:[{type:"text",value:"↩"}]};a>1&&c.children.push({type:"element",tagName:"sup",children:[{type:"text",value:String(a)}]}),s.length>0&&s.push({type:"text",value:" "}),s.push(c)}const u=o[o.length-1];if(u&&u.type==="element"&&u.tagName==="p"){const c=u.children[u.children.length-1];c&&c.type==="text"?c.value+=" ":u.children.push({type:"text",value:" "}),u.children.push(...s)}else o.push(...s);const p={type:"element",tagName:"li",properties:{id:e.clobberPrefix+"fn-"+l},children:e.wrap(o,!0)};e.patch(r,p),t.push(p)}if(t.length!==0)return{type:"element",tagName:"section",properties:{dataFootnotes:!0,className:["footnotes"]},children:[{type:"element",tagName:e.footnoteLabelTagName,properties:{...JSON.parse(JSON.stringify(e.footnoteLabelProperties)),id:"footnote-label"},children:[{type:"text",value:e.footnoteLabel}]},{type:"text",value:` `},{type:"element",tagName:"ol",properties:{},children:e.wrap(t,!0)},{type:"text",value:` -`}]}}function Gv(e,t){const n=ET(e,t),r=n.one(e,null),o=_T(n);return o&&r.children.push({type:"text",value:` -`},o),Array.isArray(r)?{type:"root",children:r}:r}const $T=function(e,t){return e&&"run"in e?LT(e,t):zT(e||t)},RT=$T;function LT(e,t){return(n,r,o)=>{e.run(Gv(n,t),r,i=>{o(i)})}}function zT(e){return t=>Gv(t,e)}var qv={exports:{}},DT="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED",NT=DT,IT=NT;function Yv(){}function Qv(){}Qv.resetWarningCache=Yv;var FT=function(){function e(r,o,i,l,a,s){if(s!==IT){var u=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw u.name="Invariant Violation",u}}e.isRequired=e;function t(){return e}var n={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:Qv,resetWarningCache:Yv};return n.PropTypes=n,n};qv.exports=FT();var jT=qv.exports;const re=$r(jT);class Hi{constructor(t,n,r){this.property=t,this.normal=n,r&&(this.space=r)}}Hi.prototype.property={};Hi.prototype.normal={};Hi.prototype.space=null;function Kv(e,t){const n={},r={};let o=-1;for(;++o4&&n.slice(0,4)==="data"&&WT.test(t)){if(t.charAt(4)==="-"){const i=t.slice(5).replace(Jm,YT);r="data"+i.charAt(0).toUpperCase()+i.slice(1)}else{const i=t.slice(4);if(!Jm.test(i)){let l=i.replace(VT,qT);l.charAt(0)!=="-"&&(l="-"+l),t="data"+l}}o=Tf}return new o(r,t)}function qT(e){return"-"+e.toLowerCase()}function YT(e){return e.charAt(1).toUpperCase()}const eg={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"},QT=Kv([Jv,Zv,nw,rw,UT],"html"),KT=Kv([Jv,Zv,nw,rw,HT],"svg");function XT(e){if(e.allowedElements&&e.disallowedElements)throw new TypeError("Only one of `allowedElements` and `disallowedElements` should be defined");if(e.allowedElements||e.disallowedElements||e.allowElement)return t=>{Ef(t,"element",(n,r,o)=>{const i=o;let l;if(e.allowedElements?l=!e.allowedElements.includes(n.tagName):e.disallowedElements&&(l=e.disallowedElements.includes(n.tagName)),!l&&e.allowElement&&typeof r=="number"&&(l=!e.allowElement(n,r,i)),l&&typeof r=="number")return e.unwrapDisallowed&&n.children?i.children.splice(r,1,...n.children):i.children.splice(r,1),r})}}function ZT(e){const t=e&&typeof e=="object"&&e.type==="text"?e.value||"":e;return typeof t=="string"&&t.replace(/[ \t\n\f\r]/g,"")===""}function JT(e){return e.join(" ").trim()}function eO(e,t){const n=t||{};return(e[e.length-1]===""?[...e,""]:e).join((n.padRight?" ":"")+","+(n.padLeft===!1?"":" ")).trim()}var Of={exports:{}},tg=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,tO=/\n/g,nO=/^\s*/,rO=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,oO=/^:\s*/,iO=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,lO=/^[;\s]*/,aO=/^\s+|\s+$/g,sO=` -`,ng="/",rg="*",yr="",uO="comment",cO="declaration",pO=function(e,t){if(typeof e!="string")throw new TypeError("First argument must be a string");if(!e)return[];t=t||{};var n=1,r=1;function o(h){var m=h.match(tO);m&&(n+=m.length);var w=h.lastIndexOf(sO);r=~w?h.length-w:r+h.length}function i(){var h={line:n,column:r};return function(m){return m.position=new l(h),u(),m}}function l(h){this.start=h,this.end={line:n,column:r},this.source=t.source}l.prototype.content=e;function a(h){var m=new Error(t.source+":"+n+":"+r+": "+h);if(m.reason=h,m.filename=t.source,m.line=n,m.column=r,m.source=e,!t.silent)throw m}function s(h){var m=h.exec(e);if(m){var w=m[0];return o(w),e=e.slice(w.length),m}}function u(){s(nO)}function c(h){var m;for(h=h||[];m=p();)m!==!1&&h.push(m);return h}function p(){var h=i();if(!(ng!=e.charAt(0)||rg!=e.charAt(1))){for(var m=2;yr!=e.charAt(m)&&(rg!=e.charAt(m)||ng!=e.charAt(m+1));)++m;if(m+=2,yr===e.charAt(m-1))return a("End of comment missing");var w=e.slice(2,m-2);return r+=2,o(w),e=e.slice(m),r+=2,h({type:uO,comment:w})}}function d(){var h=i(),m=s(rO);if(m){if(p(),!s(oO))return a("property missing ':'");var w=s(iO),g=h({type:cO,property:og(m[0].replace(tg,yr)),value:w?og(w[0].replace(tg,yr)):yr});return s(lO),g}}function f(){var h=[];c(h);for(var m;m=d();)m!==!1&&(h.push(m),c(h));return h}return u(),f()};function og(e){return e?e.replace(aO,yr):yr}var fO=pO;function ow(e,t){var n=null;if(!e||typeof e!="string")return n;for(var r,o=fO(e),i=typeof t=="function",l,a,s=0,u=o.length;s0?ae.createElement(f,s,p):ae.createElement(f,s)}function yO(e){let t=-1;for(;++t for more info)`),delete yl[i]}const t=I4().use(U3).use(e.remarkPlugins||[]).use(RT,{...e.remarkRehypeOptions,allowDangerousHtml:!0}).use(e.rehypePlugins||[]).use(XT,e),n=new bv;typeof e.children=="string"?n.value=e.children:e.children!==void 0&&e.children!==null&&console.warn(`[react-markdown] Warning: please pass a string as \`children\` (not: \`${e.children}\`)`);const r=t.runSync(t.parse(n),n);if(r.type!=="root")throw new TypeError("Expected a `root` node");let o=ae.createElement(ae.Fragment,{},iw({options:e,schema:QT,listDepth:0},r));return e.className&&(o=ae.createElement("div",{className:e.className},o)),o}lw.propTypes={children:re.string,className:re.string,allowElement:re.func,allowedElements:re.arrayOf(re.string),disallowedElements:re.arrayOf(re.string),unwrapDisallowed:re.bool,remarkPlugins:re.arrayOf(re.oneOfType([re.object,re.func,re.arrayOf(re.oneOfType([re.bool,re.string,re.object,re.func,re.arrayOf(re.any)]))])),rehypePlugins:re.arrayOf(re.oneOfType([re.object,re.func,re.arrayOf(re.oneOfType([re.bool,re.string,re.object,re.func,re.arrayOf(re.any)]))])),sourcePos:re.bool,rawSourcePos:re.bool,skipHtml:re.bool,includeElementIndex:re.bool,transformLinkUri:re.oneOfType([re.func,re.bool]),linkTarget:re.oneOfType([re.func,re.string]),transformImageUri:re.func,components:re.object};const SO={tokenize:AO,partial:!0},aw={tokenize:_O,partial:!0},sw={tokenize:$O,partial:!0},uw={tokenize:RO,partial:!0},CO={tokenize:LO,partial:!0},cw={tokenize:TO,previous:fw},pw={tokenize:OO,previous:dw},zn={tokenize:PO,previous:hw},dn={},EO={text:dn};let hr=48;for(;hr<123;)dn[hr]=zn,hr++,hr===58?hr=65:hr===91&&(hr=97);dn[43]=zn;dn[45]=zn;dn[46]=zn;dn[95]=zn;dn[72]=[zn,pw];dn[104]=[zn,pw];dn[87]=[zn,cw];dn[119]=[zn,cw];function PO(e,t,n){const r=this;let o,i;return l;function l(p){return!Hc(p)||!hw.call(r,r.previous)||Af(r.events)?n(p):(e.enter("literalAutolink"),e.enter("literalAutolinkEmail"),a(p))}function a(p){return Hc(p)?(e.consume(p),a):p===64?(e.consume(p),s):n(p)}function s(p){return p===46?e.check(CO,c,u)(p):p===45||p===95||nt(p)?(i=!0,e.consume(p),s):c(p)}function u(p){return e.consume(p),o=!0,s}function c(p){return i&&o&<(r.previous)?(e.exit("literalAutolinkEmail"),e.exit("literalAutolink"),t(p)):n(p)}}function TO(e,t,n){const r=this;return o;function o(l){return l!==87&&l!==119||!fw.call(r,r.previous)||Af(r.events)?n(l):(e.enter("literalAutolink"),e.enter("literalAutolinkWww"),e.check(SO,e.attempt(aw,e.attempt(sw,i),n),n)(l))}function i(l){return e.exit("literalAutolinkWww"),e.exit("literalAutolink"),t(l)}}function OO(e,t,n){const r=this;let o="",i=!1;return l;function l(p){return(p===72||p===104)&&dw.call(r,r.previous)&&!Af(r.events)?(e.enter("literalAutolink"),e.enter("literalAutolinkHttp"),o+=String.fromCodePoint(p),e.consume(p),a):n(p)}function a(p){if(lt(p)&&o.length<5)return o+=String.fromCodePoint(p),e.consume(p),a;if(p===58){const d=o.toLowerCase();if(d==="http"||d==="https")return e.consume(p),s}return n(p)}function s(p){return p===47?(e.consume(p),i?u:(i=!0,s)):n(p)}function u(p){return p===null||va(p)||Se(p)||_r(p)||ws(p)?n(p):e.attempt(aw,e.attempt(sw,c),n)(p)}function c(p){return e.exit("literalAutolinkHttp"),e.exit("literalAutolink"),t(p)}}function AO(e,t,n){let r=0;return o;function o(l){return(l===87||l===119)&&r<3?(r++,e.consume(l),o):l===46&&r===3?(e.consume(l),i):n(l)}function i(l){return l===null?n(l):t(l)}}function _O(e,t,n){let r,o,i;return l;function l(u){return u===46||u===95?e.check(uw,s,a)(u):u===null||Se(u)||_r(u)||u!==45&&ws(u)?s(u):(i=!0,e.consume(u),l)}function a(u){return u===95?r=!0:(o=r,r=void 0),e.consume(u),l}function s(u){return o||r||!i?n(u):t(u)}}function $O(e,t){let n=0,r=0;return o;function o(l){return l===40?(n++,e.consume(l),o):l===41&&r0&&!n&&(e[e.length-1][1]._gfmAutolinkLiteralWalkedInto=!0),n}const zO={tokenize:UO,partial:!0};function DO(){return{document:{91:{tokenize:jO,continuation:{tokenize:MO},exit:BO}},text:{91:{tokenize:FO},93:{add:"after",tokenize:NO,resolveTo:IO}}}}function NO(e,t,n){const r=this;let o=r.events.length;const i=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]);let l;for(;o--;){const s=r.events[o][1];if(s.type==="labelImage"){l=s;break}if(s.type==="gfmFootnoteCall"||s.type==="labelLink"||s.type==="label"||s.type==="image"||s.type==="link")break}return a;function a(s){if(!l||!l._balanced)return n(s);const u=Zt(r.sliceSerialize({start:l.end,end:r.now()}));return u.codePointAt(0)!==94||!i.includes(u.slice(1))?n(s):(e.enter("gfmFootnoteCallLabelMarker"),e.consume(s),e.exit("gfmFootnoteCallLabelMarker"),t(s))}}function IO(e,t){let n=e.length;for(;n--;)if(e[n][1].type==="labelImage"&&e[n][0]==="enter"){e[n][1];break}e[n+1][1].type="data",e[n+3][1].type="gfmFootnoteCallLabelMarker";const r={type:"gfmFootnoteCall",start:Object.assign({},e[n+3][1].start),end:Object.assign({},e[e.length-1][1].end)},o={type:"gfmFootnoteCallMarker",start:Object.assign({},e[n+3][1].end),end:Object.assign({},e[n+3][1].end)};o.end.column++,o.end.offset++,o.end._bufferIndex++;const i={type:"gfmFootnoteCallString",start:Object.assign({},o.end),end:Object.assign({},e[e.length-1][1].start)},l={type:"chunkString",contentType:"string",start:Object.assign({},i.start),end:Object.assign({},i.end)},a=[e[n+1],e[n+2],["enter",r,t],e[n+3],e[n+4],["enter",o,t],["exit",o,t],["enter",i,t],["enter",l,t],["exit",l,t],["exit",i,t],e[e.length-2],e[e.length-1],["exit",r,t]];return e.splice(n,e.length-n+1,...a),e}function FO(e,t,n){const r=this,o=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]);let i=0,l;return a;function a(p){return e.enter("gfmFootnoteCall"),e.enter("gfmFootnoteCallLabelMarker"),e.consume(p),e.exit("gfmFootnoteCallLabelMarker"),s}function s(p){return p!==94?n(p):(e.enter("gfmFootnoteCallMarker"),e.consume(p),e.exit("gfmFootnoteCallMarker"),e.enter("gfmFootnoteCallString"),e.enter("chunkString").contentType="string",u)}function u(p){if(i>999||p===93&&!l||p===null||p===91||Se(p))return n(p);if(p===93){e.exit("chunkString");const d=e.exit("gfmFootnoteCallString");return o.includes(Zt(r.sliceSerialize(d)))?(e.enter("gfmFootnoteCallLabelMarker"),e.consume(p),e.exit("gfmFootnoteCallLabelMarker"),e.exit("gfmFootnoteCall"),t):n(p)}return Se(p)||(l=!0),i++,e.consume(p),p===92?c:u}function c(p){return p===91||p===92||p===93?(e.consume(p),i++,u):u(p)}}function jO(e,t,n){const r=this,o=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]);let i,l=0,a;return s;function s(h){return e.enter("gfmFootnoteDefinition")._container=!0,e.enter("gfmFootnoteDefinitionLabel"),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(h),e.exit("gfmFootnoteDefinitionLabelMarker"),u}function u(h){return h===94?(e.enter("gfmFootnoteDefinitionMarker"),e.consume(h),e.exit("gfmFootnoteDefinitionMarker"),e.enter("gfmFootnoteDefinitionLabelString"),e.enter("chunkString").contentType="string",c):n(h)}function c(h){if(l>999||h===93&&!a||h===null||h===91||Se(h))return n(h);if(h===93){e.exit("chunkString");const m=e.exit("gfmFootnoteDefinitionLabelString");return i=Zt(r.sliceSerialize(m)),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(h),e.exit("gfmFootnoteDefinitionLabelMarker"),e.exit("gfmFootnoteDefinitionLabel"),d}return Se(h)||(a=!0),l++,e.consume(h),h===92?p:c}function p(h){return h===91||h===92||h===93?(e.consume(h),l++,c):c(h)}function d(h){return h===58?(e.enter("definitionMarker"),e.consume(h),e.exit("definitionMarker"),o.includes(i)||o.push(i),me(e,f,"gfmFootnoteDefinitionWhitespace")):n(h)}function f(h){return t(h)}}function MO(e,t,n){return e.check(Ui,t,e.attempt(zO,t,n))}function BO(e){e.exit("gfmFootnoteDefinition")}function UO(e,t,n){const r=this;return me(e,o,"gfmFootnoteDefinitionIndent",4+1);function o(i){const l=r.events[r.events.length-1];return l&&l[1].type==="gfmFootnoteDefinitionIndent"&&l[2].sliceSerialize(l[1],!0).length===4?t(i):n(i)}}function HO(e){let n=(e||{}).singleTilde;const r={tokenize:i,resolveAll:o};return n==null&&(n=!0),{text:{126:r},insideSpan:{null:[r]},attentionMarkers:{null:[126]}};function o(l,a){let s=-1;for(;++s1?s(h):(l.consume(h),p++,f);if(p<2&&!n)return s(h);const w=l.exit("strikethroughSequenceTemporary"),g=wa(h);return w._open=!g||g===2&&!!m,w._close=!m||m===2&&!!g,a(h)}}}class WO{constructor(){this.map=[]}add(t,n,r){VO(this,t,n,r)}consume(t){if(this.map.sort((i,l)=>i[0]-l[0]),this.map.length===0)return;let n=this.map.length;const r=[];for(;n>0;)n-=1,r.push(t.slice(this.map[n][0]+this.map[n][1])),r.push(this.map[n][2]),t.length=this.map[n][0];r.push([...t]),t.length=0;let o=r.pop();for(;o;)t.push(...o),o=r.pop();this.map.length=0}}function VO(e,t,n,r){let o=0;if(!(n===0&&r.length===0)){for(;o-1;){const H=r.events[z][1].type;if(H==="lineEnding"||H==="linePrefix")z--;else break}const _=z>-1?r.events[z][1].type:null,Y=_==="tableHead"||_==="tableRow"?k:s;return Y===k&&r.parser.lazy[r.now().line]?n(P):Y(P)}function s(P){return e.enter("tableHead"),e.enter("tableRow"),u(P)}function u(P){return P===124||(l=!0,i+=1),c(P)}function c(P){return P===null?n(P):X(P)?i>1?(i=0,r.interrupt=!0,e.exit("tableRow"),e.enter("lineEnding"),e.consume(P),e.exit("lineEnding"),f):n(P):se(P)?me(e,c,"whitespace")(P):(i+=1,l&&(l=!1,o+=1),P===124?(e.enter("tableCellDivider"),e.consume(P),e.exit("tableCellDivider"),l=!0,c):(e.enter("data"),p(P)))}function p(P){return P===null||P===124||Se(P)?(e.exit("data"),c(P)):(e.consume(P),P===92?d:p)}function d(P){return P===92||P===124?(e.consume(P),p):p(P)}function f(P){return r.interrupt=!1,r.parser.lazy[r.now().line]?n(P):(e.enter("tableDelimiterRow"),l=!1,se(P)?me(e,h,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(P):h(P))}function h(P){return P===45||P===58?w(P):P===124?(l=!0,e.enter("tableCellDivider"),e.consume(P),e.exit("tableCellDivider"),m):E(P)}function m(P){return se(P)?me(e,w,"whitespace")(P):w(P)}function w(P){return P===58?(i+=1,l=!0,e.enter("tableDelimiterMarker"),e.consume(P),e.exit("tableDelimiterMarker"),g):P===45?(i+=1,g(P)):P===null||X(P)?C(P):E(P)}function g(P){return P===45?(e.enter("tableDelimiterFiller"),y(P)):E(P)}function y(P){return P===45?(e.consume(P),y):P===58?(l=!0,e.exit("tableDelimiterFiller"),e.enter("tableDelimiterMarker"),e.consume(P),e.exit("tableDelimiterMarker"),v):(e.exit("tableDelimiterFiller"),v(P))}function v(P){return se(P)?me(e,C,"whitespace")(P):C(P)}function C(P){return P===124?h(P):P===null||X(P)?!l||o!==i?E(P):(e.exit("tableDelimiterRow"),e.exit("tableHead"),t(P)):E(P)}function E(P){return n(P)}function k(P){return e.enter("tableRow"),T(P)}function T(P){return P===124?(e.enter("tableCellDivider"),e.consume(P),e.exit("tableCellDivider"),T):P===null||X(P)?(e.exit("tableRow"),t(P)):se(P)?me(e,T,"whitespace")(P):(e.enter("data"),A(P))}function A(P){return P===null||P===124||Se(P)?(e.exit("data"),T(P)):(e.consume(P),P===92?N:A)}function N(P){return P===92||P===124?(e.consume(P),A):A(P)}}function QO(e,t){let n=-1,r=!0,o=0,i=[0,0,0,0],l=[0,0,0,0],a=!1,s=0,u,c,p;const d=new WO;for(;++nn[2]+1){const h=n[2]+1,m=n[3]-n[2]-1;e.add(h,m,[])}}e.add(n[3]+1,0,[["exit",p,t]])}return o!==void 0&&(i.end=Object.assign({},Mr(t.events,o)),e.add(o,0,[["exit",i,t]]),i=void 0),i}function lg(e,t,n,r,o){const i=[],l=Mr(t.events,n);o&&(o.end=Object.assign({},l),i.push(["exit",o,t])),r.end=Object.assign({},l),i.push(["exit",r,t]),e.add(n+1,0,i)}function Mr(e,t){const n=e[t],r=n[0]==="enter"?"start":"end";return n[1][r]}const KO={tokenize:ZO},XO={text:{91:KO}};function ZO(e,t,n){const r=this;return o;function o(s){return r.previous!==null||!r._gfmTasklistFirstContentOfListItem?n(s):(e.enter("taskListCheck"),e.enter("taskListCheckMarker"),e.consume(s),e.exit("taskListCheckMarker"),i)}function i(s){return Se(s)?(e.enter("taskListCheckValueUnchecked"),e.consume(s),e.exit("taskListCheckValueUnchecked"),l):s===88||s===120?(e.enter("taskListCheckValueChecked"),e.consume(s),e.exit("taskListCheckValueChecked"),l):n(s)}function l(s){return s===93?(e.enter("taskListCheckMarker"),e.consume(s),e.exit("taskListCheckMarker"),e.exit("taskListCheck"),a):n(s)}function a(s){return X(s)?t(s):se(s)?e.check({tokenize:JO},t,n)(s):n(s)}}function JO(e,t,n){return me(e,r,"whitespace");function r(o){return o===null?n(o):t(o)}}function eA(e){return Pv([EO,DO(),HO(e),qO,XO])}function ag(e,t){const n=String(e);if(typeof t!="string")throw new TypeError("Expected character");let r=0,o=n.indexOf(t);for(;o!==-1;)r++,o=n.indexOf(t,o+t.length);return r}function tA(e){if(typeof e!="string")throw new TypeError("Expected a string");return e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}const nA={}.hasOwnProperty,rA=function(e,t,n,r){let o,i;typeof t=="string"||t instanceof RegExp?(i=[[t,n]],o=r):(i=t,o=n),o||(o={});const l=Cf(o.ignore||[]),a=oA(i);let s=-1;for(;++s0?{type:"text",value:T}:void 0),T!==!1&&(w!==E&&v.push({type:"text",value:p.value.slice(w,E)}),Array.isArray(T)?v.push(...T):T&&v.push(T),w=E+C[0].length,y=!0),!h.global)break;C=h.exec(p.value)}return y?(we}const vu="phrasing",wu=["autolink","link","image","label"],iA={transforms:[fA],enter:{literalAutolink:aA,literalAutolinkEmail:xu,literalAutolinkHttp:xu,literalAutolinkWww:xu},exit:{literalAutolink:pA,literalAutolinkEmail:cA,literalAutolinkHttp:sA,literalAutolinkWww:uA}},lA={unsafe:[{character:"@",before:"[+\\-.\\w]",after:"[\\-.\\w]",inConstruct:vu,notInConstruct:wu},{character:".",before:"[Ww]",after:"[\\-.\\w]",inConstruct:vu,notInConstruct:wu},{character:":",before:"[ps]",after:"\\/",inConstruct:vu,notInConstruct:wu}]};function aA(e){this.enter({type:"link",title:null,url:"",children:[]},e)}function xu(e){this.config.enter.autolinkProtocol.call(this,e)}function sA(e){this.config.exit.autolinkProtocol.call(this,e)}function uA(e){this.config.exit.data.call(this,e);const t=this.stack[this.stack.length-1];t.url="http://"+this.sliceSerialize(e)}function cA(e){this.config.exit.autolinkEmail.call(this,e)}function pA(e){this.exit(e)}function fA(e){rA(e,[[/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/gi,dA],[/([-.\w+]+)@([-\w]+(?:\.[-\w]+)+)/g,hA]],{ignore:["link","linkReference"]})}function dA(e,t,n,r,o){let i="";if(!mw(o)||(/^w/i.test(t)&&(n=t+n,t="",i="http://"),!mA(n)))return!1;const l=gA(n+r);if(!l[0])return!1;const a={type:"link",title:null,url:i+t+l[0],children:[{type:"text",value:t+l[0]}]};return l[1]?[a,{type:"text",value:l[1]}]:a}function hA(e,t,n,r){return!mw(r,!0)||/[-\d_]$/.test(n)?!1:{type:"link",title:null,url:"mailto:"+t+"@"+n,children:[{type:"text",value:t+"@"+n}]}}function mA(e){const t=e.split(".");return!(t.length<2||t[t.length-1]&&(/_/.test(t[t.length-1])||!/[a-zA-Z\d]/.test(t[t.length-1]))||t[t.length-2]&&(/_/.test(t[t.length-2])||!/[a-zA-Z\d]/.test(t[t.length-2])))}function gA(e){const t=/[!"&'),.:;<>?\]}]+$/.exec(e);if(!t)return[e,void 0];e=e.slice(0,t.index);let n=t[0],r=n.indexOf(")");const o=ag(e,"(");let i=ag(e,")");for(;r!==-1&&o>i;)e+=n.slice(0,r+1),n=n.slice(r+1),r=n.indexOf(")"),i++;return[e,n]}function mw(e,t){const n=e.input.charCodeAt(e.index-1);return(e.index===0||_r(n)||ws(n))&&(!t||n!==47)}function gw(e){return e.label||!e.identifier?e.label||"":Iv(e.identifier)}function yA(e,t,n){const r=t.indexStack,o=e.children||[],i=t.createTracker(n),l=[];let a=-1;for(r.push(-1);++a{e.run(Zv(n,t),r,i=>{o(i)})}}function WT(e){return t=>Zv(t,e)}var Jv={exports:{}},VT="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED",GT=VT,qT=GT;function ew(){}function tw(){}tw.resetWarningCache=ew;var YT=function(){function e(r,o,i,l,a,s){if(s!==qT){var u=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw u.name="Invariant Violation",u}}e.isRequired=e;function t(){return e}var n={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:tw,resetWarningCache:ew};return n.PropTypes=n,n};Jv.exports=YT();var QT=Jv.exports;const re=_r(QT);class Vi{constructor(t,n,r){this.property=t,this.normal=n,r&&(this.space=r)}}Vi.prototype.property={};Vi.prototype.normal={};Vi.prototype.space=null;function nw(e,t){const n={},r={};let o=-1;for(;++o4&&n.slice(0,4)==="data"&&e3.test(t)){if(t.charAt(4)==="-"){const i=t.slice(5).replace(ng,o3);r="data"+i.charAt(0).toUpperCase()+i.slice(1)}else{const i=t.slice(4);if(!ng.test(i)){let l=i.replace(t3,r3);l.charAt(0)!=="-"&&(l="-"+l),t="data"+l}}o=Tf}return new o(r,t)}function r3(e){return"-"+e.toLowerCase()}function o3(e){return e.charAt(1).toUpperCase()}const rg={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"},i3=nw([iw,ow,sw,uw,ZT],"html"),l3=nw([iw,ow,sw,uw,JT],"svg");function a3(e){if(e.allowedElements&&e.disallowedElements)throw new TypeError("Only one of `allowedElements` and `disallowedElements` should be defined");if(e.allowedElements||e.disallowedElements||e.allowElement)return t=>{Pf(t,"element",(n,r,o)=>{const i=o;let l;if(e.allowedElements?l=!e.allowedElements.includes(n.tagName):e.disallowedElements&&(l=e.disallowedElements.includes(n.tagName)),!l&&e.allowElement&&typeof r=="number"&&(l=!e.allowElement(n,r,i)),l&&typeof r=="number")return e.unwrapDisallowed&&n.children?i.children.splice(r,1,...n.children):i.children.splice(r,1),r})}}function s3(e){const t=e&&typeof e=="object"&&e.type==="text"?e.value||"":e;return typeof t=="string"&&t.replace(/[ \t\n\f\r]/g,"")===""}function u3(e){return e.join(" ").trim()}function c3(e,t){const n=t||{};return(e[e.length-1]===""?[...e,""]:e).join((n.padRight?" ":"")+","+(n.padLeft===!1?"":" ")).trim()}var Af={exports:{}},og=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,p3=/\n/g,f3=/^\s*/,d3=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,h3=/^:\s*/,m3=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,g3=/^[;\s]*/,y3=/^\s+|\s+$/g,v3=` +`,ig="/",lg="*",yr="",w3="comment",x3="declaration",b3=function(e,t){if(typeof e!="string")throw new TypeError("First argument must be a string");if(!e)return[];t=t||{};var n=1,r=1;function o(h){var m=h.match(p3);m&&(n+=m.length);var w=h.lastIndexOf(v3);r=~w?h.length-w:r+h.length}function i(){var h={line:n,column:r};return function(m){return m.position=new l(h),u(),m}}function l(h){this.start=h,this.end={line:n,column:r},this.source=t.source}l.prototype.content=e;function a(h){var m=new Error(t.source+":"+n+":"+r+": "+h);if(m.reason=h,m.filename=t.source,m.line=n,m.column=r,m.source=e,!t.silent)throw m}function s(h){var m=h.exec(e);if(m){var w=m[0];return o(w),e=e.slice(w.length),m}}function u(){s(f3)}function p(h){var m;for(h=h||[];m=c();)m!==!1&&h.push(m);return h}function c(){var h=i();if(!(ig!=e.charAt(0)||lg!=e.charAt(1))){for(var m=2;yr!=e.charAt(m)&&(lg!=e.charAt(m)||ig!=e.charAt(m+1));)++m;if(m+=2,yr===e.charAt(m-1))return a("End of comment missing");var w=e.slice(2,m-2);return r+=2,o(w),e=e.slice(m),r+=2,h({type:w3,comment:w})}}function d(){var h=i(),m=s(d3);if(m){if(c(),!s(h3))return a("property missing ':'");var w=s(m3),g=h({type:x3,property:ag(m[0].replace(og,yr)),value:w?ag(w[0].replace(og,yr)):yr});return s(g3),g}}function f(){var h=[];p(h);for(var m;m=d();)m!==!1&&(h.push(m),p(h));return h}return u(),f()};function ag(e){return e?e.replace(y3,yr):yr}var k3=b3;function cw(e,t){var n=null;if(!e||typeof e!="string")return n;for(var r,o=k3(e),i=typeof t=="function",l,a,s=0,u=o.length;s0?le.createElement(f,s,c):le.createElement(f,s)}function O3(e){let t=-1;for(;++t for more info)`),delete wl[i]}const t=q4().use(ZO).use(e.remarkPlugins||[]).use(UT,{...e.remarkRehypeOptions,allowDangerousHtml:!0}).use(e.rehypePlugins||[]).use(a3,e),n=new Ov;typeof e.children=="string"?n.value=e.children:e.children!==void 0&&e.children!==null&&console.warn(`[react-markdown] Warning: please pass a string as \`children\` (not: \`${e.children}\`)`);const r=t.runSync(t.parse(n),n);if(r.type!=="root")throw new TypeError("Expected a `root` node");let o=le.createElement(le.Fragment,{},pw({options:e,schema:i3,listDepth:0},r));return e.className&&(o=le.createElement("div",{className:e.className},o)),o}fw.propTypes={children:re.string,className:re.string,allowElement:re.func,allowedElements:re.arrayOf(re.string),disallowedElements:re.arrayOf(re.string),unwrapDisallowed:re.bool,remarkPlugins:re.arrayOf(re.oneOfType([re.object,re.func,re.arrayOf(re.oneOfType([re.bool,re.string,re.object,re.func,re.arrayOf(re.any)]))])),rehypePlugins:re.arrayOf(re.oneOfType([re.object,re.func,re.arrayOf(re.oneOfType([re.bool,re.string,re.object,re.func,re.arrayOf(re.any)]))])),sourcePos:re.bool,rawSourcePos:re.bool,skipHtml:re.bool,includeElementIndex:re.bool,transformLinkUri:re.oneOfType([re.func,re.bool]),linkTarget:re.oneOfType([re.func,re.string]),transformImageUri:re.func,components:re.object};const L3={tokenize:j3,partial:!0},dw={tokenize:M3,partial:!0},hw={tokenize:B3,partial:!0},mw={tokenize:U3,partial:!0},D3={tokenize:H3,partial:!0},gw={tokenize:I3,previous:vw},yw={tokenize:F3,previous:ww},Dn={tokenize:N3,previous:xw},dn={},z3={text:dn};let hr=48;for(;hr<123;)dn[hr]=Dn,hr++,hr===58?hr=65:hr===91&&(hr=97);dn[43]=Dn;dn[45]=Dn;dn[46]=Dn;dn[95]=Dn;dn[72]=[Dn,yw];dn[104]=[Dn,yw];dn[87]=[Dn,gw];dn[119]=[Dn,gw];function N3(e,t,n){const r=this;let o,i;return l;function l(c){return!Gc(c)||!xw.call(r,r.previous)||$f(r.events)?n(c):(e.enter("literalAutolink"),e.enter("literalAutolinkEmail"),a(c))}function a(c){return Gc(c)?(e.consume(c),a):c===64?(e.consume(c),s):n(c)}function s(c){return c===46?e.check(D3,p,u)(c):c===45||c===95||rt(c)?(i=!0,e.consume(c),s):p(c)}function u(c){return e.consume(c),o=!0,s}function p(c){return i&&o&&at(r.previous)?(e.exit("literalAutolinkEmail"),e.exit("literalAutolink"),t(c)):n(c)}}function I3(e,t,n){const r=this;return o;function o(l){return l!==87&&l!==119||!vw.call(r,r.previous)||$f(r.events)?n(l):(e.enter("literalAutolink"),e.enter("literalAutolinkWww"),e.check(L3,e.attempt(dw,e.attempt(hw,i),n),n)(l))}function i(l){return e.exit("literalAutolinkWww"),e.exit("literalAutolink"),t(l)}}function F3(e,t,n){const r=this;let o="",i=!1;return l;function l(c){return(c===72||c===104)&&ww.call(r,r.previous)&&!$f(r.events)?(e.enter("literalAutolink"),e.enter("literalAutolinkHttp"),o+=String.fromCodePoint(c),e.consume(c),a):n(c)}function a(c){if(at(c)&&o.length<5)return o+=String.fromCodePoint(c),e.consume(c),a;if(c===58){const d=o.toLowerCase();if(d==="http"||d==="https")return e.consume(c),s}return n(c)}function s(c){return c===47?(e.consume(c),i?u:(i=!0,s)):n(c)}function u(c){return c===null||ka(c)||Se(c)||$r(c)||ks(c)?n(c):e.attempt(dw,e.attempt(hw,p),n)(c)}function p(c){return e.exit("literalAutolinkHttp"),e.exit("literalAutolink"),t(c)}}function j3(e,t,n){let r=0;return o;function o(l){return(l===87||l===119)&&r<3?(r++,e.consume(l),o):l===46&&r===3?(e.consume(l),i):n(l)}function i(l){return l===null?n(l):t(l)}}function M3(e,t,n){let r,o,i;return l;function l(u){return u===46||u===95?e.check(mw,s,a)(u):u===null||Se(u)||$r(u)||u!==45&&ks(u)?s(u):(i=!0,e.consume(u),l)}function a(u){return u===95?r=!0:(o=r,r=void 0),e.consume(u),l}function s(u){return o||r||!i?n(u):t(u)}}function B3(e,t){let n=0,r=0;return o;function o(l){return l===40?(n++,e.consume(l),o):l===41&&r0&&!n&&(e[e.length-1][1]._gfmAutolinkLiteralWalkedInto=!0),n}const W3={tokenize:Z3,partial:!0};function V3(){return{document:{91:{tokenize:Q3,continuation:{tokenize:K3},exit:X3}},text:{91:{tokenize:Y3},93:{add:"after",tokenize:G3,resolveTo:q3}}}}function G3(e,t,n){const r=this;let o=r.events.length;const i=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]);let l;for(;o--;){const s=r.events[o][1];if(s.type==="labelImage"){l=s;break}if(s.type==="gfmFootnoteCall"||s.type==="labelLink"||s.type==="label"||s.type==="image"||s.type==="link")break}return a;function a(s){if(!l||!l._balanced)return n(s);const u=Zt(r.sliceSerialize({start:l.end,end:r.now()}));return u.codePointAt(0)!==94||!i.includes(u.slice(1))?n(s):(e.enter("gfmFootnoteCallLabelMarker"),e.consume(s),e.exit("gfmFootnoteCallLabelMarker"),t(s))}}function q3(e,t){let n=e.length;for(;n--;)if(e[n][1].type==="labelImage"&&e[n][0]==="enter"){e[n][1];break}e[n+1][1].type="data",e[n+3][1].type="gfmFootnoteCallLabelMarker";const r={type:"gfmFootnoteCall",start:Object.assign({},e[n+3][1].start),end:Object.assign({},e[e.length-1][1].end)},o={type:"gfmFootnoteCallMarker",start:Object.assign({},e[n+3][1].end),end:Object.assign({},e[n+3][1].end)};o.end.column++,o.end.offset++,o.end._bufferIndex++;const i={type:"gfmFootnoteCallString",start:Object.assign({},o.end),end:Object.assign({},e[e.length-1][1].start)},l={type:"chunkString",contentType:"string",start:Object.assign({},i.start),end:Object.assign({},i.end)},a=[e[n+1],e[n+2],["enter",r,t],e[n+3],e[n+4],["enter",o,t],["exit",o,t],["enter",i,t],["enter",l,t],["exit",l,t],["exit",i,t],e[e.length-2],e[e.length-1],["exit",r,t]];return e.splice(n,e.length-n+1,...a),e}function Y3(e,t,n){const r=this,o=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]);let i=0,l;return a;function a(c){return e.enter("gfmFootnoteCall"),e.enter("gfmFootnoteCallLabelMarker"),e.consume(c),e.exit("gfmFootnoteCallLabelMarker"),s}function s(c){return c!==94?n(c):(e.enter("gfmFootnoteCallMarker"),e.consume(c),e.exit("gfmFootnoteCallMarker"),e.enter("gfmFootnoteCallString"),e.enter("chunkString").contentType="string",u)}function u(c){if(i>999||c===93&&!l||c===null||c===91||Se(c))return n(c);if(c===93){e.exit("chunkString");const d=e.exit("gfmFootnoteCallString");return o.includes(Zt(r.sliceSerialize(d)))?(e.enter("gfmFootnoteCallLabelMarker"),e.consume(c),e.exit("gfmFootnoteCallLabelMarker"),e.exit("gfmFootnoteCall"),t):n(c)}return Se(c)||(l=!0),i++,e.consume(c),c===92?p:u}function p(c){return c===91||c===92||c===93?(e.consume(c),i++,u):u(c)}}function Q3(e,t,n){const r=this,o=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]);let i,l=0,a;return s;function s(h){return e.enter("gfmFootnoteDefinition")._container=!0,e.enter("gfmFootnoteDefinitionLabel"),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(h),e.exit("gfmFootnoteDefinitionLabelMarker"),u}function u(h){return h===94?(e.enter("gfmFootnoteDefinitionMarker"),e.consume(h),e.exit("gfmFootnoteDefinitionMarker"),e.enter("gfmFootnoteDefinitionLabelString"),e.enter("chunkString").contentType="string",p):n(h)}function p(h){if(l>999||h===93&&!a||h===null||h===91||Se(h))return n(h);if(h===93){e.exit("chunkString");const m=e.exit("gfmFootnoteDefinitionLabelString");return i=Zt(r.sliceSerialize(m)),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(h),e.exit("gfmFootnoteDefinitionLabelMarker"),e.exit("gfmFootnoteDefinitionLabel"),d}return Se(h)||(a=!0),l++,e.consume(h),h===92?c:p}function c(h){return h===91||h===92||h===93?(e.consume(h),l++,p):p(h)}function d(h){return h===58?(e.enter("definitionMarker"),e.consume(h),e.exit("definitionMarker"),o.includes(i)||o.push(i),de(e,f,"gfmFootnoteDefinitionWhitespace")):n(h)}function f(h){return t(h)}}function K3(e,t,n){return e.check(Wi,t,e.attempt(W3,t,n))}function X3(e){e.exit("gfmFootnoteDefinition")}function Z3(e,t,n){const r=this;return de(e,o,"gfmFootnoteDefinitionIndent",4+1);function o(i){const l=r.events[r.events.length-1];return l&&l[1].type==="gfmFootnoteDefinitionIndent"&&l[2].sliceSerialize(l[1],!0).length===4?t(i):n(i)}}function J3(e){let n=(e||{}).singleTilde;const r={tokenize:i,resolveAll:o};return n==null&&(n=!0),{text:{126:r},insideSpan:{null:[r]},attentionMarkers:{null:[126]}};function o(l,a){let s=-1;for(;++s1?s(h):(l.consume(h),c++,f);if(c<2&&!n)return s(h);const w=l.exit("strikethroughSequenceTemporary"),g=Sa(h);return w._open=!g||g===2&&!!m,w._close=!m||m===2&&!!g,a(h)}}}class eA{constructor(){this.map=[]}add(t,n,r){tA(this,t,n,r)}consume(t){if(this.map.sort((i,l)=>i[0]-l[0]),this.map.length===0)return;let n=this.map.length;const r=[];for(;n>0;)n-=1,r.push(t.slice(this.map[n][0]+this.map[n][1])),r.push(this.map[n][2]),t.length=this.map[n][0];r.push([...t]),t.length=0;let o=r.pop();for(;o;)t.push(...o),o=r.pop();this.map.length=0}}function tA(e,t,n,r){let o=0;if(!(n===0&&r.length===0)){for(;o-1;){const q=r.events[_][1].type;if(q==="lineEnding"||q==="linePrefix")_--;else break}const R=_>-1?r.events[_][1].type:null,H=R==="tableHead"||R==="tableRow"?k:s;return H===k&&r.parser.lazy[r.now().line]?n(P):H(P)}function s(P){return e.enter("tableHead"),e.enter("tableRow"),u(P)}function u(P){return P===124||(l=!0,i+=1),p(P)}function p(P){return P===null?n(P):K(P)?i>1?(i=0,r.interrupt=!0,e.exit("tableRow"),e.enter("lineEnding"),e.consume(P),e.exit("lineEnding"),f):n(P):ae(P)?de(e,p,"whitespace")(P):(i+=1,l&&(l=!1,o+=1),P===124?(e.enter("tableCellDivider"),e.consume(P),e.exit("tableCellDivider"),l=!0,p):(e.enter("data"),c(P)))}function c(P){return P===null||P===124||Se(P)?(e.exit("data"),p(P)):(e.consume(P),P===92?d:c)}function d(P){return P===92||P===124?(e.consume(P),c):c(P)}function f(P){return r.interrupt=!1,r.parser.lazy[r.now().line]?n(P):(e.enter("tableDelimiterRow"),l=!1,ae(P)?de(e,h,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(P):h(P))}function h(P){return P===45||P===58?w(P):P===124?(l=!0,e.enter("tableCellDivider"),e.consume(P),e.exit("tableCellDivider"),m):E(P)}function m(P){return ae(P)?de(e,w,"whitespace")(P):w(P)}function w(P){return P===58?(i+=1,l=!0,e.enter("tableDelimiterMarker"),e.consume(P),e.exit("tableDelimiterMarker"),g):P===45?(i+=1,g(P)):P===null||K(P)?C(P):E(P)}function g(P){return P===45?(e.enter("tableDelimiterFiller"),y(P)):E(P)}function y(P){return P===45?(e.consume(P),y):P===58?(l=!0,e.exit("tableDelimiterFiller"),e.enter("tableDelimiterMarker"),e.consume(P),e.exit("tableDelimiterMarker"),v):(e.exit("tableDelimiterFiller"),v(P))}function v(P){return ae(P)?de(e,C,"whitespace")(P):C(P)}function C(P){return P===124?h(P):P===null||K(P)?!l||o!==i?E(P):(e.exit("tableDelimiterRow"),e.exit("tableHead"),t(P)):E(P)}function E(P){return n(P)}function k(P){return e.enter("tableRow"),O(P)}function O(P){return P===124?(e.enter("tableCellDivider"),e.consume(P),e.exit("tableCellDivider"),O):P===null||K(P)?(e.exit("tableRow"),t(P)):ae(P)?de(e,O,"whitespace")(P):(e.enter("data"),T(P))}function T(P){return P===null||P===124||Se(P)?(e.exit("data"),O(P)):(e.consume(P),P===92?N:T)}function N(P){return P===92||P===124?(e.consume(P),T):T(P)}}function iA(e,t){let n=-1,r=!0,o=0,i=[0,0,0,0],l=[0,0,0,0],a=!1,s=0,u,p,c;const d=new eA;for(;++nn[2]+1){const h=n[2]+1,m=n[3]-n[2]-1;e.add(h,m,[])}}e.add(n[3]+1,0,[["exit",c,t]])}return o!==void 0&&(i.end=Object.assign({},Br(t.events,o)),e.add(o,0,[["exit",i,t]]),i=void 0),i}function ug(e,t,n,r,o){const i=[],l=Br(t.events,n);o&&(o.end=Object.assign({},l),i.push(["exit",o,t])),r.end=Object.assign({},l),i.push(["exit",r,t]),e.add(n+1,0,i)}function Br(e,t){const n=e[t],r=n[0]==="enter"?"start":"end";return n[1][r]}const lA={tokenize:sA},aA={text:{91:lA}};function sA(e,t,n){const r=this;return o;function o(s){return r.previous!==null||!r._gfmTasklistFirstContentOfListItem?n(s):(e.enter("taskListCheck"),e.enter("taskListCheckMarker"),e.consume(s),e.exit("taskListCheckMarker"),i)}function i(s){return Se(s)?(e.enter("taskListCheckValueUnchecked"),e.consume(s),e.exit("taskListCheckValueUnchecked"),l):s===88||s===120?(e.enter("taskListCheckValueChecked"),e.consume(s),e.exit("taskListCheckValueChecked"),l):n(s)}function l(s){return s===93?(e.enter("taskListCheckMarker"),e.consume(s),e.exit("taskListCheckMarker"),e.exit("taskListCheck"),a):n(s)}function a(s){return K(s)?t(s):ae(s)?e.check({tokenize:uA},t,n)(s):n(s)}}function uA(e,t,n){return de(e,r,"whitespace");function r(o){return o===null?n(o):t(o)}}function cA(e){return Rv([z3,V3(),J3(e),rA,aA])}function cg(e,t){const n=String(e);if(typeof t!="string")throw new TypeError("Expected character");let r=0,o=n.indexOf(t);for(;o!==-1;)r++,o=n.indexOf(t,o+t.length);return r}function pA(e){if(typeof e!="string")throw new TypeError("Expected a string");return e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}const fA={}.hasOwnProperty,dA=function(e,t,n,r){let o,i;typeof t=="string"||t instanceof RegExp?(i=[[t,n]],o=r):(i=t,o=n),o||(o={});const l=Ef(o.ignore||[]),a=hA(i);let s=-1;for(;++s0?{type:"text",value:O}:void 0),O!==!1&&(w!==E&&v.push({type:"text",value:c.value.slice(w,E)}),Array.isArray(O)?v.push(...O):O&&v.push(O),w=E+C[0].length,y=!0),!h.global)break;C=h.exec(c.value)}return y?(we}const bu="phrasing",ku=["autolink","link","image","label"],mA={transforms:[kA],enter:{literalAutolink:yA,literalAutolinkEmail:Su,literalAutolinkHttp:Su,literalAutolinkWww:Su},exit:{literalAutolink:bA,literalAutolinkEmail:xA,literalAutolinkHttp:vA,literalAutolinkWww:wA}},gA={unsafe:[{character:"@",before:"[+\\-.\\w]",after:"[\\-.\\w]",inConstruct:bu,notInConstruct:ku},{character:".",before:"[Ww]",after:"[\\-.\\w]",inConstruct:bu,notInConstruct:ku},{character:":",before:"[ps]",after:"\\/",inConstruct:bu,notInConstruct:ku}]};function yA(e){this.enter({type:"link",title:null,url:"",children:[]},e)}function Su(e){this.config.enter.autolinkProtocol.call(this,e)}function vA(e){this.config.exit.autolinkProtocol.call(this,e)}function wA(e){this.config.exit.data.call(this,e);const t=this.stack[this.stack.length-1];t.url="http://"+this.sliceSerialize(e)}function xA(e){this.config.exit.autolinkEmail.call(this,e)}function bA(e){this.exit(e)}function kA(e){dA(e,[[/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/gi,SA],[/([-.\w+]+)@([-\w]+(?:\.[-\w]+)+)/g,CA]],{ignore:["link","linkReference"]})}function SA(e,t,n,r,o){let i="";if(!bw(o)||(/^w/i.test(t)&&(n=t+n,t="",i="http://"),!EA(n)))return!1;const l=PA(n+r);if(!l[0])return!1;const a={type:"link",title:null,url:i+t+l[0],children:[{type:"text",value:t+l[0]}]};return l[1]?[a,{type:"text",value:l[1]}]:a}function CA(e,t,n,r){return!bw(r,!0)||/[-\d_]$/.test(n)?!1:{type:"link",title:null,url:"mailto:"+t+"@"+n,children:[{type:"text",value:t+"@"+n}]}}function EA(e){const t=e.split(".");return!(t.length<2||t[t.length-1]&&(/_/.test(t[t.length-1])||!/[a-zA-Z\d]/.test(t[t.length-1]))||t[t.length-2]&&(/_/.test(t[t.length-2])||!/[a-zA-Z\d]/.test(t[t.length-2])))}function PA(e){const t=/[!"&'),.:;<>?\]}]+$/.exec(e);if(!t)return[e,void 0];e=e.slice(0,t.index);let n=t[0],r=n.indexOf(")");const o=cg(e,"(");let i=cg(e,")");for(;r!==-1&&o>i;)e+=n.slice(0,r+1),n=n.slice(r+1),r=n.indexOf(")"),i++;return[e,n]}function bw(e,t){const n=e.input.charCodeAt(e.index-1);return(e.index===0||$r(n)||ks(n))&&(!t||n!==47)}function kw(e){return e.label||!e.identifier?e.label||"":Hv(e.identifier)}function OA(e,t,n){const r=t.indexStack,o=e.children||[],i=t.createTracker(n),l=[];let a=-1;for(r.push(-1);++a `}return` -`}const wA=/\r?\n|\r/g;function xA(e,t){const n=[];let r=0,o=0,i;for(;i=wA.exec(e);)l(e.slice(r,i.index)),n.push(i[0]),r=i.index+i[0].length,o++;return l(e.slice(r)),n.join("");function l(a){n.push(t(a,o,!a))}}function yw(e){if(!e._compiled){const t=(e.atBreak?"[\\r\\n][\\t ]*":"")+(e.before?"(?:"+e.before+")":"");e._compiled=new RegExp((t?"("+t+")":"")+(/[|\\{}()[\]^$+*?.-]/.test(e.character)?"\\":"")+e.character+(e.after?"(?:"+e.after+")":""),"g")}return e._compiled}function bA(e,t){return cg(e,t.inConstruct,!0)&&!cg(e,t.notInConstruct,!1)}function cg(e,t,n){if(typeof t=="string"&&(t=[t]),!t||t.length===0)return n;let r=-1;for(;++r=u||c+10?" ":"")),o.shift(4),i+=o.move(xA(yA(e,n,o.current()),DA)),l(),i}function DA(e,t,n){return t===0?e:(n?"":" ")+e}function xw(e,t,n){const r=t.indexStack,o=e.children||[],i=[];let l=-1,a=n.before;r.push(-1);let s=t.createTracker(n);for(;++l0&&(a==="\r"||a===` -`)&&u.type==="html"&&(i[i.length-1]=i[i.length-1].replace(/(\r?\n|\r)$/," "),a=" ",s=t.createTracker(n),s.move(i.join(""))),i.push(s.move(t.handle(u,e,t,{...s.current(),before:a,after:c}))),a=i[i.length-1].slice(-1)}return r.pop(),i.join("")}const NA=["autolink","destinationLiteral","destinationRaw","reference","titleQuote","titleApostrophe"];bw.peek=BA;const IA={canContainEols:["delete"],enter:{strikethrough:jA},exit:{strikethrough:MA}},FA={unsafe:[{character:"~",inConstruct:"phrasing",notInConstruct:NA}],handlers:{delete:bw}};function jA(e){this.enter({type:"delete",children:[]},e)}function MA(e){this.exit(e)}function bw(e,t,n,r){const o=ks(r),i=n.enter("strikethrough");let l=o.move("~~");return l+=xw(e,n,{...o.current(),before:l,after:"~"}),l+=o.move("~~"),i(),l}function BA(){return"~"}kw.peek=UA;function kw(e,t,n){let r=e.value||"",o="`",i=-1;for(;new RegExp("(^|[^`])"+o+"([^`]|$)").test(r);)o+="`";for(/[^ \r\n]/.test(r)&&(/^[ \r\n]/.test(r)&&/[ \r\n]$/.test(r)||/^`|`$/.test(r))&&(r=" "+r+" ");++is&&(s=e[u].length);++wa[w])&&(a[w]=y)}h.push(g)}i[u]=h,l[u]=m}let c=-1;if(typeof n=="object"&&"length"in n)for(;++ca[c]&&(a[c]=g),d[c]=g),p[c]=y}i.splice(1,0,p),l.splice(1,0,d),u=-1;const f=[];for(;++un==="none"?null:n),children:[]},e),this.setData("inTable",!0)}function YA(e){this.exit(e),this.setData("inTable")}function QA(e){this.enter({type:"tableRow",children:[]},e)}function bu(e){this.exit(e)}function dg(e){this.enter({type:"tableCell",children:[]},e)}function KA(e){let t=this.resume();this.getData("inTable")&&(t=t.replace(/\\([\\|])/g,XA));const n=this.stack[this.stack.length-1];n.value=t,this.exit(e)}function XA(e,t){return t==="|"?t:e}function ZA(e){const t=e||{},n=t.tableCellPadding,r=t.tablePipeAlign,o=t.stringLength,i=n?" ":"|";return{unsafe:[{character:"\r",inConstruct:"tableCell"},{character:` -`,inConstruct:"tableCell"},{atBreak:!0,character:"|",after:"[ :-]"},{character:"|",inConstruct:"tableCell"},{atBreak:!0,character:":",after:"-"},{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{table:l,tableRow:a,tableCell:s,inlineCode:d}};function l(f,h,m,w){return u(c(f,m,w),f.align)}function a(f,h,m,w){const g=p(f,m,w),y=u([g]);return y.slice(0,y.indexOf(` -`))}function s(f,h,m,w){const g=m.enter("tableCell"),y=m.enter("phrasing"),v=xw(f,m,{...w,before:i,after:i});return y(),g(),v}function u(f,h){return HA(f,{align:h,alignDelimiters:r,padding:n,stringLength:o})}function c(f,h,m){const w=f.children;let g=-1;const y=[],v=h.enter("table");for(;++g-1?t.start:1)+(n.options.incrementListMarker===!1?0:t.children.indexOf(e))+i);let l=i.length+1;(o==="tab"||o==="mixed"&&(t&&t.type==="list"&&t.spread||e.spread))&&(l=Math.ceil(l/4)*4);const a=n.createTracker(r);a.move(i+" ".repeat(l-i.length)),a.shift(l);const s=n.enter("listItem"),u=n.indentLines(n.containerFlow(e,a.current()),c);return s(),u;function c(p,d,f){return d?(f?"":" ".repeat(l))+p:(f?i:i+" ".repeat(l-i.length))+p}}const n_={exit:{taskListCheckValueChecked:hg,taskListCheckValueUnchecked:hg,paragraph:o_}},r_={unsafe:[{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{listItem:i_}};function hg(e){const t=this.stack[this.stack.length-2];t.checked=e.type==="taskListCheckValueChecked"}function o_(e){const t=this.stack[this.stack.length-2];if(t&&t.type==="listItem"&&typeof t.checked=="boolean"){const n=this.stack[this.stack.length-1],r=n.children[0];if(r&&r.type==="text"){const o=t.children;let i=-1,l;for(;++i1&&(n+="s"),[e+" "+n+" ago","in "+e+" "+n]}var f_=["秒","分钟","小时","天","周","个月","年"];function d_(e,t){if(t===0)return["刚刚","片刻后"];var n=f_[~~(t/2)];return[e+" "+n+"前",e+" "+n+"后"]}var Wc={},Sw=function(e,t){Wc[e]=t},h_=function(e){return Wc[e]||Wc.en_US},ku=[60,60,24,7,365/7/12,12];function mg(e){return e instanceof Date?e:!isNaN(e)||/^\d+$/.test(e)?new Date(parseInt(e)):(e=(e||"").trim().replace(/\.\d+/,"").replace(/-/,"/").replace(/-/,"/").replace(/(\d)T(\d)/,"$1 $2").replace(/Z/," UTC").replace(/([+-]\d\d):?(\d\d)/," $1$2"),new Date(e))}function m_(e,t){var n=e<0?1:0;e=Math.abs(e);for(var r=e,o=0;e>=ku[o]&&o(o===0?9:1)&&(o+=1),t(e,o,r)[n].replace("%s",e.toString())}function g_(e,t){var n=t?mg(t):new Date;return(+n-+mg(e))/1e3}var y_=function(e,t,n){var r=g_(e,n&&n.relativeDate);return m_(r,h_(t))};Sw("en_US",p_);Sw("zh_CN",d_);function v_(e){const t=new Date(e),n=t.getHours(),r=String(t.getMinutes()).padStart(2,"0"),o=n>=12?"PM":"AM";return`${n%12||12}:${r} ${o}`}function Cw({error:e}){return L.jsx("img",{className:On("opencopilot-h-7 opencopilot-w-7 opencopilot-rounded-lg opencopilot-object-cover opencopilot-aspect-square hover:opencopilot-shadow",e&&"border opencopilot-border-rose-500 opencopilot-shadow-none"),src:"https://cdn.dribbble.com/users/281679/screenshots/14897126/media/f52c47307ac2daa0c727b1840c41d5ab.png?compress=1&resize=1600x1200&vertical=center",alt:"bot's avatar"})}function w_(){return L.jsx("div",{className:"opencopilot-rounded-lg opencopilot-shrink-0 opencopilot-bg-accent opencopilot-h-7 opencopilot-w-7 opencopilot-object-cover opencopilot-aspect-square hover:opencopilot-shadow opencopilot-border-primary-light opencopilot-border opencopilot-flex opencopilot-items-center opencopilot-justify-center",children:L.jsx("span",{className:"opencopilot-text-xl opencopilot-text-primary opencopilot-fill-current",children:L.jsx(u_,{})})})}function gg({message:e,timestamp:t}){const{displayText:n}=wf({text:e,every:1e-4,shouldStart:!0});return L.jsxs("div",{className:"opencopilot-p-2 opencopilot-w-full",children:[L.jsxs("div",{className:"opencopilot-flex opencopilot-items-start opencopilot-gap-3 opencopilot-w-full",dir:"auto",children:[L.jsx(Cw,{}),L.jsx("div",{className:"opencopilot-space-y-2 opencopilot-flex-1",children:L.jsx("div",{className:"opencopilot-w-fit",children:L.jsx("div",{dir:"auto",children:L.jsx(lw,{remarkPlugins:[s_],className:"opencopilot-prose opencopilot-prose-slate opencopilot-font-medium opencopilot-text-sm opencopilot-prose-sm prose-h1:opencopilot-font-medium prose-h2:opencopilot-font-normal prose-headings:opencopilot-my-1 opencopilot-max-w-full",children:n})})})})]}),L.jsx("div",{className:"opencopilot-w-full opencopilot-ps-[52px]",children:L.jsx("div",{children:t&&L.jsxs("span",{className:"opencopilot-text-xs opencopilot-m-0 group-last-of-type:opencopilot-inline opencopilot-hidden",children:["Bot · ",y_(t)]})})})]})}function x_(){const{displayText:e}=wf({text:"Bot is Thinking..."});return L.jsxs("div",{className:"opencopilot-p-2 opencopilot-flex opencopilot-items-center opencopilot-gap-3 opencopilot-w-full",children:[L.jsx("div",{className:"loading opencopilot-flex-col opencopilot-w-7 opencopilot-flex opencopilot-h-7 opencopilot-bg-accent opencopilot-text-primary opencopilot-rounded-lg opencopilot-shrink-0 opencopilot-mt-auto flex-center",children:L.jsx(MC,{height:"15",width:"15",color:"var(--opencopilot-primary-clr)",visible:!0})}),L.jsx("div",{className:"opencopilot-space-y-2 opencopilot-flex-1",children:L.jsx("div",{className:"mesg_body opencopilot-w-fit opencopilot-whitespace-nowrap opencopilot-max-w-full",children:L.jsx("p",{className:"opencopilot-text-sm opencopilot-lowercase",children:e})})})]})}function b_({content:e,timestamp:t}){return L.jsxs("div",{dir:"auto",className:"opencopilot-w-full last-of-type:opencopilot-mb-10 opencopilot-bg-accent opencopilot-p-2 opencopilot-flex opencopilot-gap-3 opencopilot-items-center",children:[L.jsx(w_,{}),L.jsx("div",{children:L.jsxs(ys,{children:[L.jsx(vf,{asChild:!0,children:L.jsx("p",{className:"opencopilot-prose opencopilot-prose-slate opencopilot-font-medium opencopilot-text-sm opencopilot-prose-sm",children:e})}),L.jsx(vs,{children:L.jsx("span",{children:t&&v_(t)})})]})})]})}function k_(){const{displayText:e}=wf({text:"Error sending the message.",every:.001});return L.jsx("div",{className:"opencopilot-clear-both opencopilot-w-full opencopilot-p-2",children:L.jsxs("div",{className:"opencopilot-flex opencopilot-items-center opencopilot-gap-3 opencopilot-w-full",children:[L.jsx(Cw,{error:!0}),L.jsx("div",{className:"opencopilot-text-rose-500 opencopilot-text-sm",children:e})]})})}const S_=e=>[(n,r)=>{if(e.current){const{scrollWidth:o,scrollHeight:i}=e.current,l=o-e.current.clientWidth,a=i-e.current.clientHeight,s=n/100*l,u=r/100*a;e.current.scrollTo(s,u)}}];function C_(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i=0)&&(n[o]=e[o]);return n}var E_=b.useLayoutEffect,P_=function(t){var n=b.useRef(t);return E_(function(){n.current=t}),n},yg=function(t,n){if(typeof t=="function"){t(n);return}t.current=n},T_=function(t,n){var r=b.useRef();return b.useCallback(function(o){t.current=o,r.current&&yg(r.current,null),r.current=n,n&&yg(n,o)},[n])},vg={"min-height":"0","max-height":"none",height:"0",visibility:"hidden",overflow:"hidden",position:"absolute","z-index":"-1000",top:"0",right:"0"},O_=function(t){Object.keys(vg).forEach(function(n){t.style.setProperty(n,vg[n],"important")})},wg=O_,ot=null,xg=function(t,n){var r=t.scrollHeight;return n.sizingStyle.boxSizing==="border-box"?r+n.borderSize:r-n.paddingSize};function A_(e,t,n,r){n===void 0&&(n=1),r===void 0&&(r=1/0),ot||(ot=document.createElement("textarea"),ot.setAttribute("tabindex","-1"),ot.setAttribute("aria-hidden","true"),wg(ot)),ot.parentNode===null&&document.body.appendChild(ot);var o=e.paddingSize,i=e.borderSize,l=e.sizingStyle,a=l.boxSizing;Object.keys(l).forEach(function(d){var f=d;ot.style[f]=l[f]}),wg(ot),ot.value=t;var s=xg(ot,e);ot.value=t,s=xg(ot,e),ot.value="x";var u=ot.scrollHeight-o,c=u*n;a==="border-box"&&(c=c+o+i),s=Math.max(c,s);var p=u*r;return a==="border-box"&&(p=p+o+i),s=Math.min(p,s),[s,u]}var bg=function(){},__=function(t,n){return t.reduce(function(r,o){return r[o]=n[o],r},{})},$_=["borderBottomWidth","borderLeftWidth","borderRightWidth","borderTopWidth","boxSizing","fontFamily","fontSize","fontStyle","fontWeight","letterSpacing","lineHeight","paddingBottom","paddingLeft","paddingRight","paddingTop","tabSize","textIndent","textRendering","textTransform","width","wordBreak"],R_=!!document.documentElement.currentStyle,L_=function(t){var n=window.getComputedStyle(t);if(n===null)return null;var r=__($_,n),o=r.boxSizing;if(o==="")return null;R_&&o==="border-box"&&(r.width=parseFloat(r.width)+parseFloat(r.borderRightWidth)+parseFloat(r.borderLeftWidth)+parseFloat(r.paddingRight)+parseFloat(r.paddingLeft)+"px");var i=parseFloat(r.paddingBottom)+parseFloat(r.paddingTop),l=parseFloat(r.borderBottomWidth)+parseFloat(r.borderTopWidth);return{sizingStyle:r,paddingSize:i,borderSize:l}},z_=L_;function Ew(e,t,n){var r=P_(n);b.useLayoutEffect(function(){var o=function(l){return r.current(l)};if(e)return e.addEventListener(t,o),function(){return e.removeEventListener(t,o)}},[])}var D_=function(t){Ew(window,"resize",t)},N_=function(t){Ew(document.fonts,"loadingdone",t)},I_=["cacheMeasurements","maxRows","minRows","onChange","onHeightChange"],F_=function(t,n){var r=t.cacheMeasurements,o=t.maxRows,i=t.minRows,l=t.onChange,a=l===void 0?bg:l,s=t.onHeightChange,u=s===void 0?bg:s,c=C_(t,I_),p=c.value!==void 0,d=b.useRef(null),f=T_(d,n),h=b.useRef(0),m=b.useRef(),w=function(){var v=d.current,C=r&&m.current?m.current:z_(v);if(C){m.current=C;var E=A_(C,v.value||v.placeholder||"x",i,o),k=E[0],T=E[1];h.current!==k&&(h.current=k,v.style.setProperty("height",k+"px","important"),u(k,{rowHeight:T}))}},g=function(v){p||w(),a(v)};return b.useLayoutEffect(w),D_(w),N_(w),b.createElement("textarea",ye({},c,{onChange:g,ref:f}))},j_=b.forwardRef(F_);function M_(e){return Ii({tag:"svg",attr:{viewBox:"0 0 16 16",fill:"currentColor"},child:[{tag:"path",attr:{d:"M1 1.91L1.78 1.5L15 7.44899V8.3999L1.78 14.33L1 13.91L2.58311 8L1 1.91ZM3.6118 8.5L2.33037 13.1295L13.5 7.8999L2.33037 2.83859L3.6118 7.43874L9 7.5V8.5H3.6118Z"}}]})(e)}function B_(e){return Ii({tag:"svg",attr:{viewBox:"0 0 24 24",fill:"none"},child:[{tag:"path",attr:{d:"M13.1459 11.0499L12.9716 9.05752L15.3462 8.84977C14.4471 7.98322 13.2242 7.4503 11.8769 7.4503C9.11547 7.4503 6.87689 9.68888 6.87689 12.4503C6.87689 15.2117 9.11547 17.4503 11.8769 17.4503C13.6977 17.4503 15.2911 16.4771 16.1654 15.0224L18.1682 15.5231C17.0301 17.8487 14.6405 19.4503 11.8769 19.4503C8.0109 19.4503 4.87689 16.3163 4.87689 12.4503C4.87689 8.58431 8.0109 5.4503 11.8769 5.4503C13.8233 5.4503 15.5842 6.24474 16.853 7.52706L16.6078 4.72412L18.6002 4.5498L19.1231 10.527L13.1459 11.0499Z",fill:"currentColor"}}]})(e)}function U_(){return Date.now()}function H_(){var n,r,o,i;const e=a1();return{notify:new Audio((r=(n=e==null?void 0:e.data)==null?void 0:n.sound_effects)==null?void 0:r.response),submit:new Audio((i=(o=e==null?void 0:e.data)==null?void 0:o.sound_effects)==null?void 0:i.submit)}}const Pw=b.createContext(void 0),W_=({children:e})=>{const[t,n]=b.useState([]),r=H_(),[o,i]=b.useState(!1),[l,a]=b.useState(!1),{axiosInstance:s}=i1(),u=jp(),c=h=>{var w;h.from==="user"?r==null||r.submit.play():(w=r==null?void 0:r.notify)==null||w.play();const m={...h,timestamp:h.timestamp?h.timestamp:U_()};n(g=>[...g,m])},p=async h=>{a(!1),c(h);try{i(!0);const m=await s.post("/chat/send",{...h,headers:u==null?void 0:u.headers});c({...m.data,from:"bot"})}catch{console.error("Error sending the message:"),a(!0)}finally{i(!1)}};function d(){n([])}const f={messages:t,sendMessage:p,loading:o,error:l,reset:d};return L.jsx(Pw.Provider,{value:f,children:e})},ba=()=>{const e=b.useContext(Pw);if(!e)throw new Error("useChat must be used within a ChatProvider");return e};function V_(e){return Ii({tag:"svg",attr:{viewBox:"0 0 24 24",strokeWidth:"2",stroke:"currentColor",fill:"none",strokeLinecap:"round",strokeLinejoin:"round"},child:[{tag:"path",attr:{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}},{tag:"path",attr:{d:"M3 12h1m8 -9v1m8 8h1m-15.4 -6.4l.7 .7m12.1 -.7l-.7 .7"}},{tag:"path",attr:{d:"M9 16a5 5 0 1 1 6 0a3.5 3.5 0 0 0 -1 3a2 2 0 0 1 -4 0a3.5 3.5 0 0 0 -1 -3"}},{tag:"path",attr:{d:"M9.7 17l4.6 0"}}]})(e)}function G_(){var r,o;const e=a1(),{messages:t,sendMessage:n}=ba();return L.jsx(L.Fragment,{children:t.length===0&&((r=e==null?void 0:e.data)==null?void 0:r.inital_questions)&&L.jsxs("div",{className:"opencopilot-flex opencopilot-items-center opencopilot-gap-4 opencopilot-justify-between opencopilot-w-full opencopilot-px-4",children:[L.jsx("div",{className:"opencopilot-flex opencopilot-items-center opencopilot-flex-wrap opencopilot-gap-2 opencopilot-flex-1",children:(o=e.data)==null?void 0:o.inital_questions.map((i,l)=>L.jsx("button",{className:"opencopilot-text-xs opencopilot-w-fit opencopilot-font-semibold opencopilot-whitespace-nowrap opencopilot-px-2.5 opencopilot-py-1 opencopilot-rounded-full opencopilot-bg-accent opencopilot-text-primary",onClick:()=>{n({from:"user",content:i})},children:i},l))}),L.jsxs(ys,{children:[L.jsx(vf,{children:L.jsx("span",{className:"opencopilot-text-xl opencopilot-text-primary opencopilot-mb-auto",children:L.jsx(V_,{})})}),L.jsx(vs,{asChild:!0,children:L.jsx("span",{className:"opencopilot-text-xs opencopilot-font-medium fade-in-bottom opencopilot-px-2 opencopilot-py-1 opencopilot-mb-3",children:"suggestions"})})]})]})})}function q_(){const[e,t]=b.useState(""),n=b.useRef(null),{sendMessage:r,reset:o,messages:i}=ba(),{loading:l}=ba(),a=e.trim().length>0,s=c=>{const p=c.currentTarget.value;t(p)};function u(){e.trim().length>0&&(t(""),r({from:"user",content:e}))}return L.jsxs("footer",{className:"opencopilot-p-2 opencopilot-flex opencopilot-w-full opencopilot-flex-col opencopilot-gap-2",children:[L.jsx("div",{className:"opencopilot-overflow-y-auto opencopilot-w-full ",children:L.jsx(G_,{})}),L.jsxs("div",{className:"opencopilot-w-full opencopilot-flex opencopilot-items-center opencopilot-transition-all opencopilot-justify-between focus-within:opencopilot-ring-1 focus-within:opencopilot-ring-primary opencopilot-gap-2 opencopilot-bg-accent opencopilot-p-2 opencopilot-rounded-2xl",children:[L.jsx("div",{className:"opencopilot-flex-1",children:L.jsx(j_,{dir:"auto",ref:n,autoFocus:!0,onKeyDown:c=>{c.key==="Enter"&&!c.shiftKey&&(c.preventDefault(),u())},disabled:l,maxRows:4,rows:1,value:e,onChange:s,className:"opencopilot-w-full opencopilot-resize-none opencopilot-bg-transparent focus-visible:opencopilot-outline-none opencopilot-border-none focus:opencopilot-outline-none focus:opencopilot-border-none opencopilot-max-h-[200px] opencopilot-scrollbar-thin opencopilot-leading-tight opencopilot-whitespace-pre-wrap opencopilot-py-1.5 opencopilot-px-4 placeholder:opencopilot-align-middle opencopilot-overflow-auto opencopilot-outline-none opencopilot-text-accent2 opencopilot-text-[14px] placeholder:opencopilot-text-xs opencopilot-font-normal"})}),L.jsxs("div",{className:"opencopilot-flex opencopilot-items-center opencopilot-justify-center opencopilot-gap-2 opencopilot-h-fit opencopilot-px-2 opencopilot-text-lg",children:[L.jsxs(ys,{children:[L.jsx(vf,{asChild:!0,children:L.jsx("button",{onClick:o,className:"opencopilot-text-xl disabled:opencopilot-opacity-40 disabled:opencopilot-pointer-events-none disabled:opencopilot-cursor-not-allowed opencopilot-text-[#5e5c5e] opencopilot-transition-all",disabled:!(i.length>0),children:L.jsx(B_,{})})}),L.jsx(vs,{children:"reset chat"})]}),L.jsx("button",{onClick:u,className:"opencopilot-text-xl disabled:opencopilot-opacity-40 disabled:opencopilot-pointer-events-none disabled:opencopilot-cursor-not-allowed opencopilot-text-[#5e5c5e] opencopilot-transition-all",disabled:l||!a,children:L.jsx(M_,{})})]})]})]})}function Y_({data:e,render:t,fallback:n}){return e.length===0?n:e.map((r,o)=>t(r,o))}function Q_(){const e=b.useRef(null),[t]=S_(e),{messages:n,loading:r,error:o}=ba(),i=jp(),l=i==null?void 0:i.initialMessage;return b.useEffect(()=>{t(0,100)},[]),b.useEffect(()=>{t(0,100)},[n,t]),L.jsxs("div",{className:"opencopilot-w-full opencopilot-flex opencopilot-h-full opencopilot-flex-col opencopilot-items-start opencopilot-relative",children:[L.jsx(NC,{}),L.jsx("main",{ref:e,className:"opencopilot-flex-1 opencopilot-w-full opencopilot-shrink-0 opencopilot-overflow-auto opencopilot-scrollbar-thin opencopilot-scroll-smooth",children:L.jsxs("div",{className:"opencopilot-flex opencopilot-h-fit opencopilot-mt-auto opencopilot-flex-col opencopilot-py-2 opencopilot-max-h-full opencopilot-items-center opencopilot-gap-1 last:fade-in-right",children:[l&&L.jsx(gg,{message:l}),L.jsx(Y_,{fallback:L.jsx("hr",{}),data:n,render:(a,s)=>{if(a.from==="bot"){if(a.type==="text")return L.jsx(gg,{timestamp:a.timestamp,message:a.response.text},s)}else if(a.from==="user")return L.jsx(b_,{timestamp:a.timestamp,content:a.content},s)}}),r&&L.jsx(x_,{}),o&&L.jsx(k_,{})]})}),L.jsx(q_,{})]})}function K_(){return L.jsx(W_,{children:L.jsx(Q_,{})})}const X_=typeof window>"u";function Z_({triggerSelector:e}){const[t,n]=I0();return b.useEffect(()=>{if(X_)return;const r=document.querySelector(e);if(r)return r.addEventListener("click",n),()=>r.removeEventListener("click",n);console.warn("The trigger element can't be found, make sure it is present in the DOM")},[e,n]),L.jsx("div",{className:On(t&&"!opencopilot-z-[100000] opencopilot-transition-all opencopilot-shadow-lg opencopilot-ease-in sm:opencopilot-w-96 opencopilot-fixed opencopilot-w-screen opencopilot-h-screen opencopilot-top-0 opencopilot-bottom-0 opencopilot-right-0"),children:L.jsx("div",{"data-open":t,className:On("opencopilot-font-inter opencopilot-overflow-hidden opencopilot-h-full sm:opencopilot-rounded-xl opencopilot-bg-white","opencopilot-opacity-0 opencopilot-transition-opacity opencopilot-ease",t&&"opencopilot-opacity-100 opencopilot-animate-in opencopilot-fade-in",!t&&"opencopilot-hidden opencopilot-animate-out opencopilot-fade-out"),children:L.jsx(K_,{})})})}function J_({triggerSelector:e,...t}){const n=document.createElement("style");n.innerHTML=Jb,document.body.appendChild(n);const r=document.createElement("div");r.id="opencopilot-aicopilot",document.body.appendChild(r),Su.createRoot(r).render(L.jsx(SS,{options:{...t},children:L.jsx(Z_,{triggerSelector:e})}))}window.initAiCoPilot=J_; +`}const AA=/\r?\n|\r/g;function $A(e,t){const n=[];let r=0,o=0,i;for(;i=AA.exec(e);)l(e.slice(r,i.index)),n.push(i[0]),r=i.index+i[0].length,o++;return l(e.slice(r)),n.join("");function l(a){n.push(t(a,o,!a))}}function Sw(e){if(!e._compiled){const t=(e.atBreak?"[\\r\\n][\\t ]*":"")+(e.before?"(?:"+e.before+")":"");e._compiled=new RegExp((t?"("+t+")":"")+(/[|\\{}()[\]^$+*?.-]/.test(e.character)?"\\":"")+e.character+(e.after?"(?:"+e.after+")":""),"g")}return e._compiled}function _A(e,t){return dg(e,t.inConstruct,!0)&&!dg(e,t.notInConstruct,!1)}function dg(e,t,n){if(typeof t=="string"&&(t=[t]),!t||t.length===0)return n;let r=-1;for(;++r=u||p+10?" ":"")),o.shift(4),i+=o.move($A(OA(e,n,o.current()),VA)),l(),i}function VA(e,t,n){return t===0?e:(n?"":" ")+e}function Pw(e,t,n){const r=t.indexStack,o=e.children||[],i=[];let l=-1,a=n.before;r.push(-1);let s=t.createTracker(n);for(;++l0&&(a==="\r"||a===` +`)&&u.type==="html"&&(i[i.length-1]=i[i.length-1].replace(/(\r?\n|\r)$/," "),a=" ",s=t.createTracker(n),s.move(i.join(""))),i.push(s.move(t.handle(u,e,t,{...s.current(),before:a,after:p}))),a=i[i.length-1].slice(-1)}return r.pop(),i.join("")}const GA=["autolink","destinationLiteral","destinationRaw","reference","titleQuote","titleApostrophe"];Ow.peek=XA;const qA={canContainEols:["delete"],enter:{strikethrough:QA},exit:{strikethrough:KA}},YA={unsafe:[{character:"~",inConstruct:"phrasing",notInConstruct:GA}],handlers:{delete:Ow}};function QA(e){this.enter({type:"delete",children:[]},e)}function KA(e){this.exit(e)}function Ow(e,t,n,r){const o=Es(r),i=n.enter("strikethrough");let l=o.move("~~");return l+=Pw(e,n,{...o.current(),before:l,after:"~"}),l+=o.move("~~"),i(),l}function XA(){return"~"}Tw.peek=ZA;function Tw(e,t,n){let r=e.value||"",o="`",i=-1;for(;new RegExp("(^|[^`])"+o+"([^`]|$)").test(r);)o+="`";for(/[^ \r\n]/.test(r)&&(/^[ \r\n]/.test(r)&&/[ \r\n]$/.test(r)||/^`|`$/.test(r))&&(r=" "+r+" ");++is&&(s=e[u].length);++wa[w])&&(a[w]=y)}h.push(g)}i[u]=h,l[u]=m}let p=-1;if(typeof n=="object"&&"length"in n)for(;++pa[p]&&(a[p]=g),d[p]=g),c[p]=y}i.splice(1,0,c),l.splice(1,0,d),u=-1;const f=[];for(;++un==="none"?null:n),children:[]},e),this.setData("inTable",!0)}function o$(e){this.exit(e),this.setData("inTable")}function i$(e){this.enter({type:"tableRow",children:[]},e)}function Cu(e){this.exit(e)}function gg(e){this.enter({type:"tableCell",children:[]},e)}function l$(e){let t=this.resume();this.getData("inTable")&&(t=t.replace(/\\([\\|])/g,a$));const n=this.stack[this.stack.length-1];n.value=t,this.exit(e)}function a$(e,t){return t==="|"?t:e}function s$(e){const t=e||{},n=t.tableCellPadding,r=t.tablePipeAlign,o=t.stringLength,i=n?" ":"|";return{unsafe:[{character:"\r",inConstruct:"tableCell"},{character:` +`,inConstruct:"tableCell"},{atBreak:!0,character:"|",after:"[ :-]"},{character:"|",inConstruct:"tableCell"},{atBreak:!0,character:":",after:"-"},{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{table:l,tableRow:a,tableCell:s,inlineCode:d}};function l(f,h,m,w){return u(p(f,m,w),f.align)}function a(f,h,m,w){const g=c(f,m,w),y=u([g]);return y.slice(0,y.indexOf(` +`))}function s(f,h,m,w){const g=m.enter("tableCell"),y=m.enter("phrasing"),v=Pw(f,m,{...w,before:i,after:i});return y(),g(),v}function u(f,h){return JA(f,{align:h,alignDelimiters:r,padding:n,stringLength:o})}function p(f,h,m){const w=f.children;let g=-1;const y=[],v=h.enter("table");for(;++g-1?t.start:1)+(n.options.incrementListMarker===!1?0:t.children.indexOf(e))+i);let l=i.length+1;(o==="tab"||o==="mixed"&&(t&&t.type==="list"&&t.spread||e.spread))&&(l=Math.ceil(l/4)*4);const a=n.createTracker(r);a.move(i+" ".repeat(l-i.length)),a.shift(l);const s=n.enter("listItem"),u=n.indentLines(n.containerFlow(e,a.current()),p);return s(),u;function p(c,d,f){return d?(f?"":" ".repeat(l))+c:(f?i:i+" ".repeat(l-i.length))+c}}const f$={exit:{taskListCheckValueChecked:yg,taskListCheckValueUnchecked:yg,paragraph:h$}},d$={unsafe:[{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{listItem:m$}};function yg(e){const t=this.stack[this.stack.length-2];t.checked=e.type==="taskListCheckValueChecked"}function h$(e){const t=this.stack[this.stack.length-2];if(t&&t.type==="listItem"&&typeof t.checked=="boolean"){const n=this.stack[this.stack.length-1],r=n.children[0];if(r&&r.type==="text"){const o=t.children;let i=-1,l;for(;++i1&&(n+="s"),[e+" "+n+" ago","in "+e+" "+n]}var k$=["秒","分钟","小时","天","周","个月","年"];function S$(e,t){if(t===0)return["刚刚","片刻后"];var n=k$[~~(t/2)];return[e+" "+n+"前",e+" "+n+"后"]}var qc={},Aw=function(e,t){qc[e]=t},C$=function(e){return qc[e]||qc.en_US},Eu=[60,60,24,7,365/7/12,12];function vg(e){return e instanceof Date?e:!isNaN(e)||/^\d+$/.test(e)?new Date(parseInt(e)):(e=(e||"").trim().replace(/\.\d+/,"").replace(/-/,"/").replace(/-/,"/").replace(/(\d)T(\d)/,"$1 $2").replace(/Z/," UTC").replace(/([+-]\d\d):?(\d\d)/," $1$2"),new Date(e))}function E$(e,t){var n=e<0?1:0;e=Math.abs(e);for(var r=e,o=0;e>=Eu[o]&&o(o===0?9:1)&&(o+=1),t(e,o,r)[n].replace("%s",e.toString())}function P$(e,t){var n=t?vg(t):new Date;return(+n-+vg(e))/1e3}var O$=function(e,t,n){var r=P$(e,n&&n.relativeDate);return E$(r,C$(t))};Aw("en_US",b$);Aw("zh_CN",S$);function T$(e){const t=new Date(e),n=t.getHours(),r=String(t.getMinutes()).padStart(2,"0"),o=n>=12?"PM":"AM";return`${n%12||12}:${r} ${o}`}function A$(){const[e,t]=x.useState(!1),n=async r=>{if(!(navigator!=null&&navigator.clipboard))return console.warn("Clipboard not supported"),!1;try{return await navigator.clipboard.writeText(r),t(!0),!0}catch(o){return console.warn("Copy failed",o),t(!1),!1}};return x.useEffect(()=>{if(e){const r=setTimeout(()=>{t(!1)},5e3);return()=>clearTimeout(r)}},[e]),[e,n]}function $$(e){return zr({tag:"svg",attr:{fill:"none",viewBox:"0 0 24 24",strokeWidth:"2",stroke:"currentColor","aria-hidden":"true"},child:[{tag:"path",attr:{strokeLinecap:"round",strokeLinejoin:"round",d:"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"}}]})(e)}function _$(e){return zr({tag:"svg",attr:{fill:"none",viewBox:"0 0 24 24",strokeWidth:"2",stroke:"currentColor","aria-hidden":"true"},child:[{tag:"path",attr:{strokeLinecap:"round",strokeLinejoin:"round",d:"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"}}]})(e)}function R$(){return Date.now()}function L$(){var n,r,o,i;const e=p1();return{notify:new Audio((r=(n=e==null?void 0:e.data)==null?void 0:n.sound_effects)==null?void 0:r.response),submit:new Audio((i=(o=e==null?void 0:e.data)==null?void 0:o.sound_effects)==null?void 0:i.submit)}}function wg(e){return typeof e=="string"?e.trim().length===0:Array.isArray(e)?e.length===0:typeof e=="object"?Object.keys(e).length===0:e===void 0}function _f(){return Math.random().toString(36).substring(2,15)}function D$(e){return e[e.length-1]}const $w=x.createContext(void 0),z$=({children:e})=>{const[t,n]=x.useState([]),r=L$(),[o,i]=x.useState(!1),[l,a]=x.useState(null),{axiosInstance:s}=u1(),u=Ua(),p=h=>{var w;h.from==="user"?r==null||r.submit.play():(w=r==null?void 0:r.notify)==null||w.play();const m={...h,timestamp:h.timestamp?h.timestamp:R$()};n(g=>[...g,m])},c=async h=>{h.from==="user"&&p(h),a(null),i(!0);try{const{data:m,status:w,statusText:g}=await s.post("/chat/send",{...h,headers:u==null?void 0:u.headers,user:u==null?void 0:u.user});w===200?p({...m,id:_f(),from:"bot"}):a({message:h,reason:g})}catch(m){a({message:h,reason:m==null?void 0:m.message})}finally{i(!1)}};function d(){n([])}const f={messages:t,sendMessage:c,loading:o,failedMessage:l,reset:d};return L.jsx($w.Provider,{value:f,children:e})},$i=()=>{const e=x.useContext($w);if(!e)throw new Error("useChat must be used within a ChatProvider");return e};function _w({error:e}){return L.jsx("img",{className:Tn("opencopilot-h-7 opencopilot-w-7 opencopilot-rounded-lg opencopilot-object-cover opencopilot-aspect-square hover:opencopilot-shadow",e&&"border opencopilot-border-rose-500 opencopilot-shadow-none"),src:"https://cdn.dribbble.com/users/281679/screenshots/14897126/media/f52c47307ac2daa0c727b1840c41d5ab.png?compress=1&resize=1600x1200&vertical=center",alt:"bot's avatar"})}function N$(){var t;const e=Ua();return L.jsxs(Bi,{children:[L.jsx(Ui,{hidden:!(e!=null&&e.user),side:"top",align:"center",children:(t=e==null?void 0:e.user)==null?void 0:t.name}),L.jsx(bs,{asChild:!0,children:L.jsx("div",{className:"opencopilot-rounded-lg opencopilot-shrink-0 opencopilot-bg-accent opencopilot-h-7 opencopilot-w-7 opencopilot-object-cover opencopilot-aspect-square hover:opencopilot-shadow opencopilot-border-primary-light opencopilot-border opencopilot-flex opencopilot-items-center opencopilot-justify-center",children:L.jsx("span",{className:"opencopilot-text-xl opencopilot-text-primary opencopilot-fill-current",children:L.jsx(w$,{})})})})]})}function xg({message:e,timestamp:t,id:n}){var s;const{displayText:r}=xf({text:e,every:1e-4,shouldStart:!0}),[o,i]=A$(),{messages:l}=$i(),a=((s=D$(l))==null?void 0:s.id)===n;return L.jsxs("div",{className:"opencopilot-p-2 group opencopilot-w-full",children:[L.jsxs("div",{className:"opencopilot-flex opencopilot-select-none opencopilot-items-start opencopilot-gap-3 opencopilot-w-full",dir:"auto",children:[L.jsx(_w,{}),L.jsx("div",{className:"opencopilot-space-y-2 opencopilot-flex-1",children:L.jsx("div",{className:"opencopilot-w-fit",children:L.jsx("div",{dir:"auto",children:L.jsx(fw,{remarkPlugins:[v$],className:"opencopilot-prose opencopilot-prose-slate opencopilot-font-medium opencopilot-text-sm opencopilot-prose-sm prose-h1:opencopilot-font-medium prose-h2:opencopilot-font-normal prose-headings:opencopilot-my-1 opencopilot-max-w-full",children:r})})})})]}),a&&L.jsxs("div",{className:"opencopilot-w-full opencopilot-ps-10 opencopilot-flex opencopilot-items-center opencopilot-justify-between",children:[L.jsx("div",{children:t&&L.jsxs("span",{className:"opencopilot-text-xs opencopilot-m-0",children:["Bot · ",O$(t)]})}),L.jsx("button",{className:"opencopilot-text-lg opencopilot-justify-self-end",onClick:()=>i(r),children:o?L.jsx($$,{className:"opencopilot-text-emerald-500"}):L.jsx(_$,{})})]})]})}function I$(){const{displayText:e}=xf({text:"Bot is Thinking..."});return L.jsxs("div",{className:"opencopilot-p-2 opencopilot-flex opencopilot-items-center opencopilot-gap-3 opencopilot-w-full",children:[L.jsx("div",{className:"loading opencopilot-flex-col opencopilot-w-7 opencopilot-flex opencopilot-h-7 opencopilot-bg-accent opencopilot-text-primary opencopilot-rounded-lg opencopilot-shrink-0 opencopilot-mt-auto flex-center",children:L.jsx(WC,{height:"15",width:"15",color:"var(--opencopilot-primary-clr)",visible:!0})}),L.jsx("div",{className:"opencopilot-space-y-2 opencopilot-flex-1",children:L.jsx("div",{className:"mesg_body opencopilot-w-fit opencopilot-whitespace-nowrap opencopilot-max-w-full",children:L.jsx("p",{className:"opencopilot-text-sm opencopilot-lowercase",children:e})})})]})}function F$({content:e,timestamp:t}){return L.jsxs("div",{dir:"auto",className:"opencopilot-w-full opencopilot-overflow-x-auto opencopilot-max-w-full last-of-type:opencopilot-mb-10 opencopilot-bg-accent opencopilot-p-2 opencopilot-flex opencopilot-gap-3 opencopilot-items-center",children:[L.jsx(N$,{}),L.jsx("div",{children:L.jsxs(Bi,{children:[L.jsx(bs,{asChild:!0,children:L.jsx("p",{className:"opencopilot-prose opencopilot-prose-slate opencopilot-font-medium opencopilot-text-sm opencopilot-prose-sm",children:e})}),L.jsx(Ui,{children:L.jsx("span",{children:t&&T$(t)})})]})})]})}function j$({message:e}){const{displayText:t}=xf({text:"Error sending the message.",every:.001});return L.jsx("div",{className:"opencopilot-clear-both opencopilot-w-full opencopilot-p-2",children:L.jsxs("div",{className:"opencopilot-flex opencopilot-items-center opencopilot-gap-3 opencopilot-w-full",children:[L.jsx(_w,{error:!0}),L.jsx("div",{className:"opencopilot-text-rose-500 opencopilot-text-sm",children:t})]})})}const M$=e=>[(n,r)=>{if(e.current){const{scrollWidth:o,scrollHeight:i}=e.current,l=o-e.current.clientWidth,a=i-e.current.clientHeight,s=n/100*l,u=r/100*a;e.current.scrollTo(s,u)}}];function B$(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i=0)&&(n[o]=e[o]);return n}var U$=x.useLayoutEffect,H$=function(t){var n=x.useRef(t);return U$(function(){n.current=t}),n},bg=function(t,n){if(typeof t=="function"){t(n);return}t.current=n},W$=function(t,n){var r=x.useRef();return x.useCallback(function(o){t.current=o,r.current&&bg(r.current,null),r.current=n,n&&bg(n,o)},[n])},kg={"min-height":"0","max-height":"none",height:"0",visibility:"hidden",overflow:"hidden",position:"absolute","z-index":"-1000",top:"0",right:"0"},V$=function(t){Object.keys(kg).forEach(function(n){t.style.setProperty(n,kg[n],"important")})},Sg=V$,it=null,Cg=function(t,n){var r=t.scrollHeight;return n.sizingStyle.boxSizing==="border-box"?r+n.borderSize:r-n.paddingSize};function G$(e,t,n,r){n===void 0&&(n=1),r===void 0&&(r=1/0),it||(it=document.createElement("textarea"),it.setAttribute("tabindex","-1"),it.setAttribute("aria-hidden","true"),Sg(it)),it.parentNode===null&&document.body.appendChild(it);var o=e.paddingSize,i=e.borderSize,l=e.sizingStyle,a=l.boxSizing;Object.keys(l).forEach(function(d){var f=d;it.style[f]=l[f]}),Sg(it),it.value=t;var s=Cg(it,e);it.value=t,s=Cg(it,e),it.value="x";var u=it.scrollHeight-o,p=u*n;a==="border-box"&&(p=p+o+i),s=Math.max(p,s);var c=u*r;return a==="border-box"&&(c=c+o+i),s=Math.min(c,s),[s,u]}var Eg=function(){},q$=function(t,n){return t.reduce(function(r,o){return r[o]=n[o],r},{})},Y$=["borderBottomWidth","borderLeftWidth","borderRightWidth","borderTopWidth","boxSizing","fontFamily","fontSize","fontStyle","fontWeight","letterSpacing","lineHeight","paddingBottom","paddingLeft","paddingRight","paddingTop","tabSize","textIndent","textRendering","textTransform","width","wordBreak"],Q$=!!document.documentElement.currentStyle,K$=function(t){var n=window.getComputedStyle(t);if(n===null)return null;var r=q$(Y$,n),o=r.boxSizing;if(o==="")return null;Q$&&o==="border-box"&&(r.width=parseFloat(r.width)+parseFloat(r.borderRightWidth)+parseFloat(r.borderLeftWidth)+parseFloat(r.paddingRight)+parseFloat(r.paddingLeft)+"px");var i=parseFloat(r.paddingBottom)+parseFloat(r.paddingTop),l=parseFloat(r.borderBottomWidth)+parseFloat(r.borderTopWidth);return{sizingStyle:r,paddingSize:i,borderSize:l}},X$=K$;function Rw(e,t,n){var r=H$(n);x.useLayoutEffect(function(){var o=function(l){return r.current(l)};if(e)return e.addEventListener(t,o),function(){return e.removeEventListener(t,o)}},[])}var Z$=function(t){Rw(window,"resize",t)},J$=function(t){Rw(document.fonts,"loadingdone",t)},e_=["cacheMeasurements","maxRows","minRows","onChange","onHeightChange"],t_=function(t,n){var r=t.cacheMeasurements,o=t.maxRows,i=t.minRows,l=t.onChange,a=l===void 0?Eg:l,s=t.onHeightChange,u=s===void 0?Eg:s,p=B$(t,e_),c=p.value!==void 0,d=x.useRef(null),f=W$(d,n),h=x.useRef(0),m=x.useRef(),w=function(){var v=d.current,C=r&&m.current?m.current:X$(v);if(C){m.current=C;var E=G$(C,v.value||v.placeholder||"x",i,o),k=E[0],O=E[1];h.current!==k&&(h.current=k,v.style.setProperty("height",k+"px","important"),u(k,{rowHeight:O}))}},g=function(v){c||w(),a(v)};return x.useLayoutEffect(w),Z$(w),J$(w),x.createElement("textarea",ge({},p,{onChange:g,ref:f}))},n_=x.forwardRef(t_);function r_(e){return zr({tag:"svg",attr:{viewBox:"0 0 16 16",fill:"currentColor"},child:[{tag:"path",attr:{d:"M1 1.91L1.78 1.5L15 7.44899V8.3999L1.78 14.33L1 13.91L2.58311 8L1 1.91ZM3.6118 8.5L2.33037 13.1295L13.5 7.8999L2.33037 2.83859L3.6118 7.43874L9 7.5V8.5H3.6118Z"}}]})(e)}function o_(e){return zr({tag:"svg",attr:{viewBox:"0 0 24 24",fill:"none"},child:[{tag:"path",attr:{d:"M13.1459 11.0499L12.9716 9.05752L15.3462 8.84977C14.4471 7.98322 13.2242 7.4503 11.8769 7.4503C9.11547 7.4503 6.87689 9.68888 6.87689 12.4503C6.87689 15.2117 9.11547 17.4503 11.8769 17.4503C13.6977 17.4503 15.2911 16.4771 16.1654 15.0224L18.1682 15.5231C17.0301 17.8487 14.6405 19.4503 11.8769 19.4503C8.0109 19.4503 4.87689 16.3163 4.87689 12.4503C4.87689 8.58431 8.0109 5.4503 11.8769 5.4503C13.8233 5.4503 15.5842 6.24474 16.853 7.52706L16.6078 4.72412L18.6002 4.5498L19.1231 10.527L13.1459 11.0499Z",fill:"currentColor"}}]})(e)}function i_(e){return zr({tag:"svg",attr:{viewBox:"0 0 24 24",strokeWidth:"2",stroke:"currentColor",fill:"none",strokeLinecap:"round",strokeLinejoin:"round"},child:[{tag:"path",attr:{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}},{tag:"path",attr:{d:"M3 12h1m8 -9v1m8 8h1m-15.4 -6.4l.7 .7m12.1 -.7l-.7 .7"}},{tag:"path",attr:{d:"M9 16a5 5 0 1 1 6 0a3.5 3.5 0 0 0 -1 3a2 2 0 0 1 -4 0a3.5 3.5 0 0 0 -1 -3"}},{tag:"path",attr:{d:"M9.7 17l4.6 0"}}]})(e)}function l_(){const{data:e}=p1(),{messages:t,sendMessage:n}=$i();return L.jsx(L.Fragment,{children:wg(t)&&!wg(e==null?void 0:e.inital_questions)&&L.jsxs("div",{className:"opencopilot-flex opencopilot-items-center opencopilot-gap-4 opencopilot-justify-between opencopilot-w-full opencopilot-px-4",children:[L.jsx("div",{className:"opencopilot-flex opencopilot-items-center opencopilot-flex-wrap opencopilot-gap-2 opencopilot-flex-1",children:e==null?void 0:e.inital_questions.map((r,o)=>L.jsx("button",{className:"opencopilot-text-xs opencopilot-w-fit opencopilot-font-semibold opencopilot-whitespace-nowrap opencopilot-px-2.5 opencopilot-py-1 opencopilot-rounded-full opencopilot-bg-accent opencopilot-text-primary",onClick:()=>{n({from:"user",content:r,id:_f()})},children:r},o))}),L.jsxs(Bi,{children:[L.jsx(bs,{children:L.jsx("span",{className:"opencopilot-text-xl opencopilot-text-primary opencopilot-mb-auto",children:L.jsx(i_,{})})}),L.jsx(Ui,{asChild:!0,children:L.jsx("span",{className:"opencopilot-text-xs opencopilot-font-medium fade-in-bottom opencopilot-px-2 opencopilot-py-1 opencopilot-mb-3",children:"suggestions"})})]})]})})}function a_(){const[e,t]=x.useState(""),n=x.useRef(null),{sendMessage:r,reset:o,messages:i}=$i(),{loading:l}=$i(),a=e.trim().length>0,s=p=>{const c=p.currentTarget.value;t(c)};function u(){e.trim().length>0&&(t(""),r({from:"user",content:e,id:_f()}))}return L.jsxs("footer",{className:"opencopilot-p-2 opencopilot-flex opencopilot-w-full opencopilot-flex-col opencopilot-gap-2",children:[L.jsx("div",{className:"opencopilot-overflow-y-auto opencopilot-w-full ",children:L.jsx(l_,{})}),L.jsxs("div",{className:"opencopilot-w-full opencopilot-flex opencopilot-items-center opencopilot-ring-[#334155]/60 opencopilot-transition-colors opencopilot-justify-between opencopilot-ring-1 opencopilot-overflow-hidden focus-within:opencopilot-ring-primary opencopilot-gap-2 opencopilot-bg-accent opencopilot-p-2 opencopilot-rounded-2xl",children:[L.jsx("div",{className:"opencopilot-flex-1",children:L.jsx(n_,{dir:"auto",ref:n,autoFocus:!0,onKeyDown:p=>{p.key==="Enter"&&!p.shiftKey&&(p.preventDefault(),u())},disabled:l,maxRows:4,rows:1,value:e,onChange:s,className:"opencopilot-w-full opencopilot-resize-none opencopilot-bg-transparent focus-visible:opencopilot-outline-none opencopilot-border-none focus:opencopilot-outline-none focus:opencopilot-border-none opencopilot-scrollbar-thin opencopilot-leading-tight opencopilot-whitespace-pre-wrap opencopilot-py-1.5 opencopilot-px-4 placeholder:opencopilot-align-middle opencopilot-overflow-auto opencopilot-outline-none opencopilot-text-accent2 opencopilot-text-[14px] placeholder:opencopilot-text-xs opencopilot-font-normal"})}),L.jsxs("div",{className:"opencopilot-flex opencopilot-items-center opencopilot-justify-center opencopilot-gap-2 opencopilot-h-fit opencopilot-px-2 opencopilot-text-lg",children:[L.jsxs(Bi,{children:[L.jsx(bs,{asChild:!0,children:L.jsx("button",{onClick:o,className:"opencopilot-text-xl disabled:opencopilot-opacity-40 disabled:opencopilot-pointer-events-none disabled:opencopilot-cursor-not-allowed opencopilot-text-[#5e5c5e] opencopilot-transition-all",disabled:!(i.length>0),children:L.jsx(o_,{})})}),L.jsx(Ui,{children:"reset chat"})]}),L.jsx("button",{onClick:u,className:"opencopilot-text-xl disabled:opencopilot-opacity-40 disabled:opencopilot-pointer-events-none disabled:opencopilot-cursor-not-allowed opencopilot-text-[#5e5c5e] opencopilot-transition-all",disabled:l||!a,children:L.jsx(r_,{})})]})]})]})}function s_({data:e,render:t,fallback:n}){return e.length===0?n:e.map((r,o)=>t(r,o))}function u_(){const e=x.useRef(null),[t]=M$(e),{messages:n,loading:r,failedMessage:o}=$i(),i=Ua(),l=i==null?void 0:i.initialMessage;return x.useEffect(()=>{t(0,100)},[]),x.useEffect(()=>{t(0,100)},[n,t]),L.jsxs("div",{className:"opencopilot-w-full opencopilot-flex opencopilot-h-full opencopilot-flex-col opencopilot-items-start opencopilot-relative",children:[L.jsx(MC,{}),L.jsx("main",{ref:e,className:"opencopilot-flex-1 opencopilot-w-full opencopilot-overflow-x-hidden opencopilot-shrink-0 opencopilot-overflow-auto opencopilot-scrollbar-thin opencopilot-scroll-smooth",children:L.jsxs("div",{className:"opencopilot-flex opencopilot-h-fit opencopilot-mt-auto opencopilot-flex-col opencopilot-py-2 opencopilot-max-h-full opencopilot-items-center opencopilot-gap-1 last:fade-in-right",children:[l&&L.jsx(xg,{message:l}),L.jsx(s_,{fallback:L.jsx("hr",{}),data:n,render:(a,s)=>{if(a.from==="bot"){if(a.type==="text")return L.jsx(xg,{timestamp:a.timestamp,id:a.id,message:a.response.text},s)}else if(a.from==="user")return L.jsx(F$,{id:a.id,timestamp:a.timestamp,content:a.content},s)}}),r&&L.jsx(I$,{}),o&&L.jsx(j$,{message:o})]})}),L.jsx(a_,{})]})}function c_(){return L.jsx(z$,{children:L.jsx(u_,{})})}const p_=typeof window>"u";function f_({triggerSelector:e}){const[t,n]=B0();return x.useEffect(()=>{if(p_)return;const r=document.querySelector(e);if(r)return r.addEventListener("click",n),()=>r.removeEventListener("click",n);console.warn("The trigger element can't be found, make sure it is present in the DOM")},[e,n]),L.jsx("div",{className:Tn(t&&"!opencopilot-z-[100000] opencopilot-transition-all opencopilot-shadow-lg opencopilot-ease-in sm:opencopilot-w-96 opencopilot-fixed opencopilot-w-screen opencopilot-h-screen opencopilot-top-0 opencopilot-bottom-0 opencopilot-right-0"),children:L.jsx("div",{"data-open":t,className:Tn("opencopilot-font-inter opencopilot-overflow-hidden opencopilot-h-full sm:opencopilot-rounded-xl opencopilot-bg-white","opencopilot-opacity-0 opencopilot-transition-opacity opencopilot-ease",t&&"opencopilot-opacity-100 opencopilot-animate-in opencopilot-fade-in",!t&&"opencopilot-hidden opencopilot-animate-out opencopilot-fade-out"),children:L.jsx(c_,{})})})}function d_({triggerSelector:e,...t}){const n=document.createElement("style");n.innerHTML=ik,document.body.appendChild(n);const r=document.createElement("div");r.id="opencopilot-aicopilot",document.body.appendChild(r),Pu.createRoot(r).render(L.jsx(TS,{options:{...t},children:L.jsx(f_,{triggerSelector:e})}))}window.initAiCoPilot=d_; diff --git a/copilot-widget/index.html b/copilot-widget/index.html index e7fa01700..809faf082 100644 --- a/copilot-widget/index.html +++ b/copilot-widget/index.html @@ -22,6 +22,9 @@ headers: { Authorization: "Bearer your_auth_token_goes_here", }, + user: { + name: "John Doe", + }, }); }; diff --git a/copilot-widget/lib/components/Messages.tsx b/copilot-widget/lib/components/Messages.tsx index 2f8846072..35561d2ae 100644 --- a/copilot-widget/lib/components/Messages.tsx +++ b/copilot-widget/lib/components/Messages.tsx @@ -11,6 +11,7 @@ import { useCopyToClipboard } from "@lib/hooks/useCopy"; import { HiOutlineClipboard, HiOutlineClipboardCheck } from "react-icons/hi"; import { FailedMessage, useChat } from "@lib/contexts/Controller"; import { getLast } from "@lib/utils/utils"; +import { useConfigData } from "@lib/contexts/ConfigData"; function BotIcon({ error }: { error?: boolean }) { return ( - - - - + + + +
+ + + +
+
+
); } diff --git a/copilot-widget/lib/components/ToolTip.tsx b/copilot-widget/lib/components/ToolTip.tsx index 1b75234b7..902a734fc 100644 --- a/copilot-widget/lib/components/ToolTip.tsx +++ b/copilot-widget/lib/components/ToolTip.tsx @@ -24,7 +24,7 @@ const TooltipContent = forwardRef< sideOffset={sideOffset} dir="auto" className={cn( - "opencopilot-text-primary opencopilot-font-medium opencopilot-bg-accent opencopilot-z-[50000] opencopilot-overflow-hidden opencopilot-shadow opencopilot-min-w-fit opencopilot-max-w-[15rem] opencopilot-select-none opencopilot-rounded-sm opencopilot-p-0.5 opencopilot-text-xs opencopilot-px-1 opencopilot-leading-none", + "opencopilot-text-primary opencopilot-font-medium opencopilot-px-2 opencopilot-bg-accent opencopilot-z-[50000] opencopilot-py-1 opencopilot-overflow-hidden opencopilot-shadow opencopilot-min-w-fit opencopilot-max-w-[15rem] opencopilot-select-none opencopilot-rounded-sm opencopilot-p-0.5 opencopilot-text-xs opencopilot-leading-none", "opencopilot-animate-in opencopilot-fade-in-0 opencopilot-slide-in-from-bottom-5 data-[state=closed]:animate-out data-[state=closed]:opencopilot-slide-in-from-top-0", className )} diff --git a/copilot-widget/lib/contexts/ConfigData.tsx b/copilot-widget/lib/contexts/ConfigData.tsx index 3b986e28f..1df3375e3 100644 --- a/copilot-widget/lib/contexts/ConfigData.tsx +++ b/copilot-widget/lib/contexts/ConfigData.tsx @@ -3,7 +3,7 @@ import { ReactNode, createContext, useContext } from "react"; export type ConfigDataContextType = Pick< Options, - "token" | "initialMessage" | "headers" | "apiUrl" + "token" | "initialMessage" | "headers" | "apiUrl" | "user" >; const ConfigDataContext = createContext( diff --git a/copilot-widget/lib/contexts/Controller.tsx b/copilot-widget/lib/contexts/Controller.tsx index b3f96d87f..cf9944bf2 100644 --- a/copilot-widget/lib/contexts/Controller.tsx +++ b/copilot-widget/lib/contexts/Controller.tsx @@ -55,6 +55,7 @@ const ChatProvider: React.FC<{ children: ReactNode }> = ({ children }) => { { ...message, headers: config?.headers, + user: config?.user, } ); if (status === 200) { diff --git a/copilot-widget/lib/types/options.ts b/copilot-widget/lib/types/options.ts index 7d440be80..390418f55 100644 --- a/copilot-widget/lib/types/options.ts +++ b/copilot-widget/lib/types/options.ts @@ -1,7 +1,10 @@ export type Options = { - token: string; - headers: Record; - initialMessage: string - triggerSelector: string; - apiUrl: string; + token: string; + headers: Record; + initialMessage: string; + triggerSelector: string; + apiUrl: string; + user?: { + name?: string; + }; }; diff --git a/copilot-widget/package.json b/copilot-widget/package.json index 2640ed15e..18138ca20 100644 --- a/copilot-widget/package.json +++ b/copilot-widget/package.json @@ -1,7 +1,7 @@ { "name": "@openchatai/copilot-widget", "private": false, - "version": "1.0.9", + "version": "1.1.0", "type": "module", "scripts": { "dev": "vite", @@ -75,4 +75,4 @@ }, "./index.css": "./dist/index.css" } -} \ No newline at end of file +}