tia-gpc-widget 1.0.9 → 1.1.0

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.
@@ -1,4 +1,4 @@
1
- var TiaGPC=function(e){"use strict";function t(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var n,r,o={exports:{}},i={};function a(){if(n)return i;n=1;var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),o=Symbol.for("react.strict_mode"),a=Symbol.for("react.profiler"),s=Symbol.for("react.provider"),l=Symbol.for("react.context"),u=Symbol.for("react.forward_ref"),c=Symbol.for("react.suspense"),d=Symbol.for("react.memo"),f=Symbol.for("react.lazy"),p=Symbol.iterator;var h={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},g=Object.assign,m={};function y(e,t,n){this.props=e,this.context=t,this.refs=m,this.updater=n||h}function v(){}function b(e,t,n){this.props=e,this.context=t,this.refs=m,this.updater=n||h}y.prototype.isReactComponent={},y.prototype.setState=function(e,t){if("object"!=typeof e&&"function"!=typeof e&&null!=e)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")},y.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")},v.prototype=y.prototype;var k=b.prototype=new v;k.constructor=b,g(k,y.prototype),k.isPureReactComponent=!0;var w=Array.isArray,x=Object.prototype.hasOwnProperty,S={current:null},E={key:!0,ref:!0,__self:!0,__source:!0};function C(t,n,r){var o,i={},a=null,s=null;if(null!=n)for(o in void 0!==n.ref&&(s=n.ref),void 0!==n.key&&(a=""+n.key),n)x.call(n,o)&&!E.hasOwnProperty(o)&&(i[o]=n[o]);var l=arguments.length-2;if(1===l)i.children=r;else if(1<l){for(var u=Array(l),c=0;c<l;c++)u[c]=arguments[c+2];i.children=u}if(t&&t.defaultProps)for(o in l=t.defaultProps)void 0===i[o]&&(i[o]=l[o]);return{$$typeof:e,type:t,key:a,ref:s,props:i,_owner:S.current}}function T(t){return"object"==typeof t&&null!==t&&t.$$typeof===e}var N=/\/+/g;function O(e,t){return"object"==typeof e&&null!==e&&null!=e.key?function(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,function(e){return t[e]})}(""+e.key):t.toString(36)}function P(n,r,o,i,a){var s=typeof n;"undefined"!==s&&"boolean"!==s||(n=null);var l=!1;if(null===n)l=!0;else switch(s){case"string":case"number":l=!0;break;case"object":switch(n.$$typeof){case e:case t:l=!0}}if(l)return a=a(l=n),n=""===i?"."+O(l,0):i,w(a)?(o="",null!=n&&(o=n.replace(N,"$&/")+"/"),P(a,r,o,"",function(e){return e})):null!=a&&(T(a)&&(a=function(t,n){return{$$typeof:e,type:t.type,key:n,ref:t.ref,props:t.props,_owner:t._owner}}(a,o+(!a.key||l&&l.key===a.key?"":(""+a.key).replace(N,"$&/")+"/")+n)),r.push(a)),1;if(l=0,i=""===i?".":i+":",w(n))for(var u=0;u<n.length;u++){var c=i+O(s=n[u],u);l+=P(s,r,o,c,a)}else if(c=function(e){return null===e||"object"!=typeof e?null:"function"==typeof(e=p&&e[p]||e["@@iterator"])?e:null}(n),"function"==typeof c)for(n=c.call(n),u=0;!(s=n.next()).done;)l+=P(s=s.value,r,o,c=i+O(s,u++),a);else if("object"===s)throw r=String(n),Error("Objects are not valid as a React child (found: "+("[object Object]"===r?"object with keys {"+Object.keys(n).join(", ")+"}":r)+"). If you meant to render a collection of children, use an array instead.");return l}function L(e,t,n){if(null==e)return e;var r=[],o=0;return P(e,r,"","",function(e){return t.call(n,e,o++)}),r}function _(e){if(-1===e._status){var t=e._result;(t=t()).then(function(t){0!==e._status&&-1!==e._status||(e._status=1,e._result=t)},function(t){0!==e._status&&-1!==e._status||(e._status=2,e._result=t)}),-1===e._status&&(e._status=0,e._result=t)}if(1===e._status)return e._result.default;throw e._result}var R={current:null},I={transition:null},A={ReactCurrentDispatcher:R,ReactCurrentBatchConfig:I,ReactCurrentOwner:S};function z(){throw Error("act(...) is not supported in production builds of React.")}return i.Children={map:L,forEach:function(e,t,n){L(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return L(e,function(){t++}),t},toArray:function(e){return L(e,function(e){return e})||[]},only:function(e){if(!T(e))throw Error("React.Children.only expected to receive a single React element child.");return e}},i.Component=y,i.Fragment=r,i.Profiler=a,i.PureComponent=b,i.StrictMode=o,i.Suspense=c,i.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=A,i.act=z,i.cloneElement=function(t,n,r){if(null==t)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+t+".");var o=g({},t.props),i=t.key,a=t.ref,s=t._owner;if(null!=n){if(void 0!==n.ref&&(a=n.ref,s=S.current),void 0!==n.key&&(i=""+n.key),t.type&&t.type.defaultProps)var l=t.type.defaultProps;for(u in n)x.call(n,u)&&!E.hasOwnProperty(u)&&(o[u]=void 0===n[u]&&void 0!==l?l[u]:n[u])}var u=arguments.length-2;if(1===u)o.children=r;else if(1<u){l=Array(u);for(var c=0;c<u;c++)l[c]=arguments[c+2];o.children=l}return{$$typeof:e,type:t.type,key:i,ref:a,props:o,_owner:s}},i.createContext=function(e){return(e={$$typeof:l,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null}).Provider={$$typeof:s,_context:e},e.Consumer=e},i.createElement=C,i.createFactory=function(e){var t=C.bind(null,e);return t.type=e,t},i.createRef=function(){return{current:null}},i.forwardRef=function(e){return{$$typeof:u,render:e}},i.isValidElement=T,i.lazy=function(e){return{$$typeof:f,_payload:{_status:-1,_result:e},_init:_}},i.memo=function(e,t){return{$$typeof:d,type:e,compare:void 0===t?null:t}},i.startTransition=function(e){var t=I.transition;I.transition={};try{e()}finally{I.transition=t}},i.unstable_act=z,i.useCallback=function(e,t){return R.current.useCallback(e,t)},i.useContext=function(e){return R.current.useContext(e)},i.useDebugValue=function(){},i.useDeferredValue=function(e){return R.current.useDeferredValue(e)},i.useEffect=function(e,t){return R.current.useEffect(e,t)},i.useId=function(){return R.current.useId()},i.useImperativeHandle=function(e,t,n){return R.current.useImperativeHandle(e,t,n)},i.useInsertionEffect=function(e,t){return R.current.useInsertionEffect(e,t)},i.useLayoutEffect=function(e,t){return R.current.useLayoutEffect(e,t)},i.useMemo=function(e,t){return R.current.useMemo(e,t)},i.useReducer=function(e,t,n){return R.current.useReducer(e,t,n)},i.useRef=function(e){return R.current.useRef(e)},i.useState=function(e){return R.current.useState(e)},i.useSyncExternalStore=function(e,t,n){return R.current.useSyncExternalStore(e,t,n)},i.useTransition=function(){return R.current.useTransition()},i.version="18.3.1",i}function s(){return r||(r=1,o.exports=a()),o.exports}var l=s();const u=t(l);var c,d,f,p,h,g={},m={exports:{}},y={},v={exports:{}},b={};function k(){return d||(d=1,v.exports=(c||(c=1,function(e){function t(e,t){var n=e.length;e.push(t);e:for(;0<n;){var r=n-1>>>1,i=e[r];if(!(0<o(i,t)))break e;e[r]=t,e[n]=i,n=r}}function n(e){return 0===e.length?null:e[0]}function r(e){if(0===e.length)return null;var t=e[0],n=e.pop();if(n!==t){e[0]=n;e:for(var r=0,i=e.length,a=i>>>1;r<a;){var s=2*(r+1)-1,l=e[s],u=s+1,c=e[u];if(0>o(l,n))u<i&&0>o(c,l)?(e[r]=c,e[u]=n,r=u):(e[r]=l,e[s]=n,r=s);else{if(!(u<i&&0>o(c,n)))break e;e[r]=c,e[u]=n,r=u}}}return t}function o(e,t){var n=e.sortIndex-t.sortIndex;return 0!==n?n:e.id-t.id}if("object"==typeof performance&&"function"==typeof performance.now){var i=performance;e.unstable_now=function(){return i.now()}}else{var a=Date,s=a.now();e.unstable_now=function(){return a.now()-s}}var l=[],u=[],c=1,d=null,f=3,p=!1,h=!1,g=!1,m="function"==typeof setTimeout?setTimeout:null,y="function"==typeof clearTimeout?clearTimeout:null,v="undefined"!=typeof setImmediate?setImmediate:null;function b(e){for(var o=n(u);null!==o;){if(null===o.callback)r(u);else{if(!(o.startTime<=e))break;r(u),o.sortIndex=o.expirationTime,t(l,o)}o=n(u)}}function k(e){if(g=!1,b(e),!h)if(null!==n(l))h=!0,R(w);else{var t=n(u);null!==t&&I(k,t.startTime-e)}}function w(t,o){h=!1,g&&(g=!1,y(C),C=-1),p=!0;var i=f;try{for(b(o),d=n(l);null!==d&&(!(d.expirationTime>o)||t&&!O());){var a=d.callback;if("function"==typeof a){d.callback=null,f=d.priorityLevel;var s=a(d.expirationTime<=o);o=e.unstable_now(),"function"==typeof s?d.callback=s:d===n(l)&&r(l),b(o)}else r(l);d=n(l)}if(null!==d)var c=!0;else{var m=n(u);null!==m&&I(k,m.startTime-o),c=!1}return c}finally{d=null,f=i,p=!1}}"undefined"!=typeof navigator&&void 0!==navigator.scheduling&&void 0!==navigator.scheduling.isInputPending&&navigator.scheduling.isInputPending.bind(navigator.scheduling);var x,S=!1,E=null,C=-1,T=5,N=-1;function O(){return!(e.unstable_now()-N<T)}function P(){if(null!==E){var t=e.unstable_now();N=t;var n=!0;try{n=E(!0,t)}finally{n?x():(S=!1,E=null)}}else S=!1}if("function"==typeof v)x=function(){v(P)};else if("undefined"!=typeof MessageChannel){var L=new MessageChannel,_=L.port2;L.port1.onmessage=P,x=function(){_.postMessage(null)}}else x=function(){m(P,0)};function R(e){E=e,S||(S=!0,x())}function I(t,n){C=m(function(){t(e.unstable_now())},n)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(e){e.callback=null},e.unstable_continueExecution=function(){h||p||(h=!0,R(w))},e.unstable_forceFrameRate=function(e){0>e||125<e||(T=0<e?Math.floor(1e3/e):5)},e.unstable_getCurrentPriorityLevel=function(){return f},e.unstable_getFirstCallbackNode=function(){return n(l)},e.unstable_next=function(e){switch(f){case 1:case 2:case 3:var t=3;break;default:t=f}var n=f;f=t;try{return e()}finally{f=n}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(e,t){switch(e){case 1:case 2:case 3:case 4:case 5:break;default:e=3}var n=f;f=e;try{return t()}finally{f=n}},e.unstable_scheduleCallback=function(r,o,i){var a=e.unstable_now();switch(i="object"==typeof i&&null!==i&&"number"==typeof(i=i.delay)&&0<i?a+i:a,r){case 1:var s=-1;break;case 2:s=250;break;case 5:s=1073741823;break;case 4:s=1e4;break;default:s=5e3}return r={id:c++,callback:o,priorityLevel:r,startTime:i,expirationTime:s=i+s,sortIndex:-1},i>a?(r.sortIndex=i,t(u,r),null===n(l)&&r===n(u)&&(g?(y(C),C=-1):g=!0,I(k,i-a))):(r.sortIndex=s,t(l,r),h||p||(h=!0,R(w))),r},e.unstable_shouldYield=O,e.unstable_wrapCallback=function(e){var t=f;return function(){var n=f;f=t;try{return e.apply(this,arguments)}finally{f=n}}}}(b)),b)),v.exports}
1
+ var TiaGPC=function(e){"use strict";function t(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var n,r,o={exports:{}},i={};function a(){if(n)return i;n=1;var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),o=Symbol.for("react.strict_mode"),a=Symbol.for("react.profiler"),s=Symbol.for("react.provider"),l=Symbol.for("react.context"),u=Symbol.for("react.forward_ref"),c=Symbol.for("react.suspense"),d=Symbol.for("react.memo"),f=Symbol.for("react.lazy"),p=Symbol.iterator;var h={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},g=Object.assign,m={};function y(e,t,n){this.props=e,this.context=t,this.refs=m,this.updater=n||h}function v(){}function b(e,t,n){this.props=e,this.context=t,this.refs=m,this.updater=n||h}y.prototype.isReactComponent={},y.prototype.setState=function(e,t){if("object"!=typeof e&&"function"!=typeof e&&null!=e)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")},y.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")},v.prototype=y.prototype;var k=b.prototype=new v;k.constructor=b,g(k,y.prototype),k.isPureReactComponent=!0;var x=Array.isArray,w=Object.prototype.hasOwnProperty,S={current:null},E={key:!0,ref:!0,__self:!0,__source:!0};function C(t,n,r){var o,i={},a=null,s=null;if(null!=n)for(o in void 0!==n.ref&&(s=n.ref),void 0!==n.key&&(a=""+n.key),n)w.call(n,o)&&!E.hasOwnProperty(o)&&(i[o]=n[o]);var l=arguments.length-2;if(1===l)i.children=r;else if(1<l){for(var u=Array(l),c=0;c<l;c++)u[c]=arguments[c+2];i.children=u}if(t&&t.defaultProps)for(o in l=t.defaultProps)void 0===i[o]&&(i[o]=l[o]);return{$$typeof:e,type:t,key:a,ref:s,props:i,_owner:S.current}}function T(t){return"object"==typeof t&&null!==t&&t.$$typeof===e}var O=/\/+/g;function N(e,t){return"object"==typeof e&&null!==e&&null!=e.key?function(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,function(e){return t[e]})}(""+e.key):t.toString(36)}function P(n,r,o,i,a){var s=typeof n;"undefined"!==s&&"boolean"!==s||(n=null);var l=!1;if(null===n)l=!0;else switch(s){case"string":case"number":l=!0;break;case"object":switch(n.$$typeof){case e:case t:l=!0}}if(l)return a=a(l=n),n=""===i?"."+N(l,0):i,x(a)?(o="",null!=n&&(o=n.replace(O,"$&/")+"/"),P(a,r,o,"",function(e){return e})):null!=a&&(T(a)&&(a=function(t,n){return{$$typeof:e,type:t.type,key:n,ref:t.ref,props:t.props,_owner:t._owner}}(a,o+(!a.key||l&&l.key===a.key?"":(""+a.key).replace(O,"$&/")+"/")+n)),r.push(a)),1;if(l=0,i=""===i?".":i+":",x(n))for(var u=0;u<n.length;u++){var c=i+N(s=n[u],u);l+=P(s,r,o,c,a)}else if(c=function(e){return null===e||"object"!=typeof e?null:"function"==typeof(e=p&&e[p]||e["@@iterator"])?e:null}(n),"function"==typeof c)for(n=c.call(n),u=0;!(s=n.next()).done;)l+=P(s=s.value,r,o,c=i+N(s,u++),a);else if("object"===s)throw r=String(n),Error("Objects are not valid as a React child (found: "+("[object Object]"===r?"object with keys {"+Object.keys(n).join(", ")+"}":r)+"). If you meant to render a collection of children, use an array instead.");return l}function L(e,t,n){if(null==e)return e;var r=[],o=0;return P(e,r,"","",function(e){return t.call(n,e,o++)}),r}function R(e){if(-1===e._status){var t=e._result;(t=t()).then(function(t){0!==e._status&&-1!==e._status||(e._status=1,e._result=t)},function(t){0!==e._status&&-1!==e._status||(e._status=2,e._result=t)}),-1===e._status&&(e._status=0,e._result=t)}if(1===e._status)return e._result.default;throw e._result}var _={current:null},I={transition:null},A={ReactCurrentDispatcher:_,ReactCurrentBatchConfig:I,ReactCurrentOwner:S};function D(){throw Error("act(...) is not supported in production builds of React.")}return i.Children={map:L,forEach:function(e,t,n){L(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return L(e,function(){t++}),t},toArray:function(e){return L(e,function(e){return e})||[]},only:function(e){if(!T(e))throw Error("React.Children.only expected to receive a single React element child.");return e}},i.Component=y,i.Fragment=r,i.Profiler=a,i.PureComponent=b,i.StrictMode=o,i.Suspense=c,i.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=A,i.act=D,i.cloneElement=function(t,n,r){if(null==t)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+t+".");var o=g({},t.props),i=t.key,a=t.ref,s=t._owner;if(null!=n){if(void 0!==n.ref&&(a=n.ref,s=S.current),void 0!==n.key&&(i=""+n.key),t.type&&t.type.defaultProps)var l=t.type.defaultProps;for(u in n)w.call(n,u)&&!E.hasOwnProperty(u)&&(o[u]=void 0===n[u]&&void 0!==l?l[u]:n[u])}var u=arguments.length-2;if(1===u)o.children=r;else if(1<u){l=Array(u);for(var c=0;c<u;c++)l[c]=arguments[c+2];o.children=l}return{$$typeof:e,type:t.type,key:i,ref:a,props:o,_owner:s}},i.createContext=function(e){return(e={$$typeof:l,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null}).Provider={$$typeof:s,_context:e},e.Consumer=e},i.createElement=C,i.createFactory=function(e){var t=C.bind(null,e);return t.type=e,t},i.createRef=function(){return{current:null}},i.forwardRef=function(e){return{$$typeof:u,render:e}},i.isValidElement=T,i.lazy=function(e){return{$$typeof:f,_payload:{_status:-1,_result:e},_init:R}},i.memo=function(e,t){return{$$typeof:d,type:e,compare:void 0===t?null:t}},i.startTransition=function(e){var t=I.transition;I.transition={};try{e()}finally{I.transition=t}},i.unstable_act=D,i.useCallback=function(e,t){return _.current.useCallback(e,t)},i.useContext=function(e){return _.current.useContext(e)},i.useDebugValue=function(){},i.useDeferredValue=function(e){return _.current.useDeferredValue(e)},i.useEffect=function(e,t){return _.current.useEffect(e,t)},i.useId=function(){return _.current.useId()},i.useImperativeHandle=function(e,t,n){return _.current.useImperativeHandle(e,t,n)},i.useInsertionEffect=function(e,t){return _.current.useInsertionEffect(e,t)},i.useLayoutEffect=function(e,t){return _.current.useLayoutEffect(e,t)},i.useMemo=function(e,t){return _.current.useMemo(e,t)},i.useReducer=function(e,t,n){return _.current.useReducer(e,t,n)},i.useRef=function(e){return _.current.useRef(e)},i.useState=function(e){return _.current.useState(e)},i.useSyncExternalStore=function(e,t,n){return _.current.useSyncExternalStore(e,t,n)},i.useTransition=function(){return _.current.useTransition()},i.version="18.3.1",i}function s(){return r||(r=1,o.exports=a()),o.exports}var l=s();const u=t(l);var c,d,f,p,h,g={},m={exports:{}},y={},v={exports:{}},b={};function k(){return d||(d=1,v.exports=(c||(c=1,function(e){function t(e,t){var n=e.length;e.push(t);e:for(;0<n;){var r=n-1>>>1,i=e[r];if(!(0<o(i,t)))break e;e[r]=t,e[n]=i,n=r}}function n(e){return 0===e.length?null:e[0]}function r(e){if(0===e.length)return null;var t=e[0],n=e.pop();if(n!==t){e[0]=n;e:for(var r=0,i=e.length,a=i>>>1;r<a;){var s=2*(r+1)-1,l=e[s],u=s+1,c=e[u];if(0>o(l,n))u<i&&0>o(c,l)?(e[r]=c,e[u]=n,r=u):(e[r]=l,e[s]=n,r=s);else{if(!(u<i&&0>o(c,n)))break e;e[r]=c,e[u]=n,r=u}}}return t}function o(e,t){var n=e.sortIndex-t.sortIndex;return 0!==n?n:e.id-t.id}if("object"==typeof performance&&"function"==typeof performance.now){var i=performance;e.unstable_now=function(){return i.now()}}else{var a=Date,s=a.now();e.unstable_now=function(){return a.now()-s}}var l=[],u=[],c=1,d=null,f=3,p=!1,h=!1,g=!1,m="function"==typeof setTimeout?setTimeout:null,y="function"==typeof clearTimeout?clearTimeout:null,v="undefined"!=typeof setImmediate?setImmediate:null;function b(e){for(var o=n(u);null!==o;){if(null===o.callback)r(u);else{if(!(o.startTime<=e))break;r(u),o.sortIndex=o.expirationTime,t(l,o)}o=n(u)}}function k(e){if(g=!1,b(e),!h)if(null!==n(l))h=!0,_(x);else{var t=n(u);null!==t&&I(k,t.startTime-e)}}function x(t,o){h=!1,g&&(g=!1,y(C),C=-1),p=!0;var i=f;try{for(b(o),d=n(l);null!==d&&(!(d.expirationTime>o)||t&&!N());){var a=d.callback;if("function"==typeof a){d.callback=null,f=d.priorityLevel;var s=a(d.expirationTime<=o);o=e.unstable_now(),"function"==typeof s?d.callback=s:d===n(l)&&r(l),b(o)}else r(l);d=n(l)}if(null!==d)var c=!0;else{var m=n(u);null!==m&&I(k,m.startTime-o),c=!1}return c}finally{d=null,f=i,p=!1}}"undefined"!=typeof navigator&&void 0!==navigator.scheduling&&void 0!==navigator.scheduling.isInputPending&&navigator.scheduling.isInputPending.bind(navigator.scheduling);var w,S=!1,E=null,C=-1,T=5,O=-1;function N(){return!(e.unstable_now()-O<T)}function P(){if(null!==E){var t=e.unstable_now();O=t;var n=!0;try{n=E(!0,t)}finally{n?w():(S=!1,E=null)}}else S=!1}if("function"==typeof v)w=function(){v(P)};else if("undefined"!=typeof MessageChannel){var L=new MessageChannel,R=L.port2;L.port1.onmessage=P,w=function(){R.postMessage(null)}}else w=function(){m(P,0)};function _(e){E=e,S||(S=!0,w())}function I(t,n){C=m(function(){t(e.unstable_now())},n)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(e){e.callback=null},e.unstable_continueExecution=function(){h||p||(h=!0,_(x))},e.unstable_forceFrameRate=function(e){0>e||125<e||(T=0<e?Math.floor(1e3/e):5)},e.unstable_getCurrentPriorityLevel=function(){return f},e.unstable_getFirstCallbackNode=function(){return n(l)},e.unstable_next=function(e){switch(f){case 1:case 2:case 3:var t=3;break;default:t=f}var n=f;f=t;try{return e()}finally{f=n}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(e,t){switch(e){case 1:case 2:case 3:case 4:case 5:break;default:e=3}var n=f;f=e;try{return t()}finally{f=n}},e.unstable_scheduleCallback=function(r,o,i){var a=e.unstable_now();switch(i="object"==typeof i&&null!==i&&"number"==typeof(i=i.delay)&&0<i?a+i:a,r){case 1:var s=-1;break;case 2:s=250;break;case 5:s=1073741823;break;case 4:s=1e4;break;default:s=5e3}return r={id:c++,callback:o,priorityLevel:r,startTime:i,expirationTime:s=i+s,sortIndex:-1},i>a?(r.sortIndex=i,t(u,r),null===n(l)&&r===n(u)&&(g?(y(C),C=-1):g=!0,I(k,i-a))):(r.sortIndex=s,t(l,r),h||p||(h=!0,_(x))),r},e.unstable_shouldYield=N,e.unstable_wrapCallback=function(e){var t=f;return function(){var n=f;f=t;try{return e.apply(this,arguments)}finally{f=n}}}}(b)),b)),v.exports}
2
2
  /**
3
3
  * @license React
4
4
  * react-dom.production.min.js
@@ -7,7 +7,7 @@ var TiaGPC=function(e){"use strict";function t(e){return e&&e.__esModule&&Object
7
7
  *
8
8
  * This source code is licensed under the MIT license found in the
9
9
  * LICENSE file in the root directory of this source tree.
10
- */function w(){if(f)return y;f=1;var e=s(),t=k();function n(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n<arguments.length;n++)t+="&args[]="+encodeURIComponent(arguments[n]);return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var r=new Set,o={};function i(e,t){a(e,t),a(e+"Capture",t)}function a(e,t){for(o[e]=t,e=0;e<t.length;e++)r.add(t[e])}var l=!("undefined"==typeof window||void 0===window.document||void 0===window.document.createElement),u=Object.prototype.hasOwnProperty,c=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,d={},p={};function h(e,t,n,r,o,i,a){this.acceptsBooleans=2===t||3===t||4===t,this.attributeName=r,this.attributeNamespace=o,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=i,this.removeEmptyString=a}var g={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){g[e]=new h(e,0,!1,e,null,!1,!1)}),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];g[t]=new h(t,1,!1,e[1],null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(function(e){g[e]=new h(e,2,!1,e.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){g[e]=new h(e,2,!1,e,null,!1,!1)}),"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){g[e]=new h(e,3,!1,e.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(function(e){g[e]=new h(e,3,!0,e,null,!1,!1)}),["capture","download"].forEach(function(e){g[e]=new h(e,4,!1,e,null,!1,!1)}),["cols","rows","size","span"].forEach(function(e){g[e]=new h(e,6,!1,e,null,!1,!1)}),["rowSpan","start"].forEach(function(e){g[e]=new h(e,5,!1,e.toLowerCase(),null,!1,!1)});var m=/[\-:]([a-z])/g;function v(e){return e[1].toUpperCase()}function b(e,t,n,r){var o=g.hasOwnProperty(t)?g[t]:null;(null!==o?0!==o.type:r||!(2<t.length)||"o"!==t[0]&&"O"!==t[0]||"n"!==t[1]&&"N"!==t[1])&&(function(e,t,n,r){if(null==t||function(e,t,n,r){if(null!==n&&0===n.type)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return!r&&(null!==n?!n.acceptsBooleans:"data-"!==(e=e.toLowerCase().slice(0,5))&&"aria-"!==e);default:return!1}}(e,t,n,r))return!0;if(r)return!1;if(null!==n)switch(n.type){case 3:return!t;case 4:return!1===t;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}(t,n,o,r)&&(n=null),r||null===o?function(e){return!!u.call(p,e)||!u.call(d,e)&&(c.test(e)?p[e]=!0:(d[e]=!0,!1))}(t)&&(null===n?e.removeAttribute(t):e.setAttribute(t,""+n)):o.mustUseProperty?e[o.propertyName]=null===n?3!==o.type&&"":n:(t=o.attributeName,r=o.attributeNamespace,null===n?e.removeAttribute(t):(n=3===(o=o.type)||4===o&&!0===n?"":""+n,r?e.setAttributeNS(r,t,n):e.setAttribute(t,n))))}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var t=e.replace(m,v);g[t]=new h(t,1,!1,e,null,!1,!1)}),"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(m,v);g[t]=new h(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)}),["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(m,v);g[t]=new h(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(function(e){g[e]=new h(e,1,!1,e.toLowerCase(),null,!1,!1)}),g.xlinkHref=new h("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(function(e){g[e]=new h(e,1,!1,e.toLowerCase(),null,!0,!0)});var w=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,x=Symbol.for("react.element"),S=Symbol.for("react.portal"),E=Symbol.for("react.fragment"),C=Symbol.for("react.strict_mode"),T=Symbol.for("react.profiler"),N=Symbol.for("react.provider"),O=Symbol.for("react.context"),P=Symbol.for("react.forward_ref"),L=Symbol.for("react.suspense"),_=Symbol.for("react.suspense_list"),R=Symbol.for("react.memo"),I=Symbol.for("react.lazy"),A=Symbol.for("react.offscreen"),z=Symbol.iterator;function j(e){return null===e||"object"!=typeof e?null:"function"==typeof(e=z&&e[z]||e["@@iterator"])?e:null}var D,F=Object.assign;function M(e){if(void 0===D)try{throw Error()}catch(n){var t=n.stack.trim().match(/\n( *(at )?)/);D=t&&t[1]||""}return"\n"+D+e}var U=!1;function B(e,t){if(!e||U)return"";U=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(t)if(t=function(){throw Error()},Object.defineProperty(t.prototype,"props",{set:function(){throw Error()}}),"object"==typeof Reflect&&Reflect.construct){try{Reflect.construct(t,[])}catch(je){var r=je}Reflect.construct(e,[],t)}else{try{t.call()}catch(je){r=je}e.call(t.prototype)}else{try{throw Error()}catch(je){r=je}e()}}catch(je){if(je&&r&&"string"==typeof je.stack){for(var o=je.stack.split("\n"),i=r.stack.split("\n"),a=o.length-1,s=i.length-1;1<=a&&0<=s&&o[a]!==i[s];)s--;for(;1<=a&&0<=s;a--,s--)if(o[a]!==i[s]){if(1!==a||1!==s)do{if(a--,0>--s||o[a]!==i[s]){var l="\n"+o[a].replace(" at new "," at ");return e.displayName&&l.includes("<anonymous>")&&(l=l.replace("<anonymous>",e.displayName)),l}}while(1<=a&&0<=s);break}}}finally{U=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?M(e):""}function $(e){switch(e.tag){case 5:return M(e.type);case 16:return M("Lazy");case 13:return M("Suspense");case 19:return M("SuspenseList");case 0:case 2:case 15:return e=B(e.type,!1);case 11:return e=B(e.type.render,!1);case 1:return e=B(e.type,!0);default:return""}}function V(e){if(null==e)return null;if("function"==typeof e)return e.displayName||e.name||null;if("string"==typeof e)return e;switch(e){case E:return"Fragment";case S:return"Portal";case T:return"Profiler";case C:return"StrictMode";case L:return"Suspense";case _:return"SuspenseList"}if("object"==typeof e)switch(e.$$typeof){case O:return(e.displayName||"Context")+".Consumer";case N:return(e._context.displayName||"Context")+".Provider";case P:var t=e.render;return(e=e.displayName)||(e=""!==(e=t.displayName||t.name||"")?"ForwardRef("+e+")":"ForwardRef"),e;case R:return null!==(t=e.displayName||null)?t:V(e.type)||"Memo";case I:t=e._payload,e=e._init;try{return V(e(t))}catch(n){}}return null}function H(e){var t=e.type;switch(e.tag){case 24:return"Cache";case 9:return(t.displayName||"Context")+".Consumer";case 10:return(t._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return e=(e=t.render).displayName||e.name||"",t.displayName||(""!==e?"ForwardRef("+e+")":"ForwardRef");case 7:return"Fragment";case 5:return t;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return V(t);case 8:return t===C?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if("function"==typeof t)return t.displayName||t.name||null;if("string"==typeof t)return t}return null}function q(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":case"object":return e;default:return""}}function W(e){var t=e.type;return(e=e.nodeName)&&"input"===e.toLowerCase()&&("checkbox"===t||"radio"===t)}function K(e){e._valueTracker||(e._valueTracker=function(e){var t=W(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),r=""+e[t];if(!e.hasOwnProperty(t)&&void 0!==n&&"function"==typeof n.get&&"function"==typeof n.set){var o=n.get,i=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return o.call(this)},set:function(e){r=""+e,i.call(this,e)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(e){r=""+e},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}(e))}function Q(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=W(e)?e.checked?"true":"false":e.value),(e=r)!==n&&(t.setValue(e),!0)}function J(e){if(void 0===(e=e||("undefined"!=typeof document?document:void 0)))return null;try{return e.activeElement||e.body}catch(t){return e.body}}function Y(e,t){var n=t.checked;return F({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:null!=n?n:e._wrapperState.initialChecked})}function G(e,t){var n=null==t.defaultValue?"":t.defaultValue,r=null!=t.checked?t.checked:t.defaultChecked;n=q(null!=t.value?t.value:n),e._wrapperState={initialChecked:r,initialValue:n,controlled:"checkbox"===t.type||"radio"===t.type?null!=t.checked:null!=t.value}}function X(e,t){null!=(t=t.checked)&&b(e,"checked",t,!1)}function Z(e,t){X(e,t);var n=q(t.value),r=t.type;if(null!=n)"number"===r?(0===n&&""===e.value||e.value!=n)&&(e.value=""+n):e.value!==""+n&&(e.value=""+n);else if("submit"===r||"reset"===r)return void e.removeAttribute("value");t.hasOwnProperty("value")?te(e,t.type,n):t.hasOwnProperty("defaultValue")&&te(e,t.type,q(t.defaultValue)),null==t.checked&&null!=t.defaultChecked&&(e.defaultChecked=!!t.defaultChecked)}function ee(e,t,n){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var r=t.type;if(!("submit"!==r&&"reset"!==r||void 0!==t.value&&null!==t.value))return;t=""+e._wrapperState.initialValue,n||t===e.value||(e.value=t),e.defaultValue=t}""!==(n=e.name)&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,""!==n&&(e.name=n)}function te(e,t,n){"number"===t&&J(e.ownerDocument)===e||(null==n?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var ne=Array.isArray;function re(e,t,n,r){if(e=e.options,t){t={};for(var o=0;o<n.length;o++)t["$"+n[o]]=!0;for(n=0;n<e.length;n++)o=t.hasOwnProperty("$"+e[n].value),e[n].selected!==o&&(e[n].selected=o),o&&r&&(e[n].defaultSelected=!0)}else{for(n=""+q(n),t=null,o=0;o<e.length;o++){if(e[o].value===n)return e[o].selected=!0,void(r&&(e[o].defaultSelected=!0));null!==t||e[o].disabled||(t=e[o])}null!==t&&(t.selected=!0)}}function oe(e,t){if(null!=t.dangerouslySetInnerHTML)throw Error(n(91));return F({},t,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue})}function ie(e,t){var r=t.value;if(null==r){if(r=t.children,t=t.defaultValue,null!=r){if(null!=t)throw Error(n(92));if(ne(r)){if(1<r.length)throw Error(n(93));r=r[0]}t=r}null==t&&(t=""),r=t}e._wrapperState={initialValue:q(r)}}function ae(e,t){var n=q(t.value),r=q(t.defaultValue);null!=n&&((n=""+n)!==e.value&&(e.value=n),null==t.defaultValue&&e.defaultValue!==n&&(e.defaultValue=n)),null!=r&&(e.defaultValue=""+r)}function se(e){var t=e.textContent;t===e._wrapperState.initialValue&&""!==t&&null!==t&&(e.value=t)}function le(e){switch(e){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function ue(e,t){return null==e||"http://www.w3.org/1999/xhtml"===e?le(t):"http://www.w3.org/2000/svg"===e&&"foreignObject"===t?"http://www.w3.org/1999/xhtml":e}var ce,de,fe=(de=function(e,t){if("http://www.w3.org/2000/svg"!==e.namespaceURI||"innerHTML"in e)e.innerHTML=t;else{for((ce=ce||document.createElement("div")).innerHTML="<svg>"+t.valueOf().toString()+"</svg>",t=ce.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}},"undefined"!=typeof MSApp&&MSApp.execUnsafeLocalFunction?function(e,t,n,r){MSApp.execUnsafeLocalFunction(function(){return de(e,t)})}:de);function pe(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&3===n.nodeType)return void(n.nodeValue=t)}e.textContent=t}var he={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},ge=["Webkit","ms","Moz","O"];function me(e,t,n){return null==t||"boolean"==typeof t||""===t?"":n||"number"!=typeof t||0===t||he.hasOwnProperty(e)&&he[e]?(""+t).trim():t+"px"}function ye(e,t){for(var n in e=e.style,t)if(t.hasOwnProperty(n)){var r=0===n.indexOf("--"),o=me(n,t[n],r);"float"===n&&(n="cssFloat"),r?e.setProperty(n,o):e[n]=o}}Object.keys(he).forEach(function(e){ge.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),he[t]=he[e]})});var ve=F({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function be(e,t){if(t){if(ve[e]&&(null!=t.children||null!=t.dangerouslySetInnerHTML))throw Error(n(137,e));if(null!=t.dangerouslySetInnerHTML){if(null!=t.children)throw Error(n(60));if("object"!=typeof t.dangerouslySetInnerHTML||!("__html"in t.dangerouslySetInnerHTML))throw Error(n(61))}if(null!=t.style&&"object"!=typeof t.style)throw Error(n(62))}}function ke(e,t){if(-1===e.indexOf("-"))return"string"==typeof t.is;switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var we=null;function xe(e){return(e=e.target||e.srcElement||window).correspondingUseElement&&(e=e.correspondingUseElement),3===e.nodeType?e.parentNode:e}var Se=null,Ee=null,Ce=null;function Te(e){if(e=Co(e)){if("function"!=typeof Se)throw Error(n(280));var t=e.stateNode;t&&(t=No(t),Se(e.stateNode,e.type,t))}}function Ne(e){Ee?Ce?Ce.push(e):Ce=[e]:Ee=e}function Oe(){if(Ee){var e=Ee,t=Ce;if(Ce=Ee=null,Te(e),t)for(e=0;e<t.length;e++)Te(t[e])}}function Pe(e,t){return e(t)}function Le(){}var _e=!1;function Re(e,t,n){if(_e)return e(t,n);_e=!0;try{return Pe(e,t,n)}finally{_e=!1,(null!==Ee||null!==Ce)&&(Le(),Oe())}}function De(e,t){var r=e.stateNode;if(null===r)return null;var o=No(r);if(null===o)return null;r=o[t];e:switch(t){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(o=!o.disabled)||(o=!("button"===(e=e.type)||"input"===e||"select"===e||"textarea"===e)),e=!o;break e;default:e=!1}if(e)return null;if(r&&"function"!=typeof r)throw Error(n(231,t,typeof r));return r}var Fe=!1;if(l)try{var Me={};Object.defineProperty(Me,"passive",{get:function(){Fe=!0}}),window.addEventListener("test",Me,Me),window.removeEventListener("test",Me,Me)}catch(de){Fe=!1}function Ue(e,t,n,r,o,i,a,s,l){var u=Array.prototype.slice.call(arguments,3);try{t.apply(n,u)}catch(c){this.onError(c)}}var Be=!1,$e=null,Ve=!1,He=null,qe={onError:function(e){Be=!0,$e=e}};function We(e,t,n,r,o,i,a,s,l){Be=!1,$e=null,Ue.apply(qe,arguments)}function Ke(e){var t=e,n=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do{!!(4098&(t=e).flags)&&(n=t.return),e=t.return}while(e)}return 3===t.tag?n:null}function Qe(e){if(13===e.tag){var t=e.memoizedState;if(null===t&&(null!==(e=e.alternate)&&(t=e.memoizedState)),null!==t)return t.dehydrated}return null}function Je(e){if(Ke(e)!==e)throw Error(n(188))}function Ye(e){return null!==(e=function(e){var t=e.alternate;if(!t){if(null===(t=Ke(e)))throw Error(n(188));return t!==e?null:e}for(var r=e,o=t;;){var i=r.return;if(null===i)break;var a=i.alternate;if(null===a){if(null!==(o=i.return)){r=o;continue}break}if(i.child===a.child){for(a=i.child;a;){if(a===r)return Je(i),e;if(a===o)return Je(i),t;a=a.sibling}throw Error(n(188))}if(r.return!==o.return)r=i,o=a;else{for(var s=!1,l=i.child;l;){if(l===r){s=!0,r=i,o=a;break}if(l===o){s=!0,o=i,r=a;break}l=l.sibling}if(!s){for(l=a.child;l;){if(l===r){s=!0,r=a,o=i;break}if(l===o){s=!0,o=a,r=i;break}l=l.sibling}if(!s)throw Error(n(189))}}if(r.alternate!==o)throw Error(n(190))}if(3!==r.tag)throw Error(n(188));return r.stateNode.current===r?e:t}(e))?Ge(e):null}function Ge(e){if(5===e.tag||6===e.tag)return e;for(e=e.child;null!==e;){var t=Ge(e);if(null!==t)return t;e=e.sibling}return null}var Xe=t.unstable_scheduleCallback,Ze=t.unstable_cancelCallback,et=t.unstable_shouldYield,tt=t.unstable_requestPaint,nt=t.unstable_now,rt=t.unstable_getCurrentPriorityLevel,ot=t.unstable_ImmediatePriority,it=t.unstable_UserBlockingPriority,at=t.unstable_NormalPriority,st=t.unstable_LowPriority,lt=t.unstable_IdlePriority,ut=null,ct=null;var dt=Math.clz32?Math.clz32:function(e){return e>>>=0,0===e?32:31-(ft(e)/pt|0)|0},ft=Math.log,pt=Math.LN2;var ht=64,gt=4194304;function mt(e){switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return 4194240&e;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return 130023424&e;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return e}}function yt(e,t){var n=e.pendingLanes;if(0===n)return 0;var r=0,o=e.suspendedLanes,i=e.pingedLanes,a=268435455&n;if(0!==a){var s=a&~o;0!==s?r=mt(s):0!==(i&=a)&&(r=mt(i))}else 0!==(a=n&~o)?r=mt(a):0!==i&&(r=mt(i));if(0===r)return 0;if(0!==t&&t!==r&&0===(t&o)&&((o=r&-r)>=(i=t&-t)||16===o&&4194240&i))return t;if(4&r&&(r|=16&n),0!==(t=e.entangledLanes))for(e=e.entanglements,t&=r;0<t;)o=1<<(n=31-dt(t)),r|=e[n],t&=~o;return r}function vt(e,t){switch(e){case 1:case 2:case 4:return t+250;case 8:case 16:case 32:case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;default:return-1}}function bt(e){return 0!==(e=-1073741825&e.pendingLanes)?e:1073741824&e?1073741824:0}function kt(){var e=ht;return!(4194240&(ht<<=1))&&(ht=64),e}function wt(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function xt(e,t,n){e.pendingLanes|=t,536870912!==t&&(e.suspendedLanes=0,e.pingedLanes=0),(e=e.eventTimes)[t=31-dt(t)]=n}function St(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var r=31-dt(n),o=1<<r;o&t|e[r]&t&&(e[r]|=t),n&=~o}}var Et=0;function Ct(e){return 1<(e&=-e)?4<e?268435455&e?16:536870912:4:1}var Tt,Nt,Ot,Pt,Lt,_t=!1,Rt=[],It=null,At=null,zt=null,jt=new Map,Dt=new Map,Ft=[],Mt="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset submit".split(" ");function Ut(e,t){switch(e){case"focusin":case"focusout":It=null;break;case"dragenter":case"dragleave":At=null;break;case"mouseover":case"mouseout":zt=null;break;case"pointerover":case"pointerout":jt.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":Dt.delete(t.pointerId)}}function Bt(e,t,n,r,o,i){return null===e||e.nativeEvent!==i?(e={blockedOn:t,domEventName:n,eventSystemFlags:r,nativeEvent:i,targetContainers:[o]},null!==t&&(null!==(t=Co(t))&&Nt(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,null!==o&&-1===t.indexOf(o)&&t.push(o),e)}function $t(e){var t=Eo(e.target);if(null!==t){var n=Ke(t);if(null!==n)if(13===(t=n.tag)){if(null!==(t=Qe(n)))return e.blockedOn=t,void Lt(e.priority,function(){Ot(n)})}else if(3===t&&n.stateNode.current.memoizedState.isDehydrated)return void(e.blockedOn=3===n.tag?n.stateNode.containerInfo:null)}e.blockedOn=null}function Vt(e){if(null!==e.blockedOn)return!1;for(var t=e.targetContainers;0<t.length;){var n=en(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(null!==n)return null!==(t=Co(n))&&Nt(t),e.blockedOn=n,!1;var r=new(n=e.nativeEvent).constructor(n.type,n);we=r,n.target.dispatchEvent(r),we=null,t.shift()}return!0}function Ht(e,t,n){Vt(e)&&n.delete(t)}function qt(){_t=!1,null!==It&&Vt(It)&&(It=null),null!==At&&Vt(At)&&(At=null),null!==zt&&Vt(zt)&&(zt=null),jt.forEach(Ht),Dt.forEach(Ht)}function Wt(e,n){e.blockedOn===n&&(e.blockedOn=null,_t||(_t=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,qt)))}function Kt(e){function t(t){return Wt(t,e)}if(0<Rt.length){Wt(Rt[0],e);for(var n=1;n<Rt.length;n++){var r=Rt[n];r.blockedOn===e&&(r.blockedOn=null)}}for(null!==It&&Wt(It,e),null!==At&&Wt(At,e),null!==zt&&Wt(zt,e),jt.forEach(t),Dt.forEach(t),n=0;n<Ft.length;n++)(r=Ft[n]).blockedOn===e&&(r.blockedOn=null);for(;0<Ft.length&&null===(n=Ft[0]).blockedOn;)$t(n),null===n.blockedOn&&Ft.shift()}var Qt=w.ReactCurrentBatchConfig,Jt=!0;function Yt(e,t,n,r){var o=Et,i=Qt.transition;Qt.transition=null;try{Et=1,Xt(e,t,n,r)}finally{Et=o,Qt.transition=i}}function Gt(e,t,n,r){var o=Et,i=Qt.transition;Qt.transition=null;try{Et=4,Xt(e,t,n,r)}finally{Et=o,Qt.transition=i}}function Xt(e,t,n,r){if(Jt){var o=en(e,t,n,r);if(null===o)Jr(e,t,r,Zt,n),Ut(e,r);else if(function(e,t,n,r,o){switch(t){case"focusin":return It=Bt(It,e,t,n,r,o),!0;case"dragenter":return At=Bt(At,e,t,n,r,o),!0;case"mouseover":return zt=Bt(zt,e,t,n,r,o),!0;case"pointerover":var i=o.pointerId;return jt.set(i,Bt(jt.get(i)||null,e,t,n,r,o)),!0;case"gotpointercapture":return i=o.pointerId,Dt.set(i,Bt(Dt.get(i)||null,e,t,n,r,o)),!0}return!1}(o,e,t,n,r))r.stopPropagation();else if(Ut(e,r),4&t&&-1<Mt.indexOf(e)){for(;null!==o;){var i=Co(o);if(null!==i&&Tt(i),null===(i=en(e,t,n,r))&&Jr(e,t,r,Zt,n),i===o)break;o=i}null!==o&&r.stopPropagation()}else Jr(e,t,r,null,n)}}var Zt=null;function en(e,t,n,r){if(Zt=null,null!==(e=Eo(e=xe(r))))if(null===(t=Ke(e)))e=null;else if(13===(n=t.tag)){if(null!==(e=Qe(t)))return e;e=null}else if(3===n){if(t.stateNode.current.memoizedState.isDehydrated)return 3===t.tag?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null);return Zt=e,null}function tn(e){switch(e){case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 1;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"toggle":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 4;case"message":switch(rt()){case ot:return 1;case it:return 4;case at:case st:return 16;case lt:return 536870912;default:return 16}default:return 16}}var nn=null,rn=null,on=null;function an(){if(on)return on;var e,t,n=rn,r=n.length,o="value"in nn?nn.value:nn.textContent,i=o.length;for(e=0;e<r&&n[e]===o[e];e++);var a=r-e;for(t=1;t<=a&&n[r-t]===o[i-t];t++);return on=o.slice(e,1<t?1-t:void 0)}function sn(e){var t=e.keyCode;return"charCode"in e?0===(e=e.charCode)&&13===t&&(e=13):e=t,10===e&&(e=13),32<=e||13===e?e:0}function ln(){return!0}function un(){return!1}function cn(e){function t(t,n,r,o,i){for(var a in this._reactName=t,this._targetInst=r,this.type=n,this.nativeEvent=o,this.target=i,this.currentTarget=null,e)e.hasOwnProperty(a)&&(t=e[a],this[a]=t?t(o):o[a]);return this.isDefaultPrevented=(null!=o.defaultPrevented?o.defaultPrevented:!1===o.returnValue)?ln:un,this.isPropagationStopped=un,this}return F(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var e=this.nativeEvent;e&&(e.preventDefault?e.preventDefault():"unknown"!=typeof e.returnValue&&(e.returnValue=!1),this.isDefaultPrevented=ln)},stopPropagation:function(){var e=this.nativeEvent;e&&(e.stopPropagation?e.stopPropagation():"unknown"!=typeof e.cancelBubble&&(e.cancelBubble=!0),this.isPropagationStopped=ln)},persist:function(){},isPersistent:ln}),t}var dn,fn,pn,hn={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},gn=cn(hn),mn=F({},hn,{view:0,detail:0}),yn=cn(mn),vn=F({},mn,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Ln,button:0,buttons:0,relatedTarget:function(e){return void 0===e.relatedTarget?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return"movementX"in e?e.movementX:(e!==pn&&(pn&&"mousemove"===e.type?(dn=e.screenX-pn.screenX,fn=e.screenY-pn.screenY):fn=dn=0,pn=e),dn)},movementY:function(e){return"movementY"in e?e.movementY:fn}}),bn=cn(vn),kn=cn(F({},vn,{dataTransfer:0})),wn=cn(F({},mn,{relatedTarget:0})),xn=cn(F({},hn,{animationName:0,elapsedTime:0,pseudoElement:0})),Sn=F({},hn,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),En=cn(Sn),Cn=cn(F({},hn,{data:0})),Tn={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},Nn={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},On={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Pn(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):!!(e=On[e])&&!!t[e]}function Ln(){return Pn}var _n=F({},mn,{key:function(e){if(e.key){var t=Tn[e.key]||e.key;if("Unidentified"!==t)return t}return"keypress"===e.type?13===(e=sn(e))?"Enter":String.fromCharCode(e):"keydown"===e.type||"keyup"===e.type?Nn[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Ln,charCode:function(e){return"keypress"===e.type?sn(e):0},keyCode:function(e){return"keydown"===e.type||"keyup"===e.type?e.keyCode:0},which:function(e){return"keypress"===e.type?sn(e):"keydown"===e.type||"keyup"===e.type?e.keyCode:0}}),Rn=cn(_n),In=cn(F({},vn,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0})),An=cn(F({},mn,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Ln})),zn=cn(F({},hn,{propertyName:0,elapsedTime:0,pseudoElement:0})),jn=F({},vn,{deltaX:function(e){return"deltaX"in e?e.deltaX:"wheelDeltaX"in e?-e.wheelDeltaX:0},deltaY:function(e){return"deltaY"in e?e.deltaY:"wheelDeltaY"in e?-e.wheelDeltaY:"wheelDelta"in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0}),Dn=cn(jn),Fn=[9,13,27,32],Mn=l&&"CompositionEvent"in window,Un=null;l&&"documentMode"in document&&(Un=document.documentMode);var Bn=l&&"TextEvent"in window&&!Un,$n=l&&(!Mn||Un&&8<Un&&11>=Un),Vn=String.fromCharCode(32),Hn=!1;function qn(e,t){switch(e){case"keyup":return-1!==Fn.indexOf(t.keyCode);case"keydown":return 229!==t.keyCode;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Wn(e){return"object"==typeof(e=e.detail)&&"data"in e?e.data:null}var Kn=!1;var Qn={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function Jn(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return"input"===t?!!Qn[e.type]:"textarea"===t}function Yn(e,t,n,r){Ne(r),0<(t=Gr(t,"onChange")).length&&(n=new gn("onChange","change",null,n,r),e.push({event:n,listeners:t}))}var Gn=null,Xn=null;function Zn(e){Vr(e,0)}function er(e){if(Q(To(e)))return e}function tr(e,t){if("change"===e)return t}var nr=!1;if(l){var rr;if(l){var or="oninput"in document;if(!or){var ir=document.createElement("div");ir.setAttribute("oninput","return;"),or="function"==typeof ir.oninput}rr=or}else rr=!1;nr=rr&&(!document.documentMode||9<document.documentMode)}function ar(){Gn&&(Gn.detachEvent("onpropertychange",sr),Xn=Gn=null)}function sr(e){if("value"===e.propertyName&&er(Xn)){var t=[];Yn(t,Xn,e,xe(e)),Re(Zn,t)}}function lr(e,t,n){"focusin"===e?(ar(),Xn=n,(Gn=t).attachEvent("onpropertychange",sr)):"focusout"===e&&ar()}function ur(e){if("selectionchange"===e||"keyup"===e||"keydown"===e)return er(Xn)}function cr(e,t){if("click"===e)return er(t)}function dr(e,t){if("input"===e||"change"===e)return er(t)}var fr="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t};function pr(e,t){if(fr(e,t))return!0;if("object"!=typeof e||null===e||"object"!=typeof t||null===t)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(r=0;r<n.length;r++){var o=n[r];if(!u.call(t,o)||!fr(e[o],t[o]))return!1}return!0}function hr(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function gr(e,t){var n,r=hr(e);for(e=0;r;){if(3===r.nodeType){if(n=e+r.textContent.length,e<=t&&n>=t)return{node:r,offset:t-e};e=n}e:{for(;r;){if(r.nextSibling){r=r.nextSibling;break e}r=r.parentNode}r=void 0}r=hr(r)}}function mr(e,t){return!(!e||!t)&&(e===t||(!e||3!==e.nodeType)&&(t&&3===t.nodeType?mr(e,t.parentNode):"contains"in e?e.contains(t):!!e.compareDocumentPosition&&!!(16&e.compareDocumentPosition(t))))}function yr(){for(var e=window,t=J();t instanceof e.HTMLIFrameElement;){try{var n="string"==typeof t.contentWindow.location.href}catch(r){n=!1}if(!n)break;t=J((e=t.contentWindow).document)}return t}function vr(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&("input"===t&&("text"===e.type||"search"===e.type||"tel"===e.type||"url"===e.type||"password"===e.type)||"textarea"===t||"true"===e.contentEditable)}function br(e){var t=yr(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&mr(n.ownerDocument.documentElement,n)){if(null!==r&&vr(n))if(t=r.start,void 0===(e=r.end)&&(e=t),"selectionStart"in n)n.selectionStart=t,n.selectionEnd=Math.min(e,n.value.length);else if((e=(t=n.ownerDocument||document)&&t.defaultView||window).getSelection){e=e.getSelection();var o=n.textContent.length,i=Math.min(r.start,o);r=void 0===r.end?i:Math.min(r.end,o),!e.extend&&i>r&&(o=r,r=i,i=o),o=gr(n,i);var a=gr(n,r);o&&a&&(1!==e.rangeCount||e.anchorNode!==o.node||e.anchorOffset!==o.offset||e.focusNode!==a.node||e.focusOffset!==a.offset)&&((t=t.createRange()).setStart(o.node,o.offset),e.removeAllRanges(),i>r?(e.addRange(t),e.extend(a.node,a.offset)):(t.setEnd(a.node,a.offset),e.addRange(t)))}for(t=[],e=n;e=e.parentNode;)1===e.nodeType&&t.push({element:e,left:e.scrollLeft,top:e.scrollTop});for("function"==typeof n.focus&&n.focus(),n=0;n<t.length;n++)(e=t[n]).element.scrollLeft=e.left,e.element.scrollTop=e.top}}var kr=l&&"documentMode"in document&&11>=document.documentMode,wr=null,xr=null,Sr=null,Er=!1;function Cr(e,t,n){var r=n.window===n?n.document:9===n.nodeType?n:n.ownerDocument;Er||null==wr||wr!==J(r)||("selectionStart"in(r=wr)&&vr(r)?r={start:r.selectionStart,end:r.selectionEnd}:r={anchorNode:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection()).anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset},Sr&&pr(Sr,r)||(Sr=r,0<(r=Gr(xr,"onSelect")).length&&(t=new gn("onSelect","select",null,t,n),e.push({event:t,listeners:r}),t.target=wr)))}function Tr(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit"+e]="webkit"+t,n["Moz"+e]="moz"+t,n}var Nr={animationend:Tr("Animation","AnimationEnd"),animationiteration:Tr("Animation","AnimationIteration"),animationstart:Tr("Animation","AnimationStart"),transitionend:Tr("Transition","TransitionEnd")},Or={},Pr={};function Lr(e){if(Or[e])return Or[e];if(!Nr[e])return e;var t,n=Nr[e];for(t in n)if(n.hasOwnProperty(t)&&t in Pr)return Or[e]=n[t];return e}l&&(Pr=document.createElement("div").style,"AnimationEvent"in window||(delete Nr.animationend.animation,delete Nr.animationiteration.animation,delete Nr.animationstart.animation),"TransitionEvent"in window||delete Nr.transitionend.transition);var _r=Lr("animationend"),Rr=Lr("animationiteration"),Ir=Lr("animationstart"),Ar=Lr("transitionend"),zr=new Map,jr="abort auxClick cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");function Dr(e,t){zr.set(e,t),i(t,[e])}for(var Fr=0;Fr<jr.length;Fr++){var Mr=jr[Fr];Dr(Mr.toLowerCase(),"on"+(Mr[0].toUpperCase()+Mr.slice(1)))}Dr(_r,"onAnimationEnd"),Dr(Rr,"onAnimationIteration"),Dr(Ir,"onAnimationStart"),Dr("dblclick","onDoubleClick"),Dr("focusin","onFocus"),Dr("focusout","onBlur"),Dr(Ar,"onTransitionEnd"),a("onMouseEnter",["mouseout","mouseover"]),a("onMouseLeave",["mouseout","mouseover"]),a("onPointerEnter",["pointerout","pointerover"]),a("onPointerLeave",["pointerout","pointerover"]),i("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),i("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),i("onBeforeInput",["compositionend","keypress","textInput","paste"]),i("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),i("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),i("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Ur="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),Br=new Set("cancel close invalid load scroll toggle".split(" ").concat(Ur));function $r(e,t,r){var o=e.type||"unknown-event";e.currentTarget=r,function(e,t,r,o,i,a,s,l,u){if(We.apply(this,arguments),Be){if(!Be)throw Error(n(198));var c=$e;Be=!1,$e=null,Ve||(Ve=!0,He=c)}}(o,t,void 0,e),e.currentTarget=null}function Vr(e,t){t=!!(4&t);for(var n=0;n<e.length;n++){var r=e[n],o=r.event;r=r.listeners;e:{var i=void 0;if(t)for(var a=r.length-1;0<=a;a--){var s=r[a],l=s.instance,u=s.currentTarget;if(s=s.listener,l!==i&&o.isPropagationStopped())break e;$r(o,s,u),i=l}else for(a=0;a<r.length;a++){if(l=(s=r[a]).instance,u=s.currentTarget,s=s.listener,l!==i&&o.isPropagationStopped())break e;$r(o,s,u),i=l}}}if(Ve)throw e=He,Ve=!1,He=null,e}function Hr(e,t){var n=t[wo];void 0===n&&(n=t[wo]=new Set);var r=e+"__bubble";n.has(r)||(Qr(t,e,2,!1),n.add(r))}function qr(e,t,n){var r=0;t&&(r|=4),Qr(n,e,r,t)}var Wr="_reactListening"+Math.random().toString(36).slice(2);function Kr(e){if(!e[Wr]){e[Wr]=!0,r.forEach(function(t){"selectionchange"!==t&&(Br.has(t)||qr(t,!1,e),qr(t,!0,e))});var t=9===e.nodeType?e:e.ownerDocument;null===t||t[Wr]||(t[Wr]=!0,qr("selectionchange",!1,t))}}function Qr(e,t,n,r){switch(tn(t)){case 1:var o=Yt;break;case 4:o=Gt;break;default:o=Xt}n=o.bind(null,t,n,e),o=void 0,!Fe||"touchstart"!==t&&"touchmove"!==t&&"wheel"!==t||(o=!0),r?void 0!==o?e.addEventListener(t,n,{capture:!0,passive:o}):e.addEventListener(t,n,!0):void 0!==o?e.addEventListener(t,n,{passive:o}):e.addEventListener(t,n,!1)}function Jr(e,t,n,r,o){var i=r;if(!(1&t||2&t||null===r))e:for(;;){if(null===r)return;var a=r.tag;if(3===a||4===a){var s=r.stateNode.containerInfo;if(s===o||8===s.nodeType&&s.parentNode===o)break;if(4===a)for(a=r.return;null!==a;){var l=a.tag;if((3===l||4===l)&&((l=a.stateNode.containerInfo)===o||8===l.nodeType&&l.parentNode===o))return;a=a.return}for(;null!==s;){if(null===(a=Eo(s)))return;if(5===(l=a.tag)||6===l){r=i=a;continue e}s=s.parentNode}}r=r.return}Re(function(){var r=i,o=xe(n),a=[];e:{var s=zr.get(e);if(void 0!==s){var l=gn,u=e;switch(e){case"keypress":if(0===sn(n))break e;case"keydown":case"keyup":l=Rn;break;case"focusin":u="focus",l=wn;break;case"focusout":u="blur",l=wn;break;case"beforeblur":case"afterblur":l=wn;break;case"click":if(2===n.button)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":l=bn;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":l=kn;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":l=An;break;case _r:case Rr:case Ir:l=xn;break;case Ar:l=zn;break;case"scroll":l=yn;break;case"wheel":l=Dn;break;case"copy":case"cut":case"paste":l=En;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":l=In}var c=!!(4&t),d=!c&&"scroll"===e,f=c?null!==s?s+"Capture":null:s;c=[];for(var p,h=r;null!==h;){var g=(p=h).stateNode;if(5===p.tag&&null!==g&&(p=g,null!==f&&(null!=(g=De(h,f))&&c.push(Yr(h,g,p)))),d)break;h=h.return}0<c.length&&(s=new l(s,u,null,n,o),a.push({event:s,listeners:c}))}}if(!(7&t)){if(l="mouseout"===e||"pointerout"===e,(!(s="mouseover"===e||"pointerover"===e)||n===we||!(u=n.relatedTarget||n.fromElement)||!Eo(u)&&!u[ko])&&(l||s)&&(s=o.window===o?o:(s=o.ownerDocument)?s.defaultView||s.parentWindow:window,l?(l=r,null!==(u=(u=n.relatedTarget||n.toElement)?Eo(u):null)&&(u!==(d=Ke(u))||5!==u.tag&&6!==u.tag)&&(u=null)):(l=null,u=r),l!==u)){if(c=bn,g="onMouseLeave",f="onMouseEnter",h="mouse","pointerout"!==e&&"pointerover"!==e||(c=In,g="onPointerLeave",f="onPointerEnter",h="pointer"),d=null==l?s:To(l),p=null==u?s:To(u),(s=new c(g,h+"leave",l,n,o)).target=d,s.relatedTarget=p,g=null,Eo(o)===r&&((c=new c(f,h+"enter",u,n,o)).target=p,c.relatedTarget=d,g=c),d=g,l&&u)e:{for(f=u,h=0,p=c=l;p;p=Xr(p))h++;for(p=0,g=f;g;g=Xr(g))p++;for(;0<h-p;)c=Xr(c),h--;for(;0<p-h;)f=Xr(f),p--;for(;h--;){if(c===f||null!==f&&c===f.alternate)break e;c=Xr(c),f=Xr(f)}c=null}else c=null;null!==l&&Zr(a,s,l,c,!1),null!==u&&null!==d&&Zr(a,d,u,c,!0)}if("select"===(l=(s=r?To(r):window).nodeName&&s.nodeName.toLowerCase())||"input"===l&&"file"===s.type)var m=tr;else if(Jn(s))if(nr)m=dr;else{m=ur;var y=lr}else(l=s.nodeName)&&"input"===l.toLowerCase()&&("checkbox"===s.type||"radio"===s.type)&&(m=cr);switch(m&&(m=m(e,r))?Yn(a,m,n,o):(y&&y(e,s,r),"focusout"===e&&(y=s._wrapperState)&&y.controlled&&"number"===s.type&&te(s,"number",s.value)),y=r?To(r):window,e){case"focusin":(Jn(y)||"true"===y.contentEditable)&&(wr=y,xr=r,Sr=null);break;case"focusout":Sr=xr=wr=null;break;case"mousedown":Er=!0;break;case"contextmenu":case"mouseup":case"dragend":Er=!1,Cr(a,n,o);break;case"selectionchange":if(kr)break;case"keydown":case"keyup":Cr(a,n,o)}var v;if(Mn)e:{switch(e){case"compositionstart":var b="onCompositionStart";break e;case"compositionend":b="onCompositionEnd";break e;case"compositionupdate":b="onCompositionUpdate";break e}b=void 0}else Kn?qn(e,n)&&(b="onCompositionEnd"):"keydown"===e&&229===n.keyCode&&(b="onCompositionStart");b&&($n&&"ko"!==n.locale&&(Kn||"onCompositionStart"!==b?"onCompositionEnd"===b&&Kn&&(v=an()):(rn="value"in(nn=o)?nn.value:nn.textContent,Kn=!0)),0<(y=Gr(r,b)).length&&(b=new Cn(b,e,null,n,o),a.push({event:b,listeners:y}),v?b.data=v:null!==(v=Wn(n))&&(b.data=v))),(v=Bn?function(e,t){switch(e){case"compositionend":return Wn(t);case"keypress":return 32!==t.which?null:(Hn=!0,Vn);case"textInput":return(e=t.data)===Vn&&Hn?null:e;default:return null}}(e,n):function(e,t){if(Kn)return"compositionend"===e||!Mn&&qn(e,t)?(e=an(),on=rn=nn=null,Kn=!1,e):null;switch(e){case"paste":default:return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case"compositionend":return $n&&"ko"!==t.locale?null:t.data}}(e,n))&&(0<(r=Gr(r,"onBeforeInput")).length&&(o=new Cn("onBeforeInput","beforeinput",null,n,o),a.push({event:o,listeners:r}),o.data=v))}Vr(a,t)})}function Yr(e,t,n){return{instance:e,listener:t,currentTarget:n}}function Gr(e,t){for(var n=t+"Capture",r=[];null!==e;){var o=e,i=o.stateNode;5===o.tag&&null!==i&&(o=i,null!=(i=De(e,n))&&r.unshift(Yr(e,i,o)),null!=(i=De(e,t))&&r.push(Yr(e,i,o))),e=e.return}return r}function Xr(e){if(null===e)return null;do{e=e.return}while(e&&5!==e.tag);return e||null}function Zr(e,t,n,r,o){for(var i=t._reactName,a=[];null!==n&&n!==r;){var s=n,l=s.alternate,u=s.stateNode;if(null!==l&&l===r)break;5===s.tag&&null!==u&&(s=u,o?null!=(l=De(n,i))&&a.unshift(Yr(n,l,s)):o||null!=(l=De(n,i))&&a.push(Yr(n,l,s))),n=n.return}0!==a.length&&e.push({event:t,listeners:a})}var eo=/\r\n?/g,to=/\u0000|\uFFFD/g;function no(e){return("string"==typeof e?e:""+e).replace(eo,"\n").replace(to,"")}function ro(e,t,r){if(t=no(t),no(e)!==t&&r)throw Error(n(425))}function oo(){}var io=null,ao=null;function so(e,t){return"textarea"===e||"noscript"===e||"string"==typeof t.children||"number"==typeof t.children||"object"==typeof t.dangerouslySetInnerHTML&&null!==t.dangerouslySetInnerHTML&&null!=t.dangerouslySetInnerHTML.__html}var lo="function"==typeof setTimeout?setTimeout:void 0,uo="function"==typeof clearTimeout?clearTimeout:void 0,co="function"==typeof Promise?Promise:void 0,fo="function"==typeof queueMicrotask?queueMicrotask:void 0!==co?function(e){return co.resolve(null).then(e).catch(po)}:lo;function po(e){setTimeout(function(){throw e})}function ho(e,t){var n=t,r=0;do{var o=n.nextSibling;if(e.removeChild(n),o&&8===o.nodeType)if("/$"===(n=o.data)){if(0===r)return e.removeChild(o),void Kt(t);r--}else"$"!==n&&"$?"!==n&&"$!"!==n||r++;n=o}while(n);Kt(t)}function go(e){for(;null!=e;e=e.nextSibling){var t=e.nodeType;if(1===t||3===t)break;if(8===t){if("$"===(t=e.data)||"$!"===t||"$?"===t)break;if("/$"===t)return null}}return e}function mo(e){e=e.previousSibling;for(var t=0;e;){if(8===e.nodeType){var n=e.data;if("$"===n||"$!"===n||"$?"===n){if(0===t)return e;t--}else"/$"===n&&t++}e=e.previousSibling}return null}var yo=Math.random().toString(36).slice(2),vo="__reactFiber$"+yo,bo="__reactProps$"+yo,ko="__reactContainer$"+yo,wo="__reactEvents$"+yo,xo="__reactListeners$"+yo,So="__reactHandles$"+yo;function Eo(e){var t=e[vo];if(t)return t;for(var n=e.parentNode;n;){if(t=n[ko]||n[vo]){if(n=t.alternate,null!==t.child||null!==n&&null!==n.child)for(e=mo(e);null!==e;){if(n=e[vo])return n;e=mo(e)}return t}n=(e=n).parentNode}return null}function Co(e){return!(e=e[vo]||e[ko])||5!==e.tag&&6!==e.tag&&13!==e.tag&&3!==e.tag?null:e}function To(e){if(5===e.tag||6===e.tag)return e.stateNode;throw Error(n(33))}function No(e){return e[bo]||null}var Oo=[],Po=-1;function Lo(e){return{current:e}}function _o(e){0>Po||(e.current=Oo[Po],Oo[Po]=null,Po--)}function Ro(e,t){Po++,Oo[Po]=e.current,e.current=t}var Io={},Ao=Lo(Io),zo=Lo(!1),jo=Io;function Do(e,t){var n=e.type.contextTypes;if(!n)return Io;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var o,i={};for(o in n)i[o]=t[o];return r&&((e=e.stateNode).__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=i),i}function Fo(e){return null!=(e=e.childContextTypes)}function Mo(){_o(zo),_o(Ao)}function Uo(e,t,r){if(Ao.current!==Io)throw Error(n(168));Ro(Ao,t),Ro(zo,r)}function Bo(e,t,r){var o=e.stateNode;if(t=t.childContextTypes,"function"!=typeof o.getChildContext)return r;for(var i in o=o.getChildContext())if(!(i in t))throw Error(n(108,H(e)||"Unknown",i));return F({},r,o)}function $o(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||Io,jo=Ao.current,Ro(Ao,e),Ro(zo,zo.current),!0}function Vo(e,t,r){var o=e.stateNode;if(!o)throw Error(n(169));r?(e=Bo(e,t,jo),o.__reactInternalMemoizedMergedChildContext=e,_o(zo),_o(Ao),Ro(Ao,e)):_o(zo),Ro(zo,r)}var Ho=null,qo=!1,Wo=!1;function Ko(e){null===Ho?Ho=[e]:Ho.push(e)}function Qo(){if(!Wo&&null!==Ho){Wo=!0;var e=0,t=Et;try{var n=Ho;for(Et=1;e<n.length;e++){var r=n[e];do{r=r(!0)}while(null!==r)}Ho=null,qo=!1}catch(Ie){throw null!==Ho&&(Ho=Ho.slice(e+1)),Xe(ot,Qo),Ie}finally{Et=t,Wo=!1}}return null}var Jo=[],Yo=0,Go=null,Xo=0,Zo=[],ei=0,ti=null,ni=1,ri="";function oi(e,t){Jo[Yo++]=Xo,Jo[Yo++]=Go,Go=e,Xo=t}function ii(e,t,n){Zo[ei++]=ni,Zo[ei++]=ri,Zo[ei++]=ti,ti=e;var r=ni;e=ri;var o=32-dt(r)-1;r&=~(1<<o),n+=1;var i=32-dt(t)+o;if(30<i){var a=o-o%5;i=(r&(1<<a)-1).toString(32),r>>=a,o-=a,ni=1<<32-dt(t)+o|n<<o|r,ri=i+e}else ni=1<<i|n<<o|r,ri=e}function ai(e){null!==e.return&&(oi(e,1),ii(e,1,0))}function si(e){for(;e===Go;)Go=Jo[--Yo],Jo[Yo]=null,Xo=Jo[--Yo],Jo[Yo]=null;for(;e===ti;)ti=Zo[--ei],Zo[ei]=null,ri=Zo[--ei],Zo[ei]=null,ni=Zo[--ei],Zo[ei]=null}var li=null,ui=null,ci=!1,di=null;function fi(e,t){var n=zu(5,null,null,0);n.elementType="DELETED",n.stateNode=t,n.return=e,null===(t=e.deletions)?(e.deletions=[n],e.flags|=16):t.push(n)}function pi(e,t){switch(e.tag){case 5:var n=e.type;return null!==(t=1!==t.nodeType||n.toLowerCase()!==t.nodeName.toLowerCase()?null:t)&&(e.stateNode=t,li=e,ui=go(t.firstChild),!0);case 6:return null!==(t=""===e.pendingProps||3!==t.nodeType?null:t)&&(e.stateNode=t,li=e,ui=null,!0);case 13:return null!==(t=8!==t.nodeType?null:t)&&(n=null!==ti?{id:ni,overflow:ri}:null,e.memoizedState={dehydrated:t,treeContext:n,retryLane:1073741824},(n=zu(18,null,null,0)).stateNode=t,n.return=e,e.child=n,li=e,ui=null,!0);default:return!1}}function hi(e){return!(!(1&e.mode)||128&e.flags)}function gi(e){if(ci){var t=ui;if(t){var r=t;if(!pi(e,t)){if(hi(e))throw Error(n(418));t=go(r.nextSibling);var o=li;t&&pi(e,t)?fi(o,r):(e.flags=-4097&e.flags|2,ci=!1,li=e)}}else{if(hi(e))throw Error(n(418));e.flags=-4097&e.flags|2,ci=!1,li=e}}}function mi(e){for(e=e.return;null!==e&&5!==e.tag&&3!==e.tag&&13!==e.tag;)e=e.return;li=e}function yi(e){if(e!==li)return!1;if(!ci)return mi(e),ci=!0,!1;var t;if((t=3!==e.tag)&&!(t=5!==e.tag)&&(t="head"!==(t=e.type)&&"body"!==t&&!so(e.type,e.memoizedProps)),t&&(t=ui)){if(hi(e))throw vi(),Error(n(418));for(;t;)fi(e,t),t=go(t.nextSibling)}if(mi(e),13===e.tag){if(!(e=null!==(e=e.memoizedState)?e.dehydrated:null))throw Error(n(317));e:{for(e=e.nextSibling,t=0;e;){if(8===e.nodeType){var r=e.data;if("/$"===r){if(0===t){ui=go(e.nextSibling);break e}t--}else"$"!==r&&"$!"!==r&&"$?"!==r||t++}e=e.nextSibling}ui=null}}else ui=li?go(e.stateNode.nextSibling):null;return!0}function vi(){for(var e=ui;e;)e=go(e.nextSibling)}function bi(){ui=li=null,ci=!1}function ki(e){null===di?di=[e]:di.push(e)}var wi=w.ReactCurrentBatchConfig;function xi(e,t,r){if(null!==(e=r.ref)&&"function"!=typeof e&&"object"!=typeof e){if(r._owner){if(r=r._owner){if(1!==r.tag)throw Error(n(309));var o=r.stateNode}if(!o)throw Error(n(147,e));var i=o,a=""+e;return null!==t&&null!==t.ref&&"function"==typeof t.ref&&t.ref._stringRef===a?t.ref:((t=function(e){var t=i.refs;null===e?delete t[a]:t[a]=e})._stringRef=a,t)}if("string"!=typeof e)throw Error(n(284));if(!r._owner)throw Error(n(290,e))}return e}function Si(e,t){throw e=Object.prototype.toString.call(t),Error(n(31,"[object Object]"===e?"object with keys {"+Object.keys(t).join(", ")+"}":e))}function Ei(e){return(0,e._init)(e._payload)}function Ci(e){function t(t,n){if(e){var r=t.deletions;null===r?(t.deletions=[n],t.flags|=16):r.push(n)}}function r(n,r){if(!e)return null;for(;null!==r;)t(n,r),r=r.sibling;return null}function o(e,t){for(e=new Map;null!==t;)null!==t.key?e.set(t.key,t):e.set(t.index,t),t=t.sibling;return e}function i(e,t){return(e=Du(e,t)).index=0,e.sibling=null,e}function a(t,n,r){return t.index=r,e?null!==(r=t.alternate)?(r=r.index)<n?(t.flags|=2,n):r:(t.flags|=2,n):(t.flags|=1048576,n)}function s(t){return e&&null===t.alternate&&(t.flags|=2),t}function l(e,t,n,r){return null===t||6!==t.tag?((t=Bu(n,e.mode,r)).return=e,t):((t=i(t,n)).return=e,t)}function u(e,t,n,r){var o=n.type;return o===E?d(e,t,n.props.children,r,n.key):null!==t&&(t.elementType===o||"object"==typeof o&&null!==o&&o.$$typeof===I&&Ei(o)===t.type)?((r=i(t,n.props)).ref=xi(e,t,n),r.return=e,r):((r=Fu(n.type,n.key,n.props,null,e.mode,r)).ref=xi(e,t,n),r.return=e,r)}function c(e,t,n,r){return null===t||4!==t.tag||t.stateNode.containerInfo!==n.containerInfo||t.stateNode.implementation!==n.implementation?((t=$u(n,e.mode,r)).return=e,t):((t=i(t,n.children||[])).return=e,t)}function d(e,t,n,r,o){return null===t||7!==t.tag?((t=Mu(n,e.mode,r,o)).return=e,t):((t=i(t,n)).return=e,t)}function f(e,t,n){if("string"==typeof t&&""!==t||"number"==typeof t)return(t=Bu(""+t,e.mode,n)).return=e,t;if("object"==typeof t&&null!==t){switch(t.$$typeof){case x:return(n=Fu(t.type,t.key,t.props,null,e.mode,n)).ref=xi(e,null,t),n.return=e,n;case S:return(t=$u(t,e.mode,n)).return=e,t;case I:return f(e,(0,t._init)(t._payload),n)}if(ne(t)||j(t))return(t=Mu(t,e.mode,n,null)).return=e,t;Si(e,t)}return null}function p(e,t,n,r){var o=null!==t?t.key:null;if("string"==typeof n&&""!==n||"number"==typeof n)return null!==o?null:l(e,t,""+n,r);if("object"==typeof n&&null!==n){switch(n.$$typeof){case x:return n.key===o?u(e,t,n,r):null;case S:return n.key===o?c(e,t,n,r):null;case I:return p(e,t,(o=n._init)(n._payload),r)}if(ne(n)||j(n))return null!==o?null:d(e,t,n,r,null);Si(e,n)}return null}function h(e,t,n,r,o){if("string"==typeof r&&""!==r||"number"==typeof r)return l(t,e=e.get(n)||null,""+r,o);if("object"==typeof r&&null!==r){switch(r.$$typeof){case x:return u(t,e=e.get(null===r.key?n:r.key)||null,r,o);case S:return c(t,e=e.get(null===r.key?n:r.key)||null,r,o);case I:return h(e,t,n,(0,r._init)(r._payload),o)}if(ne(r)||j(r))return d(t,e=e.get(n)||null,r,o,null);Si(t,r)}return null}return function l(u,c,d,g){if("object"==typeof d&&null!==d&&d.type===E&&null===d.key&&(d=d.props.children),"object"==typeof d&&null!==d){switch(d.$$typeof){case x:e:{for(var m=d.key,y=c;null!==y;){if(y.key===m){if((m=d.type)===E){if(7===y.tag){r(u,y.sibling),(c=i(y,d.props.children)).return=u,u=c;break e}}else if(y.elementType===m||"object"==typeof m&&null!==m&&m.$$typeof===I&&Ei(m)===y.type){r(u,y.sibling),(c=i(y,d.props)).ref=xi(u,y,d),c.return=u,u=c;break e}r(u,y);break}t(u,y),y=y.sibling}d.type===E?((c=Mu(d.props.children,u.mode,g,d.key)).return=u,u=c):((g=Fu(d.type,d.key,d.props,null,u.mode,g)).ref=xi(u,c,d),g.return=u,u=g)}return s(u);case S:e:{for(y=d.key;null!==c;){if(c.key===y){if(4===c.tag&&c.stateNode.containerInfo===d.containerInfo&&c.stateNode.implementation===d.implementation){r(u,c.sibling),(c=i(c,d.children||[])).return=u,u=c;break e}r(u,c);break}t(u,c),c=c.sibling}(c=$u(d,u.mode,g)).return=u,u=c}return s(u);case I:return l(u,c,(y=d._init)(d._payload),g)}if(ne(d))return function(n,i,s,l){for(var u=null,c=null,d=i,g=i=0,m=null;null!==d&&g<s.length;g++){d.index>g?(m=d,d=null):m=d.sibling;var y=p(n,d,s[g],l);if(null===y){null===d&&(d=m);break}e&&d&&null===y.alternate&&t(n,d),i=a(y,i,g),null===c?u=y:c.sibling=y,c=y,d=m}if(g===s.length)return r(n,d),ci&&oi(n,g),u;if(null===d){for(;g<s.length;g++)null!==(d=f(n,s[g],l))&&(i=a(d,i,g),null===c?u=d:c.sibling=d,c=d);return ci&&oi(n,g),u}for(d=o(n,d);g<s.length;g++)null!==(m=h(d,n,g,s[g],l))&&(e&&null!==m.alternate&&d.delete(null===m.key?g:m.key),i=a(m,i,g),null===c?u=m:c.sibling=m,c=m);return e&&d.forEach(function(e){return t(n,e)}),ci&&oi(n,g),u}(u,c,d,g);if(j(d))return function(i,s,l,u){var c=j(l);if("function"!=typeof c)throw Error(n(150));if(null==(l=c.call(l)))throw Error(n(151));for(var d=c=null,g=s,m=s=0,y=null,v=l.next();null!==g&&!v.done;m++,v=l.next()){g.index>m?(y=g,g=null):y=g.sibling;var b=p(i,g,v.value,u);if(null===b){null===g&&(g=y);break}e&&g&&null===b.alternate&&t(i,g),s=a(b,s,m),null===d?c=b:d.sibling=b,d=b,g=y}if(v.done)return r(i,g),ci&&oi(i,m),c;if(null===g){for(;!v.done;m++,v=l.next())null!==(v=f(i,v.value,u))&&(s=a(v,s,m),null===d?c=v:d.sibling=v,d=v);return ci&&oi(i,m),c}for(g=o(i,g);!v.done;m++,v=l.next())null!==(v=h(g,i,m,v.value,u))&&(e&&null!==v.alternate&&g.delete(null===v.key?m:v.key),s=a(v,s,m),null===d?c=v:d.sibling=v,d=v);return e&&g.forEach(function(e){return t(i,e)}),ci&&oi(i,m),c}(u,c,d,g);Si(u,d)}return"string"==typeof d&&""!==d||"number"==typeof d?(d=""+d,null!==c&&6===c.tag?(r(u,c.sibling),(c=i(c,d)).return=u,u=c):(r(u,c),(c=Bu(d,u.mode,g)).return=u,u=c),s(u)):r(u,c)}}var Ti=Ci(!0),Ni=Ci(!1),Oi=Lo(null),Pi=null,Li=null,_i=null;function Ri(){_i=Li=Pi=null}function Ii(e){var t=Oi.current;_o(Oi),e._currentValue=t}function Ai(e,t,n){for(;null!==e;){var r=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,null!==r&&(r.childLanes|=t)):null!==r&&(r.childLanes&t)!==t&&(r.childLanes|=t),e===n)break;e=e.return}}function zi(e,t){Pi=e,_i=Li=null,null!==(e=e.dependencies)&&null!==e.firstContext&&(0!==(e.lanes&t)&&(Ss=!0),e.firstContext=null)}function ji(e){var t=e._currentValue;if(_i!==e)if(e={context:e,memoizedValue:t,next:null},null===Li){if(null===Pi)throw Error(n(308));Li=e,Pi.dependencies={lanes:0,firstContext:e}}else Li=Li.next=e;return t}var Di=null;function Fi(e){null===Di?Di=[e]:Di.push(e)}function Mi(e,t,n,r){var o=t.interleaved;return null===o?(n.next=n,Fi(t)):(n.next=o.next,o.next=n),t.interleaved=n,Ui(e,r)}function Ui(e,t){e.lanes|=t;var n=e.alternate;for(null!==n&&(n.lanes|=t),n=e,e=e.return;null!==e;)e.childLanes|=t,null!==(n=e.alternate)&&(n.childLanes|=t),n=e,e=e.return;return 3===n.tag?n.stateNode:null}var Bi=!1;function $i(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function Vi(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,effects:e.effects})}function Hi(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function qi(e,t,n){var r=e.updateQueue;if(null===r)return null;if(r=r.shared,2&Rl){var o=r.pending;return null===o?t.next=t:(t.next=o.next,o.next=t),r.pending=t,Ui(e,n)}return null===(o=r.interleaved)?(t.next=t,Fi(r)):(t.next=o.next,o.next=t),r.interleaved=t,Ui(e,n)}function Wi(e,t,n){if(null!==(t=t.updateQueue)&&(t=t.shared,4194240&n)){var r=t.lanes;n|=r&=e.pendingLanes,t.lanes=n,St(e,n)}}function Ki(e,t){var n=e.updateQueue,r=e.alternate;if(null!==r&&n===(r=r.updateQueue)){var o=null,i=null;if(null!==(n=n.firstBaseUpdate)){do{var a={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};null===i?o=i=a:i=i.next=a,n=n.next}while(null!==n);null===i?o=i=t:i=i.next=t}else o=i=t;return n={baseState:r.baseState,firstBaseUpdate:o,lastBaseUpdate:i,shared:r.shared,effects:r.effects},void(e.updateQueue=n)}null===(e=n.lastBaseUpdate)?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}function Qi(e,t,n,r){var o=e.updateQueue;Bi=!1;var i=o.firstBaseUpdate,a=o.lastBaseUpdate,s=o.shared.pending;if(null!==s){o.shared.pending=null;var l=s,u=l.next;l.next=null,null===a?i=u:a.next=u,a=l;var c=e.alternate;null!==c&&((s=(c=c.updateQueue).lastBaseUpdate)!==a&&(null===s?c.firstBaseUpdate=u:s.next=u,c.lastBaseUpdate=l))}if(null!==i){var d=o.baseState;for(a=0,c=u=l=null,s=i;;){var f=s.lane,p=s.eventTime;if((r&f)===f){null!==c&&(c=c.next={eventTime:p,lane:0,tag:s.tag,payload:s.payload,callback:s.callback,next:null});e:{var h=e,g=s;switch(f=t,p=n,g.tag){case 1:if("function"==typeof(h=g.payload)){d=h.call(p,d,f);break e}d=h;break e;case 3:h.flags=-65537&h.flags|128;case 0:if(null==(f="function"==typeof(h=g.payload)?h.call(p,d,f):h))break e;d=F({},d,f);break e;case 2:Bi=!0}}null!==s.callback&&0!==s.lane&&(e.flags|=64,null===(f=o.effects)?o.effects=[s]:f.push(s))}else p={eventTime:p,lane:f,tag:s.tag,payload:s.payload,callback:s.callback,next:null},null===c?(u=c=p,l=d):c=c.next=p,a|=f;if(null===(s=s.next)){if(null===(s=o.shared.pending))break;s=(f=s).next,f.next=null,o.lastBaseUpdate=f,o.shared.pending=null}}if(null===c&&(l=d),o.baseState=l,o.firstBaseUpdate=u,o.lastBaseUpdate=c,null!==(t=o.shared.interleaved)){o=t;do{a|=o.lane,o=o.next}while(o!==t)}else null===i&&(o.shared.lanes=0);Ul|=a,e.lanes=a,e.memoizedState=d}}function Ji(e,t,r){if(e=t.effects,t.effects=null,null!==e)for(t=0;t<e.length;t++){var o=e[t],i=o.callback;if(null!==i){if(o.callback=null,o=r,"function"!=typeof i)throw Error(n(191,i));i.call(o)}}}var Yi={},Gi=Lo(Yi),Xi=Lo(Yi),Zi=Lo(Yi);function ea(e){if(e===Yi)throw Error(n(174));return e}function ta(e,t){switch(Ro(Zi,t),Ro(Xi,e),Ro(Gi,Yi),e=t.nodeType){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:ue(null,"");break;default:t=ue(t=(e=8===e?t.parentNode:t).namespaceURI||null,e=e.tagName)}_o(Gi),Ro(Gi,t)}function na(){_o(Gi),_o(Xi),_o(Zi)}function ra(e){ea(Zi.current);var t=ea(Gi.current),n=ue(t,e.type);t!==n&&(Ro(Xi,e),Ro(Gi,n))}function oa(e){Xi.current===e&&(_o(Gi),_o(Xi))}var ia=Lo(0);function aa(e){for(var t=e;null!==t;){if(13===t.tag){var n=t.memoizedState;if(null!==n&&(null===(n=n.dehydrated)||"$?"===n.data||"$!"===n.data))return t}else if(19===t.tag&&void 0!==t.memoizedProps.revealOrder){if(128&t.flags)return t}else if(null!==t.child){t.child.return=t,t=t.child;continue}if(t===e)break;for(;null===t.sibling;){if(null===t.return||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var sa=[];function la(){for(var e=0;e<sa.length;e++)sa[e]._workInProgressVersionPrimary=null;sa.length=0}var ua=w.ReactCurrentDispatcher,ca=w.ReactCurrentBatchConfig,da=0,fa=null,pa=null,ha=null,ga=!1,ma=!1,ya=0,va=0;function ba(){throw Error(n(321))}function ka(e,t){if(null===t)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!fr(e[n],t[n]))return!1;return!0}function wa(e,t,r,o,i,a){if(da=a,fa=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,ua.current=null===e||null===e.memoizedState?os:is,e=r(o,i),ma){a=0;do{if(ma=!1,ya=0,25<=a)throw Error(n(301));a+=1,ha=pa=null,t.updateQueue=null,ua.current=as,e=r(o,i)}while(ma)}if(ua.current=rs,t=null!==pa&&null!==pa.next,da=0,ha=pa=fa=null,ga=!1,t)throw Error(n(300));return e}function xa(){var e=0!==ya;return ya=0,e}function Sa(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return null===ha?fa.memoizedState=ha=e:ha=ha.next=e,ha}function Ea(){if(null===pa){var e=fa.alternate;e=null!==e?e.memoizedState:null}else e=pa.next;var t=null===ha?fa.memoizedState:ha.next;if(null!==t)ha=t,pa=e;else{if(null===e)throw Error(n(310));e={memoizedState:(pa=e).memoizedState,baseState:pa.baseState,baseQueue:pa.baseQueue,queue:pa.queue,next:null},null===ha?fa.memoizedState=ha=e:ha=ha.next=e}return ha}function Ca(e,t){return"function"==typeof t?t(e):t}function Ta(e){var t=Ea(),r=t.queue;if(null===r)throw Error(n(311));r.lastRenderedReducer=e;var o=pa,i=o.baseQueue,a=r.pending;if(null!==a){if(null!==i){var s=i.next;i.next=a.next,a.next=s}o.baseQueue=i=a,r.pending=null}if(null!==i){a=i.next,o=o.baseState;var l=s=null,u=null,c=a;do{var d=c.lane;if((da&d)===d)null!==u&&(u=u.next={lane:0,action:c.action,hasEagerState:c.hasEagerState,eagerState:c.eagerState,next:null}),o=c.hasEagerState?c.eagerState:e(o,c.action);else{var f={lane:d,action:c.action,hasEagerState:c.hasEagerState,eagerState:c.eagerState,next:null};null===u?(l=u=f,s=o):u=u.next=f,fa.lanes|=d,Ul|=d}c=c.next}while(null!==c&&c!==a);null===u?s=o:u.next=l,fr(o,t.memoizedState)||(Ss=!0),t.memoizedState=o,t.baseState=s,t.baseQueue=u,r.lastRenderedState=o}if(null!==(e=r.interleaved)){i=e;do{a=i.lane,fa.lanes|=a,Ul|=a,i=i.next}while(i!==e)}else null===i&&(r.lanes=0);return[t.memoizedState,r.dispatch]}function Na(e){var t=Ea(),r=t.queue;if(null===r)throw Error(n(311));r.lastRenderedReducer=e;var o=r.dispatch,i=r.pending,a=t.memoizedState;if(null!==i){r.pending=null;var s=i=i.next;do{a=e(a,s.action),s=s.next}while(s!==i);fr(a,t.memoizedState)||(Ss=!0),t.memoizedState=a,null===t.baseQueue&&(t.baseState=a),r.lastRenderedState=a}return[a,o]}function Oa(){}function Pa(e,t){var r=fa,o=Ea(),i=t(),a=!fr(o.memoizedState,i);if(a&&(o.memoizedState=i,Ss=!0),o=o.queue,Ba(Ra.bind(null,r,o,e),[e]),o.getSnapshot!==t||a||null!==ha&&1&ha.memoizedState.tag){if(r.flags|=2048,ja(9,_a.bind(null,r,o,i,t),void 0,null),null===Il)throw Error(n(349));30&da||La(r,t,i)}return i}function La(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},null===(t=fa.updateQueue)?(t={lastEffect:null,stores:null},fa.updateQueue=t,t.stores=[e]):null===(n=t.stores)?t.stores=[e]:n.push(e)}function _a(e,t,n,r){t.value=n,t.getSnapshot=r,Ia(t)&&Aa(e)}function Ra(e,t,n){return n(function(){Ia(t)&&Aa(e)})}function Ia(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!fr(e,n)}catch(r){return!0}}function Aa(e){var t=Ui(e,1);null!==t&&au(t,e,1,-1)}function za(e){var t=Sa();return"function"==typeof e&&(e=e()),t.memoizedState=t.baseState=e,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:Ca,lastRenderedState:e},t.queue=e,e=e.dispatch=Za.bind(null,fa,e),[t.memoizedState,e]}function ja(e,t,n,r){return e={tag:e,create:t,destroy:n,deps:r,next:null},null===(t=fa.updateQueue)?(t={lastEffect:null,stores:null},fa.updateQueue=t,t.lastEffect=e.next=e):null===(n=t.lastEffect)?t.lastEffect=e.next=e:(r=n.next,n.next=e,e.next=r,t.lastEffect=e),e}function Da(){return Ea().memoizedState}function Fa(e,t,n,r){var o=Sa();fa.flags|=e,o.memoizedState=ja(1|t,n,void 0,void 0===r?null:r)}function Ma(e,t,n,r){var o=Ea();r=void 0===r?null:r;var i=void 0;if(null!==pa){var a=pa.memoizedState;if(i=a.destroy,null!==r&&ka(r,a.deps))return void(o.memoizedState=ja(t,n,i,r))}fa.flags|=e,o.memoizedState=ja(1|t,n,i,r)}function Ua(e,t){return Fa(8390656,8,e,t)}function Ba(e,t){return Ma(2048,8,e,t)}function $a(e,t){return Ma(4,2,e,t)}function Va(e,t){return Ma(4,4,e,t)}function Ha(e,t){return"function"==typeof t?(e=e(),t(e),function(){t(null)}):null!=t?(e=e(),t.current=e,function(){t.current=null}):void 0}function qa(e,t,n){return n=null!=n?n.concat([e]):null,Ma(4,4,Ha.bind(null,t,e),n)}function Wa(){}function Ka(e,t){var n=Ea();t=void 0===t?null:t;var r=n.memoizedState;return null!==r&&null!==t&&ka(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function Qa(e,t){var n=Ea();t=void 0===t?null:t;var r=n.memoizedState;return null!==r&&null!==t&&ka(t,r[1])?r[0]:(e=e(),n.memoizedState=[e,t],e)}function Ja(e,t,n){return 21&da?(fr(n,t)||(n=kt(),fa.lanes|=n,Ul|=n,e.baseState=!0),t):(e.baseState&&(e.baseState=!1,Ss=!0),e.memoizedState=n)}function Ya(e,t){var n=Et;Et=0!==n&&4>n?n:4,e(!0);var r=ca.transition;ca.transition={};try{e(!1),t()}finally{Et=n,ca.transition=r}}function Ga(){return Ea().memoizedState}function Xa(e,t,n){var r=iu(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},es(e))ts(t,n);else if(null!==(n=Mi(e,t,n,r))){au(n,e,r,ou()),ns(n,t,r)}}function Za(e,t,n){var r=iu(e),o={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(es(e))ts(t,o);else{var i=e.alternate;if(0===e.lanes&&(null===i||0===i.lanes)&&null!==(i=t.lastRenderedReducer))try{var a=t.lastRenderedState,s=i(a,n);if(o.hasEagerState=!0,o.eagerState=s,fr(s,a)){var l=t.interleaved;return null===l?(o.next=o,Fi(t)):(o.next=l.next,l.next=o),void(t.interleaved=o)}}catch(je){}null!==(n=Mi(e,t,o,r))&&(au(n,e,r,o=ou()),ns(n,t,r))}}function es(e){var t=e.alternate;return e===fa||null!==t&&t===fa}function ts(e,t){ma=ga=!0;var n=e.pending;null===n?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function ns(e,t,n){if(4194240&n){var r=t.lanes;n|=r&=e.pendingLanes,t.lanes=n,St(e,n)}}var rs={readContext:ji,useCallback:ba,useContext:ba,useEffect:ba,useImperativeHandle:ba,useInsertionEffect:ba,useLayoutEffect:ba,useMemo:ba,useReducer:ba,useRef:ba,useState:ba,useDebugValue:ba,useDeferredValue:ba,useTransition:ba,useMutableSource:ba,useSyncExternalStore:ba,useId:ba,unstable_isNewReconciler:!1},os={readContext:ji,useCallback:function(e,t){return Sa().memoizedState=[e,void 0===t?null:t],e},useContext:ji,useEffect:Ua,useImperativeHandle:function(e,t,n){return n=null!=n?n.concat([e]):null,Fa(4194308,4,Ha.bind(null,t,e),n)},useLayoutEffect:function(e,t){return Fa(4194308,4,e,t)},useInsertionEffect:function(e,t){return Fa(4,2,e,t)},useMemo:function(e,t){var n=Sa();return t=void 0===t?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=Sa();return t=void 0!==n?n(t):t,r.memoizedState=r.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},r.queue=e,e=e.dispatch=Xa.bind(null,fa,e),[r.memoizedState,e]},useRef:function(e){return e={current:e},Sa().memoizedState=e},useState:za,useDebugValue:Wa,useDeferredValue:function(e){return Sa().memoizedState=e},useTransition:function(){var e=za(!1),t=e[0];return e=Ya.bind(null,e[1]),Sa().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,r){var o=fa,i=Sa();if(ci){if(void 0===r)throw Error(n(407));r=r()}else{if(r=t(),null===Il)throw Error(n(349));30&da||La(o,t,r)}i.memoizedState=r;var a={value:r,getSnapshot:t};return i.queue=a,Ua(Ra.bind(null,o,a,e),[e]),o.flags|=2048,ja(9,_a.bind(null,o,a,r,t),void 0,null),r},useId:function(){var e=Sa(),t=Il.identifierPrefix;if(ci){var n=ri;t=":"+t+"R"+(n=(ni&~(1<<32-dt(ni)-1)).toString(32)+n),0<(n=ya++)&&(t+="H"+n.toString(32)),t+=":"}else t=":"+t+"r"+(n=va++).toString(32)+":";return e.memoizedState=t},unstable_isNewReconciler:!1},is={readContext:ji,useCallback:Ka,useContext:ji,useEffect:Ba,useImperativeHandle:qa,useInsertionEffect:$a,useLayoutEffect:Va,useMemo:Qa,useReducer:Ta,useRef:Da,useState:function(){return Ta(Ca)},useDebugValue:Wa,useDeferredValue:function(e){return Ja(Ea(),pa.memoizedState,e)},useTransition:function(){return[Ta(Ca)[0],Ea().memoizedState]},useMutableSource:Oa,useSyncExternalStore:Pa,useId:Ga,unstable_isNewReconciler:!1},as={readContext:ji,useCallback:Ka,useContext:ji,useEffect:Ba,useImperativeHandle:qa,useInsertionEffect:$a,useLayoutEffect:Va,useMemo:Qa,useReducer:Na,useRef:Da,useState:function(){return Na(Ca)},useDebugValue:Wa,useDeferredValue:function(e){var t=Ea();return null===pa?t.memoizedState=e:Ja(t,pa.memoizedState,e)},useTransition:function(){return[Na(Ca)[0],Ea().memoizedState]},useMutableSource:Oa,useSyncExternalStore:Pa,useId:Ga,unstable_isNewReconciler:!1};function ss(e,t){if(e&&e.defaultProps){for(var n in t=F({},t),e=e.defaultProps)void 0===t[n]&&(t[n]=e[n]);return t}return t}function ls(e,t,n,r){n=null==(n=n(r,t=e.memoizedState))?t:F({},t,n),e.memoizedState=n,0===e.lanes&&(e.updateQueue.baseState=n)}var us={isMounted:function(e){return!!(e=e._reactInternals)&&Ke(e)===e},enqueueSetState:function(e,t,n){e=e._reactInternals;var r=ou(),o=iu(e),i=Hi(r,o);i.payload=t,null!=n&&(i.callback=n),null!==(t=qi(e,i,o))&&(au(t,e,o,r),Wi(t,e,o))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=ou(),o=iu(e),i=Hi(r,o);i.tag=1,i.payload=t,null!=n&&(i.callback=n),null!==(t=qi(e,i,o))&&(au(t,e,o,r),Wi(t,e,o))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=ou(),r=iu(e),o=Hi(n,r);o.tag=2,null!=t&&(o.callback=t),null!==(t=qi(e,o,r))&&(au(t,e,r,n),Wi(t,e,r))}};function cs(e,t,n,r,o,i,a){return"function"==typeof(e=e.stateNode).shouldComponentUpdate?e.shouldComponentUpdate(r,i,a):!t.prototype||!t.prototype.isPureReactComponent||(!pr(n,r)||!pr(o,i))}function ds(e,t,n){var r=!1,o=Io,i=t.contextType;return"object"==typeof i&&null!==i?i=ji(i):(o=Fo(t)?jo:Ao.current,i=(r=null!=(r=t.contextTypes))?Do(e,o):Io),t=new t(n,i),e.memoizedState=null!==t.state&&void 0!==t.state?t.state:null,t.updater=us,e.stateNode=t,t._reactInternals=e,r&&((e=e.stateNode).__reactInternalMemoizedUnmaskedChildContext=o,e.__reactInternalMemoizedMaskedChildContext=i),t}function fs(e,t,n,r){e=t.state,"function"==typeof t.componentWillReceiveProps&&t.componentWillReceiveProps(n,r),"function"==typeof t.UNSAFE_componentWillReceiveProps&&t.UNSAFE_componentWillReceiveProps(n,r),t.state!==e&&us.enqueueReplaceState(t,t.state,null)}function ps(e,t,n,r){var o=e.stateNode;o.props=n,o.state=e.memoizedState,o.refs={},$i(e);var i=t.contextType;"object"==typeof i&&null!==i?o.context=ji(i):(i=Fo(t)?jo:Ao.current,o.context=Do(e,i)),o.state=e.memoizedState,"function"==typeof(i=t.getDerivedStateFromProps)&&(ls(e,t,i,n),o.state=e.memoizedState),"function"==typeof t.getDerivedStateFromProps||"function"==typeof o.getSnapshotBeforeUpdate||"function"!=typeof o.UNSAFE_componentWillMount&&"function"!=typeof o.componentWillMount||(t=o.state,"function"==typeof o.componentWillMount&&o.componentWillMount(),"function"==typeof o.UNSAFE_componentWillMount&&o.UNSAFE_componentWillMount(),t!==o.state&&us.enqueueReplaceState(o,o.state,null),Qi(e,n,o,r),o.state=e.memoizedState),"function"==typeof o.componentDidMount&&(e.flags|=4194308)}function hs(e,t){try{var n="",r=t;do{n+=$(r),r=r.return}while(r);var o=n}catch(i){o="\nError generating stack: "+i.message+"\n"+i.stack}return{value:e,source:t,stack:o,digest:null}}function gs(e,t,n){return{value:e,source:null,stack:null!=n?n:null,digest:null!=t?t:null}}var ms="function"==typeof WeakMap?WeakMap:Map;function ys(e,t,n){(n=Hi(-1,n)).tag=3,n.payload={element:null};var r=t.value;return n.callback=function(){Ql||(Ql=!0,Jl=r)},n}function vs(e,t,n){(n=Hi(-1,n)).tag=3;var r=e.type.getDerivedStateFromError;if("function"==typeof r){var o=t.value;n.payload=function(){return r(o)},n.callback=function(){}}var i=e.stateNode;return null!==i&&"function"==typeof i.componentDidCatch&&(n.callback=function(){"function"!=typeof r&&(null===Yl?Yl=new Set([this]):Yl.add(this));var e=t.stack;this.componentDidCatch(t.value,{componentStack:null!==e?e:""})}),n}function bs(e,t,n){var r=e.pingCache;if(null===r){r=e.pingCache=new ms;var o=new Set;r.set(t,o)}else void 0===(o=r.get(t))&&(o=new Set,r.set(t,o));o.has(n)||(o.add(n),e=Pu.bind(null,e,t,n),t.then(e,e))}function ks(e){do{var t;if((t=13===e.tag)&&(t=null===(t=e.memoizedState)||null!==t.dehydrated),t)return e;e=e.return}while(null!==e);return null}function ws(e,t,n,r,o){return 1&e.mode?(e.flags|=65536,e.lanes=o,e):(e===t?e.flags|=65536:(e.flags|=128,n.flags|=131072,n.flags&=-52805,1===n.tag&&(null===n.alternate?n.tag=17:((t=Hi(-1,1)).tag=2,qi(n,t,1))),n.lanes|=1),e)}var xs=w.ReactCurrentOwner,Ss=!1;function Es(e,t,n,r){t.child=null===e?Ni(t,null,n,r):Ti(t,e.child,n,r)}function Cs(e,t,n,r,o){n=n.render;var i=t.ref;return zi(t,o),r=wa(e,t,n,r,i,o),n=xa(),null===e||Ss?(ci&&n&&ai(t),t.flags|=1,Es(e,t,r,o),t.child):(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~o,Qs(e,t,o))}function Ts(e,t,n,r,o){if(null===e){var i=n.type;return"function"!=typeof i||ju(i)||void 0!==i.defaultProps||null!==n.compare||void 0!==n.defaultProps?((e=Fu(n.type,null,r,t,t.mode,o)).ref=t.ref,e.return=t,t.child=e):(t.tag=15,t.type=i,Ns(e,t,i,r,o))}if(i=e.child,0===(e.lanes&o)){var a=i.memoizedProps;if((n=null!==(n=n.compare)?n:pr)(a,r)&&e.ref===t.ref)return Qs(e,t,o)}return t.flags|=1,(e=Du(i,r)).ref=t.ref,e.return=t,t.child=e}function Ns(e,t,n,r,o){if(null!==e){var i=e.memoizedProps;if(pr(i,r)&&e.ref===t.ref){if(Ss=!1,t.pendingProps=r=i,0===(e.lanes&o))return t.lanes=e.lanes,Qs(e,t,o);131072&e.flags&&(Ss=!0)}}return Ls(e,t,n,r,o)}function Os(e,t,n){var r=t.pendingProps,o=r.children,i=null!==e?e.memoizedState:null;if("hidden"===r.mode)if(1&t.mode){if(!(1073741824&n))return e=null!==i?i.baseLanes|n:n,t.lanes=t.childLanes=1073741824,t.memoizedState={baseLanes:e,cachePool:null,transitions:null},t.updateQueue=null,Ro(Dl,jl),jl|=e,null;t.memoizedState={baseLanes:0,cachePool:null,transitions:null},r=null!==i?i.baseLanes:n,Ro(Dl,jl),jl|=r}else t.memoizedState={baseLanes:0,cachePool:null,transitions:null},Ro(Dl,jl),jl|=n;else null!==i?(r=i.baseLanes|n,t.memoizedState=null):r=n,Ro(Dl,jl),jl|=r;return Es(e,t,o,n),t.child}function Ps(e,t){var n=t.ref;(null===e&&null!==n||null!==e&&e.ref!==n)&&(t.flags|=512,t.flags|=2097152)}function Ls(e,t,n,r,o){var i=Fo(n)?jo:Ao.current;return i=Do(t,i),zi(t,o),n=wa(e,t,n,r,i,o),r=xa(),null===e||Ss?(ci&&r&&ai(t),t.flags|=1,Es(e,t,n,o),t.child):(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~o,Qs(e,t,o))}function _s(e,t,n,r,o){if(Fo(n)){var i=!0;$o(t)}else i=!1;if(zi(t,o),null===t.stateNode)Ks(e,t),ds(t,n,r),ps(t,n,r,o),r=!0;else if(null===e){var a=t.stateNode,s=t.memoizedProps;a.props=s;var l=a.context,u=n.contextType;"object"==typeof u&&null!==u?u=ji(u):u=Do(t,u=Fo(n)?jo:Ao.current);var c=n.getDerivedStateFromProps,d="function"==typeof c||"function"==typeof a.getSnapshotBeforeUpdate;d||"function"!=typeof a.UNSAFE_componentWillReceiveProps&&"function"!=typeof a.componentWillReceiveProps||(s!==r||l!==u)&&fs(t,a,r,u),Bi=!1;var f=t.memoizedState;a.state=f,Qi(t,r,a,o),l=t.memoizedState,s!==r||f!==l||zo.current||Bi?("function"==typeof c&&(ls(t,n,c,r),l=t.memoizedState),(s=Bi||cs(t,n,s,r,f,l,u))?(d||"function"!=typeof a.UNSAFE_componentWillMount&&"function"!=typeof a.componentWillMount||("function"==typeof a.componentWillMount&&a.componentWillMount(),"function"==typeof a.UNSAFE_componentWillMount&&a.UNSAFE_componentWillMount()),"function"==typeof a.componentDidMount&&(t.flags|=4194308)):("function"==typeof a.componentDidMount&&(t.flags|=4194308),t.memoizedProps=r,t.memoizedState=l),a.props=r,a.state=l,a.context=u,r=s):("function"==typeof a.componentDidMount&&(t.flags|=4194308),r=!1)}else{a=t.stateNode,Vi(e,t),s=t.memoizedProps,u=t.type===t.elementType?s:ss(t.type,s),a.props=u,d=t.pendingProps,f=a.context,"object"==typeof(l=n.contextType)&&null!==l?l=ji(l):l=Do(t,l=Fo(n)?jo:Ao.current);var p=n.getDerivedStateFromProps;(c="function"==typeof p||"function"==typeof a.getSnapshotBeforeUpdate)||"function"!=typeof a.UNSAFE_componentWillReceiveProps&&"function"!=typeof a.componentWillReceiveProps||(s!==d||f!==l)&&fs(t,a,r,l),Bi=!1,f=t.memoizedState,a.state=f,Qi(t,r,a,o);var h=t.memoizedState;s!==d||f!==h||zo.current||Bi?("function"==typeof p&&(ls(t,n,p,r),h=t.memoizedState),(u=Bi||cs(t,n,u,r,f,h,l)||!1)?(c||"function"!=typeof a.UNSAFE_componentWillUpdate&&"function"!=typeof a.componentWillUpdate||("function"==typeof a.componentWillUpdate&&a.componentWillUpdate(r,h,l),"function"==typeof a.UNSAFE_componentWillUpdate&&a.UNSAFE_componentWillUpdate(r,h,l)),"function"==typeof a.componentDidUpdate&&(t.flags|=4),"function"==typeof a.getSnapshotBeforeUpdate&&(t.flags|=1024)):("function"!=typeof a.componentDidUpdate||s===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),"function"!=typeof a.getSnapshotBeforeUpdate||s===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=h),a.props=r,a.state=h,a.context=l,r=u):("function"!=typeof a.componentDidUpdate||s===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),"function"!=typeof a.getSnapshotBeforeUpdate||s===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),r=!1)}return Rs(e,t,n,r,i,o)}function Rs(e,t,n,r,o,i){Ps(e,t);var a=!!(128&t.flags);if(!r&&!a)return o&&Vo(t,n,!1),Qs(e,t,i);r=t.stateNode,xs.current=t;var s=a&&"function"!=typeof n.getDerivedStateFromError?null:r.render();return t.flags|=1,null!==e&&a?(t.child=Ti(t,e.child,null,i),t.child=Ti(t,null,s,i)):Es(e,t,s,i),t.memoizedState=r.state,o&&Vo(t,n,!0),t.child}function Is(e){var t=e.stateNode;t.pendingContext?Uo(0,t.pendingContext,t.pendingContext!==t.context):t.context&&Uo(0,t.context,!1),ta(e,t.containerInfo)}function As(e,t,n,r,o){return bi(),ki(o),t.flags|=256,Es(e,t,n,r),t.child}var zs,js,Ds,Fs,Ms={dehydrated:null,treeContext:null,retryLane:0};function Us(e){return{baseLanes:e,cachePool:null,transitions:null}}function Bs(e,t,r){var o,i=t.pendingProps,a=ia.current,s=!1,l=!!(128&t.flags);if((o=l)||(o=(null===e||null!==e.memoizedState)&&!!(2&a)),o?(s=!0,t.flags&=-129):null!==e&&null===e.memoizedState||(a|=1),Ro(ia,1&a),null===e)return gi(t),null!==(e=t.memoizedState)&&null!==(e=e.dehydrated)?(1&t.mode?"$!"===e.data?t.lanes=8:t.lanes=1073741824:t.lanes=1,null):(l=i.children,e=i.fallback,s?(i=t.mode,s=t.child,l={mode:"hidden",children:l},1&i||null===s?s=Uu(l,i,0,null):(s.childLanes=0,s.pendingProps=l),e=Mu(e,i,r,null),s.return=t,e.return=t,s.sibling=e,t.child=s,t.child.memoizedState=Us(r),t.memoizedState=Ms,e):$s(t,l));if(null!==(a=e.memoizedState)&&null!==(o=a.dehydrated))return function(e,t,r,o,i,a,s){if(r)return 256&t.flags?(t.flags&=-257,Vs(e,t,s,o=gs(Error(n(422))))):null!==t.memoizedState?(t.child=e.child,t.flags|=128,null):(a=o.fallback,i=t.mode,o=Uu({mode:"visible",children:o.children},i,0,null),(a=Mu(a,i,s,null)).flags|=2,o.return=t,a.return=t,o.sibling=a,t.child=o,1&t.mode&&Ti(t,e.child,null,s),t.child.memoizedState=Us(s),t.memoizedState=Ms,a);if(!(1&t.mode))return Vs(e,t,s,null);if("$!"===i.data){if(o=i.nextSibling&&i.nextSibling.dataset)var l=o.dgst;return o=l,Vs(e,t,s,o=gs(a=Error(n(419)),o,void 0))}if(l=0!==(s&e.childLanes),Ss||l){if(null!==(o=Il)){switch(s&-s){case 4:i=2;break;case 16:i=8;break;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:i=32;break;case 536870912:i=268435456;break;default:i=0}0!==(i=0!==(i&(o.suspendedLanes|s))?0:i)&&i!==a.retryLane&&(a.retryLane=i,Ui(e,i),au(o,e,i,-1))}return bu(),Vs(e,t,s,o=gs(Error(n(421))))}return"$?"===i.data?(t.flags|=128,t.child=e.child,t=_u.bind(null,e),i._reactRetry=t,null):(e=a.treeContext,ui=go(i.nextSibling),li=t,ci=!0,di=null,null!==e&&(Zo[ei++]=ni,Zo[ei++]=ri,Zo[ei++]=ti,ni=e.id,ri=e.overflow,ti=t),t=$s(t,o.children),t.flags|=4096,t)}(e,t,l,i,o,a,r);if(s){s=i.fallback,l=t.mode,o=(a=e.child).sibling;var u={mode:"hidden",children:i.children};return 1&l||t.child===a?(i=Du(a,u)).subtreeFlags=14680064&a.subtreeFlags:((i=t.child).childLanes=0,i.pendingProps=u,t.deletions=null),null!==o?s=Du(o,s):(s=Mu(s,l,r,null)).flags|=2,s.return=t,i.return=t,i.sibling=s,t.child=i,i=s,s=t.child,l=null===(l=e.child.memoizedState)?Us(r):{baseLanes:l.baseLanes|r,cachePool:null,transitions:l.transitions},s.memoizedState=l,s.childLanes=e.childLanes&~r,t.memoizedState=Ms,i}return e=(s=e.child).sibling,i=Du(s,{mode:"visible",children:i.children}),!(1&t.mode)&&(i.lanes=r),i.return=t,i.sibling=null,null!==e&&(null===(r=t.deletions)?(t.deletions=[e],t.flags|=16):r.push(e)),t.child=i,t.memoizedState=null,i}function $s(e,t){return(t=Uu({mode:"visible",children:t},e.mode,0,null)).return=e,e.child=t}function Vs(e,t,n,r){return null!==r&&ki(r),Ti(t,e.child,null,n),(e=$s(t,t.pendingProps.children)).flags|=2,t.memoizedState=null,e}function Hs(e,t,n){e.lanes|=t;var r=e.alternate;null!==r&&(r.lanes|=t),Ai(e.return,t,n)}function qs(e,t,n,r,o){var i=e.memoizedState;null===i?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:o}:(i.isBackwards=t,i.rendering=null,i.renderingStartTime=0,i.last=r,i.tail=n,i.tailMode=o)}function Ws(e,t,n){var r=t.pendingProps,o=r.revealOrder,i=r.tail;if(Es(e,t,r.children,n),2&(r=ia.current))r=1&r|2,t.flags|=128;else{if(null!==e&&128&e.flags)e:for(e=t.child;null!==e;){if(13===e.tag)null!==e.memoizedState&&Hs(e,n,t);else if(19===e.tag)Hs(e,n,t);else if(null!==e.child){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;null===e.sibling;){if(null===e.return||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}r&=1}if(Ro(ia,r),1&t.mode)switch(o){case"forwards":for(n=t.child,o=null;null!==n;)null!==(e=n.alternate)&&null===aa(e)&&(o=n),n=n.sibling;null===(n=o)?(o=t.child,t.child=null):(o=n.sibling,n.sibling=null),qs(t,!1,o,n,i);break;case"backwards":for(n=null,o=t.child,t.child=null;null!==o;){if(null!==(e=o.alternate)&&null===aa(e)){t.child=o;break}e=o.sibling,o.sibling=n,n=o,o=e}qs(t,!0,n,null,i);break;case"together":qs(t,!1,null,null,void 0);break;default:t.memoizedState=null}else t.memoizedState=null;return t.child}function Ks(e,t){!(1&t.mode)&&null!==e&&(e.alternate=null,t.alternate=null,t.flags|=2)}function Qs(e,t,r){if(null!==e&&(t.dependencies=e.dependencies),Ul|=t.lanes,0===(r&t.childLanes))return null;if(null!==e&&t.child!==e.child)throw Error(n(153));if(null!==t.child){for(r=Du(e=t.child,e.pendingProps),t.child=r,r.return=t;null!==e.sibling;)e=e.sibling,(r=r.sibling=Du(e,e.pendingProps)).return=t;r.sibling=null}return t.child}function Js(e,t){if(!ci)switch(e.tailMode){case"hidden":t=e.tail;for(var n=null;null!==t;)null!==t.alternate&&(n=t),t=t.sibling;null===n?e.tail=null:n.sibling=null;break;case"collapsed":n=e.tail;for(var r=null;null!==n;)null!==n.alternate&&(r=n),n=n.sibling;null===r?t||null===e.tail?e.tail=null:e.tail.sibling=null:r.sibling=null}}function Ys(e){var t=null!==e.alternate&&e.alternate.child===e.child,n=0,r=0;if(t)for(var o=e.child;null!==o;)n|=o.lanes|o.childLanes,r|=14680064&o.subtreeFlags,r|=14680064&o.flags,o.return=e,o=o.sibling;else for(o=e.child;null!==o;)n|=o.lanes|o.childLanes,r|=o.subtreeFlags,r|=o.flags,o.return=e,o=o.sibling;return e.subtreeFlags|=r,e.childLanes=n,t}function Gs(e,t,r){var i=t.pendingProps;switch(si(t),t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Ys(t),null;case 1:case 17:return Fo(t.type)&&Mo(),Ys(t),null;case 3:return i=t.stateNode,na(),_o(zo),_o(Ao),la(),i.pendingContext&&(i.context=i.pendingContext,i.pendingContext=null),null!==e&&null!==e.child||(yi(t)?t.flags|=4:null===e||e.memoizedState.isDehydrated&&!(256&t.flags)||(t.flags|=1024,null!==di&&(cu(di),di=null))),js(e,t),Ys(t),null;case 5:oa(t);var a=ea(Zi.current);if(r=t.type,null!==e&&null!=t.stateNode)Ds(e,t,r,i,a),e.ref!==t.ref&&(t.flags|=512,t.flags|=2097152);else{if(!i){if(null===t.stateNode)throw Error(n(166));return Ys(t),null}if(e=ea(Gi.current),yi(t)){i=t.stateNode,r=t.type;var s=t.memoizedProps;switch(i[vo]=t,i[bo]=s,e=!!(1&t.mode),r){case"dialog":Hr("cancel",i),Hr("close",i);break;case"iframe":case"object":case"embed":Hr("load",i);break;case"video":case"audio":for(a=0;a<Ur.length;a++)Hr(Ur[a],i);break;case"source":Hr("error",i);break;case"img":case"image":case"link":Hr("error",i),Hr("load",i);break;case"details":Hr("toggle",i);break;case"input":G(i,s),Hr("invalid",i);break;case"select":i._wrapperState={wasMultiple:!!s.multiple},Hr("invalid",i);break;case"textarea":ie(i,s),Hr("invalid",i)}for(var l in be(r,s),a=null,s)if(s.hasOwnProperty(l)){var u=s[l];"children"===l?"string"==typeof u?i.textContent!==u&&(!0!==s.suppressHydrationWarning&&ro(i.textContent,u,e),a=["children",u]):"number"==typeof u&&i.textContent!==""+u&&(!0!==s.suppressHydrationWarning&&ro(i.textContent,u,e),a=["children",""+u]):o.hasOwnProperty(l)&&null!=u&&"onScroll"===l&&Hr("scroll",i)}switch(r){case"input":K(i),ee(i,s,!0);break;case"textarea":K(i),se(i);break;case"select":case"option":break;default:"function"==typeof s.onClick&&(i.onclick=oo)}i=a,t.updateQueue=i,null!==i&&(t.flags|=4)}else{l=9===a.nodeType?a:a.ownerDocument,"http://www.w3.org/1999/xhtml"===e&&(e=le(r)),"http://www.w3.org/1999/xhtml"===e?"script"===r?((e=l.createElement("div")).innerHTML="<script><\/script>",e=e.removeChild(e.firstChild)):"string"==typeof i.is?e=l.createElement(r,{is:i.is}):(e=l.createElement(r),"select"===r&&(l=e,i.multiple?l.multiple=!0:i.size&&(l.size=i.size))):e=l.createElementNS(e,r),e[vo]=t,e[bo]=i,zs(e,t,!1,!1),t.stateNode=e;e:{switch(l=ke(r,i),r){case"dialog":Hr("cancel",e),Hr("close",e),a=i;break;case"iframe":case"object":case"embed":Hr("load",e),a=i;break;case"video":case"audio":for(a=0;a<Ur.length;a++)Hr(Ur[a],e);a=i;break;case"source":Hr("error",e),a=i;break;case"img":case"image":case"link":Hr("error",e),Hr("load",e),a=i;break;case"details":Hr("toggle",e),a=i;break;case"input":G(e,i),a=Y(e,i),Hr("invalid",e);break;case"option":default:a=i;break;case"select":e._wrapperState={wasMultiple:!!i.multiple},a=F({},i,{value:void 0}),Hr("invalid",e);break;case"textarea":ie(e,i),a=oe(e,i),Hr("invalid",e)}for(s in be(r,a),u=a)if(u.hasOwnProperty(s)){var c=u[s];"style"===s?ye(e,c):"dangerouslySetInnerHTML"===s?null!=(c=c?c.__html:void 0)&&fe(e,c):"children"===s?"string"==typeof c?("textarea"!==r||""!==c)&&pe(e,c):"number"==typeof c&&pe(e,""+c):"suppressContentEditableWarning"!==s&&"suppressHydrationWarning"!==s&&"autoFocus"!==s&&(o.hasOwnProperty(s)?null!=c&&"onScroll"===s&&Hr("scroll",e):null!=c&&b(e,s,c,l))}switch(r){case"input":K(e),ee(e,i,!1);break;case"textarea":K(e),se(e);break;case"option":null!=i.value&&e.setAttribute("value",""+q(i.value));break;case"select":e.multiple=!!i.multiple,null!=(s=i.value)?re(e,!!i.multiple,s,!1):null!=i.defaultValue&&re(e,!!i.multiple,i.defaultValue,!0);break;default:"function"==typeof a.onClick&&(e.onclick=oo)}switch(r){case"button":case"input":case"select":case"textarea":i=!!i.autoFocus;break e;case"img":i=!0;break e;default:i=!1}}i&&(t.flags|=4)}null!==t.ref&&(t.flags|=512,t.flags|=2097152)}return Ys(t),null;case 6:if(e&&null!=t.stateNode)Fs(e,t,e.memoizedProps,i);else{if("string"!=typeof i&&null===t.stateNode)throw Error(n(166));if(r=ea(Zi.current),ea(Gi.current),yi(t)){if(i=t.stateNode,r=t.memoizedProps,i[vo]=t,(s=i.nodeValue!==r)&&null!==(e=li))switch(e.tag){case 3:ro(i.nodeValue,r,!!(1&e.mode));break;case 5:!0!==e.memoizedProps.suppressHydrationWarning&&ro(i.nodeValue,r,!!(1&e.mode))}s&&(t.flags|=4)}else(i=(9===r.nodeType?r:r.ownerDocument).createTextNode(i))[vo]=t,t.stateNode=i}return Ys(t),null;case 13:if(_o(ia),i=t.memoizedState,null===e||null!==e.memoizedState&&null!==e.memoizedState.dehydrated){if(ci&&null!==ui&&1&t.mode&&!(128&t.flags))vi(),bi(),t.flags|=98560,s=!1;else if(s=yi(t),null!==i&&null!==i.dehydrated){if(null===e){if(!s)throw Error(n(318));if(!(s=null!==(s=t.memoizedState)?s.dehydrated:null))throw Error(n(317));s[vo]=t}else bi(),!(128&t.flags)&&(t.memoizedState=null),t.flags|=4;Ys(t),s=!1}else null!==di&&(cu(di),di=null),s=!0;if(!s)return 65536&t.flags?t:null}return 128&t.flags?(t.lanes=r,t):((i=null!==i)!==(null!==e&&null!==e.memoizedState)&&i&&(t.child.flags|=8192,1&t.mode&&(null===e||1&ia.current?0===Fl&&(Fl=3):bu())),null!==t.updateQueue&&(t.flags|=4),Ys(t),null);case 4:return na(),js(e,t),null===e&&Kr(t.stateNode.containerInfo),Ys(t),null;case 10:return Ii(t.type._context),Ys(t),null;case 19:if(_o(ia),null===(s=t.memoizedState))return Ys(t),null;if(i=!!(128&t.flags),null===(l=s.rendering))if(i)Js(s,!1);else{if(0!==Fl||null!==e&&128&e.flags)for(e=t.child;null!==e;){if(null!==(l=aa(e))){for(t.flags|=128,Js(s,!1),null!==(i=l.updateQueue)&&(t.updateQueue=i,t.flags|=4),t.subtreeFlags=0,i=r,r=t.child;null!==r;)e=i,(s=r).flags&=14680066,null===(l=s.alternate)?(s.childLanes=0,s.lanes=e,s.child=null,s.subtreeFlags=0,s.memoizedProps=null,s.memoizedState=null,s.updateQueue=null,s.dependencies=null,s.stateNode=null):(s.childLanes=l.childLanes,s.lanes=l.lanes,s.child=l.child,s.subtreeFlags=0,s.deletions=null,s.memoizedProps=l.memoizedProps,s.memoizedState=l.memoizedState,s.updateQueue=l.updateQueue,s.type=l.type,e=l.dependencies,s.dependencies=null===e?null:{lanes:e.lanes,firstContext:e.firstContext}),r=r.sibling;return Ro(ia,1&ia.current|2),t.child}e=e.sibling}null!==s.tail&&nt()>Wl&&(t.flags|=128,i=!0,Js(s,!1),t.lanes=4194304)}else{if(!i)if(null!==(e=aa(l))){if(t.flags|=128,i=!0,null!==(r=e.updateQueue)&&(t.updateQueue=r,t.flags|=4),Js(s,!0),null===s.tail&&"hidden"===s.tailMode&&!l.alternate&&!ci)return Ys(t),null}else 2*nt()-s.renderingStartTime>Wl&&1073741824!==r&&(t.flags|=128,i=!0,Js(s,!1),t.lanes=4194304);s.isBackwards?(l.sibling=t.child,t.child=l):(null!==(r=s.last)?r.sibling=l:t.child=l,s.last=l)}return null!==s.tail?(t=s.tail,s.rendering=t,s.tail=t.sibling,s.renderingStartTime=nt(),t.sibling=null,r=ia.current,Ro(ia,i?1&r|2:1&r),t):(Ys(t),null);case 22:case 23:return gu(),i=null!==t.memoizedState,null!==e&&null!==e.memoizedState!==i&&(t.flags|=8192),i&&1&t.mode?!!(1073741824&jl)&&(Ys(t),6&t.subtreeFlags&&(t.flags|=8192)):Ys(t),null;case 24:case 25:return null}throw Error(n(156,t.tag))}function Xs(e,t){switch(si(t),t.tag){case 1:return Fo(t.type)&&Mo(),65536&(e=t.flags)?(t.flags=-65537&e|128,t):null;case 3:return na(),_o(zo),_o(Ao),la(),65536&(e=t.flags)&&!(128&e)?(t.flags=-65537&e|128,t):null;case 5:return oa(t),null;case 13:if(_o(ia),null!==(e=t.memoizedState)&&null!==e.dehydrated){if(null===t.alternate)throw Error(n(340));bi()}return 65536&(e=t.flags)?(t.flags=-65537&e|128,t):null;case 19:return _o(ia),null;case 4:return na(),null;case 10:return Ii(t.type._context),null;case 22:case 23:return gu(),null;default:return null}}zs=function(e,t){for(var n=t.child;null!==n;){if(5===n.tag||6===n.tag)e.appendChild(n.stateNode);else if(4!==n.tag&&null!==n.child){n.child.return=n,n=n.child;continue}if(n===t)break;for(;null===n.sibling;){if(null===n.return||n.return===t)return;n=n.return}n.sibling.return=n.return,n=n.sibling}},js=function(){},Ds=function(e,t,n,r){var i=e.memoizedProps;if(i!==r){e=t.stateNode,ea(Gi.current);var a,s=null;switch(n){case"input":i=Y(e,i),r=Y(e,r),s=[];break;case"select":i=F({},i,{value:void 0}),r=F({},r,{value:void 0}),s=[];break;case"textarea":i=oe(e,i),r=oe(e,r),s=[];break;default:"function"!=typeof i.onClick&&"function"==typeof r.onClick&&(e.onclick=oo)}for(c in be(n,r),n=null,i)if(!r.hasOwnProperty(c)&&i.hasOwnProperty(c)&&null!=i[c])if("style"===c){var l=i[c];for(a in l)l.hasOwnProperty(a)&&(n||(n={}),n[a]="")}else"dangerouslySetInnerHTML"!==c&&"children"!==c&&"suppressContentEditableWarning"!==c&&"suppressHydrationWarning"!==c&&"autoFocus"!==c&&(o.hasOwnProperty(c)?s||(s=[]):(s=s||[]).push(c,null));for(c in r){var u=r[c];if(l=null!=i?i[c]:void 0,r.hasOwnProperty(c)&&u!==l&&(null!=u||null!=l))if("style"===c)if(l){for(a in l)!l.hasOwnProperty(a)||u&&u.hasOwnProperty(a)||(n||(n={}),n[a]="");for(a in u)u.hasOwnProperty(a)&&l[a]!==u[a]&&(n||(n={}),n[a]=u[a])}else n||(s||(s=[]),s.push(c,n)),n=u;else"dangerouslySetInnerHTML"===c?(u=u?u.__html:void 0,l=l?l.__html:void 0,null!=u&&l!==u&&(s=s||[]).push(c,u)):"children"===c?"string"!=typeof u&&"number"!=typeof u||(s=s||[]).push(c,""+u):"suppressContentEditableWarning"!==c&&"suppressHydrationWarning"!==c&&(o.hasOwnProperty(c)?(null!=u&&"onScroll"===c&&Hr("scroll",e),s||l===u||(s=[])):(s=s||[]).push(c,u))}n&&(s=s||[]).push("style",n);var c=s;(t.updateQueue=c)&&(t.flags|=4)}},Fs=function(e,t,n,r){n!==r&&(t.flags|=4)};var Zs=!1,el=!1,tl="function"==typeof WeakSet?WeakSet:Set,nl=null;function rl(e,t){var n=e.ref;if(null!==n)if("function"==typeof n)try{n(null)}catch(r){Ou(e,t,r)}else n.current=null}function ol(e,t,n){try{n()}catch(r){Ou(e,t,r)}}var il=!1;function al(e,t,n){var r=t.updateQueue;if(null!==(r=null!==r?r.lastEffect:null)){var o=r=r.next;do{if((o.tag&e)===e){var i=o.destroy;o.destroy=void 0,void 0!==i&&ol(t,n,i)}o=o.next}while(o!==r)}}function sl(e,t){if(null!==(t=null!==(t=t.updateQueue)?t.lastEffect:null)){var n=t=t.next;do{if((n.tag&e)===e){var r=n.create;n.destroy=r()}n=n.next}while(n!==t)}}function ll(e){var t=e.ref;if(null!==t){var n=e.stateNode;e.tag,e=n,"function"==typeof t?t(e):t.current=e}}function ul(e){var t=e.alternate;null!==t&&(e.alternate=null,ul(t)),e.child=null,e.deletions=null,e.sibling=null,5===e.tag&&(null!==(t=e.stateNode)&&(delete t[vo],delete t[bo],delete t[wo],delete t[xo],delete t[So])),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function cl(e){return 5===e.tag||3===e.tag||4===e.tag}function dl(e){e:for(;;){for(;null===e.sibling;){if(null===e.return||cl(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;5!==e.tag&&6!==e.tag&&18!==e.tag;){if(2&e.flags)continue e;if(null===e.child||4===e.tag)continue e;e.child.return=e,e=e.child}if(!(2&e.flags))return e.stateNode}}function fl(e,t,n){var r=e.tag;if(5===r||6===r)e=e.stateNode,t?8===n.nodeType?n.parentNode.insertBefore(e,t):n.insertBefore(e,t):(8===n.nodeType?(t=n.parentNode).insertBefore(e,n):(t=n).appendChild(e),null!=(n=n._reactRootContainer)||null!==t.onclick||(t.onclick=oo));else if(4!==r&&null!==(e=e.child))for(fl(e,t,n),e=e.sibling;null!==e;)fl(e,t,n),e=e.sibling}function pl(e,t,n){var r=e.tag;if(5===r||6===r)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(4!==r&&null!==(e=e.child))for(pl(e,t,n),e=e.sibling;null!==e;)pl(e,t,n),e=e.sibling}var hl=null,gl=!1;function ml(e,t,n){for(n=n.child;null!==n;)yl(e,t,n),n=n.sibling}function yl(e,t,n){if(ct&&"function"==typeof ct.onCommitFiberUnmount)try{ct.onCommitFiberUnmount(ut,n)}catch(s){}switch(n.tag){case 5:el||rl(n,t);case 6:var r=hl,o=gl;hl=null,ml(e,t,n),gl=o,null!==(hl=r)&&(gl?(e=hl,n=n.stateNode,8===e.nodeType?e.parentNode.removeChild(n):e.removeChild(n)):hl.removeChild(n.stateNode));break;case 18:null!==hl&&(gl?(e=hl,n=n.stateNode,8===e.nodeType?ho(e.parentNode,n):1===e.nodeType&&ho(e,n),Kt(e)):ho(hl,n.stateNode));break;case 4:r=hl,o=gl,hl=n.stateNode.containerInfo,gl=!0,ml(e,t,n),hl=r,gl=o;break;case 0:case 11:case 14:case 15:if(!el&&(null!==(r=n.updateQueue)&&null!==(r=r.lastEffect))){o=r=r.next;do{var i=o,a=i.destroy;i=i.tag,void 0!==a&&(2&i||4&i)&&ol(n,t,a),o=o.next}while(o!==r)}ml(e,t,n);break;case 1:if(!el&&(rl(n,t),"function"==typeof(r=n.stateNode).componentWillUnmount))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(s){Ou(n,t,s)}ml(e,t,n);break;case 21:ml(e,t,n);break;case 22:1&n.mode?(el=(r=el)||null!==n.memoizedState,ml(e,t,n),el=r):ml(e,t,n);break;default:ml(e,t,n)}}function vl(e){var t=e.updateQueue;if(null!==t){e.updateQueue=null;var n=e.stateNode;null===n&&(n=e.stateNode=new tl),t.forEach(function(t){var r=Ru.bind(null,e,t);n.has(t)||(n.add(t),t.then(r,r))})}}function bl(e,t){var r=t.deletions;if(null!==r)for(var o=0;o<r.length;o++){var i=r[o];try{var a=e,s=t,l=s;e:for(;null!==l;){switch(l.tag){case 5:hl=l.stateNode,gl=!1;break e;case 3:case 4:hl=l.stateNode.containerInfo,gl=!0;break e}l=l.return}if(null===hl)throw Error(n(160));yl(a,s,i),hl=null,gl=!1;var u=i.alternate;null!==u&&(u.return=null),i.return=null}catch(je){Ou(i,t,je)}}if(12854&t.subtreeFlags)for(t=t.child;null!==t;)kl(t,e),t=t.sibling}function kl(e,t){var r=e.alternate,o=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:if(bl(t,e),wl(e),4&o){try{al(3,e,e.return),sl(3,e)}catch(Ae){Ou(e,e.return,Ae)}try{al(5,e,e.return)}catch(Ae){Ou(e,e.return,Ae)}}break;case 1:bl(t,e),wl(e),512&o&&null!==r&&rl(r,r.return);break;case 5:if(bl(t,e),wl(e),512&o&&null!==r&&rl(r,r.return),32&e.flags){var i=e.stateNode;try{pe(i,"")}catch(Ae){Ou(e,e.return,Ae)}}if(4&o&&null!=(i=e.stateNode)){var a=e.memoizedProps,s=null!==r?r.memoizedProps:a,l=e.type,u=e.updateQueue;if(e.updateQueue=null,null!==u)try{"input"===l&&"radio"===a.type&&null!=a.name&&X(i,a),ke(l,s);var c=ke(l,a);for(s=0;s<u.length;s+=2){var d=u[s],f=u[s+1];"style"===d?ye(i,f):"dangerouslySetInnerHTML"===d?fe(i,f):"children"===d?pe(i,f):b(i,d,f,c)}switch(l){case"input":Z(i,a);break;case"textarea":ae(i,a);break;case"select":var p=i._wrapperState.wasMultiple;i._wrapperState.wasMultiple=!!a.multiple;var h=a.value;null!=h?re(i,!!a.multiple,h,!1):p!==!!a.multiple&&(null!=a.defaultValue?re(i,!!a.multiple,a.defaultValue,!0):re(i,!!a.multiple,a.multiple?[]:"",!1))}i[bo]=a}catch(Ae){Ou(e,e.return,Ae)}}break;case 6:if(bl(t,e),wl(e),4&o){if(null===e.stateNode)throw Error(n(162));i=e.stateNode,a=e.memoizedProps;try{i.nodeValue=a}catch(Ae){Ou(e,e.return,Ae)}}break;case 3:if(bl(t,e),wl(e),4&o&&null!==r&&r.memoizedState.isDehydrated)try{Kt(t.containerInfo)}catch(Ae){Ou(e,e.return,Ae)}break;case 4:default:bl(t,e),wl(e);break;case 13:bl(t,e),wl(e),8192&(i=e.child).flags&&(a=null!==i.memoizedState,i.stateNode.isHidden=a,!a||null!==i.alternate&&null!==i.alternate.memoizedState||(ql=nt())),4&o&&vl(e);break;case 22:if(d=null!==r&&null!==r.memoizedState,1&e.mode?(el=(c=el)||d,bl(t,e),el=c):bl(t,e),wl(e),8192&o){if(c=null!==e.memoizedState,(e.stateNode.isHidden=c)&&!d&&1&e.mode)for(nl=e,d=e.child;null!==d;){for(f=nl=d;null!==nl;){switch(h=(p=nl).child,p.tag){case 0:case 11:case 14:case 15:al(4,p,p.return);break;case 1:rl(p,p.return);var g=p.stateNode;if("function"==typeof g.componentWillUnmount){o=p,r=p.return;try{t=o,g.props=t.memoizedProps,g.state=t.memoizedState,g.componentWillUnmount()}catch(Ae){Ou(o,r,Ae)}}break;case 5:rl(p,p.return);break;case 22:if(null!==p.memoizedState){Cl(f);continue}}null!==h?(h.return=p,nl=h):Cl(f)}d=d.sibling}e:for(d=null,f=e;;){if(5===f.tag){if(null===d){d=f;try{i=f.stateNode,c?"function"==typeof(a=i.style).setProperty?a.setProperty("display","none","important"):a.display="none":(l=f.stateNode,s=null!=(u=f.memoizedProps.style)&&u.hasOwnProperty("display")?u.display:null,l.style.display=me("display",s))}catch(Ae){Ou(e,e.return,Ae)}}}else if(6===f.tag){if(null===d)try{f.stateNode.nodeValue=c?"":f.memoizedProps}catch(Ae){Ou(e,e.return,Ae)}}else if((22!==f.tag&&23!==f.tag||null===f.memoizedState||f===e)&&null!==f.child){f.child.return=f,f=f.child;continue}if(f===e)break e;for(;null===f.sibling;){if(null===f.return||f.return===e)break e;d===f&&(d=null),f=f.return}d===f&&(d=null),f.sibling.return=f.return,f=f.sibling}}break;case 19:bl(t,e),wl(e),4&o&&vl(e);case 21:}}function wl(e){var t=e.flags;if(2&t){try{e:{for(var r=e.return;null!==r;){if(cl(r)){var o=r;break e}r=r.return}throw Error(n(160))}switch(o.tag){case 5:var i=o.stateNode;32&o.flags&&(pe(i,""),o.flags&=-33),pl(e,dl(e),i);break;case 3:case 4:var a=o.stateNode.containerInfo;fl(e,dl(e),a);break;default:throw Error(n(161))}}catch(s){Ou(e,e.return,s)}e.flags&=-3}4096&t&&(e.flags&=-4097)}function xl(e,t,n){nl=e,Sl(e)}function Sl(e,t,n){for(var r=!!(1&e.mode);null!==nl;){var o=nl,i=o.child;if(22===o.tag&&r){var a=null!==o.memoizedState||Zs;if(!a){var s=o.alternate,l=null!==s&&null!==s.memoizedState||el;s=Zs;var u=el;if(Zs=a,(el=l)&&!u)for(nl=o;null!==nl;)l=(a=nl).child,22===a.tag&&null!==a.memoizedState?Tl(o):null!==l?(l.return=a,nl=l):Tl(o);for(;null!==i;)nl=i,Sl(i),i=i.sibling;nl=o,Zs=s,el=u}El(e)}else 8772&o.subtreeFlags&&null!==i?(i.return=o,nl=i):El(e)}}function El(e){for(;null!==nl;){var t=nl;if(8772&t.flags){var r=t.alternate;try{if(8772&t.flags)switch(t.tag){case 0:case 11:case 15:el||sl(5,t);break;case 1:var o=t.stateNode;if(4&t.flags&&!el)if(null===r)o.componentDidMount();else{var i=t.elementType===t.type?r.memoizedProps:ss(t.type,r.memoizedProps);o.componentDidUpdate(i,r.memoizedState,o.__reactInternalSnapshotBeforeUpdate)}var a=t.updateQueue;null!==a&&Ji(t,a,o);break;case 3:var s=t.updateQueue;if(null!==s){if(r=null,null!==t.child)switch(t.child.tag){case 5:case 1:r=t.child.stateNode}Ji(t,s,r)}break;case 5:var l=t.stateNode;if(null===r&&4&t.flags){r=l;var u=t.memoizedProps;switch(t.type){case"button":case"input":case"select":case"textarea":u.autoFocus&&r.focus();break;case"img":u.src&&(r.src=u.src)}}break;case 6:case 4:case 12:case 19:case 17:case 21:case 22:case 23:case 25:break;case 13:if(null===t.memoizedState){var c=t.alternate;if(null!==c){var d=c.memoizedState;if(null!==d){var f=d.dehydrated;null!==f&&Kt(f)}}}break;default:throw Error(n(163))}el||512&t.flags&&ll(t)}catch(ze){Ou(t,t.return,ze)}}if(t===e){nl=null;break}if(null!==(r=t.sibling)){r.return=t.return,nl=r;break}nl=t.return}}function Cl(e){for(;null!==nl;){var t=nl;if(t===e){nl=null;break}var n=t.sibling;if(null!==n){n.return=t.return,nl=n;break}nl=t.return}}function Tl(e){for(;null!==nl;){var t=nl;try{switch(t.tag){case 0:case 11:case 15:var n=t.return;try{sl(4,t)}catch(l){Ou(t,n,l)}break;case 1:var r=t.stateNode;if("function"==typeof r.componentDidMount){var o=t.return;try{r.componentDidMount()}catch(l){Ou(t,o,l)}}var i=t.return;try{ll(t)}catch(l){Ou(t,i,l)}break;case 5:var a=t.return;try{ll(t)}catch(l){Ou(t,a,l)}}}catch(l){Ou(t,t.return,l)}if(t===e){nl=null;break}var s=t.sibling;if(null!==s){s.return=t.return,nl=s;break}nl=t.return}}var Nl,Ol=Math.ceil,Pl=w.ReactCurrentDispatcher,Ll=w.ReactCurrentOwner,_l=w.ReactCurrentBatchConfig,Rl=0,Il=null,Al=null,zl=0,jl=0,Dl=Lo(0),Fl=0,Ml=null,Ul=0,Bl=0,$l=0,Vl=null,Hl=null,ql=0,Wl=1/0,Kl=null,Ql=!1,Jl=null,Yl=null,Gl=!1,Xl=null,Zl=0,eu=0,tu=null,nu=-1,ru=0;function ou(){return 6&Rl?nt():-1!==nu?nu:nu=nt()}function iu(e){return 1&e.mode?2&Rl&&0!==zl?zl&-zl:null!==wi.transition?(0===ru&&(ru=kt()),ru):0!==(e=Et)?e:e=void 0===(e=window.event)?16:tn(e.type):1}function au(e,t,r,o){if(50<eu)throw eu=0,tu=null,Error(n(185));xt(e,r,o),2&Rl&&e===Il||(e===Il&&(!(2&Rl)&&(Bl|=r),4===Fl&&du(e,zl)),su(e,o),1===r&&0===Rl&&!(1&t.mode)&&(Wl=nt()+500,qo&&Qo()))}function su(e,t){var n=e.callbackNode;!function(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,o=e.expirationTimes,i=e.pendingLanes;0<i;){var a=31-dt(i),s=1<<a,l=o[a];-1===l?0!==(s&n)&&0===(s&r)||(o[a]=vt(s,t)):l<=t&&(e.expiredLanes|=s),i&=~s}}(e,t);var r=yt(e,e===Il?zl:0);if(0===r)null!==n&&Ze(n),e.callbackNode=null,e.callbackPriority=0;else if(t=r&-r,e.callbackPriority!==t){if(null!=n&&Ze(n),1===t)0===e.tag?function(e){qo=!0,Ko(e)}(fu.bind(null,e)):Ko(fu.bind(null,e)),fo(function(){!(6&Rl)&&Qo()}),n=null;else{switch(Ct(r)){case 1:n=ot;break;case 4:n=it;break;case 16:default:n=at;break;case 536870912:n=lt}n=Iu(n,lu.bind(null,e))}e.callbackPriority=t,e.callbackNode=n}}function lu(e,t){if(nu=-1,ru=0,6&Rl)throw Error(n(327));var r=e.callbackNode;if(Tu()&&e.callbackNode!==r)return null;var o=yt(e,e===Il?zl:0);if(0===o)return null;if(30&o||0!==(o&e.expiredLanes)||t)t=ku(e,o);else{t=o;var i=Rl;Rl|=2;var a=vu();for(Il===e&&zl===t||(Kl=null,Wl=nt()+500,mu(e,t));;)try{xu();break}catch(l){yu(e,l)}Ri(),Pl.current=a,Rl=i,null!==Al?t=0:(Il=null,zl=0,t=Fl)}if(0!==t){if(2===t&&(0!==(i=bt(e))&&(o=i,t=uu(e,i))),1===t)throw r=Ml,mu(e,0),du(e,o),su(e,nt()),r;if(6===t)du(e,o);else{if(i=e.current.alternate,!(30&o||function(e){for(var t=e;;){if(16384&t.flags){var n=t.updateQueue;if(null!==n&&null!==(n=n.stores))for(var r=0;r<n.length;r++){var o=n[r],i=o.getSnapshot;o=o.value;try{if(!fr(i(),o))return!1}catch(s){return!1}}}if(n=t.child,16384&t.subtreeFlags&&null!==n)n.return=t,t=n;else{if(t===e)break;for(;null===t.sibling;){if(null===t.return||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}(i)||(t=ku(e,o),2===t&&(a=bt(e),0!==a&&(o=a,t=uu(e,a))),1!==t)))throw r=Ml,mu(e,0),du(e,o),su(e,nt()),r;switch(e.finishedWork=i,e.finishedLanes=o,t){case 0:case 1:throw Error(n(345));case 2:case 5:Cu(e,Hl,Kl);break;case 3:if(du(e,o),(130023424&o)===o&&10<(t=ql+500-nt())){if(0!==yt(e,0))break;if(((i=e.suspendedLanes)&o)!==o){ou(),e.pingedLanes|=e.suspendedLanes&i;break}e.timeoutHandle=lo(Cu.bind(null,e,Hl,Kl),t);break}Cu(e,Hl,Kl);break;case 4:if(du(e,o),(4194240&o)===o)break;for(t=e.eventTimes,i=-1;0<o;){var s=31-dt(o);a=1<<s,(s=t[s])>i&&(i=s),o&=~a}if(o=i,10<(o=(120>(o=nt()-o)?120:480>o?480:1080>o?1080:1920>o?1920:3e3>o?3e3:4320>o?4320:1960*Ol(o/1960))-o)){e.timeoutHandle=lo(Cu.bind(null,e,Hl,Kl),o);break}Cu(e,Hl,Kl);break;default:throw Error(n(329))}}}return su(e,nt()),e.callbackNode===r?lu.bind(null,e):null}function uu(e,t){var n=Vl;return e.current.memoizedState.isDehydrated&&(mu(e,t).flags|=256),2!==(e=ku(e,t))&&(t=Hl,Hl=n,null!==t&&cu(t)),e}function cu(e){null===Hl?Hl=e:Hl.push.apply(Hl,e)}function du(e,t){for(t&=~$l,t&=~Bl,e.suspendedLanes|=t,e.pingedLanes&=~t,e=e.expirationTimes;0<t;){var n=31-dt(t),r=1<<n;e[n]=-1,t&=~r}}function fu(e){if(6&Rl)throw Error(n(327));Tu();var t=yt(e,0);if(!(1&t))return su(e,nt()),null;var r=ku(e,t);if(0!==e.tag&&2===r){var o=bt(e);0!==o&&(t=o,r=uu(e,o))}if(1===r)throw r=Ml,mu(e,0),du(e,t),su(e,nt()),r;if(6===r)throw Error(n(345));return e.finishedWork=e.current.alternate,e.finishedLanes=t,Cu(e,Hl,Kl),su(e,nt()),null}function pu(e,t){var n=Rl;Rl|=1;try{return e(t)}finally{0===(Rl=n)&&(Wl=nt()+500,qo&&Qo())}}function hu(e){null!==Xl&&0===Xl.tag&&!(6&Rl)&&Tu();var t=Rl;Rl|=1;var n=_l.transition,r=Et;try{if(_l.transition=null,Et=1,e)return e()}finally{Et=r,_l.transition=n,!(6&(Rl=t))&&Qo()}}function gu(){jl=Dl.current,_o(Dl)}function mu(e,t){e.finishedWork=null,e.finishedLanes=0;var n=e.timeoutHandle;if(-1!==n&&(e.timeoutHandle=-1,uo(n)),null!==Al)for(n=Al.return;null!==n;){var r=n;switch(si(r),r.tag){case 1:null!=(r=r.type.childContextTypes)&&Mo();break;case 3:na(),_o(zo),_o(Ao),la();break;case 5:oa(r);break;case 4:na();break;case 13:case 19:_o(ia);break;case 10:Ii(r.type._context);break;case 22:case 23:gu()}n=n.return}if(Il=e,Al=e=Du(e.current,null),zl=jl=t,Fl=0,Ml=null,$l=Bl=Ul=0,Hl=Vl=null,null!==Di){for(t=0;t<Di.length;t++)if(null!==(r=(n=Di[t]).interleaved)){n.interleaved=null;var o=r.next,i=n.pending;if(null!==i){var a=i.next;i.next=o,r.next=a}n.pending=r}Di=null}return e}function yu(e,t){for(;;){var r=Al;try{if(Ri(),ua.current=rs,ga){for(var o=fa.memoizedState;null!==o;){var i=o.queue;null!==i&&(i.pending=null),o=o.next}ga=!1}if(da=0,ha=pa=fa=null,ma=!1,ya=0,Ll.current=null,null===r||null===r.return){Fl=1,Ml=t,Al=null;break}e:{var a=e,s=r.return,l=r,u=t;if(t=zl,l.flags|=32768,null!==u&&"object"==typeof u&&"function"==typeof u.then){var c=u,d=l,f=d.tag;if(!(1&d.mode||0!==f&&11!==f&&15!==f)){var p=d.alternate;p?(d.updateQueue=p.updateQueue,d.memoizedState=p.memoizedState,d.lanes=p.lanes):(d.updateQueue=null,d.memoizedState=null)}var h=ks(s);if(null!==h){h.flags&=-257,ws(h,s,l,0,t),1&h.mode&&bs(a,c,t),u=c;var g=(t=h).updateQueue;if(null===g){var m=new Set;m.add(u),t.updateQueue=m}else g.add(u);break e}if(!(1&t)){bs(a,c,t),bu();break e}u=Error(n(426))}else if(ci&&1&l.mode){var y=ks(s);if(null!==y){!(65536&y.flags)&&(y.flags|=256),ws(y,s,l,0,t),ki(hs(u,l));break e}}a=u=hs(u,l),4!==Fl&&(Fl=2),null===Vl?Vl=[a]:Vl.push(a),a=s;do{switch(a.tag){case 3:a.flags|=65536,t&=-t,a.lanes|=t,Ki(a,ys(0,u,t));break e;case 1:l=u;var v=a.type,b=a.stateNode;if(!(128&a.flags||"function"!=typeof v.getDerivedStateFromError&&(null===b||"function"!=typeof b.componentDidCatch||null!==Yl&&Yl.has(b)))){a.flags|=65536,t&=-t,a.lanes|=t,Ki(a,vs(a,l,t));break e}}a=a.return}while(null!==a)}Eu(r)}catch(k){t=k,Al===r&&null!==r&&(Al=r=r.return);continue}break}}function vu(){var e=Pl.current;return Pl.current=rs,null===e?rs:e}function bu(){0!==Fl&&3!==Fl&&2!==Fl||(Fl=4),null===Il||!(268435455&Ul)&&!(268435455&Bl)||du(Il,zl)}function ku(e,t){var r=Rl;Rl|=2;var o=vu();for(Il===e&&zl===t||(Kl=null,mu(e,t));;)try{wu();break}catch(Ie){yu(e,Ie)}if(Ri(),Rl=r,Pl.current=o,null!==Al)throw Error(n(261));return Il=null,zl=0,Fl}function wu(){for(;null!==Al;)Su(Al)}function xu(){for(;null!==Al&&!et();)Su(Al)}function Su(e){var t=Nl(e.alternate,e,jl);e.memoizedProps=e.pendingProps,null===t?Eu(e):Al=t,Ll.current=null}function Eu(e){var t=e;do{var n=t.alternate;if(e=t.return,32768&t.flags){if(null!==(n=Xs(n,t)))return n.flags&=32767,void(Al=n);if(null===e)return Fl=6,void(Al=null);e.flags|=32768,e.subtreeFlags=0,e.deletions=null}else if(null!==(n=Gs(n,t,jl)))return void(Al=n);if(null!==(t=t.sibling))return void(Al=t);Al=t=e}while(null!==t);0===Fl&&(Fl=5)}function Cu(e,t,r){var o=Et,i=_l.transition;try{_l.transition=null,Et=1,function(e,t,r,o){do{Tu()}while(null!==Xl);if(6&Rl)throw Error(n(327));r=e.finishedWork;var i=e.finishedLanes;if(null===r)return null;if(e.finishedWork=null,e.finishedLanes=0,r===e.current)throw Error(n(177));e.callbackNode=null,e.callbackPriority=0;var a=r.lanes|r.childLanes;if(function(e,t){var n=e.pendingLanes&~t;e.pendingLanes=t,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=t,e.mutableReadLanes&=t,e.entangledLanes&=t,t=e.entanglements;var r=e.eventTimes;for(e=e.expirationTimes;0<n;){var o=31-dt(n),i=1<<o;t[o]=0,r[o]=-1,e[o]=-1,n&=~i}}(e,a),e===Il&&(Al=Il=null,zl=0),!(2064&r.subtreeFlags)&&!(2064&r.flags)||Gl||(Gl=!0,Iu(at,function(){return Tu(),null})),a=!!(15990&r.flags),!!(15990&r.subtreeFlags)||a){a=_l.transition,_l.transition=null;var s=Et;Et=1;var l=Rl;Rl|=4,Ll.current=null,function(e,t){if(io=Jt,vr(e=yr())){if("selectionStart"in e)var r={start:e.selectionStart,end:e.selectionEnd};else e:{var o=(r=(r=e.ownerDocument)&&r.defaultView||window).getSelection&&r.getSelection();if(o&&0!==o.rangeCount){r=o.anchorNode;var i=o.anchorOffset,a=o.focusNode;o=o.focusOffset;try{r.nodeType,a.nodeType}catch(w){r=null;break e}var s=0,l=-1,u=-1,c=0,d=0,f=e,p=null;t:for(;;){for(var h;f!==r||0!==i&&3!==f.nodeType||(l=s+i),f!==a||0!==o&&3!==f.nodeType||(u=s+o),3===f.nodeType&&(s+=f.nodeValue.length),null!==(h=f.firstChild);)p=f,f=h;for(;;){if(f===e)break t;if(p===r&&++c===i&&(l=s),p===a&&++d===o&&(u=s),null!==(h=f.nextSibling))break;p=(f=p).parentNode}f=h}r=-1===l||-1===u?null:{start:l,end:u}}else r=null}r=r||{start:0,end:0}}else r=null;for(ao={focusedElem:e,selectionRange:r},Jt=!1,nl=t;null!==nl;)if(e=(t=nl).child,1028&t.subtreeFlags&&null!==e)e.return=t,nl=e;else for(;null!==nl;){t=nl;try{var g=t.alternate;if(1024&t.flags)switch(t.tag){case 0:case 11:case 15:case 5:case 6:case 4:case 17:break;case 1:if(null!==g){var m=g.memoizedProps,y=g.memoizedState,v=t.stateNode,b=v.getSnapshotBeforeUpdate(t.elementType===t.type?m:ss(t.type,m),y);v.__reactInternalSnapshotBeforeUpdate=b}break;case 3:var k=t.stateNode.containerInfo;1===k.nodeType?k.textContent="":9===k.nodeType&&k.documentElement&&k.removeChild(k.documentElement);break;default:throw Error(n(163))}}catch(w){Ou(t,t.return,w)}if(null!==(e=t.sibling)){e.return=t.return,nl=e;break}nl=t.return}g=il,il=!1}(e,r),kl(r,e),br(ao),Jt=!!io,ao=io=null,e.current=r,xl(r),tt(),Rl=l,Et=s,_l.transition=a}else e.current=r;if(Gl&&(Gl=!1,Xl=e,Zl=i),a=e.pendingLanes,0===a&&(Yl=null),function(e){if(ct&&"function"==typeof ct.onCommitFiberRoot)try{ct.onCommitFiberRoot(ut,e,void 0,!(128&~e.current.flags))}catch(t){}}(r.stateNode),su(e,nt()),null!==t)for(o=e.onRecoverableError,r=0;r<t.length;r++)i=t[r],o(i.value,{componentStack:i.stack,digest:i.digest});if(Ql)throw Ql=!1,e=Jl,Jl=null,e;!!(1&Zl)&&0!==e.tag&&Tu(),a=e.pendingLanes,1&a?e===tu?eu++:(eu=0,tu=e):eu=0,Qo()}(e,t,r,o)}finally{_l.transition=i,Et=o}return null}function Tu(){if(null!==Xl){var e=Ct(Zl),t=_l.transition,r=Et;try{if(_l.transition=null,Et=16>e?16:e,null===Xl)var o=!1;else{if(e=Xl,Xl=null,Zl=0,6&Rl)throw Error(n(331));var i=Rl;for(Rl|=4,nl=e.current;null!==nl;){var a=nl,s=a.child;if(16&nl.flags){var l=a.deletions;if(null!==l){for(var u=0;u<l.length;u++){var c=l[u];for(nl=c;null!==nl;){var d=nl;switch(d.tag){case 0:case 11:case 15:al(8,d,a)}var f=d.child;if(null!==f)f.return=d,nl=f;else for(;null!==nl;){var p=(d=nl).sibling,h=d.return;if(ul(d),d===c){nl=null;break}if(null!==p){p.return=h,nl=p;break}nl=h}}}var g=a.alternate;if(null!==g){var m=g.child;if(null!==m){g.child=null;do{var y=m.sibling;m.sibling=null,m=y}while(null!==m)}}nl=a}}if(2064&a.subtreeFlags&&null!==s)s.return=a,nl=s;else e:for(;null!==nl;){if(2048&(a=nl).flags)switch(a.tag){case 0:case 11:case 15:al(9,a,a.return)}var v=a.sibling;if(null!==v){v.return=a.return,nl=v;break e}nl=a.return}}var b=e.current;for(nl=b;null!==nl;){var k=(s=nl).child;if(2064&s.subtreeFlags&&null!==k)k.return=s,nl=k;else e:for(s=b;null!==nl;){if(2048&(l=nl).flags)try{switch(l.tag){case 0:case 11:case 15:sl(9,l)}}catch(x){Ou(l,l.return,x)}if(l===s){nl=null;break e}var w=l.sibling;if(null!==w){w.return=l.return,nl=w;break e}nl=l.return}}if(Rl=i,Qo(),ct&&"function"==typeof ct.onPostCommitFiberRoot)try{ct.onPostCommitFiberRoot(ut,e)}catch(x){}o=!0}return o}finally{Et=r,_l.transition=t}}return!1}function Nu(e,t,n){e=qi(e,t=ys(0,t=hs(n,t),1),1),t=ou(),null!==e&&(xt(e,1,t),su(e,t))}function Ou(e,t,n){if(3===e.tag)Nu(e,e,n);else for(;null!==t;){if(3===t.tag){Nu(t,e,n);break}if(1===t.tag){var r=t.stateNode;if("function"==typeof t.type.getDerivedStateFromError||"function"==typeof r.componentDidCatch&&(null===Yl||!Yl.has(r))){t=qi(t,e=vs(t,e=hs(n,e),1),1),e=ou(),null!==t&&(xt(t,1,e),su(t,e));break}}t=t.return}}function Pu(e,t,n){var r=e.pingCache;null!==r&&r.delete(t),t=ou(),e.pingedLanes|=e.suspendedLanes&n,Il===e&&(zl&n)===n&&(4===Fl||3===Fl&&(130023424&zl)===zl&&500>nt()-ql?mu(e,0):$l|=n),su(e,t)}function Lu(e,t){0===t&&(1&e.mode?(t=gt,!(130023424&(gt<<=1))&&(gt=4194304)):t=1);var n=ou();null!==(e=Ui(e,t))&&(xt(e,t,n),su(e,n))}function _u(e){var t=e.memoizedState,n=0;null!==t&&(n=t.retryLane),Lu(e,n)}function Ru(e,t){var r=0;switch(e.tag){case 13:var o=e.stateNode,i=e.memoizedState;null!==i&&(r=i.retryLane);break;case 19:o=e.stateNode;break;default:throw Error(n(314))}null!==o&&o.delete(t),Lu(e,r)}function Iu(e,t){return Xe(e,t)}function Au(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function zu(e,t,n,r){return new Au(e,t,n,r)}function ju(e){return!(!(e=e.prototype)||!e.isReactComponent)}function Du(e,t){var n=e.alternate;return null===n?((n=zu(e.tag,t,e.key,e.mode)).elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=14680064&e.flags,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=null===t?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n}function Fu(e,t,r,o,i,a){var s=2;if(o=e,"function"==typeof e)ju(e)&&(s=1);else if("string"==typeof e)s=5;else e:switch(e){case E:return Mu(r.children,i,a,t);case C:s=8,i|=8;break;case T:return(e=zu(12,r,t,2|i)).elementType=T,e.lanes=a,e;case L:return(e=zu(13,r,t,i)).elementType=L,e.lanes=a,e;case _:return(e=zu(19,r,t,i)).elementType=_,e.lanes=a,e;case A:return Uu(r,i,a,t);default:if("object"==typeof e&&null!==e)switch(e.$$typeof){case N:s=10;break e;case O:s=9;break e;case P:s=11;break e;case R:s=14;break e;case I:s=16,o=null;break e}throw Error(n(130,null==e?e:typeof e,""))}return(t=zu(s,r,t,i)).elementType=e,t.type=o,t.lanes=a,t}function Mu(e,t,n,r){return(e=zu(7,e,r,t)).lanes=n,e}function Uu(e,t,n,r){return(e=zu(22,e,r,t)).elementType=A,e.lanes=n,e.stateNode={isHidden:!1},e}function Bu(e,t,n){return(e=zu(6,e,null,t)).lanes=n,e}function $u(e,t,n){return(t=zu(4,null!==e.children?e.children:[],e.key,t)).lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function Vu(e,t,n,r,o){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=wt(0),this.expirationTimes=wt(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=wt(0),this.identifierPrefix=r,this.onRecoverableError=o,this.mutableSourceEagerHydrationData=null}function Hu(e,t,n,r,o,i,a,s,l){return e=new Vu(e,t,n,s,l),1===t?(t=1,!0===i&&(t|=8)):t=0,i=zu(3,null,null,t),e.current=i,i.stateNode=e,i.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},$i(i),e}function qu(e){if(!e)return Io;e:{if(Ke(e=e._reactInternals)!==e||1!==e.tag)throw Error(n(170));var t=e;do{switch(t.tag){case 3:t=t.stateNode.context;break e;case 1:if(Fo(t.type)){t=t.stateNode.__reactInternalMemoizedMergedChildContext;break e}}t=t.return}while(null!==t);throw Error(n(171))}if(1===e.tag){var r=e.type;if(Fo(r))return Bo(e,r,t)}return t}function Wu(e,t,n,r,o,i,a,s,l){return(e=Hu(n,r,!0,e,0,i,0,s,l)).context=qu(null),n=e.current,(i=Hi(r=ou(),o=iu(n))).callback=null!=t?t:null,qi(n,i,o),e.current.lanes=o,xt(e,o,r),su(e,r),e}function Ku(e,t,n,r){var o=t.current,i=ou(),a=iu(o);return n=qu(n),null===t.context?t.context=n:t.pendingContext=n,(t=Hi(i,a)).payload={element:e},null!==(r=void 0===r?null:r)&&(t.callback=r),null!==(e=qi(o,t,a))&&(au(e,o,a,i),Wi(e,o,a)),a}function Qu(e){return(e=e.current).child?(e.child.tag,e.child.stateNode):null}function Ju(e,t){if(null!==(e=e.memoizedState)&&null!==e.dehydrated){var n=e.retryLane;e.retryLane=0!==n&&n<t?n:t}}function Yu(e,t){Ju(e,t),(e=e.alternate)&&Ju(e,t)}Nl=function(e,t,r){if(null!==e)if(e.memoizedProps!==t.pendingProps||zo.current)Ss=!0;else{if(0===(e.lanes&r)&&!(128&t.flags))return Ss=!1,function(e,t,n){switch(t.tag){case 3:Is(t),bi();break;case 5:ra(t);break;case 1:Fo(t.type)&&$o(t);break;case 4:ta(t,t.stateNode.containerInfo);break;case 10:var r=t.type._context,o=t.memoizedProps.value;Ro(Oi,r._currentValue),r._currentValue=o;break;case 13:if(null!==(r=t.memoizedState))return null!==r.dehydrated?(Ro(ia,1&ia.current),t.flags|=128,null):0!==(n&t.child.childLanes)?Bs(e,t,n):(Ro(ia,1&ia.current),null!==(e=Qs(e,t,n))?e.sibling:null);Ro(ia,1&ia.current);break;case 19:if(r=0!==(n&t.childLanes),128&e.flags){if(r)return Ws(e,t,n);t.flags|=128}if(null!==(o=t.memoizedState)&&(o.rendering=null,o.tail=null,o.lastEffect=null),Ro(ia,ia.current),r)break;return null;case 22:case 23:return t.lanes=0,Os(e,t,n)}return Qs(e,t,n)}(e,t,r);Ss=!!(131072&e.flags)}else Ss=!1,ci&&1048576&t.flags&&ii(t,Xo,t.index);switch(t.lanes=0,t.tag){case 2:var o=t.type;Ks(e,t),e=t.pendingProps;var i=Do(t,Ao.current);zi(t,r),i=wa(null,t,o,e,i,r);var a=xa();return t.flags|=1,"object"==typeof i&&null!==i&&"function"==typeof i.render&&void 0===i.$$typeof?(t.tag=1,t.memoizedState=null,t.updateQueue=null,Fo(o)?(a=!0,$o(t)):a=!1,t.memoizedState=null!==i.state&&void 0!==i.state?i.state:null,$i(t),i.updater=us,t.stateNode=i,i._reactInternals=t,ps(t,o,e,r),t=Rs(null,t,o,!0,a,r)):(t.tag=0,ci&&a&&ai(t),Es(null,t,i,r),t=t.child),t;case 16:o=t.elementType;e:{switch(Ks(e,t),e=t.pendingProps,o=(i=o._init)(o._payload),t.type=o,i=t.tag=function(e){if("function"==typeof e)return ju(e)?1:0;if(null!=e){if((e=e.$$typeof)===P)return 11;if(e===R)return 14}return 2}(o),e=ss(o,e),i){case 0:t=Ls(null,t,o,e,r);break e;case 1:t=_s(null,t,o,e,r);break e;case 11:t=Cs(null,t,o,e,r);break e;case 14:t=Ts(null,t,o,ss(o.type,e),r);break e}throw Error(n(306,o,""))}return t;case 0:return o=t.type,i=t.pendingProps,Ls(e,t,o,i=t.elementType===o?i:ss(o,i),r);case 1:return o=t.type,i=t.pendingProps,_s(e,t,o,i=t.elementType===o?i:ss(o,i),r);case 3:e:{if(Is(t),null===e)throw Error(n(387));o=t.pendingProps,i=(a=t.memoizedState).element,Vi(e,t),Qi(t,o,null,r);var s=t.memoizedState;if(o=s.element,a.isDehydrated){if(a={element:o,isDehydrated:!1,cache:s.cache,pendingSuspenseBoundaries:s.pendingSuspenseBoundaries,transitions:s.transitions},t.updateQueue.baseState=a,t.memoizedState=a,256&t.flags){t=As(e,t,o,r,i=hs(Error(n(423)),t));break e}if(o!==i){t=As(e,t,o,r,i=hs(Error(n(424)),t));break e}for(ui=go(t.stateNode.containerInfo.firstChild),li=t,ci=!0,di=null,r=Ni(t,null,o,r),t.child=r;r;)r.flags=-3&r.flags|4096,r=r.sibling}else{if(bi(),o===i){t=Qs(e,t,r);break e}Es(e,t,o,r)}t=t.child}return t;case 5:return ra(t),null===e&&gi(t),o=t.type,i=t.pendingProps,a=null!==e?e.memoizedProps:null,s=i.children,so(o,i)?s=null:null!==a&&so(o,a)&&(t.flags|=32),Ps(e,t),Es(e,t,s,r),t.child;case 6:return null===e&&gi(t),null;case 13:return Bs(e,t,r);case 4:return ta(t,t.stateNode.containerInfo),o=t.pendingProps,null===e?t.child=Ti(t,null,o,r):Es(e,t,o,r),t.child;case 11:return o=t.type,i=t.pendingProps,Cs(e,t,o,i=t.elementType===o?i:ss(o,i),r);case 7:return Es(e,t,t.pendingProps,r),t.child;case 8:case 12:return Es(e,t,t.pendingProps.children,r),t.child;case 10:e:{if(o=t.type._context,i=t.pendingProps,a=t.memoizedProps,s=i.value,Ro(Oi,o._currentValue),o._currentValue=s,null!==a)if(fr(a.value,s)){if(a.children===i.children&&!zo.current){t=Qs(e,t,r);break e}}else for(null!==(a=t.child)&&(a.return=t);null!==a;){var l=a.dependencies;if(null!==l){s=a.child;for(var u=l.firstContext;null!==u;){if(u.context===o){if(1===a.tag){(u=Hi(-1,r&-r)).tag=2;var c=a.updateQueue;if(null!==c){var d=(c=c.shared).pending;null===d?u.next=u:(u.next=d.next,d.next=u),c.pending=u}}a.lanes|=r,null!==(u=a.alternate)&&(u.lanes|=r),Ai(a.return,r,t),l.lanes|=r;break}u=u.next}}else if(10===a.tag)s=a.type===t.type?null:a.child;else if(18===a.tag){if(null===(s=a.return))throw Error(n(341));s.lanes|=r,null!==(l=s.alternate)&&(l.lanes|=r),Ai(s,r,t),s=a.sibling}else s=a.child;if(null!==s)s.return=a;else for(s=a;null!==s;){if(s===t){s=null;break}if(null!==(a=s.sibling)){a.return=s.return,s=a;break}s=s.return}a=s}Es(e,t,i.children,r),t=t.child}return t;case 9:return i=t.type,o=t.pendingProps.children,zi(t,r),o=o(i=ji(i)),t.flags|=1,Es(e,t,o,r),t.child;case 14:return i=ss(o=t.type,t.pendingProps),Ts(e,t,o,i=ss(o.type,i),r);case 15:return Ns(e,t,t.type,t.pendingProps,r);case 17:return o=t.type,i=t.pendingProps,i=t.elementType===o?i:ss(o,i),Ks(e,t),t.tag=1,Fo(o)?(e=!0,$o(t)):e=!1,zi(t,r),ds(t,o,i),ps(t,o,i,r),Rs(null,t,o,!0,e,r);case 19:return Ws(e,t,r);case 22:return Os(e,t,r)}throw Error(n(156,t.tag))};var Gu="function"==typeof reportError?reportError:function(e){};function Xu(e){this._internalRoot=e}function Zu(e){this._internalRoot=e}function ec(e){return!(!e||1!==e.nodeType&&9!==e.nodeType&&11!==e.nodeType)}function tc(e){return!(!e||1!==e.nodeType&&9!==e.nodeType&&11!==e.nodeType&&(8!==e.nodeType||" react-mount-point-unstable "!==e.nodeValue))}function nc(){}function rc(e,t,n,r,o){var i=n._reactRootContainer;if(i){var a=i;if("function"==typeof o){var s=o;o=function(){var e=Qu(a);s.call(e)}}Ku(t,a,e,o)}else a=function(e,t,n,r,o){if(o){if("function"==typeof r){var i=r;r=function(){var e=Qu(a);i.call(e)}}var a=Wu(t,r,e,0,null,!1,0,"",nc);return e._reactRootContainer=a,e[ko]=a.current,Kr(8===e.nodeType?e.parentNode:e),hu(),a}for(;o=e.lastChild;)e.removeChild(o);if("function"==typeof r){var s=r;r=function(){var e=Qu(l);s.call(e)}}var l=Hu(e,0,!1,null,0,!1,0,"",nc);return e._reactRootContainer=l,e[ko]=l.current,Kr(8===e.nodeType?e.parentNode:e),hu(function(){Ku(t,l,n,r)}),l}(n,t,e,o,r);return Qu(a)}Zu.prototype.render=Xu.prototype.render=function(e){var t=this._internalRoot;if(null===t)throw Error(n(409));Ku(e,t,null,null)},Zu.prototype.unmount=Xu.prototype.unmount=function(){var e=this._internalRoot;if(null!==e){this._internalRoot=null;var t=e.containerInfo;hu(function(){Ku(null,e,null,null)}),t[ko]=null}},Zu.prototype.unstable_scheduleHydration=function(e){if(e){var t=Pt();e={blockedOn:null,target:e,priority:t};for(var n=0;n<Ft.length&&0!==t&&t<Ft[n].priority;n++);Ft.splice(n,0,e),0===n&&$t(e)}},Tt=function(e){switch(e.tag){case 3:var t=e.stateNode;if(t.current.memoizedState.isDehydrated){var n=mt(t.pendingLanes);0!==n&&(St(t,1|n),su(t,nt()),!(6&Rl)&&(Wl=nt()+500,Qo()))}break;case 13:hu(function(){var t=Ui(e,1);if(null!==t){var n=ou();au(t,e,1,n)}}),Yu(e,1)}},Nt=function(e){if(13===e.tag){var t=Ui(e,134217728);if(null!==t)au(t,e,134217728,ou());Yu(e,134217728)}},Ot=function(e){if(13===e.tag){var t=iu(e),n=Ui(e,t);if(null!==n)au(n,e,t,ou());Yu(e,t)}},Pt=function(){return Et},Lt=function(e,t){var n=Et;try{return Et=e,t()}finally{Et=n}},Se=function(e,t,r){switch(t){case"input":if(Z(e,r),t=r.name,"radio"===r.type&&null!=t){for(r=e;r.parentNode;)r=r.parentNode;for(r=r.querySelectorAll("input[name="+JSON.stringify(""+t)+'][type="radio"]'),t=0;t<r.length;t++){var o=r[t];if(o!==e&&o.form===e.form){var i=No(o);if(!i)throw Error(n(90));Q(o),Z(o,i)}}}break;case"textarea":ae(e,r);break;case"select":null!=(t=r.value)&&re(e,!!r.multiple,t,!1)}},Pe=pu,Le=hu;var oc={usingClientEntryPoint:!1,Events:[Co,To,No,Ne,Oe,pu]},ic={findFiberByHostInstance:Eo,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},ac={bundleType:ic.bundleType,version:ic.version,rendererPackageName:ic.rendererPackageName,rendererConfig:ic.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:w.ReactCurrentDispatcher,findHostInstanceByFiber:function(e){return null===(e=Ye(e))?null:e.stateNode},findFiberByHostInstance:ic.findFiberByHostInstance||function(){return null},findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.3.1-next-f1338f8080-20240426"};if("undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__){var sc=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!sc.isDisabled&&sc.supportsFiber)try{ut=sc.inject(ac),ct=sc}catch(de){}}return y.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=oc,y.createPortal=function(e,t){var r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null;if(!ec(t))throw Error(n(200));return function(e,t,n){var r=3<arguments.length&&void 0!==arguments[3]?arguments[3]:null;return{$$typeof:S,key:null==r?null:""+r,children:e,containerInfo:t,implementation:n}}(e,t,null,r)},y.createRoot=function(e,t){if(!ec(e))throw Error(n(299));var r=!1,o="",i=Gu;return null!=t&&(!0===t.unstable_strictMode&&(r=!0),void 0!==t.identifierPrefix&&(o=t.identifierPrefix),void 0!==t.onRecoverableError&&(i=t.onRecoverableError)),t=Hu(e,1,!1,null,0,r,0,o,i),e[ko]=t.current,Kr(8===e.nodeType?e.parentNode:e),new Xu(t)},y.findDOMNode=function(e){if(null==e)return null;if(1===e.nodeType)return e;var t=e._reactInternals;if(void 0===t){if("function"==typeof e.render)throw Error(n(188));throw e=Object.keys(e).join(","),Error(n(268,e))}return e=null===(e=Ye(t))?null:e.stateNode},y.flushSync=function(e){return hu(e)},y.hydrate=function(e,t,r){if(!tc(t))throw Error(n(200));return rc(null,e,t,!0,r)},y.hydrateRoot=function(e,t,r){if(!ec(e))throw Error(n(405));var o=null!=r&&r.hydratedSources||null,i=!1,a="",s=Gu;if(null!=r&&(!0===r.unstable_strictMode&&(i=!0),void 0!==r.identifierPrefix&&(a=r.identifierPrefix),void 0!==r.onRecoverableError&&(s=r.onRecoverableError)),t=Wu(t,null,e,1,null!=r?r:null,i,0,a,s),e[ko]=t.current,Kr(e),o)for(e=0;e<o.length;e++)i=(i=(r=o[e])._getVersion)(r._source),null==t.mutableSourceEagerHydrationData?t.mutableSourceEagerHydrationData=[r,i]:t.mutableSourceEagerHydrationData.push(r,i);return new Zu(t)},y.render=function(e,t,r){if(!tc(t))throw Error(n(200));return rc(null,e,t,!1,r)},y.unmountComponentAtNode=function(e){if(!tc(e))throw Error(n(40));return!!e._reactRootContainer&&(hu(function(){rc(null,null,e,!1,function(){e._reactRootContainer=null,e[ko]=null})}),!0)},y.unstable_batchedUpdates=pu,y.unstable_renderSubtreeIntoContainer=function(e,t,r,o){if(!tc(r))throw Error(n(200));if(null==e||void 0===e._reactInternals)throw Error(n(38));return rc(e,t,r,!1,o)},y.version="18.3.1-next-f1338f8080-20240426",y}var x,S,E=function(){if(h)return g;h=1;var e=(p||(p=1,function e(){if("undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE)try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(t){}}(),m.exports=w()),m.exports);return g.createRoot=e.createRoot,g.hydrateRoot=e.hydrateRoot,g}(),C={exports:{}},T={};var N=(S||(S=1,C.exports=function(){if(x)return T;x=1;var e=s(),t=Symbol.for("react.element"),n=Symbol.for("react.fragment"),r=Object.prototype.hasOwnProperty,o=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,i={key:!0,ref:!0,__self:!0,__source:!0};function a(e,n,a){var s,l={},u=null,c=null;for(s in void 0!==a&&(u=""+a),void 0!==n.key&&(u=""+n.key),void 0!==n.ref&&(c=n.ref),n)r.call(n,s)&&!i.hasOwnProperty(s)&&(l[s]=n[s]);if(e&&e.defaultProps)for(s in n=e.defaultProps)void 0===l[s]&&(l[s]=n[s]);return{$$typeof:t,type:e,key:u,ref:c,props:l,_owner:o.current}}return T.Fragment=n,T.jsx=a,T.jsxs=a,T}()),C.exports);const O={},P=(e,t,n,r)=>{I(n)&&O[n]||(I(n)&&(O[n]=new Date),((e,t,n,r)=>{const o=[n,{code:t,...r||{}}];if(e?.services?.logger?.forward)return e.services.logger.forward(o,"warn","react-i18next::",!0);I(o[0])&&(o[0]=`react-i18next:: ${o[0]}`),e?.services?.logger?.warn?e.services.logger.warn(...o):console})(e,t,n,r))},L=(e,t)=>()=>{if(e.isInitialized)t();else{const n=()=>{setTimeout(()=>{e.off("initialized",n)},0),t()};e.on("initialized",n)}},_=(e,t,n)=>{e.loadNamespaces(t,L(e,n))},R=(e,t,n,r)=>{if(I(n)&&(n=[n]),e.options.preload&&e.options.preload.indexOf(t)>-1)return _(e,n,r);n.forEach(t=>{e.options.ns.indexOf(t)<0&&e.options.ns.push(t)}),e.loadLanguages(t,L(e,r))},I=e=>"string"==typeof e,A=/&(?:amp|#38|lt|#60|gt|#62|apos|#39|quot|#34|nbsp|#160|copy|#169|reg|#174|hellip|#8230|#x2F|#47);/g,z={"&amp;":"&","&#38;":"&","&lt;":"<","&#60;":"<","&gt;":">","&#62;":">","&apos;":"'","&#39;":"'","&quot;":'"',"&#34;":'"',"&nbsp;":" ","&#160;":" ","&copy;":"©","&#169;":"©","&reg;":"®","&#174;":"®","&hellip;":"…","&#8230;":"…","&#x2F;":"/","&#47;":"/"},j=e=>z[e];let D={bindI18n:"languageChanged",bindI18nStore:"",transEmptyNodeValue:"",transSupportBasicHtmlNodes:!0,transWrapTextNodes:"",transKeepBasicHtmlNodesFor:["br","strong","i","p"],useSuspense:!0,unescape:e=>e.replace(A,j)};let F;const M={type:"3rdParty",init(e){((e={})=>{D={...D,...e}})(e.options.react),(e=>{F=e})(e)}},U=l.createContext();class B{constructor(){this.usedNamespaces={}}addUsedNamespaces(e){e.forEach(e=>{this.usedNamespaces[e]||(this.usedNamespaces[e]=!0)})}getUsedNamespaces(){return Object.keys(this.usedNamespaces)}}const $=(e,t,n,r)=>e.getFixedT(t,n,r),V=(e,t={})=>{const{i18n:n}=t,{i18n:r,defaultNS:o}=l.useContext(U)||{},i=n||r||F;if(i&&!i.reportNamespaces&&(i.reportNamespaces=new B),!i){P(i,"NO_I18NEXT_INSTANCE","useTranslation: You will need to pass in an i18next instance by using initReactI18next");const e=(e,t)=>{return I(t)?t:"object"==typeof(n=t)&&null!==n&&I(t.defaultValue)?t.defaultValue:Array.isArray(e)?e[e.length-1]:e;var n},t=[e,{},!1];return t.t=e,t.i18n={},t.ready=!1,t}i.options.react?.wait&&P(i,"DEPRECATED_OPTION","useTranslation: It seems you are still using the old wait option, you may migrate to the new useSuspense behaviour.");const a={...D,...i.options.react,...t},{useSuspense:s,keyPrefix:u}=a;let c=o||i.options?.defaultNS;c=I(c)?[c]:c||["translation"],i.reportNamespaces.addUsedNamespaces?.(c);const d=(i.isInitialized||i.initializedStoreOnce)&&c.every(e=>((e,t,n={})=>t.languages&&t.languages.length?t.hasLoadedNamespace(e,{lng:n.lng,precheck:(t,r)=>{if(n.bindI18n&&n.bindI18n.indexOf("languageChanging")>-1&&t.services.backendConnector.backend&&t.isLanguageChangingTo&&!r(t.isLanguageChangingTo,e))return!1}}):(P(t,"NO_LANGUAGES","i18n.languages were undefined or empty",{languages:t.languages}),!0))(e,i,a)),f=((e,t,n,r)=>l.useCallback($(e,t,n,r),[e,t,n,r]))(i,t.lng||null,"fallback"===a.nsMode?c:c[0],u),p=()=>f,h=()=>$(i,t.lng||null,"fallback"===a.nsMode?c:c[0],u),[g,m]=l.useState(p);let y=c.join();t.lng&&(y=`${t.lng}${y}`);const v=((e,t)=>{const n=l.useRef();return l.useEffect(()=>{n.current=e},[e,t]),n.current})(y),b=l.useRef(!0);l.useEffect(()=>{const{bindI18n:e,bindI18nStore:n}=a;b.current=!0,d||s||(t.lng?R(i,t.lng,c,()=>{b.current&&m(h)}):_(i,c,()=>{b.current&&m(h)})),d&&v&&v!==y&&b.current&&m(h);const r=()=>{b.current&&m(h)};return e&&i?.on(e,r),n&&i?.store.on(n,r),()=>{b.current=!1,i&&e&&e?.split(" ").forEach(e=>i.off(e,r)),n&&i&&n.split(" ").forEach(e=>i.store.off(e,r))}},[i,y]),l.useEffect(()=>{b.current&&d&&m(p)},[i,u,d]);const k=[g,i,d];if(k.t=g,k.i18n=i,k.ready=d,d)return k;if(!d&&!s)return k;throw new Promise(e=>{t.lng?R(i,t.lng,c,()=>e()):_(i,c,()=>e())})};function H({i18n:e,defaultNS:t,children:n}){const r=l.useMemo(()=>({i18n:e,defaultNS:t}),[e,t]);return l.createElement(U.Provider,{value:r},n)}
10
+ */function x(){if(f)return y;f=1;var e=s(),t=k();function n(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n<arguments.length;n++)t+="&args[]="+encodeURIComponent(arguments[n]);return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var r=new Set,o={};function i(e,t){a(e,t),a(e+"Capture",t)}function a(e,t){for(o[e]=t,e=0;e<t.length;e++)r.add(t[e])}var l=!("undefined"==typeof window||void 0===window.document||void 0===window.document.createElement),u=Object.prototype.hasOwnProperty,c=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,d={},p={};function h(e,t,n,r,o,i,a){this.acceptsBooleans=2===t||3===t||4===t,this.attributeName=r,this.attributeNamespace=o,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=i,this.removeEmptyString=a}var g={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){g[e]=new h(e,0,!1,e,null,!1,!1)}),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];g[t]=new h(t,1,!1,e[1],null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(function(e){g[e]=new h(e,2,!1,e.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){g[e]=new h(e,2,!1,e,null,!1,!1)}),"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){g[e]=new h(e,3,!1,e.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(function(e){g[e]=new h(e,3,!0,e,null,!1,!1)}),["capture","download"].forEach(function(e){g[e]=new h(e,4,!1,e,null,!1,!1)}),["cols","rows","size","span"].forEach(function(e){g[e]=new h(e,6,!1,e,null,!1,!1)}),["rowSpan","start"].forEach(function(e){g[e]=new h(e,5,!1,e.toLowerCase(),null,!1,!1)});var m=/[\-:]([a-z])/g;function v(e){return e[1].toUpperCase()}function b(e,t,n,r){var o=g.hasOwnProperty(t)?g[t]:null;(null!==o?0!==o.type:r||!(2<t.length)||"o"!==t[0]&&"O"!==t[0]||"n"!==t[1]&&"N"!==t[1])&&(function(e,t,n,r){if(null==t||function(e,t,n,r){if(null!==n&&0===n.type)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return!r&&(null!==n?!n.acceptsBooleans:"data-"!==(e=e.toLowerCase().slice(0,5))&&"aria-"!==e);default:return!1}}(e,t,n,r))return!0;if(r)return!1;if(null!==n)switch(n.type){case 3:return!t;case 4:return!1===t;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}(t,n,o,r)&&(n=null),r||null===o?function(e){return!!u.call(p,e)||!u.call(d,e)&&(c.test(e)?p[e]=!0:(d[e]=!0,!1))}(t)&&(null===n?e.removeAttribute(t):e.setAttribute(t,""+n)):o.mustUseProperty?e[o.propertyName]=null===n?3!==o.type&&"":n:(t=o.attributeName,r=o.attributeNamespace,null===n?e.removeAttribute(t):(n=3===(o=o.type)||4===o&&!0===n?"":""+n,r?e.setAttributeNS(r,t,n):e.setAttribute(t,n))))}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var t=e.replace(m,v);g[t]=new h(t,1,!1,e,null,!1,!1)}),"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(m,v);g[t]=new h(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)}),["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(m,v);g[t]=new h(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(function(e){g[e]=new h(e,1,!1,e.toLowerCase(),null,!1,!1)}),g.xlinkHref=new h("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(function(e){g[e]=new h(e,1,!1,e.toLowerCase(),null,!0,!0)});var x=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,w=Symbol.for("react.element"),S=Symbol.for("react.portal"),E=Symbol.for("react.fragment"),C=Symbol.for("react.strict_mode"),T=Symbol.for("react.profiler"),O=Symbol.for("react.provider"),N=Symbol.for("react.context"),P=Symbol.for("react.forward_ref"),L=Symbol.for("react.suspense"),R=Symbol.for("react.suspense_list"),_=Symbol.for("react.memo"),I=Symbol.for("react.lazy"),A=Symbol.for("react.offscreen"),D=Symbol.iterator;function z(e){return null===e||"object"!=typeof e?null:"function"==typeof(e=D&&e[D]||e["@@iterator"])?e:null}var j,F=Object.assign;function M(e){if(void 0===j)try{throw Error()}catch(n){var t=n.stack.trim().match(/\n( *(at )?)/);j=t&&t[1]||""}return"\n"+j+e}var U=!1;function B(e,t){if(!e||U)return"";U=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(t)if(t=function(){throw Error()},Object.defineProperty(t.prototype,"props",{set:function(){throw Error()}}),"object"==typeof Reflect&&Reflect.construct){try{Reflect.construct(t,[])}catch(Fe){var r=Fe}Reflect.construct(e,[],t)}else{try{t.call()}catch(Fe){r=Fe}e.call(t.prototype)}else{try{throw Error()}catch(Fe){r=Fe}e()}}catch(Fe){if(Fe&&r&&"string"==typeof Fe.stack){for(var o=Fe.stack.split("\n"),i=r.stack.split("\n"),a=o.length-1,s=i.length-1;1<=a&&0<=s&&o[a]!==i[s];)s--;for(;1<=a&&0<=s;a--,s--)if(o[a]!==i[s]){if(1!==a||1!==s)do{if(a--,0>--s||o[a]!==i[s]){var l="\n"+o[a].replace(" at new "," at ");return e.displayName&&l.includes("<anonymous>")&&(l=l.replace("<anonymous>",e.displayName)),l}}while(1<=a&&0<=s);break}}}finally{U=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?M(e):""}function $(e){switch(e.tag){case 5:return M(e.type);case 16:return M("Lazy");case 13:return M("Suspense");case 19:return M("SuspenseList");case 0:case 2:case 15:return e=B(e.type,!1);case 11:return e=B(e.type.render,!1);case 1:return e=B(e.type,!0);default:return""}}function V(e){if(null==e)return null;if("function"==typeof e)return e.displayName||e.name||null;if("string"==typeof e)return e;switch(e){case E:return"Fragment";case S:return"Portal";case T:return"Profiler";case C:return"StrictMode";case L:return"Suspense";case R:return"SuspenseList"}if("object"==typeof e)switch(e.$$typeof){case N:return(e.displayName||"Context")+".Consumer";case O:return(e._context.displayName||"Context")+".Provider";case P:var t=e.render;return(e=e.displayName)||(e=""!==(e=t.displayName||t.name||"")?"ForwardRef("+e+")":"ForwardRef"),e;case _:return null!==(t=e.displayName||null)?t:V(e.type)||"Memo";case I:t=e._payload,e=e._init;try{return V(e(t))}catch(n){}}return null}function H(e){var t=e.type;switch(e.tag){case 24:return"Cache";case 9:return(t.displayName||"Context")+".Consumer";case 10:return(t._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return e=(e=t.render).displayName||e.name||"",t.displayName||(""!==e?"ForwardRef("+e+")":"ForwardRef");case 7:return"Fragment";case 5:return t;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return V(t);case 8:return t===C?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if("function"==typeof t)return t.displayName||t.name||null;if("string"==typeof t)return t}return null}function q(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":case"object":return e;default:return""}}function W(e){var t=e.type;return(e=e.nodeName)&&"input"===e.toLowerCase()&&("checkbox"===t||"radio"===t)}function K(e){e._valueTracker||(e._valueTracker=function(e){var t=W(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),r=""+e[t];if(!e.hasOwnProperty(t)&&void 0!==n&&"function"==typeof n.get&&"function"==typeof n.set){var o=n.get,i=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return o.call(this)},set:function(e){r=""+e,i.call(this,e)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(e){r=""+e},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}(e))}function Q(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=W(e)?e.checked?"true":"false":e.value),(e=r)!==n&&(t.setValue(e),!0)}function J(e){if(void 0===(e=e||("undefined"!=typeof document?document:void 0)))return null;try{return e.activeElement||e.body}catch(t){return e.body}}function Y(e,t){var n=t.checked;return F({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:null!=n?n:e._wrapperState.initialChecked})}function G(e,t){var n=null==t.defaultValue?"":t.defaultValue,r=null!=t.checked?t.checked:t.defaultChecked;n=q(null!=t.value?t.value:n),e._wrapperState={initialChecked:r,initialValue:n,controlled:"checkbox"===t.type||"radio"===t.type?null!=t.checked:null!=t.value}}function X(e,t){null!=(t=t.checked)&&b(e,"checked",t,!1)}function Z(e,t){X(e,t);var n=q(t.value),r=t.type;if(null!=n)"number"===r?(0===n&&""===e.value||e.value!=n)&&(e.value=""+n):e.value!==""+n&&(e.value=""+n);else if("submit"===r||"reset"===r)return void e.removeAttribute("value");t.hasOwnProperty("value")?te(e,t.type,n):t.hasOwnProperty("defaultValue")&&te(e,t.type,q(t.defaultValue)),null==t.checked&&null!=t.defaultChecked&&(e.defaultChecked=!!t.defaultChecked)}function ee(e,t,n){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var r=t.type;if(!("submit"!==r&&"reset"!==r||void 0!==t.value&&null!==t.value))return;t=""+e._wrapperState.initialValue,n||t===e.value||(e.value=t),e.defaultValue=t}""!==(n=e.name)&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,""!==n&&(e.name=n)}function te(e,t,n){"number"===t&&J(e.ownerDocument)===e||(null==n?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var ne=Array.isArray;function re(e,t,n,r){if(e=e.options,t){t={};for(var o=0;o<n.length;o++)t["$"+n[o]]=!0;for(n=0;n<e.length;n++)o=t.hasOwnProperty("$"+e[n].value),e[n].selected!==o&&(e[n].selected=o),o&&r&&(e[n].defaultSelected=!0)}else{for(n=""+q(n),t=null,o=0;o<e.length;o++){if(e[o].value===n)return e[o].selected=!0,void(r&&(e[o].defaultSelected=!0));null!==t||e[o].disabled||(t=e[o])}null!==t&&(t.selected=!0)}}function oe(e,t){if(null!=t.dangerouslySetInnerHTML)throw Error(n(91));return F({},t,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue})}function ie(e,t){var r=t.value;if(null==r){if(r=t.children,t=t.defaultValue,null!=r){if(null!=t)throw Error(n(92));if(ne(r)){if(1<r.length)throw Error(n(93));r=r[0]}t=r}null==t&&(t=""),r=t}e._wrapperState={initialValue:q(r)}}function ae(e,t){var n=q(t.value),r=q(t.defaultValue);null!=n&&((n=""+n)!==e.value&&(e.value=n),null==t.defaultValue&&e.defaultValue!==n&&(e.defaultValue=n)),null!=r&&(e.defaultValue=""+r)}function se(e){var t=e.textContent;t===e._wrapperState.initialValue&&""!==t&&null!==t&&(e.value=t)}function le(e){switch(e){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function ue(e,t){return null==e||"http://www.w3.org/1999/xhtml"===e?le(t):"http://www.w3.org/2000/svg"===e&&"foreignObject"===t?"http://www.w3.org/1999/xhtml":e}var ce,de,fe=(de=function(e,t){if("http://www.w3.org/2000/svg"!==e.namespaceURI||"innerHTML"in e)e.innerHTML=t;else{for((ce=ce||document.createElement("div")).innerHTML="<svg>"+t.valueOf().toString()+"</svg>",t=ce.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}},"undefined"!=typeof MSApp&&MSApp.execUnsafeLocalFunction?function(e,t,n,r){MSApp.execUnsafeLocalFunction(function(){return de(e,t)})}:de);function pe(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&3===n.nodeType)return void(n.nodeValue=t)}e.textContent=t}var he={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},ge=["Webkit","ms","Moz","O"];function me(e,t,n){return null==t||"boolean"==typeof t||""===t?"":n||"number"!=typeof t||0===t||he.hasOwnProperty(e)&&he[e]?(""+t).trim():t+"px"}function ye(e,t){for(var n in e=e.style,t)if(t.hasOwnProperty(n)){var r=0===n.indexOf("--"),o=me(n,t[n],r);"float"===n&&(n="cssFloat"),r?e.setProperty(n,o):e[n]=o}}Object.keys(he).forEach(function(e){ge.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),he[t]=he[e]})});var ve=F({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function be(e,t){if(t){if(ve[e]&&(null!=t.children||null!=t.dangerouslySetInnerHTML))throw Error(n(137,e));if(null!=t.dangerouslySetInnerHTML){if(null!=t.children)throw Error(n(60));if("object"!=typeof t.dangerouslySetInnerHTML||!("__html"in t.dangerouslySetInnerHTML))throw Error(n(61))}if(null!=t.style&&"object"!=typeof t.style)throw Error(n(62))}}function ke(e,t){if(-1===e.indexOf("-"))return"string"==typeof t.is;switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var xe=null;function we(e){return(e=e.target||e.srcElement||window).correspondingUseElement&&(e=e.correspondingUseElement),3===e.nodeType?e.parentNode:e}var Se=null,Ee=null,Ce=null;function Te(e){if(e=Co(e)){if("function"!=typeof Se)throw Error(n(280));var t=e.stateNode;t&&(t=Oo(t),Se(e.stateNode,e.type,t))}}function Oe(e){Ee?Ce?Ce.push(e):Ce=[e]:Ee=e}function Ne(){if(Ee){var e=Ee,t=Ce;if(Ce=Ee=null,Te(e),t)for(e=0;e<t.length;e++)Te(t[e])}}function Pe(e,t){return e(t)}function Le(){}var Re=!1;function _e(e,t,n){if(Re)return e(t,n);Re=!0;try{return Pe(e,t,n)}finally{Re=!1,(null!==Ee||null!==Ce)&&(Le(),Ne())}}function Ie(e,t){var r=e.stateNode;if(null===r)return null;var o=Oo(r);if(null===o)return null;r=o[t];e:switch(t){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(o=!o.disabled)||(o=!("button"===(e=e.type)||"input"===e||"select"===e||"textarea"===e)),e=!o;break e;default:e=!1}if(e)return null;if(r&&"function"!=typeof r)throw Error(n(231,t,typeof r));return r}var Ae=!1;if(l)try{var Me={};Object.defineProperty(Me,"passive",{get:function(){Ae=!0}}),window.addEventListener("test",Me,Me),window.removeEventListener("test",Me,Me)}catch(de){Ae=!1}function Ue(e,t,n,r,o,i,a,s,l){var u=Array.prototype.slice.call(arguments,3);try{t.apply(n,u)}catch(c){this.onError(c)}}var Be=!1,$e=null,Ve=!1,He=null,qe={onError:function(e){Be=!0,$e=e}};function We(e,t,n,r,o,i,a,s,l){Be=!1,$e=null,Ue.apply(qe,arguments)}function Ke(e){var t=e,n=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do{!!(4098&(t=e).flags)&&(n=t.return),e=t.return}while(e)}return 3===t.tag?n:null}function Qe(e){if(13===e.tag){var t=e.memoizedState;if(null===t&&(null!==(e=e.alternate)&&(t=e.memoizedState)),null!==t)return t.dehydrated}return null}function Je(e){if(Ke(e)!==e)throw Error(n(188))}function Ye(e){return null!==(e=function(e){var t=e.alternate;if(!t){if(null===(t=Ke(e)))throw Error(n(188));return t!==e?null:e}for(var r=e,o=t;;){var i=r.return;if(null===i)break;var a=i.alternate;if(null===a){if(null!==(o=i.return)){r=o;continue}break}if(i.child===a.child){for(a=i.child;a;){if(a===r)return Je(i),e;if(a===o)return Je(i),t;a=a.sibling}throw Error(n(188))}if(r.return!==o.return)r=i,o=a;else{for(var s=!1,l=i.child;l;){if(l===r){s=!0,r=i,o=a;break}if(l===o){s=!0,o=i,r=a;break}l=l.sibling}if(!s){for(l=a.child;l;){if(l===r){s=!0,r=a,o=i;break}if(l===o){s=!0,o=a,r=i;break}l=l.sibling}if(!s)throw Error(n(189))}}if(r.alternate!==o)throw Error(n(190))}if(3!==r.tag)throw Error(n(188));return r.stateNode.current===r?e:t}(e))?Ge(e):null}function Ge(e){if(5===e.tag||6===e.tag)return e;for(e=e.child;null!==e;){var t=Ge(e);if(null!==t)return t;e=e.sibling}return null}var Xe=t.unstable_scheduleCallback,Ze=t.unstable_cancelCallback,et=t.unstable_shouldYield,tt=t.unstable_requestPaint,nt=t.unstable_now,rt=t.unstable_getCurrentPriorityLevel,ot=t.unstable_ImmediatePriority,it=t.unstable_UserBlockingPriority,at=t.unstable_NormalPriority,st=t.unstable_LowPriority,lt=t.unstable_IdlePriority,ut=null,ct=null;var dt=Math.clz32?Math.clz32:function(e){return e>>>=0,0===e?32:31-(ft(e)/pt|0)|0},ft=Math.log,pt=Math.LN2;var ht=64,gt=4194304;function mt(e){switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return 4194240&e;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return 130023424&e;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return e}}function yt(e,t){var n=e.pendingLanes;if(0===n)return 0;var r=0,o=e.suspendedLanes,i=e.pingedLanes,a=268435455&n;if(0!==a){var s=a&~o;0!==s?r=mt(s):0!==(i&=a)&&(r=mt(i))}else 0!==(a=n&~o)?r=mt(a):0!==i&&(r=mt(i));if(0===r)return 0;if(0!==t&&t!==r&&0===(t&o)&&((o=r&-r)>=(i=t&-t)||16===o&&4194240&i))return t;if(4&r&&(r|=16&n),0!==(t=e.entangledLanes))for(e=e.entanglements,t&=r;0<t;)o=1<<(n=31-dt(t)),r|=e[n],t&=~o;return r}function vt(e,t){switch(e){case 1:case 2:case 4:return t+250;case 8:case 16:case 32:case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;default:return-1}}function bt(e){return 0!==(e=-1073741825&e.pendingLanes)?e:1073741824&e?1073741824:0}function kt(){var e=ht;return!(4194240&(ht<<=1))&&(ht=64),e}function xt(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function wt(e,t,n){e.pendingLanes|=t,536870912!==t&&(e.suspendedLanes=0,e.pingedLanes=0),(e=e.eventTimes)[t=31-dt(t)]=n}function St(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var r=31-dt(n),o=1<<r;o&t|e[r]&t&&(e[r]|=t),n&=~o}}var Et=0;function Ct(e){return 1<(e&=-e)?4<e?268435455&e?16:536870912:4:1}var Tt,Ot,Nt,Pt,Lt,Rt=!1,_t=[],It=null,At=null,Dt=null,zt=new Map,jt=new Map,Ft=[],Mt="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset submit".split(" ");function Ut(e,t){switch(e){case"focusin":case"focusout":It=null;break;case"dragenter":case"dragleave":At=null;break;case"mouseover":case"mouseout":Dt=null;break;case"pointerover":case"pointerout":zt.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":jt.delete(t.pointerId)}}function Bt(e,t,n,r,o,i){return null===e||e.nativeEvent!==i?(e={blockedOn:t,domEventName:n,eventSystemFlags:r,nativeEvent:i,targetContainers:[o]},null!==t&&(null!==(t=Co(t))&&Ot(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,null!==o&&-1===t.indexOf(o)&&t.push(o),e)}function $t(e){var t=Eo(e.target);if(null!==t){var n=Ke(t);if(null!==n)if(13===(t=n.tag)){if(null!==(t=Qe(n)))return e.blockedOn=t,void Lt(e.priority,function(){Nt(n)})}else if(3===t&&n.stateNode.current.memoizedState.isDehydrated)return void(e.blockedOn=3===n.tag?n.stateNode.containerInfo:null)}e.blockedOn=null}function Vt(e){if(null!==e.blockedOn)return!1;for(var t=e.targetContainers;0<t.length;){var n=en(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(null!==n)return null!==(t=Co(n))&&Ot(t),e.blockedOn=n,!1;var r=new(n=e.nativeEvent).constructor(n.type,n);xe=r,n.target.dispatchEvent(r),xe=null,t.shift()}return!0}function Ht(e,t,n){Vt(e)&&n.delete(t)}function qt(){Rt=!1,null!==It&&Vt(It)&&(It=null),null!==At&&Vt(At)&&(At=null),null!==Dt&&Vt(Dt)&&(Dt=null),zt.forEach(Ht),jt.forEach(Ht)}function Wt(e,n){e.blockedOn===n&&(e.blockedOn=null,Rt||(Rt=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,qt)))}function Kt(e){function t(t){return Wt(t,e)}if(0<_t.length){Wt(_t[0],e);for(var n=1;n<_t.length;n++){var r=_t[n];r.blockedOn===e&&(r.blockedOn=null)}}for(null!==It&&Wt(It,e),null!==At&&Wt(At,e),null!==Dt&&Wt(Dt,e),zt.forEach(t),jt.forEach(t),n=0;n<Ft.length;n++)(r=Ft[n]).blockedOn===e&&(r.blockedOn=null);for(;0<Ft.length&&null===(n=Ft[0]).blockedOn;)$t(n),null===n.blockedOn&&Ft.shift()}var Qt=x.ReactCurrentBatchConfig,Jt=!0;function Yt(e,t,n,r){var o=Et,i=Qt.transition;Qt.transition=null;try{Et=1,Xt(e,t,n,r)}finally{Et=o,Qt.transition=i}}function Gt(e,t,n,r){var o=Et,i=Qt.transition;Qt.transition=null;try{Et=4,Xt(e,t,n,r)}finally{Et=o,Qt.transition=i}}function Xt(e,t,n,r){if(Jt){var o=en(e,t,n,r);if(null===o)Jr(e,t,r,Zt,n),Ut(e,r);else if(function(e,t,n,r,o){switch(t){case"focusin":return It=Bt(It,e,t,n,r,o),!0;case"dragenter":return At=Bt(At,e,t,n,r,o),!0;case"mouseover":return Dt=Bt(Dt,e,t,n,r,o),!0;case"pointerover":var i=o.pointerId;return zt.set(i,Bt(zt.get(i)||null,e,t,n,r,o)),!0;case"gotpointercapture":return i=o.pointerId,jt.set(i,Bt(jt.get(i)||null,e,t,n,r,o)),!0}return!1}(o,e,t,n,r))r.stopPropagation();else if(Ut(e,r),4&t&&-1<Mt.indexOf(e)){for(;null!==o;){var i=Co(o);if(null!==i&&Tt(i),null===(i=en(e,t,n,r))&&Jr(e,t,r,Zt,n),i===o)break;o=i}null!==o&&r.stopPropagation()}else Jr(e,t,r,null,n)}}var Zt=null;function en(e,t,n,r){if(Zt=null,null!==(e=Eo(e=we(r))))if(null===(t=Ke(e)))e=null;else if(13===(n=t.tag)){if(null!==(e=Qe(t)))return e;e=null}else if(3===n){if(t.stateNode.current.memoizedState.isDehydrated)return 3===t.tag?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null);return Zt=e,null}function tn(e){switch(e){case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 1;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"toggle":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 4;case"message":switch(rt()){case ot:return 1;case it:return 4;case at:case st:return 16;case lt:return 536870912;default:return 16}default:return 16}}var nn=null,rn=null,on=null;function an(){if(on)return on;var e,t,n=rn,r=n.length,o="value"in nn?nn.value:nn.textContent,i=o.length;for(e=0;e<r&&n[e]===o[e];e++);var a=r-e;for(t=1;t<=a&&n[r-t]===o[i-t];t++);return on=o.slice(e,1<t?1-t:void 0)}function sn(e){var t=e.keyCode;return"charCode"in e?0===(e=e.charCode)&&13===t&&(e=13):e=t,10===e&&(e=13),32<=e||13===e?e:0}function ln(){return!0}function un(){return!1}function cn(e){function t(t,n,r,o,i){for(var a in this._reactName=t,this._targetInst=r,this.type=n,this.nativeEvent=o,this.target=i,this.currentTarget=null,e)e.hasOwnProperty(a)&&(t=e[a],this[a]=t?t(o):o[a]);return this.isDefaultPrevented=(null!=o.defaultPrevented?o.defaultPrevented:!1===o.returnValue)?ln:un,this.isPropagationStopped=un,this}return F(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var e=this.nativeEvent;e&&(e.preventDefault?e.preventDefault():"unknown"!=typeof e.returnValue&&(e.returnValue=!1),this.isDefaultPrevented=ln)},stopPropagation:function(){var e=this.nativeEvent;e&&(e.stopPropagation?e.stopPropagation():"unknown"!=typeof e.cancelBubble&&(e.cancelBubble=!0),this.isPropagationStopped=ln)},persist:function(){},isPersistent:ln}),t}var dn,fn,pn,hn={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},gn=cn(hn),mn=F({},hn,{view:0,detail:0}),yn=cn(mn),vn=F({},mn,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Ln,button:0,buttons:0,relatedTarget:function(e){return void 0===e.relatedTarget?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return"movementX"in e?e.movementX:(e!==pn&&(pn&&"mousemove"===e.type?(dn=e.screenX-pn.screenX,fn=e.screenY-pn.screenY):fn=dn=0,pn=e),dn)},movementY:function(e){return"movementY"in e?e.movementY:fn}}),bn=cn(vn),kn=cn(F({},vn,{dataTransfer:0})),xn=cn(F({},mn,{relatedTarget:0})),wn=cn(F({},hn,{animationName:0,elapsedTime:0,pseudoElement:0})),Sn=F({},hn,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),En=cn(Sn),Cn=cn(F({},hn,{data:0})),Tn={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},On={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},Nn={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Pn(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):!!(e=Nn[e])&&!!t[e]}function Ln(){return Pn}var Rn=F({},mn,{key:function(e){if(e.key){var t=Tn[e.key]||e.key;if("Unidentified"!==t)return t}return"keypress"===e.type?13===(e=sn(e))?"Enter":String.fromCharCode(e):"keydown"===e.type||"keyup"===e.type?On[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Ln,charCode:function(e){return"keypress"===e.type?sn(e):0},keyCode:function(e){return"keydown"===e.type||"keyup"===e.type?e.keyCode:0},which:function(e){return"keypress"===e.type?sn(e):"keydown"===e.type||"keyup"===e.type?e.keyCode:0}}),_n=cn(Rn),In=cn(F({},vn,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0})),An=cn(F({},mn,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Ln})),Dn=cn(F({},hn,{propertyName:0,elapsedTime:0,pseudoElement:0})),zn=F({},vn,{deltaX:function(e){return"deltaX"in e?e.deltaX:"wheelDeltaX"in e?-e.wheelDeltaX:0},deltaY:function(e){return"deltaY"in e?e.deltaY:"wheelDeltaY"in e?-e.wheelDeltaY:"wheelDelta"in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0}),jn=cn(zn),Fn=[9,13,27,32],Mn=l&&"CompositionEvent"in window,Un=null;l&&"documentMode"in document&&(Un=document.documentMode);var Bn=l&&"TextEvent"in window&&!Un,$n=l&&(!Mn||Un&&8<Un&&11>=Un),Vn=String.fromCharCode(32),Hn=!1;function qn(e,t){switch(e){case"keyup":return-1!==Fn.indexOf(t.keyCode);case"keydown":return 229!==t.keyCode;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Wn(e){return"object"==typeof(e=e.detail)&&"data"in e?e.data:null}var Kn=!1;var Qn={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function Jn(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return"input"===t?!!Qn[e.type]:"textarea"===t}function Yn(e,t,n,r){Oe(r),0<(t=Gr(t,"onChange")).length&&(n=new gn("onChange","change",null,n,r),e.push({event:n,listeners:t}))}var Gn=null,Xn=null;function Zn(e){Vr(e,0)}function er(e){if(Q(To(e)))return e}function tr(e,t){if("change"===e)return t}var nr=!1;if(l){var rr;if(l){var or="oninput"in document;if(!or){var ir=document.createElement("div");ir.setAttribute("oninput","return;"),or="function"==typeof ir.oninput}rr=or}else rr=!1;nr=rr&&(!document.documentMode||9<document.documentMode)}function ar(){Gn&&(Gn.detachEvent("onpropertychange",sr),Xn=Gn=null)}function sr(e){if("value"===e.propertyName&&er(Xn)){var t=[];Yn(t,Xn,e,we(e)),_e(Zn,t)}}function lr(e,t,n){"focusin"===e?(ar(),Xn=n,(Gn=t).attachEvent("onpropertychange",sr)):"focusout"===e&&ar()}function ur(e){if("selectionchange"===e||"keyup"===e||"keydown"===e)return er(Xn)}function cr(e,t){if("click"===e)return er(t)}function dr(e,t){if("input"===e||"change"===e)return er(t)}var fr="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t};function pr(e,t){if(fr(e,t))return!0;if("object"!=typeof e||null===e||"object"!=typeof t||null===t)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(r=0;r<n.length;r++){var o=n[r];if(!u.call(t,o)||!fr(e[o],t[o]))return!1}return!0}function hr(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function gr(e,t){var n,r=hr(e);for(e=0;r;){if(3===r.nodeType){if(n=e+r.textContent.length,e<=t&&n>=t)return{node:r,offset:t-e};e=n}e:{for(;r;){if(r.nextSibling){r=r.nextSibling;break e}r=r.parentNode}r=void 0}r=hr(r)}}function mr(e,t){return!(!e||!t)&&(e===t||(!e||3!==e.nodeType)&&(t&&3===t.nodeType?mr(e,t.parentNode):"contains"in e?e.contains(t):!!e.compareDocumentPosition&&!!(16&e.compareDocumentPosition(t))))}function yr(){for(var e=window,t=J();t instanceof e.HTMLIFrameElement;){try{var n="string"==typeof t.contentWindow.location.href}catch(r){n=!1}if(!n)break;t=J((e=t.contentWindow).document)}return t}function vr(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&("input"===t&&("text"===e.type||"search"===e.type||"tel"===e.type||"url"===e.type||"password"===e.type)||"textarea"===t||"true"===e.contentEditable)}function br(e){var t=yr(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&mr(n.ownerDocument.documentElement,n)){if(null!==r&&vr(n))if(t=r.start,void 0===(e=r.end)&&(e=t),"selectionStart"in n)n.selectionStart=t,n.selectionEnd=Math.min(e,n.value.length);else if((e=(t=n.ownerDocument||document)&&t.defaultView||window).getSelection){e=e.getSelection();var o=n.textContent.length,i=Math.min(r.start,o);r=void 0===r.end?i:Math.min(r.end,o),!e.extend&&i>r&&(o=r,r=i,i=o),o=gr(n,i);var a=gr(n,r);o&&a&&(1!==e.rangeCount||e.anchorNode!==o.node||e.anchorOffset!==o.offset||e.focusNode!==a.node||e.focusOffset!==a.offset)&&((t=t.createRange()).setStart(o.node,o.offset),e.removeAllRanges(),i>r?(e.addRange(t),e.extend(a.node,a.offset)):(t.setEnd(a.node,a.offset),e.addRange(t)))}for(t=[],e=n;e=e.parentNode;)1===e.nodeType&&t.push({element:e,left:e.scrollLeft,top:e.scrollTop});for("function"==typeof n.focus&&n.focus(),n=0;n<t.length;n++)(e=t[n]).element.scrollLeft=e.left,e.element.scrollTop=e.top}}var kr=l&&"documentMode"in document&&11>=document.documentMode,xr=null,wr=null,Sr=null,Er=!1;function Cr(e,t,n){var r=n.window===n?n.document:9===n.nodeType?n:n.ownerDocument;Er||null==xr||xr!==J(r)||("selectionStart"in(r=xr)&&vr(r)?r={start:r.selectionStart,end:r.selectionEnd}:r={anchorNode:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection()).anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset},Sr&&pr(Sr,r)||(Sr=r,0<(r=Gr(wr,"onSelect")).length&&(t=new gn("onSelect","select",null,t,n),e.push({event:t,listeners:r}),t.target=xr)))}function Tr(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit"+e]="webkit"+t,n["Moz"+e]="moz"+t,n}var Or={animationend:Tr("Animation","AnimationEnd"),animationiteration:Tr("Animation","AnimationIteration"),animationstart:Tr("Animation","AnimationStart"),transitionend:Tr("Transition","TransitionEnd")},Nr={},Pr={};function Lr(e){if(Nr[e])return Nr[e];if(!Or[e])return e;var t,n=Or[e];for(t in n)if(n.hasOwnProperty(t)&&t in Pr)return Nr[e]=n[t];return e}l&&(Pr=document.createElement("div").style,"AnimationEvent"in window||(delete Or.animationend.animation,delete Or.animationiteration.animation,delete Or.animationstart.animation),"TransitionEvent"in window||delete Or.transitionend.transition);var Rr=Lr("animationend"),_r=Lr("animationiteration"),Ir=Lr("animationstart"),Ar=Lr("transitionend"),Dr=new Map,zr="abort auxClick cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");function jr(e,t){Dr.set(e,t),i(t,[e])}for(var Fr=0;Fr<zr.length;Fr++){var Mr=zr[Fr];jr(Mr.toLowerCase(),"on"+(Mr[0].toUpperCase()+Mr.slice(1)))}jr(Rr,"onAnimationEnd"),jr(_r,"onAnimationIteration"),jr(Ir,"onAnimationStart"),jr("dblclick","onDoubleClick"),jr("focusin","onFocus"),jr("focusout","onBlur"),jr(Ar,"onTransitionEnd"),a("onMouseEnter",["mouseout","mouseover"]),a("onMouseLeave",["mouseout","mouseover"]),a("onPointerEnter",["pointerout","pointerover"]),a("onPointerLeave",["pointerout","pointerover"]),i("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),i("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),i("onBeforeInput",["compositionend","keypress","textInput","paste"]),i("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),i("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),i("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Ur="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),Br=new Set("cancel close invalid load scroll toggle".split(" ").concat(Ur));function $r(e,t,r){var o=e.type||"unknown-event";e.currentTarget=r,function(e,t,r,o,i,a,s,l,u){if(We.apply(this,arguments),Be){if(!Be)throw Error(n(198));var c=$e;Be=!1,$e=null,Ve||(Ve=!0,He=c)}}(o,t,void 0,e),e.currentTarget=null}function Vr(e,t){t=!!(4&t);for(var n=0;n<e.length;n++){var r=e[n],o=r.event;r=r.listeners;e:{var i=void 0;if(t)for(var a=r.length-1;0<=a;a--){var s=r[a],l=s.instance,u=s.currentTarget;if(s=s.listener,l!==i&&o.isPropagationStopped())break e;$r(o,s,u),i=l}else for(a=0;a<r.length;a++){if(l=(s=r[a]).instance,u=s.currentTarget,s=s.listener,l!==i&&o.isPropagationStopped())break e;$r(o,s,u),i=l}}}if(Ve)throw e=He,Ve=!1,He=null,e}function Hr(e,t){var n=t[xo];void 0===n&&(n=t[xo]=new Set);var r=e+"__bubble";n.has(r)||(Qr(t,e,2,!1),n.add(r))}function qr(e,t,n){var r=0;t&&(r|=4),Qr(n,e,r,t)}var Wr="_reactListening"+Math.random().toString(36).slice(2);function Kr(e){if(!e[Wr]){e[Wr]=!0,r.forEach(function(t){"selectionchange"!==t&&(Br.has(t)||qr(t,!1,e),qr(t,!0,e))});var t=9===e.nodeType?e:e.ownerDocument;null===t||t[Wr]||(t[Wr]=!0,qr("selectionchange",!1,t))}}function Qr(e,t,n,r){switch(tn(t)){case 1:var o=Yt;break;case 4:o=Gt;break;default:o=Xt}n=o.bind(null,t,n,e),o=void 0,!Ae||"touchstart"!==t&&"touchmove"!==t&&"wheel"!==t||(o=!0),r?void 0!==o?e.addEventListener(t,n,{capture:!0,passive:o}):e.addEventListener(t,n,!0):void 0!==o?e.addEventListener(t,n,{passive:o}):e.addEventListener(t,n,!1)}function Jr(e,t,n,r,o){var i=r;if(!(1&t||2&t||null===r))e:for(;;){if(null===r)return;var a=r.tag;if(3===a||4===a){var s=r.stateNode.containerInfo;if(s===o||8===s.nodeType&&s.parentNode===o)break;if(4===a)for(a=r.return;null!==a;){var l=a.tag;if((3===l||4===l)&&((l=a.stateNode.containerInfo)===o||8===l.nodeType&&l.parentNode===o))return;a=a.return}for(;null!==s;){if(null===(a=Eo(s)))return;if(5===(l=a.tag)||6===l){r=i=a;continue e}s=s.parentNode}}r=r.return}_e(function(){var r=i,o=we(n),a=[];e:{var s=Dr.get(e);if(void 0!==s){var l=gn,u=e;switch(e){case"keypress":if(0===sn(n))break e;case"keydown":case"keyup":l=_n;break;case"focusin":u="focus",l=xn;break;case"focusout":u="blur",l=xn;break;case"beforeblur":case"afterblur":l=xn;break;case"click":if(2===n.button)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":l=bn;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":l=kn;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":l=An;break;case Rr:case _r:case Ir:l=wn;break;case Ar:l=Dn;break;case"scroll":l=yn;break;case"wheel":l=jn;break;case"copy":case"cut":case"paste":l=En;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":l=In}var c=!!(4&t),d=!c&&"scroll"===e,f=c?null!==s?s+"Capture":null:s;c=[];for(var p,h=r;null!==h;){var g=(p=h).stateNode;if(5===p.tag&&null!==g&&(p=g,null!==f&&(null!=(g=Ie(h,f))&&c.push(Yr(h,g,p)))),d)break;h=h.return}0<c.length&&(s=new l(s,u,null,n,o),a.push({event:s,listeners:c}))}}if(!(7&t)){if(l="mouseout"===e||"pointerout"===e,(!(s="mouseover"===e||"pointerover"===e)||n===xe||!(u=n.relatedTarget||n.fromElement)||!Eo(u)&&!u[ko])&&(l||s)&&(s=o.window===o?o:(s=o.ownerDocument)?s.defaultView||s.parentWindow:window,l?(l=r,null!==(u=(u=n.relatedTarget||n.toElement)?Eo(u):null)&&(u!==(d=Ke(u))||5!==u.tag&&6!==u.tag)&&(u=null)):(l=null,u=r),l!==u)){if(c=bn,g="onMouseLeave",f="onMouseEnter",h="mouse","pointerout"!==e&&"pointerover"!==e||(c=In,g="onPointerLeave",f="onPointerEnter",h="pointer"),d=null==l?s:To(l),p=null==u?s:To(u),(s=new c(g,h+"leave",l,n,o)).target=d,s.relatedTarget=p,g=null,Eo(o)===r&&((c=new c(f,h+"enter",u,n,o)).target=p,c.relatedTarget=d,g=c),d=g,l&&u)e:{for(f=u,h=0,p=c=l;p;p=Xr(p))h++;for(p=0,g=f;g;g=Xr(g))p++;for(;0<h-p;)c=Xr(c),h--;for(;0<p-h;)f=Xr(f),p--;for(;h--;){if(c===f||null!==f&&c===f.alternate)break e;c=Xr(c),f=Xr(f)}c=null}else c=null;null!==l&&Zr(a,s,l,c,!1),null!==u&&null!==d&&Zr(a,d,u,c,!0)}if("select"===(l=(s=r?To(r):window).nodeName&&s.nodeName.toLowerCase())||"input"===l&&"file"===s.type)var m=tr;else if(Jn(s))if(nr)m=dr;else{m=ur;var y=lr}else(l=s.nodeName)&&"input"===l.toLowerCase()&&("checkbox"===s.type||"radio"===s.type)&&(m=cr);switch(m&&(m=m(e,r))?Yn(a,m,n,o):(y&&y(e,s,r),"focusout"===e&&(y=s._wrapperState)&&y.controlled&&"number"===s.type&&te(s,"number",s.value)),y=r?To(r):window,e){case"focusin":(Jn(y)||"true"===y.contentEditable)&&(xr=y,wr=r,Sr=null);break;case"focusout":Sr=wr=xr=null;break;case"mousedown":Er=!0;break;case"contextmenu":case"mouseup":case"dragend":Er=!1,Cr(a,n,o);break;case"selectionchange":if(kr)break;case"keydown":case"keyup":Cr(a,n,o)}var v;if(Mn)e:{switch(e){case"compositionstart":var b="onCompositionStart";break e;case"compositionend":b="onCompositionEnd";break e;case"compositionupdate":b="onCompositionUpdate";break e}b=void 0}else Kn?qn(e,n)&&(b="onCompositionEnd"):"keydown"===e&&229===n.keyCode&&(b="onCompositionStart");b&&($n&&"ko"!==n.locale&&(Kn||"onCompositionStart"!==b?"onCompositionEnd"===b&&Kn&&(v=an()):(rn="value"in(nn=o)?nn.value:nn.textContent,Kn=!0)),0<(y=Gr(r,b)).length&&(b=new Cn(b,e,null,n,o),a.push({event:b,listeners:y}),v?b.data=v:null!==(v=Wn(n))&&(b.data=v))),(v=Bn?function(e,t){switch(e){case"compositionend":return Wn(t);case"keypress":return 32!==t.which?null:(Hn=!0,Vn);case"textInput":return(e=t.data)===Vn&&Hn?null:e;default:return null}}(e,n):function(e,t){if(Kn)return"compositionend"===e||!Mn&&qn(e,t)?(e=an(),on=rn=nn=null,Kn=!1,e):null;switch(e){case"paste":default:return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case"compositionend":return $n&&"ko"!==t.locale?null:t.data}}(e,n))&&(0<(r=Gr(r,"onBeforeInput")).length&&(o=new Cn("onBeforeInput","beforeinput",null,n,o),a.push({event:o,listeners:r}),o.data=v))}Vr(a,t)})}function Yr(e,t,n){return{instance:e,listener:t,currentTarget:n}}function Gr(e,t){for(var n=t+"Capture",r=[];null!==e;){var o=e,i=o.stateNode;5===o.tag&&null!==i&&(o=i,null!=(i=Ie(e,n))&&r.unshift(Yr(e,i,o)),null!=(i=Ie(e,t))&&r.push(Yr(e,i,o))),e=e.return}return r}function Xr(e){if(null===e)return null;do{e=e.return}while(e&&5!==e.tag);return e||null}function Zr(e,t,n,r,o){for(var i=t._reactName,a=[];null!==n&&n!==r;){var s=n,l=s.alternate,u=s.stateNode;if(null!==l&&l===r)break;5===s.tag&&null!==u&&(s=u,o?null!=(l=Ie(n,i))&&a.unshift(Yr(n,l,s)):o||null!=(l=Ie(n,i))&&a.push(Yr(n,l,s))),n=n.return}0!==a.length&&e.push({event:t,listeners:a})}var eo=/\r\n?/g,to=/\u0000|\uFFFD/g;function no(e){return("string"==typeof e?e:""+e).replace(eo,"\n").replace(to,"")}function ro(e,t,r){if(t=no(t),no(e)!==t&&r)throw Error(n(425))}function oo(){}var io=null,ao=null;function so(e,t){return"textarea"===e||"noscript"===e||"string"==typeof t.children||"number"==typeof t.children||"object"==typeof t.dangerouslySetInnerHTML&&null!==t.dangerouslySetInnerHTML&&null!=t.dangerouslySetInnerHTML.__html}var lo="function"==typeof setTimeout?setTimeout:void 0,uo="function"==typeof clearTimeout?clearTimeout:void 0,co="function"==typeof Promise?Promise:void 0,fo="function"==typeof queueMicrotask?queueMicrotask:void 0!==co?function(e){return co.resolve(null).then(e).catch(po)}:lo;function po(e){setTimeout(function(){throw e})}function ho(e,t){var n=t,r=0;do{var o=n.nextSibling;if(e.removeChild(n),o&&8===o.nodeType)if("/$"===(n=o.data)){if(0===r)return e.removeChild(o),void Kt(t);r--}else"$"!==n&&"$?"!==n&&"$!"!==n||r++;n=o}while(n);Kt(t)}function go(e){for(;null!=e;e=e.nextSibling){var t=e.nodeType;if(1===t||3===t)break;if(8===t){if("$"===(t=e.data)||"$!"===t||"$?"===t)break;if("/$"===t)return null}}return e}function mo(e){e=e.previousSibling;for(var t=0;e;){if(8===e.nodeType){var n=e.data;if("$"===n||"$!"===n||"$?"===n){if(0===t)return e;t--}else"/$"===n&&t++}e=e.previousSibling}return null}var yo=Math.random().toString(36).slice(2),vo="__reactFiber$"+yo,bo="__reactProps$"+yo,ko="__reactContainer$"+yo,xo="__reactEvents$"+yo,wo="__reactListeners$"+yo,So="__reactHandles$"+yo;function Eo(e){var t=e[vo];if(t)return t;for(var n=e.parentNode;n;){if(t=n[ko]||n[vo]){if(n=t.alternate,null!==t.child||null!==n&&null!==n.child)for(e=mo(e);null!==e;){if(n=e[vo])return n;e=mo(e)}return t}n=(e=n).parentNode}return null}function Co(e){return!(e=e[vo]||e[ko])||5!==e.tag&&6!==e.tag&&13!==e.tag&&3!==e.tag?null:e}function To(e){if(5===e.tag||6===e.tag)return e.stateNode;throw Error(n(33))}function Oo(e){return e[bo]||null}var No=[],Po=-1;function Lo(e){return{current:e}}function Ro(e){0>Po||(e.current=No[Po],No[Po]=null,Po--)}function _o(e,t){Po++,No[Po]=e.current,e.current=t}var Io={},Ao=Lo(Io),Do=Lo(!1),zo=Io;function jo(e,t){var n=e.type.contextTypes;if(!n)return Io;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var o,i={};for(o in n)i[o]=t[o];return r&&((e=e.stateNode).__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=i),i}function Fo(e){return null!=(e=e.childContextTypes)}function Mo(){Ro(Do),Ro(Ao)}function Uo(e,t,r){if(Ao.current!==Io)throw Error(n(168));_o(Ao,t),_o(Do,r)}function Bo(e,t,r){var o=e.stateNode;if(t=t.childContextTypes,"function"!=typeof o.getChildContext)return r;for(var i in o=o.getChildContext())if(!(i in t))throw Error(n(108,H(e)||"Unknown",i));return F({},r,o)}function $o(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||Io,zo=Ao.current,_o(Ao,e),_o(Do,Do.current),!0}function Vo(e,t,r){var o=e.stateNode;if(!o)throw Error(n(169));r?(e=Bo(e,t,zo),o.__reactInternalMemoizedMergedChildContext=e,Ro(Do),Ro(Ao),_o(Ao,e)):Ro(Do),_o(Do,r)}var Ho=null,qo=!1,Wo=!1;function Ko(e){null===Ho?Ho=[e]:Ho.push(e)}function Qo(){if(!Wo&&null!==Ho){Wo=!0;var e=0,t=Et;try{var n=Ho;for(Et=1;e<n.length;e++){var r=n[e];do{r=r(!0)}while(null!==r)}Ho=null,qo=!1}catch(De){throw null!==Ho&&(Ho=Ho.slice(e+1)),Xe(ot,Qo),De}finally{Et=t,Wo=!1}}return null}var Jo=[],Yo=0,Go=null,Xo=0,Zo=[],ei=0,ti=null,ni=1,ri="";function oi(e,t){Jo[Yo++]=Xo,Jo[Yo++]=Go,Go=e,Xo=t}function ii(e,t,n){Zo[ei++]=ni,Zo[ei++]=ri,Zo[ei++]=ti,ti=e;var r=ni;e=ri;var o=32-dt(r)-1;r&=~(1<<o),n+=1;var i=32-dt(t)+o;if(30<i){var a=o-o%5;i=(r&(1<<a)-1).toString(32),r>>=a,o-=a,ni=1<<32-dt(t)+o|n<<o|r,ri=i+e}else ni=1<<i|n<<o|r,ri=e}function ai(e){null!==e.return&&(oi(e,1),ii(e,1,0))}function si(e){for(;e===Go;)Go=Jo[--Yo],Jo[Yo]=null,Xo=Jo[--Yo],Jo[Yo]=null;for(;e===ti;)ti=Zo[--ei],Zo[ei]=null,ri=Zo[--ei],Zo[ei]=null,ni=Zo[--ei],Zo[ei]=null}var li=null,ui=null,ci=!1,di=null;function fi(e,t){var n=Du(5,null,null,0);n.elementType="DELETED",n.stateNode=t,n.return=e,null===(t=e.deletions)?(e.deletions=[n],e.flags|=16):t.push(n)}function pi(e,t){switch(e.tag){case 5:var n=e.type;return null!==(t=1!==t.nodeType||n.toLowerCase()!==t.nodeName.toLowerCase()?null:t)&&(e.stateNode=t,li=e,ui=go(t.firstChild),!0);case 6:return null!==(t=""===e.pendingProps||3!==t.nodeType?null:t)&&(e.stateNode=t,li=e,ui=null,!0);case 13:return null!==(t=8!==t.nodeType?null:t)&&(n=null!==ti?{id:ni,overflow:ri}:null,e.memoizedState={dehydrated:t,treeContext:n,retryLane:1073741824},(n=Du(18,null,null,0)).stateNode=t,n.return=e,e.child=n,li=e,ui=null,!0);default:return!1}}function hi(e){return!(!(1&e.mode)||128&e.flags)}function gi(e){if(ci){var t=ui;if(t){var r=t;if(!pi(e,t)){if(hi(e))throw Error(n(418));t=go(r.nextSibling);var o=li;t&&pi(e,t)?fi(o,r):(e.flags=-4097&e.flags|2,ci=!1,li=e)}}else{if(hi(e))throw Error(n(418));e.flags=-4097&e.flags|2,ci=!1,li=e}}}function mi(e){for(e=e.return;null!==e&&5!==e.tag&&3!==e.tag&&13!==e.tag;)e=e.return;li=e}function yi(e){if(e!==li)return!1;if(!ci)return mi(e),ci=!0,!1;var t;if((t=3!==e.tag)&&!(t=5!==e.tag)&&(t="head"!==(t=e.type)&&"body"!==t&&!so(e.type,e.memoizedProps)),t&&(t=ui)){if(hi(e))throw vi(),Error(n(418));for(;t;)fi(e,t),t=go(t.nextSibling)}if(mi(e),13===e.tag){if(!(e=null!==(e=e.memoizedState)?e.dehydrated:null))throw Error(n(317));e:{for(e=e.nextSibling,t=0;e;){if(8===e.nodeType){var r=e.data;if("/$"===r){if(0===t){ui=go(e.nextSibling);break e}t--}else"$"!==r&&"$!"!==r&&"$?"!==r||t++}e=e.nextSibling}ui=null}}else ui=li?go(e.stateNode.nextSibling):null;return!0}function vi(){for(var e=ui;e;)e=go(e.nextSibling)}function bi(){ui=li=null,ci=!1}function ki(e){null===di?di=[e]:di.push(e)}var xi=x.ReactCurrentBatchConfig;function wi(e,t,r){if(null!==(e=r.ref)&&"function"!=typeof e&&"object"!=typeof e){if(r._owner){if(r=r._owner){if(1!==r.tag)throw Error(n(309));var o=r.stateNode}if(!o)throw Error(n(147,e));var i=o,a=""+e;return null!==t&&null!==t.ref&&"function"==typeof t.ref&&t.ref._stringRef===a?t.ref:((t=function(e){var t=i.refs;null===e?delete t[a]:t[a]=e})._stringRef=a,t)}if("string"!=typeof e)throw Error(n(284));if(!r._owner)throw Error(n(290,e))}return e}function Si(e,t){throw e=Object.prototype.toString.call(t),Error(n(31,"[object Object]"===e?"object with keys {"+Object.keys(t).join(", ")+"}":e))}function Ei(e){return(0,e._init)(e._payload)}function Ci(e){function t(t,n){if(e){var r=t.deletions;null===r?(t.deletions=[n],t.flags|=16):r.push(n)}}function r(n,r){if(!e)return null;for(;null!==r;)t(n,r),r=r.sibling;return null}function o(e,t){for(e=new Map;null!==t;)null!==t.key?e.set(t.key,t):e.set(t.index,t),t=t.sibling;return e}function i(e,t){return(e=ju(e,t)).index=0,e.sibling=null,e}function a(t,n,r){return t.index=r,e?null!==(r=t.alternate)?(r=r.index)<n?(t.flags|=2,n):r:(t.flags|=2,n):(t.flags|=1048576,n)}function s(t){return e&&null===t.alternate&&(t.flags|=2),t}function l(e,t,n,r){return null===t||6!==t.tag?((t=Bu(n,e.mode,r)).return=e,t):((t=i(t,n)).return=e,t)}function u(e,t,n,r){var o=n.type;return o===E?d(e,t,n.props.children,r,n.key):null!==t&&(t.elementType===o||"object"==typeof o&&null!==o&&o.$$typeof===I&&Ei(o)===t.type)?((r=i(t,n.props)).ref=wi(e,t,n),r.return=e,r):((r=Fu(n.type,n.key,n.props,null,e.mode,r)).ref=wi(e,t,n),r.return=e,r)}function c(e,t,n,r){return null===t||4!==t.tag||t.stateNode.containerInfo!==n.containerInfo||t.stateNode.implementation!==n.implementation?((t=$u(n,e.mode,r)).return=e,t):((t=i(t,n.children||[])).return=e,t)}function d(e,t,n,r,o){return null===t||7!==t.tag?((t=Mu(n,e.mode,r,o)).return=e,t):((t=i(t,n)).return=e,t)}function f(e,t,n){if("string"==typeof t&&""!==t||"number"==typeof t)return(t=Bu(""+t,e.mode,n)).return=e,t;if("object"==typeof t&&null!==t){switch(t.$$typeof){case w:return(n=Fu(t.type,t.key,t.props,null,e.mode,n)).ref=wi(e,null,t),n.return=e,n;case S:return(t=$u(t,e.mode,n)).return=e,t;case I:return f(e,(0,t._init)(t._payload),n)}if(ne(t)||z(t))return(t=Mu(t,e.mode,n,null)).return=e,t;Si(e,t)}return null}function p(e,t,n,r){var o=null!==t?t.key:null;if("string"==typeof n&&""!==n||"number"==typeof n)return null!==o?null:l(e,t,""+n,r);if("object"==typeof n&&null!==n){switch(n.$$typeof){case w:return n.key===o?u(e,t,n,r):null;case S:return n.key===o?c(e,t,n,r):null;case I:return p(e,t,(o=n._init)(n._payload),r)}if(ne(n)||z(n))return null!==o?null:d(e,t,n,r,null);Si(e,n)}return null}function h(e,t,n,r,o){if("string"==typeof r&&""!==r||"number"==typeof r)return l(t,e=e.get(n)||null,""+r,o);if("object"==typeof r&&null!==r){switch(r.$$typeof){case w:return u(t,e=e.get(null===r.key?n:r.key)||null,r,o);case S:return c(t,e=e.get(null===r.key?n:r.key)||null,r,o);case I:return h(e,t,n,(0,r._init)(r._payload),o)}if(ne(r)||z(r))return d(t,e=e.get(n)||null,r,o,null);Si(t,r)}return null}return function l(u,c,d,g){if("object"==typeof d&&null!==d&&d.type===E&&null===d.key&&(d=d.props.children),"object"==typeof d&&null!==d){switch(d.$$typeof){case w:e:{for(var m=d.key,y=c;null!==y;){if(y.key===m){if((m=d.type)===E){if(7===y.tag){r(u,y.sibling),(c=i(y,d.props.children)).return=u,u=c;break e}}else if(y.elementType===m||"object"==typeof m&&null!==m&&m.$$typeof===I&&Ei(m)===y.type){r(u,y.sibling),(c=i(y,d.props)).ref=wi(u,y,d),c.return=u,u=c;break e}r(u,y);break}t(u,y),y=y.sibling}d.type===E?((c=Mu(d.props.children,u.mode,g,d.key)).return=u,u=c):((g=Fu(d.type,d.key,d.props,null,u.mode,g)).ref=wi(u,c,d),g.return=u,u=g)}return s(u);case S:e:{for(y=d.key;null!==c;){if(c.key===y){if(4===c.tag&&c.stateNode.containerInfo===d.containerInfo&&c.stateNode.implementation===d.implementation){r(u,c.sibling),(c=i(c,d.children||[])).return=u,u=c;break e}r(u,c);break}t(u,c),c=c.sibling}(c=$u(d,u.mode,g)).return=u,u=c}return s(u);case I:return l(u,c,(y=d._init)(d._payload),g)}if(ne(d))return function(n,i,s,l){for(var u=null,c=null,d=i,g=i=0,m=null;null!==d&&g<s.length;g++){d.index>g?(m=d,d=null):m=d.sibling;var y=p(n,d,s[g],l);if(null===y){null===d&&(d=m);break}e&&d&&null===y.alternate&&t(n,d),i=a(y,i,g),null===c?u=y:c.sibling=y,c=y,d=m}if(g===s.length)return r(n,d),ci&&oi(n,g),u;if(null===d){for(;g<s.length;g++)null!==(d=f(n,s[g],l))&&(i=a(d,i,g),null===c?u=d:c.sibling=d,c=d);return ci&&oi(n,g),u}for(d=o(n,d);g<s.length;g++)null!==(m=h(d,n,g,s[g],l))&&(e&&null!==m.alternate&&d.delete(null===m.key?g:m.key),i=a(m,i,g),null===c?u=m:c.sibling=m,c=m);return e&&d.forEach(function(e){return t(n,e)}),ci&&oi(n,g),u}(u,c,d,g);if(z(d))return function(i,s,l,u){var c=z(l);if("function"!=typeof c)throw Error(n(150));if(null==(l=c.call(l)))throw Error(n(151));for(var d=c=null,g=s,m=s=0,y=null,v=l.next();null!==g&&!v.done;m++,v=l.next()){g.index>m?(y=g,g=null):y=g.sibling;var b=p(i,g,v.value,u);if(null===b){null===g&&(g=y);break}e&&g&&null===b.alternate&&t(i,g),s=a(b,s,m),null===d?c=b:d.sibling=b,d=b,g=y}if(v.done)return r(i,g),ci&&oi(i,m),c;if(null===g){for(;!v.done;m++,v=l.next())null!==(v=f(i,v.value,u))&&(s=a(v,s,m),null===d?c=v:d.sibling=v,d=v);return ci&&oi(i,m),c}for(g=o(i,g);!v.done;m++,v=l.next())null!==(v=h(g,i,m,v.value,u))&&(e&&null!==v.alternate&&g.delete(null===v.key?m:v.key),s=a(v,s,m),null===d?c=v:d.sibling=v,d=v);return e&&g.forEach(function(e){return t(i,e)}),ci&&oi(i,m),c}(u,c,d,g);Si(u,d)}return"string"==typeof d&&""!==d||"number"==typeof d?(d=""+d,null!==c&&6===c.tag?(r(u,c.sibling),(c=i(c,d)).return=u,u=c):(r(u,c),(c=Bu(d,u.mode,g)).return=u,u=c),s(u)):r(u,c)}}var Ti=Ci(!0),Oi=Ci(!1),Ni=Lo(null),Pi=null,Li=null,Ri=null;function _i(){Ri=Li=Pi=null}function Ii(e){var t=Ni.current;Ro(Ni),e._currentValue=t}function Ai(e,t,n){for(;null!==e;){var r=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,null!==r&&(r.childLanes|=t)):null!==r&&(r.childLanes&t)!==t&&(r.childLanes|=t),e===n)break;e=e.return}}function Di(e,t){Pi=e,Ri=Li=null,null!==(e=e.dependencies)&&null!==e.firstContext&&(0!==(e.lanes&t)&&(Ss=!0),e.firstContext=null)}function zi(e){var t=e._currentValue;if(Ri!==e)if(e={context:e,memoizedValue:t,next:null},null===Li){if(null===Pi)throw Error(n(308));Li=e,Pi.dependencies={lanes:0,firstContext:e}}else Li=Li.next=e;return t}var ji=null;function Fi(e){null===ji?ji=[e]:ji.push(e)}function Mi(e,t,n,r){var o=t.interleaved;return null===o?(n.next=n,Fi(t)):(n.next=o.next,o.next=n),t.interleaved=n,Ui(e,r)}function Ui(e,t){e.lanes|=t;var n=e.alternate;for(null!==n&&(n.lanes|=t),n=e,e=e.return;null!==e;)e.childLanes|=t,null!==(n=e.alternate)&&(n.childLanes|=t),n=e,e=e.return;return 3===n.tag?n.stateNode:null}var Bi=!1;function $i(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function Vi(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,effects:e.effects})}function Hi(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function qi(e,t,n){var r=e.updateQueue;if(null===r)return null;if(r=r.shared,2&_l){var o=r.pending;return null===o?t.next=t:(t.next=o.next,o.next=t),r.pending=t,Ui(e,n)}return null===(o=r.interleaved)?(t.next=t,Fi(r)):(t.next=o.next,o.next=t),r.interleaved=t,Ui(e,n)}function Wi(e,t,n){if(null!==(t=t.updateQueue)&&(t=t.shared,4194240&n)){var r=t.lanes;n|=r&=e.pendingLanes,t.lanes=n,St(e,n)}}function Ki(e,t){var n=e.updateQueue,r=e.alternate;if(null!==r&&n===(r=r.updateQueue)){var o=null,i=null;if(null!==(n=n.firstBaseUpdate)){do{var a={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};null===i?o=i=a:i=i.next=a,n=n.next}while(null!==n);null===i?o=i=t:i=i.next=t}else o=i=t;return n={baseState:r.baseState,firstBaseUpdate:o,lastBaseUpdate:i,shared:r.shared,effects:r.effects},void(e.updateQueue=n)}null===(e=n.lastBaseUpdate)?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}function Qi(e,t,n,r){var o=e.updateQueue;Bi=!1;var i=o.firstBaseUpdate,a=o.lastBaseUpdate,s=o.shared.pending;if(null!==s){o.shared.pending=null;var l=s,u=l.next;l.next=null,null===a?i=u:a.next=u,a=l;var c=e.alternate;null!==c&&((s=(c=c.updateQueue).lastBaseUpdate)!==a&&(null===s?c.firstBaseUpdate=u:s.next=u,c.lastBaseUpdate=l))}if(null!==i){var d=o.baseState;for(a=0,c=u=l=null,s=i;;){var f=s.lane,p=s.eventTime;if((r&f)===f){null!==c&&(c=c.next={eventTime:p,lane:0,tag:s.tag,payload:s.payload,callback:s.callback,next:null});e:{var h=e,g=s;switch(f=t,p=n,g.tag){case 1:if("function"==typeof(h=g.payload)){d=h.call(p,d,f);break e}d=h;break e;case 3:h.flags=-65537&h.flags|128;case 0:if(null==(f="function"==typeof(h=g.payload)?h.call(p,d,f):h))break e;d=F({},d,f);break e;case 2:Bi=!0}}null!==s.callback&&0!==s.lane&&(e.flags|=64,null===(f=o.effects)?o.effects=[s]:f.push(s))}else p={eventTime:p,lane:f,tag:s.tag,payload:s.payload,callback:s.callback,next:null},null===c?(u=c=p,l=d):c=c.next=p,a|=f;if(null===(s=s.next)){if(null===(s=o.shared.pending))break;s=(f=s).next,f.next=null,o.lastBaseUpdate=f,o.shared.pending=null}}if(null===c&&(l=d),o.baseState=l,o.firstBaseUpdate=u,o.lastBaseUpdate=c,null!==(t=o.shared.interleaved)){o=t;do{a|=o.lane,o=o.next}while(o!==t)}else null===i&&(o.shared.lanes=0);Ul|=a,e.lanes=a,e.memoizedState=d}}function Ji(e,t,r){if(e=t.effects,t.effects=null,null!==e)for(t=0;t<e.length;t++){var o=e[t],i=o.callback;if(null!==i){if(o.callback=null,o=r,"function"!=typeof i)throw Error(n(191,i));i.call(o)}}}var Yi={},Gi=Lo(Yi),Xi=Lo(Yi),Zi=Lo(Yi);function ea(e){if(e===Yi)throw Error(n(174));return e}function ta(e,t){switch(_o(Zi,t),_o(Xi,e),_o(Gi,Yi),e=t.nodeType){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:ue(null,"");break;default:t=ue(t=(e=8===e?t.parentNode:t).namespaceURI||null,e=e.tagName)}Ro(Gi),_o(Gi,t)}function na(){Ro(Gi),Ro(Xi),Ro(Zi)}function ra(e){ea(Zi.current);var t=ea(Gi.current),n=ue(t,e.type);t!==n&&(_o(Xi,e),_o(Gi,n))}function oa(e){Xi.current===e&&(Ro(Gi),Ro(Xi))}var ia=Lo(0);function aa(e){for(var t=e;null!==t;){if(13===t.tag){var n=t.memoizedState;if(null!==n&&(null===(n=n.dehydrated)||"$?"===n.data||"$!"===n.data))return t}else if(19===t.tag&&void 0!==t.memoizedProps.revealOrder){if(128&t.flags)return t}else if(null!==t.child){t.child.return=t,t=t.child;continue}if(t===e)break;for(;null===t.sibling;){if(null===t.return||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var sa=[];function la(){for(var e=0;e<sa.length;e++)sa[e]._workInProgressVersionPrimary=null;sa.length=0}var ua=x.ReactCurrentDispatcher,ca=x.ReactCurrentBatchConfig,da=0,fa=null,pa=null,ha=null,ga=!1,ma=!1,ya=0,va=0;function ba(){throw Error(n(321))}function ka(e,t){if(null===t)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!fr(e[n],t[n]))return!1;return!0}function xa(e,t,r,o,i,a){if(da=a,fa=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,ua.current=null===e||null===e.memoizedState?os:is,e=r(o,i),ma){a=0;do{if(ma=!1,ya=0,25<=a)throw Error(n(301));a+=1,ha=pa=null,t.updateQueue=null,ua.current=as,e=r(o,i)}while(ma)}if(ua.current=rs,t=null!==pa&&null!==pa.next,da=0,ha=pa=fa=null,ga=!1,t)throw Error(n(300));return e}function wa(){var e=0!==ya;return ya=0,e}function Sa(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return null===ha?fa.memoizedState=ha=e:ha=ha.next=e,ha}function Ea(){if(null===pa){var e=fa.alternate;e=null!==e?e.memoizedState:null}else e=pa.next;var t=null===ha?fa.memoizedState:ha.next;if(null!==t)ha=t,pa=e;else{if(null===e)throw Error(n(310));e={memoizedState:(pa=e).memoizedState,baseState:pa.baseState,baseQueue:pa.baseQueue,queue:pa.queue,next:null},null===ha?fa.memoizedState=ha=e:ha=ha.next=e}return ha}function Ca(e,t){return"function"==typeof t?t(e):t}function Ta(e){var t=Ea(),r=t.queue;if(null===r)throw Error(n(311));r.lastRenderedReducer=e;var o=pa,i=o.baseQueue,a=r.pending;if(null!==a){if(null!==i){var s=i.next;i.next=a.next,a.next=s}o.baseQueue=i=a,r.pending=null}if(null!==i){a=i.next,o=o.baseState;var l=s=null,u=null,c=a;do{var d=c.lane;if((da&d)===d)null!==u&&(u=u.next={lane:0,action:c.action,hasEagerState:c.hasEagerState,eagerState:c.eagerState,next:null}),o=c.hasEagerState?c.eagerState:e(o,c.action);else{var f={lane:d,action:c.action,hasEagerState:c.hasEagerState,eagerState:c.eagerState,next:null};null===u?(l=u=f,s=o):u=u.next=f,fa.lanes|=d,Ul|=d}c=c.next}while(null!==c&&c!==a);null===u?s=o:u.next=l,fr(o,t.memoizedState)||(Ss=!0),t.memoizedState=o,t.baseState=s,t.baseQueue=u,r.lastRenderedState=o}if(null!==(e=r.interleaved)){i=e;do{a=i.lane,fa.lanes|=a,Ul|=a,i=i.next}while(i!==e)}else null===i&&(r.lanes=0);return[t.memoizedState,r.dispatch]}function Oa(e){var t=Ea(),r=t.queue;if(null===r)throw Error(n(311));r.lastRenderedReducer=e;var o=r.dispatch,i=r.pending,a=t.memoizedState;if(null!==i){r.pending=null;var s=i=i.next;do{a=e(a,s.action),s=s.next}while(s!==i);fr(a,t.memoizedState)||(Ss=!0),t.memoizedState=a,null===t.baseQueue&&(t.baseState=a),r.lastRenderedState=a}return[a,o]}function Na(){}function Pa(e,t){var r=fa,o=Ea(),i=t(),a=!fr(o.memoizedState,i);if(a&&(o.memoizedState=i,Ss=!0),o=o.queue,Ba(_a.bind(null,r,o,e),[e]),o.getSnapshot!==t||a||null!==ha&&1&ha.memoizedState.tag){if(r.flags|=2048,za(9,Ra.bind(null,r,o,i,t),void 0,null),null===Il)throw Error(n(349));30&da||La(r,t,i)}return i}function La(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},null===(t=fa.updateQueue)?(t={lastEffect:null,stores:null},fa.updateQueue=t,t.stores=[e]):null===(n=t.stores)?t.stores=[e]:n.push(e)}function Ra(e,t,n,r){t.value=n,t.getSnapshot=r,Ia(t)&&Aa(e)}function _a(e,t,n){return n(function(){Ia(t)&&Aa(e)})}function Ia(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!fr(e,n)}catch(r){return!0}}function Aa(e){var t=Ui(e,1);null!==t&&au(t,e,1,-1)}function Da(e){var t=Sa();return"function"==typeof e&&(e=e()),t.memoizedState=t.baseState=e,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:Ca,lastRenderedState:e},t.queue=e,e=e.dispatch=Za.bind(null,fa,e),[t.memoizedState,e]}function za(e,t,n,r){return e={tag:e,create:t,destroy:n,deps:r,next:null},null===(t=fa.updateQueue)?(t={lastEffect:null,stores:null},fa.updateQueue=t,t.lastEffect=e.next=e):null===(n=t.lastEffect)?t.lastEffect=e.next=e:(r=n.next,n.next=e,e.next=r,t.lastEffect=e),e}function ja(){return Ea().memoizedState}function Fa(e,t,n,r){var o=Sa();fa.flags|=e,o.memoizedState=za(1|t,n,void 0,void 0===r?null:r)}function Ma(e,t,n,r){var o=Ea();r=void 0===r?null:r;var i=void 0;if(null!==pa){var a=pa.memoizedState;if(i=a.destroy,null!==r&&ka(r,a.deps))return void(o.memoizedState=za(t,n,i,r))}fa.flags|=e,o.memoizedState=za(1|t,n,i,r)}function Ua(e,t){return Fa(8390656,8,e,t)}function Ba(e,t){return Ma(2048,8,e,t)}function $a(e,t){return Ma(4,2,e,t)}function Va(e,t){return Ma(4,4,e,t)}function Ha(e,t){return"function"==typeof t?(e=e(),t(e),function(){t(null)}):null!=t?(e=e(),t.current=e,function(){t.current=null}):void 0}function qa(e,t,n){return n=null!=n?n.concat([e]):null,Ma(4,4,Ha.bind(null,t,e),n)}function Wa(){}function Ka(e,t){var n=Ea();t=void 0===t?null:t;var r=n.memoizedState;return null!==r&&null!==t&&ka(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function Qa(e,t){var n=Ea();t=void 0===t?null:t;var r=n.memoizedState;return null!==r&&null!==t&&ka(t,r[1])?r[0]:(e=e(),n.memoizedState=[e,t],e)}function Ja(e,t,n){return 21&da?(fr(n,t)||(n=kt(),fa.lanes|=n,Ul|=n,e.baseState=!0),t):(e.baseState&&(e.baseState=!1,Ss=!0),e.memoizedState=n)}function Ya(e,t){var n=Et;Et=0!==n&&4>n?n:4,e(!0);var r=ca.transition;ca.transition={};try{e(!1),t()}finally{Et=n,ca.transition=r}}function Ga(){return Ea().memoizedState}function Xa(e,t,n){var r=iu(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},es(e))ts(t,n);else if(null!==(n=Mi(e,t,n,r))){au(n,e,r,ou()),ns(n,t,r)}}function Za(e,t,n){var r=iu(e),o={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(es(e))ts(t,o);else{var i=e.alternate;if(0===e.lanes&&(null===i||0===i.lanes)&&null!==(i=t.lastRenderedReducer))try{var a=t.lastRenderedState,s=i(a,n);if(o.hasEagerState=!0,o.eagerState=s,fr(s,a)){var l=t.interleaved;return null===l?(o.next=o,Fi(t)):(o.next=l.next,l.next=o),void(t.interleaved=o)}}catch(Fe){}null!==(n=Mi(e,t,o,r))&&(au(n,e,r,o=ou()),ns(n,t,r))}}function es(e){var t=e.alternate;return e===fa||null!==t&&t===fa}function ts(e,t){ma=ga=!0;var n=e.pending;null===n?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function ns(e,t,n){if(4194240&n){var r=t.lanes;n|=r&=e.pendingLanes,t.lanes=n,St(e,n)}}var rs={readContext:zi,useCallback:ba,useContext:ba,useEffect:ba,useImperativeHandle:ba,useInsertionEffect:ba,useLayoutEffect:ba,useMemo:ba,useReducer:ba,useRef:ba,useState:ba,useDebugValue:ba,useDeferredValue:ba,useTransition:ba,useMutableSource:ba,useSyncExternalStore:ba,useId:ba,unstable_isNewReconciler:!1},os={readContext:zi,useCallback:function(e,t){return Sa().memoizedState=[e,void 0===t?null:t],e},useContext:zi,useEffect:Ua,useImperativeHandle:function(e,t,n){return n=null!=n?n.concat([e]):null,Fa(4194308,4,Ha.bind(null,t,e),n)},useLayoutEffect:function(e,t){return Fa(4194308,4,e,t)},useInsertionEffect:function(e,t){return Fa(4,2,e,t)},useMemo:function(e,t){var n=Sa();return t=void 0===t?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=Sa();return t=void 0!==n?n(t):t,r.memoizedState=r.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},r.queue=e,e=e.dispatch=Xa.bind(null,fa,e),[r.memoizedState,e]},useRef:function(e){return e={current:e},Sa().memoizedState=e},useState:Da,useDebugValue:Wa,useDeferredValue:function(e){return Sa().memoizedState=e},useTransition:function(){var e=Da(!1),t=e[0];return e=Ya.bind(null,e[1]),Sa().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,r){var o=fa,i=Sa();if(ci){if(void 0===r)throw Error(n(407));r=r()}else{if(r=t(),null===Il)throw Error(n(349));30&da||La(o,t,r)}i.memoizedState=r;var a={value:r,getSnapshot:t};return i.queue=a,Ua(_a.bind(null,o,a,e),[e]),o.flags|=2048,za(9,Ra.bind(null,o,a,r,t),void 0,null),r},useId:function(){var e=Sa(),t=Il.identifierPrefix;if(ci){var n=ri;t=":"+t+"R"+(n=(ni&~(1<<32-dt(ni)-1)).toString(32)+n),0<(n=ya++)&&(t+="H"+n.toString(32)),t+=":"}else t=":"+t+"r"+(n=va++).toString(32)+":";return e.memoizedState=t},unstable_isNewReconciler:!1},is={readContext:zi,useCallback:Ka,useContext:zi,useEffect:Ba,useImperativeHandle:qa,useInsertionEffect:$a,useLayoutEffect:Va,useMemo:Qa,useReducer:Ta,useRef:ja,useState:function(){return Ta(Ca)},useDebugValue:Wa,useDeferredValue:function(e){return Ja(Ea(),pa.memoizedState,e)},useTransition:function(){return[Ta(Ca)[0],Ea().memoizedState]},useMutableSource:Na,useSyncExternalStore:Pa,useId:Ga,unstable_isNewReconciler:!1},as={readContext:zi,useCallback:Ka,useContext:zi,useEffect:Ba,useImperativeHandle:qa,useInsertionEffect:$a,useLayoutEffect:Va,useMemo:Qa,useReducer:Oa,useRef:ja,useState:function(){return Oa(Ca)},useDebugValue:Wa,useDeferredValue:function(e){var t=Ea();return null===pa?t.memoizedState=e:Ja(t,pa.memoizedState,e)},useTransition:function(){return[Oa(Ca)[0],Ea().memoizedState]},useMutableSource:Na,useSyncExternalStore:Pa,useId:Ga,unstable_isNewReconciler:!1};function ss(e,t){if(e&&e.defaultProps){for(var n in t=F({},t),e=e.defaultProps)void 0===t[n]&&(t[n]=e[n]);return t}return t}function ls(e,t,n,r){n=null==(n=n(r,t=e.memoizedState))?t:F({},t,n),e.memoizedState=n,0===e.lanes&&(e.updateQueue.baseState=n)}var us={isMounted:function(e){return!!(e=e._reactInternals)&&Ke(e)===e},enqueueSetState:function(e,t,n){e=e._reactInternals;var r=ou(),o=iu(e),i=Hi(r,o);i.payload=t,null!=n&&(i.callback=n),null!==(t=qi(e,i,o))&&(au(t,e,o,r),Wi(t,e,o))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=ou(),o=iu(e),i=Hi(r,o);i.tag=1,i.payload=t,null!=n&&(i.callback=n),null!==(t=qi(e,i,o))&&(au(t,e,o,r),Wi(t,e,o))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=ou(),r=iu(e),o=Hi(n,r);o.tag=2,null!=t&&(o.callback=t),null!==(t=qi(e,o,r))&&(au(t,e,r,n),Wi(t,e,r))}};function cs(e,t,n,r,o,i,a){return"function"==typeof(e=e.stateNode).shouldComponentUpdate?e.shouldComponentUpdate(r,i,a):!t.prototype||!t.prototype.isPureReactComponent||(!pr(n,r)||!pr(o,i))}function ds(e,t,n){var r=!1,o=Io,i=t.contextType;return"object"==typeof i&&null!==i?i=zi(i):(o=Fo(t)?zo:Ao.current,i=(r=null!=(r=t.contextTypes))?jo(e,o):Io),t=new t(n,i),e.memoizedState=null!==t.state&&void 0!==t.state?t.state:null,t.updater=us,e.stateNode=t,t._reactInternals=e,r&&((e=e.stateNode).__reactInternalMemoizedUnmaskedChildContext=o,e.__reactInternalMemoizedMaskedChildContext=i),t}function fs(e,t,n,r){e=t.state,"function"==typeof t.componentWillReceiveProps&&t.componentWillReceiveProps(n,r),"function"==typeof t.UNSAFE_componentWillReceiveProps&&t.UNSAFE_componentWillReceiveProps(n,r),t.state!==e&&us.enqueueReplaceState(t,t.state,null)}function ps(e,t,n,r){var o=e.stateNode;o.props=n,o.state=e.memoizedState,o.refs={},$i(e);var i=t.contextType;"object"==typeof i&&null!==i?o.context=zi(i):(i=Fo(t)?zo:Ao.current,o.context=jo(e,i)),o.state=e.memoizedState,"function"==typeof(i=t.getDerivedStateFromProps)&&(ls(e,t,i,n),o.state=e.memoizedState),"function"==typeof t.getDerivedStateFromProps||"function"==typeof o.getSnapshotBeforeUpdate||"function"!=typeof o.UNSAFE_componentWillMount&&"function"!=typeof o.componentWillMount||(t=o.state,"function"==typeof o.componentWillMount&&o.componentWillMount(),"function"==typeof o.UNSAFE_componentWillMount&&o.UNSAFE_componentWillMount(),t!==o.state&&us.enqueueReplaceState(o,o.state,null),Qi(e,n,o,r),o.state=e.memoizedState),"function"==typeof o.componentDidMount&&(e.flags|=4194308)}function hs(e,t){try{var n="",r=t;do{n+=$(r),r=r.return}while(r);var o=n}catch(i){o="\nError generating stack: "+i.message+"\n"+i.stack}return{value:e,source:t,stack:o,digest:null}}function gs(e,t,n){return{value:e,source:null,stack:null!=n?n:null,digest:null!=t?t:null}}var ms="function"==typeof WeakMap?WeakMap:Map;function ys(e,t,n){(n=Hi(-1,n)).tag=3,n.payload={element:null};var r=t.value;return n.callback=function(){Ql||(Ql=!0,Jl=r)},n}function vs(e,t,n){(n=Hi(-1,n)).tag=3;var r=e.type.getDerivedStateFromError;if("function"==typeof r){var o=t.value;n.payload=function(){return r(o)},n.callback=function(){}}var i=e.stateNode;return null!==i&&"function"==typeof i.componentDidCatch&&(n.callback=function(){"function"!=typeof r&&(null===Yl?Yl=new Set([this]):Yl.add(this));var e=t.stack;this.componentDidCatch(t.value,{componentStack:null!==e?e:""})}),n}function bs(e,t,n){var r=e.pingCache;if(null===r){r=e.pingCache=new ms;var o=new Set;r.set(t,o)}else void 0===(o=r.get(t))&&(o=new Set,r.set(t,o));o.has(n)||(o.add(n),e=Pu.bind(null,e,t,n),t.then(e,e))}function ks(e){do{var t;if((t=13===e.tag)&&(t=null===(t=e.memoizedState)||null!==t.dehydrated),t)return e;e=e.return}while(null!==e);return null}function xs(e,t,n,r,o){return 1&e.mode?(e.flags|=65536,e.lanes=o,e):(e===t?e.flags|=65536:(e.flags|=128,n.flags|=131072,n.flags&=-52805,1===n.tag&&(null===n.alternate?n.tag=17:((t=Hi(-1,1)).tag=2,qi(n,t,1))),n.lanes|=1),e)}var ws=x.ReactCurrentOwner,Ss=!1;function Es(e,t,n,r){t.child=null===e?Oi(t,null,n,r):Ti(t,e.child,n,r)}function Cs(e,t,n,r,o){n=n.render;var i=t.ref;return Di(t,o),r=xa(e,t,n,r,i,o),n=wa(),null===e||Ss?(ci&&n&&ai(t),t.flags|=1,Es(e,t,r,o),t.child):(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~o,Qs(e,t,o))}function Ts(e,t,n,r,o){if(null===e){var i=n.type;return"function"!=typeof i||zu(i)||void 0!==i.defaultProps||null!==n.compare||void 0!==n.defaultProps?((e=Fu(n.type,null,r,t,t.mode,o)).ref=t.ref,e.return=t,t.child=e):(t.tag=15,t.type=i,Os(e,t,i,r,o))}if(i=e.child,0===(e.lanes&o)){var a=i.memoizedProps;if((n=null!==(n=n.compare)?n:pr)(a,r)&&e.ref===t.ref)return Qs(e,t,o)}return t.flags|=1,(e=ju(i,r)).ref=t.ref,e.return=t,t.child=e}function Os(e,t,n,r,o){if(null!==e){var i=e.memoizedProps;if(pr(i,r)&&e.ref===t.ref){if(Ss=!1,t.pendingProps=r=i,0===(e.lanes&o))return t.lanes=e.lanes,Qs(e,t,o);131072&e.flags&&(Ss=!0)}}return Ls(e,t,n,r,o)}function Ns(e,t,n){var r=t.pendingProps,o=r.children,i=null!==e?e.memoizedState:null;if("hidden"===r.mode)if(1&t.mode){if(!(1073741824&n))return e=null!==i?i.baseLanes|n:n,t.lanes=t.childLanes=1073741824,t.memoizedState={baseLanes:e,cachePool:null,transitions:null},t.updateQueue=null,_o(jl,zl),zl|=e,null;t.memoizedState={baseLanes:0,cachePool:null,transitions:null},r=null!==i?i.baseLanes:n,_o(jl,zl),zl|=r}else t.memoizedState={baseLanes:0,cachePool:null,transitions:null},_o(jl,zl),zl|=n;else null!==i?(r=i.baseLanes|n,t.memoizedState=null):r=n,_o(jl,zl),zl|=r;return Es(e,t,o,n),t.child}function Ps(e,t){var n=t.ref;(null===e&&null!==n||null!==e&&e.ref!==n)&&(t.flags|=512,t.flags|=2097152)}function Ls(e,t,n,r,o){var i=Fo(n)?zo:Ao.current;return i=jo(t,i),Di(t,o),n=xa(e,t,n,r,i,o),r=wa(),null===e||Ss?(ci&&r&&ai(t),t.flags|=1,Es(e,t,n,o),t.child):(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~o,Qs(e,t,o))}function Rs(e,t,n,r,o){if(Fo(n)){var i=!0;$o(t)}else i=!1;if(Di(t,o),null===t.stateNode)Ks(e,t),ds(t,n,r),ps(t,n,r,o),r=!0;else if(null===e){var a=t.stateNode,s=t.memoizedProps;a.props=s;var l=a.context,u=n.contextType;"object"==typeof u&&null!==u?u=zi(u):u=jo(t,u=Fo(n)?zo:Ao.current);var c=n.getDerivedStateFromProps,d="function"==typeof c||"function"==typeof a.getSnapshotBeforeUpdate;d||"function"!=typeof a.UNSAFE_componentWillReceiveProps&&"function"!=typeof a.componentWillReceiveProps||(s!==r||l!==u)&&fs(t,a,r,u),Bi=!1;var f=t.memoizedState;a.state=f,Qi(t,r,a,o),l=t.memoizedState,s!==r||f!==l||Do.current||Bi?("function"==typeof c&&(ls(t,n,c,r),l=t.memoizedState),(s=Bi||cs(t,n,s,r,f,l,u))?(d||"function"!=typeof a.UNSAFE_componentWillMount&&"function"!=typeof a.componentWillMount||("function"==typeof a.componentWillMount&&a.componentWillMount(),"function"==typeof a.UNSAFE_componentWillMount&&a.UNSAFE_componentWillMount()),"function"==typeof a.componentDidMount&&(t.flags|=4194308)):("function"==typeof a.componentDidMount&&(t.flags|=4194308),t.memoizedProps=r,t.memoizedState=l),a.props=r,a.state=l,a.context=u,r=s):("function"==typeof a.componentDidMount&&(t.flags|=4194308),r=!1)}else{a=t.stateNode,Vi(e,t),s=t.memoizedProps,u=t.type===t.elementType?s:ss(t.type,s),a.props=u,d=t.pendingProps,f=a.context,"object"==typeof(l=n.contextType)&&null!==l?l=zi(l):l=jo(t,l=Fo(n)?zo:Ao.current);var p=n.getDerivedStateFromProps;(c="function"==typeof p||"function"==typeof a.getSnapshotBeforeUpdate)||"function"!=typeof a.UNSAFE_componentWillReceiveProps&&"function"!=typeof a.componentWillReceiveProps||(s!==d||f!==l)&&fs(t,a,r,l),Bi=!1,f=t.memoizedState,a.state=f,Qi(t,r,a,o);var h=t.memoizedState;s!==d||f!==h||Do.current||Bi?("function"==typeof p&&(ls(t,n,p,r),h=t.memoizedState),(u=Bi||cs(t,n,u,r,f,h,l)||!1)?(c||"function"!=typeof a.UNSAFE_componentWillUpdate&&"function"!=typeof a.componentWillUpdate||("function"==typeof a.componentWillUpdate&&a.componentWillUpdate(r,h,l),"function"==typeof a.UNSAFE_componentWillUpdate&&a.UNSAFE_componentWillUpdate(r,h,l)),"function"==typeof a.componentDidUpdate&&(t.flags|=4),"function"==typeof a.getSnapshotBeforeUpdate&&(t.flags|=1024)):("function"!=typeof a.componentDidUpdate||s===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),"function"!=typeof a.getSnapshotBeforeUpdate||s===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=h),a.props=r,a.state=h,a.context=l,r=u):("function"!=typeof a.componentDidUpdate||s===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),"function"!=typeof a.getSnapshotBeforeUpdate||s===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),r=!1)}return _s(e,t,n,r,i,o)}function _s(e,t,n,r,o,i){Ps(e,t);var a=!!(128&t.flags);if(!r&&!a)return o&&Vo(t,n,!1),Qs(e,t,i);r=t.stateNode,ws.current=t;var s=a&&"function"!=typeof n.getDerivedStateFromError?null:r.render();return t.flags|=1,null!==e&&a?(t.child=Ti(t,e.child,null,i),t.child=Ti(t,null,s,i)):Es(e,t,s,i),t.memoizedState=r.state,o&&Vo(t,n,!0),t.child}function Is(e){var t=e.stateNode;t.pendingContext?Uo(0,t.pendingContext,t.pendingContext!==t.context):t.context&&Uo(0,t.context,!1),ta(e,t.containerInfo)}function As(e,t,n,r,o){return bi(),ki(o),t.flags|=256,Es(e,t,n,r),t.child}var Ds,zs,js,Fs,Ms={dehydrated:null,treeContext:null,retryLane:0};function Us(e){return{baseLanes:e,cachePool:null,transitions:null}}function Bs(e,t,r){var o,i=t.pendingProps,a=ia.current,s=!1,l=!!(128&t.flags);if((o=l)||(o=(null===e||null!==e.memoizedState)&&!!(2&a)),o?(s=!0,t.flags&=-129):null!==e&&null===e.memoizedState||(a|=1),_o(ia,1&a),null===e)return gi(t),null!==(e=t.memoizedState)&&null!==(e=e.dehydrated)?(1&t.mode?"$!"===e.data?t.lanes=8:t.lanes=1073741824:t.lanes=1,null):(l=i.children,e=i.fallback,s?(i=t.mode,s=t.child,l={mode:"hidden",children:l},1&i||null===s?s=Uu(l,i,0,null):(s.childLanes=0,s.pendingProps=l),e=Mu(e,i,r,null),s.return=t,e.return=t,s.sibling=e,t.child=s,t.child.memoizedState=Us(r),t.memoizedState=Ms,e):$s(t,l));if(null!==(a=e.memoizedState)&&null!==(o=a.dehydrated))return function(e,t,r,o,i,a,s){if(r)return 256&t.flags?(t.flags&=-257,Vs(e,t,s,o=gs(Error(n(422))))):null!==t.memoizedState?(t.child=e.child,t.flags|=128,null):(a=o.fallback,i=t.mode,o=Uu({mode:"visible",children:o.children},i,0,null),(a=Mu(a,i,s,null)).flags|=2,o.return=t,a.return=t,o.sibling=a,t.child=o,1&t.mode&&Ti(t,e.child,null,s),t.child.memoizedState=Us(s),t.memoizedState=Ms,a);if(!(1&t.mode))return Vs(e,t,s,null);if("$!"===i.data){if(o=i.nextSibling&&i.nextSibling.dataset)var l=o.dgst;return o=l,Vs(e,t,s,o=gs(a=Error(n(419)),o,void 0))}if(l=0!==(s&e.childLanes),Ss||l){if(null!==(o=Il)){switch(s&-s){case 4:i=2;break;case 16:i=8;break;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:i=32;break;case 536870912:i=268435456;break;default:i=0}0!==(i=0!==(i&(o.suspendedLanes|s))?0:i)&&i!==a.retryLane&&(a.retryLane=i,Ui(e,i),au(o,e,i,-1))}return bu(),Vs(e,t,s,o=gs(Error(n(421))))}return"$?"===i.data?(t.flags|=128,t.child=e.child,t=Ru.bind(null,e),i._reactRetry=t,null):(e=a.treeContext,ui=go(i.nextSibling),li=t,ci=!0,di=null,null!==e&&(Zo[ei++]=ni,Zo[ei++]=ri,Zo[ei++]=ti,ni=e.id,ri=e.overflow,ti=t),t=$s(t,o.children),t.flags|=4096,t)}(e,t,l,i,o,a,r);if(s){s=i.fallback,l=t.mode,o=(a=e.child).sibling;var u={mode:"hidden",children:i.children};return 1&l||t.child===a?(i=ju(a,u)).subtreeFlags=14680064&a.subtreeFlags:((i=t.child).childLanes=0,i.pendingProps=u,t.deletions=null),null!==o?s=ju(o,s):(s=Mu(s,l,r,null)).flags|=2,s.return=t,i.return=t,i.sibling=s,t.child=i,i=s,s=t.child,l=null===(l=e.child.memoizedState)?Us(r):{baseLanes:l.baseLanes|r,cachePool:null,transitions:l.transitions},s.memoizedState=l,s.childLanes=e.childLanes&~r,t.memoizedState=Ms,i}return e=(s=e.child).sibling,i=ju(s,{mode:"visible",children:i.children}),!(1&t.mode)&&(i.lanes=r),i.return=t,i.sibling=null,null!==e&&(null===(r=t.deletions)?(t.deletions=[e],t.flags|=16):r.push(e)),t.child=i,t.memoizedState=null,i}function $s(e,t){return(t=Uu({mode:"visible",children:t},e.mode,0,null)).return=e,e.child=t}function Vs(e,t,n,r){return null!==r&&ki(r),Ti(t,e.child,null,n),(e=$s(t,t.pendingProps.children)).flags|=2,t.memoizedState=null,e}function Hs(e,t,n){e.lanes|=t;var r=e.alternate;null!==r&&(r.lanes|=t),Ai(e.return,t,n)}function qs(e,t,n,r,o){var i=e.memoizedState;null===i?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:o}:(i.isBackwards=t,i.rendering=null,i.renderingStartTime=0,i.last=r,i.tail=n,i.tailMode=o)}function Ws(e,t,n){var r=t.pendingProps,o=r.revealOrder,i=r.tail;if(Es(e,t,r.children,n),2&(r=ia.current))r=1&r|2,t.flags|=128;else{if(null!==e&&128&e.flags)e:for(e=t.child;null!==e;){if(13===e.tag)null!==e.memoizedState&&Hs(e,n,t);else if(19===e.tag)Hs(e,n,t);else if(null!==e.child){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;null===e.sibling;){if(null===e.return||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}r&=1}if(_o(ia,r),1&t.mode)switch(o){case"forwards":for(n=t.child,o=null;null!==n;)null!==(e=n.alternate)&&null===aa(e)&&(o=n),n=n.sibling;null===(n=o)?(o=t.child,t.child=null):(o=n.sibling,n.sibling=null),qs(t,!1,o,n,i);break;case"backwards":for(n=null,o=t.child,t.child=null;null!==o;){if(null!==(e=o.alternate)&&null===aa(e)){t.child=o;break}e=o.sibling,o.sibling=n,n=o,o=e}qs(t,!0,n,null,i);break;case"together":qs(t,!1,null,null,void 0);break;default:t.memoizedState=null}else t.memoizedState=null;return t.child}function Ks(e,t){!(1&t.mode)&&null!==e&&(e.alternate=null,t.alternate=null,t.flags|=2)}function Qs(e,t,r){if(null!==e&&(t.dependencies=e.dependencies),Ul|=t.lanes,0===(r&t.childLanes))return null;if(null!==e&&t.child!==e.child)throw Error(n(153));if(null!==t.child){for(r=ju(e=t.child,e.pendingProps),t.child=r,r.return=t;null!==e.sibling;)e=e.sibling,(r=r.sibling=ju(e,e.pendingProps)).return=t;r.sibling=null}return t.child}function Js(e,t){if(!ci)switch(e.tailMode){case"hidden":t=e.tail;for(var n=null;null!==t;)null!==t.alternate&&(n=t),t=t.sibling;null===n?e.tail=null:n.sibling=null;break;case"collapsed":n=e.tail;for(var r=null;null!==n;)null!==n.alternate&&(r=n),n=n.sibling;null===r?t||null===e.tail?e.tail=null:e.tail.sibling=null:r.sibling=null}}function Ys(e){var t=null!==e.alternate&&e.alternate.child===e.child,n=0,r=0;if(t)for(var o=e.child;null!==o;)n|=o.lanes|o.childLanes,r|=14680064&o.subtreeFlags,r|=14680064&o.flags,o.return=e,o=o.sibling;else for(o=e.child;null!==o;)n|=o.lanes|o.childLanes,r|=o.subtreeFlags,r|=o.flags,o.return=e,o=o.sibling;return e.subtreeFlags|=r,e.childLanes=n,t}function Gs(e,t,r){var i=t.pendingProps;switch(si(t),t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Ys(t),null;case 1:case 17:return Fo(t.type)&&Mo(),Ys(t),null;case 3:return i=t.stateNode,na(),Ro(Do),Ro(Ao),la(),i.pendingContext&&(i.context=i.pendingContext,i.pendingContext=null),null!==e&&null!==e.child||(yi(t)?t.flags|=4:null===e||e.memoizedState.isDehydrated&&!(256&t.flags)||(t.flags|=1024,null!==di&&(cu(di),di=null))),zs(e,t),Ys(t),null;case 5:oa(t);var a=ea(Zi.current);if(r=t.type,null!==e&&null!=t.stateNode)js(e,t,r,i,a),e.ref!==t.ref&&(t.flags|=512,t.flags|=2097152);else{if(!i){if(null===t.stateNode)throw Error(n(166));return Ys(t),null}if(e=ea(Gi.current),yi(t)){i=t.stateNode,r=t.type;var s=t.memoizedProps;switch(i[vo]=t,i[bo]=s,e=!!(1&t.mode),r){case"dialog":Hr("cancel",i),Hr("close",i);break;case"iframe":case"object":case"embed":Hr("load",i);break;case"video":case"audio":for(a=0;a<Ur.length;a++)Hr(Ur[a],i);break;case"source":Hr("error",i);break;case"img":case"image":case"link":Hr("error",i),Hr("load",i);break;case"details":Hr("toggle",i);break;case"input":G(i,s),Hr("invalid",i);break;case"select":i._wrapperState={wasMultiple:!!s.multiple},Hr("invalid",i);break;case"textarea":ie(i,s),Hr("invalid",i)}for(var l in be(r,s),a=null,s)if(s.hasOwnProperty(l)){var u=s[l];"children"===l?"string"==typeof u?i.textContent!==u&&(!0!==s.suppressHydrationWarning&&ro(i.textContent,u,e),a=["children",u]):"number"==typeof u&&i.textContent!==""+u&&(!0!==s.suppressHydrationWarning&&ro(i.textContent,u,e),a=["children",""+u]):o.hasOwnProperty(l)&&null!=u&&"onScroll"===l&&Hr("scroll",i)}switch(r){case"input":K(i),ee(i,s,!0);break;case"textarea":K(i),se(i);break;case"select":case"option":break;default:"function"==typeof s.onClick&&(i.onclick=oo)}i=a,t.updateQueue=i,null!==i&&(t.flags|=4)}else{l=9===a.nodeType?a:a.ownerDocument,"http://www.w3.org/1999/xhtml"===e&&(e=le(r)),"http://www.w3.org/1999/xhtml"===e?"script"===r?((e=l.createElement("div")).innerHTML="<script><\/script>",e=e.removeChild(e.firstChild)):"string"==typeof i.is?e=l.createElement(r,{is:i.is}):(e=l.createElement(r),"select"===r&&(l=e,i.multiple?l.multiple=!0:i.size&&(l.size=i.size))):e=l.createElementNS(e,r),e[vo]=t,e[bo]=i,Ds(e,t,!1,!1),t.stateNode=e;e:{switch(l=ke(r,i),r){case"dialog":Hr("cancel",e),Hr("close",e),a=i;break;case"iframe":case"object":case"embed":Hr("load",e),a=i;break;case"video":case"audio":for(a=0;a<Ur.length;a++)Hr(Ur[a],e);a=i;break;case"source":Hr("error",e),a=i;break;case"img":case"image":case"link":Hr("error",e),Hr("load",e),a=i;break;case"details":Hr("toggle",e),a=i;break;case"input":G(e,i),a=Y(e,i),Hr("invalid",e);break;case"option":default:a=i;break;case"select":e._wrapperState={wasMultiple:!!i.multiple},a=F({},i,{value:void 0}),Hr("invalid",e);break;case"textarea":ie(e,i),a=oe(e,i),Hr("invalid",e)}for(s in be(r,a),u=a)if(u.hasOwnProperty(s)){var c=u[s];"style"===s?ye(e,c):"dangerouslySetInnerHTML"===s?null!=(c=c?c.__html:void 0)&&fe(e,c):"children"===s?"string"==typeof c?("textarea"!==r||""!==c)&&pe(e,c):"number"==typeof c&&pe(e,""+c):"suppressContentEditableWarning"!==s&&"suppressHydrationWarning"!==s&&"autoFocus"!==s&&(o.hasOwnProperty(s)?null!=c&&"onScroll"===s&&Hr("scroll",e):null!=c&&b(e,s,c,l))}switch(r){case"input":K(e),ee(e,i,!1);break;case"textarea":K(e),se(e);break;case"option":null!=i.value&&e.setAttribute("value",""+q(i.value));break;case"select":e.multiple=!!i.multiple,null!=(s=i.value)?re(e,!!i.multiple,s,!1):null!=i.defaultValue&&re(e,!!i.multiple,i.defaultValue,!0);break;default:"function"==typeof a.onClick&&(e.onclick=oo)}switch(r){case"button":case"input":case"select":case"textarea":i=!!i.autoFocus;break e;case"img":i=!0;break e;default:i=!1}}i&&(t.flags|=4)}null!==t.ref&&(t.flags|=512,t.flags|=2097152)}return Ys(t),null;case 6:if(e&&null!=t.stateNode)Fs(e,t,e.memoizedProps,i);else{if("string"!=typeof i&&null===t.stateNode)throw Error(n(166));if(r=ea(Zi.current),ea(Gi.current),yi(t)){if(i=t.stateNode,r=t.memoizedProps,i[vo]=t,(s=i.nodeValue!==r)&&null!==(e=li))switch(e.tag){case 3:ro(i.nodeValue,r,!!(1&e.mode));break;case 5:!0!==e.memoizedProps.suppressHydrationWarning&&ro(i.nodeValue,r,!!(1&e.mode))}s&&(t.flags|=4)}else(i=(9===r.nodeType?r:r.ownerDocument).createTextNode(i))[vo]=t,t.stateNode=i}return Ys(t),null;case 13:if(Ro(ia),i=t.memoizedState,null===e||null!==e.memoizedState&&null!==e.memoizedState.dehydrated){if(ci&&null!==ui&&1&t.mode&&!(128&t.flags))vi(),bi(),t.flags|=98560,s=!1;else if(s=yi(t),null!==i&&null!==i.dehydrated){if(null===e){if(!s)throw Error(n(318));if(!(s=null!==(s=t.memoizedState)?s.dehydrated:null))throw Error(n(317));s[vo]=t}else bi(),!(128&t.flags)&&(t.memoizedState=null),t.flags|=4;Ys(t),s=!1}else null!==di&&(cu(di),di=null),s=!0;if(!s)return 65536&t.flags?t:null}return 128&t.flags?(t.lanes=r,t):((i=null!==i)!==(null!==e&&null!==e.memoizedState)&&i&&(t.child.flags|=8192,1&t.mode&&(null===e||1&ia.current?0===Fl&&(Fl=3):bu())),null!==t.updateQueue&&(t.flags|=4),Ys(t),null);case 4:return na(),zs(e,t),null===e&&Kr(t.stateNode.containerInfo),Ys(t),null;case 10:return Ii(t.type._context),Ys(t),null;case 19:if(Ro(ia),null===(s=t.memoizedState))return Ys(t),null;if(i=!!(128&t.flags),null===(l=s.rendering))if(i)Js(s,!1);else{if(0!==Fl||null!==e&&128&e.flags)for(e=t.child;null!==e;){if(null!==(l=aa(e))){for(t.flags|=128,Js(s,!1),null!==(i=l.updateQueue)&&(t.updateQueue=i,t.flags|=4),t.subtreeFlags=0,i=r,r=t.child;null!==r;)e=i,(s=r).flags&=14680066,null===(l=s.alternate)?(s.childLanes=0,s.lanes=e,s.child=null,s.subtreeFlags=0,s.memoizedProps=null,s.memoizedState=null,s.updateQueue=null,s.dependencies=null,s.stateNode=null):(s.childLanes=l.childLanes,s.lanes=l.lanes,s.child=l.child,s.subtreeFlags=0,s.deletions=null,s.memoizedProps=l.memoizedProps,s.memoizedState=l.memoizedState,s.updateQueue=l.updateQueue,s.type=l.type,e=l.dependencies,s.dependencies=null===e?null:{lanes:e.lanes,firstContext:e.firstContext}),r=r.sibling;return _o(ia,1&ia.current|2),t.child}e=e.sibling}null!==s.tail&&nt()>Wl&&(t.flags|=128,i=!0,Js(s,!1),t.lanes=4194304)}else{if(!i)if(null!==(e=aa(l))){if(t.flags|=128,i=!0,null!==(r=e.updateQueue)&&(t.updateQueue=r,t.flags|=4),Js(s,!0),null===s.tail&&"hidden"===s.tailMode&&!l.alternate&&!ci)return Ys(t),null}else 2*nt()-s.renderingStartTime>Wl&&1073741824!==r&&(t.flags|=128,i=!0,Js(s,!1),t.lanes=4194304);s.isBackwards?(l.sibling=t.child,t.child=l):(null!==(r=s.last)?r.sibling=l:t.child=l,s.last=l)}return null!==s.tail?(t=s.tail,s.rendering=t,s.tail=t.sibling,s.renderingStartTime=nt(),t.sibling=null,r=ia.current,_o(ia,i?1&r|2:1&r),t):(Ys(t),null);case 22:case 23:return gu(),i=null!==t.memoizedState,null!==e&&null!==e.memoizedState!==i&&(t.flags|=8192),i&&1&t.mode?!!(1073741824&zl)&&(Ys(t),6&t.subtreeFlags&&(t.flags|=8192)):Ys(t),null;case 24:case 25:return null}throw Error(n(156,t.tag))}function Xs(e,t){switch(si(t),t.tag){case 1:return Fo(t.type)&&Mo(),65536&(e=t.flags)?(t.flags=-65537&e|128,t):null;case 3:return na(),Ro(Do),Ro(Ao),la(),65536&(e=t.flags)&&!(128&e)?(t.flags=-65537&e|128,t):null;case 5:return oa(t),null;case 13:if(Ro(ia),null!==(e=t.memoizedState)&&null!==e.dehydrated){if(null===t.alternate)throw Error(n(340));bi()}return 65536&(e=t.flags)?(t.flags=-65537&e|128,t):null;case 19:return Ro(ia),null;case 4:return na(),null;case 10:return Ii(t.type._context),null;case 22:case 23:return gu(),null;default:return null}}Ds=function(e,t){for(var n=t.child;null!==n;){if(5===n.tag||6===n.tag)e.appendChild(n.stateNode);else if(4!==n.tag&&null!==n.child){n.child.return=n,n=n.child;continue}if(n===t)break;for(;null===n.sibling;){if(null===n.return||n.return===t)return;n=n.return}n.sibling.return=n.return,n=n.sibling}},zs=function(){},js=function(e,t,n,r){var i=e.memoizedProps;if(i!==r){e=t.stateNode,ea(Gi.current);var a,s=null;switch(n){case"input":i=Y(e,i),r=Y(e,r),s=[];break;case"select":i=F({},i,{value:void 0}),r=F({},r,{value:void 0}),s=[];break;case"textarea":i=oe(e,i),r=oe(e,r),s=[];break;default:"function"!=typeof i.onClick&&"function"==typeof r.onClick&&(e.onclick=oo)}for(c in be(n,r),n=null,i)if(!r.hasOwnProperty(c)&&i.hasOwnProperty(c)&&null!=i[c])if("style"===c){var l=i[c];for(a in l)l.hasOwnProperty(a)&&(n||(n={}),n[a]="")}else"dangerouslySetInnerHTML"!==c&&"children"!==c&&"suppressContentEditableWarning"!==c&&"suppressHydrationWarning"!==c&&"autoFocus"!==c&&(o.hasOwnProperty(c)?s||(s=[]):(s=s||[]).push(c,null));for(c in r){var u=r[c];if(l=null!=i?i[c]:void 0,r.hasOwnProperty(c)&&u!==l&&(null!=u||null!=l))if("style"===c)if(l){for(a in l)!l.hasOwnProperty(a)||u&&u.hasOwnProperty(a)||(n||(n={}),n[a]="");for(a in u)u.hasOwnProperty(a)&&l[a]!==u[a]&&(n||(n={}),n[a]=u[a])}else n||(s||(s=[]),s.push(c,n)),n=u;else"dangerouslySetInnerHTML"===c?(u=u?u.__html:void 0,l=l?l.__html:void 0,null!=u&&l!==u&&(s=s||[]).push(c,u)):"children"===c?"string"!=typeof u&&"number"!=typeof u||(s=s||[]).push(c,""+u):"suppressContentEditableWarning"!==c&&"suppressHydrationWarning"!==c&&(o.hasOwnProperty(c)?(null!=u&&"onScroll"===c&&Hr("scroll",e),s||l===u||(s=[])):(s=s||[]).push(c,u))}n&&(s=s||[]).push("style",n);var c=s;(t.updateQueue=c)&&(t.flags|=4)}},Fs=function(e,t,n,r){n!==r&&(t.flags|=4)};var Zs=!1,el=!1,tl="function"==typeof WeakSet?WeakSet:Set,nl=null;function rl(e,t){var n=e.ref;if(null!==n)if("function"==typeof n)try{n(null)}catch(r){Nu(e,t,r)}else n.current=null}function ol(e,t,n){try{n()}catch(r){Nu(e,t,r)}}var il=!1;function al(e,t,n){var r=t.updateQueue;if(null!==(r=null!==r?r.lastEffect:null)){var o=r=r.next;do{if((o.tag&e)===e){var i=o.destroy;o.destroy=void 0,void 0!==i&&ol(t,n,i)}o=o.next}while(o!==r)}}function sl(e,t){if(null!==(t=null!==(t=t.updateQueue)?t.lastEffect:null)){var n=t=t.next;do{if((n.tag&e)===e){var r=n.create;n.destroy=r()}n=n.next}while(n!==t)}}function ll(e){var t=e.ref;if(null!==t){var n=e.stateNode;e.tag,e=n,"function"==typeof t?t(e):t.current=e}}function ul(e){var t=e.alternate;null!==t&&(e.alternate=null,ul(t)),e.child=null,e.deletions=null,e.sibling=null,5===e.tag&&(null!==(t=e.stateNode)&&(delete t[vo],delete t[bo],delete t[xo],delete t[wo],delete t[So])),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function cl(e){return 5===e.tag||3===e.tag||4===e.tag}function dl(e){e:for(;;){for(;null===e.sibling;){if(null===e.return||cl(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;5!==e.tag&&6!==e.tag&&18!==e.tag;){if(2&e.flags)continue e;if(null===e.child||4===e.tag)continue e;e.child.return=e,e=e.child}if(!(2&e.flags))return e.stateNode}}function fl(e,t,n){var r=e.tag;if(5===r||6===r)e=e.stateNode,t?8===n.nodeType?n.parentNode.insertBefore(e,t):n.insertBefore(e,t):(8===n.nodeType?(t=n.parentNode).insertBefore(e,n):(t=n).appendChild(e),null!=(n=n._reactRootContainer)||null!==t.onclick||(t.onclick=oo));else if(4!==r&&null!==(e=e.child))for(fl(e,t,n),e=e.sibling;null!==e;)fl(e,t,n),e=e.sibling}function pl(e,t,n){var r=e.tag;if(5===r||6===r)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(4!==r&&null!==(e=e.child))for(pl(e,t,n),e=e.sibling;null!==e;)pl(e,t,n),e=e.sibling}var hl=null,gl=!1;function ml(e,t,n){for(n=n.child;null!==n;)yl(e,t,n),n=n.sibling}function yl(e,t,n){if(ct&&"function"==typeof ct.onCommitFiberUnmount)try{ct.onCommitFiberUnmount(ut,n)}catch(s){}switch(n.tag){case 5:el||rl(n,t);case 6:var r=hl,o=gl;hl=null,ml(e,t,n),gl=o,null!==(hl=r)&&(gl?(e=hl,n=n.stateNode,8===e.nodeType?e.parentNode.removeChild(n):e.removeChild(n)):hl.removeChild(n.stateNode));break;case 18:null!==hl&&(gl?(e=hl,n=n.stateNode,8===e.nodeType?ho(e.parentNode,n):1===e.nodeType&&ho(e,n),Kt(e)):ho(hl,n.stateNode));break;case 4:r=hl,o=gl,hl=n.stateNode.containerInfo,gl=!0,ml(e,t,n),hl=r,gl=o;break;case 0:case 11:case 14:case 15:if(!el&&(null!==(r=n.updateQueue)&&null!==(r=r.lastEffect))){o=r=r.next;do{var i=o,a=i.destroy;i=i.tag,void 0!==a&&(2&i||4&i)&&ol(n,t,a),o=o.next}while(o!==r)}ml(e,t,n);break;case 1:if(!el&&(rl(n,t),"function"==typeof(r=n.stateNode).componentWillUnmount))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(s){Nu(n,t,s)}ml(e,t,n);break;case 21:ml(e,t,n);break;case 22:1&n.mode?(el=(r=el)||null!==n.memoizedState,ml(e,t,n),el=r):ml(e,t,n);break;default:ml(e,t,n)}}function vl(e){var t=e.updateQueue;if(null!==t){e.updateQueue=null;var n=e.stateNode;null===n&&(n=e.stateNode=new tl),t.forEach(function(t){var r=_u.bind(null,e,t);n.has(t)||(n.add(t),t.then(r,r))})}}function bl(e,t){var r=t.deletions;if(null!==r)for(var o=0;o<r.length;o++){var i=r[o];try{var a=e,s=t,l=s;e:for(;null!==l;){switch(l.tag){case 5:hl=l.stateNode,gl=!1;break e;case 3:case 4:hl=l.stateNode.containerInfo,gl=!0;break e}l=l.return}if(null===hl)throw Error(n(160));yl(a,s,i),hl=null,gl=!1;var u=i.alternate;null!==u&&(u.return=null),i.return=null}catch(Fe){Nu(i,t,Fe)}}if(12854&t.subtreeFlags)for(t=t.child;null!==t;)kl(t,e),t=t.sibling}function kl(e,t){var r=e.alternate,o=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:if(bl(t,e),xl(e),4&o){try{al(3,e,e.return),sl(3,e)}catch(ze){Nu(e,e.return,ze)}try{al(5,e,e.return)}catch(ze){Nu(e,e.return,ze)}}break;case 1:bl(t,e),xl(e),512&o&&null!==r&&rl(r,r.return);break;case 5:if(bl(t,e),xl(e),512&o&&null!==r&&rl(r,r.return),32&e.flags){var i=e.stateNode;try{pe(i,"")}catch(ze){Nu(e,e.return,ze)}}if(4&o&&null!=(i=e.stateNode)){var a=e.memoizedProps,s=null!==r?r.memoizedProps:a,l=e.type,u=e.updateQueue;if(e.updateQueue=null,null!==u)try{"input"===l&&"radio"===a.type&&null!=a.name&&X(i,a),ke(l,s);var c=ke(l,a);for(s=0;s<u.length;s+=2){var d=u[s],f=u[s+1];"style"===d?ye(i,f):"dangerouslySetInnerHTML"===d?fe(i,f):"children"===d?pe(i,f):b(i,d,f,c)}switch(l){case"input":Z(i,a);break;case"textarea":ae(i,a);break;case"select":var p=i._wrapperState.wasMultiple;i._wrapperState.wasMultiple=!!a.multiple;var h=a.value;null!=h?re(i,!!a.multiple,h,!1):p!==!!a.multiple&&(null!=a.defaultValue?re(i,!!a.multiple,a.defaultValue,!0):re(i,!!a.multiple,a.multiple?[]:"",!1))}i[bo]=a}catch(ze){Nu(e,e.return,ze)}}break;case 6:if(bl(t,e),xl(e),4&o){if(null===e.stateNode)throw Error(n(162));i=e.stateNode,a=e.memoizedProps;try{i.nodeValue=a}catch(ze){Nu(e,e.return,ze)}}break;case 3:if(bl(t,e),xl(e),4&o&&null!==r&&r.memoizedState.isDehydrated)try{Kt(t.containerInfo)}catch(ze){Nu(e,e.return,ze)}break;case 4:default:bl(t,e),xl(e);break;case 13:bl(t,e),xl(e),8192&(i=e.child).flags&&(a=null!==i.memoizedState,i.stateNode.isHidden=a,!a||null!==i.alternate&&null!==i.alternate.memoizedState||(ql=nt())),4&o&&vl(e);break;case 22:if(d=null!==r&&null!==r.memoizedState,1&e.mode?(el=(c=el)||d,bl(t,e),el=c):bl(t,e),xl(e),8192&o){if(c=null!==e.memoizedState,(e.stateNode.isHidden=c)&&!d&&1&e.mode)for(nl=e,d=e.child;null!==d;){for(f=nl=d;null!==nl;){switch(h=(p=nl).child,p.tag){case 0:case 11:case 14:case 15:al(4,p,p.return);break;case 1:rl(p,p.return);var g=p.stateNode;if("function"==typeof g.componentWillUnmount){o=p,r=p.return;try{t=o,g.props=t.memoizedProps,g.state=t.memoizedState,g.componentWillUnmount()}catch(ze){Nu(o,r,ze)}}break;case 5:rl(p,p.return);break;case 22:if(null!==p.memoizedState){Cl(f);continue}}null!==h?(h.return=p,nl=h):Cl(f)}d=d.sibling}e:for(d=null,f=e;;){if(5===f.tag){if(null===d){d=f;try{i=f.stateNode,c?"function"==typeof(a=i.style).setProperty?a.setProperty("display","none","important"):a.display="none":(l=f.stateNode,s=null!=(u=f.memoizedProps.style)&&u.hasOwnProperty("display")?u.display:null,l.style.display=me("display",s))}catch(ze){Nu(e,e.return,ze)}}}else if(6===f.tag){if(null===d)try{f.stateNode.nodeValue=c?"":f.memoizedProps}catch(ze){Nu(e,e.return,ze)}}else if((22!==f.tag&&23!==f.tag||null===f.memoizedState||f===e)&&null!==f.child){f.child.return=f,f=f.child;continue}if(f===e)break e;for(;null===f.sibling;){if(null===f.return||f.return===e)break e;d===f&&(d=null),f=f.return}d===f&&(d=null),f.sibling.return=f.return,f=f.sibling}}break;case 19:bl(t,e),xl(e),4&o&&vl(e);case 21:}}function xl(e){var t=e.flags;if(2&t){try{e:{for(var r=e.return;null!==r;){if(cl(r)){var o=r;break e}r=r.return}throw Error(n(160))}switch(o.tag){case 5:var i=o.stateNode;32&o.flags&&(pe(i,""),o.flags&=-33),pl(e,dl(e),i);break;case 3:case 4:var a=o.stateNode.containerInfo;fl(e,dl(e),a);break;default:throw Error(n(161))}}catch(s){Nu(e,e.return,s)}e.flags&=-3}4096&t&&(e.flags&=-4097)}function wl(e,t,n){nl=e,Sl(e)}function Sl(e,t,n){for(var r=!!(1&e.mode);null!==nl;){var o=nl,i=o.child;if(22===o.tag&&r){var a=null!==o.memoizedState||Zs;if(!a){var s=o.alternate,l=null!==s&&null!==s.memoizedState||el;s=Zs;var u=el;if(Zs=a,(el=l)&&!u)for(nl=o;null!==nl;)l=(a=nl).child,22===a.tag&&null!==a.memoizedState?Tl(o):null!==l?(l.return=a,nl=l):Tl(o);for(;null!==i;)nl=i,Sl(i),i=i.sibling;nl=o,Zs=s,el=u}El(e)}else 8772&o.subtreeFlags&&null!==i?(i.return=o,nl=i):El(e)}}function El(e){for(;null!==nl;){var t=nl;if(8772&t.flags){var r=t.alternate;try{if(8772&t.flags)switch(t.tag){case 0:case 11:case 15:el||sl(5,t);break;case 1:var o=t.stateNode;if(4&t.flags&&!el)if(null===r)o.componentDidMount();else{var i=t.elementType===t.type?r.memoizedProps:ss(t.type,r.memoizedProps);o.componentDidUpdate(i,r.memoizedState,o.__reactInternalSnapshotBeforeUpdate)}var a=t.updateQueue;null!==a&&Ji(t,a,o);break;case 3:var s=t.updateQueue;if(null!==s){if(r=null,null!==t.child)switch(t.child.tag){case 5:case 1:r=t.child.stateNode}Ji(t,s,r)}break;case 5:var l=t.stateNode;if(null===r&&4&t.flags){r=l;var u=t.memoizedProps;switch(t.type){case"button":case"input":case"select":case"textarea":u.autoFocus&&r.focus();break;case"img":u.src&&(r.src=u.src)}}break;case 6:case 4:case 12:case 19:case 17:case 21:case 22:case 23:case 25:break;case 13:if(null===t.memoizedState){var c=t.alternate;if(null!==c){var d=c.memoizedState;if(null!==d){var f=d.dehydrated;null!==f&&Kt(f)}}}break;default:throw Error(n(163))}el||512&t.flags&&ll(t)}catch(je){Nu(t,t.return,je)}}if(t===e){nl=null;break}if(null!==(r=t.sibling)){r.return=t.return,nl=r;break}nl=t.return}}function Cl(e){for(;null!==nl;){var t=nl;if(t===e){nl=null;break}var n=t.sibling;if(null!==n){n.return=t.return,nl=n;break}nl=t.return}}function Tl(e){for(;null!==nl;){var t=nl;try{switch(t.tag){case 0:case 11:case 15:var n=t.return;try{sl(4,t)}catch(l){Nu(t,n,l)}break;case 1:var r=t.stateNode;if("function"==typeof r.componentDidMount){var o=t.return;try{r.componentDidMount()}catch(l){Nu(t,o,l)}}var i=t.return;try{ll(t)}catch(l){Nu(t,i,l)}break;case 5:var a=t.return;try{ll(t)}catch(l){Nu(t,a,l)}}}catch(l){Nu(t,t.return,l)}if(t===e){nl=null;break}var s=t.sibling;if(null!==s){s.return=t.return,nl=s;break}nl=t.return}}var Ol,Nl=Math.ceil,Pl=x.ReactCurrentDispatcher,Ll=x.ReactCurrentOwner,Rl=x.ReactCurrentBatchConfig,_l=0,Il=null,Al=null,Dl=0,zl=0,jl=Lo(0),Fl=0,Ml=null,Ul=0,Bl=0,$l=0,Vl=null,Hl=null,ql=0,Wl=1/0,Kl=null,Ql=!1,Jl=null,Yl=null,Gl=!1,Xl=null,Zl=0,eu=0,tu=null,nu=-1,ru=0;function ou(){return 6&_l?nt():-1!==nu?nu:nu=nt()}function iu(e){return 1&e.mode?2&_l&&0!==Dl?Dl&-Dl:null!==xi.transition?(0===ru&&(ru=kt()),ru):0!==(e=Et)?e:e=void 0===(e=window.event)?16:tn(e.type):1}function au(e,t,r,o){if(50<eu)throw eu=0,tu=null,Error(n(185));wt(e,r,o),2&_l&&e===Il||(e===Il&&(!(2&_l)&&(Bl|=r),4===Fl&&du(e,Dl)),su(e,o),1===r&&0===_l&&!(1&t.mode)&&(Wl=nt()+500,qo&&Qo()))}function su(e,t){var n=e.callbackNode;!function(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,o=e.expirationTimes,i=e.pendingLanes;0<i;){var a=31-dt(i),s=1<<a,l=o[a];-1===l?0!==(s&n)&&0===(s&r)||(o[a]=vt(s,t)):l<=t&&(e.expiredLanes|=s),i&=~s}}(e,t);var r=yt(e,e===Il?Dl:0);if(0===r)null!==n&&Ze(n),e.callbackNode=null,e.callbackPriority=0;else if(t=r&-r,e.callbackPriority!==t){if(null!=n&&Ze(n),1===t)0===e.tag?function(e){qo=!0,Ko(e)}(fu.bind(null,e)):Ko(fu.bind(null,e)),fo(function(){!(6&_l)&&Qo()}),n=null;else{switch(Ct(r)){case 1:n=ot;break;case 4:n=it;break;case 16:default:n=at;break;case 536870912:n=lt}n=Iu(n,lu.bind(null,e))}e.callbackPriority=t,e.callbackNode=n}}function lu(e,t){if(nu=-1,ru=0,6&_l)throw Error(n(327));var r=e.callbackNode;if(Tu()&&e.callbackNode!==r)return null;var o=yt(e,e===Il?Dl:0);if(0===o)return null;if(30&o||0!==(o&e.expiredLanes)||t)t=ku(e,o);else{t=o;var i=_l;_l|=2;var a=vu();for(Il===e&&Dl===t||(Kl=null,Wl=nt()+500,mu(e,t));;)try{wu();break}catch(l){yu(e,l)}_i(),Pl.current=a,_l=i,null!==Al?t=0:(Il=null,Dl=0,t=Fl)}if(0!==t){if(2===t&&(0!==(i=bt(e))&&(o=i,t=uu(e,i))),1===t)throw r=Ml,mu(e,0),du(e,o),su(e,nt()),r;if(6===t)du(e,o);else{if(i=e.current.alternate,!(30&o||function(e){for(var t=e;;){if(16384&t.flags){var n=t.updateQueue;if(null!==n&&null!==(n=n.stores))for(var r=0;r<n.length;r++){var o=n[r],i=o.getSnapshot;o=o.value;try{if(!fr(i(),o))return!1}catch(s){return!1}}}if(n=t.child,16384&t.subtreeFlags&&null!==n)n.return=t,t=n;else{if(t===e)break;for(;null===t.sibling;){if(null===t.return||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}(i)||(t=ku(e,o),2===t&&(a=bt(e),0!==a&&(o=a,t=uu(e,a))),1!==t)))throw r=Ml,mu(e,0),du(e,o),su(e,nt()),r;switch(e.finishedWork=i,e.finishedLanes=o,t){case 0:case 1:throw Error(n(345));case 2:case 5:Cu(e,Hl,Kl);break;case 3:if(du(e,o),(130023424&o)===o&&10<(t=ql+500-nt())){if(0!==yt(e,0))break;if(((i=e.suspendedLanes)&o)!==o){ou(),e.pingedLanes|=e.suspendedLanes&i;break}e.timeoutHandle=lo(Cu.bind(null,e,Hl,Kl),t);break}Cu(e,Hl,Kl);break;case 4:if(du(e,o),(4194240&o)===o)break;for(t=e.eventTimes,i=-1;0<o;){var s=31-dt(o);a=1<<s,(s=t[s])>i&&(i=s),o&=~a}if(o=i,10<(o=(120>(o=nt()-o)?120:480>o?480:1080>o?1080:1920>o?1920:3e3>o?3e3:4320>o?4320:1960*Nl(o/1960))-o)){e.timeoutHandle=lo(Cu.bind(null,e,Hl,Kl),o);break}Cu(e,Hl,Kl);break;default:throw Error(n(329))}}}return su(e,nt()),e.callbackNode===r?lu.bind(null,e):null}function uu(e,t){var n=Vl;return e.current.memoizedState.isDehydrated&&(mu(e,t).flags|=256),2!==(e=ku(e,t))&&(t=Hl,Hl=n,null!==t&&cu(t)),e}function cu(e){null===Hl?Hl=e:Hl.push.apply(Hl,e)}function du(e,t){for(t&=~$l,t&=~Bl,e.suspendedLanes|=t,e.pingedLanes&=~t,e=e.expirationTimes;0<t;){var n=31-dt(t),r=1<<n;e[n]=-1,t&=~r}}function fu(e){if(6&_l)throw Error(n(327));Tu();var t=yt(e,0);if(!(1&t))return su(e,nt()),null;var r=ku(e,t);if(0!==e.tag&&2===r){var o=bt(e);0!==o&&(t=o,r=uu(e,o))}if(1===r)throw r=Ml,mu(e,0),du(e,t),su(e,nt()),r;if(6===r)throw Error(n(345));return e.finishedWork=e.current.alternate,e.finishedLanes=t,Cu(e,Hl,Kl),su(e,nt()),null}function pu(e,t){var n=_l;_l|=1;try{return e(t)}finally{0===(_l=n)&&(Wl=nt()+500,qo&&Qo())}}function hu(e){null!==Xl&&0===Xl.tag&&!(6&_l)&&Tu();var t=_l;_l|=1;var n=Rl.transition,r=Et;try{if(Rl.transition=null,Et=1,e)return e()}finally{Et=r,Rl.transition=n,!(6&(_l=t))&&Qo()}}function gu(){zl=jl.current,Ro(jl)}function mu(e,t){e.finishedWork=null,e.finishedLanes=0;var n=e.timeoutHandle;if(-1!==n&&(e.timeoutHandle=-1,uo(n)),null!==Al)for(n=Al.return;null!==n;){var r=n;switch(si(r),r.tag){case 1:null!=(r=r.type.childContextTypes)&&Mo();break;case 3:na(),Ro(Do),Ro(Ao),la();break;case 5:oa(r);break;case 4:na();break;case 13:case 19:Ro(ia);break;case 10:Ii(r.type._context);break;case 22:case 23:gu()}n=n.return}if(Il=e,Al=e=ju(e.current,null),Dl=zl=t,Fl=0,Ml=null,$l=Bl=Ul=0,Hl=Vl=null,null!==ji){for(t=0;t<ji.length;t++)if(null!==(r=(n=ji[t]).interleaved)){n.interleaved=null;var o=r.next,i=n.pending;if(null!==i){var a=i.next;i.next=o,r.next=a}n.pending=r}ji=null}return e}function yu(e,t){for(;;){var r=Al;try{if(_i(),ua.current=rs,ga){for(var o=fa.memoizedState;null!==o;){var i=o.queue;null!==i&&(i.pending=null),o=o.next}ga=!1}if(da=0,ha=pa=fa=null,ma=!1,ya=0,Ll.current=null,null===r||null===r.return){Fl=1,Ml=t,Al=null;break}e:{var a=e,s=r.return,l=r,u=t;if(t=Dl,l.flags|=32768,null!==u&&"object"==typeof u&&"function"==typeof u.then){var c=u,d=l,f=d.tag;if(!(1&d.mode||0!==f&&11!==f&&15!==f)){var p=d.alternate;p?(d.updateQueue=p.updateQueue,d.memoizedState=p.memoizedState,d.lanes=p.lanes):(d.updateQueue=null,d.memoizedState=null)}var h=ks(s);if(null!==h){h.flags&=-257,xs(h,s,l,0,t),1&h.mode&&bs(a,c,t),u=c;var g=(t=h).updateQueue;if(null===g){var m=new Set;m.add(u),t.updateQueue=m}else g.add(u);break e}if(!(1&t)){bs(a,c,t),bu();break e}u=Error(n(426))}else if(ci&&1&l.mode){var y=ks(s);if(null!==y){!(65536&y.flags)&&(y.flags|=256),xs(y,s,l,0,t),ki(hs(u,l));break e}}a=u=hs(u,l),4!==Fl&&(Fl=2),null===Vl?Vl=[a]:Vl.push(a),a=s;do{switch(a.tag){case 3:a.flags|=65536,t&=-t,a.lanes|=t,Ki(a,ys(0,u,t));break e;case 1:l=u;var v=a.type,b=a.stateNode;if(!(128&a.flags||"function"!=typeof v.getDerivedStateFromError&&(null===b||"function"!=typeof b.componentDidCatch||null!==Yl&&Yl.has(b)))){a.flags|=65536,t&=-t,a.lanes|=t,Ki(a,vs(a,l,t));break e}}a=a.return}while(null!==a)}Eu(r)}catch(k){t=k,Al===r&&null!==r&&(Al=r=r.return);continue}break}}function vu(){var e=Pl.current;return Pl.current=rs,null===e?rs:e}function bu(){0!==Fl&&3!==Fl&&2!==Fl||(Fl=4),null===Il||!(268435455&Ul)&&!(268435455&Bl)||du(Il,Dl)}function ku(e,t){var r=_l;_l|=2;var o=vu();for(Il===e&&Dl===t||(Kl=null,mu(e,t));;)try{xu();break}catch(De){yu(e,De)}if(_i(),_l=r,Pl.current=o,null!==Al)throw Error(n(261));return Il=null,Dl=0,Fl}function xu(){for(;null!==Al;)Su(Al)}function wu(){for(;null!==Al&&!et();)Su(Al)}function Su(e){var t=Ol(e.alternate,e,zl);e.memoizedProps=e.pendingProps,null===t?Eu(e):Al=t,Ll.current=null}function Eu(e){var t=e;do{var n=t.alternate;if(e=t.return,32768&t.flags){if(null!==(n=Xs(n,t)))return n.flags&=32767,void(Al=n);if(null===e)return Fl=6,void(Al=null);e.flags|=32768,e.subtreeFlags=0,e.deletions=null}else if(null!==(n=Gs(n,t,zl)))return void(Al=n);if(null!==(t=t.sibling))return void(Al=t);Al=t=e}while(null!==t);0===Fl&&(Fl=5)}function Cu(e,t,r){var o=Et,i=Rl.transition;try{Rl.transition=null,Et=1,function(e,t,r,o){do{Tu()}while(null!==Xl);if(6&_l)throw Error(n(327));r=e.finishedWork;var i=e.finishedLanes;if(null===r)return null;if(e.finishedWork=null,e.finishedLanes=0,r===e.current)throw Error(n(177));e.callbackNode=null,e.callbackPriority=0;var a=r.lanes|r.childLanes;if(function(e,t){var n=e.pendingLanes&~t;e.pendingLanes=t,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=t,e.mutableReadLanes&=t,e.entangledLanes&=t,t=e.entanglements;var r=e.eventTimes;for(e=e.expirationTimes;0<n;){var o=31-dt(n),i=1<<o;t[o]=0,r[o]=-1,e[o]=-1,n&=~i}}(e,a),e===Il&&(Al=Il=null,Dl=0),!(2064&r.subtreeFlags)&&!(2064&r.flags)||Gl||(Gl=!0,Iu(at,function(){return Tu(),null})),a=!!(15990&r.flags),!!(15990&r.subtreeFlags)||a){a=Rl.transition,Rl.transition=null;var s=Et;Et=1;var l=_l;_l|=4,Ll.current=null,function(e,t){if(io=Jt,vr(e=yr())){if("selectionStart"in e)var r={start:e.selectionStart,end:e.selectionEnd};else e:{var o=(r=(r=e.ownerDocument)&&r.defaultView||window).getSelection&&r.getSelection();if(o&&0!==o.rangeCount){r=o.anchorNode;var i=o.anchorOffset,a=o.focusNode;o=o.focusOffset;try{r.nodeType,a.nodeType}catch(x){r=null;break e}var s=0,l=-1,u=-1,c=0,d=0,f=e,p=null;t:for(;;){for(var h;f!==r||0!==i&&3!==f.nodeType||(l=s+i),f!==a||0!==o&&3!==f.nodeType||(u=s+o),3===f.nodeType&&(s+=f.nodeValue.length),null!==(h=f.firstChild);)p=f,f=h;for(;;){if(f===e)break t;if(p===r&&++c===i&&(l=s),p===a&&++d===o&&(u=s),null!==(h=f.nextSibling))break;p=(f=p).parentNode}f=h}r=-1===l||-1===u?null:{start:l,end:u}}else r=null}r=r||{start:0,end:0}}else r=null;for(ao={focusedElem:e,selectionRange:r},Jt=!1,nl=t;null!==nl;)if(e=(t=nl).child,1028&t.subtreeFlags&&null!==e)e.return=t,nl=e;else for(;null!==nl;){t=nl;try{var g=t.alternate;if(1024&t.flags)switch(t.tag){case 0:case 11:case 15:case 5:case 6:case 4:case 17:break;case 1:if(null!==g){var m=g.memoizedProps,y=g.memoizedState,v=t.stateNode,b=v.getSnapshotBeforeUpdate(t.elementType===t.type?m:ss(t.type,m),y);v.__reactInternalSnapshotBeforeUpdate=b}break;case 3:var k=t.stateNode.containerInfo;1===k.nodeType?k.textContent="":9===k.nodeType&&k.documentElement&&k.removeChild(k.documentElement);break;default:throw Error(n(163))}}catch(x){Nu(t,t.return,x)}if(null!==(e=t.sibling)){e.return=t.return,nl=e;break}nl=t.return}g=il,il=!1}(e,r),kl(r,e),br(ao),Jt=!!io,ao=io=null,e.current=r,wl(r),tt(),_l=l,Et=s,Rl.transition=a}else e.current=r;if(Gl&&(Gl=!1,Xl=e,Zl=i),a=e.pendingLanes,0===a&&(Yl=null),function(e){if(ct&&"function"==typeof ct.onCommitFiberRoot)try{ct.onCommitFiberRoot(ut,e,void 0,!(128&~e.current.flags))}catch(t){}}(r.stateNode),su(e,nt()),null!==t)for(o=e.onRecoverableError,r=0;r<t.length;r++)i=t[r],o(i.value,{componentStack:i.stack,digest:i.digest});if(Ql)throw Ql=!1,e=Jl,Jl=null,e;!!(1&Zl)&&0!==e.tag&&Tu(),a=e.pendingLanes,1&a?e===tu?eu++:(eu=0,tu=e):eu=0,Qo()}(e,t,r,o)}finally{Rl.transition=i,Et=o}return null}function Tu(){if(null!==Xl){var e=Ct(Zl),t=Rl.transition,r=Et;try{if(Rl.transition=null,Et=16>e?16:e,null===Xl)var o=!1;else{if(e=Xl,Xl=null,Zl=0,6&_l)throw Error(n(331));var i=_l;for(_l|=4,nl=e.current;null!==nl;){var a=nl,s=a.child;if(16&nl.flags){var l=a.deletions;if(null!==l){for(var u=0;u<l.length;u++){var c=l[u];for(nl=c;null!==nl;){var d=nl;switch(d.tag){case 0:case 11:case 15:al(8,d,a)}var f=d.child;if(null!==f)f.return=d,nl=f;else for(;null!==nl;){var p=(d=nl).sibling,h=d.return;if(ul(d),d===c){nl=null;break}if(null!==p){p.return=h,nl=p;break}nl=h}}}var g=a.alternate;if(null!==g){var m=g.child;if(null!==m){g.child=null;do{var y=m.sibling;m.sibling=null,m=y}while(null!==m)}}nl=a}}if(2064&a.subtreeFlags&&null!==s)s.return=a,nl=s;else e:for(;null!==nl;){if(2048&(a=nl).flags)switch(a.tag){case 0:case 11:case 15:al(9,a,a.return)}var v=a.sibling;if(null!==v){v.return=a.return,nl=v;break e}nl=a.return}}var b=e.current;for(nl=b;null!==nl;){var k=(s=nl).child;if(2064&s.subtreeFlags&&null!==k)k.return=s,nl=k;else e:for(s=b;null!==nl;){if(2048&(l=nl).flags)try{switch(l.tag){case 0:case 11:case 15:sl(9,l)}}catch(w){Nu(l,l.return,w)}if(l===s){nl=null;break e}var x=l.sibling;if(null!==x){x.return=l.return,nl=x;break e}nl=l.return}}if(_l=i,Qo(),ct&&"function"==typeof ct.onPostCommitFiberRoot)try{ct.onPostCommitFiberRoot(ut,e)}catch(w){}o=!0}return o}finally{Et=r,Rl.transition=t}}return!1}function Ou(e,t,n){e=qi(e,t=ys(0,t=hs(n,t),1),1),t=ou(),null!==e&&(wt(e,1,t),su(e,t))}function Nu(e,t,n){if(3===e.tag)Ou(e,e,n);else for(;null!==t;){if(3===t.tag){Ou(t,e,n);break}if(1===t.tag){var r=t.stateNode;if("function"==typeof t.type.getDerivedStateFromError||"function"==typeof r.componentDidCatch&&(null===Yl||!Yl.has(r))){t=qi(t,e=vs(t,e=hs(n,e),1),1),e=ou(),null!==t&&(wt(t,1,e),su(t,e));break}}t=t.return}}function Pu(e,t,n){var r=e.pingCache;null!==r&&r.delete(t),t=ou(),e.pingedLanes|=e.suspendedLanes&n,Il===e&&(Dl&n)===n&&(4===Fl||3===Fl&&(130023424&Dl)===Dl&&500>nt()-ql?mu(e,0):$l|=n),su(e,t)}function Lu(e,t){0===t&&(1&e.mode?(t=gt,!(130023424&(gt<<=1))&&(gt=4194304)):t=1);var n=ou();null!==(e=Ui(e,t))&&(wt(e,t,n),su(e,n))}function Ru(e){var t=e.memoizedState,n=0;null!==t&&(n=t.retryLane),Lu(e,n)}function _u(e,t){var r=0;switch(e.tag){case 13:var o=e.stateNode,i=e.memoizedState;null!==i&&(r=i.retryLane);break;case 19:o=e.stateNode;break;default:throw Error(n(314))}null!==o&&o.delete(t),Lu(e,r)}function Iu(e,t){return Xe(e,t)}function Au(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Du(e,t,n,r){return new Au(e,t,n,r)}function zu(e){return!(!(e=e.prototype)||!e.isReactComponent)}function ju(e,t){var n=e.alternate;return null===n?((n=Du(e.tag,t,e.key,e.mode)).elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=14680064&e.flags,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=null===t?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n}function Fu(e,t,r,o,i,a){var s=2;if(o=e,"function"==typeof e)zu(e)&&(s=1);else if("string"==typeof e)s=5;else e:switch(e){case E:return Mu(r.children,i,a,t);case C:s=8,i|=8;break;case T:return(e=Du(12,r,t,2|i)).elementType=T,e.lanes=a,e;case L:return(e=Du(13,r,t,i)).elementType=L,e.lanes=a,e;case R:return(e=Du(19,r,t,i)).elementType=R,e.lanes=a,e;case A:return Uu(r,i,a,t);default:if("object"==typeof e&&null!==e)switch(e.$$typeof){case O:s=10;break e;case N:s=9;break e;case P:s=11;break e;case _:s=14;break e;case I:s=16,o=null;break e}throw Error(n(130,null==e?e:typeof e,""))}return(t=Du(s,r,t,i)).elementType=e,t.type=o,t.lanes=a,t}function Mu(e,t,n,r){return(e=Du(7,e,r,t)).lanes=n,e}function Uu(e,t,n,r){return(e=Du(22,e,r,t)).elementType=A,e.lanes=n,e.stateNode={isHidden:!1},e}function Bu(e,t,n){return(e=Du(6,e,null,t)).lanes=n,e}function $u(e,t,n){return(t=Du(4,null!==e.children?e.children:[],e.key,t)).lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function Vu(e,t,n,r,o){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=xt(0),this.expirationTimes=xt(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=xt(0),this.identifierPrefix=r,this.onRecoverableError=o,this.mutableSourceEagerHydrationData=null}function Hu(e,t,n,r,o,i,a,s,l){return e=new Vu(e,t,n,s,l),1===t?(t=1,!0===i&&(t|=8)):t=0,i=Du(3,null,null,t),e.current=i,i.stateNode=e,i.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},$i(i),e}function qu(e){if(!e)return Io;e:{if(Ke(e=e._reactInternals)!==e||1!==e.tag)throw Error(n(170));var t=e;do{switch(t.tag){case 3:t=t.stateNode.context;break e;case 1:if(Fo(t.type)){t=t.stateNode.__reactInternalMemoizedMergedChildContext;break e}}t=t.return}while(null!==t);throw Error(n(171))}if(1===e.tag){var r=e.type;if(Fo(r))return Bo(e,r,t)}return t}function Wu(e,t,n,r,o,i,a,s,l){return(e=Hu(n,r,!0,e,0,i,0,s,l)).context=qu(null),n=e.current,(i=Hi(r=ou(),o=iu(n))).callback=null!=t?t:null,qi(n,i,o),e.current.lanes=o,wt(e,o,r),su(e,r),e}function Ku(e,t,n,r){var o=t.current,i=ou(),a=iu(o);return n=qu(n),null===t.context?t.context=n:t.pendingContext=n,(t=Hi(i,a)).payload={element:e},null!==(r=void 0===r?null:r)&&(t.callback=r),null!==(e=qi(o,t,a))&&(au(e,o,a,i),Wi(e,o,a)),a}function Qu(e){return(e=e.current).child?(e.child.tag,e.child.stateNode):null}function Ju(e,t){if(null!==(e=e.memoizedState)&&null!==e.dehydrated){var n=e.retryLane;e.retryLane=0!==n&&n<t?n:t}}function Yu(e,t){Ju(e,t),(e=e.alternate)&&Ju(e,t)}Ol=function(e,t,r){if(null!==e)if(e.memoizedProps!==t.pendingProps||Do.current)Ss=!0;else{if(0===(e.lanes&r)&&!(128&t.flags))return Ss=!1,function(e,t,n){switch(t.tag){case 3:Is(t),bi();break;case 5:ra(t);break;case 1:Fo(t.type)&&$o(t);break;case 4:ta(t,t.stateNode.containerInfo);break;case 10:var r=t.type._context,o=t.memoizedProps.value;_o(Ni,r._currentValue),r._currentValue=o;break;case 13:if(null!==(r=t.memoizedState))return null!==r.dehydrated?(_o(ia,1&ia.current),t.flags|=128,null):0!==(n&t.child.childLanes)?Bs(e,t,n):(_o(ia,1&ia.current),null!==(e=Qs(e,t,n))?e.sibling:null);_o(ia,1&ia.current);break;case 19:if(r=0!==(n&t.childLanes),128&e.flags){if(r)return Ws(e,t,n);t.flags|=128}if(null!==(o=t.memoizedState)&&(o.rendering=null,o.tail=null,o.lastEffect=null),_o(ia,ia.current),r)break;return null;case 22:case 23:return t.lanes=0,Ns(e,t,n)}return Qs(e,t,n)}(e,t,r);Ss=!!(131072&e.flags)}else Ss=!1,ci&&1048576&t.flags&&ii(t,Xo,t.index);switch(t.lanes=0,t.tag){case 2:var o=t.type;Ks(e,t),e=t.pendingProps;var i=jo(t,Ao.current);Di(t,r),i=xa(null,t,o,e,i,r);var a=wa();return t.flags|=1,"object"==typeof i&&null!==i&&"function"==typeof i.render&&void 0===i.$$typeof?(t.tag=1,t.memoizedState=null,t.updateQueue=null,Fo(o)?(a=!0,$o(t)):a=!1,t.memoizedState=null!==i.state&&void 0!==i.state?i.state:null,$i(t),i.updater=us,t.stateNode=i,i._reactInternals=t,ps(t,o,e,r),t=_s(null,t,o,!0,a,r)):(t.tag=0,ci&&a&&ai(t),Es(null,t,i,r),t=t.child),t;case 16:o=t.elementType;e:{switch(Ks(e,t),e=t.pendingProps,o=(i=o._init)(o._payload),t.type=o,i=t.tag=function(e){if("function"==typeof e)return zu(e)?1:0;if(null!=e){if((e=e.$$typeof)===P)return 11;if(e===_)return 14}return 2}(o),e=ss(o,e),i){case 0:t=Ls(null,t,o,e,r);break e;case 1:t=Rs(null,t,o,e,r);break e;case 11:t=Cs(null,t,o,e,r);break e;case 14:t=Ts(null,t,o,ss(o.type,e),r);break e}throw Error(n(306,o,""))}return t;case 0:return o=t.type,i=t.pendingProps,Ls(e,t,o,i=t.elementType===o?i:ss(o,i),r);case 1:return o=t.type,i=t.pendingProps,Rs(e,t,o,i=t.elementType===o?i:ss(o,i),r);case 3:e:{if(Is(t),null===e)throw Error(n(387));o=t.pendingProps,i=(a=t.memoizedState).element,Vi(e,t),Qi(t,o,null,r);var s=t.memoizedState;if(o=s.element,a.isDehydrated){if(a={element:o,isDehydrated:!1,cache:s.cache,pendingSuspenseBoundaries:s.pendingSuspenseBoundaries,transitions:s.transitions},t.updateQueue.baseState=a,t.memoizedState=a,256&t.flags){t=As(e,t,o,r,i=hs(Error(n(423)),t));break e}if(o!==i){t=As(e,t,o,r,i=hs(Error(n(424)),t));break e}for(ui=go(t.stateNode.containerInfo.firstChild),li=t,ci=!0,di=null,r=Oi(t,null,o,r),t.child=r;r;)r.flags=-3&r.flags|4096,r=r.sibling}else{if(bi(),o===i){t=Qs(e,t,r);break e}Es(e,t,o,r)}t=t.child}return t;case 5:return ra(t),null===e&&gi(t),o=t.type,i=t.pendingProps,a=null!==e?e.memoizedProps:null,s=i.children,so(o,i)?s=null:null!==a&&so(o,a)&&(t.flags|=32),Ps(e,t),Es(e,t,s,r),t.child;case 6:return null===e&&gi(t),null;case 13:return Bs(e,t,r);case 4:return ta(t,t.stateNode.containerInfo),o=t.pendingProps,null===e?t.child=Ti(t,null,o,r):Es(e,t,o,r),t.child;case 11:return o=t.type,i=t.pendingProps,Cs(e,t,o,i=t.elementType===o?i:ss(o,i),r);case 7:return Es(e,t,t.pendingProps,r),t.child;case 8:case 12:return Es(e,t,t.pendingProps.children,r),t.child;case 10:e:{if(o=t.type._context,i=t.pendingProps,a=t.memoizedProps,s=i.value,_o(Ni,o._currentValue),o._currentValue=s,null!==a)if(fr(a.value,s)){if(a.children===i.children&&!Do.current){t=Qs(e,t,r);break e}}else for(null!==(a=t.child)&&(a.return=t);null!==a;){var l=a.dependencies;if(null!==l){s=a.child;for(var u=l.firstContext;null!==u;){if(u.context===o){if(1===a.tag){(u=Hi(-1,r&-r)).tag=2;var c=a.updateQueue;if(null!==c){var d=(c=c.shared).pending;null===d?u.next=u:(u.next=d.next,d.next=u),c.pending=u}}a.lanes|=r,null!==(u=a.alternate)&&(u.lanes|=r),Ai(a.return,r,t),l.lanes|=r;break}u=u.next}}else if(10===a.tag)s=a.type===t.type?null:a.child;else if(18===a.tag){if(null===(s=a.return))throw Error(n(341));s.lanes|=r,null!==(l=s.alternate)&&(l.lanes|=r),Ai(s,r,t),s=a.sibling}else s=a.child;if(null!==s)s.return=a;else for(s=a;null!==s;){if(s===t){s=null;break}if(null!==(a=s.sibling)){a.return=s.return,s=a;break}s=s.return}a=s}Es(e,t,i.children,r),t=t.child}return t;case 9:return i=t.type,o=t.pendingProps.children,Di(t,r),o=o(i=zi(i)),t.flags|=1,Es(e,t,o,r),t.child;case 14:return i=ss(o=t.type,t.pendingProps),Ts(e,t,o,i=ss(o.type,i),r);case 15:return Os(e,t,t.type,t.pendingProps,r);case 17:return o=t.type,i=t.pendingProps,i=t.elementType===o?i:ss(o,i),Ks(e,t),t.tag=1,Fo(o)?(e=!0,$o(t)):e=!1,Di(t,r),ds(t,o,i),ps(t,o,i,r),_s(null,t,o,!0,e,r);case 19:return Ws(e,t,r);case 22:return Ns(e,t,r)}throw Error(n(156,t.tag))};var Gu="function"==typeof reportError?reportError:function(e){};function Xu(e){this._internalRoot=e}function Zu(e){this._internalRoot=e}function ec(e){return!(!e||1!==e.nodeType&&9!==e.nodeType&&11!==e.nodeType)}function tc(e){return!(!e||1!==e.nodeType&&9!==e.nodeType&&11!==e.nodeType&&(8!==e.nodeType||" react-mount-point-unstable "!==e.nodeValue))}function nc(){}function rc(e,t,n,r,o){var i=n._reactRootContainer;if(i){var a=i;if("function"==typeof o){var s=o;o=function(){var e=Qu(a);s.call(e)}}Ku(t,a,e,o)}else a=function(e,t,n,r,o){if(o){if("function"==typeof r){var i=r;r=function(){var e=Qu(a);i.call(e)}}var a=Wu(t,r,e,0,null,!1,0,"",nc);return e._reactRootContainer=a,e[ko]=a.current,Kr(8===e.nodeType?e.parentNode:e),hu(),a}for(;o=e.lastChild;)e.removeChild(o);if("function"==typeof r){var s=r;r=function(){var e=Qu(l);s.call(e)}}var l=Hu(e,0,!1,null,0,!1,0,"",nc);return e._reactRootContainer=l,e[ko]=l.current,Kr(8===e.nodeType?e.parentNode:e),hu(function(){Ku(t,l,n,r)}),l}(n,t,e,o,r);return Qu(a)}Zu.prototype.render=Xu.prototype.render=function(e){var t=this._internalRoot;if(null===t)throw Error(n(409));Ku(e,t,null,null)},Zu.prototype.unmount=Xu.prototype.unmount=function(){var e=this._internalRoot;if(null!==e){this._internalRoot=null;var t=e.containerInfo;hu(function(){Ku(null,e,null,null)}),t[ko]=null}},Zu.prototype.unstable_scheduleHydration=function(e){if(e){var t=Pt();e={blockedOn:null,target:e,priority:t};for(var n=0;n<Ft.length&&0!==t&&t<Ft[n].priority;n++);Ft.splice(n,0,e),0===n&&$t(e)}},Tt=function(e){switch(e.tag){case 3:var t=e.stateNode;if(t.current.memoizedState.isDehydrated){var n=mt(t.pendingLanes);0!==n&&(St(t,1|n),su(t,nt()),!(6&_l)&&(Wl=nt()+500,Qo()))}break;case 13:hu(function(){var t=Ui(e,1);if(null!==t){var n=ou();au(t,e,1,n)}}),Yu(e,1)}},Ot=function(e){if(13===e.tag){var t=Ui(e,134217728);if(null!==t)au(t,e,134217728,ou());Yu(e,134217728)}},Nt=function(e){if(13===e.tag){var t=iu(e),n=Ui(e,t);if(null!==n)au(n,e,t,ou());Yu(e,t)}},Pt=function(){return Et},Lt=function(e,t){var n=Et;try{return Et=e,t()}finally{Et=n}},Se=function(e,t,r){switch(t){case"input":if(Z(e,r),t=r.name,"radio"===r.type&&null!=t){for(r=e;r.parentNode;)r=r.parentNode;for(r=r.querySelectorAll("input[name="+JSON.stringify(""+t)+'][type="radio"]'),t=0;t<r.length;t++){var o=r[t];if(o!==e&&o.form===e.form){var i=Oo(o);if(!i)throw Error(n(90));Q(o),Z(o,i)}}}break;case"textarea":ae(e,r);break;case"select":null!=(t=r.value)&&re(e,!!r.multiple,t,!1)}},Pe=pu,Le=hu;var oc={usingClientEntryPoint:!1,Events:[Co,To,Oo,Oe,Ne,pu]},ic={findFiberByHostInstance:Eo,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},ac={bundleType:ic.bundleType,version:ic.version,rendererPackageName:ic.rendererPackageName,rendererConfig:ic.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:x.ReactCurrentDispatcher,findHostInstanceByFiber:function(e){return null===(e=Ye(e))?null:e.stateNode},findFiberByHostInstance:ic.findFiberByHostInstance||function(){return null},findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.3.1-next-f1338f8080-20240426"};if("undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__){var sc=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!sc.isDisabled&&sc.supportsFiber)try{ut=sc.inject(ac),ct=sc}catch(de){}}return y.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=oc,y.createPortal=function(e,t){var r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null;if(!ec(t))throw Error(n(200));return function(e,t,n){var r=3<arguments.length&&void 0!==arguments[3]?arguments[3]:null;return{$$typeof:S,key:null==r?null:""+r,children:e,containerInfo:t,implementation:n}}(e,t,null,r)},y.createRoot=function(e,t){if(!ec(e))throw Error(n(299));var r=!1,o="",i=Gu;return null!=t&&(!0===t.unstable_strictMode&&(r=!0),void 0!==t.identifierPrefix&&(o=t.identifierPrefix),void 0!==t.onRecoverableError&&(i=t.onRecoverableError)),t=Hu(e,1,!1,null,0,r,0,o,i),e[ko]=t.current,Kr(8===e.nodeType?e.parentNode:e),new Xu(t)},y.findDOMNode=function(e){if(null==e)return null;if(1===e.nodeType)return e;var t=e._reactInternals;if(void 0===t){if("function"==typeof e.render)throw Error(n(188));throw e=Object.keys(e).join(","),Error(n(268,e))}return e=null===(e=Ye(t))?null:e.stateNode},y.flushSync=function(e){return hu(e)},y.hydrate=function(e,t,r){if(!tc(t))throw Error(n(200));return rc(null,e,t,!0,r)},y.hydrateRoot=function(e,t,r){if(!ec(e))throw Error(n(405));var o=null!=r&&r.hydratedSources||null,i=!1,a="",s=Gu;if(null!=r&&(!0===r.unstable_strictMode&&(i=!0),void 0!==r.identifierPrefix&&(a=r.identifierPrefix),void 0!==r.onRecoverableError&&(s=r.onRecoverableError)),t=Wu(t,null,e,1,null!=r?r:null,i,0,a,s),e[ko]=t.current,Kr(e),o)for(e=0;e<o.length;e++)i=(i=(r=o[e])._getVersion)(r._source),null==t.mutableSourceEagerHydrationData?t.mutableSourceEagerHydrationData=[r,i]:t.mutableSourceEagerHydrationData.push(r,i);return new Zu(t)},y.render=function(e,t,r){if(!tc(t))throw Error(n(200));return rc(null,e,t,!1,r)},y.unmountComponentAtNode=function(e){if(!tc(e))throw Error(n(40));return!!e._reactRootContainer&&(hu(function(){rc(null,null,e,!1,function(){e._reactRootContainer=null,e[ko]=null})}),!0)},y.unstable_batchedUpdates=pu,y.unstable_renderSubtreeIntoContainer=function(e,t,r,o){if(!tc(r))throw Error(n(200));if(null==e||void 0===e._reactInternals)throw Error(n(38));return rc(e,t,r,!1,o)},y.version="18.3.1-next-f1338f8080-20240426",y}var w,S,E=function(){if(h)return g;h=1;var e=(p||(p=1,function e(){if("undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE)try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(t){}}(),m.exports=x()),m.exports);return g.createRoot=e.createRoot,g.hydrateRoot=e.hydrateRoot,g}(),C={exports:{}},T={};var O=(S||(S=1,C.exports=function(){if(w)return T;w=1;var e=s(),t=Symbol.for("react.element"),n=Symbol.for("react.fragment"),r=Object.prototype.hasOwnProperty,o=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,i={key:!0,ref:!0,__self:!0,__source:!0};function a(e,n,a){var s,l={},u=null,c=null;for(s in void 0!==a&&(u=""+a),void 0!==n.key&&(u=""+n.key),void 0!==n.ref&&(c=n.ref),n)r.call(n,s)&&!i.hasOwnProperty(s)&&(l[s]=n[s]);if(e&&e.defaultProps)for(s in n=e.defaultProps)void 0===l[s]&&(l[s]=n[s]);return{$$typeof:t,type:e,key:u,ref:c,props:l,_owner:o.current}}return T.Fragment=n,T.jsx=a,T.jsxs=a,T}()),C.exports);const N={},P=(e,t,n,r)=>{I(n)&&N[n]||(I(n)&&(N[n]=new Date),((e,t,n,r)=>{const o=[n,{code:t,...r||{}}];if(e?.services?.logger?.forward)return e.services.logger.forward(o,"warn","react-i18next::",!0);I(o[0])&&(o[0]=`react-i18next:: ${o[0]}`),e?.services?.logger?.warn?e.services.logger.warn(...o):console})(e,t,n,r))},L=(e,t)=>()=>{if(e.isInitialized)t();else{const n=()=>{setTimeout(()=>{e.off("initialized",n)},0),t()};e.on("initialized",n)}},R=(e,t,n)=>{e.loadNamespaces(t,L(e,n))},_=(e,t,n,r)=>{if(I(n)&&(n=[n]),e.options.preload&&e.options.preload.indexOf(t)>-1)return R(e,n,r);n.forEach(t=>{e.options.ns.indexOf(t)<0&&e.options.ns.push(t)}),e.loadLanguages(t,L(e,r))},I=e=>"string"==typeof e,A=/&(?:amp|#38|lt|#60|gt|#62|apos|#39|quot|#34|nbsp|#160|copy|#169|reg|#174|hellip|#8230|#x2F|#47);/g,D={"&amp;":"&","&#38;":"&","&lt;":"<","&#60;":"<","&gt;":">","&#62;":">","&apos;":"'","&#39;":"'","&quot;":'"',"&#34;":'"',"&nbsp;":" ","&#160;":" ","&copy;":"©","&#169;":"©","&reg;":"®","&#174;":"®","&hellip;":"…","&#8230;":"…","&#x2F;":"/","&#47;":"/"},z=e=>D[e];let j={bindI18n:"languageChanged",bindI18nStore:"",transEmptyNodeValue:"",transSupportBasicHtmlNodes:!0,transWrapTextNodes:"",transKeepBasicHtmlNodesFor:["br","strong","i","p"],useSuspense:!0,unescape:e=>e.replace(A,z)};let F;const M={type:"3rdParty",init(e){((e={})=>{j={...j,...e}})(e.options.react),(e=>{F=e})(e)}},U=l.createContext();class B{constructor(){this.usedNamespaces={}}addUsedNamespaces(e){e.forEach(e=>{this.usedNamespaces[e]||(this.usedNamespaces[e]=!0)})}getUsedNamespaces(){return Object.keys(this.usedNamespaces)}}const $=(e,t,n,r)=>e.getFixedT(t,n,r),V=(e,t={})=>{const{i18n:n}=t,{i18n:r,defaultNS:o}=l.useContext(U)||{},i=n||r||F;if(i&&!i.reportNamespaces&&(i.reportNamespaces=new B),!i){P(i,"NO_I18NEXT_INSTANCE","useTranslation: You will need to pass in an i18next instance by using initReactI18next");const e=(e,t)=>{return I(t)?t:"object"==typeof(n=t)&&null!==n&&I(t.defaultValue)?t.defaultValue:Array.isArray(e)?e[e.length-1]:e;var n},t=[e,{},!1];return t.t=e,t.i18n={},t.ready=!1,t}i.options.react?.wait&&P(i,"DEPRECATED_OPTION","useTranslation: It seems you are still using the old wait option, you may migrate to the new useSuspense behaviour.");const a={...j,...i.options.react,...t},{useSuspense:s,keyPrefix:u}=a;let c=o||i.options?.defaultNS;c=I(c)?[c]:c||["translation"],i.reportNamespaces.addUsedNamespaces?.(c);const d=(i.isInitialized||i.initializedStoreOnce)&&c.every(e=>((e,t,n={})=>t.languages&&t.languages.length?t.hasLoadedNamespace(e,{lng:n.lng,precheck:(t,r)=>{if(n.bindI18n&&n.bindI18n.indexOf("languageChanging")>-1&&t.services.backendConnector.backend&&t.isLanguageChangingTo&&!r(t.isLanguageChangingTo,e))return!1}}):(P(t,"NO_LANGUAGES","i18n.languages were undefined or empty",{languages:t.languages}),!0))(e,i,a)),f=((e,t,n,r)=>l.useCallback($(e,t,n,r),[e,t,n,r]))(i,t.lng||null,"fallback"===a.nsMode?c:c[0],u),p=()=>f,h=()=>$(i,t.lng||null,"fallback"===a.nsMode?c:c[0],u),[g,m]=l.useState(p);let y=c.join();t.lng&&(y=`${t.lng}${y}`);const v=((e,t)=>{const n=l.useRef();return l.useEffect(()=>{n.current=e},[e,t]),n.current})(y),b=l.useRef(!0);l.useEffect(()=>{const{bindI18n:e,bindI18nStore:n}=a;b.current=!0,d||s||(t.lng?_(i,t.lng,c,()=>{b.current&&m(h)}):R(i,c,()=>{b.current&&m(h)})),d&&v&&v!==y&&b.current&&m(h);const r=()=>{b.current&&m(h)};return e&&i?.on(e,r),n&&i?.store.on(n,r),()=>{b.current=!1,i&&e&&e?.split(" ").forEach(e=>i.off(e,r)),n&&i&&n.split(" ").forEach(e=>i.store.off(e,r))}},[i,y]),l.useEffect(()=>{b.current&&d&&m(p)},[i,u,d]);const k=[g,i,d];if(k.t=g,k.i18n=i,k.ready=d,d)return k;if(!d&&!s)return k;throw new Promise(e=>{t.lng?_(i,t.lng,c,()=>e()):R(i,c,()=>e())})};function H({i18n:e,defaultNS:t,children:n}){const r=l.useMemo(()=>({i18n:e,defaultNS:t}),[e,t]);return l.createElement(U.Provider,{value:r},n)}
11
11
  /**
12
12
  * @license lucide-react v0.525.0 - ISC
13
13
  *
@@ -26,13 +26,13 @@ var Q={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24"
26
26
  *
27
27
  * This source code is licensed under the ISC license.
28
28
  * See the LICENSE file in the root directory of this source tree.
29
- */const J=l.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:n=2,absoluteStrokeWidth:r,className:o="",children:i,iconNode:a,...s},u)=>l.createElement("svg",{ref:u,...Q,width:t,height:t,stroke:e,strokeWidth:r?24*Number(n)/Number(t):n,className:W("lucide",o),...!i&&!K(s)&&{"aria-hidden":"true"},...s},[...a.map(([e,t])=>l.createElement(e,t)),...Array.isArray(i)?i:[i]])),Y=(e,t)=>{const n=l.forwardRef(({className:n,...r},o)=>{return l.createElement(J,{ref:o,iconNode:t,className:W(`lucide-${i=q(e),i.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase()}`,`lucide-${e}`,n),...r});var i});return n.displayName=q(e),n},G=Y("chevron-down",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]),X=Y("circle-alert",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]]),Z=Y("globe",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20",key:"13o1zl"}],["path",{d:"M2 12h20",key:"9i4pu4"}]]),ee=Y("message-circle",[["path",{d:"M7.9 20A9 9 0 1 0 4 16.1L2 22Z",key:"vv11sd"}]]),te=Y("message-square",[["path",{d:"M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z",key:"1lielz"}]]),ne=Y("moon",[["path",{d:"M12 3a6 6 0 0 0 9 9 9 9 0 1 1-9-9Z",key:"a7tn18"}]]),re=Y("send",[["path",{d:"M14.536 21.686a.5.5 0 0 0 .937-.024l6.5-19a.496.496 0 0 0-.635-.635l-19 6.5a.5.5 0 0 0-.024.937l7.93 3.18a2 2 0 0 1 1.112 1.11z",key:"1ffxy3"}],["path",{d:"m21.854 2.147-10.94 10.939",key:"12cjpa"}]]),oe=Y("sun",[["circle",{cx:"12",cy:"12",r:"4",key:"4exip2"}],["path",{d:"M12 2v2",key:"tus03m"}],["path",{d:"M12 20v2",key:"1lh1kg"}],["path",{d:"m4.93 4.93 1.41 1.41",key:"149t6j"}],["path",{d:"m17.66 17.66 1.41 1.41",key:"ptbguv"}],["path",{d:"M2 12h2",key:"1t8f8n"}],["path",{d:"M20 12h2",key:"1q8mjw"}],["path",{d:"m6.34 17.66-1.41 1.41",key:"1m8zz5"}],["path",{d:"m19.07 4.93-1.41 1.41",key:"1shlcs"}]]),ie=({onClick:e,unreadCount:t=0,widgetConfig:n})=>{const{t:r}=V(),o=n?.company_name||r("widget.title");return N.jsxs("button",{onClick:e,className:"gpc-floating-button gpc-floating-button-with-text gpc-animate-fade-in","aria-label":r("chat.title"),title:r("chat.title"),children:[N.jsxs("div",{className:"gpc-floating-content",children:[N.jsx(ee,{className:"gpc-floating-icon"}),N.jsxs("span",{className:"gpc-floating-text",children:[r("widget.questionsTo")," ",o]})]}),t>0&&N.jsx("span",{className:"gpc-notification-badge",children:t>9?"9+":t})]})};
29
+ */const J=l.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:n=2,absoluteStrokeWidth:r,className:o="",children:i,iconNode:a,...s},u)=>l.createElement("svg",{ref:u,...Q,width:t,height:t,stroke:e,strokeWidth:r?24*Number(n)/Number(t):n,className:W("lucide",o),...!i&&!K(s)&&{"aria-hidden":"true"},...s},[...a.map(([e,t])=>l.createElement(e,t)),...Array.isArray(i)?i:[i]])),Y=(e,t)=>{const n=l.forwardRef(({className:n,...r},o)=>{return l.createElement(J,{ref:o,iconNode:t,className:W(`lucide-${i=q(e),i.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase()}`,`lucide-${e}`,n),...r});var i});return n.displayName=q(e),n},G=Y("chevron-down",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]),X=Y("circle-alert",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]]),Z=Y("globe",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20",key:"13o1zl"}],["path",{d:"M2 12h20",key:"9i4pu4"}]]),ee=Y("message-circle",[["path",{d:"M7.9 20A9 9 0 1 0 4 16.1L2 22Z",key:"vv11sd"}]]),te=Y("message-square",[["path",{d:"M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z",key:"1lielz"}]]),ne=Y("mic-off",[["line",{x1:"2",x2:"22",y1:"2",y2:"22",key:"a6p6uj"}],["path",{d:"M18.89 13.23A7.12 7.12 0 0 0 19 12v-2",key:"80xlxr"}],["path",{d:"M5 10v2a7 7 0 0 0 12 5",key:"p2k8kg"}],["path",{d:"M15 9.34V5a3 3 0 0 0-5.68-1.33",key:"1gzdoj"}],["path",{d:"M9 9v3a3 3 0 0 0 5.12 2.12",key:"r2i35w"}],["line",{x1:"12",x2:"12",y1:"19",y2:"22",key:"x3vr5v"}]]),re=Y("mic",[["path",{d:"M12 19v3",key:"npa21l"}],["path",{d:"M19 10v2a7 7 0 0 1-14 0v-2",key:"1vc78b"}],["rect",{x:"9",y:"2",width:"6",height:"13",rx:"3",key:"s6n7sd"}]]),oe=Y("moon",[["path",{d:"M12 3a6 6 0 0 0 9 9 9 9 0 1 1-9-9Z",key:"a7tn18"}]]),ie=Y("send",[["path",{d:"M14.536 21.686a.5.5 0 0 0 .937-.024l6.5-19a.496.496 0 0 0-.635-.635l-19 6.5a.5.5 0 0 0-.024.937l7.93 3.18a2 2 0 0 1 1.112 1.11z",key:"1ffxy3"}],["path",{d:"m21.854 2.147-10.94 10.939",key:"12cjpa"}]]),ae=Y("sun",[["circle",{cx:"12",cy:"12",r:"4",key:"4exip2"}],["path",{d:"M12 2v2",key:"tus03m"}],["path",{d:"M12 20v2",key:"1lh1kg"}],["path",{d:"m4.93 4.93 1.41 1.41",key:"149t6j"}],["path",{d:"m17.66 17.66 1.41 1.41",key:"ptbguv"}],["path",{d:"M2 12h2",key:"1t8f8n"}],["path",{d:"M20 12h2",key:"1q8mjw"}],["path",{d:"m6.34 17.66-1.41 1.41",key:"1m8zz5"}],["path",{d:"m19.07 4.93-1.41 1.41",key:"1shlcs"}]]),se=({onClick:e,unreadCount:t=0,widgetConfig:n})=>{const{t:r}=V(),o=n?.company_name||r("widget.title");return O.jsxs("button",{onClick:e,className:"gpc-floating-button gpc-floating-button-with-text gpc-animate-fade-in","aria-label":r("chat.title"),title:r("chat.title"),children:[O.jsxs("div",{className:"gpc-floating-content",children:[O.jsx(ee,{className:"gpc-floating-icon"}),O.jsxs("span",{className:"gpc-floating-text",children:[r("widget.questionsTo")," ",o]})]}),t>0&&O.jsx("span",{className:"gpc-notification-badge",children:t>9?"9+":t})]})};
30
30
  /**
31
31
  * @license lucide-react v0.525.0 - ISC
32
32
  *
33
33
  * This source code is licensed under the ISC license.
34
34
  * See the LICENSE file in the root directory of this source tree.
35
- */let ae,se,le,ue={data:""},ce=/(?:([\u0080-\uFFFF\w-%@]+) *:? *([^{;]+?);|([^;}{]*?) *{)|(}\s*)/g,de=/\/\*[^]*?\*\/| +/g,fe=/\n+/g,pe=(e,t)=>{let n="",r="",o="";for(let i in e){let a=e[i];"@"==i[0]?"i"==i[1]?n=i+" "+a+";":r+="f"==i[1]?pe(a,i):i+"{"+pe(a,"k"==i[1]?"":t)+"}":"object"==typeof a?r+=pe(a,t?t.replace(/([^,])+/g,e=>i.replace(/([^,]*:\S+\([^)]*\))|([^,])+/g,t=>/&/.test(t)?t.replace(/&/g,e):e?e+" "+t:t)):i):null!=a&&(i=/^--/.test(i)?i:i.replace(/[A-Z]/g,"-$&").toLowerCase(),o+=pe.p?pe.p(i,a):i+":"+a+";")}return n+(t&&o?t+"{"+o+"}":o)+r},he={},ge=e=>{if("object"==typeof e){let t="";for(let n in e)t+=n+ge(e[n]);return t}return e};function me(e){let t=this||{},n=e.call?e(t.p):e;return((e,t,n,r,o)=>{let i=ge(e),a=he[i]||(he[i]=(e=>{let t=0,n=11;for(;t<e.length;)n=101*n+e.charCodeAt(t++)>>>0;return"go"+n})(i));if(!he[a]){let t=i!==e?e:(e=>{let t,n,r=[{}];for(;t=ce.exec(e.replace(de,""));)t[4]?r.shift():t[3]?(n=t[3].replace(fe," ").trim(),r.unshift(r[0][n]=r[0][n]||{})):r[0][t[1]]=t[2].replace(fe," ").trim();return r[0]})(e);he[a]=pe(o?{["@keyframes "+a]:t}:t,n?"":"."+a)}let s=n&&he.g?he.g:null;return n&&(he.g=he[a]),l=he[a],u=t,c=r,(d=s)?u.data=u.data.replace(d,l):-1===u.data.indexOf(l)&&(u.data=c?l+u.data:u.data+l),a;var l,u,c,d})(n.unshift?n.raw?((e,t,n)=>e.reduce((e,r,o)=>{let i=t[o];if(i&&i.call){let e=i(n),t=e&&e.props&&e.props.className||/^go/.test(e)&&e;i=t?"."+t:e&&"object"==typeof e?e.props?"":pe(e,""):!1===e?"":e}return e+r+(null==i?"":i)},""))(n,[].slice.call(arguments,1),t.p):n.reduce((e,n)=>Object.assign(e,n&&n.call?n(t.p):n),{}):n,(e=>{if("object"==typeof window){let t=(e?e.querySelector("#_goober"):window._goober)||Object.assign(document.createElement("style"),{innerHTML:" ",id:"_goober"});return t.nonce=window.__nonce__,t.parentNode||(e||document.head).appendChild(t),t.firstChild}return e||ue})(t.target),t.g,t.o,t.k)}me.bind({g:1});let ye=me.bind({k:1});function ve(e,t){let n=this||{};return function(){let t=arguments;return function r(o,i){let a=Object.assign({},o),s=a.className||r.className;n.p=Object.assign({theme:se&&se()},a),n.o=/ *go\d+/.test(s),a.className=me.apply(n,t)+(s?" "+s:"");let l=e;return e[0]&&(l=a.as||e,delete a.as),le&&l[0]&&le(a),ae(l,a)}}}var be=(e,t)=>(e=>"function"==typeof e)(e)?e(t):e,ke=(()=>{let e=0;return()=>(++e).toString()})(),we=(()=>{let e;return()=>{if(void 0===e&&typeof window<"u"){let t=matchMedia("(prefers-reduced-motion: reduce)");e=!t||t.matches}return e}})(),xe="default",Se=(e,t)=>{let{toastLimit:n}=e.settings;switch(t.type){case 0:return{...e,toasts:[t.toast,...e.toasts].slice(0,n)};case 1:return{...e,toasts:e.toasts.map(e=>e.id===t.toast.id?{...e,...t.toast}:e)};case 2:let{toast:r}=t;return Se(e,{type:e.toasts.find(e=>e.id===r.id)?1:0,toast:r});case 3:let{toastId:o}=t;return{...e,toasts:e.toasts.map(e=>e.id===o||void 0===o?{...e,dismissed:!0,visible:!1}:e)};case 4:return void 0===t.toastId?{...e,toasts:[]}:{...e,toasts:e.toasts.filter(e=>e.id!==t.toastId)};case 5:return{...e,pausedAt:t.time};case 6:let i=t.time-(e.pausedAt||0);return{...e,pausedAt:void 0,toasts:e.toasts.map(e=>({...e,pauseDuration:e.pauseDuration+i}))}}},Ee=[],Ce={toasts:[],pausedAt:void 0,settings:{toastLimit:20}},Te={},Ne=(e,t=xe)=>{Te[t]=Se(Te[t]||Ce,e),Ee.forEach(([e,n])=>{e===t&&n(Te[t])})},Oe=e=>Object.keys(Te).forEach(t=>Ne(e,t)),Pe=(e=xe)=>t=>{Ne(t,e)},Le={blank:4e3,error:4e3,success:2e3,loading:1/0,custom:4e3},_e=e=>(t,n)=>{let r=((e,t="blank",n)=>({createdAt:Date.now(),visible:!0,dismissed:!1,type:t,ariaProps:{role:"status","aria-live":"polite"},message:e,pauseDuration:0,...n,id:(null==n?void 0:n.id)||ke()}))(t,e,n);return Pe(r.toasterId||(e=>Object.keys(Te).find(t=>Te[t].toasts.some(t=>t.id===e)))(r.id))({type:2,toast:r}),r.id},Re=(e,t)=>_e("blank")(e,t);Re.error=_e("error"),Re.success=_e("success"),Re.loading=_e("loading"),Re.custom=_e("custom"),Re.dismiss=(e,t)=>{let n={type:3,toastId:e};t?Pe(t)(n):Oe(n)},Re.dismissAll=e=>Re.dismiss(void 0,e),Re.remove=(e,t)=>{let n={type:4,toastId:e};t?Pe(t)(n):Oe(n)},Re.removeAll=e=>Re.remove(void 0,e),Re.promise=(e,t,n)=>{let r=Re.loading(t.loading,{...n,...null==n?void 0:n.loading});return"function"==typeof e&&(e=e()),e.then(e=>{let o=t.success?be(t.success,e):void 0;return o?Re.success(o,{id:r,...n,...null==n?void 0:n.success}):Re.dismiss(r),e}).catch(e=>{let o=t.error?be(t.error,e):void 0;o?Re.error(o,{id:r,...n,...null==n?void 0:n.error}):Re.dismiss(r)}),e};var Ie,Ae,ze,je,De=(e,t="default")=>{let{toasts:n,pausedAt:r}=((e={},t=xe)=>{let[n,r]=l.useState(Te[t]||Ce),o=l.useRef(Te[t]);l.useEffect(()=>(o.current!==Te[t]&&r(Te[t]),Ee.push([t,r]),()=>{let e=Ee.findIndex(([e])=>e===t);e>-1&&Ee.splice(e,1)}),[t]);let i=n.toasts.map(t=>{var n,r,o;return{...e,...e[t.type],...t,removeDelay:t.removeDelay||(null==(n=e[t.type])?void 0:n.removeDelay)||(null==e?void 0:e.removeDelay),duration:t.duration||(null==(r=e[t.type])?void 0:r.duration)||(null==e?void 0:e.duration)||Le[t.type],style:{...e.style,...null==(o=e[t.type])?void 0:o.style,...t.style}}});return{...n,toasts:i}})(e,t),o=l.useRef(new Map).current,i=l.useCallback((e,t=1e3)=>{if(o.has(e))return;let n=setTimeout(()=>{o.delete(e),a({type:4,toastId:e})},t);o.set(e,n)},[]);l.useEffect(()=>{if(r)return;let e=Date.now(),o=n.map(n=>{if(n.duration===1/0)return;let r=(n.duration||0)+n.pauseDuration-(e-n.createdAt);if(!(r<0))return setTimeout(()=>Re.dismiss(n.id,t),r);n.visible&&Re.dismiss(n.id)});return()=>{o.forEach(e=>e&&clearTimeout(e))}},[n,r,t]);let a=l.useCallback(Pe(t),[t]),s=l.useCallback(()=>{a({type:5,time:Date.now()})},[a]),u=l.useCallback((e,t)=>{a({type:1,toast:{id:e,height:t}})},[a]),c=l.useCallback(()=>{r&&a({type:6,time:Date.now()})},[r,a]),d=l.useCallback((e,t)=>{let{reverseOrder:r=!1,gutter:o=8,defaultPosition:i}=t||{},a=n.filter(t=>(t.position||i)===(e.position||i)&&t.height),s=a.findIndex(t=>t.id===e.id),l=a.filter((e,t)=>t<s&&e.visible).length;return a.filter(e=>e.visible).slice(...r?[l+1]:[0,l]).reduce((e,t)=>e+(t.height||0)+o,0)},[n]);return l.useEffect(()=>{n.forEach(e=>{if(e.dismissed)i(e.id,e.removeDelay);else{let t=o.get(e.id);t&&(clearTimeout(t),o.delete(e.id))}})},[n,i]),{toasts:n,handlers:{updateHeight:u,startPause:s,endPause:c,calculateOffset:d}}},Fe=ye`
35
+ */let le,ue,ce,de={data:""},fe=/(?:([\u0080-\uFFFF\w-%@]+) *:? *([^{;]+?);|([^;}{]*?) *{)|(}\s*)/g,pe=/\/\*[^]*?\*\/| +/g,he=/\n+/g,ge=(e,t)=>{let n="",r="",o="";for(let i in e){let a=e[i];"@"==i[0]?"i"==i[1]?n=i+" "+a+";":r+="f"==i[1]?ge(a,i):i+"{"+ge(a,"k"==i[1]?"":t)+"}":"object"==typeof a?r+=ge(a,t?t.replace(/([^,])+/g,e=>i.replace(/([^,]*:\S+\([^)]*\))|([^,])+/g,t=>/&/.test(t)?t.replace(/&/g,e):e?e+" "+t:t)):i):null!=a&&(i=/^--/.test(i)?i:i.replace(/[A-Z]/g,"-$&").toLowerCase(),o+=ge.p?ge.p(i,a):i+":"+a+";")}return n+(t&&o?t+"{"+o+"}":o)+r},me={},ye=e=>{if("object"==typeof e){let t="";for(let n in e)t+=n+ye(e[n]);return t}return e};function ve(e){let t=this||{},n=e.call?e(t.p):e;return((e,t,n,r,o)=>{let i=ye(e),a=me[i]||(me[i]=(e=>{let t=0,n=11;for(;t<e.length;)n=101*n+e.charCodeAt(t++)>>>0;return"go"+n})(i));if(!me[a]){let t=i!==e?e:(e=>{let t,n,r=[{}];for(;t=fe.exec(e.replace(pe,""));)t[4]?r.shift():t[3]?(n=t[3].replace(he," ").trim(),r.unshift(r[0][n]=r[0][n]||{})):r[0][t[1]]=t[2].replace(he," ").trim();return r[0]})(e);me[a]=ge(o?{["@keyframes "+a]:t}:t,n?"":"."+a)}let s=n&&me.g?me.g:null;return n&&(me.g=me[a]),l=me[a],u=t,c=r,(d=s)?u.data=u.data.replace(d,l):-1===u.data.indexOf(l)&&(u.data=c?l+u.data:u.data+l),a;var l,u,c,d})(n.unshift?n.raw?((e,t,n)=>e.reduce((e,r,o)=>{let i=t[o];if(i&&i.call){let e=i(n),t=e&&e.props&&e.props.className||/^go/.test(e)&&e;i=t?"."+t:e&&"object"==typeof e?e.props?"":ge(e,""):!1===e?"":e}return e+r+(null==i?"":i)},""))(n,[].slice.call(arguments,1),t.p):n.reduce((e,n)=>Object.assign(e,n&&n.call?n(t.p):n),{}):n,(e=>{if("object"==typeof window){let t=(e?e.querySelector("#_goober"):window._goober)||Object.assign(document.createElement("style"),{innerHTML:" ",id:"_goober"});return t.nonce=window.__nonce__,t.parentNode||(e||document.head).appendChild(t),t.firstChild}return e||de})(t.target),t.g,t.o,t.k)}ve.bind({g:1});let be=ve.bind({k:1});function ke(e,t){let n=this||{};return function(){let t=arguments;return function r(o,i){let a=Object.assign({},o),s=a.className||r.className;n.p=Object.assign({theme:ue&&ue()},a),n.o=/ *go\d+/.test(s),a.className=ve.apply(n,t)+(s?" "+s:"");let l=e;return e[0]&&(l=a.as||e,delete a.as),ce&&l[0]&&ce(a),le(l,a)}}}var xe=(e,t)=>(e=>"function"==typeof e)(e)?e(t):e,we=(()=>{let e=0;return()=>(++e).toString()})(),Se=(()=>{let e;return()=>{if(void 0===e&&typeof window<"u"){let t=matchMedia("(prefers-reduced-motion: reduce)");e=!t||t.matches}return e}})(),Ee="default",Ce=(e,t)=>{let{toastLimit:n}=e.settings;switch(t.type){case 0:return{...e,toasts:[t.toast,...e.toasts].slice(0,n)};case 1:return{...e,toasts:e.toasts.map(e=>e.id===t.toast.id?{...e,...t.toast}:e)};case 2:let{toast:r}=t;return Ce(e,{type:e.toasts.find(e=>e.id===r.id)?1:0,toast:r});case 3:let{toastId:o}=t;return{...e,toasts:e.toasts.map(e=>e.id===o||void 0===o?{...e,dismissed:!0,visible:!1}:e)};case 4:return void 0===t.toastId?{...e,toasts:[]}:{...e,toasts:e.toasts.filter(e=>e.id!==t.toastId)};case 5:return{...e,pausedAt:t.time};case 6:let i=t.time-(e.pausedAt||0);return{...e,pausedAt:void 0,toasts:e.toasts.map(e=>({...e,pauseDuration:e.pauseDuration+i}))}}},Te=[],Oe={toasts:[],pausedAt:void 0,settings:{toastLimit:20}},Ne={},Pe=(e,t=Ee)=>{Ne[t]=Ce(Ne[t]||Oe,e),Te.forEach(([e,n])=>{e===t&&n(Ne[t])})},Le=e=>Object.keys(Ne).forEach(t=>Pe(e,t)),Re=(e=Ee)=>t=>{Pe(t,e)},_e={blank:4e3,error:4e3,success:2e3,loading:1/0,custom:4e3},Ie=e=>(t,n)=>{let r=((e,t="blank",n)=>({createdAt:Date.now(),visible:!0,dismissed:!1,type:t,ariaProps:{role:"status","aria-live":"polite"},message:e,pauseDuration:0,...n,id:(null==n?void 0:n.id)||we()}))(t,e,n);return Re(r.toasterId||(e=>Object.keys(Ne).find(t=>Ne[t].toasts.some(t=>t.id===e)))(r.id))({type:2,toast:r}),r.id},Ae=(e,t)=>Ie("blank")(e,t);Ae.error=Ie("error"),Ae.success=Ie("success"),Ae.loading=Ie("loading"),Ae.custom=Ie("custom"),Ae.dismiss=(e,t)=>{let n={type:3,toastId:e};t?Re(t)(n):Le(n)},Ae.dismissAll=e=>Ae.dismiss(void 0,e),Ae.remove=(e,t)=>{let n={type:4,toastId:e};t?Re(t)(n):Le(n)},Ae.removeAll=e=>Ae.remove(void 0,e),Ae.promise=(e,t,n)=>{let r=Ae.loading(t.loading,{...n,...null==n?void 0:n.loading});return"function"==typeof e&&(e=e()),e.then(e=>{let o=t.success?xe(t.success,e):void 0;return o?Ae.success(o,{id:r,...n,...null==n?void 0:n.success}):Ae.dismiss(r),e}).catch(e=>{let o=t.error?xe(t.error,e):void 0;o?Ae.error(o,{id:r,...n,...null==n?void 0:n.error}):Ae.dismiss(r)}),e};var De,ze,je,Fe,Me=(e,t="default")=>{let{toasts:n,pausedAt:r}=((e={},t=Ee)=>{let[n,r]=l.useState(Ne[t]||Oe),o=l.useRef(Ne[t]);l.useEffect(()=>(o.current!==Ne[t]&&r(Ne[t]),Te.push([t,r]),()=>{let e=Te.findIndex(([e])=>e===t);e>-1&&Te.splice(e,1)}),[t]);let i=n.toasts.map(t=>{var n,r,o;return{...e,...e[t.type],...t,removeDelay:t.removeDelay||(null==(n=e[t.type])?void 0:n.removeDelay)||(null==e?void 0:e.removeDelay),duration:t.duration||(null==(r=e[t.type])?void 0:r.duration)||(null==e?void 0:e.duration)||_e[t.type],style:{...e.style,...null==(o=e[t.type])?void 0:o.style,...t.style}}});return{...n,toasts:i}})(e,t),o=l.useRef(new Map).current,i=l.useCallback((e,t=1e3)=>{if(o.has(e))return;let n=setTimeout(()=>{o.delete(e),a({type:4,toastId:e})},t);o.set(e,n)},[]);l.useEffect(()=>{if(r)return;let e=Date.now(),o=n.map(n=>{if(n.duration===1/0)return;let r=(n.duration||0)+n.pauseDuration-(e-n.createdAt);if(!(r<0))return setTimeout(()=>Ae.dismiss(n.id,t),r);n.visible&&Ae.dismiss(n.id)});return()=>{o.forEach(e=>e&&clearTimeout(e))}},[n,r,t]);let a=l.useCallback(Re(t),[t]),s=l.useCallback(()=>{a({type:5,time:Date.now()})},[a]),u=l.useCallback((e,t)=>{a({type:1,toast:{id:e,height:t}})},[a]),c=l.useCallback(()=>{r&&a({type:6,time:Date.now()})},[r,a]),d=l.useCallback((e,t)=>{let{reverseOrder:r=!1,gutter:o=8,defaultPosition:i}=t||{},a=n.filter(t=>(t.position||i)===(e.position||i)&&t.height),s=a.findIndex(t=>t.id===e.id),l=a.filter((e,t)=>t<s&&e.visible).length;return a.filter(e=>e.visible).slice(...r?[l+1]:[0,l]).reduce((e,t)=>e+(t.height||0)+o,0)},[n]);return l.useEffect(()=>{n.forEach(e=>{if(e.dismissed)i(e.id,e.removeDelay);else{let t=o.get(e.id);t&&(clearTimeout(t),o.delete(e.id))}})},[n,i]),{toasts:n,handlers:{updateHeight:u,startPause:s,endPause:c,calculateOffset:d}}},Ue=be`
36
36
  from {
37
37
  transform: scale(0) rotate(45deg);
38
38
  opacity: 0;
@@ -40,7 +40,7 @@ from {
40
40
  to {
41
41
  transform: scale(1) rotate(45deg);
42
42
  opacity: 1;
43
- }`,Me=ye`
43
+ }`,Be=be`
44
44
  from {
45
45
  transform: scale(0);
46
46
  opacity: 0;
@@ -48,7 +48,7 @@ from {
48
48
  to {
49
49
  transform: scale(1);
50
50
  opacity: 1;
51
- }`,Ue=ye`
51
+ }`,$e=be`
52
52
  from {
53
53
  transform: scale(0) rotate(90deg);
54
54
  opacity: 0;
@@ -56,7 +56,7 @@ from {
56
56
  to {
57
57
  transform: scale(1) rotate(90deg);
58
58
  opacity: 1;
59
- }`,Be=ve("div")`
59
+ }`,Ve=ke("div")`
60
60
  width: 20px;
61
61
  opacity: 0;
62
62
  height: 20px;
@@ -65,14 +65,14 @@ to {
65
65
  position: relative;
66
66
  transform: rotate(45deg);
67
67
 
68
- animation: ${Fe} 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275)
68
+ animation: ${Ue} 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275)
69
69
  forwards;
70
70
  animation-delay: 100ms;
71
71
 
72
72
  &:after,
73
73
  &:before {
74
74
  content: '';
75
- animation: ${Me} 0.15s ease-out forwards;
75
+ animation: ${Be} 0.15s ease-out forwards;
76
76
  animation-delay: 150ms;
77
77
  position: absolute;
78
78
  border-radius: 3px;
@@ -85,18 +85,18 @@ to {
85
85
  }
86
86
 
87
87
  &:before {
88
- animation: ${Ue} 0.15s ease-out forwards;
88
+ animation: ${$e} 0.15s ease-out forwards;
89
89
  animation-delay: 180ms;
90
90
  transform: rotate(90deg);
91
91
  }
92
- `,$e=ye`
92
+ `,He=be`
93
93
  from {
94
94
  transform: rotate(0deg);
95
95
  }
96
96
  to {
97
97
  transform: rotate(360deg);
98
98
  }
99
- `,Ve=ve("div")`
99
+ `,qe=ke("div")`
100
100
  width: 12px;
101
101
  height: 12px;
102
102
  box-sizing: border-box;
@@ -104,8 +104,8 @@ to {
104
104
  border-radius: 100%;
105
105
  border-color: ${e=>e.secondary||"#e0e0e0"};
106
106
  border-right-color: ${e=>e.primary||"#616161"};
107
- animation: ${$e} 1s linear infinite;
108
- `,He=ye`
107
+ animation: ${He} 1s linear infinite;
108
+ `,We=be`
109
109
  from {
110
110
  transform: scale(0) rotate(45deg);
111
111
  opacity: 0;
@@ -113,7 +113,7 @@ from {
113
113
  to {
114
114
  transform: scale(1) rotate(45deg);
115
115
  opacity: 1;
116
- }`,qe=ye`
116
+ }`,Ke=be`
117
117
  0% {
118
118
  height: 0;
119
119
  width: 0;
@@ -127,7 +127,7 @@ to {
127
127
  100% {
128
128
  opacity: 1;
129
129
  height: 10px;
130
- }`,We=ve("div")`
130
+ }`,Qe=ke("div")`
131
131
  width: 20px;
132
132
  opacity: 0;
133
133
  height: 20px;
@@ -136,13 +136,13 @@ to {
136
136
  position: relative;
137
137
  transform: rotate(45deg);
138
138
 
139
- animation: ${He} 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275)
139
+ animation: ${We} 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275)
140
140
  forwards;
141
141
  animation-delay: 100ms;
142
142
  &:after {
143
143
  content: '';
144
144
  box-sizing: border-box;
145
- animation: ${qe} 0.2s ease-out forwards;
145
+ animation: ${Ke} 0.2s ease-out forwards;
146
146
  opacity: 0;
147
147
  animation-delay: 200ms;
148
148
  position: absolute;
@@ -154,16 +154,16 @@ to {
154
154
  height: 10px;
155
155
  width: 6px;
156
156
  }
157
- `,Ke=ve("div")`
157
+ `,Je=ke("div")`
158
158
  position: absolute;
159
- `,Qe=ve("div")`
159
+ `,Ye=ke("div")`
160
160
  position: relative;
161
161
  display: flex;
162
162
  justify-content: center;
163
163
  align-items: center;
164
164
  min-width: 20px;
165
165
  min-height: 20px;
166
- `,Je=ye`
166
+ `,Ge=be`
167
167
  from {
168
168
  transform: scale(0.6);
169
169
  opacity: 0.4;
@@ -171,14 +171,14 @@ from {
171
171
  to {
172
172
  transform: scale(1);
173
173
  opacity: 1;
174
- }`,Ye=ve("div")`
174
+ }`,Xe=ke("div")`
175
175
  position: relative;
176
176
  transform: scale(0.6);
177
177
  opacity: 0.4;
178
178
  min-width: 20px;
179
- animation: ${Je} 0.3s 0.12s cubic-bezier(0.175, 0.885, 0.32, 1.275)
179
+ animation: ${Ge} 0.3s 0.12s cubic-bezier(0.175, 0.885, 0.32, 1.275)
180
180
  forwards;
181
- `,Ge=({toast:e})=>{let{icon:t,type:n,iconTheme:r}=e;return void 0!==t?"string"==typeof t?l.createElement(Ye,null,t):t:"blank"===n?null:l.createElement(Qe,null,l.createElement(Ve,{...r}),"loading"!==n&&l.createElement(Ke,null,"error"===n?l.createElement(Be,{...r}):l.createElement(We,{...r})))},Xe=e=>`\n0% {transform: translate3d(0,${-200*e}%,0) scale(.6); opacity:.5;}\n100% {transform: translate3d(0,0,0) scale(1); opacity:1;}\n`,Ze=e=>`\n0% {transform: translate3d(0,0,-1px) scale(1); opacity:1;}\n100% {transform: translate3d(0,${-150*e}%,-1px) scale(.6); opacity:0;}\n`,et=ve("div")`
181
+ `,Ze=({toast:e})=>{let{icon:t,type:n,iconTheme:r}=e;return void 0!==t?"string"==typeof t?l.createElement(Xe,null,t):t:"blank"===n?null:l.createElement(Ye,null,l.createElement(qe,{...r}),"loading"!==n&&l.createElement(Je,null,"error"===n?l.createElement(Ve,{...r}):l.createElement(Qe,{...r})))},et=e=>`\n0% {transform: translate3d(0,${-200*e}%,0) scale(.6); opacity:.5;}\n100% {transform: translate3d(0,0,0) scale(1); opacity:1;}\n`,tt=e=>`\n0% {transform: translate3d(0,0,-1px) scale(1); opacity:1;}\n100% {transform: translate3d(0,${-150*e}%,-1px) scale(.6); opacity:0;}\n`,nt=ke("div")`
182
182
  display: flex;
183
183
  align-items: center;
184
184
  background: #fff;
@@ -190,17 +190,17 @@ to {
190
190
  pointer-events: auto;
191
191
  padding: 8px 10px;
192
192
  border-radius: 8px;
193
- `,tt=ve("div")`
193
+ `,rt=ke("div")`
194
194
  display: flex;
195
195
  justify-content: center;
196
196
  margin: 4px 10px;
197
197
  color: inherit;
198
198
  flex: 1 1 auto;
199
199
  white-space: pre-line;
200
- `,nt=l.memo(({toast:e,position:t,style:n,children:r})=>{let o=e.height?((e,t)=>{let n=e.includes("top")?1:-1,[r,o]=we()?["0%{opacity:0;} 100%{opacity:1;}","0%{opacity:1;} 100%{opacity:0;}"]:[Xe(n),Ze(n)];return{animation:t?`${ye(r)} 0.35s cubic-bezier(.21,1.02,.73,1) forwards`:`${ye(o)} 0.4s forwards cubic-bezier(.06,.71,.55,1)`}})(e.position||t||"top-center",e.visible):{opacity:0},i=l.createElement(Ge,{toast:e}),a=l.createElement(tt,{...e.ariaProps},be(e.message,e));return l.createElement(et,{className:e.className,style:{...o,...n,...e.style}},"function"==typeof r?r({icon:i,message:a}):l.createElement(l.Fragment,null,i,a))});Ie=l.createElement,pe.p=Ae,ae=Ie,se=ze,le=je;var rt=({id:e,className:t,style:n,onHeightUpdate:r,children:o})=>{let i=l.useCallback(t=>{if(t){let n=()=>{let n=t.getBoundingClientRect().height;r(e,n)};n(),new MutationObserver(n).observe(t,{subtree:!0,childList:!0,characterData:!0})}},[e,r]);return l.createElement("div",{ref:i,className:t,style:n},o)},ot=me`
200
+ `,ot=l.memo(({toast:e,position:t,style:n,children:r})=>{let o=e.height?((e,t)=>{let n=e.includes("top")?1:-1,[r,o]=Se()?["0%{opacity:0;} 100%{opacity:1;}","0%{opacity:1;} 100%{opacity:0;}"]:[et(n),tt(n)];return{animation:t?`${be(r)} 0.35s cubic-bezier(.21,1.02,.73,1) forwards`:`${be(o)} 0.4s forwards cubic-bezier(.06,.71,.55,1)`}})(e.position||t||"top-center",e.visible):{opacity:0},i=l.createElement(Ze,{toast:e}),a=l.createElement(rt,{...e.ariaProps},xe(e.message,e));return l.createElement(nt,{className:e.className,style:{...o,...n,...e.style}},"function"==typeof r?r({icon:i,message:a}):l.createElement(l.Fragment,null,i,a))});De=l.createElement,ge.p=ze,le=De,ue=je,ce=Fe;var it=({id:e,className:t,style:n,onHeightUpdate:r,children:o})=>{let i=l.useCallback(t=>{if(t){let n=()=>{let n=t.getBoundingClientRect().height;r(e,n)};n(),new MutationObserver(n).observe(t,{subtree:!0,childList:!0,characterData:!0})}},[e,r]);return l.createElement("div",{ref:i,className:t,style:n},o)},at=ve`
201
201
  z-index: 9999;
202
202
  > * {
203
203
  pointer-events: auto;
204
204
  }
205
- `,it=({reverseOrder:e,position:t="top-center",toastOptions:n,gutter:r,children:o,toasterId:i,containerStyle:a,containerClassName:s})=>{let{toasts:u,handlers:c}=De(n,i);return l.createElement("div",{"data-rht-toaster":i||"",style:{position:"fixed",zIndex:9999,top:16,left:16,right:16,bottom:16,pointerEvents:"none",...a},className:s,onMouseEnter:c.startPause,onMouseLeave:c.endPause},u.map(n=>{let i=n.position||t,a=((e,t)=>{let n=e.includes("top"),r=n?{top:0}:{bottom:0},o=e.includes("center")?{justifyContent:"center"}:e.includes("right")?{justifyContent:"flex-end"}:{};return{left:0,right:0,display:"flex",position:"absolute",transition:we()?void 0:"all 230ms cubic-bezier(.21,1.02,.73,1)",transform:`translateY(${t*(n?1:-1)}px)`,...r,...o}})(i,c.calculateOffset(n,{reverseOrder:e,gutter:r,defaultPosition:t}));return l.createElement(rt,{id:n.id,key:n.id,onHeightUpdate:c.updateHeight,className:n.visible?ot:"",style:a},"custom"===n.type?be(n.message,n):o?o(n):l.createElement(nt,{toast:n,position:i}))}))},at=Re;const st=({theme:e,onToggle:t})=>{const{t:n}=V();return N.jsx("button",{onClick:t,className:"gpc-header-button gpc-focus-visible gpc-transition","aria-label":n("theme.toggle"),title:n("theme.toggle"),children:"light"===e?N.jsx(ne,{className:"gpc-icon"}):N.jsx(oe,{className:"gpc-icon"})})},lt=[{code:"en",label:"English",flag:"🇬🇧"},{code:"es",label:"Español",flag:"🇪🇸"},{code:"fr",label:"Français",flag:"🇫🇷"}],ut=()=>{const{i18n:e}=V(),[t,n]=l.useState(!1),r=l.useRef(null),o=lt.find(t=>t.code===e.language)||lt[0];return l.useEffect(()=>{const e=e=>{r.current&&!r.current.contains(e.target)&&n(!1)};return t&&document.addEventListener("mousedown",e),()=>{document.removeEventListener("mousedown",e)}},[t]),N.jsxs("div",{className:"gpc-language-selector",ref:r,children:[N.jsx("button",{onClick:()=>n(!t),className:"gpc-header-button gpc-focus-visible gpc-transition","aria-label":"Cambiar idioma",title:"Cambiar idioma",children:N.jsx(Z,{className:"gpc-icon"})}),t&&N.jsx("div",{className:"gpc-language-dropdown",children:lt.map(t=>N.jsxs("button",{onClick:()=>{return r=t.code,e.changeLanguage(r),void n(!1);var r},className:"gpc-language-option "+(t.code===o.code?"gpc-language-option-active":""),children:[N.jsx("span",{className:"gpc-language-flag",children:t.flag}),N.jsx("span",{className:"gpc-language-label",children:t.label})]},t.code))})]})},ct=({onClose:e,theme:t,onToggleTheme:n,showBranding:r=!0,widgetConfig:o=null})=>{const{t:i}=V(),a=o?.company_name||i("widget.title"),s=o?.company_logo_base64,l=s?.startsWith("data:")?s:s?`data:image/png;base64,${s}`:null;return N.jsxs("div",{className:"gpc-chat-header",children:[N.jsxs("div",{className:"gpc-header-content",children:[l&&N.jsx("div",{className:"gpc-header-logo",children:N.jsx("img",{src:l,alt:a,className:"gpc-company-logo"})}),N.jsx("div",{className:"gpc-header-text",children:N.jsx("h2",{className:"gpc-header-title",children:a})})]}),N.jsxs("div",{className:"gpc-header-actions",children:[N.jsx(ut,{}),N.jsx(st,{theme:t,onToggle:n}),N.jsx("button",{onClick:e,className:"gpc-header-button gpc-focus-visible gpc-transition","aria-label":i("chat.close"),title:i("chat.close"),children:N.jsx(G,{className:"gpc-icon"})})]})]})};function dt(){}function ft(){}const pt=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,ht=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,gt={};function mt(e,t){return(gt.jsx?ht:pt).test(e)}const yt=/[ \t\n\f\r]/g;function vt(e){return""===e.replace(yt,"")}class bt{constructor(e,t,n){this.normal=t,this.property=e,n&&(this.space=n)}}function kt(e,t){const n={},r={};for(const o of e)Object.assign(n,o.property),Object.assign(r,o.normal);return new bt(n,r,t)}function wt(e){return e.toLowerCase()}bt.prototype.normal={},bt.prototype.property={},bt.prototype.space=void 0;class xt{constructor(e,t){this.attribute=t,this.property=e}}xt.prototype.attribute="",xt.prototype.booleanish=!1,xt.prototype.boolean=!1,xt.prototype.commaOrSpaceSeparated=!1,xt.prototype.commaSeparated=!1,xt.prototype.defined=!1,xt.prototype.mustUseProperty=!1,xt.prototype.number=!1,xt.prototype.overloadedBoolean=!1,xt.prototype.property="",xt.prototype.spaceSeparated=!1,xt.prototype.space=void 0;let St=0;const Et=_t(),Ct=_t(),Tt=_t(),Nt=_t(),Ot=_t(),Pt=_t(),Lt=_t();function _t(){return 2**++St}const Rt=Object.freeze(Object.defineProperty({__proto__:null,boolean:Et,booleanish:Ct,commaOrSpaceSeparated:Lt,commaSeparated:Pt,number:Nt,overloadedBoolean:Tt,spaceSeparated:Ot},Symbol.toStringTag,{value:"Module"})),It=Object.keys(Rt);class At extends xt{constructor(e,t,n,r){let o=-1;if(super(e,t),zt(this,"space",r),"number"==typeof n)for(;++o<It.length;){const e=It[o];zt(this,It[o],(n&Rt[e])===Rt[e])}}}function zt(e,t,n){n&&(e[t]=n)}function jt(e){const t={},n={};for(const[r,o]of Object.entries(e.properties)){const i=new At(r,e.transform(e.attributes||{},r),o,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(i.mustUseProperty=!0),t[r]=i,n[wt(r)]=r,n[wt(i.attribute)]=r}return new bt(t,n,e.space)}At.prototype.defined=!0;const Dt=jt({properties:{ariaActiveDescendant:null,ariaAtomic:Ct,ariaAutoComplete:null,ariaBusy:Ct,ariaChecked:Ct,ariaColCount:Nt,ariaColIndex:Nt,ariaColSpan:Nt,ariaControls:Ot,ariaCurrent:null,ariaDescribedBy:Ot,ariaDetails:null,ariaDisabled:Ct,ariaDropEffect:Ot,ariaErrorMessage:null,ariaExpanded:Ct,ariaFlowTo:Ot,ariaGrabbed:Ct,ariaHasPopup:null,ariaHidden:Ct,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:Ot,ariaLevel:Nt,ariaLive:null,ariaModal:Ct,ariaMultiLine:Ct,ariaMultiSelectable:Ct,ariaOrientation:null,ariaOwns:Ot,ariaPlaceholder:null,ariaPosInSet:Nt,ariaPressed:Ct,ariaReadOnly:Ct,ariaRelevant:null,ariaRequired:Ct,ariaRoleDescription:Ot,ariaRowCount:Nt,ariaRowIndex:Nt,ariaRowSpan:Nt,ariaSelected:Ct,ariaSetSize:Nt,ariaSort:null,ariaValueMax:Nt,ariaValueMin:Nt,ariaValueNow:Nt,ariaValueText:null,role:null},transform:(e,t)=>"role"===t?t:"aria-"+t.slice(4).toLowerCase()});function Ft(e,t){return t in e?e[t]:t}function Mt(e,t){return Ft(e,t.toLowerCase())}const Ut=jt({attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:Pt,acceptCharset:Ot,accessKey:Ot,action:null,allow:null,allowFullScreen:Et,allowPaymentRequest:Et,allowUserMedia:Et,alt:null,as:null,async:Et,autoCapitalize:null,autoComplete:Ot,autoFocus:Et,autoPlay:Et,blocking:Ot,capture:null,charSet:null,checked:Et,cite:null,className:Ot,cols:Nt,colSpan:null,content:null,contentEditable:Ct,controls:Et,controlsList:Ot,coords:Nt|Pt,crossOrigin:null,data:null,dateTime:null,decoding:null,default:Et,defer:Et,dir:null,dirName:null,disabled:Et,download:Tt,draggable:Ct,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:Et,formTarget:null,headers:Ot,height:Nt,hidden:Tt,high:Nt,href:null,hrefLang:null,htmlFor:Ot,httpEquiv:Ot,id:null,imageSizes:null,imageSrcSet:null,inert:Et,inputMode:null,integrity:null,is:null,isMap:Et,itemId:null,itemProp:Ot,itemRef:Ot,itemScope:Et,itemType:Ot,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:Et,low:Nt,manifest:null,max:null,maxLength:Nt,media:null,method:null,min:null,minLength:Nt,multiple:Et,muted:Et,name:null,nonce:null,noModule:Et,noValidate:Et,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:Et,optimum:Nt,pattern:null,ping:Ot,placeholder:null,playsInline:Et,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:Et,referrerPolicy:null,rel:Ot,required:Et,reversed:Et,rows:Nt,rowSpan:Nt,sandbox:Ot,scope:null,scoped:Et,seamless:Et,selected:Et,shadowRootClonable:Et,shadowRootDelegatesFocus:Et,shadowRootMode:null,shape:null,size:Nt,sizes:null,slot:null,span:Nt,spellCheck:Ct,src:null,srcDoc:null,srcLang:null,srcSet:null,start:Nt,step:null,style:null,tabIndex:Nt,target:null,title:null,translate:null,type:null,typeMustMatch:Et,useMap:null,value:Ct,width:Nt,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:Ot,axis:null,background:null,bgColor:null,border:Nt,borderColor:null,bottomMargin:Nt,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:Et,declare:Et,event:null,face:null,frame:null,frameBorder:null,hSpace:Nt,leftMargin:Nt,link:null,longDesc:null,lowSrc:null,marginHeight:Nt,marginWidth:Nt,noResize:Et,noHref:Et,noShade:Et,noWrap:Et,object:null,profile:null,prompt:null,rev:null,rightMargin:Nt,rules:null,scheme:null,scrolling:Ct,standby:null,summary:null,text:null,topMargin:Nt,valueType:null,version:null,vAlign:null,vLink:null,vSpace:Nt,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:Et,disableRemotePlayback:Et,prefix:null,property:null,results:Nt,security:null,unselectable:null},space:"html",transform:Mt}),Bt=jt({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"},properties:{about:Lt,accentHeight:Nt,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:Nt,amplitude:Nt,arabicForm:null,ascent:Nt,attributeName:null,attributeType:null,azimuth:Nt,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:Nt,by:null,calcMode:null,capHeight:Nt,className:Ot,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:Nt,diffuseConstant:Nt,direction:null,display:null,dur:null,divisor:Nt,dominantBaseline:null,download:Et,dx:null,dy:null,edgeMode:null,editable:null,elevation:Nt,enableBackground:null,end:null,event:null,exponent:Nt,externalResourcesRequired:null,fill:null,fillOpacity:Nt,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:Pt,g2:Pt,glyphName:Pt,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:Nt,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:Nt,horizOriginX:Nt,horizOriginY:Nt,id:null,ideographic:Nt,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:Nt,k:Nt,k1:Nt,k2:Nt,k3:Nt,k4:Nt,kernelMatrix:Lt,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:Nt,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:Nt,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:Nt,overlineThickness:Nt,paintOrder:null,panose1:null,path:null,pathLength:Nt,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:Ot,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:Nt,pointsAtY:Nt,pointsAtZ:Nt,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:Lt,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:Lt,rev:Lt,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:Lt,requiredFeatures:Lt,requiredFonts:Lt,requiredFormats:Lt,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:Nt,specularExponent:Nt,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:Nt,strikethroughThickness:Nt,string:null,stroke:null,strokeDashArray:Lt,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:Nt,strokeOpacity:Nt,strokeWidth:null,style:null,surfaceScale:Nt,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:Lt,tabIndex:Nt,tableValues:null,target:null,targetX:Nt,targetY:Nt,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:Lt,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:Nt,underlineThickness:Nt,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:Nt,values:null,vAlphabetic:Nt,vMathematical:Nt,vectorEffect:null,vHanging:Nt,vIdeographic:Nt,version:null,vertAdvY:Nt,vertOriginX:Nt,vertOriginY:Nt,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:Nt,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null},space:"svg",transform:Ft}),$t=jt({properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null},space:"xlink",transform:(e,t)=>"xlink:"+t.slice(5).toLowerCase()}),Vt=jt({attributes:{xmlnsxlink:"xmlns:xlink"},properties:{xmlnsXLink:null,xmlns:null},space:"xmlns",transform:Mt}),Ht=jt({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:"xml",transform:(e,t)=>"xml:"+t.slice(3).toLowerCase()}),qt={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"},Wt=/[A-Z]/g,Kt=/-[a-z]/g,Qt=/^data[-\w.:]+$/i;function Jt(e){return"-"+e.toLowerCase()}function Yt(e){return e.charAt(1).toUpperCase()}const Gt=kt([Dt,Ut,$t,Vt,Ht],"html"),Xt=kt([Dt,Bt,$t,Vt,Ht],"svg");var Zt,en,tn,nn={};function rn(){if(tn)return nn;tn=1;var e=nn&&nn.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(nn,"__esModule",{value:!0}),nn.default=function(e,n){let r=null;if(!e||"string"!=typeof e)return r;const o=(0,t.default)(e),i="function"==typeof n;return o.forEach(e=>{if("declaration"!==e.type)return;const{property:t,value:o}=e;i?n(t,o,e):o&&(r=r||{},r[t]=o)}),r};const t=e(function(){if(en)return Zt;en=1;var e=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,t=/\n/g,n=/^\s*/,r=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,o=/^:\s*/,i=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,a=/^[;\s]*/,s=/^\s+|\s+$/g,l="";function u(e){return e?e.replace(s,l):l}return Zt=function(s,c){if("string"!=typeof s)throw new TypeError("First argument must be a string");if(!s)return[];c=c||{};var d=1,f=1;function p(e){var n=e.match(t);n&&(d+=n.length);var r=e.lastIndexOf("\n");f=~r?e.length-r:f+e.length}function h(){var e={line:d,column:f};return function(t){return t.position=new g(e),v(),t}}function g(e){this.start=e,this.end={line:d,column:f},this.source=c.source}function m(e){var t=new Error(c.source+":"+d+":"+f+": "+e);if(t.reason=e,t.filename=c.source,t.line=d,t.column=f,t.source=s,!c.silent)throw t}function y(e){var t=e.exec(s);if(t){var n=t[0];return p(n),s=s.slice(n.length),t}}function v(){y(n)}function b(e){var t;for(e=e||[];t=k();)!1!==t&&e.push(t);return e}function k(){var e=h();if("/"==s.charAt(0)&&"*"==s.charAt(1)){for(var t=2;l!=s.charAt(t)&&("*"!=s.charAt(t)||"/"!=s.charAt(t+1));)++t;if(t+=2,l===s.charAt(t-1))return m("End of comment missing");var n=s.slice(2,t-2);return f+=2,p(n),s=s.slice(t),f+=2,e({type:"comment",comment:n})}}function w(){var t=h(),n=y(r);if(n){if(k(),!y(o))return m("property missing ':'");var s=y(i),c=t({type:"declaration",property:u(n[0].replace(e,l)),value:s?u(s[0].replace(e,l)):l});return y(a),c}}return g.prototype.content=s,v(),function(){var e,t=[];for(b(t);e=w();)!1!==e&&(t.push(e),b(t));return t}()}}());return nn}var on,an,sn,ln={};function un(){if(on)return ln;on=1,Object.defineProperty(ln,"__esModule",{value:!0}),ln.camelCase=void 0;var e=/^--[a-zA-Z0-9_-]+$/,t=/-([a-z])/g,n=/^[^-]+$/,r=/^-(webkit|moz|ms|o|khtml)-/,o=/^-(ms)-/,i=function(e,t){return t.toUpperCase()},a=function(e,t){return"".concat(t,"-")};return ln.camelCase=function(s,l){return void 0===l&&(l={}),function(t){return!t||n.test(t)||e.test(t)}(s)?s:(s=s.toLowerCase(),(s=l.reactCompat?s.replace(o,a):s.replace(r,a)).replace(t,i))},ln}const cn=t(function(){if(sn)return an;sn=1;var e=(an&&an.__importDefault||function(e){return e&&e.__esModule?e:{default:e}})(rn()),t=un();function n(n,r){var o={};return n&&"string"==typeof n?((0,e.default)(n,function(e,n){e&&n&&(o[(0,t.camelCase)(e,r)]=n)}),o):o}return n.default=n,an=n}()),dn=pn("end"),fn=pn("start");function pn(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 hn(e){return e&&"object"==typeof e?"position"in e||"type"in e?mn(e.position):"start"in e||"end"in e?mn(e):"line"in e||"column"in e?gn(e):"":""}function gn(e){return yn(e&&e.line)+":"+yn(e&&e.column)}function mn(e){return gn(e&&e.start)+"-"+gn(e&&e.end)}function yn(e){return e&&"number"==typeof e?e:1}class vn extends Error{constructor(e,t,n){super(),"string"==typeof t&&(n=t,t=void 0);let r="",o={},i=!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&&(i=!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 a=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=a?a.column:void 0,this.fatal=void 0,this.file="",this.message=r,this.line=a?a.line:void 0,this.name=hn(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=i&&o.cause&&"string"==typeof o.cause.stack?o.cause.stack:"",this.actual=void 0,this.expected=void 0,this.note=void 0,this.url=void 0}}vn.prototype.file="",vn.prototype.name="",vn.prototype.reason="",vn.prototype.message="",vn.prototype.stack="",vn.prototype.column=void 0,vn.prototype.line=void 0,vn.prototype.ancestors=void 0,vn.prototype.cause=void 0,vn.prototype.fatal=void 0,vn.prototype.place=void 0,vn.prototype.ruleId=void 0,vn.prototype.source=void 0;const bn={}.hasOwnProperty,kn=new Map,wn=/[A-Z]/g,xn=new Set(["table","tbody","thead","tfoot","tr"]),Sn=new Set(["td","th"]),En="https://github.com/syntax-tree/hast-util-to-jsx-runtime";function Cn(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,i){const a=Array.isArray(o.children),s=fn(n);return t(r,o,i,a,{columnNumber:s?s.column-1:void 0,fileName:e,lineNumber:s?s.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,i){const a=Array.isArray(o.children)?n:t;return i?a(r,o,i):a(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?Xt:Gt,stylePropertyNameCase:t.stylePropertyNameCase||"dom",tableCellAlignToStyle:!1!==t.tableCellAlignToStyle},i=Tn(o,e,void 0);return i&&"string"!=typeof i?i:o.create(e,o.Fragment,{children:i||void 0},void 0)}function Tn(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=Xt,e.schema=o);e.ancestors.push(t);const i=_n(e,t.tagName,!1),a=function(e,t){const n={};let r,o;for(o in t.properties)if("children"!==o&&bn.call(t.properties,o)){const i=Ln(e,o,t.properties[o]);if(i){const[o,a]=i;e.tableCellAlignToStyle&&"align"===o&&"string"==typeof a&&Sn.has(t.tagName)?r=a:n[o]=a}}if(r){(n.style||(n.style={}))["css"===e.stylePropertyNameCase?"text-align":"textAlign"]=r}return n}(e,t);let s=Pn(e,t);xn.has(t.tagName)&&(s=s.filter(function(e){return"string"!=typeof e||!("object"==typeof(t=e)?"text"===t.type&&vt(t.value):vt(t));var t}));return Nn(e,a,i,t),On(a,s),e.ancestors.pop(),e.schema=r,e.create(t,i,a,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)}Rn(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=Xt,e.schema=o);e.ancestors.push(t);const i=null===t.name?e.Fragment:_n(e,t.name,!0),a=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];dt(t.type);const o=t.expression;dt(o.type);const i=o.properties[0];dt(i.type),Object.assign(n,e.evaluater.evaluateExpression(i.argument))}else Rn(e,t.position);else{const o=r.name;let i;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];dt(t.type),i=e.evaluater.evaluateExpression(t.expression)}else Rn(e,t.position);else i=null===r.value||r.value;n[o]=i}return n}(e,t),s=Pn(e,t);return Nn(e,a,i,t),On(a,s),e.ancestors.pop(),e.schema=r,e.create(t,i,a,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);Rn(e,t.position)}(e,t):"root"===t.type?function(e,t,n){const r={};return On(r,Pn(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 Nn(e,t,n,r){"string"!=typeof n&&n!==e.Fragment&&e.passNode&&(t.node=r)}function On(e,t){if(t.length>0){const n=t.length>1?t:t[0];n&&(e.children=n)}}function Pn(e,t){const n=[];let r=-1;const o=e.passKeys?new Map:kn;for(;++r<t.children.length;){const i=t.children[r];let a;if(e.passKeys){const e="element"===i.type?i.tagName:"mdxJsxFlowElement"===i.type||"mdxJsxTextElement"===i.type?i.name:void 0;if(e){const t=o.get(e)||0;a=e+"-"+t,o.set(e,t+1)}}const s=Tn(e,i,a);void 0!==s&&n.push(s)}return n}function Ln(e,t,n){const r=function(e,t){const n=wt(t);let r=t,o=xt;if(n in e.normal)return e.property[e.normal[n]];if(n.length>4&&"data"===n.slice(0,4)&&Qt.test(t)){if("-"===t.charAt(4)){const e=t.slice(5).replace(Kt,Yt);r="data"+e.charAt(0).toUpperCase()+e.slice(1)}else{const e=t.slice(4);if(!Kt.test(e)){let n=e.replace(Wt,Jt);"-"!==n.charAt(0)&&(n="-"+n),t="data"+n}}o=At}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){const t={};return(""===e[e.length-1]?[...e,""]:e).join((t.padRight?" ":"")+","+(!1===t.padLeft?"":" ")).trim()}(n):n.join(" ").trim()),"style"===r.property){let t="object"==typeof n?n:function(e,t){try{return cn(t,{reactCompat:!0})}catch(n){if(e.ignoreInvalidStyle)return{};const t=n,r=new vn("Cannot parse `style` attribute",{ancestors:e.ancestors,cause:t,ruleId:"style",source:"hast-util-to-jsx-runtime"});throw r.file=e.filePath||void 0,r.url=En+"#cannot-parse-style-attribute",r}}(e,String(n));return"css"===e.stylePropertyNameCase&&(t=function(e){const t={};let n;for(n in e)bn.call(e,n)&&(t[In(n)]=e[n]);return t}(t)),["style",t]}return["react"===e.elementAttributeNameCase&&r.space?qt[r.property]||r.property:r.attribute,n]}}function _n(e,t,n){let r;if(n)if(t.includes(".")){const e=t.split(".");let n,o=-1;for(;++o<e.length;){const t=mt(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=mt(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 bn.call(e.components,t)?e.components[t]:t}if(e.evaluater)return e.evaluater.evaluateExpression(r);Rn(e)}function Rn(e,t){const n=new vn("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=En+"#cannot-handle-mdx-estrees-without-createevaluater",n}function In(e){let t=e.replace(wn,An);return"ms-"===t.slice(0,3)&&(t="-"+t),t}function An(e){return"-"+e.toLowerCase()}const zn={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"]},jn={};function Dn(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 Fn(e.children,t,n)}return Array.isArray(e)?Fn(e,t,n):""}function Fn(e,t,n){const r=[];let o=-1;for(;++o<e.length;)r[o]=Dn(e[o],t,n);return r.join("")}const Mn=document.createElement("i");function Un(e){const t="&"+e+";";Mn.innerHTML=t;const n=Mn.textContent;return(59!==n.charCodeAt(n.length-1)||"semi"===e)&&(n!==t&&n)}function Bn(e,t,n,r){const o=e.length;let i,a=0;if(t=t<0?-t>o?0:o+t:t>o?o:t,n=n>0?n:0,r.length<1e4)i=Array.from(r),i.unshift(t,n),e.splice(...i);else for(n&&e.splice(t,n);a<r.length;)i=r.slice(a,a+1e4),i.unshift(t,0),e.splice(...i),a+=1e4,t+=1e4}function $n(e,t){return e.length>0?(Bn(e,e.length,0,t),e):t}const Vn={}.hasOwnProperty;function Hn(e,t){let n;for(n in t){const r=(Vn.call(e,n)?e[n]:void 0)||(e[n]={}),o=t[n];let i;if(o)for(i in o){Vn.call(r,i)||(r[i]=[]);const e=o[i];qn(r[i],Array.isArray(e)?e:e?[e]:[])}}}function qn(e,t){let n=-1;const r=[];for(;++n<t.length;)("after"===t[n].add?e:r).push(t[n]);Bn(e,0,0,r)}function Wn(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 Kn(e){return e.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}const Qn=ar(/[A-Za-z]/),Jn=ar(/[\dA-Za-z]/),Yn=ar(/[#-'*+\--9=?A-Z^-~]/);function Gn(e){return null!==e&&(e<32||127===e)}const Xn=ar(/\d/),Zn=ar(/[\dA-Fa-f]/),er=ar(/[!-/:-@[-`{-~]/);function tr(e){return null!==e&&e<-2}function nr(e){return null!==e&&(e<0||32===e)}function rr(e){return-2===e||-1===e||32===e}const or=ar(new RegExp("\\p{P}|\\p{S}","u")),ir=ar(/\s/);function ar(e){return function(t){return null!==t&&t>-1&&e.test(String.fromCharCode(t))}}function sr(e){const t=[];let n=-1,r=0,o=0;for(;++n<e.length;){const i=e.charCodeAt(n);let a="";if(37===i&&Jn(e.charCodeAt(n+1))&&Jn(e.charCodeAt(n+2)))o=2;else if(i<128)/[!#$&-;=?-Z_a-z~]/.test(String.fromCharCode(i))||(a=String.fromCharCode(i));else if(i>55295&&i<57344){const t=e.charCodeAt(n+1);i<56320&&t>56319&&t<57344?(a=String.fromCharCode(i,t),o=1):a="�"}else a=String.fromCharCode(i);a&&(t.push(e.slice(r,n),encodeURIComponent(a)),r=n+o+1,a=""),o&&(n+=o,o=0)}return t.join("")+e.slice(r)}function lr(e,t,n,r){const o=r?r-1:Number.POSITIVE_INFINITY;let i=0;return function(r){if(rr(r))return e.enter(n),a(r);return t(r)};function a(r){return rr(r)&&i++<o?(e.consume(r),a):(e.exit(n),t(r))}}const ur={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"),lr(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)):tr(t)?(e.consume(t),e.exit("chunkText"),r):(e.consume(t),o)}}};const cr={tokenize:function(e){const t=this,n=[];let r,o,i,a=0;return s;function s(r){if(a<n.length){const o=n[a];return t.containerState=o[1],e.attempt(o[0].continuation,l,u)(r)}return u(r)}function l(e){if(a++,t.containerState._closeFlow){t.containerState._closeFlow=void 0,r&&v();const n=t.events.length;let o,i=n;for(;i--;)if("exit"===t.events[i][0]&&"chunkFlow"===t.events[i][1].type){o=t.events[i][1].end;break}y(a);let s=n;for(;s<t.events.length;)t.events[s][1].end={...o},s++;return Bn(t.events,i+1,0,t.events.slice(n)),t.events.length=s,u(e)}return s(e)}function u(o){if(a===n.length){if(!r)return f(o);if(r.currentConstruct&&r.currentConstruct.concrete)return h(o);t.interrupt=Boolean(r.currentConstruct&&!r._gfmTableDynamicInterruptHack)}return t.containerState={},e.check(dr,c,d)(o)}function c(e){return r&&v(),y(a),f(e)}function d(e){return t.parser.lazy[t.now().line]=a!==n.length,i=t.now().offset,h(e)}function f(n){return t.containerState={},e.attempt(dr,p,h)(n)}function p(e){return a++,n.push([t.currentConstruct,t.containerState]),f(e)}function h(n){return null===n?(r&&v(),y(0),void e.consume(n)):(r=r||t.parser.flow(t.now()),e.enter("chunkFlow",{_tokenizer:r,contentType:"flow",previous:o}),g(n))}function g(n){return null===n?(m(e.exit("chunkFlow"),!0),y(0),void e.consume(n)):tr(n)?(e.consume(n),m(e.exit("chunkFlow")),a=0,t.interrupt=void 0,s):(e.consume(n),g)}function m(e,n){const s=t.sliceStream(e);if(n&&s.push(null),e.previous=o,o&&(o.next=e),o=e,r.defineSkip(e.start),r.write(s),t.parser.lazy[e.start.line]){let e=r.events.length;for(;e--;)if(r.events[e][1].start.offset<i&&(!r.events[e][1].end||r.events[e][1].end.offset>i))return;const n=t.events.length;let o,s,l=n;for(;l--;)if("exit"===t.events[l][0]&&"chunkFlow"===t.events[l][1].type){if(o){s=t.events[l][1].end;break}o=!0}for(y(a),e=n;e<t.events.length;)t.events[e][1].end={...s},e++;Bn(t.events,l+1,0,t.events.slice(n)),t.events.length=e}}function y(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 v(){r.write([null]),o=void 0,r=void 0,t.containerState._closeFlow=void 0}}},dr={tokenize:function(e,t,n){return lr(e,e.attempt(this.parser.constructs.document,t,n),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}};function fr(e){return null===e||nr(e)||ir(e)?1:or(e)?2:void 0}function pr(e,t,n){const r=[];let o=-1;for(;++o<e.length;){const i=e[o].resolveAll;i&&!r.includes(i)&&(t=i(t,n),r.push(i))}return t}const hr={name:"attention",resolveAll:function(e,t){let n,r,o,i,a,s,l,u,c=-1;for(;++c<e.length;)if("enter"===e[c][0]&&"attentionSequence"===e[c][1].type&&e[c][1]._close)for(n=c;n--;)if("exit"===e[n][0]&&"attentionSequence"===e[n][1].type&&e[n][1]._open&&t.sliceSerialize(e[n][1]).charCodeAt(0)===t.sliceSerialize(e[c][1]).charCodeAt(0)){if((e[n][1]._close||e[c][1]._open)&&(e[c][1].end.offset-e[c][1].start.offset)%3&&!((e[n][1].end.offset-e[n][1].start.offset+e[c][1].end.offset-e[c][1].start.offset)%3))continue;s=e[n][1].end.offset-e[n][1].start.offset>1&&e[c][1].end.offset-e[c][1].start.offset>1?2:1;const d={...e[n][1].end},f={...e[c][1].start};gr(d,-s),gr(f,s),i={type:s>1?"strongSequence":"emphasisSequence",start:d,end:{...e[n][1].end}},a={type:s>1?"strongSequence":"emphasisSequence",start:{...e[c][1].start},end:f},o={type:s>1?"strongText":"emphasisText",start:{...e[n][1].end},end:{...e[c][1].start}},r={type:s>1?"strong":"emphasis",start:{...i.start},end:{...a.end}},e[n][1].end={...i.start},e[c][1].start={...a.end},l=[],e[n][1].end.offset-e[n][1].start.offset&&(l=$n(l,[["enter",e[n][1],t],["exit",e[n][1],t]])),l=$n(l,[["enter",r,t],["enter",i,t],["exit",i,t],["enter",o,t]]),l=$n(l,pr(t.parser.constructs.insideSpan.null,e.slice(n+1,c),t)),l=$n(l,[["exit",o,t],["enter",a,t],["exit",a,t],["exit",r,t]]),e[c][1].end.offset-e[c][1].start.offset?(u=2,l=$n(l,[["enter",e[c][1],t],["exit",e[c][1],t]])):u=0,Bn(e,n-1,c-n+3,l),c=n+l.length-u-2;break}c=-1;for(;++c<e.length;)"attentionSequence"===e[c][1].type&&(e[c][1].type="data");return e},tokenize:function(e,t){const n=this.parser.constructs.attentionMarkers.null,r=this.previous,o=fr(r);let i;return function(t){return i=t,e.enter("attentionSequence"),a(t)};function a(s){if(s===i)return e.consume(s),a;const l=e.exit("attentionSequence"),u=fr(s),c=!u||2===u&&o||n.includes(s),d=!o||2===o&&u||n.includes(r);return l._open=Boolean(42===i?c:c&&(o||!d)),l._close=Boolean(42===i?d:d&&(u||!c)),t(s)}}};function gr(e,t){e.column+=t,e.offset+=t,e._bufferIndex+=t}const mr={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 Qn(t)?(e.consume(t),i):64===t?n(t):l(t)}function i(e){return 43===e||45===e||46===e||Jn(e)?(r=1,a(e)):l(e)}function a(t){return 58===t?(e.consume(t),r=0,s):(43===t||45===t||46===t||Jn(t))&&r++<32?(e.consume(t),a):(r=0,l(t))}function s(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||Gn(r)?n(r):(e.consume(r),s)}function l(t){return 64===t?(e.consume(t),u):Yn(t)?(e.consume(t),l):n(t)}function u(e){return Jn(e)?c(e):n(e)}function c(n){return 46===n?(e.consume(n),r=0,u):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||Jn(t))&&r++<63){const n=45===t?d:c;return e.consume(t),n}return n(t)}}};const yr={partial:!0,tokenize:function(e,t,n){return function(t){return rr(t)?lr(e,r,"linePrefix")(t):r(t)};function r(e){return null===e||tr(e)?t(e):n(e)}}};const vr={continuation:{tokenize:function(e,t,n){const r=this;return function(t){if(rr(t))return lr(e,o,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(t);return o(t)};function o(r){return e.attempt(vr,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 rr(n)?(e.enter("blockQuotePrefixWhitespace"),e.consume(n),e.exit("blockQuotePrefixWhitespace"),e.exit("blockQuotePrefix"),t):(e.exit("blockQuotePrefix"),t(n))}}};const br={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 er(r)?(e.enter("characterEscapeValue"),e.consume(r),e.exit("characterEscapeValue"),e.exit("characterEscape"),t):n(r)}}};const kr={name:"characterReference",tokenize:function(e,t,n){const r=this;let o,i,a=0;return function(t){return e.enter("characterReference"),e.enter("characterReferenceMarker"),e.consume(t),e.exit("characterReferenceMarker"),s};function s(t){return 35===t?(e.enter("characterReferenceMarkerNumeric"),e.consume(t),e.exit("characterReferenceMarkerNumeric"),l):(e.enter("characterReferenceValue"),o=31,i=Jn,u(t))}function l(t){return 88===t||120===t?(e.enter("characterReferenceMarkerHexadecimal"),e.consume(t),e.exit("characterReferenceMarkerHexadecimal"),e.enter("characterReferenceValue"),o=6,i=Zn,u):(e.enter("characterReferenceValue"),o=7,i=Xn,u(t))}function u(s){if(59===s&&a){const o=e.exit("characterReferenceValue");return i!==Jn||Un(r.sliceSerialize(o))?(e.enter("characterReferenceMarker"),e.consume(s),e.exit("characterReferenceMarker"),e.exit("characterReference"),t):n(s)}return i(s)&&a++<o?(e.consume(s),u):n(s)}}};const wr={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)}}},xr={concrete:!0,name:"codeFenced",tokenize:function(e,t,n){const r=this,o={partial:!0,tokenize:function(e,t,n){let o=0;return a;function a(t){return e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),l}function l(t){return e.enter("codeFencedFence"),rr(t)?lr(e,u,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(t):u(t)}function u(t){return t===i?(e.enter("codeFencedFenceSequence"),c(t)):n(t)}function c(t){return t===i?(o++,e.consume(t),c):o>=s?(e.exit("codeFencedFenceSequence"),rr(t)?lr(e,d,"whitespace")(t):d(t)):n(t)}function d(r){return null===r||tr(r)?(e.exit("codeFencedFence"),t(r)):n(r)}}};let i,a=0,s=0;return function(t){return function(t){const n=r.events[r.events.length-1];return a=n&&"linePrefix"===n[1].type?n[2].sliceSerialize(n[1],!0).length:0,i=t,e.enter("codeFenced"),e.enter("codeFencedFence"),e.enter("codeFencedFenceSequence"),l(t)}(t)};function l(t){return t===i?(s++,e.consume(t),l):s<3?n(t):(e.exit("codeFencedFenceSequence"),rr(t)?lr(e,u,"whitespace")(t):u(t))}function u(n){return null===n||tr(n)?(e.exit("codeFencedFence"),r.interrupt?t(n):e.check(wr,p,v)(n)):(e.enter("codeFencedFenceInfo"),e.enter("chunkString",{contentType:"string"}),c(n))}function c(t){return null===t||tr(t)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),u(t)):rr(t)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),lr(e,d,"whitespace")(t)):96===t&&t===i?n(t):(e.consume(t),c)}function d(t){return null===t||tr(t)?u(t):(e.enter("codeFencedFenceMeta"),e.enter("chunkString",{contentType:"string"}),f(t))}function f(t){return null===t||tr(t)?(e.exit("chunkString"),e.exit("codeFencedFenceMeta"),u(t)):96===t&&t===i?n(t):(e.consume(t),f)}function p(t){return e.attempt(o,v,h)(t)}function h(t){return e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),g}function g(t){return a>0&&rr(t)?lr(e,m,"linePrefix",a+1)(t):m(t)}function m(t){return null===t||tr(t)?e.check(wr,p,v)(t):(e.enter("codeFlowValue"),y(t))}function y(t){return null===t||tr(t)?(e.exit("codeFlowValue"),m(t)):(e.consume(t),y)}function v(n){return e.exit("codeFenced"),t(n)}}};const Sr={name:"codeIndented",tokenize:function(e,t,n){const r=this;return function(t){return e.enter("codeIndented"),lr(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?i(e):n(e)}function i(t){return null===t?s(t):tr(t)?e.attempt(Er,i,s)(t):(e.enter("codeFlowValue"),a(t))}function a(t){return null===t||tr(t)?(e.exit("codeFlowValue"),i(t)):(e.consume(t),a)}function s(n){return e.exit("codeIndented"),t(n)}}},Er={partial:!0,tokenize:function(e,t,n){const r=this;return o;function o(t){return r.parser.lazy[r.now().line]?n(t):tr(t)?(e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),o):lr(e,i,"linePrefix",5)(t)}function i(e){const i=r.events[r.events.length-1];return i&&"linePrefix"===i[1].type&&i[2].sliceSerialize(i[1],!0).length>=4?t(e):tr(e)?o(e):n(e)}}};const Cr={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,i=0;return function(t){return e.enter("codeText"),e.enter("codeTextSequence"),a(t)};function a(t){return 96===t?(e.consume(t),i++,a):(e.exit("codeTextSequence"),s(t))}function s(t){return null===t?n(t):32===t?(e.enter("space"),e.consume(t),e.exit("space"),s):96===t?(o=e.enter("codeTextSequence"),r=0,u(t)):tr(t)?(e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),s):(e.enter("codeTextData"),l(t))}function l(t){return null===t||32===t||96===t||tr(t)?(e.exit("codeTextData"),s(t)):(e.consume(t),l)}function u(n){return 96===n?(e.consume(n),r++,u):r===i?(e.exit("codeTextSequence"),e.exit("codeText"),t(n)):(o.type="codeTextData",l(n))}}};class Tr{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&&Nr(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),Nr(this.left,e)}unshift(e){this.setCursor(0),this.right.push(e)}unshiftMany(e){this.setCursor(0),Nr(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);Nr(this.right,t.reverse())}else{const t=this.right.splice(this.left.length+this.right.length-e,Number.POSITIVE_INFINITY);Nr(this.left,t.reverse())}}}function Nr(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 Or(e){const t={};let n,r,o,i,a,s,l,u=-1;const c=new Tr(e);for(;++u<c.length;){for(;u in t;)u=t[u];if(n=c.get(u),u&&"chunkFlow"===n[1].type&&"listItemPrefix"===c.get(u-1)[1].type&&(s=n[1]._tokenizer.events,o=0,o<s.length&&"lineEndingBlank"===s[o][1].type&&(o+=2),o<s.length&&"content"===s[o][1].type))for(;++o<s.length&&"content"!==s[o][1].type;)"chunkText"===s[o][1].type&&(s[o][1]._isInFirstContentOfListItem=!0,o++);if("enter"===n[0])n[1].contentType&&(Object.assign(t,Pr(c,u)),u=t[u],l=!0);else if(n[1]._container){for(o=u,r=void 0;o--;)if(i=c.get(o),"lineEnding"===i[1].type||"lineEndingBlank"===i[1].type)"enter"===i[0]&&(r&&(c.get(r)[1].type="lineEndingBlank"),i[1].type="lineEnding",r=o);else if("linePrefix"!==i[1].type&&"listItemIndent"!==i[1].type)break;r&&(n[1].end={...c.get(r)[1].start},a=c.slice(r,u),a.unshift(n),c.splice(r,u-r+1,a))}}return Bn(e,0,Number.POSITIVE_INFINITY,c.slice(0)),!l}function Pr(e,t){const n=e.get(t)[1],r=e.get(t)[2];let o=t-1;const i=[];let a=n._tokenizer;a||(a=r.parser[n.contentType](n.start),n._contentTypeTextTrailing&&(a._contentTypeTextTrailing=!0));const s=a.events,l=[],u={};let c,d,f=-1,p=n,h=0,g=0;const m=[g];for(;p;){for(;e.get(++o)[1]!==p;);i.push(o),p._tokenizer||(c=r.sliceStream(p),p.next||c.push(null),d&&a.defineSkip(p.start),p._isInFirstContentOfListItem&&(a._gfmTasklistFirstContentOfListItem=!0),a.write(c),p._isInFirstContentOfListItem&&(a._gfmTasklistFirstContentOfListItem=void 0)),d=p,p=p.next}for(p=n;++f<s.length;)"exit"===s[f][0]&&"enter"===s[f-1][0]&&s[f][1].type===s[f-1][1].type&&s[f][1].start.line!==s[f][1].end.line&&(g=f+1,m.push(g),p._tokenizer=void 0,p.previous=void 0,p=p.next);for(a.events=[],p?(p._tokenizer=void 0,p.previous=void 0):m.pop(),f=m.length;f--;){const t=s.slice(m[f],m[f+1]),n=i.pop();l.push([n,n+t.length-1]),e.splice(n,2,t)}for(l.reverse(),f=-1;++f<l.length;)u[h+l[f][0]]=h+l[f][1],h+=l[f][1]-l[f][0]-1;return u}const Lr={resolve:function(e){return Or(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):tr(t)?e.check(_r,i,o)(t):(e.consume(t),r)}function o(n){return e.exit("chunkContent"),e.exit("content"),t(n)}function i(t){return e.consume(t),e.exit("chunkContent"),n.next=e.enter("chunkContent",{contentType:"content",previous:n}),n=n.next,r}}},_r={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"),lr(e,o,"linePrefix")};function o(o){if(null===o||tr(o))return n(o);const i=r.events[r.events.length-1];return!r.parser.constructs.disable.null.includes("codeIndented")&&i&&"linePrefix"===i[1].type&&i[2].sliceSerialize(i[1],!0).length>=4?t(o):e.interrupt(r.parser.constructs.flow,n,t)(o)}}};function Rr(e,t,n,r,o,i,a,s,l){const u=l||Number.POSITIVE_INFINITY;let c=0;return function(t){if(60===t)return e.enter(r),e.enter(o),e.enter(i),e.consume(t),e.exit(i),d;if(null===t||32===t||41===t||Gn(t))return n(t);return e.enter(r),e.enter(a),e.enter(s),e.enter("chunkString",{contentType:"string"}),h(t)};function d(n){return 62===n?(e.enter(i),e.consume(n),e.exit(i),e.exit(o),e.exit(r),t):(e.enter(s),e.enter("chunkString",{contentType:"string"}),f(n))}function f(t){return 62===t?(e.exit("chunkString"),e.exit(s),d(t)):null===t||60===t||tr(t)?n(t):(e.consume(t),92===t?p:f)}function p(t){return 60===t||62===t||92===t?(e.consume(t),f):f(t)}function h(o){return c||null!==o&&41!==o&&!nr(o)?c<u&&40===o?(e.consume(o),c++,h):41===o?(e.consume(o),c--,h):null===o||32===o||40===o||Gn(o)?n(o):(e.consume(o),92===o?g:h):(e.exit("chunkString"),e.exit(s),e.exit(a),e.exit(r),t(o))}function g(t){return 40===t||41===t||92===t?(e.consume(t),h):h(t)}}function Ir(e,t,n,r,o,i){const a=this;let s,l=0;return function(t){return e.enter(r),e.enter(o),e.consume(t),e.exit(o),e.enter(i),u};function u(d){return l>999||null===d||91===d||93===d&&!s||94===d&&!l&&"_hiddenFootnoteSupport"in a.parser.constructs?n(d):93===d?(e.exit(i),e.enter(o),e.consume(d),e.exit(o),e.exit(r),t):tr(d)?(e.enter("lineEnding"),e.consume(d),e.exit("lineEnding"),u):(e.enter("chunkString",{contentType:"string"}),c(d))}function c(t){return null===t||91===t||93===t||tr(t)||l++>999?(e.exit("chunkString"),u(t)):(e.consume(t),s||(s=!rr(t)),92===t?d:c)}function d(t){return 91===t||92===t||93===t?(e.consume(t),l++,c):c(t)}}function Ar(e,t,n,r,o,i){let a;return function(t){if(34===t||39===t||40===t)return e.enter(r),e.enter(o),e.consume(t),e.exit(o),a=40===t?41:t,s;return n(t)};function s(n){return n===a?(e.enter(o),e.consume(n),e.exit(o),e.exit(r),t):(e.enter(i),l(n))}function l(t){return t===a?(e.exit(i),s(a)):null===t?n(t):tr(t)?(e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),lr(e,l,"linePrefix")):(e.enter("chunkString",{contentType:"string"}),u(t))}function u(t){return t===a||null===t||tr(t)?(e.exit("chunkString"),l(t)):(e.consume(t),92===t?c:u)}function c(t){return t===a||92===t?(e.consume(t),u):u(t)}}function zr(e,t){let n;return function r(o){if(tr(o))return e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),n=!0,r;if(rr(o))return lr(e,r,n?"linePrefix":"lineSuffix")(o);return t(o)}}const jr={name:"definition",tokenize:function(e,t,n){const r=this;let o;return function(t){return e.enter("definition"),function(t){return Ir.call(r,e,i,n,"definitionLabel","definitionLabelMarker","definitionLabelString")(t)}(t)};function i(t){return o=Kn(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)),58===t?(e.enter("definitionMarker"),e.consume(t),e.exit("definitionMarker"),a):n(t)}function a(t){return nr(t)?zr(e,s)(t):s(t)}function s(t){return Rr(e,l,n,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(t)}function l(t){return e.attempt(Dr,u,u)(t)}function u(t){return rr(t)?lr(e,c,"whitespace")(t):c(t)}function c(i){return null===i||tr(i)?(e.exit("definition"),r.parser.defined.push(o),t(i)):n(i)}}},Dr={partial:!0,tokenize:function(e,t,n){return function(t){return nr(t)?zr(e,r)(t):n(t)};function r(t){return Ar(e,o,n,"definitionTitle","definitionTitleMarker","definitionTitleString")(t)}function o(t){return rr(t)?lr(e,i,"whitespace")(t):i(t)}function i(e){return null===e||tr(e)?t(e):n(e)}}};const Fr={name:"hardBreakEscape",tokenize:function(e,t,n){return function(t){return e.enter("hardBreakEscape"),e.consume(t),r};function r(r){return tr(r)?(e.exit("hardBreakEscape"),t(r)):n(r)}}};const Mr={name:"headingAtx",resolve:function(e,t){let n,r,o=e.length-2,i=3;"whitespace"===e[i][1].type&&(i+=2);o-2>i&&"whitespace"===e[o][1].type&&(o-=2);"atxHeadingSequence"===e[o][1].type&&(i===o-1||o-4>i&&"whitespace"===e[o-2][1].type)&&(o-=i+1===o?2:4);o>i&&(n={type:"atxHeadingText",start:e[i][1].start,end:e[o][1].end},r={type:"chunkText",start:e[i][1].start,end:e[o][1].end,contentType:"text"},Bn(e,i,o-i+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||nr(t)?(e.exit("atxHeadingSequence"),i(t)):n(t)}function i(n){return 35===n?(e.enter("atxHeadingSequence"),a(n)):null===n||tr(n)?(e.exit("atxHeading"),t(n)):rr(n)?lr(e,i,"whitespace")(n):(e.enter("atxHeadingText"),s(n))}function a(t){return 35===t?(e.consume(t),a):(e.exit("atxHeadingSequence"),i(t))}function s(t){return null===t||35===t||nr(t)?(e.exit("atxHeadingText"),i(t)):(e.consume(t),s)}}};const Ur=["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"],Br=["pre","script","style","textarea"],$r={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,i,a,s,l;return function(t){return function(t){return e.enter("htmlFlow"),e.enter("htmlFlowData"),e.consume(t),u}(t)};function u(s){return 33===s?(e.consume(s),c):47===s?(e.consume(s),i=!0,p):63===s?(e.consume(s),o=3,r.interrupt?t:A):Qn(s)?(e.consume(s),a=String.fromCharCode(s),h):n(s)}function c(i){return 45===i?(e.consume(i),o=2,d):91===i?(e.consume(i),o=5,s=0,f):Qn(i)?(e.consume(i),o=4,r.interrupt?t:A):n(i)}function d(o){return 45===o?(e.consume(o),r.interrupt?t:A):n(o)}function f(o){const i="CDATA[";return o===i.charCodeAt(s++)?(e.consume(o),6===s?r.interrupt?t:T:f):n(o)}function p(t){return Qn(t)?(e.consume(t),a=String.fromCharCode(t),h):n(t)}function h(s){if(null===s||47===s||62===s||nr(s)){const l=47===s,u=a.toLowerCase();return l||i||!Br.includes(u)?Ur.includes(a.toLowerCase())?(o=6,l?(e.consume(s),g):r.interrupt?t(s):T(s)):(o=7,r.interrupt&&!r.parser.lazy[r.now().line]?n(s):i?m(s):y(s)):(o=1,r.interrupt?t(s):T(s))}return 45===s||Jn(s)?(e.consume(s),a+=String.fromCharCode(s),h):n(s)}function g(o){return 62===o?(e.consume(o),r.interrupt?t:T):n(o)}function m(t){return rr(t)?(e.consume(t),m):E(t)}function y(t){return 47===t?(e.consume(t),E):58===t||95===t||Qn(t)?(e.consume(t),v):rr(t)?(e.consume(t),y):E(t)}function v(t){return 45===t||46===t||58===t||95===t||Jn(t)?(e.consume(t),v):b(t)}function b(t){return 61===t?(e.consume(t),k):rr(t)?(e.consume(t),b):y(t)}function k(t){return null===t||60===t||61===t||62===t||96===t?n(t):34===t||39===t?(e.consume(t),l=t,w):rr(t)?(e.consume(t),k):x(t)}function w(t){return t===l?(e.consume(t),l=null,S):null===t||tr(t)?n(t):(e.consume(t),w)}function x(t){return null===t||34===t||39===t||47===t||60===t||61===t||62===t||96===t||nr(t)?b(t):(e.consume(t),x)}function S(e){return 47===e||62===e||rr(e)?y(e):n(e)}function E(t){return 62===t?(e.consume(t),C):n(t)}function C(t){return null===t||tr(t)?T(t):rr(t)?(e.consume(t),C):n(t)}function T(t){return 45===t&&2===o?(e.consume(t),L):60===t&&1===o?(e.consume(t),_):62===t&&4===o?(e.consume(t),z):63===t&&3===o?(e.consume(t),A):93===t&&5===o?(e.consume(t),I):!tr(t)||6!==o&&7!==o?null===t||tr(t)?(e.exit("htmlFlowData"),N(t)):(e.consume(t),T):(e.exit("htmlFlowData"),e.check(Vr,j,N)(t))}function N(t){return e.check(Hr,O,j)(t)}function O(t){return e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),P}function P(t){return null===t||tr(t)?N(t):(e.enter("htmlFlowData"),T(t))}function L(t){return 45===t?(e.consume(t),A):T(t)}function _(t){return 47===t?(e.consume(t),a="",R):T(t)}function R(t){if(62===t){const n=a.toLowerCase();return Br.includes(n)?(e.consume(t),z):T(t)}return Qn(t)&&a.length<8?(e.consume(t),a+=String.fromCharCode(t),R):T(t)}function I(t){return 93===t?(e.consume(t),A):T(t)}function A(t){return 62===t?(e.consume(t),z):45===t&&2===o?(e.consume(t),A):T(t)}function z(t){return null===t||tr(t)?(e.exit("htmlFlowData"),j(t)):(e.consume(t),z)}function j(n){return e.exit("htmlFlow"),t(n)}}},Vr={partial:!0,tokenize:function(e,t,n){return function(r){return e.enter("lineEnding"),e.consume(r),e.exit("lineEnding"),e.attempt(yr,t,n)}}},Hr={partial:!0,tokenize:function(e,t,n){const r=this;return function(t){if(tr(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 qr={name:"htmlText",tokenize:function(e,t,n){const r=this;let o,i,a;return function(t){return e.enter("htmlText"),e.enter("htmlTextData"),e.consume(t),s};function s(t){return 33===t?(e.consume(t),l):47===t?(e.consume(t),k):63===t?(e.consume(t),v):Qn(t)?(e.consume(t),S):n(t)}function l(t){return 45===t?(e.consume(t),u):91===t?(e.consume(t),i=0,p):Qn(t)?(e.consume(t),y):n(t)}function u(t){return 45===t?(e.consume(t),f):n(t)}function c(t){return null===t?n(t):45===t?(e.consume(t),d):tr(t)?(a=c,R(t)):(e.consume(t),c)}function d(t){return 45===t?(e.consume(t),f):c(t)}function f(e){return 62===e?_(e):45===e?d(e):c(e)}function p(t){const r="CDATA[";return t===r.charCodeAt(i++)?(e.consume(t),6===i?h:p):n(t)}function h(t){return null===t?n(t):93===t?(e.consume(t),g):tr(t)?(a=h,R(t)):(e.consume(t),h)}function g(t){return 93===t?(e.consume(t),m):h(t)}function m(t){return 62===t?_(t):93===t?(e.consume(t),m):h(t)}function y(t){return null===t||62===t?_(t):tr(t)?(a=y,R(t)):(e.consume(t),y)}function v(t){return null===t?n(t):63===t?(e.consume(t),b):tr(t)?(a=v,R(t)):(e.consume(t),v)}function b(e){return 62===e?_(e):v(e)}function k(t){return Qn(t)?(e.consume(t),w):n(t)}function w(t){return 45===t||Jn(t)?(e.consume(t),w):x(t)}function x(t){return tr(t)?(a=x,R(t)):rr(t)?(e.consume(t),x):_(t)}function S(t){return 45===t||Jn(t)?(e.consume(t),S):47===t||62===t||nr(t)?E(t):n(t)}function E(t){return 47===t?(e.consume(t),_):58===t||95===t||Qn(t)?(e.consume(t),C):tr(t)?(a=E,R(t)):rr(t)?(e.consume(t),E):_(t)}function C(t){return 45===t||46===t||58===t||95===t||Jn(t)?(e.consume(t),C):T(t)}function T(t){return 61===t?(e.consume(t),N):tr(t)?(a=T,R(t)):rr(t)?(e.consume(t),T):E(t)}function N(t){return null===t||60===t||61===t||62===t||96===t?n(t):34===t||39===t?(e.consume(t),o=t,O):tr(t)?(a=N,R(t)):rr(t)?(e.consume(t),N):(e.consume(t),P)}function O(t){return t===o?(e.consume(t),o=void 0,L):null===t?n(t):tr(t)?(a=O,R(t)):(e.consume(t),O)}function P(t){return null===t||34===t||39===t||60===t||61===t||96===t?n(t):47===t||62===t||nr(t)?E(t):(e.consume(t),P)}function L(e){return 47===e||62===e||nr(e)?E(e):n(e)}function _(r){return 62===r?(e.consume(r),e.exit("htmlTextData"),e.exit("htmlText"),t):n(r)}function R(t){return e.exit("htmlTextData"),e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),I}function I(t){return rr(t)?lr(e,A,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(t):A(t)}function A(t){return e.enter("htmlTextData"),a(t)}}};const Wr={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&&Bn(e,0,e.length,n);return e},resolveTo:function(e,t){let n,r,o,i,a=e.length,s=0;for(;a--;)if(n=e[a][1],r){if("link"===n.type||"labelLink"===n.type&&n._inactive)break;"enter"===e[a][0]&&"labelLink"===n.type&&(n._inactive=!0)}else if(o){if("enter"===e[a][0]&&("labelImage"===n.type||"labelLink"===n.type)&&!n._balanced&&(r=a,"labelLink"!==n.type)){s=2;break}}else"labelEnd"===n.type&&(o=a);const l={type:"labelLink"===e[r][1].type?"link":"image",start:{...e[r][1].start},end:{...e[e.length-1][1].end}},u={type:"label",start:{...e[r][1].start},end:{...e[o][1].end}},c={type:"labelText",start:{...e[r+s+2][1].end},end:{...e[o-2][1].start}};return i=[["enter",l,t],["enter",u,t]],i=$n(i,e.slice(r+1,r+s+3)),i=$n(i,[["enter",c,t]]),i=$n(i,pr(t.parser.constructs.insideSpan.null,e.slice(r+s+4,o-3),t)),i=$n(i,[["exit",c,t],e[o-2],e[o-1],["exit",u,t]]),i=$n(i,e.slice(o+1)),i=$n(i,[["exit",l,t]]),Bn(e,r,e.length,i),e},tokenize:function(e,t,n){const r=this;let o,i,a=r.events.length;for(;a--;)if(("labelImage"===r.events[a][1].type||"labelLink"===r.events[a][1].type)&&!r.events[a][1]._balanced){o=r.events[a][1];break}return function(t){if(!o)return n(t);if(o._inactive)return c(t);return i=r.parser.defined.includes(Kn(r.sliceSerialize({start:o.end,end:r.now()}))),e.enter("labelEnd"),e.enter("labelMarker"),e.consume(t),e.exit("labelMarker"),e.exit("labelEnd"),s};function s(t){return 40===t?e.attempt(Kr,u,i?u:c)(t):91===t?e.attempt(Qr,u,i?l:c)(t):i?u(t):c(t)}function l(t){return e.attempt(Jr,u,c)(t)}function u(e){return t(e)}function c(e){return o._balanced=!0,n(e)}}},Kr={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 nr(t)?zr(e,o)(t):o(t)}function o(t){return 41===t?u(t):Rr(e,i,a,"resourceDestination","resourceDestinationLiteral","resourceDestinationLiteralMarker","resourceDestinationRaw","resourceDestinationString",32)(t)}function i(t){return nr(t)?zr(e,s)(t):u(t)}function a(e){return n(e)}function s(t){return 34===t||39===t||40===t?Ar(e,l,n,"resourceTitle","resourceTitleMarker","resourceTitleString")(t):u(t)}function l(t){return nr(t)?zr(e,u)(t):u(t)}function u(r){return 41===r?(e.enter("resourceMarker"),e.consume(r),e.exit("resourceMarker"),e.exit("resource"),t):n(r)}}},Qr={tokenize:function(e,t,n){const r=this;return function(t){return Ir.call(r,e,o,i,"reference","referenceMarker","referenceString")(t)};function o(e){return r.parser.defined.includes(Kn(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)))?t(e):n(e)}function i(e){return n(e)}}},Jr={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 Yr={name:"labelStartImage",resolveAll:Wr.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"),i):n(t)}function i(e){return 94===e&&"_hiddenFootnoteSupport"in r.parser.constructs?n(e):t(e)}}};const Gr={name:"labelStartLink",resolveAll:Wr.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 Xr={name:"lineEnding",tokenize:function(e,t){return function(n){return e.enter("lineEnding"),e.consume(n),e.exit("lineEnding"),lr(e,t,"linePrefix")}}};const Zr={name:"thematicBreak",tokenize:function(e,t,n){let r,o=0;return function(t){return e.enter("thematicBreak"),function(e){return r=e,i(e)}(t)};function i(i){return i===r?(e.enter("thematicBreakSequence"),a(i)):o>=3&&(null===i||tr(i))?(e.exit("thematicBreak"),t(i)):n(i)}function a(t){return t===r?(e.consume(t),o++,a):(e.exit("thematicBreakSequence"),rr(t)?lr(e,i,"whitespace")(t):i(t))}}};const eo={continuation:{tokenize:function(e,t,n){const r=this;return r.containerState._closeFlow=void 0,e.check(yr,function(n){return r.containerState.furtherBlankLines=r.containerState.furtherBlankLines||r.containerState.initialBlankLine,lr(e,t,"listItemIndent",r.containerState.size+1)(n)},function(n){if(r.containerState.furtherBlankLines||!rr(n))return r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,o(n);return r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,e.attempt(no,t,o)(n)});function o(o){return r.containerState._closeFlow=!0,r.interrupt=void 0,lr(e,e.attempt(eo,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 i=o&&"linePrefix"===o[1].type?o[2].sliceSerialize(o[1],!0).length:0,a=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:Xn(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(Zr,n,l)(t):l(t);if(!r.interrupt||49===t)return e.enter("listItemPrefix"),e.enter("listItemValue"),s(t)}return n(t)};function s(t){return Xn(t)&&++a<10?(e.consume(t),s):(!r.interrupt||a<2)&&(r.containerState.marker?t===r.containerState.marker:41===t||46===t)?(e.exit("listItemValue"),l(t)):n(t)}function l(t){return e.enter("listItemMarker"),e.consume(t),e.exit("listItemMarker"),r.containerState.marker=r.containerState.marker||t,e.check(yr,r.interrupt?n:u,e.attempt(to,d,c))}function u(e){return r.containerState.initialBlankLine=!0,i++,d(e)}function c(t){return rr(t)?(e.enter("listItemPrefixWhitespace"),e.consume(t),e.exit("listItemPrefixWhitespace"),d):n(t)}function d(n){return r.containerState.size=i+r.sliceSerialize(e.exit("listItemPrefix"),!0).length,t(n)}}},to={partial:!0,tokenize:function(e,t,n){const r=this;return lr(e,function(e){const o=r.events[r.events.length-1];return!rr(e)&&o&&"listItemPrefixWhitespace"===o[1].type?t(e):n(e)},"listItemPrefixWhitespace",r.parser.constructs.disable.null.includes("codeIndented")?void 0:5)}},no={partial:!0,tokenize:function(e,t,n){const r=this;return lr(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 ro={name:"setextUnderline",resolveTo:function(e,t){let n,r,o,i=e.length;for(;i--;)if("enter"===e[i][0]){if("content"===e[i][1].type){n=i;break}"paragraph"===e[i][1].type&&(r=i)}else"content"===e[i][1].type&&e.splice(i,1),o||"definition"!==e[i][1].type||(o=i);const a={type:"setextHeading",start:{...e[n][1].start},end:{...e[e.length-1][1].end}};e[r][1].type="setextHeadingText",o?(e.splice(r,0,["enter",a,t]),e.splice(o+1,0,["exit",e[n][1],t]),e[n][1].end={...e[o][1].end}):e[n][1]=a;return e.push(["exit",a,t]),e},tokenize:function(e,t,n){const r=this;let o;return function(t){let a,s=r.events.length;for(;s--;)if("lineEnding"!==r.events[s][1].type&&"linePrefix"!==r.events[s][1].type&&"content"!==r.events[s][1].type){a="paragraph"===r.events[s][1].type;break}if(!r.parser.lazy[r.now().line]&&(r.interrupt||a))return e.enter("setextHeadingLine"),o=t,function(t){return e.enter("setextHeadingLineSequence"),i(t)}(t);return n(t)};function i(t){return t===o?(e.consume(t),i):(e.exit("setextHeadingLineSequence"),rr(t)?lr(e,a,"lineSuffix")(t):a(t))}function a(r){return null===r||tr(r)?(e.exit("setextHeadingLine"),t(r)):n(r)}}};const oo={tokenize:function(e){const t=this,n=e.attempt(yr,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,lr(e,e.attempt(this.parser.constructs.flow,r,e.attempt(Lr,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 io={resolveAll:uo()},ao=lo("string"),so=lo("text");function lo(e){return{resolveAll:uo("text"===e?co:void 0),tokenize:function(t){const n=this,r=this.parser.constructs[e],o=t.attempt(r,i,a);return i;function i(e){return l(e)?o(e):a(e)}function a(e){if(null!==e)return t.enter("data"),t.consume(e),s;t.consume(e)}function s(e){return l(e)?(t.exit("data"),o(e)):(t.consume(e),s)}function l(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 uo(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 co(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 i,a=o.length,s=-1,l=0;for(;a--;){const e=o[a];if("string"==typeof e){for(s=e.length;32===e.charCodeAt(s-1);)l++,s--;if(s)break;s=-1}else if(-2===e)i=!0,l++;else if(-1!==e){a++;break}}if(t._contentTypeTextTrailing&&n===e.length&&(l=0),l){const o={type:n===e.length||i||l<2?"lineSuffix":"hardBreakTrailing",start:{_bufferIndex:a?s:r.start._bufferIndex+s,_index:r.start._index+a,line:r.end.line,column:r.end.column-l,offset:r.end.offset-l},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 fo={42:eo,43:eo,45:eo,48:eo,49:eo,50:eo,51:eo,52:eo,53:eo,54:eo,55:eo,56:eo,57:eo,62:vr},po={91:jr},ho={[-2]:Sr,[-1]:Sr,32:Sr},go={35:Mr,42:Zr,45:[ro,Zr],60:$r,61:ro,95:Zr,96:xr,126:xr},mo={38:kr,92:br},yo={[-5]:Xr,[-4]:Xr,[-3]:Xr,33:Yr,38:kr,42:hr,60:[mr,qr],91:Gr,92:[Fr,br],93:Wr,95:hr,96:Cr},vo={null:[hr,io]},bo=Object.freeze(Object.defineProperty({__proto__:null,attentionMarkers:{null:[42,95]},contentInitial:po,disable:{null:[]},document:fo,flow:go,flowInitial:ho,insideSpan:vo,string:mo,text:yo},Symbol.toStringTag,{value:"Module"}));function ko(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={},i=[];let a=[],s=[];const l={attempt:m(function(e,t){y(e,t.from)}),check:m(g),consume:function(e){tr(e)?(r.line++,r.column=1,r.offset+=-3===e?2:1,v()):-1!==e&&(r.column++,r.offset++);r._bufferIndex<0?r._index++:(r._bufferIndex++,r._bufferIndex===a[r._index].length&&(r._bufferIndex=-1,r._index++));u.previous=e},enter:function(e,t){const n=t||{};return n.type=e,n.start=f(),u.events.push(["enter",n,u]),s.push(n),n},exit:function(e){const t=s.pop();return t.end=f(),u.events.push(["exit",t,u]),t},interrupt:m(g,{interrupt:!0})},u={code:null,containerState:{},defineSkip:function(e){o[e.line]=e.column,v()},events:[],now:f,parser:e,previous:null,sliceSerialize:function(e,t){return function(e,t){let n=-1;const r=[];let o;for(;++n<e.length;){const i=e[n];let a;if("string"==typeof i)a=i;else switch(i){case-5:a="\r";break;case-4:a="\n";break;case-3:a="\r\n";break;case-2:a=t?" ":"\t";break;case-1:if(!t&&o)continue;a=" ";break;default:a=String.fromCharCode(i)}o=-2===i,r.push(a)}return r.join("")}(d(e),t)},sliceStream:d,write:function(e){if(a=$n(a,e),p(),null!==a[a.length-1])return[];return y(t,0),u.events=pr(i,u.events,u),u.events}};let c=t.tokenize.call(u,l);return t.resolveAll&&i.push(t),u;function d(e){return function(e,t){const n=t.start._index,r=t.start._bufferIndex,o=t.end._index,i=t.end._bufferIndex;let a;if(n===o)a=[e[n].slice(r,i)];else{if(a=e.slice(n,o),r>-1){const e=a[0];"string"==typeof e?a[0]=e.slice(r):a.shift()}i>0&&a.push(e[o].slice(0,i))}return a}(a,e)}function f(){const{_bufferIndex:e,_index:t,line:n,column:o,offset:i}=r;return{_bufferIndex:e,_index:t,line:n,column:o,offset:i}}function p(){let e;for(;r._index<a.length;){const t=a[r._index];if("string"==typeof t)for(e=r._index,r._bufferIndex<0&&(r._bufferIndex=0);r._index===e&&r._bufferIndex<t.length;)h(t.charCodeAt(r._bufferIndex));else h(t)}}function h(e){c=c(e)}function g(e,t){t.restore()}function m(e,t){return function(n,o,i){let a,c,d,p;return Array.isArray(n)?h(n):"tokenize"in n?h([n]):function(e){return t;function t(t){const n=null!==t&&e[t],r=null!==t&&e.null;return h([...Array.isArray(n)?n:n?[n]:[],...Array.isArray(r)?r:r?[r]:[]])(t)}}(n);function h(e){return a=e,c=0,0===e.length?i:g(e[c])}function g(e){return function(n){p=function(){const e=f(),t=u.previous,n=u.currentConstruct,o=u.events.length,i=Array.from(s);return{from:o,restore:a};function a(){r=e,u.previous=t,u.currentConstruct=n,u.events.length=o,s=i,v()}}(),d=e,e.partial||(u.currentConstruct=e);if(e.name&&u.parser.constructs.disable.null.includes(e.name))return y();return e.tokenize.call(t?Object.assign(Object.create(u),t):u,l,m,y)(n)}}function m(t){return e(d,p),o}function y(e){return p.restore(),++c<a.length?g(a[c]):i}}}function y(e,t){e.resolveAll&&!i.includes(e)&&i.push(e),e.resolve&&Bn(u.events,t,u.events.length-t,e.resolve(u.events.slice(t),u)),e.resolveTo&&(u.events=e.resolveTo(u.events,u))}function v(){r.line in o&&r.column<2&&(r.column=o[r.line],r.offset+=o[r.line]-1)}}function wo(e){const t={constructs:function(e){const t={};let n=-1;for(;++n<e.length;)Hn(t,e[n]);return t}([bo,...(e||{}).extensions||[]]),content:n(ur),defined:[],document:n(cr),flow:n(oo),lazy:{},string:n(ao),text:n(so)};return t;function n(e){return function(n){return ko(t,e,n)}}}const xo=/[\0\t\n\r]/g;const So=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function Eo(e,t,n){if(t)return t;if(35===n.charCodeAt(0)){const e=n.charCodeAt(1),t=120===e||88===e;return Wn(n.slice(t?2:1),t?16:10)}return Un(n)||e}const Co={}.hasOwnProperty;function To(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:i(te),autolinkProtocol:C,autolinkEmail:C,atxHeading:i(G),blockQuote:i(W),characterEscape:C,characterReference:C,codeFenced:i(K),codeFencedFenceInfo:a,codeFencedFenceMeta:a,codeIndented:i(K,a),codeText:i(Q,a),codeTextData:C,data:C,codeFlowValue:C,definition:i(J),definitionDestinationString:a,definitionLabelString:a,definitionTitleString:a,emphasis:i(Y),hardBreakEscape:i(X),hardBreakTrailing:i(X),htmlFlow:i(Z,a),htmlFlowData:C,htmlText:i(Z,a),htmlTextData:C,image:i(ee),label:a,link:i(te),listItem:i(re),listItemValue:f,listOrdered:i(ne,d),listUnordered:i(ne),paragraph:i(oe),reference:M,referenceString:a,resourceDestinationString:a,resourceTitleString:a,setextHeading:i(G),strong:i(ie),thematicBreak:i(se)},exit:{atxHeading:l(),atxHeadingSequence:w,autolink:l(),autolinkEmail:q,autolinkProtocol:H,blockQuote:l(),characterEscapeValue:T,characterReferenceMarkerHexadecimal:B,characterReferenceMarkerNumeric:B,characterReferenceValue:$,characterReference:V,codeFenced:l(m),codeFencedFence:g,codeFencedFenceInfo:p,codeFencedFenceMeta:h,codeFlowValue:T,codeIndented:l(y),codeText:l(_),codeTextData:T,data:T,definition:l(),definitionDestinationString:k,definitionLabelString:v,definitionTitleString:b,emphasis:l(),hardBreakEscape:l(O),hardBreakTrailing:l(O),htmlFlow:l(P),htmlFlowData:T,htmlText:l(L),htmlTextData:T,image:l(I),label:z,labelText:A,lineEnding:N,link:l(R),listItem:l(),listOrdered:l(),listUnordered:l(),paragraph:l(),referenceString:U,resourceDestinationString:j,resourceTitleString:D,resource:F,setextHeading:l(E),setextHeadingLineSequence:S,setextHeadingText:x,strong:l(),thematicBreak:l()}};Oo(t,(e||{}).mdastExtensions||[]);const n={};return r;function r(e){let r={type:"root",children:[]};const i={stack:[r],tokenStack:[],config:t,enter:s,exit:u,buffer:a,resume:c,data:n},l=[];let d=-1;for(;++d<e.length;)if("listOrdered"===e[d][1].type||"listUnordered"===e[d][1].type)if("enter"===e[d][0])l.push(d);else{d=o(e,l.pop(),d)}for(d=-1;++d<e.length;){const n=t[e[d][0]];Co.call(n,e[d][1].type)&&n[e[d][1].type].call(Object.assign({sliceSerialize:e[d][2].sliceSerialize},i),e[d][1])}if(i.tokenStack.length>0){const e=i.tokenStack[i.tokenStack.length-1];(e[1]||Lo).call(i,void 0,e[0])}for(r.position={start:No(e.length>0?e[0][1].start:{line:1,column:1,offset:0}),end:No(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,i,a,s=t-1,l=-1,u=!1;for(;++s<=n;){const t=e[s];switch(t[1].type){case"listUnordered":case"listOrdered":case"blockQuote":"enter"===t[0]?l++:l--,a=void 0;break;case"lineEndingBlank":"enter"===t[0]&&(!r||a||l||i||(i=s),a=void 0);break;case"linePrefix":case"listItemValue":case"listItemMarker":case"listItemPrefix":case"listItemPrefixWhitespace":break;default:a=void 0}if(!l&&"enter"===t[0]&&"listItemPrefix"===t[1].type||-1===l&&"exit"===t[0]&&("listUnordered"===t[1].type||"listOrdered"===t[1].type)){if(r){let a=s;for(o=void 0;a--;){const t=e[a];if("lineEnding"===t[1].type||"lineEndingBlank"===t[1].type){if("exit"===t[0])continue;o&&(e[o][1].type="lineEndingBlank",u=!0),t[1].type="lineEnding",o=a}else if("linePrefix"!==t[1].type&&"blockQuotePrefix"!==t[1].type&&"blockQuotePrefixWhitespace"!==t[1].type&&"blockQuoteMarker"!==t[1].type&&"listItemIndent"!==t[1].type)break}i&&(!o||i<o)&&(r._spread=!0),r.end=Object.assign({},o?e[o][1].start:t[1].end),e.splice(o||s,0,["exit",r,t[2]]),s++,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(s,0,["enter",o,t[2]]),s++,n++,i=void 0,a=!0}}}return e[t][1]._spread=u,n}function i(e,t){return n;function n(n){s.call(this,e(n),n),t&&t.call(this,n)}}function a(){this.stack.push({type:"fragment",children:[]})}function s(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:No(t.start),end:void 0}}function l(e){return t;function t(t){e&&e.call(this,t),u.call(this,t)}}function u(e,t){const n=this.stack.pop(),r=this.tokenStack.pop();if(!r)throw new Error("Cannot close `"+e.type+"` ("+hn({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]||Lo).call(this,e,r[0])}n.position.end=No(e.end)}function c(){return function(e){return Dn(e,"boolean"!=typeof jn.includeImageAlt||jn.includeImageAlt,"boolean"!=typeof jn.includeHtml||jn.includeHtml)}(this.stack.pop())}function d(){this.data.expectingFirstListItemValue=!0}function f(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 h(){const e=this.resume();this.stack[this.stack.length-1].meta=e}function g(){this.data.flowCodeInside||(this.buffer(),this.data.flowCodeInside=!0)}function m(){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 y(){const e=this.resume();this.stack[this.stack.length-1].value=e.replace(/(\r?\n|\r)$/g,"")}function v(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.label=t,n.identifier=Kn(this.sliceSerialize(e)).toLowerCase()}function b(){const e=this.resume();this.stack[this.stack.length-1].title=e}function k(){const e=this.resume();this.stack[this.stack.length-1].url=e}function w(e){const t=this.stack[this.stack.length-1];if(!t.depth){const n=this.sliceSerialize(e).length;t.depth=n}}function x(){this.data.setextHeadingSlurpLineEnding=!0}function S(e){this.stack[this.stack.length-1].depth=61===this.sliceSerialize(e).codePointAt(0)?1:2}function E(){this.data.setextHeadingSlurpLineEnding=void 0}function C(e){const t=this.stack[this.stack.length-1].children;let n=t[t.length-1];n&&"text"===n.type||(n=ae(),n.position={start:No(e.start),end:void 0},t.push(n)),this.stack.push(n)}function T(e){const t=this.stack.pop();t.value+=this.sliceSerialize(e),t.position.end=No(e.end)}function N(e){const n=this.stack[this.stack.length-1];if(this.data.atHardBreak){return n.children[n.children.length-1].position.end=No(e.end),void(this.data.atHardBreak=void 0)}!this.data.setextHeadingSlurpLineEnding&&t.canContainEols.includes(n.type)&&(C.call(this,e),T.call(this,e))}function O(){this.data.atHardBreak=!0}function P(){const e=this.resume();this.stack[this.stack.length-1].value=e}function L(){const e=this.resume();this.stack[this.stack.length-1].value=e}function _(){const e=this.resume();this.stack[this.stack.length-1].value=e}function R(){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 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 A(e){const t=this.sliceSerialize(e),n=this.stack[this.stack.length-2];n.label=function(e){return e.replace(So,Eo)}(t),n.identifier=Kn(t).toLowerCase()}function z(){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 j(){const e=this.resume();this.stack[this.stack.length-1].url=e}function D(){const e=this.resume();this.stack[this.stack.length-1].title=e}function F(){this.data.inReference=void 0}function M(){this.data.referenceType="collapsed"}function U(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.label=t,n.identifier=Kn(this.sliceSerialize(e)).toLowerCase(),this.data.referenceType="full"}function B(e){this.data.characterReferenceType=e.type}function $(e){const t=this.sliceSerialize(e),n=this.data.characterReferenceType;let r;if(n)r=Wn(t,"characterReferenceMarkerNumeric"===n?10:16),this.data.characterReferenceType=void 0;else{r=Un(t)}this.stack[this.stack.length-1].value+=r}function V(e){this.stack.pop().position.end=No(e.end)}function H(e){T.call(this,e);this.stack[this.stack.length-1].url=this.sliceSerialize(e)}function q(e){T.call(this,e);this.stack[this.stack.length-1].url="mailto:"+this.sliceSerialize(e)}function W(){return{type:"blockquote",children:[]}}function K(){return{type:"code",lang:null,meta:null,value:""}}function Q(){return{type:"inlineCode",value:""}}function J(){return{type:"definition",identifier:"",label:null,title:null,url:""}}function Y(){return{type:"emphasis",children:[]}}function G(){return{type:"heading",depth:0,children:[]}}function X(){return{type:"break"}}function Z(){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 ie(){return{type:"strong",children:[]}}function ae(){return{type:"text",value:""}}function se(){return{type:"thematicBreak"}}}(n)(function(e){for(;!Or(e););return e}(wo(n).document().write(function(){let e,t=1,n="",r=!0;return function(o,i,a){const s=[];let l,u,c,d,f;for(o=n+("string"==typeof o?o.toString():new TextDecoder(i||void 0).decode(o)),c=0,n="",r&&(65279===o.charCodeAt(0)&&c++,r=void 0);c<o.length;){if(xo.lastIndex=c,l=xo.exec(o),d=l&&void 0!==l.index?l.index:o.length,f=o.charCodeAt(d),!l){n=o.slice(c);break}if(10===f&&c===d&&e)s.push(-3),e=void 0;else switch(e&&(s.push(-5),e=void 0),c<d&&(s.push(o.slice(c,d)),t+=d-c),f){case 0:s.push(65533),t++;break;case 9:for(u=4*Math.ceil(t/4),s.push(-2);t++<u;)s.push(-1);break;case 10:s.push(-4),t=1;break;default:e=!0,t=1}c=d+1}return a&&(e&&s.push(-5),n&&s.push(n),s.push(null)),s}}()(e,t,!0))))}function No(e){return{line:e.line,column:e.column,offset:e.offset}}function Oo(e,t){let n=-1;for(;++n<t.length;){const r=t[n];Array.isArray(r)?Oo(e,r):Po(e,r)}}function Po(e,t){let n;for(n in t)if(Co.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 Lo(e,t){throw e?new Error("Cannot close `"+e.type+"` ("+hn({start:e.start,end:e.end})+"): a different token (`"+t.type+"`, "+hn({start:t.start,end:t.end})+") is open"):new Error("Cannot close document, a token (`"+t.type+"`, "+hn({start:t.start,end:t.end})+") is still open")}function _o(e){const t=this;t.parser=function(n){return To(n,{...t.data("settings"),...e,extensions:t.data("micromarkExtensions")||[],mdastExtensions:t.data("fromMarkdownExtensions")||[]})}}function Ro(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),i=o[0];i&&"text"===i.type?i.value="["+i.value:o.unshift({type:"text",value:"["});const a=o[o.length-1];return a&&"text"===a.type?a.value+=r:o.push({type:"text",value:r}),o}function Io(e){const t=e.spread;return null==t?e.children.length>1:t}function Ao(e){const t=String(e),n=/\r?\n|\r/g;let r=n.exec(t),o=0;const i=[];for(;r;)i.push(zo(t.slice(o,r.index),o>0,!0),r[0]),o=r.index+r[0].length,r=n.exec(t);return i.push(zo(t.slice(o),o>0,!1)),i.join("")}function zo(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 jo={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=sr(r.toLowerCase()),i=e.footnoteOrder.indexOf(r);let a,s=e.footnoteCounts.get(r);void 0===s?(s=0,e.footnoteOrder.push(r),a=e.footnoteOrder.length):a=i+1,s+=1,e.footnoteCounts.set(r,s);const l={type:"element",tagName:"a",properties:{href:"#"+n+"fn-"+o,id:n+"fnref-"+o+(s>1?"-"+s:""),dataFootnoteRef:!0,ariaDescribedBy:["footnote-label"]},children:[{type:"text",value:String(a)}]};e.patch(t,l);const u={type:"element",tagName:"sup",properties:{},children:[l]};return e.patch(t,u),e.applyData(t,u)},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 Ro(e,t);const o={src:sr(r.url||""),alt:t.alt};null!==r.title&&void 0!==r.title&&(o.title=r.title);const i={type:"element",tagName:"img",properties:o,children:[]};return e.patch(t,i),e.applyData(t,i)},image:function(e,t){const n={src:sr(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 Ro(e,t);const o={href:sr(r.url||"")};null!==r.title&&void 0!==r.title&&(o.title=r.title);const i={type:"element",tagName:"a",properties:o,children:e.all(t)};return e.patch(t,i),e.applyData(t,i)},link:function(e,t){const n={href:sr(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=Io(n[r])}return t}(n):Io(t),i={},a=[];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:[]}),i.className=["task-list-item"]}let s=-1;for(;++s<r.length;){const e=r[s];(o||0!==s||"element"!==e.type||"p"!==e.tagName)&&a.push({type:"text",value:"\n"}),"element"!==e.type||"p"!==e.tagName||o?a.push(e):a.push(...e.children)}const l=r[r.length-1];l&&(o||"element"!==l.type||"p"!==l.tagName)&&a.push({type:"text",value:"\n"});const u={type:"element",tagName:"li",properties:i,children:a};return e.patch(t,u),e.applyData(t,u)},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 i={type:"element",tagName:t.ordered?"ol":"ul",properties:n,children:e.wrap(r,!0)};return e.patch(t,i),e.applyData(t,i)},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)},i=fn(t.children[1]),a=dn(t.children[t.children.length-1]);i&&a&&(r.position={start:i,end:a}),o.push(r)}const i={type:"element",tagName:"table",properties:{},children:e.wrap(o,!0)};return e.patch(t,i),e.applyData(t,i)},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",i=n&&"table"===n.type?n.align:void 0,a=i?i.length:t.children.length;let s=-1;const l=[];for(;++s<a;){const n=t.children[s],r={},a=i?i[s]:void 0;a&&(r.align=a);let u={type:"element",tagName:o,properties:r,children:[]};n&&(u.children=e.all(n),e.patch(n,u),u=e.applyData(n,u)),l.push(u)}const u={type:"element",tagName:"tr",properties:{},children:e.wrap(l,!0)};return e.patch(t,u),e.applyData(t,u)},text:function(e,t){const n={type:"text",value:Ao(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:Do,yaml:Do,definition:Do,footnoteDefinition:Do};function Do(){}const Fo="object"==typeof self?self:globalThis,Mo=e=>((e,t)=>{const n=(t,n)=>(e.set(n,t),t),r=o=>{if(e.has(o))return e.get(o);const[i,a]=t[o];switch(i){case 0:case-1:return n(a,o);case 1:{const e=n([],o);for(const t of a)e.push(r(t));return e}case 2:{const e=n({},o);for(const[t,n]of a)e[r(t)]=r(n);return e}case 3:return n(new Date(a),o);case 4:{const{source:e,flags:t}=a;return n(new RegExp(e,t),o)}case 5:{const e=n(new Map,o);for(const[t,n]of a)e.set(r(t),r(n));return e}case 6:{const e=n(new Set,o);for(const t of a)e.add(r(t));return e}case 7:{const{name:e,message:t}=a;return n(new Fo[e](t),o)}case 8:return n(BigInt(a),o);case"BigInt":return n(Object(BigInt(a)),o);case"ArrayBuffer":return n(new Uint8Array(a).buffer,a);case"DataView":{const{buffer:e}=new Uint8Array(a);return n(new DataView(e),a)}}return n(new Fo[i](a),o)};return r})(new Map,e)(0),Uo="",{toString:Bo}={},{keys:$o}=Object,Vo=e=>{const t=typeof e;if("object"!==t||!e)return[0,t];const n=Bo.call(e).slice(8,-1);switch(n){case"Array":return[1,Uo];case"Object":return[2,Uo];case"Date":return[3,Uo];case"RegExp":return[4,Uo];case"Map":return[5,Uo];case"Set":return[6,Uo];case"DataView":return[1,n]}return n.includes("Array")?[1,n]:n.includes("Error")?[7,n]:[2,n]},Ho=([e,t])=>0===e&&("function"===t||"symbol"===t),qo=(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},i=r=>{if(n.has(r))return n.get(r);let[a,s]=Vo(r);switch(a){case 0:{let t=r;switch(s){case"bigint":a=8,t=r.toString();break;case"function":case"symbol":if(e)throw new TypeError("unable to serialize "+s);t=null;break;case"undefined":return o([-1],r)}return o([a,t],r)}case 1:{if(s){let e=r;return"DataView"===s?e=new Uint8Array(r.buffer):"ArrayBuffer"===s&&(e=new Uint8Array(r)),o([s,[...e]],r)}const e=[],t=o([a,e],r);for(const n of r)e.push(i(n));return t}case 2:{if(s)switch(s){case"BigInt":return o([s,r.toString()],r);case"Boolean":case"Number":case"String":return o([s,r.valueOf()],r)}if(t&&"toJSON"in r)return i(r.toJSON());const n=[],l=o([a,n],r);for(const t of $o(r))!e&&Ho(Vo(r[t]))||n.push([i(t),i(r[t])]);return l}case 3:return o([a,r.toISOString()],r);case 4:{const{source:e,flags:t}=r;return o([a,{source:e,flags:t}],r)}case 5:{const t=[],n=o([a,t],r);for(const[o,a]of r)(e||!Ho(Vo(o))&&!Ho(Vo(a)))&&t.push([i(o),i(a)]);return n}case 6:{const t=[],n=o([a,t],r);for(const o of r)!e&&Ho(Vo(o))||t.push(i(o));return n}}const{message:l}=r;return o([a,{name:s,message:l}],r)};return i})(!(t||n),!!t,new Map,r)(e),r},Wo="function"==typeof structuredClone?(e,t)=>t&&("json"in t||"lossy"in t)?Mo(qo(e,t)):structuredClone(e):(e,t)=>Mo(qo(e,t));function Ko(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 Qo(e,t){return"Back to reference "+(e+1)+(t>1?"-"+t:"")}const Jo=function(e){if(null==e)return Go;if("function"==typeof e)return Yo(e);if("object"==typeof e)return Array.isArray(e)?function(e){const t=[];let n=-1;for(;++n<e.length;)t[n]=Jo(e[n]);return Yo(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 Yo(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 Yo(t);function t(t){return t&&t.type===e}}(e);throw new Error("Expected function, string, or object as test")};function Yo(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 Go(){return!0}const Xo=[],Zo=!0,ei=!1;function ti(e,t,n,r){let o;"function"==typeof t&&"function"!=typeof n?(r=n,n=t):o=t;const i=Jo(o),a=r?-1:1;!function e(o,s,l){const u=o&&"object"==typeof o?o:{};if("string"==typeof u.type){const e="string"==typeof u.tagName?u.tagName:"string"==typeof u.name?u.name:void 0;Object.defineProperty(c,"name",{value:"node ("+o.type+(e?"<"+e+">":"")+")"})}return c;function c(){let u,c,d,f=Xo;if((!t||i(o,s,l[l.length-1]||void 0))&&(f=function(e){if(Array.isArray(e))return e;if("number"==typeof e)return[Zo,e];return null==e?Xo:[e]}(n(o,l)),f[0]===ei))return f;if("children"in o&&o.children){const t=o;if(t.children&&"skip"!==f[0])for(c=(r?t.children.length:-1)+a,d=l.concat(t);c>-1&&c<t.children.length;){const n=t.children[c];if(u=e(n,c,d)(),u[0]===ei)return u;c="number"==typeof u[1]?u[1]:c+a}}return f}}(e,void 0,[])()}function ni(e,t,n,r){let o,i,a;"function"==typeof t&&"function"!=typeof n?(i=void 0,a=t,o=n):(i=t,a=n,o=r),ti(e,i,function(e,t){const n=t[t.length-1],r=n?n.children.indexOf(e):void 0;return a(e,r,n)},o)}const ri={}.hasOwnProperty,oi={};function ii(e,t){e.position&&(t.position=function(e){const t=fn(e),n=dn(e);if(t&&n)return{start:t,end:n}}(e))}function ai(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,Wo(o)),"children"in n&&n.children&&null!=r&&(n.children=r)}return n}function si(e,t){const n=t.data||{},r=!("value"in t)||ri.call(n,"hProperties")||ri.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 li(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 ui(e){let t=0,n=e.charCodeAt(t);for(;9===n||32===n;)t++,n=e.charCodeAt(t);return e.slice(t)}function ci(e,t){const n=function(e,t){const n=t||oi,r=new Map,o=new Map,i=new Map,a={...jo,...n.handlers},s={all:function(e){const t=[];if("children"in e){const n=e.children;let r=-1;for(;++r<n.length;){const o=s.one(n[r],e);if(o){if(r&&"break"===n[r-1].type&&(Array.isArray(o)||"text"!==o.type||(o.value=ui(o.value)),!Array.isArray(o)&&"element"===o.type)){const e=o.children[0];e&&"text"===e.type&&(e.value=ui(e.value))}Array.isArray(o)?t.push(...o):t.push(o)}}}return t},applyData:ai,definitionById:r,footnoteById:o,footnoteCounts:i,footnoteOrder:[],handlers:a,one:function(e,t){const n=e.type,r=s.handlers[n];if(ri.call(s.handlers,n)&&r)return r(s,e,t);if(s.options.passThrough&&s.options.passThrough.includes(n)){if("children"in e){const{children:t,...n}=e,r=Wo(n);return r.children=s.all(e),r}return Wo(e)}return(s.options.unknownHandler||si)(s,e,t)},options:n,patch:ii,wrap:li};return ni(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)}}),s}(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||Ko,r=e.options.footnoteBackLabel||Qo,o=e.options.footnoteLabel||"Footnotes",i=e.options.footnoteLabelTagName||"h2",a=e.options.footnoteLabelProperties||{className:["sr-only"]},s=[];let l=-1;for(;++l<e.footnoteOrder.length;){const o=e.footnoteById.get(e.footnoteOrder[l]);if(!o)continue;const i=e.all(o),a=String(o.identifier).toUpperCase(),u=sr(a.toLowerCase());let c=0;const d=[],f=e.footnoteCounts.get(a);for(;void 0!==f&&++c<=f;){d.length>0&&d.push({type:"text",value:" "});let e="string"==typeof n?n:n(l,c);"string"==typeof e&&(e={type:"text",value:e}),d.push({type:"element",tagName:"a",properties:{href:"#"+t+"fnref-"+u+(c>1?"-"+c:""),dataFootnoteBackref:"",ariaLabel:"string"==typeof r?r:r(l,c),className:["data-footnote-backref"]},children:Array.isArray(e)?e:[e]})}const p=i[i.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 i.push(...d);const h={type:"element",tagName:"li",properties:{id:t+"fn-"+u},children:e.wrap(i,!0)};e.patch(o,h),s.push(h)}if(0!==s.length)return{type:"element",tagName:"section",properties:{dataFootnotes:!0,className:["footnotes"]},children:[{type:"element",tagName:i,properties:{...Wo(a),id:"footnote-label"},children:[{type:"text",value:o}]},{type:"text",value:"\n"},{type:"element",tagName:"ol",properties:{},children:e.wrap(s,!0)},{type:"text",value:"\n"}]}}(n),i=Array.isArray(r)?{type:"root",children:r}:r||{type:"root",children:[]};return o&&i.children.push({type:"text",value:"\n"},o),i}function di(e,t){return e&&"run"in e?async function(n,r){const o=ci(n,{file:r,...t});await e.run(o,r)}:function(n,r){return ci(n,{file:r,...e||t})}}function fi(e){if(e)throw e}var pi,hi;var gi=function(){if(hi)return pi;hi=1;var e=Object.prototype.hasOwnProperty,t=Object.prototype.toString,n=Object.defineProperty,r=Object.getOwnPropertyDescriptor,o=function(e){return"function"==typeof Array.isArray?Array.isArray(e):"[object Array]"===t.call(e)},i=function(n){if(!n||"[object Object]"!==t.call(n))return!1;var r,o=e.call(n,"constructor"),i=n.constructor&&n.constructor.prototype&&e.call(n.constructor.prototype,"isPrototypeOf");if(n.constructor&&!o&&!i)return!1;for(r in n);return void 0===r||e.call(n,r)},a=function(e,t){n&&"__proto__"===t.name?n(e,t.name,{enumerable:!0,configurable:!0,value:t.newValue,writable:!0}):e[t.name]=t.newValue},s=function(t,n){if("__proto__"===n){if(!e.call(t,n))return;if(r)return r(t,n).value}return t[n]};return pi=function e(){var t,n,r,l,u,c,d=arguments[0],f=1,p=arguments.length,h=!1;for("boolean"==typeof d&&(h=d,d=arguments[1]||{},f=2),(null==d||"object"!=typeof d&&"function"!=typeof d)&&(d={});f<p;++f)if(null!=(t=arguments[f]))for(n in t)r=s(d,n),d!==(l=s(t,n))&&(h&&l&&(i(l)||(u=o(l)))?(u?(u=!1,c=r&&o(r)?r:[]):c=r&&i(r)?r:{},a(d,{name:n,newValue:e(h,c,l)})):void 0!==l&&a(d,{name:n,newValue:l}));return d},pi}();const mi=t(gi);function yi(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 vi(){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(i,...a){const s=e[++n];let l=-1;if(i)r(i);else{for(;++l<t.length;)null!==a[l]&&void 0!==a[l]||(a[l]=t[l]);t=a,s?function(e,t){let n;return r;function r(...t){const r=e.length>t.length;let s;r&&t.push(o);try{s=e.apply(this,t)}catch(i){if(r&&n)throw i;return o(i)}r||(s&&s.then&&"function"==typeof s.then?s.then(a,o):s instanceof Error?o(s):a(s))}function o(e,...r){n||(n=!0,t(e,...r))}function a(e){o(null,e)}}(s,o)(...a):r(null,...a)}}(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 bi={basename:function(e,t){if(void 0!==t&&"string"!=typeof t)throw new TypeError('"ext" argument must be a string');ki(e);let n,r=0,o=-1,i=e.length;if(void 0===t||0===t.length||t.length>e.length){for(;i--;)if(47===e.codePointAt(i)){if(n){r=i+1;break}}else o<0&&(n=!0,o=i+1);return o<0?"":e.slice(r,o)}if(t===e)return"";let a=-1,s=t.length-1;for(;i--;)if(47===e.codePointAt(i)){if(n){r=i+1;break}}else a<0&&(n=!0,a=i+1),s>-1&&(e.codePointAt(i)===t.codePointAt(s--)?s<0&&(o=i):(s=-1,o=a));r===o?o=a:o<0&&(o=e.length);return e.slice(r,o)},dirname:function(e){if(ki(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){ki(e);let t,n=e.length,r=-1,o=0,i=-1,a=0;for(;n--;){const s=e.codePointAt(n);if(47!==s)r<0&&(t=!0,r=n+1),46===s?i<0?i=n:1!==a&&(a=1):i>-1&&(a=-1);else if(t){o=n+1;break}}if(i<0||r<0||0===a||1===a&&i===r-1&&i===o+1)return"";return e.slice(i,r)},join:function(...e){let t,n=-1;for(;++n<e.length;)ki(e[n]),e[n]&&(t=void 0===t?e[n]:t+"/"+e[n]);return void 0===t?".":function(e){ki(e);const t=47===e.codePointAt(0);let n=function(e,t){let n,r,o="",i=0,a=-1,s=0,l=-1;for(;++l<=e.length;){if(l<e.length)n=e.codePointAt(l);else{if(47===n)break;n=47}if(47===n){if(a===l-1||1===s);else if(a!==l-1&&2===s){if(o.length<2||2!==i||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="",i=0):(o=o.slice(0,r),i=o.length-1-o.lastIndexOf("/")),a=l,s=0;continue}}else if(o.length>0){o="",i=0,a=l,s=0;continue}t&&(o=o.length>0?o+"/..":"..",i=2)}else o.length>0?o+="/"+e.slice(a+1,l):o=e.slice(a+1,l),i=l-a-1;a=l,s=0}else 46===n&&s>-1?s++:s=-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 ki(e){if("string"!=typeof e)throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}const wi={cwd:function(){return"/"}};function xi(e){return Boolean(null!==e&&"object"==typeof e&&"href"in e&&e.href&&"protocol"in e&&e.protocol&&void 0===e.auth)}function Si(e){if("string"==typeof e)e=new URL(e);else if(!xi(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 Ei=["history","path","basename","stem","extname","dirname"];class Ci{constructor(e){let t;t=e?xi(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?"":wi.cwd(),this.data={},this.history=[],this.messages=[],this.value,this.map,this.result,this.stored;let n,r=-1;for(;++r<Ei.length;){const e=Ei[r];e in t&&void 0!==t[e]&&null!==t[e]&&(this[e]="history"===e?[...t[e]]:t[e])}for(n in t)Ei.includes(n)||(this[n]=t[n])}get basename(){return"string"==typeof this.path?bi.basename(this.path):void 0}set basename(e){Ni(e,"basename"),Ti(e,"basename"),this.path=bi.join(this.dirname||"",e)}get dirname(){return"string"==typeof this.path?bi.dirname(this.path):void 0}set dirname(e){Oi(this.basename,"dirname"),this.path=bi.join(e||"",this.basename)}get extname(){return"string"==typeof this.path?bi.extname(this.path):void 0}set extname(e){if(Ti(e,"extname"),Oi(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=bi.join(this.dirname,this.stem+(e||""))}get path(){return this.history[this.history.length-1]}set path(e){xi(e)&&(e=Si(e)),Ni(e,"path"),this.path!==e&&this.history.push(e)}get stem(){return"string"==typeof this.path?bi.basename(this.path,this.extname):void 0}set stem(e){Ni(e,"stem"),Ti(e,"stem"),this.path=bi.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 vn(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 Ti(e,t){if(e&&e.includes(bi.sep))throw new Error("`"+t+"` cannot be a path: did not expect `"+bi.sep+"`")}function Ni(e,t){if(!e)throw new Error("`"+t+"` cannot be empty")}function Oi(e,t){if(!e)throw new Error("Setting `"+t+"` requires `path` to be set too")}const Pi=function(e){const t=this.constructor.prototype,n=t[e],r=function(){return n.apply(r,arguments)};return Object.setPrototypeOf(r,t),r},Li={}.hasOwnProperty;class _i extends Pi{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=vi()}copy(){const e=new _i;let t=-1;for(;++t<this.attachers.length;){const n=this.attachers[t];e.use(...n)}return e.data(mi(!0,{},this.namespace)),e}data(e,t){return"string"==typeof e?2===arguments.length?(zi("data",this.frozen),this.namespace[e]=t,this):Li.call(this.namespace,e)&&this.namespace[e]||void 0:e?(zi("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=Fi(e),n=this.parser||this.Parser;return Ii("parse",n),n(String(t),t)}process(e,t){const n=this;return this.freeze(),Ii("process",this.parser||this.Parser),Ai("process",this.compiler||this.Compiler),t?r(void 0,t):new Promise(r);function r(r,o){const i=Fi(e),a=n.parse(i);function s(e,n){e||!n?o(e):r?r(n):t(void 0,n)}n.run(a,i,function(e,t,r){if(e||!t||!r)return s(e);const o=t,i=n.stringify(o,r);var a;"string"==typeof(a=i)||function(e){return Boolean(e&&"object"==typeof e&&"byteLength"in e&&"byteOffset"in e)}(a)?r.value=i:r.result=i,s(e,r)})}}processSync(e){let t,n=!1;return this.freeze(),Ii("processSync",this.parser||this.Parser),Ai("processSync",this.compiler||this.Compiler),this.process(e,function(e,r){n=!0,fi(e),t=r}),Di("processSync","process",n),t}run(e,t,n){ji(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,i){const a=Fi(t);r.run(e,a,function(t,r,a){const s=r||e;t?i(t):o?o(s):n(void 0,s,a)})}}runSync(e,t){let n,r=!1;return this.run(e,t,function(e,t){fi(e),n=t,r=!0}),Di("runSync","run",r),n}stringify(e,t){this.freeze();const n=Fi(t),r=this.compiler||this.Compiler;return Ai("stringify",r),ji(e),r(e,n)}use(e,...t){const n=this.attachers,r=this.namespace;if(zi("use",this.frozen),null==e);else if("function"==typeof e)s(e,t);else{if("object"!=typeof e)throw new TypeError("Expected usable value, not `"+e+"`");Array.isArray(e)?a(e):i(e)}return this;function o(e){if("function"==typeof e)s(e,[]);else{if("object"!=typeof e)throw new TypeError("Expected usable value, not `"+e+"`");if(Array.isArray(e)){const[t,...n]=e;s(t,n)}else i(e)}}function i(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");a(e.plugins),e.settings&&(r.settings=mi(!0,r.settings,e.settings))}function a(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 s(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,...i]=t;const a=n[o][1];yi(a)&&yi(r)&&(r=mi(!0,a,r)),n[o]=[e,r,...i]}}}}const Ri=(new _i).freeze();function Ii(e,t){if("function"!=typeof t)throw new TypeError("Cannot `"+e+"` without `parser`")}function Ai(e,t){if("function"!=typeof t)throw new TypeError("Cannot `"+e+"` without `compiler`")}function zi(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 ji(e){if(!yi(e)||"string"!=typeof e.type)throw new TypeError("Expected node, got `"+e+"`")}function Di(e,t,n){if(!n)throw new Error("`"+e+"` finished async. Use `"+t+"` instead")}function Fi(e){return function(e){return Boolean(e&&"object"==typeof e&&"message"in e&&"messages"in e)}(e)?e:new Ci(e)}const Mi=[],Ui={allowDangerousHtml:!0},Bi=/^(https?|ircs?|mailto|xmpp)$/i,$i=[{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:"className",id:"remove-classname"},{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 Vi(e){const t=function(e){const t=e.rehypePlugins||Mi,n=e.remarkPlugins||Mi,r=e.remarkRehypeOptions?{...e.remarkRehypeOptions,...Ui}:Ui,o=Ri().use(_o).use(n).use(di,r).use(t);return o}(e),n=function(e){const t=e.children||"",n=new Ci;"string"==typeof t&&(n.value=t);return n}(e);return function(e,t){const n=t.allowedElements,r=t.allowElement,o=t.components,i=t.disallowedElements,a=t.skipHtml,s=t.unwrapDisallowed,l=t.urlTransform||Hi;for(const c of $i)Object.hasOwn(t,c.from)&&ft((c.from,c.to&&c.to,c.id));return ni(e,u),Cn(e,{Fragment:N.Fragment,components:o,ignoreInvalidStyle:!0,jsx:N.jsx,jsxs:N.jsxs,passKeys:!0,passNode:!0});function u(e,t,o){if("raw"===e.type&&o&&"number"==typeof t)return a?o.children.splice(t,1):o.children[t]={type:"text",value:e.value},t;if("element"===e.type){let t;for(t in zn)if(Object.hasOwn(zn,t)&&Object.hasOwn(e.properties,t)){const n=e.properties[t],r=zn[t];(null===r||r.includes(e.tagName))&&(e.properties[t]=l(String(n||""),t,e))}}if("element"===e.type){let a=n?!n.includes(e.tagName):!!i&&i.includes(e.tagName);if(!a&&r&&"number"==typeof t&&(a=!r(e,t,o)),a&&o&&"number"==typeof t)return s&&e.children?o.children.splice(t,1,...e.children):o.children.splice(t,1),t}}}(t.runSync(t.parse(n),n),e)}function Hi(e){const t=e.indexOf(":"),n=e.indexOf("?"),r=e.indexOf("#"),o=e.indexOf("/");return-1===t||-1!==o&&t>o||-1!==n&&t>n||-1!==r&&t>r||Bi.test(e.slice(0,t))?e:""}const qi="https://www.tiagpctest.softiabot.com",Wi={BOTTOM_RIGHT:"bottom-right",BOTTOM_LEFT:"bottom-left",TOP_RIGHT:"top-right",TOP_LEFT:"top-left"},Ki={LIGHT:"light",DARK:"dark",AUTO:"auto"},Qi={SPANISH:"es",ENGLISH:"en",FRANCES:"fr"},Ji=640,Yi=Ki.AUTO,Gi=Wi.BOTTOM_RIGHT,Xi=Qi.ENGLISH,Zi="400px",ea="600px",ta=!1,na=!0,ra=!0,oa=3e4,ia=2e3,aa=e=>{try{return new Date(e).toLocaleTimeString("es-ES",{hour:"2-digit",minute:"2-digit"})}catch{return""}},sa=()=>crypto.randomUUID(),la=({size:e="md",className:t=""})=>N.jsx("div",{className:`gpc-spinner ${{sm:"w-4 h-4 border-2",md:"w-6 h-6 border-2",lg:"w-8 h-8 border-3"}[e]} ${t}`,role:"status","aria-label":"Cargando",children:N.jsx("span",{className:"sr-only",children:"Cargando..."})}),ua=()=>N.jsxs("div",{className:"gpc-typing-indicator",role:"status","aria-label":"Escribiendo",children:[N.jsx("span",{className:"gpc-typing-dot"}),N.jsx("span",{className:"gpc-typing-dot"}),N.jsx("span",{className:"gpc-typing-dot"})]}),ca=({message:e,showMetadata:t=!1,messageRef:n=null})=>{const{t:r}=V(),o="user"===e.role,i=!o&&e.isStreaming&&!e.content;return N.jsxs("div",{ref:n,className:"gpc-message "+(o?"gpc-message-user":"gpc-message-assistant"),role:"article","aria-label":o?"Mensaje del usuario":"Mensaje del asistente",children:[N.jsx("div",{className:"gpc-message-content",children:i?N.jsx(ua,{}):o?e.content.trim():N.jsx(Vi,{children:e.content})}),N.jsx("div",{className:"gpc-message-timestamp "+(o?"gpc-message-timestamp-user":""),children:aa(e.timestamp)}),!o&&t&&e.metadata&&N.jsxs("div",{className:"gpc-message-metadata",children:[e.metadata.tokensUsed&&N.jsxs("div",{className:"gpc-metadata-item",children:[N.jsxs("strong",{children:[r("metadata.tokensUsed"),":"]})," ",e.metadata.tokensUsed]}),e.metadata.responseTimeMs&&N.jsxs("div",{className:"gpc-metadata-item",children:[N.jsxs("strong",{children:[r("metadata.responseTime"),":"]})," ",(a=e.metadata.responseTimeMs,a>=1e3?`${(a/1e3).toFixed(1)}s`:`${Math.round(a)}ms`)]}),e.metadata.model&&N.jsxs("div",{className:"gpc-metadata-item",children:[N.jsxs("strong",{children:[r("metadata.model"),":"]})," ",e.metadata.model]})]})]});var a},da=({messages:e,isLoading:t,showMetadata:n=!1,widgetConfig:r=null})=>{const{t:o}=V(),i=l.useRef(null),a=l.useRef(null),s=l.useRef(e.length);l.useEffect(()=>{const t=e.length>s.current,n=e[e.length-1];t&&n&&("user"===n.role?i.current?.scrollIntoView({behavior:"smooth"}):"assistant"===n.role&&n.isStreaming&&setTimeout(()=>{a.current?.scrollIntoView({behavior:"smooth",block:"start"})},100)),s.current=e.length},[e]);const u=r?.company_name||"TIA GPC",c=r?.company_logo_base64,d=c?.startsWith("data:")?c:c?`data:image/png;base64,${c}`:null;return 0!==e.length||t?N.jsxs("div",{className:"gpc-messages-container gpc-scrollbar gpc-smooth-scroll",children:[e.map((t,r)=>N.jsx(ca,{message:t,showMetadata:n,messageRef:r===e.length-1?a:null},t.id)),N.jsx("div",{ref:i})]}):N.jsx("div",{className:"gpc-messages-container",children:N.jsxs("div",{className:"gpc-empty-state",children:[d?N.jsx("div",{className:"gpc-welcome-logo",children:N.jsx("img",{src:d,alt:u,className:"gpc-welcome-company-logo"})}):N.jsx(te,{className:"gpc-empty-icon"}),N.jsx("h3",{className:"gpc-empty-title",children:o("chat.welcome",{companyName:u})}),N.jsx("p",{className:"gpc-empty-text",children:o("chat.emptyState")})]})})},fa=({onSendMessage:e,isLoading:t,disabled:n})=>{const{t:r}=V(),[o,i]=l.useState(""),a=l.useRef(null);l.useEffect(()=>{n||t||a.current?.focus()},[n,t]);const s=async r=>{r.preventDefault();const a=(e=>e.trim().slice(0,2e3))(o);if(a&&!t&&!n)try{await e(a),i("")}catch(s){}},u=o.trim().length>0&&!t&&!n;return N.jsxs("form",{onSubmit:s,className:"gpc-input-container",children:[N.jsx("input",{ref:a,type:"text",value:o,onChange:e=>i(e.target.value),onKeyDown:e=>{"Enter"!==e.key||e.shiftKey||(e.preventDefault(),s(e))},placeholder:r("chat.placeholder"),disabled:t||n,maxLength:ia,className:"gpc-input","aria-label":r("chat.placeholder"),"aria-describedby":"chat-input-help"}),N.jsx("button",{type:"submit",disabled:!u,className:"gpc-send-button","aria-label":r("chat.send"),title:r("chat.send"),children:t?N.jsx("span",{className:"gpc-spinner"}):N.jsx(re,{className:"gpc-icon"})}),N.jsxs("span",{id:"chat-input-help",className:"gpc-sr-only",children:[r("chat.placeholder"),". Máximo ",ia," caracteres."]})]})};var pa=l.forwardRef(({as:e="div",...t},n)=>N.jsx(e,{...t,ref:n})),ha="cf-turnstile-script",ga="onloadTurnstileCallback",ma=e=>!!document.getElementById(e),ya={normal:{width:300,height:65},compact:{width:150,height:140},invisible:{width:0,height:0,overflow:"hidden"},flexible:{minWidth:300,width:"100%",height:65},interactionOnly:{width:"fit-content",height:"auto",display:"flex"}};function va(e){if("invisible"!==e&&"interactionOnly"!==e)return e}var ba,ka="unloaded",wa=new Promise((e,t)=>{ba={resolve:e,reject:t},"ready"===ka&&e(void 0)}),xa=l.forwardRef((e,t)=>{let{scriptOptions:n,options:r={},siteKey:o,onWidgetLoad:i,onSuccess:a,onExpire:s,onError:u,onBeforeInteractive:c,onAfterInteractive:d,onUnsupported:f,onTimeout:p,onLoadScript:h,id:g,style:m,as:y="div",injectScript:v=!0,rerenderOnCallbackChange:b=!1,...k}=e,w=r.size,x=l.useCallback(()=>typeof w>"u"?{}:"execute"===r.execution?ya.invisible:"interaction-only"===r.appearance?ya.interactionOnly:ya[w],[r.execution,w,r.appearance]),[S,E]=l.useState(x()),C=l.useRef(null),[T,O]=l.useState(!1),P=l.useRef(),L=l.useRef(!1),_=g||"cf-turnstile",R=l.useRef({onSuccess:a,onError:u,onExpire:s,onBeforeInteractive:c,onAfterInteractive:d,onUnsupported:f,onTimeout:p});l.useEffect(()=>{b||(R.current={onSuccess:a,onError:u,onExpire:s,onBeforeInteractive:c,onAfterInteractive:d,onUnsupported:f,onTimeout:p})});let I=n?.id||ha,A=function(e=ha){let[t,n]=l.useState(!1);return l.useEffect(()=>{let t=()=>{ma(e)&&n(!0)},r=new MutationObserver(t);return r.observe(document,{childList:!0,subtree:!0}),t(),()=>{r.disconnect()}},[e]),t}(I),z=n?.onLoadCallbackName||ga,j=r.appearance||"always",D=l.useMemo(()=>({sitekey:o,action:r.action,cData:r.cData,theme:r.theme||"auto",language:r.language||"auto",tabindex:r.tabIndex,"response-field":r.responseField,"response-field-name":r.responseFieldName,size:va(w),retry:r.retry||"auto","retry-interval":r.retryInterval||8e3,"refresh-expired":r.refreshExpired||"auto","refresh-timeout":r.refreshTimeout||"auto",execution:r.execution||"render",appearance:r.appearance||"always","feedback-enabled":r.feedbackEnabled||!0,callback:e=>{L.current=!0,b?a?.(e):R.current.onSuccess?.(e)},"error-callback":b?u:(...e)=>R.current.onError?.(...e),"expired-callback":b?s:(...e)=>R.current.onExpire?.(...e),"before-interactive-callback":b?c:(...e)=>R.current.onBeforeInteractive?.(...e),"after-interactive-callback":b?d:(...e)=>R.current.onAfterInteractive?.(...e),"unsupported-callback":b?f:(...e)=>R.current.onUnsupported?.(...e),"timeout-callback":b?p:(...e)=>R.current.onTimeout?.(...e)}),[r.action,r.appearance,r.cData,r.execution,r.language,r.refreshExpired,r.responseField,r.responseFieldName,r.retry,r.retryInterval,r.tabIndex,r.theme,r.feedbackEnabled,r.refreshTimeout,o,w,b,b?a:null,b?u:null,b?s:null,b?c:null,b?d:null,b?f:null,b?p:null]),F=l.useCallback(()=>typeof window<"u"&&!!window.turnstile,[]);return l.useEffect(function(){v&&!T&&(({render:e="explicit",onLoadCallbackName:t=ga,scriptOptions:{nonce:n="",defer:r=!0,async:o=!0,id:i="",appendTo:a,onError:s,crossOrigin:l=""}={}})=>{let u=i||ha;if(ma(u))return;let c=document.createElement("script");c.id=u,c.src=`https://challenges.cloudflare.com/turnstile/v0/api.js?onload=${t}&render=${e}`,document.querySelector(`script[src="${c.src}"]`)||(c.defer=!!r,c.async=!!o,n&&(c.nonce=n),l&&(c.crossOrigin=l),s&&(c.onerror=s,delete window[t]),("body"===a?document.body:document.getElementsByTagName("head")[0]).appendChild(c))})({onLoadCallbackName:z,scriptOptions:{...n,id:I}})},[v,T,n,I]),l.useEffect(function(){"ready"!==ka&&((e=ga)=>("unloaded"===ka&&(ka="loading",window[e]=()=>{ba.resolve(),ka="ready",delete window[e]}),wa))(z).then(()=>O(!0)).catch(console.error)},[]),l.useEffect(function(){if(!C.current||!T)return;let e=!1;return(async()=>{if(e||!C.current)return;let t=window.turnstile.render(C.current,D);P.current=t,P.current&&i?.(P.current)})(),()=>{e=!0,P.current&&(window.turnstile.remove(P.current),L.current=!1)}},[_,T,D]),l.useImperativeHandle(t,()=>{let{turnstile:e}=window;return{getResponse(){if(e?.getResponse&&P.current&&F())return e.getResponse(P.current)},getResponsePromise:async(e=3e4,t=100)=>new Promise((n,r)=>{let o,i=async()=>{if(L.current&&window.turnstile&&P.current)try{let e=window.turnstile.getResponse(P.current);return o&&clearTimeout(o),e?n(e):r(new Error("No response received"))}catch(a){return o&&clearTimeout(o),r(new Error("Failed to get response"))}o||(o=setTimeout(()=>{o&&clearTimeout(o),r(new Error("Timeout"))},e)),await new Promise(e=>setTimeout(e,t)),await i()};i()}),reset(){if(e?.reset&&P.current&&F()){"execute"===r.execution&&E(ya.invisible);try{L.current=!1,e.reset(P.current)}catch(je){}}},remove(){e?.remove&&P.current&&F()&&(E(ya.invisible),L.current=!1,e.remove(P.current),P.current=null)},render(){if(!e?.render||!C.current||!F()||P.current)return;let t=e.render(C.current,D);return P.current=t,P.current&&i?.(P.current),"execute"!==r.execution&&E(w?ya[w]:{}),t},execute(){"execute"===r.execution&&e?.execute&&C.current&&P.current&&F()&&(e.execute(C.current,D),E(w?ya[w]:{}))},isExpired:()=>!!(e?.isExpired&&P.current&&F())&&e.isExpired(P.current)}},[P,r.execution,w,D,C,F,T,i]),l.useEffect(()=>{A&&!T&&window.turnstile&&O(!0)},[T,A]),l.useEffect(()=>{E(x())},[r.execution,w,j]),l.useEffect(()=>{!A||"function"!=typeof h||h()},[A]),N.jsx(pa,{ref:C,as:y,id:_,style:{...S,...m},...k})});xa.displayName="Turnstile";const Sa=({siteKey:e,onSuccess:t,onError:n})=>{const{t:r}=V(),[o,i]=l.useState(!1),[a,s]=l.useState(null);return N.jsxs("div",{className:"gpc-validator-container",children:[N.jsxs("div",{className:"gpc-validator-header",children:[N.jsx("h3",{className:"gpc-validator-title",children:r("chat.validation")}),N.jsx("p",{className:"gpc-validator-subtitle",children:r("turnstile.verifying")})]}),!a&&N.jsx("div",{className:"gpc-animate-fade-in",children:N.jsx(xa,{siteKey:e,onSuccess:async e=>{i(!0),s(null);try{await t(e)}catch(o){s(r("turnstile.error")),n?.(o)}finally{i(!1)}},onError:e=>{s(r("turnstile.error")),n?.(new Error(r("turnstile.error")))},options:{theme:"light",size:"normal"}})}),o&&N.jsxs("div",{className:"gpc-validator-loading",children:[N.jsx(la,{size:"md"}),N.jsx("p",{className:"gpc-validator-text",children:r("chat.validation")})]}),a&&N.jsxs("div",{className:"gpc-validator-error",children:[N.jsx(X,{className:"gpc-error-icon"}),N.jsxs("div",{className:"gpc-error-content",children:[N.jsx("p",{className:"gpc-error-title",children:r("errors.validation")}),N.jsx("p",{className:"gpc-error-message",children:a}),N.jsx("button",{onClick:()=>window.location.reload(),className:"gpc-error-button",children:r("chat.retry")})]})]})]})},Ea=(e="auto")=>{const[t,n]=l.useState(e),[r,o]=l.useState("light");l.useEffect(()=>{if(o("auto"===t?window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light":t),"auto"===t){const e=window.matchMedia("(prefers-color-scheme: dark)"),t=e=>{o(e.matches?"dark":"light")};return e.addEventListener("change",t),()=>{e.removeEventListener("change",t)}}},[t]);return{theme:r,themeMode:t,setThemeMode:n,toggleTheme:()=>{n(e=>"auto"===e?"light"===r?"dark":"light":"light"===e?"dark":"light")}}},Ca=({gpcService:e,licenseToken:t,widgetConfig:n,turnstileSiteKey:r,onClose:o,themeMode:i,showBranding:a=!0,showMetadata:s=!1,onError:u})=>{const{t:c}=V(),[d,f]=l.useState(null),[p,h]=l.useState(!1),{theme:g,toggleTheme:m}=Ea(i),y=l.useCallback(()=>{h(!1),f(null),e&&e.renewSessionToken()},[e]),{messages:v,isLoading:b,sendMessage:k}=((e,t,n)=>{const{t:r}=V(),[o,i]=l.useState([]),[a,s]=l.useState(!1),[u,c]=l.useState(null),d=l.useCallback(async o=>{if(!o.trim()||a)return;if(!t)return void at.error("Validación anti-bot pendiente");const l={id:sa(),role:"user",content:o.trim(),timestamp:(new Date).toISOString()};i(e=>[...e,l]),s(!0),c(null);const u=sa(),d={id:u,role:"assistant",content:"",timestamp:(new Date).toISOString(),isStreaming:!0};i(e=>[...e,d]);try{const n=await e.sendMessage(o,t,e=>{i(t=>t.map(t=>t.id===u?{...t,content:t.content+e}:t))});i(e=>e.map(e=>e.id===u?{id:n.data.message_id,role:"assistant",content:n.data.response,timestamp:n.data.created_at,isStreaming:!1,metadata:{costUsd:n.data.cost_usd,creditBalanceUsd:n.data.credit_balance_usd,inputTokens:n.data.input_tokens,outputTokens:n.data.output_tokens,responseTimeMs:n.data.response_time_ms,modelUsed:n.data.model_used}}:e))}catch(f){let e,t;i(e=>e.filter(e=>e.id!==u));try{e=JSON.parse(f.message)}catch{e={statusCode:500,message:f.message}}const o=e.statusCode||500,a=e.errorCode||"";switch(401===o&&"SESSION_EXPIRED"===a&&(t=r("errors.sessionExpired","Session expired, please verify again"),n&&n()),o){case 401:t||(t=r("errors.unauthorized"));break;case 402:t=r("errors.insufficientCredits");break;case 403:t=a.includes("DOMAIN")||a.includes("UNAUTHORIZED")?r("errors.domainUnauthorized"):r("errors.validation");break;case 429:t=r("errors.rateLimit");break;case 503:case 502:case 504:t=r("errors.aiServiceUnavailable");break;case 500:t=r("errors.serverError");break;default:t=r("errors.generic")}c(t),at.error(t,{duration:4e3,position:"top-center"});const s={id:sa(),role:"assistant",content:t,timestamp:(new Date).toISOString()};i(e=>[...e,s])}finally{s(!1)}},[e,t,a,r,n]),f=l.useCallback(()=>{i([]),c(null)},[]),p=l.useCallback(()=>{c(null)},[]);return{messages:o,isLoading:a,error:u,sendMessage:d,clearMessages:f,clearError:p}})(e,d,y);l.useEffect(()=>{e&&e.hasValidCachedSession()&&(h(!0),f("CACHED_SESSION"))},[e]);return l.useEffect(()=>()=>{e&&e.releaseSession().catch(e=>{})},[e]),N.jsxs("div",{className:"gpc-chat-window gpc-animate-fade-in "+("dark"===g?"gpc-dark":""),children:[N.jsx(ct,{onClose:o,theme:g,onToggleTheme:m,showBranding:a,widgetConfig:n}),p?N.jsxs(N.Fragment,{children:[N.jsx(da,{messages:v,isLoading:b,showMetadata:s,widgetConfig:n}),N.jsx(fa,{onSendMessage:k,isLoading:b,disabled:!1})]}):N.jsx(Sa,{siteKey:r,onSuccess:t=>{f(t),h(!0),e&&e.validateSession()},onError:u}),a&&N.jsx("div",{className:"gpc-footer",children:N.jsx("span",{className:"gpc-footer-text",children:c("widget.poweredBy")})}),N.jsx(it,{position:"top-center"})]})};function Ta(e,t){return function(){return e.apply(t,arguments)}}const{toString:Na}=Object.prototype,{getPrototypeOf:Oa}=Object,{iterator:Pa,toStringTag:La}=Symbol,_a=(e=>t=>{const n=Na.call(t);return e[n]||(e[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),Ra=e=>(e=e.toLowerCase(),t=>_a(t)===e),Ia=e=>t=>typeof t===e,{isArray:Aa}=Array,za=Ia("undefined");function ja(e){return null!==e&&!za(e)&&null!==e.constructor&&!za(e.constructor)&&Ma(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const Da=Ra("ArrayBuffer");const Fa=Ia("string"),Ma=Ia("function"),Ua=Ia("number"),Ba=e=>null!==e&&"object"==typeof e,$a=e=>{if("object"!==_a(e))return!1;const t=Oa(e);return!(null!==t&&t!==Object.prototype&&null!==Object.getPrototypeOf(t)||La in e||Pa in e)},Va=Ra("Date"),Ha=Ra("File"),qa=Ra("Blob"),Wa=Ra("FileList"),Ka=Ra("URLSearchParams"),[Qa,Ja,Ya,Ga]=["ReadableStream","Request","Response","Headers"].map(Ra);function Xa(e,t,{allOwnKeys:n=!1}={}){if(null==e)return;let r,o;if("object"!=typeof e&&(e=[e]),Aa(e))for(r=0,o=e.length;r<o;r++)t.call(null,e[r],r,e);else{if(ja(e))return;const o=n?Object.getOwnPropertyNames(e):Object.keys(e),i=o.length;let a;for(r=0;r<i;r++)a=o[r],t.call(null,e[a],a,e)}}function Za(e,t){if(ja(e))return null;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 es="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:global,ts=e=>!za(e)&&e!==es;const ns=(e=>t=>e&&t instanceof e)("undefined"!=typeof Uint8Array&&Oa(Uint8Array)),rs=Ra("HTMLFormElement"),os=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),is=Ra("RegExp"),as=(e,t)=>{const n=Object.getOwnPropertyDescriptors(e),r={};Xa(n,(n,o)=>{let i;!1!==(i=t(n,o,e))&&(r[o]=i||n)}),Object.defineProperties(e,r)};const ss=Ra("AsyncFunction"),ls=(us="function"==typeof setImmediate,cs=Ma(es.postMessage),us?setImmediate:cs?(ds=`axios@${Math.random()}`,fs=[],es.addEventListener("message",({source:e,data:t})=>{e===es&&t===ds&&fs.length&&fs.shift()()},!1),e=>{fs.push(e),es.postMessage(ds,"*")}):e=>setTimeout(e));var us,cs,ds,fs;const ps="undefined"!=typeof queueMicrotask?queueMicrotask.bind(es):"undefined"!=typeof process&&process.nextTick||ls,hs={isArray:Aa,isArrayBuffer:Da,isBuffer:ja,isFormData:e=>{let t;return e&&("function"==typeof FormData&&e instanceof FormData||Ma(e.append)&&("formdata"===(t=_a(e))||"object"===t&&Ma(e.toString)&&"[object FormData]"===e.toString()))},isArrayBufferView:function(e){let t;return t="undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(e):e&&e.buffer&&Da(e.buffer),t},isString:Fa,isNumber:Ua,isBoolean:e=>!0===e||!1===e,isObject:Ba,isPlainObject:$a,isEmptyObject:e=>{if(!Ba(e)||ja(e))return!1;try{return 0===Object.keys(e).length&&Object.getPrototypeOf(e)===Object.prototype}catch(Ie){return!1}},isReadableStream:Qa,isRequest:Ja,isResponse:Ya,isHeaders:Ga,isUndefined:za,isDate:Va,isFile:Ha,isBlob:qa,isRegExp:is,isFunction:Ma,isStream:e=>Ba(e)&&Ma(e.pipe),isURLSearchParams:Ka,isTypedArray:ns,isFileList:Wa,forEach:Xa,merge:function e(){const{caseless:t,skipUndefined:n}=ts(this)&&this||{},r={},o=(o,i)=>{const a=t&&Za(r,i)||i;$a(r[a])&&$a(o)?r[a]=e(r[a],o):$a(o)?r[a]=e({},o):Aa(o)?r[a]=o.slice():n&&za(o)||(r[a]=o)};for(let i=0,a=arguments.length;i<a;i++)arguments[i]&&Xa(arguments[i],o);return r},extend:(e,t,n,{allOwnKeys:r}={})=>(Xa(t,(t,r)=>{n&&Ma(t)?e[r]=Ta(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,i,a;const s={};if(t=t||{},null==e)return t;do{for(o=Object.getOwnPropertyNames(e),i=o.length;i-- >0;)a=o[i],r&&!r(a,e,t)||s[a]||(t[a]=e[a],s[a]=!0);e=!1!==n&&Oa(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},kindOf:_a,kindOfTest:Ra,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(Aa(e))return e;let t=e.length;if(!Ua(t))return null;const n=new Array(t);for(;t-- >0;)n[t]=e[t];return n},forEachEntry:(e,t)=>{const n=(e&&e[Pa]).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:rs,hasOwnProperty:os,hasOwnProp:os,reduceDescriptors:as,freezeMethods:e=>{as(e,(t,n)=>{if(Ma(e)&&-1!==["arguments","caller","callee"].indexOf(n))return!1;const r=e[n];Ma(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 Aa(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:Za,global:es,isContextDefined:ts,isSpecCompliantForm:function(e){return!!(e&&Ma(e.append)&&"FormData"===e[La]&&e[Pa])},toJSONObject:e=>{const t=new Array(10),n=(e,r)=>{if(Ba(e)){if(t.indexOf(e)>=0)return;if(ja(e))return e;if(!("toJSON"in e)){t[r]=e;const o=Aa(e)?[]:{};return Xa(e,(e,t)=>{const i=n(e,r+1);!za(i)&&(o[t]=i)}),t[r]=void 0,o}}return e};return n(e,0)},isAsyncFn:ss,isThenable:e=>e&&(Ba(e)||Ma(e))&&Ma(e.then)&&Ma(e.catch),setImmediate:ls,asap:ps,isIterable:e=>null!=e&&Ma(e[Pa])};function gs(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)}hs.inherits(gs,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:hs.toJSONObject(this.config),code:this.code,status:this.status}}});const ms=gs.prototype,ys={};["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=>{ys[e]={value:e}}),Object.defineProperties(gs,ys),Object.defineProperty(ms,"isAxiosError",{value:!0}),gs.from=(e,t,n,r,o,i)=>{const a=Object.create(ms);hs.toFlatObject(e,a,function(e){return e!==Error.prototype},e=>"isAxiosError"!==e);const s=e&&e.message?e.message:"Error",l=null==t&&e?e.code:t;return gs.call(a,s,l,n,r,o),e&&null==a.cause&&Object.defineProperty(a,"cause",{value:e,configurable:!0}),a.name=e&&e.name||"Error",i&&Object.assign(a,i),a};function vs(e){return hs.isPlainObject(e)||hs.isArray(e)}function bs(e){return hs.endsWith(e,"[]")?e.slice(0,-2):e}function ks(e,t,n){return e?e.concat(t).map(function(e,t){return e=bs(e),!n&&t?"["+e+"]":e}).join(n?".":""):t}const ws=hs.toFlatObject(hs,{},null,function(e){return/^is[A-Z]/.test(e)});function xs(e,t,n){if(!hs.isObject(e))throw new TypeError("target must be an object");t=t||new FormData;const r=(n=hs.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(e,t){return!hs.isUndefined(t[e])})).metaTokens,o=n.visitor||u,i=n.dots,a=n.indexes,s=(n.Blob||"undefined"!=typeof Blob&&Blob)&&hs.isSpecCompliantForm(t);if(!hs.isFunction(o))throw new TypeError("visitor must be a function");function l(e){if(null===e)return"";if(hs.isDate(e))return e.toISOString();if(hs.isBoolean(e))return e.toString();if(!s&&hs.isBlob(e))throw new gs("Blob is not supported. Use a Buffer instead.");return hs.isArrayBuffer(e)||hs.isTypedArray(e)?s&&"function"==typeof Blob?new Blob([e]):Buffer.from(e):e}function u(e,n,o){let s=e;if(e&&!o&&"object"==typeof e)if(hs.endsWith(n,"{}"))n=r?n:n.slice(0,-2),e=JSON.stringify(e);else if(hs.isArray(e)&&function(e){return hs.isArray(e)&&!e.some(vs)}(e)||(hs.isFileList(e)||hs.endsWith(n,"[]"))&&(s=hs.toArray(e)))return n=bs(n),s.forEach(function(e,r){!hs.isUndefined(e)&&null!==e&&t.append(!0===a?ks([n],r,i):null===a?n:n+"[]",l(e))}),!1;return!!vs(e)||(t.append(ks(o,n,i),l(e)),!1)}const c=[],d=Object.assign(ws,{defaultVisitor:u,convertValue:l,isVisitable:vs});if(!hs.isObject(e))throw new TypeError("data must be an object");return function e(n,r){if(!hs.isUndefined(n)){if(-1!==c.indexOf(n))throw Error("Circular reference detected in "+r.join("."));c.push(n),hs.forEach(n,function(n,i){!0===(!(hs.isUndefined(n)||null===n)&&o.call(t,n,hs.isString(i)?i.trim():i,r,d))&&e(n,r?r.concat(i):[i])}),c.pop()}}(e),t}function Ss(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(e){return t[e]})}function Es(e,t){this._pairs=[],e&&xs(e,this,t)}const Cs=Es.prototype;function Ts(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function Ns(e,t,n){if(!t)return e;const r=n&&n.encode||Ts;hs.isFunction(n)&&(n={serialize:n});const o=n&&n.serialize;let i;if(i=o?o(t,n):hs.isURLSearchParams(t)?t.toString():new Es(t,n).toString(r),i){const t=e.indexOf("#");-1!==t&&(e=e.slice(0,t)),e+=(-1===e.indexOf("?")?"?":"&")+i}return e}Cs.append=function(e,t){this._pairs.push([e,t])},Cs.toString=function(e){const t=e?function(t){return e.call(this,t,Ss)}:Ss;return this._pairs.map(function(e){return t(e[0])+"="+t(e[1])},"").join("&")};class Os{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){hs.forEach(this.handlers,function(t){null!==t&&e(t)})}}const Ps={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},Ls={isBrowser:!0,classes:{URLSearchParams:"undefined"!=typeof URLSearchParams?URLSearchParams:Es,FormData:"undefined"!=typeof FormData?FormData:null,Blob:"undefined"!=typeof Blob?Blob:null},protocols:["http","https","file","blob","url","data"]},_s="undefined"!=typeof window&&"undefined"!=typeof document,Rs="object"==typeof navigator&&navigator||void 0,Is=_s&&(!Rs||["ReactNative","NativeScript","NS"].indexOf(Rs.product)<0),As="undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope&&"function"==typeof self.importScripts,zs=_s&&window.location.href||"http://localhost",js={...Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:_s,hasStandardBrowserEnv:Is,hasStandardBrowserWebWorkerEnv:As,navigator:Rs,origin:zs},Symbol.toStringTag,{value:"Module"})),...Ls};function Ds(e){function t(e,n,r,o){let i=e[o++];if("__proto__"===i)return!0;const a=Number.isFinite(+i),s=o>=e.length;if(i=!i&&hs.isArray(r)?r.length:i,s)return hs.hasOwnProp(r,i)?r[i]=[r[i],n]:r[i]=n,!a;r[i]&&hs.isObject(r[i])||(r[i]=[]);return t(e,n,r[i],o)&&hs.isArray(r[i])&&(r[i]=function(e){const t={},n=Object.keys(e);let r;const o=n.length;let i;for(r=0;r<o;r++)i=n[r],t[i]=e[i];return t}(r[i])),!a}if(hs.isFormData(e)&&hs.isFunction(e.entries)){const n={};return hs.forEachEntry(e,(e,r)=>{t(function(e){return hs.matchAll(/\w+|\[(\w*)]/g,e).map(e=>"[]"===e[0]?"":e[1]||e[0])}(e),r,n,0)}),n}return null}const Fs={transitional:Ps,adapter:["xhr","http","fetch"],transformRequest:[function(e,t){const n=t.getContentType()||"",r=n.indexOf("application/json")>-1,o=hs.isObject(e);o&&hs.isHTMLForm(e)&&(e=new FormData(e));if(hs.isFormData(e))return r?JSON.stringify(Ds(e)):e;if(hs.isArrayBuffer(e)||hs.isBuffer(e)||hs.isStream(e)||hs.isFile(e)||hs.isBlob(e)||hs.isReadableStream(e))return e;if(hs.isArrayBufferView(e))return e.buffer;if(hs.isURLSearchParams(e))return t.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();let i;if(o){if(n.indexOf("application/x-www-form-urlencoded")>-1)return function(e,t){return xs(e,new js.classes.URLSearchParams,{visitor:function(e,t,n,r){return js.isNode&&hs.isBuffer(e)?(this.append(t,e.toString("base64")),!1):r.defaultVisitor.apply(this,arguments)},...t})}(e,this.formSerializer).toString();if((i=hs.isFileList(e))||n.indexOf("multipart/form-data")>-1){const t=this.env&&this.env.FormData;return xs(i?{"files[]":e}:e,t&&new t,this.formSerializer)}}return o||r?(t.setContentType("application/json",!1),function(e,t,n){if(hs.isString(e))try{return(t||JSON.parse)(e),hs.trim(e)}catch(Ie){if("SyntaxError"!==Ie.name)throw Ie}return(n||JSON.stringify)(e)}(e)):e}],transformResponse:[function(e){const t=this.transitional||Fs.transitional,n=t&&t.forcedJSONParsing,r="json"===this.responseType;if(hs.isResponse(e)||hs.isReadableStream(e))return e;if(e&&hs.isString(e)&&(n&&!this.responseType||r)){const n=!(t&&t.silentJSONParsing)&&r;try{return JSON.parse(e,this.parseReviver)}catch(Ie){if(n){if("SyntaxError"===Ie.name)throw gs.from(Ie,gs.ERR_BAD_RESPONSE,this,null,this.response);throw Ie}}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:js.classes.FormData,Blob:js.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};hs.forEach(["delete","get","head","post","put","patch"],e=>{Fs.headers[e]={}});const Ms=hs.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"]),Us=Symbol("internals");function Bs(e){return e&&String(e).trim().toLowerCase()}function $s(e){return!1===e||null==e?e:hs.isArray(e)?e.map($s):String(e)}function Vs(e,t,n,r,o){return hs.isFunction(r)?r.call(this,t,n):(o&&(t=n),hs.isString(t)?hs.isString(r)?-1!==t.indexOf(r):hs.isRegExp(r)?r.test(t):void 0:void 0)}let Hs=class{constructor(e){e&&this.set(e)}set(e,t,n){const r=this;function o(e,t,n){const o=Bs(t);if(!o)throw new Error("header name must be a non-empty string");const i=hs.findKey(r,o);(!i||void 0===r[i]||!0===n||void 0===n&&!1!==r[i])&&(r[i||t]=$s(e))}const i=(e,t)=>hs.forEach(e,(e,n)=>o(e,n,t));if(hs.isPlainObject(e)||e instanceof this.constructor)i(e,t);else if(hs.isString(e)&&(e=e.trim())&&!/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim()))i((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]&&Ms[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(hs.isObject(e)&&hs.isIterable(e)){let n,r,o={};for(const t of e){if(!hs.isArray(t))throw TypeError("Object iterator must return a key-value pair");o[r=t[0]]=(n=o[r])?hs.isArray(n)?[...n,t[1]]:[n,t[1]]:t[1]}i(o,t)}else null!=e&&o(t,e,n);return this}get(e,t){if(e=Bs(e)){const n=hs.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(hs.isFunction(t))return t.call(this,e,n);if(hs.isRegExp(t))return t.exec(e);throw new TypeError("parser must be boolean|regexp|function")}}}has(e,t){if(e=Bs(e)){const n=hs.findKey(this,e);return!(!n||void 0===this[n]||t&&!Vs(0,this[n],n,t))}return!1}delete(e,t){const n=this;let r=!1;function o(e){if(e=Bs(e)){const o=hs.findKey(n,e);!o||t&&!Vs(0,n[o],o,t)||(delete n[o],r=!0)}}return hs.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&&!Vs(0,this[o],o,e,!0)||(delete this[o],r=!0)}return r}normalize(e){const t=this,n={};return hs.forEach(this,(r,o)=>{const i=hs.findKey(n,o);if(i)return t[i]=$s(r),void delete t[o];const a=e?function(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(e,t,n)=>t.toUpperCase()+n)}(o):String(o).trim();a!==o&&delete t[o],t[a]=$s(r),n[a]=!0}),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){const t=Object.create(null);return hs.forEach(this,(n,r)=>{null!=n&&!1!==n&&(t[r]=e&&hs.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")}getSetCookie(){return this.get("set-cookie")||[]}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[Us]=this[Us]={accessors:{}}).accessors,n=this.prototype;function r(e){const r=Bs(e);t[r]||(!function(e,t){const n=hs.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 hs.isArray(e)?e.forEach(r):r(e),this}};function qs(e,t){const n=this||Fs,r=t||n,o=Hs.from(r.headers);let i=r.data;return hs.forEach(e,function(e){i=e.call(n,i,o.normalize(),t?t.status:void 0)}),o.normalize(),i}function Ws(e){return!(!e||!e.__CANCEL__)}function Ks(e,t,n){gs.call(this,null==e?"canceled":e,gs.ERR_CANCELED,t,n),this.name="CanceledError"}function Qs(e,t,n){const r=n.config.validateStatus;n.status&&r&&!r(n.status)?t(new gs("Request failed with status code "+n.status,[gs.ERR_BAD_REQUEST,gs.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n)):e(n)}Hs.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),hs.reduceDescriptors(Hs.prototype,({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(e){this[n]=e}}}),hs.freezeMethods(Hs),hs.inherits(Ks,gs,{__CANCEL__:!0});const Js=(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,i=0,a=0;return t=void 0!==t?t:1e3,function(s){const l=Date.now(),u=r[a];o||(o=l),n[i]=s,r[i]=l;let c=a,d=0;for(;c!==i;)d+=n[c++],c%=e;if(i=(i+1)%e,i===a&&(a=(a+1)%e),l-o<t)return;const f=u&&l-u;return f?Math.round(1e3*d/f):void 0}}(50,250);return function(e,t){let n,r,o=0,i=1e3/t;const a=(t,i=Date.now())=>{o=i,n=null,r&&(clearTimeout(r),r=null),e(...t)};return[(...e)=>{const t=Date.now(),s=t-o;s>=i?a(e,t):(n=e,r||(r=setTimeout(()=>{r=null,a(n)},i-s)))},()=>n&&a(n)]}(n=>{const i=n.loaded,a=n.lengthComputable?n.total:void 0,s=i-r,l=o(s);r=i;e({loaded:i,total:a,progress:a?i/a:void 0,bytes:s,rate:l||void 0,estimated:l&&a&&i<=a?(a-i)/l:void 0,event:n,lengthComputable:null!=a,[t?"download":"upload"]:!0})},n)},Ys=(e,t)=>{const n=null!=e;return[r=>t[0]({lengthComputable:n,total:e,loaded:r}),t[1]]},Gs=e=>(...t)=>hs.asap(()=>e(...t)),Xs=js.hasStandardBrowserEnv?((e,t)=>n=>(n=new URL(n,js.origin),e.protocol===n.protocol&&e.host===n.host&&(t||e.port===n.port)))(new URL(js.origin),js.navigator&&/(msie|trident)/i.test(js.navigator.userAgent)):()=>!0,Zs=js.hasStandardBrowserEnv?{write(e,t,n,r,o,i){const a=[e+"="+encodeURIComponent(t)];hs.isNumber(n)&&a.push("expires="+new Date(n).toGMTString()),hs.isString(r)&&a.push("path="+r),hs.isString(o)&&a.push("domain="+o),!0===i&&a.push("secure"),document.cookie=a.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 el(e,t,n){let r=!/^([a-z][a-z\d+\-.]*:)?\/\//i.test(t);return e&&(r||0==n)?function(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}(e,t):t}const tl=e=>e instanceof Hs?{...e}:e;function nl(e,t){t=t||{};const n={};function r(e,t,n,r){return hs.isPlainObject(e)&&hs.isPlainObject(t)?hs.merge.call({caseless:r},e,t):hs.isPlainObject(t)?hs.merge({},t):hs.isArray(t)?t.slice():t}function o(e,t,n,o){return hs.isUndefined(t)?hs.isUndefined(e)?void 0:r(void 0,e,0,o):r(e,t,0,o)}function i(e,t){if(!hs.isUndefined(t))return r(void 0,t)}function a(e,t){return hs.isUndefined(t)?hs.isUndefined(e)?void 0:r(void 0,e):r(void 0,t)}function s(n,o,i){return i in t?r(n,o):i in e?r(void 0,n):void 0}const l={url:i,method:i,data:i,baseURL:a,transformRequest:a,transformResponse:a,paramsSerializer:a,timeout:a,timeoutMessage:a,withCredentials:a,withXSRFToken:a,adapter:a,responseType:a,xsrfCookieName:a,xsrfHeaderName:a,onUploadProgress:a,onDownloadProgress:a,decompress:a,maxContentLength:a,maxBodyLength:a,beforeRedirect:a,transport:a,httpAgent:a,httpsAgent:a,cancelToken:a,socketPath:a,responseEncoding:a,validateStatus:s,headers:(e,t,n)=>o(tl(e),tl(t),0,!0)};return hs.forEach(Object.keys({...e,...t}),function(r){const i=l[r]||o,a=i(e[r],t[r],r);hs.isUndefined(a)&&i!==s||(n[r]=a)}),n}const rl=e=>{const t=nl({},e);let{data:n,withXSRFToken:r,xsrfHeaderName:o,xsrfCookieName:i,headers:a,auth:s}=t;if(t.headers=a=Hs.from(a),t.url=Ns(el(t.baseURL,t.url,t.allowAbsoluteUrls),e.params,e.paramsSerializer),s&&a.set("Authorization","Basic "+btoa((s.username||"")+":"+(s.password?unescape(encodeURIComponent(s.password)):""))),hs.isFormData(n))if(js.hasStandardBrowserEnv||js.hasStandardBrowserWebWorkerEnv)a.setContentType(void 0);else if(hs.isFunction(n.getHeaders)){const e=n.getHeaders(),t=["content-type","content-length"];Object.entries(e).forEach(([e,n])=>{t.includes(e.toLowerCase())&&a.set(e,n)})}if(js.hasStandardBrowserEnv&&(r&&hs.isFunction(r)&&(r=r(t)),r||!1!==r&&Xs(t.url))){const e=o&&i&&Zs.read(i);e&&a.set(o,e)}return t},ol="undefined"!=typeof XMLHttpRequest&&function(e){return new Promise(function(t,n){const r=rl(e);let o=r.data;const i=Hs.from(r.headers).normalize();let a,s,l,u,c,{responseType:d,onUploadProgress:f,onDownloadProgress:p}=r;function h(){u&&u(),c&&c(),r.cancelToken&&r.cancelToken.unsubscribe(a),r.signal&&r.signal.removeEventListener("abort",a)}let g=new XMLHttpRequest;function m(){if(!g)return;const r=Hs.from("getAllResponseHeaders"in g&&g.getAllResponseHeaders());Qs(function(e){t(e),h()},function(e){n(e),h()},{data:d&&"text"!==d&&"json"!==d?g.response:g.responseText,status:g.status,statusText:g.statusText,headers:r,config:e,request:g}),g=null}g.open(r.method.toUpperCase(),r.url,!0),g.timeout=r.timeout,"onloadend"in g?g.onloadend=m:g.onreadystatechange=function(){g&&4===g.readyState&&(0!==g.status||g.responseURL&&0===g.responseURL.indexOf("file:"))&&setTimeout(m)},g.onabort=function(){g&&(n(new gs("Request aborted",gs.ECONNABORTED,e,g)),g=null)},g.onerror=function(t){const r=new gs(t&&t.message?t.message:"Network Error",gs.ERR_NETWORK,e,g);r.event=t||null,n(r),g=null},g.ontimeout=function(){let t=r.timeout?"timeout of "+r.timeout+"ms exceeded":"timeout exceeded";const o=r.transitional||Ps;r.timeoutErrorMessage&&(t=r.timeoutErrorMessage),n(new gs(t,o.clarifyTimeoutError?gs.ETIMEDOUT:gs.ECONNABORTED,e,g)),g=null},void 0===o&&i.setContentType(null),"setRequestHeader"in g&&hs.forEach(i.toJSON(),function(e,t){g.setRequestHeader(t,e)}),hs.isUndefined(r.withCredentials)||(g.withCredentials=!!r.withCredentials),d&&"json"!==d&&(g.responseType=r.responseType),p&&([l,c]=Js(p,!0),g.addEventListener("progress",l)),f&&g.upload&&([s,u]=Js(f),g.upload.addEventListener("progress",s),g.upload.addEventListener("loadend",u)),(r.cancelToken||r.signal)&&(a=t=>{g&&(n(!t||t.type?new Ks(null,e,g):t),g.abort(),g=null)},r.cancelToken&&r.cancelToken.subscribe(a),r.signal&&(r.signal.aborted?a():r.signal.addEventListener("abort",a)));const y=function(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}(r.url);y&&-1===js.protocols.indexOf(y)?n(new gs("Unsupported protocol "+y+":",gs.ERR_BAD_REQUEST,e)):g.send(o||null)})},il=(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,a();const t=e instanceof Error?e:this.reason;r.abort(t instanceof gs?t:new Ks(t instanceof Error?t.message:t))}};let i=t&&setTimeout(()=>{i=null,o(new gs(`timeout ${t} of ms exceeded`,gs.ETIMEDOUT))},t);const a=()=>{e&&(i&&clearTimeout(i),i=null,e.forEach(e=>{e.unsubscribe?e.unsubscribe(o):e.removeEventListener("abort",o)}),e=null)};e.forEach(e=>e.addEventListener("abort",o));const{signal:s}=r;return s.unsubscribe=()=>hs.asap(a),s}},al=function*(e,t){let n=e.byteLength;if(n<t)return void(yield e);let r,o=0;for(;o<n;)r=o+t,yield e.slice(o,r),o=r},sl=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()}},ll=(e,t,n,r)=>{const o=async function*(e,t){for await(const n of sl(e))yield*al(n,t)}(e,t);let i,a=0,s=e=>{i||(i=!0,r&&r(e))};return new ReadableStream({async pull(e){try{const{done:t,value:r}=await o.next();if(t)return s(),void e.close();let i=r.byteLength;if(n){let e=a+=i;n(e)}e.enqueue(new Uint8Array(r))}catch(t){throw s(t),t}},cancel:e=>(s(e),o.return())},{highWaterMark:2})},{isFunction:ul}=hs,cl=(({Request:e,Response:t})=>({Request:e,Response:t}))(hs.global),{ReadableStream:dl,TextEncoder:fl}=hs.global,pl=(e,...t)=>{try{return!!e(...t)}catch(Ie){return!1}},hl=e=>{e=hs.merge.call({skipUndefined:!0},cl,e);const{fetch:t,Request:n,Response:r}=e,o=t?ul(t):"function"==typeof fetch,i=ul(n),a=ul(r);if(!o)return!1;const s=o&&ul(dl),l=o&&("function"==typeof fl?(e=>t=>e.encode(t))(new fl):async e=>new Uint8Array(await new n(e).arrayBuffer())),u=i&&s&&pl(()=>{let e=!1;const t=new n(js.origin,{body:new dl,method:"POST",get duplex(){return e=!0,"half"}}).headers.has("Content-Type");return e&&!t}),c=a&&s&&pl(()=>hs.isReadableStream(new r("").body)),d={stream:c&&(e=>e.body)};o&&["text","arrayBuffer","blob","formData","stream"].forEach(e=>{!d[e]&&(d[e]=(t,n)=>{let r=t&&t[e];if(r)return r.call(t);throw new gs(`Response type '${e}' is not supported`,gs.ERR_NOT_SUPPORT,n)})});const f=async(e,t)=>{const r=hs.toFiniteNumber(e.getContentLength());return null==r?(async e=>{if(null==e)return 0;if(hs.isBlob(e))return e.size;if(hs.isSpecCompliantForm(e)){const t=new n(js.origin,{method:"POST",body:e});return(await t.arrayBuffer()).byteLength}return hs.isArrayBufferView(e)||hs.isArrayBuffer(e)?e.byteLength:(hs.isURLSearchParams(e)&&(e+=""),hs.isString(e)?(await l(e)).byteLength:void 0)})(t):r};return async e=>{let{url:o,method:a,data:s,signal:l,cancelToken:p,timeout:h,onDownloadProgress:g,onUploadProgress:m,responseType:y,headers:v,withCredentials:b="same-origin",fetchOptions:k}=rl(e),w=t||fetch;y=y?(y+"").toLowerCase():"text";let x=il([l,p&&p.toAbortSignal()],h),S=null;const E=x&&x.unsubscribe&&(()=>{x.unsubscribe()});let C;try{if(m&&u&&"get"!==a&&"head"!==a&&0!==(C=await f(v,s))){let e,t=new n(o,{method:"POST",body:s,duplex:"half"});if(hs.isFormData(s)&&(e=t.headers.get("content-type"))&&v.setContentType(e),t.body){const[e,n]=Ys(C,Js(Gs(m)));s=ll(t.body,65536,e,n)}}hs.isString(b)||(b=b?"include":"omit");const t=i&&"credentials"in n.prototype,l={...k,signal:x,method:a.toUpperCase(),headers:v.normalize().toJSON(),body:s,duplex:"half",credentials:t?b:void 0};S=i&&new n(o,l);let p=await(i?w(S,k):w(o,l));const h=c&&("stream"===y||"response"===y);if(c&&(g||h&&E)){const e={};["status","statusText","headers"].forEach(t=>{e[t]=p[t]});const t=hs.toFiniteNumber(p.headers.get("content-length")),[n,o]=g&&Ys(t,Js(Gs(g),!0))||[];p=new r(ll(p.body,65536,n,()=>{o&&o(),E&&E()}),e)}y=y||"text";let T=await d[hs.findKey(d,y)||"text"](p,e);return!h&&E&&E(),await new Promise((t,n)=>{Qs(t,n,{data:T,headers:Hs.from(p.headers),status:p.status,statusText:p.statusText,config:e,request:S})})}catch(T){if(E&&E(),T&&"TypeError"===T.name&&/Load failed|fetch/i.test(T.message))throw Object.assign(new gs("Network Error",gs.ERR_NETWORK,e,S),{cause:T.cause||T});throw gs.from(T,T&&T.code,e,S)}}},gl=new Map,ml=e=>{let t=e?e.env:{};const{fetch:n,Request:r,Response:o}=t,i=[r,o,n];let a,s,l=i.length,u=gl;for(;l--;)a=i[l],s=u.get(a),void 0===s&&u.set(a,s=l?new Map:hl(t)),u=s;return s};ml();const yl={http:null,xhr:ol,fetch:{get:ml}};hs.forEach(yl,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch(Ie){}Object.defineProperty(e,"adapterName",{value:t})}});const vl=e=>`- ${e}`,bl=e=>hs.isFunction(e)||null===e||!1===e,kl=(e,t)=>{e=hs.isArray(e)?e:[e];const{length:n}=e;let r,o;const i={};for(let a=0;a<n;a++){let n;if(r=e[a],o=r,!bl(r)&&(o=yl[(n=String(r)).toLowerCase()],void 0===o))throw new gs(`Unknown adapter '${n}'`);if(o&&(hs.isFunction(o)||(o=o.get(t))))break;i[n||"#"+a]=o}if(!o){const e=Object.entries(i).map(([e,t])=>`adapter ${e} `+(!1===t?"is not supported by the environment":"is not available in the build"));throw new gs("There is no suitable adapter to dispatch the request "+(n?e.length>1?"since :\n"+e.map(vl).join("\n"):" "+vl(e[0]):"as no adapter specified"),"ERR_NOT_SUPPORT")}return o};function wl(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new Ks(null,e)}function xl(e){wl(e),e.headers=Hs.from(e.headers),e.data=qs.call(e,e.transformRequest),-1!==["post","put","patch"].indexOf(e.method)&&e.headers.setContentType("application/x-www-form-urlencoded",!1);return kl(e.adapter||Fs.adapter,e)(e).then(function(t){return wl(e),t.data=qs.call(e,e.transformResponse,t),t.headers=Hs.from(t.headers),t},function(t){return Ws(t)||(wl(e),t&&t.response&&(t.response.data=qs.call(e,e.transformResponse,t.response),t.response.headers=Hs.from(t.response.headers))),Promise.reject(t)})}const Sl="1.12.2",El={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{El[e]=function(n){return typeof n===e||"a"+(t<1?"n ":" ")+e}});const Cl={};El.transitional=function(e,t,n){return(r,o,i)=>{if(!1===e)throw new gs(function(e,t){return"[Axios v"+Sl+"] Transitional option '"+e+"'"+t+(n?". "+n:"")}(o," has been removed"+(t?" in "+t:"")),gs.ERR_DEPRECATED);return t&&!Cl[o]&&(Cl[o]=!0),!e||e(r,o,i)}},El.spelling=function(e){return(e,t)=>!0};const Tl={assertOptions:function(e,t,n){if("object"!=typeof e)throw new gs("options must be an object",gs.ERR_BAD_OPTION_VALUE);const r=Object.keys(e);let o=r.length;for(;o-- >0;){const i=r[o],a=t[i];if(a){const t=e[i],n=void 0===t||a(t,i,e);if(!0!==n)throw new gs("option "+i+" must be "+n,gs.ERR_BAD_OPTION_VALUE);continue}if(!0!==n)throw new gs("Unknown option "+i,gs.ERR_BAD_OPTION)}},validators:El},Nl=Tl.validators;let Ol=class{constructor(e){this.defaults=e||{},this.interceptors={request:new Os,response:new Os}}async request(e,t){try{return await this._request(e,t)}catch(n){if(n instanceof Error){let e={};Error.captureStackTrace?Error.captureStackTrace(e):e=new Error;const t=e.stack?e.stack.replace(/^.+\n/,""):"";try{n.stack?t&&!String(n.stack).endsWith(t.replace(/^.+\n.+\n/,""))&&(n.stack+="\n"+t):n.stack=t}catch(Ie){}}throw n}}_request(e,t){"string"==typeof e?(t=t||{}).url=e:t=e||{},t=nl(this.defaults,t);const{transitional:n,paramsSerializer:r,headers:o}=t;void 0!==n&&Tl.assertOptions(n,{silentJSONParsing:Nl.transitional(Nl.boolean),forcedJSONParsing:Nl.transitional(Nl.boolean),clarifyTimeoutError:Nl.transitional(Nl.boolean)},!1),null!=r&&(hs.isFunction(r)?t.paramsSerializer={serialize:r}:Tl.assertOptions(r,{encode:Nl.function,serialize:Nl.function},!0)),void 0!==t.allowAbsoluteUrls||(void 0!==this.defaults.allowAbsoluteUrls?t.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:t.allowAbsoluteUrls=!0),Tl.assertOptions(t,{baseUrl:Nl.spelling("baseURL"),withXsrfToken:Nl.spelling("withXSRFToken")},!0),t.method=(t.method||this.defaults.method||"get").toLowerCase();let i=o&&hs.merge(o.common,o[t.method]);o&&hs.forEach(["delete","get","head","post","put","patch","common"],e=>{delete o[e]}),t.headers=Hs.concat(i,o);const a=[];let s=!0;this.interceptors.request.forEach(function(e){"function"==typeof e.runWhen&&!1===e.runWhen(t)||(s=s&&e.synchronous,a.unshift(e.fulfilled,e.rejected))});const l=[];let u;this.interceptors.response.forEach(function(e){l.push(e.fulfilled,e.rejected)});let c,d=0;if(!s){const e=[xl.bind(this),void 0];for(e.unshift(...a),e.push(...l),c=e.length,u=Promise.resolve(t);d<c;)u=u.then(e[d++],e[d++]);return u}c=a.length;let f=t;for(;d<c;){const e=a[d++],t=a[d++];try{f=e(f)}catch(p){t.call(this,p);break}}try{u=xl.call(this,f)}catch(p){return Promise.reject(p)}for(d=0,c=l.length;d<c;)u=u.then(l[d++],l[d++]);return u}getUri(e){return Ns(el((e=nl(this.defaults,e)).baseURL,e.url,e.allowAbsoluteUrls),e.params,e.paramsSerializer)}};hs.forEach(["delete","get","head","options"],function(e){Ol.prototype[e]=function(t,n){return this.request(nl(n||{},{method:e,url:t,data:(n||{}).data}))}}),hs.forEach(["post","put","patch"],function(e){function t(t){return function(n,r,o){return this.request(nl(o||{},{method:e,headers:t?{"Content-Type":"multipart/form-data"}:{},url:n,data:r}))}}Ol.prototype[e]=t(),Ol.prototype[e+"Form"]=t(!0)});const Pl={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(Pl).forEach(([e,t])=>{Pl[t]=e});const Ll=function e(t){const n=new Ol(t),r=Ta(Ol.prototype.request,n);return hs.extend(r,Ol.prototype,n,{allOwnKeys:!0}),hs.extend(r,n,null,{allOwnKeys:!0}),r.create=function(n){return e(nl(t,n))},r}(Fs);Ll.Axios=Ol,Ll.CanceledError=Ks,Ll.CancelToken=class e{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 Ks(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 t;return{token:new e(function(e){t=e}),cancel:t}}},Ll.isCancel=Ws,Ll.VERSION=Sl,Ll.toFormData=xs,Ll.AxiosError=gs,Ll.Cancel=Ll.CanceledError,Ll.all=function(e){return Promise.all(e)},Ll.spread=function(e){return function(t){return e.apply(null,t)}},Ll.isAxiosError=function(e){return hs.isObject(e)&&!0===e.isAxiosError},Ll.mergeConfig=nl,Ll.AxiosHeaders=Hs,Ll.formToJSON=e=>Ds(hs.isHTMLForm(e)?new FormData(e):e),Ll.getAdapter=kl,Ll.HttpStatusCode=Pl,Ll.default=Ll;const{Axios:_l,AxiosError:Rl,CanceledError:Il,isCancel:Al,CancelToken:zl,VERSION:jl,all:Dl,Cancel:Fl,isAxiosError:Ml,spread:Ul,toFormData:Bl,AxiosHeaders:$l,HttpStatusCode:Vl,formToJSON:Hl,getAdapter:ql,mergeConfig:Wl}=Ll;class Kl{constructor(e,t){this.licenseToken=t,this.sessionToken=this._getOrCreateSessionToken(t),this.api=Ll.create({baseURL:e||qi,timeout:oa,headers:{"Content-Type":"application/json"}}),this.api.interceptors.request.use(e=>(this.licenseToken&&(e.headers.Authorization=`Bearer ${this.licenseToken}`),e))}_generateSessionToken(){return"session_"+Array.from(crypto.getRandomValues(new Uint8Array(28))).map(e=>e.toString(16).padStart(2,"0")).join("")}_getStorageKey(e){return`tiagpc_session_${e.substring(0,16)}`}_getOrCreateSessionToken(e){const t=this._getStorageKey(e);try{const e=localStorage.getItem(t);if(e){const{sessionToken:n,timestamp:r,validated:o}=JSON.parse(e),i=Date.now();if(o&&i-r<864e5)return n;localStorage.removeItem(t)}}catch(n){}return this._generateSessionToken()}hasValidCachedSession(){const e=this._getStorageKey(this.licenseToken);try{const t=localStorage.getItem(e);if(t){const{sessionToken:e,timestamp:n,validated:r}=JSON.parse(t),o=Date.now();return r&&o-n<864e5}}catch(t){}return!1}_saveSessionToken(e,t,n=!1){const r=this._getStorageKey(e);try{const e={sessionToken:t,timestamp:Date.now(),validated:n};localStorage.setItem(r,JSON.stringify(e))}catch(o){}}_clearSessionToken(e){const t=this._getStorageKey(e);try{localStorage.removeItem(t)}catch(n){}}async sendMessage(e,t,n){if(!this.licenseToken)throw new Error("License token is required.");const r=this.hasValidCachedSession();if(!t&&!r)throw new Error("Turnstile token is required for anti-bot validation.");const o=`${this.api.defaults.baseURL}/ask`;try{const r=await fetch(o,{method:"POST",headers:{"Content-Type":"application/json",Authorization:`Bearer ${this.licenseToken}`},body:JSON.stringify({message:e,turnstile_token:t||"CACHED_SESSION",session_token:this.sessionToken})});if(!r.ok){const e=await r.json().catch(()=>({}));throw new Error(JSON.stringify({statusCode:r.status,errorCode:e.error_code||"UNKNOWN_ERROR",message:e.message||"Request failed",retryAfter:e.retry_after_seconds||null}))}const a=r.body.getReader(),s=new TextDecoder;let l="",u="",c=null,d=null;for(;;){const{done:e,value:t}=await a.read();if(e)break;l+=s.decode(t,{stream:!0});const r=l.split("\n");l=r.pop();for(const o of r){if(!o.trim()||!o.startsWith("data: "))continue;const e=o.replace("data: ","").trim();if("[DONE]"!==e)try{const t=JSON.parse(e);if("content"===t.type)u+=t.text,n&&n(t.text);else if("metadata"===t.type)c=t;else if("summary"===t.type)d=t;else if("error"===t.type)throw new Error(JSON.stringify({statusCode:t.status_code||500,errorCode:t.error_code,message:t.message,retryAfter:null}))}catch(i){if(i.message&&i.message.startsWith("{"))throw i}}}if(!d)throw new Error("No summary received from server");return{success:!0,data:{message_id:d.message_id,response:u,cost_usd:d.cost_usd,credit_balance_usd:d.credit_balance_usd,input_tokens:d.input_tokens,output_tokens:d.output_tokens,response_time_ms:d.response_time_ms,model_used:d.model_used,created_at:d.created_at}}}catch(a){if(a.message.startsWith("{"))throw a;throw new Error(JSON.stringify({statusCode:500,errorCode:"NETWORK_ERROR",message:a.message,retryAfter:null}))}}async releaseSession(){if(this.licenseToken)try{return(await this.api.post("/release-session",{session_token:this.sessionToken})).data}catch(e){}}async getInitConfig(){if(!this.licenseToken)throw new Error("License token is required.");try{return(await this.api.get("/init")).data}catch(e){this._handleError(e)}}async checkHealth(){try{return(await this.api.get("/health")).data}catch(e){return{status:"unhealthy",error:e.message}}}getSessionToken(){return this.sessionToken}renewSessionToken(){const e=this._generateSessionToken();this.sessionToken=e,this._saveSessionToken(this.licenseToken,e)}validateSession(){this._saveSessionToken(this.licenseToken,this.sessionToken,!0)}_handleError(e){if(e.response){const t=e.response.data,n={statusCode:e.response.status,errorCode:t.error_code||"UNKNOWN_ERROR",message:t.message||"Request failed",retryAfter:t.retry_after_seconds||null};throw new Error(JSON.stringify(n))}throw e.request?new Error(JSON.stringify({statusCode:503,errorCode:"NETWORK_ERROR",message:"No response from server",retryAfter:null})):new Error(JSON.stringify({statusCode:500,errorCode:"INTERNAL_ERROR",message:e.message,retryAfter:null}))}}const Ql=e=>"string"==typeof e,Jl=()=>{let e,t;const n=new Promise((n,r)=>{e=n,t=r});return n.resolve=e,n.reject=t,n},Yl=e=>null==e?"":""+e,Gl=/###/g,Xl=e=>e&&e.indexOf("###")>-1?e.replace(Gl,"."):e,Zl=e=>!e||Ql(e),eu=(e,t,n)=>{const r=Ql(t)?t.split("."):t;let o=0;for(;o<r.length-1;){if(Zl(e))return{};const t=Xl(r[o]);!e[t]&&n&&(e[t]=new n),e=Object.prototype.hasOwnProperty.call(e,t)?e[t]:{},++o}return Zl(e)?{}:{obj:e,k:Xl(r[o])}},tu=(e,t,n)=>{const{obj:r,k:o}=eu(e,t,Object);if(void 0!==r||1===t.length)return void(r[o]=n);let i=t[t.length-1],a=t.slice(0,t.length-1),s=eu(e,a,Object);for(;void 0===s.obj&&a.length;)i=`${a[a.length-1]}.${i}`,a=a.slice(0,a.length-1),s=eu(e,a,Object),s?.obj&&void 0!==s.obj[`${s.k}.${i}`]&&(s.obj=void 0);s.obj[`${s.k}.${i}`]=n},nu=(e,t)=>{const{obj:n,k:r}=eu(e,t);if(n&&Object.prototype.hasOwnProperty.call(n,r))return n[r]},ru=(e,t,n)=>{for(const r in t)"__proto__"!==r&&"constructor"!==r&&(r in e?Ql(e[r])||e[r]instanceof String||Ql(t[r])||t[r]instanceof String?n&&(e[r]=t[r]):ru(e[r],t[r],n):e[r]=t[r]);return e},ou=e=>e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&");var iu={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;","/":"&#x2F;"};const au=e=>Ql(e)?e.replace(/[&<>"'\/]/g,e=>iu[e]):e;const su=[" ",",","?","!",";"],lu=new class{constructor(e){this.capacity=e,this.regExpMap=new Map,this.regExpQueue=[]}getRegExp(e){const t=this.regExpMap.get(e);if(void 0!==t)return t;const n=new RegExp(e);return this.regExpQueue.length===this.capacity&&this.regExpMap.delete(this.regExpQueue.shift()),this.regExpMap.set(e,n),this.regExpQueue.push(e),n}}(20),uu=(e,t,n=".")=>{if(!e)return;if(e[t]){if(!Object.prototype.hasOwnProperty.call(e,t))return;return e[t]}const r=t.split(n);let o=e;for(let i=0;i<r.length;){if(!o||"object"!=typeof o)return;let e,t="";for(let a=i;a<r.length;++a)if(a!==i&&(t+=n),t+=r[a],e=o[t],void 0!==e){if(["string","number","boolean"].indexOf(typeof e)>-1&&a<r.length-1)continue;i+=a-i+1;break}o=e}return o},cu=e=>e?.replace("_","-"),du={type:"logger",log(e){this.output("log",e)},warn(e){this.output("warn",e)},error(e){this.output("error",e)},output(e,t){}};class fu{constructor(e,t={}){this.init(e,t)}init(e,t={}){this.prefix=t.prefix||"i18next:",this.logger=e||du,this.options=t,this.debug=t.debug}log(...e){return this.forward(e,"log","",!0)}warn(...e){return this.forward(e,"warn","",!0)}error(...e){return this.forward(e,"error","")}deprecate(...e){return this.forward(e,"warn","WARNING DEPRECATED: ",!0)}forward(e,t,n,r){return r&&!this.debug?null:(Ql(e[0])&&(e[0]=`${n}${this.prefix} ${e[0]}`),this.logger[t](e))}create(e){return new fu(this.logger,{prefix:`${this.prefix}:${e}:`,...this.options})}clone(e){return(e=e||this.options).prefix=e.prefix||this.prefix,new fu(this.logger,e)}}var pu=new fu;class hu{constructor(){this.observers={}}on(e,t){return e.split(" ").forEach(e=>{this.observers[e]||(this.observers[e]=new Map);const n=this.observers[e].get(t)||0;this.observers[e].set(t,n+1)}),this}off(e,t){this.observers[e]&&(t?this.observers[e].delete(t):delete this.observers[e])}emit(e,...t){if(this.observers[e]){Array.from(this.observers[e].entries()).forEach(([e,n])=>{for(let r=0;r<n;r++)e(...t)})}if(this.observers["*"]){Array.from(this.observers["*"].entries()).forEach(([n,r])=>{for(let o=0;o<r;o++)n.apply(n,[e,...t])})}}}class gu extends hu{constructor(e,t={ns:["translation"],defaultNS:"translation"}){super(),this.data=e||{},this.options=t,void 0===this.options.keySeparator&&(this.options.keySeparator="."),void 0===this.options.ignoreJSONStructure&&(this.options.ignoreJSONStructure=!0)}addNamespaces(e){this.options.ns.indexOf(e)<0&&this.options.ns.push(e)}removeNamespaces(e){const t=this.options.ns.indexOf(e);t>-1&&this.options.ns.splice(t,1)}getResource(e,t,n,r={}){const o=void 0!==r.keySeparator?r.keySeparator:this.options.keySeparator,i=void 0!==r.ignoreJSONStructure?r.ignoreJSONStructure:this.options.ignoreJSONStructure;let a;e.indexOf(".")>-1?a=e.split("."):(a=[e,t],n&&(Array.isArray(n)?a.push(...n):Ql(n)&&o?a.push(...n.split(o)):a.push(n)));const s=nu(this.data,a);return!s&&!t&&!n&&e.indexOf(".")>-1&&(e=a[0],t=a[1],n=a.slice(2).join(".")),!s&&i&&Ql(n)?uu(this.data?.[e]?.[t],n,o):s}addResource(e,t,n,r,o={silent:!1}){const i=void 0!==o.keySeparator?o.keySeparator:this.options.keySeparator;let a=[e,t];n&&(a=a.concat(i?n.split(i):n)),e.indexOf(".")>-1&&(a=e.split("."),r=t,t=a[1]),this.addNamespaces(t),tu(this.data,a,r),o.silent||this.emit("added",e,t,n,r)}addResources(e,t,n,r={silent:!1}){for(const o in n)(Ql(n[o])||Array.isArray(n[o]))&&this.addResource(e,t,o,n[o],{silent:!0});r.silent||this.emit("added",e,t,n)}addResourceBundle(e,t,n,r,o,i={silent:!1,skipCopy:!1}){let a=[e,t];e.indexOf(".")>-1&&(a=e.split("."),r=n,n=t,t=a[1]),this.addNamespaces(t);let s=nu(this.data,a)||{};i.skipCopy||(n=JSON.parse(JSON.stringify(n))),r?ru(s,n,o):s={...s,...n},tu(this.data,a,s),i.silent||this.emit("added",e,t,n)}removeResourceBundle(e,t){this.hasResourceBundle(e,t)&&delete this.data[e][t],this.removeNamespaces(t),this.emit("removed",e,t)}hasResourceBundle(e,t){return void 0!==this.getResource(e,t)}getResourceBundle(e,t){return t||(t=this.options.defaultNS),this.getResource(e,t)}getDataByLanguage(e){return this.data[e]}hasLanguageSomeTranslations(e){const t=this.getDataByLanguage(e);return!!(t&&Object.keys(t)||[]).find(e=>t[e]&&Object.keys(t[e]).length>0)}toJSON(){return this.data}}var mu={processors:{},addPostProcessor(e){this.processors[e.name]=e},handle(e,t,n,r,o){return e.forEach(e=>{t=this.processors[e]?.process(t,n,r,o)??t}),t}};const yu=Symbol("i18next/PATH_KEY");function vu(e,t){const{[yu]:n}=e(function(){const e=[],t=Object.create(null);let n;return t.get=(r,o)=>(n?.revoke?.(),o===yu?e:(e.push(o),n=Proxy.revocable(r,t),n.proxy)),Proxy.revocable(Object.create(null),t).proxy}());return n.join(t?.keySeparator??".")}const bu={},ku=e=>!Ql(e)&&"boolean"!=typeof e&&"number"!=typeof e;class wu extends hu{constructor(e,t={}){super(),((e,t,n)=>{e.forEach(e=>{t[e]&&(n[e]=t[e])})})(["resourceStore","languageUtils","pluralResolver","interpolator","backendConnector","i18nFormat","utils"],e,this),this.options=t,void 0===this.options.keySeparator&&(this.options.keySeparator="."),this.logger=pu.create("translator")}changeLanguage(e){e&&(this.language=e)}exists(e,t={interpolation:{}}){const n={...t};if(null==e)return!1;const r=this.resolve(e,n);if(void 0===r?.res)return!1;const o=ku(r.res);return!1!==n.returnObjects||!o}extractFromKey(e,t){let n=void 0!==t.nsSeparator?t.nsSeparator:this.options.nsSeparator;void 0===n&&(n=":");const r=void 0!==t.keySeparator?t.keySeparator:this.options.keySeparator;let o=t.ns||this.options.defaultNS||[];const i=n&&e.indexOf(n)>-1,a=!(this.options.userDefinedKeySeparator||t.keySeparator||this.options.userDefinedNsSeparator||t.nsSeparator||((e,t,n)=>{t=t||"",n=n||"";const r=su.filter(e=>t.indexOf(e)<0&&n.indexOf(e)<0);if(0===r.length)return!0;const o=lu.getRegExp(`(${r.map(e=>"?"===e?"\\?":e).join("|")})`);let i=!o.test(e);if(!i){const t=e.indexOf(n);t>0&&!o.test(e.substring(0,t))&&(i=!0)}return i})(e,n,r));if(i&&!a){const t=e.match(this.interpolator.nestingRegexp);if(t&&t.length>0)return{key:e,namespaces:Ql(o)?[o]:o};const i=e.split(n);(n!==r||n===r&&this.options.ns.indexOf(i[0])>-1)&&(o=i.shift()),e=i.join(r)}return{key:e,namespaces:Ql(o)?[o]:o}}translate(e,t,n){let r="object"==typeof t?{...t}:t;if("object"!=typeof r&&this.options.overloadTranslationOptionHandler&&(r=this.options.overloadTranslationOptionHandler(arguments)),"object"==typeof r&&(r={...r}),r||(r={}),null==e)return"";"function"==typeof e&&(e=vu(e,{...this.options,...r})),Array.isArray(e)||(e=[String(e)]);const o=void 0!==r.returnDetails?r.returnDetails:this.options.returnDetails,i=void 0!==r.keySeparator?r.keySeparator:this.options.keySeparator,{key:a,namespaces:s}=this.extractFromKey(e[e.length-1],r),l=s[s.length-1];let u=void 0!==r.nsSeparator?r.nsSeparator:this.options.nsSeparator;void 0===u&&(u=":");const c=r.lng||this.language,d=r.appendNamespaceToCIMode||this.options.appendNamespaceToCIMode;if("cimode"===c?.toLowerCase())return d?o?{res:`${l}${u}${a}`,usedKey:a,exactUsedKey:a,usedLng:c,usedNS:l,usedParams:this.getUsedParamsDetails(r)}:`${l}${u}${a}`:o?{res:a,usedKey:a,exactUsedKey:a,usedLng:c,usedNS:l,usedParams:this.getUsedParamsDetails(r)}:a;const f=this.resolve(e,r);let p=f?.res;const h=f?.usedKey||a,g=f?.exactUsedKey||a,m=void 0!==r.joinArrays?r.joinArrays:this.options.joinArrays,y=!this.i18nFormat||this.i18nFormat.handleAsObject,v=void 0!==r.count&&!Ql(r.count),b=wu.hasDefaultValue(r),k=v?this.pluralResolver.getSuffix(c,r.count,r):"",w=r.ordinal&&v?this.pluralResolver.getSuffix(c,r.count,{ordinal:!1}):"",x=v&&!r.ordinal&&0===r.count,S=x&&r[`defaultValue${this.options.pluralSeparator}zero`]||r[`defaultValue${k}`]||r[`defaultValue${w}`]||r.defaultValue;let E=p;y&&!p&&b&&(E=S);const C=ku(E),T=Object.prototype.toString.apply(E);if(!(y&&E&&C&&["[object Number]","[object Function]","[object RegExp]"].indexOf(T)<0)||Ql(m)&&Array.isArray(E))if(y&&Ql(m)&&Array.isArray(p))p=p.join(m),p&&(p=this.extendTranslation(p,e,r,n));else{let t=!1,o=!1;!this.isValidLookup(p)&&b&&(t=!0,p=S),this.isValidLookup(p)||(o=!0,p=a);const s=(r.missingKeyNoValueFallbackToKey||this.options.missingKeyNoValueFallbackToKey)&&o?void 0:p,d=b&&S!==p&&this.options.updateMissing;if(o||t||d){if(this.logger.log(d?"updateKey":"missingKey",c,l,a,d?S:p),i){const e=this.resolve(a,{...r,keySeparator:!1});e&&e.res&&this.logger.warn("Seems the loaded translations were in flat JSON format instead of nested. Either set keySeparator: false on init or make sure your translations are published in nested format.")}let e=[];const t=this.languageUtils.getFallbackCodes(this.options.fallbackLng,r.lng||this.language);if("fallback"===this.options.saveMissingTo&&t&&t[0])for(let r=0;r<t.length;r++)e.push(t[r]);else"all"===this.options.saveMissingTo?e=this.languageUtils.toResolveHierarchy(r.lng||this.language):e.push(r.lng||this.language);const n=(e,t,n)=>{const o=b&&n!==p?n:s;this.options.missingKeyHandler?this.options.missingKeyHandler(e,l,t,o,d,r):this.backendConnector?.saveMissing&&this.backendConnector.saveMissing(e,l,t,o,d,r),this.emit("missingKey",e,l,t,p)};this.options.saveMissing&&(this.options.saveMissingPlurals&&v?e.forEach(e=>{const t=this.pluralResolver.getSuffixes(e,r);x&&r[`defaultValue${this.options.pluralSeparator}zero`]&&t.indexOf(`${this.options.pluralSeparator}zero`)<0&&t.push(`${this.options.pluralSeparator}zero`),t.forEach(t=>{n([e],a+t,r[`defaultValue${t}`]||S)})}):n(e,a,S))}p=this.extendTranslation(p,e,r,f,n),o&&p===a&&this.options.appendNamespaceToMissingKey&&(p=`${l}${u}${a}`),(o||t)&&this.options.parseMissingKeyHandler&&(p=this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey?`${l}${u}${a}`:a,t?p:void 0,r))}else{if(!r.returnObjects&&!this.options.returnObjects){this.options.returnedObjectHandler||this.logger.warn("accessing an object - but returnObjects options is not enabled!");const e=this.options.returnedObjectHandler?this.options.returnedObjectHandler(h,E,{...r,ns:s}):`key '${a} (${this.language})' returned an object instead of string.`;return o?(f.res=e,f.usedParams=this.getUsedParamsDetails(r),f):e}if(i){const e=Array.isArray(E),t=e?[]:{},n=e?g:h;for(const o in E)if(Object.prototype.hasOwnProperty.call(E,o)){const e=`${n}${i}${o}`;t[o]=b&&!p?this.translate(e,{...r,defaultValue:ku(S)?S[o]:void 0,joinArrays:!1,ns:s}):this.translate(e,{...r,joinArrays:!1,ns:s}),t[o]===e&&(t[o]=E[o])}p=t}}return o?(f.res=p,f.usedParams=this.getUsedParamsDetails(r),f):p}extendTranslation(e,t,n,r,o){if(this.i18nFormat?.parse)e=this.i18nFormat.parse(e,{...this.options.interpolation.defaultVariables,...n},n.lng||this.language||r.usedLng,r.usedNS,r.usedKey,{resolved:r});else if(!n.skipInterpolation){n.interpolation&&this.interpolator.init({...n,interpolation:{...this.options.interpolation,...n.interpolation}});const i=Ql(e)&&(void 0!==n?.interpolation?.skipOnVariables?n.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables);let a;if(i){const t=e.match(this.interpolator.nestingRegexp);a=t&&t.length}let s=n.replace&&!Ql(n.replace)?n.replace:n;if(this.options.interpolation.defaultVariables&&(s={...this.options.interpolation.defaultVariables,...s}),e=this.interpolator.interpolate(e,s,n.lng||this.language||r.usedLng,n),i){const t=e.match(this.interpolator.nestingRegexp);a<(t&&t.length)&&(n.nest=!1)}!n.lng&&r&&r.res&&(n.lng=this.language||r.usedLng),!1!==n.nest&&(e=this.interpolator.nest(e,(...e)=>o?.[0]!==e[0]||n.context?this.translate(...e,t):(this.logger.warn(`It seems you are nesting recursively key: ${e[0]} in key: ${t[0]}`),null),n)),n.interpolation&&this.interpolator.reset()}const i=n.postProcess||this.options.postProcess,a=Ql(i)?[i]:i;return null!=e&&a?.length&&!1!==n.applyPostProcessor&&(e=mu.handle(a,e,t,this.options&&this.options.postProcessPassResolved?{i18nResolved:{...r,usedParams:this.getUsedParamsDetails(n)},...n}:n,this)),e}resolve(e,t={}){let n,r,o,i,a;return Ql(e)&&(e=[e]),e.forEach(e=>{if(this.isValidLookup(n))return;const s=this.extractFromKey(e,t),l=s.key;r=l;let u=s.namespaces;this.options.fallbackNS&&(u=u.concat(this.options.fallbackNS));const c=void 0!==t.count&&!Ql(t.count),d=c&&!t.ordinal&&0===t.count,f=void 0!==t.context&&(Ql(t.context)||"number"==typeof t.context)&&""!==t.context,p=t.lngs?t.lngs:this.languageUtils.toResolveHierarchy(t.lng||this.language,t.fallbackLng);u.forEach(e=>{this.isValidLookup(n)||(a=e,bu[`${p[0]}-${e}`]||!this.utils?.hasLoadedNamespace||this.utils?.hasLoadedNamespace(a)||(bu[`${p[0]}-${e}`]=!0,this.logger.warn(`key "${r}" for languages "${p.join(", ")}" won't get resolved as namespace "${a}" was not yet loaded`,"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")),p.forEach(r=>{if(this.isValidLookup(n))return;i=r;const a=[l];if(this.i18nFormat?.addLookupKeys)this.i18nFormat.addLookupKeys(a,l,r,e,t);else{let e;c&&(e=this.pluralResolver.getSuffix(r,t.count,t));const n=`${this.options.pluralSeparator}zero`,o=`${this.options.pluralSeparator}ordinal${this.options.pluralSeparator}`;if(c&&(t.ordinal&&0===e.indexOf(o)&&a.push(l+e.replace(o,this.options.pluralSeparator)),a.push(l+e),d&&a.push(l+n)),f){const r=`${l}${this.options.contextSeparator||"_"}${t.context}`;a.push(r),c&&(t.ordinal&&0===e.indexOf(o)&&a.push(r+e.replace(o,this.options.pluralSeparator)),a.push(r+e),d&&a.push(r+n))}}let s;for(;s=a.pop();)this.isValidLookup(n)||(o=s,n=this.getResource(r,e,s,t))}))})}),{res:n,usedKey:r,exactUsedKey:o,usedLng:i,usedNS:a}}isValidLookup(e){return!(void 0===e||!this.options.returnNull&&null===e||!this.options.returnEmptyString&&""===e)}getResource(e,t,n,r={}){return this.i18nFormat?.getResource?this.i18nFormat.getResource(e,t,n,r):this.resourceStore.getResource(e,t,n,r)}getUsedParamsDetails(e={}){const t=["defaultValue","ordinal","context","replace","lng","lngs","fallbackLng","ns","keySeparator","nsSeparator","returnObjects","returnDetails","joinArrays","postProcess","interpolation"],n=e.replace&&!Ql(e.replace);let r=n?e.replace:e;if(n&&void 0!==e.count&&(r.count=e.count),this.options.interpolation.defaultVariables&&(r={...this.options.interpolation.defaultVariables,...r}),!n){r={...r};for(const e of t)delete r[e]}return r}static hasDefaultValue(e){const t="defaultValue";for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&t===n.substring(0,12)&&void 0!==e[n])return!0;return!1}}class xu{constructor(e){this.options=e,this.supportedLngs=this.options.supportedLngs||!1,this.logger=pu.create("languageUtils")}getScriptPartFromCode(e){if(!(e=cu(e))||e.indexOf("-")<0)return null;const t=e.split("-");return 2===t.length?null:(t.pop(),"x"===t[t.length-1].toLowerCase()?null:this.formatLanguageCode(t.join("-")))}getLanguagePartFromCode(e){if(!(e=cu(e))||e.indexOf("-")<0)return e;const t=e.split("-");return this.formatLanguageCode(t[0])}formatLanguageCode(e){if(Ql(e)&&e.indexOf("-")>-1){let t;try{t=Intl.getCanonicalLocales(e)[0]}catch(Ie){}return t&&this.options.lowerCaseLng&&(t=t.toLowerCase()),t||(this.options.lowerCaseLng?e.toLowerCase():e)}return this.options.cleanCode||this.options.lowerCaseLng?e.toLowerCase():e}isSupportedCode(e){return("languageOnly"===this.options.load||this.options.nonExplicitSupportedLngs)&&(e=this.getLanguagePartFromCode(e)),!this.supportedLngs||!this.supportedLngs.length||this.supportedLngs.indexOf(e)>-1}getBestMatchFromCodes(e){if(!e)return null;let t;return e.forEach(e=>{if(t)return;const n=this.formatLanguageCode(e);this.options.supportedLngs&&!this.isSupportedCode(n)||(t=n)}),!t&&this.options.supportedLngs&&e.forEach(e=>{if(t)return;const n=this.getScriptPartFromCode(e);if(this.isSupportedCode(n))return t=n;const r=this.getLanguagePartFromCode(e);if(this.isSupportedCode(r))return t=r;t=this.options.supportedLngs.find(e=>e===r?e:e.indexOf("-")<0&&r.indexOf("-")<0?void 0:e.indexOf("-")>0&&r.indexOf("-")<0&&e.substring(0,e.indexOf("-"))===r||0===e.indexOf(r)&&r.length>1?e:void 0)}),t||(t=this.getFallbackCodes(this.options.fallbackLng)[0]),t}getFallbackCodes(e,t){if(!e)return[];if("function"==typeof e&&(e=e(t)),Ql(e)&&(e=[e]),Array.isArray(e))return e;if(!t)return e.default||[];let n=e[t];return n||(n=e[this.getScriptPartFromCode(t)]),n||(n=e[this.formatLanguageCode(t)]),n||(n=e[this.getLanguagePartFromCode(t)]),n||(n=e.default),n||[]}toResolveHierarchy(e,t){const n=this.getFallbackCodes((!1===t?[]:t)||this.options.fallbackLng||[],e),r=[],o=e=>{e&&(this.isSupportedCode(e)?r.push(e):this.logger.warn(`rejecting language code not found in supportedLngs: ${e}`))};return Ql(e)&&(e.indexOf("-")>-1||e.indexOf("_")>-1)?("languageOnly"!==this.options.load&&o(this.formatLanguageCode(e)),"languageOnly"!==this.options.load&&"currentOnly"!==this.options.load&&o(this.getScriptPartFromCode(e)),"currentOnly"!==this.options.load&&o(this.getLanguagePartFromCode(e))):Ql(e)&&o(this.formatLanguageCode(e)),n.forEach(e=>{r.indexOf(e)<0&&o(this.formatLanguageCode(e))}),r}}const Su={zero:0,one:1,two:2,few:3,many:4,other:5},Eu={select:e=>1===e?"one":"other",resolvedOptions:()=>({pluralCategories:["one","other"]})};class Cu{constructor(e,t={}){this.languageUtils=e,this.options=t,this.logger=pu.create("pluralResolver"),this.pluralRulesCache={}}addRule(e,t){this.rules[e]=t}clearCache(){this.pluralRulesCache={}}getRule(e,t={}){const n=cu("dev"===e?"en":e),r=t.ordinal?"ordinal":"cardinal",o=JSON.stringify({cleanedCode:n,type:r});if(o in this.pluralRulesCache)return this.pluralRulesCache[o];let i;try{i=new Intl.PluralRules(n,{type:r})}catch(a){if(!Intl)return this.logger.error("No Intl support, please use an Intl polyfill!"),Eu;if(!e.match(/-|_/))return Eu;const n=this.languageUtils.getLanguagePartFromCode(e);i=this.getRule(n,t)}return this.pluralRulesCache[o]=i,i}needsPlural(e,t={}){let n=this.getRule(e,t);return n||(n=this.getRule("dev",t)),n?.resolvedOptions().pluralCategories.length>1}getPluralFormsOfKey(e,t,n={}){return this.getSuffixes(e,n).map(e=>`${t}${e}`)}getSuffixes(e,t={}){let n=this.getRule(e,t);return n||(n=this.getRule("dev",t)),n?n.resolvedOptions().pluralCategories.sort((e,t)=>Su[e]-Su[t]).map(e=>`${this.options.prepend}${t.ordinal?`ordinal${this.options.prepend}`:""}${e}`):[]}getSuffix(e,t,n={}){const r=this.getRule(e,n);return r?`${this.options.prepend}${n.ordinal?`ordinal${this.options.prepend}`:""}${r.select(t)}`:(this.logger.warn(`no plural rule found for: ${e}`),this.getSuffix("dev",t,n))}}const Tu=(e,t,n,r=".",o=!0)=>{let i=((e,t,n)=>{const r=nu(e,n);return void 0!==r?r:nu(t,n)})(e,t,n);return!i&&o&&Ql(n)&&(i=uu(e,n,r),void 0===i&&(i=uu(t,n,r))),i},Nu=e=>e.replace(/\$/g,"$$$$");class Ou{constructor(e={}){this.logger=pu.create("interpolator"),this.options=e,this.format=e?.interpolation?.format||(e=>e),this.init(e)}init(e={}){e.interpolation||(e.interpolation={escapeValue:!0});const{escape:t,escapeValue:n,useRawValueToEscape:r,prefix:o,prefixEscaped:i,suffix:a,suffixEscaped:s,formatSeparator:l,unescapeSuffix:u,unescapePrefix:c,nestingPrefix:d,nestingPrefixEscaped:f,nestingSuffix:p,nestingSuffixEscaped:h,nestingOptionsSeparator:g,maxReplaces:m,alwaysFormat:y}=e.interpolation;this.escape=void 0!==t?t:au,this.escapeValue=void 0===n||n,this.useRawValueToEscape=void 0!==r&&r,this.prefix=o?ou(o):i||"{{",this.suffix=a?ou(a):s||"}}",this.formatSeparator=l||",",this.unescapePrefix=u?"":c||"-",this.unescapeSuffix=this.unescapePrefix?"":u||"",this.nestingPrefix=d?ou(d):f||ou("$t("),this.nestingSuffix=p?ou(p):h||ou(")"),this.nestingOptionsSeparator=g||",",this.maxReplaces=m||1e3,this.alwaysFormat=void 0!==y&&y,this.resetRegExp()}reset(){this.options&&this.init(this.options)}resetRegExp(){const e=(e,t)=>e?.source===t?(e.lastIndex=0,e):new RegExp(t,"g");this.regexp=e(this.regexp,`${this.prefix}(.+?)${this.suffix}`),this.regexpUnescape=e(this.regexpUnescape,`${this.prefix}${this.unescapePrefix}(.+?)${this.unescapeSuffix}${this.suffix}`),this.nestingRegexp=e(this.nestingRegexp,`${this.nestingPrefix}((?:[^()"']+|"[^"]*"|'[^']*'|\\((?:[^()]|"[^"]*"|'[^']*')*\\))*?)${this.nestingSuffix}`)}interpolate(e,t,n,r){let o,i,a;const s=this.options&&this.options.interpolation&&this.options.interpolation.defaultVariables||{},l=e=>{if(e.indexOf(this.formatSeparator)<0){const o=Tu(t,s,e,this.options.keySeparator,this.options.ignoreJSONStructure);return this.alwaysFormat?this.format(o,void 0,n,{...r,...t,interpolationkey:e}):o}const o=e.split(this.formatSeparator),i=o.shift().trim(),a=o.join(this.formatSeparator).trim();return this.format(Tu(t,s,i,this.options.keySeparator,this.options.ignoreJSONStructure),a,n,{...r,...t,interpolationkey:i})};this.resetRegExp();const u=r?.missingInterpolationHandler||this.options.missingInterpolationHandler,c=void 0!==r?.interpolation?.skipOnVariables?r.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables;return[{regex:this.regexpUnescape,safeValue:e=>Nu(e)},{regex:this.regexp,safeValue:e=>this.escapeValue?Nu(this.escape(e)):Nu(e)}].forEach(t=>{for(a=0;o=t.regex.exec(e);){const n=o[1].trim();if(i=l(n),void 0===i)if("function"==typeof u){const t=u(e,o,r);i=Ql(t)?t:""}else if(r&&Object.prototype.hasOwnProperty.call(r,n))i="";else{if(c){i=o[0];continue}this.logger.warn(`missed to pass in variable ${n} for interpolating ${e}`),i=""}else Ql(i)||this.useRawValueToEscape||(i=Yl(i));const s=t.safeValue(i);if(e=e.replace(o[0],s),c?(t.regex.lastIndex+=i.length,t.regex.lastIndex-=o[0].length):t.regex.lastIndex=0,a++,a>=this.maxReplaces)break}}),e}nest(e,t,n={}){let r,o,i;const a=(e,t)=>{const n=this.nestingOptionsSeparator;if(e.indexOf(n)<0)return e;const r=e.split(new RegExp(`${n}[ ]*{`));let o=`{${r[1]}`;e=r[0],o=this.interpolate(o,i);const a=o.match(/'/g),s=o.match(/"/g);((a?.length??0)%2==0&&!s||s.length%2!=0)&&(o=o.replace(/'/g,'"'));try{i=JSON.parse(o),t&&(i={...t,...i})}catch(Ie){return this.logger.warn(`failed parsing options string in nesting for key ${e}`,Ie),`${e}${n}${o}`}return i.defaultValue&&i.defaultValue.indexOf(this.prefix)>-1&&delete i.defaultValue,e};for(;r=this.nestingRegexp.exec(e);){let s=[];i={...n},i=i.replace&&!Ql(i.replace)?i.replace:i,i.applyPostProcessor=!1,delete i.defaultValue;const l=/{.*}/.test(r[1])?r[1].lastIndexOf("}")+1:r[1].indexOf(this.formatSeparator);if(-1!==l&&(s=r[1].slice(l).split(this.formatSeparator).map(e=>e.trim()).filter(Boolean),r[1]=r[1].slice(0,l)),o=t(a.call(this,r[1].trim(),i),i),o&&r[0]===e&&!Ql(o))return o;Ql(o)||(o=Yl(o)),o||(this.logger.warn(`missed to resolve ${r[1]} for nesting ${e}`),o=""),s.length&&(o=s.reduce((e,t)=>this.format(e,t,n.lng,{...n,interpolationkey:r[1].trim()}),o.trim())),e=e.replace(r[0],o),this.regexp.lastIndex=0}return e}}const Pu=e=>{const t={};return(n,r,o)=>{let i=o;o&&o.interpolationkey&&o.formatParams&&o.formatParams[o.interpolationkey]&&o[o.interpolationkey]&&(i={...i,[o.interpolationkey]:void 0});const a=r+JSON.stringify(i);let s=t[a];return s||(s=e(cu(r),o),t[a]=s),s(n)}},Lu=e=>(t,n,r)=>e(cu(n),r)(t);class _u{constructor(e={}){this.logger=pu.create("formatter"),this.options=e,this.init(e)}init(e,t={interpolation:{}}){this.formatSeparator=t.interpolation.formatSeparator||",";const n=t.cacheInBuiltFormats?Pu:Lu;this.formats={number:n((e,t)=>{const n=new Intl.NumberFormat(e,{...t});return e=>n.format(e)}),currency:n((e,t)=>{const n=new Intl.NumberFormat(e,{...t,style:"currency"});return e=>n.format(e)}),datetime:n((e,t)=>{const n=new Intl.DateTimeFormat(e,{...t});return e=>n.format(e)}),relativetime:n((e,t)=>{const n=new Intl.RelativeTimeFormat(e,{...t});return e=>n.format(e,t.range||"day")}),list:n((e,t)=>{const n=new Intl.ListFormat(e,{...t});return e=>n.format(e)})}}add(e,t){this.formats[e.toLowerCase().trim()]=t}addCached(e,t){this.formats[e.toLowerCase().trim()]=Pu(t)}format(e,t,n,r={}){const o=t.split(this.formatSeparator);if(o.length>1&&o[0].indexOf("(")>1&&o[0].indexOf(")")<0&&o.find(e=>e.indexOf(")")>-1)){const e=o.findIndex(e=>e.indexOf(")")>-1);o[0]=[o[0],...o.splice(1,e)].join(this.formatSeparator)}const i=o.reduce((e,t)=>{const{formatName:o,formatOptions:i}=(e=>{let t=e.toLowerCase().trim();const n={};if(e.indexOf("(")>-1){const r=e.split("(");t=r[0].toLowerCase().trim();const o=r[1].substring(0,r[1].length-1);"currency"===t&&o.indexOf(":")<0?n.currency||(n.currency=o.trim()):"relativetime"===t&&o.indexOf(":")<0?n.range||(n.range=o.trim()):o.split(";").forEach(e=>{if(e){const[t,...r]=e.split(":"),o=r.join(":").trim().replace(/^'+|'+$/g,""),i=t.trim();n[i]||(n[i]=o),"false"===o&&(n[i]=!1),"true"===o&&(n[i]=!0),isNaN(o)||(n[i]=parseInt(o,10))}})}return{formatName:t,formatOptions:n}})(t);if(this.formats[o]){let t=e;try{const a=r?.formatParams?.[r.interpolationkey]||{},s=a.locale||a.lng||r.locale||r.lng||n;t=this.formats[o](e,s,{...i,...r,...a})}catch(a){this.logger.warn(a)}return t}return this.logger.warn(`there was no format function for ${o}`),e},e);return i}}class Ru extends hu{constructor(e,t,n,r={}){super(),this.backend=e,this.store=t,this.services=n,this.languageUtils=n.languageUtils,this.options=r,this.logger=pu.create("backendConnector"),this.waitingReads=[],this.maxParallelReads=r.maxParallelReads||10,this.readingCalls=0,this.maxRetries=r.maxRetries>=0?r.maxRetries:5,this.retryTimeout=r.retryTimeout>=1?r.retryTimeout:350,this.state={},this.queue=[],this.backend?.init?.(n,r.backend,r)}queueLoad(e,t,n,r){const o={},i={},a={},s={};return e.forEach(e=>{let r=!0;t.forEach(t=>{const a=`${e}|${t}`;!n.reload&&this.store.hasResourceBundle(e,t)?this.state[a]=2:this.state[a]<0||(1===this.state[a]?void 0===i[a]&&(i[a]=!0):(this.state[a]=1,r=!1,void 0===i[a]&&(i[a]=!0),void 0===o[a]&&(o[a]=!0),void 0===s[t]&&(s[t]=!0)))}),r||(a[e]=!0)}),(Object.keys(o).length||Object.keys(i).length)&&this.queue.push({pending:i,pendingCount:Object.keys(i).length,loaded:{},errors:[],callback:r}),{toLoad:Object.keys(o),pending:Object.keys(i),toLoadLanguages:Object.keys(a),toLoadNamespaces:Object.keys(s)}}loaded(e,t,n){const r=e.split("|"),o=r[0],i=r[1];t&&this.emit("failedLoading",o,i,t),!t&&n&&this.store.addResourceBundle(o,i,n,void 0,void 0,{skipCopy:!0}),this.state[e]=t?-1:2,t&&n&&(this.state[e]=0);const a={};this.queue.forEach(n=>{((e,t,n)=>{const{obj:r,k:o}=eu(e,t,Object);r[o]=r[o]||[],r[o].push(n)})(n.loaded,[o],i),((e,t)=>{void 0!==e.pending[t]&&(delete e.pending[t],e.pendingCount--)})(n,e),t&&n.errors.push(t),0!==n.pendingCount||n.done||(Object.keys(n.loaded).forEach(e=>{a[e]||(a[e]={});const t=n.loaded[e];t.length&&t.forEach(t=>{void 0===a[e][t]&&(a[e][t]=!0)})}),n.done=!0,n.errors.length?n.callback(n.errors):n.callback())}),this.emit("loaded",a),this.queue=this.queue.filter(e=>!e.done)}read(e,t,n,r=0,o=this.retryTimeout,i){if(!e.length)return i(null,{});if(this.readingCalls>=this.maxParallelReads)return void this.waitingReads.push({lng:e,ns:t,fcName:n,tried:r,wait:o,callback:i});this.readingCalls++;const a=(a,s)=>{if(this.readingCalls--,this.waitingReads.length>0){const e=this.waitingReads.shift();this.read(e.lng,e.ns,e.fcName,e.tried,e.wait,e.callback)}a&&s&&r<this.maxRetries?setTimeout(()=>{this.read.call(this,e,t,n,r+1,2*o,i)},o):i(a,s)},s=this.backend[n].bind(this.backend);if(2!==s.length)return s(e,t,a);try{const n=s(e,t);n&&"function"==typeof n.then?n.then(e=>a(null,e)).catch(a):a(null,n)}catch(l){a(l)}}prepareLoading(e,t,n={},r){if(!this.backend)return this.logger.warn("No backend was added via i18next.use. Will not load resources."),r&&r();Ql(e)&&(e=this.languageUtils.toResolveHierarchy(e)),Ql(t)&&(t=[t]);const o=this.queueLoad(e,t,n,r);if(!o.toLoad.length)return o.pending.length||r(),null;o.toLoad.forEach(e=>{this.loadOne(e)})}load(e,t,n){this.prepareLoading(e,t,{},n)}reload(e,t,n){this.prepareLoading(e,t,{reload:!0},n)}loadOne(e,t=""){const n=e.split("|"),r=n[0],o=n[1];this.read(r,o,"read",void 0,void 0,(n,i)=>{n&&this.logger.warn(`${t}loading namespace ${o} for language ${r} failed`,n),!n&&i&&this.logger.log(`${t}loaded namespace ${o} for language ${r}`,i),this.loaded(e,n,i)})}saveMissing(e,t,n,r,o,i={},a=()=>{}){if(!this.services?.utils?.hasLoadedNamespace||this.services?.utils?.hasLoadedNamespace(t)){if(null!=n&&""!==n){if(this.backend?.create){const l={...i,isUpdate:o},u=this.backend.create.bind(this.backend);if(u.length<6)try{let o;o=5===u.length?u(e,t,n,r,l):u(e,t,n,r),o&&"function"==typeof o.then?o.then(e=>a(null,e)).catch(a):a(null,o)}catch(s){a(s)}else u(e,t,n,r,a,l)}e&&e[0]&&this.store.addResource(e[0],t,n,r)}}else this.logger.warn(`did not save key "${n}" as the namespace "${t}" was not yet loaded`,"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")}}const Iu=()=>({debug:!1,initAsync:!0,ns:["translation"],defaultNS:["translation"],fallbackLng:["dev"],fallbackNS:!1,supportedLngs:!1,nonExplicitSupportedLngs:!1,load:"all",preload:!1,simplifyPluralSuffix:!0,keySeparator:".",nsSeparator:":",pluralSeparator:"_",contextSeparator:"_",partialBundledLanguages:!1,saveMissing:!1,updateMissing:!1,saveMissingTo:"fallback",saveMissingPlurals:!0,missingKeyHandler:!1,missingInterpolationHandler:!1,postProcess:!1,postProcessPassResolved:!1,returnNull:!1,returnEmptyString:!0,returnObjects:!1,joinArrays:!1,returnedObjectHandler:!1,parseMissingKeyHandler:!1,appendNamespaceToMissingKey:!1,appendNamespaceToCIMode:!1,overloadTranslationOptionHandler:e=>{let t={};if("object"==typeof e[1]&&(t=e[1]),Ql(e[1])&&(t.defaultValue=e[1]),Ql(e[2])&&(t.tDescription=e[2]),"object"==typeof e[2]||"object"==typeof e[3]){const n=e[3]||e[2];Object.keys(n).forEach(e=>{t[e]=n[e]})}return t},interpolation:{escapeValue:!0,format:e=>e,prefix:"{{",suffix:"}}",formatSeparator:",",unescapePrefix:"-",nestingPrefix:"$t(",nestingSuffix:")",nestingOptionsSeparator:",",maxReplaces:1e3,skipOnVariables:!0},cacheInBuiltFormats:!0}),Au=e=>(Ql(e.ns)&&(e.ns=[e.ns]),Ql(e.fallbackLng)&&(e.fallbackLng=[e.fallbackLng]),Ql(e.fallbackNS)&&(e.fallbackNS=[e.fallbackNS]),e.supportedLngs?.indexOf?.("cimode")<0&&(e.supportedLngs=e.supportedLngs.concat(["cimode"])),"boolean"==typeof e.initImmediate&&(e.initAsync=e.initImmediate),e),zu=()=>{};class ju extends hu{constructor(e={},t){var n;if(super(),this.options=Au(e),this.services={},this.logger=pu,this.modules={external:[]},n=this,Object.getOwnPropertyNames(Object.getPrototypeOf(n)).forEach(e=>{"function"==typeof n[e]&&(n[e]=n[e].bind(n))}),t&&!this.isInitialized&&!e.isClone){if(!this.options.initAsync)return this.init(e,t),this;setTimeout(()=>{this.init(e,t)},0)}}init(e={},t){this.isInitializing=!0,"function"==typeof e&&(t=e,e={}),null==e.defaultNS&&e.ns&&(Ql(e.ns)?e.defaultNS=e.ns:e.ns.indexOf("translation")<0&&(e.defaultNS=e.ns[0]));const n=Iu();this.options={...n,...this.options,...Au(e)},this.options.interpolation={...n.interpolation,...this.options.interpolation},void 0!==e.keySeparator&&(this.options.userDefinedKeySeparator=e.keySeparator),void 0!==e.nsSeparator&&(this.options.userDefinedNsSeparator=e.nsSeparator);const r=e=>e?"function"==typeof e?new e:e:null;if(!this.options.isClone){let e;this.modules.logger?pu.init(r(this.modules.logger),this.options):pu.init(null,this.options),e=this.modules.formatter?this.modules.formatter:_u;const t=new xu(this.options);this.store=new gu(this.options.resources,this.options);const o=this.services;o.logger=pu,o.resourceStore=this.store,o.languageUtils=t,o.pluralResolver=new Cu(t,{prepend:this.options.pluralSeparator,simplifyPluralSuffix:this.options.simplifyPluralSuffix});this.options.interpolation.format&&this.options.interpolation.format!==n.interpolation.format&&this.logger.deprecate("init: you are still using the legacy format function, please use the new approach: https://www.i18next.com/translation-function/formatting"),!e||this.options.interpolation.format&&this.options.interpolation.format!==n.interpolation.format||(o.formatter=r(e),o.formatter.init&&o.formatter.init(o,this.options),this.options.interpolation.format=o.formatter.format.bind(o.formatter)),o.interpolator=new Ou(this.options),o.utils={hasLoadedNamespace:this.hasLoadedNamespace.bind(this)},o.backendConnector=new Ru(r(this.modules.backend),o.resourceStore,o,this.options),o.backendConnector.on("*",(e,...t)=>{this.emit(e,...t)}),this.modules.languageDetector&&(o.languageDetector=r(this.modules.languageDetector),o.languageDetector.init&&o.languageDetector.init(o,this.options.detection,this.options)),this.modules.i18nFormat&&(o.i18nFormat=r(this.modules.i18nFormat),o.i18nFormat.init&&o.i18nFormat.init(this)),this.translator=new wu(this.services,this.options),this.translator.on("*",(e,...t)=>{this.emit(e,...t)}),this.modules.external.forEach(e=>{e.init&&e.init(this)})}if(this.format=this.options.interpolation.format,t||(t=zu),this.options.fallbackLng&&!this.services.languageDetector&&!this.options.lng){const e=this.services.languageUtils.getFallbackCodes(this.options.fallbackLng);e.length>0&&"dev"!==e[0]&&(this.options.lng=e[0])}this.services.languageDetector||this.options.lng||this.logger.warn("init: no languageDetector is used and no lng is defined");["getResource","hasResourceBundle","getResourceBundle","getDataByLanguage"].forEach(e=>{this[e]=(...t)=>this.store[e](...t)});["addResource","addResources","addResourceBundle","removeResourceBundle"].forEach(e=>{this[e]=(...t)=>(this.store[e](...t),this)});const o=Jl(),i=()=>{const e=(e,n)=>{this.isInitializing=!1,this.isInitialized&&!this.initializedStoreOnce&&this.logger.warn("init: i18next is already initialized. You should call init just once!"),this.isInitialized=!0,this.options.isClone||this.logger.log("initialized",this.options),this.emit("initialized",this.options),o.resolve(n),t(e,n)};if(this.languages&&!this.isInitialized)return e(null,this.t.bind(this));this.changeLanguage(this.options.lng,e)};return this.options.resources||!this.options.initAsync?i():setTimeout(i,0),o}loadResources(e,t=zu){let n=t;const r=Ql(e)?e:this.language;if("function"==typeof e&&(n=e),!this.options.resources||this.options.partialBundledLanguages){if("cimode"===r?.toLowerCase()&&(!this.options.preload||0===this.options.preload.length))return n();const e=[],t=t=>{if(!t)return;if("cimode"===t)return;this.services.languageUtils.toResolveHierarchy(t).forEach(t=>{"cimode"!==t&&e.indexOf(t)<0&&e.push(t)})};if(r)t(r);else{this.services.languageUtils.getFallbackCodes(this.options.fallbackLng).forEach(e=>t(e))}this.options.preload?.forEach?.(e=>t(e)),this.services.backendConnector.load(e,this.options.ns,e=>{e||this.resolvedLanguage||!this.language||this.setResolvedLanguage(this.language),n(e)})}else n(null)}reloadResources(e,t,n){const r=Jl();return"function"==typeof e&&(n=e,e=void 0),"function"==typeof t&&(n=t,t=void 0),e||(e=this.languages),t||(t=this.options.ns),n||(n=zu),this.services.backendConnector.reload(e,t,e=>{r.resolve(),n(e)}),r}use(e){if(!e)throw new Error("You are passing an undefined module! Please check the object you are passing to i18next.use()");if(!e.type)throw new Error("You are passing a wrong module! Please check the object you are passing to i18next.use()");return"backend"===e.type&&(this.modules.backend=e),("logger"===e.type||e.log&&e.warn&&e.error)&&(this.modules.logger=e),"languageDetector"===e.type&&(this.modules.languageDetector=e),"i18nFormat"===e.type&&(this.modules.i18nFormat=e),"postProcessor"===e.type&&mu.addPostProcessor(e),"formatter"===e.type&&(this.modules.formatter=e),"3rdParty"===e.type&&this.modules.external.push(e),this}setResolvedLanguage(e){if(e&&this.languages&&!(["cimode","dev"].indexOf(e)>-1)){for(let e=0;e<this.languages.length;e++){const t=this.languages[e];if(!(["cimode","dev"].indexOf(t)>-1)&&this.store.hasLanguageSomeTranslations(t)){this.resolvedLanguage=t;break}}!this.resolvedLanguage&&this.languages.indexOf(e)<0&&this.store.hasLanguageSomeTranslations(e)&&(this.resolvedLanguage=e,this.languages.unshift(e))}}changeLanguage(e,t){this.isLanguageChangingTo=e;const n=Jl();this.emit("languageChanging",e);const r=e=>{this.language=e,this.languages=this.services.languageUtils.toResolveHierarchy(e),this.resolvedLanguage=void 0,this.setResolvedLanguage(e)},o=(o,i)=>{i?this.isLanguageChangingTo===e&&(r(i),this.translator.changeLanguage(i),this.isLanguageChangingTo=void 0,this.emit("languageChanged",i),this.logger.log("languageChanged",i)):this.isLanguageChangingTo=void 0,n.resolve((...e)=>this.t(...e)),t&&t(o,(...e)=>this.t(...e))},i=t=>{e||t||!this.services.languageDetector||(t=[]);const n=Ql(t)?t:t&&t[0],i=this.store.hasLanguageSomeTranslations(n)?n:this.services.languageUtils.getBestMatchFromCodes(Ql(t)?[t]:t);i&&(this.language||r(i),this.translator.language||this.translator.changeLanguage(i),this.services.languageDetector?.cacheUserLanguage?.(i)),this.loadResources(i,e=>{o(e,i)})};return e||!this.services.languageDetector||this.services.languageDetector.async?!e&&this.services.languageDetector&&this.services.languageDetector.async?0===this.services.languageDetector.detect.length?this.services.languageDetector.detect().then(i):this.services.languageDetector.detect(i):i(e):i(this.services.languageDetector.detect()),n}getFixedT(e,t,n){const r=(e,t,...o)=>{let i;i="object"!=typeof t?this.options.overloadTranslationOptionHandler([e,t].concat(o)):{...t},i.lng=i.lng||r.lng,i.lngs=i.lngs||r.lngs,i.ns=i.ns||r.ns,""!==i.keyPrefix&&(i.keyPrefix=i.keyPrefix||n||r.keyPrefix);const a=this.options.keySeparator||".";let s;return i.keyPrefix&&Array.isArray(e)?s=e.map(e=>("function"==typeof e&&(e=vu(e,{...this.options,...t})),`${i.keyPrefix}${a}${e}`)):("function"==typeof e&&(e=vu(e,{...this.options,...t})),s=i.keyPrefix?`${i.keyPrefix}${a}${e}`:e),this.t(s,i)};return Ql(e)?r.lng=e:r.lngs=e,r.ns=t,r.keyPrefix=n,r}t(...e){return this.translator?.translate(...e)}exists(...e){return this.translator?.exists(...e)}setDefaultNamespace(e){this.options.defaultNS=e}hasLoadedNamespace(e,t={}){if(!this.isInitialized)return this.logger.warn("hasLoadedNamespace: i18next was not initialized",this.languages),!1;if(!this.languages||!this.languages.length)return this.logger.warn("hasLoadedNamespace: i18n.languages were undefined or empty",this.languages),!1;const n=t.lng||this.resolvedLanguage||this.languages[0],r=!!this.options&&this.options.fallbackLng,o=this.languages[this.languages.length-1];if("cimode"===n.toLowerCase())return!0;const i=(e,t)=>{const n=this.services.backendConnector.state[`${e}|${t}`];return-1===n||0===n||2===n};if(t.precheck){const e=t.precheck(this,i);if(void 0!==e)return e}return!!this.hasResourceBundle(n,e)||(!(this.services.backendConnector.backend&&(!this.options.resources||this.options.partialBundledLanguages))||!(!i(n,e)||r&&!i(o,e)))}loadNamespaces(e,t){const n=Jl();return this.options.ns?(Ql(e)&&(e=[e]),e.forEach(e=>{this.options.ns.indexOf(e)<0&&this.options.ns.push(e)}),this.loadResources(e=>{n.resolve(),t&&t(e)}),n):(t&&t(),Promise.resolve())}loadLanguages(e,t){const n=Jl();Ql(e)&&(e=[e]);const r=this.options.preload||[],o=e.filter(e=>r.indexOf(e)<0&&this.services.languageUtils.isSupportedCode(e));return o.length?(this.options.preload=r.concat(o),this.loadResources(e=>{n.resolve(),t&&t(e)}),n):(t&&t(),Promise.resolve())}dir(e){if(e||(e=this.resolvedLanguage||(this.languages?.length>0?this.languages[0]:this.language)),!e)return"rtl";try{const t=new Intl.Locale(e);if(t&&t.getTextInfo){const e=t.getTextInfo();if(e&&e.direction)return e.direction}}catch(Ie){}const t=this.services?.languageUtils||new xu(Iu());return e.toLowerCase().indexOf("-latn")>1?"ltr":["ar","shu","sqr","ssh","xaa","yhd","yud","aao","abh","abv","acm","acq","acw","acx","acy","adf","ads","aeb","aec","afb","ajp","apc","apd","arb","arq","ars","ary","arz","auz","avl","ayh","ayl","ayn","ayp","bbz","pga","he","iw","ps","pbt","pbu","pst","prp","prd","ug","ur","ydd","yds","yih","ji","yi","hbo","men","xmn","fa","jpr","peo","pes","prs","dv","sam","ckb"].indexOf(t.getLanguagePartFromCode(e))>-1||e.toLowerCase().indexOf("-arab")>1?"rtl":"ltr"}static createInstance(e={},t){return new ju(e,t)}cloneInstance(e={},t=zu){const n=e.forkResourceStore;n&&delete e.forkResourceStore;const r={...this.options,...e,isClone:!0},o=new ju(r);void 0===e.debug&&void 0===e.prefix||(o.logger=o.logger.clone(e));if(["store","services","language"].forEach(e=>{o[e]=this[e]}),o.services={...this.services},o.services.utils={hasLoadedNamespace:o.hasLoadedNamespace.bind(o)},n){const e=Object.keys(this.store.data).reduce((e,t)=>(e[t]={...this.store.data[t]},e[t]=Object.keys(e[t]).reduce((n,r)=>(n[r]={...e[t][r]},n),e[t]),e),{});o.store=new gu(e,r),o.services.resourceStore=o.store}return o.translator=new wu(o.services,r),o.translator.on("*",(e,...t)=>{o.emit(e,...t)}),o.init(r,t),o.translator.options=r,o.translator.backendConnector.services.utils={hasLoadedNamespace:o.hasLoadedNamespace.bind(o)},o}toJSON(){return{options:this.options,store:this.store,language:this.language,languages:this.languages,resolvedLanguage:this.resolvedLanguage}}}const Du=ju.createInstance();Du.createInstance=ju.createInstance,Du.createInstance,Du.dir,Du.init,Du.loadResources,Du.reloadResources,Du.use,Du.changeLanguage,Du.getFixedT,Du.t,Du.exists,Du.setDefaultNamespace,Du.hasLoadedNamespace,Du.loadNamespaces,Du.loadLanguages;const{slice:Fu,forEach:Mu}=[];const Uu=/^[\u0009\u0020-\u007e\u0080-\u00ff]+$/,Bu={create(e,t,n,r){let o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{path:"/",sameSite:"strict"};n&&(o.expires=new Date,o.expires.setTime(o.expires.getTime()+60*n*1e3)),r&&(o.domain=r),document.cookie=function(e,t){const n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{path:"/"};let r=`${e}=${encodeURIComponent(t)}`;if(n.maxAge>0){const e=n.maxAge-0;if(Number.isNaN(e))throw new Error("maxAge should be a Number");r+=`; Max-Age=${Math.floor(e)}`}if(n.domain){if(!Uu.test(n.domain))throw new TypeError("option domain is invalid");r+=`; Domain=${n.domain}`}if(n.path){if(!Uu.test(n.path))throw new TypeError("option path is invalid");r+=`; Path=${n.path}`}if(n.expires){if("function"!=typeof n.expires.toUTCString)throw new TypeError("option expires is invalid");r+=`; Expires=${n.expires.toUTCString()}`}if(n.httpOnly&&(r+="; HttpOnly"),n.secure&&(r+="; Secure"),n.sameSite)switch("string"==typeof n.sameSite?n.sameSite.toLowerCase():n.sameSite){case!0:r+="; SameSite=Strict";break;case"lax":r+="; SameSite=Lax";break;case"strict":r+="; SameSite=Strict";break;case"none":r+="; SameSite=None";break;default:throw new TypeError("option sameSite is invalid")}return n.partitioned&&(r+="; Partitioned"),r}(e,t,o)},read(e){const t=`${e}=`,n=document.cookie.split(";");for(let r=0;r<n.length;r++){let e=n[r];for(;" "===e.charAt(0);)e=e.substring(1,e.length);if(0===e.indexOf(t))return e.substring(t.length,e.length)}return null},remove(e,t){this.create(e,"",-1,t)}};var $u={name:"cookie",lookup(e){let{lookupCookie:t}=e;if(t&&"undefined"!=typeof document)return Bu.read(t)||void 0},cacheUserLanguage(e,t){let{lookupCookie:n,cookieMinutes:r,cookieDomain:o,cookieOptions:i}=t;n&&"undefined"!=typeof document&&Bu.create(n,e,r,o,i)}},Vu={name:"querystring",lookup(e){let t,{lookupQuerystring:n}=e;if("undefined"!=typeof window){let{search:e}=window.location;!window.location.search&&window.location.hash?.indexOf("?")>-1&&(e=window.location.hash.substring(window.location.hash.indexOf("?")));const r=e.substring(1).split("&");for(let o=0;o<r.length;o++){const e=r[o].indexOf("=");if(e>0){r[o].substring(0,e)===n&&(t=r[o].substring(e+1))}}}return t}},Hu={name:"hash",lookup(e){let t,{lookupHash:n,lookupFromHashIndex:r}=e;if("undefined"!=typeof window){const{hash:e}=window.location;if(e&&e.length>2){const o=e.substring(1);if(n){const e=o.split("&");for(let r=0;r<e.length;r++){const o=e[r].indexOf("=");if(o>0){e[r].substring(0,o)===n&&(t=e[r].substring(o+1))}}}if(t)return t;if(!t&&r>-1){const t=e.match(/\/([a-zA-Z-]*)/g);if(!Array.isArray(t))return;const n="number"==typeof r?r:0;return t[n]?.replace("/","")}}}return t}};let qu=null;const Wu=()=>{if(null!==qu)return qu;try{if(qu="undefined"!=typeof window&&null!==window.localStorage,!qu)return!1;const e="i18next.translate.boo";window.localStorage.setItem(e,"foo"),window.localStorage.removeItem(e)}catch(Ie){qu=!1}return qu};var Ku={name:"localStorage",lookup(e){let{lookupLocalStorage:t}=e;if(t&&Wu())return window.localStorage.getItem(t)||void 0},cacheUserLanguage(e,t){let{lookupLocalStorage:n}=t;n&&Wu()&&window.localStorage.setItem(n,e)}};let Qu=null;const Ju=()=>{if(null!==Qu)return Qu;try{if(Qu="undefined"!=typeof window&&null!==window.sessionStorage,!Qu)return!1;const e="i18next.translate.boo";window.sessionStorage.setItem(e,"foo"),window.sessionStorage.removeItem(e)}catch(Ie){Qu=!1}return Qu};var Yu={name:"sessionStorage",lookup(e){let{lookupSessionStorage:t}=e;if(t&&Ju())return window.sessionStorage.getItem(t)||void 0},cacheUserLanguage(e,t){let{lookupSessionStorage:n}=t;n&&Ju()&&window.sessionStorage.setItem(n,e)}},Gu={name:"navigator",lookup(e){const t=[];if("undefined"!=typeof navigator){const{languages:e,userLanguage:n,language:r}=navigator;if(e)for(let o=0;o<e.length;o++)t.push(e[o]);n&&t.push(n),r&&t.push(r)}return t.length>0?t:void 0}},Xu={name:"htmlTag",lookup(e){let t,{htmlTag:n}=e;const r=n||("undefined"!=typeof document?document.documentElement:null);return r&&"function"==typeof r.getAttribute&&(t=r.getAttribute("lang")),t}},Zu={name:"path",lookup(e){let{lookupFromPathIndex:t}=e;if("undefined"==typeof window)return;const n=window.location.pathname.match(/\/([a-zA-Z-]*)/g);if(!Array.isArray(n))return;const r="number"==typeof t?t:0;return n[r]?.replace("/","")}},ec={name:"subdomain",lookup(e){let{lookupFromSubdomainIndex:t}=e;const n="number"==typeof t?t+1:1,r="undefined"!=typeof window&&window.location?.hostname?.match(/^(\w{2,5})\.(([a-z0-9-]{1,63}\.[a-z]{2,6})|localhost)/i);if(r)return r[n]}};let tc=!1;try{document.cookie,tc=!0}catch(Ie){}const nc=["querystring","cookie","localStorage","sessionStorage","navigator","htmlTag"];tc||nc.splice(1,1);class rc{constructor(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.type="languageDetector",this.detectors={},this.init(e,t)}init(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{languageUtils:{}},t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};this.services=e,this.options=function(e){return Mu.call(Fu.call(arguments,1),t=>{if(t)for(const n in t)void 0===e[n]&&(e[n]=t[n])}),e}(t,this.options||{},{order:nc,lookupQuerystring:"lng",lookupCookie:"i18next",lookupLocalStorage:"i18nextLng",lookupSessionStorage:"i18nextLng",caches:["localStorage"],excludeCacheFor:["cimode"],convertDetectedLanguage:e=>e}),"string"==typeof this.options.convertDetectedLanguage&&this.options.convertDetectedLanguage.indexOf("15897")>-1&&(this.options.convertDetectedLanguage=e=>e.replace("-","_")),this.options.lookupFromUrlIndex&&(this.options.lookupFromPathIndex=this.options.lookupFromUrlIndex),this.i18nOptions=n,this.addDetector($u),this.addDetector(Vu),this.addDetector(Ku),this.addDetector(Yu),this.addDetector(Gu),this.addDetector(Xu),this.addDetector(Zu),this.addDetector(ec),this.addDetector(Hu)}addDetector(e){return this.detectors[e.name]=e,this}detect(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.options.order,t=[];return e.forEach(e=>{if(this.detectors[e]){let n=this.detectors[e].lookup(this.options);n&&"string"==typeof n&&(n=[n]),n&&(t=t.concat(n))}}),t=t.filter(e=>{return null!=e&&!("string"==typeof(t=e)&&[/<\s*script.*?>/i,/<\s*\/\s*script\s*>/i,/<\s*img.*?on\w+\s*=/i,/<\s*\w+\s*on\w+\s*=.*?>/i,/javascript\s*:/i,/vbscript\s*:/i,/expression\s*\(/i,/eval\s*\(/i,/alert\s*\(/i,/document\.cookie/i,/document\.write\s*\(/i,/window\.location/i,/innerHTML/i].some(e=>e.test(t)));var t}).map(e=>this.options.convertDetectedLanguage(e)),this.services&&this.services.languageUtils&&this.services.languageUtils.getBestMatchFromCodes?t:t.length>0?t[0]:null}cacheUserLanguage(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.options.caches;t&&(this.options.excludeCacheFor&&this.options.excludeCacheFor.indexOf(e)>-1||t.forEach(t=>{this.detectors[t]&&this.detectors[t].cacheUserLanguage(e,this.options)}))}}rc.type="languageDetector";const oc={widget:{title:"TIA GPC",poweredBy:"Desarrollado por TIA GPC",questionsTo:"Preguntas a"},chat:{title:"Asistente",placeholder:"Escribe tu pregunta...",send:"Enviar",close:"Cerrar",welcome:"¡Hola! Bienvenido a {{companyName}}. ¿En qué puedo ayudarte hoy?",emptyState:"Inicia una conversación escribiendo tu pregunta",validation:"Verificando seguridad...",retry:"Reintentar"},theme:{light:"Claro",dark:"Oscuro",toggle:"Cambiar tema"},errors:{unauthorized:"Autenticación fallida. Por favor, verifica tu token de licencia e intenta nuevamente.",validation:"Verificación anti-bot fallida. Por favor, recarga la página e intenta nuevamente.",network:"No se pudo conectar al servidor. Verifica tu conexión a internet.",rateLimit:"Has realizado demasiadas consultas o se alcanzó el límite de usuarios concurrentes. Por favor, espera un momento antes de continuar.",session:"Tu sesión ha expirado por inactividad. Por favor, recarga la página para continuar.",insufficientCredits:"Créditos insuficientes. Por favor, recarga créditos desde tu panel de administración para continuar usando TIA GPC.",generic:"Ha ocurrido un error inesperado. Por favor, intenta nuevamente.",aiServiceUnavailable:"El asistente está temporalmente no disponible. Por favor, intenta de nuevo en unos momentos.",serverError:"El servidor encontró un problema. Por favor, intenta de nuevo más tarde.",domainUnauthorized:"Este dominio no está autorizado para usar este widget. Por favor, contacta a tu administrador."},turnstile:{verifying:"Verificando que eres humano...",error:"No se pudo completar la verificación de seguridad. Por favor, recarga la página e intenta nuevamente."},metadata:{tokensUsed:"Tokens usados",responseTime:"Tiempo de respuesta",model:"Modelo"}},ic={widget:{title:"TIA GPC",poweredBy:"Powered by TIA GPC",questionsTo:"Questions to"},chat:{title:"Assistant",placeholder:"Type your question...",send:"Send",close:"Close",welcome:"Hello! Welcome to {{companyName}}. How can I help you today?",emptyState:"Start a conversation by typing your question",validation:"Verifying security...",retry:"Retry"},theme:{light:"Light",dark:"Dark",toggle:"Toggle theme"},errors:{unauthorized:"Authentication failed. Please check your license token and try again.",validation:"Bot verification failed. Please reload the page and try again.",network:"Unable to connect to the server. Please check your internet connection.",rateLimit:"You've made too many requests or the concurrent user limit has been reached. Please wait a moment before continuing.",session:"Your session has expired due to inactivity. Please reload the page to continue.",insufficientCredits:"Insufficient credits. Please reload credits from your admin panel to continue using TIA GPC.",generic:"An unexpected error has occurred. Please try again.",aiServiceUnavailable:"The assistant is temporarily unavailable. Please try again in a few moments.",serverError:"The server encountered a problem. Please try again later.",domainUnauthorized:"This domain is not authorized to use this widget. Please contact your administrator."},turnstile:{verifying:"Verifying you're human...",error:"Security verification could not be completed. Please reload the page and try again."},metadata:{tokensUsed:"Tokens used",responseTime:"Response time",model:"Model"}},ac={widget:{title:"TIA GPC",poweredBy:"Propulsé par TIA GPC",questionsTo:"Questions à"},chat:{title:"Assistant",placeholder:"Tapez votre question...",send:"Envoyer",close:"Fermer",welcome:"Bonjour ! Bienvenue à {{companyName}}. Comment puis-je vous aider aujourd'hui ?",emptyState:"Commencez une conversation en tapant votre question",validation:"Vérification de sécurité...",retry:"Réessayer"},theme:{light:"Clair",dark:"Sombre",toggle:"Changer de thème"},errors:{unauthorized:"Échec de l'authentification. Veuillez vérifier votre jeton de licence et réessayer.",validation:"La vérification anti-bot a échoué. Veuillez recharger la page et réessayer.",network:"Impossible de se connecter au serveur. Veuillez vérifier votre connexion internet.",rateLimit:"Vous avez fait trop de demandes ou la limite d'utilisateurs concurrents a été atteinte. Veuillez patienter un moment avant de continuer.",session:"Votre session a expiré en raison d'inactivité. Veuillez recharger la page pour continuer.",insufficientCredits:"Crédits insuffisants. Veuillez recharger des crédits depuis votre panneau d'administration pour continuer à utiliser TIA GPC.",generic:"Une erreur inattendue s'est produite. Veuillez réessayer.",aiServiceUnavailable:"L'assistant est temporairement indisponible. Veuillez réessayer dans quelques instants.",serverError:"Le serveur a rencontré un problème. Veuillez réessayer plus tard.",domainUnauthorized:"Ce domaine n'est pas autorisé à utiliser ce widget. Veuillez contacter votre administrateur."},turnstile:{verifying:"Vérification que vous êtes humain...",error:"La vérification de sécurité n'a pas pu être complétée. Veuillez recharger la page et réessayer."},metadata:{tokensUsed:"Tokens utilisés",responseTime:"Temps de réponse",model:"Modèle"}};Du.use(rc).use(M).init({resources:{en:{translation:ic},es:{translation:oc},fr:{translation:ac}},fallbackLng:"en",supportedLngs:["en","es","fr"],interpolation:{escapeValue:!1},detection:{order:["localStorage","navigator"],caches:["localStorage"]}});const sc=({token:e,turnstileSiteKey:t="0x4AAAAAAB-BKyDZcYYqCbid",theme:n=Yi,position:r=Gi,language:o=Xi,primaryColor:i,width:a=Zi,height:s=ea,apiUrl:u=qi,onReady:c,onError:d,onClose:f,autoOpen:p=ta,showBranding:h=na,mobileFullscreen:g=ra,...m})=>{const[y,v]=l.useState(p),[b,k]=l.useState(!1),[w,x]=l.useState(null),[S,E]=l.useState(!0),C=l.useMemo(()=>new Kl(u,e),[u,e]);if(l.useEffect(()=>{const e=()=>{k(window.innerWidth<Ji)};return e(),window.addEventListener("resize",e),()=>window.removeEventListener("resize",e)},[]),l.useEffect(()=>{o&&Du.changeLanguage&&Du.changeLanguage(o)},[o]),l.useEffect(()=>{(async()=>{if(e)try{const e=await C.getInitConfig();e.success&&(x(e.data),c&&c(e.data))}catch(t){d&&d(t)}finally{E(!1)}else E(!1)})()},[e,C,c,d]),!e)return null;return N.jsx(H,{i18n:Du,children:N.jsxs("div",{className:`gpc-widget gpc-widget-container ${b&&g?"gpc-position-bottom-right":`gpc-position-${r}`} ${"dark"===n?"gpc-dark":""}`,style:(()=>{const e={};return i&&(e["--gpc-color-primary"]=i),b&&g||(a&&(e["--gpc-widget-width"]=a),s&&(e["--gpc-widget-height"]=s)),e})(),children:[!y&&N.jsx(ie,{onClick:()=>v(!0),widgetConfig:w}),y&&!S&&N.jsx(Ca,{gpcService:C,licenseToken:e,widgetConfig:w,turnstileSiteKey:t,onClose:()=>{v(!1),f?.()},themeMode:n,showBranding:h,showMetadata:m.showMetadata||!1,onError:d})]})})};sc.defaultProps={theme:"auto",position:"bottom-right",language:"en",width:"400px",height:"600px",autoOpen:!1,showBranding:!0,mobileFullscreen:!0};class lc extends HTMLElement{constructor(){super(),this.root=null,this.mountPoint=null}static get observedAttributes(){return["token","theme","position","language","primary-color","width","height","api-url","turnstile-site-key","auto-open","show-branding","mobile-fullscreen"]}connectedCallback(){this.mountPoint=document.createElement("div"),this.mountPoint.className="tia-gpc-mount",this.appendChild(this.mountPoint),this.root=E.createRoot(this.mountPoint),this.render()}disconnectedCallback(){this.root&&(this.root.unmount(),this.root=null)}attributeChangedCallback(e,t,n){t!==n&&this.root&&this.render()}getProps(){const e={},t=this.getAttribute("token");t&&(e.token=t);const n=this.getAttribute("theme");n&&(e.theme=n);const r=this.getAttribute("position");r&&(e.position=r);const o=this.getAttribute("language");o&&(e.language=o);const i=this.getAttribute("primary-color");i&&(e.primaryColor=i);const a=this.getAttribute("width");a&&(e.width=a);const s=this.getAttribute("height");s&&(e.height=s);const l=this.getAttribute("api-url");l&&(e.apiUrl=l);const u=this.getAttribute("turnstile-site-key");u&&(e.turnstileSiteKey=u);const c=this.getAttribute("auto-open");null!==c&&(e.autoOpen="false"!==c);const d=this.getAttribute("show-branding");null!==d&&(e.showBranding="false"!==d);const f=this.getAttribute("mobile-fullscreen");return null!==f&&(e.mobileFullscreen="false"!==f),e.onReady=()=>{this.dispatchEvent(new CustomEvent("ready",{bubbles:!0,composed:!0}))},e.onError=e=>{this.dispatchEvent(new CustomEvent("error",{bubbles:!0,composed:!0,detail:e}))},e.onClose=()=>{this.dispatchEvent(new CustomEvent("close",{bubbles:!0,composed:!0}))},e}render(){if(!this.root)return;const e=this.getProps();this.root.render(u.createElement(sc,e))}open(){this.dispatchEvent(new CustomEvent("open-widget",{bubbles:!0,composed:!0}))}close(){this.dispatchEvent(new CustomEvent("close-widget",{bubbles:!0,composed:!0}))}}"undefined"==typeof window||customElements.get("tia-gpc-widget")||customElements.define("tia-gpc-widget",lc),window.TiaGPC={version:"1.0.0",POSITIONS:Wi,THEMES:Ki,LANGUAGES:Qi,create(e){if(!e||!e.token)throw new Error('TiaGPC.create(): El parámetro "token" es requerido');const t=document.createElement("tia-gpc-widget");t.setAttribute("token",e.token),e.theme&&t.setAttribute("theme",e.theme),e.position&&t.setAttribute("position",e.position),e.language&&t.setAttribute("language",e.language),e.primaryColor&&t.setAttribute("primary-color",e.primaryColor),e.width&&t.setAttribute("width",e.width),e.height&&t.setAttribute("height",e.height),e.apiUrl&&t.setAttribute("api-url",e.apiUrl),e.turnstileSiteKey&&t.setAttribute("turnstile-site-key",e.turnstileSiteKey),void 0!==e.autoOpen&&t.setAttribute("auto-open",String(e.autoOpen)),void 0!==e.showBranding&&t.setAttribute("show-branding",String(e.showBranding)),void 0!==e.mobileFullscreen&&t.setAttribute("mobile-fullscreen",String(e.mobileFullscreen)),e.onReady&&t.addEventListener("ready",e.onReady),e.onError&&t.addEventListener("error",t=>e.onError(t.detail)),e.onClose&&t.addEventListener("close",e.onClose);return(e.container||document.body).appendChild(t),t},info(){return{version:this.version,positions:this.POSITIONS,themes:this.THEMES,languages:this.LANGUAGES}}};const uc=window.TiaGPC;return e.TiaGPCWebComponent=lc,e.default=uc,Object.defineProperties(e,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}}),e}({});
205
+ `,st=({reverseOrder:e,position:t="top-center",toastOptions:n,gutter:r,children:o,toasterId:i,containerStyle:a,containerClassName:s})=>{let{toasts:u,handlers:c}=Me(n,i);return l.createElement("div",{"data-rht-toaster":i||"",style:{position:"fixed",zIndex:9999,top:16,left:16,right:16,bottom:16,pointerEvents:"none",...a},className:s,onMouseEnter:c.startPause,onMouseLeave:c.endPause},u.map(n=>{let i=n.position||t,a=((e,t)=>{let n=e.includes("top"),r=n?{top:0}:{bottom:0},o=e.includes("center")?{justifyContent:"center"}:e.includes("right")?{justifyContent:"flex-end"}:{};return{left:0,right:0,display:"flex",position:"absolute",transition:Se()?void 0:"all 230ms cubic-bezier(.21,1.02,.73,1)",transform:`translateY(${t*(n?1:-1)}px)`,...r,...o}})(i,c.calculateOffset(n,{reverseOrder:e,gutter:r,defaultPosition:t}));return l.createElement(it,{id:n.id,key:n.id,onHeightUpdate:c.updateHeight,className:n.visible?at:"",style:a},"custom"===n.type?xe(n.message,n):o?o(n):l.createElement(ot,{toast:n,position:i}))}))},lt=Ae;const ut=({theme:e,onToggle:t})=>{const{t:n}=V();return O.jsx("button",{onClick:t,className:"gpc-header-button gpc-focus-visible gpc-transition","aria-label":n("theme.toggle"),title:n("theme.toggle"),children:"light"===e?O.jsx(oe,{className:"gpc-icon"}):O.jsx(ae,{className:"gpc-icon"})})},ct=[{code:"en",label:"English",flag:"🇬🇧"},{code:"es",label:"Español",flag:"🇪🇸"},{code:"fr",label:"Français",flag:"🇫🇷"}],dt=()=>{const{i18n:e}=V(),[t,n]=l.useState(!1),r=l.useRef(null),o=ct.find(t=>t.code===e.language)||ct[0];return l.useEffect(()=>{const e=e=>{r.current&&!r.current.contains(e.target)&&n(!1)};return t&&document.addEventListener("mousedown",e),()=>{document.removeEventListener("mousedown",e)}},[t]),O.jsxs("div",{className:"gpc-language-selector",ref:r,children:[O.jsx("button",{onClick:()=>n(!t),className:"gpc-header-button gpc-focus-visible gpc-transition","aria-label":"Cambiar idioma",title:"Cambiar idioma",children:O.jsx(Z,{className:"gpc-icon"})}),t&&O.jsx("div",{className:"gpc-language-dropdown",children:ct.map(t=>O.jsxs("button",{onClick:()=>{return r=t.code,e.changeLanguage(r),void n(!1);var r},className:"gpc-language-option "+(t.code===o.code?"gpc-language-option-active":""),children:[O.jsx("span",{className:"gpc-language-flag",children:t.flag}),O.jsx("span",{className:"gpc-language-label",children:t.label})]},t.code))})]})},ft=({onClose:e,theme:t,onToggleTheme:n,showBranding:r=!0,widgetConfig:o=null})=>{const{t:i}=V(),a=o?.company_name||i("widget.title"),s=o?.company_logo_base64,l=s?.startsWith("data:")?s:s?`data:image/png;base64,${s}`:null;return O.jsxs("div",{className:"gpc-chat-header",children:[O.jsxs("div",{className:"gpc-header-content",children:[l&&O.jsx("div",{className:"gpc-header-logo",children:O.jsx("img",{src:l,alt:a,className:"gpc-company-logo"})}),O.jsx("div",{className:"gpc-header-text",children:O.jsx("h2",{className:"gpc-header-title",children:a})})]}),O.jsxs("div",{className:"gpc-header-actions",children:[O.jsx(dt,{}),O.jsx(ut,{theme:t,onToggle:n}),O.jsx("button",{onClick:e,className:"gpc-header-button gpc-focus-visible gpc-transition","aria-label":i("chat.close"),title:i("chat.close"),children:O.jsx(G,{className:"gpc-icon"})})]})]})};function pt(){}function ht(){}const gt=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,mt=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,yt={};function vt(e,t){return(yt.jsx?mt:gt).test(e)}const bt=/[ \t\n\f\r]/g;function kt(e){return""===e.replace(bt,"")}class xt{constructor(e,t,n){this.normal=t,this.property=e,n&&(this.space=n)}}function wt(e,t){const n={},r={};for(const o of e)Object.assign(n,o.property),Object.assign(r,o.normal);return new xt(n,r,t)}function St(e){return e.toLowerCase()}xt.prototype.normal={},xt.prototype.property={},xt.prototype.space=void 0;class Et{constructor(e,t){this.attribute=t,this.property=e}}Et.prototype.attribute="",Et.prototype.booleanish=!1,Et.prototype.boolean=!1,Et.prototype.commaOrSpaceSeparated=!1,Et.prototype.commaSeparated=!1,Et.prototype.defined=!1,Et.prototype.mustUseProperty=!1,Et.prototype.number=!1,Et.prototype.overloadedBoolean=!1,Et.prototype.property="",Et.prototype.spaceSeparated=!1,Et.prototype.space=void 0;let Ct=0;const Tt=It(),Ot=It(),Nt=It(),Pt=It(),Lt=It(),Rt=It(),_t=It();function It(){return 2**++Ct}const At=Object.freeze(Object.defineProperty({__proto__:null,boolean:Tt,booleanish:Ot,commaOrSpaceSeparated:_t,commaSeparated:Rt,number:Pt,overloadedBoolean:Nt,spaceSeparated:Lt},Symbol.toStringTag,{value:"Module"})),Dt=Object.keys(At);class zt extends Et{constructor(e,t,n,r){let o=-1;if(super(e,t),jt(this,"space",r),"number"==typeof n)for(;++o<Dt.length;){const e=Dt[o];jt(this,Dt[o],(n&At[e])===At[e])}}}function jt(e,t,n){n&&(e[t]=n)}function Ft(e){const t={},n={};for(const[r,o]of Object.entries(e.properties)){const i=new zt(r,e.transform(e.attributes||{},r),o,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(i.mustUseProperty=!0),t[r]=i,n[St(r)]=r,n[St(i.attribute)]=r}return new xt(t,n,e.space)}zt.prototype.defined=!0;const Mt=Ft({properties:{ariaActiveDescendant:null,ariaAtomic:Ot,ariaAutoComplete:null,ariaBusy:Ot,ariaChecked:Ot,ariaColCount:Pt,ariaColIndex:Pt,ariaColSpan:Pt,ariaControls:Lt,ariaCurrent:null,ariaDescribedBy:Lt,ariaDetails:null,ariaDisabled:Ot,ariaDropEffect:Lt,ariaErrorMessage:null,ariaExpanded:Ot,ariaFlowTo:Lt,ariaGrabbed:Ot,ariaHasPopup:null,ariaHidden:Ot,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:Lt,ariaLevel:Pt,ariaLive:null,ariaModal:Ot,ariaMultiLine:Ot,ariaMultiSelectable:Ot,ariaOrientation:null,ariaOwns:Lt,ariaPlaceholder:null,ariaPosInSet:Pt,ariaPressed:Ot,ariaReadOnly:Ot,ariaRelevant:null,ariaRequired:Ot,ariaRoleDescription:Lt,ariaRowCount:Pt,ariaRowIndex:Pt,ariaRowSpan:Pt,ariaSelected:Ot,ariaSetSize:Pt,ariaSort:null,ariaValueMax:Pt,ariaValueMin:Pt,ariaValueNow:Pt,ariaValueText:null,role:null},transform:(e,t)=>"role"===t?t:"aria-"+t.slice(4).toLowerCase()});function Ut(e,t){return t in e?e[t]:t}function Bt(e,t){return Ut(e,t.toLowerCase())}const $t=Ft({attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:Rt,acceptCharset:Lt,accessKey:Lt,action:null,allow:null,allowFullScreen:Tt,allowPaymentRequest:Tt,allowUserMedia:Tt,alt:null,as:null,async:Tt,autoCapitalize:null,autoComplete:Lt,autoFocus:Tt,autoPlay:Tt,blocking:Lt,capture:null,charSet:null,checked:Tt,cite:null,className:Lt,cols:Pt,colSpan:null,content:null,contentEditable:Ot,controls:Tt,controlsList:Lt,coords:Pt|Rt,crossOrigin:null,data:null,dateTime:null,decoding:null,default:Tt,defer:Tt,dir:null,dirName:null,disabled:Tt,download:Nt,draggable:Ot,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:Tt,formTarget:null,headers:Lt,height:Pt,hidden:Nt,high:Pt,href:null,hrefLang:null,htmlFor:Lt,httpEquiv:Lt,id:null,imageSizes:null,imageSrcSet:null,inert:Tt,inputMode:null,integrity:null,is:null,isMap:Tt,itemId:null,itemProp:Lt,itemRef:Lt,itemScope:Tt,itemType:Lt,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:Tt,low:Pt,manifest:null,max:null,maxLength:Pt,media:null,method:null,min:null,minLength:Pt,multiple:Tt,muted:Tt,name:null,nonce:null,noModule:Tt,noValidate:Tt,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:Tt,optimum:Pt,pattern:null,ping:Lt,placeholder:null,playsInline:Tt,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:Tt,referrerPolicy:null,rel:Lt,required:Tt,reversed:Tt,rows:Pt,rowSpan:Pt,sandbox:Lt,scope:null,scoped:Tt,seamless:Tt,selected:Tt,shadowRootClonable:Tt,shadowRootDelegatesFocus:Tt,shadowRootMode:null,shape:null,size:Pt,sizes:null,slot:null,span:Pt,spellCheck:Ot,src:null,srcDoc:null,srcLang:null,srcSet:null,start:Pt,step:null,style:null,tabIndex:Pt,target:null,title:null,translate:null,type:null,typeMustMatch:Tt,useMap:null,value:Ot,width:Pt,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:Lt,axis:null,background:null,bgColor:null,border:Pt,borderColor:null,bottomMargin:Pt,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:Tt,declare:Tt,event:null,face:null,frame:null,frameBorder:null,hSpace:Pt,leftMargin:Pt,link:null,longDesc:null,lowSrc:null,marginHeight:Pt,marginWidth:Pt,noResize:Tt,noHref:Tt,noShade:Tt,noWrap:Tt,object:null,profile:null,prompt:null,rev:null,rightMargin:Pt,rules:null,scheme:null,scrolling:Ot,standby:null,summary:null,text:null,topMargin:Pt,valueType:null,version:null,vAlign:null,vLink:null,vSpace:Pt,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:Tt,disableRemotePlayback:Tt,prefix:null,property:null,results:Pt,security:null,unselectable:null},space:"html",transform:Bt}),Vt=Ft({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"},properties:{about:_t,accentHeight:Pt,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:Pt,amplitude:Pt,arabicForm:null,ascent:Pt,attributeName:null,attributeType:null,azimuth:Pt,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:Pt,by:null,calcMode:null,capHeight:Pt,className:Lt,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:Pt,diffuseConstant:Pt,direction:null,display:null,dur:null,divisor:Pt,dominantBaseline:null,download:Tt,dx:null,dy:null,edgeMode:null,editable:null,elevation:Pt,enableBackground:null,end:null,event:null,exponent:Pt,externalResourcesRequired:null,fill:null,fillOpacity:Pt,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:Rt,g2:Rt,glyphName:Rt,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:Pt,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:Pt,horizOriginX:Pt,horizOriginY:Pt,id:null,ideographic:Pt,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:Pt,k:Pt,k1:Pt,k2:Pt,k3:Pt,k4:Pt,kernelMatrix:_t,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:Pt,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:Pt,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:Pt,overlineThickness:Pt,paintOrder:null,panose1:null,path:null,pathLength:Pt,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:Lt,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:Pt,pointsAtY:Pt,pointsAtZ:Pt,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:_t,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:_t,rev:_t,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:_t,requiredFeatures:_t,requiredFonts:_t,requiredFormats:_t,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:Pt,specularExponent:Pt,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:Pt,strikethroughThickness:Pt,string:null,stroke:null,strokeDashArray:_t,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:Pt,strokeOpacity:Pt,strokeWidth:null,style:null,surfaceScale:Pt,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:_t,tabIndex:Pt,tableValues:null,target:null,targetX:Pt,targetY:Pt,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:_t,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:Pt,underlineThickness:Pt,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:Pt,values:null,vAlphabetic:Pt,vMathematical:Pt,vectorEffect:null,vHanging:Pt,vIdeographic:Pt,version:null,vertAdvY:Pt,vertOriginX:Pt,vertOriginY:Pt,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:Pt,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null},space:"svg",transform:Ut}),Ht=Ft({properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null},space:"xlink",transform:(e,t)=>"xlink:"+t.slice(5).toLowerCase()}),qt=Ft({attributes:{xmlnsxlink:"xmlns:xlink"},properties:{xmlnsXLink:null,xmlns:null},space:"xmlns",transform:Bt}),Wt=Ft({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:"xml",transform:(e,t)=>"xml:"+t.slice(3).toLowerCase()}),Kt={classId:"classID",dataType:"datatype",itemId:"itemID",strokeDashArray:"strokeDasharray",strokeDashOffset:"strokeDashoffset",strokeLineCap:"strokeLinecap",strokeLineJoin:"strokeLinejoin",strokeMiterLimit:"strokeMiterlimit",typeOf:"typeof",xLinkActuate:"xlinkActuate",xLinkArcRole:"xlinkArcrole",xLinkHref:"xlinkHref",xLinkRole:"xlinkRole",xLinkShow:"xlinkShow",xLinkTitle:"xlinkTitle",xLinkType:"xlinkType",xmlnsXLink:"xmlnsXlink"},Qt=/[A-Z]/g,Jt=/-[a-z]/g,Yt=/^data[-\w.:]+$/i;function Gt(e){return"-"+e.toLowerCase()}function Xt(e){return e.charAt(1).toUpperCase()}const Zt=wt([Mt,$t,Ht,qt,Wt],"html"),en=wt([Mt,Vt,Ht,qt,Wt],"svg");var tn,nn,rn,on={};function an(){if(rn)return on;rn=1;var e=on&&on.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(on,"__esModule",{value:!0}),on.default=function(e,n){let r=null;if(!e||"string"!=typeof e)return r;const o=(0,t.default)(e),i="function"==typeof n;return o.forEach(e=>{if("declaration"!==e.type)return;const{property:t,value:o}=e;i?n(t,o,e):o&&(r=r||{},r[t]=o)}),r};const t=e(function(){if(nn)return tn;nn=1;var e=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,t=/\n/g,n=/^\s*/,r=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,o=/^:\s*/,i=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,a=/^[;\s]*/,s=/^\s+|\s+$/g,l="";function u(e){return e?e.replace(s,l):l}return tn=function(s,c){if("string"!=typeof s)throw new TypeError("First argument must be a string");if(!s)return[];c=c||{};var d=1,f=1;function p(e){var n=e.match(t);n&&(d+=n.length);var r=e.lastIndexOf("\n");f=~r?e.length-r:f+e.length}function h(){var e={line:d,column:f};return function(t){return t.position=new g(e),v(),t}}function g(e){this.start=e,this.end={line:d,column:f},this.source=c.source}function m(e){var t=new Error(c.source+":"+d+":"+f+": "+e);if(t.reason=e,t.filename=c.source,t.line=d,t.column=f,t.source=s,!c.silent)throw t}function y(e){var t=e.exec(s);if(t){var n=t[0];return p(n),s=s.slice(n.length),t}}function v(){y(n)}function b(e){var t;for(e=e||[];t=k();)!1!==t&&e.push(t);return e}function k(){var e=h();if("/"==s.charAt(0)&&"*"==s.charAt(1)){for(var t=2;l!=s.charAt(t)&&("*"!=s.charAt(t)||"/"!=s.charAt(t+1));)++t;if(t+=2,l===s.charAt(t-1))return m("End of comment missing");var n=s.slice(2,t-2);return f+=2,p(n),s=s.slice(t),f+=2,e({type:"comment",comment:n})}}function x(){var t=h(),n=y(r);if(n){if(k(),!y(o))return m("property missing ':'");var s=y(i),c=t({type:"declaration",property:u(n[0].replace(e,l)),value:s?u(s[0].replace(e,l)):l});return y(a),c}}return g.prototype.content=s,v(),function(){var e,t=[];for(b(t);e=x();)!1!==e&&(t.push(e),b(t));return t}()}}());return on}var sn,ln,un,cn={};function dn(){if(sn)return cn;sn=1,Object.defineProperty(cn,"__esModule",{value:!0}),cn.camelCase=void 0;var e=/^--[a-zA-Z0-9_-]+$/,t=/-([a-z])/g,n=/^[^-]+$/,r=/^-(webkit|moz|ms|o|khtml)-/,o=/^-(ms)-/,i=function(e,t){return t.toUpperCase()},a=function(e,t){return"".concat(t,"-")};return cn.camelCase=function(s,l){return void 0===l&&(l={}),function(t){return!t||n.test(t)||e.test(t)}(s)?s:(s=s.toLowerCase(),(s=l.reactCompat?s.replace(o,a):s.replace(r,a)).replace(t,i))},cn}const fn=t(function(){if(un)return ln;un=1;var e=(ln&&ln.__importDefault||function(e){return e&&e.__esModule?e:{default:e}})(an()),t=dn();function n(n,r){var o={};return n&&"string"==typeof n?((0,e.default)(n,function(e,n){e&&n&&(o[(0,t.camelCase)(e,r)]=n)}),o):o}return n.default=n,ln=n}()),pn=gn("end"),hn=gn("start");function gn(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 mn(e){return e&&"object"==typeof e?"position"in e||"type"in e?vn(e.position):"start"in e||"end"in e?vn(e):"line"in e||"column"in e?yn(e):"":""}function yn(e){return bn(e&&e.line)+":"+bn(e&&e.column)}function vn(e){return yn(e&&e.start)+"-"+yn(e&&e.end)}function bn(e){return e&&"number"==typeof e?e:1}class kn extends Error{constructor(e,t,n){super(),"string"==typeof t&&(n=t,t=void 0);let r="",o={},i=!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&&(i=!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 a=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=a?a.column:void 0,this.fatal=void 0,this.file="",this.message=r,this.line=a?a.line:void 0,this.name=mn(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=i&&o.cause&&"string"==typeof o.cause.stack?o.cause.stack:"",this.actual=void 0,this.expected=void 0,this.note=void 0,this.url=void 0}}kn.prototype.file="",kn.prototype.name="",kn.prototype.reason="",kn.prototype.message="",kn.prototype.stack="",kn.prototype.column=void 0,kn.prototype.line=void 0,kn.prototype.ancestors=void 0,kn.prototype.cause=void 0,kn.prototype.fatal=void 0,kn.prototype.place=void 0,kn.prototype.ruleId=void 0,kn.prototype.source=void 0;const xn={}.hasOwnProperty,wn=new Map,Sn=/[A-Z]/g,En=new Set(["table","tbody","thead","tfoot","tr"]),Cn=new Set(["td","th"]),Tn="https://github.com/syntax-tree/hast-util-to-jsx-runtime";function On(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,i){const a=Array.isArray(o.children),s=hn(n);return t(r,o,i,a,{columnNumber:s?s.column-1:void 0,fileName:e,lineNumber:s?s.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,i){const a=Array.isArray(o.children)?n:t;return i?a(r,o,i):a(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?en:Zt,stylePropertyNameCase:t.stylePropertyNameCase||"dom",tableCellAlignToStyle:!1!==t.tableCellAlignToStyle},i=Nn(o,e,void 0);return i&&"string"!=typeof i?i:o.create(e,o.Fragment,{children:i||void 0},void 0)}function Nn(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=en,e.schema=o);e.ancestors.push(t);const i=In(e,t.tagName,!1),a=function(e,t){const n={};let r,o;for(o in t.properties)if("children"!==o&&xn.call(t.properties,o)){const i=_n(e,o,t.properties[o]);if(i){const[o,a]=i;e.tableCellAlignToStyle&&"align"===o&&"string"==typeof a&&Cn.has(t.tagName)?r=a:n[o]=a}}if(r){(n.style||(n.style={}))["css"===e.stylePropertyNameCase?"text-align":"textAlign"]=r}return n}(e,t);let s=Rn(e,t);En.has(t.tagName)&&(s=s.filter(function(e){return"string"!=typeof e||!("object"==typeof(t=e)?"text"===t.type&&kt(t.value):kt(t));var t}));return Pn(e,a,i,t),Ln(a,s),e.ancestors.pop(),e.schema=r,e.create(t,i,a,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)}An(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=en,e.schema=o);e.ancestors.push(t);const i=null===t.name?e.Fragment:In(e,t.name,!0),a=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];pt(t.type);const o=t.expression;pt(o.type);const i=o.properties[0];pt(i.type),Object.assign(n,e.evaluater.evaluateExpression(i.argument))}else An(e,t.position);else{const o=r.name;let i;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];pt(t.type),i=e.evaluater.evaluateExpression(t.expression)}else An(e,t.position);else i=null===r.value||r.value;n[o]=i}return n}(e,t),s=Rn(e,t);return Pn(e,a,i,t),Ln(a,s),e.ancestors.pop(),e.schema=r,e.create(t,i,a,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);An(e,t.position)}(e,t):"root"===t.type?function(e,t,n){const r={};return Ln(r,Rn(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 Pn(e,t,n,r){"string"!=typeof n&&n!==e.Fragment&&e.passNode&&(t.node=r)}function Ln(e,t){if(t.length>0){const n=t.length>1?t:t[0];n&&(e.children=n)}}function Rn(e,t){const n=[];let r=-1;const o=e.passKeys?new Map:wn;for(;++r<t.children.length;){const i=t.children[r];let a;if(e.passKeys){const e="element"===i.type?i.tagName:"mdxJsxFlowElement"===i.type||"mdxJsxTextElement"===i.type?i.name:void 0;if(e){const t=o.get(e)||0;a=e+"-"+t,o.set(e,t+1)}}const s=Nn(e,i,a);void 0!==s&&n.push(s)}return n}function _n(e,t,n){const r=function(e,t){const n=St(t);let r=t,o=Et;if(n in e.normal)return e.property[e.normal[n]];if(n.length>4&&"data"===n.slice(0,4)&&Yt.test(t)){if("-"===t.charAt(4)){const e=t.slice(5).replace(Jt,Xt);r="data"+e.charAt(0).toUpperCase()+e.slice(1)}else{const e=t.slice(4);if(!Jt.test(e)){let n=e.replace(Qt,Gt);"-"!==n.charAt(0)&&(n="-"+n),t="data"+n}}o=zt}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){const t={};return(""===e[e.length-1]?[...e,""]:e).join((t.padRight?" ":"")+","+(!1===t.padLeft?"":" ")).trim()}(n):n.join(" ").trim()),"style"===r.property){let t="object"==typeof n?n:function(e,t){try{return fn(t,{reactCompat:!0})}catch(n){if(e.ignoreInvalidStyle)return{};const t=n,r=new kn("Cannot parse `style` attribute",{ancestors:e.ancestors,cause:t,ruleId:"style",source:"hast-util-to-jsx-runtime"});throw r.file=e.filePath||void 0,r.url=Tn+"#cannot-parse-style-attribute",r}}(e,String(n));return"css"===e.stylePropertyNameCase&&(t=function(e){const t={};let n;for(n in e)xn.call(e,n)&&(t[Dn(n)]=e[n]);return t}(t)),["style",t]}return["react"===e.elementAttributeNameCase&&r.space?Kt[r.property]||r.property:r.attribute,n]}}function In(e,t,n){let r;if(n)if(t.includes(".")){const e=t.split(".");let n,o=-1;for(;++o<e.length;){const t=vt(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=vt(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 xn.call(e.components,t)?e.components[t]:t}if(e.evaluater)return e.evaluater.evaluateExpression(r);An(e)}function An(e,t){const n=new kn("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=Tn+"#cannot-handle-mdx-estrees-without-createevaluater",n}function Dn(e){let t=e.replace(Sn,zn);return"ms-"===t.slice(0,3)&&(t="-"+t),t}function zn(e){return"-"+e.toLowerCase()}const jn={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"]},Fn={};function Mn(e,t){return Un(e,"boolean"!=typeof Fn.includeImageAlt||Fn.includeImageAlt,"boolean"!=typeof Fn.includeHtml||Fn.includeHtml)}function Un(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 Bn(e.children,t,n)}return Array.isArray(e)?Bn(e,t,n):""}function Bn(e,t,n){const r=[];let o=-1;for(;++o<e.length;)r[o]=Un(e[o],t,n);return r.join("")}const $n=document.createElement("i");function Vn(e){const t="&"+e+";";$n.innerHTML=t;const n=$n.textContent;return(59!==n.charCodeAt(n.length-1)||"semi"===e)&&(n!==t&&n)}function Hn(e,t,n,r){const o=e.length;let i,a=0;if(t=t<0?-t>o?0:o+t:t>o?o:t,n=n>0?n:0,r.length<1e4)i=Array.from(r),i.unshift(t,n),e.splice(...i);else for(n&&e.splice(t,n);a<r.length;)i=r.slice(a,a+1e4),i.unshift(t,0),e.splice(...i),a+=1e4,t+=1e4}function qn(e,t){return e.length>0?(Hn(e,e.length,0,t),e):t}const Wn={}.hasOwnProperty;function Kn(e){const t={};let n=-1;for(;++n<e.length;)Qn(t,e[n]);return t}function Qn(e,t){let n;for(n in t){const r=(Wn.call(e,n)?e[n]:void 0)||(e[n]={}),o=t[n];let i;if(o)for(i in o){Wn.call(r,i)||(r[i]=[]);const e=o[i];Jn(r[i],Array.isArray(e)?e:e?[e]:[])}}}function Jn(e,t){let n=-1;const r=[];for(;++n<t.length;)("after"===t[n].add?e:r).push(t[n]);Hn(e,0,0,r)}function Yn(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 Gn(e){return e.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}const Xn=cr(/[A-Za-z]/),Zn=cr(/[\dA-Za-z]/),er=cr(/[#-'*+\--9=?A-Z^-~]/);function tr(e){return null!==e&&(e<32||127===e)}const nr=cr(/\d/),rr=cr(/[\dA-Fa-f]/),or=cr(/[!-/:-@[-`{-~]/);function ir(e){return null!==e&&e<-2}function ar(e){return null!==e&&(e<0||32===e)}function sr(e){return-2===e||-1===e||32===e}const lr=cr(new RegExp("\\p{P}|\\p{S}","u")),ur=cr(/\s/);function cr(e){return function(t){return null!==t&&t>-1&&e.test(String.fromCharCode(t))}}function dr(e){const t=[];let n=-1,r=0,o=0;for(;++n<e.length;){const i=e.charCodeAt(n);let a="";if(37===i&&Zn(e.charCodeAt(n+1))&&Zn(e.charCodeAt(n+2)))o=2;else if(i<128)/[!#$&-;=?-Z_a-z~]/.test(String.fromCharCode(i))||(a=String.fromCharCode(i));else if(i>55295&&i<57344){const t=e.charCodeAt(n+1);i<56320&&t>56319&&t<57344?(a=String.fromCharCode(i,t),o=1):a="�"}else a=String.fromCharCode(i);a&&(t.push(e.slice(r,n),encodeURIComponent(a)),r=n+o+1,a=""),o&&(n+=o,o=0)}return t.join("")+e.slice(r)}function fr(e,t,n,r){const o=r?r-1:Number.POSITIVE_INFINITY;let i=0;return function(r){if(sr(r))return e.enter(n),a(r);return t(r)};function a(r){return sr(r)&&i++<o?(e.consume(r),a):(e.exit(n),t(r))}}const pr={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"),fr(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)):ir(t)?(e.consume(t),e.exit("chunkText"),r):(e.consume(t),o)}}};const hr={tokenize:function(e){const t=this,n=[];let r,o,i,a=0;return s;function s(r){if(a<n.length){const o=n[a];return t.containerState=o[1],e.attempt(o[0].continuation,l,u)(r)}return u(r)}function l(e){if(a++,t.containerState._closeFlow){t.containerState._closeFlow=void 0,r&&v();const n=t.events.length;let o,i=n;for(;i--;)if("exit"===t.events[i][0]&&"chunkFlow"===t.events[i][1].type){o=t.events[i][1].end;break}y(a);let s=n;for(;s<t.events.length;)t.events[s][1].end={...o},s++;return Hn(t.events,i+1,0,t.events.slice(n)),t.events.length=s,u(e)}return s(e)}function u(o){if(a===n.length){if(!r)return f(o);if(r.currentConstruct&&r.currentConstruct.concrete)return h(o);t.interrupt=Boolean(r.currentConstruct&&!r._gfmTableDynamicInterruptHack)}return t.containerState={},e.check(gr,c,d)(o)}function c(e){return r&&v(),y(a),f(e)}function d(e){return t.parser.lazy[t.now().line]=a!==n.length,i=t.now().offset,h(e)}function f(n){return t.containerState={},e.attempt(gr,p,h)(n)}function p(e){return a++,n.push([t.currentConstruct,t.containerState]),f(e)}function h(n){return null===n?(r&&v(),y(0),void e.consume(n)):(r=r||t.parser.flow(t.now()),e.enter("chunkFlow",{_tokenizer:r,contentType:"flow",previous:o}),g(n))}function g(n){return null===n?(m(e.exit("chunkFlow"),!0),y(0),void e.consume(n)):ir(n)?(e.consume(n),m(e.exit("chunkFlow")),a=0,t.interrupt=void 0,s):(e.consume(n),g)}function m(e,n){const s=t.sliceStream(e);if(n&&s.push(null),e.previous=o,o&&(o.next=e),o=e,r.defineSkip(e.start),r.write(s),t.parser.lazy[e.start.line]){let e=r.events.length;for(;e--;)if(r.events[e][1].start.offset<i&&(!r.events[e][1].end||r.events[e][1].end.offset>i))return;const n=t.events.length;let o,s,l=n;for(;l--;)if("exit"===t.events[l][0]&&"chunkFlow"===t.events[l][1].type){if(o){s=t.events[l][1].end;break}o=!0}for(y(a),e=n;e<t.events.length;)t.events[e][1].end={...s},e++;Hn(t.events,l+1,0,t.events.slice(n)),t.events.length=e}}function y(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 v(){r.write([null]),o=void 0,r=void 0,t.containerState._closeFlow=void 0}}},gr={tokenize:function(e,t,n){return fr(e,e.attempt(this.parser.constructs.document,t,n),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}};function mr(e){return null===e||ar(e)||ur(e)?1:lr(e)?2:void 0}function yr(e,t,n){const r=[];let o=-1;for(;++o<e.length;){const i=e[o].resolveAll;i&&!r.includes(i)&&(t=i(t,n),r.push(i))}return t}const vr={name:"attention",resolveAll:function(e,t){let n,r,o,i,a,s,l,u,c=-1;for(;++c<e.length;)if("enter"===e[c][0]&&"attentionSequence"===e[c][1].type&&e[c][1]._close)for(n=c;n--;)if("exit"===e[n][0]&&"attentionSequence"===e[n][1].type&&e[n][1]._open&&t.sliceSerialize(e[n][1]).charCodeAt(0)===t.sliceSerialize(e[c][1]).charCodeAt(0)){if((e[n][1]._close||e[c][1]._open)&&(e[c][1].end.offset-e[c][1].start.offset)%3&&!((e[n][1].end.offset-e[n][1].start.offset+e[c][1].end.offset-e[c][1].start.offset)%3))continue;s=e[n][1].end.offset-e[n][1].start.offset>1&&e[c][1].end.offset-e[c][1].start.offset>1?2:1;const d={...e[n][1].end},f={...e[c][1].start};br(d,-s),br(f,s),i={type:s>1?"strongSequence":"emphasisSequence",start:d,end:{...e[n][1].end}},a={type:s>1?"strongSequence":"emphasisSequence",start:{...e[c][1].start},end:f},o={type:s>1?"strongText":"emphasisText",start:{...e[n][1].end},end:{...e[c][1].start}},r={type:s>1?"strong":"emphasis",start:{...i.start},end:{...a.end}},e[n][1].end={...i.start},e[c][1].start={...a.end},l=[],e[n][1].end.offset-e[n][1].start.offset&&(l=qn(l,[["enter",e[n][1],t],["exit",e[n][1],t]])),l=qn(l,[["enter",r,t],["enter",i,t],["exit",i,t],["enter",o,t]]),l=qn(l,yr(t.parser.constructs.insideSpan.null,e.slice(n+1,c),t)),l=qn(l,[["exit",o,t],["enter",a,t],["exit",a,t],["exit",r,t]]),e[c][1].end.offset-e[c][1].start.offset?(u=2,l=qn(l,[["enter",e[c][1],t],["exit",e[c][1],t]])):u=0,Hn(e,n-1,c-n+3,l),c=n+l.length-u-2;break}c=-1;for(;++c<e.length;)"attentionSequence"===e[c][1].type&&(e[c][1].type="data");return e},tokenize:function(e,t){const n=this.parser.constructs.attentionMarkers.null,r=this.previous,o=mr(r);let i;return function(t){return i=t,e.enter("attentionSequence"),a(t)};function a(s){if(s===i)return e.consume(s),a;const l=e.exit("attentionSequence"),u=mr(s),c=!u||2===u&&o||n.includes(s),d=!o||2===o&&u||n.includes(r);return l._open=Boolean(42===i?c:c&&(o||!d)),l._close=Boolean(42===i?d:d&&(u||!c)),t(s)}}};function br(e,t){e.column+=t,e.offset+=t,e._bufferIndex+=t}const kr={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 Xn(t)?(e.consume(t),i):64===t?n(t):l(t)}function i(e){return 43===e||45===e||46===e||Zn(e)?(r=1,a(e)):l(e)}function a(t){return 58===t?(e.consume(t),r=0,s):(43===t||45===t||46===t||Zn(t))&&r++<32?(e.consume(t),a):(r=0,l(t))}function s(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||tr(r)?n(r):(e.consume(r),s)}function l(t){return 64===t?(e.consume(t),u):er(t)?(e.consume(t),l):n(t)}function u(e){return Zn(e)?c(e):n(e)}function c(n){return 46===n?(e.consume(n),r=0,u):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||Zn(t))&&r++<63){const n=45===t?d:c;return e.consume(t),n}return n(t)}}};const xr={partial:!0,tokenize:function(e,t,n){return function(t){return sr(t)?fr(e,r,"linePrefix")(t):r(t)};function r(e){return null===e||ir(e)?t(e):n(e)}}};const wr={continuation:{tokenize:function(e,t,n){const r=this;return function(t){if(sr(t))return fr(e,o,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(t);return o(t)};function o(r){return e.attempt(wr,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 sr(n)?(e.enter("blockQuotePrefixWhitespace"),e.consume(n),e.exit("blockQuotePrefixWhitespace"),e.exit("blockQuotePrefix"),t):(e.exit("blockQuotePrefix"),t(n))}}};const Sr={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 or(r)?(e.enter("characterEscapeValue"),e.consume(r),e.exit("characterEscapeValue"),e.exit("characterEscape"),t):n(r)}}};const Er={name:"characterReference",tokenize:function(e,t,n){const r=this;let o,i,a=0;return function(t){return e.enter("characterReference"),e.enter("characterReferenceMarker"),e.consume(t),e.exit("characterReferenceMarker"),s};function s(t){return 35===t?(e.enter("characterReferenceMarkerNumeric"),e.consume(t),e.exit("characterReferenceMarkerNumeric"),l):(e.enter("characterReferenceValue"),o=31,i=Zn,u(t))}function l(t){return 88===t||120===t?(e.enter("characterReferenceMarkerHexadecimal"),e.consume(t),e.exit("characterReferenceMarkerHexadecimal"),e.enter("characterReferenceValue"),o=6,i=rr,u):(e.enter("characterReferenceValue"),o=7,i=nr,u(t))}function u(s){if(59===s&&a){const o=e.exit("characterReferenceValue");return i!==Zn||Vn(r.sliceSerialize(o))?(e.enter("characterReferenceMarker"),e.consume(s),e.exit("characterReferenceMarker"),e.exit("characterReference"),t):n(s)}return i(s)&&a++<o?(e.consume(s),u):n(s)}}};const Cr={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)}}},Tr={concrete:!0,name:"codeFenced",tokenize:function(e,t,n){const r=this,o={partial:!0,tokenize:function(e,t,n){let o=0;return a;function a(t){return e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),l}function l(t){return e.enter("codeFencedFence"),sr(t)?fr(e,u,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(t):u(t)}function u(t){return t===i?(e.enter("codeFencedFenceSequence"),c(t)):n(t)}function c(t){return t===i?(o++,e.consume(t),c):o>=s?(e.exit("codeFencedFenceSequence"),sr(t)?fr(e,d,"whitespace")(t):d(t)):n(t)}function d(r){return null===r||ir(r)?(e.exit("codeFencedFence"),t(r)):n(r)}}};let i,a=0,s=0;return function(t){return function(t){const n=r.events[r.events.length-1];return a=n&&"linePrefix"===n[1].type?n[2].sliceSerialize(n[1],!0).length:0,i=t,e.enter("codeFenced"),e.enter("codeFencedFence"),e.enter("codeFencedFenceSequence"),l(t)}(t)};function l(t){return t===i?(s++,e.consume(t),l):s<3?n(t):(e.exit("codeFencedFenceSequence"),sr(t)?fr(e,u,"whitespace")(t):u(t))}function u(n){return null===n||ir(n)?(e.exit("codeFencedFence"),r.interrupt?t(n):e.check(Cr,p,v)(n)):(e.enter("codeFencedFenceInfo"),e.enter("chunkString",{contentType:"string"}),c(n))}function c(t){return null===t||ir(t)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),u(t)):sr(t)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),fr(e,d,"whitespace")(t)):96===t&&t===i?n(t):(e.consume(t),c)}function d(t){return null===t||ir(t)?u(t):(e.enter("codeFencedFenceMeta"),e.enter("chunkString",{contentType:"string"}),f(t))}function f(t){return null===t||ir(t)?(e.exit("chunkString"),e.exit("codeFencedFenceMeta"),u(t)):96===t&&t===i?n(t):(e.consume(t),f)}function p(t){return e.attempt(o,v,h)(t)}function h(t){return e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),g}function g(t){return a>0&&sr(t)?fr(e,m,"linePrefix",a+1)(t):m(t)}function m(t){return null===t||ir(t)?e.check(Cr,p,v)(t):(e.enter("codeFlowValue"),y(t))}function y(t){return null===t||ir(t)?(e.exit("codeFlowValue"),m(t)):(e.consume(t),y)}function v(n){return e.exit("codeFenced"),t(n)}}};const Or={name:"codeIndented",tokenize:function(e,t,n){const r=this;return function(t){return e.enter("codeIndented"),fr(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?i(e):n(e)}function i(t){return null===t?s(t):ir(t)?e.attempt(Nr,i,s)(t):(e.enter("codeFlowValue"),a(t))}function a(t){return null===t||ir(t)?(e.exit("codeFlowValue"),i(t)):(e.consume(t),a)}function s(n){return e.exit("codeIndented"),t(n)}}},Nr={partial:!0,tokenize:function(e,t,n){const r=this;return o;function o(t){return r.parser.lazy[r.now().line]?n(t):ir(t)?(e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),o):fr(e,i,"linePrefix",5)(t)}function i(e){const i=r.events[r.events.length-1];return i&&"linePrefix"===i[1].type&&i[2].sliceSerialize(i[1],!0).length>=4?t(e):ir(e)?o(e):n(e)}}};const Pr={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,i=0;return function(t){return e.enter("codeText"),e.enter("codeTextSequence"),a(t)};function a(t){return 96===t?(e.consume(t),i++,a):(e.exit("codeTextSequence"),s(t))}function s(t){return null===t?n(t):32===t?(e.enter("space"),e.consume(t),e.exit("space"),s):96===t?(o=e.enter("codeTextSequence"),r=0,u(t)):ir(t)?(e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),s):(e.enter("codeTextData"),l(t))}function l(t){return null===t||32===t||96===t||ir(t)?(e.exit("codeTextData"),s(t)):(e.consume(t),l)}function u(n){return 96===n?(e.consume(n),r++,u):r===i?(e.exit("codeTextSequence"),e.exit("codeText"),t(n)):(o.type="codeTextData",l(n))}}};class Lr{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&&Rr(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),Rr(this.left,e)}unshift(e){this.setCursor(0),this.right.push(e)}unshiftMany(e){this.setCursor(0),Rr(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);Rr(this.right,t.reverse())}else{const t=this.right.splice(this.left.length+this.right.length-e,Number.POSITIVE_INFINITY);Rr(this.left,t.reverse())}}}function Rr(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 _r(e){const t={};let n,r,o,i,a,s,l,u=-1;const c=new Lr(e);for(;++u<c.length;){for(;u in t;)u=t[u];if(n=c.get(u),u&&"chunkFlow"===n[1].type&&"listItemPrefix"===c.get(u-1)[1].type&&(s=n[1]._tokenizer.events,o=0,o<s.length&&"lineEndingBlank"===s[o][1].type&&(o+=2),o<s.length&&"content"===s[o][1].type))for(;++o<s.length&&"content"!==s[o][1].type;)"chunkText"===s[o][1].type&&(s[o][1]._isInFirstContentOfListItem=!0,o++);if("enter"===n[0])n[1].contentType&&(Object.assign(t,Ir(c,u)),u=t[u],l=!0);else if(n[1]._container){for(o=u,r=void 0;o--;)if(i=c.get(o),"lineEnding"===i[1].type||"lineEndingBlank"===i[1].type)"enter"===i[0]&&(r&&(c.get(r)[1].type="lineEndingBlank"),i[1].type="lineEnding",r=o);else if("linePrefix"!==i[1].type&&"listItemIndent"!==i[1].type)break;r&&(n[1].end={...c.get(r)[1].start},a=c.slice(r,u),a.unshift(n),c.splice(r,u-r+1,a))}}return Hn(e,0,Number.POSITIVE_INFINITY,c.slice(0)),!l}function Ir(e,t){const n=e.get(t)[1],r=e.get(t)[2];let o=t-1;const i=[];let a=n._tokenizer;a||(a=r.parser[n.contentType](n.start),n._contentTypeTextTrailing&&(a._contentTypeTextTrailing=!0));const s=a.events,l=[],u={};let c,d,f=-1,p=n,h=0,g=0;const m=[g];for(;p;){for(;e.get(++o)[1]!==p;);i.push(o),p._tokenizer||(c=r.sliceStream(p),p.next||c.push(null),d&&a.defineSkip(p.start),p._isInFirstContentOfListItem&&(a._gfmTasklistFirstContentOfListItem=!0),a.write(c),p._isInFirstContentOfListItem&&(a._gfmTasklistFirstContentOfListItem=void 0)),d=p,p=p.next}for(p=n;++f<s.length;)"exit"===s[f][0]&&"enter"===s[f-1][0]&&s[f][1].type===s[f-1][1].type&&s[f][1].start.line!==s[f][1].end.line&&(g=f+1,m.push(g),p._tokenizer=void 0,p.previous=void 0,p=p.next);for(a.events=[],p?(p._tokenizer=void 0,p.previous=void 0):m.pop(),f=m.length;f--;){const t=s.slice(m[f],m[f+1]),n=i.pop();l.push([n,n+t.length-1]),e.splice(n,2,t)}for(l.reverse(),f=-1;++f<l.length;)u[h+l[f][0]]=h+l[f][1],h+=l[f][1]-l[f][0]-1;return u}const Ar={resolve:function(e){return _r(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):ir(t)?e.check(Dr,i,o)(t):(e.consume(t),r)}function o(n){return e.exit("chunkContent"),e.exit("content"),t(n)}function i(t){return e.consume(t),e.exit("chunkContent"),n.next=e.enter("chunkContent",{contentType:"content",previous:n}),n=n.next,r}}},Dr={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"),fr(e,o,"linePrefix")};function o(o){if(null===o||ir(o))return n(o);const i=r.events[r.events.length-1];return!r.parser.constructs.disable.null.includes("codeIndented")&&i&&"linePrefix"===i[1].type&&i[2].sliceSerialize(i[1],!0).length>=4?t(o):e.interrupt(r.parser.constructs.flow,n,t)(o)}}};function zr(e,t,n,r,o,i,a,s,l){const u=l||Number.POSITIVE_INFINITY;let c=0;return function(t){if(60===t)return e.enter(r),e.enter(o),e.enter(i),e.consume(t),e.exit(i),d;if(null===t||32===t||41===t||tr(t))return n(t);return e.enter(r),e.enter(a),e.enter(s),e.enter("chunkString",{contentType:"string"}),h(t)};function d(n){return 62===n?(e.enter(i),e.consume(n),e.exit(i),e.exit(o),e.exit(r),t):(e.enter(s),e.enter("chunkString",{contentType:"string"}),f(n))}function f(t){return 62===t?(e.exit("chunkString"),e.exit(s),d(t)):null===t||60===t||ir(t)?n(t):(e.consume(t),92===t?p:f)}function p(t){return 60===t||62===t||92===t?(e.consume(t),f):f(t)}function h(o){return c||null!==o&&41!==o&&!ar(o)?c<u&&40===o?(e.consume(o),c++,h):41===o?(e.consume(o),c--,h):null===o||32===o||40===o||tr(o)?n(o):(e.consume(o),92===o?g:h):(e.exit("chunkString"),e.exit(s),e.exit(a),e.exit(r),t(o))}function g(t){return 40===t||41===t||92===t?(e.consume(t),h):h(t)}}function jr(e,t,n,r,o,i){const a=this;let s,l=0;return function(t){return e.enter(r),e.enter(o),e.consume(t),e.exit(o),e.enter(i),u};function u(d){return l>999||null===d||91===d||93===d&&!s||94===d&&!l&&"_hiddenFootnoteSupport"in a.parser.constructs?n(d):93===d?(e.exit(i),e.enter(o),e.consume(d),e.exit(o),e.exit(r),t):ir(d)?(e.enter("lineEnding"),e.consume(d),e.exit("lineEnding"),u):(e.enter("chunkString",{contentType:"string"}),c(d))}function c(t){return null===t||91===t||93===t||ir(t)||l++>999?(e.exit("chunkString"),u(t)):(e.consume(t),s||(s=!sr(t)),92===t?d:c)}function d(t){return 91===t||92===t||93===t?(e.consume(t),l++,c):c(t)}}function Fr(e,t,n,r,o,i){let a;return function(t){if(34===t||39===t||40===t)return e.enter(r),e.enter(o),e.consume(t),e.exit(o),a=40===t?41:t,s;return n(t)};function s(n){return n===a?(e.enter(o),e.consume(n),e.exit(o),e.exit(r),t):(e.enter(i),l(n))}function l(t){return t===a?(e.exit(i),s(a)):null===t?n(t):ir(t)?(e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),fr(e,l,"linePrefix")):(e.enter("chunkString",{contentType:"string"}),u(t))}function u(t){return t===a||null===t||ir(t)?(e.exit("chunkString"),l(t)):(e.consume(t),92===t?c:u)}function c(t){return t===a||92===t?(e.consume(t),u):u(t)}}function Mr(e,t){let n;return function r(o){if(ir(o))return e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),n=!0,r;if(sr(o))return fr(e,r,n?"linePrefix":"lineSuffix")(o);return t(o)}}const Ur={name:"definition",tokenize:function(e,t,n){const r=this;let o;return function(t){return e.enter("definition"),function(t){return jr.call(r,e,i,n,"definitionLabel","definitionLabelMarker","definitionLabelString")(t)}(t)};function i(t){return o=Gn(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)),58===t?(e.enter("definitionMarker"),e.consume(t),e.exit("definitionMarker"),a):n(t)}function a(t){return ar(t)?Mr(e,s)(t):s(t)}function s(t){return zr(e,l,n,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(t)}function l(t){return e.attempt(Br,u,u)(t)}function u(t){return sr(t)?fr(e,c,"whitespace")(t):c(t)}function c(i){return null===i||ir(i)?(e.exit("definition"),r.parser.defined.push(o),t(i)):n(i)}}},Br={partial:!0,tokenize:function(e,t,n){return function(t){return ar(t)?Mr(e,r)(t):n(t)};function r(t){return Fr(e,o,n,"definitionTitle","definitionTitleMarker","definitionTitleString")(t)}function o(t){return sr(t)?fr(e,i,"whitespace")(t):i(t)}function i(e){return null===e||ir(e)?t(e):n(e)}}};const $r={name:"hardBreakEscape",tokenize:function(e,t,n){return function(t){return e.enter("hardBreakEscape"),e.consume(t),r};function r(r){return ir(r)?(e.exit("hardBreakEscape"),t(r)):n(r)}}};const Vr={name:"headingAtx",resolve:function(e,t){let n,r,o=e.length-2,i=3;"whitespace"===e[i][1].type&&(i+=2);o-2>i&&"whitespace"===e[o][1].type&&(o-=2);"atxHeadingSequence"===e[o][1].type&&(i===o-1||o-4>i&&"whitespace"===e[o-2][1].type)&&(o-=i+1===o?2:4);o>i&&(n={type:"atxHeadingText",start:e[i][1].start,end:e[o][1].end},r={type:"chunkText",start:e[i][1].start,end:e[o][1].end,contentType:"text"},Hn(e,i,o-i+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||ar(t)?(e.exit("atxHeadingSequence"),i(t)):n(t)}function i(n){return 35===n?(e.enter("atxHeadingSequence"),a(n)):null===n||ir(n)?(e.exit("atxHeading"),t(n)):sr(n)?fr(e,i,"whitespace")(n):(e.enter("atxHeadingText"),s(n))}function a(t){return 35===t?(e.consume(t),a):(e.exit("atxHeadingSequence"),i(t))}function s(t){return null===t||35===t||ar(t)?(e.exit("atxHeadingText"),i(t)):(e.consume(t),s)}}};const Hr=["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"],qr=["pre","script","style","textarea"],Wr={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,i,a,s,l;return function(t){return function(t){return e.enter("htmlFlow"),e.enter("htmlFlowData"),e.consume(t),u}(t)};function u(s){return 33===s?(e.consume(s),c):47===s?(e.consume(s),i=!0,p):63===s?(e.consume(s),o=3,r.interrupt?t:A):Xn(s)?(e.consume(s),a=String.fromCharCode(s),h):n(s)}function c(i){return 45===i?(e.consume(i),o=2,d):91===i?(e.consume(i),o=5,s=0,f):Xn(i)?(e.consume(i),o=4,r.interrupt?t:A):n(i)}function d(o){return 45===o?(e.consume(o),r.interrupt?t:A):n(o)}function f(o){const i="CDATA[";return o===i.charCodeAt(s++)?(e.consume(o),6===s?r.interrupt?t:T:f):n(o)}function p(t){return Xn(t)?(e.consume(t),a=String.fromCharCode(t),h):n(t)}function h(s){if(null===s||47===s||62===s||ar(s)){const l=47===s,u=a.toLowerCase();return l||i||!qr.includes(u)?Hr.includes(a.toLowerCase())?(o=6,l?(e.consume(s),g):r.interrupt?t(s):T(s)):(o=7,r.interrupt&&!r.parser.lazy[r.now().line]?n(s):i?m(s):y(s)):(o=1,r.interrupt?t(s):T(s))}return 45===s||Zn(s)?(e.consume(s),a+=String.fromCharCode(s),h):n(s)}function g(o){return 62===o?(e.consume(o),r.interrupt?t:T):n(o)}function m(t){return sr(t)?(e.consume(t),m):E(t)}function y(t){return 47===t?(e.consume(t),E):58===t||95===t||Xn(t)?(e.consume(t),v):sr(t)?(e.consume(t),y):E(t)}function v(t){return 45===t||46===t||58===t||95===t||Zn(t)?(e.consume(t),v):b(t)}function b(t){return 61===t?(e.consume(t),k):sr(t)?(e.consume(t),b):y(t)}function k(t){return null===t||60===t||61===t||62===t||96===t?n(t):34===t||39===t?(e.consume(t),l=t,x):sr(t)?(e.consume(t),k):w(t)}function x(t){return t===l?(e.consume(t),l=null,S):null===t||ir(t)?n(t):(e.consume(t),x)}function w(t){return null===t||34===t||39===t||47===t||60===t||61===t||62===t||96===t||ar(t)?b(t):(e.consume(t),w)}function S(e){return 47===e||62===e||sr(e)?y(e):n(e)}function E(t){return 62===t?(e.consume(t),C):n(t)}function C(t){return null===t||ir(t)?T(t):sr(t)?(e.consume(t),C):n(t)}function T(t){return 45===t&&2===o?(e.consume(t),L):60===t&&1===o?(e.consume(t),R):62===t&&4===o?(e.consume(t),D):63===t&&3===o?(e.consume(t),A):93===t&&5===o?(e.consume(t),I):!ir(t)||6!==o&&7!==o?null===t||ir(t)?(e.exit("htmlFlowData"),O(t)):(e.consume(t),T):(e.exit("htmlFlowData"),e.check(Kr,z,O)(t))}function O(t){return e.check(Qr,N,z)(t)}function N(t){return e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),P}function P(t){return null===t||ir(t)?O(t):(e.enter("htmlFlowData"),T(t))}function L(t){return 45===t?(e.consume(t),A):T(t)}function R(t){return 47===t?(e.consume(t),a="",_):T(t)}function _(t){if(62===t){const n=a.toLowerCase();return qr.includes(n)?(e.consume(t),D):T(t)}return Xn(t)&&a.length<8?(e.consume(t),a+=String.fromCharCode(t),_):T(t)}function I(t){return 93===t?(e.consume(t),A):T(t)}function A(t){return 62===t?(e.consume(t),D):45===t&&2===o?(e.consume(t),A):T(t)}function D(t){return null===t||ir(t)?(e.exit("htmlFlowData"),z(t)):(e.consume(t),D)}function z(n){return e.exit("htmlFlow"),t(n)}}},Kr={partial:!0,tokenize:function(e,t,n){return function(r){return e.enter("lineEnding"),e.consume(r),e.exit("lineEnding"),e.attempt(xr,t,n)}}},Qr={partial:!0,tokenize:function(e,t,n){const r=this;return function(t){if(ir(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 Jr={name:"htmlText",tokenize:function(e,t,n){const r=this;let o,i,a;return function(t){return e.enter("htmlText"),e.enter("htmlTextData"),e.consume(t),s};function s(t){return 33===t?(e.consume(t),l):47===t?(e.consume(t),k):63===t?(e.consume(t),v):Xn(t)?(e.consume(t),S):n(t)}function l(t){return 45===t?(e.consume(t),u):91===t?(e.consume(t),i=0,p):Xn(t)?(e.consume(t),y):n(t)}function u(t){return 45===t?(e.consume(t),f):n(t)}function c(t){return null===t?n(t):45===t?(e.consume(t),d):ir(t)?(a=c,_(t)):(e.consume(t),c)}function d(t){return 45===t?(e.consume(t),f):c(t)}function f(e){return 62===e?R(e):45===e?d(e):c(e)}function p(t){const r="CDATA[";return t===r.charCodeAt(i++)?(e.consume(t),6===i?h:p):n(t)}function h(t){return null===t?n(t):93===t?(e.consume(t),g):ir(t)?(a=h,_(t)):(e.consume(t),h)}function g(t){return 93===t?(e.consume(t),m):h(t)}function m(t){return 62===t?R(t):93===t?(e.consume(t),m):h(t)}function y(t){return null===t||62===t?R(t):ir(t)?(a=y,_(t)):(e.consume(t),y)}function v(t){return null===t?n(t):63===t?(e.consume(t),b):ir(t)?(a=v,_(t)):(e.consume(t),v)}function b(e){return 62===e?R(e):v(e)}function k(t){return Xn(t)?(e.consume(t),x):n(t)}function x(t){return 45===t||Zn(t)?(e.consume(t),x):w(t)}function w(t){return ir(t)?(a=w,_(t)):sr(t)?(e.consume(t),w):R(t)}function S(t){return 45===t||Zn(t)?(e.consume(t),S):47===t||62===t||ar(t)?E(t):n(t)}function E(t){return 47===t?(e.consume(t),R):58===t||95===t||Xn(t)?(e.consume(t),C):ir(t)?(a=E,_(t)):sr(t)?(e.consume(t),E):R(t)}function C(t){return 45===t||46===t||58===t||95===t||Zn(t)?(e.consume(t),C):T(t)}function T(t){return 61===t?(e.consume(t),O):ir(t)?(a=T,_(t)):sr(t)?(e.consume(t),T):E(t)}function O(t){return null===t||60===t||61===t||62===t||96===t?n(t):34===t||39===t?(e.consume(t),o=t,N):ir(t)?(a=O,_(t)):sr(t)?(e.consume(t),O):(e.consume(t),P)}function N(t){return t===o?(e.consume(t),o=void 0,L):null===t?n(t):ir(t)?(a=N,_(t)):(e.consume(t),N)}function P(t){return null===t||34===t||39===t||60===t||61===t||96===t?n(t):47===t||62===t||ar(t)?E(t):(e.consume(t),P)}function L(e){return 47===e||62===e||ar(e)?E(e):n(e)}function R(r){return 62===r?(e.consume(r),e.exit("htmlTextData"),e.exit("htmlText"),t):n(r)}function _(t){return e.exit("htmlTextData"),e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),I}function I(t){return sr(t)?fr(e,A,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(t):A(t)}function A(t){return e.enter("htmlTextData"),a(t)}}};const Yr={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&&Hn(e,0,e.length,n);return e},resolveTo:function(e,t){let n,r,o,i,a=e.length,s=0;for(;a--;)if(n=e[a][1],r){if("link"===n.type||"labelLink"===n.type&&n._inactive)break;"enter"===e[a][0]&&"labelLink"===n.type&&(n._inactive=!0)}else if(o){if("enter"===e[a][0]&&("labelImage"===n.type||"labelLink"===n.type)&&!n._balanced&&(r=a,"labelLink"!==n.type)){s=2;break}}else"labelEnd"===n.type&&(o=a);const l={type:"labelLink"===e[r][1].type?"link":"image",start:{...e[r][1].start},end:{...e[e.length-1][1].end}},u={type:"label",start:{...e[r][1].start},end:{...e[o][1].end}},c={type:"labelText",start:{...e[r+s+2][1].end},end:{...e[o-2][1].start}};return i=[["enter",l,t],["enter",u,t]],i=qn(i,e.slice(r+1,r+s+3)),i=qn(i,[["enter",c,t]]),i=qn(i,yr(t.parser.constructs.insideSpan.null,e.slice(r+s+4,o-3),t)),i=qn(i,[["exit",c,t],e[o-2],e[o-1],["exit",u,t]]),i=qn(i,e.slice(o+1)),i=qn(i,[["exit",l,t]]),Hn(e,r,e.length,i),e},tokenize:function(e,t,n){const r=this;let o,i,a=r.events.length;for(;a--;)if(("labelImage"===r.events[a][1].type||"labelLink"===r.events[a][1].type)&&!r.events[a][1]._balanced){o=r.events[a][1];break}return function(t){if(!o)return n(t);if(o._inactive)return c(t);return i=r.parser.defined.includes(Gn(r.sliceSerialize({start:o.end,end:r.now()}))),e.enter("labelEnd"),e.enter("labelMarker"),e.consume(t),e.exit("labelMarker"),e.exit("labelEnd"),s};function s(t){return 40===t?e.attempt(Gr,u,i?u:c)(t):91===t?e.attempt(Xr,u,i?l:c)(t):i?u(t):c(t)}function l(t){return e.attempt(Zr,u,c)(t)}function u(e){return t(e)}function c(e){return o._balanced=!0,n(e)}}},Gr={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 ar(t)?Mr(e,o)(t):o(t)}function o(t){return 41===t?u(t):zr(e,i,a,"resourceDestination","resourceDestinationLiteral","resourceDestinationLiteralMarker","resourceDestinationRaw","resourceDestinationString",32)(t)}function i(t){return ar(t)?Mr(e,s)(t):u(t)}function a(e){return n(e)}function s(t){return 34===t||39===t||40===t?Fr(e,l,n,"resourceTitle","resourceTitleMarker","resourceTitleString")(t):u(t)}function l(t){return ar(t)?Mr(e,u)(t):u(t)}function u(r){return 41===r?(e.enter("resourceMarker"),e.consume(r),e.exit("resourceMarker"),e.exit("resource"),t):n(r)}}},Xr={tokenize:function(e,t,n){const r=this;return function(t){return jr.call(r,e,o,i,"reference","referenceMarker","referenceString")(t)};function o(e){return r.parser.defined.includes(Gn(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)))?t(e):n(e)}function i(e){return n(e)}}},Zr={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 eo={name:"labelStartImage",resolveAll:Yr.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"),i):n(t)}function i(e){return 94===e&&"_hiddenFootnoteSupport"in r.parser.constructs?n(e):t(e)}}};const to={name:"labelStartLink",resolveAll:Yr.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 no={name:"lineEnding",tokenize:function(e,t){return function(n){return e.enter("lineEnding"),e.consume(n),e.exit("lineEnding"),fr(e,t,"linePrefix")}}};const ro={name:"thematicBreak",tokenize:function(e,t,n){let r,o=0;return function(t){return e.enter("thematicBreak"),function(e){return r=e,i(e)}(t)};function i(i){return i===r?(e.enter("thematicBreakSequence"),a(i)):o>=3&&(null===i||ir(i))?(e.exit("thematicBreak"),t(i)):n(i)}function a(t){return t===r?(e.consume(t),o++,a):(e.exit("thematicBreakSequence"),sr(t)?fr(e,i,"whitespace")(t):i(t))}}};const oo={continuation:{tokenize:function(e,t,n){const r=this;return r.containerState._closeFlow=void 0,e.check(xr,function(n){return r.containerState.furtherBlankLines=r.containerState.furtherBlankLines||r.containerState.initialBlankLine,fr(e,t,"listItemIndent",r.containerState.size+1)(n)},function(n){if(r.containerState.furtherBlankLines||!sr(n))return r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,o(n);return r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,e.attempt(ao,t,o)(n)});function o(o){return r.containerState._closeFlow=!0,r.interrupt=void 0,fr(e,e.attempt(oo,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 i=o&&"linePrefix"===o[1].type?o[2].sliceSerialize(o[1],!0).length:0,a=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:nr(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(ro,n,l)(t):l(t);if(!r.interrupt||49===t)return e.enter("listItemPrefix"),e.enter("listItemValue"),s(t)}return n(t)};function s(t){return nr(t)&&++a<10?(e.consume(t),s):(!r.interrupt||a<2)&&(r.containerState.marker?t===r.containerState.marker:41===t||46===t)?(e.exit("listItemValue"),l(t)):n(t)}function l(t){return e.enter("listItemMarker"),e.consume(t),e.exit("listItemMarker"),r.containerState.marker=r.containerState.marker||t,e.check(xr,r.interrupt?n:u,e.attempt(io,d,c))}function u(e){return r.containerState.initialBlankLine=!0,i++,d(e)}function c(t){return sr(t)?(e.enter("listItemPrefixWhitespace"),e.consume(t),e.exit("listItemPrefixWhitespace"),d):n(t)}function d(n){return r.containerState.size=i+r.sliceSerialize(e.exit("listItemPrefix"),!0).length,t(n)}}},io={partial:!0,tokenize:function(e,t,n){const r=this;return fr(e,function(e){const o=r.events[r.events.length-1];return!sr(e)&&o&&"listItemPrefixWhitespace"===o[1].type?t(e):n(e)},"listItemPrefixWhitespace",r.parser.constructs.disable.null.includes("codeIndented")?void 0:5)}},ao={partial:!0,tokenize:function(e,t,n){const r=this;return fr(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 so={name:"setextUnderline",resolveTo:function(e,t){let n,r,o,i=e.length;for(;i--;)if("enter"===e[i][0]){if("content"===e[i][1].type){n=i;break}"paragraph"===e[i][1].type&&(r=i)}else"content"===e[i][1].type&&e.splice(i,1),o||"definition"!==e[i][1].type||(o=i);const a={type:"setextHeading",start:{...e[n][1].start},end:{...e[e.length-1][1].end}};e[r][1].type="setextHeadingText",o?(e.splice(r,0,["enter",a,t]),e.splice(o+1,0,["exit",e[n][1],t]),e[n][1].end={...e[o][1].end}):e[n][1]=a;return e.push(["exit",a,t]),e},tokenize:function(e,t,n){const r=this;let o;return function(t){let a,s=r.events.length;for(;s--;)if("lineEnding"!==r.events[s][1].type&&"linePrefix"!==r.events[s][1].type&&"content"!==r.events[s][1].type){a="paragraph"===r.events[s][1].type;break}if(!r.parser.lazy[r.now().line]&&(r.interrupt||a))return e.enter("setextHeadingLine"),o=t,function(t){return e.enter("setextHeadingLineSequence"),i(t)}(t);return n(t)};function i(t){return t===o?(e.consume(t),i):(e.exit("setextHeadingLineSequence"),sr(t)?fr(e,a,"lineSuffix")(t):a(t))}function a(r){return null===r||ir(r)?(e.exit("setextHeadingLine"),t(r)):n(r)}}};const lo={tokenize:function(e){const t=this,n=e.attempt(xr,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,fr(e,e.attempt(this.parser.constructs.flow,r,e.attempt(Ar,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 uo={resolveAll:ho()},co=po("string"),fo=po("text");function po(e){return{resolveAll:ho("text"===e?go:void 0),tokenize:function(t){const n=this,r=this.parser.constructs[e],o=t.attempt(r,i,a);return i;function i(e){return l(e)?o(e):a(e)}function a(e){if(null!==e)return t.enter("data"),t.consume(e),s;t.consume(e)}function s(e){return l(e)?(t.exit("data"),o(e)):(t.consume(e),s)}function l(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 ho(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 go(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 i,a=o.length,s=-1,l=0;for(;a--;){const e=o[a];if("string"==typeof e){for(s=e.length;32===e.charCodeAt(s-1);)l++,s--;if(s)break;s=-1}else if(-2===e)i=!0,l++;else if(-1!==e){a++;break}}if(t._contentTypeTextTrailing&&n===e.length&&(l=0),l){const o={type:n===e.length||i||l<2?"lineSuffix":"hardBreakTrailing",start:{_bufferIndex:a?s:r.start._bufferIndex+s,_index:r.start._index+a,line:r.end.line,column:r.end.column-l,offset:r.end.offset-l},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 mo={42:oo,43:oo,45:oo,48:oo,49:oo,50:oo,51:oo,52:oo,53:oo,54:oo,55:oo,56:oo,57:oo,62:wr},yo={91:Ur},vo={[-2]:Or,[-1]:Or,32:Or},bo={35:Vr,42:ro,45:[so,ro],60:Wr,61:so,95:ro,96:Tr,126:Tr},ko={38:Er,92:Sr},xo={[-5]:no,[-4]:no,[-3]:no,33:eo,38:Er,42:vr,60:[kr,Jr],91:to,92:[$r,Sr],93:Yr,95:vr,96:Pr},wo={null:[vr,uo]},So=Object.freeze(Object.defineProperty({__proto__:null,attentionMarkers:{null:[42,95]},contentInitial:yo,disable:{null:[]},document:mo,flow:bo,flowInitial:vo,insideSpan:wo,string:ko,text:xo},Symbol.toStringTag,{value:"Module"}));function Eo(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={},i=[];let a=[],s=[];const l={attempt:m(function(e,t){y(e,t.from)}),check:m(g),consume:function(e){ir(e)?(r.line++,r.column=1,r.offset+=-3===e?2:1,v()):-1!==e&&(r.column++,r.offset++);r._bufferIndex<0?r._index++:(r._bufferIndex++,r._bufferIndex===a[r._index].length&&(r._bufferIndex=-1,r._index++));u.previous=e},enter:function(e,t){const n=t||{};return n.type=e,n.start=f(),u.events.push(["enter",n,u]),s.push(n),n},exit:function(e){const t=s.pop();return t.end=f(),u.events.push(["exit",t,u]),t},interrupt:m(g,{interrupt:!0})},u={code:null,containerState:{},defineSkip:function(e){o[e.line]=e.column,v()},events:[],now:f,parser:e,previous:null,sliceSerialize:function(e,t){return function(e,t){let n=-1;const r=[];let o;for(;++n<e.length;){const i=e[n];let a;if("string"==typeof i)a=i;else switch(i){case-5:a="\r";break;case-4:a="\n";break;case-3:a="\r\n";break;case-2:a=t?" ":"\t";break;case-1:if(!t&&o)continue;a=" ";break;default:a=String.fromCharCode(i)}o=-2===i,r.push(a)}return r.join("")}(d(e),t)},sliceStream:d,write:function(e){if(a=qn(a,e),p(),null!==a[a.length-1])return[];return y(t,0),u.events=yr(i,u.events,u),u.events}};let c=t.tokenize.call(u,l);return t.resolveAll&&i.push(t),u;function d(e){return function(e,t){const n=t.start._index,r=t.start._bufferIndex,o=t.end._index,i=t.end._bufferIndex;let a;if(n===o)a=[e[n].slice(r,i)];else{if(a=e.slice(n,o),r>-1){const e=a[0];"string"==typeof e?a[0]=e.slice(r):a.shift()}i>0&&a.push(e[o].slice(0,i))}return a}(a,e)}function f(){const{_bufferIndex:e,_index:t,line:n,column:o,offset:i}=r;return{_bufferIndex:e,_index:t,line:n,column:o,offset:i}}function p(){let e;for(;r._index<a.length;){const t=a[r._index];if("string"==typeof t)for(e=r._index,r._bufferIndex<0&&(r._bufferIndex=0);r._index===e&&r._bufferIndex<t.length;)h(t.charCodeAt(r._bufferIndex));else h(t)}}function h(e){c=c(e)}function g(e,t){t.restore()}function m(e,t){return function(n,o,i){let a,c,d,p;return Array.isArray(n)?h(n):"tokenize"in n?h([n]):function(e){return t;function t(t){const n=null!==t&&e[t],r=null!==t&&e.null;return h([...Array.isArray(n)?n:n?[n]:[],...Array.isArray(r)?r:r?[r]:[]])(t)}}(n);function h(e){return a=e,c=0,0===e.length?i:g(e[c])}function g(e){return function(n){p=function(){const e=f(),t=u.previous,n=u.currentConstruct,o=u.events.length,i=Array.from(s);return{from:o,restore:a};function a(){r=e,u.previous=t,u.currentConstruct=n,u.events.length=o,s=i,v()}}(),d=e,e.partial||(u.currentConstruct=e);if(e.name&&u.parser.constructs.disable.null.includes(e.name))return y();return e.tokenize.call(t?Object.assign(Object.create(u),t):u,l,m,y)(n)}}function m(t){return e(d,p),o}function y(e){return p.restore(),++c<a.length?g(a[c]):i}}}function y(e,t){e.resolveAll&&!i.includes(e)&&i.push(e),e.resolve&&Hn(u.events,t,u.events.length-t,e.resolve(u.events.slice(t),u)),e.resolveTo&&(u.events=e.resolveTo(u.events,u))}function v(){r.line in o&&r.column<2&&(r.column=o[r.line],r.offset+=o[r.line]-1)}}const Co=/[\0\t\n\r]/g;const To=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function Oo(e,t,n){if(t)return t;if(35===n.charCodeAt(0)){const e=n.charCodeAt(1),t=120===e||88===e;return Yn(n.slice(t?2:1),t?16:10)}return Vn(n)||e}const No={}.hasOwnProperty;function Po(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:i(te),autolinkProtocol:C,autolinkEmail:C,atxHeading:i(G),blockQuote:i(W),characterEscape:C,characterReference:C,codeFenced:i(K),codeFencedFenceInfo:a,codeFencedFenceMeta:a,codeIndented:i(K,a),codeText:i(Q,a),codeTextData:C,data:C,codeFlowValue:C,definition:i(J),definitionDestinationString:a,definitionLabelString:a,definitionTitleString:a,emphasis:i(Y),hardBreakEscape:i(X),hardBreakTrailing:i(X),htmlFlow:i(Z,a),htmlFlowData:C,htmlText:i(Z,a),htmlTextData:C,image:i(ee),label:a,link:i(te),listItem:i(re),listItemValue:f,listOrdered:i(ne,d),listUnordered:i(ne),paragraph:i(oe),reference:M,referenceString:a,resourceDestinationString:a,resourceTitleString:a,setextHeading:i(G),strong:i(ie),thematicBreak:i(se)},exit:{atxHeading:l(),atxHeadingSequence:x,autolink:l(),autolinkEmail:q,autolinkProtocol:H,blockQuote:l(),characterEscapeValue:T,characterReferenceMarkerHexadecimal:B,characterReferenceMarkerNumeric:B,characterReferenceValue:$,characterReference:V,codeFenced:l(m),codeFencedFence:g,codeFencedFenceInfo:p,codeFencedFenceMeta:h,codeFlowValue:T,codeIndented:l(y),codeText:l(R),codeTextData:T,data:T,definition:l(),definitionDestinationString:k,definitionLabelString:v,definitionTitleString:b,emphasis:l(),hardBreakEscape:l(N),hardBreakTrailing:l(N),htmlFlow:l(P),htmlFlowData:T,htmlText:l(L),htmlTextData:T,image:l(I),label:D,labelText:A,lineEnding:O,link:l(_),listItem:l(),listOrdered:l(),listUnordered:l(),paragraph:l(),referenceString:U,resourceDestinationString:z,resourceTitleString:j,resource:F,setextHeading:l(E),setextHeadingLineSequence:S,setextHeadingText:w,strong:l(),thematicBreak:l()}};Ro(t,(e||{}).mdastExtensions||[]);const n={};return r;function r(e){let r={type:"root",children:[]};const i={stack:[r],tokenStack:[],config:t,enter:s,exit:u,buffer:a,resume:c,data:n},l=[];let d=-1;for(;++d<e.length;)if("listOrdered"===e[d][1].type||"listUnordered"===e[d][1].type)if("enter"===e[d][0])l.push(d);else{d=o(e,l.pop(),d)}for(d=-1;++d<e.length;){const n=t[e[d][0]];No.call(n,e[d][1].type)&&n[e[d][1].type].call(Object.assign({sliceSerialize:e[d][2].sliceSerialize},i),e[d][1])}if(i.tokenStack.length>0){const e=i.tokenStack[i.tokenStack.length-1];(e[1]||Io).call(i,void 0,e[0])}for(r.position={start:Lo(e.length>0?e[0][1].start:{line:1,column:1,offset:0}),end:Lo(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,i,a,s=t-1,l=-1,u=!1;for(;++s<=n;){const t=e[s];switch(t[1].type){case"listUnordered":case"listOrdered":case"blockQuote":"enter"===t[0]?l++:l--,a=void 0;break;case"lineEndingBlank":"enter"===t[0]&&(!r||a||l||i||(i=s),a=void 0);break;case"linePrefix":case"listItemValue":case"listItemMarker":case"listItemPrefix":case"listItemPrefixWhitespace":break;default:a=void 0}if(!l&&"enter"===t[0]&&"listItemPrefix"===t[1].type||-1===l&&"exit"===t[0]&&("listUnordered"===t[1].type||"listOrdered"===t[1].type)){if(r){let a=s;for(o=void 0;a--;){const t=e[a];if("lineEnding"===t[1].type||"lineEndingBlank"===t[1].type){if("exit"===t[0])continue;o&&(e[o][1].type="lineEndingBlank",u=!0),t[1].type="lineEnding",o=a}else if("linePrefix"!==t[1].type&&"blockQuotePrefix"!==t[1].type&&"blockQuotePrefixWhitespace"!==t[1].type&&"blockQuoteMarker"!==t[1].type&&"listItemIndent"!==t[1].type)break}i&&(!o||i<o)&&(r._spread=!0),r.end=Object.assign({},o?e[o][1].start:t[1].end),e.splice(o||s,0,["exit",r,t[2]]),s++,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(s,0,["enter",o,t[2]]),s++,n++,i=void 0,a=!0}}}return e[t][1]._spread=u,n}function i(e,t){return n;function n(n){s.call(this,e(n),n),t&&t.call(this,n)}}function a(){this.stack.push({type:"fragment",children:[]})}function s(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:Lo(t.start),end:void 0}}function l(e){return t;function t(t){e&&e.call(this,t),u.call(this,t)}}function u(e,t){const n=this.stack.pop(),r=this.tokenStack.pop();if(!r)throw new Error("Cannot close `"+e.type+"` ("+mn({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]||Io).call(this,e,r[0])}n.position.end=Lo(e.end)}function c(){return Mn(this.stack.pop())}function d(){this.data.expectingFirstListItemValue=!0}function f(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 h(){const e=this.resume();this.stack[this.stack.length-1].meta=e}function g(){this.data.flowCodeInside||(this.buffer(),this.data.flowCodeInside=!0)}function m(){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 y(){const e=this.resume();this.stack[this.stack.length-1].value=e.replace(/(\r?\n|\r)$/g,"")}function v(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.label=t,n.identifier=Gn(this.sliceSerialize(e)).toLowerCase()}function b(){const e=this.resume();this.stack[this.stack.length-1].title=e}function k(){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 w(){this.data.setextHeadingSlurpLineEnding=!0}function S(e){this.stack[this.stack.length-1].depth=61===this.sliceSerialize(e).codePointAt(0)?1:2}function E(){this.data.setextHeadingSlurpLineEnding=void 0}function C(e){const t=this.stack[this.stack.length-1].children;let n=t[t.length-1];n&&"text"===n.type||(n=ae(),n.position={start:Lo(e.start),end:void 0},t.push(n)),this.stack.push(n)}function T(e){const t=this.stack.pop();t.value+=this.sliceSerialize(e),t.position.end=Lo(e.end)}function O(e){const n=this.stack[this.stack.length-1];if(this.data.atHardBreak){return n.children[n.children.length-1].position.end=Lo(e.end),void(this.data.atHardBreak=void 0)}!this.data.setextHeadingSlurpLineEnding&&t.canContainEols.includes(n.type)&&(C.call(this,e),T.call(this,e))}function N(){this.data.atHardBreak=!0}function P(){const e=this.resume();this.stack[this.stack.length-1].value=e}function L(){const e=this.resume();this.stack[this.stack.length-1].value=e}function R(){const e=this.resume();this.stack[this.stack.length-1].value=e}function _(){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 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 A(e){const t=this.sliceSerialize(e),n=this.stack[this.stack.length-2];n.label=function(e){return e.replace(To,Oo)}(t),n.identifier=Gn(t).toLowerCase()}function D(){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 z(){const e=this.resume();this.stack[this.stack.length-1].url=e}function j(){const e=this.resume();this.stack[this.stack.length-1].title=e}function F(){this.data.inReference=void 0}function M(){this.data.referenceType="collapsed"}function U(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.label=t,n.identifier=Gn(this.sliceSerialize(e)).toLowerCase(),this.data.referenceType="full"}function B(e){this.data.characterReferenceType=e.type}function $(e){const t=this.sliceSerialize(e),n=this.data.characterReferenceType;let r;if(n)r=Yn(t,"characterReferenceMarkerNumeric"===n?10:16),this.data.characterReferenceType=void 0;else{r=Vn(t)}this.stack[this.stack.length-1].value+=r}function V(e){this.stack.pop().position.end=Lo(e.end)}function H(e){T.call(this,e);this.stack[this.stack.length-1].url=this.sliceSerialize(e)}function q(e){T.call(this,e);this.stack[this.stack.length-1].url="mailto:"+this.sliceSerialize(e)}function W(){return{type:"blockquote",children:[]}}function K(){return{type:"code",lang:null,meta:null,value:""}}function Q(){return{type:"inlineCode",value:""}}function J(){return{type:"definition",identifier:"",label:null,title:null,url:""}}function Y(){return{type:"emphasis",children:[]}}function G(){return{type:"heading",depth:0,children:[]}}function X(){return{type:"break"}}function Z(){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 ie(){return{type:"strong",children:[]}}function ae(){return{type:"text",value:""}}function se(){return{type:"thematicBreak"}}}(n)(function(e){for(;!_r(e););return e}(function(e){const t={constructs:Kn([So,...(e||{}).extensions||[]]),content:n(pr),defined:[],document:n(hr),flow:n(lo),lazy:{},string:n(co),text:n(fo)};return t;function n(e){return function(n){return Eo(t,e,n)}}}(n).document().write(function(){let e,t=1,n="",r=!0;return function(o,i,a){const s=[];let l,u,c,d,f;for(o=n+("string"==typeof o?o.toString():new TextDecoder(i||void 0).decode(o)),c=0,n="",r&&(65279===o.charCodeAt(0)&&c++,r=void 0);c<o.length;){if(Co.lastIndex=c,l=Co.exec(o),d=l&&void 0!==l.index?l.index:o.length,f=o.charCodeAt(d),!l){n=o.slice(c);break}if(10===f&&c===d&&e)s.push(-3),e=void 0;else switch(e&&(s.push(-5),e=void 0),c<d&&(s.push(o.slice(c,d)),t+=d-c),f){case 0:s.push(65533),t++;break;case 9:for(u=4*Math.ceil(t/4),s.push(-2);t++<u;)s.push(-1);break;case 10:s.push(-4),t=1;break;default:e=!0,t=1}c=d+1}return a&&(e&&s.push(-5),n&&s.push(n),s.push(null)),s}}()(e,t,!0))))}function Lo(e){return{line:e.line,column:e.column,offset:e.offset}}function Ro(e,t){let n=-1;for(;++n<t.length;){const r=t[n];Array.isArray(r)?Ro(e,r):_o(e,r)}}function _o(e,t){let n;for(n in t)if(No.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 Io(e,t){throw e?new Error("Cannot close `"+e.type+"` ("+mn({start:e.start,end:e.end})+"): a different token (`"+t.type+"`, "+mn({start:t.start,end:t.end})+") is open"):new Error("Cannot close document, a token (`"+t.type+"`, "+mn({start:t.start,end:t.end})+") is still open")}function Ao(e){const t=this;t.parser=function(n){return Po(n,{...t.data("settings"),...e,extensions:t.data("micromarkExtensions")||[],mdastExtensions:t.data("fromMarkdownExtensions")||[]})}}function Do(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),i=o[0];i&&"text"===i.type?i.value="["+i.value:o.unshift({type:"text",value:"["});const a=o[o.length-1];return a&&"text"===a.type?a.value+=r:o.push({type:"text",value:r}),o}function zo(e){const t=e.spread;return null==t?e.children.length>1:t}function jo(e){const t=String(e),n=/\r?\n|\r/g;let r=n.exec(t),o=0;const i=[];for(;r;)i.push(Fo(t.slice(o,r.index),o>0,!0),r[0]),o=r.index+r[0].length,r=n.exec(t);return i.push(Fo(t.slice(o),o>0,!1)),i.join("")}function Fo(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 Mo={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=dr(r.toLowerCase()),i=e.footnoteOrder.indexOf(r);let a,s=e.footnoteCounts.get(r);void 0===s?(s=0,e.footnoteOrder.push(r),a=e.footnoteOrder.length):a=i+1,s+=1,e.footnoteCounts.set(r,s);const l={type:"element",tagName:"a",properties:{href:"#"+n+"fn-"+o,id:n+"fnref-"+o+(s>1?"-"+s:""),dataFootnoteRef:!0,ariaDescribedBy:["footnote-label"]},children:[{type:"text",value:String(a)}]};e.patch(t,l);const u={type:"element",tagName:"sup",properties:{},children:[l]};return e.patch(t,u),e.applyData(t,u)},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 Do(e,t);const o={src:dr(r.url||""),alt:t.alt};null!==r.title&&void 0!==r.title&&(o.title=r.title);const i={type:"element",tagName:"img",properties:o,children:[]};return e.patch(t,i),e.applyData(t,i)},image:function(e,t){const n={src:dr(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 Do(e,t);const o={href:dr(r.url||"")};null!==r.title&&void 0!==r.title&&(o.title=r.title);const i={type:"element",tagName:"a",properties:o,children:e.all(t)};return e.patch(t,i),e.applyData(t,i)},link:function(e,t){const n={href:dr(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=zo(n[r])}return t}(n):zo(t),i={},a=[];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:[]}),i.className=["task-list-item"]}let s=-1;for(;++s<r.length;){const e=r[s];(o||0!==s||"element"!==e.type||"p"!==e.tagName)&&a.push({type:"text",value:"\n"}),"element"!==e.type||"p"!==e.tagName||o?a.push(e):a.push(...e.children)}const l=r[r.length-1];l&&(o||"element"!==l.type||"p"!==l.tagName)&&a.push({type:"text",value:"\n"});const u={type:"element",tagName:"li",properties:i,children:a};return e.patch(t,u),e.applyData(t,u)},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 i={type:"element",tagName:t.ordered?"ol":"ul",properties:n,children:e.wrap(r,!0)};return e.patch(t,i),e.applyData(t,i)},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)},i=hn(t.children[1]),a=pn(t.children[t.children.length-1]);i&&a&&(r.position={start:i,end:a}),o.push(r)}const i={type:"element",tagName:"table",properties:{},children:e.wrap(o,!0)};return e.patch(t,i),e.applyData(t,i)},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",i=n&&"table"===n.type?n.align:void 0,a=i?i.length:t.children.length;let s=-1;const l=[];for(;++s<a;){const n=t.children[s],r={},a=i?i[s]:void 0;a&&(r.align=a);let u={type:"element",tagName:o,properties:r,children:[]};n&&(u.children=e.all(n),e.patch(n,u),u=e.applyData(n,u)),l.push(u)}const u={type:"element",tagName:"tr",properties:{},children:e.wrap(l,!0)};return e.patch(t,u),e.applyData(t,u)},text:function(e,t){const n={type:"text",value:jo(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:Uo,yaml:Uo,definition:Uo,footnoteDefinition:Uo};function Uo(){}const Bo="object"==typeof self?self:globalThis,$o=e=>((e,t)=>{const n=(t,n)=>(e.set(n,t),t),r=o=>{if(e.has(o))return e.get(o);const[i,a]=t[o];switch(i){case 0:case-1:return n(a,o);case 1:{const e=n([],o);for(const t of a)e.push(r(t));return e}case 2:{const e=n({},o);for(const[t,n]of a)e[r(t)]=r(n);return e}case 3:return n(new Date(a),o);case 4:{const{source:e,flags:t}=a;return n(new RegExp(e,t),o)}case 5:{const e=n(new Map,o);for(const[t,n]of a)e.set(r(t),r(n));return e}case 6:{const e=n(new Set,o);for(const t of a)e.add(r(t));return e}case 7:{const{name:e,message:t}=a;return n(new Bo[e](t),o)}case 8:return n(BigInt(a),o);case"BigInt":return n(Object(BigInt(a)),o);case"ArrayBuffer":return n(new Uint8Array(a).buffer,a);case"DataView":{const{buffer:e}=new Uint8Array(a);return n(new DataView(e),a)}}return n(new Bo[i](a),o)};return r})(new Map,e)(0),Vo="",{toString:Ho}={},{keys:qo}=Object,Wo=e=>{const t=typeof e;if("object"!==t||!e)return[0,t];const n=Ho.call(e).slice(8,-1);switch(n){case"Array":return[1,Vo];case"Object":return[2,Vo];case"Date":return[3,Vo];case"RegExp":return[4,Vo];case"Map":return[5,Vo];case"Set":return[6,Vo];case"DataView":return[1,n]}return n.includes("Array")?[1,n]:n.includes("Error")?[7,n]:[2,n]},Ko=([e,t])=>0===e&&("function"===t||"symbol"===t),Qo=(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},i=r=>{if(n.has(r))return n.get(r);let[a,s]=Wo(r);switch(a){case 0:{let t=r;switch(s){case"bigint":a=8,t=r.toString();break;case"function":case"symbol":if(e)throw new TypeError("unable to serialize "+s);t=null;break;case"undefined":return o([-1],r)}return o([a,t],r)}case 1:{if(s){let e=r;return"DataView"===s?e=new Uint8Array(r.buffer):"ArrayBuffer"===s&&(e=new Uint8Array(r)),o([s,[...e]],r)}const e=[],t=o([a,e],r);for(const n of r)e.push(i(n));return t}case 2:{if(s)switch(s){case"BigInt":return o([s,r.toString()],r);case"Boolean":case"Number":case"String":return o([s,r.valueOf()],r)}if(t&&"toJSON"in r)return i(r.toJSON());const n=[],l=o([a,n],r);for(const t of qo(r))!e&&Ko(Wo(r[t]))||n.push([i(t),i(r[t])]);return l}case 3:return o([a,r.toISOString()],r);case 4:{const{source:e,flags:t}=r;return o([a,{source:e,flags:t}],r)}case 5:{const t=[],n=o([a,t],r);for(const[o,a]of r)(e||!Ko(Wo(o))&&!Ko(Wo(a)))&&t.push([i(o),i(a)]);return n}case 6:{const t=[],n=o([a,t],r);for(const o of r)!e&&Ko(Wo(o))||t.push(i(o));return n}}const{message:l}=r;return o([a,{name:s,message:l}],r)};return i})(!(t||n),!!t,new Map,r)(e),r},Jo="function"==typeof structuredClone?(e,t)=>t&&("json"in t||"lossy"in t)?$o(Qo(e,t)):structuredClone(e):(e,t)=>$o(Qo(e,t));function Yo(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 Go(e,t){return"Back to reference "+(e+1)+(t>1?"-"+t:"")}const Xo=function(e){if(null==e)return ei;if("function"==typeof e)return Zo(e);if("object"==typeof e)return Array.isArray(e)?function(e){const t=[];let n=-1;for(;++n<e.length;)t[n]=Xo(e[n]);return Zo(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 Zo(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 Zo(t);function t(t){return t&&t.type===e}}(e);throw new Error("Expected function, string, or object as test")};function Zo(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 ei(){return!0}const ti=[],ni=!0,ri=!1;function oi(e,t,n,r){let o;"function"==typeof t&&"function"!=typeof n?(r=n,n=t):o=t;const i=Xo(o),a=r?-1:1;!function e(o,s,l){const u=o&&"object"==typeof o?o:{};if("string"==typeof u.type){const e="string"==typeof u.tagName?u.tagName:"string"==typeof u.name?u.name:void 0;Object.defineProperty(c,"name",{value:"node ("+o.type+(e?"<"+e+">":"")+")"})}return c;function c(){let u,c,d,f=ti;if((!t||i(o,s,l[l.length-1]||void 0))&&(f=function(e){if(Array.isArray(e))return e;if("number"==typeof e)return[ni,e];return null==e?ti:[e]}(n(o,l)),f[0]===ri))return f;if("children"in o&&o.children){const t=o;if(t.children&&"skip"!==f[0])for(c=(r?t.children.length:-1)+a,d=l.concat(t);c>-1&&c<t.children.length;){const n=t.children[c];if(u=e(n,c,d)(),u[0]===ri)return u;c="number"==typeof u[1]?u[1]:c+a}}return f}}(e,void 0,[])()}function ii(e,t,n,r){let o,i,a;"function"==typeof t&&"function"!=typeof n?(i=void 0,a=t,o=n):(i=t,a=n,o=r),oi(e,i,function(e,t){const n=t[t.length-1],r=n?n.children.indexOf(e):void 0;return a(e,r,n)},o)}const ai={}.hasOwnProperty,si={};function li(e,t){e.position&&(t.position=function(e){const t=hn(e),n=pn(e);if(t&&n)return{start:t,end:n}}(e))}function ui(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,Jo(o)),"children"in n&&n.children&&null!=r&&(n.children=r)}return n}function ci(e,t){const n=t.data||{},r=!("value"in t)||ai.call(n,"hProperties")||ai.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 di(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 fi(e){let t=0,n=e.charCodeAt(t);for(;9===n||32===n;)t++,n=e.charCodeAt(t);return e.slice(t)}function pi(e,t){const n=function(e,t){const n=t||si,r=new Map,o=new Map,i=new Map,a={...Mo,...n.handlers},s={all:function(e){const t=[];if("children"in e){const n=e.children;let r=-1;for(;++r<n.length;){const o=s.one(n[r],e);if(o){if(r&&"break"===n[r-1].type&&(Array.isArray(o)||"text"!==o.type||(o.value=fi(o.value)),!Array.isArray(o)&&"element"===o.type)){const e=o.children[0];e&&"text"===e.type&&(e.value=fi(e.value))}Array.isArray(o)?t.push(...o):t.push(o)}}}return t},applyData:ui,definitionById:r,footnoteById:o,footnoteCounts:i,footnoteOrder:[],handlers:a,one:function(e,t){const n=e.type,r=s.handlers[n];if(ai.call(s.handlers,n)&&r)return r(s,e,t);if(s.options.passThrough&&s.options.passThrough.includes(n)){if("children"in e){const{children:t,...n}=e,r=Jo(n);return r.children=s.all(e),r}return Jo(e)}return(s.options.unknownHandler||ci)(s,e,t)},options:n,patch:li,wrap:di};return ii(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)}}),s}(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||Yo,r=e.options.footnoteBackLabel||Go,o=e.options.footnoteLabel||"Footnotes",i=e.options.footnoteLabelTagName||"h2",a=e.options.footnoteLabelProperties||{className:["sr-only"]},s=[];let l=-1;for(;++l<e.footnoteOrder.length;){const o=e.footnoteById.get(e.footnoteOrder[l]);if(!o)continue;const i=e.all(o),a=String(o.identifier).toUpperCase(),u=dr(a.toLowerCase());let c=0;const d=[],f=e.footnoteCounts.get(a);for(;void 0!==f&&++c<=f;){d.length>0&&d.push({type:"text",value:" "});let e="string"==typeof n?n:n(l,c);"string"==typeof e&&(e={type:"text",value:e}),d.push({type:"element",tagName:"a",properties:{href:"#"+t+"fnref-"+u+(c>1?"-"+c:""),dataFootnoteBackref:"",ariaLabel:"string"==typeof r?r:r(l,c),className:["data-footnote-backref"]},children:Array.isArray(e)?e:[e]})}const p=i[i.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 i.push(...d);const h={type:"element",tagName:"li",properties:{id:t+"fn-"+u},children:e.wrap(i,!0)};e.patch(o,h),s.push(h)}if(0!==s.length)return{type:"element",tagName:"section",properties:{dataFootnotes:!0,className:["footnotes"]},children:[{type:"element",tagName:i,properties:{...Jo(a),id:"footnote-label"},children:[{type:"text",value:o}]},{type:"text",value:"\n"},{type:"element",tagName:"ol",properties:{},children:e.wrap(s,!0)},{type:"text",value:"\n"}]}}(n),i=Array.isArray(r)?{type:"root",children:r}:r||{type:"root",children:[]};return o&&i.children.push({type:"text",value:"\n"},o),i}function hi(e,t){return e&&"run"in e?async function(n,r){const o=pi(n,{file:r,...t});await e.run(o,r)}:function(n,r){return pi(n,{file:r,...e||t})}}function gi(e){if(e)throw e}var mi,yi;var vi=function(){if(yi)return mi;yi=1;var e=Object.prototype.hasOwnProperty,t=Object.prototype.toString,n=Object.defineProperty,r=Object.getOwnPropertyDescriptor,o=function(e){return"function"==typeof Array.isArray?Array.isArray(e):"[object Array]"===t.call(e)},i=function(n){if(!n||"[object Object]"!==t.call(n))return!1;var r,o=e.call(n,"constructor"),i=n.constructor&&n.constructor.prototype&&e.call(n.constructor.prototype,"isPrototypeOf");if(n.constructor&&!o&&!i)return!1;for(r in n);return void 0===r||e.call(n,r)},a=function(e,t){n&&"__proto__"===t.name?n(e,t.name,{enumerable:!0,configurable:!0,value:t.newValue,writable:!0}):e[t.name]=t.newValue},s=function(t,n){if("__proto__"===n){if(!e.call(t,n))return;if(r)return r(t,n).value}return t[n]};return mi=function e(){var t,n,r,l,u,c,d=arguments[0],f=1,p=arguments.length,h=!1;for("boolean"==typeof d&&(h=d,d=arguments[1]||{},f=2),(null==d||"object"!=typeof d&&"function"!=typeof d)&&(d={});f<p;++f)if(null!=(t=arguments[f]))for(n in t)r=s(d,n),d!==(l=s(t,n))&&(h&&l&&(i(l)||(u=o(l)))?(u?(u=!1,c=r&&o(r)?r:[]):c=r&&i(r)?r:{},a(d,{name:n,newValue:e(h,c,l)})):void 0!==l&&a(d,{name:n,newValue:l}));return d},mi}();const bi=t(vi);function ki(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 xi(){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(i,...a){const s=e[++n];let l=-1;if(i)r(i);else{for(;++l<t.length;)null!==a[l]&&void 0!==a[l]||(a[l]=t[l]);t=a,s?function(e,t){let n;return r;function r(...t){const r=e.length>t.length;let s;r&&t.push(o);try{s=e.apply(this,t)}catch(i){if(r&&n)throw i;return o(i)}r||(s&&s.then&&"function"==typeof s.then?s.then(a,o):s instanceof Error?o(s):a(s))}function o(e,...r){n||(n=!0,t(e,...r))}function a(e){o(null,e)}}(s,o)(...a):r(null,...a)}}(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 wi={basename:function(e,t){if(void 0!==t&&"string"!=typeof t)throw new TypeError('"ext" argument must be a string');Si(e);let n,r=0,o=-1,i=e.length;if(void 0===t||0===t.length||t.length>e.length){for(;i--;)if(47===e.codePointAt(i)){if(n){r=i+1;break}}else o<0&&(n=!0,o=i+1);return o<0?"":e.slice(r,o)}if(t===e)return"";let a=-1,s=t.length-1;for(;i--;)if(47===e.codePointAt(i)){if(n){r=i+1;break}}else a<0&&(n=!0,a=i+1),s>-1&&(e.codePointAt(i)===t.codePointAt(s--)?s<0&&(o=i):(s=-1,o=a));r===o?o=a:o<0&&(o=e.length);return e.slice(r,o)},dirname:function(e){if(Si(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){Si(e);let t,n=e.length,r=-1,o=0,i=-1,a=0;for(;n--;){const s=e.codePointAt(n);if(47!==s)r<0&&(t=!0,r=n+1),46===s?i<0?i=n:1!==a&&(a=1):i>-1&&(a=-1);else if(t){o=n+1;break}}if(i<0||r<0||0===a||1===a&&i===r-1&&i===o+1)return"";return e.slice(i,r)},join:function(...e){let t,n=-1;for(;++n<e.length;)Si(e[n]),e[n]&&(t=void 0===t?e[n]:t+"/"+e[n]);return void 0===t?".":function(e){Si(e);const t=47===e.codePointAt(0);let n=function(e,t){let n,r,o="",i=0,a=-1,s=0,l=-1;for(;++l<=e.length;){if(l<e.length)n=e.codePointAt(l);else{if(47===n)break;n=47}if(47===n){if(a===l-1||1===s);else if(a!==l-1&&2===s){if(o.length<2||2!==i||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="",i=0):(o=o.slice(0,r),i=o.length-1-o.lastIndexOf("/")),a=l,s=0;continue}}else if(o.length>0){o="",i=0,a=l,s=0;continue}t&&(o=o.length>0?o+"/..":"..",i=2)}else o.length>0?o+="/"+e.slice(a+1,l):o=e.slice(a+1,l),i=l-a-1;a=l,s=0}else 46===n&&s>-1?s++:s=-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 Si(e){if("string"!=typeof e)throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}const Ei={cwd:function(){return"/"}};function Ci(e){return Boolean(null!==e&&"object"==typeof e&&"href"in e&&e.href&&"protocol"in e&&e.protocol&&void 0===e.auth)}function Ti(e){if("string"==typeof e)e=new URL(e);else if(!Ci(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 Oi=["history","path","basename","stem","extname","dirname"];class Ni{constructor(e){let t;t=e?Ci(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?"":Ei.cwd(),this.data={},this.history=[],this.messages=[],this.value,this.map,this.result,this.stored;let n,r=-1;for(;++r<Oi.length;){const e=Oi[r];e in t&&void 0!==t[e]&&null!==t[e]&&(this[e]="history"===e?[...t[e]]:t[e])}for(n in t)Oi.includes(n)||(this[n]=t[n])}get basename(){return"string"==typeof this.path?wi.basename(this.path):void 0}set basename(e){Li(e,"basename"),Pi(e,"basename"),this.path=wi.join(this.dirname||"",e)}get dirname(){return"string"==typeof this.path?wi.dirname(this.path):void 0}set dirname(e){Ri(this.basename,"dirname"),this.path=wi.join(e||"",this.basename)}get extname(){return"string"==typeof this.path?wi.extname(this.path):void 0}set extname(e){if(Pi(e,"extname"),Ri(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=wi.join(this.dirname,this.stem+(e||""))}get path(){return this.history[this.history.length-1]}set path(e){Ci(e)&&(e=Ti(e)),Li(e,"path"),this.path!==e&&this.history.push(e)}get stem(){return"string"==typeof this.path?wi.basename(this.path,this.extname):void 0}set stem(e){Li(e,"stem"),Pi(e,"stem"),this.path=wi.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 kn(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 Pi(e,t){if(e&&e.includes(wi.sep))throw new Error("`"+t+"` cannot be a path: did not expect `"+wi.sep+"`")}function Li(e,t){if(!e)throw new Error("`"+t+"` cannot be empty")}function Ri(e,t){if(!e)throw new Error("Setting `"+t+"` requires `path` to be set too")}const _i=function(e){const t=this.constructor.prototype,n=t[e],r=function(){return n.apply(r,arguments)};return Object.setPrototypeOf(r,t),r},Ii={}.hasOwnProperty;class Ai extends _i{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=xi()}copy(){const e=new Ai;let t=-1;for(;++t<this.attachers.length;){const n=this.attachers[t];e.use(...n)}return e.data(bi(!0,{},this.namespace)),e}data(e,t){return"string"==typeof e?2===arguments.length?(Fi("data",this.frozen),this.namespace[e]=t,this):Ii.call(this.namespace,e)&&this.namespace[e]||void 0:e?(Fi("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=Bi(e),n=this.parser||this.Parser;return zi("parse",n),n(String(t),t)}process(e,t){const n=this;return this.freeze(),zi("process",this.parser||this.Parser),ji("process",this.compiler||this.Compiler),t?r(void 0,t):new Promise(r);function r(r,o){const i=Bi(e),a=n.parse(i);function s(e,n){e||!n?o(e):r?r(n):t(void 0,n)}n.run(a,i,function(e,t,r){if(e||!t||!r)return s(e);const o=t,i=n.stringify(o,r);var a;"string"==typeof(a=i)||function(e){return Boolean(e&&"object"==typeof e&&"byteLength"in e&&"byteOffset"in e)}(a)?r.value=i:r.result=i,s(e,r)})}}processSync(e){let t,n=!1;return this.freeze(),zi("processSync",this.parser||this.Parser),ji("processSync",this.compiler||this.Compiler),this.process(e,function(e,r){n=!0,gi(e),t=r}),Ui("processSync","process",n),t}run(e,t,n){Mi(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,i){const a=Bi(t);r.run(e,a,function(t,r,a){const s=r||e;t?i(t):o?o(s):n(void 0,s,a)})}}runSync(e,t){let n,r=!1;return this.run(e,t,function(e,t){gi(e),n=t,r=!0}),Ui("runSync","run",r),n}stringify(e,t){this.freeze();const n=Bi(t),r=this.compiler||this.Compiler;return ji("stringify",r),Mi(e),r(e,n)}use(e,...t){const n=this.attachers,r=this.namespace;if(Fi("use",this.frozen),null==e);else if("function"==typeof e)s(e,t);else{if("object"!=typeof e)throw new TypeError("Expected usable value, not `"+e+"`");Array.isArray(e)?a(e):i(e)}return this;function o(e){if("function"==typeof e)s(e,[]);else{if("object"!=typeof e)throw new TypeError("Expected usable value, not `"+e+"`");if(Array.isArray(e)){const[t,...n]=e;s(t,n)}else i(e)}}function i(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");a(e.plugins),e.settings&&(r.settings=bi(!0,r.settings,e.settings))}function a(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 s(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,...i]=t;const a=n[o][1];ki(a)&&ki(r)&&(r=bi(!0,a,r)),n[o]=[e,r,...i]}}}}const Di=(new Ai).freeze();function zi(e,t){if("function"!=typeof t)throw new TypeError("Cannot `"+e+"` without `parser`")}function ji(e,t){if("function"!=typeof t)throw new TypeError("Cannot `"+e+"` without `compiler`")}function Fi(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 Mi(e){if(!ki(e)||"string"!=typeof e.type)throw new TypeError("Expected node, got `"+e+"`")}function Ui(e,t,n){if(!n)throw new Error("`"+e+"` finished async. Use `"+t+"` instead")}function Bi(e){return function(e){return Boolean(e&&"object"==typeof e&&"message"in e&&"messages"in e)}(e)?e:new Ni(e)}const $i=[],Vi={allowDangerousHtml:!0},Hi=/^(https?|ircs?|mailto|xmpp)$/i,qi=[{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:"className",id:"remove-classname"},{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 Wi(e){const t=function(e){const t=e.rehypePlugins||$i,n=e.remarkPlugins||$i,r=e.remarkRehypeOptions?{...e.remarkRehypeOptions,...Vi}:Vi,o=Di().use(Ao).use(n).use(hi,r).use(t);return o}(e),n=function(e){const t=e.children||"",n=new Ni;"string"==typeof t&&(n.value=t);return n}(e);return function(e,t){const n=t.allowedElements,r=t.allowElement,o=t.components,i=t.disallowedElements,a=t.skipHtml,s=t.unwrapDisallowed,l=t.urlTransform||Ki;for(const c of qi)Object.hasOwn(t,c.from)&&ht((c.from,c.to&&c.to,c.id));return ii(e,u),On(e,{Fragment:O.Fragment,components:o,ignoreInvalidStyle:!0,jsx:O.jsx,jsxs:O.jsxs,passKeys:!0,passNode:!0});function u(e,t,o){if("raw"===e.type&&o&&"number"==typeof t)return a?o.children.splice(t,1):o.children[t]={type:"text",value:e.value},t;if("element"===e.type){let t;for(t in jn)if(Object.hasOwn(jn,t)&&Object.hasOwn(e.properties,t)){const n=e.properties[t],r=jn[t];(null===r||r.includes(e.tagName))&&(e.properties[t]=l(String(n||""),t,e))}}if("element"===e.type){let a=n?!n.includes(e.tagName):!!i&&i.includes(e.tagName);if(!a&&r&&"number"==typeof t&&(a=!r(e,t,o)),a&&o&&"number"==typeof t)return s&&e.children?o.children.splice(t,1,...e.children):o.children.splice(t,1),t}}}(t.runSync(t.parse(n),n),e)}function Ki(e){const t=e.indexOf(":"),n=e.indexOf("?"),r=e.indexOf("#"),o=e.indexOf("/");return-1===t||-1!==o&&t>o||-1!==n&&t>n||-1!==r&&t>r||Hi.test(e.slice(0,t))?e:""}function Qi(e,t){const n=String(e);if("string"!=typeof t)throw new TypeError("Expected character");let r=0,o=n.indexOf(t);for(;-1!==o;)r++,o=n.indexOf(t,o+t.length);return r}function Ji(e,t,n){const r=Xo((n||{}).ignore||[]),o=function(e){const t=[];if(!Array.isArray(e))throw new TypeError("Expected find and replace tuple or list of tuples");const n=!e[0]||Array.isArray(e[0])?e:[e];let r=-1;for(;++r<n.length;){const e=n[r];t.push([Yi(e[0]),Gi(e[1])])}return t}(t);let i=-1;for(;++i<o.length;)oi(e,"text",a);function a(e,t){let n,a=-1;for(;++a<t.length;){const e=t[a],o=n?n.children:void 0;if(r(e,o?o.indexOf(e):void 0,n))return;n=e}if(n)return function(e,t){const n=t[t.length-1],r=o[i][0],a=o[i][1];let s=0;const l=n.children.indexOf(e);let u=!1,c=[];r.lastIndex=0;let d=r.exec(e.value);for(;d;){const n=d.index,o={index:d.index,input:d.input,stack:[...t,e]};let i=a(...d,o);if("string"==typeof i&&(i=i.length>0?{type:"text",value:i}:void 0),!1===i?r.lastIndex=n+1:(s!==n&&c.push({type:"text",value:e.value.slice(s,n)}),Array.isArray(i)?c.push(...i):i&&c.push(i),s=n+d[0].length,u=!0),!r.global)break;d=r.exec(e.value)}u?(s<e.value.length&&c.push({type:"text",value:e.value.slice(s)}),n.children.splice(l,1,...c)):c=[e];return l+c.length}(e,t)}}function Yi(e){return"string"==typeof e?new RegExp(function(e){if("string"!=typeof e)throw new TypeError("Expected a string");return e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}(e),"g"):e}function Gi(e){return"function"==typeof e?e:function(){return e}}const Xi="phrasing",Zi=["autolink","link","image","label"];function ea(e){this.enter({type:"link",title:null,url:"",children:[]},e)}function ta(e){this.config.enter.autolinkProtocol.call(this,e)}function na(e){this.config.exit.autolinkProtocol.call(this,e)}function ra(e){this.config.exit.data.call(this,e);const t=this.stack[this.stack.length-1];t.type,t.url="http://"+this.sliceSerialize(e)}function oa(e){this.config.exit.autolinkEmail.call(this,e)}function ia(e){this.exit(e)}function aa(e){Ji(e,[[/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/gi,sa],[new RegExp("(?<=^|\\s|\\p{P}|\\p{S})([-.\\w+]+)@([-\\w]+(?:\\.[-\\w]+)+)","gu"),la]],{ignore:["link","linkReference"]})}function sa(e,t,n,r,o){let i="";if(!ua(o))return!1;if(/^w/i.test(t)&&(n=t+n,t="",i="http://"),!function(e){const t=e.split(".");if(t.length<2||t[t.length-1]&&(/_/.test(t[t.length-1])||!/[a-zA-Z\d]/.test(t[t.length-1]))||t[t.length-2]&&(/_/.test(t[t.length-2])||!/[a-zA-Z\d]/.test(t[t.length-2])))return!1;return!0}(n))return!1;const a=function(e){const t=/[!"&'),.:;<>?\]}]+$/.exec(e);if(!t)return[e,void 0];e=e.slice(0,t.index);let n=t[0],r=n.indexOf(")");const o=Qi(e,"(");let i=Qi(e,")");for(;-1!==r&&o>i;)e+=n.slice(0,r+1),n=n.slice(r+1),r=n.indexOf(")"),i++;return[e,n]}(n+r);if(!a[0])return!1;const s={type:"link",title:null,url:i+t+a[0],children:[{type:"text",value:t+a[0]}]};return a[1]?[s,{type:"text",value:a[1]}]:s}function la(e,t,n,r){return!(!ua(r,!0)||/[-\d_]$/.test(n))&&{type:"link",title:null,url:"mailto:"+t+"@"+n,children:[{type:"text",value:t+"@"+n}]}}function ua(e,t){const n=e.input.charCodeAt(e.index-1);return(0===e.index||ur(n)||lr(n))&&(!t||47!==n)}function ca(){this.buffer()}function da(e){this.enter({type:"footnoteReference",identifier:"",label:""},e)}function fa(){this.buffer()}function pa(e){this.enter({type:"footnoteDefinition",identifier:"",label:"",children:[]},e)}function ha(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.identifier=Gn(this.sliceSerialize(e)).toLowerCase(),n.label=t}function ga(e){this.exit(e)}function ma(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.identifier=Gn(this.sliceSerialize(e)).toLowerCase(),n.label=t}function ya(e){this.exit(e)}function va(e,t,n,r){const o=n.createTracker(r);let i=o.move("[^");const a=n.enter("footnoteReference"),s=n.enter("reference");return i+=o.move(n.safe(n.associationId(e),{after:"]",before:i})),s(),a(),i+=o.move("]"),i}function ba(e){let t=!1;return e&&e.firstLineBlank&&(t=!0),{handlers:{footnoteDefinition:function(e,n,r,o){const i=r.createTracker(o);let a=i.move("[^");const s=r.enter("footnoteDefinition"),l=r.enter("label");a+=i.move(r.safe(r.associationId(e),{before:a,after:"]"})),l(),a+=i.move("]:"),e.children&&e.children.length>0&&(i.shift(4),a+=i.move((t?"\n":" ")+r.indentLines(r.containerFlow(e,i.current()),t?xa:ka)));return s(),a},footnoteReference:va},unsafe:[{character:"[",inConstruct:["label","phrasing","reference"]}]}}function ka(e,t,n){return 0===t?e:xa(e,t,n)}function xa(e,t,n){return(n?"":" ")+e}va.peek=function(){return"["};const wa=["autolink","destinationLiteral","destinationRaw","reference","titleQuote","titleApostrophe"];function Sa(e){this.enter({type:"delete",children:[]},e)}function Ea(e){this.exit(e)}function Ca(e,t,n,r){const o=n.createTracker(r),i=n.enter("strikethrough");let a=o.move("~~");return a+=n.containerPhrasing(e,{...o.current(),before:a,after:"~"}),a+=o.move("~~"),i(),a}function Ta(e){return e.length}function Oa(e){return null==e?"":String(e)}function Na(e){const t="string"==typeof e?e.codePointAt(0):0;return 67===t||99===t?99:76===t||108===t?108:82===t||114===t?114:0}function Pa(e,t,n){return">"+(n?"":" ")+e}function La(e,t){return Ra(e,t.inConstruct,!0)&&!Ra(e,t.notInConstruct,!1)}function Ra(e,t,n){if("string"==typeof t&&(t=[t]),!t||0===t.length)return n;let r=-1;for(;++r<t.length;)if(e.includes(t[r]))return!0;return!1}function _a(e,t,n,r){let o=-1;for(;++o<n.unsafe.length;)if("\n"===n.unsafe[o].character&&La(n.stack,n.unsafe[o]))return/[ \t]/.test(r.before)?"":" ";return"\\\n"}function Ia(e,t,n){return(n?"":" ")+e}function Aa(e){const t=e.options.quote||'"';if('"'!==t&&"'"!==t)throw new Error("Cannot serialize title with `"+t+"` for `options.quote`, expected `\"`, or `'`");return t}function Da(e){return"&#x"+e.toString(16).toUpperCase()+";"}function za(e,t,n){const r=mr(e),o=mr(t);return void 0===r?void 0===o?"_"===n?{inside:!0,outside:!0}:{inside:!1,outside:!1}:1===o?{inside:!0,outside:!0}:{inside:!1,outside:!0}:1===r?void 0===o?{inside:!1,outside:!1}:1===o?{inside:!0,outside:!0}:{inside:!1,outside:!1}:void 0===o?{inside:!1,outside:!1}:1===o?{inside:!0,outside:!1}:{inside:!1,outside:!1}}function ja(e,t,n,r){const o=function(e){const t=e.options.emphasis||"*";if("*"!==t&&"_"!==t)throw new Error("Cannot serialize emphasis with `"+t+"` for `options.emphasis`, expected `*`, or `_`");return t}(n),i=n.enter("emphasis"),a=n.createTracker(r),s=a.move(o);let l=a.move(n.containerPhrasing(e,{after:o,before:s,...a.current()}));const u=l.charCodeAt(0),c=za(r.before.charCodeAt(r.before.length-1),u,o);c.inside&&(l=Da(u)+l.slice(1));const d=l.charCodeAt(l.length-1),f=za(r.after.charCodeAt(0),d,o);f.inside&&(l=l.slice(0,-1)+Da(d));const p=a.move(o);return i(),n.attentionEncodeSurroundingInfo={after:f.outside,before:c.outside},s+l+p}function Fa(e){return e.value||""}function Ma(e,t,n,r){const o=Aa(n),i='"'===o?"Quote":"Apostrophe",a=n.enter("image");let s=n.enter("label");const l=n.createTracker(r);let u=l.move("![");return u+=l.move(n.safe(e.alt,{before:u,after:"]",...l.current()})),u+=l.move("]("),s(),!e.url&&e.title||/[\0- \u007F]/.test(e.url)?(s=n.enter("destinationLiteral"),u+=l.move("<"),u+=l.move(n.safe(e.url,{before:u,after:">",...l.current()})),u+=l.move(">")):(s=n.enter("destinationRaw"),u+=l.move(n.safe(e.url,{before:u,after:e.title?" ":")",...l.current()}))),s(),e.title&&(s=n.enter(`title${i}`),u+=l.move(" "+o),u+=l.move(n.safe(e.title,{before:u,after:o,...l.current()})),u+=l.move(o),s()),u+=l.move(")"),a(),u}function Ua(e,t,n,r){const o=e.referenceType,i=n.enter("imageReference");let a=n.enter("label");const s=n.createTracker(r);let l=s.move("![");const u=n.safe(e.alt,{before:l,after:"]",...s.current()});l+=s.move(u+"]["),a();const c=n.stack;n.stack=[],a=n.enter("reference");const d=n.safe(n.associationId(e),{before:l,after:"]",...s.current()});return a(),n.stack=c,i(),"full"!==o&&u&&u===d?"shortcut"===o?l=l.slice(0,-1):l+=s.move("]"):l+=s.move(d+"]"),l}function Ba(e,t,n){let r=e.value||"",o="`",i=-1;for(;new RegExp("(^|[^`])"+o+"([^`]|$)").test(r);)o+="`";for(/[^ \r\n]/.test(r)&&(/^[ \r\n]/.test(r)&&/[ \r\n]$/.test(r)||/^`|`$/.test(r))&&(r=" "+r+" ");++i<n.unsafe.length;){const e=n.unsafe[i],t=n.compilePattern(e);let o;if(e.atBreak)for(;o=t.exec(r);){let e=o.index;10===r.charCodeAt(e)&&13===r.charCodeAt(e-1)&&e--,r=r.slice(0,e)+" "+r.slice(o.index+1)}}return o+r+o}function $a(e,t){const n=Mn(e);return Boolean(!t.options.resourceLink&&e.url&&!e.title&&e.children&&1===e.children.length&&"text"===e.children[0].type&&(n===e.url||"mailto:"+n===e.url)&&/^[a-z][a-z+.-]+:/i.test(e.url)&&!/[\0- <>\u007F]/.test(e.url))}function Va(e,t,n,r){const o=Aa(n),i='"'===o?"Quote":"Apostrophe",a=n.createTracker(r);let s,l;if($a(e,n)){const t=n.stack;n.stack=[],s=n.enter("autolink");let r=a.move("<");return r+=a.move(n.containerPhrasing(e,{before:r,after:">",...a.current()})),r+=a.move(">"),s(),n.stack=t,r}s=n.enter("link"),l=n.enter("label");let u=a.move("[");return u+=a.move(n.containerPhrasing(e,{before:u,after:"](",...a.current()})),u+=a.move("]("),l(),!e.url&&e.title||/[\0- \u007F]/.test(e.url)?(l=n.enter("destinationLiteral"),u+=a.move("<"),u+=a.move(n.safe(e.url,{before:u,after:">",...a.current()})),u+=a.move(">")):(l=n.enter("destinationRaw"),u+=a.move(n.safe(e.url,{before:u,after:e.title?" ":")",...a.current()}))),l(),e.title&&(l=n.enter(`title${i}`),u+=a.move(" "+o),u+=a.move(n.safe(e.title,{before:u,after:o,...a.current()})),u+=a.move(o),l()),u+=a.move(")"),s(),u}function Ha(e,t,n,r){const o=e.referenceType,i=n.enter("linkReference");let a=n.enter("label");const s=n.createTracker(r);let l=s.move("[");const u=n.containerPhrasing(e,{before:l,after:"]",...s.current()});l+=s.move(u+"]["),a();const c=n.stack;n.stack=[],a=n.enter("reference");const d=n.safe(n.associationId(e),{before:l,after:"]",...s.current()});return a(),n.stack=c,i(),"full"!==o&&u&&u===d?"shortcut"===o?l=l.slice(0,-1):l+=s.move("]"):l+=s.move(d+"]"),l}function qa(e){const t=e.options.bullet||"*";if("*"!==t&&"+"!==t&&"-"!==t)throw new Error("Cannot serialize items with `"+t+"` for `options.bullet`, expected `*`, `+`, or `-`");return t}function Wa(e){const t=e.options.rule||"*";if("*"!==t&&"-"!==t&&"_"!==t)throw new Error("Cannot serialize rules with `"+t+"` for `options.rule`, expected `*`, `-`, or `_`");return t}Ca.peek=function(){return"~"},ja.peek=function(e,t,n){return n.options.emphasis||"*"},Fa.peek=function(){return"<"},Ma.peek=function(){return"!"},Ua.peek=function(){return"!"},Ba.peek=function(){return"`"},Va.peek=function(e,t,n){return $a(e,n)?"<":"["},Ha.peek=function(){return"["};const Ka=Xo(["break","delete","emphasis","footnote","footnoteReference","image","imageReference","inlineCode","inlineMath","link","linkReference","mdxJsxTextElement","mdxTextExpression","strong","text","textDirective"]);function Qa(e,t,n,r){const o=function(e){const t=e.options.strong||"*";if("*"!==t&&"_"!==t)throw new Error("Cannot serialize strong with `"+t+"` for `options.strong`, expected `*`, or `_`");return t}(n),i=n.enter("strong"),a=n.createTracker(r),s=a.move(o+o);let l=a.move(n.containerPhrasing(e,{after:o,before:s,...a.current()}));const u=l.charCodeAt(0),c=za(r.before.charCodeAt(r.before.length-1),u,o);c.inside&&(l=Da(u)+l.slice(1));const d=l.charCodeAt(l.length-1),f=za(r.after.charCodeAt(0),d,o);f.inside&&(l=l.slice(0,-1)+Da(d));const p=a.move(o+o);return i(),n.attentionEncodeSurroundingInfo={after:f.outside,before:c.outside},s+l+p}Qa.peek=function(e,t,n){return n.options.strong||"*"};const Ja={blockquote:function(e,t,n,r){const o=n.enter("blockquote"),i=n.createTracker(r);i.move("> "),i.shift(2);const a=n.indentLines(n.containerFlow(e,i.current()),Pa);return o(),a},break:_a,code:function(e,t,n,r){const o=function(e){const t=e.options.fence||"`";if("`"!==t&&"~"!==t)throw new Error("Cannot serialize code with `"+t+"` for `options.fence`, expected `` ` `` or `~`");return t}(n),i=e.value||"",a="`"===o?"GraveAccent":"Tilde";if(function(e,t){return Boolean(!1===t.options.fences&&e.value&&!e.lang&&/[^ \r\n]/.test(e.value)&&!/^[\t ]*(?:[\r\n]|$)|(?:^|[\r\n])[\t ]*$/.test(e.value))}(e,n)){const e=n.enter("codeIndented"),t=n.indentLines(i,Ia);return e(),t}const s=n.createTracker(r),l=o.repeat(Math.max(function(e,t){const n=String(e);let r=n.indexOf(t),o=r,i=0,a=0;if("string"!=typeof t)throw new TypeError("Expected substring");for(;-1!==r;)r===o?++i>a&&(a=i):i=1,o=r+t.length,r=n.indexOf(t,o);return a}(i,o)+1,3)),u=n.enter("codeFenced");let c=s.move(l);if(e.lang){const t=n.enter(`codeFencedLang${a}`);c+=s.move(n.safe(e.lang,{before:c,after:" ",encode:["`"],...s.current()})),t()}if(e.lang&&e.meta){const t=n.enter(`codeFencedMeta${a}`);c+=s.move(" "),c+=s.move(n.safe(e.meta,{before:c,after:"\n",encode:["`"],...s.current()})),t()}return c+=s.move("\n"),i&&(c+=s.move(i+"\n")),c+=s.move(l),u(),c},definition:function(e,t,n,r){const o=Aa(n),i='"'===o?"Quote":"Apostrophe",a=n.enter("definition");let s=n.enter("label");const l=n.createTracker(r);let u=l.move("[");return u+=l.move(n.safe(n.associationId(e),{before:u,after:"]",...l.current()})),u+=l.move("]: "),s(),!e.url||/[\0- \u007F]/.test(e.url)?(s=n.enter("destinationLiteral"),u+=l.move("<"),u+=l.move(n.safe(e.url,{before:u,after:">",...l.current()})),u+=l.move(">")):(s=n.enter("destinationRaw"),u+=l.move(n.safe(e.url,{before:u,after:e.title?" ":"\n",...l.current()}))),s(),e.title&&(s=n.enter(`title${i}`),u+=l.move(" "+o),u+=l.move(n.safe(e.title,{before:u,after:o,...l.current()})),u+=l.move(o),s()),a(),u},emphasis:ja,hardBreak:_a,heading:function(e,t,n,r){const o=Math.max(Math.min(6,e.depth||1),1),i=n.createTracker(r);if(function(e,t){let n=!1;return ii(e,function(e){if("value"in e&&/\r?\n|\r/.test(e.value)||"break"===e.type)return n=!0,ri}),Boolean((!e.depth||e.depth<3)&&Mn(e)&&(t.options.setext||n))}(e,n)){const t=n.enter("headingSetext"),r=n.enter("phrasing"),a=n.containerPhrasing(e,{...i.current(),before:"\n",after:"\n"});return r(),t(),a+"\n"+(1===o?"=":"-").repeat(a.length-(Math.max(a.lastIndexOf("\r"),a.lastIndexOf("\n"))+1))}const a="#".repeat(o),s=n.enter("headingAtx"),l=n.enter("phrasing");i.move(a+" ");let u=n.containerPhrasing(e,{before:"# ",after:"\n",...i.current()});return/^[\t ]/.test(u)&&(u=Da(u.charCodeAt(0))+u.slice(1)),u=u?a+" "+u:a,n.options.closeAtx&&(u+=" "+a),l(),s(),u},html:Fa,image:Ma,imageReference:Ua,inlineCode:Ba,link:Va,linkReference:Ha,list:function(e,t,n,r){const o=n.enter("list"),i=n.bulletCurrent;let a=e.ordered?function(e){const t=e.options.bulletOrdered||".";if("."!==t&&")"!==t)throw new Error("Cannot serialize items with `"+t+"` for `options.bulletOrdered`, expected `.` or `)`");return t}(n):qa(n);const s=e.ordered?"."===a?")":".":function(e){const t=qa(e),n=e.options.bulletOther;if(!n)return"*"===t?"-":"*";if("*"!==n&&"+"!==n&&"-"!==n)throw new Error("Cannot serialize items with `"+n+"` for `options.bulletOther`, expected `*`, `+`, or `-`");if(n===t)throw new Error("Expected `bullet` (`"+t+"`) and `bulletOther` (`"+n+"`) to be different");return n}(n);let l=!(!t||!n.bulletLastUsed)&&a===n.bulletLastUsed;if(!e.ordered){const t=e.children?e.children[0]:void 0;if("*"!==a&&"-"!==a||!t||t.children&&t.children[0]||"list"!==n.stack[n.stack.length-1]||"listItem"!==n.stack[n.stack.length-2]||"list"!==n.stack[n.stack.length-3]||"listItem"!==n.stack[n.stack.length-4]||0!==n.indexStack[n.indexStack.length-1]||0!==n.indexStack[n.indexStack.length-2]||0!==n.indexStack[n.indexStack.length-3]||(l=!0),Wa(n)===a&&t){let t=-1;for(;++t<e.children.length;){const n=e.children[t];if(n&&"listItem"===n.type&&n.children&&n.children[0]&&"thematicBreak"===n.children[0].type){l=!0;break}}}}l&&(a=s),n.bulletCurrent=a;const u=n.containerFlow(e,r);return n.bulletLastUsed=a,n.bulletCurrent=i,o(),u},listItem:function(e,t,n,r){const o=function(e){const t=e.options.listItemIndent||"one";if("tab"!==t&&"one"!==t&&"mixed"!==t)throw new Error("Cannot serialize items with `"+t+"` for `options.listItemIndent`, expected `tab`, `one`, or `mixed`");return t}(n);let i=n.bulletCurrent||qa(n);t&&"list"===t.type&&t.ordered&&(i=("number"==typeof t.start&&t.start>-1?t.start:1)+(!1===n.options.incrementListMarker?0:t.children.indexOf(e))+i);let a=i.length+1;("tab"===o||"mixed"===o&&(t&&"list"===t.type&&t.spread||e.spread))&&(a=4*Math.ceil(a/4));const s=n.createTracker(r);s.move(i+" ".repeat(a-i.length)),s.shift(a);const l=n.enter("listItem"),u=n.indentLines(n.containerFlow(e,s.current()),function(e,t,n){if(t)return(n?"":" ".repeat(a))+e;return(n?i:i+" ".repeat(a-i.length))+e});return l(),u},paragraph:function(e,t,n,r){const o=n.enter("paragraph"),i=n.enter("phrasing"),a=n.containerPhrasing(e,r);return i(),o(),a},root:function(e,t,n,r){return(e.children.some(function(e){return Ka(e)})?n.containerPhrasing:n.containerFlow).call(n,e,r)},strong:Qa,text:function(e,t,n,r){return n.safe(e.value,r)},thematicBreak:function(e,t,n){const r=(Wa(n)+(n.options.ruleSpaces?" ":"")).repeat(function(e){const t=e.options.ruleRepetition||3;if(t<3)throw new Error("Cannot serialize rules with repetition `"+t+"` for `options.ruleRepetition`, expected `3` or more");return t}(n));return n.options.ruleSpaces?r.slice(0,-1):r}};function Ya(e){const t=e._align;this.enter({type:"table",align:t.map(function(e){return"none"===e?null:e}),children:[]},e),this.data.inTable=!0}function Ga(e){this.exit(e),this.data.inTable=void 0}function Xa(e){this.enter({type:"tableRow",children:[]},e)}function Za(e){this.exit(e)}function es(e){this.enter({type:"tableCell",children:[]},e)}function ts(e){let t=this.resume();this.data.inTable&&(t=t.replace(/\\([\\|])/g,ns));const n=this.stack[this.stack.length-1];n.type,n.value=t,this.exit(e)}function ns(e,t){return"|"===t?t:e}function rs(e){const t=e||{},n=t.tableCellPadding,r=t.tablePipeAlign,o=t.stringLength,i=n?" ":"|";return{unsafe:[{character:"\r",inConstruct:"tableCell"},{character:"\n",inConstruct:"tableCell"},{atBreak:!0,character:"|",after:"[\t :-]"},{character:"|",inConstruct:"tableCell"},{atBreak:!0,character:":",after:"-"},{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{inlineCode:function(e,t,n){let r=Ja.inlineCode(e,t,n);n.stack.includes("tableCell")&&(r=r.replace(/\|/g,"\\$&"));return r},table:function(e,t,n,r){return s(function(e,t,n){const r=e.children;let o=-1;const i=[],a=t.enter("table");for(;++o<r.length;)i[o]=l(r[o],t,n);return a(),i}(e,n,r),e.align)},tableCell:a,tableRow:function(e,t,n,r){const o=s([l(e,n,r)]);return o.slice(0,o.indexOf("\n"))}}};function a(e,t,n,r){const o=n.enter("tableCell"),a=n.enter("phrasing"),s=n.containerPhrasing(e,{...r,before:i,after:i});return a(),o(),s}function s(e,t){return function(e,t){const n=t||{},r=(n.align||[]).concat(),o=n.stringLength||Ta,i=[],a=[],s=[],l=[];let u=0,c=-1;for(;++c<e.length;){const t=[],r=[];let i=-1;for(e[c].length>u&&(u=e[c].length);++i<e[c].length;){const a=Oa(e[c][i]);if(!1!==n.alignDelimiters){const e=o(a);r[i]=e,(void 0===l[i]||e>l[i])&&(l[i]=e)}t.push(a)}a[c]=t,s[c]=r}let d=-1;if("object"==typeof r&&"length"in r)for(;++d<u;)i[d]=Na(r[d]);else{const e=Na(r);for(;++d<u;)i[d]=e}d=-1;const f=[],p=[];for(;++d<u;){const e=i[d];let t="",r="";99===e?(t=":",r=":"):108===e?t=":":114===e&&(r=":");let o=!1===n.alignDelimiters?1:Math.max(1,l[d]-t.length-r.length);const a=t+"-".repeat(o)+r;!1!==n.alignDelimiters&&(o=t.length+o+r.length,o>l[d]&&(l[d]=o),p[d]=o),f[d]=a}a.splice(1,0,f),s.splice(1,0,p),c=-1;const h=[];for(;++c<a.length;){const e=a[c],t=s[c];d=-1;const r=[];for(;++d<u;){const o=e[d]||"";let a="",s="";if(!1!==n.alignDelimiters){const e=l[d]-(t[d]||0),n=i[d];114===n?a=" ".repeat(e):99===n?e%2?(a=" ".repeat(e/2+.5),s=" ".repeat(e/2-.5)):(a=" ".repeat(e/2),s=a):s=" ".repeat(e)}!1===n.delimiterStart||d||r.push("|"),!1===n.padding||!1===n.alignDelimiters&&""===o||!1===n.delimiterStart&&!d||r.push(" "),!1!==n.alignDelimiters&&r.push(a),r.push(o),!1!==n.alignDelimiters&&r.push(s),!1!==n.padding&&r.push(" "),!1===n.delimiterEnd&&d===u-1||r.push("|")}h.push(!1===n.delimiterEnd?r.join("").replace(/ +$/,""):r.join(""))}return h.join("\n")}(e,{align:t,alignDelimiters:r,padding:n,stringLength:o})}function l(e,t,n){const r=e.children;let o=-1;const i=[],s=t.enter("tableRow");for(;++o<r.length;)i[o]=a(r[o],0,t,n);return s(),i}}function os(e){const t=this.stack[this.stack.length-2];t.type,t.checked="taskListCheckValueChecked"===e.type}function is(e){const t=this.stack[this.stack.length-2];if(t&&"listItem"===t.type&&"boolean"==typeof t.checked){const e=this.stack[this.stack.length-1];e.type;const n=e.children[0];if(n&&"text"===n.type){const r=t.children;let o,i=-1;for(;++i<r.length;){const e=r[i];if("paragraph"===e.type){o=e;break}}o===e&&(n.value=n.value.slice(1),0===n.value.length?e.children.shift():e.position&&n.position&&"number"==typeof n.position.start.offset&&(n.position.start.column++,n.position.start.offset++,e.position.start=Object.assign({},n.position.start)))}}this.exit(e)}function as(e,t,n,r){const o=e.children[0],i="boolean"==typeof e.checked&&o&&"paragraph"===o.type,a="["+(e.checked?"x":" ")+"] ",s=n.createTracker(r);i&&s.move(a);let l=Ja.listItem(e,t,n,{...r,...s.current()});return i&&(l=l.replace(/^(?:[*+-]|\d+\.)([\r\n]| {1,3})/,function(e){return e+a})),l}const ss={tokenize:function(e,t,n){let r=0;return function t(i){if((87===i||119===i)&&r<3)return r++,e.consume(i),t;if(46===i&&3===r)return e.consume(i),o;return n(i)};function o(e){return null===e?n(e):t(e)}},partial:!0},ls={tokenize:function(e,t,n){let r,o,i;return a;function a(t){return 46===t||95===t?e.check(cs,l,s)(t):null===t||ar(t)||ur(t)||45!==t&&lr(t)?l(t):(i=!0,e.consume(t),a)}function s(t){return 95===t?r=!0:(o=r,r=void 0),e.consume(t),a}function l(e){return o||r||!i?n(e):t(e)}},partial:!0},us={tokenize:function(e,t){let n=0,r=0;return o;function o(a){return 40===a?(n++,e.consume(a),o):41===a&&r<n?i(a):33===a||34===a||38===a||39===a||41===a||42===a||44===a||46===a||58===a||59===a||60===a||63===a||93===a||95===a||126===a?e.check(cs,t,i)(a):null===a||ar(a)||ur(a)?t(a):(e.consume(a),o)}function i(t){return 41===t&&r++,e.consume(t),o}},partial:!0},cs={tokenize:function(e,t,n){return r;function r(a){return 33===a||34===a||39===a||41===a||42===a||44===a||46===a||58===a||59===a||63===a||95===a||126===a?(e.consume(a),r):38===a?(e.consume(a),i):93===a?(e.consume(a),o):60===a||null===a||ar(a)||ur(a)?t(a):n(a)}function o(e){return null===e||40===e||91===e||ar(e)||ur(e)?t(e):r(e)}function i(e){return Xn(e)?a(e):n(e)}function a(t){return 59===t?(e.consume(t),r):Xn(t)?(e.consume(t),a):n(t)}},partial:!0},ds={tokenize:function(e,t,n){return function(t){return e.consume(t),r};function r(e){return Zn(e)?n(e):t(e)}},partial:!0},fs={name:"wwwAutolink",tokenize:function(e,t,n){const r=this;return function(t){if(87!==t&&119!==t||!ys.call(r,r.previous)||xs(r.events))return n(t);return e.enter("literalAutolink"),e.enter("literalAutolinkWww"),e.check(ss,e.attempt(ls,e.attempt(us,o),n),n)(t)};function o(n){return e.exit("literalAutolinkWww"),e.exit("literalAutolink"),t(n)}},previous:ys},ps={name:"protocolAutolink",tokenize:function(e,t,n){const r=this;let o="",i=!1;return function(t){if((72===t||104===t)&&vs.call(r,r.previous)&&!xs(r.events))return e.enter("literalAutolink"),e.enter("literalAutolinkHttp"),o+=String.fromCodePoint(t),e.consume(t),a;return n(t)};function a(t){if(Xn(t)&&o.length<5)return o+=String.fromCodePoint(t),e.consume(t),a;if(58===t){const n=o.toLowerCase();if("http"===n||"https"===n)return e.consume(t),s}return n(t)}function s(t){return 47===t?(e.consume(t),i?l:(i=!0,s)):n(t)}function l(t){return null===t||tr(t)||ar(t)||ur(t)||lr(t)?n(t):e.attempt(ls,e.attempt(us,u),n)(t)}function u(n){return e.exit("literalAutolinkHttp"),e.exit("literalAutolink"),t(n)}},previous:vs},hs={name:"emailAutolink",tokenize:function(e,t,n){const r=this;let o,i;return function(t){if(!ks(t)||!bs.call(r,r.previous)||xs(r.events))return n(t);return e.enter("literalAutolink"),e.enter("literalAutolinkEmail"),a(t)};function a(t){return ks(t)?(e.consume(t),a):64===t?(e.consume(t),s):n(t)}function s(t){return 46===t?e.check(ds,u,l)(t):45===t||95===t||Zn(t)?(i=!0,e.consume(t),s):u(t)}function l(t){return e.consume(t),o=!0,s}function u(a){return i&&o&&Xn(r.previous)?(e.exit("literalAutolinkEmail"),e.exit("literalAutolink"),t(a)):n(a)}},previous:bs},gs={};let ms=48;for(;ms<123;)gs[ms]=hs,ms++,58===ms?ms=65:91===ms&&(ms=97);function ys(e){return null===e||40===e||42===e||95===e||91===e||93===e||126===e||ar(e)}function vs(e){return!Xn(e)}function bs(e){return!(47===e||ks(e))}function ks(e){return 43===e||45===e||46===e||95===e||Zn(e)}function xs(e){let t=e.length,n=!1;for(;t--;){const r=e[t][1];if(("labelLink"===r.type||"labelImage"===r.type)&&!r._balanced){n=!0;break}if(r._gfmAutolinkLiteralWalkedInto){n=!1;break}}return e.length>0&&!n&&(e[e.length-1][1]._gfmAutolinkLiteralWalkedInto=!0),n}gs[43]=hs,gs[45]=hs,gs[46]=hs,gs[95]=hs,gs[72]=[hs,ps],gs[104]=[hs,ps],gs[87]=[hs,fs],gs[119]=[hs,fs];const ws={tokenize:function(e,t,n){const r=this;return fr(e,function(e){const o=r.events[r.events.length-1];return o&&"gfmFootnoteDefinitionIndent"===o[1].type&&4===o[2].sliceSerialize(o[1],!0).length?t(e):n(e)},"gfmFootnoteDefinitionIndent",5)},partial:!0};function Ss(e,t,n){const r=this;let o=r.events.length;const i=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]);let a;for(;o--;){const e=r.events[o][1];if("labelImage"===e.type){a=e;break}if("gfmFootnoteCall"===e.type||"labelLink"===e.type||"label"===e.type||"image"===e.type||"link"===e.type)break}return function(o){if(!a||!a._balanced)return n(o);const s=Gn(r.sliceSerialize({start:a.end,end:r.now()}));if(94!==s.codePointAt(0)||!i.includes(s.slice(1)))return n(o);return e.enter("gfmFootnoteCallLabelMarker"),e.consume(o),e.exit("gfmFootnoteCallLabelMarker"),t(o)}}function Es(e,t){let n=e.length;for(;n--;)if("labelImage"===e[n][1].type&&"enter"===e[n][0]){e[n][1];break}e[n+1][1].type="data",e[n+3][1].type="gfmFootnoteCallLabelMarker";const r={type:"gfmFootnoteCall",start:Object.assign({},e[n+3][1].start),end:Object.assign({},e[e.length-1][1].end)},o={type:"gfmFootnoteCallMarker",start:Object.assign({},e[n+3][1].end),end:Object.assign({},e[n+3][1].end)};o.end.column++,o.end.offset++,o.end._bufferIndex++;const i={type:"gfmFootnoteCallString",start:Object.assign({},o.end),end:Object.assign({},e[e.length-1][1].start)},a={type:"chunkString",contentType:"string",start:Object.assign({},i.start),end:Object.assign({},i.end)},s=[e[n+1],e[n+2],["enter",r,t],e[n+3],e[n+4],["enter",o,t],["exit",o,t],["enter",i,t],["enter",a,t],["exit",a,t],["exit",i,t],e[e.length-2],e[e.length-1],["exit",r,t]];return e.splice(n,e.length-n+1,...s),e}function Cs(e,t,n){const r=this,o=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]);let i,a=0;return function(t){return e.enter("gfmFootnoteCall"),e.enter("gfmFootnoteCallLabelMarker"),e.consume(t),e.exit("gfmFootnoteCallLabelMarker"),s};function s(t){return 94!==t?n(t):(e.enter("gfmFootnoteCallMarker"),e.consume(t),e.exit("gfmFootnoteCallMarker"),e.enter("gfmFootnoteCallString"),e.enter("chunkString").contentType="string",l)}function l(s){if(a>999||93===s&&!i||null===s||91===s||ar(s))return n(s);if(93===s){e.exit("chunkString");const i=e.exit("gfmFootnoteCallString");return o.includes(Gn(r.sliceSerialize(i)))?(e.enter("gfmFootnoteCallLabelMarker"),e.consume(s),e.exit("gfmFootnoteCallLabelMarker"),e.exit("gfmFootnoteCall"),t):n(s)}return ar(s)||(i=!0),a++,e.consume(s),92===s?u:l}function u(t){return 91===t||92===t||93===t?(e.consume(t),a++,l):l(t)}}function Ts(e,t,n){const r=this,o=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]);let i,a,s=0;return function(t){return e.enter("gfmFootnoteDefinition")._container=!0,e.enter("gfmFootnoteDefinitionLabel"),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(t),e.exit("gfmFootnoteDefinitionLabelMarker"),l};function l(t){return 94===t?(e.enter("gfmFootnoteDefinitionMarker"),e.consume(t),e.exit("gfmFootnoteDefinitionMarker"),e.enter("gfmFootnoteDefinitionLabelString"),e.enter("chunkString").contentType="string",u):n(t)}function u(t){if(s>999||93===t&&!a||null===t||91===t||ar(t))return n(t);if(93===t){e.exit("chunkString");const n=e.exit("gfmFootnoteDefinitionLabelString");return i=Gn(r.sliceSerialize(n)),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(t),e.exit("gfmFootnoteDefinitionLabelMarker"),e.exit("gfmFootnoteDefinitionLabel"),d}return ar(t)||(a=!0),s++,e.consume(t),92===t?c:u}function c(t){return 91===t||92===t||93===t?(e.consume(t),s++,u):u(t)}function d(t){return 58===t?(e.enter("definitionMarker"),e.consume(t),e.exit("definitionMarker"),o.includes(i)||o.push(i),fr(e,f,"gfmFootnoteDefinitionWhitespace")):n(t)}function f(e){return t(e)}}function Os(e,t,n){return e.check(xr,t,e.attempt(ws,t,n))}function Ns(e){e.exit("gfmFootnoteDefinition")}function Ps(e){let t=(e||{}).singleTilde;const n={name:"strikethrough",tokenize:function(e,n,r){const o=this.previous,i=this.events;let a=0;return function(t){if(126===o&&"characterEscape"!==i[i.length-1][1].type)return r(t);return e.enter("strikethroughSequenceTemporary"),s(t)};function s(i){const l=mr(o);if(126===i)return a>1?r(i):(e.consume(i),a++,s);if(a<2&&!t)return r(i);const u=e.exit("strikethroughSequenceTemporary"),c=mr(i);return u._open=!c||2===c&&Boolean(l),u._close=!l||2===l&&Boolean(c),n(i)}},resolveAll:function(e,t){let n=-1;for(;++n<e.length;)if("enter"===e[n][0]&&"strikethroughSequenceTemporary"===e[n][1].type&&e[n][1]._close){let r=n;for(;r--;)if("exit"===e[r][0]&&"strikethroughSequenceTemporary"===e[r][1].type&&e[r][1]._open&&e[n][1].end.offset-e[n][1].start.offset===e[r][1].end.offset-e[r][1].start.offset){e[n][1].type="strikethroughSequence",e[r][1].type="strikethroughSequence";const o={type:"strikethrough",start:Object.assign({},e[r][1].start),end:Object.assign({},e[n][1].end)},i={type:"strikethroughText",start:Object.assign({},e[r][1].end),end:Object.assign({},e[n][1].start)},a=[["enter",o,t],["enter",e[r][1],t],["exit",e[r][1],t],["enter",i,t]],s=t.parser.constructs.insideSpan.null;s&&Hn(a,a.length,0,yr(s,e.slice(r+1,n),t)),Hn(a,a.length,0,[["exit",i,t],["enter",e[n][1],t],["exit",e[n][1],t],["exit",o,t]]),Hn(e,r-1,n-r+3,a),n=r+a.length-2;break}}n=-1;for(;++n<e.length;)"strikethroughSequenceTemporary"===e[n][1].type&&(e[n][1].type="data");return e}};return null==t&&(t=!0),{text:{126:n},insideSpan:{null:[n]},attentionMarkers:{null:[126]}}}class Ls{constructor(){this.map=[]}add(e,t,n){!function(e,t,n,r){let o=0;if(0===n&&0===r.length)return;for(;o<e.map.length;){if(e.map[o][0]===t)return e.map[o][1]+=n,void e.map[o][2].push(...r);o+=1}e.map.push([t,n,r])}(this,e,t,n)}consume(e){if(this.map.sort(function(e,t){return e[0]-t[0]}),0===this.map.length)return;let t=this.map.length;const n=[];for(;t>0;)t-=1,n.push(e.slice(this.map[t][0]+this.map[t][1]),this.map[t][2]),e.length=this.map[t][0];n.push(e.slice()),e.length=0;let r=n.pop();for(;r;){for(const t of r)e.push(t);r=n.pop()}this.map.length=0}}function Rs(e,t){let n=!1;const r=[];for(;t<e.length;){const o=e[t];if(n){if("enter"===o[0])"tableContent"===o[1].type&&r.push("tableDelimiterMarker"===e[t+1][1].type?"left":"none");else if("tableContent"===o[1].type){if("tableDelimiterMarker"===e[t-1][1].type){const e=r.length-1;r[e]="left"===r[e]?"center":"right"}}else if("tableDelimiterRow"===o[1].type)break}else"enter"===o[0]&&"tableDelimiterRow"===o[1].type&&(n=!0);t+=1}return r}function _s(e,t,n){const r=this;let o,i=0,a=0;return function(e){let t=r.events.length-1;for(;t>-1;){const e=r.events[t][1].type;if("lineEnding"!==e&&"linePrefix"!==e)break;t--}const o=t>-1?r.events[t][1].type:null,i="tableHead"===o||"tableRow"===o?k:s;if(i===k&&r.parser.lazy[r.now().line])return n(e);return i(e)};function s(t){return e.enter("tableHead"),e.enter("tableRow"),function(e){if(124===e)return l(e);return o=!0,a+=1,l(e)}(t)}function l(t){return null===t?n(t):ir(t)?a>1?(a=0,r.interrupt=!0,e.exit("tableRow"),e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),d):n(t):sr(t)?fr(e,l,"whitespace")(t):(a+=1,o&&(o=!1,i+=1),124===t?(e.enter("tableCellDivider"),e.consume(t),e.exit("tableCellDivider"),o=!0,l):(e.enter("data"),u(t)))}function u(t){return null===t||124===t||ar(t)?(e.exit("data"),l(t)):(e.consume(t),92===t?c:u)}function c(t){return 92===t||124===t?(e.consume(t),u):u(t)}function d(t){return r.interrupt=!1,r.parser.lazy[r.now().line]?n(t):(e.enter("tableDelimiterRow"),o=!1,sr(t)?fr(e,f,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(t):f(t))}function f(t){return 45===t||58===t?h(t):124===t?(o=!0,e.enter("tableCellDivider"),e.consume(t),e.exit("tableCellDivider"),p):b(t)}function p(t){return sr(t)?fr(e,h,"whitespace")(t):h(t)}function h(t){return 58===t?(a+=1,o=!0,e.enter("tableDelimiterMarker"),e.consume(t),e.exit("tableDelimiterMarker"),g):45===t?(a+=1,g(t)):null===t||ir(t)?v(t):b(t)}function g(t){return 45===t?(e.enter("tableDelimiterFiller"),m(t)):b(t)}function m(t){return 45===t?(e.consume(t),m):58===t?(o=!0,e.exit("tableDelimiterFiller"),e.enter("tableDelimiterMarker"),e.consume(t),e.exit("tableDelimiterMarker"),y):(e.exit("tableDelimiterFiller"),y(t))}function y(t){return sr(t)?fr(e,v,"whitespace")(t):v(t)}function v(n){return 124===n?f(n):(null===n||ir(n))&&o&&i===a?(e.exit("tableDelimiterRow"),e.exit("tableHead"),t(n)):b(n)}function b(e){return n(e)}function k(t){return e.enter("tableRow"),x(t)}function x(n){return 124===n?(e.enter("tableCellDivider"),e.consume(n),e.exit("tableCellDivider"),x):null===n||ir(n)?(e.exit("tableRow"),t(n)):sr(n)?fr(e,x,"whitespace")(n):(e.enter("data"),w(n))}function w(t){return null===t||124===t||ar(t)?(e.exit("data"),x(t)):(e.consume(t),92===t?S:w)}function S(t){return 92===t||124===t?(e.consume(t),w):w(t)}}function Is(e,t){let n,r,o,i=-1,a=!0,s=0,l=[0,0,0,0],u=[0,0,0,0],c=!1,d=0;const f=new Ls;for(;++i<e.length;){const p=e[i],h=p[1];"enter"===p[0]?"tableHead"===h.type?(c=!1,0!==d&&(Ds(f,t,d,n,r),r=void 0,d=0),n={type:"table",start:Object.assign({},h.start),end:Object.assign({},h.end)},f.add(i,0,[["enter",n,t]])):"tableRow"===h.type||"tableDelimiterRow"===h.type?(a=!0,o=void 0,l=[0,0,0,0],u=[0,i+1,0,0],c&&(c=!1,r={type:"tableBody",start:Object.assign({},h.start),end:Object.assign({},h.end)},f.add(i,0,[["enter",r,t]])),s="tableDelimiterRow"===h.type?2:r?3:1):!s||"data"!==h.type&&"tableDelimiterMarker"!==h.type&&"tableDelimiterFiller"!==h.type?"tableCellDivider"===h.type&&(a?a=!1:(0!==l[1]&&(u[0]=u[1],o=As(f,t,l,s,void 0,o)),l=u,u=[l[1],i,0,0])):(a=!1,0===u[2]&&(0!==l[1]&&(u[0]=u[1],o=As(f,t,l,s,void 0,o),l=[0,0,0,0]),u[2]=i)):"tableHead"===h.type?(c=!0,d=i):"tableRow"===h.type||"tableDelimiterRow"===h.type?(d=i,0!==l[1]?(u[0]=u[1],o=As(f,t,l,s,i,o)):0!==u[1]&&(o=As(f,t,u,s,i,o)),s=0):!s||"data"!==h.type&&"tableDelimiterMarker"!==h.type&&"tableDelimiterFiller"!==h.type||(u[3]=i)}for(0!==d&&Ds(f,t,d,n,r),f.consume(t.events),i=-1;++i<t.events.length;){const e=t.events[i];"enter"===e[0]&&"table"===e[1].type&&(e[1]._align=Rs(t.events,i))}return e}function As(e,t,n,r,o,i){const a=1===r?"tableHeader":2===r?"tableDelimiter":"tableData";0!==n[0]&&(i.end=Object.assign({},zs(t.events,n[0])),e.add(n[0],0,[["exit",i,t]]));const s=zs(t.events,n[1]);if(i={type:a,start:Object.assign({},s),end:Object.assign({},s)},e.add(n[1],0,[["enter",i,t]]),0!==n[2]){const o=zs(t.events,n[2]),i=zs(t.events,n[3]),a={type:"tableContent",start:Object.assign({},o),end:Object.assign({},i)};if(e.add(n[2],0,[["enter",a,t]]),2!==r){const r=t.events[n[2]],o=t.events[n[3]];if(r[1].end=Object.assign({},o[1].end),r[1].type="chunkText",r[1].contentType="text",n[3]>n[2]+1){const t=n[2]+1,r=n[3]-n[2]-1;e.add(t,r,[])}}e.add(n[3]+1,0,[["exit",a,t]])}return void 0!==o&&(i.end=Object.assign({},zs(t.events,o)),e.add(o,0,[["exit",i,t]]),i=void 0),i}function Ds(e,t,n,r,o){const i=[],a=zs(t.events,n);o&&(o.end=Object.assign({},a),i.push(["exit",o,t])),r.end=Object.assign({},a),i.push(["exit",r,t]),e.add(n+1,0,i)}function zs(e,t){const n=e[t],r="enter"===n[0]?"start":"end";return n[1][r]}const js={name:"tasklistCheck",tokenize:function(e,t,n){const r=this;return function(t){if(null!==r.previous||!r._gfmTasklistFirstContentOfListItem)return n(t);return e.enter("taskListCheck"),e.enter("taskListCheckMarker"),e.consume(t),e.exit("taskListCheckMarker"),o};function o(t){return ar(t)?(e.enter("taskListCheckValueUnchecked"),e.consume(t),e.exit("taskListCheckValueUnchecked"),i):88===t||120===t?(e.enter("taskListCheckValueChecked"),e.consume(t),e.exit("taskListCheckValueChecked"),i):n(t)}function i(t){return 93===t?(e.enter("taskListCheckMarker"),e.consume(t),e.exit("taskListCheckMarker"),e.exit("taskListCheck"),a):n(t)}function a(r){return ir(r)?t(r):sr(r)?e.check({tokenize:Fs},t,n)(r):n(r)}}};function Fs(e,t,n){return fr(e,function(e){return null===e?n(e):t(e)},"whitespace")}const Ms={};function Us(e){const t=e||Ms,n=this.data(),r=n.micromarkExtensions||(n.micromarkExtensions=[]),o=n.fromMarkdownExtensions||(n.fromMarkdownExtensions=[]),i=n.toMarkdownExtensions||(n.toMarkdownExtensions=[]);r.push(function(e){return Kn([{text:gs},{document:{91:{name:"gfmFootnoteDefinition",tokenize:Ts,continuation:{tokenize:Os},exit:Ns}},text:{91:{name:"gfmFootnoteCall",tokenize:Cs},93:{name:"gfmPotentialFootnoteCall",add:"after",tokenize:Ss,resolveTo:Es}}},Ps(e),{flow:{null:{name:"table",tokenize:_s,resolveAll:Is}}},{text:{91:js}}])}(t)),o.push([{transforms:[aa],enter:{literalAutolink:ea,literalAutolinkEmail:ta,literalAutolinkHttp:ta,literalAutolinkWww:ta},exit:{literalAutolink:ia,literalAutolinkEmail:oa,literalAutolinkHttp:na,literalAutolinkWww:ra}},{enter:{gfmFootnoteCallString:ca,gfmFootnoteCall:da,gfmFootnoteDefinitionLabelString:fa,gfmFootnoteDefinition:pa},exit:{gfmFootnoteCallString:ha,gfmFootnoteCall:ga,gfmFootnoteDefinitionLabelString:ma,gfmFootnoteDefinition:ya}},{canContainEols:["delete"],enter:{strikethrough:Sa},exit:{strikethrough:Ea}},{enter:{table:Ya,tableData:es,tableHeader:es,tableRow:Xa},exit:{codeText:ts,table:Ga,tableData:Za,tableHeader:Za,tableRow:Za}},{exit:{taskListCheckValueChecked:os,taskListCheckValueUnchecked:os,paragraph:is}}]),i.push(function(e){return{extensions:[{unsafe:[{character:"@",before:"[+\\-.\\w]",after:"[\\-.\\w]",inConstruct:Xi,notInConstruct:Zi},{character:".",before:"[Ww]",after:"[\\-.\\w]",inConstruct:Xi,notInConstruct:Zi},{character:":",before:"[ps]",after:"\\/",inConstruct:Xi,notInConstruct:Zi}]},ba(e),{unsafe:[{character:"~",inConstruct:"phrasing",notInConstruct:wa}],handlers:{delete:Ca}},rs(e),{unsafe:[{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{listItem:as}}]}}(t))}const Bs="https://www.tiagpctest.softiabot.com",$s={BOTTOM_RIGHT:"bottom-right",BOTTOM_LEFT:"bottom-left",TOP_RIGHT:"top-right",TOP_LEFT:"top-left"},Vs={LIGHT:"light",DARK:"dark",AUTO:"auto"},Hs={SPANISH:"es",ENGLISH:"en",FRANCES:"fr"},qs=640,Ws=Vs.AUTO,Ks=$s.BOTTOM_RIGHT,Qs=Hs.ENGLISH,Js="400px",Ys="600px",Gs=!1,Xs=!0,Zs=!0,el=3e4,tl=2e3,nl=e=>{try{return new Date(e).toLocaleTimeString("es-ES",{hour:"2-digit",minute:"2-digit"})}catch{return""}},rl=()=>crypto.randomUUID(),ol=({size:e="md",className:t=""})=>O.jsx("div",{className:`gpc-spinner ${{sm:"w-4 h-4 border-2",md:"w-6 h-6 border-2",lg:"w-8 h-8 border-3"}[e]} ${t}`,role:"status","aria-label":"Cargando",children:O.jsx("span",{className:"sr-only",children:"Cargando..."})}),il=()=>O.jsxs("div",{className:"gpc-typing-indicator",role:"status","aria-label":"Escribiendo",children:[O.jsx("span",{className:"gpc-typing-dot"}),O.jsx("span",{className:"gpc-typing-dot"}),O.jsx("span",{className:"gpc-typing-dot"})]}),al=({message:e,showMetadata:t=!1,messageRef:n=null})=>{const{t:r}=V(),o="user"===e.role,i=!o&&e.isStreaming&&!e.content;return O.jsxs("div",{ref:n,className:"gpc-message "+(o?"gpc-message-user":"gpc-message-assistant"),role:"article","aria-label":o?"Mensaje del usuario":"Mensaje del asistente",children:[O.jsx("div",{className:"gpc-message-content",children:i?O.jsx(il,{}):o?e.content.trim():O.jsx(Wi,{remarkPlugins:[Us],components:{table:({node:e,...t})=>O.jsx("div",{className:"gpc-table-wrapper",children:O.jsx("table",{className:"gpc-table",...t})}),thead:({node:e,...t})=>O.jsx("thead",{className:"gpc-table-head",...t}),tbody:({node:e,...t})=>O.jsx("tbody",{className:"gpc-table-body",...t}),tr:({node:e,...t})=>O.jsx("tr",{className:"gpc-table-row",...t}),th:({node:e,...t})=>O.jsx("th",{className:"gpc-table-header",...t}),td:({node:e,...t})=>O.jsx("td",{className:"gpc-table-cell",...t})},children:e.content})}),O.jsx("div",{className:"gpc-message-timestamp "+(o?"gpc-message-timestamp-user":""),children:nl(e.timestamp)}),!o&&t&&e.metadata&&O.jsxs("div",{className:"gpc-message-metadata",children:[e.metadata.tokensUsed&&O.jsxs("div",{className:"gpc-metadata-item",children:[O.jsxs("strong",{children:[r("metadata.tokensUsed"),":"]})," ",e.metadata.tokensUsed]}),e.metadata.responseTimeMs&&O.jsxs("div",{className:"gpc-metadata-item",children:[O.jsxs("strong",{children:[r("metadata.responseTime"),":"]})," ",(a=e.metadata.responseTimeMs,a>=1e3?`${(a/1e3).toFixed(1)}s`:`${Math.round(a)}ms`)]}),e.metadata.model&&O.jsxs("div",{className:"gpc-metadata-item",children:[O.jsxs("strong",{children:[r("metadata.model"),":"]})," ",e.metadata.model]})]})]});var a},sl=({messages:e,isLoading:t,showMetadata:n=!1,widgetConfig:r=null})=>{const{t:o}=V(),i=l.useRef(null),a=l.useRef(null),s=l.useRef(e.length);l.useEffect(()=>{const t=e.length>s.current,n=e[e.length-1];t&&n&&("user"===n.role?i.current?.scrollIntoView({behavior:"smooth"}):"assistant"===n.role&&n.isStreaming&&setTimeout(()=>{a.current?.scrollIntoView({behavior:"smooth",block:"start"})},100)),s.current=e.length},[e]);const u=r?.company_name||"TIA GPC",c=r?.company_logo_base64,d=c?.startsWith("data:")?c:c?`data:image/png;base64,${c}`:null;return 0!==e.length||t?O.jsxs("div",{className:"gpc-messages-container gpc-scrollbar gpc-smooth-scroll",children:[e.map((t,r)=>O.jsx(al,{message:t,showMetadata:n,messageRef:r===e.length-1?a:null},t.id)),O.jsx("div",{ref:i})]}):O.jsx("div",{className:"gpc-messages-container",children:O.jsxs("div",{className:"gpc-empty-state",children:[d?O.jsx("div",{className:"gpc-welcome-logo",children:O.jsx("img",{src:d,alt:u,className:"gpc-welcome-company-logo"})}):O.jsx(te,{className:"gpc-empty-icon"}),O.jsx("h3",{className:"gpc-empty-title",children:o("chat.welcome",{companyName:u})}),O.jsx("p",{className:"gpc-empty-text",children:o("chat.emptyState")})]})})},ll=({onTranscript:e,isLoading:t,disabled:n,onRecordingStateChange:r})=>{const{t:o}=V(),[i,a]=l.useState(!1),[s,u]=l.useState(!1),c=l.useRef(null),d=l.useRef([]),f=l.useRef(null),p=l.useRef(null),h=l.useRef(null),g=l.useRef(null),m=l.useRef(null);l.useEffect(()=>()=>{"recording"===c.current?.state&&c.current.stop(),f.current&&"closed"!==f.current.state&&f.current.close(),m.current&&clearInterval(m.current)},[]),l.useEffect(()=>{r&&r(i||s)},[i,s,r]);const y=async()=>{try{if(!navigator.mediaDevices||!navigator.mediaDevices.getUserMedia)return void alert(o("voice.unsupported"));const t=await navigator.mediaDevices.getUserMedia({audio:{echoCancellation:!0,noiseSuppression:!0,autoGainControl:!0,sampleRate:48e3,channelCount:1}});f.current=new(window.AudioContext||window.webkitAudioContext),p.current=f.current.createAnalyser();f.current.createMediaStreamSource(t).connect(p.current),p.current.fftSize=1024,p.current.smoothingTimeConstant=.4,p.current.minDecibels=-85,p.current.maxDecibels=-15;const n=p.current.frequencyBinCount;h.current=new Uint8Array(n);const r=new MediaRecorder(t,{mimeType:"audio/webm;codecs=opus"});c.current=r,d.current=[],g.current=null,r.ondataavailable=e=>{e.data.size>0&&d.current.push(e.data)},r.onstop=async()=>{if(m.current&&(clearInterval(m.current),m.current=null),f.current&&"closed"!==f.current.state&&f.current.close(),g.current=null,0===d.current.length)return;const t=new Blob(d.current,{type:"audio/webm"});u(!0);try{await e(t)}catch(n){alert(o("voice.error"))}finally{u(!1),d.current=[]}},r.start(100),a(!0),m.current=setInterval(()=>{(()=>{if(!p.current||!h.current)return;p.current.getByteTimeDomainData(h.current);let e=0;for(let t=0;t<h.current.length;t++){const n=(h.current[t]-128)/128;e+=n*n}if(100*Math.sqrt(e/h.current.length)<1.2){if(g.current||(g.current=Date.now()),Date.now()-g.current>2e3)v()}else g.current=null})()},100)}catch(t){"NotAllowedError"===t.name||"PermissionDeniedError"===t.name?alert(o("voice.permissionDenied")):alert(o("voice.unsupported"))}},v=()=>{(i||"recording"===c.current?.state)&&(c.current&&"recording"===c.current.state&&c.current.stop(),m.current&&(clearInterval(m.current),m.current=null),g.current=null,a(!1),c.current&&c.current.stream&&c.current.stream.getTracks().forEach(e=>e.stop()))},b=n||t||s,k=o(s?"voice.processing":i?"voice.stop":"voice.record");return O.jsx("button",{type:"button",onClick:()=>{i?v():y()},disabled:b,className:"gpc-voice-button "+(i?"gpc-voice-recording":""),"aria-label":k,title:k,children:s?O.jsx("span",{className:"gpc-spinner"}):i?O.jsx(ne,{className:"gpc-icon gpc-voice-icon-active"}):O.jsx(re,{className:"gpc-icon"})})},ul=({onSendMessage:e,isLoading:t,disabled:n,gpcService:r})=>{const{t:o}=V(),[i,a]=l.useState(""),[s,u]=l.useState(!1),c=l.useRef(null);l.useEffect(()=>{n||t||s||c.current?.focus()},[n,t,s]);const d=async r=>{r.preventDefault();const o=(e=>e.trim().slice(0,2e3))(i);if(o&&!t&&!n&&!s)try{await e(o),a("")}catch(l){}},f=i.trim().length>0&&!t&&!n&&!s,p=t||n||s;return O.jsxs("form",{onSubmit:d,className:"gpc-input-container",children:[O.jsx("input",{ref:c,type:"text",value:i,onChange:e=>a(e.target.value),onKeyDown:e=>{"Enter"!==e.key||e.shiftKey||s||(e.preventDefault(),d(e))},placeholder:o("chat.placeholder"),disabled:p,maxLength:tl,className:"gpc-input","aria-label":o("chat.placeholder"),"aria-describedby":"chat-input-help"}),O.jsx(ll,{onTranscript:async e=>{if(!r)throw new Error("GPC Service not available");const t=await r.transcribeAudio(e);t.success&&t.text&&(a(t.text),c.current?.focus())},isLoading:t,disabled:n,onRecordingStateChange:e=>{u(e)}}),O.jsx("button",{type:"submit",disabled:!f,className:"gpc-send-button","aria-label":o("chat.send"),title:o("chat.send"),children:t?O.jsx("span",{className:"gpc-spinner"}):O.jsx(ie,{className:"gpc-icon"})}),O.jsxs("span",{id:"chat-input-help",className:"gpc-sr-only",children:[o("chat.placeholder"),". Máximo ",tl," caracteres."]})]})};var cl=l.forwardRef(({as:e="div",...t},n)=>O.jsx(e,{...t,ref:n})),dl="cf-turnstile-script",fl="onloadTurnstileCallback",pl=e=>!!document.getElementById(e),hl={normal:{width:300,height:65},compact:{width:150,height:140},invisible:{width:0,height:0,overflow:"hidden"},flexible:{minWidth:300,width:"100%",height:65},interactionOnly:{width:"fit-content",height:"auto",display:"flex"}};function gl(e){if("invisible"!==e&&"interactionOnly"!==e)return e}var ml,yl="unloaded",vl=new Promise((e,t)=>{ml={resolve:e,reject:t},"ready"===yl&&e(void 0)}),bl=l.forwardRef((e,t)=>{let{scriptOptions:n,options:r={},siteKey:o,onWidgetLoad:i,onSuccess:a,onExpire:s,onError:u,onBeforeInteractive:c,onAfterInteractive:d,onUnsupported:f,onTimeout:p,onLoadScript:h,id:g,style:m,as:y="div",injectScript:v=!0,rerenderOnCallbackChange:b=!1,...k}=e,x=r.size,w=l.useCallback(()=>typeof x>"u"?{}:"execute"===r.execution?hl.invisible:"interaction-only"===r.appearance?hl.interactionOnly:hl[x],[r.execution,x,r.appearance]),[S,E]=l.useState(w()),C=l.useRef(null),[T,N]=l.useState(!1),P=l.useRef(),L=l.useRef(!1),R=g||"cf-turnstile",_=l.useRef({onSuccess:a,onError:u,onExpire:s,onBeforeInteractive:c,onAfterInteractive:d,onUnsupported:f,onTimeout:p});l.useEffect(()=>{b||(_.current={onSuccess:a,onError:u,onExpire:s,onBeforeInteractive:c,onAfterInteractive:d,onUnsupported:f,onTimeout:p})});let I=n?.id||dl,A=function(e=dl){let[t,n]=l.useState(!1);return l.useEffect(()=>{let t=()=>{pl(e)&&n(!0)},r=new MutationObserver(t);return r.observe(document,{childList:!0,subtree:!0}),t(),()=>{r.disconnect()}},[e]),t}(I),D=n?.onLoadCallbackName||fl,z=r.appearance||"always",j=l.useMemo(()=>({sitekey:o,action:r.action,cData:r.cData,theme:r.theme||"auto",language:r.language||"auto",tabindex:r.tabIndex,"response-field":r.responseField,"response-field-name":r.responseFieldName,size:gl(x),retry:r.retry||"auto","retry-interval":r.retryInterval||8e3,"refresh-expired":r.refreshExpired||"auto","refresh-timeout":r.refreshTimeout||"auto",execution:r.execution||"render",appearance:r.appearance||"always","feedback-enabled":r.feedbackEnabled||!0,callback:e=>{L.current=!0,b?a?.(e):_.current.onSuccess?.(e)},"error-callback":b?u:(...e)=>_.current.onError?.(...e),"expired-callback":b?s:(...e)=>_.current.onExpire?.(...e),"before-interactive-callback":b?c:(...e)=>_.current.onBeforeInteractive?.(...e),"after-interactive-callback":b?d:(...e)=>_.current.onAfterInteractive?.(...e),"unsupported-callback":b?f:(...e)=>_.current.onUnsupported?.(...e),"timeout-callback":b?p:(...e)=>_.current.onTimeout?.(...e)}),[r.action,r.appearance,r.cData,r.execution,r.language,r.refreshExpired,r.responseField,r.responseFieldName,r.retry,r.retryInterval,r.tabIndex,r.theme,r.feedbackEnabled,r.refreshTimeout,o,x,b,b?a:null,b?u:null,b?s:null,b?c:null,b?d:null,b?f:null,b?p:null]),F=l.useCallback(()=>typeof window<"u"&&!!window.turnstile,[]);return l.useEffect(function(){v&&!T&&(({render:e="explicit",onLoadCallbackName:t=fl,scriptOptions:{nonce:n="",defer:r=!0,async:o=!0,id:i="",appendTo:a,onError:s,crossOrigin:l=""}={}})=>{let u=i||dl;if(pl(u))return;let c=document.createElement("script");c.id=u,c.src=`https://challenges.cloudflare.com/turnstile/v0/api.js?onload=${t}&render=${e}`,document.querySelector(`script[src="${c.src}"]`)||(c.defer=!!r,c.async=!!o,n&&(c.nonce=n),l&&(c.crossOrigin=l),s&&(c.onerror=s,delete window[t]),("body"===a?document.body:document.getElementsByTagName("head")[0]).appendChild(c))})({onLoadCallbackName:D,scriptOptions:{...n,id:I}})},[v,T,n,I]),l.useEffect(function(){"ready"!==yl&&((e=fl)=>("unloaded"===yl&&(yl="loading",window[e]=()=>{ml.resolve(),yl="ready",delete window[e]}),vl))(D).then(()=>N(!0)).catch(console.error)},[]),l.useEffect(function(){if(!C.current||!T)return;let e=!1;return(async()=>{if(e||!C.current)return;let t=window.turnstile.render(C.current,j);P.current=t,P.current&&i?.(P.current)})(),()=>{e=!0,P.current&&(window.turnstile.remove(P.current),L.current=!1)}},[R,T,j]),l.useImperativeHandle(t,()=>{let{turnstile:e}=window;return{getResponse(){if(e?.getResponse&&P.current&&F())return e.getResponse(P.current)},getResponsePromise:async(e=3e4,t=100)=>new Promise((n,r)=>{let o,i=async()=>{if(L.current&&window.turnstile&&P.current)try{let e=window.turnstile.getResponse(P.current);return o&&clearTimeout(o),e?n(e):r(new Error("No response received"))}catch(a){return o&&clearTimeout(o),r(new Error("Failed to get response"))}o||(o=setTimeout(()=>{o&&clearTimeout(o),r(new Error("Timeout"))},e)),await new Promise(e=>setTimeout(e,t)),await i()};i()}),reset(){if(e?.reset&&P.current&&F()){"execute"===r.execution&&E(hl.invisible);try{L.current=!1,e.reset(P.current)}catch(Fe){}}},remove(){e?.remove&&P.current&&F()&&(E(hl.invisible),L.current=!1,e.remove(P.current),P.current=null)},render(){if(!e?.render||!C.current||!F()||P.current)return;let t=e.render(C.current,j);return P.current=t,P.current&&i?.(P.current),"execute"!==r.execution&&E(x?hl[x]:{}),t},execute(){"execute"===r.execution&&e?.execute&&C.current&&P.current&&F()&&(e.execute(C.current,j),E(x?hl[x]:{}))},isExpired:()=>!!(e?.isExpired&&P.current&&F())&&e.isExpired(P.current)}},[P,r.execution,x,j,C,F,T,i]),l.useEffect(()=>{A&&!T&&window.turnstile&&N(!0)},[T,A]),l.useEffect(()=>{E(w())},[r.execution,x,z]),l.useEffect(()=>{!A||"function"!=typeof h||h()},[A]),O.jsx(cl,{ref:C,as:y,id:R,style:{...S,...m},...k})});bl.displayName="Turnstile";const kl=({siteKey:e,onSuccess:t,onError:n})=>{const{t:r}=V(),[o,i]=l.useState(!1),[a,s]=l.useState(null);return O.jsxs("div",{className:"gpc-validator-container",children:[O.jsxs("div",{className:"gpc-validator-header",children:[O.jsx("h3",{className:"gpc-validator-title",children:r("chat.validation")}),O.jsx("p",{className:"gpc-validator-subtitle",children:r("turnstile.verifying")})]}),!a&&O.jsx("div",{className:"gpc-animate-fade-in",children:O.jsx(bl,{siteKey:e,onSuccess:async e=>{i(!0),s(null);try{await t(e)}catch(o){s(r("turnstile.error")),n?.(o)}finally{i(!1)}},onError:e=>{s(r("turnstile.error")),n?.(new Error(r("turnstile.error")))},options:{theme:"light",size:"normal"}})}),o&&O.jsxs("div",{className:"gpc-validator-loading",children:[O.jsx(ol,{size:"md"}),O.jsx("p",{className:"gpc-validator-text",children:r("chat.validation")})]}),a&&O.jsxs("div",{className:"gpc-validator-error",children:[O.jsx(X,{className:"gpc-error-icon"}),O.jsxs("div",{className:"gpc-error-content",children:[O.jsx("p",{className:"gpc-error-title",children:r("errors.validation")}),O.jsx("p",{className:"gpc-error-message",children:a}),O.jsx("button",{onClick:()=>window.location.reload(),className:"gpc-error-button",children:r("chat.retry")})]})]})]})},xl=(e="auto")=>{const[t,n]=l.useState(e),[r,o]=l.useState("light");l.useEffect(()=>{if(o("auto"===t?window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light":t),"auto"===t){const e=window.matchMedia("(prefers-color-scheme: dark)"),t=e=>{o(e.matches?"dark":"light")};return e.addEventListener("change",t),()=>{e.removeEventListener("change",t)}}},[t]);return{theme:r,themeMode:t,setThemeMode:n,toggleTheme:()=>{n(e=>"auto"===e?"light"===r?"dark":"light":"light"===e?"dark":"light")}}},wl=({gpcService:e,licenseToken:t,widgetConfig:n,turnstileSiteKey:r,onClose:o,themeMode:i,showBranding:a=!0,showMetadata:s=!1,onError:u})=>{const{t:c}=V(),[d,f]=l.useState(null),[p,h]=l.useState(!1),{theme:g,toggleTheme:m}=xl(i),y=l.useCallback(()=>{h(!1),f(null),e&&e.renewSessionToken()},[e]),{messages:v,isLoading:b,sendMessage:k}=((e,t,n)=>{const{t:r}=V(),[o,i]=l.useState([]),[a,s]=l.useState(!1),[u,c]=l.useState(null),d=l.useCallback(async o=>{if(!o.trim()||a)return;if(!t)return void lt.error("Validación anti-bot pendiente");const l={id:rl(),role:"user",content:o.trim(),timestamp:(new Date).toISOString()};i(e=>[...e,l]),s(!0),c(null);const u=rl(),d={id:u,role:"assistant",content:"",timestamp:(new Date).toISOString(),isStreaming:!0};i(e=>[...e,d]);try{const n=await e.sendMessage(o,t,e=>{i(t=>t.map(t=>t.id===u?{...t,content:t.content+e}:t))});i(e=>e.map(e=>e.id===u?{id:n.data.message_id,role:"assistant",content:n.data.response,timestamp:n.data.created_at,isStreaming:!1,metadata:{costUsd:n.data.cost_usd,creditBalanceUsd:n.data.credit_balance_usd,inputTokens:n.data.input_tokens,outputTokens:n.data.output_tokens,responseTimeMs:n.data.response_time_ms,modelUsed:n.data.model_used}}:e))}catch(f){let e,t;i(e=>e.filter(e=>e.id!==u));try{e=JSON.parse(f.message)}catch{e={statusCode:500,message:f.message}}const o=e.statusCode||500,a=e.errorCode||"";switch(401===o&&"SESSION_EXPIRED"===a&&(t=r("errors.sessionExpired","Session expired, please verify again"),n&&n()),o){case 401:t||(t=r("errors.unauthorized"));break;case 402:t=r("errors.insufficientCredits");break;case 403:t=a.includes("DOMAIN")||a.includes("UNAUTHORIZED")?r("errors.domainUnauthorized"):r("errors.validation");break;case 429:t=r("errors.rateLimit");break;case 503:case 502:case 504:t=r("errors.aiServiceUnavailable");break;case 500:t=r("errors.serverError");break;default:t=r("errors.generic")}c(t),lt.error(t,{duration:4e3,position:"top-center"});const s={id:rl(),role:"assistant",content:t,timestamp:(new Date).toISOString()};i(e=>[...e,s])}finally{s(!1)}},[e,t,a,r,n]),f=l.useCallback(()=>{i([]),c(null)},[]),p=l.useCallback(()=>{c(null)},[]);return{messages:o,isLoading:a,error:u,sendMessage:d,clearMessages:f,clearError:p}})(e,d,y);l.useEffect(()=>{e&&e.hasValidCachedSession()&&(h(!0),f("CACHED_SESSION"))},[e]);return l.useEffect(()=>()=>{e&&e.releaseSession().catch(e=>{})},[e]),O.jsxs("div",{className:"gpc-chat-window gpc-animate-fade-in "+("dark"===g?"gpc-dark":""),children:[O.jsx(ft,{onClose:o,theme:g,onToggleTheme:m,showBranding:a,widgetConfig:n}),p?O.jsxs(O.Fragment,{children:[O.jsx(sl,{messages:v,isLoading:b,showMetadata:s,widgetConfig:n}),O.jsx(ul,{onSendMessage:k,isLoading:b,disabled:!1,gpcService:e})]}):O.jsx(kl,{siteKey:r,onSuccess:t=>{f(t),h(!0),e&&e.validateSession()},onError:u}),a&&O.jsx("div",{className:"gpc-footer",children:O.jsx("span",{className:"gpc-footer-text",children:c("widget.poweredBy")})}),O.jsx(st,{position:"top-center"})]})};function Sl(e,t){return function(){return e.apply(t,arguments)}}const{toString:El}=Object.prototype,{getPrototypeOf:Cl}=Object,{iterator:Tl,toStringTag:Ol}=Symbol,Nl=(e=>t=>{const n=El.call(t);return e[n]||(e[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),Pl=e=>(e=e.toLowerCase(),t=>Nl(t)===e),Ll=e=>t=>typeof t===e,{isArray:Rl}=Array,_l=Ll("undefined");function Il(e){return null!==e&&!_l(e)&&null!==e.constructor&&!_l(e.constructor)&&zl(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const Al=Pl("ArrayBuffer");const Dl=Ll("string"),zl=Ll("function"),jl=Ll("number"),Fl=e=>null!==e&&"object"==typeof e,Ml=e=>{if("object"!==Nl(e))return!1;const t=Cl(e);return!(null!==t&&t!==Object.prototype&&null!==Object.getPrototypeOf(t)||Ol in e||Tl in e)},Ul=Pl("Date"),Bl=Pl("File"),$l=Pl("Blob"),Vl=Pl("FileList"),Hl=Pl("URLSearchParams"),[ql,Wl,Kl,Ql]=["ReadableStream","Request","Response","Headers"].map(Pl);function Jl(e,t,{allOwnKeys:n=!1}={}){if(null==e)return;let r,o;if("object"!=typeof e&&(e=[e]),Rl(e))for(r=0,o=e.length;r<o;r++)t.call(null,e[r],r,e);else{if(Il(e))return;const o=n?Object.getOwnPropertyNames(e):Object.keys(e),i=o.length;let a;for(r=0;r<i;r++)a=o[r],t.call(null,e[a],a,e)}}function Yl(e,t){if(Il(e))return null;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 Gl="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:global,Xl=e=>!_l(e)&&e!==Gl;const Zl=(e=>t=>e&&t instanceof e)("undefined"!=typeof Uint8Array&&Cl(Uint8Array)),eu=Pl("HTMLFormElement"),tu=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),nu=Pl("RegExp"),ru=(e,t)=>{const n=Object.getOwnPropertyDescriptors(e),r={};Jl(n,(n,o)=>{let i;!1!==(i=t(n,o,e))&&(r[o]=i||n)}),Object.defineProperties(e,r)};const ou=Pl("AsyncFunction"),iu=(au="function"==typeof setImmediate,su=zl(Gl.postMessage),au?setImmediate:su?(lu=`axios@${Math.random()}`,uu=[],Gl.addEventListener("message",({source:e,data:t})=>{e===Gl&&t===lu&&uu.length&&uu.shift()()},!1),e=>{uu.push(e),Gl.postMessage(lu,"*")}):e=>setTimeout(e));var au,su,lu,uu;const cu="undefined"!=typeof queueMicrotask?queueMicrotask.bind(Gl):"undefined"!=typeof process&&process.nextTick||iu,du={isArray:Rl,isArrayBuffer:Al,isBuffer:Il,isFormData:e=>{let t;return e&&("function"==typeof FormData&&e instanceof FormData||zl(e.append)&&("formdata"===(t=Nl(e))||"object"===t&&zl(e.toString)&&"[object FormData]"===e.toString()))},isArrayBufferView:function(e){let t;return t="undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(e):e&&e.buffer&&Al(e.buffer),t},isString:Dl,isNumber:jl,isBoolean:e=>!0===e||!1===e,isObject:Fl,isPlainObject:Ml,isEmptyObject:e=>{if(!Fl(e)||Il(e))return!1;try{return 0===Object.keys(e).length&&Object.getPrototypeOf(e)===Object.prototype}catch(De){return!1}},isReadableStream:ql,isRequest:Wl,isResponse:Kl,isHeaders:Ql,isUndefined:_l,isDate:Ul,isFile:Bl,isBlob:$l,isRegExp:nu,isFunction:zl,isStream:e=>Fl(e)&&zl(e.pipe),isURLSearchParams:Hl,isTypedArray:Zl,isFileList:Vl,forEach:Jl,merge:function e(){const{caseless:t,skipUndefined:n}=Xl(this)&&this||{},r={},o=(o,i)=>{const a=t&&Yl(r,i)||i;Ml(r[a])&&Ml(o)?r[a]=e(r[a],o):Ml(o)?r[a]=e({},o):Rl(o)?r[a]=o.slice():n&&_l(o)||(r[a]=o)};for(let i=0,a=arguments.length;i<a;i++)arguments[i]&&Jl(arguments[i],o);return r},extend:(e,t,n,{allOwnKeys:r}={})=>(Jl(t,(t,r)=>{n&&zl(t)?e[r]=Sl(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,i,a;const s={};if(t=t||{},null==e)return t;do{for(o=Object.getOwnPropertyNames(e),i=o.length;i-- >0;)a=o[i],r&&!r(a,e,t)||s[a]||(t[a]=e[a],s[a]=!0);e=!1!==n&&Cl(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},kindOf:Nl,kindOfTest:Pl,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(Rl(e))return e;let t=e.length;if(!jl(t))return null;const n=new Array(t);for(;t-- >0;)n[t]=e[t];return n},forEachEntry:(e,t)=>{const n=(e&&e[Tl]).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:eu,hasOwnProperty:tu,hasOwnProp:tu,reduceDescriptors:ru,freezeMethods:e=>{ru(e,(t,n)=>{if(zl(e)&&-1!==["arguments","caller","callee"].indexOf(n))return!1;const r=e[n];zl(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 Rl(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:Yl,global:Gl,isContextDefined:Xl,isSpecCompliantForm:function(e){return!!(e&&zl(e.append)&&"FormData"===e[Ol]&&e[Tl])},toJSONObject:e=>{const t=new Array(10),n=(e,r)=>{if(Fl(e)){if(t.indexOf(e)>=0)return;if(Il(e))return e;if(!("toJSON"in e)){t[r]=e;const o=Rl(e)?[]:{};return Jl(e,(e,t)=>{const i=n(e,r+1);!_l(i)&&(o[t]=i)}),t[r]=void 0,o}}return e};return n(e,0)},isAsyncFn:ou,isThenable:e=>e&&(Fl(e)||zl(e))&&zl(e.then)&&zl(e.catch),setImmediate:iu,asap:cu,isIterable:e=>null!=e&&zl(e[Tl])};function fu(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)}du.inherits(fu,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:du.toJSONObject(this.config),code:this.code,status:this.status}}});const pu=fu.prototype,hu={};["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=>{hu[e]={value:e}}),Object.defineProperties(fu,hu),Object.defineProperty(pu,"isAxiosError",{value:!0}),fu.from=(e,t,n,r,o,i)=>{const a=Object.create(pu);du.toFlatObject(e,a,function(e){return e!==Error.prototype},e=>"isAxiosError"!==e);const s=e&&e.message?e.message:"Error",l=null==t&&e?e.code:t;return fu.call(a,s,l,n,r,o),e&&null==a.cause&&Object.defineProperty(a,"cause",{value:e,configurable:!0}),a.name=e&&e.name||"Error",i&&Object.assign(a,i),a};function gu(e){return du.isPlainObject(e)||du.isArray(e)}function mu(e){return du.endsWith(e,"[]")?e.slice(0,-2):e}function yu(e,t,n){return e?e.concat(t).map(function(e,t){return e=mu(e),!n&&t?"["+e+"]":e}).join(n?".":""):t}const vu=du.toFlatObject(du,{},null,function(e){return/^is[A-Z]/.test(e)});function bu(e,t,n){if(!du.isObject(e))throw new TypeError("target must be an object");t=t||new FormData;const r=(n=du.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(e,t){return!du.isUndefined(t[e])})).metaTokens,o=n.visitor||u,i=n.dots,a=n.indexes,s=(n.Blob||"undefined"!=typeof Blob&&Blob)&&du.isSpecCompliantForm(t);if(!du.isFunction(o))throw new TypeError("visitor must be a function");function l(e){if(null===e)return"";if(du.isDate(e))return e.toISOString();if(du.isBoolean(e))return e.toString();if(!s&&du.isBlob(e))throw new fu("Blob is not supported. Use a Buffer instead.");return du.isArrayBuffer(e)||du.isTypedArray(e)?s&&"function"==typeof Blob?new Blob([e]):Buffer.from(e):e}function u(e,n,o){let s=e;if(e&&!o&&"object"==typeof e)if(du.endsWith(n,"{}"))n=r?n:n.slice(0,-2),e=JSON.stringify(e);else if(du.isArray(e)&&function(e){return du.isArray(e)&&!e.some(gu)}(e)||(du.isFileList(e)||du.endsWith(n,"[]"))&&(s=du.toArray(e)))return n=mu(n),s.forEach(function(e,r){!du.isUndefined(e)&&null!==e&&t.append(!0===a?yu([n],r,i):null===a?n:n+"[]",l(e))}),!1;return!!gu(e)||(t.append(yu(o,n,i),l(e)),!1)}const c=[],d=Object.assign(vu,{defaultVisitor:u,convertValue:l,isVisitable:gu});if(!du.isObject(e))throw new TypeError("data must be an object");return function e(n,r){if(!du.isUndefined(n)){if(-1!==c.indexOf(n))throw Error("Circular reference detected in "+r.join("."));c.push(n),du.forEach(n,function(n,i){!0===(!(du.isUndefined(n)||null===n)&&o.call(t,n,du.isString(i)?i.trim():i,r,d))&&e(n,r?r.concat(i):[i])}),c.pop()}}(e),t}function ku(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(e){return t[e]})}function xu(e,t){this._pairs=[],e&&bu(e,this,t)}const wu=xu.prototype;function Su(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function Eu(e,t,n){if(!t)return e;const r=n&&n.encode||Su;du.isFunction(n)&&(n={serialize:n});const o=n&&n.serialize;let i;if(i=o?o(t,n):du.isURLSearchParams(t)?t.toString():new xu(t,n).toString(r),i){const t=e.indexOf("#");-1!==t&&(e=e.slice(0,t)),e+=(-1===e.indexOf("?")?"?":"&")+i}return e}wu.append=function(e,t){this._pairs.push([e,t])},wu.toString=function(e){const t=e?function(t){return e.call(this,t,ku)}:ku;return this._pairs.map(function(e){return t(e[0])+"="+t(e[1])},"").join("&")};class Cu{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){du.forEach(this.handlers,function(t){null!==t&&e(t)})}}const Tu={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},Ou={isBrowser:!0,classes:{URLSearchParams:"undefined"!=typeof URLSearchParams?URLSearchParams:xu,FormData:"undefined"!=typeof FormData?FormData:null,Blob:"undefined"!=typeof Blob?Blob:null},protocols:["http","https","file","blob","url","data"]},Nu="undefined"!=typeof window&&"undefined"!=typeof document,Pu="object"==typeof navigator&&navigator||void 0,Lu=Nu&&(!Pu||["ReactNative","NativeScript","NS"].indexOf(Pu.product)<0),Ru="undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope&&"function"==typeof self.importScripts,_u=Nu&&window.location.href||"http://localhost",Iu={...Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:Nu,hasStandardBrowserEnv:Lu,hasStandardBrowserWebWorkerEnv:Ru,navigator:Pu,origin:_u},Symbol.toStringTag,{value:"Module"})),...Ou};function Au(e){function t(e,n,r,o){let i=e[o++];if("__proto__"===i)return!0;const a=Number.isFinite(+i),s=o>=e.length;if(i=!i&&du.isArray(r)?r.length:i,s)return du.hasOwnProp(r,i)?r[i]=[r[i],n]:r[i]=n,!a;r[i]&&du.isObject(r[i])||(r[i]=[]);return t(e,n,r[i],o)&&du.isArray(r[i])&&(r[i]=function(e){const t={},n=Object.keys(e);let r;const o=n.length;let i;for(r=0;r<o;r++)i=n[r],t[i]=e[i];return t}(r[i])),!a}if(du.isFormData(e)&&du.isFunction(e.entries)){const n={};return du.forEachEntry(e,(e,r)=>{t(function(e){return du.matchAll(/\w+|\[(\w*)]/g,e).map(e=>"[]"===e[0]?"":e[1]||e[0])}(e),r,n,0)}),n}return null}const Du={transitional:Tu,adapter:["xhr","http","fetch"],transformRequest:[function(e,t){const n=t.getContentType()||"",r=n.indexOf("application/json")>-1,o=du.isObject(e);o&&du.isHTMLForm(e)&&(e=new FormData(e));if(du.isFormData(e))return r?JSON.stringify(Au(e)):e;if(du.isArrayBuffer(e)||du.isBuffer(e)||du.isStream(e)||du.isFile(e)||du.isBlob(e)||du.isReadableStream(e))return e;if(du.isArrayBufferView(e))return e.buffer;if(du.isURLSearchParams(e))return t.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();let i;if(o){if(n.indexOf("application/x-www-form-urlencoded")>-1)return function(e,t){return bu(e,new Iu.classes.URLSearchParams,{visitor:function(e,t,n,r){return Iu.isNode&&du.isBuffer(e)?(this.append(t,e.toString("base64")),!1):r.defaultVisitor.apply(this,arguments)},...t})}(e,this.formSerializer).toString();if((i=du.isFileList(e))||n.indexOf("multipart/form-data")>-1){const t=this.env&&this.env.FormData;return bu(i?{"files[]":e}:e,t&&new t,this.formSerializer)}}return o||r?(t.setContentType("application/json",!1),function(e,t,n){if(du.isString(e))try{return(t||JSON.parse)(e),du.trim(e)}catch(De){if("SyntaxError"!==De.name)throw De}return(n||JSON.stringify)(e)}(e)):e}],transformResponse:[function(e){const t=this.transitional||Du.transitional,n=t&&t.forcedJSONParsing,r="json"===this.responseType;if(du.isResponse(e)||du.isReadableStream(e))return e;if(e&&du.isString(e)&&(n&&!this.responseType||r)){const n=!(t&&t.silentJSONParsing)&&r;try{return JSON.parse(e,this.parseReviver)}catch(De){if(n){if("SyntaxError"===De.name)throw fu.from(De,fu.ERR_BAD_RESPONSE,this,null,this.response);throw De}}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:Iu.classes.FormData,Blob:Iu.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};du.forEach(["delete","get","head","post","put","patch"],e=>{Du.headers[e]={}});const zu=du.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"]),ju=Symbol("internals");function Fu(e){return e&&String(e).trim().toLowerCase()}function Mu(e){return!1===e||null==e?e:du.isArray(e)?e.map(Mu):String(e)}function Uu(e,t,n,r,o){return du.isFunction(r)?r.call(this,t,n):(o&&(t=n),du.isString(t)?du.isString(r)?-1!==t.indexOf(r):du.isRegExp(r)?r.test(t):void 0:void 0)}let Bu=class{constructor(e){e&&this.set(e)}set(e,t,n){const r=this;function o(e,t,n){const o=Fu(t);if(!o)throw new Error("header name must be a non-empty string");const i=du.findKey(r,o);(!i||void 0===r[i]||!0===n||void 0===n&&!1!==r[i])&&(r[i||t]=Mu(e))}const i=(e,t)=>du.forEach(e,(e,n)=>o(e,n,t));if(du.isPlainObject(e)||e instanceof this.constructor)i(e,t);else if(du.isString(e)&&(e=e.trim())&&!/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim()))i((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]&&zu[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(du.isObject(e)&&du.isIterable(e)){let n,r,o={};for(const t of e){if(!du.isArray(t))throw TypeError("Object iterator must return a key-value pair");o[r=t[0]]=(n=o[r])?du.isArray(n)?[...n,t[1]]:[n,t[1]]:t[1]}i(o,t)}else null!=e&&o(t,e,n);return this}get(e,t){if(e=Fu(e)){const n=du.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(du.isFunction(t))return t.call(this,e,n);if(du.isRegExp(t))return t.exec(e);throw new TypeError("parser must be boolean|regexp|function")}}}has(e,t){if(e=Fu(e)){const n=du.findKey(this,e);return!(!n||void 0===this[n]||t&&!Uu(0,this[n],n,t))}return!1}delete(e,t){const n=this;let r=!1;function o(e){if(e=Fu(e)){const o=du.findKey(n,e);!o||t&&!Uu(0,n[o],o,t)||(delete n[o],r=!0)}}return du.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&&!Uu(0,this[o],o,e,!0)||(delete this[o],r=!0)}return r}normalize(e){const t=this,n={};return du.forEach(this,(r,o)=>{const i=du.findKey(n,o);if(i)return t[i]=Mu(r),void delete t[o];const a=e?function(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(e,t,n)=>t.toUpperCase()+n)}(o):String(o).trim();a!==o&&delete t[o],t[a]=Mu(r),n[a]=!0}),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){const t=Object.create(null);return du.forEach(this,(n,r)=>{null!=n&&!1!==n&&(t[r]=e&&du.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")}getSetCookie(){return this.get("set-cookie")||[]}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[ju]=this[ju]={accessors:{}}).accessors,n=this.prototype;function r(e){const r=Fu(e);t[r]||(!function(e,t){const n=du.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 du.isArray(e)?e.forEach(r):r(e),this}};function $u(e,t){const n=this||Du,r=t||n,o=Bu.from(r.headers);let i=r.data;return du.forEach(e,function(e){i=e.call(n,i,o.normalize(),t?t.status:void 0)}),o.normalize(),i}function Vu(e){return!(!e||!e.__CANCEL__)}function Hu(e,t,n){fu.call(this,null==e?"canceled":e,fu.ERR_CANCELED,t,n),this.name="CanceledError"}function qu(e,t,n){const r=n.config.validateStatus;n.status&&r&&!r(n.status)?t(new fu("Request failed with status code "+n.status,[fu.ERR_BAD_REQUEST,fu.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n)):e(n)}Bu.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),du.reduceDescriptors(Bu.prototype,({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(e){this[n]=e}}}),du.freezeMethods(Bu),du.inherits(Hu,fu,{__CANCEL__:!0});const Wu=(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,i=0,a=0;return t=void 0!==t?t:1e3,function(s){const l=Date.now(),u=r[a];o||(o=l),n[i]=s,r[i]=l;let c=a,d=0;for(;c!==i;)d+=n[c++],c%=e;if(i=(i+1)%e,i===a&&(a=(a+1)%e),l-o<t)return;const f=u&&l-u;return f?Math.round(1e3*d/f):void 0}}(50,250);return function(e,t){let n,r,o=0,i=1e3/t;const a=(t,i=Date.now())=>{o=i,n=null,r&&(clearTimeout(r),r=null),e(...t)};return[(...e)=>{const t=Date.now(),s=t-o;s>=i?a(e,t):(n=e,r||(r=setTimeout(()=>{r=null,a(n)},i-s)))},()=>n&&a(n)]}(n=>{const i=n.loaded,a=n.lengthComputable?n.total:void 0,s=i-r,l=o(s);r=i;e({loaded:i,total:a,progress:a?i/a:void 0,bytes:s,rate:l||void 0,estimated:l&&a&&i<=a?(a-i)/l:void 0,event:n,lengthComputable:null!=a,[t?"download":"upload"]:!0})},n)},Ku=(e,t)=>{const n=null!=e;return[r=>t[0]({lengthComputable:n,total:e,loaded:r}),t[1]]},Qu=e=>(...t)=>du.asap(()=>e(...t)),Ju=Iu.hasStandardBrowserEnv?((e,t)=>n=>(n=new URL(n,Iu.origin),e.protocol===n.protocol&&e.host===n.host&&(t||e.port===n.port)))(new URL(Iu.origin),Iu.navigator&&/(msie|trident)/i.test(Iu.navigator.userAgent)):()=>!0,Yu=Iu.hasStandardBrowserEnv?{write(e,t,n,r,o,i){const a=[e+"="+encodeURIComponent(t)];du.isNumber(n)&&a.push("expires="+new Date(n).toGMTString()),du.isString(r)&&a.push("path="+r),du.isString(o)&&a.push("domain="+o),!0===i&&a.push("secure"),document.cookie=a.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 Gu(e,t,n){let r=!/^([a-z][a-z\d+\-.]*:)?\/\//i.test(t);return e&&(r||0==n)?function(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}(e,t):t}const Xu=e=>e instanceof Bu?{...e}:e;function Zu(e,t){t=t||{};const n={};function r(e,t,n,r){return du.isPlainObject(e)&&du.isPlainObject(t)?du.merge.call({caseless:r},e,t):du.isPlainObject(t)?du.merge({},t):du.isArray(t)?t.slice():t}function o(e,t,n,o){return du.isUndefined(t)?du.isUndefined(e)?void 0:r(void 0,e,0,o):r(e,t,0,o)}function i(e,t){if(!du.isUndefined(t))return r(void 0,t)}function a(e,t){return du.isUndefined(t)?du.isUndefined(e)?void 0:r(void 0,e):r(void 0,t)}function s(n,o,i){return i in t?r(n,o):i in e?r(void 0,n):void 0}const l={url:i,method:i,data:i,baseURL:a,transformRequest:a,transformResponse:a,paramsSerializer:a,timeout:a,timeoutMessage:a,withCredentials:a,withXSRFToken:a,adapter:a,responseType:a,xsrfCookieName:a,xsrfHeaderName:a,onUploadProgress:a,onDownloadProgress:a,decompress:a,maxContentLength:a,maxBodyLength:a,beforeRedirect:a,transport:a,httpAgent:a,httpsAgent:a,cancelToken:a,socketPath:a,responseEncoding:a,validateStatus:s,headers:(e,t,n)=>o(Xu(e),Xu(t),0,!0)};return du.forEach(Object.keys({...e,...t}),function(r){const i=l[r]||o,a=i(e[r],t[r],r);du.isUndefined(a)&&i!==s||(n[r]=a)}),n}const ec=e=>{const t=Zu({},e);let{data:n,withXSRFToken:r,xsrfHeaderName:o,xsrfCookieName:i,headers:a,auth:s}=t;if(t.headers=a=Bu.from(a),t.url=Eu(Gu(t.baseURL,t.url,t.allowAbsoluteUrls),e.params,e.paramsSerializer),s&&a.set("Authorization","Basic "+btoa((s.username||"")+":"+(s.password?unescape(encodeURIComponent(s.password)):""))),du.isFormData(n))if(Iu.hasStandardBrowserEnv||Iu.hasStandardBrowserWebWorkerEnv)a.setContentType(void 0);else if(du.isFunction(n.getHeaders)){const e=n.getHeaders(),t=["content-type","content-length"];Object.entries(e).forEach(([e,n])=>{t.includes(e.toLowerCase())&&a.set(e,n)})}if(Iu.hasStandardBrowserEnv&&(r&&du.isFunction(r)&&(r=r(t)),r||!1!==r&&Ju(t.url))){const e=o&&i&&Yu.read(i);e&&a.set(o,e)}return t},tc="undefined"!=typeof XMLHttpRequest&&function(e){return new Promise(function(t,n){const r=ec(e);let o=r.data;const i=Bu.from(r.headers).normalize();let a,s,l,u,c,{responseType:d,onUploadProgress:f,onDownloadProgress:p}=r;function h(){u&&u(),c&&c(),r.cancelToken&&r.cancelToken.unsubscribe(a),r.signal&&r.signal.removeEventListener("abort",a)}let g=new XMLHttpRequest;function m(){if(!g)return;const r=Bu.from("getAllResponseHeaders"in g&&g.getAllResponseHeaders());qu(function(e){t(e),h()},function(e){n(e),h()},{data:d&&"text"!==d&&"json"!==d?g.response:g.responseText,status:g.status,statusText:g.statusText,headers:r,config:e,request:g}),g=null}g.open(r.method.toUpperCase(),r.url,!0),g.timeout=r.timeout,"onloadend"in g?g.onloadend=m:g.onreadystatechange=function(){g&&4===g.readyState&&(0!==g.status||g.responseURL&&0===g.responseURL.indexOf("file:"))&&setTimeout(m)},g.onabort=function(){g&&(n(new fu("Request aborted",fu.ECONNABORTED,e,g)),g=null)},g.onerror=function(t){const r=new fu(t&&t.message?t.message:"Network Error",fu.ERR_NETWORK,e,g);r.event=t||null,n(r),g=null},g.ontimeout=function(){let t=r.timeout?"timeout of "+r.timeout+"ms exceeded":"timeout exceeded";const o=r.transitional||Tu;r.timeoutErrorMessage&&(t=r.timeoutErrorMessage),n(new fu(t,o.clarifyTimeoutError?fu.ETIMEDOUT:fu.ECONNABORTED,e,g)),g=null},void 0===o&&i.setContentType(null),"setRequestHeader"in g&&du.forEach(i.toJSON(),function(e,t){g.setRequestHeader(t,e)}),du.isUndefined(r.withCredentials)||(g.withCredentials=!!r.withCredentials),d&&"json"!==d&&(g.responseType=r.responseType),p&&([l,c]=Wu(p,!0),g.addEventListener("progress",l)),f&&g.upload&&([s,u]=Wu(f),g.upload.addEventListener("progress",s),g.upload.addEventListener("loadend",u)),(r.cancelToken||r.signal)&&(a=t=>{g&&(n(!t||t.type?new Hu(null,e,g):t),g.abort(),g=null)},r.cancelToken&&r.cancelToken.subscribe(a),r.signal&&(r.signal.aborted?a():r.signal.addEventListener("abort",a)));const y=function(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}(r.url);y&&-1===Iu.protocols.indexOf(y)?n(new fu("Unsupported protocol "+y+":",fu.ERR_BAD_REQUEST,e)):g.send(o||null)})},nc=(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,a();const t=e instanceof Error?e:this.reason;r.abort(t instanceof fu?t:new Hu(t instanceof Error?t.message:t))}};let i=t&&setTimeout(()=>{i=null,o(new fu(`timeout ${t} of ms exceeded`,fu.ETIMEDOUT))},t);const a=()=>{e&&(i&&clearTimeout(i),i=null,e.forEach(e=>{e.unsubscribe?e.unsubscribe(o):e.removeEventListener("abort",o)}),e=null)};e.forEach(e=>e.addEventListener("abort",o));const{signal:s}=r;return s.unsubscribe=()=>du.asap(a),s}},rc=function*(e,t){let n=e.byteLength;if(n<t)return void(yield e);let r,o=0;for(;o<n;)r=o+t,yield e.slice(o,r),o=r},oc=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()}},ic=(e,t,n,r)=>{const o=async function*(e,t){for await(const n of oc(e))yield*rc(n,t)}(e,t);let i,a=0,s=e=>{i||(i=!0,r&&r(e))};return new ReadableStream({async pull(e){try{const{done:t,value:r}=await o.next();if(t)return s(),void e.close();let i=r.byteLength;if(n){let e=a+=i;n(e)}e.enqueue(new Uint8Array(r))}catch(t){throw s(t),t}},cancel:e=>(s(e),o.return())},{highWaterMark:2})},{isFunction:ac}=du,sc=(({Request:e,Response:t})=>({Request:e,Response:t}))(du.global),{ReadableStream:lc,TextEncoder:uc}=du.global,cc=(e,...t)=>{try{return!!e(...t)}catch(De){return!1}},dc=e=>{e=du.merge.call({skipUndefined:!0},sc,e);const{fetch:t,Request:n,Response:r}=e,o=t?ac(t):"function"==typeof fetch,i=ac(n),a=ac(r);if(!o)return!1;const s=o&&ac(lc),l=o&&("function"==typeof uc?(e=>t=>e.encode(t))(new uc):async e=>new Uint8Array(await new n(e).arrayBuffer())),u=i&&s&&cc(()=>{let e=!1;const t=new n(Iu.origin,{body:new lc,method:"POST",get duplex(){return e=!0,"half"}}).headers.has("Content-Type");return e&&!t}),c=a&&s&&cc(()=>du.isReadableStream(new r("").body)),d={stream:c&&(e=>e.body)};o&&["text","arrayBuffer","blob","formData","stream"].forEach(e=>{!d[e]&&(d[e]=(t,n)=>{let r=t&&t[e];if(r)return r.call(t);throw new fu(`Response type '${e}' is not supported`,fu.ERR_NOT_SUPPORT,n)})});const f=async(e,t)=>{const r=du.toFiniteNumber(e.getContentLength());return null==r?(async e=>{if(null==e)return 0;if(du.isBlob(e))return e.size;if(du.isSpecCompliantForm(e)){const t=new n(Iu.origin,{method:"POST",body:e});return(await t.arrayBuffer()).byteLength}return du.isArrayBufferView(e)||du.isArrayBuffer(e)?e.byteLength:(du.isURLSearchParams(e)&&(e+=""),du.isString(e)?(await l(e)).byteLength:void 0)})(t):r};return async e=>{let{url:o,method:a,data:s,signal:l,cancelToken:p,timeout:h,onDownloadProgress:g,onUploadProgress:m,responseType:y,headers:v,withCredentials:b="same-origin",fetchOptions:k}=ec(e),x=t||fetch;y=y?(y+"").toLowerCase():"text";let w=nc([l,p&&p.toAbortSignal()],h),S=null;const E=w&&w.unsubscribe&&(()=>{w.unsubscribe()});let C;try{if(m&&u&&"get"!==a&&"head"!==a&&0!==(C=await f(v,s))){let e,t=new n(o,{method:"POST",body:s,duplex:"half"});if(du.isFormData(s)&&(e=t.headers.get("content-type"))&&v.setContentType(e),t.body){const[e,n]=Ku(C,Wu(Qu(m)));s=ic(t.body,65536,e,n)}}du.isString(b)||(b=b?"include":"omit");const t=i&&"credentials"in n.prototype,l={...k,signal:w,method:a.toUpperCase(),headers:v.normalize().toJSON(),body:s,duplex:"half",credentials:t?b:void 0};S=i&&new n(o,l);let p=await(i?x(S,k):x(o,l));const h=c&&("stream"===y||"response"===y);if(c&&(g||h&&E)){const e={};["status","statusText","headers"].forEach(t=>{e[t]=p[t]});const t=du.toFiniteNumber(p.headers.get("content-length")),[n,o]=g&&Ku(t,Wu(Qu(g),!0))||[];p=new r(ic(p.body,65536,n,()=>{o&&o(),E&&E()}),e)}y=y||"text";let T=await d[du.findKey(d,y)||"text"](p,e);return!h&&E&&E(),await new Promise((t,n)=>{qu(t,n,{data:T,headers:Bu.from(p.headers),status:p.status,statusText:p.statusText,config:e,request:S})})}catch(T){if(E&&E(),T&&"TypeError"===T.name&&/Load failed|fetch/i.test(T.message))throw Object.assign(new fu("Network Error",fu.ERR_NETWORK,e,S),{cause:T.cause||T});throw fu.from(T,T&&T.code,e,S)}}},fc=new Map,pc=e=>{let t=e?e.env:{};const{fetch:n,Request:r,Response:o}=t,i=[r,o,n];let a,s,l=i.length,u=fc;for(;l--;)a=i[l],s=u.get(a),void 0===s&&u.set(a,s=l?new Map:dc(t)),u=s;return s};pc();const hc={http:null,xhr:tc,fetch:{get:pc}};du.forEach(hc,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch(De){}Object.defineProperty(e,"adapterName",{value:t})}});const gc=e=>`- ${e}`,mc=e=>du.isFunction(e)||null===e||!1===e,yc=(e,t)=>{e=du.isArray(e)?e:[e];const{length:n}=e;let r,o;const i={};for(let a=0;a<n;a++){let n;if(r=e[a],o=r,!mc(r)&&(o=hc[(n=String(r)).toLowerCase()],void 0===o))throw new fu(`Unknown adapter '${n}'`);if(o&&(du.isFunction(o)||(o=o.get(t))))break;i[n||"#"+a]=o}if(!o){const e=Object.entries(i).map(([e,t])=>`adapter ${e} `+(!1===t?"is not supported by the environment":"is not available in the build"));throw new fu("There is no suitable adapter to dispatch the request "+(n?e.length>1?"since :\n"+e.map(gc).join("\n"):" "+gc(e[0]):"as no adapter specified"),"ERR_NOT_SUPPORT")}return o};function vc(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new Hu(null,e)}function bc(e){vc(e),e.headers=Bu.from(e.headers),e.data=$u.call(e,e.transformRequest),-1!==["post","put","patch"].indexOf(e.method)&&e.headers.setContentType("application/x-www-form-urlencoded",!1);return yc(e.adapter||Du.adapter,e)(e).then(function(t){return vc(e),t.data=$u.call(e,e.transformResponse,t),t.headers=Bu.from(t.headers),t},function(t){return Vu(t)||(vc(e),t&&t.response&&(t.response.data=$u.call(e,e.transformResponse,t.response),t.response.headers=Bu.from(t.response.headers))),Promise.reject(t)})}const kc="1.12.2",xc={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{xc[e]=function(n){return typeof n===e||"a"+(t<1?"n ":" ")+e}});const wc={};xc.transitional=function(e,t,n){return(r,o,i)=>{if(!1===e)throw new fu(function(e,t){return"[Axios v"+kc+"] Transitional option '"+e+"'"+t+(n?". "+n:"")}(o," has been removed"+(t?" in "+t:"")),fu.ERR_DEPRECATED);return t&&!wc[o]&&(wc[o]=!0),!e||e(r,o,i)}},xc.spelling=function(e){return(e,t)=>!0};const Sc={assertOptions:function(e,t,n){if("object"!=typeof e)throw new fu("options must be an object",fu.ERR_BAD_OPTION_VALUE);const r=Object.keys(e);let o=r.length;for(;o-- >0;){const i=r[o],a=t[i];if(a){const t=e[i],n=void 0===t||a(t,i,e);if(!0!==n)throw new fu("option "+i+" must be "+n,fu.ERR_BAD_OPTION_VALUE);continue}if(!0!==n)throw new fu("Unknown option "+i,fu.ERR_BAD_OPTION)}},validators:xc},Ec=Sc.validators;let Cc=class{constructor(e){this.defaults=e||{},this.interceptors={request:new Cu,response:new Cu}}async request(e,t){try{return await this._request(e,t)}catch(n){if(n instanceof Error){let e={};Error.captureStackTrace?Error.captureStackTrace(e):e=new Error;const t=e.stack?e.stack.replace(/^.+\n/,""):"";try{n.stack?t&&!String(n.stack).endsWith(t.replace(/^.+\n.+\n/,""))&&(n.stack+="\n"+t):n.stack=t}catch(De){}}throw n}}_request(e,t){"string"==typeof e?(t=t||{}).url=e:t=e||{},t=Zu(this.defaults,t);const{transitional:n,paramsSerializer:r,headers:o}=t;void 0!==n&&Sc.assertOptions(n,{silentJSONParsing:Ec.transitional(Ec.boolean),forcedJSONParsing:Ec.transitional(Ec.boolean),clarifyTimeoutError:Ec.transitional(Ec.boolean)},!1),null!=r&&(du.isFunction(r)?t.paramsSerializer={serialize:r}:Sc.assertOptions(r,{encode:Ec.function,serialize:Ec.function},!0)),void 0!==t.allowAbsoluteUrls||(void 0!==this.defaults.allowAbsoluteUrls?t.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:t.allowAbsoluteUrls=!0),Sc.assertOptions(t,{baseUrl:Ec.spelling("baseURL"),withXsrfToken:Ec.spelling("withXSRFToken")},!0),t.method=(t.method||this.defaults.method||"get").toLowerCase();let i=o&&du.merge(o.common,o[t.method]);o&&du.forEach(["delete","get","head","post","put","patch","common"],e=>{delete o[e]}),t.headers=Bu.concat(i,o);const a=[];let s=!0;this.interceptors.request.forEach(function(e){"function"==typeof e.runWhen&&!1===e.runWhen(t)||(s=s&&e.synchronous,a.unshift(e.fulfilled,e.rejected))});const l=[];let u;this.interceptors.response.forEach(function(e){l.push(e.fulfilled,e.rejected)});let c,d=0;if(!s){const e=[bc.bind(this),void 0];for(e.unshift(...a),e.push(...l),c=e.length,u=Promise.resolve(t);d<c;)u=u.then(e[d++],e[d++]);return u}c=a.length;let f=t;for(;d<c;){const e=a[d++],t=a[d++];try{f=e(f)}catch(p){t.call(this,p);break}}try{u=bc.call(this,f)}catch(p){return Promise.reject(p)}for(d=0,c=l.length;d<c;)u=u.then(l[d++],l[d++]);return u}getUri(e){return Eu(Gu((e=Zu(this.defaults,e)).baseURL,e.url,e.allowAbsoluteUrls),e.params,e.paramsSerializer)}};du.forEach(["delete","get","head","options"],function(e){Cc.prototype[e]=function(t,n){return this.request(Zu(n||{},{method:e,url:t,data:(n||{}).data}))}}),du.forEach(["post","put","patch"],function(e){function t(t){return function(n,r,o){return this.request(Zu(o||{},{method:e,headers:t?{"Content-Type":"multipart/form-data"}:{},url:n,data:r}))}}Cc.prototype[e]=t(),Cc.prototype[e+"Form"]=t(!0)});const Tc={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(Tc).forEach(([e,t])=>{Tc[t]=e});const Oc=function e(t){const n=new Cc(t),r=Sl(Cc.prototype.request,n);return du.extend(r,Cc.prototype,n,{allOwnKeys:!0}),du.extend(r,n,null,{allOwnKeys:!0}),r.create=function(n){return e(Zu(t,n))},r}(Du);Oc.Axios=Cc,Oc.CanceledError=Hu,Oc.CancelToken=class e{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 Hu(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 t;return{token:new e(function(e){t=e}),cancel:t}}},Oc.isCancel=Vu,Oc.VERSION=kc,Oc.toFormData=bu,Oc.AxiosError=fu,Oc.Cancel=Oc.CanceledError,Oc.all=function(e){return Promise.all(e)},Oc.spread=function(e){return function(t){return e.apply(null,t)}},Oc.isAxiosError=function(e){return du.isObject(e)&&!0===e.isAxiosError},Oc.mergeConfig=Zu,Oc.AxiosHeaders=Bu,Oc.formToJSON=e=>Au(du.isHTMLForm(e)?new FormData(e):e),Oc.getAdapter=yc,Oc.HttpStatusCode=Tc,Oc.default=Oc;const{Axios:Nc,AxiosError:Pc,CanceledError:Lc,isCancel:Rc,CancelToken:_c,VERSION:Ic,all:Ac,Cancel:Dc,isAxiosError:zc,spread:jc,toFormData:Fc,AxiosHeaders:Mc,HttpStatusCode:Uc,formToJSON:Bc,getAdapter:$c,mergeConfig:Vc}=Oc;class Hc{constructor(e,t){this.licenseToken=t,this.sessionToken=this._getOrCreateSessionToken(t),this.api=Oc.create({baseURL:e||Bs,timeout:el,headers:{"Content-Type":"application/json"}}),this.api.interceptors.request.use(e=>(this.licenseToken&&(e.headers.Authorization=`Bearer ${this.licenseToken}`),e))}_generateSessionToken(){return"session_"+Array.from(crypto.getRandomValues(new Uint8Array(28))).map(e=>e.toString(16).padStart(2,"0")).join("")}_getStorageKey(e){return`tiagpc_session_${e.substring(0,16)}`}_getOrCreateSessionToken(e){const t=this._getStorageKey(e);try{const e=localStorage.getItem(t);if(e){const{sessionToken:n,timestamp:r,validated:o}=JSON.parse(e),i=Date.now();if(o&&i-r<864e5)return n;localStorage.removeItem(t)}}catch(n){}return this._generateSessionToken()}hasValidCachedSession(){const e=this._getStorageKey(this.licenseToken);try{const t=localStorage.getItem(e);if(t){const{sessionToken:e,timestamp:n,validated:r}=JSON.parse(t),o=Date.now();return r&&o-n<864e5}}catch(t){}return!1}_saveSessionToken(e,t,n=!1){const r=this._getStorageKey(e);try{const e={sessionToken:t,timestamp:Date.now(),validated:n};localStorage.setItem(r,JSON.stringify(e))}catch(o){}}_clearSessionToken(e){const t=this._getStorageKey(e);try{localStorage.removeItem(t)}catch(n){}}async sendMessage(e,t,n){if(!this.licenseToken)throw new Error("License token is required.");const r=this.hasValidCachedSession();if(!t&&!r)throw new Error("Turnstile token is required for anti-bot validation.");const o=`${this.api.defaults.baseURL}/ask`;try{const r=await fetch(o,{method:"POST",headers:{"Content-Type":"application/json",Authorization:`Bearer ${this.licenseToken}`},body:JSON.stringify({message:e,turnstile_token:t||"CACHED_SESSION",session_token:this.sessionToken})});if(!r.ok){const e=await r.json().catch(()=>({}));throw new Error(JSON.stringify({statusCode:r.status,errorCode:e.error_code||"UNKNOWN_ERROR",message:e.message||"Request failed",retryAfter:e.retry_after_seconds||null}))}const a=r.body.getReader(),s=new TextDecoder;let l="",u="",c=null,d=null;for(;;){const{done:e,value:t}=await a.read();if(e)break;l+=s.decode(t,{stream:!0});const r=l.split("\n");l=r.pop();for(const o of r){if(!o.trim()||!o.startsWith("data: "))continue;const e=o.replace("data: ","").trim();if("[DONE]"!==e)try{const t=JSON.parse(e);if("content"===t.type)u+=t.text,n&&n(t.text);else if("metadata"===t.type)c=t;else if("summary"===t.type)d=t;else if("error"===t.type)throw new Error(JSON.stringify({statusCode:t.status_code||500,errorCode:t.error_code,message:t.message,retryAfter:null}))}catch(i){if(i.message&&i.message.startsWith("{"))throw i}}}if(!d)throw new Error("No summary received from server");return{success:!0,data:{message_id:d.message_id,response:u,cost_usd:d.cost_usd,credit_balance_usd:d.credit_balance_usd,input_tokens:d.input_tokens,output_tokens:d.output_tokens,response_time_ms:d.response_time_ms,model_used:d.model_used,created_at:d.created_at}}}catch(a){if(a.message.startsWith("{"))throw a;throw new Error(JSON.stringify({statusCode:500,errorCode:"NETWORK_ERROR",message:a.message,retryAfter:null}))}}async transcribeAudio(e){if(!this.licenseToken)throw new Error("License token is required.");try{const t=new FormData;t.append("file",e,"audio.webm");return(await this.api.post("/transcribe",t,{headers:{"Content-Type":"multipart/form-data"}})).data}catch(t){this._handleError(t)}}async releaseSession(){if(this.licenseToken)try{return(await this.api.post("/release-session",{session_token:this.sessionToken})).data}catch(e){}}async getInitConfig(){if(!this.licenseToken)throw new Error("License token is required.");try{return(await this.api.get("/init")).data}catch(e){this._handleError(e)}}async checkHealth(){try{return(await this.api.get("/health")).data}catch(e){return{status:"unhealthy",error:e.message}}}getSessionToken(){return this.sessionToken}renewSessionToken(){const e=this._generateSessionToken();this.sessionToken=e,this._saveSessionToken(this.licenseToken,e)}validateSession(){this._saveSessionToken(this.licenseToken,this.sessionToken,!0)}_handleError(e){if(e.response){const t=e.response.data,n={statusCode:e.response.status,errorCode:t.error_code||"UNKNOWN_ERROR",message:t.message||"Request failed",retryAfter:t.retry_after_seconds||null};throw new Error(JSON.stringify(n))}throw e.request?new Error(JSON.stringify({statusCode:503,errorCode:"NETWORK_ERROR",message:"No response from server",retryAfter:null})):new Error(JSON.stringify({statusCode:500,errorCode:"INTERNAL_ERROR",message:e.message,retryAfter:null}))}}const qc=e=>"string"==typeof e,Wc=()=>{let e,t;const n=new Promise((n,r)=>{e=n,t=r});return n.resolve=e,n.reject=t,n},Kc=e=>null==e?"":""+e,Qc=/###/g,Jc=e=>e&&e.indexOf("###")>-1?e.replace(Qc,"."):e,Yc=e=>!e||qc(e),Gc=(e,t,n)=>{const r=qc(t)?t.split("."):t;let o=0;for(;o<r.length-1;){if(Yc(e))return{};const t=Jc(r[o]);!e[t]&&n&&(e[t]=new n),e=Object.prototype.hasOwnProperty.call(e,t)?e[t]:{},++o}return Yc(e)?{}:{obj:e,k:Jc(r[o])}},Xc=(e,t,n)=>{const{obj:r,k:o}=Gc(e,t,Object);if(void 0!==r||1===t.length)return void(r[o]=n);let i=t[t.length-1],a=t.slice(0,t.length-1),s=Gc(e,a,Object);for(;void 0===s.obj&&a.length;)i=`${a[a.length-1]}.${i}`,a=a.slice(0,a.length-1),s=Gc(e,a,Object),s?.obj&&void 0!==s.obj[`${s.k}.${i}`]&&(s.obj=void 0);s.obj[`${s.k}.${i}`]=n},Zc=(e,t)=>{const{obj:n,k:r}=Gc(e,t);if(n&&Object.prototype.hasOwnProperty.call(n,r))return n[r]},ed=(e,t,n)=>{for(const r in t)"__proto__"!==r&&"constructor"!==r&&(r in e?qc(e[r])||e[r]instanceof String||qc(t[r])||t[r]instanceof String?n&&(e[r]=t[r]):ed(e[r],t[r],n):e[r]=t[r]);return e},td=e=>e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&");var nd={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;","/":"&#x2F;"};const rd=e=>qc(e)?e.replace(/[&<>"'\/]/g,e=>nd[e]):e;const od=[" ",",","?","!",";"],id=new class{constructor(e){this.capacity=e,this.regExpMap=new Map,this.regExpQueue=[]}getRegExp(e){const t=this.regExpMap.get(e);if(void 0!==t)return t;const n=new RegExp(e);return this.regExpQueue.length===this.capacity&&this.regExpMap.delete(this.regExpQueue.shift()),this.regExpMap.set(e,n),this.regExpQueue.push(e),n}}(20),ad=(e,t,n=".")=>{if(!e)return;if(e[t]){if(!Object.prototype.hasOwnProperty.call(e,t))return;return e[t]}const r=t.split(n);let o=e;for(let i=0;i<r.length;){if(!o||"object"!=typeof o)return;let e,t="";for(let a=i;a<r.length;++a)if(a!==i&&(t+=n),t+=r[a],e=o[t],void 0!==e){if(["string","number","boolean"].indexOf(typeof e)>-1&&a<r.length-1)continue;i+=a-i+1;break}o=e}return o},sd=e=>e?.replace("_","-"),ld={type:"logger",log(e){this.output("log",e)},warn(e){this.output("warn",e)},error(e){this.output("error",e)},output(e,t){}};class ud{constructor(e,t={}){this.init(e,t)}init(e,t={}){this.prefix=t.prefix||"i18next:",this.logger=e||ld,this.options=t,this.debug=t.debug}log(...e){return this.forward(e,"log","",!0)}warn(...e){return this.forward(e,"warn","",!0)}error(...e){return this.forward(e,"error","")}deprecate(...e){return this.forward(e,"warn","WARNING DEPRECATED: ",!0)}forward(e,t,n,r){return r&&!this.debug?null:(qc(e[0])&&(e[0]=`${n}${this.prefix} ${e[0]}`),this.logger[t](e))}create(e){return new ud(this.logger,{prefix:`${this.prefix}:${e}:`,...this.options})}clone(e){return(e=e||this.options).prefix=e.prefix||this.prefix,new ud(this.logger,e)}}var cd=new ud;class dd{constructor(){this.observers={}}on(e,t){return e.split(" ").forEach(e=>{this.observers[e]||(this.observers[e]=new Map);const n=this.observers[e].get(t)||0;this.observers[e].set(t,n+1)}),this}off(e,t){this.observers[e]&&(t?this.observers[e].delete(t):delete this.observers[e])}emit(e,...t){if(this.observers[e]){Array.from(this.observers[e].entries()).forEach(([e,n])=>{for(let r=0;r<n;r++)e(...t)})}if(this.observers["*"]){Array.from(this.observers["*"].entries()).forEach(([n,r])=>{for(let o=0;o<r;o++)n.apply(n,[e,...t])})}}}class fd extends dd{constructor(e,t={ns:["translation"],defaultNS:"translation"}){super(),this.data=e||{},this.options=t,void 0===this.options.keySeparator&&(this.options.keySeparator="."),void 0===this.options.ignoreJSONStructure&&(this.options.ignoreJSONStructure=!0)}addNamespaces(e){this.options.ns.indexOf(e)<0&&this.options.ns.push(e)}removeNamespaces(e){const t=this.options.ns.indexOf(e);t>-1&&this.options.ns.splice(t,1)}getResource(e,t,n,r={}){const o=void 0!==r.keySeparator?r.keySeparator:this.options.keySeparator,i=void 0!==r.ignoreJSONStructure?r.ignoreJSONStructure:this.options.ignoreJSONStructure;let a;e.indexOf(".")>-1?a=e.split("."):(a=[e,t],n&&(Array.isArray(n)?a.push(...n):qc(n)&&o?a.push(...n.split(o)):a.push(n)));const s=Zc(this.data,a);return!s&&!t&&!n&&e.indexOf(".")>-1&&(e=a[0],t=a[1],n=a.slice(2).join(".")),!s&&i&&qc(n)?ad(this.data?.[e]?.[t],n,o):s}addResource(e,t,n,r,o={silent:!1}){const i=void 0!==o.keySeparator?o.keySeparator:this.options.keySeparator;let a=[e,t];n&&(a=a.concat(i?n.split(i):n)),e.indexOf(".")>-1&&(a=e.split("."),r=t,t=a[1]),this.addNamespaces(t),Xc(this.data,a,r),o.silent||this.emit("added",e,t,n,r)}addResources(e,t,n,r={silent:!1}){for(const o in n)(qc(n[o])||Array.isArray(n[o]))&&this.addResource(e,t,o,n[o],{silent:!0});r.silent||this.emit("added",e,t,n)}addResourceBundle(e,t,n,r,o,i={silent:!1,skipCopy:!1}){let a=[e,t];e.indexOf(".")>-1&&(a=e.split("."),r=n,n=t,t=a[1]),this.addNamespaces(t);let s=Zc(this.data,a)||{};i.skipCopy||(n=JSON.parse(JSON.stringify(n))),r?ed(s,n,o):s={...s,...n},Xc(this.data,a,s),i.silent||this.emit("added",e,t,n)}removeResourceBundle(e,t){this.hasResourceBundle(e,t)&&delete this.data[e][t],this.removeNamespaces(t),this.emit("removed",e,t)}hasResourceBundle(e,t){return void 0!==this.getResource(e,t)}getResourceBundle(e,t){return t||(t=this.options.defaultNS),this.getResource(e,t)}getDataByLanguage(e){return this.data[e]}hasLanguageSomeTranslations(e){const t=this.getDataByLanguage(e);return!!(t&&Object.keys(t)||[]).find(e=>t[e]&&Object.keys(t[e]).length>0)}toJSON(){return this.data}}var pd={processors:{},addPostProcessor(e){this.processors[e.name]=e},handle(e,t,n,r,o){return e.forEach(e=>{t=this.processors[e]?.process(t,n,r,o)??t}),t}};const hd=Symbol("i18next/PATH_KEY");function gd(e,t){const{[hd]:n}=e(function(){const e=[],t=Object.create(null);let n;return t.get=(r,o)=>(n?.revoke?.(),o===hd?e:(e.push(o),n=Proxy.revocable(r,t),n.proxy)),Proxy.revocable(Object.create(null),t).proxy}());return n.join(t?.keySeparator??".")}const md={},yd=e=>!qc(e)&&"boolean"!=typeof e&&"number"!=typeof e;class vd extends dd{constructor(e,t={}){super(),((e,t,n)=>{e.forEach(e=>{t[e]&&(n[e]=t[e])})})(["resourceStore","languageUtils","pluralResolver","interpolator","backendConnector","i18nFormat","utils"],e,this),this.options=t,void 0===this.options.keySeparator&&(this.options.keySeparator="."),this.logger=cd.create("translator")}changeLanguage(e){e&&(this.language=e)}exists(e,t={interpolation:{}}){const n={...t};if(null==e)return!1;const r=this.resolve(e,n);if(void 0===r?.res)return!1;const o=yd(r.res);return!1!==n.returnObjects||!o}extractFromKey(e,t){let n=void 0!==t.nsSeparator?t.nsSeparator:this.options.nsSeparator;void 0===n&&(n=":");const r=void 0!==t.keySeparator?t.keySeparator:this.options.keySeparator;let o=t.ns||this.options.defaultNS||[];const i=n&&e.indexOf(n)>-1,a=!(this.options.userDefinedKeySeparator||t.keySeparator||this.options.userDefinedNsSeparator||t.nsSeparator||((e,t,n)=>{t=t||"",n=n||"";const r=od.filter(e=>t.indexOf(e)<0&&n.indexOf(e)<0);if(0===r.length)return!0;const o=id.getRegExp(`(${r.map(e=>"?"===e?"\\?":e).join("|")})`);let i=!o.test(e);if(!i){const t=e.indexOf(n);t>0&&!o.test(e.substring(0,t))&&(i=!0)}return i})(e,n,r));if(i&&!a){const t=e.match(this.interpolator.nestingRegexp);if(t&&t.length>0)return{key:e,namespaces:qc(o)?[o]:o};const i=e.split(n);(n!==r||n===r&&this.options.ns.indexOf(i[0])>-1)&&(o=i.shift()),e=i.join(r)}return{key:e,namespaces:qc(o)?[o]:o}}translate(e,t,n){let r="object"==typeof t?{...t}:t;if("object"!=typeof r&&this.options.overloadTranslationOptionHandler&&(r=this.options.overloadTranslationOptionHandler(arguments)),"object"==typeof r&&(r={...r}),r||(r={}),null==e)return"";"function"==typeof e&&(e=gd(e,{...this.options,...r})),Array.isArray(e)||(e=[String(e)]);const o=void 0!==r.returnDetails?r.returnDetails:this.options.returnDetails,i=void 0!==r.keySeparator?r.keySeparator:this.options.keySeparator,{key:a,namespaces:s}=this.extractFromKey(e[e.length-1],r),l=s[s.length-1];let u=void 0!==r.nsSeparator?r.nsSeparator:this.options.nsSeparator;void 0===u&&(u=":");const c=r.lng||this.language,d=r.appendNamespaceToCIMode||this.options.appendNamespaceToCIMode;if("cimode"===c?.toLowerCase())return d?o?{res:`${l}${u}${a}`,usedKey:a,exactUsedKey:a,usedLng:c,usedNS:l,usedParams:this.getUsedParamsDetails(r)}:`${l}${u}${a}`:o?{res:a,usedKey:a,exactUsedKey:a,usedLng:c,usedNS:l,usedParams:this.getUsedParamsDetails(r)}:a;const f=this.resolve(e,r);let p=f?.res;const h=f?.usedKey||a,g=f?.exactUsedKey||a,m=void 0!==r.joinArrays?r.joinArrays:this.options.joinArrays,y=!this.i18nFormat||this.i18nFormat.handleAsObject,v=void 0!==r.count&&!qc(r.count),b=vd.hasDefaultValue(r),k=v?this.pluralResolver.getSuffix(c,r.count,r):"",x=r.ordinal&&v?this.pluralResolver.getSuffix(c,r.count,{ordinal:!1}):"",w=v&&!r.ordinal&&0===r.count,S=w&&r[`defaultValue${this.options.pluralSeparator}zero`]||r[`defaultValue${k}`]||r[`defaultValue${x}`]||r.defaultValue;let E=p;y&&!p&&b&&(E=S);const C=yd(E),T=Object.prototype.toString.apply(E);if(!(y&&E&&C&&["[object Number]","[object Function]","[object RegExp]"].indexOf(T)<0)||qc(m)&&Array.isArray(E))if(y&&qc(m)&&Array.isArray(p))p=p.join(m),p&&(p=this.extendTranslation(p,e,r,n));else{let t=!1,o=!1;!this.isValidLookup(p)&&b&&(t=!0,p=S),this.isValidLookup(p)||(o=!0,p=a);const s=(r.missingKeyNoValueFallbackToKey||this.options.missingKeyNoValueFallbackToKey)&&o?void 0:p,d=b&&S!==p&&this.options.updateMissing;if(o||t||d){if(this.logger.log(d?"updateKey":"missingKey",c,l,a,d?S:p),i){const e=this.resolve(a,{...r,keySeparator:!1});e&&e.res&&this.logger.warn("Seems the loaded translations were in flat JSON format instead of nested. Either set keySeparator: false on init or make sure your translations are published in nested format.")}let e=[];const t=this.languageUtils.getFallbackCodes(this.options.fallbackLng,r.lng||this.language);if("fallback"===this.options.saveMissingTo&&t&&t[0])for(let r=0;r<t.length;r++)e.push(t[r]);else"all"===this.options.saveMissingTo?e=this.languageUtils.toResolveHierarchy(r.lng||this.language):e.push(r.lng||this.language);const n=(e,t,n)=>{const o=b&&n!==p?n:s;this.options.missingKeyHandler?this.options.missingKeyHandler(e,l,t,o,d,r):this.backendConnector?.saveMissing&&this.backendConnector.saveMissing(e,l,t,o,d,r),this.emit("missingKey",e,l,t,p)};this.options.saveMissing&&(this.options.saveMissingPlurals&&v?e.forEach(e=>{const t=this.pluralResolver.getSuffixes(e,r);w&&r[`defaultValue${this.options.pluralSeparator}zero`]&&t.indexOf(`${this.options.pluralSeparator}zero`)<0&&t.push(`${this.options.pluralSeparator}zero`),t.forEach(t=>{n([e],a+t,r[`defaultValue${t}`]||S)})}):n(e,a,S))}p=this.extendTranslation(p,e,r,f,n),o&&p===a&&this.options.appendNamespaceToMissingKey&&(p=`${l}${u}${a}`),(o||t)&&this.options.parseMissingKeyHandler&&(p=this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey?`${l}${u}${a}`:a,t?p:void 0,r))}else{if(!r.returnObjects&&!this.options.returnObjects){this.options.returnedObjectHandler||this.logger.warn("accessing an object - but returnObjects options is not enabled!");const e=this.options.returnedObjectHandler?this.options.returnedObjectHandler(h,E,{...r,ns:s}):`key '${a} (${this.language})' returned an object instead of string.`;return o?(f.res=e,f.usedParams=this.getUsedParamsDetails(r),f):e}if(i){const e=Array.isArray(E),t=e?[]:{},n=e?g:h;for(const o in E)if(Object.prototype.hasOwnProperty.call(E,o)){const e=`${n}${i}${o}`;t[o]=b&&!p?this.translate(e,{...r,defaultValue:yd(S)?S[o]:void 0,joinArrays:!1,ns:s}):this.translate(e,{...r,joinArrays:!1,ns:s}),t[o]===e&&(t[o]=E[o])}p=t}}return o?(f.res=p,f.usedParams=this.getUsedParamsDetails(r),f):p}extendTranslation(e,t,n,r,o){if(this.i18nFormat?.parse)e=this.i18nFormat.parse(e,{...this.options.interpolation.defaultVariables,...n},n.lng||this.language||r.usedLng,r.usedNS,r.usedKey,{resolved:r});else if(!n.skipInterpolation){n.interpolation&&this.interpolator.init({...n,interpolation:{...this.options.interpolation,...n.interpolation}});const i=qc(e)&&(void 0!==n?.interpolation?.skipOnVariables?n.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables);let a;if(i){const t=e.match(this.interpolator.nestingRegexp);a=t&&t.length}let s=n.replace&&!qc(n.replace)?n.replace:n;if(this.options.interpolation.defaultVariables&&(s={...this.options.interpolation.defaultVariables,...s}),e=this.interpolator.interpolate(e,s,n.lng||this.language||r.usedLng,n),i){const t=e.match(this.interpolator.nestingRegexp);a<(t&&t.length)&&(n.nest=!1)}!n.lng&&r&&r.res&&(n.lng=this.language||r.usedLng),!1!==n.nest&&(e=this.interpolator.nest(e,(...e)=>o?.[0]!==e[0]||n.context?this.translate(...e,t):(this.logger.warn(`It seems you are nesting recursively key: ${e[0]} in key: ${t[0]}`),null),n)),n.interpolation&&this.interpolator.reset()}const i=n.postProcess||this.options.postProcess,a=qc(i)?[i]:i;return null!=e&&a?.length&&!1!==n.applyPostProcessor&&(e=pd.handle(a,e,t,this.options&&this.options.postProcessPassResolved?{i18nResolved:{...r,usedParams:this.getUsedParamsDetails(n)},...n}:n,this)),e}resolve(e,t={}){let n,r,o,i,a;return qc(e)&&(e=[e]),e.forEach(e=>{if(this.isValidLookup(n))return;const s=this.extractFromKey(e,t),l=s.key;r=l;let u=s.namespaces;this.options.fallbackNS&&(u=u.concat(this.options.fallbackNS));const c=void 0!==t.count&&!qc(t.count),d=c&&!t.ordinal&&0===t.count,f=void 0!==t.context&&(qc(t.context)||"number"==typeof t.context)&&""!==t.context,p=t.lngs?t.lngs:this.languageUtils.toResolveHierarchy(t.lng||this.language,t.fallbackLng);u.forEach(e=>{this.isValidLookup(n)||(a=e,md[`${p[0]}-${e}`]||!this.utils?.hasLoadedNamespace||this.utils?.hasLoadedNamespace(a)||(md[`${p[0]}-${e}`]=!0,this.logger.warn(`key "${r}" for languages "${p.join(", ")}" won't get resolved as namespace "${a}" was not yet loaded`,"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")),p.forEach(r=>{if(this.isValidLookup(n))return;i=r;const a=[l];if(this.i18nFormat?.addLookupKeys)this.i18nFormat.addLookupKeys(a,l,r,e,t);else{let e;c&&(e=this.pluralResolver.getSuffix(r,t.count,t));const n=`${this.options.pluralSeparator}zero`,o=`${this.options.pluralSeparator}ordinal${this.options.pluralSeparator}`;if(c&&(t.ordinal&&0===e.indexOf(o)&&a.push(l+e.replace(o,this.options.pluralSeparator)),a.push(l+e),d&&a.push(l+n)),f){const r=`${l}${this.options.contextSeparator||"_"}${t.context}`;a.push(r),c&&(t.ordinal&&0===e.indexOf(o)&&a.push(r+e.replace(o,this.options.pluralSeparator)),a.push(r+e),d&&a.push(r+n))}}let s;for(;s=a.pop();)this.isValidLookup(n)||(o=s,n=this.getResource(r,e,s,t))}))})}),{res:n,usedKey:r,exactUsedKey:o,usedLng:i,usedNS:a}}isValidLookup(e){return!(void 0===e||!this.options.returnNull&&null===e||!this.options.returnEmptyString&&""===e)}getResource(e,t,n,r={}){return this.i18nFormat?.getResource?this.i18nFormat.getResource(e,t,n,r):this.resourceStore.getResource(e,t,n,r)}getUsedParamsDetails(e={}){const t=["defaultValue","ordinal","context","replace","lng","lngs","fallbackLng","ns","keySeparator","nsSeparator","returnObjects","returnDetails","joinArrays","postProcess","interpolation"],n=e.replace&&!qc(e.replace);let r=n?e.replace:e;if(n&&void 0!==e.count&&(r.count=e.count),this.options.interpolation.defaultVariables&&(r={...this.options.interpolation.defaultVariables,...r}),!n){r={...r};for(const e of t)delete r[e]}return r}static hasDefaultValue(e){const t="defaultValue";for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&t===n.substring(0,12)&&void 0!==e[n])return!0;return!1}}class bd{constructor(e){this.options=e,this.supportedLngs=this.options.supportedLngs||!1,this.logger=cd.create("languageUtils")}getScriptPartFromCode(e){if(!(e=sd(e))||e.indexOf("-")<0)return null;const t=e.split("-");return 2===t.length?null:(t.pop(),"x"===t[t.length-1].toLowerCase()?null:this.formatLanguageCode(t.join("-")))}getLanguagePartFromCode(e){if(!(e=sd(e))||e.indexOf("-")<0)return e;const t=e.split("-");return this.formatLanguageCode(t[0])}formatLanguageCode(e){if(qc(e)&&e.indexOf("-")>-1){let t;try{t=Intl.getCanonicalLocales(e)[0]}catch(De){}return t&&this.options.lowerCaseLng&&(t=t.toLowerCase()),t||(this.options.lowerCaseLng?e.toLowerCase():e)}return this.options.cleanCode||this.options.lowerCaseLng?e.toLowerCase():e}isSupportedCode(e){return("languageOnly"===this.options.load||this.options.nonExplicitSupportedLngs)&&(e=this.getLanguagePartFromCode(e)),!this.supportedLngs||!this.supportedLngs.length||this.supportedLngs.indexOf(e)>-1}getBestMatchFromCodes(e){if(!e)return null;let t;return e.forEach(e=>{if(t)return;const n=this.formatLanguageCode(e);this.options.supportedLngs&&!this.isSupportedCode(n)||(t=n)}),!t&&this.options.supportedLngs&&e.forEach(e=>{if(t)return;const n=this.getScriptPartFromCode(e);if(this.isSupportedCode(n))return t=n;const r=this.getLanguagePartFromCode(e);if(this.isSupportedCode(r))return t=r;t=this.options.supportedLngs.find(e=>e===r?e:e.indexOf("-")<0&&r.indexOf("-")<0?void 0:e.indexOf("-")>0&&r.indexOf("-")<0&&e.substring(0,e.indexOf("-"))===r||0===e.indexOf(r)&&r.length>1?e:void 0)}),t||(t=this.getFallbackCodes(this.options.fallbackLng)[0]),t}getFallbackCodes(e,t){if(!e)return[];if("function"==typeof e&&(e=e(t)),qc(e)&&(e=[e]),Array.isArray(e))return e;if(!t)return e.default||[];let n=e[t];return n||(n=e[this.getScriptPartFromCode(t)]),n||(n=e[this.formatLanguageCode(t)]),n||(n=e[this.getLanguagePartFromCode(t)]),n||(n=e.default),n||[]}toResolveHierarchy(e,t){const n=this.getFallbackCodes((!1===t?[]:t)||this.options.fallbackLng||[],e),r=[],o=e=>{e&&(this.isSupportedCode(e)?r.push(e):this.logger.warn(`rejecting language code not found in supportedLngs: ${e}`))};return qc(e)&&(e.indexOf("-")>-1||e.indexOf("_")>-1)?("languageOnly"!==this.options.load&&o(this.formatLanguageCode(e)),"languageOnly"!==this.options.load&&"currentOnly"!==this.options.load&&o(this.getScriptPartFromCode(e)),"currentOnly"!==this.options.load&&o(this.getLanguagePartFromCode(e))):qc(e)&&o(this.formatLanguageCode(e)),n.forEach(e=>{r.indexOf(e)<0&&o(this.formatLanguageCode(e))}),r}}const kd={zero:0,one:1,two:2,few:3,many:4,other:5},xd={select:e=>1===e?"one":"other",resolvedOptions:()=>({pluralCategories:["one","other"]})};class wd{constructor(e,t={}){this.languageUtils=e,this.options=t,this.logger=cd.create("pluralResolver"),this.pluralRulesCache={}}addRule(e,t){this.rules[e]=t}clearCache(){this.pluralRulesCache={}}getRule(e,t={}){const n=sd("dev"===e?"en":e),r=t.ordinal?"ordinal":"cardinal",o=JSON.stringify({cleanedCode:n,type:r});if(o in this.pluralRulesCache)return this.pluralRulesCache[o];let i;try{i=new Intl.PluralRules(n,{type:r})}catch(a){if(!Intl)return this.logger.error("No Intl support, please use an Intl polyfill!"),xd;if(!e.match(/-|_/))return xd;const n=this.languageUtils.getLanguagePartFromCode(e);i=this.getRule(n,t)}return this.pluralRulesCache[o]=i,i}needsPlural(e,t={}){let n=this.getRule(e,t);return n||(n=this.getRule("dev",t)),n?.resolvedOptions().pluralCategories.length>1}getPluralFormsOfKey(e,t,n={}){return this.getSuffixes(e,n).map(e=>`${t}${e}`)}getSuffixes(e,t={}){let n=this.getRule(e,t);return n||(n=this.getRule("dev",t)),n?n.resolvedOptions().pluralCategories.sort((e,t)=>kd[e]-kd[t]).map(e=>`${this.options.prepend}${t.ordinal?`ordinal${this.options.prepend}`:""}${e}`):[]}getSuffix(e,t,n={}){const r=this.getRule(e,n);return r?`${this.options.prepend}${n.ordinal?`ordinal${this.options.prepend}`:""}${r.select(t)}`:(this.logger.warn(`no plural rule found for: ${e}`),this.getSuffix("dev",t,n))}}const Sd=(e,t,n,r=".",o=!0)=>{let i=((e,t,n)=>{const r=Zc(e,n);return void 0!==r?r:Zc(t,n)})(e,t,n);return!i&&o&&qc(n)&&(i=ad(e,n,r),void 0===i&&(i=ad(t,n,r))),i},Ed=e=>e.replace(/\$/g,"$$$$");class Cd{constructor(e={}){this.logger=cd.create("interpolator"),this.options=e,this.format=e?.interpolation?.format||(e=>e),this.init(e)}init(e={}){e.interpolation||(e.interpolation={escapeValue:!0});const{escape:t,escapeValue:n,useRawValueToEscape:r,prefix:o,prefixEscaped:i,suffix:a,suffixEscaped:s,formatSeparator:l,unescapeSuffix:u,unescapePrefix:c,nestingPrefix:d,nestingPrefixEscaped:f,nestingSuffix:p,nestingSuffixEscaped:h,nestingOptionsSeparator:g,maxReplaces:m,alwaysFormat:y}=e.interpolation;this.escape=void 0!==t?t:rd,this.escapeValue=void 0===n||n,this.useRawValueToEscape=void 0!==r&&r,this.prefix=o?td(o):i||"{{",this.suffix=a?td(a):s||"}}",this.formatSeparator=l||",",this.unescapePrefix=u?"":c||"-",this.unescapeSuffix=this.unescapePrefix?"":u||"",this.nestingPrefix=d?td(d):f||td("$t("),this.nestingSuffix=p?td(p):h||td(")"),this.nestingOptionsSeparator=g||",",this.maxReplaces=m||1e3,this.alwaysFormat=void 0!==y&&y,this.resetRegExp()}reset(){this.options&&this.init(this.options)}resetRegExp(){const e=(e,t)=>e?.source===t?(e.lastIndex=0,e):new RegExp(t,"g");this.regexp=e(this.regexp,`${this.prefix}(.+?)${this.suffix}`),this.regexpUnescape=e(this.regexpUnescape,`${this.prefix}${this.unescapePrefix}(.+?)${this.unescapeSuffix}${this.suffix}`),this.nestingRegexp=e(this.nestingRegexp,`${this.nestingPrefix}((?:[^()"']+|"[^"]*"|'[^']*'|\\((?:[^()]|"[^"]*"|'[^']*')*\\))*?)${this.nestingSuffix}`)}interpolate(e,t,n,r){let o,i,a;const s=this.options&&this.options.interpolation&&this.options.interpolation.defaultVariables||{},l=e=>{if(e.indexOf(this.formatSeparator)<0){const o=Sd(t,s,e,this.options.keySeparator,this.options.ignoreJSONStructure);return this.alwaysFormat?this.format(o,void 0,n,{...r,...t,interpolationkey:e}):o}const o=e.split(this.formatSeparator),i=o.shift().trim(),a=o.join(this.formatSeparator).trim();return this.format(Sd(t,s,i,this.options.keySeparator,this.options.ignoreJSONStructure),a,n,{...r,...t,interpolationkey:i})};this.resetRegExp();const u=r?.missingInterpolationHandler||this.options.missingInterpolationHandler,c=void 0!==r?.interpolation?.skipOnVariables?r.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables;return[{regex:this.regexpUnescape,safeValue:e=>Ed(e)},{regex:this.regexp,safeValue:e=>this.escapeValue?Ed(this.escape(e)):Ed(e)}].forEach(t=>{for(a=0;o=t.regex.exec(e);){const n=o[1].trim();if(i=l(n),void 0===i)if("function"==typeof u){const t=u(e,o,r);i=qc(t)?t:""}else if(r&&Object.prototype.hasOwnProperty.call(r,n))i="";else{if(c){i=o[0];continue}this.logger.warn(`missed to pass in variable ${n} for interpolating ${e}`),i=""}else qc(i)||this.useRawValueToEscape||(i=Kc(i));const s=t.safeValue(i);if(e=e.replace(o[0],s),c?(t.regex.lastIndex+=i.length,t.regex.lastIndex-=o[0].length):t.regex.lastIndex=0,a++,a>=this.maxReplaces)break}}),e}nest(e,t,n={}){let r,o,i;const a=(e,t)=>{const n=this.nestingOptionsSeparator;if(e.indexOf(n)<0)return e;const r=e.split(new RegExp(`${n}[ ]*{`));let o=`{${r[1]}`;e=r[0],o=this.interpolate(o,i);const a=o.match(/'/g),s=o.match(/"/g);((a?.length??0)%2==0&&!s||s.length%2!=0)&&(o=o.replace(/'/g,'"'));try{i=JSON.parse(o),t&&(i={...t,...i})}catch(De){return this.logger.warn(`failed parsing options string in nesting for key ${e}`,De),`${e}${n}${o}`}return i.defaultValue&&i.defaultValue.indexOf(this.prefix)>-1&&delete i.defaultValue,e};for(;r=this.nestingRegexp.exec(e);){let s=[];i={...n},i=i.replace&&!qc(i.replace)?i.replace:i,i.applyPostProcessor=!1,delete i.defaultValue;const l=/{.*}/.test(r[1])?r[1].lastIndexOf("}")+1:r[1].indexOf(this.formatSeparator);if(-1!==l&&(s=r[1].slice(l).split(this.formatSeparator).map(e=>e.trim()).filter(Boolean),r[1]=r[1].slice(0,l)),o=t(a.call(this,r[1].trim(),i),i),o&&r[0]===e&&!qc(o))return o;qc(o)||(o=Kc(o)),o||(this.logger.warn(`missed to resolve ${r[1]} for nesting ${e}`),o=""),s.length&&(o=s.reduce((e,t)=>this.format(e,t,n.lng,{...n,interpolationkey:r[1].trim()}),o.trim())),e=e.replace(r[0],o),this.regexp.lastIndex=0}return e}}const Td=e=>{const t={};return(n,r,o)=>{let i=o;o&&o.interpolationkey&&o.formatParams&&o.formatParams[o.interpolationkey]&&o[o.interpolationkey]&&(i={...i,[o.interpolationkey]:void 0});const a=r+JSON.stringify(i);let s=t[a];return s||(s=e(sd(r),o),t[a]=s),s(n)}},Od=e=>(t,n,r)=>e(sd(n),r)(t);class Nd{constructor(e={}){this.logger=cd.create("formatter"),this.options=e,this.init(e)}init(e,t={interpolation:{}}){this.formatSeparator=t.interpolation.formatSeparator||",";const n=t.cacheInBuiltFormats?Td:Od;this.formats={number:n((e,t)=>{const n=new Intl.NumberFormat(e,{...t});return e=>n.format(e)}),currency:n((e,t)=>{const n=new Intl.NumberFormat(e,{...t,style:"currency"});return e=>n.format(e)}),datetime:n((e,t)=>{const n=new Intl.DateTimeFormat(e,{...t});return e=>n.format(e)}),relativetime:n((e,t)=>{const n=new Intl.RelativeTimeFormat(e,{...t});return e=>n.format(e,t.range||"day")}),list:n((e,t)=>{const n=new Intl.ListFormat(e,{...t});return e=>n.format(e)})}}add(e,t){this.formats[e.toLowerCase().trim()]=t}addCached(e,t){this.formats[e.toLowerCase().trim()]=Td(t)}format(e,t,n,r={}){const o=t.split(this.formatSeparator);if(o.length>1&&o[0].indexOf("(")>1&&o[0].indexOf(")")<0&&o.find(e=>e.indexOf(")")>-1)){const e=o.findIndex(e=>e.indexOf(")")>-1);o[0]=[o[0],...o.splice(1,e)].join(this.formatSeparator)}const i=o.reduce((e,t)=>{const{formatName:o,formatOptions:i}=(e=>{let t=e.toLowerCase().trim();const n={};if(e.indexOf("(")>-1){const r=e.split("(");t=r[0].toLowerCase().trim();const o=r[1].substring(0,r[1].length-1);"currency"===t&&o.indexOf(":")<0?n.currency||(n.currency=o.trim()):"relativetime"===t&&o.indexOf(":")<0?n.range||(n.range=o.trim()):o.split(";").forEach(e=>{if(e){const[t,...r]=e.split(":"),o=r.join(":").trim().replace(/^'+|'+$/g,""),i=t.trim();n[i]||(n[i]=o),"false"===o&&(n[i]=!1),"true"===o&&(n[i]=!0),isNaN(o)||(n[i]=parseInt(o,10))}})}return{formatName:t,formatOptions:n}})(t);if(this.formats[o]){let t=e;try{const a=r?.formatParams?.[r.interpolationkey]||{},s=a.locale||a.lng||r.locale||r.lng||n;t=this.formats[o](e,s,{...i,...r,...a})}catch(a){this.logger.warn(a)}return t}return this.logger.warn(`there was no format function for ${o}`),e},e);return i}}class Pd extends dd{constructor(e,t,n,r={}){super(),this.backend=e,this.store=t,this.services=n,this.languageUtils=n.languageUtils,this.options=r,this.logger=cd.create("backendConnector"),this.waitingReads=[],this.maxParallelReads=r.maxParallelReads||10,this.readingCalls=0,this.maxRetries=r.maxRetries>=0?r.maxRetries:5,this.retryTimeout=r.retryTimeout>=1?r.retryTimeout:350,this.state={},this.queue=[],this.backend?.init?.(n,r.backend,r)}queueLoad(e,t,n,r){const o={},i={},a={},s={};return e.forEach(e=>{let r=!0;t.forEach(t=>{const a=`${e}|${t}`;!n.reload&&this.store.hasResourceBundle(e,t)?this.state[a]=2:this.state[a]<0||(1===this.state[a]?void 0===i[a]&&(i[a]=!0):(this.state[a]=1,r=!1,void 0===i[a]&&(i[a]=!0),void 0===o[a]&&(o[a]=!0),void 0===s[t]&&(s[t]=!0)))}),r||(a[e]=!0)}),(Object.keys(o).length||Object.keys(i).length)&&this.queue.push({pending:i,pendingCount:Object.keys(i).length,loaded:{},errors:[],callback:r}),{toLoad:Object.keys(o),pending:Object.keys(i),toLoadLanguages:Object.keys(a),toLoadNamespaces:Object.keys(s)}}loaded(e,t,n){const r=e.split("|"),o=r[0],i=r[1];t&&this.emit("failedLoading",o,i,t),!t&&n&&this.store.addResourceBundle(o,i,n,void 0,void 0,{skipCopy:!0}),this.state[e]=t?-1:2,t&&n&&(this.state[e]=0);const a={};this.queue.forEach(n=>{((e,t,n)=>{const{obj:r,k:o}=Gc(e,t,Object);r[o]=r[o]||[],r[o].push(n)})(n.loaded,[o],i),((e,t)=>{void 0!==e.pending[t]&&(delete e.pending[t],e.pendingCount--)})(n,e),t&&n.errors.push(t),0!==n.pendingCount||n.done||(Object.keys(n.loaded).forEach(e=>{a[e]||(a[e]={});const t=n.loaded[e];t.length&&t.forEach(t=>{void 0===a[e][t]&&(a[e][t]=!0)})}),n.done=!0,n.errors.length?n.callback(n.errors):n.callback())}),this.emit("loaded",a),this.queue=this.queue.filter(e=>!e.done)}read(e,t,n,r=0,o=this.retryTimeout,i){if(!e.length)return i(null,{});if(this.readingCalls>=this.maxParallelReads)return void this.waitingReads.push({lng:e,ns:t,fcName:n,tried:r,wait:o,callback:i});this.readingCalls++;const a=(a,s)=>{if(this.readingCalls--,this.waitingReads.length>0){const e=this.waitingReads.shift();this.read(e.lng,e.ns,e.fcName,e.tried,e.wait,e.callback)}a&&s&&r<this.maxRetries?setTimeout(()=>{this.read.call(this,e,t,n,r+1,2*o,i)},o):i(a,s)},s=this.backend[n].bind(this.backend);if(2!==s.length)return s(e,t,a);try{const n=s(e,t);n&&"function"==typeof n.then?n.then(e=>a(null,e)).catch(a):a(null,n)}catch(l){a(l)}}prepareLoading(e,t,n={},r){if(!this.backend)return this.logger.warn("No backend was added via i18next.use. Will not load resources."),r&&r();qc(e)&&(e=this.languageUtils.toResolveHierarchy(e)),qc(t)&&(t=[t]);const o=this.queueLoad(e,t,n,r);if(!o.toLoad.length)return o.pending.length||r(),null;o.toLoad.forEach(e=>{this.loadOne(e)})}load(e,t,n){this.prepareLoading(e,t,{},n)}reload(e,t,n){this.prepareLoading(e,t,{reload:!0},n)}loadOne(e,t=""){const n=e.split("|"),r=n[0],o=n[1];this.read(r,o,"read",void 0,void 0,(n,i)=>{n&&this.logger.warn(`${t}loading namespace ${o} for language ${r} failed`,n),!n&&i&&this.logger.log(`${t}loaded namespace ${o} for language ${r}`,i),this.loaded(e,n,i)})}saveMissing(e,t,n,r,o,i={},a=()=>{}){if(!this.services?.utils?.hasLoadedNamespace||this.services?.utils?.hasLoadedNamespace(t)){if(null!=n&&""!==n){if(this.backend?.create){const l={...i,isUpdate:o},u=this.backend.create.bind(this.backend);if(u.length<6)try{let o;o=5===u.length?u(e,t,n,r,l):u(e,t,n,r),o&&"function"==typeof o.then?o.then(e=>a(null,e)).catch(a):a(null,o)}catch(s){a(s)}else u(e,t,n,r,a,l)}e&&e[0]&&this.store.addResource(e[0],t,n,r)}}else this.logger.warn(`did not save key "${n}" as the namespace "${t}" was not yet loaded`,"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")}}const Ld=()=>({debug:!1,initAsync:!0,ns:["translation"],defaultNS:["translation"],fallbackLng:["dev"],fallbackNS:!1,supportedLngs:!1,nonExplicitSupportedLngs:!1,load:"all",preload:!1,simplifyPluralSuffix:!0,keySeparator:".",nsSeparator:":",pluralSeparator:"_",contextSeparator:"_",partialBundledLanguages:!1,saveMissing:!1,updateMissing:!1,saveMissingTo:"fallback",saveMissingPlurals:!0,missingKeyHandler:!1,missingInterpolationHandler:!1,postProcess:!1,postProcessPassResolved:!1,returnNull:!1,returnEmptyString:!0,returnObjects:!1,joinArrays:!1,returnedObjectHandler:!1,parseMissingKeyHandler:!1,appendNamespaceToMissingKey:!1,appendNamespaceToCIMode:!1,overloadTranslationOptionHandler:e=>{let t={};if("object"==typeof e[1]&&(t=e[1]),qc(e[1])&&(t.defaultValue=e[1]),qc(e[2])&&(t.tDescription=e[2]),"object"==typeof e[2]||"object"==typeof e[3]){const n=e[3]||e[2];Object.keys(n).forEach(e=>{t[e]=n[e]})}return t},interpolation:{escapeValue:!0,format:e=>e,prefix:"{{",suffix:"}}",formatSeparator:",",unescapePrefix:"-",nestingPrefix:"$t(",nestingSuffix:")",nestingOptionsSeparator:",",maxReplaces:1e3,skipOnVariables:!0},cacheInBuiltFormats:!0}),Rd=e=>(qc(e.ns)&&(e.ns=[e.ns]),qc(e.fallbackLng)&&(e.fallbackLng=[e.fallbackLng]),qc(e.fallbackNS)&&(e.fallbackNS=[e.fallbackNS]),e.supportedLngs?.indexOf?.("cimode")<0&&(e.supportedLngs=e.supportedLngs.concat(["cimode"])),"boolean"==typeof e.initImmediate&&(e.initAsync=e.initImmediate),e),_d=()=>{};class Id extends dd{constructor(e={},t){var n;if(super(),this.options=Rd(e),this.services={},this.logger=cd,this.modules={external:[]},n=this,Object.getOwnPropertyNames(Object.getPrototypeOf(n)).forEach(e=>{"function"==typeof n[e]&&(n[e]=n[e].bind(n))}),t&&!this.isInitialized&&!e.isClone){if(!this.options.initAsync)return this.init(e,t),this;setTimeout(()=>{this.init(e,t)},0)}}init(e={},t){this.isInitializing=!0,"function"==typeof e&&(t=e,e={}),null==e.defaultNS&&e.ns&&(qc(e.ns)?e.defaultNS=e.ns:e.ns.indexOf("translation")<0&&(e.defaultNS=e.ns[0]));const n=Ld();this.options={...n,...this.options,...Rd(e)},this.options.interpolation={...n.interpolation,...this.options.interpolation},void 0!==e.keySeparator&&(this.options.userDefinedKeySeparator=e.keySeparator),void 0!==e.nsSeparator&&(this.options.userDefinedNsSeparator=e.nsSeparator);const r=e=>e?"function"==typeof e?new e:e:null;if(!this.options.isClone){let e;this.modules.logger?cd.init(r(this.modules.logger),this.options):cd.init(null,this.options),e=this.modules.formatter?this.modules.formatter:Nd;const t=new bd(this.options);this.store=new fd(this.options.resources,this.options);const o=this.services;o.logger=cd,o.resourceStore=this.store,o.languageUtils=t,o.pluralResolver=new wd(t,{prepend:this.options.pluralSeparator,simplifyPluralSuffix:this.options.simplifyPluralSuffix});this.options.interpolation.format&&this.options.interpolation.format!==n.interpolation.format&&this.logger.deprecate("init: you are still using the legacy format function, please use the new approach: https://www.i18next.com/translation-function/formatting"),!e||this.options.interpolation.format&&this.options.interpolation.format!==n.interpolation.format||(o.formatter=r(e),o.formatter.init&&o.formatter.init(o,this.options),this.options.interpolation.format=o.formatter.format.bind(o.formatter)),o.interpolator=new Cd(this.options),o.utils={hasLoadedNamespace:this.hasLoadedNamespace.bind(this)},o.backendConnector=new Pd(r(this.modules.backend),o.resourceStore,o,this.options),o.backendConnector.on("*",(e,...t)=>{this.emit(e,...t)}),this.modules.languageDetector&&(o.languageDetector=r(this.modules.languageDetector),o.languageDetector.init&&o.languageDetector.init(o,this.options.detection,this.options)),this.modules.i18nFormat&&(o.i18nFormat=r(this.modules.i18nFormat),o.i18nFormat.init&&o.i18nFormat.init(this)),this.translator=new vd(this.services,this.options),this.translator.on("*",(e,...t)=>{this.emit(e,...t)}),this.modules.external.forEach(e=>{e.init&&e.init(this)})}if(this.format=this.options.interpolation.format,t||(t=_d),this.options.fallbackLng&&!this.services.languageDetector&&!this.options.lng){const e=this.services.languageUtils.getFallbackCodes(this.options.fallbackLng);e.length>0&&"dev"!==e[0]&&(this.options.lng=e[0])}this.services.languageDetector||this.options.lng||this.logger.warn("init: no languageDetector is used and no lng is defined");["getResource","hasResourceBundle","getResourceBundle","getDataByLanguage"].forEach(e=>{this[e]=(...t)=>this.store[e](...t)});["addResource","addResources","addResourceBundle","removeResourceBundle"].forEach(e=>{this[e]=(...t)=>(this.store[e](...t),this)});const o=Wc(),i=()=>{const e=(e,n)=>{this.isInitializing=!1,this.isInitialized&&!this.initializedStoreOnce&&this.logger.warn("init: i18next is already initialized. You should call init just once!"),this.isInitialized=!0,this.options.isClone||this.logger.log("initialized",this.options),this.emit("initialized",this.options),o.resolve(n),t(e,n)};if(this.languages&&!this.isInitialized)return e(null,this.t.bind(this));this.changeLanguage(this.options.lng,e)};return this.options.resources||!this.options.initAsync?i():setTimeout(i,0),o}loadResources(e,t=_d){let n=t;const r=qc(e)?e:this.language;if("function"==typeof e&&(n=e),!this.options.resources||this.options.partialBundledLanguages){if("cimode"===r?.toLowerCase()&&(!this.options.preload||0===this.options.preload.length))return n();const e=[],t=t=>{if(!t)return;if("cimode"===t)return;this.services.languageUtils.toResolveHierarchy(t).forEach(t=>{"cimode"!==t&&e.indexOf(t)<0&&e.push(t)})};if(r)t(r);else{this.services.languageUtils.getFallbackCodes(this.options.fallbackLng).forEach(e=>t(e))}this.options.preload?.forEach?.(e=>t(e)),this.services.backendConnector.load(e,this.options.ns,e=>{e||this.resolvedLanguage||!this.language||this.setResolvedLanguage(this.language),n(e)})}else n(null)}reloadResources(e,t,n){const r=Wc();return"function"==typeof e&&(n=e,e=void 0),"function"==typeof t&&(n=t,t=void 0),e||(e=this.languages),t||(t=this.options.ns),n||(n=_d),this.services.backendConnector.reload(e,t,e=>{r.resolve(),n(e)}),r}use(e){if(!e)throw new Error("You are passing an undefined module! Please check the object you are passing to i18next.use()");if(!e.type)throw new Error("You are passing a wrong module! Please check the object you are passing to i18next.use()");return"backend"===e.type&&(this.modules.backend=e),("logger"===e.type||e.log&&e.warn&&e.error)&&(this.modules.logger=e),"languageDetector"===e.type&&(this.modules.languageDetector=e),"i18nFormat"===e.type&&(this.modules.i18nFormat=e),"postProcessor"===e.type&&pd.addPostProcessor(e),"formatter"===e.type&&(this.modules.formatter=e),"3rdParty"===e.type&&this.modules.external.push(e),this}setResolvedLanguage(e){if(e&&this.languages&&!(["cimode","dev"].indexOf(e)>-1)){for(let e=0;e<this.languages.length;e++){const t=this.languages[e];if(!(["cimode","dev"].indexOf(t)>-1)&&this.store.hasLanguageSomeTranslations(t)){this.resolvedLanguage=t;break}}!this.resolvedLanguage&&this.languages.indexOf(e)<0&&this.store.hasLanguageSomeTranslations(e)&&(this.resolvedLanguage=e,this.languages.unshift(e))}}changeLanguage(e,t){this.isLanguageChangingTo=e;const n=Wc();this.emit("languageChanging",e);const r=e=>{this.language=e,this.languages=this.services.languageUtils.toResolveHierarchy(e),this.resolvedLanguage=void 0,this.setResolvedLanguage(e)},o=(o,i)=>{i?this.isLanguageChangingTo===e&&(r(i),this.translator.changeLanguage(i),this.isLanguageChangingTo=void 0,this.emit("languageChanged",i),this.logger.log("languageChanged",i)):this.isLanguageChangingTo=void 0,n.resolve((...e)=>this.t(...e)),t&&t(o,(...e)=>this.t(...e))},i=t=>{e||t||!this.services.languageDetector||(t=[]);const n=qc(t)?t:t&&t[0],i=this.store.hasLanguageSomeTranslations(n)?n:this.services.languageUtils.getBestMatchFromCodes(qc(t)?[t]:t);i&&(this.language||r(i),this.translator.language||this.translator.changeLanguage(i),this.services.languageDetector?.cacheUserLanguage?.(i)),this.loadResources(i,e=>{o(e,i)})};return e||!this.services.languageDetector||this.services.languageDetector.async?!e&&this.services.languageDetector&&this.services.languageDetector.async?0===this.services.languageDetector.detect.length?this.services.languageDetector.detect().then(i):this.services.languageDetector.detect(i):i(e):i(this.services.languageDetector.detect()),n}getFixedT(e,t,n){const r=(e,t,...o)=>{let i;i="object"!=typeof t?this.options.overloadTranslationOptionHandler([e,t].concat(o)):{...t},i.lng=i.lng||r.lng,i.lngs=i.lngs||r.lngs,i.ns=i.ns||r.ns,""!==i.keyPrefix&&(i.keyPrefix=i.keyPrefix||n||r.keyPrefix);const a=this.options.keySeparator||".";let s;return i.keyPrefix&&Array.isArray(e)?s=e.map(e=>("function"==typeof e&&(e=gd(e,{...this.options,...t})),`${i.keyPrefix}${a}${e}`)):("function"==typeof e&&(e=gd(e,{...this.options,...t})),s=i.keyPrefix?`${i.keyPrefix}${a}${e}`:e),this.t(s,i)};return qc(e)?r.lng=e:r.lngs=e,r.ns=t,r.keyPrefix=n,r}t(...e){return this.translator?.translate(...e)}exists(...e){return this.translator?.exists(...e)}setDefaultNamespace(e){this.options.defaultNS=e}hasLoadedNamespace(e,t={}){if(!this.isInitialized)return this.logger.warn("hasLoadedNamespace: i18next was not initialized",this.languages),!1;if(!this.languages||!this.languages.length)return this.logger.warn("hasLoadedNamespace: i18n.languages were undefined or empty",this.languages),!1;const n=t.lng||this.resolvedLanguage||this.languages[0],r=!!this.options&&this.options.fallbackLng,o=this.languages[this.languages.length-1];if("cimode"===n.toLowerCase())return!0;const i=(e,t)=>{const n=this.services.backendConnector.state[`${e}|${t}`];return-1===n||0===n||2===n};if(t.precheck){const e=t.precheck(this,i);if(void 0!==e)return e}return!!this.hasResourceBundle(n,e)||(!(this.services.backendConnector.backend&&(!this.options.resources||this.options.partialBundledLanguages))||!(!i(n,e)||r&&!i(o,e)))}loadNamespaces(e,t){const n=Wc();return this.options.ns?(qc(e)&&(e=[e]),e.forEach(e=>{this.options.ns.indexOf(e)<0&&this.options.ns.push(e)}),this.loadResources(e=>{n.resolve(),t&&t(e)}),n):(t&&t(),Promise.resolve())}loadLanguages(e,t){const n=Wc();qc(e)&&(e=[e]);const r=this.options.preload||[],o=e.filter(e=>r.indexOf(e)<0&&this.services.languageUtils.isSupportedCode(e));return o.length?(this.options.preload=r.concat(o),this.loadResources(e=>{n.resolve(),t&&t(e)}),n):(t&&t(),Promise.resolve())}dir(e){if(e||(e=this.resolvedLanguage||(this.languages?.length>0?this.languages[0]:this.language)),!e)return"rtl";try{const t=new Intl.Locale(e);if(t&&t.getTextInfo){const e=t.getTextInfo();if(e&&e.direction)return e.direction}}catch(De){}const t=this.services?.languageUtils||new bd(Ld());return e.toLowerCase().indexOf("-latn")>1?"ltr":["ar","shu","sqr","ssh","xaa","yhd","yud","aao","abh","abv","acm","acq","acw","acx","acy","adf","ads","aeb","aec","afb","ajp","apc","apd","arb","arq","ars","ary","arz","auz","avl","ayh","ayl","ayn","ayp","bbz","pga","he","iw","ps","pbt","pbu","pst","prp","prd","ug","ur","ydd","yds","yih","ji","yi","hbo","men","xmn","fa","jpr","peo","pes","prs","dv","sam","ckb"].indexOf(t.getLanguagePartFromCode(e))>-1||e.toLowerCase().indexOf("-arab")>1?"rtl":"ltr"}static createInstance(e={},t){return new Id(e,t)}cloneInstance(e={},t=_d){const n=e.forkResourceStore;n&&delete e.forkResourceStore;const r={...this.options,...e,isClone:!0},o=new Id(r);void 0===e.debug&&void 0===e.prefix||(o.logger=o.logger.clone(e));if(["store","services","language"].forEach(e=>{o[e]=this[e]}),o.services={...this.services},o.services.utils={hasLoadedNamespace:o.hasLoadedNamespace.bind(o)},n){const e=Object.keys(this.store.data).reduce((e,t)=>(e[t]={...this.store.data[t]},e[t]=Object.keys(e[t]).reduce((n,r)=>(n[r]={...e[t][r]},n),e[t]),e),{});o.store=new fd(e,r),o.services.resourceStore=o.store}return o.translator=new vd(o.services,r),o.translator.on("*",(e,...t)=>{o.emit(e,...t)}),o.init(r,t),o.translator.options=r,o.translator.backendConnector.services.utils={hasLoadedNamespace:o.hasLoadedNamespace.bind(o)},o}toJSON(){return{options:this.options,store:this.store,language:this.language,languages:this.languages,resolvedLanguage:this.resolvedLanguage}}}const Ad=Id.createInstance();Ad.createInstance=Id.createInstance,Ad.createInstance,Ad.dir,Ad.init,Ad.loadResources,Ad.reloadResources,Ad.use,Ad.changeLanguage,Ad.getFixedT,Ad.t,Ad.exists,Ad.setDefaultNamespace,Ad.hasLoadedNamespace,Ad.loadNamespaces,Ad.loadLanguages;const{slice:Dd,forEach:zd}=[];const jd=/^[\u0009\u0020-\u007e\u0080-\u00ff]+$/,Fd={create(e,t,n,r){let o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{path:"/",sameSite:"strict"};n&&(o.expires=new Date,o.expires.setTime(o.expires.getTime()+60*n*1e3)),r&&(o.domain=r),document.cookie=function(e,t){const n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{path:"/"};let r=`${e}=${encodeURIComponent(t)}`;if(n.maxAge>0){const e=n.maxAge-0;if(Number.isNaN(e))throw new Error("maxAge should be a Number");r+=`; Max-Age=${Math.floor(e)}`}if(n.domain){if(!jd.test(n.domain))throw new TypeError("option domain is invalid");r+=`; Domain=${n.domain}`}if(n.path){if(!jd.test(n.path))throw new TypeError("option path is invalid");r+=`; Path=${n.path}`}if(n.expires){if("function"!=typeof n.expires.toUTCString)throw new TypeError("option expires is invalid");r+=`; Expires=${n.expires.toUTCString()}`}if(n.httpOnly&&(r+="; HttpOnly"),n.secure&&(r+="; Secure"),n.sameSite)switch("string"==typeof n.sameSite?n.sameSite.toLowerCase():n.sameSite){case!0:r+="; SameSite=Strict";break;case"lax":r+="; SameSite=Lax";break;case"strict":r+="; SameSite=Strict";break;case"none":r+="; SameSite=None";break;default:throw new TypeError("option sameSite is invalid")}return n.partitioned&&(r+="; Partitioned"),r}(e,t,o)},read(e){const t=`${e}=`,n=document.cookie.split(";");for(let r=0;r<n.length;r++){let e=n[r];for(;" "===e.charAt(0);)e=e.substring(1,e.length);if(0===e.indexOf(t))return e.substring(t.length,e.length)}return null},remove(e,t){this.create(e,"",-1,t)}};var Md={name:"cookie",lookup(e){let{lookupCookie:t}=e;if(t&&"undefined"!=typeof document)return Fd.read(t)||void 0},cacheUserLanguage(e,t){let{lookupCookie:n,cookieMinutes:r,cookieDomain:o,cookieOptions:i}=t;n&&"undefined"!=typeof document&&Fd.create(n,e,r,o,i)}},Ud={name:"querystring",lookup(e){let t,{lookupQuerystring:n}=e;if("undefined"!=typeof window){let{search:e}=window.location;!window.location.search&&window.location.hash?.indexOf("?")>-1&&(e=window.location.hash.substring(window.location.hash.indexOf("?")));const r=e.substring(1).split("&");for(let o=0;o<r.length;o++){const e=r[o].indexOf("=");if(e>0){r[o].substring(0,e)===n&&(t=r[o].substring(e+1))}}}return t}},Bd={name:"hash",lookup(e){let t,{lookupHash:n,lookupFromHashIndex:r}=e;if("undefined"!=typeof window){const{hash:e}=window.location;if(e&&e.length>2){const o=e.substring(1);if(n){const e=o.split("&");for(let r=0;r<e.length;r++){const o=e[r].indexOf("=");if(o>0){e[r].substring(0,o)===n&&(t=e[r].substring(o+1))}}}if(t)return t;if(!t&&r>-1){const t=e.match(/\/([a-zA-Z-]*)/g);if(!Array.isArray(t))return;const n="number"==typeof r?r:0;return t[n]?.replace("/","")}}}return t}};let $d=null;const Vd=()=>{if(null!==$d)return $d;try{if($d="undefined"!=typeof window&&null!==window.localStorage,!$d)return!1;const e="i18next.translate.boo";window.localStorage.setItem(e,"foo"),window.localStorage.removeItem(e)}catch(De){$d=!1}return $d};var Hd={name:"localStorage",lookup(e){let{lookupLocalStorage:t}=e;if(t&&Vd())return window.localStorage.getItem(t)||void 0},cacheUserLanguage(e,t){let{lookupLocalStorage:n}=t;n&&Vd()&&window.localStorage.setItem(n,e)}};let qd=null;const Wd=()=>{if(null!==qd)return qd;try{if(qd="undefined"!=typeof window&&null!==window.sessionStorage,!qd)return!1;const e="i18next.translate.boo";window.sessionStorage.setItem(e,"foo"),window.sessionStorage.removeItem(e)}catch(De){qd=!1}return qd};var Kd={name:"sessionStorage",lookup(e){let{lookupSessionStorage:t}=e;if(t&&Wd())return window.sessionStorage.getItem(t)||void 0},cacheUserLanguage(e,t){let{lookupSessionStorage:n}=t;n&&Wd()&&window.sessionStorage.setItem(n,e)}},Qd={name:"navigator",lookup(e){const t=[];if("undefined"!=typeof navigator){const{languages:e,userLanguage:n,language:r}=navigator;if(e)for(let o=0;o<e.length;o++)t.push(e[o]);n&&t.push(n),r&&t.push(r)}return t.length>0?t:void 0}},Jd={name:"htmlTag",lookup(e){let t,{htmlTag:n}=e;const r=n||("undefined"!=typeof document?document.documentElement:null);return r&&"function"==typeof r.getAttribute&&(t=r.getAttribute("lang")),t}},Yd={name:"path",lookup(e){let{lookupFromPathIndex:t}=e;if("undefined"==typeof window)return;const n=window.location.pathname.match(/\/([a-zA-Z-]*)/g);if(!Array.isArray(n))return;const r="number"==typeof t?t:0;return n[r]?.replace("/","")}},Gd={name:"subdomain",lookup(e){let{lookupFromSubdomainIndex:t}=e;const n="number"==typeof t?t+1:1,r="undefined"!=typeof window&&window.location?.hostname?.match(/^(\w{2,5})\.(([a-z0-9-]{1,63}\.[a-z]{2,6})|localhost)/i);if(r)return r[n]}};let Xd=!1;try{document.cookie,Xd=!0}catch(De){}const Zd=["querystring","cookie","localStorage","sessionStorage","navigator","htmlTag"];Xd||Zd.splice(1,1);class ef{constructor(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.type="languageDetector",this.detectors={},this.init(e,t)}init(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{languageUtils:{}},t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};this.services=e,this.options=function(e){return zd.call(Dd.call(arguments,1),t=>{if(t)for(const n in t)void 0===e[n]&&(e[n]=t[n])}),e}(t,this.options||{},{order:Zd,lookupQuerystring:"lng",lookupCookie:"i18next",lookupLocalStorage:"i18nextLng",lookupSessionStorage:"i18nextLng",caches:["localStorage"],excludeCacheFor:["cimode"],convertDetectedLanguage:e=>e}),"string"==typeof this.options.convertDetectedLanguage&&this.options.convertDetectedLanguage.indexOf("15897")>-1&&(this.options.convertDetectedLanguage=e=>e.replace("-","_")),this.options.lookupFromUrlIndex&&(this.options.lookupFromPathIndex=this.options.lookupFromUrlIndex),this.i18nOptions=n,this.addDetector(Md),this.addDetector(Ud),this.addDetector(Hd),this.addDetector(Kd),this.addDetector(Qd),this.addDetector(Jd),this.addDetector(Yd),this.addDetector(Gd),this.addDetector(Bd)}addDetector(e){return this.detectors[e.name]=e,this}detect(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.options.order,t=[];return e.forEach(e=>{if(this.detectors[e]){let n=this.detectors[e].lookup(this.options);n&&"string"==typeof n&&(n=[n]),n&&(t=t.concat(n))}}),t=t.filter(e=>{return null!=e&&!("string"==typeof(t=e)&&[/<\s*script.*?>/i,/<\s*\/\s*script\s*>/i,/<\s*img.*?on\w+\s*=/i,/<\s*\w+\s*on\w+\s*=.*?>/i,/javascript\s*:/i,/vbscript\s*:/i,/expression\s*\(/i,/eval\s*\(/i,/alert\s*\(/i,/document\.cookie/i,/document\.write\s*\(/i,/window\.location/i,/innerHTML/i].some(e=>e.test(t)));var t}).map(e=>this.options.convertDetectedLanguage(e)),this.services&&this.services.languageUtils&&this.services.languageUtils.getBestMatchFromCodes?t:t.length>0?t[0]:null}cacheUserLanguage(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.options.caches;t&&(this.options.excludeCacheFor&&this.options.excludeCacheFor.indexOf(e)>-1||t.forEach(t=>{this.detectors[t]&&this.detectors[t].cacheUserLanguage(e,this.options)}))}}ef.type="languageDetector";const tf={widget:{title:"TIA GPC",poweredBy:"Desarrollado por TIA GPC",questionsTo:"Preguntas a"},chat:{title:"Asistente",placeholder:"Escribe tu pregunta...",send:"Enviar",close:"Cerrar",welcome:"¡Hola! Bienvenido a {{companyName}}. ¿En qué puedo ayudarte hoy?",emptyState:"Inicia una conversación escribiendo tu pregunta",validation:"Verificando seguridad...",retry:"Reintentar"},voice:{record:"Grabar audio",recording:"Grabando...",stop:"Detener grabación",processing:"Transcribiendo audio...",error:"Error al transcribir audio",unsupported:"Tu navegador no soporta grabación de audio",permissionDenied:"Permiso de micrófono denegado"},theme:{light:"Claro",dark:"Oscuro",toggle:"Cambiar tema"},errors:{unauthorized:"Autenticación fallida. Por favor, verifica tu token de licencia e intenta nuevamente.",validation:"Verificación anti-bot fallida. Por favor, recarga la página e intenta nuevamente.",network:"No se pudo conectar al servidor. Verifica tu conexión a internet.",rateLimit:"Has realizado demasiadas consultas o se alcanzó el límite de usuarios concurrentes. Por favor, espera un momento antes de continuar.",session:"Tu sesión ha expirado por inactividad. Por favor, recarga la página para continuar.",insufficientCredits:"Créditos insuficientes. Por favor, recarga créditos desde tu panel de administración para continuar usando TIA GPC.",generic:"Ha ocurrido un error inesperado. Por favor, intenta nuevamente.",aiServiceUnavailable:"El asistente está temporalmente no disponible. Por favor, intenta de nuevo en unos momentos.",serverError:"El servidor encontró un problema. Por favor, intenta de nuevo más tarde.",domainUnauthorized:"Este dominio no está autorizado para usar este widget. Por favor, contacta a tu administrador."},turnstile:{verifying:"Verificando que eres humano...",error:"No se pudo completar la verificación de seguridad. Por favor, recarga la página e intenta nuevamente."},metadata:{tokensUsed:"Tokens usados",responseTime:"Tiempo de respuesta",model:"Modelo"}},nf={widget:{title:"TIA GPC",poweredBy:"Powered by TIA GPC",questionsTo:"Questions to"},chat:{title:"Assistant",placeholder:"Type your question...",send:"Send",close:"Close",welcome:"Hello! Welcome to {{companyName}}. How can I help you today?",emptyState:"Start a conversation by typing your question",validation:"Verifying security...",retry:"Retry"},voice:{record:"Record audio",recording:"Recording...",stop:"Stop recording",processing:"Transcribing audio...",error:"Error transcribing audio",unsupported:"Your browser does not support audio recording",permissionDenied:"Microphone permission denied"},theme:{light:"Light",dark:"Dark",toggle:"Toggle theme"},errors:{unauthorized:"Authentication failed. Please check your license token and try again.",validation:"Bot verification failed. Please reload the page and try again.",network:"Unable to connect to the server. Please check your internet connection.",rateLimit:"You've made too many requests or the concurrent user limit has been reached. Please wait a moment before continuing.",session:"Your session has expired due to inactivity. Please reload the page to continue.",insufficientCredits:"Insufficient credits. Please reload credits from your admin panel to continue using TIA GPC.",generic:"An unexpected error has occurred. Please try again.",aiServiceUnavailable:"The assistant is temporarily unavailable. Please try again in a few moments.",serverError:"The server encountered a problem. Please try again later.",domainUnauthorized:"This domain is not authorized to use this widget. Please contact your administrator."},turnstile:{verifying:"Verifying you're human...",error:"Security verification could not be completed. Please reload the page and try again."},metadata:{tokensUsed:"Tokens used",responseTime:"Response time",model:"Model"}},rf={widget:{title:"TIA GPC",poweredBy:"Propulsé par TIA GPC",questionsTo:"Questions à"},chat:{title:"Assistant",placeholder:"Tapez votre question...",send:"Envoyer",close:"Fermer",welcome:"Bonjour ! Bienvenue à {{companyName}}. Comment puis-je vous aider aujourd'hui ?",emptyState:"Commencez une conversation en tapant votre question",validation:"Vérification de sécurité...",retry:"Réessayer"},voice:{record:"Enregistrer audio",recording:"Enregistrement...",stop:"Arrêter l'enregistrement",processing:"Transcription audio...",error:"Erreur de transcription audio",unsupported:"Votre navigateur ne prend pas en charge l'enregistrement audio",permissionDenied:"Permission du microphone refusée"},theme:{light:"Clair",dark:"Sombre",toggle:"Changer de thème"},errors:{unauthorized:"Échec de l'authentification. Veuillez vérifier votre jeton de licence et réessayer.",validation:"La vérification anti-bot a échoué. Veuillez recharger la page et réessayer.",network:"Impossible de se connecter au serveur. Veuillez vérifier votre connexion internet.",rateLimit:"Vous avez fait trop de demandes ou la limite d'utilisateurs concurrents a été atteinte. Veuillez patienter un moment avant de continuer.",session:"Votre session a expiré en raison d'inactivité. Veuillez recharger la page pour continuer.",insufficientCredits:"Crédits insuffisants. Veuillez recharger des crédits depuis votre panneau d'administration pour continuer à utiliser TIA GPC.",generic:"Une erreur inattendue s'est produite. Veuillez réessayer.",aiServiceUnavailable:"L'assistant est temporairement indisponible. Veuillez réessayer dans quelques instants.",serverError:"Le serveur a rencontré un problème. Veuillez réessayer plus tard.",domainUnauthorized:"Ce domaine n'est pas autorisé à utiliser ce widget. Veuillez contacter votre administrateur."},turnstile:{verifying:"Vérification que vous êtes humain...",error:"La vérification de sécurité n'a pas pu être complétée. Veuillez recharger la page et réessayer."},metadata:{tokensUsed:"Tokens utilisés",responseTime:"Temps de réponse",model:"Modèle"}};Ad.use(ef).use(M).init({resources:{en:{translation:nf},es:{translation:tf},fr:{translation:rf}},fallbackLng:"en",supportedLngs:["en","es","fr"],interpolation:{escapeValue:!1},detection:{order:["localStorage","navigator"],caches:["localStorage"]}});const of=({token:e,turnstileSiteKey:t="0x4AAAAAAB-BKyDZcYYqCbid",theme:n=Ws,position:r=Ks,language:o=Qs,primaryColor:i,width:a=Js,height:s=Ys,apiUrl:u=Bs,onReady:c,onError:d,onClose:f,autoOpen:p=Gs,showBranding:h=Xs,mobileFullscreen:g=Zs,...m})=>{const[y,v]=l.useState(p),[b,k]=l.useState(!1),[x,w]=l.useState(null),[S,E]=l.useState(!0),C=l.useMemo(()=>new Hc(u,e),[u,e]);if(l.useEffect(()=>{const e=()=>{k(window.innerWidth<qs)};return e(),window.addEventListener("resize",e),()=>window.removeEventListener("resize",e)},[]),l.useEffect(()=>{o&&Ad.changeLanguage&&Ad.changeLanguage(o)},[o]),l.useEffect(()=>{(async()=>{if(e)try{const e=await C.getInitConfig();e.success&&(w(e.data),c&&c(e.data))}catch(t){d&&d(t)}finally{E(!1)}else E(!1)})()},[e,C,c,d]),!e)return null;return O.jsx(H,{i18n:Ad,children:O.jsxs("div",{className:`gpc-widget gpc-widget-container ${b&&g?"gpc-position-bottom-right":`gpc-position-${r}`} ${"dark"===n?"gpc-dark":""}`,style:(()=>{const e={};return i&&(e["--gpc-color-primary"]=i),b&&g||(a&&(e["--gpc-widget-width"]=a),s&&(e["--gpc-widget-height"]=s)),e})(),children:[!y&&O.jsx(se,{onClick:()=>v(!0),widgetConfig:x}),y&&!S&&O.jsx(wl,{gpcService:C,licenseToken:e,widgetConfig:x,turnstileSiteKey:t,onClose:()=>{v(!1),f?.()},themeMode:n,showBranding:h,showMetadata:m.showMetadata||!1,onError:d})]})})};of.defaultProps={theme:"auto",position:"bottom-right",language:"en",width:"400px",height:"600px",autoOpen:!1,showBranding:!0,mobileFullscreen:!0};class af extends HTMLElement{constructor(){super(),this.root=null,this.mountPoint=null}static get observedAttributes(){return["token","theme","position","language","primary-color","width","height","api-url","turnstile-site-key","auto-open","show-branding","mobile-fullscreen"]}connectedCallback(){this.mountPoint=document.createElement("div"),this.mountPoint.className="tia-gpc-mount",this.appendChild(this.mountPoint),this.root=E.createRoot(this.mountPoint),this.render()}disconnectedCallback(){this.root&&(this.root.unmount(),this.root=null)}attributeChangedCallback(e,t,n){t!==n&&this.root&&this.render()}getProps(){const e={},t=this.getAttribute("token");t&&(e.token=t);const n=this.getAttribute("theme");n&&(e.theme=n);const r=this.getAttribute("position");r&&(e.position=r);const o=this.getAttribute("language");o&&(e.language=o);const i=this.getAttribute("primary-color");i&&(e.primaryColor=i);const a=this.getAttribute("width");a&&(e.width=a);const s=this.getAttribute("height");s&&(e.height=s);const l=this.getAttribute("api-url");l&&(e.apiUrl=l);const u=this.getAttribute("turnstile-site-key");u&&(e.turnstileSiteKey=u);const c=this.getAttribute("auto-open");null!==c&&(e.autoOpen="false"!==c);const d=this.getAttribute("show-branding");null!==d&&(e.showBranding="false"!==d);const f=this.getAttribute("mobile-fullscreen");return null!==f&&(e.mobileFullscreen="false"!==f),e.onReady=()=>{this.dispatchEvent(new CustomEvent("ready",{bubbles:!0,composed:!0}))},e.onError=e=>{this.dispatchEvent(new CustomEvent("error",{bubbles:!0,composed:!0,detail:e}))},e.onClose=()=>{this.dispatchEvent(new CustomEvent("close",{bubbles:!0,composed:!0}))},e}render(){if(!this.root)return;const e=this.getProps();this.root.render(u.createElement(of,e))}open(){this.dispatchEvent(new CustomEvent("open-widget",{bubbles:!0,composed:!0}))}close(){this.dispatchEvent(new CustomEvent("close-widget",{bubbles:!0,composed:!0}))}}"undefined"==typeof window||customElements.get("tia-gpc-widget")||customElements.define("tia-gpc-widget",af),window.TiaGPC={version:"1.0.0",POSITIONS:$s,THEMES:Vs,LANGUAGES:Hs,create(e){if(!e||!e.token)throw new Error('TiaGPC.create(): El parámetro "token" es requerido');const t=document.createElement("tia-gpc-widget");t.setAttribute("token",e.token),e.theme&&t.setAttribute("theme",e.theme),e.position&&t.setAttribute("position",e.position),e.language&&t.setAttribute("language",e.language),e.primaryColor&&t.setAttribute("primary-color",e.primaryColor),e.width&&t.setAttribute("width",e.width),e.height&&t.setAttribute("height",e.height),e.apiUrl&&t.setAttribute("api-url",e.apiUrl),e.turnstileSiteKey&&t.setAttribute("turnstile-site-key",e.turnstileSiteKey),void 0!==e.autoOpen&&t.setAttribute("auto-open",String(e.autoOpen)),void 0!==e.showBranding&&t.setAttribute("show-branding",String(e.showBranding)),void 0!==e.mobileFullscreen&&t.setAttribute("mobile-fullscreen",String(e.mobileFullscreen)),e.onReady&&t.addEventListener("ready",e.onReady),e.onError&&t.addEventListener("error",t=>e.onError(t.detail)),e.onClose&&t.addEventListener("close",e.onClose);return(e.container||document.body).appendChild(t),t},info(){return{version:this.version,positions:this.POSITIONS,themes:this.THEMES,languages:this.LANGUAGES}}};const sf=window.TiaGPC;return e.TiaGPCWebComponent=af,e.default=sf,Object.defineProperties(e,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}}),e}({});
206
206
  //# sourceMappingURL=tia-gpc-widget.standalone.js.map