@monology-io/chat-widget 1.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (32) hide show
  1. package/README.md +241 -0
  2. package/dist/index.esm.js +15 -0
  3. package/dist/index.esm.js.map +1 -0
  4. package/dist/index.js +15 -0
  5. package/dist/index.js.map +1 -0
  6. package/dist/types/App.test.d.ts +1 -0
  7. package/dist/types/components/Chat.d.ts +17 -0
  8. package/dist/types/components/ChatContainer.d.ts +6 -0
  9. package/dist/types/components/ChatSuggestions.d.ts +14 -0
  10. package/dist/types/components/ColorSelector.d.ts +7 -0
  11. package/dist/types/components/ConversationTitleBadge.d.ts +5 -0
  12. package/dist/types/components/ConversationsHistory.d.ts +7 -0
  13. package/dist/types/components/CustomIcons.d.ts +74 -0
  14. package/dist/types/components/FormRenderer.d.ts +54 -0
  15. package/dist/types/components/Header.d.ts +13 -0
  16. package/dist/types/components/MarkdownRenderer.d.ts +5 -0
  17. package/dist/types/components/MessageLoader.d.ts +2 -0
  18. package/dist/types/components/RenderWidget.d.ts +15 -0
  19. package/dist/types/components/Sidebar.d.ts +4 -0
  20. package/dist/types/components/StatusPopup.d.ts +14 -0
  21. package/dist/types/components/ThemeContext.d.ts +10 -0
  22. package/dist/types/components/ThemeToggle.d.ts +5 -0
  23. package/dist/types/components/UserVerificationPopup.d.ts +23 -0
  24. package/dist/types/components/Widget.d.ts +15 -0
  25. package/dist/types/components/axios.d.ts +3 -0
  26. package/dist/types/components/conversation.service.d.ts +7 -0
  27. package/dist/types/components/reportWebVitals.d.ts +2 -0
  28. package/dist/types/components/setupTests.d.ts +1 -0
  29. package/dist/types/components/token.service.d.ts +2 -0
  30. package/dist/types/components/types.d.ts +4 -0
  31. package/dist/types/index.d.ts +3 -0
  32. package/package.json +60 -0
@@ -0,0 +1,15 @@
1
+ import e,{useState as t,createContext as n,useContext as r,useRef as o,useEffect as a,useCallback as i}from"react";import{Fragment as l,jsx as s,jsxs as c}from"react/jsx-runtime";var u,d="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},m={exports:{}},p={exports:{}},f={};var h,g,_,y,b,v,x,k,w,C,E,S,R,F,P={};
2
+ /** @license React v16.13.1
3
+ * react-is.development.js
4
+ *
5
+ * Copyright (c) Facebook, Inc. and its affiliates.
6
+ *
7
+ * This source code is licensed under the MIT license found in the
8
+ * LICENSE file in the root directory of this source tree.
9
+ */function T(){return g||(g=1,e=p,"production"===process.env.NODE_ENV?e.exports=function(){if(u)return f;u=1;var e="function"==typeof Symbol&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,a=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,s=e?Symbol.for("react.async_mode"):60111,c=e?Symbol.for("react.concurrent_mode"):60111,d=e?Symbol.for("react.forward_ref"):60112,m=e?Symbol.for("react.suspense"):60113,p=e?Symbol.for("react.suspense_list"):60120,h=e?Symbol.for("react.memo"):60115,g=e?Symbol.for("react.lazy"):60116,_=e?Symbol.for("react.block"):60121,y=e?Symbol.for("react.fundamental"):60117,b=e?Symbol.for("react.responder"):60118,v=e?Symbol.for("react.scope"):60119;function x(e){if("object"==typeof e&&null!==e){var u=e.$$typeof;switch(u){case t:switch(e=e.type){case s:case c:case r:case a:case o:case m:return e;default:switch(e=e&&e.$$typeof){case l:case d:case g:case h:case i:return e;default:return u}}case n:return u}}}function k(e){return x(e)===c}return f.AsyncMode=s,f.ConcurrentMode=c,f.ContextConsumer=l,f.ContextProvider=i,f.Element=t,f.ForwardRef=d,f.Fragment=r,f.Lazy=g,f.Memo=h,f.Portal=n,f.Profiler=a,f.StrictMode=o,f.Suspense=m,f.isAsyncMode=function(e){return k(e)||x(e)===s},f.isConcurrentMode=k,f.isContextConsumer=function(e){return x(e)===l},f.isContextProvider=function(e){return x(e)===i},f.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===t},f.isForwardRef=function(e){return x(e)===d},f.isFragment=function(e){return x(e)===r},f.isLazy=function(e){return x(e)===g},f.isMemo=function(e){return x(e)===h},f.isPortal=function(e){return x(e)===n},f.isProfiler=function(e){return x(e)===a},f.isStrictMode=function(e){return x(e)===o},f.isSuspense=function(e){return x(e)===m},f.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===r||e===c||e===a||e===o||e===m||e===p||"object"==typeof e&&null!==e&&(e.$$typeof===g||e.$$typeof===h||e.$$typeof===i||e.$$typeof===l||e.$$typeof===d||e.$$typeof===y||e.$$typeof===b||e.$$typeof===v||e.$$typeof===_)},f.typeOf=x,f}():e.exports=(h||(h=1,"production"!==process.env.NODE_ENV&&function(){var e="function"==typeof Symbol&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,a=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,s=e?Symbol.for("react.async_mode"):60111,c=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,d=e?Symbol.for("react.suspense"):60113,m=e?Symbol.for("react.suspense_list"):60120,p=e?Symbol.for("react.memo"):60115,f=e?Symbol.for("react.lazy"):60116,h=e?Symbol.for("react.block"):60121,g=e?Symbol.for("react.fundamental"):60117,_=e?Symbol.for("react.responder"):60118,y=e?Symbol.for("react.scope"):60119;function b(e){if("object"==typeof e&&null!==e){var m=e.$$typeof;switch(m){case t:var h=e.type;switch(h){case s:case c:case r:case a:case o:case d:return h;default:var g=h&&h.$$typeof;switch(g){case l:case u:case f:case p:case i:return g;default:return m}}case n:return m}}}var v=s,x=c,k=l,w=i,C=t,E=u,S=r,R=f,F=p,T=n,B=a,I=o,N=d,L=!1;function O(e){return b(e)===c}P.AsyncMode=v,P.ConcurrentMode=x,P.ContextConsumer=k,P.ContextProvider=w,P.Element=C,P.ForwardRef=E,P.Fragment=S,P.Lazy=R,P.Memo=F,P.Portal=T,P.Profiler=B,P.StrictMode=I,P.Suspense=N,P.isAsyncMode=function(e){return L||(L=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),O(e)||b(e)===s},P.isConcurrentMode=O,P.isContextConsumer=function(e){return b(e)===l},P.isContextProvider=function(e){return b(e)===i},P.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===t},P.isForwardRef=function(e){return b(e)===u},P.isFragment=function(e){return b(e)===r},P.isLazy=function(e){return b(e)===f},P.isMemo=function(e){return b(e)===p},P.isPortal=function(e){return b(e)===n},P.isProfiler=function(e){return b(e)===a},P.isStrictMode=function(e){return b(e)===o},P.isSuspense=function(e){return b(e)===d},P.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===r||e===c||e===a||e===o||e===d||e===m||"object"==typeof e&&null!==e&&(e.$$typeof===f||e.$$typeof===p||e.$$typeof===i||e.$$typeof===l||e.$$typeof===u||e.$$typeof===g||e.$$typeof===_||e.$$typeof===y||e.$$typeof===h)},P.typeOf=b}()),P)),p.exports;var e}
10
+ /*
11
+ object-assign
12
+ (c) Sindre Sorhus
13
+ @license MIT
14
+ */function B(){if(y)return _;y=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,n=Object.prototype.propertyIsEnumerable;return _=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},n=0;n<10;n++)t["_"+String.fromCharCode(n)]=n;if("0123456789"!==Object.getOwnPropertyNames(t).map((function(e){return t[e]})).join(""))return!1;var r={};return"abcdefghijklmnopqrst".split("").forEach((function(e){r[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},r)).join("")}catch(e){return!1}}()?Object.assign:function(r,o){for(var a,i,l=function(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}(r),s=1;s<arguments.length;s++){for(var c in a=Object(arguments[s]))t.call(a,c)&&(l[c]=a[c]);if(e){i=e(a);for(var u=0;u<i.length;u++)n.call(a,i[u])&&(l[i[u]]=a[i[u]])}}return l},_}function I(){if(v)return b;v=1;return b="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"}function N(){return k?x:(k=1,x=Function.call.bind(Object.prototype.hasOwnProperty))}if("production"!==process.env.NODE_ENV){var L=T();m.exports=function(){if(S)return E;S=1;var e=T(),t=B(),n=I(),r=N(),o=function(){if(C)return w;C=1;var e=function(){};if("production"!==process.env.NODE_ENV){var t=I(),n={},r=N();e=function(e){var t="Warning: "+e;"undefined"!=typeof console&&console.error(t);try{throw new Error(t)}catch(e){}}}function o(o,a,i,l,s){if("production"!==process.env.NODE_ENV)for(var c in o)if(r(o,c)){var u;try{if("function"!=typeof o[c]){var d=Error((l||"React class")+": "+i+" type `"+c+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof o[c]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw d.name="Invariant Violation",d}u=o[c](a,c,l,i,null,t)}catch(e){u=e}if(!u||u instanceof Error||e((l||"React class")+": type specification of "+i+" `"+c+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof u+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),u instanceof Error&&!(u.message in n)){n[u.message]=!0;var m=s?s():"";e("Failed "+i+" type: "+u.message+(null!=m?m:""))}}}return o.resetWarningCache=function(){"production"!==process.env.NODE_ENV&&(n={})},w=o}(),a=function(){};function i(){return null}return"production"!==process.env.NODE_ENV&&(a=function(e){var t="Warning: "+e;"undefined"!=typeof console&&console.error(t);try{throw new Error(t)}catch(e){}}),E=function(l,s){var c="function"==typeof Symbol&&Symbol.iterator,u="<<anonymous>>",d={array:h("array"),bigint:h("bigint"),bool:h("boolean"),func:h("function"),number:h("number"),object:h("object"),string:h("string"),symbol:h("symbol"),any:f(i),arrayOf:function(e){return f((function(t,r,o,a,i){if("function"!=typeof e)return new p("Property `"+i+"` of component `"+o+"` has invalid PropType notation inside arrayOf.");var l=t[r];if(!Array.isArray(l))return new p("Invalid "+a+" `"+i+"` of type `"+y(l)+"` supplied to `"+o+"`, expected an array.");for(var s=0;s<l.length;s++){var c=e(l,s,o,a,i+"["+s+"]",n);if(c instanceof Error)return c}return null}))},element:f((function(e,t,n,r,o){var a=e[t];return l(a)?null:new p("Invalid "+r+" `"+o+"` of type `"+y(a)+"` supplied to `"+n+"`, expected a single ReactElement.")})),elementType:f((function(t,n,r,o,a){var i=t[n];return e.isValidElementType(i)?null:new p("Invalid "+o+" `"+a+"` of type `"+y(i)+"` supplied to `"+r+"`, expected a single ReactElement type.")})),instanceOf:function(e){return f((function(t,n,r,o,a){if(!(t[n]instanceof e)){var i=e.name||u;return new p("Invalid "+o+" `"+a+"` of type `"+((l=t[n]).constructor&&l.constructor.name?l.constructor.name:u)+"` supplied to `"+r+"`, expected instance of `"+i+"`.")}var l;return null}))},node:f((function(e,t,n,r,o){return _(e[t])?null:new p("Invalid "+r+" `"+o+"` supplied to `"+n+"`, expected a ReactNode.")})),objectOf:function(e){return f((function(t,o,a,i,l){if("function"!=typeof e)return new p("Property `"+l+"` of component `"+a+"` has invalid PropType notation inside objectOf.");var s=t[o],c=y(s);if("object"!==c)return new p("Invalid "+i+" `"+l+"` of type `"+c+"` supplied to `"+a+"`, expected an object.");for(var u in s)if(r(s,u)){var d=e(s,u,a,i,l+"."+u,n);if(d instanceof Error)return d}return null}))},oneOf:function(e){return Array.isArray(e)?f((function(t,n,r,o,a){for(var i=t[n],l=0;l<e.length;l++)if(m(i,e[l]))return null;var s=JSON.stringify(e,(function(e,t){return"symbol"===b(t)?String(t):t}));return new p("Invalid "+o+" `"+a+"` of value `"+String(i)+"` supplied to `"+r+"`, expected one of "+s+".")})):("production"!==process.env.NODE_ENV&&a(arguments.length>1?"Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).":"Invalid argument supplied to oneOf, expected an array."),i)},oneOfType:function(e){if(!Array.isArray(e))return"production"!==process.env.NODE_ENV&&a("Invalid argument supplied to oneOfType, expected an instance of array."),i;for(var t=0;t<e.length;t++){var o=e[t];if("function"!=typeof o)return a("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+v(o)+" at index "+t+"."),i}return f((function(t,o,a,i,l){for(var s=[],c=0;c<e.length;c++){var u=(0,e[c])(t,o,a,i,l,n);if(null==u)return null;u.data&&r(u.data,"expectedType")&&s.push(u.data.expectedType)}return new p("Invalid "+i+" `"+l+"` supplied to `"+a+"`"+(s.length>0?", expected one of type ["+s.join(", ")+"]":"")+".")}))},shape:function(e){return f((function(t,r,o,a,i){var l=t[r],s=y(l);if("object"!==s)return new p("Invalid "+a+" `"+i+"` of type `"+s+"` supplied to `"+o+"`, expected `object`.");for(var c in e){var u=e[c];if("function"!=typeof u)return g(o,a,i,c,b(u));var d=u(l,c,o,a,i+"."+c,n);if(d)return d}return null}))},exact:function(e){return f((function(o,a,i,l,s){var c=o[a],u=y(c);if("object"!==u)return new p("Invalid "+l+" `"+s+"` of type `"+u+"` supplied to `"+i+"`, expected `object`.");var d=t({},o[a],e);for(var m in d){var f=e[m];if(r(e,m)&&"function"!=typeof f)return g(i,l,s,m,b(f));if(!f)return new p("Invalid "+l+" `"+s+"` key `"+m+"` supplied to `"+i+"`.\nBad object: "+JSON.stringify(o[a],null," ")+"\nValid keys: "+JSON.stringify(Object.keys(e),null," "));var h=f(c,m,i,l,s+"."+m,n);if(h)return h}return null}))}};function m(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}function p(e,t){this.message=e,this.data=t&&"object"==typeof t?t:{},this.stack=""}function f(e){if("production"!==process.env.NODE_ENV)var t={},r=0;function o(o,i,l,c,d,m,f){if(c=c||u,m=m||l,f!==n){if(s){var h=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 h.name="Invariant Violation",h}if("production"!==process.env.NODE_ENV&&"undefined"!=typeof console){var g=c+":"+l;!t[g]&&r<3&&(a("You are manually calling a React.PropTypes validation function for the `"+m+"` prop on `"+c+"`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."),t[g]=!0,r++)}}return null==i[l]?o?null===i[l]?new p("The "+d+" `"+m+"` is marked as required in `"+c+"`, but its value is `null`."):new p("The "+d+" `"+m+"` is marked as required in `"+c+"`, but its value is `undefined`."):null:e(i,l,c,d,m)}var i=o.bind(null,!1);return i.isRequired=o.bind(null,!0),i}function h(e){return f((function(t,n,r,o,a,i){var l=t[n];return y(l)!==e?new p("Invalid "+o+" `"+a+"` of type `"+b(l)+"` supplied to `"+r+"`, expected `"+e+"`.",{expectedType:e}):null}))}function g(e,t,n,r,o){return new p((e||"React class")+": "+t+" type `"+n+"."+r+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+o+"`.")}function _(e){switch(typeof e){case"number":case"string":case"undefined":return!0;case"boolean":return!e;case"object":if(Array.isArray(e))return e.every(_);if(null===e||l(e))return!0;var t=function(e){var t=e&&(c&&e[c]||e["@@iterator"]);if("function"==typeof t)return t}(e);if(!t)return!1;var n,r=t.call(e);if(t!==e.entries){for(;!(n=r.next()).done;)if(!_(n.value))return!1}else for(;!(n=r.next()).done;){var o=n.value;if(o&&!_(o[1]))return!1}return!0;default:return!1}}function y(e){var t=typeof e;return Array.isArray(e)?"array":e instanceof RegExp?"object":function(e,t){return"symbol"===e||!!t&&("Symbol"===t["@@toStringTag"]||"function"==typeof Symbol&&t instanceof Symbol)}(t,e)?"symbol":t}function b(e){if(null==e)return""+e;var t=y(e);if("object"===t){if(e instanceof Date)return"date";if(e instanceof RegExp)return"regexp"}return t}function v(e){var t=b(e);switch(t){case"array":case"object":return"an "+t;case"boolean":case"date":case"regexp":return"a "+t;default:return t}}return p.prototype=Error.prototype,d.checkPropTypes=o,d.resetWarningCache=o.resetWarningCache,d.PropTypes=d,d},E}()(L.isElement,!0)}else m.exports=function(){if(F)return R;F=1;var e=I();function t(){}function n(){}return n.resetWarningCache=t,R=function(){function r(t,n,r,o,a,i){if(i!==e){var l=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw l.name="Invariant Violation",l}}function o(){return r}r.isRequired=r;var a={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:o,element:r,elementType:r,instanceOf:o,node:r,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:n,resetWarningCache:t};return a.PropTypes=a,a}}()();const O="light",A="dark",M=n(),z=({children:n})=>{const[r,o]=t(O);return e.createElement(M.Provider,{value:{theme:r,setTheme:o}},n)};z.propTypes={children:m.exports.node.isRequired};const H=()=>{const e=r(M);if(void 0===e)throw new Error("useTheme must be used within a ThemeProvider");return e};function D(e,t){void 0===t&&(t={});var n=t.insertAt;if(e&&"undefined"!=typeof document){var r=document.head||document.getElementsByTagName("head")[0],o=document.createElement("style");o.type="text/css","top"===n&&r.firstChild?r.insertBefore(o,r.firstChild):r.appendChild(o),o.styleSheet?o.styleSheet.cssText=e:o.appendChild(document.createTextNode(e))}}var U={chat:"Chat-module_chat_TkTXC",messages:"Chat-module_messages_uT8Yz",message:"Chat-module_message_jheCw",slideIn:"Chat-module_slideIn_X3q0H",messageBot:"Chat-module_messageBot_rYfoI",slideInBot:"Chat-module_slideInBot_PItdn",botMessageContent:"Chat-module_botMessageContent_OgfhN",messageHuman:"Chat-module_messageHuman_D07k6",messageForm:"Chat-module_messageForm_-4gfQ",botAvatar:"Chat-module_botAvatar_QfXcw",botAvatarLight:"Chat-module_botAvatarLight_1TqwN",botAvatarDark:"Chat-module_botAvatarDark_Szzjw",infoButtonContainer:"Chat-module_infoButtonContainer_ogUED",infoButton:"Chat-module_infoButton_xOtzm",infoButtonLight:"Chat-module_infoButtonLight_PC-sY",infoButtonDark:"Chat-module_infoButtonDark_agFbh",tooltip:"Chat-module_tooltip_nH3jI",tooltipLight:"Chat-module_tooltipLight_c5JRE",tooltipDark:"Chat-module_tooltipDark_rwN3p",inputArea:"Chat-module_inputArea_ivDlJ",input:"Chat-module_input_Exw64",inputDark:"Chat-module_inputDark_jFWz4",inputLight:"Chat-module_inputLight_xmCJW",sendButton:"Chat-module_sendButton_PUbZ-",sendButtonSending:"Chat-module_sendButtonSending_qbQvj",sendPulse:"Chat-module_sendPulse_yZQoP",sendButtonDark:"Chat-module_sendButtonDark_9gxSg",centeredContainer:"Chat-module_centeredContainer_d8tOf",watermarkLight:"Chat-module_watermarkLight_vS5lU",watermarkDark:"Chat-module_watermarkDark_1nFO5",formContainer:"Chat-module_formContainer_GZKBT",messageBotLight:"Chat-module_messageBotLight_PiMHz",messageBotDark:"Chat-module_messageBotDark_lp-hs",messageHumanLight:"Chat-module_messageHumanLight_juWm2",messageHumanDark:"Chat-module_messageHumanDark_5C4vD",messageFormLight:"Chat-module_messageFormLight_pSPBQ",messageFormDark:"Chat-module_messageFormDark_xm7kE",messagesLight:"Chat-module_messagesLight_Yye3o",messagesDark:"Chat-module_messagesDark_IWEte",submitButton:"Chat-module_submitButton_-OkwP",p:"Chat-module_p_6KdZB",li:"Chat-module_li_hqjqn",code:"Chat-module_code_UwMj0",preBlockDark:"Chat-module_preBlockDark_NKuD6",preBlockLight:"Chat-module_preBlockLight_K2TKx",chatSourceTitle:"Chat-module_chatSourceTitle_xEKTN",messageWrapper:"Chat-module_messageWrapper_P-nnd",messageWrapperUser:"Chat-module_messageWrapperUser_SlOX0",messageWrapperBot:"Chat-module_messageWrapperBot_-G4oE",messageTimestamp:"Chat-module_messageTimestamp_snFrl",botMessageActions:"Chat-module_botMessageActions_-o6b6",copyButton:"Chat-module_copyButton_S7M8C",scrollToBottomButton:"Chat-module_scrollToBottomButton_PXNA-",scrollToBottomButtonDark:"Chat-module_scrollToBottomButtonDark_KSOFP",messageSending:"Chat-module_messageSending_b1M9a",messageError:"Chat-module_messageError_BwUpC",messageStatus:"Chat-module_messageStatus_FUYD9",messageStatusSending:"Chat-module_messageStatusSending_8apKY",messageStatusError:"Chat-module_messageStatusError_09iUB",messageStatusIcon:"Chat-module_messageStatusIcon_Vqjf-",spinnerSmall:"Chat-module_spinnerSmall_FCEja",spin:"Chat-module_spin_hVmeQ",messageErrorActions:"Chat-module_messageErrorActions_i8n7a",retryButton:"Chat-module_retryButton_5BMM9",chatArea:"Chat-module_chatArea_hWhGQ",messageGrouped:"Chat-module_messageGrouped_4D0P8",messageGroupStart:"Chat-module_messageGroupStart_tBX3-",userMessageGroupMiddle:"Chat-module_userMessageGroupMiddle_Nl-gd",userMessageGroupEnd:"Chat-module_userMessageGroupEnd_QCMuZ",botMessageGroupMiddle:"Chat-module_botMessageGroupMiddle_Ph8e7",botMessageGroupEnd:"Chat-module_botMessageGroupEnd_1e1gp",copyToast:"Chat-module_copyToast_V58OG",pulse:"Chat-module_pulse_mDeN9",messageSlideInLeft:"Chat-module_messageSlideInLeft_59SPW",messageSlideInRight:"Chat-module_messageSlideInRight_nhg-b",messageFadeIn:"Chat-module_messageFadeIn_pGgul",toastFadeIn:"Chat-module_toastFadeIn_v3sgd",subtleBounce:"Chat-module_subtleBounce_VpoYh"};function j(e,t){return function(){return e.apply(t,arguments)}}D(".Chat-module_chat_TkTXC{display:flex;flex-direction:column;height:100%;overflow-y:auto;position:relative}.Chat-module_messages_uT8Yz{box-sizing:border-box;display:flex;flex-direction:column;flex-grow:1;margin:0 auto;max-width:800px;overflow-y:auto;padding:1rem;scrollbar-color:rgba(0,0,0,.2) transparent;scrollbar-width:thin;width:100%}.Chat-module_messages_uT8Yz::-webkit-scrollbar{width:6px}.Chat-module_messages_uT8Yz::-webkit-scrollbar-track{background:transparent}.Chat-module_messages_uT8Yz::-webkit-scrollbar-thumb{background-color:rgba(0,0,0,.2);border-radius:3px}.Chat-module_message_jheCw{animation:Chat-module_slideIn_X3q0H .3s ease forwards;border-radius:.6rem;box-sizing:border-box;font-family:Inter,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,sans-serif;font-size:15px;letter-spacing:.01em;line-height:1.6;max-width:70%;opacity:0;overflow-wrap:break-word;padding:.6rem .7rem;position:relative;text-align:left;transform:translateY(40px);white-space:normal;word-break:normal;p{margin:0}}.Chat-module_messageBot_rYfoI{align-self:flex-start;animation:Chat-module_slideInBot_PItdn .4s ease forwards;border-top-left-radius:0;margin-left:1.5rem;padding-left:1rem;transform:translateX(-20px)}.Chat-module_botMessageContent_OgfhN{border-left:2px solid var(--selected-color-light1);padding-left:12px;transition:transform .2s ease,border-color .2s ease}.Chat-module_botMessageContent_OgfhN:hover{transform:translateY(-.8px)}.Chat-module_messageHuman_D07k6{align-self:flex-end;border-radius:1.2rem;border-bottom-right-radius:0;box-shadow:0 2px 8px var(--selected-color-light1);font-weight:450;overflow-wrap:anywhere;transition:transform .2s ease,box-shadow .2s ease;word-break:keep-all}.Chat-module_messageHuman_D07k6:hover{box-shadow:0 4px 12px var(--selected-color-light1);transform:translateY(-1px)}.Chat-module_messageForm_-4gfQ{align-self:flex-end;border-bottom-right-radius:0;font-weight:450}.Chat-module_botAvatar_QfXcw{align-items:center;border-radius:50%;display:flex;height:24px;justify-content:center;left:-2rem;padding-bottom:2px;position:absolute;top:.3rem;width:24px}.Chat-module_botAvatarLight_1TqwN{background-color:#f0f0f0;color:#444}.Chat-module_botAvatarDark_Szzjw{background-color:#303030;color:#f2e7fe}.Chat-module_infoButtonContainer_ogUED{bottom:-25px;left:0;position:absolute}.Chat-module_infoButton_xOtzm{align-items:center;background:none;border:none;border-radius:50%;cursor:pointer;display:flex;height:24px;justify-content:center;padding:0;transition:background-color .3s ease;width:24px}.Chat-module_infoButtonLight_PC-sY svg{color:#007bff}.Chat-module_infoButtonDark_agFbh svg{color:#0056b3}.Chat-module_infoButtonLight_PC-sY:hover{background-color:rgba(0,0,0,.1)}.Chat-module_infoButtonDark_agFbh:hover{background-color:rgba(78,75,75,.582)}.Chat-module_tooltip_nH3jI{border-radius:.25rem;bottom:100%;box-shadow:0 2px 10px rgba(0,0,0,.1);font-size:.8rem;left:0;padding:.5rem;position:absolute;width:200px;z-index:10}.Chat-module_tooltipLight_c5JRE{background-color:#fff;border:1px solid #ccc;color:#000}.Chat-module_tooltipDark_rwN3p{background-color:#444;border:1px solid #555;color:#fff}.Chat-module_tooltip_nH3jI h4{margin:0 0 .5rem}.Chat-module_tooltip_nH3jI ul{margin:0;padding-left:1rem}.Chat-module_tooltip_nH3jI li{margin-bottom:.25rem}.Chat-module_tooltip_nH3jI a{color:inherit;text-decoration:none;word-break:break-all}.Chat-module_tooltip_nH3jI a:hover{text-decoration:underline}.Chat-module_inputArea_ivDlJ{display:flex;margin-bottom:2px;max-width:800px;padding:.8rem 1rem 1rem;position:relative}.Chat-module_input_Exw64{border:1px solid #ccc;border-radius:1.5rem;box-sizing:border-box;flex-grow:1;font-family:inherit;font-size:.95rem;height:44px;line-height:22px;max-height:150px;min-height:44px;outline:none;overflow-y:hidden;padding:10px 3rem 10px .75rem;resize:none;transition:border-color .2s ease,box-shadow .2s ease;vertical-align:middle}.Chat-module_input_Exw64:focus{border-color:var(--selected-color);box-shadow:0 0 0 3px var(--selected-color-light1)}.Chat-module_inputDark_jFWz4{background-color:#000a0af7;border-color:#777;color:#fff}.Chat-module_inputDark_jFWz4:focus{border-color:var(--selected-color);box-shadow:0 0 0 3px var(--selected-color-light1)}.Chat-module_inputLight_xmCJW{background-color:#fff;border-color:#ccc;color:#000}.Chat-module_inputLight_xmCJW:focus{border-color:var(--selected-color);box-shadow:0 0 0 3px var(--selected-color-light1)}.Chat-module_sendButton_PUbZ-{align-items:center;background:none;background:var(--selected-color)!important;border:none;border-radius:50%;color:#fff;cursor:pointer;display:flex;height:2rem;justify-content:center;padding-left:4px;position:absolute;right:1.5rem;top:48%;transform:translateY(-50%);transform-origin:center;transition:all .2s ease;width:2rem}.Chat-module_sendButton_PUbZ-:hover:not(:disabled){filter:brightness(1.1);transform:translateY(-50%) scale(1.08)}.Chat-module_sendButton_PUbZ-:active:not(:disabled){transform:translateY(-50%) scale(.95)}.Chat-module_sendButton_PUbZ-:disabled{cursor:not-allowed;opacity:.5}.Chat-module_sendButtonSending_qbQvj{animation:Chat-module_sendPulse_yZQoP .2s ease-out;padding-right:4px}.Chat-module_sendButtonDark_9gxSg:hover:not(:disabled){filter:brightness(1.15)}.Chat-module_centeredContainer_d8tOf{margin:0 auto;max-width:800px;width:100%}.Chat-module_watermarkLight_vS5lU{bottom:5px!important;color:#888!important;display:block!important;font-size:10px!important;opacity:.6!important;position:absolute!important;right:18px!important;transition:opacity .2s ease!important;visibility:visible!important;z-index:999999!important;a{color:#666;font-weight:500;text-decoration:none;transition:color .2s ease,text-shadow .2s ease;word-break:break-all}a:hover{color:var(--selected-color);text-shadow:0 0 8px var(--selected-color-light1)}}.Chat-module_watermarkLight_vS5lU:hover{opacity:.8!important}.Chat-module_watermarkDark_1nFO5{bottom:5px!important;color:#eee!important;display:block!important;font-size:10px!important;opacity:.6!important;position:absolute!important;right:18px!important;transition:opacity .2s ease!important;visibility:visible!important;z-index:999999!important;a{color:#fff;font-weight:500;text-decoration:none;transition:color .2s ease,text-shadow .2s ease;word-break:break-all}a:hover{color:var(--selected-color);text-shadow:0 0 8px var(--selected-color-light1)}}.Chat-module_watermarkDark_1nFO5:hover{opacity:.8!important}.Chat-module_formContainer_GZKBT{box-sizing:border-box;margin:0 auto;max-width:600px;min-width:380px;padding:1rem;width:100%}.Chat-module_messageBotLight_PiMHz{background:#fff;border:1px solid #e5e5e5;color:#000}.Chat-module_messageBotDark_lp-hs{background-color:#080f0fde;border:1px solid #262626;color:#f2e7fe}.Chat-module_messageHumanLight_juWm2{background:var(--selected-color);color:#fff}.Chat-module_messageHumanDark_5C4vD{background:var(--selected-color-light);color:#fff}.Chat-module_messageFormLight_pSPBQ{background:var(--selected-color);color:#fff}.Chat-module_messageFormDark_xm7kE{background:var(--selected-color-light);color:#fff}.Chat-module_messagesLight_Yye3o::-webkit-scrollbar-thumb{background-color:rgba(0,0,0,.2)}.Chat-module_messagesLight_Yye3o{scrollbar-color:rgba(0,0,0,.2) transparent}.Chat-module_messagesDark_IWEte::-webkit-scrollbar-thumb{background-color:hsla(0,0%,100%,.2)}.Chat-module_messagesDark_IWEte{scrollbar-color:hsla(0,0%,100%,.2) transparent}.Chat-module_submitButton_-OkwP{background:var(--selected-color);color:#fff}.Chat-module_p_6KdZB{margin:auto}.Chat-module_li_hqjqn{margin-bottom:1.2em}.Chat-module_code_UwMj0{font-family:SFMono-Regular,Consolas,Liberation Mono,Menlo,monospace;font-size:85%}.Chat-module_preBlockDark_NKuD6{background-color:#303030;border:1px solid #383838;border-radius:6px;color:#e8e8e8;padding:5px}.Chat-module_preBlockLight_K2TKx{background-color:#e5e5e5;border:1px solid #d5d5d5;border-radius:6px;color:#222;padding:5px}.Chat-module_chatSourceTitle_xEKTN{font-size:14px;font-weight:500}.Chat-module_messageWrapper_P-nnd{display:flex;flex-direction:column;margin-bottom:20px;position:relative}.Chat-module_messageWrapperUser_SlOX0{max-width:100%;width:auto}.Chat-module_messageWrapperBot_-G4oE{align-self:flex-start;max-width:95%;padding-left:.8rem;width:100%}.Chat-module_messageTimestamp_snFrl{color:#9ca3af;font-size:11px;margin-top:4px;white-space:nowrap}.Chat-module_messageWrapperUser_SlOX0 .Chat-module_messageTimestamp_snFrl{text-align:right}.Chat-module_messageWrapperBot_-G4oE .Chat-module_messageTimestamp_snFrl{text-align:left}.Chat-module_botMessageActions_-o6b6{align-items:center;display:flex;gap:8px;margin-top:8px}.Chat-module_copyButton_S7M8C{align-items:center;background:transparent;border:none;border-radius:6px;color:#9ca3af;cursor:pointer;display:flex;font-size:12px;gap:6px;padding:4px 8px;transition:color .2s ease,box-shadow .2s ease,background-color .2s ease}.Chat-module_copyButton_S7M8C:hover{background-color:var(--selected-color-light1);box-shadow:0 0 8px var(--selected-color-light1);color:var(--selected-color)}.Chat-module_copyButton_S7M8C svg{height:14px;width:14px}.Chat-module_scrollToBottomButton_PXNA-{align-items:center;background:#fff;border:1px solid #e5e7eb;border-radius:50%;bottom:16px;box-shadow:0 2px 8px rgba(0,0,0,.12);color:#6b7280;cursor:pointer;display:flex;height:28px;justify-content:center;left:50%;opacity:.85;padding:1px 0 0;position:absolute;transform:translateX(-50%);transition:all .2s ease;width:28px;z-index:10}.Chat-module_scrollToBottomButton_PXNA-:hover{border-color:var(--selected-color-light1);box-shadow:0 4px 16px var(--selected-color-light1);color:var(--selected-color);opacity:1;transform:translateX(-50%) scale(1.05)}.Chat-module_scrollToBottomButtonDark_KSOFP{background:#374151;border-color:#4b5563;color:#9ca3af}.Chat-module_scrollToBottomButtonDark_KSOFP:hover{box-shadow:0 4px 16px var(--selected-color-light1);color:var(--selected-color)}.Chat-module_scrollToBottomButton_PXNA- svg{height:14px;width:14px}.Chat-module_messageSending_b1M9a{opacity:.7}.Chat-module_messageError_BwUpC{border:2px solid #ef4444!important}.Chat-module_messageStatus_FUYD9{align-items:center;display:flex;font-size:11px;gap:4px;justify-content:flex-end;margin-top:4px}.Chat-module_messageStatusSending_8apKY{color:hsla(0,0%,100%,.7)}.Chat-module_messageStatusError_09iUB{color:#fff}.Chat-module_messageStatusIcon_Vqjf-{height:14px;width:14px}.Chat-module_spinnerSmall_FCEja{animation:Chat-module_spin_hVmeQ .8s linear infinite;border:2px solid hsla(0,0%,100%,.3);border-radius:50%;border-top-color:#fff;height:12px;width:12px}.Chat-module_messageErrorActions_i8n7a{align-items:center;color:hsla(0,0%,100%,.9);display:flex;font-size:12px;gap:8px;margin-top:8px}.Chat-module_retryButton_5BMM9{background:none;border:none;color:#fff;cursor:pointer;font-size:12px;font-weight:500;padding:0;text-decoration:underline;transition:opacity .15s ease}.Chat-module_retryButton_5BMM9:hover{opacity:.8}.Chat-module_chatArea_hWhGQ{display:flex;flex:1;flex-direction:column;overflow:hidden;position:relative}.Chat-module_messageGrouped_4D0P8{margin-top:4px}.Chat-module_messageGroupStart_tBX3-{margin-top:16px}.Chat-module_userMessageGroupMiddle_Nl-gd{border-radius:16px 4px 4px 16px}.Chat-module_userMessageGroupEnd_QCMuZ{border-radius:16px 4px 16px 16px}.Chat-module_botMessageGroupMiddle_Ph8e7{border-radius:4px 16px 16px 4px}.Chat-module_botMessageGroupEnd_1e1gp{border-radius:4px 16px 16px 16px}@keyframes Chat-module_pulse_mDeN9{0%{box-shadow:0 0 0 0 rgba(0,123,255,.4);transform:scale(1)}70%{box-shadow:0 0 0 10px rgba(0,123,255,0);transform:scale(1.05)}to{box-shadow:0 0 0 0 rgba(0,123,255,0);transform:scale(1)}}@keyframes Chat-module_slideIn_X3q0H{0%{opacity:0;transform:translateY(100px)}to{opacity:1;transform:translateY(0)}}@keyframes Chat-module_slideInBot_PItdn{0%{opacity:0;transform:translateX(-20px)}to{opacity:1;transform:translateX(0)}}@keyframes Chat-module_messageSlideInLeft_59SPW{0%{opacity:0;transform:translateX(-12px)}to{opacity:1;transform:translateX(0)}}@keyframes Chat-module_messageSlideInRight_nhg-b{0%{opacity:0;transform:translateX(12px)}to{opacity:1;transform:translateX(0)}}@keyframes Chat-module_messageFadeIn_pGgul{0%{opacity:0;transform:translateY(8px)}to{opacity:1;transform:translateY(0)}}@keyframes Chat-module_sendPulse_yZQoP{0%{transform:translateY(-50%) scale(1)}50%{transform:translateY(-50%) scale(.9)}to{transform:translateY(-50%) scale(1)}}@keyframes Chat-module_spin_hVmeQ{to{transform:rotate(1turn)}}@keyframes Chat-module_toastFadeIn_v3sgd{0%{opacity:0;transform:translateX(-50%) translateY(4px)}to{opacity:1;transform:translateX(-50%) translateY(0)}}@keyframes Chat-module_subtleBounce_VpoYh{0%,to{transform:translateX(-50%) translateY(0)}50%{transform:translateX(-50%) translateY(3px)}}@media (prefers-reduced-motion:reduce){.Chat-module_copyToast_V58OG,.Chat-module_messageBot_rYfoI,.Chat-module_messageForm_-4gfQ,.Chat-module_messageHuman_D07k6,.Chat-module_message_jheCw,.Chat-module_scrollToBottomButton_PXNA-,.Chat-module_sendButton_PUbZ-{animation-duration:.01ms!important;animation-iteration-count:1!important;transition-duration:.01ms!important}}");const{toString:V}=Object.prototype,{getPrototypeOf:W}=Object,$=(q=Object.create(null),e=>{const t=V.call(e);return q[t]||(q[t]=t.slice(8,-1).toLowerCase())});var q;const X=e=>(e=e.toLowerCase(),t=>$(t)===e),Y=e=>t=>typeof t===e,{isArray:G}=Array,Z=Y("undefined");const J=X("ArrayBuffer");const K=Y("string"),Q=Y("function"),ee=Y("number"),te=e=>null!==e&&"object"==typeof e,ne=e=>{if("object"!==$(e))return!1;const t=W(e);return!(null!==t&&t!==Object.prototype&&null!==Object.getPrototypeOf(t)||Symbol.toStringTag in e||Symbol.iterator in e)},re=X("Date"),oe=X("File"),ae=X("Blob"),ie=X("FileList"),le=X("URLSearchParams"),[se,ce,ue,de]=["ReadableStream","Request","Response","Headers"].map(X);function me(e,t,{allOwnKeys:n=!1}={}){if(null==e)return;let r,o;if("object"!=typeof e&&(e=[e]),G(e))for(r=0,o=e.length;r<o;r++)t.call(null,e[r],r,e);else{const o=n?Object.getOwnPropertyNames(e):Object.keys(e),a=o.length;let i;for(r=0;r<a;r++)i=o[r],t.call(null,e[i],i,e)}}function pe(e,t){t=t.toLowerCase();const n=Object.keys(e);let r,o=n.length;for(;o-- >0;)if(r=n[o],t===r.toLowerCase())return r;return null}const fe="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:global,he=e=>!Z(e)&&e!==fe;const ge=(_e="undefined"!=typeof Uint8Array&&W(Uint8Array),e=>_e&&e instanceof _e);var _e;const ye=X("HTMLFormElement"),be=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),ve=X("RegExp"),xe=(e,t)=>{const n=Object.getOwnPropertyDescriptors(e),r={};me(n,((n,o)=>{let a;!1!==(a=t(n,o,e))&&(r[o]=a||n)})),Object.defineProperties(e,r)},ke="abcdefghijklmnopqrstuvwxyz",we="0123456789",Ce={DIGIT:we,ALPHA:ke,ALPHA_DIGIT:ke+ke.toUpperCase()+we};const Ee=X("AsyncFunction"),Se=(Re="function"==typeof setImmediate,Fe=Q(fe.postMessage),Re?setImmediate:Fe?(Pe=`axios@${Math.random()}`,Te=[],fe.addEventListener("message",(({source:e,data:t})=>{e===fe&&t===Pe&&Te.length&&Te.shift()()}),!1),e=>{Te.push(e),fe.postMessage(Pe,"*")}):e=>setTimeout(e));var Re,Fe,Pe,Te;const Be="undefined"!=typeof queueMicrotask?queueMicrotask.bind(fe):"undefined"!=typeof process&&process.nextTick||Se;var Ie={isArray:G,isArrayBuffer:J,isBuffer:function(e){return null!==e&&!Z(e)&&null!==e.constructor&&!Z(e.constructor)&&Q(e.constructor.isBuffer)&&e.constructor.isBuffer(e)},isFormData:e=>{let t;return e&&("function"==typeof FormData&&e instanceof FormData||Q(e.append)&&("formdata"===(t=$(e))||"object"===t&&Q(e.toString)&&"[object FormData]"===e.toString()))},isArrayBufferView:function(e){let t;return t="undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(e):e&&e.buffer&&J(e.buffer),t},isString:K,isNumber:ee,isBoolean:e=>!0===e||!1===e,isObject:te,isPlainObject:ne,isReadableStream:se,isRequest:ce,isResponse:ue,isHeaders:de,isUndefined:Z,isDate:re,isFile:oe,isBlob:ae,isRegExp:ve,isFunction:Q,isStream:e=>te(e)&&Q(e.pipe),isURLSearchParams:le,isTypedArray:ge,isFileList:ie,forEach:me,merge:function e(){const{caseless:t}=he(this)&&this||{},n={},r=(r,o)=>{const a=t&&pe(n,o)||o;ne(n[a])&&ne(r)?n[a]=e(n[a],r):ne(r)?n[a]=e({},r):G(r)?n[a]=r.slice():n[a]=r};for(let e=0,t=arguments.length;e<t;e++)arguments[e]&&me(arguments[e],r);return n},extend:(e,t,n,{allOwnKeys:r}={})=>(me(t,((t,r)=>{n&&Q(t)?e[r]=j(t,n):e[r]=t}),{allOwnKeys:r}),e),trim:e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,""),stripBOM:e=>(65279===e.charCodeAt(0)&&(e=e.slice(1)),e),inherits:(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)},toFlatObject:(e,t,n,r)=>{let o,a,i;const l={};if(t=t||{},null==e)return t;do{for(o=Object.getOwnPropertyNames(e),a=o.length;a-- >0;)i=o[a],r&&!r(i,e,t)||l[i]||(t[i]=e[i],l[i]=!0);e=!1!==n&&W(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},kindOf:$,kindOfTest:X,endsWith:(e,t,n)=>{e=String(e),(void 0===n||n>e.length)&&(n=e.length),n-=t.length;const r=e.indexOf(t,n);return-1!==r&&r===n},toArray:e=>{if(!e)return null;if(G(e))return e;let t=e.length;if(!ee(t))return null;const n=new Array(t);for(;t-- >0;)n[t]=e[t];return n},forEachEntry:(e,t)=>{const n=(e&&e[Symbol.iterator]).call(e);let r;for(;(r=n.next())&&!r.done;){const n=r.value;t.call(e,n[0],n[1])}},matchAll:(e,t)=>{let n;const r=[];for(;null!==(n=e.exec(t));)r.push(n);return r},isHTMLForm:ye,hasOwnProperty:be,hasOwnProp:be,reduceDescriptors:xe,freezeMethods:e=>{xe(e,((t,n)=>{if(Q(e)&&-1!==["arguments","caller","callee"].indexOf(n))return!1;const r=e[n];Q(r)&&(t.enumerable=!1,"writable"in t?t.writable=!1:t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+n+"'")}))}))},toObjectSet:(e,t)=>{const n={},r=e=>{e.forEach((e=>{n[e]=!0}))};return G(e)?r(e):r(String(e).split(t)),n},toCamelCase:e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,(function(e,t,n){return t.toUpperCase()+n})),noop:()=>{},toFiniteNumber:(e,t)=>null!=e&&Number.isFinite(e=+e)?e:t,findKey:pe,global:fe,isContextDefined:he,ALPHABET:Ce,generateString:(e=16,t=Ce.ALPHA_DIGIT)=>{let n="";const{length:r}=t;for(;e--;)n+=t[Math.random()*r|0];return n},isSpecCompliantForm:function(e){return!!(e&&Q(e.append)&&"FormData"===e[Symbol.toStringTag]&&e[Symbol.iterator])},toJSONObject:e=>{const t=new Array(10),n=(e,r)=>{if(te(e)){if(t.indexOf(e)>=0)return;if(!("toJSON"in e)){t[r]=e;const o=G(e)?[]:{};return me(e,((e,t)=>{const a=n(e,r+1);!Z(a)&&(o[t]=a)})),t[r]=void 0,o}}return e};return n(e,0)},isAsyncFn:Ee,isThenable:e=>e&&(te(e)||Q(e))&&Q(e.then)&&Q(e.catch),setImmediate:Se,asap:Be};function Ne(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,this.status=o.status?o.status:null)}Ie.inherits(Ne,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:Ie.toJSONObject(this.config),code:this.code,status:this.status}}});const Le=Ne.prototype,Oe={};["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=>{Oe[e]={value:e}})),Object.defineProperties(Ne,Oe),Object.defineProperty(Le,"isAxiosError",{value:!0}),Ne.from=(e,t,n,r,o,a)=>{const i=Object.create(Le);return Ie.toFlatObject(e,i,(function(e){return e!==Error.prototype}),(e=>"isAxiosError"!==e)),Ne.call(i,e.message,t,n,r,o),i.cause=e,i.name=e.name,a&&Object.assign(i,a),i};function Ae(e){return Ie.isPlainObject(e)||Ie.isArray(e)}function Me(e){return Ie.endsWith(e,"[]")?e.slice(0,-2):e}function ze(e,t,n){return e?e.concat(t).map((function(e,t){return e=Me(e),!n&&t?"["+e+"]":e})).join(n?".":""):t}const He=Ie.toFlatObject(Ie,{},null,(function(e){return/^is[A-Z]/.test(e)}));function De(e,t,n){if(!Ie.isObject(e))throw new TypeError("target must be an object");t=t||new FormData;const r=(n=Ie.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,(function(e,t){return!Ie.isUndefined(t[e])}))).metaTokens,o=n.visitor||c,a=n.dots,i=n.indexes,l=(n.Blob||"undefined"!=typeof Blob&&Blob)&&Ie.isSpecCompliantForm(t);if(!Ie.isFunction(o))throw new TypeError("visitor must be a function");function s(e){if(null===e)return"";if(Ie.isDate(e))return e.toISOString();if(!l&&Ie.isBlob(e))throw new Ne("Blob is not supported. Use a Buffer instead.");return Ie.isArrayBuffer(e)||Ie.isTypedArray(e)?l&&"function"==typeof Blob?new Blob([e]):Buffer.from(e):e}function c(e,n,o){let l=e;if(e&&!o&&"object"==typeof e)if(Ie.endsWith(n,"{}"))n=r?n:n.slice(0,-2),e=JSON.stringify(e);else if(Ie.isArray(e)&&function(e){return Ie.isArray(e)&&!e.some(Ae)}(e)||(Ie.isFileList(e)||Ie.endsWith(n,"[]"))&&(l=Ie.toArray(e)))return n=Me(n),l.forEach((function(e,r){!Ie.isUndefined(e)&&null!==e&&t.append(!0===i?ze([n],r,a):null===i?n:n+"[]",s(e))})),!1;return!!Ae(e)||(t.append(ze(o,n,a),s(e)),!1)}const u=[],d=Object.assign(He,{defaultVisitor:c,convertValue:s,isVisitable:Ae});if(!Ie.isObject(e))throw new TypeError("data must be an object");return function e(n,r){if(!Ie.isUndefined(n)){if(-1!==u.indexOf(n))throw Error("Circular reference detected in "+r.join("."));u.push(n),Ie.forEach(n,(function(n,a){!0===(!(Ie.isUndefined(n)||null===n)&&o.call(t,n,Ie.isString(a)?a.trim():a,r,d))&&e(n,r?r.concat(a):[a])})),u.pop()}}(e),t}function Ue(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,(function(e){return t[e]}))}function je(e,t){this._pairs=[],e&&De(e,this,t)}const Ve=je.prototype;function We(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function $e(e,t,n){if(!t)return e;const r=n&&n.encode||We;Ie.isFunction(n)&&(n={serialize:n});const o=n&&n.serialize;let a;if(a=o?o(t,n):Ie.isURLSearchParams(t)?t.toString():new je(t,n).toString(r),a){const t=e.indexOf("#");-1!==t&&(e=e.slice(0,t)),e+=(-1===e.indexOf("?")?"?":"&")+a}return e}Ve.append=function(e,t){this._pairs.push([e,t])},Ve.toString=function(e){const t=e?function(t){return e.call(this,t,Ue)}:Ue;return this._pairs.map((function(e){return t(e[0])+"="+t(e[1])}),"").join("&")};class qe{constructor(){this.handlers=[]}use(e,t,n){return this.handlers.push({fulfilled:e,rejected:t,synchronous:!!n&&n.synchronous,runWhen:n?n.runWhen:null}),this.handlers.length-1}eject(e){this.handlers[e]&&(this.handlers[e]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(e){Ie.forEach(this.handlers,(function(t){null!==t&&e(t)}))}}var Xe={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},Ye={isBrowser:!0,classes:{URLSearchParams:"undefined"!=typeof URLSearchParams?URLSearchParams:je,FormData:"undefined"!=typeof FormData?FormData:null,Blob:"undefined"!=typeof Blob?Blob:null},protocols:["http","https","file","blob","url","data"]};const Ge="undefined"!=typeof window&&"undefined"!=typeof document,Ze="object"==typeof navigator&&navigator||void 0,Je=Ge&&(!Ze||["ReactNative","NativeScript","NS"].indexOf(Ze.product)<0),Ke="undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope&&"function"==typeof self.importScripts,Qe=Ge&&window.location.href||"http://localhost";var et={...Object.freeze({__proto__:null,hasBrowserEnv:Ge,hasStandardBrowserWebWorkerEnv:Ke,hasStandardBrowserEnv:Je,navigator:Ze,origin:Qe}),...Ye};function tt(e){function t(e,n,r,o){let a=e[o++];if("__proto__"===a)return!0;const i=Number.isFinite(+a),l=o>=e.length;if(a=!a&&Ie.isArray(r)?r.length:a,l)return Ie.hasOwnProp(r,a)?r[a]=[r[a],n]:r[a]=n,!i;r[a]&&Ie.isObject(r[a])||(r[a]=[]);return t(e,n,r[a],o)&&Ie.isArray(r[a])&&(r[a]=function(e){const t={},n=Object.keys(e);let r;const o=n.length;let a;for(r=0;r<o;r++)a=n[r],t[a]=e[a];return t}(r[a])),!i}if(Ie.isFormData(e)&&Ie.isFunction(e.entries)){const n={};return Ie.forEachEntry(e,((e,r)=>{t(function(e){return Ie.matchAll(/\w+|\[(\w*)]/g,e).map((e=>"[]"===e[0]?"":e[1]||e[0]))}(e),r,n,0)})),n}return null}const nt={transitional:Xe,adapter:["xhr","http","fetch"],transformRequest:[function(e,t){const n=t.getContentType()||"",r=n.indexOf("application/json")>-1,o=Ie.isObject(e);o&&Ie.isHTMLForm(e)&&(e=new FormData(e));if(Ie.isFormData(e))return r?JSON.stringify(tt(e)):e;if(Ie.isArrayBuffer(e)||Ie.isBuffer(e)||Ie.isStream(e)||Ie.isFile(e)||Ie.isBlob(e)||Ie.isReadableStream(e))return e;if(Ie.isArrayBufferView(e))return e.buffer;if(Ie.isURLSearchParams(e))return t.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();let a;if(o){if(n.indexOf("application/x-www-form-urlencoded")>-1)return function(e,t){return De(e,new et.classes.URLSearchParams,Object.assign({visitor:function(e,t,n,r){return et.isNode&&Ie.isBuffer(e)?(this.append(t,e.toString("base64")),!1):r.defaultVisitor.apply(this,arguments)}},t))}(e,this.formSerializer).toString();if((a=Ie.isFileList(e))||n.indexOf("multipart/form-data")>-1){const t=this.env&&this.env.FormData;return De(a?{"files[]":e}:e,t&&new t,this.formSerializer)}}return o||r?(t.setContentType("application/json",!1),function(e,t,n){if(Ie.isString(e))try{return(t||JSON.parse)(e),Ie.trim(e)}catch(e){if("SyntaxError"!==e.name)throw e}return(n||JSON.stringify)(e)}(e)):e}],transformResponse:[function(e){const t=this.transitional||nt.transitional,n=t&&t.forcedJSONParsing,r="json"===this.responseType;if(Ie.isResponse(e)||Ie.isReadableStream(e))return e;if(e&&Ie.isString(e)&&(n&&!this.responseType||r)){const n=!(t&&t.silentJSONParsing)&&r;try{return JSON.parse(e)}catch(e){if(n){if("SyntaxError"===e.name)throw Ne.from(e,Ne.ERR_BAD_RESPONSE,this,null,this.response);throw e}}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:et.classes.FormData,Blob:et.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};Ie.forEach(["delete","get","head","post","put","patch"],(e=>{nt.headers[e]={}}));const rt=Ie.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"]);const ot=Symbol("internals");function at(e){return e&&String(e).trim().toLowerCase()}function it(e){return!1===e||null==e?e:Ie.isArray(e)?e.map(it):String(e)}function lt(e,t,n,r,o){return Ie.isFunction(r)?r.call(this,t,n):(o&&(t=n),Ie.isString(t)?Ie.isString(r)?-1!==t.indexOf(r):Ie.isRegExp(r)?r.test(t):void 0:void 0)}class st{constructor(e){e&&this.set(e)}set(e,t,n){const r=this;function o(e,t,n){const o=at(t);if(!o)throw new Error("header name must be a non-empty string");const a=Ie.findKey(r,o);(!a||void 0===r[a]||!0===n||void 0===n&&!1!==r[a])&&(r[a||t]=it(e))}const a=(e,t)=>Ie.forEach(e,((e,n)=>o(e,n,t)));if(Ie.isPlainObject(e)||e instanceof this.constructor)a(e,t);else if(Ie.isString(e)&&(e=e.trim())&&!/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim()))a((e=>{const t={};let n,r,o;return e&&e.split("\n").forEach((function(e){o=e.indexOf(":"),n=e.substring(0,o).trim().toLowerCase(),r=e.substring(o+1).trim(),!n||t[n]&&rt[n]||("set-cookie"===n?t[n]?t[n].push(r):t[n]=[r]:t[n]=t[n]?t[n]+", "+r:r)})),t})(e),t);else if(Ie.isHeaders(e))for(const[t,r]of e.entries())o(r,t,n);else null!=e&&o(t,e,n);return this}get(e,t){if(e=at(e)){const n=Ie.findKey(this,e);if(n){const e=this[n];if(!t)return e;if(!0===t)return function(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}(e);if(Ie.isFunction(t))return t.call(this,e,n);if(Ie.isRegExp(t))return t.exec(e);throw new TypeError("parser must be boolean|regexp|function")}}}has(e,t){if(e=at(e)){const n=Ie.findKey(this,e);return!(!n||void 0===this[n]||t&&!lt(0,this[n],n,t))}return!1}delete(e,t){const n=this;let r=!1;function o(e){if(e=at(e)){const o=Ie.findKey(n,e);!o||t&&!lt(0,n[o],o,t)||(delete n[o],r=!0)}}return Ie.isArray(e)?e.forEach(o):o(e),r}clear(e){const t=Object.keys(this);let n=t.length,r=!1;for(;n--;){const o=t[n];e&&!lt(0,this[o],o,e,!0)||(delete this[o],r=!0)}return r}normalize(e){const t=this,n={};return Ie.forEach(this,((r,o)=>{const a=Ie.findKey(n,o);if(a)return t[a]=it(r),void delete t[o];const i=e?function(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,((e,t,n)=>t.toUpperCase()+n))}(o):String(o).trim();i!==o&&delete t[o],t[i]=it(r),n[i]=!0})),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){const t=Object.create(null);return Ie.forEach(this,((n,r)=>{null!=n&&!1!==n&&(t[r]=e&&Ie.isArray(n)?n.join(", "):n)})),t}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map((([e,t])=>e+": "+t)).join("\n")}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(e){return e instanceof this?e:new this(e)}static concat(e,...t){const n=new this(e);return t.forEach((e=>n.set(e))),n}static accessor(e){const t=(this[ot]=this[ot]={accessors:{}}).accessors,n=this.prototype;function r(e){const r=at(e);t[r]||(!function(e,t){const n=Ie.toCamelCase(" "+t);["get","set","has"].forEach((r=>{Object.defineProperty(e,r+n,{value:function(e,n,o){return this[r].call(this,t,e,n,o)},configurable:!0})}))}(n,e),t[r]=!0)}return Ie.isArray(e)?e.forEach(r):r(e),this}}function ct(e,t){const n=this||nt,r=t||n,o=st.from(r.headers);let a=r.data;return Ie.forEach(e,(function(e){a=e.call(n,a,o.normalize(),t?t.status:void 0)})),o.normalize(),a}function ut(e){return!(!e||!e.__CANCEL__)}function dt(e,t,n){Ne.call(this,null==e?"canceled":e,Ne.ERR_CANCELED,t,n),this.name="CanceledError"}function mt(e,t,n){const r=n.config.validateStatus;n.status&&r&&!r(n.status)?t(new Ne("Request failed with status code "+n.status,[Ne.ERR_BAD_REQUEST,Ne.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n)):e(n)}st.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),Ie.reduceDescriptors(st.prototype,(({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(e){this[n]=e}}})),Ie.freezeMethods(st),Ie.inherits(dt,Ne,{__CANCEL__:!0});const pt=(e,t,n=3)=>{let r=0;const o=function(e,t){e=e||10;const n=new Array(e),r=new Array(e);let o,a=0,i=0;return t=void 0!==t?t:1e3,function(l){const s=Date.now(),c=r[i];o||(o=s),n[a]=l,r[a]=s;let u=i,d=0;for(;u!==a;)d+=n[u++],u%=e;if(a=(a+1)%e,a===i&&(i=(i+1)%e),s-o<t)return;const m=c&&s-c;return m?Math.round(1e3*d/m):void 0}}(50,250);return function(e,t){let n,r,o=0,a=1e3/t;const i=(t,a=Date.now())=>{o=a,n=null,r&&(clearTimeout(r),r=null),e.apply(null,t)};return[(...e)=>{const t=Date.now(),l=t-o;l>=a?i(e,t):(n=e,r||(r=setTimeout((()=>{r=null,i(n)}),a-l)))},()=>n&&i(n)]}((n=>{const a=n.loaded,i=n.lengthComputable?n.total:void 0,l=a-r,s=o(l);r=a;e({loaded:a,total:i,progress:i?a/i:void 0,bytes:l,rate:s||void 0,estimated:s&&i&&a<=i?(i-a)/s:void 0,event:n,lengthComputable:null!=i,[t?"download":"upload"]:!0})}),n)},ft=(e,t)=>{const n=null!=e;return[r=>t[0]({lengthComputable:n,total:e,loaded:r}),t[1]]},ht=e=>(...t)=>Ie.asap((()=>e(...t)));var gt=et.hasStandardBrowserEnv?((e,t)=>n=>(n=new URL(n,et.origin),e.protocol===n.protocol&&e.host===n.host&&(t||e.port===n.port)))(new URL(et.origin),et.navigator&&/(msie|trident)/i.test(et.navigator.userAgent)):()=>!0,_t=et.hasStandardBrowserEnv?{write(e,t,n,r,o,a){const i=[e+"="+encodeURIComponent(t)];Ie.isNumber(n)&&i.push("expires="+new Date(n).toGMTString()),Ie.isString(r)&&i.push("path="+r),Ie.isString(o)&&i.push("domain="+o),!0===a&&i.push("secure"),document.cookie=i.join("; ")},read(e){const t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove(e){this.write(e,"",Date.now()-864e5)}}:{write(){},read:()=>null,remove(){}};function yt(e,t){return e&&!/^([a-z][a-z\d+\-.]*:)?\/\//i.test(t)?function(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}(e,t):t}const bt=e=>e instanceof st?{...e}:e;function vt(e,t){t=t||{};const n={};function r(e,t,n,r){return Ie.isPlainObject(e)&&Ie.isPlainObject(t)?Ie.merge.call({caseless:r},e,t):Ie.isPlainObject(t)?Ie.merge({},t):Ie.isArray(t)?t.slice():t}function o(e,t,n,o){return Ie.isUndefined(t)?Ie.isUndefined(e)?void 0:r(void 0,e,0,o):r(e,t,0,o)}function a(e,t){if(!Ie.isUndefined(t))return r(void 0,t)}function i(e,t){return Ie.isUndefined(t)?Ie.isUndefined(e)?void 0:r(void 0,e):r(void 0,t)}function l(n,o,a){return a in t?r(n,o):a in e?r(void 0,n):void 0}const s={url:a,method:a,data:a,baseURL:i,transformRequest:i,transformResponse:i,paramsSerializer:i,timeout:i,timeoutMessage:i,withCredentials:i,withXSRFToken:i,adapter:i,responseType:i,xsrfCookieName:i,xsrfHeaderName:i,onUploadProgress:i,onDownloadProgress:i,decompress:i,maxContentLength:i,maxBodyLength:i,beforeRedirect:i,transport:i,httpAgent:i,httpsAgent:i,cancelToken:i,socketPath:i,responseEncoding:i,validateStatus:l,headers:(e,t,n)=>o(bt(e),bt(t),0,!0)};return Ie.forEach(Object.keys(Object.assign({},e,t)),(function(r){const a=s[r]||o,i=a(e[r],t[r],r);Ie.isUndefined(i)&&a!==l||(n[r]=i)})),n}var xt=e=>{const t=vt({},e);let n,{data:r,withXSRFToken:o,xsrfHeaderName:a,xsrfCookieName:i,headers:l,auth:s}=t;if(t.headers=l=st.from(l),t.url=$e(yt(t.baseURL,t.url),e.params,e.paramsSerializer),s&&l.set("Authorization","Basic "+btoa((s.username||"")+":"+(s.password?unescape(encodeURIComponent(s.password)):""))),Ie.isFormData(r))if(et.hasStandardBrowserEnv||et.hasStandardBrowserWebWorkerEnv)l.setContentType(void 0);else if(!1!==(n=l.getContentType())){const[e,...t]=n?n.split(";").map((e=>e.trim())).filter(Boolean):[];l.setContentType([e||"multipart/form-data",...t].join("; "))}if(et.hasStandardBrowserEnv&&(o&&Ie.isFunction(o)&&(o=o(t)),o||!1!==o&&gt(t.url))){const e=a&&i&&_t.read(i);e&&l.set(a,e)}return t};var kt="undefined"!=typeof XMLHttpRequest&&function(e){return new Promise((function(t,n){const r=xt(e);let o=r.data;const a=st.from(r.headers).normalize();let i,l,s,c,u,{responseType:d,onUploadProgress:m,onDownloadProgress:p}=r;function f(){c&&c(),u&&u(),r.cancelToken&&r.cancelToken.unsubscribe(i),r.signal&&r.signal.removeEventListener("abort",i)}let h=new XMLHttpRequest;function g(){if(!h)return;const r=st.from("getAllResponseHeaders"in h&&h.getAllResponseHeaders());mt((function(e){t(e),f()}),(function(e){n(e),f()}),{data:d&&"text"!==d&&"json"!==d?h.response:h.responseText,status:h.status,statusText:h.statusText,headers:r,config:e,request:h}),h=null}h.open(r.method.toUpperCase(),r.url,!0),h.timeout=r.timeout,"onloadend"in h?h.onloadend=g:h.onreadystatechange=function(){h&&4===h.readyState&&(0!==h.status||h.responseURL&&0===h.responseURL.indexOf("file:"))&&setTimeout(g)},h.onabort=function(){h&&(n(new Ne("Request aborted",Ne.ECONNABORTED,e,h)),h=null)},h.onerror=function(){n(new Ne("Network Error",Ne.ERR_NETWORK,e,h)),h=null},h.ontimeout=function(){let t=r.timeout?"timeout of "+r.timeout+"ms exceeded":"timeout exceeded";const o=r.transitional||Xe;r.timeoutErrorMessage&&(t=r.timeoutErrorMessage),n(new Ne(t,o.clarifyTimeoutError?Ne.ETIMEDOUT:Ne.ECONNABORTED,e,h)),h=null},void 0===o&&a.setContentType(null),"setRequestHeader"in h&&Ie.forEach(a.toJSON(),(function(e,t){h.setRequestHeader(t,e)})),Ie.isUndefined(r.withCredentials)||(h.withCredentials=!!r.withCredentials),d&&"json"!==d&&(h.responseType=r.responseType),p&&([s,u]=pt(p,!0),h.addEventListener("progress",s)),m&&h.upload&&([l,c]=pt(m),h.upload.addEventListener("progress",l),h.upload.addEventListener("loadend",c)),(r.cancelToken||r.signal)&&(i=t=>{h&&(n(!t||t.type?new dt(null,e,h):t),h.abort(),h=null)},r.cancelToken&&r.cancelToken.subscribe(i),r.signal&&(r.signal.aborted?i():r.signal.addEventListener("abort",i)));const _=function(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}(r.url);_&&-1===et.protocols.indexOf(_)?n(new Ne("Unsupported protocol "+_+":",Ne.ERR_BAD_REQUEST,e)):h.send(o||null)}))};const wt=(e,t)=>{const{length:n}=e=e?e.filter(Boolean):[];if(t||n){let n,r=new AbortController;const o=function(e){if(!n){n=!0,i();const t=e instanceof Error?e:this.reason;r.abort(t instanceof Ne?t:new dt(t instanceof Error?t.message:t))}};let a=t&&setTimeout((()=>{a=null,o(new Ne(`timeout ${t} of ms exceeded`,Ne.ETIMEDOUT))}),t);const i=()=>{e&&(a&&clearTimeout(a),a=null,e.forEach((e=>{e.unsubscribe?e.unsubscribe(o):e.removeEventListener("abort",o)})),e=null)};e.forEach((e=>e.addEventListener("abort",o)));const{signal:l}=r;return l.unsubscribe=()=>Ie.asap(i),l}},Ct=function*(e,t){let n=e.byteLength;if(!t||n<t)return void(yield e);let r,o=0;for(;o<n;)r=o+t,yield e.slice(o,r),o=r},Et=async function*(e){if(e[Symbol.asyncIterator])return void(yield*e);const t=e.getReader();try{for(;;){const{done:e,value:n}=await t.read();if(e)break;yield n}}finally{await t.cancel()}},St=(e,t,n,r)=>{const o=async function*(e,t){for await(const n of Et(e))yield*Ct(n,t)}(e,t);let a,i=0,l=e=>{a||(a=!0,r&&r(e))};return new ReadableStream({async pull(e){try{const{done:t,value:r}=await o.next();if(t)return l(),void e.close();let a=r.byteLength;if(n){let e=i+=a;n(e)}e.enqueue(new Uint8Array(r))}catch(e){throw l(e),e}},cancel:e=>(l(e),o.return())},{highWaterMark:2})},Rt="function"==typeof fetch&&"function"==typeof Request&&"function"==typeof Response,Ft=Rt&&"function"==typeof ReadableStream,Pt=Rt&&("function"==typeof TextEncoder?(Tt=new TextEncoder,e=>Tt.encode(e)):async e=>new Uint8Array(await new Response(e).arrayBuffer()));var Tt;const Bt=(e,...t)=>{try{return!!e(...t)}catch(e){return!1}},It=Ft&&Bt((()=>{let e=!1;const t=new Request(et.origin,{body:new ReadableStream,method:"POST",get duplex(){return e=!0,"half"}}).headers.has("Content-Type");return e&&!t})),Nt=Ft&&Bt((()=>Ie.isReadableStream(new Response("").body))),Lt={stream:Nt&&(e=>e.body)};var Ot;Rt&&(Ot=new Response,["text","arrayBuffer","blob","formData","stream"].forEach((e=>{!Lt[e]&&(Lt[e]=Ie.isFunction(Ot[e])?t=>t[e]():(t,n)=>{throw new Ne(`Response type '${e}' is not supported`,Ne.ERR_NOT_SUPPORT,n)})})));const At=async(e,t)=>{const n=Ie.toFiniteNumber(e.getContentLength());return null==n?(async e=>{if(null==e)return 0;if(Ie.isBlob(e))return e.size;if(Ie.isSpecCompliantForm(e)){const t=new Request(et.origin,{method:"POST",body:e});return(await t.arrayBuffer()).byteLength}return Ie.isArrayBufferView(e)||Ie.isArrayBuffer(e)?e.byteLength:(Ie.isURLSearchParams(e)&&(e+=""),Ie.isString(e)?(await Pt(e)).byteLength:void 0)})(t):n};const Mt={http:null,xhr:kt,fetch:Rt&&(async e=>{let{url:t,method:n,data:r,signal:o,cancelToken:a,timeout:i,onDownloadProgress:l,onUploadProgress:s,responseType:c,headers:u,withCredentials:d="same-origin",fetchOptions:m}=xt(e);c=c?(c+"").toLowerCase():"text";let p,f=wt([o,a&&a.toAbortSignal()],i);const h=f&&f.unsubscribe&&(()=>{f.unsubscribe()});let g;try{if(s&&It&&"get"!==n&&"head"!==n&&0!==(g=await At(u,r))){let e,n=new Request(t,{method:"POST",body:r,duplex:"half"});if(Ie.isFormData(r)&&(e=n.headers.get("content-type"))&&u.setContentType(e),n.body){const[e,t]=ft(g,pt(ht(s)));r=St(n.body,65536,e,t)}}Ie.isString(d)||(d=d?"include":"omit");const o="credentials"in Request.prototype;p=new Request(t,{...m,signal:f,method:n.toUpperCase(),headers:u.normalize().toJSON(),body:r,duplex:"half",credentials:o?d:void 0});let a=await fetch(p);const i=Nt&&("stream"===c||"response"===c);if(Nt&&(l||i&&h)){const e={};["status","statusText","headers"].forEach((t=>{e[t]=a[t]}));const t=Ie.toFiniteNumber(a.headers.get("content-length")),[n,r]=l&&ft(t,pt(ht(l),!0))||[];a=new Response(St(a.body,65536,n,(()=>{r&&r(),h&&h()})),e)}c=c||"text";let _=await Lt[Ie.findKey(Lt,c)||"text"](a,e);return!i&&h&&h(),await new Promise(((t,n)=>{mt(t,n,{data:_,headers:st.from(a.headers),status:a.status,statusText:a.statusText,config:e,request:p})}))}catch(t){if(h&&h(),t&&"TypeError"===t.name&&/fetch/i.test(t.message))throw Object.assign(new Ne("Network Error",Ne.ERR_NETWORK,e,p),{cause:t.cause||t});throw Ne.from(t,t&&t.code,e,p)}})};Ie.forEach(Mt,((e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch(e){}Object.defineProperty(e,"adapterName",{value:t})}}));const zt=e=>`- ${e}`,Ht=e=>Ie.isFunction(e)||null===e||!1===e;var Dt=e=>{e=Ie.isArray(e)?e:[e];const{length:t}=e;let n,r;const o={};for(let a=0;a<t;a++){let t;if(n=e[a],r=n,!Ht(n)&&(r=Mt[(t=String(n)).toLowerCase()],void 0===r))throw new Ne(`Unknown adapter '${t}'`);if(r)break;o[t||"#"+a]=r}if(!r){const e=Object.entries(o).map((([e,t])=>`adapter ${e} `+(!1===t?"is not supported by the environment":"is not available in the build")));throw new Ne("There is no suitable adapter to dispatch the request "+(t?e.length>1?"since :\n"+e.map(zt).join("\n"):" "+zt(e[0]):"as no adapter specified"),"ERR_NOT_SUPPORT")}return r};function Ut(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new dt(null,e)}function jt(e){Ut(e),e.headers=st.from(e.headers),e.data=ct.call(e,e.transformRequest),-1!==["post","put","patch"].indexOf(e.method)&&e.headers.setContentType("application/x-www-form-urlencoded",!1);return Dt(e.adapter||nt.adapter)(e).then((function(t){return Ut(e),t.data=ct.call(e,e.transformResponse,t),t.headers=st.from(t.headers),t}),(function(t){return ut(t)||(Ut(e),t&&t.response&&(t.response.data=ct.call(e,e.transformResponse,t.response),t.response.headers=st.from(t.response.headers))),Promise.reject(t)}))}const Vt="1.7.8",Wt={};["object","boolean","number","function","string","symbol"].forEach(((e,t)=>{Wt[e]=function(n){return typeof n===e||"a"+(t<1?"n ":" ")+e}}));const $t={};Wt.transitional=function(e,t,n){function r(e,t){return"[Axios v1.7.8] Transitional option '"+e+"'"+t+(n?". "+n:"")}return(n,o,a)=>{if(!1===e)throw new Ne(r(o," has been removed"+(t?" in "+t:"")),Ne.ERR_DEPRECATED);return t&&!$t[o]&&($t[o]=!0,console.warn(r(o," has been deprecated since v"+t+" and will be removed in the near future"))),!e||e(n,o,a)}},Wt.spelling=function(e){return(t,n)=>(console.warn(`${n} is likely a misspelling of ${e}`),!0)};var qt={assertOptions:function(e,t,n){if("object"!=typeof e)throw new Ne("options must be an object",Ne.ERR_BAD_OPTION_VALUE);const r=Object.keys(e);let o=r.length;for(;o-- >0;){const a=r[o],i=t[a];if(i){const t=e[a],n=void 0===t||i(t,a,e);if(!0!==n)throw new Ne("option "+a+" must be "+n,Ne.ERR_BAD_OPTION_VALUE)}else if(!0!==n)throw new Ne("Unknown option "+a,Ne.ERR_BAD_OPTION)}},validators:Wt};const Xt=qt.validators;class Yt{constructor(e){this.defaults=e,this.interceptors={request:new qe,response:new qe}}async request(e,t){try{return await this._request(e,t)}catch(e){if(e instanceof Error){let t={};Error.captureStackTrace?Error.captureStackTrace(t):t=new Error;const n=t.stack?t.stack.replace(/^.+\n/,""):"";try{e.stack?n&&!String(e.stack).endsWith(n.replace(/^.+\n.+\n/,""))&&(e.stack+="\n"+n):e.stack=n}catch(e){}}throw e}}_request(e,t){"string"==typeof e?(t=t||{}).url=e:t=e||{},t=vt(this.defaults,t);const{transitional:n,paramsSerializer:r,headers:o}=t;void 0!==n&&qt.assertOptions(n,{silentJSONParsing:Xt.transitional(Xt.boolean),forcedJSONParsing:Xt.transitional(Xt.boolean),clarifyTimeoutError:Xt.transitional(Xt.boolean)},!1),null!=r&&(Ie.isFunction(r)?t.paramsSerializer={serialize:r}:qt.assertOptions(r,{encode:Xt.function,serialize:Xt.function},!0)),qt.assertOptions(t,{baseUrl:Xt.spelling("baseURL"),withXsrfToken:Xt.spelling("withXSRFToken")},!0),t.method=(t.method||this.defaults.method||"get").toLowerCase();let a=o&&Ie.merge(o.common,o[t.method]);o&&Ie.forEach(["delete","get","head","post","put","patch","common"],(e=>{delete o[e]})),t.headers=st.concat(a,o);const i=[];let l=!0;this.interceptors.request.forEach((function(e){"function"==typeof e.runWhen&&!1===e.runWhen(t)||(l=l&&e.synchronous,i.unshift(e.fulfilled,e.rejected))}));const s=[];let c;this.interceptors.response.forEach((function(e){s.push(e.fulfilled,e.rejected)}));let u,d=0;if(!l){const e=[jt.bind(this),void 0];for(e.unshift.apply(e,i),e.push.apply(e,s),u=e.length,c=Promise.resolve(t);d<u;)c=c.then(e[d++],e[d++]);return c}u=i.length;let m=t;for(d=0;d<u;){const e=i[d++],t=i[d++];try{m=e(m)}catch(e){t.call(this,e);break}}try{c=jt.call(this,m)}catch(e){return Promise.reject(e)}for(d=0,u=s.length;d<u;)c=c.then(s[d++],s[d++]);return c}getUri(e){return $e(yt((e=vt(this.defaults,e)).baseURL,e.url),e.params,e.paramsSerializer)}}Ie.forEach(["delete","get","head","options"],(function(e){Yt.prototype[e]=function(t,n){return this.request(vt(n||{},{method:e,url:t,data:(n||{}).data}))}})),Ie.forEach(["post","put","patch"],(function(e){function t(t){return function(n,r,o){return this.request(vt(o||{},{method:e,headers:t?{"Content-Type":"multipart/form-data"}:{},url:n,data:r}))}}Yt.prototype[e]=t(),Yt.prototype[e+"Form"]=t(!0)}));class Gt{constructor(e){if("function"!=typeof e)throw new TypeError("executor must be a function.");let t;this.promise=new Promise((function(e){t=e}));const n=this;this.promise.then((e=>{if(!n._listeners)return;let t=n._listeners.length;for(;t-- >0;)n._listeners[t](e);n._listeners=null})),this.promise.then=e=>{let t;const r=new Promise((e=>{n.subscribe(e),t=e})).then(e);return r.cancel=function(){n.unsubscribe(t)},r},e((function(e,r,o){n.reason||(n.reason=new dt(e,r,o),t(n.reason))}))}throwIfRequested(){if(this.reason)throw this.reason}subscribe(e){this.reason?e(this.reason):this._listeners?this._listeners.push(e):this._listeners=[e]}unsubscribe(e){if(!this._listeners)return;const t=this._listeners.indexOf(e);-1!==t&&this._listeners.splice(t,1)}toAbortSignal(){const e=new AbortController,t=t=>{e.abort(t)};return this.subscribe(t),e.signal.unsubscribe=()=>this.unsubscribe(t),e.signal}static source(){let e;return{token:new Gt((function(t){e=t})),cancel:e}}}const Zt={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(Zt).forEach((([e,t])=>{Zt[t]=e}));const Jt=function e(t){const n=new Yt(t),r=j(Yt.prototype.request,n);return Ie.extend(r,Yt.prototype,n,{allOwnKeys:!0}),Ie.extend(r,n,null,{allOwnKeys:!0}),r.create=function(n){return e(vt(t,n))},r}(nt);Jt.Axios=Yt,Jt.CanceledError=dt,Jt.CancelToken=Gt,Jt.isCancel=ut,Jt.VERSION=Vt,Jt.toFormData=De,Jt.AxiosError=Ne,Jt.Cancel=Jt.CanceledError,Jt.all=function(e){return Promise.all(e)},Jt.spread=function(e){return function(t){return e.apply(null,t)}},Jt.isAxiosError=function(e){return Ie.isObject(e)&&!0===e.isAxiosError},Jt.mergeConfig=vt,Jt.AxiosHeaders=st,Jt.formToJSON=e=>tt(Ie.isHTMLForm(e)?new FormData(e):e),Jt.getAdapter=Dt,Jt.HttpStatusCode=Zt,Jt.default=Jt;const Kt=Jt.create({baseURL:"https://widgets.monology.io"});Kt.interceptors.request.use((e=>e),(e=>Promise.reject(e)));const Qt=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,en=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,tn={};function nn(e,t){return((t||tn).jsx?en:Qt).test(e)}const rn=/[ \t\n\f\r]/g;function on(e){return""===e.replace(rn,"")}class an{constructor(e,t,n){this.property=e,this.normal=t,n&&(this.space=n)}}function ln(e,t){const n={},r={};let o=-1;for(;++o<e.length;)Object.assign(n,e[o].property),Object.assign(r,e[o].normal);return new an(n,r,t)}function sn(e){return e.toLowerCase()}an.prototype.property={},an.prototype.normal={},an.prototype.space=null;class cn{constructor(e,t){this.property=e,this.attribute=t}}cn.prototype.space=null,cn.prototype.boolean=!1,cn.prototype.booleanish=!1,cn.prototype.overloadedBoolean=!1,cn.prototype.number=!1,cn.prototype.commaSeparated=!1,cn.prototype.spaceSeparated=!1,cn.prototype.commaOrSpaceSeparated=!1,cn.prototype.mustUseProperty=!1,cn.prototype.defined=!1;let un=0;const dn=yn(),mn=yn(),pn=yn(),fn=yn(),hn=yn(),gn=yn(),_n=yn();function yn(){return 2**++un}var bn=Object.freeze({__proto__:null,boolean:dn,booleanish:mn,overloadedBoolean:pn,number:fn,spaceSeparated:hn,commaSeparated:gn,commaOrSpaceSeparated:_n});const vn=Object.keys(bn);class xn extends cn{constructor(e,t,n,r){let o=-1;if(super(e,t),kn(this,"space",r),"number"==typeof n)for(;++o<vn.length;){const e=vn[o];kn(this,vn[o],(n&bn[e])===bn[e])}}}function kn(e,t,n){n&&(e[t]=n)}xn.prototype.defined=!0;const wn={}.hasOwnProperty;function Cn(e){const t={},n={};let r;for(r in e.properties)if(wn.call(e.properties,r)){const o=e.properties[r],a=new xn(r,e.transform(e.attributes||{},r),o,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(a.mustUseProperty=!0),t[r]=a,n[sn(r)]=r,n[sn(a.attribute)]=r}return new an(t,n,e.space)}const En=Cn({space:"xlink",transform:(e,t)=>"xlink:"+t.slice(5).toLowerCase(),properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null}}),Sn=Cn({space:"xml",transform:(e,t)=>"xml:"+t.slice(3).toLowerCase(),properties:{xmlLang:null,xmlBase:null,xmlSpace:null}});function Rn(e,t){return t in e?e[t]:t}function Fn(e,t){return Rn(e,t.toLowerCase())}const Pn=Cn({space:"xmlns",attributes:{xmlnsxlink:"xmlns:xlink"},transform:Fn,properties:{xmlns:null,xmlnsXLink:null}}),Tn=Cn({transform:(e,t)=>"role"===t?t:"aria-"+t.slice(4).toLowerCase(),properties:{ariaActiveDescendant:null,ariaAtomic:mn,ariaAutoComplete:null,ariaBusy:mn,ariaChecked:mn,ariaColCount:fn,ariaColIndex:fn,ariaColSpan:fn,ariaControls:hn,ariaCurrent:null,ariaDescribedBy:hn,ariaDetails:null,ariaDisabled:mn,ariaDropEffect:hn,ariaErrorMessage:null,ariaExpanded:mn,ariaFlowTo:hn,ariaGrabbed:mn,ariaHasPopup:null,ariaHidden:mn,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:hn,ariaLevel:fn,ariaLive:null,ariaModal:mn,ariaMultiLine:mn,ariaMultiSelectable:mn,ariaOrientation:null,ariaOwns:hn,ariaPlaceholder:null,ariaPosInSet:fn,ariaPressed:mn,ariaReadOnly:mn,ariaRelevant:null,ariaRequired:mn,ariaRoleDescription:hn,ariaRowCount:fn,ariaRowIndex:fn,ariaRowSpan:fn,ariaSelected:mn,ariaSetSize:fn,ariaSort:null,ariaValueMax:fn,ariaValueMin:fn,ariaValueNow:fn,ariaValueText:null,role:null}}),Bn=Cn({space:"html",attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},transform:Fn,mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:gn,acceptCharset:hn,accessKey:hn,action:null,allow:null,allowFullScreen:dn,allowPaymentRequest:dn,allowUserMedia:dn,alt:null,as:null,async:dn,autoCapitalize:null,autoComplete:hn,autoFocus:dn,autoPlay:dn,blocking:hn,capture:null,charSet:null,checked:dn,cite:null,className:hn,cols:fn,colSpan:null,content:null,contentEditable:mn,controls:dn,controlsList:hn,coords:fn|gn,crossOrigin:null,data:null,dateTime:null,decoding:null,default:dn,defer:dn,dir:null,dirName:null,disabled:dn,download:pn,draggable:mn,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:dn,formTarget:null,headers:hn,height:fn,hidden:dn,high:fn,href:null,hrefLang:null,htmlFor:hn,httpEquiv:hn,id:null,imageSizes:null,imageSrcSet:null,inert:dn,inputMode:null,integrity:null,is:null,isMap:dn,itemId:null,itemProp:hn,itemRef:hn,itemScope:dn,itemType:hn,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:dn,low:fn,manifest:null,max:null,maxLength:fn,media:null,method:null,min:null,minLength:fn,multiple:dn,muted:dn,name:null,nonce:null,noModule:dn,noValidate:dn,onAbort:null,onAfterPrint:null,onAuxClick:null,onBeforeMatch:null,onBeforePrint:null,onBeforeToggle:null,onBeforeUnload:null,onBlur:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onContextLost:null,onContextMenu:null,onContextRestored:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnded:null,onError:null,onFocus:null,onFormData:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLanguageChange:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadEnd:null,onLoadStart:null,onMessage:null,onMessageError:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRejectionHandled:null,onReset:null,onResize:null,onScroll:null,onScrollEnd:null,onSecurityPolicyViolation:null,onSeeked:null,onSeeking:null,onSelect:null,onSlotChange:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnhandledRejection:null,onUnload:null,onVolumeChange:null,onWaiting:null,onWheel:null,open:dn,optimum:fn,pattern:null,ping:hn,placeholder:null,playsInline:dn,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:dn,referrerPolicy:null,rel:hn,required:dn,reversed:dn,rows:fn,rowSpan:fn,sandbox:hn,scope:null,scoped:dn,seamless:dn,selected:dn,shadowRootClonable:dn,shadowRootDelegatesFocus:dn,shadowRootMode:null,shape:null,size:fn,sizes:null,slot:null,span:fn,spellCheck:mn,src:null,srcDoc:null,srcLang:null,srcSet:null,start:fn,step:null,style:null,tabIndex:fn,target:null,title:null,translate:null,type:null,typeMustMatch:dn,useMap:null,value:mn,width:fn,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:hn,axis:null,background:null,bgColor:null,border:fn,borderColor:null,bottomMargin:fn,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:dn,declare:dn,event:null,face:null,frame:null,frameBorder:null,hSpace:fn,leftMargin:fn,link:null,longDesc:null,lowSrc:null,marginHeight:fn,marginWidth:fn,noResize:dn,noHref:dn,noShade:dn,noWrap:dn,object:null,profile:null,prompt:null,rev:null,rightMargin:fn,rules:null,scheme:null,scrolling:mn,standby:null,summary:null,text:null,topMargin:fn,valueType:null,version:null,vAlign:null,vLink:null,vSpace:fn,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:dn,disableRemotePlayback:dn,prefix:null,property:null,results:fn,security:null,unselectable:null}}),In=Cn({space:"svg",attributes:{accentHeight:"accent-height",alignmentBaseline:"alignment-baseline",arabicForm:"arabic-form",baselineShift:"baseline-shift",capHeight:"cap-height",className:"class",clipPath:"clip-path",clipRule:"clip-rule",colorInterpolation:"color-interpolation",colorInterpolationFilters:"color-interpolation-filters",colorProfile:"color-profile",colorRendering:"color-rendering",crossOrigin:"crossorigin",dataType:"datatype",dominantBaseline:"dominant-baseline",enableBackground:"enable-background",fillOpacity:"fill-opacity",fillRule:"fill-rule",floodColor:"flood-color",floodOpacity:"flood-opacity",fontFamily:"font-family",fontSize:"font-size",fontSizeAdjust:"font-size-adjust",fontStretch:"font-stretch",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",glyphName:"glyph-name",glyphOrientationHorizontal:"glyph-orientation-horizontal",glyphOrientationVertical:"glyph-orientation-vertical",hrefLang:"hreflang",horizAdvX:"horiz-adv-x",horizOriginX:"horiz-origin-x",horizOriginY:"horiz-origin-y",imageRendering:"image-rendering",letterSpacing:"letter-spacing",lightingColor:"lighting-color",markerEnd:"marker-end",markerMid:"marker-mid",markerStart:"marker-start",navDown:"nav-down",navDownLeft:"nav-down-left",navDownRight:"nav-down-right",navLeft:"nav-left",navNext:"nav-next",navPrev:"nav-prev",navRight:"nav-right",navUp:"nav-up",navUpLeft:"nav-up-left",navUpRight:"nav-up-right",onAbort:"onabort",onActivate:"onactivate",onAfterPrint:"onafterprint",onBeforePrint:"onbeforeprint",onBegin:"onbegin",onCancel:"oncancel",onCanPlay:"oncanplay",onCanPlayThrough:"oncanplaythrough",onChange:"onchange",onClick:"onclick",onClose:"onclose",onCopy:"oncopy",onCueChange:"oncuechange",onCut:"oncut",onDblClick:"ondblclick",onDrag:"ondrag",onDragEnd:"ondragend",onDragEnter:"ondragenter",onDragExit:"ondragexit",onDragLeave:"ondragleave",onDragOver:"ondragover",onDragStart:"ondragstart",onDrop:"ondrop",onDurationChange:"ondurationchange",onEmptied:"onemptied",onEnd:"onend",onEnded:"onended",onError:"onerror",onFocus:"onfocus",onFocusIn:"onfocusin",onFocusOut:"onfocusout",onHashChange:"onhashchange",onInput:"oninput",onInvalid:"oninvalid",onKeyDown:"onkeydown",onKeyPress:"onkeypress",onKeyUp:"onkeyup",onLoad:"onload",onLoadedData:"onloadeddata",onLoadedMetadata:"onloadedmetadata",onLoadStart:"onloadstart",onMessage:"onmessage",onMouseDown:"onmousedown",onMouseEnter:"onmouseenter",onMouseLeave:"onmouseleave",onMouseMove:"onmousemove",onMouseOut:"onmouseout",onMouseOver:"onmouseover",onMouseUp:"onmouseup",onMouseWheel:"onmousewheel",onOffline:"onoffline",onOnline:"ononline",onPageHide:"onpagehide",onPageShow:"onpageshow",onPaste:"onpaste",onPause:"onpause",onPlay:"onplay",onPlaying:"onplaying",onPopState:"onpopstate",onProgress:"onprogress",onRateChange:"onratechange",onRepeat:"onrepeat",onReset:"onreset",onResize:"onresize",onScroll:"onscroll",onSeeked:"onseeked",onSeeking:"onseeking",onSelect:"onselect",onShow:"onshow",onStalled:"onstalled",onStorage:"onstorage",onSubmit:"onsubmit",onSuspend:"onsuspend",onTimeUpdate:"ontimeupdate",onToggle:"ontoggle",onUnload:"onunload",onVolumeChange:"onvolumechange",onWaiting:"onwaiting",onZoom:"onzoom",overlinePosition:"overline-position",overlineThickness:"overline-thickness",paintOrder:"paint-order",panose1:"panose-1",pointerEvents:"pointer-events",referrerPolicy:"referrerpolicy",renderingIntent:"rendering-intent",shapeRendering:"shape-rendering",stopColor:"stop-color",stopOpacity:"stop-opacity",strikethroughPosition:"strikethrough-position",strikethroughThickness:"strikethrough-thickness",strokeDashArray:"stroke-dasharray",strokeDashOffset:"stroke-dashoffset",strokeLineCap:"stroke-linecap",strokeLineJoin:"stroke-linejoin",strokeMiterLimit:"stroke-miterlimit",strokeOpacity:"stroke-opacity",strokeWidth:"stroke-width",tabIndex:"tabindex",textAnchor:"text-anchor",textDecoration:"text-decoration",textRendering:"text-rendering",transformOrigin:"transform-origin",typeOf:"typeof",underlinePosition:"underline-position",underlineThickness:"underline-thickness",unicodeBidi:"unicode-bidi",unicodeRange:"unicode-range",unitsPerEm:"units-per-em",vAlphabetic:"v-alphabetic",vHanging:"v-hanging",vIdeographic:"v-ideographic",vMathematical:"v-mathematical",vectorEffect:"vector-effect",vertAdvY:"vert-adv-y",vertOriginX:"vert-origin-x",vertOriginY:"vert-origin-y",wordSpacing:"word-spacing",writingMode:"writing-mode",xHeight:"x-height",playbackOrder:"playbackorder",timelineBegin:"timelinebegin"},transform:Rn,properties:{about:_n,accentHeight:fn,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:fn,amplitude:fn,arabicForm:null,ascent:fn,attributeName:null,attributeType:null,azimuth:fn,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:fn,by:null,calcMode:null,capHeight:fn,className:hn,clip:null,clipPath:null,clipPathUnits:null,clipRule:null,color:null,colorInterpolation:null,colorInterpolationFilters:null,colorProfile:null,colorRendering:null,content:null,contentScriptType:null,contentStyleType:null,crossOrigin:null,cursor:null,cx:null,cy:null,d:null,dataType:null,defaultAction:null,descent:fn,diffuseConstant:fn,direction:null,display:null,dur:null,divisor:fn,dominantBaseline:null,download:dn,dx:null,dy:null,edgeMode:null,editable:null,elevation:fn,enableBackground:null,end:null,event:null,exponent:fn,externalResourcesRequired:null,fill:null,fillOpacity:fn,fillRule:null,filter:null,filterRes:null,filterUnits:null,floodColor:null,floodOpacity:null,focusable:null,focusHighlight:null,fontFamily:null,fontSize:null,fontSizeAdjust:null,fontStretch:null,fontStyle:null,fontVariant:null,fontWeight:null,format:null,fr:null,from:null,fx:null,fy:null,g1:gn,g2:gn,glyphName:gn,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:fn,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:fn,horizOriginX:fn,horizOriginY:fn,id:null,ideographic:fn,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:fn,k:fn,k1:fn,k2:fn,k3:fn,k4:fn,kernelMatrix:_n,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:fn,local:null,markerEnd:null,markerMid:null,markerStart:null,markerHeight:null,markerUnits:null,markerWidth:null,mask:null,maskContentUnits:null,maskUnits:null,mathematical:null,max:null,media:null,mediaCharacterEncoding:null,mediaContentEncodings:null,mediaSize:fn,mediaTime:null,method:null,min:null,mode:null,name:null,navDown:null,navDownLeft:null,navDownRight:null,navLeft:null,navNext:null,navPrev:null,navRight:null,navUp:null,navUpLeft:null,navUpRight:null,numOctaves:null,observer:null,offset:null,onAbort:null,onActivate:null,onAfterPrint:null,onBeforePrint:null,onBegin:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnd:null,onEnded:null,onError:null,onFocus:null,onFocusIn:null,onFocusOut:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadStart:null,onMessage:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onMouseWheel:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRepeat:null,onReset:null,onResize:null,onScroll:null,onSeeked:null,onSeeking:null,onSelect:null,onShow:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnload:null,onVolumeChange:null,onWaiting:null,onZoom:null,opacity:null,operator:null,order:null,orient:null,orientation:null,origin:null,overflow:null,overlay:null,overlinePosition:fn,overlineThickness:fn,paintOrder:null,panose1:null,path:null,pathLength:fn,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:hn,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:fn,pointsAtY:fn,pointsAtZ:fn,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:_n,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:_n,rev:_n,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:_n,requiredFeatures:_n,requiredFonts:_n,requiredFormats:_n,resource:null,restart:null,result:null,rotate:null,rx:null,ry:null,scale:null,seed:null,shapeRendering:null,side:null,slope:null,snapshotTime:null,specularConstant:fn,specularExponent:fn,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:fn,strikethroughThickness:fn,string:null,stroke:null,strokeDashArray:_n,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:fn,strokeOpacity:fn,strokeWidth:null,style:null,surfaceScale:fn,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:_n,tabIndex:fn,tableValues:null,target:null,targetX:fn,targetY:fn,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:_n,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:fn,underlineThickness:fn,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:fn,values:null,vAlphabetic:fn,vMathematical:fn,vectorEffect:null,vHanging:fn,vIdeographic:fn,version:null,vertAdvY:fn,vertOriginX:fn,vertOriginY:fn,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:fn,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null}}),Nn=/^data[-\w.:]+$/i,Ln=/-[a-z]/g,On=/[A-Z]/g;function An(e){return"-"+e.toLowerCase()}function Mn(e){return e.charAt(1).toUpperCase()}const zn={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"},Hn=ln([Sn,En,Pn,Tn,Bn],"html"),Dn=ln([Sn,En,Pn,Tn,In],"svg");var Un={},jn=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,Vn=/\n/g,Wn=/^\s*/,$n=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,qn=/^:\s*/,Xn=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,Yn=/^[;\s]*/,Gn=/^\s+|\s+$/g,Zn="";function Jn(e){return e?e.replace(Gn,Zn):Zn}var Kn=d&&d.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(Un,"__esModule",{value:!0});var Qn=Un.default=function(e,t){var n=null;if(!e||"string"!=typeof e)return n;var r=(0,er.default)(e),o="function"==typeof t;return r.forEach((function(e){if("declaration"===e.type){var r=e.property,a=e.value;o?t(r,a,e):a&&((n=n||{})[r]=a)}})),n},er=Kn((function(e,t){if("string"!=typeof e)throw new TypeError("First argument must be a string");if(!e)return[];t=t||{};var n=1,r=1;function o(e){var t=e.match(Vn);t&&(n+=t.length);var o=e.lastIndexOf("\n");r=~o?e.length-o:r+e.length}function a(){var e={line:n,column:r};return function(t){return t.position=new i(e),c(),t}}function i(e){this.start=e,this.end={line:n,column:r},this.source=t.source}function l(o){var a=new Error(t.source+":"+n+":"+r+": "+o);if(a.reason=o,a.filename=t.source,a.line=n,a.column=r,a.source=e,!t.silent)throw a}function s(t){var n=t.exec(e);if(n){var r=n[0];return o(r),e=e.slice(r.length),n}}function c(){s(Wn)}function u(e){var t;for(e=e||[];t=d();)!1!==t&&e.push(t);return e}function d(){var t=a();if("/"==e.charAt(0)&&"*"==e.charAt(1)){for(var n=2;Zn!=e.charAt(n)&&("*"!=e.charAt(n)||"/"!=e.charAt(n+1));)++n;if(n+=2,Zn===e.charAt(n-1))return l("End of comment missing");var i=e.slice(2,n-2);return r+=2,o(i),e=e.slice(n),r+=2,t({type:"comment",comment:i})}}function m(){var e=a(),t=s($n);if(t){if(d(),!s(qn))return l("property missing ':'");var n=s(Xn),r=e({type:"declaration",property:Jn(t[0].replace(jn,Zn)),value:n?Jn(n[0].replace(jn,Zn)):Zn});return s(Yn),r}}return i.prototype.content=e,c(),function(){var e,t=[];for(u(t);e=m();)!1!==e&&(t.push(e),u(t));return t}()}));var tr=Qn.default||Qn;const nr=or("end"),rr=or("start");function or(e){return function(t){const n=t&&t.position&&t.position[e]||{};if("number"==typeof n.line&&n.line>0&&"number"==typeof n.column&&n.column>0)return{line:n.line,column:n.column,offset:"number"==typeof n.offset&&n.offset>-1?n.offset:void 0}}}function ar(e){return e&&"object"==typeof e?"position"in e||"type"in e?lr(e.position):"start"in e||"end"in e?lr(e):"line"in e||"column"in e?ir(e):"":""}function ir(e){return sr(e&&e.line)+":"+sr(e&&e.column)}function lr(e){return ir(e&&e.start)+"-"+ir(e&&e.end)}function sr(e){return e&&"number"==typeof e?e:1}class cr extends Error{constructor(e,t,n){super(),"string"==typeof t&&(n=t,t=void 0);let r="",o={},a=!1;if(t&&(o="line"in t&&"column"in t||"start"in t&&"end"in t?{place:t}:"type"in t?{ancestors:[t],place:t.position}:{...t}),"string"==typeof e?r=e:!o.cause&&e&&(a=!0,r=e.message,o.cause=e),!o.ruleId&&!o.source&&"string"==typeof n){const e=n.indexOf(":");-1===e?o.ruleId=n:(o.source=n.slice(0,e),o.ruleId=n.slice(e+1))}if(!o.place&&o.ancestors&&o.ancestors){const e=o.ancestors[o.ancestors.length-1];e&&(o.place=e.position)}const i=o.place&&"start"in o.place?o.place.start:o.place;this.ancestors=o.ancestors||void 0,this.cause=o.cause||void 0,this.column=i?i.column:void 0,this.fatal=void 0,this.file,this.message=r,this.line=i?i.line:void 0,this.name=ar(o.place)||"1:1",this.place=o.place||void 0,this.reason=this.message,this.ruleId=o.ruleId||void 0,this.source=o.source||void 0,this.stack=a&&o.cause&&"string"==typeof o.cause.stack?o.cause.stack:"",this.actual,this.expected,this.note,this.url}}cr.prototype.file="",cr.prototype.name="",cr.prototype.reason="",cr.prototype.message="",cr.prototype.stack="",cr.prototype.column=void 0,cr.prototype.line=void 0,cr.prototype.ancestors=void 0,cr.prototype.cause=void 0,cr.prototype.fatal=void 0,cr.prototype.place=void 0,cr.prototype.ruleId=void 0,cr.prototype.source=void 0;const ur={}.hasOwnProperty,dr=new Map,mr=/[A-Z]/g,pr=/-([a-z])/g,fr=new Set(["table","tbody","thead","tfoot","tr"]),hr=new Set(["td","th"]),gr="https://github.com/syntax-tree/hast-util-to-jsx-runtime";function _r(e,t){if(!t||void 0===t.Fragment)throw new TypeError("Expected `Fragment` in options");const n=t.filePath||void 0;let r;if(t.development){if("function"!=typeof t.jsxDEV)throw new TypeError("Expected `jsxDEV` in options when `development: true`");r=function(e,t){return n;function n(n,r,o,a){const i=Array.isArray(o.children),l=rr(n);return t(r,o,a,i,{columnNumber:l?l.column-1:void 0,fileName:e,lineNumber:l?l.line:void 0},void 0)}}(n,t.jsxDEV)}else{if("function"!=typeof t.jsx)throw new TypeError("Expected `jsx` in production options");if("function"!=typeof t.jsxs)throw new TypeError("Expected `jsxs` in production options");r=function(e,t,n){return r;function r(e,r,o,a){const i=Array.isArray(o.children)?n:t;return a?i(r,o,a):i(r,o)}}(0,t.jsx,t.jsxs)}const o={Fragment:t.Fragment,ancestors:[],components:t.components||{},create:r,elementAttributeNameCase:t.elementAttributeNameCase||"react",evaluater:t.createEvaluater?t.createEvaluater():void 0,filePath:n,ignoreInvalidStyle:t.ignoreInvalidStyle||!1,passKeys:!1!==t.passKeys,passNode:t.passNode||!1,schema:"svg"===t.space?Dn:Hn,stylePropertyNameCase:t.stylePropertyNameCase||"dom",tableCellAlignToStyle:!1!==t.tableCellAlignToStyle},a=yr(o,e,void 0);return a&&"string"!=typeof a?a:o.create(e,o.Fragment,{children:a||void 0},void 0)}function yr(e,t,n){return"element"===t.type?function(e,t,n){const r=e.schema;let o=r;"svg"===t.tagName.toLowerCase()&&"html"===r.space&&(o=Dn,e.schema=o);e.ancestors.push(t);const a=wr(e,t.tagName,!1),i=function(e,t){const n={};let r,o;for(o in t.properties)if("children"!==o&&ur.call(t.properties,o)){const a=kr(e,o,t.properties[o]);if(a){const[o,i]=a;e.tableCellAlignToStyle&&"align"===o&&"string"==typeof i&&hr.has(t.tagName)?r=i:n[o]=i}}if(r){(n.style||(n.style={}))["css"===e.stylePropertyNameCase?"text-align":"textAlign"]=r}return n}(e,t);let l=xr(e,t);fr.has(t.tagName)&&(l=l.filter((function(e){return"string"!=typeof e||!("object"==typeof(t=e)?"text"===t.type&&on(t.value):on(t));var t})));return br(e,i,a,t),vr(i,l),e.ancestors.pop(),e.schema=r,e.create(t,a,i,n)}(e,t,n):"mdxFlowExpression"===t.type||"mdxTextExpression"===t.type?function(e,t){if(t.data&&t.data.estree&&e.evaluater){const n=t.data.estree.body[0];return n.type,e.evaluater.evaluateExpression(n.expression)}Cr(e,t.position)}(e,t):"mdxJsxFlowElement"===t.type||"mdxJsxTextElement"===t.type?function(e,t,n){const r=e.schema;let o=r;"svg"===t.name&&"html"===r.space&&(o=Dn,e.schema=o);e.ancestors.push(t);const a=null===t.name?e.Fragment:wr(e,t.name,!0),i=function(e,t){const n={};for(const r of t.attributes)if("mdxJsxExpressionAttribute"===r.type)if(r.data&&r.data.estree&&e.evaluater){const t=r.data.estree.body[0];t.type;const o=t.expression;o.type;const a=o.properties[0];a.type,Object.assign(n,e.evaluater.evaluateExpression(a.argument))}else Cr(e,t.position);else{const o=r.name;let a;if(r.value&&"object"==typeof r.value)if(r.value.data&&r.value.data.estree&&e.evaluater){const t=r.value.data.estree.body[0];t.type,a=e.evaluater.evaluateExpression(t.expression)}else Cr(e,t.position);else a=null===r.value||r.value;n[o]=a}return n}(e,t),l=xr(e,t);return br(e,i,a,t),vr(i,l),e.ancestors.pop(),e.schema=r,e.create(t,a,i,n)}(e,t,n):"mdxjsEsm"===t.type?function(e,t){if(t.data&&t.data.estree&&e.evaluater)return e.evaluater.evaluateProgram(t.data.estree);Cr(e,t.position)}(e,t):"root"===t.type?function(e,t,n){const r={};return vr(r,xr(e,t)),e.create(t,e.Fragment,r,n)}(e,t,n):"text"===t.type?function(e,t){return t.value}(0,t):void 0}function br(e,t,n,r){"string"!=typeof n&&n!==e.Fragment&&e.passNode&&(t.node=r)}function vr(e,t){if(t.length>0){const n=t.length>1?t:t[0];n&&(e.children=n)}}function xr(e,t){const n=[];let r=-1;const o=e.passKeys?new Map:dr;for(;++r<t.children.length;){const a=t.children[r];let i;if(e.passKeys){const e="element"===a.type?a.tagName:"mdxJsxFlowElement"===a.type||"mdxJsxTextElement"===a.type?a.name:void 0;if(e){const t=o.get(e)||0;i=e+"-"+t,o.set(e,t+1)}}const l=yr(e,a,i);void 0!==l&&n.push(l)}return n}function kr(e,t,n){const r=function(e,t){const n=sn(t);let r=t,o=cn;if(n in e.normal)return e.property[e.normal[n]];if(n.length>4&&"data"===n.slice(0,4)&&Nn.test(t)){if("-"===t.charAt(4)){const e=t.slice(5).replace(Ln,Mn);r="data"+e.charAt(0).toUpperCase()+e.slice(1)}else{const e=t.slice(4);if(!Ln.test(e)){let n=e.replace(On,An);"-"!==n.charAt(0)&&(n="-"+n),t="data"+n}}o=xn}return new o(r,t)}(e.schema,t);if(!(null==n||"number"==typeof n&&Number.isNaN(n))){if(Array.isArray(n)&&(n=r.commaSeparated?function(e,t){const n=t||{};return(""===e[e.length-1]?[...e,""]:e).join((n.padRight?" ":"")+","+(!1===n.padLeft?"":" ")).trim()}(n):n.join(" ").trim()),"style"===r.property){let t="object"==typeof n?n:function(e,t){const n={};try{tr(t,r)}catch(t){if(!e.ignoreInvalidStyle){const n=t,r=new cr("Cannot parse `style` attribute",{ancestors:e.ancestors,cause:n,ruleId:"style",source:"hast-util-to-jsx-runtime"});throw r.file=e.filePath||void 0,r.url=gr+"#cannot-parse-style-attribute",r}}return n;function r(e,t){let r=e;"--"!==r.slice(0,2)&&("-ms-"===r.slice(0,4)&&(r="ms-"+r.slice(4)),r=r.replace(pr,Sr)),n[r]=t}}(e,String(n));return"css"===e.stylePropertyNameCase&&(t=function(e){const t={};let n;for(n in e)ur.call(e,n)&&(t[Er(n)]=e[n]);return t}(t)),["style",t]}return["react"===e.elementAttributeNameCase&&r.space?zn[r.property]||r.property:r.attribute,n]}}function wr(e,t,n){let r;if(n)if(t.includes(".")){const e=t.split(".");let n,o=-1;for(;++o<e.length;){const t=nn(e[o])?{type:"Identifier",name:e[o]}:{type:"Literal",value:e[o]};n=n?{type:"MemberExpression",object:n,property:t,computed:Boolean(o&&"Literal"===t.type),optional:!1}:t}r=n}else r=nn(t)&&!/^[a-z]/.test(t)?{type:"Identifier",name:t}:{type:"Literal",value:t};else r={type:"Literal",value:t};if("Literal"===r.type){const t=r.value;return ur.call(e.components,t)?e.components[t]:t}if(e.evaluater)return e.evaluater.evaluateExpression(r);Cr(e)}function Cr(e,t){const n=new cr("Cannot handle MDX estrees without `createEvaluater`",{ancestors:e.ancestors,place:t,ruleId:"mdx-estree",source:"hast-util-to-jsx-runtime"});throw n.file=e.filePath||void 0,n.url=gr+"#cannot-handle-mdx-estrees-without-createevaluater",n}function Er(e){let t=e.replace(mr,Rr);return"ms-"===t.slice(0,3)&&(t="-"+t),t}function Sr(e,t){return t.toUpperCase()}function Rr(e){return"-"+e.toLowerCase()}const Fr={action:["form"],cite:["blockquote","del","ins","q"],data:["object"],formAction:["button","input"],href:["a","area","base","link"],icon:["menuitem"],itemId:null,manifest:["html"],ping:["a","area"],poster:["video"],src:["audio","embed","iframe","img","input","script","source","track","video"]},Pr={};function Tr(e,t,n){if(function(e){return Boolean(e&&"object"==typeof e)}(e)){if("value"in e)return"html"!==e.type||n?e.value:"";if(t&&"alt"in e&&e.alt)return e.alt;if("children"in e)return Br(e.children,t,n)}return Array.isArray(e)?Br(e,t,n):""}function Br(e,t,n){const r=[];let o=-1;for(;++o<e.length;)r[o]=Tr(e[o],t,n);return r.join("")}const Ir=document.createElement("i");function Nr(e){const t="&"+e+";";Ir.innerHTML=t;const n=Ir.textContent;return(59!==n.charCodeAt(n.length-1)||"semi"===e)&&(n!==t&&n)}function Lr(e,t,n,r){const o=e.length;let a,i=0;if(t=t<0?-t>o?0:o+t:t>o?o:t,n=n>0?n:0,r.length<1e4)a=Array.from(r),a.unshift(t,n),e.splice(...a);else for(n&&e.splice(t,n);i<r.length;)a=r.slice(i,i+1e4),a.unshift(t,0),e.splice(...a),i+=1e4,t+=1e4}function Or(e,t){return e.length>0?(Lr(e,e.length,0,t),e):t}const Ar={}.hasOwnProperty;function Mr(e,t){let n;for(n in t){const r=(Ar.call(e,n)?e[n]:void 0)||(e[n]={}),o=t[n];let a;if(o)for(a in o){Ar.call(r,a)||(r[a]=[]);const e=o[a];zr(r[a],Array.isArray(e)?e:e?[e]:[])}}}function zr(e,t){let n=-1;const r=[];for(;++n<t.length;)("after"===t[n].add?e:r).push(t[n]);Lr(e,0,0,r)}function Hr(e,t){const n=Number.parseInt(e,t);return n<9||11===n||n>13&&n<32||n>126&&n<160||n>55295&&n<57344||n>64975&&n<65008||!(65535&~n)||65534==(65535&n)||n>1114111?"�":String.fromCodePoint(n)}function Dr(e){return e.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}const Ur=Qr(/[A-Za-z]/),jr=Qr(/[\dA-Za-z]/),Vr=Qr(/[#-'*+\--9=?A-Z^-~]/);function Wr(e){return null!==e&&(e<32||127===e)}const $r=Qr(/\d/),qr=Qr(/[\dA-Fa-f]/),Xr=Qr(/[!-/:-@[-`{-~]/);function Yr(e){return null!==e&&e<-2}function Gr(e){return null!==e&&(e<0||32===e)}function Zr(e){return-2===e||-1===e||32===e}const Jr=Qr(/\p{P}|\p{S}/u),Kr=Qr(/\s/);function Qr(e){return function(t){return null!==t&&t>-1&&e.test(String.fromCharCode(t))}}function eo(e){const t=[];let n=-1,r=0,o=0;for(;++n<e.length;){const a=e.charCodeAt(n);let i="";if(37===a&&jr(e.charCodeAt(n+1))&&jr(e.charCodeAt(n+2)))o=2;else if(a<128)/[!#$&-;=?-Z_a-z~]/.test(String.fromCharCode(a))||(i=String.fromCharCode(a));else if(a>55295&&a<57344){const t=e.charCodeAt(n+1);a<56320&&t>56319&&t<57344?(i=String.fromCharCode(a,t),o=1):i="�"}else i=String.fromCharCode(a);i&&(t.push(e.slice(r,n),encodeURIComponent(i)),r=n+o+1,i=""),o&&(n+=o,o=0)}return t.join("")+e.slice(r)}function to(e,t,n,r){const o=r?r-1:Number.POSITIVE_INFINITY;let a=0;return function(r){if(Zr(r))return e.enter(n),i(r);return t(r)};function i(r){return Zr(r)&&a++<o?(e.consume(r),i):(e.exit(n),t(r))}}const no={tokenize:function(e){const t=e.attempt(this.parser.constructs.contentInitial,(function(n){if(null===n)return void e.consume(n);return e.enter("lineEnding"),e.consume(n),e.exit("lineEnding"),to(e,t,"linePrefix")}),(function(t){return e.enter("paragraph"),r(t)}));let n;return t;function r(t){const r=e.enter("chunkText",{contentType:"text",previous:n});return n&&(n.next=r),n=r,o(t)}function o(t){return null===t?(e.exit("chunkText"),e.exit("paragraph"),void e.consume(t)):Yr(t)?(e.consume(t),e.exit("chunkText"),r):(e.consume(t),o)}}};const ro={tokenize:function(e){const t=this,n=[];let r,o,a,i=0;return l;function l(r){if(i<n.length){const o=n[i];return t.containerState=o[1],e.attempt(o[0].continuation,s,c)(r)}return c(r)}function s(e){if(i++,t.containerState._closeFlow){t.containerState._closeFlow=void 0,r&&y();const n=t.events.length;let o,a=n;for(;a--;)if("exit"===t.events[a][0]&&"chunkFlow"===t.events[a][1].type){o=t.events[a][1].end;break}_(i);let l=n;for(;l<t.events.length;)t.events[l][1].end={...o},l++;return Lr(t.events,a+1,0,t.events.slice(n)),t.events.length=l,c(e)}return l(e)}function c(o){if(i===n.length){if(!r)return m(o);if(r.currentConstruct&&r.currentConstruct.concrete)return f(o);t.interrupt=Boolean(r.currentConstruct&&!r._gfmTableDynamicInterruptHack)}return t.containerState={},e.check(oo,u,d)(o)}function u(e){return r&&y(),_(i),m(e)}function d(e){return t.parser.lazy[t.now().line]=i!==n.length,a=t.now().offset,f(e)}function m(n){return t.containerState={},e.attempt(oo,p,f)(n)}function p(e){return i++,n.push([t.currentConstruct,t.containerState]),m(e)}function f(n){return null===n?(r&&y(),_(0),void e.consume(n)):(r=r||t.parser.flow(t.now()),e.enter("chunkFlow",{_tokenizer:r,contentType:"flow",previous:o}),h(n))}function h(n){return null===n?(g(e.exit("chunkFlow"),!0),_(0),void e.consume(n)):Yr(n)?(e.consume(n),g(e.exit("chunkFlow")),i=0,t.interrupt=void 0,l):(e.consume(n),h)}function g(e,n){const l=t.sliceStream(e);if(n&&l.push(null),e.previous=o,o&&(o.next=e),o=e,r.defineSkip(e.start),r.write(l),t.parser.lazy[e.start.line]){let e=r.events.length;for(;e--;)if(r.events[e][1].start.offset<a&&(!r.events[e][1].end||r.events[e][1].end.offset>a))return;const n=t.events.length;let o,l,s=n;for(;s--;)if("exit"===t.events[s][0]&&"chunkFlow"===t.events[s][1].type){if(o){l=t.events[s][1].end;break}o=!0}for(_(i),e=n;e<t.events.length;)t.events[e][1].end={...l},e++;Lr(t.events,s+1,0,t.events.slice(n)),t.events.length=e}}function _(r){let o=n.length;for(;o-- >r;){const r=n[o];t.containerState=r[1],r[0].exit.call(t,e)}n.length=r}function y(){r.write([null]),o=void 0,r=void 0,t.containerState._closeFlow=void 0}}},oo={tokenize:function(e,t,n){return to(e,e.attempt(this.parser.constructs.document,t,n),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}};function ao(e){return null===e||Gr(e)||Kr(e)?1:Jr(e)?2:void 0}function io(e,t,n){const r=[];let o=-1;for(;++o<e.length;){const a=e[o].resolveAll;a&&!r.includes(a)&&(t=a(t,n),r.push(a))}return t}const lo={name:"attention",resolveAll:function(e,t){let n,r,o,a,i,l,s,c,u=-1;for(;++u<e.length;)if("enter"===e[u][0]&&"attentionSequence"===e[u][1].type&&e[u][1]._close)for(n=u;n--;)if("exit"===e[n][0]&&"attentionSequence"===e[n][1].type&&e[n][1]._open&&t.sliceSerialize(e[n][1]).charCodeAt(0)===t.sliceSerialize(e[u][1]).charCodeAt(0)){if((e[n][1]._close||e[u][1]._open)&&(e[u][1].end.offset-e[u][1].start.offset)%3&&!((e[n][1].end.offset-e[n][1].start.offset+e[u][1].end.offset-e[u][1].start.offset)%3))continue;l=e[n][1].end.offset-e[n][1].start.offset>1&&e[u][1].end.offset-e[u][1].start.offset>1?2:1;const d={...e[n][1].end},m={...e[u][1].start};so(d,-l),so(m,l),a={type:l>1?"strongSequence":"emphasisSequence",start:d,end:{...e[n][1].end}},i={type:l>1?"strongSequence":"emphasisSequence",start:{...e[u][1].start},end:m},o={type:l>1?"strongText":"emphasisText",start:{...e[n][1].end},end:{...e[u][1].start}},r={type:l>1?"strong":"emphasis",start:{...a.start},end:{...i.end}},e[n][1].end={...a.start},e[u][1].start={...i.end},s=[],e[n][1].end.offset-e[n][1].start.offset&&(s=Or(s,[["enter",e[n][1],t],["exit",e[n][1],t]])),s=Or(s,[["enter",r,t],["enter",a,t],["exit",a,t],["enter",o,t]]),s=Or(s,io(t.parser.constructs.insideSpan.null,e.slice(n+1,u),t)),s=Or(s,[["exit",o,t],["enter",i,t],["exit",i,t],["exit",r,t]]),e[u][1].end.offset-e[u][1].start.offset?(c=2,s=Or(s,[["enter",e[u][1],t],["exit",e[u][1],t]])):c=0,Lr(e,n-1,u-n+3,s),u=n+s.length-c-2;break}u=-1;for(;++u<e.length;)"attentionSequence"===e[u][1].type&&(e[u][1].type="data");return e},tokenize:function(e,t){const n=this.parser.constructs.attentionMarkers.null,r=this.previous,o=ao(r);let a;return function(t){return a=t,e.enter("attentionSequence"),i(t)};function i(l){if(l===a)return e.consume(l),i;const s=e.exit("attentionSequence"),c=ao(l),u=!c||2===c&&o||n.includes(l),d=!o||2===o&&c||n.includes(r);return s._open=Boolean(42===a?u:u&&(o||!d)),s._close=Boolean(42===a?d:d&&(c||!u)),t(l)}}};function so(e,t){e.column+=t,e.offset+=t,e._bufferIndex+=t}const co={name:"autolink",tokenize:function(e,t,n){let r=0;return function(t){return e.enter("autolink"),e.enter("autolinkMarker"),e.consume(t),e.exit("autolinkMarker"),e.enter("autolinkProtocol"),o};function o(t){return Ur(t)?(e.consume(t),a):64===t?n(t):s(t)}function a(e){return 43===e||45===e||46===e||jr(e)?(r=1,i(e)):s(e)}function i(t){return 58===t?(e.consume(t),r=0,l):(43===t||45===t||46===t||jr(t))&&r++<32?(e.consume(t),i):(r=0,s(t))}function l(r){return 62===r?(e.exit("autolinkProtocol"),e.enter("autolinkMarker"),e.consume(r),e.exit("autolinkMarker"),e.exit("autolink"),t):null===r||32===r||60===r||Wr(r)?n(r):(e.consume(r),l)}function s(t){return 64===t?(e.consume(t),c):Vr(t)?(e.consume(t),s):n(t)}function c(e){return jr(e)?u(e):n(e)}function u(n){return 46===n?(e.consume(n),r=0,c):62===n?(e.exit("autolinkProtocol").type="autolinkEmail",e.enter("autolinkMarker"),e.consume(n),e.exit("autolinkMarker"),e.exit("autolink"),t):d(n)}function d(t){if((45===t||jr(t))&&r++<63){const n=45===t?d:u;return e.consume(t),n}return n(t)}}};const uo={partial:!0,tokenize:function(e,t,n){return function(t){return Zr(t)?to(e,r,"linePrefix")(t):r(t)};function r(e){return null===e||Yr(e)?t(e):n(e)}}};const mo={continuation:{tokenize:function(e,t,n){const r=this;return function(t){if(Zr(t))return to(e,o,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(t);return o(t)};function o(r){return e.attempt(mo,t,n)(r)}}},exit:function(e){e.exit("blockQuote")},name:"blockQuote",tokenize:function(e,t,n){const r=this;return function(t){if(62===t){const n=r.containerState;return n.open||(e.enter("blockQuote",{_container:!0}),n.open=!0),e.enter("blockQuotePrefix"),e.enter("blockQuoteMarker"),e.consume(t),e.exit("blockQuoteMarker"),o}return n(t)};function o(n){return Zr(n)?(e.enter("blockQuotePrefixWhitespace"),e.consume(n),e.exit("blockQuotePrefixWhitespace"),e.exit("blockQuotePrefix"),t):(e.exit("blockQuotePrefix"),t(n))}}};const po={name:"characterEscape",tokenize:function(e,t,n){return function(t){return e.enter("characterEscape"),e.enter("escapeMarker"),e.consume(t),e.exit("escapeMarker"),r};function r(r){return Xr(r)?(e.enter("characterEscapeValue"),e.consume(r),e.exit("characterEscapeValue"),e.exit("characterEscape"),t):n(r)}}};const fo={name:"characterReference",tokenize:function(e,t,n){const r=this;let o,a,i=0;return function(t){return e.enter("characterReference"),e.enter("characterReferenceMarker"),e.consume(t),e.exit("characterReferenceMarker"),l};function l(t){return 35===t?(e.enter("characterReferenceMarkerNumeric"),e.consume(t),e.exit("characterReferenceMarkerNumeric"),s):(e.enter("characterReferenceValue"),o=31,a=jr,c(t))}function s(t){return 88===t||120===t?(e.enter("characterReferenceMarkerHexadecimal"),e.consume(t),e.exit("characterReferenceMarkerHexadecimal"),e.enter("characterReferenceValue"),o=6,a=qr,c):(e.enter("characterReferenceValue"),o=7,a=$r,c(t))}function c(l){if(59===l&&i){const o=e.exit("characterReferenceValue");return a!==jr||Nr(r.sliceSerialize(o))?(e.enter("characterReferenceMarker"),e.consume(l),e.exit("characterReferenceMarker"),e.exit("characterReference"),t):n(l)}return a(l)&&i++<o?(e.consume(l),c):n(l)}}};const ho={partial:!0,tokenize:function(e,t,n){const r=this;return function(t){if(null===t)return n(t);return e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),o};function o(e){return r.parser.lazy[r.now().line]?n(e):t(e)}}},go={concrete:!0,name:"codeFenced",tokenize:function(e,t,n){const r=this,o={partial:!0,tokenize:function(e,t,n){let o=0;return i;function i(t){return e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),s}function s(t){return e.enter("codeFencedFence"),Zr(t)?to(e,c,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(t):c(t)}function c(t){return t===a?(e.enter("codeFencedFenceSequence"),u(t)):n(t)}function u(t){return t===a?(o++,e.consume(t),u):o>=l?(e.exit("codeFencedFenceSequence"),Zr(t)?to(e,d,"whitespace")(t):d(t)):n(t)}function d(r){return null===r||Yr(r)?(e.exit("codeFencedFence"),t(r)):n(r)}}};let a,i=0,l=0;return function(t){return function(t){const n=r.events[r.events.length-1];return i=n&&"linePrefix"===n[1].type?n[2].sliceSerialize(n[1],!0).length:0,a=t,e.enter("codeFenced"),e.enter("codeFencedFence"),e.enter("codeFencedFenceSequence"),s(t)}(t)};function s(t){return t===a?(l++,e.consume(t),s):l<3?n(t):(e.exit("codeFencedFenceSequence"),Zr(t)?to(e,c,"whitespace")(t):c(t))}function c(n){return null===n||Yr(n)?(e.exit("codeFencedFence"),r.interrupt?t(n):e.check(ho,p,y)(n)):(e.enter("codeFencedFenceInfo"),e.enter("chunkString",{contentType:"string"}),u(n))}function u(t){return null===t||Yr(t)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),c(t)):Zr(t)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),to(e,d,"whitespace")(t)):96===t&&t===a?n(t):(e.consume(t),u)}function d(t){return null===t||Yr(t)?c(t):(e.enter("codeFencedFenceMeta"),e.enter("chunkString",{contentType:"string"}),m(t))}function m(t){return null===t||Yr(t)?(e.exit("chunkString"),e.exit("codeFencedFenceMeta"),c(t)):96===t&&t===a?n(t):(e.consume(t),m)}function p(t){return e.attempt(o,y,f)(t)}function f(t){return e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),h}function h(t){return i>0&&Zr(t)?to(e,g,"linePrefix",i+1)(t):g(t)}function g(t){return null===t||Yr(t)?e.check(ho,p,y)(t):(e.enter("codeFlowValue"),_(t))}function _(t){return null===t||Yr(t)?(e.exit("codeFlowValue"),g(t)):(e.consume(t),_)}function y(n){return e.exit("codeFenced"),t(n)}}};const _o={name:"codeIndented",tokenize:function(e,t,n){const r=this;return function(t){return e.enter("codeIndented"),to(e,o,"linePrefix",5)(t)};function o(e){const t=r.events[r.events.length-1];return t&&"linePrefix"===t[1].type&&t[2].sliceSerialize(t[1],!0).length>=4?a(e):n(e)}function a(t){return null===t?l(t):Yr(t)?e.attempt(yo,a,l)(t):(e.enter("codeFlowValue"),i(t))}function i(t){return null===t||Yr(t)?(e.exit("codeFlowValue"),a(t)):(e.consume(t),i)}function l(n){return e.exit("codeIndented"),t(n)}}},yo={partial:!0,tokenize:function(e,t,n){const r=this;return o;function o(t){return r.parser.lazy[r.now().line]?n(t):Yr(t)?(e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),o):to(e,a,"linePrefix",5)(t)}function a(e){const a=r.events[r.events.length-1];return a&&"linePrefix"===a[1].type&&a[2].sliceSerialize(a[1],!0).length>=4?t(e):Yr(e)?o(e):n(e)}}};const bo={name:"codeText",previous:function(e){return 96!==e||"characterEscape"===this.events[this.events.length-1][1].type},resolve:function(e){let t,n,r=e.length-4,o=3;if(!("lineEnding"!==e[o][1].type&&"space"!==e[o][1].type||"lineEnding"!==e[r][1].type&&"space"!==e[r][1].type))for(t=o;++t<r;)if("codeTextData"===e[t][1].type){e[o][1].type="codeTextPadding",e[r][1].type="codeTextPadding",o+=2,r-=2;break}t=o-1,r++;for(;++t<=r;)void 0===n?t!==r&&"lineEnding"!==e[t][1].type&&(n=t):t!==r&&"lineEnding"!==e[t][1].type||(e[n][1].type="codeTextData",t!==n+2&&(e[n][1].end=e[t-1][1].end,e.splice(n+2,t-n-2),r-=t-n-2,t=n+2),n=void 0);return e},tokenize:function(e,t,n){let r,o,a=0;return function(t){return e.enter("codeText"),e.enter("codeTextSequence"),i(t)};function i(t){return 96===t?(e.consume(t),a++,i):(e.exit("codeTextSequence"),l(t))}function l(t){return null===t?n(t):32===t?(e.enter("space"),e.consume(t),e.exit("space"),l):96===t?(o=e.enter("codeTextSequence"),r=0,c(t)):Yr(t)?(e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),l):(e.enter("codeTextData"),s(t))}function s(t){return null===t||32===t||96===t||Yr(t)?(e.exit("codeTextData"),l(t)):(e.consume(t),s)}function c(n){return 96===n?(e.consume(n),r++,c):r===a?(e.exit("codeTextSequence"),e.exit("codeText"),t(n)):(o.type="codeTextData",s(n))}}};class vo{constructor(e){this.left=e?[...e]:[],this.right=[]}get(e){if(e<0||e>=this.left.length+this.right.length)throw new RangeError("Cannot access index `"+e+"` in a splice buffer of size `"+(this.left.length+this.right.length)+"`");return e<this.left.length?this.left[e]:this.right[this.right.length-e+this.left.length-1]}get length(){return this.left.length+this.right.length}shift(){return this.setCursor(0),this.right.pop()}slice(e,t){const n=null==t?Number.POSITIVE_INFINITY:t;return n<this.left.length?this.left.slice(e,n):e>this.left.length?this.right.slice(this.right.length-n+this.left.length,this.right.length-e+this.left.length).reverse():this.left.slice(e).concat(this.right.slice(this.right.length-n+this.left.length).reverse())}splice(e,t,n){const r=t||0;this.setCursor(Math.trunc(e));const o=this.right.splice(this.right.length-r,Number.POSITIVE_INFINITY);return n&&xo(this.left,n),o.reverse()}pop(){return this.setCursor(Number.POSITIVE_INFINITY),this.left.pop()}push(e){this.setCursor(Number.POSITIVE_INFINITY),this.left.push(e)}pushMany(e){this.setCursor(Number.POSITIVE_INFINITY),xo(this.left,e)}unshift(e){this.setCursor(0),this.right.push(e)}unshiftMany(e){this.setCursor(0),xo(this.right,e.reverse())}setCursor(e){if(!(e===this.left.length||e>this.left.length&&0===this.right.length||e<0&&0===this.left.length))if(e<this.left.length){const t=this.left.splice(e,Number.POSITIVE_INFINITY);xo(this.right,t.reverse())}else{const t=this.right.splice(this.left.length+this.right.length-e,Number.POSITIVE_INFINITY);xo(this.left,t.reverse())}}}function xo(e,t){let n=0;if(t.length<1e4)e.push(...t);else for(;n<t.length;)e.push(...t.slice(n,n+1e4)),n+=1e4}function ko(e){const t={};let n,r,o,a,i,l,s,c=-1;const u=new vo(e);for(;++c<u.length;){for(;c in t;)c=t[c];if(n=u.get(c),c&&"chunkFlow"===n[1].type&&"listItemPrefix"===u.get(c-1)[1].type&&(l=n[1]._tokenizer.events,o=0,o<l.length&&"lineEndingBlank"===l[o][1].type&&(o+=2),o<l.length&&"content"===l[o][1].type))for(;++o<l.length&&"content"!==l[o][1].type;)"chunkText"===l[o][1].type&&(l[o][1]._isInFirstContentOfListItem=!0,o++);if("enter"===n[0])n[1].contentType&&(Object.assign(t,wo(u,c)),c=t[c],s=!0);else if(n[1]._container){for(o=c,r=void 0;o--&&(a=u.get(o),"lineEnding"===a[1].type||"lineEndingBlank"===a[1].type);)"enter"===a[0]&&(r&&(u.get(r)[1].type="lineEndingBlank"),a[1].type="lineEnding",r=o);r&&(n[1].end={...u.get(r)[1].start},i=u.slice(r,c),i.unshift(n),u.splice(r,c-r+1,i))}}return Lr(e,0,Number.POSITIVE_INFINITY,u.slice(0)),!s}function wo(e,t){const n=e.get(t)[1],r=e.get(t)[2];let o=t-1;const a=[],i=n._tokenizer||r.parser[n.contentType](n.start),l=i.events,s=[],c={};let u,d,m=-1,p=n,f=0,h=0;const g=[h];for(;p;){for(;e.get(++o)[1]!==p;);a.push(o),p._tokenizer||(u=r.sliceStream(p),p.next||u.push(null),d&&i.defineSkip(p.start),p._isInFirstContentOfListItem&&(i._gfmTasklistFirstContentOfListItem=!0),i.write(u),p._isInFirstContentOfListItem&&(i._gfmTasklistFirstContentOfListItem=void 0)),d=p,p=p.next}for(p=n;++m<l.length;)"exit"===l[m][0]&&"enter"===l[m-1][0]&&l[m][1].type===l[m-1][1].type&&l[m][1].start.line!==l[m][1].end.line&&(h=m+1,g.push(h),p._tokenizer=void 0,p.previous=void 0,p=p.next);for(i.events=[],p?(p._tokenizer=void 0,p.previous=void 0):g.pop(),m=g.length;m--;){const t=l.slice(g[m],g[m+1]),n=a.pop();s.push([n,n+t.length-1]),e.splice(n,2,t)}for(s.reverse(),m=-1;++m<s.length;)c[f+s[m][0]]=f+s[m][1],f+=s[m][1]-s[m][0]-1;return c}const Co={resolve:function(e){return ko(e),e},tokenize:function(e,t){let n;return function(t){return e.enter("content"),n=e.enter("chunkContent",{contentType:"content"}),r(t)};function r(t){return null===t?o(t):Yr(t)?e.check(Eo,a,o)(t):(e.consume(t),r)}function o(n){return e.exit("chunkContent"),e.exit("content"),t(n)}function a(t){return e.consume(t),e.exit("chunkContent"),n.next=e.enter("chunkContent",{contentType:"content",previous:n}),n=n.next,r}}},Eo={partial:!0,tokenize:function(e,t,n){const r=this;return function(t){return e.exit("chunkContent"),e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),to(e,o,"linePrefix")};function o(o){if(null===o||Yr(o))return n(o);const a=r.events[r.events.length-1];return!r.parser.constructs.disable.null.includes("codeIndented")&&a&&"linePrefix"===a[1].type&&a[2].sliceSerialize(a[1],!0).length>=4?t(o):e.interrupt(r.parser.constructs.flow,n,t)(o)}}};function So(e,t,n,r,o,a,i,l,s){const c=s||Number.POSITIVE_INFINITY;let u=0;return function(t){if(60===t)return e.enter(r),e.enter(o),e.enter(a),e.consume(t),e.exit(a),d;if(null===t||32===t||41===t||Wr(t))return n(t);return e.enter(r),e.enter(i),e.enter(l),e.enter("chunkString",{contentType:"string"}),f(t)};function d(n){return 62===n?(e.enter(a),e.consume(n),e.exit(a),e.exit(o),e.exit(r),t):(e.enter(l),e.enter("chunkString",{contentType:"string"}),m(n))}function m(t){return 62===t?(e.exit("chunkString"),e.exit(l),d(t)):null===t||60===t||Yr(t)?n(t):(e.consume(t),92===t?p:m)}function p(t){return 60===t||62===t||92===t?(e.consume(t),m):m(t)}function f(o){return u||null!==o&&41!==o&&!Gr(o)?u<c&&40===o?(e.consume(o),u++,f):41===o?(e.consume(o),u--,f):null===o||32===o||40===o||Wr(o)?n(o):(e.consume(o),92===o?h:f):(e.exit("chunkString"),e.exit(l),e.exit(i),e.exit(r),t(o))}function h(t){return 40===t||41===t||92===t?(e.consume(t),f):f(t)}}function Ro(e,t,n,r,o,a){const i=this;let l,s=0;return function(t){return e.enter(r),e.enter(o),e.consume(t),e.exit(o),e.enter(a),c};function c(d){return s>999||null===d||91===d||93===d&&!l||94===d&&!s&&"_hiddenFootnoteSupport"in i.parser.constructs?n(d):93===d?(e.exit(a),e.enter(o),e.consume(d),e.exit(o),e.exit(r),t):Yr(d)?(e.enter("lineEnding"),e.consume(d),e.exit("lineEnding"),c):(e.enter("chunkString",{contentType:"string"}),u(d))}function u(t){return null===t||91===t||93===t||Yr(t)||s++>999?(e.exit("chunkString"),c(t)):(e.consume(t),l||(l=!Zr(t)),92===t?d:u)}function d(t){return 91===t||92===t||93===t?(e.consume(t),s++,u):u(t)}}function Fo(e,t,n,r,o,a){let i;return function(t){if(34===t||39===t||40===t)return e.enter(r),e.enter(o),e.consume(t),e.exit(o),i=40===t?41:t,l;return n(t)};function l(n){return n===i?(e.enter(o),e.consume(n),e.exit(o),e.exit(r),t):(e.enter(a),s(n))}function s(t){return t===i?(e.exit(a),l(i)):null===t?n(t):Yr(t)?(e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),to(e,s,"linePrefix")):(e.enter("chunkString",{contentType:"string"}),c(t))}function c(t){return t===i||null===t||Yr(t)?(e.exit("chunkString"),s(t)):(e.consume(t),92===t?u:c)}function u(t){return t===i||92===t?(e.consume(t),c):c(t)}}function Po(e,t){let n;return function r(o){if(Yr(o))return e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),n=!0,r;if(Zr(o))return to(e,r,n?"linePrefix":"lineSuffix")(o);return t(o)}}const To={name:"definition",tokenize:function(e,t,n){const r=this;let o;return function(t){return e.enter("definition"),function(t){return Ro.call(r,e,a,n,"definitionLabel","definitionLabelMarker","definitionLabelString")(t)}(t)};function a(t){return o=Dr(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)),58===t?(e.enter("definitionMarker"),e.consume(t),e.exit("definitionMarker"),i):n(t)}function i(t){return Gr(t)?Po(e,l)(t):l(t)}function l(t){return So(e,s,n,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(t)}function s(t){return e.attempt(Bo,c,c)(t)}function c(t){return Zr(t)?to(e,u,"whitespace")(t):u(t)}function u(a){return null===a||Yr(a)?(e.exit("definition"),r.parser.defined.push(o),t(a)):n(a)}}},Bo={partial:!0,tokenize:function(e,t,n){return function(t){return Gr(t)?Po(e,r)(t):n(t)};function r(t){return Fo(e,o,n,"definitionTitle","definitionTitleMarker","definitionTitleString")(t)}function o(t){return Zr(t)?to(e,a,"whitespace")(t):a(t)}function a(e){return null===e||Yr(e)?t(e):n(e)}}};const Io={name:"hardBreakEscape",tokenize:function(e,t,n){return function(t){return e.enter("hardBreakEscape"),e.consume(t),r};function r(r){return Yr(r)?(e.exit("hardBreakEscape"),t(r)):n(r)}}};const No={name:"headingAtx",resolve:function(e,t){let n,r,o=e.length-2,a=3;"whitespace"===e[a][1].type&&(a+=2);o-2>a&&"whitespace"===e[o][1].type&&(o-=2);"atxHeadingSequence"===e[o][1].type&&(a===o-1||o-4>a&&"whitespace"===e[o-2][1].type)&&(o-=a+1===o?2:4);o>a&&(n={type:"atxHeadingText",start:e[a][1].start,end:e[o][1].end},r={type:"chunkText",start:e[a][1].start,end:e[o][1].end,contentType:"text"},Lr(e,a,o-a+1,[["enter",n,t],["enter",r,t],["exit",r,t],["exit",n,t]]));return e},tokenize:function(e,t,n){let r=0;return function(t){return e.enter("atxHeading"),function(t){return e.enter("atxHeadingSequence"),o(t)}(t)};function o(t){return 35===t&&r++<6?(e.consume(t),o):null===t||Gr(t)?(e.exit("atxHeadingSequence"),a(t)):n(t)}function a(n){return 35===n?(e.enter("atxHeadingSequence"),i(n)):null===n||Yr(n)?(e.exit("atxHeading"),t(n)):Zr(n)?to(e,a,"whitespace")(n):(e.enter("atxHeadingText"),l(n))}function i(t){return 35===t?(e.consume(t),i):(e.exit("atxHeadingSequence"),a(t))}function l(t){return null===t||35===t||Gr(t)?(e.exit("atxHeadingText"),a(t)):(e.consume(t),l)}}};const Lo=["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"],Oo=["pre","script","style","textarea"],Ao={concrete:!0,name:"htmlFlow",resolveTo:function(e){let t=e.length;for(;t--&&("enter"!==e[t][0]||"htmlFlow"!==e[t][1].type););t>1&&"linePrefix"===e[t-2][1].type&&(e[t][1].start=e[t-2][1].start,e[t+1][1].start=e[t-2][1].start,e.splice(t-2,2));return e},tokenize:function(e,t,n){const r=this;let o,a,i,l,s;return function(t){return function(t){return e.enter("htmlFlow"),e.enter("htmlFlowData"),e.consume(t),c}(t)};function c(l){return 33===l?(e.consume(l),u):47===l?(e.consume(l),a=!0,p):63===l?(e.consume(l),o=3,r.interrupt?t:L):Ur(l)?(e.consume(l),i=String.fromCharCode(l),f):n(l)}function u(a){return 45===a?(e.consume(a),o=2,d):91===a?(e.consume(a),o=5,l=0,m):Ur(a)?(e.consume(a),o=4,r.interrupt?t:L):n(a)}function d(o){return 45===o?(e.consume(o),r.interrupt?t:L):n(o)}function m(o){const a="CDATA[";return o===a.charCodeAt(l++)?(e.consume(o),6===l?r.interrupt?t:S:m):n(o)}function p(t){return Ur(t)?(e.consume(t),i=String.fromCharCode(t),f):n(t)}function f(l){if(null===l||47===l||62===l||Gr(l)){const s=47===l,c=i.toLowerCase();return s||a||!Oo.includes(c)?Lo.includes(i.toLowerCase())?(o=6,s?(e.consume(l),h):r.interrupt?t(l):S(l)):(o=7,r.interrupt&&!r.parser.lazy[r.now().line]?n(l):a?g(l):_(l)):(o=1,r.interrupt?t(l):S(l))}return 45===l||jr(l)?(e.consume(l),i+=String.fromCharCode(l),f):n(l)}function h(o){return 62===o?(e.consume(o),r.interrupt?t:S):n(o)}function g(t){return Zr(t)?(e.consume(t),g):C(t)}function _(t){return 47===t?(e.consume(t),C):58===t||95===t||Ur(t)?(e.consume(t),y):Zr(t)?(e.consume(t),_):C(t)}function y(t){return 45===t||46===t||58===t||95===t||jr(t)?(e.consume(t),y):b(t)}function b(t){return 61===t?(e.consume(t),v):Zr(t)?(e.consume(t),b):_(t)}function v(t){return null===t||60===t||61===t||62===t||96===t?n(t):34===t||39===t?(e.consume(t),s=t,x):Zr(t)?(e.consume(t),v):k(t)}function x(t){return t===s?(e.consume(t),s=null,w):null===t||Yr(t)?n(t):(e.consume(t),x)}function k(t){return null===t||34===t||39===t||47===t||60===t||61===t||62===t||96===t||Gr(t)?b(t):(e.consume(t),k)}function w(e){return 47===e||62===e||Zr(e)?_(e):n(e)}function C(t){return 62===t?(e.consume(t),E):n(t)}function E(t){return null===t||Yr(t)?S(t):Zr(t)?(e.consume(t),E):n(t)}function S(t){return 45===t&&2===o?(e.consume(t),T):60===t&&1===o?(e.consume(t),B):62===t&&4===o?(e.consume(t),O):63===t&&3===o?(e.consume(t),L):93===t&&5===o?(e.consume(t),N):!Yr(t)||6!==o&&7!==o?null===t||Yr(t)?(e.exit("htmlFlowData"),R(t)):(e.consume(t),S):(e.exit("htmlFlowData"),e.check(Mo,A,R)(t))}function R(t){return e.check(zo,F,A)(t)}function F(t){return e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),P}function P(t){return null===t||Yr(t)?R(t):(e.enter("htmlFlowData"),S(t))}function T(t){return 45===t?(e.consume(t),L):S(t)}function B(t){return 47===t?(e.consume(t),i="",I):S(t)}function I(t){if(62===t){const n=i.toLowerCase();return Oo.includes(n)?(e.consume(t),O):S(t)}return Ur(t)&&i.length<8?(e.consume(t),i+=String.fromCharCode(t),I):S(t)}function N(t){return 93===t?(e.consume(t),L):S(t)}function L(t){return 62===t?(e.consume(t),O):45===t&&2===o?(e.consume(t),L):S(t)}function O(t){return null===t||Yr(t)?(e.exit("htmlFlowData"),A(t)):(e.consume(t),O)}function A(n){return e.exit("htmlFlow"),t(n)}}},Mo={partial:!0,tokenize:function(e,t,n){return function(r){return e.enter("lineEnding"),e.consume(r),e.exit("lineEnding"),e.attempt(uo,t,n)}}},zo={partial:!0,tokenize:function(e,t,n){const r=this;return function(t){if(Yr(t))return e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),o;return n(t)};function o(e){return r.parser.lazy[r.now().line]?n(e):t(e)}}};const Ho={name:"htmlText",tokenize:function(e,t,n){const r=this;let o,a,i;return function(t){return e.enter("htmlText"),e.enter("htmlTextData"),e.consume(t),l};function l(t){return 33===t?(e.consume(t),s):47===t?(e.consume(t),v):63===t?(e.consume(t),y):Ur(t)?(e.consume(t),w):n(t)}function s(t){return 45===t?(e.consume(t),c):91===t?(e.consume(t),a=0,p):Ur(t)?(e.consume(t),_):n(t)}function c(t){return 45===t?(e.consume(t),m):n(t)}function u(t){return null===t?n(t):45===t?(e.consume(t),d):Yr(t)?(i=u,I(t)):(e.consume(t),u)}function d(t){return 45===t?(e.consume(t),m):u(t)}function m(e){return 62===e?B(e):45===e?d(e):u(e)}function p(t){const r="CDATA[";return t===r.charCodeAt(a++)?(e.consume(t),6===a?f:p):n(t)}function f(t){return null===t?n(t):93===t?(e.consume(t),h):Yr(t)?(i=f,I(t)):(e.consume(t),f)}function h(t){return 93===t?(e.consume(t),g):f(t)}function g(t){return 62===t?B(t):93===t?(e.consume(t),g):f(t)}function _(t){return null===t||62===t?B(t):Yr(t)?(i=_,I(t)):(e.consume(t),_)}function y(t){return null===t?n(t):63===t?(e.consume(t),b):Yr(t)?(i=y,I(t)):(e.consume(t),y)}function b(e){return 62===e?B(e):y(e)}function v(t){return Ur(t)?(e.consume(t),x):n(t)}function x(t){return 45===t||jr(t)?(e.consume(t),x):k(t)}function k(t){return Yr(t)?(i=k,I(t)):Zr(t)?(e.consume(t),k):B(t)}function w(t){return 45===t||jr(t)?(e.consume(t),w):47===t||62===t||Gr(t)?C(t):n(t)}function C(t){return 47===t?(e.consume(t),B):58===t||95===t||Ur(t)?(e.consume(t),E):Yr(t)?(i=C,I(t)):Zr(t)?(e.consume(t),C):B(t)}function E(t){return 45===t||46===t||58===t||95===t||jr(t)?(e.consume(t),E):S(t)}function S(t){return 61===t?(e.consume(t),R):Yr(t)?(i=S,I(t)):Zr(t)?(e.consume(t),S):C(t)}function R(t){return null===t||60===t||61===t||62===t||96===t?n(t):34===t||39===t?(e.consume(t),o=t,F):Yr(t)?(i=R,I(t)):Zr(t)?(e.consume(t),R):(e.consume(t),P)}function F(t){return t===o?(e.consume(t),o=void 0,T):null===t?n(t):Yr(t)?(i=F,I(t)):(e.consume(t),F)}function P(t){return null===t||34===t||39===t||60===t||61===t||96===t?n(t):47===t||62===t||Gr(t)?C(t):(e.consume(t),P)}function T(e){return 47===e||62===e||Gr(e)?C(e):n(e)}function B(r){return 62===r?(e.consume(r),e.exit("htmlTextData"),e.exit("htmlText"),t):n(r)}function I(t){return e.exit("htmlTextData"),e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),N}function N(t){return Zr(t)?to(e,L,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(t):L(t)}function L(t){return e.enter("htmlTextData"),i(t)}}};const Do={name:"labelEnd",resolveAll:function(e){let t=-1;const n=[];for(;++t<e.length;){const r=e[t][1];if(n.push(e[t]),"labelImage"===r.type||"labelLink"===r.type||"labelEnd"===r.type){const e="labelImage"===r.type?4:2;r.type="data",t+=e}}e.length!==n.length&&Lr(e,0,e.length,n);return e},resolveTo:function(e,t){let n,r,o,a,i=e.length,l=0;for(;i--;)if(n=e[i][1],r){if("link"===n.type||"labelLink"===n.type&&n._inactive)break;"enter"===e[i][0]&&"labelLink"===n.type&&(n._inactive=!0)}else if(o){if("enter"===e[i][0]&&("labelImage"===n.type||"labelLink"===n.type)&&!n._balanced&&(r=i,"labelLink"!==n.type)){l=2;break}}else"labelEnd"===n.type&&(o=i);const s={type:"labelLink"===e[r][1].type?"link":"image",start:{...e[r][1].start},end:{...e[e.length-1][1].end}},c={type:"label",start:{...e[r][1].start},end:{...e[o][1].end}},u={type:"labelText",start:{...e[r+l+2][1].end},end:{...e[o-2][1].start}};return a=[["enter",s,t],["enter",c,t]],a=Or(a,e.slice(r+1,r+l+3)),a=Or(a,[["enter",u,t]]),a=Or(a,io(t.parser.constructs.insideSpan.null,e.slice(r+l+4,o-3),t)),a=Or(a,[["exit",u,t],e[o-2],e[o-1],["exit",c,t]]),a=Or(a,e.slice(o+1)),a=Or(a,[["exit",s,t]]),Lr(e,r,e.length,a),e},tokenize:function(e,t,n){const r=this;let o,a,i=r.events.length;for(;i--;)if(("labelImage"===r.events[i][1].type||"labelLink"===r.events[i][1].type)&&!r.events[i][1]._balanced){o=r.events[i][1];break}return function(t){if(!o)return n(t);if(o._inactive)return u(t);return a=r.parser.defined.includes(Dr(r.sliceSerialize({start:o.end,end:r.now()}))),e.enter("labelEnd"),e.enter("labelMarker"),e.consume(t),e.exit("labelMarker"),e.exit("labelEnd"),l};function l(t){return 40===t?e.attempt(Uo,c,a?c:u)(t):91===t?e.attempt(jo,c,a?s:u)(t):a?c(t):u(t)}function s(t){return e.attempt(Vo,c,u)(t)}function c(e){return t(e)}function u(e){return o._balanced=!0,n(e)}}},Uo={tokenize:function(e,t,n){return function(t){return e.enter("resource"),e.enter("resourceMarker"),e.consume(t),e.exit("resourceMarker"),r};function r(t){return Gr(t)?Po(e,o)(t):o(t)}function o(t){return 41===t?c(t):So(e,a,i,"resourceDestination","resourceDestinationLiteral","resourceDestinationLiteralMarker","resourceDestinationRaw","resourceDestinationString",32)(t)}function a(t){return Gr(t)?Po(e,l)(t):c(t)}function i(e){return n(e)}function l(t){return 34===t||39===t||40===t?Fo(e,s,n,"resourceTitle","resourceTitleMarker","resourceTitleString")(t):c(t)}function s(t){return Gr(t)?Po(e,c)(t):c(t)}function c(r){return 41===r?(e.enter("resourceMarker"),e.consume(r),e.exit("resourceMarker"),e.exit("resource"),t):n(r)}}},jo={tokenize:function(e,t,n){const r=this;return function(t){return Ro.call(r,e,o,a,"reference","referenceMarker","referenceString")(t)};function o(e){return r.parser.defined.includes(Dr(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)))?t(e):n(e)}function a(e){return n(e)}}},Vo={tokenize:function(e,t,n){return function(t){return e.enter("reference"),e.enter("referenceMarker"),e.consume(t),e.exit("referenceMarker"),r};function r(r){return 93===r?(e.enter("referenceMarker"),e.consume(r),e.exit("referenceMarker"),e.exit("reference"),t):n(r)}}};const Wo={name:"labelStartImage",resolveAll:Do.resolveAll,tokenize:function(e,t,n){const r=this;return function(t){return e.enter("labelImage"),e.enter("labelImageMarker"),e.consume(t),e.exit("labelImageMarker"),o};function o(t){return 91===t?(e.enter("labelMarker"),e.consume(t),e.exit("labelMarker"),e.exit("labelImage"),a):n(t)}function a(e){return 94===e&&"_hiddenFootnoteSupport"in r.parser.constructs?n(e):t(e)}}};const $o={name:"labelStartLink",resolveAll:Do.resolveAll,tokenize:function(e,t,n){const r=this;return function(t){return e.enter("labelLink"),e.enter("labelMarker"),e.consume(t),e.exit("labelMarker"),e.exit("labelLink"),o};function o(e){return 94===e&&"_hiddenFootnoteSupport"in r.parser.constructs?n(e):t(e)}}};const qo={name:"lineEnding",tokenize:function(e,t){return function(n){return e.enter("lineEnding"),e.consume(n),e.exit("lineEnding"),to(e,t,"linePrefix")}}};const Xo={name:"thematicBreak",tokenize:function(e,t,n){let r,o=0;return function(t){return e.enter("thematicBreak"),function(e){return r=e,a(e)}(t)};function a(a){return a===r?(e.enter("thematicBreakSequence"),i(a)):o>=3&&(null===a||Yr(a))?(e.exit("thematicBreak"),t(a)):n(a)}function i(t){return t===r?(e.consume(t),o++,i):(e.exit("thematicBreakSequence"),Zr(t)?to(e,a,"whitespace")(t):a(t))}}};const Yo={continuation:{tokenize:function(e,t,n){const r=this;return r.containerState._closeFlow=void 0,e.check(uo,o,a);function o(n){return r.containerState.furtherBlankLines=r.containerState.furtherBlankLines||r.containerState.initialBlankLine,to(e,t,"listItemIndent",r.containerState.size+1)(n)}function a(n){return r.containerState.furtherBlankLines||!Zr(n)?(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,i(n)):(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,e.attempt(Zo,t,i)(n))}function i(o){return r.containerState._closeFlow=!0,r.interrupt=void 0,to(e,e.attempt(Yo,t,n),"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(o)}}},exit:function(e){e.exit(this.containerState.type)},name:"list",tokenize:function(e,t,n){const r=this,o=r.events[r.events.length-1];let a=o&&"linePrefix"===o[1].type?o[2].sliceSerialize(o[1],!0).length:0,i=0;return function(t){const o=r.containerState.type||(42===t||43===t||45===t?"listUnordered":"listOrdered");if("listUnordered"===o?!r.containerState.marker||t===r.containerState.marker:$r(t)){if(r.containerState.type||(r.containerState.type=o,e.enter(o,{_container:!0})),"listUnordered"===o)return e.enter("listItemPrefix"),42===t||45===t?e.check(Xo,n,s)(t):s(t);if(!r.interrupt||49===t)return e.enter("listItemPrefix"),e.enter("listItemValue"),l(t)}return n(t)};function l(t){return $r(t)&&++i<10?(e.consume(t),l):(!r.interrupt||i<2)&&(r.containerState.marker?t===r.containerState.marker:41===t||46===t)?(e.exit("listItemValue"),s(t)):n(t)}function s(t){return e.enter("listItemMarker"),e.consume(t),e.exit("listItemMarker"),r.containerState.marker=r.containerState.marker||t,e.check(uo,r.interrupt?n:c,e.attempt(Go,d,u))}function c(e){return r.containerState.initialBlankLine=!0,a++,d(e)}function u(t){return Zr(t)?(e.enter("listItemPrefixWhitespace"),e.consume(t),e.exit("listItemPrefixWhitespace"),d):n(t)}function d(n){return r.containerState.size=a+r.sliceSerialize(e.exit("listItemPrefix"),!0).length,t(n)}}},Go={partial:!0,tokenize:function(e,t,n){const r=this;return to(e,(function(e){const o=r.events[r.events.length-1];return!Zr(e)&&o&&"listItemPrefixWhitespace"===o[1].type?t(e):n(e)}),"listItemPrefixWhitespace",r.parser.constructs.disable.null.includes("codeIndented")?void 0:5)}},Zo={partial:!0,tokenize:function(e,t,n){const r=this;return to(e,(function(e){const o=r.events[r.events.length-1];return o&&"listItemIndent"===o[1].type&&o[2].sliceSerialize(o[1],!0).length===r.containerState.size?t(e):n(e)}),"listItemIndent",r.containerState.size+1)}};const Jo={name:"setextUnderline",resolveTo:function(e,t){let n,r,o,a=e.length;for(;a--;)if("enter"===e[a][0]){if("content"===e[a][1].type){n=a;break}"paragraph"===e[a][1].type&&(r=a)}else"content"===e[a][1].type&&e.splice(a,1),o||"definition"!==e[a][1].type||(o=a);const i={type:"setextHeading",start:{...e[r][1].start},end:{...e[e.length-1][1].end}};e[r][1].type="setextHeadingText",o?(e.splice(r,0,["enter",i,t]),e.splice(o+1,0,["exit",e[n][1],t]),e[n][1].end={...e[o][1].end}):e[n][1]=i;return e.push(["exit",i,t]),e},tokenize:function(e,t,n){const r=this;let o;return function(t){let i,l=r.events.length;for(;l--;)if("lineEnding"!==r.events[l][1].type&&"linePrefix"!==r.events[l][1].type&&"content"!==r.events[l][1].type){i="paragraph"===r.events[l][1].type;break}if(!r.parser.lazy[r.now().line]&&(r.interrupt||i))return e.enter("setextHeadingLine"),o=t,function(t){return e.enter("setextHeadingLineSequence"),a(t)}(t);return n(t)};function a(t){return t===o?(e.consume(t),a):(e.exit("setextHeadingLineSequence"),Zr(t)?to(e,i,"lineSuffix")(t):i(t))}function i(r){return null===r||Yr(r)?(e.exit("setextHeadingLine"),t(r)):n(r)}}};const Ko={tokenize:function(e){const t=this,n=e.attempt(uo,(function(r){if(null===r)return void e.consume(r);return e.enter("lineEndingBlank"),e.consume(r),e.exit("lineEndingBlank"),t.currentConstruct=void 0,n}),e.attempt(this.parser.constructs.flowInitial,r,to(e,e.attempt(this.parser.constructs.flow,r,e.attempt(Co,r)),"linePrefix")));return n;function r(r){if(null!==r)return e.enter("lineEnding"),e.consume(r),e.exit("lineEnding"),t.currentConstruct=void 0,n;e.consume(r)}}};const Qo={resolveAll:ra()},ea=na("string"),ta=na("text");function na(e){return{resolveAll:ra("text"===e?oa:void 0),tokenize:function(t){const n=this,r=this.parser.constructs[e],o=t.attempt(r,a,i);return a;function a(e){return s(e)?o(e):i(e)}function i(e){if(null!==e)return t.enter("data"),t.consume(e),l;t.consume(e)}function l(e){return s(e)?(t.exit("data"),o(e)):(t.consume(e),l)}function s(e){if(null===e)return!0;const t=r[e];let o=-1;if(t)for(;++o<t.length;){const e=t[o];if(!e.previous||e.previous.call(n,n.previous))return!0}return!1}}}}function ra(e){return function(t,n){let r,o=-1;for(;++o<=t.length;)void 0===r?t[o]&&"data"===t[o][1].type&&(r=o,o++):t[o]&&"data"===t[o][1].type||(o!==r+2&&(t[r][1].end=t[o-1][1].end,t.splice(r+2,o-r-2),o=r+2),r=void 0);return e?e(t,n):t}}function oa(e,t){let n=0;for(;++n<=e.length;)if((n===e.length||"lineEnding"===e[n][1].type)&&"data"===e[n-1][1].type){const r=e[n-1][1],o=t.sliceStream(r);let a,i=o.length,l=-1,s=0;for(;i--;){const e=o[i];if("string"==typeof e){for(l=e.length;32===e.charCodeAt(l-1);)s++,l--;if(l)break;l=-1}else if(-2===e)a=!0,s++;else if(-1!==e){i++;break}}if(s){const o={type:n===e.length||a||s<2?"lineSuffix":"hardBreakTrailing",start:{_bufferIndex:i?l:r.start._bufferIndex+l,_index:r.start._index+i,line:r.end.line,column:r.end.column-s,offset:r.end.offset-s},end:{...r.end}};r.end={...o.start},r.start.offset===r.end.offset?Object.assign(r,o):(e.splice(n,0,["enter",o,t],["exit",o,t]),n+=2)}n++}return e}const aa={42:Yo,43:Yo,45:Yo,48:Yo,49:Yo,50:Yo,51:Yo,52:Yo,53:Yo,54:Yo,55:Yo,56:Yo,57:Yo,62:mo},ia={91:To},la={[-2]:_o,[-1]:_o,32:_o},sa={35:No,42:Xo,45:[Jo,Xo],60:Ao,61:Jo,95:Xo,96:go,126:go},ca={38:fo,92:po},ua={[-5]:qo,[-4]:qo,[-3]:qo,33:Wo,38:fo,42:lo,60:[co,Ho],91:$o,92:[Io,po],93:Do,95:lo,96:bo},da={null:[lo,Qo]};var ma=Object.freeze({__proto__:null,document:aa,contentInitial:ia,flowInitial:la,flow:sa,string:ca,text:ua,insideSpan:da,attentionMarkers:{null:[42,95]},disable:{null:[]}});function pa(e,t,n){let r={_bufferIndex:-1,_index:0,line:n&&n.line||1,column:n&&n.column||1,offset:n&&n.offset||0};const o={},a=[];let i=[],l=[];const s={attempt:g((function(e,t){_(e,t.from)})),check:g(h),consume:function(e){Yr(e)?(r.line++,r.column=1,r.offset+=-3===e?2:1,y()):-1!==e&&(r.column++,r.offset++);r._bufferIndex<0?r._index++:(r._bufferIndex++,r._bufferIndex===i[r._index].length&&(r._bufferIndex=-1,r._index++));c.previous=e},enter:function(e,t){const n=t||{};return n.type=e,n.start=m(),c.events.push(["enter",n,c]),l.push(n),n},exit:function(e){const t=l.pop();return t.end=m(),c.events.push(["exit",t,c]),t},interrupt:g(h,{interrupt:!0})},c={code:null,containerState:{},defineSkip:function(e){o[e.line]=e.column,y()},events:[],now:m,parser:e,previous:null,sliceSerialize:function(e,t){return function(e,t){let n=-1;const r=[];let o;for(;++n<e.length;){const a=e[n];let i;if("string"==typeof a)i=a;else switch(a){case-5:i="\r";break;case-4:i="\n";break;case-3:i="\r\n";break;case-2:i=t?" ":"\t";break;case-1:if(!t&&o)continue;i=" ";break;default:i=String.fromCharCode(a)}o=-2===a,r.push(i)}return r.join("")}(d(e),t)},sliceStream:d,write:function(e){if(i=Or(i,e),p(),null!==i[i.length-1])return[];return _(t,0),c.events=io(a,c.events,c),c.events}};let u=t.tokenize.call(c,s);return t.resolveAll&&a.push(t),c;function d(e){return function(e,t){const n=t.start._index,r=t.start._bufferIndex,o=t.end._index,a=t.end._bufferIndex;let i;if(n===o)i=[e[n].slice(r,a)];else{if(i=e.slice(n,o),r>-1){const e=i[0];"string"==typeof e?i[0]=e.slice(r):i.shift()}a>0&&i.push(e[o].slice(0,a))}return i}(i,e)}function m(){const{_bufferIndex:e,_index:t,line:n,column:o,offset:a}=r;return{_bufferIndex:e,_index:t,line:n,column:o,offset:a}}function p(){let e;for(;r._index<i.length;){const t=i[r._index];if("string"==typeof t)for(e=r._index,r._bufferIndex<0&&(r._bufferIndex=0);r._index===e&&r._bufferIndex<t.length;)f(t.charCodeAt(r._bufferIndex));else f(t)}}function f(e){u=u(e)}function h(e,t){t.restore()}function g(e,t){return function(n,o,a){let i,u,d,p;return Array.isArray(n)?f(n):"tokenize"in n?f([n]):function(e){return t;function t(t){const n=null!==t&&e[t],r=null!==t&&e.null;return f([...Array.isArray(n)?n:n?[n]:[],...Array.isArray(r)?r:r?[r]:[]])(t)}}(n);function f(e){return i=e,u=0,0===e.length?a:h(e[u])}function h(e){return function(n){p=function(){const e=m(),t=c.previous,n=c.currentConstruct,o=c.events.length,a=Array.from(l);return{from:o,restore:i};function i(){r=e,c.previous=t,c.currentConstruct=n,c.events.length=o,l=a,y()}}(),d=e,e.partial||(c.currentConstruct=e);if(e.name&&c.parser.constructs.disable.null.includes(e.name))return _();return e.tokenize.call(t?Object.assign(Object.create(c),t):c,s,g,_)(n)}}function g(t){return e(d,p),o}function _(e){return p.restore(),++u<i.length?h(i[u]):a}}}function _(e,t){e.resolveAll&&!a.includes(e)&&a.push(e),e.resolve&&Lr(c.events,t,c.events.length-t,e.resolve(c.events.slice(t),c)),e.resolveTo&&(c.events=e.resolveTo(c.events,c))}function y(){r.line in o&&r.column<2&&(r.column=o[r.line],r.offset+=o[r.line]-1)}}function fa(e){const t=function(e){const t={};let n=-1;for(;++n<e.length;)Mr(t,e[n]);return t}([ma,...(e||{}).extensions||[]]),n={constructs:t,content:r(no),defined:[],document:r(ro),flow:r(Ko),lazy:{},string:r(ea),text:r(ta)};return n;function r(e){return function(t){return pa(n,e,t)}}}const ha=/[\0\t\n\r]/g;const ga=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function _a(e,t,n){if(t)return t;if(35===n.charCodeAt(0)){const e=n.charCodeAt(1),t=120===e||88===e;return Hr(n.slice(t?2:1),t?16:10)}return Nr(n)||e}const ya={}.hasOwnProperty;function ba(e,t,n){return"string"!=typeof t&&(n=t,t=void 0),function(e){const t={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:a(te),autolinkProtocol:E,autolinkEmail:E,atxHeading:a(J),blockQuote:a(q),characterEscape:E,characterReference:E,codeFenced:a(X),codeFencedFenceInfo:i,codeFencedFenceMeta:i,codeIndented:a(X,i),codeText:a(Y,i),codeTextData:E,data:E,codeFlowValue:E,definition:a(G),definitionDestinationString:i,definitionLabelString:i,definitionTitleString:i,emphasis:a(Z),hardBreakEscape:a(K),hardBreakTrailing:a(K),htmlFlow:a(Q,i),htmlFlowData:E,htmlText:a(Q,i),htmlTextData:E,image:a(ee),label:i,link:a(te),listItem:a(re),listItemValue:m,listOrdered:a(ne,d),listUnordered:a(ne),paragraph:a(oe),reference:H,referenceString:i,resourceDestinationString:i,resourceTitleString:i,setextHeading:a(J),strong:a(ae),thematicBreak:a(le)},exit:{atxHeading:s(),atxHeadingSequence:x,autolink:s(),autolinkEmail:$,autolinkProtocol:W,blockQuote:s(),characterEscapeValue:S,characterReferenceMarkerHexadecimal:U,characterReferenceMarkerNumeric:U,characterReferenceValue:j,characterReference:V,codeFenced:s(g),codeFencedFence:h,codeFencedFenceInfo:p,codeFencedFenceMeta:f,codeFlowValue:S,codeIndented:s(_),codeText:s(B),codeTextData:S,data:S,definition:s(),definitionDestinationString:v,definitionLabelString:y,definitionTitleString:b,emphasis:s(),hardBreakEscape:s(F),hardBreakTrailing:s(F),htmlFlow:s(P),htmlFlowData:S,htmlText:s(T),htmlTextData:S,image:s(N),label:O,labelText:L,lineEnding:R,link:s(I),listItem:s(),listOrdered:s(),listUnordered:s(),paragraph:s(),referenceString:D,resourceDestinationString:A,resourceTitleString:M,resource:z,setextHeading:s(C),setextHeadingLineSequence:w,setextHeadingText:k,strong:s(),thematicBreak:s()}};xa(t,(e||{}).mdastExtensions||[]);const n={};return r;function r(e){let r={type:"root",children:[]};const a={stack:[r],tokenStack:[],config:t,enter:l,exit:c,buffer:i,resume:u,data:n},s=[];let d=-1;for(;++d<e.length;)if("listOrdered"===e[d][1].type||"listUnordered"===e[d][1].type)if("enter"===e[d][0])s.push(d);else{d=o(e,s.pop(),d)}for(d=-1;++d<e.length;){const n=t[e[d][0]];ya.call(n,e[d][1].type)&&n[e[d][1].type].call(Object.assign({sliceSerialize:e[d][2].sliceSerialize},a),e[d][1])}if(a.tokenStack.length>0){const e=a.tokenStack[a.tokenStack.length-1];(e[1]||wa).call(a,void 0,e[0])}for(r.position={start:va(e.length>0?e[0][1].start:{line:1,column:1,offset:0}),end:va(e.length>0?e[e.length-2][1].end:{line:1,column:1,offset:0})},d=-1;++d<t.transforms.length;)r=t.transforms[d](r)||r;return r}function o(e,t,n){let r,o,a,i,l=t-1,s=-1,c=!1;for(;++l<=n;){const t=e[l];switch(t[1].type){case"listUnordered":case"listOrdered":case"blockQuote":"enter"===t[0]?s++:s--,i=void 0;break;case"lineEndingBlank":"enter"===t[0]&&(!r||i||s||a||(a=l),i=void 0);break;case"linePrefix":case"listItemValue":case"listItemMarker":case"listItemPrefix":case"listItemPrefixWhitespace":break;default:i=void 0}if(!s&&"enter"===t[0]&&"listItemPrefix"===t[1].type||-1===s&&"exit"===t[0]&&("listUnordered"===t[1].type||"listOrdered"===t[1].type)){if(r){let i=l;for(o=void 0;i--;){const t=e[i];if("lineEnding"===t[1].type||"lineEndingBlank"===t[1].type){if("exit"===t[0])continue;o&&(e[o][1].type="lineEndingBlank",c=!0),t[1].type="lineEnding",o=i}else if("linePrefix"!==t[1].type&&"blockQuotePrefix"!==t[1].type&&"blockQuotePrefixWhitespace"!==t[1].type&&"blockQuoteMarker"!==t[1].type&&"listItemIndent"!==t[1].type)break}a&&(!o||a<o)&&(r._spread=!0),r.end=Object.assign({},o?e[o][1].start:t[1].end),e.splice(o||l,0,["exit",r,t[2]]),l++,n++}if("listItemPrefix"===t[1].type){const o={type:"listItem",_spread:!1,start:Object.assign({},t[1].start),end:void 0};r=o,e.splice(l,0,["enter",o,t[2]]),l++,n++,a=void 0,i=!0}}}return e[t][1]._spread=c,n}function a(e,t){return n;function n(n){l.call(this,e(n),n),t&&t.call(this,n)}}function i(){this.stack.push({type:"fragment",children:[]})}function l(e,t,n){this.stack[this.stack.length-1].children.push(e),this.stack.push(e),this.tokenStack.push([t,n||void 0]),e.position={start:va(t.start),end:void 0}}function s(e){return t;function t(t){e&&e.call(this,t),c.call(this,t)}}function c(e,t){const n=this.stack.pop(),r=this.tokenStack.pop();if(!r)throw new Error("Cannot close `"+e.type+"` ("+ar({start:e.start,end:e.end})+"): it’s not open");if(r[0].type!==e.type)if(t)t.call(this,e,r[0]);else{(r[1]||wa).call(this,e,r[0])}n.position.end=va(e.end)}function u(){return function(e,t){const n=t||Pr;return Tr(e,"boolean"!=typeof n.includeImageAlt||n.includeImageAlt,"boolean"!=typeof n.includeHtml||n.includeHtml)}(this.stack.pop())}function d(){this.data.expectingFirstListItemValue=!0}function m(e){if(this.data.expectingFirstListItemValue){this.stack[this.stack.length-2].start=Number.parseInt(this.sliceSerialize(e),10),this.data.expectingFirstListItemValue=void 0}}function p(){const e=this.resume();this.stack[this.stack.length-1].lang=e}function f(){const e=this.resume();this.stack[this.stack.length-1].meta=e}function h(){this.data.flowCodeInside||(this.buffer(),this.data.flowCodeInside=!0)}function g(){const e=this.resume();this.stack[this.stack.length-1].value=e.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,""),this.data.flowCodeInside=void 0}function _(){const e=this.resume();this.stack[this.stack.length-1].value=e.replace(/(\r?\n|\r)$/g,"")}function y(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.label=t,n.identifier=Dr(this.sliceSerialize(e)).toLowerCase()}function b(){const e=this.resume();this.stack[this.stack.length-1].title=e}function v(){const e=this.resume();this.stack[this.stack.length-1].url=e}function x(e){const t=this.stack[this.stack.length-1];if(!t.depth){const n=this.sliceSerialize(e).length;t.depth=n}}function k(){this.data.setextHeadingSlurpLineEnding=!0}function w(e){this.stack[this.stack.length-1].depth=61===this.sliceSerialize(e).codePointAt(0)?1:2}function C(){this.data.setextHeadingSlurpLineEnding=void 0}function E(e){const t=this.stack[this.stack.length-1].children;let n=t[t.length-1];n&&"text"===n.type||(n=ie(),n.position={start:va(e.start),end:void 0},t.push(n)),this.stack.push(n)}function S(e){const t=this.stack.pop();t.value+=this.sliceSerialize(e),t.position.end=va(e.end)}function R(e){const n=this.stack[this.stack.length-1];if(this.data.atHardBreak){return n.children[n.children.length-1].position.end=va(e.end),void(this.data.atHardBreak=void 0)}!this.data.setextHeadingSlurpLineEnding&&t.canContainEols.includes(n.type)&&(E.call(this,e),S.call(this,e))}function F(){this.data.atHardBreak=!0}function P(){const e=this.resume();this.stack[this.stack.length-1].value=e}function T(){const e=this.resume();this.stack[this.stack.length-1].value=e}function B(){const e=this.resume();this.stack[this.stack.length-1].value=e}function I(){const e=this.stack[this.stack.length-1];if(this.data.inReference){const t=this.data.referenceType||"shortcut";e.type+="Reference",e.referenceType=t,delete e.url,delete e.title}else delete e.identifier,delete e.label;this.data.referenceType=void 0}function N(){const e=this.stack[this.stack.length-1];if(this.data.inReference){const t=this.data.referenceType||"shortcut";e.type+="Reference",e.referenceType=t,delete e.url,delete e.title}else delete e.identifier,delete e.label;this.data.referenceType=void 0}function L(e){const t=this.sliceSerialize(e),n=this.stack[this.stack.length-2];n.label=function(e){return e.replace(ga,_a)}(t),n.identifier=Dr(t).toLowerCase()}function O(){const e=this.stack[this.stack.length-1],t=this.resume(),n=this.stack[this.stack.length-1];if(this.data.inReference=!0,"link"===n.type){const t=e.children;n.children=t}else n.alt=t}function A(){const e=this.resume();this.stack[this.stack.length-1].url=e}function M(){const e=this.resume();this.stack[this.stack.length-1].title=e}function z(){this.data.inReference=void 0}function H(){this.data.referenceType="collapsed"}function D(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.label=t,n.identifier=Dr(this.sliceSerialize(e)).toLowerCase(),this.data.referenceType="full"}function U(e){this.data.characterReferenceType=e.type}function j(e){const t=this.sliceSerialize(e),n=this.data.characterReferenceType;let r;if(n)r=Hr(t,"characterReferenceMarkerNumeric"===n?10:16),this.data.characterReferenceType=void 0;else{r=Nr(t)}this.stack[this.stack.length-1].value+=r}function V(e){this.stack.pop().position.end=va(e.end)}function W(e){S.call(this,e);this.stack[this.stack.length-1].url=this.sliceSerialize(e)}function $(e){S.call(this,e);this.stack[this.stack.length-1].url="mailto:"+this.sliceSerialize(e)}function q(){return{type:"blockquote",children:[]}}function X(){return{type:"code",lang:null,meta:null,value:""}}function Y(){return{type:"inlineCode",value:""}}function G(){return{type:"definition",identifier:"",label:null,title:null,url:""}}function Z(){return{type:"emphasis",children:[]}}function J(){return{type:"heading",depth:0,children:[]}}function K(){return{type:"break"}}function Q(){return{type:"html",value:""}}function ee(){return{type:"image",title:null,url:"",alt:null}}function te(){return{type:"link",title:null,url:"",children:[]}}function ne(e){return{type:"list",ordered:"listOrdered"===e.type,start:null,spread:e._spread,children:[]}}function re(e){return{type:"listItem",spread:e._spread,checked:null,children:[]}}function oe(){return{type:"paragraph",children:[]}}function ae(){return{type:"strong",children:[]}}function ie(){return{type:"text",value:""}}function le(){return{type:"thematicBreak"}}}(n)(function(e){for(;!ko(e););return e}(fa(n).document().write(function(){let e,t=1,n="",r=!0;return function(o,a,i){const l=[];let s,c,u,d,m;for(o=n+("string"==typeof o?o.toString():new TextDecoder(a||void 0).decode(o)),u=0,n="",r&&(65279===o.charCodeAt(0)&&u++,r=void 0);u<o.length;){if(ha.lastIndex=u,s=ha.exec(o),d=s&&void 0!==s.index?s.index:o.length,m=o.charCodeAt(d),!s){n=o.slice(u);break}if(10===m&&u===d&&e)l.push(-3),e=void 0;else switch(e&&(l.push(-5),e=void 0),u<d&&(l.push(o.slice(u,d)),t+=d-u),m){case 0:l.push(65533),t++;break;case 9:for(c=4*Math.ceil(t/4),l.push(-2);t++<c;)l.push(-1);break;case 10:l.push(-4),t=1;break;default:e=!0,t=1}u=d+1}return i&&(e&&l.push(-5),n&&l.push(n),l.push(null)),l}}()(e,t,!0))))}function va(e){return{line:e.line,column:e.column,offset:e.offset}}function xa(e,t){let n=-1;for(;++n<t.length;){const r=t[n];Array.isArray(r)?xa(e,r):ka(e,r)}}function ka(e,t){let n;for(n in t)if(ya.call(t,n))switch(n){case"canContainEols":{const r=t[n];r&&e[n].push(...r);break}case"transforms":{const r=t[n];r&&e[n].push(...r);break}case"enter":case"exit":{const r=t[n];r&&Object.assign(e[n],r);break}}}function wa(e,t){throw e?new Error("Cannot close `"+e.type+"` ("+ar({start:e.start,end:e.end})+"): a different token (`"+t.type+"`, "+ar({start:t.start,end:t.end})+") is open"):new Error("Cannot close document, a token (`"+t.type+"`, "+ar({start:t.start,end:t.end})+") is still open")}function Ca(e){const t=this;t.parser=function(n){return ba(n,{...t.data("settings"),...e,extensions:t.data("micromarkExtensions")||[],mdastExtensions:t.data("fromMarkdownExtensions")||[]})}}function Ea(e,t){const n=t.referenceType;let r="]";if("collapsed"===n?r+="[]":"full"===n&&(r+="["+(t.label||t.identifier)+"]"),"imageReference"===t.type)return[{type:"text",value:"!["+t.alt+r}];const o=e.all(t),a=o[0];a&&"text"===a.type?a.value="["+a.value:o.unshift({type:"text",value:"["});const i=o[o.length-1];return i&&"text"===i.type?i.value+=r:o.push({type:"text",value:r}),o}function Sa(e){const t=e.spread;return null==t?e.children.length>1:t}function Ra(e){const t=String(e),n=/\r?\n|\r/g;let r=n.exec(t),o=0;const a=[];for(;r;)a.push(Fa(t.slice(o,r.index),o>0,!0),r[0]),o=r.index+r[0].length,r=n.exec(t);return a.push(Fa(t.slice(o),o>0,!1)),a.join("")}function Fa(e,t,n){let r=0,o=e.length;if(t){let t=e.codePointAt(r);for(;9===t||32===t;)r++,t=e.codePointAt(r)}if(n){let t=e.codePointAt(o-1);for(;9===t||32===t;)o--,t=e.codePointAt(o-1)}return o>r?e.slice(r,o):""}const Pa={blockquote:function(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)},break:function(e,t){const n={type:"element",tagName:"br",properties:{},children:[]};return e.patch(t,n),[e.applyData(t,n),{type:"text",value:"\n"}]},code:function(e,t){const n=t.value?t.value+"\n":"",r={};t.lang&&(r.className=["language-"+t.lang]);let o={type:"element",tagName:"code",properties:r,children:[{type:"text",value:n}]};return t.meta&&(o.data={meta:t.meta}),e.patch(t,o),o=e.applyData(t,o),o={type:"element",tagName:"pre",properties:{},children:[o]},e.patch(t,o),o},delete:function(e,t){const n={type:"element",tagName:"del",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)},emphasis:function(e,t){const n={type:"element",tagName:"em",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)},footnoteReference:function(e,t){const n="string"==typeof e.options.clobberPrefix?e.options.clobberPrefix:"user-content-",r=String(t.identifier).toUpperCase(),o=eo(r.toLowerCase()),a=e.footnoteOrder.indexOf(r);let i,l=e.footnoteCounts.get(r);void 0===l?(l=0,e.footnoteOrder.push(r),i=e.footnoteOrder.length):i=a+1,l+=1,e.footnoteCounts.set(r,l);const s={type:"element",tagName:"a",properties:{href:"#"+n+"fn-"+o,id:n+"fnref-"+o+(l>1?"-"+l:""),dataFootnoteRef:!0,ariaDescribedBy:["footnote-label"]},children:[{type:"text",value:String(i)}]};e.patch(t,s);const c={type:"element",tagName:"sup",properties:{},children:[s]};return e.patch(t,c),e.applyData(t,c)},heading:function(e,t){const n={type:"element",tagName:"h"+t.depth,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)},html:function(e,t){if(e.options.allowDangerousHtml){const n={type:"raw",value:t.value};return e.patch(t,n),e.applyData(t,n)}},imageReference:function(e,t){const n=String(t.identifier).toUpperCase(),r=e.definitionById.get(n);if(!r)return Ea(e,t);const o={src:eo(r.url||""),alt:t.alt};null!==r.title&&void 0!==r.title&&(o.title=r.title);const a={type:"element",tagName:"img",properties:o,children:[]};return e.patch(t,a),e.applyData(t,a)},image:function(e,t){const n={src:eo(t.url)};null!==t.alt&&void 0!==t.alt&&(n.alt=t.alt),null!==t.title&&void 0!==t.title&&(n.title=t.title);const r={type:"element",tagName:"img",properties:n,children:[]};return e.patch(t,r),e.applyData(t,r)},inlineCode:function(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)},linkReference:function(e,t){const n=String(t.identifier).toUpperCase(),r=e.definitionById.get(n);if(!r)return Ea(e,t);const o={href:eo(r.url||"")};null!==r.title&&void 0!==r.title&&(o.title=r.title);const a={type:"element",tagName:"a",properties:o,children:e.all(t)};return e.patch(t,a),e.applyData(t,a)},link:function(e,t){const n={href:eo(t.url)};null!==t.title&&void 0!==t.title&&(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)},listItem:function(e,t,n){const r=e.all(t),o=n?function(e){let t=!1;if("list"===e.type){t=e.spread||!1;const n=e.children;let r=-1;for(;!t&&++r<n.length;)t=Sa(n[r])}return t}(n):Sa(t),a={},i=[];if("boolean"==typeof t.checked){const e=r[0];let n;e&&"element"===e.type&&"p"===e.tagName?n=e:(n={type:"element",tagName:"p",properties:{},children:[]},r.unshift(n)),n.children.length>0&&n.children.unshift({type:"text",value:" "}),n.children.unshift({type:"element",tagName:"input",properties:{type:"checkbox",checked:t.checked,disabled:!0},children:[]}),a.className=["task-list-item"]}let l=-1;for(;++l<r.length;){const e=r[l];(o||0!==l||"element"!==e.type||"p"!==e.tagName)&&i.push({type:"text",value:"\n"}),"element"!==e.type||"p"!==e.tagName||o?i.push(e):i.push(...e.children)}const s=r[r.length-1];s&&(o||"element"!==s.type||"p"!==s.tagName)&&i.push({type:"text",value:"\n"});const c={type:"element",tagName:"li",properties:a,children:i};return e.patch(t,c),e.applyData(t,c)},list:function(e,t){const n={},r=e.all(t);let o=-1;for("number"==typeof t.start&&1!==t.start&&(n.start=t.start);++o<r.length;){const e=r[o];if("element"===e.type&&"li"===e.tagName&&e.properties&&Array.isArray(e.properties.className)&&e.properties.className.includes("task-list-item")){n.className=["contains-task-list"];break}}const a={type:"element",tagName:t.ordered?"ol":"ul",properties:n,children:e.wrap(r,!0)};return e.patch(t,a),e.applyData(t,a)},paragraph:function(e,t){const n={type:"element",tagName:"p",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)},root:function(e,t){const n={type:"root",children:e.wrap(e.all(t))};return e.patch(t,n),e.applyData(t,n)},strong:function(e,t){const n={type:"element",tagName:"strong",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)},table:function(e,t){const n=e.all(t),r=n.shift(),o=[];if(r){const n={type:"element",tagName:"thead",properties:{},children:e.wrap([r],!0)};e.patch(t.children[0],n),o.push(n)}if(n.length>0){const r={type:"element",tagName:"tbody",properties:{},children:e.wrap(n,!0)},a=rr(t.children[1]),i=nr(t.children[t.children.length-1]);a&&i&&(r.position={start:a,end:i}),o.push(r)}const a={type:"element",tagName:"table",properties:{},children:e.wrap(o,!0)};return e.patch(t,a),e.applyData(t,a)},tableCell:function(e,t){const n={type:"element",tagName:"td",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)},tableRow:function(e,t,n){const r=n?n.children:void 0,o=0===(r?r.indexOf(t):1)?"th":"td",a=n&&"table"===n.type?n.align:void 0,i=a?a.length:t.children.length;let l=-1;const s=[];for(;++l<i;){const n=t.children[l],r={},i=a?a[l]:void 0;i&&(r.align=i);let c={type:"element",tagName:o,properties:r,children:[]};n&&(c.children=e.all(n),e.patch(n,c),c=e.applyData(n,c)),s.push(c)}const c={type:"element",tagName:"tr",properties:{},children:e.wrap(s,!0)};return e.patch(t,c),e.applyData(t,c)},text:function(e,t){const n={type:"text",value:Ra(String(t.value))};return e.patch(t,n),e.applyData(t,n)},thematicBreak:function(e,t){const n={type:"element",tagName:"hr",properties:{},children:[]};return e.patch(t,n),e.applyData(t,n)},toml:Ta,yaml:Ta,definition:Ta,footnoteDefinition:Ta};function Ta(){}const Ba="object"==typeof self?self:globalThis,Ia=e=>((e,t)=>{const n=(t,n)=>(e.set(n,t),t),r=o=>{if(e.has(o))return e.get(o);const[a,i]=t[o];switch(a){case 0:case-1:return n(i,o);case 1:{const e=n([],o);for(const t of i)e.push(r(t));return e}case 2:{const e=n({},o);for(const[t,n]of i)e[r(t)]=r(n);return e}case 3:return n(new Date(i),o);case 4:{const{source:e,flags:t}=i;return n(new RegExp(e,t),o)}case 5:{const e=n(new Map,o);for(const[t,n]of i)e.set(r(t),r(n));return e}case 6:{const e=n(new Set,o);for(const t of i)e.add(r(t));return e}case 7:{const{name:e,message:t}=i;return n(new Ba[e](t),o)}case 8:return n(BigInt(i),o);case"BigInt":return n(Object(BigInt(i)),o)}return n(new Ba[a](i),o)};return r})(new Map,e)(0),Na="",{toString:La}={},{keys:Oa}=Object,Aa=e=>{const t=typeof e;if("object"!==t||!e)return[0,t];const n=La.call(e).slice(8,-1);switch(n){case"Array":return[1,Na];case"Object":return[2,Na];case"Date":return[3,Na];case"RegExp":return[4,Na];case"Map":return[5,Na];case"Set":return[6,Na]}return n.includes("Array")?[1,n]:n.includes("Error")?[7,n]:[2,n]},Ma=([e,t])=>0===e&&("function"===t||"symbol"===t),za=(e,{json:t,lossy:n}={})=>{const r=[];return((e,t,n,r)=>{const o=(e,t)=>{const o=r.push(e)-1;return n.set(t,o),o},a=r=>{if(n.has(r))return n.get(r);let[i,l]=Aa(r);switch(i){case 0:{let t=r;switch(l){case"bigint":i=8,t=r.toString();break;case"function":case"symbol":if(e)throw new TypeError("unable to serialize "+l);t=null;break;case"undefined":return o([-1],r)}return o([i,t],r)}case 1:{if(l)return o([l,[...r]],r);const e=[],t=o([i,e],r);for(const t of r)e.push(a(t));return t}case 2:{if(l)switch(l){case"BigInt":return o([l,r.toString()],r);case"Boolean":case"Number":case"String":return o([l,r.valueOf()],r)}if(t&&"toJSON"in r)return a(r.toJSON());const n=[],s=o([i,n],r);for(const t of Oa(r))!e&&Ma(Aa(r[t]))||n.push([a(t),a(r[t])]);return s}case 3:return o([i,r.toISOString()],r);case 4:{const{source:e,flags:t}=r;return o([i,{source:e,flags:t}],r)}case 5:{const t=[],n=o([i,t],r);for(const[n,o]of r)(e||!Ma(Aa(n))&&!Ma(Aa(o)))&&t.push([a(n),a(o)]);return n}case 6:{const t=[],n=o([i,t],r);for(const n of r)!e&&Ma(Aa(n))||t.push(a(n));return n}}const{message:s}=r;return o([i,{name:l,message:s}],r)};return a})(!(t||n),!!t,new Map,r)(e),r};var Ha="function"==typeof structuredClone?(e,t)=>t&&("json"in t||"lossy"in t)?Ia(za(e,t)):structuredClone(e):(e,t)=>Ia(za(e,t));function Da(e,t){const n=[{type:"text",value:"↩"}];return t>1&&n.push({type:"element",tagName:"sup",properties:{},children:[{type:"text",value:String(t)}]}),n}function Ua(e,t){return"Back to reference "+(e+1)+(t>1?"-"+t:"")}const ja=function(e){if(null==e)return Wa;if("function"==typeof e)return Va(e);if("object"==typeof e)return Array.isArray(e)?function(e){const t=[];let n=-1;for(;++n<e.length;)t[n]=ja(e[n]);return Va(r);function r(...e){let n=-1;for(;++n<t.length;)if(t[n].apply(this,e))return!0;return!1}}(e):function(e){const t=e;return Va(n);function n(n){const r=n;let o;for(o in e)if(r[o]!==t[o])return!1;return!0}}(e);if("string"==typeof e)return function(e){return Va(t);function t(t){return t&&t.type===e}}(e);throw new Error("Expected function, string, or object as test")};function Va(e){return function(t,n,r){return Boolean(function(e){return null!==e&&"object"==typeof e&&"type"in e}(t)&&e.call(this,t,"number"==typeof n?n:void 0,r||void 0))}}function Wa(){return!0}const $a=[],qa=!0,Xa=!1;function Ya(e,t,n,r){let o;"function"==typeof t&&"function"!=typeof n?(r=n,n=t):o=t;const a=ja(o),i=r?-1:1;!function e(o,l,s){const c=o&&"object"==typeof o?o:{};if("string"==typeof c.type){const e="string"==typeof c.tagName?c.tagName:"string"==typeof c.name?c.name:void 0;Object.defineProperty(u,"name",{value:"node ("+o.type+(e?"<"+e+">":"")+")"})}return u;function u(){let c,u,d,m=$a;if((!t||a(o,l,s[s.length-1]||void 0))&&(m=function(e){if(Array.isArray(e))return e;if("number"==typeof e)return[qa,e];return null==e?$a:[e]}(n(o,s)),m[0]===Xa))return m;if("children"in o&&o.children){const t=o;if(t.children&&"skip"!==m[0])for(u=(r?t.children.length:-1)+i,d=s.concat(t);u>-1&&u<t.children.length;){const n=t.children[u];if(c=e(n,u,d)(),c[0]===Xa)return c;u="number"==typeof c[1]?c[1]:u+i}}return m}}(e,void 0,[])()}function Ga(e,t,n,r){let o,a,i;"function"==typeof t&&"function"!=typeof n?(a=void 0,i=t,o=n):(a=t,i=n,o=r),Ya(e,a,(function(e,t){const n=t[t.length-1],r=n?n.children.indexOf(e):void 0;return i(e,r,n)}),o)}const Za={}.hasOwnProperty,Ja={};function Ka(e,t){e.position&&(t.position=function(e){const t=rr(e),n=nr(e);if(t&&n)return{start:t,end:n}}(e))}function Qa(e,t){let n=t;if(e&&e.data){const t=e.data.hName,r=e.data.hChildren,o=e.data.hProperties;if("string"==typeof t)if("element"===n.type)n.tagName=t;else{n={type:"element",tagName:t,properties:{},children:"children"in n?n.children:[n]}}"element"===n.type&&o&&Object.assign(n.properties,Ha(o)),"children"in n&&n.children&&null!=r&&(n.children=r)}return n}function ei(e,t){const n=t.data||{},r=!("value"in t)||Za.call(n,"hProperties")||Za.call(n,"hChildren")?{type:"element",tagName:"div",properties:{},children:e.all(t)}:{type:"text",value:t.value};return e.patch(t,r),e.applyData(t,r)}function ti(e,t){const n=[];let r=-1;for(t&&n.push({type:"text",value:"\n"});++r<e.length;)r&&n.push({type:"text",value:"\n"}),n.push(e[r]);return t&&e.length>0&&n.push({type:"text",value:"\n"}),n}function ni(e){let t=0,n=e.charCodeAt(t);for(;9===n||32===n;)t++,n=e.charCodeAt(t);return e.slice(t)}function ri(e,t){const n=function(e,t){const n=t||Ja,r=new Map,o=new Map,a=new Map,i={...Pa,...n.handlers},l={all:function(e){const t=[];if("children"in e){const n=e.children;let r=-1;for(;++r<n.length;){const o=l.one(n[r],e);if(o){if(r&&"break"===n[r-1].type&&(Array.isArray(o)||"text"!==o.type||(o.value=ni(o.value)),!Array.isArray(o)&&"element"===o.type)){const e=o.children[0];e&&"text"===e.type&&(e.value=ni(e.value))}Array.isArray(o)?t.push(...o):t.push(o)}}}return t},applyData:Qa,definitionById:r,footnoteById:o,footnoteCounts:a,footnoteOrder:[],handlers:i,one:function(e,t){const n=e.type,r=l.handlers[n];if(Za.call(l.handlers,n)&&r)return r(l,e,t);if(l.options.passThrough&&l.options.passThrough.includes(n)){if("children"in e){const{children:t,...n}=e,r=Ha(n);return r.children=l.all(e),r}return Ha(e)}return(l.options.unknownHandler||ei)(l,e,t)},options:n,patch:Ka,wrap:ti};return Ga(e,(function(e){if("definition"===e.type||"footnoteDefinition"===e.type){const t="definition"===e.type?r:o,n=String(e.identifier).toUpperCase();t.has(n)||t.set(n,e)}})),l}(e,t),r=n.one(e,void 0),o=function(e){const t="string"==typeof e.options.clobberPrefix?e.options.clobberPrefix:"user-content-",n=e.options.footnoteBackContent||Da,r=e.options.footnoteBackLabel||Ua,o=e.options.footnoteLabel||"Footnotes",a=e.options.footnoteLabelTagName||"h2",i=e.options.footnoteLabelProperties||{className:["sr-only"]},l=[];let s=-1;for(;++s<e.footnoteOrder.length;){const o=e.footnoteById.get(e.footnoteOrder[s]);if(!o)continue;const a=e.all(o),i=String(o.identifier).toUpperCase(),c=eo(i.toLowerCase());let u=0;const d=[],m=e.footnoteCounts.get(i);for(;void 0!==m&&++u<=m;){d.length>0&&d.push({type:"text",value:" "});let e="string"==typeof n?n:n(s,u);"string"==typeof e&&(e={type:"text",value:e}),d.push({type:"element",tagName:"a",properties:{href:"#"+t+"fnref-"+c+(u>1?"-"+u:""),dataFootnoteBackref:"",ariaLabel:"string"==typeof r?r:r(s,u),className:["data-footnote-backref"]},children:Array.isArray(e)?e:[e]})}const p=a[a.length-1];if(p&&"element"===p.type&&"p"===p.tagName){const e=p.children[p.children.length-1];e&&"text"===e.type?e.value+=" ":p.children.push({type:"text",value:" "}),p.children.push(...d)}else a.push(...d);const f={type:"element",tagName:"li",properties:{id:t+"fn-"+c},children:e.wrap(a,!0)};e.patch(o,f),l.push(f)}if(0!==l.length)return{type:"element",tagName:"section",properties:{dataFootnotes:!0,className:["footnotes"]},children:[{type:"element",tagName:a,properties:{...Ha(i),id:"footnote-label"},children:[{type:"text",value:o}]},{type:"text",value:"\n"},{type:"element",tagName:"ol",properties:{},children:e.wrap(l,!0)},{type:"text",value:"\n"}]}}(n),a=Array.isArray(r)?{type:"root",children:r}:r||{type:"root",children:[]};return o&&a.children.push({type:"text",value:"\n"},o),a}function oi(e,t){return e&&"run"in e?async function(n,r){const o=ri(n,{file:r,...t});await e.run(o,r)}:function(n,r){return ri(n,{file:r,...e||t})}}function ai(e){if(e)throw e}var ii=Object.prototype.hasOwnProperty,li=Object.prototype.toString,si=Object.defineProperty,ci=Object.getOwnPropertyDescriptor,ui=function(e){return"function"==typeof Array.isArray?Array.isArray(e):"[object Array]"===li.call(e)},di=function(e){if(!e||"[object Object]"!==li.call(e))return!1;var t,n=ii.call(e,"constructor"),r=e.constructor&&e.constructor.prototype&&ii.call(e.constructor.prototype,"isPrototypeOf");if(e.constructor&&!n&&!r)return!1;for(t in e);return void 0===t||ii.call(e,t)},mi=function(e,t){si&&"__proto__"===t.name?si(e,t.name,{enumerable:!0,configurable:!0,value:t.newValue,writable:!0}):e[t.name]=t.newValue},pi=function(e,t){if("__proto__"===t){if(!ii.call(e,t))return;if(ci)return ci(e,t).value}return e[t]},fi=function e(){var t,n,r,o,a,i,l=arguments[0],s=1,c=arguments.length,u=!1;for("boolean"==typeof l&&(u=l,l=arguments[1]||{},s=2),(null==l||"object"!=typeof l&&"function"!=typeof l)&&(l={});s<c;++s)if(null!=(t=arguments[s]))for(n in t)r=pi(l,n),l!==(o=pi(t,n))&&(u&&o&&(di(o)||(a=ui(o)))?(a?(a=!1,i=r&&ui(r)?r:[]):i=r&&di(r)?r:{},mi(l,{name:n,newValue:e(u,i,o)})):void 0!==o&&mi(l,{name:n,newValue:o}));return l};function hi(e){if("object"!=typeof e||null===e)return!1;const t=Object.getPrototypeOf(e);return!(null!==t&&t!==Object.prototype&&null!==Object.getPrototypeOf(t)||Symbol.toStringTag in e||Symbol.iterator in e)}function gi(){const e=[],t={run:function(...t){let n=-1;const r=t.pop();if("function"!=typeof r)throw new TypeError("Expected function as last argument, not "+r);!function o(a,...i){const l=e[++n];let s=-1;if(a)r(a);else{for(;++s<t.length;)null!==i[s]&&void 0!==i[s]||(i[s]=t[s]);t=i,l?function(e,t){let n;return r;function r(...t){const r=e.length>t.length;let i;r&&t.push(o);try{i=e.apply(this,t)}catch(e){if(r&&n)throw e;return o(e)}r||(i&&i.then&&"function"==typeof i.then?i.then(a,o):i instanceof Error?o(i):a(i))}function o(e,...r){n||(n=!0,t(e,...r))}function a(e){o(null,e)}}(l,o)(...i):r(null,...i)}}(null,...t)},use:function(n){if("function"!=typeof n)throw new TypeError("Expected `middelware` to be a function, not "+n);return e.push(n),t}};return t}const _i={basename:function(e,t){if(void 0!==t&&"string"!=typeof t)throw new TypeError('"ext" argument must be a string');yi(e);let n,r=0,o=-1,a=e.length;if(void 0===t||0===t.length||t.length>e.length){for(;a--;)if(47===e.codePointAt(a)){if(n){r=a+1;break}}else o<0&&(n=!0,o=a+1);return o<0?"":e.slice(r,o)}if(t===e)return"";let i=-1,l=t.length-1;for(;a--;)if(47===e.codePointAt(a)){if(n){r=a+1;break}}else i<0&&(n=!0,i=a+1),l>-1&&(e.codePointAt(a)===t.codePointAt(l--)?l<0&&(o=a):(l=-1,o=i));r===o?o=i:o<0&&(o=e.length);return e.slice(r,o)},dirname:function(e){if(yi(e),0===e.length)return".";let t,n=-1,r=e.length;for(;--r;)if(47===e.codePointAt(r)){if(t){n=r;break}}else t||(t=!0);return n<0?47===e.codePointAt(0)?"/":".":1===n&&47===e.codePointAt(0)?"//":e.slice(0,n)},extname:function(e){yi(e);let t,n=e.length,r=-1,o=0,a=-1,i=0;for(;n--;){const l=e.codePointAt(n);if(47!==l)r<0&&(t=!0,r=n+1),46===l?a<0?a=n:1!==i&&(i=1):a>-1&&(i=-1);else if(t){o=n+1;break}}if(a<0||r<0||0===i||1===i&&a===r-1&&a===o+1)return"";return e.slice(a,r)},join:function(...e){let t,n=-1;for(;++n<e.length;)yi(e[n]),e[n]&&(t=void 0===t?e[n]:t+"/"+e[n]);return void 0===t?".":function(e){yi(e);const t=47===e.codePointAt(0);let n=function(e,t){let n,r,o="",a=0,i=-1,l=0,s=-1;for(;++s<=e.length;){if(s<e.length)n=e.codePointAt(s);else{if(47===n)break;n=47}if(47===n){if(i===s-1||1===l);else if(i!==s-1&&2===l){if(o.length<2||2!==a||46!==o.codePointAt(o.length-1)||46!==o.codePointAt(o.length-2))if(o.length>2){if(r=o.lastIndexOf("/"),r!==o.length-1){r<0?(o="",a=0):(o=o.slice(0,r),a=o.length-1-o.lastIndexOf("/")),i=s,l=0;continue}}else if(o.length>0){o="",a=0,i=s,l=0;continue}t&&(o=o.length>0?o+"/..":"..",a=2)}else o.length>0?o+="/"+e.slice(i+1,s):o=e.slice(i+1,s),a=s-i-1;i=s,l=0}else 46===n&&l>-1?l++:l=-1}return o}(e,!t);0!==n.length||t||(n=".");n.length>0&&47===e.codePointAt(e.length-1)&&(n+="/");return t?"/"+n:n}(t)},sep:"/"};function yi(e){if("string"!=typeof e)throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}const bi={cwd:function(){return"/"}};function vi(e){return Boolean(null!==e&&"object"==typeof e&&"href"in e&&e.href&&"protocol"in e&&e.protocol&&void 0===e.auth)}function xi(e){if("string"==typeof e)e=new URL(e);else if(!vi(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("file:"!==e.protocol){const e=new TypeError("The URL must be of scheme file");throw e.code="ERR_INVALID_URL_SCHEME",e}return function(e){if(""!==e.hostname){const e=new TypeError('File URL host must be "localhost" or empty on darwin');throw e.code="ERR_INVALID_FILE_URL_HOST",e}const t=e.pathname;let n=-1;for(;++n<t.length;)if(37===t.codePointAt(n)&&50===t.codePointAt(n+1)){const e=t.codePointAt(n+2);if(70===e||102===e){const e=new TypeError("File URL path must not include encoded / characters");throw e.code="ERR_INVALID_FILE_URL_PATH",e}}return decodeURIComponent(t)}(e)}const ki=["history","path","basename","stem","extname","dirname"];class wi{constructor(e){let t;t=e?vi(e)?{path:e}:"string"==typeof e||function(e){return Boolean(e&&"object"==typeof e&&"byteLength"in e&&"byteOffset"in e)}(e)?{value:e}:e:{},this.cwd="cwd"in t?"":bi.cwd(),this.data={},this.history=[],this.messages=[],this.value,this.map,this.result,this.stored;let n,r=-1;for(;++r<ki.length;){const e=ki[r];e in t&&void 0!==t[e]&&null!==t[e]&&(this[e]="history"===e?[...t[e]]:t[e])}for(n in t)ki.includes(n)||(this[n]=t[n])}get basename(){return"string"==typeof this.path?_i.basename(this.path):void 0}set basename(e){Ei(e,"basename"),Ci(e,"basename"),this.path=_i.join(this.dirname||"",e)}get dirname(){return"string"==typeof this.path?_i.dirname(this.path):void 0}set dirname(e){Si(this.basename,"dirname"),this.path=_i.join(e||"",this.basename)}get extname(){return"string"==typeof this.path?_i.extname(this.path):void 0}set extname(e){if(Ci(e,"extname"),Si(this.dirname,"extname"),e){if(46!==e.codePointAt(0))throw new Error("`extname` must start with `.`");if(e.includes(".",1))throw new Error("`extname` cannot contain multiple dots")}this.path=_i.join(this.dirname,this.stem+(e||""))}get path(){return this.history[this.history.length-1]}set path(e){vi(e)&&(e=xi(e)),Ei(e,"path"),this.path!==e&&this.history.push(e)}get stem(){return"string"==typeof this.path?_i.basename(this.path,this.extname):void 0}set stem(e){Ei(e,"stem"),Ci(e,"stem"),this.path=_i.join(this.dirname||"",e+(this.extname||""))}fail(e,t,n){const r=this.message(e,t,n);throw r.fatal=!0,r}info(e,t,n){const r=this.message(e,t,n);return r.fatal=void 0,r}message(e,t,n){const r=new cr(e,t,n);return this.path&&(r.name=this.path+":"+r.name,r.file=this.path),r.fatal=!1,this.messages.push(r),r}toString(e){if(void 0===this.value)return"";if("string"==typeof this.value)return this.value;return new TextDecoder(e||void 0).decode(this.value)}}function Ci(e,t){if(e&&e.includes(_i.sep))throw new Error("`"+t+"` cannot be a path: did not expect `"+_i.sep+"`")}function Ei(e,t){if(!e)throw new Error("`"+t+"` cannot be empty")}function Si(e,t){if(!e)throw new Error("Setting `"+t+"` requires `path` to be set too")}const Ri=function(e){const t=this.constructor.prototype,n=t[e],r=function(){return n.apply(r,arguments)};return Object.setPrototypeOf(r,t),r},Fi={}.hasOwnProperty;class Pi extends Ri{constructor(){super("copy"),this.Compiler=void 0,this.Parser=void 0,this.attachers=[],this.compiler=void 0,this.freezeIndex=-1,this.frozen=void 0,this.namespace={},this.parser=void 0,this.transformers=gi()}copy(){const e=new Pi;let t=-1;for(;++t<this.attachers.length;){const n=this.attachers[t];e.use(...n)}return e.data(fi(!0,{},this.namespace)),e}data(e,t){return"string"==typeof e?2===arguments.length?(Ni("data",this.frozen),this.namespace[e]=t,this):Fi.call(this.namespace,e)&&this.namespace[e]||void 0:e?(Ni("data",this.frozen),this.namespace=e,this):this.namespace}freeze(){if(this.frozen)return this;const e=this;for(;++this.freezeIndex<this.attachers.length;){const[t,...n]=this.attachers[this.freezeIndex];if(!1===n[0])continue;!0===n[0]&&(n[0]=void 0);const r=t.call(e,...n);"function"==typeof r&&this.transformers.use(r)}return this.frozen=!0,this.freezeIndex=Number.POSITIVE_INFINITY,this}parse(e){this.freeze();const t=Ai(e),n=this.parser||this.Parser;return Bi("parse",n),n(String(t),t)}process(e,t){const n=this;return this.freeze(),Bi("process",this.parser||this.Parser),Ii("process",this.compiler||this.Compiler),t?r(void 0,t):new Promise(r);function r(r,o){const a=Ai(e),i=n.parse(a);function l(e,n){e||!n?o(e):r?r(n):t(void 0,n)}n.run(i,a,(function(e,t,r){if(e||!t||!r)return l(e);const o=t,a=n.stringify(o,r);var i;"string"==typeof(i=a)||function(e){return Boolean(e&&"object"==typeof e&&"byteLength"in e&&"byteOffset"in e)}(i)?r.value=a:r.result=a,l(e,r)}))}}processSync(e){let t,n=!1;return this.freeze(),Bi("processSync",this.parser||this.Parser),Ii("processSync",this.compiler||this.Compiler),this.process(e,(function(e,r){n=!0,ai(e),t=r})),Oi("processSync","process",n),t}run(e,t,n){Li(e),this.freeze();const r=this.transformers;return n||"function"!=typeof t||(n=t,t=void 0),n?o(void 0,n):new Promise(o);function o(o,a){const i=Ai(t);r.run(e,i,(function(t,r,i){const l=r||e;t?a(t):o?o(l):n(void 0,l,i)}))}}runSync(e,t){let n,r=!1;return this.run(e,t,(function(e,t){ai(e),n=t,r=!0})),Oi("runSync","run",r),n}stringify(e,t){this.freeze();const n=Ai(t),r=this.compiler||this.Compiler;return Ii("stringify",r),Li(e),r(e,n)}use(e,...t){const n=this.attachers,r=this.namespace;if(Ni("use",this.frozen),null==e);else if("function"==typeof e)l(e,t);else{if("object"!=typeof e)throw new TypeError("Expected usable value, not `"+e+"`");Array.isArray(e)?i(e):a(e)}return this;function o(e){if("function"==typeof e)l(e,[]);else{if("object"!=typeof e)throw new TypeError("Expected usable value, not `"+e+"`");if(Array.isArray(e)){const[t,...n]=e;l(t,n)}else a(e)}}function a(e){if(!("plugins"in e)&&!("settings"in e))throw new Error("Expected usable value but received an empty preset, which is probably a mistake: presets typically come with `plugins` and sometimes with `settings`, but this has neither");i(e.plugins),e.settings&&(r.settings=fi(!0,r.settings,e.settings))}function i(e){let t=-1;if(null==e);else{if(!Array.isArray(e))throw new TypeError("Expected a list of plugins, not `"+e+"`");for(;++t<e.length;){o(e[t])}}}function l(e,t){let r=-1,o=-1;for(;++r<n.length;)if(n[r][0]===e){o=r;break}if(-1===o)n.push([e,...t]);else if(t.length>0){let[r,...a]=t;const i=n[o][1];hi(i)&&hi(r)&&(r=fi(!0,i,r)),n[o]=[e,r,...a]}}}}const Ti=(new Pi).freeze();function Bi(e,t){if("function"!=typeof t)throw new TypeError("Cannot `"+e+"` without `parser`")}function Ii(e,t){if("function"!=typeof t)throw new TypeError("Cannot `"+e+"` without `compiler`")}function Ni(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 Li(e){if(!hi(e)||"string"!=typeof e.type)throw new TypeError("Expected node, got `"+e+"`")}function Oi(e,t,n){if(!n)throw new Error("`"+e+"` finished async. Use `"+t+"` instead")}function Ai(e){return function(e){return Boolean(e&&"object"==typeof e&&"message"in e&&"messages"in e)}(e)?e:new wi(e)}const Mi=[],zi={allowDangerousHtml:!0},Hi=/^(https?|ircs?|mailto|xmpp)$/i,Di=[{from:"astPlugins",id:"remove-buggy-html-in-markdown-parser"},{from:"allowDangerousHtml",id:"remove-buggy-html-in-markdown-parser"},{from:"allowNode",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"allowElement"},{from:"allowedTypes",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"allowedElements"},{from:"disallowedTypes",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"disallowedElements"},{from:"escapeHtml",id:"remove-buggy-html-in-markdown-parser"},{from:"includeElementIndex",id:"#remove-includeelementindex"},{from:"includeNodeIndex",id:"change-includenodeindex-to-includeelementindex"},{from:"linkTarget",id:"remove-linktarget"},{from:"plugins",id:"change-plugins-to-remarkplugins",to:"remarkPlugins"},{from:"rawSourcePos",id:"#remove-rawsourcepos"},{from:"renderers",id:"change-renderers-to-components",to:"components"},{from:"source",id:"change-source-to-children",to:"children"},{from:"sourcePos",id:"#remove-sourcepos"},{from:"transformImageUri",id:"#add-urltransform",to:"urlTransform"},{from:"transformLinkUri",id:"#add-urltransform",to:"urlTransform"}];function Ui(e){const t=e.allowedElements,n=e.allowElement,r=e.children||"",o=e.className,a=e.components,i=e.disallowedElements,u=e.rehypePlugins||Mi,d=e.remarkPlugins||Mi,m=e.remarkRehypeOptions?{...e.remarkRehypeOptions,...zi}:zi,p=e.skipHtml,f=e.unwrapDisallowed,h=e.urlTransform||ji,g=Ti().use(Ca).use(d).use(oi,m).use(u),_=new wi;"string"==typeof r&&(_.value=r);for(const t of Di)Object.hasOwn(e,t.from)&&(t.from,t.to&&t.to,t.id);const y=g.parse(_);let b=g.runSync(y,_);return o&&(b={type:"element",tagName:"div",properties:{className:o},children:"root"===b.type?b.children:[b]}),Ga(b,(function(e,r,o){if("raw"===e.type&&o&&"number"==typeof r)return p?o.children.splice(r,1):o.children[r]={type:"text",value:e.value},r;if("element"===e.type){let t;for(t in Fr)if(Object.hasOwn(Fr,t)&&Object.hasOwn(e.properties,t)){const n=e.properties[t],r=Fr[t];(null===r||r.includes(e.tagName))&&(e.properties[t]=h(String(n||""),t,e))}}if("element"===e.type){let a=t?!t.includes(e.tagName):!!i&&i.includes(e.tagName);if(!a&&n&&"number"==typeof r&&(a=!n(e,r,o)),a&&o&&"number"==typeof r)return f&&e.children?o.children.splice(r,1,...e.children):o.children.splice(r,1),r}})),_r(b,{Fragment:l,components:a,ignoreInvalidStyle:!0,jsx:s,jsxs:c,passKeys:!0,passNode:!0})}function ji(e){const t=e.indexOf(":"),n=e.indexOf("?"),r=e.indexOf("#"),o=e.indexOf("/");return t<0||o>-1&&t>o||n>-1&&t>n||r>-1&&t>r||Hi.test(e.slice(0,t))?e:""}var Vi="MarkdownRenderer-module_markdownRenderer_2hMGF",Wi="MarkdownRenderer-module_paragraph_daEfU",$i="MarkdownRenderer-module_heading1_EodAv",qi="MarkdownRenderer-module_heading2_xUrNa",Xi="MarkdownRenderer-module_heading3_Q-fqn",Yi="MarkdownRenderer-module_heading4_-4Q4o",Gi="MarkdownRenderer-module_heading5_JqZYf",Zi="MarkdownRenderer-module_heading6_-8XoG",Ji="MarkdownRenderer-module_unorderedList_aBIW9",Ki="MarkdownRenderer-module_orderedList_HgyEc",Qi="MarkdownRenderer-module_listItem_cpRyd",el="MarkdownRenderer-module_blockquote_OBSzA",tl="MarkdownRenderer-module_codeBlock_CPBx9",nl="MarkdownRenderer-module_inlineCode_lsXpE",rl="MarkdownRenderer-module_code_Pb52J",ol="MarkdownRenderer-module_link_Oi99H",al="MarkdownRenderer-module_horizontalRule_t4g6E",il="MarkdownRenderer-module_tableWrapper_EAkvX",ll="MarkdownRenderer-module_table_EWdTV",sl="MarkdownRenderer-module_tableHeader_pDfEC",cl="MarkdownRenderer-module_tableCell_nsbnT",ul="MarkdownRenderer-module_strong_DK-70",dl="MarkdownRenderer-module_emphasis_-ge7M";D(".MarkdownRenderer-module_markdownRenderer_2hMGF{line-height:1.6}.MarkdownRenderer-module_paragraph_daEfU{line-height:1.625;margin-bottom:1.2rem}.MarkdownRenderer-module_paragraph_daEfU:first-child{margin-top:0}.MarkdownRenderer-module_paragraph_daEfU:last-child{margin-bottom:0}.MarkdownRenderer-module_heading1_EodAv{font-size:1.5rem;font-weight:700;line-height:1.25;margin-bottom:1rem;margin-top:1.5rem}.MarkdownRenderer-module_heading1_EodAv:first-child{margin-top:0}.MarkdownRenderer-module_heading2_xUrNa{font-size:1.25rem;font-weight:700;line-height:1.25;margin-bottom:.75rem;margin-top:1.25rem}.MarkdownRenderer-module_heading2_xUrNa:first-child{margin-top:0}.MarkdownRenderer-module_heading3_Q-fqn{font-size:1.125rem;font-weight:600;line-height:1.25;margin-bottom:.75rem;margin-top:1rem}.MarkdownRenderer-module_heading3_Q-fqn:first-child{margin-top:0}.MarkdownRenderer-module_heading4_-4Q4o{font-size:1rem;font-weight:600;line-height:1.25;margin-bottom:.5rem;margin-top:.75rem}.MarkdownRenderer-module_heading4_-4Q4o:first-child{margin-top:0}.MarkdownRenderer-module_heading5_JqZYf{font-size:.875rem;font-weight:600;line-height:1.25;margin-bottom:.5rem;margin-top:.75rem}.MarkdownRenderer-module_heading5_JqZYf:first-child{margin-top:0}.MarkdownRenderer-module_heading6_-8XoG{font-size:.75rem;font-weight:600;line-height:1.25;margin-bottom:.5rem;margin-top:.5rem}.MarkdownRenderer-module_heading6_-8XoG:first-child{margin-top:0}.MarkdownRenderer-module_unorderedList_aBIW9{list-style-type:disc;margin-bottom:1.25rem;padding-left:1.5rem}.MarkdownRenderer-module_unorderedList_aBIW9>li+li{margin-top:.5rem}.MarkdownRenderer-module_orderedList_HgyEc{list-style-type:decimal;margin-bottom:1.25rem;padding-left:1.5rem}.MarkdownRenderer-module_orderedList_HgyEc>li+li{margin-top:.5rem}.MarkdownRenderer-module_listItem_cpRyd{line-height:1.7;margin-bottom:.5rem}.MarkdownRenderer-module_orderedList_HgyEc:last-child{margin-bottom:0}.MarkdownRenderer-module_blockquote_OBSzA{border-left:4px solid #d1d5db;font-style:italic;margin:1rem 0;padding-left:1rem}.MarkdownRenderer-module_codeBlock_CPBx9{border-radius:.375rem;margin-bottom:1rem;overflow-x:auto;padding:1rem}.MarkdownRenderer-module_inlineCode_lsXpE{border-radius:.25rem;font-size:.875rem;padding:.125rem .25rem}.MarkdownRenderer-module_code_Pb52J{font-family:ui-monospace,SFMono-Regular,SF Mono,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-size:.875rem;line-height:1.625}.MarkdownRenderer-module_link_Oi99H{color:#2563eb;text-decoration:none}.MarkdownRenderer-module_link_Oi99H:hover{text-decoration:underline}.MarkdownRenderer-module_horizontalRule_t4g6E{border:none;border-top:1px solid #d1d5db;margin:1.5rem 0}.MarkdownRenderer-module_tableWrapper_EAkvX{margin-bottom:1rem;overflow-x:auto}.MarkdownRenderer-module_table_EWdTV{border:1px solid #d1d5db;border-collapse:collapse;min-width:100%}.MarkdownRenderer-module_tableHeader_pDfEC{font-weight:600;text-align:left}.MarkdownRenderer-module_tableCell_nsbnT,.MarkdownRenderer-module_tableHeader_pDfEC{border:1px solid #d1d5db;padding:.5rem .75rem}.MarkdownRenderer-module_strong_DK-70{font-weight:650}.MarkdownRenderer-module_emphasis_-ge7M{font-style:italic}@media (prefers-color-scheme:dark){.MarkdownRenderer-module_blockquote_OBSzA{border-left-color:#4b5563}.MarkdownRenderer-module_codeBlock_CPBx9,.MarkdownRenderer-module_inlineCode_lsXpE{background-color:#1f2937}.MarkdownRenderer-module_link_Oi99H{color:#60a5fa}.MarkdownRenderer-module_horizontalRule_t4g6E{border-top-color:#4b5563}.MarkdownRenderer-module_table_EWdTV{border-color:#4b5563}.MarkdownRenderer-module_tableHeader_pDfEC{background-color:#1f2937;border-color:#4b5563}.MarkdownRenderer-module_tableCell_nsbnT{border-color:#4b5563}}");var ml=({children:t,className:n=""})=>{const r={p:({children:t})=>e.createElement("p",{className:Wi},t),h1:({children:t})=>e.createElement("h1",{className:$i},t),h2:({children:t})=>e.createElement("h2",{className:qi},t),h3:({children:t})=>e.createElement("h3",{className:Xi},t),h4:({children:t})=>e.createElement("h4",{className:Yi},t),h5:({children:t})=>e.createElement("h5",{className:Gi},t),h6:({children:t})=>e.createElement("h6",{className:Zi},t),ul:({children:t})=>e.createElement("ul",{className:Ji},t),ol:({children:t})=>e.createElement("ol",{className:Ki},t),li:({children:t})=>e.createElement("li",{className:Qi},t),blockquote:({children:t})=>e.createElement("blockquote",{className:el},t),pre:({children:t})=>e.createElement("pre",{className:tl},t),code:({inline:t,children:n})=>t?e.createElement("code",{className:nl},n):e.createElement("code",{className:rl},n),a:({href:t,children:n})=>e.createElement("a",{href:t,className:ol,target:"_blank",rel:"noopener noreferrer"},n),hr:()=>e.createElement("hr",{className:al}),table:({children:t})=>e.createElement("div",{className:il},e.createElement("table",{className:ll},t)),th:({children:t})=>e.createElement("th",{className:sl},t),td:({children:t})=>e.createElement("td",{className:cl},t),strong:({children:t})=>e.createElement("strong",{className:ul},t),em:({children:t})=>e.createElement("em",{className:dl},t)};return e.createElement("div",{className:`${Vi} ${n}`},e.createElement(Ui,{components:r},t))},pl={statusPopupOverlay:"StatusPopup-module_statusPopupOverlay_BX-t-",dark:"StatusPopup-module_dark_i0bGz",light:"StatusPopup-module_light_SVfB7",statusPopupContent:"StatusPopup-module_statusPopupContent_uz-PY",success:"StatusPopup-module_success_g7FnA",error:"StatusPopup-module_error_AbPvI",closeButtonStatusPopup:"StatusPopup-module_closeButtonStatusPopup_Eol6Z"};D(".StatusPopup-module_statusPopupOverlay_BX-t-{align-items:center;bottom:0;display:flex;justify-content:center;left:0;position:absolute;right:0;top:0;z-index:1000}.StatusPopup-module_statusPopupOverlay_BX-t-.StatusPopup-module_dark_i0bGz{background-color:hsla(0,0%,100%,.3)}.StatusPopup-module_statusPopupOverlay_BX-t-.StatusPopup-module_light_SVfB7{background-color:rgba(0,0,0,.5)}.StatusPopup-module_statusPopupContent_uz-PY{border-radius:8px;box-shadow:0 2px 10px rgba(0,0,0,.1);max-width:80%;padding:20px;text-align:center}.StatusPopup-module_statusPopupContent_uz-PY.StatusPopup-module_success_g7FnA.StatusPopup-module_light_SVfB7{background-color:#f0f0f0;color:green}.StatusPopup-module_statusPopupContent_uz-PY.StatusPopup-module_error_AbPvI.StatusPopup-module_light_SVfB7{background-color:#f0f0f0;color:red}.StatusPopup-module_statusPopupContent_uz-PY.StatusPopup-module_error_AbPvI.StatusPopup-module_dark_i0bGz{background-color:#292929;color:#ff3246}.StatusPopup-module_statusPopupContent_uz-PY.StatusPopup-module_success_g7FnA.StatusPopup-module_dark_i0bGz{background-color:#292929;color:#2aff5c}.StatusPopup-module_statusPopupContent_uz-PY p{font-size:16px;margin-bottom:15px}.StatusPopup-module_closeButtonStatusPopup_Eol6Z{background:var(--selected-color-light);border:none;border-radius:4px;color:#fff;cursor:pointer;font-size:14px;padding:8px 16px;transition:background-color .3s ease}.StatusPopup-module_closeButtonStatusPopup_Eol6Z.StatusPopup-module_light_SVfB7{color:#000}.StatusPopup-module_closeButtonStatusPopup_Eol6Z:hover{background:var(--selected-color)}.StatusPopup-module_closeButtonStatusPopup_Eol6Z:focus{box-shadow:0 0 0 2px hsla(208,7%,46%,.5);outline:none}");const fl=({message:t,type:n,onClose:r})=>{const{theme:o}=H();return e.createElement("div",{className:`${pl.statusPopupOverlay} ${pl[o]}`},e.createElement("div",{className:`${pl.statusPopupContent} ${pl[n]} ${pl[o]}`},e.createElement("p",null,t),e.createElement("button",{onClick:r,className:`${pl.closeButtonStatusPopup} ${pl[o]}`},"Close")))};fl.propTypes={message:m.exports.string.isRequired,type:m.exports.oneOf(["success","error"]).isRequired,onClose:m.exports.func.isRequired};var hl=fl,gl="MessageLoader-module_messageLoader_DvZJ2",_l="MessageLoader-module_loader_ukqmx",yl="MessageLoader-module_load_Zh7KY";D('.MessageLoader-module_messageLoader_DvZJ2{display:flex;justify-content:flex-start;padding-left:1.2rem}.MessageLoader-module_loader_ukqmx{height:30px;position:relative;width:60px}.MessageLoader-module_load_Zh7KY{animation:MessageLoader-module_loading_713_ObCNr 3.5s ease infinite both;background-color:var(--selected-color-light1);border-radius:50px;bottom:0;display:block;height:15px;position:absolute;transform:translateX(64px);width:15px}.MessageLoader-module_load_Zh7KY:before{animation:MessageLoader-module_loading2_713_gRbTo 3.5s ease infinite both;background-color:var(--selected-color);border-radius:inherit;content:"";height:100%;position:absolute;width:100%}@keyframes MessageLoader-module_loading_713_ObCNr{0%{transform:translateX(0);width:16px}40%{transform:translateX(0);width:100%}80%{transform:translateX(64px);width:16px}90%{transform:translateX(0);width:100%}to{transform:translateX(0);width:16px}}@keyframes MessageLoader-module_loading2_713_gRbTo{0%{transform:translateX(0);width:16px}40%{transform:translateX(0);width:80%}80%{transform:translateX(0);width:100%}90%{transform:translateX(15px);width:80%}to{transform:translateX(0);width:16px}}@media (prefers-reduced-motion:reduce){.MessageLoader-module_load_Zh7KY,.MessageLoader-module_load_Zh7KY:before{animation:none}}');var bl=()=>e.createElement("div",{className:gl},e.createElement("div",{className:_l},e.createElement("span",{className:yl}))),vl={chatSuggestions:"ChatSuggestions-module_chatSuggestions_CS-mO",suggestionButton:"ChatSuggestions-module_suggestionButton_EBaHf",chipFadeIn:"ChatSuggestions-module_chipFadeIn_4l6lG",light:"ChatSuggestions-module_light_-wA8d",dark:"ChatSuggestions-module_dark_XLTHw"};D(".ChatSuggestions-module_chatSuggestions_CS-mO{display:flex;flex-wrap:wrap;gap:.5rem;padding:.5rem}@keyframes ChatSuggestions-module_chipFadeIn_4l6lG{0%{opacity:0;transform:translateY(8px)}to{opacity:1;transform:translateY(0)}}.ChatSuggestions-module_suggestionButton_EBaHf{animation:ChatSuggestions-module_chipFadeIn_4l6lG .15s ease-out forwards;border-color:var(--selected-color);border-radius:.8rem;border-style:solid;border-width:1px;color:var(--selected-color);cursor:pointer;font-family:Inter,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,sans-serif;font-size:.8rem;font-weight:550;max-width:calc(100% - 1rem);opacity:0;overflow:hidden;padding:.4rem .5rem;text-overflow:ellipsis;transition:background-color .2s ease,transform .2s ease,box-shadow .2s ease;white-space:nowrap}.ChatSuggestions-module_suggestionButton_EBaHf:first-child{animation-delay:0ms}.ChatSuggestions-module_suggestionButton_EBaHf:nth-child(2){animation-delay:50ms}.ChatSuggestions-module_suggestionButton_EBaHf:nth-child(3){animation-delay:.1s}.ChatSuggestions-module_suggestionButton_EBaHf:nth-child(4){animation-delay:.15s}.ChatSuggestions-module_suggestionButton_EBaHf:nth-child(5){animation-delay:.2s}.ChatSuggestions-module_suggestionButton_EBaHf:nth-child(6){animation-delay:.25s}.ChatSuggestions-module_suggestionButton_EBaHf:hover{box-shadow:0 0 2px var(--selected-color),0 0 2px var(--selected-color);transform:scale(1.02)}.ChatSuggestions-module_suggestionButton_EBaHf:active{transform:scale(.98)}.ChatSuggestions-module_light_-wA8d .ChatSuggestions-module_suggestionButton_EBaHf{background-color:#fff}.ChatSuggestions-module_dark_XLTHw .ChatSuggestions-module_suggestionButton_EBaHf{background-color:#000}.ChatSuggestions-module_dark_XLTHw .ChatSuggestions-module_suggestionButton_EBaHf:hover{border-color:var(--selected-color);box-shadow:0 0 4px var(--selected-color),0 0 4px var(--selected-color)}@media (prefers-reduced-motion:reduce){.ChatSuggestions-module_suggestionButton_EBaHf{animation:none;opacity:1}}");const xl=({suggestions:t,onSuggestionClick:n,theme:r})=>e.createElement("div",{className:`${vl.chatSuggestions} ${vl[r]}`},t.map(((t,r)=>e.createElement("button",{key:r,className:vl.suggestionButton,onClick:()=>n(t)},t))));xl.propTypes={suggestions:m.exports.arrayOf(m.exports.string).isRequired,onSuggestionClick:m.exports.func.isRequired,theme:m.exports.oneOf(["light","dark","blue"]).isRequired};var kl=xl;const wl=({size:t=24,color:n="currentColor",className:r})=>e.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:t,height:t,viewBox:"0 0 24 24",fill:"none",stroke:n,strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",className:r},e.createElement("path",{d:"M3.714 3.048a.498.498 0 0 0-.683.627l2.843 7.627a2 2 0 0 1 0 1.396l-2.842 7.627a.498.498 0 0 0 .682.627l18-8.5a.5.5 0 0 0 0-.904z"}),e.createElement("path",{d:"M6 12h16"})),Cl=({size:t=24,color:n="currentColor"})=>e.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:t,height:t,viewBox:"0 0 24 24",fill:"none",stroke:n,strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"},e.createElement("circle",{cx:"12",cy:"12",r:"4"}),e.createElement("path",{d:"M12 3v1"}),e.createElement("path",{d:"M12 20v1"}),e.createElement("path",{d:"M3 12h1"}),e.createElement("path",{d:"M20 12h1"}),e.createElement("path",{d:"m18.364 5.636-.707.707"}),e.createElement("path",{d:"m6.343 17.657-.707.707"}),e.createElement("path",{d:"m5.636 5.636.707.707"}),e.createElement("path",{d:"m17.657 17.657.707.707"})),El=({size:t=24,color:n="currentColor"})=>e.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:t,height:t,viewBox:"0 0 24 24",fill:"none",stroke:n,strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"},e.createElement("path",{d:"M12 3a6 6 0 0 0 9 9 9 9 0 1 1-9-9Z"})),Sl=({size:t=24,color:n="currentColor"})=>e.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:t,height:t,viewBox:"0 0 24 24",fill:"none",stroke:n,strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"},e.createElement("path",{d:"m6 9 6 6 6-6"})),Rl=({size:t=24,color:n="currentColor"})=>e.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:t,height:t,viewBox:"0 0 24 24",fill:"none",stroke:n,strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"},e.createElement("path",{d:"M18 6 6 18"}),e.createElement("path",{d:"m6 6 12 12"})),Fl=({size:t=24,color:n="currentColor"})=>e.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:t,height:t,viewBox:"0 0 24 24",fill:"none",stroke:n,strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"},e.createElement("path",{d:"m3 15 4-8 4 8"}),e.createElement("path",{d:"M4 13h6"}),e.createElement("circle",{cx:"18",cy:"12",r:"3"}),e.createElement("path",{d:"M21 9v6"})),Pl=({size:t=24,color:n="currentColor",style:r,className:o})=>e.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",className:o,style:r,width:t,height:t,viewBox:"0 0 24 24",fill:"none",stroke:n,strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"},e.createElement("path",{d:"M21 12a9 9 0 1 1-6.219-8.56"})),Tl=({size:t=24,color:n="currentColor",style:r})=>e.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",style:r,width:t,height:t,viewBox:"0 0 24 24",fill:"none",stroke:n,strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"},e.createElement("path",{d:"M5 12h14"}),e.createElement("path",{d:"M12 5v14"})),Bl=({size:t=24,color:n="currentColor",style:r})=>e.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",style:r,width:t,height:t,viewBox:"0 0 24 24",fill:"none",stroke:n,strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"},e.createElement("path",{d:"M22 17a2 2 0 0 1-2 2H6.828a2 2 0 0 0-1.414.586l-2.202 2.202A.71.71 0 0 1 2 21.286V5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2z"}),e.createElement("path",{d:"M7 11h10"}),e.createElement("path",{d:"M7 15h6"}),e.createElement("path",{d:"M7 7h8"})),Il=({size:t=24,color:n="currentColor",style:r})=>e.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",style:r,width:t,height:t,viewBox:"0 0 24 24",fill:"none",stroke:n,strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"},e.createElement("path",{d:"m15 15 6 6"}),e.createElement("path",{d:"m15 9 6-6"}),e.createElement("path",{d:"M21 16v5h-5"}),e.createElement("path",{d:"M21 8V3h-5"}),e.createElement("path",{d:"M3 16v5h5"}),e.createElement("path",{d:"m3 21 6-6"}),e.createElement("path",{d:"M3 8V3h5"}),e.createElement("path",{d:"M9 9 3 3"})),Nl=({size:t=24,color:n="currentColor",style:r})=>e.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",style:r,width:t,height:t,viewBox:"0 0 24 24",fill:"none",stroke:n,strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"},e.createElement("path",{d:"m15 15 6 6m-6-6v4.8m0-4.8h4.8"}),e.createElement("path",{d:"M9 19.8V15m0 0H4.2M9 15l-6 6"}),e.createElement("path",{d:"M15 4.2V9m0 0h4.8M15 9l6-6"}),e.createElement("path",{d:"M9 4.2V9m0 0H4.2M9 9 3 3"})),Ll=({size:t=24,color:n="currentColor",style:r})=>e.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",style:r,width:t,height:t,viewBox:"0 0 24 24",fill:"currentColor"},e.createElement("polygon",{points:"12 2 15.09 8.26 22 9.27 17 14.14 18.18 21.02 12 17.77 5.82 21.02 7 14.14 2 9.27 8.91 8.26 12 2"})),Ol=({size:t=24,color:n="currentColor",className:r,style:o})=>e.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",className:r,style:o,width:t,height:t,viewBox:"0 0 24 24",fill:"none",stroke:n,strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"},e.createElement("rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2"}),e.createElement("path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2"})),Al=({size:t=24,color:n="currentColor",className:r,style:o})=>e.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",className:r,style:o,width:t,height:t,viewBox:"0 0 24 24",fill:"none",stroke:n,strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"},e.createElement("polyline",{points:"20 6 9 17 4 12"})),Ml=({size:t=24,color:n="currentColor",className:r,style:o})=>e.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",className:r,style:o,width:t,height:t,viewBox:"0 0 24 24",fill:"none",stroke:n,strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"},e.createElement("circle",{cx:"12",cy:"12",r:"10"}),e.createElement("rect",{x:"9",y:"9",width:"6",height:"6",rx:"1"}));function zl(){return zl=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},zl.apply(null,arguments)}var Hl={formInChat:"FormRenderer-module_formInChat_U5Gpp",formWithErrors:"FormRenderer-module_formWithErrors_bnA2M",formContent:"FormRenderer-module_formContent_cCyya",formInChatTitle:"FormRenderer-module_formInChatTitle_YM5kv",formDescription:"FormRenderer-module_formDescription_wVULJ",formInstructions:"FormRenderer-module_formInstructions_UvqAN",formSection:"FormRenderer-module_formSection_XInby",formSectionSlideIn:"FormRenderer-module_formSectionSlideIn_uypbb",formGroup:"FormRenderer-module_formGroup_HWaSx",formGroupSlideIn:"FormRenderer-module_formGroupSlideIn_23Qgw",legend:"FormRenderer-module_legend_aqRMf",toggleLabel:"FormRenderer-module_toggleLabel_Jhw9c",required:"FormRenderer-module_required_v5kwB",input:"FormRenderer-module_input_jWGA-",select:"FormRenderer-module_select_sGXpF",textarea:"FormRenderer-module_textarea_LLDyJ",inputError:"FormRenderer-module_inputError_zBqFL",selectError:"FormRenderer-module_selectError_fZjR9",textareaError:"FormRenderer-module_textareaError_6fKJS",shakeError:"FormRenderer-module_shakeError_q7ATI",inputValid:"FormRenderer-module_inputValid_jmerj",selectValid:"FormRenderer-module_selectValid_s6jJ2",textareaValid:"FormRenderer-module_textareaValid_fJmqV",characterCount:"FormRenderer-module_characterCount_HSKA-",selectionInfo:"FormRenderer-module_selectionInfo_Ji-rn",fieldset:"FormRenderer-module_fieldset_-7QtQ",radioGroup:"FormRenderer-module_radioGroup_GBiNx",radioItem:"FormRenderer-module_radioItem_mHJMl",radioInput:"FormRenderer-module_radioInput_d8UCV",radioLabel:"FormRenderer-module_radioLabel_05jqX",checkboxGroup:"FormRenderer-module_checkboxGroup_Fw2eM",checkboxContainer:"FormRenderer-module_checkboxContainer_vq4jT",checkbox:"FormRenderer-module_checkbox_WBm9R",checkboxLabel:"FormRenderer-module_checkboxLabel_ziHms",toggleSwitchContainer:"FormRenderer-module_toggleSwitchContainer_kHMTe",toggleSwitch:"FormRenderer-module_toggleSwitch_12Px-",toggleInput:"FormRenderer-module_toggleInput_-uljF",slider:"FormRenderer-module_slider_lgvNk",starRating:"FormRenderer-module_starRating_9vpTj",star:"FormRenderer-module_star_Rmv7R",filled:"FormRenderer-module_filled_uzlvi",fileInputWrapper:"FormRenderer-module_fileInputWrapper_2xR3Q",hiddenFileInput:"FormRenderer-module_hiddenFileInput_U72As",fileDropZone:"FormRenderer-module_fileDropZone_8NKE1",dragActive:"FormRenderer-module_dragActive_qtLVK",fileDropContent:"FormRenderer-module_fileDropContent_sDLOE",uploadIcon:"FormRenderer-module_uploadIcon_DELPZ",uploadText:"FormRenderer-module_uploadText_ma2HB",uploadInfo:"FormRenderer-module_uploadInfo_7hEFv",fileList:"FormRenderer-module_fileList_aKgeG",fileItem:"FormRenderer-module_fileItem_ayYyp",fileIcon:"FormRenderer-module_fileIcon_RQ8oY",fileInfo:"FormRenderer-module_fileInfo_sVi-y",fileName:"FormRenderer-module_fileName_NImgu",fileSize:"FormRenderer-module_fileSize_8hW6K",removeFileButton:"FormRenderer-module_removeFileButton_Ryxz4",errorMessage:"FormRenderer-module_errorMessage_3K3WO",formErrorSummary:"FormRenderer-module_formErrorSummary_ZPF3z",errorLink:"FormRenderer-module_errorLink_QCsBd",fieldsetError:"FormRenderer-module_fieldsetError_yDnmw",toggleError:"FormRenderer-module_toggleError_onSl6",starRatingError:"FormRenderer-module_starRatingError_-J1XW",fileDropZoneError:"FormRenderer-module_fileDropZoneError_TOWxV",disabled:"FormRenderer-module_disabled_fy4qi",formActions:"FormRenderer-module_formActions_h9ukc",cancelButton:"FormRenderer-module_cancelButton_4SgM7",submitButton:"FormRenderer-module_submitButton_-swPt",buttonPulse:"FormRenderer-module_buttonPulse_v3f-K",light:"FormRenderer-module_light_p4yDB",dark:"FormRenderer-module_dark_iSdSY",blue:"FormRenderer-module_blue_-onh9",loaderIcon:"FormRenderer-module_loaderIcon_mYvBC",spin:"FormRenderer-module_spin_ephx2",submitButtonSuccess:"FormRenderer-module_submitButtonSuccess_FX5XW",successContent:"FormRenderer-module_successContent_dqHGY",checkIcon:"FormRenderer-module_checkIcon_M-L3h",checkSlideIn:"FormRenderer-module_checkSlideIn_Ivlw4",formSuccessState:"FormRenderer-module_formSuccessState_-tAX3",confettiOverlay:"FormRenderer-module_confettiOverlay_-CzXB",confettiPiece:"FormRenderer-module_confettiPiece_dj8VP",confettiFall:"FormRenderer-module_confettiFall_0kFhx",confettiShape1:"FormRenderer-module_confettiShape1_bh1hN",confettiShape2:"FormRenderer-module_confettiShape2_WvX4e",confettiShape3:"FormRenderer-module_confettiShape3_5e3oQ",confettiShape4:"FormRenderer-module_confettiShape4_B5Sa-",confettiShape5:"FormRenderer-module_confettiShape5_zBair",successCenter:"FormRenderer-module_successCenter_pJqdX",successPop:"FormRenderer-module_successPop_mwJqN",successCheckmark:"FormRenderer-module_successCheckmark_IQ83V",checkmarkSvg:"FormRenderer-module_checkmarkSvg_P-YUf",checkmarkCircle:"FormRenderer-module_checkmarkCircle_K7SpP",drawCircle:"FormRenderer-module_drawCircle_UuGAz",checkmarkCheck:"FormRenderer-module_checkmarkCheck_dYNpm",drawCheck:"FormRenderer-module_drawCheck_UZYXl",successText:"FormRenderer-module_successText_jlmjy",textFadeIn:"FormRenderer-module_textFadeIn_kGKYR",formErrorTitle:"FormRenderer-module_formErrorTitle_Ylr7a",confettiFallAnimation:"FormRenderer-module_confettiFallAnimation_LFuK5"};D('.FormRenderer-module_formInChat_U5Gpp{border-radius:.6rem;box-sizing:border-box;display:flex;flex-direction:column;font-family:Inter,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,sans-serif;font-size:.95rem;letter-spacing:.01em;line-height:1.6;margin-bottom:10px;margin-top:10px;max-height:100%;overflow-y:auto;padding:0 .2rem;position:relative;scrollbar-color:rgba(0,0,0,.2) transparent;scrollbar-width:thin;text-align:left;width:100%}.FormRenderer-module_formInChat_U5Gpp::-webkit-scrollbar{width:6px}.FormRenderer-module_formInChat_U5Gpp::-webkit-scrollbar-track{background:transparent}.FormRenderer-module_formInChat_U5Gpp::-webkit-scrollbar-thumb{background-color:rgba(0,0,0,.2);border-radius:3px}.FormRenderer-module_formContent_cCyya{box-sizing:border-box;flex:1;max-width:100%;padding-left:.2rem;padding-right:.2rem;width:100%}.FormRenderer-module_formInChatTitle_YM5kv{font-size:1.4rem;font-weight:550;line-height:1.3;margin-bottom:1.2rem;margin-top:.8rem}.FormRenderer-module_formDescription_wVULJ{line-height:1.625;margin-bottom:1.2rem}.FormRenderer-module_formInstructions_UvqAN{font-size:.875rem;line-height:1.5;margin-bottom:1.2rem}.FormRenderer-module_formSection_XInby{animation:FormRenderer-module_formSectionSlideIn_uypbb .4s ease forwards;border-left:2px solid var(--selected-color-light1,rgba(33,150,243,.3));margin-bottom:1.5rem;opacity:0;padding-left:12px;transform:translateY(20px);transition:transform .2s ease}.FormRenderer-module_formGroup_HWaSx{animation:FormRenderer-module_formGroupSlideIn_23Qgw .3s ease forwards;box-sizing:border-box;margin-bottom:1.2rem;opacity:0;transform:translateY(10px);width:100%}.FormRenderer-module_formGroup_HWaSx:first-child{animation-delay:.05s}.FormRenderer-module_formGroup_HWaSx:nth-child(2){animation-delay:.1s}.FormRenderer-module_formGroup_HWaSx:nth-child(3){animation-delay:.15s}.FormRenderer-module_formGroup_HWaSx:nth-child(4){animation-delay:.2s}.FormRenderer-module_formGroup_HWaSx:nth-child(5){animation-delay:.25s}.FormRenderer-module_formGroup_HWaSx:nth-child(6){animation-delay:.3s}.FormRenderer-module_formGroup_HWaSx:nth-child(7){animation-delay:.35s}.FormRenderer-module_formGroup_HWaSx:nth-child(8){animation-delay:.4s}.FormRenderer-module_formGroup_HWaSx:nth-child(9){animation-delay:.45s}.FormRenderer-module_formGroup_HWaSx:nth-child(10){animation-delay:.5s}.FormRenderer-module_formGroup_HWaSx:nth-child(n+11){animation-delay:.55s}.FormRenderer-module_formGroup_HWaSx label,.FormRenderer-module_legend_aqRMf,.FormRenderer-module_toggleLabel_Jhw9c{display:block;font-size:.9rem;font-weight:600;margin-bottom:.5rem}.FormRenderer-module_required_v5kwB{color:#d32f2f;font-weight:700;margin-left:.25rem}.FormRenderer-module_input_jWGA-,.FormRenderer-module_select_sGXpF,.FormRenderer-module_textarea_LLDyJ{border:1px solid #ccc;border-radius:.6rem;box-sizing:border-box;font-family:inherit;font-size:.95rem;line-height:1.5;padding:.6rem .75rem;transition:border-color .2s ease,box-shadow .2s ease,transform .2s ease;width:100%}.FormRenderer-module_select_sGXpF{padding-right:2.5rem}.FormRenderer-module_input_jWGA-:hover,.FormRenderer-module_select_sGXpF:hover,.FormRenderer-module_textarea_LLDyJ:hover{border-color:var(--selected-color,#2196f3)}.FormRenderer-module_input_jWGA-:focus,.FormRenderer-module_select_sGXpF:focus,.FormRenderer-module_textarea_LLDyJ:focus{border-color:var(--selected-color,#2196f3);box-shadow:0 0 0 3px var(--selected-color-light1,rgba(33,150,243,.3));outline:none}.FormRenderer-module_inputError_zBqFL,.FormRenderer-module_selectError_fZjR9,.FormRenderer-module_textareaError_6fKJS{animation:FormRenderer-module_shakeError_q7ATI .4s ease;border-color:#d32f2f!important;box-shadow:0 0 0 3px rgba(211,47,47,.1)}.FormRenderer-module_inputValid_jmerj,.FormRenderer-module_selectValid_s6jJ2,.FormRenderer-module_textareaValid_fJmqV{border-color:#4caf50}.FormRenderer-module_characterCount_HSKA-{color:#888;font-size:.75rem;margin-top:.25rem;text-align:right}.FormRenderer-module_selectionInfo_Ji-rn{color:#888;font-size:.75rem;margin-top:.5rem}.FormRenderer-module_fieldset_-7QtQ{border:1px solid #e0e0e0;border-radius:.6rem;margin:0;padding:1rem;transition:transform .2s ease}.FormRenderer-module_legend_aqRMf{border:none;font-weight:600;margin-left:.5rem;padding:0 .5rem;width:auto}.FormRenderer-module_radioGroup_GBiNx{display:flex;flex-direction:column;gap:.5rem}.FormRenderer-module_radioItem_mHJMl{align-items:flex-start;display:flex;gap:.5rem}.FormRenderer-module_radioInput_d8UCV{-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:#fff;border:2px solid #ccc;border-radius:50%;cursor:pointer;flex-shrink:0;height:18px;margin:0;position:relative;transition:border-color .2s ease,box-shadow .2s ease;width:18px}.FormRenderer-module_radioInput_d8UCV:hover{border-color:var(--selected-color,#2196f3)}.FormRenderer-module_radioInput_d8UCV:focus{box-shadow:0 0 0 3px var(--selected-color-light1,rgba(33,150,243,.3));outline:none}.FormRenderer-module_radioInput_d8UCV:checked{border-color:var(--selected-color,#2196f3)}.FormRenderer-module_radioInput_d8UCV:checked:after{background-color:var(--selected-color,#2196f3);border-radius:50%;content:"";height:8px;left:50%;position:absolute;top:50%;transform:translate(-50%,-50%);width:8px}.FormRenderer-module_radioLabel_05jqX{cursor:pointer;font-weight:400;line-height:1.5;margin:0}.FormRenderer-module_checkboxGroup_Fw2eM{display:flex;flex-direction:column;gap:.5rem}.FormRenderer-module_checkboxContainer_vq4jT{align-items:flex-start;display:flex;gap:.5rem}.FormRenderer-module_checkbox_WBm9R{-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:#fff;border:2px solid #ccc;border-radius:4px;cursor:pointer;flex-shrink:0;height:18px;margin:0;position:relative;transition:border-color .2s ease,background-color .2s ease,box-shadow .2s ease;width:18px}.FormRenderer-module_checkbox_WBm9R:hover{border-color:var(--selected-color,#2196f3)}.FormRenderer-module_checkbox_WBm9R:focus{box-shadow:0 0 0 3px var(--selected-color-light1,rgba(33,150,243,.3));outline:none}.FormRenderer-module_checkbox_WBm9R:checked{background-color:var(--selected-color,#2196f3);border-color:var(--selected-color,#2196f3)}.FormRenderer-module_checkbox_WBm9R:checked:after{border:solid #fff;border-width:0 2px 2px 0;content:"";height:6px;left:5px;position:absolute;top:2px;transform:rotate(45deg);width:3px}.FormRenderer-module_checkboxLabel_ziHms{cursor:pointer;font-weight:400;line-height:1.5;margin:0}.FormRenderer-module_toggleSwitchContainer_kHMTe{align-items:center;display:flex;justify-content:space-between}.FormRenderer-module_toggleSwitch_12Px-{display:inline-block;height:24px;position:relative;width:50px}.FormRenderer-module_toggleInput_-uljF{height:0;opacity:0;width:0}.FormRenderer-module_slider_lgvNk{background-color:#ccc;border-radius:24px;bottom:0;cursor:pointer;left:0;position:absolute;right:0;top:0;transition:background-color .4s ease,box-shadow .2s ease}.FormRenderer-module_slider_lgvNk:before{background-color:#fff;border-radius:50%;bottom:4px;box-shadow:0 2px 4px rgba(0,0,0,.2);content:"";height:16px;left:4px;position:absolute;transition:transform .4s ease,box-shadow .2s ease;width:16px}.FormRenderer-module_toggleInput_-uljF:checked+.FormRenderer-module_slider_lgvNk{background-color:var(--selected-color,#2196f3)}.FormRenderer-module_toggleInput_-uljF:focus+.FormRenderer-module_slider_lgvNk{box-shadow:0 0 0 3px var(--selected-color-light1,rgba(33,150,243,.3))}.FormRenderer-module_toggleInput_-uljF:checked+.FormRenderer-module_slider_lgvNk:before{transform:translateX(26px)}.FormRenderer-module_starRating_9vpTj{display:flex;gap:8px}.FormRenderer-module_star_Rmv7R{color:#ddd;cursor:pointer;font-size:24px;transition:color .2s ease,transform .2s ease,filter .2s ease}.FormRenderer-module_star_Rmv7R:hover{filter:drop-shadow(0 0 8px var(--selected-color-light1,rgba(33,150,243,.3)));transform:scale(1.15)}.FormRenderer-module_star_Rmv7R:focus{filter:drop-shadow(0 0 8px var(--selected-color,#2196F3));outline:none}.FormRenderer-module_star_Rmv7R.FormRenderer-module_filled_uzlvi{color:gold;filter:drop-shadow(0 0 4px rgba(255,215,0,.5))}.FormRenderer-module_star_Rmv7R.FormRenderer-module_filled_uzlvi:hover{filter:drop-shadow(0 0 8px rgba(255,215,0,.7))}.FormRenderer-module_fileInputWrapper_2xR3Q{width:100%}.FormRenderer-module_hiddenFileInput_U72As{display:none}.FormRenderer-module_fileDropZone_8NKE1{background-color:#fafafa;border:2px dashed #d0d0d0;border-radius:.6rem;box-shadow:0 1px 3px rgba(0,0,0,.05);cursor:pointer;padding:1.5rem;text-align:center;transition:all .3s ease}.FormRenderer-module_fileDropZone_8NKE1:hover{background-color:#f5f5f5;border-color:var(--selected-color,#2196f3);box-shadow:0 4px 12px var(--selected-color-light1,rgba(33,150,243,.3));transform:translateY(-1px)}.FormRenderer-module_fileDropZone_8NKE1.FormRenderer-module_dragActive_qtLVK{background-color:var(--selected-color-light1,rgba(33,150,243,.1));border-color:var(--selected-color,#2196f3);box-shadow:0 4px 16px var(--selected-color-light1,rgba(33,150,243,.4));transform:scale(1.01)}.FormRenderer-module_fileDropContent_sDLOE{align-items:center;display:flex;flex-direction:column;gap:.5rem}.FormRenderer-module_uploadIcon_DELPZ{color:#999;margin-bottom:.5rem;transition:transform .2s ease}.FormRenderer-module_fileDropZone_8NKE1:hover .FormRenderer-module_uploadIcon_DELPZ{transform:translateY(-2px)}.FormRenderer-module_uploadText_ma2HB{color:#333;font-size:1rem;font-weight:500;margin:0}.FormRenderer-module_uploadInfo_7hEFv{color:#888;font-size:.75rem;margin:0}.FormRenderer-module_fileList_aKgeG{display:flex;flex-direction:column;gap:.5rem;margin-top:1rem}.FormRenderer-module_fileItem_ayYyp{align-items:center;background-color:#f5f5f5;border:1px solid #e0e0e0;border-radius:.6rem;display:flex;padding:.75rem;transition:transform .2s ease,box-shadow .2s ease}.FormRenderer-module_fileItem_ayYyp:hover{box-shadow:0 2px 8px rgba(0,0,0,.08);transform:translateY(-1px)}.FormRenderer-module_fileIcon_RQ8oY{color:#666;flex-shrink:0;margin-right:.75rem}.FormRenderer-module_fileInfo_sVi-y{flex:1;min-width:0}.FormRenderer-module_fileName_NImgu{color:#333;font-size:.875rem;font-weight:500;margin:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.FormRenderer-module_fileSize_8hW6K{color:#666;font-size:.75rem;margin:0}.FormRenderer-module_removeFileButton_Ryxz4{background:none;border:none;border-radius:.375rem;color:#666;cursor:pointer;flex-shrink:0;padding:5px .25rem .25rem;transition:all .2s ease}.FormRenderer-module_removeFileButton_Ryxz4:hover{background-color:#e0e0e0;color:#333;transform:scale(1.1)}.FormRenderer-module_errorMessage_3K3WO{color:#d32f2f;display:block;font-size:.75rem;margin-top:.25rem}.FormRenderer-module_formErrorSummary_ZPF3z{background-color:rgba(211,47,47,.1);border:1px solid #d32f2f;border-radius:4px;margin-bottom:1.5rem;padding:1rem}.FormRenderer-module_formErrorSummary_ZPF3z h3{color:#d32f2f;font-size:1rem;margin:0 0 .5rem}.FormRenderer-module_formErrorSummary_ZPF3z ul{list-style-type:disc;margin:0;padding-left:1.2rem}.FormRenderer-module_formErrorSummary_ZPF3z li{margin-bottom:.25rem}.FormRenderer-module_errorLink_QCsBd{color:#d32f2f;cursor:pointer;text-decoration:underline}.FormRenderer-module_errorLink_QCsBd:hover{text-decoration:none}.FormRenderer-module_fieldsetError_yDnmw{border-color:#d32f2f}.FormRenderer-module_fieldsetError_yDnmw .FormRenderer-module_legend_aqRMf,.FormRenderer-module_toggleError_onSl6 .FormRenderer-module_toggleLabel_Jhw9c{color:#d32f2f}.FormRenderer-module_toggleError_onSl6 .FormRenderer-module_slider_lgvNk{box-shadow:0 0 0 1px #d32f2f}.FormRenderer-module_starRatingError_-J1XW .FormRenderer-module_star_Rmv7R{color:#d32f2f}.FormRenderer-module_starRatingError_-J1XW .FormRenderer-module_star_Rmv7R.FormRenderer-module_filled_uzlvi{color:gold}.FormRenderer-module_fileDropZoneError_TOWxV{background-color:rgba(211,47,47,.05);border-color:#d32f2f}.FormRenderer-module_disabled_fy4qi{cursor:not-allowed;opacity:.5}.FormRenderer-module_formActions_h9ukc{background-color:inherit;bottom:0;display:flex;gap:1rem;justify-content:flex-end;margin-top:1rem;padding-bottom:1rem;padding-top:1rem;position:sticky}.FormRenderer-module_cancelButton_4SgM7,.FormRenderer-module_submitButton_-swPt{border:none;border-radius:1.5rem;cursor:pointer;font-family:inherit;font-size:.95rem;font-weight:500;padding:.6rem 1.5rem;transition:all .2s ease}.FormRenderer-module_submitButton_-swPt{background:var(--selected-color);color:#fff}.FormRenderer-module_submitButton_-swPt:hover:not(:disabled){box-shadow:0 4px 12px var(--selected-color-light1,rgba(33,150,243,.3));filter:brightness(1.1);transform:scale(1.03)}.FormRenderer-module_submitButton_-swPt:active:not(:disabled){animation:FormRenderer-module_buttonPulse_v3f-K .2s ease-out;transform:scale(.95)}.FormRenderer-module_submitButton_-swPt:disabled{cursor:not-allowed;opacity:.5}.FormRenderer-module_cancelButton_4SgM7:hover:not(:disabled){filter:brightness(.95);transform:scale(1.03)}.FormRenderer-module_cancelButton_4SgM7:active:not(:disabled){transform:scale(.95)}.FormRenderer-module_formInChat_U5Gpp.FormRenderer-module_light_p4yDB{--selected-color:#2196f3;background-color:#fff;color:#333}.FormRenderer-module_cancelButton_4SgM7.FormRenderer-module_light_p4yDB{background-color:#e0e0e0;color:#333}.FormRenderer-module_submitButton_-swPt.FormRenderer-module_light_p4yDB{color:#fff}.FormRenderer-module_formInChat_U5Gpp.FormRenderer-module_dark_iSdSY{--selected-color:#4dabf5;background-color:#080f0fde;color:#fff;scrollbar-color:hsla(0,0%,100%,.2) transparent}.FormRenderer-module_formInChat_U5Gpp.FormRenderer-module_dark_iSdSY::-webkit-scrollbar-thumb{background-color:hsla(0,0%,100%,.2)}.FormRenderer-module_formInChat_U5Gpp.FormRenderer-module_dark_iSdSY .FormRenderer-module_input_jWGA-,.FormRenderer-module_formInChat_U5Gpp.FormRenderer-module_dark_iSdSY .FormRenderer-module_select_sGXpF,.FormRenderer-module_formInChat_U5Gpp.FormRenderer-module_dark_iSdSY .FormRenderer-module_textarea_LLDyJ{background-color:#000a0af7;border-color:#777;color:#fff}.FormRenderer-module_formInChat_U5Gpp.FormRenderer-module_dark_iSdSY .FormRenderer-module_checkbox_WBm9R{background-color:#1a1a1a;border-color:#777}.FormRenderer-module_formInChat_U5Gpp.FormRenderer-module_dark_iSdSY .FormRenderer-module_checkbox_WBm9R:checked{background-color:var(--selected-color,#2196f3);border-color:var(--selected-color,#2196f3)}.FormRenderer-module_formInChat_U5Gpp.FormRenderer-module_dark_iSdSY .FormRenderer-module_radioInput_d8UCV{background-color:#1a1a1a;border-color:#777}.FormRenderer-module_formInChat_U5Gpp.FormRenderer-module_dark_iSdSY .FormRenderer-module_radioInput_d8UCV:checked{border-color:var(--selected-color,#2196f3)}.FormRenderer-module_formInChat_U5Gpp.FormRenderer-module_dark_iSdSY .FormRenderer-module_fieldset_-7QtQ{border-color:#444}.FormRenderer-module_formInChat_U5Gpp.FormRenderer-module_dark_iSdSY .FormRenderer-module_fileDropZone_8NKE1{background-color:#1a1a1a;border-color:#555;box-shadow:0 1px 3px rgba(0,0,0,.3)}.FormRenderer-module_formInChat_U5Gpp.FormRenderer-module_dark_iSdSY .FormRenderer-module_fileDropZone_8NKE1:hover{background-color:#222;border-color:var(--selected-color,#4dabf5);box-shadow:0 4px 12px var(--selected-color-light1,rgba(77,171,245,.3))}.FormRenderer-module_formInChat_U5Gpp.FormRenderer-module_dark_iSdSY .FormRenderer-module_fileDropZone_8NKE1.FormRenderer-module_dragActive_qtLVK{background-color:var(--selected-color-light1,rgba(77,171,245,.1));border-color:var(--selected-color,#4dabf5);box-shadow:0 4px 16px var(--selected-color-light1,rgba(77,171,245,.4))}.FormRenderer-module_formInChat_U5Gpp.FormRenderer-module_dark_iSdSY .FormRenderer-module_fileDropZoneError_TOWxV{background-color:rgba(244,67,54,.1);border-color:#f44336}.FormRenderer-module_formInChat_U5Gpp.FormRenderer-module_dark_iSdSY .FormRenderer-module_uploadIcon_DELPZ{color:#bbb}.FormRenderer-module_formInChat_U5Gpp.FormRenderer-module_dark_iSdSY .FormRenderer-module_uploadText_ma2HB{color:#fff}.FormRenderer-module_formInChat_U5Gpp.FormRenderer-module_dark_iSdSY .FormRenderer-module_uploadInfo_7hEFv{color:#aaa}.FormRenderer-module_formInChat_U5Gpp.FormRenderer-module_dark_iSdSY .FormRenderer-module_fileItem_ayYyp{background-color:#2a2a2a;border-color:#444}.FormRenderer-module_formInChat_U5Gpp.FormRenderer-module_dark_iSdSY .FormRenderer-module_fileIcon_RQ8oY{color:#bbb}.FormRenderer-module_formInChat_U5Gpp.FormRenderer-module_dark_iSdSY .FormRenderer-module_fileName_NImgu{color:#fff}.FormRenderer-module_formInChat_U5Gpp.FormRenderer-module_dark_iSdSY .FormRenderer-module_fileSize_8hW6K{color:#ccc}.FormRenderer-module_formInChat_U5Gpp.FormRenderer-module_dark_iSdSY .FormRenderer-module_removeFileButton_Ryxz4{color:#bbb}.FormRenderer-module_cancelButton_4SgM7.FormRenderer-module_dark_iSdSY,.FormRenderer-module_formInChat_U5Gpp.FormRenderer-module_dark_iSdSY .FormRenderer-module_removeFileButton_Ryxz4:hover{background-color:#444;color:#fff}.FormRenderer-module_submitButton_-swPt.FormRenderer-module_dark_iSdSY{color:#fff}.FormRenderer-module_formInChat_U5Gpp.FormRenderer-module_blue_-onh9{--selected-color:#1976d2;background-color:#e3f2fd;color:#0d47a1}.FormRenderer-module_loaderIcon_mYvBC{animation:FormRenderer-module_spin_ephx2 .8s linear infinite}@keyframes FormRenderer-module_spin_ephx2{0%{transform:rotate(0deg)}to{transform:rotate(1turn)}}.FormRenderer-module_submitButtonSuccess_FX5XW{background:linear-gradient(45deg,#22c55e,#16a34a)!important;box-shadow:0 8px 20px rgba(34,197,94,.3);transform:scale(1.05);transition:all .3s cubic-bezier(.4,0,.2,1)}.FormRenderer-module_successContent_dqHGY{align-items:center;display:flex!important;gap:8px;justify-content:center}.FormRenderer-module_checkIcon_M-L3h{animation:FormRenderer-module_checkSlideIn_Ivlw4 .5s cubic-bezier(.4,0,.2,1)}.FormRenderer-module_formSuccessState_-tAX3{pointer-events:none;transition:all .3s ease}.FormRenderer-module_confettiOverlay_-CzXB{align-items:center;border-radius:.6rem;bottom:0;display:flex;justify-content:center;left:0;overflow:visible;pointer-events:none;position:absolute;right:0;top:0;z-index:9999}.FormRenderer-module_confettiOverlay_-CzXB.FormRenderer-module_light_p4yDB{background:hsla(0,0%,100%,.96)}.FormRenderer-module_confettiOverlay_-CzXB.FormRenderer-module_dark_iSdSY{background:rgba(17,24,39,.96)}.FormRenderer-module_confettiPiece_dj8VP{animation:FormRenderer-module_confettiFall_0kFhx 3s cubic-bezier(.25,.46,.45,.94) forwards;opacity:1;pointer-events:none;position:absolute;top:0;z-index:1}.FormRenderer-module_confettiShape1_bh1hN{background:#ff6b6b;border-radius:3px;box-shadow:0 2px 4px rgba(0,0,0,.1);height:30px;width:12px}.FormRenderer-module_confettiShape2_WvX4e{background:#4ecdc4;border-radius:2px;box-shadow:0 2px 4px rgba(0,0,0,.1);height:14px;width:14px}.FormRenderer-module_confettiShape3_5e3oQ{background:#ffe66d;border-radius:50%;box-shadow:0 2px 4px rgba(0,0,0,.1);height:12px;width:12px}.FormRenderer-module_confettiShape4_B5Sa-{background:#a78bfa;border-radius:4px;box-shadow:0 2px 4px rgba(0,0,0,.1);height:32px;width:10px}.FormRenderer-module_confettiShape5_zBair{background:#34d399;border-radius:2px;box-shadow:0 2px 4px rgba(0,0,0,.1);height:14px;transform:rotate(45deg);width:14px}.FormRenderer-module_successCenter_pJqdX{align-items:center;animation:FormRenderer-module_successPop_mwJqN .5s cubic-bezier(.68,-.55,.265,1.55) .2s both;display:flex;flex-direction:column;justify-content:center;z-index:10}.FormRenderer-module_successCheckmark_IQ83V{height:72px;margin-bottom:1rem;width:72px}.FormRenderer-module_checkmarkSvg_P-YUf{height:100%;width:100%}.FormRenderer-module_checkmarkCircle_K7SpP{stroke:var(--selected-color,#10b981);stroke-width:2.5;stroke-linecap:round;stroke-dasharray:151;stroke-dashoffset:151;animation:FormRenderer-module_drawCircle_UuGAz .6s ease-out .3s forwards}.FormRenderer-module_checkmarkCheck_dYNpm{stroke:var(--selected-color,#10b981);stroke-width:3;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:40;stroke-dashoffset:40;animation:FormRenderer-module_drawCheck_UZYXl .4s ease-out .8s forwards}.FormRenderer-module_successText_jlmjy{animation:FormRenderer-module_textFadeIn_kGKYR .4s ease-out 1s both;font-size:1.25rem;font-weight:600}.FormRenderer-module_confettiOverlay_-CzXB.FormRenderer-module_light_p4yDB .FormRenderer-module_successText_jlmjy{color:#1f2937}.FormRenderer-module_confettiOverlay_-CzXB.FormRenderer-module_dark_iSdSY .FormRenderer-module_successText_jlmjy{color:#f9fafb}@keyframes FormRenderer-module_successPop_mwJqN{0%{opacity:0;transform:scale(.5)}to{opacity:1;transform:scale(1)}}@keyframes FormRenderer-module_drawCircle_UuGAz{to{stroke-dashoffset:0}}@keyframes FormRenderer-module_drawCheck_UZYXl{to{stroke-dashoffset:0}}@keyframes FormRenderer-module_textFadeIn_kGKYR{0%{opacity:0;transform:translateY(10px)}to{opacity:1;transform:translateY(0)}}@keyframes FormRenderer-module_checkSlideIn_Ivlw4{0%{opacity:0;transform:translateX(-20px)}to{opacity:1;transform:translateX(0)}}@keyframes FormRenderer-module_formSectionSlideIn_uypbb{0%{opacity:0;transform:translateY(20px)}to{opacity:1;transform:translateY(0)}}@keyframes FormRenderer-module_formGroupSlideIn_23Qgw{0%{opacity:0;transform:translateY(10px)}to{opacity:1;transform:translateY(0)}}@keyframes FormRenderer-module_buttonPulse_v3f-K{0%{transform:scale(1)}50%{transform:scale(.95)}to{transform:scale(1)}}@keyframes FormRenderer-module_shakeError_q7ATI{0%,to{transform:translateX(0)}10%,30%,50%,70%,90%{transform:translateX(-4px)}20%,40%,60%,80%{transform:translateX(4px)}}@media (prefers-reduced-motion:reduce){.FormRenderer-module_cancelButton_4SgM7,.FormRenderer-module_checkmarkCheck_dYNpm,.FormRenderer-module_checkmarkCircle_K7SpP,.FormRenderer-module_confettiPiece_dj8VP,.FormRenderer-module_fileDropZone_8NKE1,.FormRenderer-module_fileItem_ayYyp,.FormRenderer-module_formGroup_HWaSx,.FormRenderer-module_formSection_XInby,.FormRenderer-module_input_jWGA-,.FormRenderer-module_select_sGXpF,.FormRenderer-module_slider_lgvNk:before,.FormRenderer-module_star_Rmv7R,.FormRenderer-module_submitButton_-swPt,.FormRenderer-module_successCenter_pJqdX,.FormRenderer-module_successCheckmark_IQ83V,.FormRenderer-module_textarea_LLDyJ{animation-duration:.01ms!important;animation-iteration-count:1!important;transition-duration:.01ms!important}}@media (max-width:768px){.FormRenderer-module_successCheckmark_IQ83V{height:60px;width:60px}.FormRenderer-module_successText_jlmjy{font-size:1.1rem}.FormRenderer-module_confettiShape1_bh1hN,.FormRenderer-module_confettiShape4_B5Sa-{height:20px;width:8px}.FormRenderer-module_confettiShape2_WvX4e,.FormRenderer-module_confettiShape3_5e3oQ,.FormRenderer-module_confettiShape5_zBair{height:10px;width:10px}}@media (max-width:480px){.FormRenderer-module_successCheckmark_IQ83V{height:50px;width:50px}.FormRenderer-module_successText_jlmjy{font-size:1rem}.FormRenderer-module_confettiShape1_bh1hN,.FormRenderer-module_confettiShape4_B5Sa-{height:16px;width:6px}.FormRenderer-module_confettiShape2_WvX4e,.FormRenderer-module_confettiShape3_5e3oQ,.FormRenderer-module_confettiShape5_zBair{height:8px;width:8px}}.FormRenderer-module_confettiOverlay_-CzXB *{will-change:transform,opacity}.FormRenderer-module_confettiOverlay_-CzXB{-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.FormRenderer-module_formErrorTitle_Ylr7a{color:#d32f2f;font-size:15px;font-weight:550;margin-bottom:.3rem}');const Dl=e=>{try{const{refreshToken:t}=JSON.parse(localStorage.getItem(`${e}_current_conversation`));return t}catch(t){return localStorage.removeItem(`${e}_current_conversation`),null}},Ul=e=>{try{const{idToken:t}=JSON.parse(localStorage.getItem(`${e}_current_conversation`));return t}catch(t){return localStorage.removeItem(`${e}_current_conversation`),null}};let jl=null;if("undefined"!=typeof window&&window.confetti)jl=window.confetti;else try{jl=require("canvas-confetti"),jl&&jl.default&&(jl=jl.default)}catch(e){if("undefined"!=typeof window&&"undefined"!=typeof document){const e=document.createElement("script");e.src="https://cdn.jsdelivr.net/npm/canvas-confetti@1.9.2/dist/confetti.browser.min.js",e.async=!0,e.onload=()=>{jl=window.confetti},document.head.appendChild(e)}}const Vl=()=>e.createElement("svg",{width:"48",height:"48",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5"},e.createElement("path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4"}),e.createElement("polyline",{points:"17,8 12,3 7,8"}),e.createElement("line",{x1:"12",y1:"3",x2:"12",y2:"15"})),Wl=()=>e.createElement("svg",{width:"20",height:"20",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2"},e.createElement("path",{d:"M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z"}),e.createElement("polyline",{points:"14,2 14,8 20,8"})),$l=()=>e.createElement("svg",{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2"},e.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),e.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),ql={required:(e,t)=>"checkbox"===t.type?Array.isArray(e)&&e.length>0:"star_rating"===t.type||"rating"===t.type?e>0:"file"===t.type?Array.isArray(e)&&e.length>0:"toggle_switch"===t.type||"switch"===t.type?!0===e:null!=e&&""!==e,email:e=>{if(!e)return!0;return/^[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/.test(e)},phone:e=>{if(!e)return!0;const t=e.replace(/[\s\-\(\)]/g,"");return/^[\+]?[1-9][\d]{0,15}$|^[\+]?[(]?[\d\s\-\(\)]{7,}$/.test(t)&&t.length>=7&&t.length<=15},number:(e,t)=>{if(!e&&0!==e)return!0;const n=Number(e);return!isNaN(n)&&(!(void 0!==t.min&&n<t.min)&&!(void 0!==t.max&&n>t.max))},text:(e,t)=>{if(!e)return!0;if(void 0!==t.minLength&&e.length<t.minLength)return!1;if(void 0!==t.maxLength&&e.length>t.maxLength)return!1;if(t.pattern){return new RegExp(t.pattern).test(e)}return!0},dropdown:(e,t)=>!e||t.options&&t.options.includes(e),radio:(e,t)=>!e||t.options&&t.options.includes(e),checkbox:(e,t)=>!!Array.isArray(e)&&(!(void 0!==t.minSelections&&e.length<t.minSelections)&&(!(void 0!==t.maxSelections&&e.length>t.maxSelections)&&e.every((e=>t.options&&t.options.includes(e))))),file:(e,t)=>!!Array.isArray(e)&&(!(void 0!==t.minFiles&&e.length<t.minFiles)&&!(void 0!==t.maxFiles&&e.length>t.maxFiles)),rating:(e,t)=>{if(null==e)return!t.required;const n=Number(e);if(isNaN(n))return!1;const r=t.max||5;return n>=0&&n<=r}},Xl={required:"This field is required",email:"Please enter a valid email address",phone:"Please enter a valid phone number",number:e=>void 0!==e.min&&void 0!==e.max?`Please enter a number between ${e.min} and ${e.max}`:void 0!==e.min?`Please enter a number greater than or equal to ${e.min}`:void 0!==e.max?`Please enter a number less than or equal to ${e.max}`:"Please enter a valid number",text:e=>void 0!==e.minLength&&void 0!==e.maxLength?`Please enter between ${e.minLength} and ${e.maxLength} characters`:void 0!==e.minLength?`Please enter at least ${e.minLength} characters`:void 0!==e.maxLength?`Please enter no more than ${e.maxLength} characters`:e.pattern?e.patternMessage||"Please enter a valid format":"Please enter valid text",dropdown:"Please select a valid option",radio:"Please select a valid option",checkbox:e=>void 0!==e.minSelections&&void 0!==e.maxSelections?`Please select between ${e.minSelections} and ${e.maxSelections} options`:void 0!==e.minSelections?`Please select at least ${e.minSelections} option(s)`:void 0!==e.maxSelections?`Please select no more than ${e.maxSelections} option(s)`:"Please select valid options",file:e=>void 0!==e.minFiles&&void 0!==e.maxFiles?`Please upload between ${e.minFiles} and ${e.maxFiles} files`:void 0!==e.minFiles?`Please upload at least ${e.minFiles} file(s)`:void 0!==e.maxFiles?`Please upload no more than ${e.maxFiles} file(s)`:"Please upload valid files",rating:e=>`Please provide a rating between 1 and ${e.max||5}`},Yl=(e,t)=>{const n=[];if(e.required&&!ql.required(t,e))return n.push(Xl.required),n;if(!e.required&&(!t||Array.isArray(t)&&0===t.length))return n;const r=ql[e.type];if(r&&!r(t,e)){const t=Xl[e.type];n.push("function"==typeof t?t(e):t)}return n},Gl=({field:t,value:n,onChange:r,error:o,touched:a,onBlur:i})=>e.createElement("div",{className:Hl.formGroup},e.createElement("label",{htmlFor:t.name},t.label,t.required&&e.createElement("span",{className:Hl.required},"*")),e.createElement("input",{type:"text",id:t.name,name:t.name,value:n||"",onChange:e=>r(t.name,e.target.value),onBlur:()=>i(t.name),className:`${Hl.input} ${o&&a?Hl.inputError:""} ${!o&&a&&n?Hl.inputValid:""}`,required:t.required,minLength:t.minLength,maxLength:t.maxLength,pattern:t.pattern,placeholder:t.placeholder,"aria-invalid":o&&a?"true":"false","aria-describedby":o&&a?`${t.name}-error`:void 0}),o&&a&&e.createElement("span",{id:`${t.name}-error`,className:Hl.errorMessage,role:"alert"},o),t.maxLength&&e.createElement("div",{className:Hl.characterCount},(n||"").length,"/",t.maxLength)),Zl=({field:t,value:n,onChange:r,error:o,touched:a,onBlur:i})=>e.createElement("div",{className:Hl.formGroup},e.createElement("label",{htmlFor:t.name},t.label,t.required&&e.createElement("span",{className:Hl.required},"*")),e.createElement("input",{type:"email",id:t.name,name:t.name,value:n||"",onChange:e=>r(t.name,e.target.value),onBlur:()=>i(t.name),className:`${Hl.input} ${o&&a?Hl.inputError:""} ${!o&&a&&n?Hl.inputValid:""}`,required:t.required,placeholder:t.placeholder||"Enter your email","aria-invalid":o&&a?"true":"false","aria-describedby":o&&a?`${t.name}-error`:void 0}),o&&a&&e.createElement("span",{id:`${t.name}-error`,className:Hl.errorMessage,role:"alert"},o)),Jl=({field:t,value:n,onChange:r,error:o,touched:a,onBlur:i})=>e.createElement("div",{className:Hl.formGroup},e.createElement("label",{htmlFor:t.name},t.label,t.required&&e.createElement("span",{className:Hl.required},"*")),e.createElement("input",{type:"number",id:t.name,name:t.name,value:n||"",onChange:e=>r(t.name,e.target.value),onBlur:()=>i(t.name),className:`${Hl.input} ${o&&a?Hl.inputError:""} ${!o&&a&&n?Hl.inputValid:""}`,required:t.required,min:t.min,max:t.max,step:t.step,placeholder:t.placeholder,"aria-invalid":o&&a?"true":"false","aria-describedby":o&&a?`${t.name}-error`:void 0}),o&&a&&e.createElement("span",{id:`${t.name}-error`,className:Hl.errorMessage,role:"alert"},o)),Kl=({field:t,value:n,onChange:r,error:o,touched:a,onBlur:i})=>e.createElement("div",{className:Hl.formGroup},e.createElement("label",{htmlFor:t.name},t.label,t.required&&e.createElement("span",{className:Hl.required},"*")),e.createElement("input",{type:"tel",id:t.name,name:t.name,value:n||"",onChange:e=>r(t.name,e.target.value),onBlur:()=>i(t.name),className:`${Hl.input} ${o&&a?Hl.inputError:""} ${!o&&a&&n?Hl.inputValid:""}`,required:t.required,placeholder:t.placeholder||"Enter your phone number","aria-invalid":o&&a?"true":"false","aria-describedby":o&&a?`${t.name}-error`:void 0}),o&&a&&e.createElement("span",{id:`${t.name}-error`,className:Hl.errorMessage,role:"alert"},o)),Ql=({field:t,value:n,onChange:r,error:o,touched:a,onBlur:i})=>e.createElement("div",{className:Hl.formGroup},e.createElement("label",{htmlFor:t.name},t.label,t.required&&e.createElement("span",{className:Hl.required},"*")),e.createElement("select",{id:t.name,name:t.name,value:n||"",onChange:e=>r(t.name,e.target.value),onBlur:()=>i(t.name),className:`${Hl.select} ${o&&a?Hl.selectError:""} ${!o&&a&&n?Hl.selectValid:""}`,required:t.required,"aria-invalid":o&&a?"true":"false","aria-describedby":o&&a?`${t.name}-error`:void 0},e.createElement("option",{value:""},"Select an option"),t.options.map((t=>e.createElement("option",{key:t,value:t},t)))),o&&a&&e.createElement("span",{id:`${t.name}-error`,className:Hl.errorMessage,role:"alert"},o)),es=({field:t,value:n,onChange:r,error:o,touched:a,onBlur:i})=>e.createElement("div",{className:Hl.formGroup},e.createElement("fieldset",{className:`${Hl.fieldset} ${o&&a?Hl.fieldsetError:""}`},e.createElement("legend",{className:Hl.legend},t.label,t.required&&e.createElement("span",{className:Hl.required},"*")),e.createElement("div",{className:Hl.radioGroup,role:"radiogroup","aria-invalid":o&&a?"true":"false"},t.options.map((o=>e.createElement("div",{key:o,className:Hl.radioItem},e.createElement("input",{type:"radio",id:`${t.name}-${o}`,name:t.name,value:o,checked:n===o,onChange:e=>r(t.name,e.target.value),onBlur:()=>i(t.name),className:Hl.radioInput,required:t.required}),e.createElement("label",{htmlFor:`${t.name}-${o}`,className:Hl.radioLabel},o)))))),o&&a&&e.createElement("span",{className:Hl.errorMessage,role:"alert"},o)),ts=({field:t,value:n,onChange:r,error:o,touched:a,onBlur:i})=>e.createElement("div",{className:Hl.formGroup},e.createElement("fieldset",{className:`${Hl.fieldset} ${o&&a?Hl.fieldsetError:""}`},e.createElement("legend",{className:Hl.legend},t.label,t.required&&e.createElement("span",{className:Hl.required},"*")),e.createElement("div",{className:Hl.checkboxGroup,role:"group","aria-invalid":o&&a?"true":"false"},t.options&&t.options.length>0&&t.options.map((o=>e.createElement("div",{key:o,className:Hl.checkboxContainer},e.createElement("input",{type:"checkbox",id:`${t.name}-${o}`,name:`${t.name}-${o}`,checked:Array.isArray(n)&&n.includes(o),onChange:e=>((e,o)=>{const a=Array.isArray(n)?n:[];let i;i=o?[...a,e]:a.filter((t=>t!==e)),r(t.name,i)})(o,e.target.checked),onBlur:()=>i(t.name),className:Hl.checkbox}),e.createElement("label",{htmlFor:`${t.name}-${o}`,className:Hl.checkboxLabel},o)))))),o&&a&&e.createElement("span",{className:Hl.errorMessage,role:"alert"},o),(t.minSelections||t.maxSelections)&&e.createElement("div",{className:Hl.selectionInfo},t.minSelections&&t.maxSelections?`Select ${t.minSelections}-${t.maxSelections} options`:t.minSelections?`Select at least ${t.minSelections} option(s)`:`Select up to ${t.maxSelections} option(s)`)),ns=({field:t,value:n,onChange:r,error:o,touched:a,onBlur:i})=>e.createElement("div",{className:Hl.formGroup},e.createElement("div",{className:`${Hl.toggleSwitchContainer} ${o&&a?Hl.toggleError:""}`},e.createElement("span",{className:Hl.toggleLabel},t.label,t.required&&e.createElement("span",{className:Hl.required},"*")),e.createElement("label",{className:Hl.toggleSwitch},e.createElement("input",{type:"checkbox",id:t.name,name:t.name,checked:!!n,onChange:e=>r(t.name,e.target.checked),onBlur:()=>i(t.name),className:Hl.toggleInput,required:t.required,"aria-invalid":o&&a?"true":"false"}),e.createElement("span",{className:Hl.slider}))),o&&a&&e.createElement("span",{className:Hl.errorMessage,role:"alert"},o)),rs=({field:n,value:r,onChange:o,error:a,urlId:i,touched:l,onBlur:s})=>{const[c,u]=t(!1),[d,m]=t([]),[p,f]=t(""),[h,g]=t(!1),[_,y]=t(!1),b=e.useRef(null),v=a||p,{maxFiles:x=1,maxSizeInMB:k=10,accept:w="",multiple:C=!1,instantUpload:E=!0}=n,S=e=>{f("");let t=Array.from(e);if(t.filter((e=>{if(!w)return!1;const t=w.split(",").map((e=>e.trim().toLowerCase())),n=e.type.toLowerCase(),r=`.${e.name.split(".").pop()?.toLowerCase()}`;return!t.some((e=>e.startsWith(".")?e===r:new RegExp(e.replace("*",".*")).test(n)))})).length>0)return void f(`Invalid file type. Accepted: ${w}`);if(t.filter((e=>e.size>1024*k*1024)).length>0)return void f(`File(s) exceed maximum size of ${k}MB.`);(Array.isArray(r)?r.length:0)+t.length>x?f(`Cannot upload more than ${x} file(s).`):E?(async e=>{if(0===e.length)return;g(!0),f(""),m(e);const t=new FormData;e.forEach((e=>t.append("files",e)));const a=Ul(i);if(!a)return g(!1),void f("Upload failed. Please try again.");try{const e=await Kt.post(`/api/files/upload?urlId=${i}`,t,{headers:{"Content-Type":"multipart/form-data",Authorization:`Bearer ${a}`}});if(e.data.success){const t=[...Array.isArray(r)?r:[],...e.data.files];o(n.name,t),m([])}else f(e.data.error||"Upload failed."),m([])}catch(e){f("Upload failed. Please try again."),m([])}finally{g(!1)}})(t):(m((e=>[...e,...t])),o(n.name,[...d,...t]))},R=e=>{e.preventDefault(),e.stopPropagation(),u("dragover"===e.type)},F=E?Array.isArray(r)?r:[]:d;return e.createElement("div",{className:Hl.formGroup},e.createElement("label",null,n.label,n.required&&e.createElement("span",{className:Hl.required},"*")),e.createElement("div",{className:Hl.fileInputWrapper},e.createElement("input",{type:"file",ref:b,className:Hl.hiddenFileInput,accept:w,multiple:C,onChange:e=>{h||(S(e.target.files),e.target.value="")},onBlur:()=>s(n.name),disabled:h}),e.createElement("div",{className:`${Hl.fileDropZone} ${c?Hl.dragActive:""} ${v&&l?Hl.fileDropZoneError:""} ${h?Hl.disabled:""}`,onClick:()=>!h&&b.current.click(),onDrop:e=>{e.preventDefault(),e.stopPropagation(),u(!1),h||S(e.dataTransfer.files)},onDragOver:R,onDragLeave:R,onDragEnter:R,role:"button",tabIndex:0,"aria-invalid":v&&l?"true":"false"},e.createElement("div",{className:Hl.fileDropContent},e.createElement("div",{className:Hl.uploadIcon},e.createElement(Vl,null)),e.createElement("p",{className:Hl.uploadText},h?"Uploading...":"Drag & drop or click to browse"),e.createElement("p",{className:Hl.uploadInfo},"Max files: ",x,", Max size: ",k,"MB"))),v&&l&&e.createElement("span",{className:Hl.errorMessage,role:"alert"},v),e.createElement("div",{className:Hl.fileList},h&&d.map(((t,n)=>e.createElement("div",{key:`${t.name}-${n}`,className:Hl.fileItem},e.createElement("div",{className:Hl.fileIcon},e.createElement(Wl,null)),e.createElement("div",{className:Hl.fileInfo},e.createElement("p",{className:Hl.fileName},t.name),e.createElement("div",{style:{display:"flex",alignItems:"center",gap:"5px",marginTop:"3px"}},e.createElement(Pl,{className:Hl.loaderIcon,size:14}),e.createElement("p",{className:Hl.fileSize},"Uploading...")))))),!h&&F.map(((t,a)=>e.createElement("div",{key:t._id||t.name,className:Hl.fileItem},e.createElement("div",{className:Hl.fileIcon},e.createElement(Wl,null)),e.createElement("div",{className:Hl.fileInfo},e.createElement("p",{className:Hl.fileName},t.name),e.createElement("p",{className:Hl.fileSize},E?"Uploaded":(e=>{if(0===e)return"0 Bytes";const t=Math.floor(Math.log(e)/Math.log(1024));return parseFloat((e/Math.pow(1024,t)).toFixed(2))+" "+["Bytes","KB","MB","GB","TB"][t]})(t.size))),e.createElement("button",{type:"button",disabled:_,className:Hl.removeFileButton,onClick:()=>(async(e,t)=>{const a=Ul(i);if(a)try{if(y(!0),await Kt.delete(`/api/files/${r[e]?._id}`,{headers:{Authorization:`Bearer ${a}`}}),y(!1),t){const t=r.filter(((t,n)=>n!==e));o(n.name,t)}else{const t=d.filter(((t,n)=>n!==e));m(t),E||o(n.name,t)}}catch(e){f("Failed to remove file. Please try again.")}finally{y(!1)}else f("Failed to remove file. Please try again.")})(a,E)},e.createElement($l,null))))))))},os=({field:t,value:n,onChange:r,error:o,touched:a,onBlur:i})=>{const l=t.max||5;return e.createElement("div",{className:Hl.formGroup},e.createElement("label",{htmlFor:t.name},t.label,t.required&&e.createElement("span",{className:Hl.required},"*")),e.createElement("div",{className:`${Hl.starRating} ${o&&a?Hl.starRatingError:""}`,role:"radiogroup","aria-label":t.label,"aria-invalid":o&&a?"true":"false",onBlur:()=>i(t.name)},[...Array(l)].map(((o,a)=>{const i=a+1;return e.createElement("span",{key:a,className:`${Hl.star} ${i<=n?Hl.filled:""}`,onClick:()=>r(t.name,i),role:"radio",tabIndex:"0","aria-checked":i===n,onKeyPress:e=>{"Enter"!==e.key&&" "!==e.key||(e.preventDefault(),r(t.name,i))}},e.createElement(Ll,{size:28}))}))),o&&a&&e.createElement("span",{className:Hl.errorMessage,role:"alert"},o))},as=({form:n,theme:r="light",onSubmit:i,onCancel:l,isSubmitting:s=!1,isCancelling:c=!1,selectedColor:u,urlId:d})=>{const[m,p]=t({}),[f,h]=t({}),[g,_]=t({}),[y,b]=t(!1),[v,x]=t(!1),[k,w]=t(!1),C=o(null);a((()=>{const e={};n.fields.forEach((t=>{e[t.name]="toggle_switch"!==t.type&&"switch"!==t.type&&("checkbox"===t.type?[]:"star_rating"===t.type||"rating"===t.type?0:"file"===t.type?[]:"")})),p(e)}),[n]);const E=(e,t)=>{p((n=>({...n,[e]:t})));const r=n.fields.find((t=>t.name===e)),o=["file","checkbox","radio","dropdown","toggle_switch","switch","star_rating","rating"].includes(r.type);if(g[e]||y||o){o&&!g[e]&&_((t=>({...t,[e]:!0})));const n=Yl(r,t);h((t=>({...t,[e]:n.length>0?n[0]:null})))}},S=e=>{_((t=>({...t,[e]:!0})));const t=n.fields.find((t=>t.name===e)),r=m[e],o=Yl(t,r);h((t=>({...t,[e]:o.length>0?o[0]:null})))};if(!n||!n.fields)return e.createElement("div",null,"Loading form...");const R=()=>{if(u.includes("gradient")){const e=vs(u,.8),t=vs(u,.3);return{"--selected-color":u,"--selected-color-light":e,"--selected-color-light1":t}}return{"--selected-color":u,"--selected-color-light":`${u}99`,"--selected-color-light1":`${u}4D`}},F=Object.values(f).some((e=>null!==e));return e.createElement("div",{style:{position:"relative",width:"100%"}},e.createElement("canvas",{ref:C,style:{position:"absolute",top:0,left:0,width:"100%",height:"100%",pointerEvents:"none",zIndex:9998,borderRadius:"0.6rem"}}),e.createElement("form",{className:`${Hl.formInChat} ${Hl[r]} ${F?Hl.formWithErrors:""} ${k?Hl.formSuccessState:""}`,onSubmit:e=>{if(e.preventDefault(),b(!0),(()=>{const e={};let t=!0;n.fields.forEach((n=>{const r=m[n.name],o=Yl(n,r);o.length>0?(e[n.name]=o[0],t=!1):e[n.name]=null})),h(e);const r={};return n.fields.forEach((e=>{r[e.name]=!0})),_(r),t})())x(!0),setTimeout((()=>{if(w(!0),C.current&&jl){const e=jl.create(C.current,{resize:!0,useWorker:!0}),t=3e3,n=Date.now()+t,r={startVelocity:30,spread:360,ticks:60,zIndex:0,colors:["#FF6B6B","#4ECDC4","#FFE66D","#A78BFA","#34D399","#F472B6","#60A5FA","#FB923C","#EC4899","#10B981"]};function o(e,t){return Math.random()*(t-e)+e}const a=setInterval((function(){const i=n-Date.now();if(i<=0)return clearInterval(a);const l=i/t*60;e(Object.assign({},r,{particleCount:l,origin:{x:o(.1,.3),y:Math.random()-.2}})),e(Object.assign({},r,{particleCount:l,origin:{x:o(.7,.9),y:Math.random()-.2}}))}),250)}}),800),setTimeout((()=>{w(!1),x(!1),i(m)}),4e3);else{const e=n.fields.find((e=>f[e.name]));if(e){const t=document.getElementById(e.name);t&&(t.focus(),t.scrollIntoView({behavior:"smooth",block:"center"}))}}},style:R(),noValidate:!0},e.createElement("div",{className:Hl.formInChatTitle},n.title),n.description&&e.createElement("div",{className:Hl.formDescription},n.description),n.instructions&&e.createElement("div",{className:Hl.formInstructions},n.instructions),y&&F&&e.createElement("div",{className:Hl.formErrorSummary,role:"alert"},e.createElement("div",{className:Hl.formErrorTitle},"Please correct the following errors:"),e.createElement("ul",null,n.fields.filter((e=>f[e.name])).map((t=>e.createElement("li",{key:t.name},e.createElement("a",{href:"#",onClick:e=>{e.preventDefault();const n=document.getElementById(t.name);n&&(n.focus(),n.scrollIntoView({behavior:"smooth",block:"center"}))},className:Hl.errorLink},t.label,": ",f[t.name])))))),e.createElement("div",{className:Hl.formContent},n.fields.map((t=>e.createElement("div",{key:t._id||t.name,className:Hl.formSection},(t=>{const n=m[t.name],r=f[t.name],o=g[t.name],a={field:t,value:n,onChange:E,onBlur:S,error:r,touched:o};switch(t.type){case"text":return e.createElement(Gl,a);case"email":return e.createElement(Zl,a);case"number":return e.createElement(Jl,a);case"phone":return e.createElement(Kl,a);case"dropdown":return e.createElement(Ql,a);case"radio":return e.createElement(es,a);case"checkbox":return e.createElement(ts,a);case"switch":case"toggle_switch":return e.createElement(ns,a);case"file":return e.createElement(rs,zl({},a,{urlId:d}));case"rating":case"star_rating":return e.createElement(os,a);default:return e.createElement("div",null,"Unsupported field type: ",t.type)}})(t))))),e.createElement("div",{className:`${Hl.formActions} ${Hl[r]}`},e.createElement("button",{type:"button",onClick:l,style:{pointerEvents:c||s||v?"none":"all",opacity:c||s||v?.5:1},className:`${Hl.cancelButton} ${Hl[r]}`,disabled:c||s||v},c?e.createElement("span",{style:{display:"flex",alignItems:"center"}},e.createElement(Pl,{style:{marginRight:"5px"},className:Hl.loaderIcon,size:18}),e.createElement("span",null,n.cancelButtonText||"Cancel")):n.cancelButtonText||"Cancel"),e.createElement("button",{disabled:s||c,type:"submit",style:{pointerEvents:s||c?"none":"all",opacity:s||c?.5:1},className:`${Hl.submitButton} ${Hl[r]} ${v?Hl.submitButtonSuccess:""}`},v?e.createElement("span",{className:Hl.successContent},e.createElement("svg",{className:Hl.checkIcon,viewBox:"0 0 24 24",width:"20",height:"20"},e.createElement("path",{fill:"currentColor",d:"M9 16.17L4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41L9 16.17z"})),e.createElement("span",null,"Success!")):s?e.createElement("span",{style:{display:"flex",alignItems:"center"}},e.createElement(Pl,{style:{marginRight:"5px"},className:Hl.loaderIcon,size:18}),e.createElement("span",null,n.submitButtonText||"Submit")):n.submitButtonText||"Submit"))),k&&e.createElement("div",{style:{position:"absolute",top:0,left:0,right:0,bottom:0,zIndex:9999,display:"flex",alignItems:"center",justifyContent:"center",pointerEvents:"none",...R()}},e.createElement("div",{className:Hl.successCenter},e.createElement("div",{className:Hl.successCheckmark},e.createElement("svg",{viewBox:"0 0 52 52",className:Hl.checkmarkSvg},e.createElement("circle",{className:Hl.checkmarkCircle,cx:"26",cy:"26",r:"24",fill:"none"}),e.createElement("path",{className:Hl.checkmarkCheck,fill:"none",d:"M14 27l7 7 16-16"}))),e.createElement("div",{className:Hl.successText,style:{color:"dark"===r?"#f9fafb":"#1f2937",textShadow:"dark"===r?"0 2px 8px rgba(0,0,0,0.8)":"0 2px 8px rgba(255,255,255,0.8)"}},"Submitted!"))))};as.propTypes={form:m.exports.shape({title:m.exports.string,description:m.exports.string,instructions:m.exports.string,fields:m.exports.arrayOf(m.exports.shape({_id:m.exports.string,name:m.exports.string.isRequired,type:m.exports.string.isRequired,label:m.exports.string.isRequired,required:m.exports.bool,min:m.exports.number,max:m.exports.number,minLength:m.exports.number,maxLength:m.exports.number,minSelections:m.exports.number,maxSelections:m.exports.number,minFiles:m.exports.number,maxFiles:m.exports.number,pattern:m.exports.string,patternMessage:m.exports.string,placeholder:m.exports.string,step:m.exports.number,options:m.exports.arrayOf(m.exports.string),multiple:m.exports.bool,accept:m.exports.string,maxSizeInMB:m.exports.number,instantUpload:m.exports.bool})).isRequired,submitButtonText:m.exports.string,cancelButtonText:m.exports.string}).isRequired,theme:m.exports.oneOf(["light","dark","blue"]),onSubmit:m.exports.func.isRequired,onCancel:m.exports.func.isRequired,isSubmitting:m.exports.bool,isCancelling:m.exports.bool,selectedColor:m.exports.string,urlId:m.exports.string};var is=as,ls={sidebar:"Sidebar-module_sidebar_6y-lC",dark:"Sidebar-module_dark_xgW5c",visible:"Sidebar-module_visible_eP78W",hidden:"Sidebar-module_hidden_cXRLA",sidebarButton:"Sidebar-module_sidebarButton_K951Q",active:"Sidebar-module_active_n6Ibt",sidebarIndicator:"Sidebar-module_sidebarIndicator_iozci"};D(".Sidebar-module_sidebar_6y-lC{align-items:center;background-color:#fff;border-bottom:1px solid rgba(0,0,0,.1);border-bottom-right-radius:5px;border-right:1px solid rgba(0,0,0,.1);border-top:1px solid rgba(0,0,0,.1);border-top-right-radius:5px;bottom:50%;box-shadow:2px 0 8px rgba(0,0,0,.1);display:flex;flex-direction:column;left:0;padding-bottom:.1rem;padding-top:.5rem;position:absolute;transition:transform .3s ease,opacity .3s ease;width:32px;z-index:1000}.Sidebar-module_sidebar_6y-lC.Sidebar-module_dark_xgW5c{background-color:#121212;border-bottom:1px solid hsla(0,0%,100%,.2);border-right:1px solid hsla(0,0%,100%,.2);border-top:1px solid hsla(0,0%,100%,.2);box-shadow:2px 0 8px rgba(0,0,0,.3)}.Sidebar-module_sidebar_6y-lC.Sidebar-module_visible_eP78W{opacity:1;transform:translateX(0)}.Sidebar-module_sidebar_6y-lC.Sidebar-module_hidden_cXRLA{opacity:0;pointer-events:none;transform:translateX(-100%)}.Sidebar-module_sidebarButton_K951Q{align-items:center;background:transparent;border:1px solid rgba(0,0,0,.1);border-radius:50%;color:#555;cursor:pointer;display:flex;height:25px;justify-content:center;margin-bottom:12px;transition:all .2s ease;width:25px}.Sidebar-module_sidebarButton_K951Q.Sidebar-module_dark_xgW5c{border:1px solid hsla(0,0%,100%,.2);color:#fff}.Sidebar-module_sidebarButton_K951Q:hover{transform:scale(1.1)}.Sidebar-module_sidebarButton_K951Q.Sidebar-module_active_n6Ibt{background:var(--selected-color);border-color:var(--selected-color);color:#fff}.Sidebar-module_sidebarIndicator_iozci{background-color:var(--selected-color);border-bottom-right-radius:3px;border-top-right-radius:3px;height:50px;left:0;opacity:.5;position:fixed;top:80px;transition:opacity .3s ease;width:5px;z-index:999}.Sidebar-module_sidebarIndicator_iozci:hover{cursor:pointer;opacity:.8}");var ss=({onButtonClick:t})=>{const{theme:n}=H();return e.createElement(e.Fragment,null,e.createElement("div",{className:`${ls.sidebar} ${ls[n]}`},e.createElement("button",{className:`${ls.sidebarButton} ${ls[n]}`,onClick:()=>t("start-new-conversation"),title:"Start new conversation (⌘I / Ctrl+I)"},e.createElement(Tl,{size:14})),e.createElement("button",{className:`${ls.sidebarButton} ${ls[n]}`,onClick:()=>t("view-conversations"),title:"View conversations (⌘H / Ctrl+H)"},e.createElement(Bl,{size:14}))))},cs={conversationHistoryContainer:"ConversationsHistory-module_conversationHistoryContainer_73p-6",hidden:"ConversationsHistory-module_hidden_7VCOS",visible:"ConversationsHistory-module_visible_iqpOG",conversationHistoryPanel:"ConversationsHistory-module_conversationHistoryPanel_YfVTg",dark:"ConversationsHistory-module_dark_GMvce",conversationHistoryHeader:"ConversationsHistory-module_conversationHistoryHeader_y-Hl-",conversationHistoryTitle:"ConversationsHistory-module_conversationHistoryTitle_2EaH7",closeButton:"ConversationsHistory-module_closeButton_xl2pZ",conversationHistorySearch:"ConversationsHistory-module_conversationHistorySearch_4S8to",conversationHistorySearchDark:"ConversationsHistory-module_conversationHistorySearchDark_092le",conversationHistorySearchLight:"ConversationsHistory-module_conversationHistorySearchLight_nVuQP",conversationList:"ConversationsHistory-module_conversationList_9NJgj",conversationItem:"ConversationsHistory-module_conversationItem_viuer",conversationItemContent:"ConversationsHistory-module_conversationItemContent_caWu9",conversationItemHeader:"ConversationsHistory-module_conversationItemHeader_VP-QU",conversationDate:"ConversationsHistory-module_conversationDate_eX0St",conversationPreview:"ConversationsHistory-module_conversationPreview_VGqPz",unreadIndicator:"ConversationsHistory-module_unreadIndicator_-YroL",noResults:"ConversationsHistory-module_noResults_9Ps7l",conversationHistoryFooter:"ConversationsHistory-module_conversationHistoryFooter_vwGRT",newConversationButton:"ConversationsHistory-module_newConversationButton_hwT0p",conversationHistoryHeadingText:"ConversationsHistory-module_conversationHistoryHeadingText_LQC5N",conversationHistoryTitleText:"ConversationsHistory-module_conversationHistoryTitleText_fCnvo"};D(".ConversationsHistory-module_conversationHistoryContainer_73p-6{background-color:rgba(0,0,0,.25);display:flex;height:100%;justify-content:start;transition:opacity .3s ease;width:100%;z-index:1001}.ConversationsHistory-module_conversationHistoryContainer_73p-6.ConversationsHistory-module_hidden_7VCOS{opacity:0;pointer-events:none}.ConversationsHistory-module_conversationHistoryContainer_73p-6.ConversationsHistory-module_visible_iqpOG{opacity:1}.ConversationsHistory-module_conversationHistoryPanel_YfVTg{background-color:#fff;box-shadow:2px 0 10px rgba(0,0,0,.1);display:flex;flex-direction:column;height:100%;max-width:400px;transition:transform .3s ease;width:100%}.ConversationsHistory-module_conversationHistoryContainer_73p-6.ConversationsHistory-module_hidden_7VCOS .ConversationsHistory-module_conversationHistoryPanel_YfVTg{transform:translateX(-100%)}.ConversationsHistory-module_conversationHistoryContainer_73p-6.ConversationsHistory-module_visible_iqpOG .ConversationsHistory-module_conversationHistoryPanel_YfVTg{transform:translateX(0)}.ConversationsHistory-module_conversationHistoryContainer_73p-6.ConversationsHistory-module_dark_GMvce .ConversationsHistory-module_conversationHistoryPanel_YfVTg{background-color:#121212;box-shadow:2px 0 10px rgba(0,0,0,.3);color:#f2e7fe}.ConversationsHistory-module_conversationHistoryHeader_y-Hl-{align-items:center;border-bottom:1px solid #eee;display:flex;justify-content:space-between;padding:16px}.ConversationsHistory-module_conversationHistoryContainer_73p-6.ConversationsHistory-module_dark_GMvce .ConversationsHistory-module_conversationHistoryHeader_y-Hl-{border-bottom:1px solid #333}.ConversationsHistory-module_conversationHistoryTitle_2EaH7{align-items:center;display:flex;gap:8px}.ConversationsHistory-module_conversationHistoryTitle_2EaH7 h3{font-size:16px;font-weight:600;margin:0}.ConversationsHistory-module_closeButton_xl2pZ{align-items:center;background:none;border:none;border-radius:50%;color:#555;cursor:pointer;display:flex;justify-content:center;padding:4px}.ConversationsHistory-module_conversationHistoryContainer_73p-6.ConversationsHistory-module_dark_GMvce .ConversationsHistory-module_closeButton_xl2pZ{color:#f2e7fe}.ConversationsHistory-module_closeButton_xl2pZ:hover{background-color:rgba(0,0,0,.05)}.ConversationsHistory-module_conversationHistoryContainer_73p-6.ConversationsHistory-module_dark_GMvce .ConversationsHistory-module_closeButton_xl2pZ:hover{background-color:hsla(0,0%,100%,.1)}.ConversationsHistory-module_conversationHistorySearch_4S8to{border-bottom:1px solid #eee;padding:12px 16px}.ConversationsHistory-module_conversationHistoryContainer_73p-6.ConversationsHistory-module_dark_GMvce .ConversationsHistory-module_conversationHistorySearch_4S8to{border-bottom:1px solid #333}.ConversationsHistory-module_conversationHistorySearch_4S8to input{border:1px solid #ddd;border-radius:14px;font-size:14px;outline:none;padding:8px 12px;width:100%}.ConversationsHistory-module_conversationHistorySearchDark_092le{background-color:#222;border:1px solid #444;color:#fff}.ConversationsHistory-module_conversationHistorySearchLight_nVuQP{background-color:#fff;border:1px solid #ccc;color:#000}.ConversationsHistory-module_conversationList_9NJgj{flex:1;overflow-y:auto;padding:0}.ConversationsHistory-module_conversationItem_viuer{align-items:center;border-bottom:1px solid #f0f0f0;cursor:pointer;display:flex;justify-content:space-between;padding:12px 16px;transition:background-color .2s ease}.ConversationsHistory-module_conversationItem_viuer.ConversationsHistory-module_dark_GMvce{border-bottom:1px solid #333}.ConversationsHistory-module_conversationItem_viuer:hover{background-color:#f7f7f7}.ConversationsHistory-module_conversationItem_viuer.ConversationsHistory-module_dark_GMvce:hover{background-color:#222}.ConversationsHistory-module_conversationItemContent_caWu9{flex:1;overflow:hidden}.ConversationsHistory-module_conversationItemHeader_VP-QU{align-items:center;display:flex;justify-content:space-between;margin-bottom:4px}.ConversationsHistory-module_conversationItemHeader_VP-QU h4{font-size:14px;font-weight:500;margin:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.ConversationsHistory-module_conversationDate_eX0St{color:#777;font-size:12px}.ConversationsHistory-module_conversationItem_viuer.ConversationsHistory-module_dark_GMvce .ConversationsHistory-module_conversationDate_eX0St{color:#aaa}.ConversationsHistory-module_conversationPreview_VGqPz{color:#666;font-size:13px;margin:0;overflow:hidden;text-align:left;text-overflow:ellipsis;white-space:nowrap}.ConversationsHistory-module_conversationItem_viuer.ConversationsHistory-module_dark_GMvce .ConversationsHistory-module_conversationPreview_VGqPz{color:#bbb}.ConversationsHistory-module_unreadIndicator_-YroL{border-radius:50%;height:8px;margin-left:8px;width:8px}.ConversationsHistory-module_noResults_9Ps7l{color:#777;font-size:14px;padding:24px 16px;text-align:center}.ConversationsHistory-module_conversationHistoryContainer_73p-6.ConversationsHistory-module_dark_GMvce .ConversationsHistory-module_noResults_9Ps7l{color:#aaa}.ConversationsHistory-module_conversationHistoryFooter_vwGRT{border-top:1px solid #eee;padding:12px 16px}.ConversationsHistory-module_conversationHistoryContainer_73p-6.ConversationsHistory-module_dark_GMvce .ConversationsHistory-module_conversationHistoryFooter_vwGRT{border-top:1px solid #333}.ConversationsHistory-module_newConversationButton_hwT0p{border:none;border-radius:14px;color:#fff;cursor:pointer;font-size:13px;font-weight:500;padding:10px;transition:opacity .2s ease;width:100%}.ConversationsHistory-module_newConversationButton_hwT0p:hover{opacity:.9}.ConversationsHistory-module_conversationHistoryHeadingText_LQC5N{font-size:15px;font-weight:550}.ConversationsHistory-module_conversationHistoryTitleText_fCnvo{font-size:14px;font-weight:500}");const us=e=>{try{const t=JSON.parse(localStorage.getItem(`${e}_conversations`));return t||{}}catch(t){return localStorage.removeItem(`${e}_conversations`),{}}},ds=(e,t)=>{try{localStorage.setItem(`${e}_conversations`,JSON.stringify(t))}catch(t){localStorage.removeItem(`${e}_conversations`)}},ms=(e,t)=>{try{localStorage.setItem(`${e}_current_conversation`,JSON.stringify(t))}catch(t){localStorage.removeItem(`${e}_current_conversation`)}},ps=async(e,t)=>{try{return(await Kt.post(`/api/identities/${t}`,e)).data}catch(e){return null}};var fs=({urlId:n,onSelectConversation:r,onClose:o,selectedColor:i})=>{const{theme:l}=H(),[s,c]=t([]),[u,d]=t(!1),[m,p]=t(""),[f,h]=t(!0);a((()=>{(async()=>{try{h(!0);const e=Ul(n);if(!e)return void h(!1);const t=us(n);if(!t||0===Object.keys(t).length)return void h(!1);const r=await Kt.get(`/api/conversations/multi/${n}/?ids=${Object.keys(t).join(",")}`,{headers:{Authorization:`Bearer ${e}`}});r.data=r.data?.map((e=>({...e,title:e.history?.find((e=>"Human"===e.sender))?.message||e.history[0]?.message,lastMessage:e.history?.[e.history?.length-1]?.message,createdAt:new Date(e.createdAt),unread:!1}))),c(r.data),h(!1)}catch(e){console.error("Error fetching conversations:",e),h(!1)}})()}),[n]);const g=s.filter((e=>e?.title?.toLowerCase().includes(m.toLowerCase())||e?.lastMessage?.toLowerCase().includes(m.toLowerCase())));a((()=>{const e=e=>{!u||e.target.closest(`.${cs.conversationHistoryPanel}`)||e.target.closest(".sidebar-button")||(d(!1),o?.())};return document.addEventListener("mousedown",e),()=>{document.removeEventListener("mousedown",e)}}),[u]);a((()=>{o&&d(!0)}),[o]);const _=`${cs.conversationHistoryContainer} ${u?cs.visible:cs.hidden} ${"dark"===l?cs.dark:""}`;return e.createElement("div",{className:_},e.createElement("div",{className:cs.conversationHistoryPanel},e.createElement("div",{className:cs.conversationHistoryHeader},e.createElement("div",{className:cs.conversationHistoryTitle},e.createElement(Bl,{size:16}),e.createElement("div",{className:cs.conversationHistoryHeadingText},"Conversations History")),e.createElement("button",{className:cs.closeButton,onClick:()=>{d(!1),o&&o()}},e.createElement(Rl,{size:16}))),e.createElement("div",{className:cs.conversationHistorySearch},e.createElement("input",{type:"text",placeholder:"Search conversations...",value:m,onChange:e=>p(e.target.value),className:((e,t)=>cs["light"===t?`${e}Light`:`${e}Dark`]||"")("conversationHistorySearch",l)})),e.createElement("div",{className:cs.conversationList},f?e.createElement("div",{style:{display:"flex",justifyContent:"center",alignItems:"center",padding:"2rem"}},e.createElement("svg",{width:"25",height:"25",viewBox:"0 0 40 40",xmlns:"http://www.w3.org/2000/svg",style:{animation:"spin 1s linear infinite"}},e.createElement("style",null,"\n @keyframes spin {\n 0% { transform: rotate(0deg); }\n 100% { transform: rotate(360deg); }\n }\n "),e.createElement("circle",{cx:"20",cy:"20",r:"16",fill:"none",stroke:"dark"===l?"#ffffff":"#000000",strokeWidth:"3",strokeDasharray:"80",strokeDashoffset:"20",strokeLinecap:"round",opacity:"0.8"}))):g?.length>0?g?.sort(((e,t)=>t.createdAt-e.createdAt))?.map((t=>e.createElement("div",{key:t._id,className:`${cs.conversationItem} ${"dark"===l?cs.dark:""}`,onClick:()=>(e=>{r?.(e),d(!1)})(t)},e.createElement("div",{className:cs.conversationItemContent},e.createElement("div",{className:cs.conversationItemHeader},e.createElement("div",{className:cs.conversationHistoryTitleText},t.title),e.createElement("span",{className:cs.conversationDate},(e=>{const t=new Date,n=Math.floor((t-e)/864e5);return 0===n?e.toLocaleTimeString([],{hour:"2-digit",minute:"2-digit"}):1===n?"Yesterday":n<7?e.toLocaleDateString([],{weekday:"short"}):e.toLocaleDateString([],{month:"short",day:"numeric"})})(t.createdAt))),e.createElement("p",{className:cs.conversationPreview},t?.lastMessage?.length>60?t.lastMessage.substring(0,60)+"...":t.lastMessage)),t.unread&&e.createElement("div",{className:cs.unreadIndicator,style:{backgroundColor:i}})))):e.createElement("div",{className:cs.noResults},m?"No conversations match your search.":"No conversations yet.")),e.createElement("div",{className:cs.conversationHistoryFooter},e.createElement("button",{className:cs.newConversationButton,style:{background:i},onClick:()=>{r?.({_id:null}),d(!1)}},"Start New Conversation"))))},hs={conversationTitleBadge:"ConversationTitleBadge-module_conversationTitleBadge_OewKu",light:"ConversationTitleBadge-module_light_YgBI3",dark:"ConversationTitleBadge-module_dark_luXJt",conversationTitle:"ConversationTitleBadge-module_conversationTitle_JtUm-"};D(".ConversationTitleBadge-module_conversationTitleBadge_OewKu{backdrop-filter:blur(8px);-webkit-backdrop-filter:blur(8px);box-shadow:0 2px 8px rgba(0,0,0,.04);left:0;padding-top:4px;position:sticky;text-align:center;top:0;transition:all .3s ease;width:100%;z-index:2}.ConversationTitleBadge-module_conversationTitleBadge_OewKu.ConversationTitleBadge-module_light_YgBI3{background-color:hsla(0,0%,100%,.85);border-bottom:1px solid var(--selected-color-light1);color:#333}.ConversationTitleBadge-module_conversationTitleBadge_OewKu.ConversationTitleBadge-module_dark_luXJt{background-color:hsla(0,0%,7%,.85);border-bottom:1px solid var(--selected-color-light1);color:#f2e7fe}.ConversationTitleBadge-module_conversationTitle_JtUm-{display:inline-block;font-size:12px;font-weight:500;line-height:1.4;mask-image:linear-gradient(90deg,#000 85%,transparent);-webkit-mask-image:linear-gradient(90deg,#000 85%,transparent);max-width:90%;overflow:hidden;padding:0 16px;position:relative;white-space:nowrap}");var gs=({title:t,selectedColor:n})=>{const{theme:r}=H(),o=`${hs.conversationTitleBadge} ${hs[r]}`;return e.createElement("div",{className:o,style:{borderTop:`1px solid ${n}20`,borderBottom:`1px solid ${n}20`,boxShadow:`0 1px 3px ${n}10`}},e.createElement("div",{className:hs.conversationTitle},t))},_s={verificationPopupOverlay:"UserVerificationPopup-module_verificationPopupOverlay_BNW8c",overlayFadeIn:"UserVerificationPopup-module_overlayFadeIn_tS2eU",dark:"UserVerificationPopup-module_dark_Bppg7",light:"UserVerificationPopup-module_light_-EdMt",verificationPopupContent:"UserVerificationPopup-module_verificationPopupContent_hXqpS",popupAppear:"UserVerificationPopup-module_popupAppear_NArSh",header:"UserVerificationPopup-module_header_ys9SH",title:"UserVerificationPopup-module_title_LQngA",closeButton:"UserVerificationPopup-module_closeButton_nE69w",form:"UserVerificationPopup-module_form_ae6Li",description:"UserVerificationPopup-module_description_OLAsn",emailStep:"UserVerificationPopup-module_emailStep_kLWpz",otpStep:"UserVerificationPopup-module_otpStep_M64-9",inputGroup:"UserVerificationPopup-module_inputGroup_c9SDt",label:"UserVerificationPopup-module_label_EGapA",input:"UserVerificationPopup-module_input_aA4ZQ",otpInput:"UserVerificationPopup-module_otpInput_oSsmI",primaryButton:"UserVerificationPopup-module_primaryButton_H9O1C",disabled:"UserVerificationPopup-module_disabled_oL1fQ",buttonPulse:"UserVerificationPopup-module_buttonPulse_jPnpz",secondaryButton:"UserVerificationPopup-module_secondaryButton_sBXdt",otpActions:"UserVerificationPopup-module_otpActions_9z-i8",attemptsWarning:"UserVerificationPopup-module_attemptsWarning_dYD5E",errorMessage:"UserVerificationPopup-module_errorMessage_v-JXL",shakeError:"UserVerificationPopup-module_shakeError_z-uN4",pulse:"UserVerificationPopup-module_pulse_Ub1XQ",slideIn:"UserVerificationPopup-module_slideIn_mLCfJ"};D(".UserVerificationPopup-module_verificationPopupOverlay_BNW8c{align-items:center;animation:UserVerificationPopup-module_overlayFadeIn_tS2eU .3s ease-out;backdrop-filter:blur(8px);bottom:0;display:flex;justify-content:center;left:0;position:absolute;right:0;top:0;z-index:1000}.UserVerificationPopup-module_verificationPopupOverlay_BNW8c.UserVerificationPopup-module_dark_Bppg7{background-color:rgba(0,0,0,.75)}.UserVerificationPopup-module_verificationPopupOverlay_BNW8c.UserVerificationPopup-module_light_-EdMt{background-color:rgba(0,0,0,.5)}@keyframes UserVerificationPopup-module_overlayFadeIn_tS2eU{0%{opacity:0}to{opacity:1}}.UserVerificationPopup-module_verificationPopupContent_hXqpS{animation:UserVerificationPopup-module_popupAppear_NArSh .4s cubic-bezier(.68,-.55,.265,1.55) forwards;border-radius:.6rem;box-shadow:0 12px 48px rgba(0,0,0,.3);font-family:Inter,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,sans-serif;letter-spacing:.01em;line-height:1.6;max-width:450px;opacity:0;padding:0;transform:scale(.9) translateY(20px);width:90%}.UserVerificationPopup-module_verificationPopupContent_hXqpS.UserVerificationPopup-module_light_-EdMt{background-color:#fff;color:#333}.UserVerificationPopup-module_verificationPopupContent_hXqpS.UserVerificationPopup-module_dark_Bppg7{background-color:#080f0fde;color:#fff}@keyframes UserVerificationPopup-module_popupAppear_NArSh{to{opacity:1;transform:scale(1) translateY(0)}}.UserVerificationPopup-module_header_ys9SH{align-items:center;display:flex;justify-content:space-between;margin-bottom:24px;padding:24px 24px 0}.UserVerificationPopup-module_header_ys9SH.UserVerificationPopup-module_light_-EdMt{border-bottom-color:#e0e0e0}.UserVerificationPopup-module_header_ys9SH.UserVerificationPopup-module_dark_Bppg7{border-bottom-color:#404040}.UserVerificationPopup-module_title_LQngA{color:inherit;font-size:1.4rem;font-weight:550;line-height:1.3;margin:0}.UserVerificationPopup-module_closeButton_nE69w{align-items:center;background:none;border:none;border-radius:50%;cursor:pointer;display:flex;font-size:28px;height:32px;justify-content:center;padding:0;transition:all .2s ease;width:32px}.UserVerificationPopup-module_closeButton_nE69w.UserVerificationPopup-module_light_-EdMt{color:#666}.UserVerificationPopup-module_closeButton_nE69w.UserVerificationPopup-module_dark_Bppg7{color:#ccc}.UserVerificationPopup-module_closeButton_nE69w:hover{background-color:hsla(0,0%,50%,.1)}.UserVerificationPopup-module_closeButton_nE69w:focus{box-shadow:0 0 0 2px hsla(208,7%,46%,.5);outline:none}.UserVerificationPopup-module_form_ae6Li{padding:0 24px 24px}.UserVerificationPopup-module_description_OLAsn{font-size:.95rem;line-height:1.625;margin:0;opacity:.85}.UserVerificationPopup-module_emailStep_kLWpz,.UserVerificationPopup-module_otpStep_M64-9{display:flex;flex-direction:column;gap:20px}.UserVerificationPopup-module_inputGroup_c9SDt{display:flex;flex-direction:column;gap:8px}.UserVerificationPopup-module_label_EGapA{color:inherit;font-size:.9rem;font-weight:600;margin-bottom:.5rem}.UserVerificationPopup-module_input_aA4ZQ{background-color:transparent;border:1px solid #ccc;border-radius:.6rem;font-family:inherit;font-size:.95rem;line-height:1.5;padding:.6rem .75rem;transition:border-color .2s ease,box-shadow .2s ease,transform .2s ease}.UserVerificationPopup-module_input_aA4ZQ.UserVerificationPopup-module_light_-EdMt{border-color:#ccc;color:#333}.UserVerificationPopup-module_input_aA4ZQ.UserVerificationPopup-module_dark_Bppg7{background-color:#000a0af7;border-color:#777;color:#fff}.UserVerificationPopup-module_input_aA4ZQ:hover{border-color:var(--selected-color,#2196f3)}.UserVerificationPopup-module_input_aA4ZQ:focus{border-color:var(--selected-color,#2196f3);box-shadow:0 0 0 3px var(--selected-color-light1,rgba(33,150,243,.3));outline:none}.UserVerificationPopup-module_input_aA4ZQ:disabled{cursor:not-allowed;opacity:.5}.UserVerificationPopup-module_input_aA4ZQ::placeholder{opacity:.5}.UserVerificationPopup-module_otpInput_oSsmI{font-family:Courier New,monospace;font-size:20px;font-weight:600;letter-spacing:4px;text-align:center}.UserVerificationPopup-module_primaryButton_H9O1C{background:var(--selected-color,#2196f3);border:none;border-radius:1.5rem;color:#fff;cursor:pointer;font-family:inherit;font-size:.95rem;font-weight:500;padding:.6rem 1.5rem;transition:all .2s ease}.UserVerificationPopup-module_primaryButton_H9O1C:hover:not(.UserVerificationPopup-module_disabled_oL1fQ){box-shadow:0 4px 12px var(--selected-color-light1,rgba(33,150,243,.3));filter:brightness(1.1);transform:scale(1.03)}.UserVerificationPopup-module_primaryButton_H9O1C:active:not(.UserVerificationPopup-module_disabled_oL1fQ){animation:UserVerificationPopup-module_buttonPulse_jPnpz .2s ease-out;transform:scale(.95)}.UserVerificationPopup-module_primaryButton_H9O1C.UserVerificationPopup-module_disabled_oL1fQ{cursor:not-allowed;opacity:.5}@keyframes UserVerificationPopup-module_buttonPulse_jPnpz{0%{transform:scale(1)}50%{transform:scale(.95)}to{transform:scale(1)}}.UserVerificationPopup-module_secondaryButton_sBXdt{background:transparent;border:1px solid;border-radius:1.5rem;cursor:pointer;font-family:inherit;font-size:.875rem;font-weight:500;padding:.5rem 1.2rem;transition:all .2s ease}.UserVerificationPopup-module_secondaryButton_sBXdt.UserVerificationPopup-module_light_-EdMt{border-color:#ccc;color:#666}.UserVerificationPopup-module_secondaryButton_sBXdt.UserVerificationPopup-module_dark_Bppg7{border-color:#777;color:#ccc}.UserVerificationPopup-module_secondaryButton_sBXdt:hover:not(.UserVerificationPopup-module_disabled_oL1fQ){filter:brightness(.95);transform:scale(1.03)}.UserVerificationPopup-module_secondaryButton_sBXdt:active:not(.UserVerificationPopup-module_disabled_oL1fQ){transform:scale(.95)}.UserVerificationPopup-module_secondaryButton_sBXdt.UserVerificationPopup-module_disabled_oL1fQ{cursor:not-allowed;opacity:.5}.UserVerificationPopup-module_otpActions_9z-i8{display:flex;flex-wrap:wrap;gap:12px;justify-content:center}.UserVerificationPopup-module_attemptsWarning_dYD5E{color:#ff6b6b;font-size:14px;font-weight:500;margin:0;text-align:center}.UserVerificationPopup-module_errorMessage_v-JXL{animation:UserVerificationPopup-module_shakeError_z-uN4 .4s ease;border:1px solid;border-radius:.6rem;font-size:.875rem;margin-top:1rem;padding:.75rem 1rem;text-align:center}.UserVerificationPopup-module_errorMessage_v-JXL.UserVerificationPopup-module_light_-EdMt{background-color:rgba(211,47,47,.05);border-color:#ffcdd2;color:#d32f2f}.UserVerificationPopup-module_errorMessage_v-JXL.UserVerificationPopup-module_dark_Bppg7{background-color:rgba(244,67,54,.1);border-color:#5f2c2c;color:#ff6b6b}@keyframes UserVerificationPopup-module_shakeError_z-uN4{0%,to{transform:translateX(0)}10%,30%,50%,70%,90%{transform:translateX(-4px)}20%,40%,60%,80%{transform:translateX(4px)}}@keyframes UserVerificationPopup-module_pulse_Ub1XQ{0%{opacity:1}50%{opacity:.5}to{opacity:1}}.UserVerificationPopup-module_primaryButton_H9O1C.UserVerificationPopup-module_disabled_oL1fQ{animation:UserVerificationPopup-module_pulse_Ub1XQ 1.5s infinite}.UserVerificationPopup-module_closeButton_nE69w:focus,.UserVerificationPopup-module_input_aA4ZQ:focus,.UserVerificationPopup-module_primaryButton_H9O1C:focus,.UserVerificationPopup-module_secondaryButton_sBXdt:focus{box-shadow:0 0 0 2px rgba(0,123,255,.3);outline:none}.UserVerificationPopup-module_emailStep_kLWpz,.UserVerificationPopup-module_otpStep_M64-9{animation:UserVerificationPopup-module_slideIn_mLCfJ .4s ease-out}@keyframes UserVerificationPopup-module_slideIn_mLCfJ{0%{opacity:0;transform:translateY(20px)}to{opacity:1;transform:translateY(0)}}@media (prefers-reduced-motion:reduce){.UserVerificationPopup-module_emailStep_kLWpz,.UserVerificationPopup-module_errorMessage_v-JXL,.UserVerificationPopup-module_input_aA4ZQ,.UserVerificationPopup-module_otpStep_M64-9,.UserVerificationPopup-module_primaryButton_H9O1C,.UserVerificationPopup-module_secondaryButton_sBXdt,.UserVerificationPopup-module_verificationPopupContent_hXqpS,.UserVerificationPopup-module_verificationPopupOverlay_BNW8c{animation-duration:.01ms!important;animation-iteration-count:1!important;transition-duration:.01ms!important}}");const ys=({onClose:n,onValidationResponse:r,userDetails:o={},urlId:i,selectedColor:l="#2196F3"})=>{const{theme:s}=H(),[c,u]=t(o.email||""),[d,m]=t(""),[p,f]=t("email"),[h,g]=t(!1),[_,y]=t(""),[b,v]=t(0),[x,k]=t(0),[w]=t(3),C=e=>/^\d{6}$/.test(e);a((()=>{let e;return b>0&&(e=setInterval((()=>{v((e=>e-1))}),1e3)),()=>clearInterval(e)}),[b]);const E=async()=>{if((e=>/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(e))(c)){g(!0);try{const e=await Kt.post(`/api/otp/generate/${i}`,{email:c.trim(),firstName:o.firstName||"",lastName:o.lastName||"",phone:o.phone||""},{headers:{"Content-Type":"application/json"}});e.data.success?(f("otp"),v(60),k(0),m(""),y("")):y(e.data.message||"Failed to send OTP")}catch(e){y(e.response.data.message||e.message||"Network error. Please try again.")}finally{g(!1)}}else y("Please enter a valid email address")};return e.createElement("div",{className:`${_s.verificationPopupOverlay} ${_s[s]}`},e.createElement("div",{className:`${_s.verificationPopupContent} ${_s[s]}`,style:(()=>{if(l.includes("gradient")){const e=vs(l,.8),t=vs(l,.3);return{"--selected-color":l,"--selected-color-light":e,"--selected-color-light1":t}}return{"--selected-color":l,"--selected-color-light":`${l}99`,"--selected-color-light1":`${l}4D`}})()},e.createElement("div",{className:_s.header},e.createElement("div",{className:_s.title},"Please verify yourself")),e.createElement("form",{onSubmit:e=>{e.preventDefault(),"email"===p?E():(async()=>{if(C(d)){g(!0),y("");try{const e=await Kt.post(`/api/otp/validate/${i}`,{email:c.trim(),otp:d.trim()},{headers:{"Content-Type":"application/json"}});e.data.success?(r(e.data),n()):(y(e.data.message||"Invalid OTP"),k((e=>e+1)),m(""),x>=w-1&&(y("Maximum attempts reached. Please request a new OTP."),f("email"),k(0)))}catch(e){y(e.response.data.message||e.message||"Network error. Please try again.")}finally{g(!1)}}else y("Please enter a valid 6-digit OTP")})()},className:_s.form},"email"===p?e.createElement("div",{className:_s.emailStep},e.createElement("p",{className:_s.description},"Enter your email address to receive a verification code"),e.createElement("div",{className:_s.inputGroup},e.createElement("label",{htmlFor:"email",className:_s.label},"Email Address"),e.createElement("input",{id:"email",type:"email",value:c,onChange:e=>{u(e.target.value),y("")},className:`${_s.input} ${_s[s]}`,placeholder:"Enter your email",required:!0,disabled:h})),e.createElement("button",{type:"submit",disabled:h||!c.trim(),className:`${_s.primaryButton} ${_s[s]} ${h||!c.trim()?_s.disabled:""}`},h?"Sending...":"Send OTP")):e.createElement("div",{className:_s.otpStep},e.createElement("p",{className:_s.description},"Enter the 6-digit code sent to ",e.createElement("strong",null,c)),e.createElement("div",{className:_s.inputGroup},e.createElement("label",{htmlFor:"otp",className:_s.label},"Verification Code"),e.createElement("input",{id:"otp",type:"text",value:d,onChange:e=>{const t=e.target.value.replace(/\D/g,"").slice(0,6);m(t),y("")},className:`${_s.input} ${_s.otpInput} ${_s[s]}`,placeholder:"000000",maxLength:"6",required:!0,disabled:h})),e.createElement("button",{type:"submit",disabled:h||!C(d),className:`${_s.primaryButton} ${_s[s]} ${h||!C(d)?_s.disabled:""}`},h?"Validating...":"Validate OTP"),e.createElement("div",{className:_s.otpActions},e.createElement("button",{type:"button",onClick:()=>{0===b&&E()},disabled:b>0,className:`${_s.secondaryButton} ${_s[s]} ${b>0?_s.disabled:""}`},b>0?`Resend in ${b}s`:"Resend OTP"),e.createElement("button",{type:"button",onClick:()=>{f("email"),m(""),y(""),k(0)},className:`${_s.secondaryButton} ${_s[s]}`},"Change Email")),x>0&&e.createElement("p",{className:_s.attemptsWarning},w-x," attempts remaining")),_&&e.createElement("div",{className:`${_s.errorMessage} ${_s[s]}`},_))))};ys.propTypes={onClose:m.exports.func.isRequired,onValidationResponse:m.exports.func.isRequired,userDetails:m.exports.shape({email:m.exports.string,firstName:m.exports.string,lastName:m.exports.string,phone:m.exports.string}),urlId:m.exports.string.isRequired,selectedColor:m.exports.string};var bs=ys;const vs=(e,t=.8)=>{const n=(e,t)=>`rgba(${parseInt(e.slice(1,3),16)}, ${parseInt(e.slice(3,5),16)}, ${parseInt(e.slice(5,7),16)}, ${t})`,r={red:"rgb(255, 0, 0)",yellow:"rgb(255, 255, 0)",blue:"rgb(0, 0, 255)",green:"rgb(0, 128, 0)",white:"rgb(255, 255, 255)",black:"rgb(0, 0, 0)",orange:"rgb(255, 165, 0)",purple:"rgb(128, 0, 128)",pink:"rgb(255, 192, 203)",gray:"rgb(128, 128, 128)",grey:"rgb(128, 128, 128)",brown:"rgb(165, 42, 42)",cyan:"rgb(0, 255, 255)",magenta:"rgb(255, 0, 255)",lime:"rgb(0, 255, 0)",navy:"rgb(0, 0, 128)",silver:"rgb(192, 192, 192)",gold:"rgb(255, 215, 0)"},o=(e,t)=>{if((e=e.trim()).startsWith("#"))return n(e,t);if(e.startsWith("rgba("))return e.replace(/rgba\(([^,]+),\s*([^,]+),\s*([^,]+),\s*[^)]+\)/,`rgba($1, $2, $3, ${t})`);if(e.startsWith("rgb("))return e.replace(/rgb\(([^)]+)\)/,`rgba($1, ${t})`);if(r[e.toLowerCase()]){return r[e.toLowerCase()].replace(/rgb\(([^)]+)\)/,`rgba($1, ${t})`)}return e};if(e.includes("gradient(")){const a=e.match(/(linear-gradient|radial-gradient|conic-gradient)\s*\(([^)]+)\)/);if(a){const e=a[1],i=a[2],l=[];let s="",c=0;for(let e=0;e<i.length;e++){const t=i[e];"("===t&&c++,")"===t&&c--,","===t&&0===c?(l.push(s.trim()),s=""):s+=t}s.trim()&&l.push(s.trim());const u=l.map((e=>{const a=(e=e.trim()).match(/^(#[a-fA-F0-9]{6}|#[a-fA-F0-9]{3}|rgba?\([^)]+\)|[a-zA-Z]+)(\s+\d+%?)?$/);if(a){const e=a[1],n=a[2]||"";return o(e,t)+n}let i=e;return i=i.replace(/#[a-fA-F0-9]{6}|#[a-fA-F0-9]{3}/g,(e=>n(e,t))),i=i.replace(/rgba\([^)]+\)/g,(e=>o(e,t))),i=i.replace(/rgb\([^)]+\)/g,(e=>o(e,t))),Object.keys(r).forEach((e=>{const n=new RegExp(`\\b${e}\\b`,"gi");i=i.replace(n,(e=>o(e,t)))})),i}));return`${e}(${u.join(", ")})`}}return o(e,t)},xs=({urlId:n,isInitConversationLoading:r,selectedColor:l,config:s,identity:c=null,onClose:u})=>{const{theme:d}=H(),[m,p]=t([]),[f,h]=t(""),g=o(null),[_,y]=t(null),[b,v]=t(!1),[x,k]=t(r),[w,C]=t(!1),[E,S]=t([]),[R,F]=t(!1),[P,T]=t(null),[B,I]=t(!1),[N,L]=t(!1),[O,A]=t(null),M=o(null),[z,D]=t(!1),[j,V]=t(null),[W,$]=t(""),[q,X]=t(!1),[Y,G]=t(null),[Z,J]=t(null),[K,Q]=t(!1),[ee,te]=t(!1),ne=o(null),re=(e,t)=>{if(!e||""===e.trim())return;V(t),$("");const n=e.split(" ");let r=0;const o=setInterval((()=>{if(r<n.length){const e=n[r];$((t=>0===r?e:t+" "+e)),r++}else clearInterval(o),V(null),$("")}),50)},oe=(e,t)=>U["light"===t?`${e}Light`:`${e}Dark`]||"",ae=(...e)=>e.filter(Boolean).join(" "),ie=()=>{g.current?.scrollIntoView({behavior:"smooth"})},le=i((()=>{const e=g.current?.parentElement;if(!e)return;const{scrollTop:t,scrollHeight:n,clientHeight:r}=e,o=n-t-r<50;Q(!o),te(!o&&n>r)}),[]),se=i((()=>{g.current?.scrollIntoView({behavior:"smooth"}),Q(!1)}),[]),ce=i((async(e,t)=>{try{await navigator.clipboard.writeText(t),J(e),setTimeout((()=>J(null)),2e3)}catch(e){console.error("Failed to copy:",e)}}),[]),ue=i((e=>{if(!e)return"";return new Date(e).toLocaleTimeString([],{hour:"2-digit",minute:"2-digit"})}),[]);a((()=>{K||ie()}),[m,K]),a((()=>{const e=setTimeout((()=>{ne.current?.focus()}),250);return()=>clearTimeout(e)}),[]);const de=async()=>{x||f.trim()&&(await ge(f),h(""),ne.current&&(ne.current.style.height="44px"))};a((()=>{r||(C(!0),fe())}),[r]);const me=async()=>{let e=!1;const t=Dl(n);try{if(!t)return await pe(),void y({message:"Your chat was expired, I have started new chat.",type:"success"});const r=await Kt.post("/api/auth/refresh-token",{refreshToken:t}),o=us(n);o[r.data?.conversationId]={idToken:r.data?.idToken,refreshToken:t},ds(n,o),ms(n,{idToken:r.data?.idToken,refreshToken:t}),await fe(),e=!0}catch(t){if(401===t?.status){if(s?.userVerificationRequired&&!c?.email)return v(!0),e=!1,(e=>{try{localStorage.removeItem(`${e}_current_conversation`)}catch(e){}})(n),(e=>{try{localStorage.removeItem(`${e}_conversations`)}catch(e){}})(n),e;await pe(),y({message:"Your chat was expired, I have started new chat.",type:"success"}),e=!0}else y({message:t?.response?.data?.message||t?.message||`Failed to reconnect: ${t.message}`,type:"error"}),e=!1}return e},pe=async(e=null)=>{try{if(!Dl(n)&&s?.userVerificationRequired&&!e&&!c?.email)return void v(!0);let t;if(p([]),S([]),k(!0),ye(),_e(),e)t=`/api/conversations/init/${n}?identity=${e}`;else if(c?.email){const e=await ps(c,n);t=e?._id?`/api/conversations/init/${n}?identity=${e?._id}`:`/api/conversations/init/${n}`}else t=`/api/conversations/init/${n}`;const r=await Kt.get(t);let o=us(n);o[r.data?.conversationId]={idToken:r.data?.idToken,refreshToken:r.data?.refreshToken},ds(n,o),ms(n,{idToken:r.data?.idToken,refreshToken:r.data?.refreshToken}),p(r.data?.history);const a=r.data?.history?.filter((e=>"Bot"===e.sender));if(a&&a.length>0){const e=a[a.length-1];re(e.message,e._id)}k(!1),S(r.data?.suggestions),ye()}catch(e){if(k(!1),ye(),[402,429].includes(e?.status))return void y({message:e?.response?.data?.message||e?.message||"Failed to send message!",type:"error"});throw y({message:e?.response?.data?.message||e?.message||"Failed to start conversation!",type:"error"}),e}},fe=async(e=`/api/conversations/${n}`)=>{try{if(!Dl(n))return void C(!1);const t=Ul(n);if(!t)return await me(),void C(!1);const r=await Kt.get(e,{headers:{Authorization:`Bearer ${t}`}});p(r.data?.history),S(r.data?.suggestions),T(r.data?.form),setTimeout((()=>{F(r.data?.showForm)}),4e3),k(!1),C(!1)}catch(e){if(k(!1),C(!1),401===e?.status)await me();else{if([402,429].includes(e?.status))return void y({message:e?.response?.data?.message||e?.message||"Failed to send message!",type:"error"});y({message:`Error loading conversations: ${e.message}`,type:"error"})}}},he=async e=>{if(!Dl(n)&&s?.userVerificationRequired&&!c?.email)return void v(!0);const t={_id:(Date.now()+1).toString(),message:e,sender:"Human"};p((e=>[...e,t])),S([]),k(!0),h(""),_e();const r=Ul(n),o=await Kt.post(`/api/conversations/${n}`,{message:e,sender:"Human"},{headers:{Authorization:`Bearer ${r}`}});p(o.data?.history);const a=o.data?.history?.filter((e=>"Bot"===e.sender));if(a&&a.length>0){const e=a[a.length-1];re(e.message,e._id)}S(o.data?.suggestions),T(o.data?.form),setTimeout((()=>{F(o.data?.showForm)}),4e3),k(!1),ye()},ge=async e=>{try{se(),ye(),await he(e)}catch(t){if(k(!1),ye(),"CONTENT_FILTERED"===t?.response?.data?.code)return void y({message:t?.response?.data?.message||t?.message||"Failed to send message!",type:"error"});if([402,429].includes(t?.status))return void y({message:t?.response?.data?.message||t?.message||"Failed to send message!",type:"error"});const n=await me();s?.userVerificationRequired&&!n||await he(e)}},_e=()=>{const e=setTimeout((()=>{X(!0),ie()}),15e3);G(e)},ye=()=>{Y&&(clearTimeout(Y),G(null)),X(!1)};a((()=>{""===f&&ne.current&&(ne.current.style.height="44px")}),[f]);const be=async(e,t)=>{try{const r=Ul(n);if(!r)return void await me();await Kt.post(`/api/form-data/${n}`,{formData:e,form:P._id,action:t},{headers:{Authorization:`Bearer ${r}`}}),I(!1),L(!1),F(!1),await fe()}catch(e){I(!1),L(!1),y({message:e.message||"Failed to submit the form!",type:"error"})}};a((()=>{const e=new ResizeObserver((()=>{ie()}));return M.current&&e.observe(M.current),()=>{M.current&&e.unobserve(M.current)}}),[]);const ve=c?.firstName?(e=>`The stage is yours, ${e}!`)(c?.firstName):"New Conversation";a((()=>{j&&ie()}),[W,j]);return a((()=>(Dl(n)||!s?.userVerificationRequired||c?.email||v(!0),()=>{ye()})),[]),a((()=>{const e=e=>{if("Escape"!==e.key)return(e.metaKey||e.ctrlKey)&&"h"===e.key?(e.preventDefault(),void D(!0)):(e.metaKey||e.ctrlKey)&&"i"===e.key?(e.preventDefault(),D(!1),void pe()):void 0;u?.()};return window.addEventListener("keydown",e),()=>{window.removeEventListener("keydown",e)}}),[]),e.createElement("div",{className:U.chat,ref:M,style:(()=>{if(l.includes("gradient")){const e=vs(l,.8),t=vs(l,.2);return{"--selected-color":l,"--selected-color-light":e,"--selected-color-light1":t,background:s?.chat[d]?.bodyBackgroundColor,color:s?.chat[d]?.bodyTextColor}}return{"--selected-color":l,"--selected-color-light":`${l}99`,"--selected-color-light1":`${l}30`,background:s?.chat[d]?.bodyBackgroundColor,color:s?.chat[d]?.bodyTextColor}})()},R&&P?._id?e.createElement("div",{className:U.formContainer},e.createElement(is,{form:P,theme:d,onSubmit:async e=>{I(!0);const t=P.fields.filter((e=>"file"===e.type)).reduce(((t,n)=>(t[n.name]=e[n.name],t)),{});Object.values(t).length>0&&await Kt.post("/api/files/mark-as-permanent",{fileIds:Object.values(t).flat().map((e=>e._id))},{headers:{Authorization:`Bearer ${Ul(n)}`}}),await be(e,"submitted")},onCancel:async()=>{L(!0),await be({formData:null},"cancelled")},isSubmitting:B,isCancelling:N,selectedColor:l,urlId:n})):e.createElement(e.Fragment,null,e.createElement(ss,{onButtonClick:async e=>{"start-new-conversation"===e?(D(!1),await pe()):"view-conversations"===e&&D(!0)},selectedColor:l}),z?e.createElement(fs,{urlId:n,onSelectConversation:async e=>{p([]),D(!1);const t=us(n);ye(),t&&0!==Object.keys(t).length?e?._id?(C(!0),ms(n,{idToken:t[e?._id]?.idToken,refreshToken:t[e?._id]?.refreshToken}),await fe(),C(!1)):await pe():await me()},onClose:()=>D(!1),selectedColor:l}):e.createElement(e.Fragment,null,e.createElement(gs,{title:m?.slice(-2)?.find((e=>["Human","Form"].includes(e.sender)))?.message||ve,selectedColor:l}),e.createElement("div",{className:U.chatArea},e.createElement("div",{className:ae(U.centeredContainer,U.messages,oe("messages",d)),onScroll:le},w?e.createElement("div",{style:{display:"flex",justifyContent:"center",alignItems:"center",padding:"4rem 2rem"}},e.createElement("svg",{width:"25",height:"25",viewBox:"0 0 50 50",xmlns:"http://www.w3.org/2000/svg",style:{animation:"spin 1s linear infinite"}},e.createElement("style",null,"\n @keyframes spin {\n 0% { transform: rotate(0deg); }\n 100% { transform: rotate(360deg); }\n }\n "),e.createElement("circle",{cx:"25",cy:"25",r:"20",fill:"none",stroke:"dark"===d?"#ffffff":"#000000",strokeWidth:"4",strokeDasharray:"100",strokeDashoffset:"25",strokeLinecap:"round",opacity:"0.8"}))):null,m.map((t=>{const n=j===t._id?W:t.message,r="Human"===t.sender||"Form"===t.sender;return e.createElement("div",{key:t._id,className:ae(U.messageWrapper,r?U.messageWrapperUser:U.messageWrapperBot)},"Bot"===t.sender?e.createElement(e.Fragment,null,e.createElement("div",{className:U.botMessageContent},e.createElement(ml,null,n)),j!==t._id&&e.createElement("div",{className:U.botMessageActions},e.createElement("button",{className:U.copyButton,onClick:()=>ce(t._id,t.message)},Z===t._id?e.createElement(e.Fragment,null,e.createElement(Al,{size:14}),e.createElement("span",null,"Copied")):e.createElement(e.Fragment,null,e.createElement(Ol,{size:14}),e.createElement("span",null,"Copy"))),e.createElement("span",{className:U.messageTimestamp},ue(t.createdAt||t.timestamp))),t.sources?.length?e.createElement("div",{className:U.infoButtonContainer},e.createElement("button",{className:ae(U.infoButton,oe("infoButton",d)),onClick:()=>{return e=t._id,void A(O===e?null:e);var e}},e.createElement("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.createElement("circle",{cx:"8",cy:"8",r:"7",stroke:"currentColor",strokeWidth:"2"}),e.createElement("path",{d:"M8 12V7M8 5V4",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round"}))),O===t._id&&e.createElement("div",{className:ae(U.tooltip,oe("tooltip",d))},e.createElement("div",{className:U.chatSourceTitle},"Sources:"),e.createElement("ul",null,t.sources.map(((t,n)=>e.createElement("li",{key:n},e.createElement("a",{href:t,target:"_blank",rel:"noopener noreferrer"},t))))))):null):e.createElement(e.Fragment,null,e.createElement("div",{className:ae(U.message,U.messageHuman,oe("messageHuman",d))},n),e.createElement("span",{className:U.messageTimestamp},ue(t.createdAt||t.timestamp))))})),x&&e.createElement(e.Fragment,null,e.createElement("div",{style:{marginBottom:"1.8rem"}},e.createElement(bl,null)),q&&e.createElement("div",{className:U.message,style:{alignItems:"left",marginBottom:"1.8rem",opacity:0,fontSize:"12px",paddingLeft:"1.6rem",marginTop:"-2rem"}},"I'm working on your request. Please bear with me...")),e.createElement("div",{ref:g})),ee&&e.createElement("button",{className:ae(U.scrollToBottomButton,oe("scrollToBottomButton",d)),onClick:se,"aria-label":"Scroll to bottom"},e.createElement(Sl,{size:18}))),e.createElement("div",{className:U.centeredContainer},E?.length?e.createElement(kl,{suggestions:E,onSuggestionClick:async e=>{S([]),await ge(e)},theme:d}):null,e.createElement("div",{className:U.inputArea},e.createElement("textarea",{ref:ne,value:f,onChange:e=>{const t=e.target.value;h(t);const n=e.target;n.style.height="auto";const r=n.scrollHeight,o=Math.max(44,Math.min(r,150));n.style.height=o+"px"},onKeyDown:e=>{"Enter"!==e.key||e.shiftKey||(e.preventDefault(),de())},placeholder:"Type a message...",className:ae(U.input,oe("input",d)),rows:1}),e.createElement("button",{onClick:de,className:ae(U.sendButton,oe("sendButton",d),x?U.sendButtonSending:""),"aria-label":"Send message",disabled:x||!f.trim(),title:"Send message"},x?e.createElement(Ml,{className:"icon",size:20}):e.createElement(wl,{className:"icon",size:20}))),!s?.hideMonologyWatermark&&e.createElement("div",{className:oe("watermark",d)},"Powered by ",e.createElement("a",{href:"https://monology.io",target:"_blank",rel:"noopener noreferrer"},"Monology")))),_&&e.createElement(hl,{message:_.message,type:_.type,onClose:()=>{y(null)}}),b&&e.createElement(bs,{onClose:()=>v(!1),onValidationResponse:async e=>{v(!1),await pe(e?._id)},urlId:n,selectedColor:l})))};xs.propTypes={theme:m.exports.oneOf(["light","dark"]),selectedColor:m.exports.string.isRequired};var ks=xs,ws={colorSelector:"ColorSelector-module_colorSelector_LyJrE",selectedColor:"ColorSelector-module_selectedColor_4-IiO",dropdownIcon:"ColorSelector-module_dropdownIcon_v5YWy",colorDropdown:"ColorSelector-module_colorDropdown_UsSZM",dark:"ColorSelector-module_dark_bmUgX",light:"ColorSelector-module_light_oKveZ",colorOption:"ColorSelector-module_colorOption_igbTo"};D(".ColorSelector-module_colorSelector_LyJrE{display:inline-block;position:relative}.ColorSelector-module_selectedColor_4-IiO{align-items:center;border-radius:50%;cursor:pointer;display:flex;justify-content:center}.ColorSelector-module_selectedColor_4-IiO:hover{scale:1.1}.ColorSelector-module_dropdownIcon_v5YWy{transition:transform .3s ease}.ColorSelector-module_colorSelector_LyJrE:hover .ColorSelector-module_dropdownIcon_v5YWy{transform:rotate(180deg)}.ColorSelector-module_colorDropdown_UsSZM{border-radius:4px;box-shadow:0 2px 10px rgba(0,0,0,.1);left:-10px;margin-top:5px;position:absolute;top:100%;z-index:1000}.ColorSelector-module_colorDropdown_UsSZM.ColorSelector-module_dark_bmUgX{background-color:#444}.ColorSelector-module_colorDropdown_UsSZM.ColorSelector-module_light_oKveZ{background-color:#fff}.ColorSelector-module_colorOption_igbTo{align-items:center;border-radius:50%;cursor:pointer;display:flex;height:30px;justify-content:center;margin:5px;width:30px}.ColorSelector-module_colorOption_igbTo:hover{transform:scale(1.1)}");var Cs=({colors:n,selectedColor:r,onColorChange:i,currentTheme:l})=>{const[s,c]=t(!1),u=o(null);return a((()=>{const e=e=>{u.current&&!u.current.contains(e.target)&&c(!1)};return document.addEventListener("mousedown",e),()=>{document.removeEventListener("mousedown",e)}}),[]),e.createElement("div",{className:ws.colorSelector,ref:u,title:"Change color"},e.createElement("div",{className:ws.selectedColor,onClick:()=>c(!s),style:{color:r}},e.createElement(Sl,{className:ws.dropdownIcon,size:22})),s&&e.createElement("div",{className:`${ws.colorDropdown} ${ws[l]}`},n.map((t=>e.createElement("div",{key:t,className:ws.colorOption,style:{background:t},onClick:()=>(e=>{i(e),c(!1)})(t)},e.createElement(Fl,{size:16}))))))},Es={themeToggle:"ThemeToggle-module_themeToggle_jwBZM",dark:"ThemeToggle-module_dark_gWkju",light:"ThemeToggle-module_light_ewTyK"};D(".ThemeToggle-module_themeToggle_jwBZM{align-items:center;background:none;border:none;border-radius:50%;color:inherit;cursor:pointer;display:flex;justify-content:center;padding:5px}.ThemeToggle-module_themeToggle_jwBZM.ThemeToggle-module_dark_gWkju{color:#fff}.ThemeToggle-module_themeToggle_jwBZM.ThemeToggle-module_light_ewTyK{color:#333}.ThemeToggle-module_themeToggle_jwBZM.ThemeToggle-module_dark_gWkju:hover,.ThemeToggle-module_themeToggle_jwBZM.ThemeToggle-module_light_ewTyK:hover{scale:1.1}");var Ss=({isDarkMode:t,onToggle:n})=>{const{theme:r}=H();return e.createElement("button",{className:`${Es.themeToggle} ${Es[r]}`,onClick:n,title:t?"Switch to light mode":"Switch to dark mode"},t?e.createElement(Cl,{size:18}):e.createElement(El,{size:17}))},Rs={header:"Header-module_header_wbp8n",light:"Header-module_light_jJhwg",dark:"Header-module_dark_guNSC",title:"Header-module_title_jWTM-",themeSelect:"Header-module_themeSelect_x-zOl",closeButton:"Header-module_closeButton_lFPJa",headerControls:"Header-module_headerControls_MfyOq",statusIndicator:"Header-module_statusIndicator_2s39c",statusDot:"Header-module_statusDot_memSJ",statusDotOnline:"Header-module_statusDotOnline_HXEyP",statusDotTyping:"Header-module_statusDotTyping_fS4nh",statusDotOffline:"Header-module_statusDotOffline_BW6cA",statusDotError:"Header-module_statusDotError_tj4re",statusPulse:"Header-module_statusPulse_4Xzz7",statusLabel:"Header-module_statusLabel_F0Cp-"};D('.Header-module_header_wbp8n{align-items:center;box-shadow:0 1px 3px rgba(0,0,0,.05);display:flex;justify-content:space-between;padding:.5rem 1rem;position:relative}.Header-module_header_wbp8n.Header-module_light_jJhwg{box-shadow:0 1px 4px rgba(0,0,0,.06)}.Header-module_header_wbp8n.Header-module_dark_guNSC{box-shadow:0 1px 4px rgba(0,0,0,.2)}.Header-module_title_jWTM-{font-size:1.1rem;font-weight:550;margin:0;max-width:70%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;z-index:2}.Header-module_themeSelect_x-zOl{border:1px solid #ccc;border-radius:.25rem;margin-left:-2.7rem;padding:.25rem;z-index:2}.Header-module_closeButton_lFPJa{align-items:center;background:transparent;border:none;border-radius:50%;color:inherit;cursor:pointer;display:flex;justify-content:center;padding:6px;text-decoration:none;transition:transform .2s ease,box-shadow .2s ease,background-color .2s ease;z-index:2}.Header-module_header_wbp8n.Header-module_light_jJhwg .Header-module_closeButton_lFPJa{color:#333}.Header-module_header_wbp8n.Header-module_light_jJhwg .Header-module_closeButton_lFPJa:hover{background-color:var(--selected-color-light1);box-shadow:0 0 10px var(--selected-color-light1);transform:scale(1.1)}.Header-module_header_wbp8n.Header-module_dark_guNSC .Header-module_themeSelect_x-zOl{background-color:#444;border-color:#666;color:#fff}.Header-module_header_wbp8n.Header-module_dark_guNSC .Header-module_closeButton_lFPJa{color:#fff}.Header-module_header_wbp8n.Header-module_dark_guNSC .Header-module_closeButton_lFPJa:hover{background-color:var(--selected-color-light1);box-shadow:0 0 10px var(--selected-color-light1);transform:scale(1.1)}.Header-module_headerControls_MfyOq{align-items:center;display:flex;gap:10px;z-index:3}.Header-module_statusIndicator_2s39c{align-items:center;display:flex;gap:6px}.Header-module_statusDot_memSJ{border-radius:50%;height:8px;position:relative;width:8px}.Header-module_statusDotOnline_HXEyP,.Header-module_statusDotTyping_fS4nh{background:#22c55e}.Header-module_statusDotOffline_BW6cA{background:#9ca3af}.Header-module_statusDotError_tj4re{background:#ef4444}.Header-module_statusDotTyping_fS4nh:before{animation:Header-module_statusPulse_4Xzz7 1.5s ease-in-out infinite;background:#22c55e;border-radius:50%;content:"";inset:0;position:absolute}@keyframes Header-module_statusPulse_4Xzz7{0%,to{opacity:1;transform:scale(1)}50%{opacity:0;transform:scale(2)}}.Header-module_statusLabel_F0Cp-{color:#9ca3af;font-size:11px}@media (prefers-reduced-motion:reduce){.Header-module_statusDotTyping_fS4nh:before{animation:none}}');var Fs=({text:t,initialTheme:n,onClose:r,colors:o,selectedColor:i,onColorChange:l,config:s,onToggleFullscreen:c,isFullscreen:u,isSmallScreen:d})=>{const{theme:m,setTheme:p}=H();return a((()=>{p(n)}),[]),e.createElement(e.Fragment,null,e.createElement("div",{className:`${Rs.header} ${Rs[m]}`,style:{background:s?.chat[m]?.headerBackgroundColor,color:s?.chat[m]?.headerTextColor}},e.createElement("div",{className:Rs.title,style:{alignItems:"center"}},t||"ChatBot"),e.createElement("div",{className:Rs.headerControls},e.createElement(Cs,{colors:o[m||O],selectedColor:i,onColorChange:l,currentTheme:m}),!d&&e.createElement(e.Fragment,null,u?e.createElement("a",{href:"#!",onClick:e=>{e.preventDefault(),c()},className:Rs.closeButton,title:"Exit full screen"},e.createElement(Nl,{size:16})):e.createElement("a",{href:"#!",onClick:e=>{e.preventDefault(),c()},className:Rs.closeButton,title:"Full screen"},e.createElement(Il,{size:16}))),e.createElement(Ss,{isDarkMode:m===A,onToggle:()=>{p(m===A?O:A)}}),e.createElement("a",{href:"#!",onClick:e=>{e.preventDefault(),r()},className:Rs.closeButton,title:"Close chat (ESC)"},e.createElement(Rl,{size:20})))))},Ps={pulseAnimation:"Widget-module_pulseAnimation_6rJWt",pulse:"Widget-module_pulse_X1p64",bounceAnimation:"Widget-module_bounceAnimation_dB-yR",bounce:"Widget-module_bounce_8VvBb",shakeAnimation:"Widget-module_shakeAnimation_U7rV6",shake:"Widget-module_shake_IEJuF",tadaAnimation:"Widget-module_tadaAnimation_BlYCk",tada:"Widget-module_tada_t9-r7",jelloAnimation:"Widget-module_jelloAnimation_RqKAD",jello:"Widget-module_jello_2wqtq",flashAnimation:"Widget-module_flashAnimation_ZccOp",flash:"Widget-module_flash_VkDG-",spinAnimation:"Widget-module_spinAnimation_XqUSA",spin:"Widget-module_spin_w3kxk",scaleHover:"Widget-module_scaleHover_ey9Fe",glowHover:"Widget-module_glowHover_VinTY",colorShiftHover:"Widget-module_colorShiftHover_UlojN",shakeHover:"Widget-module_shakeHover_iIhdv",rotateHover:"Widget-module_rotateHover_j2gw4",noHover:"Widget-module_noHover_rgns6",mcw:"Widget-module_mcw_szZTA",widgetContainer:"Widget-module_widgetContainer_rlVfL",widgetSlideIn:"Widget-module_widgetSlideIn_q3zaf",widgetContainerClosing:"Widget-module_widgetContainerClosing_pGnua",widgetSlideOut:"Widget-module_widgetSlideOut_0ZaMp",launcherButton:"Widget-module_launcherButton_rYpAu",launcherButtonNotification:"Widget-module_launcherButtonNotification_-uUZh",notificationPulse:"Widget-module_notificationPulse_7Qdyu",chatContainer:"Widget-module_chatContainer_BtqAD",showButton:"Widget-module_showButton_xwHDs",buttonText:"Widget-module_buttonText_v0TeO",hovered:"Widget-module_hovered_LD4zB",resizeHandle:"Widget-module_resizeHandle_vP4NZ",light:"Widget-module_light_TCUap",dark:"Widget-module_dark_3LLxU",dragHandle:"Widget-module_dragHandle_wyOcT",slideIn:"Widget-module_slideIn_f-1jI",slideInBot:"Widget-module_slideInBot_-Uf3o"};D(".Widget-module_pulseAnimation_6rJWt{animation:Widget-module_pulse_X1p64 2s infinite}.Widget-module_bounceAnimation_dB-yR{animation:Widget-module_bounce_8VvBb 2s infinite}.Widget-module_shakeAnimation_U7rV6{animation:Widget-module_shake_IEJuF 2s infinite}.Widget-module_tadaAnimation_BlYCk{animation:Widget-module_tada_t9-r7 2s infinite}.Widget-module_jelloAnimation_RqKAD{animation:Widget-module_jello_2wqtq 2s infinite}.Widget-module_flashAnimation_ZccOp{animation:Widget-module_flash_VkDG- 2s infinite}.Widget-module_spinAnimation_XqUSA{animation:Widget-module_spin_w3kxk 2s infinite}.Widget-module_scaleHover_ey9Fe:hover{box-shadow:0 8px 24px rgba(0,0,0,.15)!important;transform:scale(1.08)!important}.Widget-module_glowHover_VinTY:hover{box-shadow:0 0 20px rgba(59,130,246,.8),0 0 40px rgba(59,130,246,.5),0 0 60px rgba(59,130,246,.3)!important;transform:none!important}.Widget-module_colorShiftHover_UlojN:hover{filter:brightness(1.2);transform:none!important}.Widget-module_shakeHover_iIhdv:hover{animation:Widget-module_shakeHover_iIhdv .6s}.Widget-module_rotateHover_j2gw4:hover{transform:rotate(5deg)!important}.Widget-module_noHover_rgns6:hover{box-shadow:inherit!important;transform:none!important}.Widget-module_mcw_szZTA{-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;font-family:Inter,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,sans-serif;text-rendering:optimizeLegibility;z-index:9999}.Widget-module_widgetContainer_rlVfL{animation:Widget-module_widgetSlideIn_q3zaf .2s cubic-bezier(.16,1,.3,1) forwards;background:transparent;margin:0;padding:0;position:fixed;z-index:300000}.Widget-module_widgetContainerClosing_pGnua{animation:Widget-module_widgetSlideOut_0ZaMp .15s ease-in forwards}@keyframes Widget-module_widgetSlideIn_q3zaf{0%{opacity:0;transform:scale(.95) translateY(10px)}to{opacity:1;transform:scale(1) translateY(0)}}@keyframes Widget-module_widgetSlideOut_0ZaMp{0%{opacity:1;transform:scale(1) translateY(0)}to{opacity:0;transform:scale(.95) translateY(10px)}}.Widget-module_launcherButton_rYpAu{transition:all .2s ease}.Widget-module_launcherButton_rYpAu:active{transform:scale(.95)}@keyframes Widget-module_notificationPulse_7Qdyu{0%,to{box-shadow:0 0 0 0 rgba(239,68,68,.7)}50%{box-shadow:0 0 0 12px rgba(239,68,68,0)}}.Widget-module_launcherButtonNotification_-uUZh{animation:Widget-module_notificationPulse_7Qdyu 2s ease-in-out infinite}@media (prefers-reduced-motion:reduce){.Widget-module_launcherButtonNotification_-uUZh,.Widget-module_launcherButton_rYpAu,.Widget-module_widgetContainerClosing_pGnua,.Widget-module_widgetContainer_rlVfL{animation-duration:.01ms!important;animation-iteration-count:1!important;transition-duration:.01ms!important}}.Widget-module_chatContainer_BtqAD{display:flex;flex-direction:column;height:100%;margin:0;overflow:hidden;position:relative;width:100%}.Widget-module_showButton_xwHDs{background-color:#4caf50;border:none;border-radius:.25rem;bottom:1rem;color:#fff;cursor:pointer;height:35px;overflow:hidden;padding:.5rem 1rem;position:absolute;right:1rem;transition:all .5s ease;white-space:nowrap;width:70px}.Widget-module_buttonText_v0TeO{bottom:8px;display:inline-block;font-size:medium;left:1rem;position:absolute;right:1rem;transition:opacity .5s ease,transform .5s ease}.Widget-module_showButton_xwHDs.Widget-module_hovered_LD4zB .Widget-module_buttonText_v0TeO,.Widget-module_showButton_xwHDs:not(.Widget-module_hovered_LD4zB) .Widget-module_buttonText_v0TeO{transform:translateX(0)}.Widget-module_resizeHandle_vP4NZ{border-radius:1px;cursor:nwse-resize;height:14px;left:0;position:absolute;top:0;width:14px;z-index:5}.Widget-module_resizeHandle_vP4NZ.Widget-module_light_TCUap{background-color:#e0e0e0}.Widget-module_resizeHandle_vP4NZ.Widget-module_dark_3LLxU{background-color:#444}.Widget-module_dark_3LLxU .Widget-module_resizeHandle_vP4NZ:hover{background-color:#666}.Widget-module_light_TCUap .Widget-module_resizeHandle_vP4NZ:hover{background-color:#d0d0d0}.Widget-module_dragHandle_wyOcT{border-radius:.5rem .5rem 0 0;cursor:move;height:48px;left:0;position:absolute;right:0;top:0;z-index:1}@keyframes Widget-module_pulse_X1p64{0%{box-shadow:0 0 0 0 rgba(0,123,255,.4);transform:scale(1)}70%{box-shadow:0 0 0 10px rgba(0,123,255,0);transform:scale(1.05)}to{box-shadow:0 0 0 0 rgba(0,123,255,0);transform:scale(1)}}@keyframes Widget-module_bounce_8VvBb{0%,to{transform:translateY(0)}50%{transform:translateY(-10px)}}@keyframes Widget-module_shake_IEJuF{0%,to{transform:translateX(0)}10%,30%,50%,70%,90%{transform:translateX(-5px)}20%,40%,60%,80%{transform:translateX(5px)}}@keyframes Widget-module_shakeHover_iIhdv{0%,to{transform:translateX(0)}10%,30%,50%,70%,90%{transform:translateX(-8px)}20%,40%,60%,80%{transform:translateX(8px)}}@keyframes Widget-module_tada_t9-r7{0%{transform:scale(1)}10%,20%{transform:scale(.9) rotate(-3deg)}30%,50%,70%,90%{transform:scale(1.1) rotate(3deg)}40%,60%,80%{transform:scale(1.1) rotate(-3deg)}to{transform:scale(1) rotate(0)}}@keyframes Widget-module_jello_2wqtq{0%,to{transform:skewX(0deg)}25%{transform:skewX(5deg)}50%{transform:skewX(0deg)}75%{transform:skewX(-5deg)}}@keyframes Widget-module_flash_VkDG-{0%,50%,to{opacity:1}25%,75%{opacity:.5}}@keyframes Widget-module_spin_w3kxk{0%{transform:rotate(0deg)}to{transform:rotate(1turn)}}@keyframes Widget-module_slideIn_f-1jI{0%{opacity:0;transform:translateY(100px)}to{opacity:1;transform:translateY(0)}}@keyframes Widget-module_slideInBot_-Uf3o{0%{opacity:0;transform:translateX(-20px)}to{opacity:1;transform:translateX(0)}}");var Ts=({config:t,className:n,children:r})=>{const{theme:o}=H();return e.createElement("div",{className:n,style:{borderRadius:t?.chat?.[o]?.widgetBorderRadius,background:t?.chat?.[o]?.widgetBackgroundColor,boxShadow:t?.chat?.[o]?.widgetBoxShadow,border:o===A?"none":t?.chat?.[o]?.widgetBorder}},r)};const Bs=({resizeRef:t})=>{const{theme:n}=H();return e.createElement("div",{className:`${Ps.resizeHandle} ${Ps[n]}`,ref:t})},Is=e=>{if("none"===e||!e)return Ps.noHover;return{scale:Ps.scaleHover,glow:Ps.glowHover,colorShift:Ps.colorShiftHover,shake:Ps.shakeHover,rotate:Ps.rotateHover}[e]||e},Ns={Bottom_Right:{bottom:"8%",right:"5%"},Bottom_Left:{bottom:"5%",left:"5%"},Top_Right:{top:"5%",right:"5%"},Top_Left:{top:"5%",left:"5%"}},Ls=({config:n,urlId:r,hideLauncherButton:i,onClose:l,identity:s})=>{const[c,u]=t(i),[d,m]=t(!1),[p,f]=t(!1),[h,g]=t(!1),[_,y]=t(Ns[n?.chat?.position]||{bottom:"20px",right:"20px"}),[b,v]=t(n?.chat[n?.chat?.defaultThemeMode]?.themeColors?.[0]);a((()=>{v(b||n?.chat[n?.chat?.defaultThemeMode]?.themeColors?.[0])}),[n]),a((()=>{const e=()=>{const e=window.innerWidth<=768;g(e)};return e(),window.addEventListener("resize",e),()=>window.removeEventListener("resize",e)}),[]);const[x,k]=t(!1),[w,C]=t({width:n?.chat?.defaultWidth||300,height:n?.chat?.defaultHeight||400}),[E,S]=t(!1),[R,F]=t(!1),[P,T]=t(null),B=o(null),I=o(null),N=o(null),L=()=>{u(!c),c||M()},A=()=>{m(!0),setTimeout((()=>{u(!1),m(!1),l?.()}),150)},M=async()=>{const e=(e=>{try{return JSON.parse(localStorage.getItem(`${e}_current_conversation`))}catch(t){return localStorage.removeItem(`${e}_current_conversation`),null}})(r);if(e?.idToken)return;if(Dl(r)||!n?.userVerificationRequired||s?.email)try{k(!0);const e=s?.email?await ps(s,r):null,t=e?._id?`/api/conversations/init/${r}?identity=${e?._id}`:`/api/conversations/init/${r}`,n=await Kt.get(t);let o=us(r);o||(o={}),o[n.data?.conversationId]={idToken:n.data?.idToken,refreshToken:n.data?.refreshToken},ds(r,o),ms(r,{idToken:n.data?.idToken,refreshToken:n.data?.refreshToken}),k(!1)}catch(e){k(!1)}},H=h?{position:"fixed",top:"0px",left:"0px",width:window.innerWidth,height:window.innerHeight,zIndex:9999}:{position:"fixed",..._,width:w.width,height:w.height,zIndex:R?999999:3e5};return a((()=>{if(!n?.chat?.isResizable||R||h)return;const e=B.current,t=I.current;let r,o,a,i,l,s,c=!1;const u=e=>e.touches&&e.touches[0]?{clientX:e.touches[0].clientX,clientY:e.touches[0].clientY}:{clientX:e.clientX,clientY:e.clientY},d=t=>{t.preventDefault(),c=!0;const n=u(t);if(r=n.clientX,o=n.clientY,a=parseInt(document.defaultView.getComputedStyle(e).width,10),i=parseInt(document.defaultView.getComputedStyle(e).height,10),E){const t=e.style;l=parseInt(t.left||"0"),s=parseInt(t.top||"0")}document.addEventListener("mousemove",m),document.addEventListener("mouseup",p),document.addEventListener("touchmove",m,{passive:!1}),document.addEventListener("touchend",p)},m=e=>{if(!c)return;e.preventDefault();const t=u(e);let d=a-(t.clientX-r),m=i-(t.clientY-o);const p=n?.chat?.defaultWidth||300,f=n?.chat?.defaultHeight||400;if(d=Math.max(d,p),m=Math.max(m,f),C({width:d,height:m}),E){y({left:l-(d-a)+"px",top:s-(m-i)+"px"})}},p=()=>{c=!1,document.removeEventListener("mousemove",m),document.removeEventListener("mouseup",p),document.removeEventListener("touchmove",m),document.removeEventListener("touchend",p)};return t&&(t.addEventListener("mousedown",d),t.addEventListener("touchstart",d,{passive:!1})),()=>{t&&(t.removeEventListener("mousedown",d),t.removeEventListener("touchstart",d)),document.removeEventListener("mousemove",m),document.removeEventListener("mouseup",p),document.removeEventListener("touchmove",m),document.removeEventListener("touchend",p)}}),[n?.chat?.isResizable,n?.chat?.defaultWidth,n?.chat?.defaultHeight,E,c,R,h]),a((()=>{const e=e=>{(navigator.platform.toUpperCase().includes("MAC")?e.metaKey:e.ctrlKey)&&"k"===e.key.toLowerCase()&&(e.preventDefault(),c?A():L()),"Escape"===e.key&&c&&A()};return document.addEventListener("keydown",e),()=>document.removeEventListener("keydown",e)}),[c]),a((()=>{if(!n?.chat?.isDraggable||!c||R||h)return;const e=B.current,t=N.current;let r,o,a=!1;const i=e=>e.touches&&e.touches[0]?{clientX:e.touches[0].clientX,clientY:e.touches[0].clientY}:{clientX:e.clientX,clientY:e.clientY},l=t=>{t.preventDefault(),a=!0,S(!0);const n=i(t);r=n.clientX-e.offsetLeft,o=n.clientY-e.offsetTop,document.addEventListener("mousemove",s),document.addEventListener("mouseup",u),document.addEventListener("touchmove",s,{passive:!1}),document.addEventListener("touchend",u)},s=e=>{if(!a)return;e.preventDefault();const t=i(e),l=t.clientX-r,s=t.clientY-o,c=parseInt(w.width)||n?.chat?.defaultWidth||300,u=parseInt(w.height)||n?.chat?.defaultHeight||400,d=window.innerWidth-c,m=window.innerHeight-u,p=Math.max(0,Math.min(l,d)),f=Math.max(0,Math.min(s,m));y({left:`${p}px`,top:`${f}px`})},u=()=>{a=!1,document.removeEventListener("mousemove",s),document.removeEventListener("mouseup",u),document.removeEventListener("touchmove",s),document.removeEventListener("touchend",u)};return t&&(t.addEventListener("mousedown",l),t.addEventListener("touchstart",l,{passive:!1})),()=>{t&&(t.removeEventListener("mousedown",l),t.removeEventListener("touchstart",l)),document.removeEventListener("mousemove",s),document.removeEventListener("mouseup",u),document.removeEventListener("touchmove",s),document.removeEventListener("touchend",u)}}),[n?.chat?.isDraggable,n?.chat?.defaultWidth,n?.chat?.defaultHeight,w,c,R,h]),e.createElement(z,null,c?e.createElement("div",{className:`${Ps.mcw} ${Ps.widgetContainer} ${d?Ps.widgetContainerClosing:""}`,style:H,ref:B},e.createElement(Ts,{config:n,className:Ps.chatContainer},n?.chat?.isDraggable&&!R&&!h&&e.createElement("div",{className:Ps.dragHandle,ref:N}),n?.chat?.isResizable&&!R&&!h&&e.createElement(Bs,{resizeRef:I}),e.createElement(Fs,{text:n?.name,initialTheme:n?.chat?.defaultThemeMode||O,onClose:A,colors:{light:n?.chat?.light?.themeColors,dark:n?.chat?.dark?.themeColors},selectedColor:b,onColorChange:e=>{v(e)},config:n,isFullscreen:R||h,onToggleFullscreen:()=>{h||(R?(P&&(C(P.size),y(P.position),S(P.dragged)),F(!1),T(null)):(T({size:{...w},position:{..._},dragged:E}),C({width:window.innerWidth,height:window.innerHeight}),y({top:"0px",left:"0px"}),F(!0)))},isSmallScreen:h}),e.createElement(ks,{urlId:r,isInitConversationLoading:x,selectedColor:b,config:n,identity:s,onClose:A}))):e.createElement(e.Fragment,null,!i&&e.createElement("button",{onClick:L,className:`${Ps.launcherButton} ${D=n?.chat?.launcherButton?.buttonAnimation,{pulse:Ps.pulseAnimation,bounce:Ps.bounceAnimation,shake:Ps.shakeAnimation,tada:Ps.tadaAnimation,jello:Ps.jelloAnimation,flash:Ps.flashAnimation,spin:Ps.spinAnimation}[D]||D} ${Is(n?.chat?.launcherButton?.hoverEffect)}`,style:{position:"fixed",...Ns[n?.chat?.position],borderRadius:n?.chat?.launcherButton?.buttonBorderRadius,boxShadow:n?.chat?.launcherButton?.buttonBoxShadow,background:n?.chat?.launcherButton?.buttonBackground,border:n?.chat?.launcherButton?.buttonBorder,color:n?.chat?.launcherButton?.buttonTextColor,padding:"16px 24px",fontSize:"16px",fontWeight:"550",cursor:"pointer",zIndex:1e4},onMouseEnter:e=>{f(!0)},onMouseLeave:e=>{f(!1)}},e.createElement("span",null,n?.chat?.launcherButton?.buttonText)),!c&&!i&&p&&n?.chat?.launcherButton?.tooltip&&!h&&e.createElement("div",{style:{position:"fixed",background:"black",color:"white",borderRadius:"4px",padding:"8px 12px",fontSize:"12px",...Ns[n?.chat?.position],transform:"translateY(-58px)",opacity:.9}},n?.chat?.launcherButton?.tooltip,e.createElement("div",{style:{bottom:"-4px",left:"50%",transform:"translateX(-50%)"}}))));var D};Ls.propTypes={config:m.exports.object.isRequired,urlId:m.exports.string.isRequired};var Os=Ls;const As=({urlId:n,onClose:r=()=>{},hideLauncherButton:o=!1,identity:i})=>{const[l,s]=t(null);return a((()=>{(async()=>{try{const e=await Kt.get(`/api/widgets/config/${n}`);s(e.data)}catch(e){return 402===e?.status||403===e?.status?void console.error(e?.response?.data?.message):(console.error("Error fetching widget configs:",e),null)}})()}),[]),e.createElement(e.Fragment,null,l&&e.createElement(Os,{config:l,urlId:n,onClose:r,hideLauncherButton:o,identity:i}))};As.propTypes={urlId:m.exports.string.isRequired,onClose:m.exports.func,hideLauncherButton:m.exports.bool};var Ms=As;export{Ms as RenderWidget,Os as Widget};
15
+ //# sourceMappingURL=index.esm.js.map