@piedata/pieui 1.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cli.d.ts +3 -0
- package/dist/cli.d.ts.map +1 -0
- package/dist/cli.js +361697 -0
- package/dist/components/Buttons/AjaxButtonCard/index.d.ts +2 -0
- package/dist/components/Buttons/AjaxButtonCard/index.d.ts.map +1 -0
- package/dist/components/Buttons/AjaxButtonCard/types/index.d.ts +15 -0
- package/dist/components/Buttons/AjaxButtonCard/types/index.d.ts.map +1 -0
- package/dist/components/Buttons/AjaxButtonCard/ui/AjaxButtonCard.d.ts +4 -0
- package/dist/components/Buttons/AjaxButtonCard/ui/AjaxButtonCard.d.ts.map +1 -0
- package/dist/components/Chats/ChatCard/index.d.ts +2 -0
- package/dist/components/Chats/ChatCard/index.d.ts.map +1 -0
- package/dist/components/Chats/ChatCard/types/index.d.ts +43 -0
- package/dist/components/Chats/ChatCard/types/index.d.ts.map +1 -0
- package/dist/components/Chats/ChatCard/ui/ChatCard.d.ts +4 -0
- package/dist/components/Chats/ChatCard/ui/ChatCard.d.ts.map +1 -0
- package/dist/components/Chats/ChatCard/ui/components/AttachFileButton.d.ts +11 -0
- package/dist/components/Chats/ChatCard/ui/components/AttachFileButton.d.ts.map +1 -0
- package/dist/components/Chats/ChatCard/ui/components/AttachedFileView.d.ts +7 -0
- package/dist/components/Chats/ChatCard/ui/components/AttachedFileView.d.ts.map +1 -0
- package/dist/components/Chats/ChatCard/ui/components/ChatCardInput.d.ts +22 -0
- package/dist/components/Chats/ChatCard/ui/components/ChatCardInput.d.ts.map +1 -0
- package/dist/components/Chats/ChatCard/ui/components/ChatOption.d.ts +7 -0
- package/dist/components/Chats/ChatCard/ui/components/ChatOption.d.ts.map +1 -0
- package/dist/components/Chats/ChatCard/ui/components/Markdown.d.ts +6 -0
- package/dist/components/Chats/ChatCard/ui/components/Markdown.d.ts.map +1 -0
- package/dist/components/Chats/ChatCard/ui/components/MessageAvatar.d.ts +6 -0
- package/dist/components/Chats/ChatCard/ui/components/MessageAvatar.d.ts.map +1 -0
- package/dist/components/Chats/ChatCard/ui/components/MessageCard.d.ts +9 -0
- package/dist/components/Chats/ChatCard/ui/components/MessageCard.d.ts.map +1 -0
- package/dist/components/Chats/ChatCard/ui/components/MessageContent.d.ts +7 -0
- package/dist/components/Chats/ChatCard/ui/components/MessageContent.d.ts.map +1 -0
- package/dist/components/Chats/ChatCard/ui/components/MessagesBoard.d.ts +17 -0
- package/dist/components/Chats/ChatCard/ui/components/MessagesBoard.d.ts.map +1 -0
- package/dist/components/Chats/ChatCard/ui/components/Options.d.ts +7 -0
- package/dist/components/Chats/ChatCard/ui/components/Options.d.ts.map +1 -0
- package/dist/components/Chats/ChatCard/ui/components/ResizableTextarea.d.ts +3 -0
- package/dist/components/Chats/ChatCard/ui/components/ResizableTextarea.d.ts.map +1 -0
- package/dist/components/Chats/ChatCard/ui/components/SendButton.d.ts +4 -0
- package/dist/components/Chats/ChatCard/ui/components/SendButton.d.ts.map +1 -0
- package/dist/components/Chats/ChatCard/ui/components/VoiceListeningButton.d.ts +8 -0
- package/dist/components/Chats/ChatCard/ui/components/VoiceListeningButton.d.ts.map +1 -0
- package/dist/components/Chats/ChatCard/ui/components/icons/AttachFileIcon.d.ts +3 -0
- package/dist/components/Chats/ChatCard/ui/components/icons/AttachFileIcon.d.ts.map +1 -0
- package/dist/components/Chats/ChatCard/ui/components/icons/AttachedFileIcon.d.ts +3 -0
- package/dist/components/Chats/ChatCard/ui/components/icons/AttachedFileIcon.d.ts.map +1 -0
- package/dist/components/Chats/ChatCard/ui/components/icons/CancelFileIcon.d.ts +3 -0
- package/dist/components/Chats/ChatCard/ui/components/icons/CancelFileIcon.d.ts.map +1 -0
- package/dist/components/Chats/ChatCard/ui/components/icons/DefaultAvatar.d.ts +3 -0
- package/dist/components/Chats/ChatCard/ui/components/icons/DefaultAvatar.d.ts.map +1 -0
- package/dist/components/Chats/ChatCard/ui/components/icons/SendIcon.d.ts +3 -0
- package/dist/components/Chats/ChatCard/ui/components/icons/SendIcon.d.ts.map +1 -0
- package/dist/components/Chats/ChatCard/ui/components/icons/VoiceRecordIcon.d.ts +3 -0
- package/dist/components/Chats/ChatCard/ui/components/icons/VoiceRecordIcon.d.ts.map +1 -0
- package/dist/components/Containers/AjaxGroupCard/index.d.ts +2 -0
- package/dist/components/Containers/AjaxGroupCard/index.d.ts.map +1 -0
- package/dist/components/Containers/AjaxGroupCard/types/index.d.ts +14 -0
- package/dist/components/Containers/AjaxGroupCard/types/index.d.ts.map +1 -0
- package/dist/components/Containers/AjaxGroupCard/ui/AjaxGroupCard.d.ts +5 -0
- package/dist/components/Containers/AjaxGroupCard/ui/AjaxGroupCard.d.ts.map +1 -0
- package/dist/components/Containers/SequenceCard/index.d.ts +2 -0
- package/dist/components/Containers/SequenceCard/index.d.ts.map +1 -0
- package/dist/components/Containers/SequenceCard/types/index.d.ts +9 -0
- package/dist/components/Containers/SequenceCard/types/index.d.ts.map +1 -0
- package/dist/components/Containers/SequenceCard/ui/SequenceCard.d.ts +4 -0
- package/dist/components/Containers/SequenceCard/ui/SequenceCard.d.ts.map +1 -0
- package/dist/components/Containers/UnionCard/index.d.ts +2 -0
- package/dist/components/Containers/UnionCard/index.d.ts.map +1 -0
- package/dist/components/Containers/UnionCard/types/index.d.ts +7 -0
- package/dist/components/Containers/UnionCard/types/index.d.ts.map +1 -0
- package/dist/components/Containers/UnionCard/ui/UnionCard.d.ts +4 -0
- package/dist/components/Containers/UnionCard/ui/UnionCard.d.ts.map +1 -0
- package/dist/components/PieBaseRoot/index.d.ts +5 -0
- package/dist/components/PieBaseRoot/index.d.ts.map +1 -0
- package/dist/components/PieBaseRoot/types/index.d.ts +6 -0
- package/dist/components/PieBaseRoot/types/index.d.ts.map +1 -0
- package/dist/components/PieCard/index.d.ts +4 -0
- package/dist/components/PieCard/index.d.ts.map +1 -0
- package/dist/components/PieCard/types/index.d.ts +16 -0
- package/dist/components/PieCard/types/index.d.ts.map +1 -0
- package/dist/components/PieRoot/index.d.ts +5 -0
- package/dist/components/PieRoot/index.d.ts.map +1 -0
- package/dist/components/PieRoot/types/index.d.ts +10 -0
- package/dist/components/PieRoot/types/index.d.ts.map +1 -0
- package/dist/components/PieStaticRoot/index.d.ts +5 -0
- package/dist/components/PieStaticRoot/index.d.ts.map +1 -0
- package/dist/components/PieStaticRoot/types/index.d.ts +7 -0
- package/dist/components/PieStaticRoot/types/index.d.ts.map +1 -0
- package/dist/components/PieTelegramRoot/index.d.ts +5 -0
- package/dist/components/PieTelegramRoot/index.d.ts.map +1 -0
- package/dist/components/UI/index.d.ts +8 -0
- package/dist/components/UI/index.d.ts.map +1 -0
- package/dist/components/index.d.ts +7 -0
- package/dist/components/index.d.ts.map +1 -0
- package/dist/components/index.esm.js +35 -0
- package/dist/components/index.js +48 -0
- package/dist/config/constant.d.ts +10 -0
- package/dist/config/constant.d.ts.map +1 -0
- package/dist/index.d.ts +10 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.esm.js +40 -0
- package/dist/index.js +65 -0
- package/dist/pieui.components.json +364 -0
- package/dist/providers/CentrifugeIOInitProvider.d.ts +6 -0
- package/dist/providers/CentrifugeIOInitProvider.d.ts.map +1 -0
- package/dist/providers/SocketIOInitProvider.d.ts +6 -0
- package/dist/providers/SocketIOInitProvider.d.ts.map +1 -0
- package/dist/types/index.d.ts +103 -0
- package/dist/types/index.d.ts.map +1 -0
- package/dist/util/ajaxCommonUtils.d.ts +4 -0
- package/dist/util/ajaxCommonUtils.d.ts.map +1 -0
- package/dist/util/axiosWithCache.d.ts +3 -0
- package/dist/util/axiosWithCache.d.ts.map +1 -0
- package/dist/util/centrifuge.d.ts +5 -0
- package/dist/util/centrifuge.d.ts.map +1 -0
- package/dist/util/fallback.d.ts +4 -0
- package/dist/util/fallback.d.ts.map +1 -0
- package/dist/util/globalForm.d.ts +3 -0
- package/dist/util/globalForm.d.ts.map +1 -0
- package/dist/util/initializeComponents.d.ts +18 -0
- package/dist/util/initializeComponents.d.ts.map +1 -0
- package/dist/util/lazy.d.ts +6 -0
- package/dist/util/lazy.d.ts.map +1 -0
- package/dist/util/mitt.d.ts +7 -0
- package/dist/util/mitt.d.ts.map +1 -0
- package/dist/util/queryClient.d.ts +3 -0
- package/dist/util/queryClient.d.ts.map +1 -0
- package/dist/util/registry.d.ts +11 -0
- package/dist/util/registry.d.ts.map +1 -0
- package/dist/util/socket.d.ts +5 -0
- package/dist/util/socket.d.ts.map +1 -0
- package/dist/util/sx2radium.d.ts +3 -0
- package/dist/util/sx2radium.d.ts.map +1 -0
- package/dist/util/tailwindCommonUtils.d.ts +3 -0
- package/dist/util/tailwindCommonUtils.d.ts.map +1 -0
- package/dist/util/useBodyStyles.d.ts +5 -0
- package/dist/util/useBodyStyles.d.ts.map +1 -0
- package/dist/util/useImage.d.ts +5 -0
- package/dist/util/useImage.d.ts.map +1 -0
- package/dist/util/useIsSupported.d.ts +2 -0
- package/dist/util/useIsSupported.d.ts.map +1 -0
- package/dist/util/useOpenAIWebRTC.d.ts +14 -0
- package/dist/util/useOpenAIWebRTC.d.ts.map +1 -0
- package/dist/util/useScreenSize.d.ts +6 -0
- package/dist/util/useScreenSize.d.ts.map +1 -0
- package/dist/util/useTitle.d.ts +2 -0
- package/dist/util/useTitle.d.ts.map +1 -0
- package/dist/util/useWebApp.d.ts +4 -0
- package/dist/util/useWebApp.d.ts.map +1 -0
- package/dist/util/waitForSidAvailable.d.ts +3 -0
- package/dist/util/waitForSidAvailable.d.ts.map +1 -0
- package/dist/util/webrtcClient.d.ts +32 -0
- package/dist/util/webrtcClient.d.ts.map +1 -0
- package/package.json +95 -0
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
var sU=Object.create;var{getPrototypeOf:oU,defineProperty:X6,getOwnPropertyNames:UX,getOwnPropertyDescriptor:tU}=Object,$X=Object.prototype.hasOwnProperty;var r=(Z,J,X)=>{X=Z!=null?sU(oU(Z)):{};let Y=J||!Z||!Z.__esModule?X6(X,"default",{value:Z,enumerable:!0}):X;for(let G of UX(Z))if(!$X.call(Y,G))X6(Y,G,{get:()=>Z[G],enumerable:!0});return Y},KX=new WeakMap,eU=(Z)=>{var J=KX.get(Z),X;if(J)return J;if(J=X6({},"__esModule",{value:!0}),Z&&typeof Z==="object"||typeof Z==="function")UX(Z).map((Y)=>!$X.call(J,Y)&&X6(J,Y,{get:()=>Z[Y],enumerable:!(X=tU(Z,Y))||X.enumerable}));return KX.set(Z,J),J},x=(Z,J)=>()=>(J||Z((J={exports:{}}).exports,J),J.exports);var U9=(Z,J)=>{for(var X in J)X6(Z,X,{get:J[X],enumerable:!0,configurable:!0,set:(Y)=>J[X]=()=>Y})};var LX=(Z,J)=>()=>(Z&&(J=Z(Z=0)),J);var sX=x((vw,rX)=>{var P$="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";rX.exports=P$});var ZY=x((yw,eX)=>{var w$=sX();function oX(){}function tX(){}tX.resetWarningCache=oX;eX.exports=function(){function Z(Y,G,W,H,Q,K){if(K===w$)return;var U=Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw U.name="Invariant Violation",U}Z.isRequired=Z;function J(){return Z}var X={array:Z,bigint:Z,bool:Z,func:Z,number:Z,object:Z,string:Z,symbol:Z,any:Z,arrayOf:J,element:Z,elementType:Z,instanceOf:J,node:Z,objectOf:J,oneOf:J,oneOfType:J,shape:J,exact:J,checkPropTypes:tX,resetWarningCache:oX};return X.PropTypes=X,X}});var S7=x((mw,JY)=>{JY.exports=ZY()();var _$,S$});function f$(Z){if(typeof Z==="object"&&Z!==null){var J=Z.$$typeof;switch(J){case C$:switch(Z=Z.type,Z){case h$:case v$:case j$:case b$:case x$:case y$:return Z;default:switch(Z=Z&&Z.$$typeof,Z){case g$:case XY:case m$:case YY:case k$:return Z;default:return J}}case E$:return J}}}var l1,C$,E$,j$,x$,b$,k$,g$,h$,v$,XY,y$,YY,m$,C7,E7=function(Z){return f$(Z)===YY};var GY=LX(()=>{l1=typeof Symbol==="function"&&Symbol.for,C$=l1?Symbol.for("react.element"):60103,E$=l1?Symbol.for("react.portal"):60106,j$=l1?Symbol.for("react.fragment"):60107,x$=l1?Symbol.for("react.strict_mode"):60108,b$=l1?Symbol.for("react.profiler"):60114,k$=l1?Symbol.for("react.provider"):60109,g$=l1?Symbol.for("react.context"):60110,h$=l1?Symbol.for("react.async_mode"):60111,v$=l1?Symbol.for("react.concurrent_mode"):60111,XY=l1?Symbol.for("react.forward_ref"):60112,y$=l1?Symbol.for("react.suspense"):60113,YY=l1?Symbol.for("react.memo"):60115,m$=l1?Symbol.for("react.lazy"):60116;C7=XY});var j7=x((fw,$Y)=>{GY();var p$={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},l$={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},d$={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},c$={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},KY={};KY[C7]=d$;function WY(Z){if(E7(Z))return c$;return KY[Z.$$typeof]||p$}var{defineProperty:i$,getOwnPropertyNames:n$,getOwnPropertySymbols:HY,getOwnPropertyDescriptor:a$,getPrototypeOf:r$,prototype:QY}=Object;function UY(Z,J,X){if(typeof J!=="string"){if(QY){var Y=r$(J);if(Y&&Y!==QY)UY(Z,Y,X)}var G=n$(J);if(HY)G=G.concat(HY(J));var W=WY(Z),H=WY(J);for(var Q=0;Q<G.length;++Q){var K=G[Q];if(!l$[K]&&!(X&&X[K])&&!(H&&H[K])&&!(W&&W[K])){var U=a$(J,K);try{i$(Z,K,U)}catch($){}}}return Z}return Z}$Y.exports=UY});var R9=x((k7,BY)=>{Object.defineProperty(k7,"__esModule",{value:!0});k7.default=ZL;function ZL(Z){return Z.charAt(0).toUpperCase()+Z.slice(1)}BY.exports=k7.default});var MY=x((g7,zY)=>{Object.defineProperty(g7,"__esModule",{value:!0});g7.default=WL;var XL=R9(),YL=GL(XL);function GL(Z){return Z&&Z.__esModule?Z:{default:Z}}function WL(Z,J,X){if(Z.hasOwnProperty(J)){var Y={},G=Z[J],W=(0,YL.default)(J),H=Object.keys(X);for(var Q=0;Q<H.length;Q++){var K=H[Q];if(K===J)for(var U=0;U<G.length;U++)Y[G[U]+W]=X[J];Y[K]=X[K]}return Y}return X}zY.exports=g7.default});var v7=x((h7,FY)=>{Object.defineProperty(h7,"__esModule",{value:!0});h7.default=QL;function QL(Z,J,X,Y,G){for(var W=0,H=Z.length;W<H;++W){var Q=Z[W](J,X,Y,G);if(Q)return Q}}FY.exports=h7.default});var m7=x((y7,VY)=>{Object.defineProperty(y7,"__esModule",{value:!0});y7.default=UL;function NY(Z,J){if(Z.indexOf(J)===-1)Z.push(J)}function UL(Z,J){if(Array.isArray(J))for(var X=0,Y=J.length;X<Y;++X)NY(Z,J[X]);else NY(Z,J)}VY.exports=y7.default});var u7=x((f7,AY)=>{Object.defineProperty(f7,"__esModule",{value:!0});f7.default=LL;function LL(Z){return Z instanceof Object&&!Array.isArray(Z)}AY.exports=f7.default});var RY=x((p7,qY)=>{Object.defineProperty(p7,"__esModule",{value:!0});p7.default=qL;var zL=MY(),ML=I9(zL),FL=v7(),DY=I9(FL),NL=m7(),VL=I9(NL),AL=u7(),DL=I9(AL);function I9(Z){return Z&&Z.__esModule?Z:{default:Z}}function qL(Z){var{prefixMap:J,plugins:X}=Z;function Y(G){for(var W in G){var H=G[W];if((0,DL.default)(H))G[W]=Y(H);else if(Array.isArray(H)){var Q=[];for(var K=0,U=H.length;K<U;++K){var $=(0,DY.default)(X,W,H[K],G,J);(0,VL.default)(Q,$||H[K])}if(Q.length>0)G[W]=Q}else{var L=(0,DY.default)(X,W,H,G,J);if(L)G[W]=L;G=(0,ML.default)(J,W,G)}}return G}return Y}qY.exports=p7.default});var OY=x((IY,O9)=>{/*!
|
|
2
|
+
* Bowser - a browser detector
|
|
3
|
+
* https://github.com/ded/bowser
|
|
4
|
+
* MIT License | (c) Dustin Diaz 2015
|
|
5
|
+
*/(function(Z,J,X){if(typeof O9<"u"&&O9.exports)O9.exports=X();else if(typeof define=="function"&&define.amd)define(J,X);else Z[J]=X()})(IY,"bowser",function(){var Z=!0;function J(K){function U(z1){var N=K.match(z1);return N&&N.length>1&&N[1]||""}function $(z1){var N=K.match(z1);return N&&N.length>1&&N[2]||""}var L=U(/(ipod|iphone|ipad)/i).toLowerCase(),z=/like android/i.test(K),B=!z&&/android/i.test(K),M=/nexus\s*[0-6]\s*/i.test(K),F=!M&&/nexus\s*[0-9]+/i.test(K),D=/CrOS/.test(K),q=/silk/i.test(K),P=/sailfish/i.test(K),O=/tizen/i.test(K),w=/(web|hpw)(o|0)s/i.test(K),E=/windows phone/i.test(K),I=/SamsungBrowser/i.test(K),k=!E&&/windows/i.test(K),l=!L&&!q&&/macintosh/i.test(K),y=!B&&!P&&!O&&!w&&/linux/i.test(K),a=$(/edg([ea]|ios)\/(\d+(\.\d+)?)/i),c=U(/version\/(\d+(\.\d+)?)/i),p=/tablet/i.test(K)&&!/tablet pc/i.test(K),C=!p&&/[^-]mobi/i.test(K),g=/xbox/i.test(K),A;if(/opera/i.test(K))A={name:"Opera",opera:Z,version:c||U(/(?:opera|opr|opios)[\s\/](\d+(\.\d+)?)/i)};else if(/opr\/|opios/i.test(K))A={name:"Opera",opera:Z,version:U(/(?:opr|opios)[\s\/](\d+(\.\d+)?)/i)||c};else if(/SamsungBrowser/i.test(K))A={name:"Samsung Internet for Android",samsungBrowser:Z,version:c||U(/(?:SamsungBrowser)[\s\/](\d+(\.\d+)?)/i)};else if(/Whale/i.test(K))A={name:"NAVER Whale browser",whale:Z,version:U(/(?:whale)[\s\/](\d+(?:\.\d+)+)/i)};else if(/MZBrowser/i.test(K))A={name:"MZ Browser",mzbrowser:Z,version:U(/(?:MZBrowser)[\s\/](\d+(?:\.\d+)+)/i)};else if(/coast/i.test(K))A={name:"Opera Coast",coast:Z,version:c||U(/(?:coast)[\s\/](\d+(\.\d+)?)/i)};else if(/focus/i.test(K))A={name:"Focus",focus:Z,version:U(/(?:focus)[\s\/](\d+(?:\.\d+)+)/i)};else if(/yabrowser/i.test(K))A={name:"Yandex Browser",yandexbrowser:Z,version:c||U(/(?:yabrowser)[\s\/](\d+(\.\d+)?)/i)};else if(/ucbrowser/i.test(K))A={name:"UC Browser",ucbrowser:Z,version:U(/(?:ucbrowser)[\s\/](\d+(?:\.\d+)+)/i)};else if(/mxios/i.test(K))A={name:"Maxthon",maxthon:Z,version:U(/(?:mxios)[\s\/](\d+(?:\.\d+)+)/i)};else if(/epiphany/i.test(K))A={name:"Epiphany",epiphany:Z,version:U(/(?:epiphany)[\s\/](\d+(?:\.\d+)+)/i)};else if(/puffin/i.test(K))A={name:"Puffin",puffin:Z,version:U(/(?:puffin)[\s\/](\d+(?:\.\d+)?)/i)};else if(/sleipnir/i.test(K))A={name:"Sleipnir",sleipnir:Z,version:U(/(?:sleipnir)[\s\/](\d+(?:\.\d+)+)/i)};else if(/k-meleon/i.test(K))A={name:"K-Meleon",kMeleon:Z,version:U(/(?:k-meleon)[\s\/](\d+(?:\.\d+)+)/i)};else if(E)if(A={name:"Windows Phone",osname:"Windows Phone",windowsphone:Z},a)A.msedge=Z,A.version=a;else A.msie=Z,A.version=U(/iemobile\/(\d+(\.\d+)?)/i);else if(/msie|trident/i.test(K))A={name:"Internet Explorer",msie:Z,version:U(/(?:msie |rv:)(\d+(\.\d+)?)/i)};else if(D)A={name:"Chrome",osname:"Chrome OS",chromeos:Z,chromeBook:Z,chrome:Z,version:U(/(?:chrome|crios|crmo)\/(\d+(\.\d+)?)/i)};else if(/edg([ea]|ios)/i.test(K))A={name:"Microsoft Edge",msedge:Z,version:a};else if(/vivaldi/i.test(K))A={name:"Vivaldi",vivaldi:Z,version:U(/vivaldi\/(\d+(\.\d+)?)/i)||c};else if(P)A={name:"Sailfish",osname:"Sailfish OS",sailfish:Z,version:U(/sailfish\s?browser\/(\d+(\.\d+)?)/i)};else if(/seamonkey\//i.test(K))A={name:"SeaMonkey",seamonkey:Z,version:U(/seamonkey\/(\d+(\.\d+)?)/i)};else if(/firefox|iceweasel|fxios/i.test(K)){if(A={name:"Firefox",firefox:Z,version:U(/(?:firefox|iceweasel|fxios)[ \/](\d+(\.\d+)?)/i)},/\((mobile|tablet);[^\)]*rv:[\d\.]+\)/i.test(K))A.firefoxos=Z,A.osname="Firefox OS"}else if(q)A={name:"Amazon Silk",silk:Z,version:U(/silk\/(\d+(\.\d+)?)/i)};else if(/phantom/i.test(K))A={name:"PhantomJS",phantom:Z,version:U(/phantomjs\/(\d+(\.\d+)?)/i)};else if(/slimerjs/i.test(K))A={name:"SlimerJS",slimer:Z,version:U(/slimerjs\/(\d+(\.\d+)?)/i)};else if(/blackberry|\bbb\d+/i.test(K)||/rim\stablet/i.test(K))A={name:"BlackBerry",osname:"BlackBerry OS",blackberry:Z,version:c||U(/blackberry[\d]+\/(\d+(\.\d+)?)/i)};else if(w)A={name:"WebOS",osname:"WebOS",webos:Z,version:c||U(/w(?:eb)?osbrowser\/(\d+(\.\d+)?)/i)},/touchpad\//i.test(K)&&(A.touchpad=Z);else if(/bada/i.test(K))A={name:"Bada",osname:"Bada",bada:Z,version:U(/dolfin\/(\d+(\.\d+)?)/i)};else if(O)A={name:"Tizen",osname:"Tizen",tizen:Z,version:U(/(?:tizen\s?)?browser\/(\d+(\.\d+)?)/i)||c};else if(/qupzilla/i.test(K))A={name:"QupZilla",qupzilla:Z,version:U(/(?:qupzilla)[\s\/](\d+(?:\.\d+)+)/i)||c};else if(/chromium/i.test(K))A={name:"Chromium",chromium:Z,version:U(/(?:chromium)[\s\/](\d+(?:\.\d+)?)/i)||c};else if(/chrome|crios|crmo/i.test(K))A={name:"Chrome",chrome:Z,version:U(/(?:chrome|crios|crmo)\/(\d+(\.\d+)?)/i)};else if(B)A={name:"Android",version:c};else if(/safari|applewebkit/i.test(K)){if(A={name:"Safari",safari:Z},c)A.version=c}else if(L){if(A={name:L=="iphone"?"iPhone":L=="ipad"?"iPad":"iPod"},c)A.version=c}else if(/googlebot/i.test(K))A={name:"Googlebot",googlebot:Z,version:U(/googlebot\/(\d+(\.\d+))/i)||c};else A={name:U(/^(.*)\/(.*) /),version:$(/^(.*)\/(.*) /)};if(!A.msedge&&/(apple)?webkit/i.test(K)){if(/(apple)?webkit\/537\.36/i.test(K))A.name=A.name||"Blink",A.blink=Z;else A.name=A.name||"Webkit",A.webkit=Z;if(!A.version&&c)A.version=c}else if(!A.opera&&/gecko\//i.test(K))A.name=A.name||"Gecko",A.gecko=Z,A.version=A.version||U(/gecko\/(\d+(\.\d+)?)/i);if(!A.windowsphone&&(B||A.silk))A.android=Z,A.osname="Android";else if(!A.windowsphone&&L)A[L]=Z,A.ios=Z,A.osname="iOS";else if(l)A.mac=Z,A.osname="macOS";else if(g)A.xbox=Z,A.osname="Xbox";else if(k)A.windows=Z,A.osname="Windows";else if(y)A.linux=Z,A.osname="Linux";function o(z1){switch(z1){case"NT":return"NT";case"XP":return"XP";case"NT 5.0":return"2000";case"NT 5.1":return"XP";case"NT 5.2":return"2003";case"NT 6.0":return"Vista";case"NT 6.1":return"7";case"NT 6.2":return"8";case"NT 6.3":return"8.1";case"NT 10.0":return"10";default:return}}var n="";if(A.windows)n=o(U(/Windows ((NT|XP)( \d\d?.\d)?)/i));else if(A.windowsphone)n=U(/windows phone (?:os)?\s?(\d+(\.\d+)*)/i);else if(A.mac)n=U(/Mac OS X (\d+([_\.\s]\d+)*)/i),n=n.replace(/[_\s]/g,".");else if(L)n=U(/os (\d+([_\s]\d+)*) like mac os x/i),n=n.replace(/[_\s]/g,".");else if(B)n=U(/android[ \/-](\d+(\.\d+)*)/i);else if(A.webos)n=U(/(?:web|hpw)os\/(\d+(\.\d+)*)/i);else if(A.blackberry)n=U(/rim\stablet\sos\s(\d+(\.\d+)*)/i);else if(A.bada)n=U(/bada\/(\d+(\.\d+)*)/i);else if(A.tizen)n=U(/tizen[\/\s](\d+(\.\d+)*)/i);if(n)A.osversion=n;var W1=!A.windows&&n.split(".")[0];if(p||F||L=="ipad"||B&&(W1==3||W1>=4&&!C)||A.silk)A.tablet=Z;else if(C||L=="iphone"||L=="ipod"||B||M||A.blackberry||A.webos||A.bada)A.mobile=Z;if(A.msedge||A.msie&&A.version>=10||A.yandexbrowser&&A.version>=15||A.vivaldi&&A.version>=1||A.chrome&&A.version>=20||A.samsungBrowser&&A.version>=4||A.whale&&W([A.version,"1.0"])===1||A.mzbrowser&&W([A.version,"6.0"])===1||A.focus&&W([A.version,"1.0"])===1||A.firefox&&A.version>=20||A.safari&&A.version>=6||A.opera&&A.version>=10||A.ios&&A.osversion&&A.osversion.split(".")[0]>=6||A.blackberry&&A.version>=10.1||A.chromium&&A.version>=20)A.a=Z;else if(A.msie&&A.version<10||A.chrome&&A.version<20||A.firefox&&A.version<20||A.safari&&A.version<6||A.opera&&A.version<10||A.ios&&A.osversion&&A.osversion.split(".")[0]<6||A.chromium&&A.version<20)A.c=Z;else A.x=Z;return A}var X=J(typeof navigator<"u"?navigator.userAgent||"":"");X.test=function(K){for(var U=0;U<K.length;++U){var $=K[U];if(typeof $==="string"){if($ in X)return!0}}return!1};function Y(K){return K.split(".").length}function G(K,U){var $=[],L;if(Array.prototype.map)return Array.prototype.map.call(K,U);for(L=0;L<K.length;L++)$.push(U(K[L]));return $}function W(K){var U=Math.max(Y(K[0]),Y(K[1])),$=G(K,function(L){var z=U-Y(L);return L=L+Array(z+1).join(".0"),G(L.split("."),function(B){return Array(20-B.length).join("0")+B}).reverse()});while(--U>=0)if($[0][U]>$[1][U])return 1;else if($[0][U]===$[1][U]){if(U===0)return 0}else return-1}function H(K,U,$){var L=X;if(typeof U==="string")$=U,U=void 0;if(U===void 0)U=!1;if($)L=J($);var z=""+L.version;for(var B in K)if(K.hasOwnProperty(B)){if(L[B]){if(typeof K[B]!=="string")throw Error("Browser version in the minVersion map should be a string: "+B+": "+String(K));return W([z,K[B]])<0}}return U}function Q(K,U,$){return!H(K,U,$)}return X.isUnsupportedBrowser=H,X.compareVersions=W,X.check=Q,X._detect=J,X.detect=J,X})});var SY=x((l7,_Y)=>{Object.defineProperty(l7,"__esModule",{value:!0});l7.default=PL;var IL=OY(),TY=OL(IL);function OL(Z){return Z&&Z.__esModule?Z:{default:Z}}var PY={chrome:"Webkit",safari:"Webkit",ios:"Webkit",android:"Webkit",phantom:"Webkit",opera:"Webkit",webos:"Webkit",blackberry:"Webkit",bada:"Webkit",tizen:"Webkit",chromium:"Webkit",vivaldi:"Webkit",firefox:"Moz",seamoney:"Moz",sailfish:"Moz",msie:"ms",msedge:"ms"},wY={chrome:"chrome",chromium:"chrome",safari:"safari",firfox:"firefox",msedge:"edge",opera:"opera",vivaldi:"opera",msie:"ie"};function TL(Z){if(Z.firefox)return"firefox";if(Z.mobile||Z.tablet){if(Z.ios)return"ios_saf";else if(Z.android)return"android";else if(Z.opera)return"op_mini"}for(var J in wY)if(Z.hasOwnProperty(J))return wY[J]}function PL(Z){var J=TY.default._detect(Z);if(J.yandexbrowser)J=TY.default._detect(Z.replace(/YaBrowser\/[0-9.]*/,""));for(var X in PY)if(J.hasOwnProperty(X)){var Y=PY[X];J.jsPrefix=Y,J.cssPrefix="-"+Y.toLowerCase()+"-";break}if(J.browserName=TL(J),J.version)J.browserVersion=parseFloat(J.version);else J.browserVersion=parseInt(parseFloat(J.osversion),10);if(J.osVersion=parseFloat(J.osversion),J.browserName==="ios_saf"&&J.browserVersion>J.osVersion)J.browserVersion=J.osVersion;if(J.browserName==="android"&&J.chrome&&J.browserVersion>37)J.browserName="and_chr";if(J.browserName==="android"&&J.osVersion<5)J.browserVersion=J.osVersion;if(J.browserName==="android"&&J.samsungBrowser)J.browserName="and_chr",J.browserVersion=44;return J}_Y.exports=l7.default});var EY=x((d7,CY)=>{Object.defineProperty(d7,"__esModule",{value:!0});d7.default=_L;function _L(Z,J,X){var Y="keyframes";if(Z==="chrome"&&J<43||(Z==="safari"||Z==="ios_saf")&&J<9||Z==="opera"&&J<30||Z==="android"&&J<=4.4||Z==="and_uc")return X+Y;return Y}CY.exports=d7.default});var bY=x((c7,xY)=>{Object.defineProperty(c7,"__esModule",{value:!0});var CL=function(){function Z(J,X){for(var Y=0;Y<X.length;Y++){var G=X[Y];if(G.enumerable=G.enumerable||!1,G.configurable=!0,"value"in G)G.writable=!0;Object.defineProperty(J,G.key,G)}}return function(J,X,Y){if(X)Z(J.prototype,X);if(Y)Z(J,Y);return J}}();c7.default=pL;var EL=SY(),jL=_5(EL),xL=EY(),bL=_5(xL),kL=R9(),gL=_5(kL),hL=m7(),vL=_5(hL),yL=u7(),mL=_5(yL),fL=v7(),jY=_5(fL);function _5(Z){return Z&&Z.__esModule?Z:{default:Z}}function uL(Z,J){if(!(Z instanceof J))throw TypeError("Cannot call a class as a function")}function pL(Z){var{prefixMap:J,plugins:X}=Z,Y=arguments.length>1&&arguments[1]!==void 0?arguments[1]:function(G){return G};return function(){function G(){var W=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};uL(this,G);var H=typeof navigator<"u"?navigator.userAgent:void 0;if(this._userAgent=W.userAgent||H,this._keepUnprefixed=W.keepUnprefixed||!1,this._userAgent)this._browserInfo=(0,jL.default)(this._userAgent);if(this._browserInfo&&this._browserInfo.cssPrefix)this.prefixedKeyframes=(0,bL.default)(this._browserInfo.browserName,this._browserInfo.browserVersion,this._browserInfo.cssPrefix);else return this._useFallback=!0,!1;var Q=this._browserInfo.browserName&&J[this._browserInfo.browserName];if(Q){this._requiresPrefix={};for(var K in Q)if(Q[K]>=this._browserInfo.browserVersion)this._requiresPrefix[K]=!0;this._hasPropsRequiringPrefix=Object.keys(this._requiresPrefix).length>0}else this._useFallback=!0;this._metaData={browserVersion:this._browserInfo.browserVersion,browserName:this._browserInfo.browserName,cssPrefix:this._browserInfo.cssPrefix,jsPrefix:this._browserInfo.jsPrefix,keepUnprefixed:this._keepUnprefixed,requiresPrefix:this._requiresPrefix}}return CL(G,[{key:"prefix",value:function(H){if(this._useFallback)return Y(H);if(!this._hasPropsRequiringPrefix)return H;return this._prefixStyle(H)}},{key:"_prefixStyle",value:function(H){for(var Q in H){var K=H[Q];if((0,mL.default)(K))H[Q]=this.prefix(K);else if(Array.isArray(K)){var U=[];for(var $=0,L=K.length;$<L;++$){var z=(0,jY.default)(X,Q,K[$],H,this._metaData);(0,vL.default)(U,z||K[$])}if(U.length>0)H[Q]=U}else{var B=(0,jY.default)(X,Q,K,H,this._metaData);if(B)H[Q]=B;if(this._requiresPrefix.hasOwnProperty(Q)){if(H[this._browserInfo.jsPrefix+(0,gL.default)(Q)]=K,!this._keepUnprefixed)delete H[Q]}}}return H}}],[{key:"prefixAll",value:function(H){return Y(H)}}]),G}()}xY.exports=c7.default});var i7=x((nw,T9)=>{/*!
|
|
6
|
+
Copyright (c) 2015 Jed Watson.
|
|
7
|
+
Based on code that is Copyright 2013-2015, Facebook, Inc.
|
|
8
|
+
All rights reserved.
|
|
9
|
+
*/(function(){var Z=!!(typeof window<"u"&&window.document&&window.document.createElement),J={canUseDOM:Z,canUseWorkers:typeof Worker<"u",canUseEventListeners:Z&&!!(window.addEventListener||window.attachEvent),canUseViewport:Z&&!!window.screen};if(typeof define==="function"&&typeof define.amd==="object"&&define.amd)define(function(){return J});else if(typeof T9<"u"&&T9.exports)T9.exports=J;else window.ExecutionEnvironment=J})()});var Y5=x((n7,kY)=>{Object.defineProperty(n7,"__esModule",{value:!0});n7.default=cL;var dL=/-webkit-|-moz-|-ms-/;function cL(Z){return typeof Z==="string"&&dL.test(Z)}kY.exports=n7.default});var hY=x((a7,gY)=>{Object.defineProperty(a7,"__esModule",{value:!0});a7.default=oL;var nL=Y5(),aL=rL(nL);function rL(Z){return Z&&Z.__esModule?Z:{default:Z}}var sL=["-webkit-","-moz-",""];function oL(Z,J){if(typeof J==="string"&&!(0,aL.default)(J)&&J.indexOf("calc(")>-1)return sL.map(function(X){return J.replace(/calc\(/g,X+"calc(")})}gY.exports=a7.default});var yY=x((r7,vY)=>{Object.defineProperty(r7,"__esModule",{value:!0});r7.default=YB;var eL=Y5(),ZB=JB(eL);function JB(Z){return Z&&Z.__esModule?Z:{default:Z}}var XB=["-webkit-",""];function YB(Z,J){if(typeof J==="string"&&!(0,ZB.default)(J)&&J.indexOf("cross-fade(")>-1)return XB.map(function(X){return J.replace(/cross-fade\(/g,X+"cross-fade(")})}vY.exports=r7.default});var fY=x((s7,mY)=>{Object.defineProperty(s7,"__esModule",{value:!0});s7.default=QB;var WB=["-webkit-","-moz-",""],HB={"zoom-in":!0,"zoom-out":!0,grab:!0,grabbing:!0};function QB(Z,J){if(Z==="cursor"&&HB.hasOwnProperty(J))return WB.map(function(X){return X+J})}mY.exports=s7.default});var pY=x((o7,uY)=>{Object.defineProperty(o7,"__esModule",{value:!0});o7.default=zB;var UB=Y5(),$B=LB(UB);function LB(Z){return Z&&Z.__esModule?Z:{default:Z}}var BB=["-webkit-",""];function zB(Z,J){if(typeof J==="string"&&!(0,$B.default)(J)&&J.indexOf("filter(")>-1)return BB.map(function(X){return J.replace(/filter\(/g,X+"filter(")})}uY.exports=o7.default});var cY=x((t7,dY)=>{Object.defineProperty(t7,"__esModule",{value:!0});t7.default=FB;var lY={flex:["-webkit-box","-moz-box","-ms-flexbox","-webkit-flex","flex"],"inline-flex":["-webkit-inline-box","-moz-inline-box","-ms-inline-flexbox","-webkit-inline-flex","inline-flex"]};function FB(Z,J){if(Z==="display"&&lY.hasOwnProperty(J))return lY[J]}dY.exports=t7.default});var aY=x((e7,nY)=>{Object.defineProperty(e7,"__esModule",{value:!0});e7.default=AB;var VB={"space-around":"distribute","space-between":"justify","flex-start":"start","flex-end":"end"},iY={alignContent:"msFlexLinePack",alignSelf:"msFlexItemAlign",alignItems:"msFlexAlign",justifyContent:"msFlexPack",order:"msFlexOrder",flexGrow:"msFlexPositive",flexShrink:"msFlexNegative",flexBasis:"msFlexPreferredSize"};function AB(Z,J,X){if(iY.hasOwnProperty(Z))X[iY[Z]]=VB[J]||J}nY.exports=e7.default});var oY=x((Z4,sY)=>{Object.defineProperty(Z4,"__esModule",{value:!0});Z4.default=RB;var qB={"space-around":"justify","space-between":"justify","flex-start":"start","flex-end":"end","wrap-reverse":"multiple",wrap:"multiple",flex:"box","inline-flex":"inline-box"},rY={alignItems:"WebkitBoxAlign",justifyContent:"WebkitBoxPack",flexWrap:"WebkitBoxLines",flexGrow:"WebkitBoxFlex"};function RB(Z,J,X){if(Z==="flexDirection"&&typeof J==="string"){if(J.indexOf("column")>-1)X.WebkitBoxOrient="vertical";else X.WebkitBoxOrient="horizontal";if(J.indexOf("reverse")>-1)X.WebkitBoxDirection="reverse";else X.WebkitBoxDirection="normal"}if(rY.hasOwnProperty(Z))X[rY[Z]]=qB[J]||J}sY.exports=Z4.default});var ZG=x((J4,eY)=>{Object.defineProperty(J4,"__esModule",{value:!0});J4.default=_B;var OB=Y5(),TB=PB(OB);function PB(Z){return Z&&Z.__esModule?Z:{default:Z}}var wB=["-webkit-","-moz-",""],tY=/linear-gradient|radial-gradient|repeating-linear-gradient|repeating-radial-gradient/gi;function _B(Z,J){if(typeof J==="string"&&!(0,TB.default)(J)&&tY.test(J))return wB.map(function(X){return J.replace(tY,function(Y){return X+Y})})}eY.exports=J4.default});var XG=x((X4,JG)=>{Object.defineProperty(X4,"__esModule",{value:!0});X4.default=bB;var CB=Y5(),EB=jB(CB);function jB(Z){return Z&&Z.__esModule?Z:{default:Z}}var xB=["-webkit-",""];function bB(Z,J){if(typeof J==="string"&&!(0,EB.default)(J)&&J.indexOf("image-set(")>-1)return xB.map(function(X){return J.replace(/image-set\(/g,X+"image-set(")})}JG.exports=X4.default});var GG=x((Y4,YG)=>{Object.defineProperty(Y4,"__esModule",{value:!0});Y4.default=gB;function gB(Z,J){if(Z==="position"&&J==="sticky")return["-webkit-sticky","sticky"]}YG.exports=Y4.default});var HG=x((G4,WG)=>{Object.defineProperty(G4,"__esModule",{value:!0});G4.default=fB;var vB=["-webkit-","-moz-",""],yB={maxHeight:!0,maxWidth:!0,width:!0,height:!0,columnWidth:!0,minWidth:!0,minHeight:!0},mB={"min-content":!0,"max-content":!0,"fill-available":!0,"fit-content":!0,"contain-floats":!0};function fB(Z,J){if(yB.hasOwnProperty(Z)&&mB.hasOwnProperty(J))return vB.map(function(X){return X+J})}WG.exports=G4.default});var KG=x((aw,QG)=>{var pB=/[A-Z]/g,lB=/^ms-/,W4={};function dB(Z){return"-"+Z.toLowerCase()}function cB(Z){if(W4.hasOwnProperty(Z))return W4[Z];var J=Z.replace(pB,dB);return W4[Z]=lB.test(J)?"-"+J:J}QG.exports=cB});var Q4=x((H4,UG)=>{Object.defineProperty(H4,"__esModule",{value:!0});H4.default=rB;var iB=KG(),nB=aB(iB);function aB(Z){return Z&&Z.__esModule?Z:{default:Z}}function rB(Z){return(0,nB.default)(Z)}UG.exports=H4.default});var BG=x((U4,LG)=>{Object.defineProperty(U4,"__esModule",{value:!0});U4.default=Wz;var oB=Q4(),tB=K4(oB),eB=Y5(),Zz=K4(eB),Jz=R9(),$G=K4(Jz);function K4(Z){return Z&&Z.__esModule?Z:{default:Z}}var Xz={transition:!0,transitionProperty:!0,WebkitTransition:!0,WebkitTransitionProperty:!0,MozTransition:!0,MozTransitionProperty:!0},Yz={Webkit:"-webkit-",Moz:"-moz-",ms:"-ms-"};function Gz(Z,J){if((0,Zz.default)(Z))return Z;var X=Z.split(/,(?![^()]*(?:\([^()]*\))?\))/g);for(var Y=0,G=X.length;Y<G;++Y){var W=X[Y],H=[W];for(var Q in J){var K=(0,tB.default)(Q);if(W.indexOf(K)>-1&&K!=="order"){var U=J[Q];for(var $=0,L=U.length;$<L;++$)H.unshift(W.replace(K,Yz[U[$]]+K))}}X[Y]=H.join(",")}return X.join(",")}function Wz(Z,J,X,Y){if(typeof J==="string"&&Xz.hasOwnProperty(Z)){var G=Gz(J,Y),W=G.split(/,(?![^()]*(?:\([^()]*\))?\))/g).filter(function(Q){return!/-moz-|-ms-/.test(Q)}).join(",");if(Z.indexOf("Webkit")>-1)return W;var H=G.split(/,(?![^()]*(?:\([^()]*\))?\))/g).filter(function(Q){return!/-webkit-|-ms-/.test(Q)}).join(",");if(Z.indexOf("Moz")>-1)return H;return X["Webkit"+(0,$G.default)(Z)]=W,X["Moz"+(0,$G.default)(Z)]=H,G}}LG.exports=U4.default});var a1=x((L4,wG)=>{Object.defineProperty(L4,"__esModule",{value:!0});L4.default=Qz;function Qz(Z,J,X){if(X)return[Z,J];return Z}wG.exports=L4.default});var SG=x((B4,_G)=>{Object.defineProperty(B4,"__esModule",{value:!0});B4.default=Bz;var Uz=a1(),$z=Lz(Uz);function Lz(Z){return Z&&Z.__esModule?Z:{default:Z}}function Bz(Z,J,X,Y){var{browserName:G,browserVersion:W,cssPrefix:H,keepUnprefixed:Q}=Y;if(typeof J==="string"&&J.indexOf("calc(")>-1&&(G==="firefox"&&W<15||G==="chrome"&&W<25||G==="safari"&&W<6.1||G==="ios_saf"&&W<7))return(0,$z.default)(J.replace(/calc\(/g,H+"calc("),J,Q)}_G.exports=B4.default});var EG=x((z4,CG)=>{Object.defineProperty(z4,"__esModule",{value:!0});z4.default=Vz;var Mz=a1(),Fz=Nz(Mz);function Nz(Z){return Z&&Z.__esModule?Z:{default:Z}}function Vz(Z,J,X,Y){var{browserName:G,browserVersion:W,cssPrefix:H,keepUnprefixed:Q}=Y;if(typeof J==="string"&&J.indexOf("cross-fade(")>-1&&(G==="chrome"||G==="opera"||G==="and_chr"||(G==="ios_saf"||G==="safari")&&W<10))return(0,Fz.default)(J.replace(/cross-fade\(/g,H+"cross-fade("),J,Q)}CG.exports=z4.default});var bG=x((M4,xG)=>{Object.defineProperty(M4,"__esModule",{value:!0});M4.default=Oz;var Dz=a1(),jG=qz(Dz);function qz(Z){return Z&&Z.__esModule?Z:{default:Z}}var Rz={grab:!0,grabbing:!0},Iz={"zoom-in":!0,"zoom-out":!0};function Oz(Z,J,X,Y){var{browserName:G,browserVersion:W,cssPrefix:H,keepUnprefixed:Q}=Y;if(Z==="cursor"&&Rz[J]&&(G==="firefox"||G==="chrome"||G==="safari"||G==="opera"))return(0,jG.default)(H+J,J,Q);if(Z==="cursor"&&Iz[J]&&(G==="firefox"&&W<24||G==="chrome"&&W<37||G==="safari"&&W<9||G==="opera"&&W<24))return(0,jG.default)(H+J,J,Q)}xG.exports=M4.default});var gG=x((F4,kG)=>{Object.defineProperty(F4,"__esModule",{value:!0});F4.default=Sz;var Pz=a1(),wz=_z(Pz);function _z(Z){return Z&&Z.__esModule?Z:{default:Z}}function Sz(Z,J,X,Y){var{browserName:G,browserVersion:W,cssPrefix:H,keepUnprefixed:Q}=Y;if(typeof J==="string"&&J.indexOf("filter(")>-1&&(G==="ios_saf"||G==="safari"&&W<9.1))return(0,wz.default)(J.replace(/filter\(/g,H+"filter("),J,Q)}kG.exports=F4.default});var vG=x((N4,hG)=>{Object.defineProperty(N4,"__esModule",{value:!0});N4.default=kz;var Ez=a1(),jz=xz(Ez);function xz(Z){return Z&&Z.__esModule?Z:{default:Z}}var bz={flex:!0,"inline-flex":!0};function kz(Z,J,X,Y){var{browserName:G,browserVersion:W,cssPrefix:H,keepUnprefixed:Q}=Y;if(Z==="display"&&bz[J]&&(G==="chrome"&&W<29&&W>20||(G==="safari"||G==="ios_saf")&&W<9&&W>6||G==="opera"&&(W===15||W===16)))return(0,jz.default)(H+J,J,Q)}hG.exports=N4.default});var mG=x((D4,yG)=>{Object.defineProperty(D4,"__esModule",{value:!0});D4.default=mz;var hz=a1(),vz=yz(hz);function yz(Z){return Z&&Z.__esModule?Z:{default:Z}}var V4={"space-around":"distribute","space-between":"justify","flex-start":"start","flex-end":"end",flex:"flexbox","inline-flex":"inline-flexbox"},A4={alignContent:"msFlexLinePack",alignSelf:"msFlexItemAlign",alignItems:"msFlexAlign",justifyContent:"msFlexPack",order:"msFlexOrder",flexGrow:"msFlexPositive",flexShrink:"msFlexNegative",flexBasis:"msFlexPreferredSize"};function mz(Z,J,X,Y){var{browserName:G,browserVersion:W,cssPrefix:H,keepUnprefixed:Q,requiresPrefix:K}=Y;if((A4.hasOwnProperty(Z)||Z==="display"&&typeof J==="string"&&J.indexOf("flex")>-1)&&(G==="ie_mob"||G==="ie")&&W===10){if(delete K[Z],!Q&&!Array.isArray(X[Z]))delete X[Z];if(Z==="display"&&V4.hasOwnProperty(J))return(0,vz.default)(H+V4[J],J,Q);if(A4.hasOwnProperty(Z))X[A4[Z]]=V4[J]||J}}yG.exports=D4.default});var uG=x((I4,fG)=>{Object.defineProperty(I4,"__esModule",{value:!0});I4.default=iz;var uz=a1(),pz=lz(uz);function lz(Z){return Z&&Z.__esModule?Z:{default:Z}}var q4={"space-around":"justify","space-between":"justify","flex-start":"start","flex-end":"end","wrap-reverse":"multiple",wrap:"multiple",flex:"box","inline-flex":"inline-box"},R4={alignItems:"WebkitBoxAlign",justifyContent:"WebkitBoxPack",flexWrap:"WebkitBoxLines",flexGrow:"WebkitBoxFlex"},dz=["alignContent","alignSelf","order","flexGrow","flexShrink","flexBasis","flexDirection"],cz=Object.keys(R4).concat(dz);function iz(Z,J,X,Y){var{browserName:G,browserVersion:W,cssPrefix:H,keepUnprefixed:Q,requiresPrefix:K}=Y;if((cz.indexOf(Z)>-1||Z==="display"&&typeof J==="string"&&J.indexOf("flex")>-1)&&(G==="firefox"&&W<22||G==="chrome"&&W<21||(G==="safari"||G==="ios_saf")&&W<=6.1||G==="android"&&W<4.4||G==="and_uc")){if(delete K[Z],!Q&&!Array.isArray(X[Z]))delete X[Z];if(Z==="flexDirection"&&typeof J==="string"){if(J.indexOf("column")>-1)X.WebkitBoxOrient="vertical";else X.WebkitBoxOrient="horizontal";if(J.indexOf("reverse")>-1)X.WebkitBoxDirection="reverse";else X.WebkitBoxDirection="normal"}if(Z==="display"&&q4.hasOwnProperty(J))return(0,pz.default)(H+q4[J],J,Q);if(R4.hasOwnProperty(Z))X[R4[Z]]=q4[J]||J}}fG.exports=I4.default});var dG=x((O4,lG)=>{Object.defineProperty(O4,"__esModule",{value:!0});O4.default=oz;var az=a1(),rz=sz(az);function sz(Z){return Z&&Z.__esModule?Z:{default:Z}}var pG=/linear-gradient|radial-gradient|repeating-linear-gradient|repeating-radial-gradient/gi;function oz(Z,J,X,Y){var{browserName:G,browserVersion:W,cssPrefix:H,keepUnprefixed:Q}=Y;if(typeof J==="string"&&pG.test(J)&&(G==="firefox"&&W<16||G==="chrome"&&W<26||(G==="safari"||G==="ios_saf")&&W<7||(G==="opera"||G==="op_mini")&&W<12.1||G==="android"&&W<4.4||G==="and_uc"))return(0,rz.default)(J.replace(pG,function(K){return H+K}),J,Q)}lG.exports=O4.default});var iG=x((T4,cG)=>{Object.defineProperty(T4,"__esModule",{value:!0});T4.default=XM;var ez=a1(),ZM=JM(ez);function JM(Z){return Z&&Z.__esModule?Z:{default:Z}}function XM(Z,J,X,Y){var{browserName:G,cssPrefix:W,keepUnprefixed:H}=Y;if(typeof J==="string"&&J.indexOf("image-set(")>-1&&(G==="chrome"||G==="opera"||G==="and_chr"||G==="and_uc"||G==="ios_saf"||G==="safari"))return(0,ZM.default)(J.replace(/image-set\(/g,W+"image-set("),J,H)}cG.exports=T4.default});var aG=x((P4,nG)=>{Object.defineProperty(P4,"__esModule",{value:!0});P4.default=QM;var GM=a1(),WM=HM(GM);function HM(Z){return Z&&Z.__esModule?Z:{default:Z}}function QM(Z,J,X,Y){var{browserName:G,cssPrefix:W,keepUnprefixed:H}=Y;if(Z==="position"&&J==="sticky"&&(G==="safari"||G==="ios_saf"))return(0,WM.default)(W+J,J,H)}nG.exports=P4.default});var sG=x((w4,rG)=>{Object.defineProperty(w4,"__esModule",{value:!0});w4.default=MM;var UM=a1(),$M=LM(UM);function LM(Z){return Z&&Z.__esModule?Z:{default:Z}}var BM={maxHeight:!0,maxWidth:!0,width:!0,height:!0,columnWidth:!0,minWidth:!0,minHeight:!0},zM={"min-content":!0,"max-content":!0,"fill-available":!0,"fit-content":!0,"contain-floats":!0};function MM(Z,J,X,Y){var{cssPrefix:G,keepUnprefixed:W}=Y;if(BM.hasOwnProperty(Z)&&zM.hasOwnProperty(J))return(0,$M.default)(G+J,J,W)}rG.exports=w4.default});var tG=x((S4,oG)=>{Object.defineProperty(S4,"__esModule",{value:!0});S4.default=qM;var NM=Q4(),VM=AM(NM);function AM(Z){return Z&&Z.__esModule?Z:{default:Z}}var DM={transition:!0,transitionProperty:!0,WebkitTransition:!0,WebkitTransitionProperty:!0,MozTransition:!0,MozTransitionProperty:!0},_4=void 0;function qM(Z,J,X,Y){var{cssPrefix:G,keepUnprefixed:W,requiresPrefix:H}=Y;if(typeof J==="string"&&DM.hasOwnProperty(Z)){if(!_4)_4=Object.keys(H).map(function(K){return(0,VM.default)(K)});var Q=J.split(/,(?![^()]*(?:\([^()]*\))?\))/g);return _4.forEach(function(K){Q.forEach(function(U,$){if(U.indexOf(K)>-1&&K!=="order")Q[$]=U.replace(K,G+K)+(W?","+U:"")})}),Q.join(",")}}oG.exports=S4.default});var BZ=x((QH)=>{Object.defineProperty(QH,"__esModule",{value:!0});QH.Doctype=QH.CDATA=QH.Tag=QH.Style=QH.Script=QH.Comment=QH.Directive=QH.Text=QH.Root=QH.isTag=QH.ElementType=void 0;var c1;(function(Z){Z.Root="root",Z.Text="text",Z.Directive="directive",Z.Comment="comment",Z.Script="script",Z.Style="style",Z.Tag="tag",Z.CDATA="cdata",Z.Doctype="doctype"})(c1=QH.ElementType||(QH.ElementType={}));function rN(Z){return Z.type===c1.Tag||Z.type===c1.Script||Z.type===c1.Style}QH.isTag=rN;QH.Root=c1.Root;QH.Text=c1.Text;QH.Directive=c1.Directive;QH.Comment=c1.Comment;QH.Script=c1.Script;QH.Style=c1.Style;QH.Tag=c1.Tag;QH.CDATA=c1.CDATA;QH.Doctype=c1.Doctype});var NZ=x((i)=>{var d0=i&&i.__extends||function(){var Z=function(J,X){return Z=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(Y,G){Y.__proto__=G}||function(Y,G){for(var W in G)if(Object.prototype.hasOwnProperty.call(G,W))Y[W]=G[W]},Z(J,X)};return function(J,X){if(typeof X!=="function"&&X!==null)throw TypeError("Class extends value "+String(X)+" is not a constructor or null");Z(J,X);function Y(){this.constructor=J}J.prototype=X===null?Object.create(X):(Y.prototype=X.prototype,new Y)}}(),C6=i&&i.__assign||function(){return C6=Object.assign||function(Z){for(var J,X=1,Y=arguments.length;X<Y;X++){J=arguments[X];for(var G in J)if(Object.prototype.hasOwnProperty.call(J,G))Z[G]=J[G]}return Z},C6.apply(this,arguments)};Object.defineProperty(i,"__esModule",{value:!0});i.cloneNode=i.hasChildren=i.isDocument=i.isDirective=i.isComment=i.isText=i.isCDATA=i.isTag=i.Element=i.Document=i.CDATA=i.NodeWithChildren=i.ProcessingInstruction=i.Comment=i.Text=i.DataNode=i.Node=void 0;var m1=BZ(),MZ=function(){function Z(){this.parent=null,this.prev=null,this.next=null,this.startIndex=null,this.endIndex=null}return Object.defineProperty(Z.prototype,"parentNode",{get:function(){return this.parent},set:function(J){this.parent=J},enumerable:!1,configurable:!0}),Object.defineProperty(Z.prototype,"previousSibling",{get:function(){return this.prev},set:function(J){this.prev=J},enumerable:!1,configurable:!0}),Object.defineProperty(Z.prototype,"nextSibling",{get:function(){return this.next},set:function(J){this.next=J},enumerable:!1,configurable:!0}),Z.prototype.cloneNode=function(J){if(J===void 0)J=!1;return FZ(this,J)},Z}();i.Node=MZ;var G8=function(Z){d0(J,Z);function J(X){var Y=Z.call(this)||this;return Y.data=X,Y}return Object.defineProperty(J.prototype,"nodeValue",{get:function(){return this.data},set:function(X){this.data=X},enumerable:!1,configurable:!0}),J}(MZ);i.DataNode=G8;var UH=function(Z){d0(J,Z);function J(){var X=Z!==null&&Z.apply(this,arguments)||this;return X.type=m1.ElementType.Text,X}return Object.defineProperty(J.prototype,"nodeType",{get:function(){return 3},enumerable:!1,configurable:!0}),J}(G8);i.Text=UH;var $H=function(Z){d0(J,Z);function J(){var X=Z!==null&&Z.apply(this,arguments)||this;return X.type=m1.ElementType.Comment,X}return Object.defineProperty(J.prototype,"nodeType",{get:function(){return 8},enumerable:!1,configurable:!0}),J}(G8);i.Comment=$H;var LH=function(Z){d0(J,Z);function J(X,Y){var G=Z.call(this,Y)||this;return G.name=X,G.type=m1.ElementType.Directive,G}return Object.defineProperty(J.prototype,"nodeType",{get:function(){return 1},enumerable:!1,configurable:!0}),J}(G8);i.ProcessingInstruction=LH;var W8=function(Z){d0(J,Z);function J(X){var Y=Z.call(this)||this;return Y.children=X,Y}return Object.defineProperty(J.prototype,"firstChild",{get:function(){var X;return(X=this.children[0])!==null&&X!==void 0?X:null},enumerable:!1,configurable:!0}),Object.defineProperty(J.prototype,"lastChild",{get:function(){return this.children.length>0?this.children[this.children.length-1]:null},enumerable:!1,configurable:!0}),Object.defineProperty(J.prototype,"childNodes",{get:function(){return this.children},set:function(X){this.children=X},enumerable:!1,configurable:!0}),J}(MZ);i.NodeWithChildren=W8;var BH=function(Z){d0(J,Z);function J(){var X=Z!==null&&Z.apply(this,arguments)||this;return X.type=m1.ElementType.CDATA,X}return Object.defineProperty(J.prototype,"nodeType",{get:function(){return 4},enumerable:!1,configurable:!0}),J}(W8);i.CDATA=BH;var zH=function(Z){d0(J,Z);function J(){var X=Z!==null&&Z.apply(this,arguments)||this;return X.type=m1.ElementType.Root,X}return Object.defineProperty(J.prototype,"nodeType",{get:function(){return 9},enumerable:!1,configurable:!0}),J}(W8);i.Document=zH;var MH=function(Z){d0(J,Z);function J(X,Y,G,W){if(G===void 0)G=[];if(W===void 0)W=X==="script"?m1.ElementType.Script:X==="style"?m1.ElementType.Style:m1.ElementType.Tag;var H=Z.call(this,G)||this;return H.name=X,H.attribs=Y,H.type=W,H}return Object.defineProperty(J.prototype,"nodeType",{get:function(){return 1},enumerable:!1,configurable:!0}),Object.defineProperty(J.prototype,"tagName",{get:function(){return this.name},set:function(X){this.name=X},enumerable:!1,configurable:!0}),Object.defineProperty(J.prototype,"attributes",{get:function(){var X=this;return Object.keys(this.attribs).map(function(Y){var G,W;return{name:Y,value:X.attribs[Y],namespace:(G=X["x-attribsNamespace"])===null||G===void 0?void 0:G[Y],prefix:(W=X["x-attribsPrefix"])===null||W===void 0?void 0:W[Y]}})},enumerable:!1,configurable:!0}),J}(W8);i.Element=MH;function FH(Z){return(0,m1.isTag)(Z)}i.isTag=FH;function NH(Z){return Z.type===m1.ElementType.CDATA}i.isCDATA=NH;function VH(Z){return Z.type===m1.ElementType.Text}i.isText=VH;function AH(Z){return Z.type===m1.ElementType.Comment}i.isComment=AH;function DH(Z){return Z.type===m1.ElementType.Directive}i.isDirective=DH;function qH(Z){return Z.type===m1.ElementType.Root}i.isDocument=qH;function WV(Z){return Object.prototype.hasOwnProperty.call(Z,"children")}i.hasChildren=WV;function FZ(Z,J){if(J===void 0)J=!1;var X;if(VH(Z))X=new UH(Z.data);else if(AH(Z))X=new $H(Z.data);else if(FH(Z)){var Y=J?zZ(Z.children):[],G=new MH(Z.name,C6({},Z.attribs),Y);if(Y.forEach(function(K){return K.parent=G}),Z.namespace!=null)G.namespace=Z.namespace;if(Z["x-attribsNamespace"])G["x-attribsNamespace"]=C6({},Z["x-attribsNamespace"]);if(Z["x-attribsPrefix"])G["x-attribsPrefix"]=C6({},Z["x-attribsPrefix"]);X=G}else if(NH(Z)){var Y=J?zZ(Z.children):[],W=new BH(Y);Y.forEach(function(U){return U.parent=W}),X=W}else if(qH(Z)){var Y=J?zZ(Z.children):[],H=new zH(Y);if(Y.forEach(function(U){return U.parent=H}),Z["x-mode"])H["x-mode"]=Z["x-mode"];X=H}else if(DH(Z)){var Q=new LH(Z.name,Z.data);if(Z["x-name"]!=null)Q["x-name"]=Z["x-name"],Q["x-publicId"]=Z["x-publicId"],Q["x-systemId"]=Z["x-systemId"];X=Q}else throw Error("Not implemented yet: ".concat(Z.type));if(X.startIndex=Z.startIndex,X.endIndex=Z.endIndex,Z.sourceCodeLocation!=null)X.sourceCodeLocation=Z.sourceCodeLocation;return X}i.cloneNode=FZ;function zZ(Z){var J=Z.map(function(Y){return FZ(Y,!0)});for(var X=1;X<J.length;X++)J[X].prev=J[X-1],J[X-1].next=J[X];return J}});var AZ=x((R0)=>{var HV=R0&&R0.__createBinding||(Object.create?function(Z,J,X,Y){if(Y===void 0)Y=X;var G=Object.getOwnPropertyDescriptor(J,X);if(!G||("get"in G?!J.__esModule:G.writable||G.configurable))G={enumerable:!0,get:function(){return J[X]}};Object.defineProperty(Z,Y,G)}:function(Z,J,X,Y){if(Y===void 0)Y=X;Z[Y]=J[X]}),QV=R0&&R0.__exportStar||function(Z,J){for(var X in Z)if(X!=="default"&&!Object.prototype.hasOwnProperty.call(J,X))HV(J,Z,X)};Object.defineProperty(R0,"__esModule",{value:!0});R0.DomHandler=void 0;var VZ=BZ(),c0=NZ();QV(NZ(),R0);var RH={withStartIndices:!1,withEndIndices:!1,xmlMode:!1},IH=function(){function Z(J,X,Y){if(this.dom=[],this.root=new c0.Document(this.dom),this.done=!1,this.tagStack=[this.root],this.lastNode=null,this.parser=null,typeof X==="function")Y=X,X=RH;if(typeof J==="object")X=J,J=void 0;this.callback=J!==null&&J!==void 0?J:null,this.options=X!==null&&X!==void 0?X:RH,this.elementCB=Y!==null&&Y!==void 0?Y:null}return Z.prototype.onparserinit=function(J){this.parser=J},Z.prototype.onreset=function(){this.dom=[],this.root=new c0.Document(this.dom),this.done=!1,this.tagStack=[this.root],this.lastNode=null,this.parser=null},Z.prototype.onend=function(){if(this.done)return;this.done=!0,this.parser=null,this.handleCallback(null)},Z.prototype.onerror=function(J){this.handleCallback(J)},Z.prototype.onclosetag=function(){this.lastNode=null;var J=this.tagStack.pop();if(this.options.withEndIndices)J.endIndex=this.parser.endIndex;if(this.elementCB)this.elementCB(J)},Z.prototype.onopentag=function(J,X){var Y=this.options.xmlMode?VZ.ElementType.Tag:void 0,G=new c0.Element(J,X,void 0,Y);this.addNode(G),this.tagStack.push(G)},Z.prototype.ontext=function(J){var X=this.lastNode;if(X&&X.type===VZ.ElementType.Text){if(X.data+=J,this.options.withEndIndices)X.endIndex=this.parser.endIndex}else{var Y=new c0.Text(J);this.addNode(Y),this.lastNode=Y}},Z.prototype.oncomment=function(J){if(this.lastNode&&this.lastNode.type===VZ.ElementType.Comment){this.lastNode.data+=J;return}var X=new c0.Comment(J);this.addNode(X),this.lastNode=X},Z.prototype.oncommentend=function(){this.lastNode=null},Z.prototype.oncdatastart=function(){var J=new c0.Text(""),X=new c0.CDATA([J]);this.addNode(X),J.parent=X,this.lastNode=J},Z.prototype.oncdataend=function(){this.lastNode=null},Z.prototype.onprocessinginstruction=function(J,X){var Y=new c0.ProcessingInstruction(J,X);this.addNode(Y)},Z.prototype.handleCallback=function(J){if(typeof this.callback==="function")this.callback(J,this.dom);else if(J)throw J},Z.prototype.addNode=function(J){var X=this.tagStack[this.tagStack.length-1],Y=X.children[X.children.length-1];if(this.options.withStartIndices)J.startIndex=this.parser.startIndex;if(this.options.withEndIndices)J.endIndex=this.parser.endIndex;if(X.children.push(J),Y)J.prev=Y,Y.next=J;J.parent=X,this.lastNode=null},Z}();R0.DomHandler=IH;R0.default=IH});var SH=x((OH)=>{Object.defineProperty(OH,"__esModule",{value:!0});OH.CARRIAGE_RETURN_PLACEHOLDER_REGEX=OH.CARRIAGE_RETURN_PLACEHOLDER=OH.CARRIAGE_RETURN_REGEX=OH.CARRIAGE_RETURN=OH.CASE_SENSITIVE_TAG_NAMES_MAP=OH.CASE_SENSITIVE_TAG_NAMES=void 0;OH.CASE_SENSITIVE_TAG_NAMES=["animateMotion","animateTransform","clipPath","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","foreignObject","linearGradient","radialGradient","textPath"];OH.CASE_SENSITIVE_TAG_NAMES_MAP=OH.CASE_SENSITIVE_TAG_NAMES.reduce(function(Z,J){return Z[J.toLowerCase()]=J,Z},{});OH.CARRIAGE_RETURN="\r";OH.CARRIAGE_RETURN_REGEX=new RegExp(OH.CARRIAGE_RETURN,"g");OH.CARRIAGE_RETURN_PLACEHOLDER="__HTML_DOM_PARSER_CARRIAGE_RETURN_PLACEHOLDER_".concat(Date.now(),"__");OH.CARRIAGE_RETURN_PLACEHOLDER_REGEX=new RegExp(OH.CARRIAGE_RETURN_PLACEHOLDER,"g")});var DZ=x((xH)=>{Object.defineProperty(xH,"__esModule",{value:!0});xH.formatAttributes=CH;xH.escapeSpecialCharacters=BV;xH.revertEscapedCharacters=EH;xH.formatDOM=jH;var H8=AZ(),E6=SH();function $V(Z){return E6.CASE_SENSITIVE_TAG_NAMES_MAP[Z]}function CH(Z){var J={},X=0,Y=Z.length;for(;X<Y;X++){var G=Z[X];J[G.name]=G.value}return J}function LV(Z){Z=Z.toLowerCase();var J=$V(Z);if(J)return J;return Z}function BV(Z){return Z.replace(E6.CARRIAGE_RETURN_REGEX,E6.CARRIAGE_RETURN_PLACEHOLDER)}function EH(Z){return Z.replace(E6.CARRIAGE_RETURN_PLACEHOLDER_REGEX,E6.CARRIAGE_RETURN)}function jH(Z,J,X){if(J===void 0)J=null;var Y=[],G,W=0,H=Z.length;for(;W<H;W++){var Q=Z[W];switch(Q.nodeType){case 1:{var K=LV(Q.nodeName);G=new H8.Element(K,CH(Q.attributes)),G.children=jH(K==="template"?Q.content.childNodes:Q.childNodes,G);break}case 3:G=new H8.Text(EH(Q.nodeValue));break;case 8:G=new H8.Comment(Q.nodeValue);break;default:continue}var U=Y[W-1]||null;if(U)U.next=G;G.parent=J,G.prev=U,G.next=null,Y.push(G)}if(X){if(G=new H8.ProcessingInstruction(X.substring(0,X.indexOf(" ")).toLowerCase(),X),G.next=Y[0]||null,G.parent=J,Y.unshift(G),Y[1])Y[1].prev=Y[0]}return Y}});var mH=x((yH)=>{Object.defineProperty(yH,"__esModule",{value:!0});yH.default=DV;var VV=DZ(),bH="html",kH="head",Q8="body",AV=/<([a-zA-Z]+[0-9]?)/,gH=/<head[^]*>/i,hH=/<body[^]*>/i,U8=function(Z,J){throw Error("This browser does not support `document.implementation.createHTMLDocument`")},qZ=function(Z,J){throw Error("This browser does not support `DOMParser.prototype.parseFromString`")},vH=typeof window==="object"&&window.DOMParser;if(typeof vH==="function")RZ=new vH,IZ="text/html",qZ=function(Z,J){if(J)Z="<".concat(J,">").concat(Z,"</").concat(J,">");return RZ.parseFromString(Z,IZ)},U8=qZ;var RZ,IZ;if(typeof document==="object"&&document.implementation)v5=document.implementation.createHTMLDocument(),U8=function(Z,J){if(J){var X=v5.documentElement.querySelector(J);if(X)X.innerHTML=Z;return v5}return v5.documentElement.innerHTML=Z,v5};var v5,K8=typeof document==="object"&&document.createElement("template"),OZ;if(K8&&K8.content)OZ=function(Z){return K8.innerHTML=Z,K8.content.childNodes};function DV(Z){var J,X;Z=(0,VV.escapeSpecialCharacters)(Z);var Y=Z.match(AV),G=Y&&Y[1]?Y[1].toLowerCase():"";switch(G){case bH:{var W=qZ(Z);if(!gH.test(Z)){var H=W.querySelector(kH);(J=H===null||H===void 0?void 0:H.parentNode)===null||J===void 0||J.removeChild(H)}if(!hH.test(Z)){var H=W.querySelector(Q8);(X=H===null||H===void 0?void 0:H.parentNode)===null||X===void 0||X.removeChild(H)}return W.querySelectorAll(bH)}case kH:case Q8:{var Q=U8(Z).querySelectorAll(G);if(hH.test(Z)&&gH.test(Z))return Q[0].parentNode.childNodes;return Q}default:{if(OZ)return OZ(Z);var H=U8(Z,Q8).querySelector(Q8);return H.childNodes}}}});var fH=x((j6)=>{var RV=j6&&j6.__importDefault||function(Z){return Z&&Z.__esModule?Z:{default:Z}};Object.defineProperty(j6,"__esModule",{value:!0});j6.default=PV;var IV=RV(mH()),OV=DZ(),TV=/<(![a-zA-Z\s]+)>/;function PV(Z){if(typeof Z!=="string")throw TypeError("First argument must be a string");if(!Z)return[];var J=Z.match(TV),X=J?J[1]:void 0;return(0,OV.formatDOM)((0,IV.default)(Z),null,X)}});var uH=x((SV)=>{var wV=0;SV.SAME=wV;var _V=1;SV.CAMELCASE=_V;SV.possibleStandardNames={accept:0,acceptCharset:1,"accept-charset":"acceptCharset",accessKey:1,action:0,allowFullScreen:1,alt:0,as:0,async:0,autoCapitalize:1,autoComplete:1,autoCorrect:1,autoFocus:1,autoPlay:1,autoSave:1,capture:0,cellPadding:1,cellSpacing:1,challenge:0,charSet:1,checked:0,children:0,cite:0,class:"className",classID:1,className:1,cols:0,colSpan:1,content:0,contentEditable:1,contextMenu:1,controls:0,controlsList:1,coords:0,crossOrigin:1,dangerouslySetInnerHTML:1,data:0,dateTime:1,default:0,defaultChecked:1,defaultValue:1,defer:0,dir:0,disabled:0,disablePictureInPicture:1,disableRemotePlayback:1,download:0,draggable:0,encType:1,enterKeyHint:1,for:"htmlFor",form:0,formMethod:1,formAction:1,formEncType:1,formNoValidate:1,formTarget:1,frameBorder:1,headers:0,height:0,hidden:0,high:0,href:0,hrefLang:1,htmlFor:1,httpEquiv:1,"http-equiv":"httpEquiv",icon:0,id:0,innerHTML:1,inputMode:1,integrity:0,is:0,itemID:1,itemProp:1,itemRef:1,itemScope:1,itemType:1,keyParams:1,keyType:1,kind:0,label:0,lang:0,list:0,loop:0,low:0,manifest:0,marginWidth:1,marginHeight:1,max:0,maxLength:1,media:0,mediaGroup:1,method:0,min:0,minLength:1,multiple:0,muted:0,name:0,noModule:1,nonce:0,noValidate:1,open:0,optimum:0,pattern:0,placeholder:0,playsInline:1,poster:0,preload:0,profile:0,radioGroup:1,readOnly:1,referrerPolicy:1,rel:0,required:0,reversed:0,role:0,rows:0,rowSpan:1,sandbox:0,scope:0,scoped:0,scrolling:0,seamless:0,selected:0,shape:0,size:0,sizes:0,span:0,spellCheck:1,src:0,srcDoc:1,srcLang:1,srcSet:1,start:0,step:0,style:0,summary:0,tabIndex:1,target:0,title:0,type:0,useMap:1,value:0,width:0,wmode:0,wrap:0,about:0,accentHeight:1,"accent-height":"accentHeight",accumulate:0,additive:0,alignmentBaseline:1,"alignment-baseline":"alignmentBaseline",allowReorder:1,alphabetic:0,amplitude:0,arabicForm:1,"arabic-form":"arabicForm",ascent:0,attributeName:1,attributeType:1,autoReverse:1,azimuth:0,baseFrequency:1,baselineShift:1,"baseline-shift":"baselineShift",baseProfile:1,bbox:0,begin:0,bias:0,by:0,calcMode:1,capHeight:1,"cap-height":"capHeight",clip:0,clipPath:1,"clip-path":"clipPath",clipPathUnits:1,clipRule:1,"clip-rule":"clipRule",color:0,colorInterpolation:1,"color-interpolation":"colorInterpolation",colorInterpolationFilters:1,"color-interpolation-filters":"colorInterpolationFilters",colorProfile:1,"color-profile":"colorProfile",colorRendering:1,"color-rendering":"colorRendering",contentScriptType:1,contentStyleType:1,cursor:0,cx:0,cy:0,d:0,datatype:0,decelerate:0,descent:0,diffuseConstant:1,direction:0,display:0,divisor:0,dominantBaseline:1,"dominant-baseline":"dominantBaseline",dur:0,dx:0,dy:0,edgeMode:1,elevation:0,enableBackground:1,"enable-background":"enableBackground",end:0,exponent:0,externalResourcesRequired:1,fill:0,fillOpacity:1,"fill-opacity":"fillOpacity",fillRule:1,"fill-rule":"fillRule",filter:0,filterRes:1,filterUnits:1,floodOpacity:1,"flood-opacity":"floodOpacity",floodColor:1,"flood-color":"floodColor",focusable:0,fontFamily:1,"font-family":"fontFamily",fontSize:1,"font-size":"fontSize",fontSizeAdjust:1,"font-size-adjust":"fontSizeAdjust",fontStretch:1,"font-stretch":"fontStretch",fontStyle:1,"font-style":"fontStyle",fontVariant:1,"font-variant":"fontVariant",fontWeight:1,"font-weight":"fontWeight",format:0,from:0,fx:0,fy:0,g1:0,g2:0,glyphName:1,"glyph-name":"glyphName",glyphOrientationHorizontal:1,"glyph-orientation-horizontal":"glyphOrientationHorizontal",glyphOrientationVertical:1,"glyph-orientation-vertical":"glyphOrientationVertical",glyphRef:1,gradientTransform:1,gradientUnits:1,hanging:0,horizAdvX:1,"horiz-adv-x":"horizAdvX",horizOriginX:1,"horiz-origin-x":"horizOriginX",ideographic:0,imageRendering:1,"image-rendering":"imageRendering",in2:0,in:0,inlist:0,intercept:0,k1:0,k2:0,k3:0,k4:0,k:0,kernelMatrix:1,kernelUnitLength:1,kerning:0,keyPoints:1,keySplines:1,keyTimes:1,lengthAdjust:1,letterSpacing:1,"letter-spacing":"letterSpacing",lightingColor:1,"lighting-color":"lightingColor",limitingConeAngle:1,local:0,markerEnd:1,"marker-end":"markerEnd",markerHeight:1,markerMid:1,"marker-mid":"markerMid",markerStart:1,"marker-start":"markerStart",markerUnits:1,markerWidth:1,mask:0,maskContentUnits:1,maskUnits:1,mathematical:0,mode:0,numOctaves:1,offset:0,opacity:0,operator:0,order:0,orient:0,orientation:0,origin:0,overflow:0,overlinePosition:1,"overline-position":"overlinePosition",overlineThickness:1,"overline-thickness":"overlineThickness",paintOrder:1,"paint-order":"paintOrder",panose1:0,"panose-1":"panose1",pathLength:1,patternContentUnits:1,patternTransform:1,patternUnits:1,pointerEvents:1,"pointer-events":"pointerEvents",points:0,pointsAtX:1,pointsAtY:1,pointsAtZ:1,prefix:0,preserveAlpha:1,preserveAspectRatio:1,primitiveUnits:1,property:0,r:0,radius:0,refX:1,refY:1,renderingIntent:1,"rendering-intent":"renderingIntent",repeatCount:1,repeatDur:1,requiredExtensions:1,requiredFeatures:1,resource:0,restart:0,result:0,results:0,rotate:0,rx:0,ry:0,scale:0,security:0,seed:0,shapeRendering:1,"shape-rendering":"shapeRendering",slope:0,spacing:0,specularConstant:1,specularExponent:1,speed:0,spreadMethod:1,startOffset:1,stdDeviation:1,stemh:0,stemv:0,stitchTiles:1,stopColor:1,"stop-color":"stopColor",stopOpacity:1,"stop-opacity":"stopOpacity",strikethroughPosition:1,"strikethrough-position":"strikethroughPosition",strikethroughThickness:1,"strikethrough-thickness":"strikethroughThickness",string:0,stroke:0,strokeDasharray:1,"stroke-dasharray":"strokeDasharray",strokeDashoffset:1,"stroke-dashoffset":"strokeDashoffset",strokeLinecap:1,"stroke-linecap":"strokeLinecap",strokeLinejoin:1,"stroke-linejoin":"strokeLinejoin",strokeMiterlimit:1,"stroke-miterlimit":"strokeMiterlimit",strokeWidth:1,"stroke-width":"strokeWidth",strokeOpacity:1,"stroke-opacity":"strokeOpacity",suppressContentEditableWarning:1,suppressHydrationWarning:1,surfaceScale:1,systemLanguage:1,tableValues:1,targetX:1,targetY:1,textAnchor:1,"text-anchor":"textAnchor",textDecoration:1,"text-decoration":"textDecoration",textLength:1,textRendering:1,"text-rendering":"textRendering",to:0,transform:0,typeof:0,u1:0,u2:0,underlinePosition:1,"underline-position":"underlinePosition",underlineThickness:1,"underline-thickness":"underlineThickness",unicode:0,unicodeBidi:1,"unicode-bidi":"unicodeBidi",unicodeRange:1,"unicode-range":"unicodeRange",unitsPerEm:1,"units-per-em":"unitsPerEm",unselectable:0,vAlphabetic:1,"v-alphabetic":"vAlphabetic",values:0,vectorEffect:1,"vector-effect":"vectorEffect",version:0,vertAdvY:1,"vert-adv-y":"vertAdvY",vertOriginX:1,"vert-origin-x":"vertOriginX",vertOriginY:1,"vert-origin-y":"vertOriginY",vHanging:1,"v-hanging":"vHanging",vIdeographic:1,"v-ideographic":"vIdeographic",viewBox:1,viewTarget:1,visibility:0,vMathematical:1,"v-mathematical":"vMathematical",vocab:0,widths:0,wordSpacing:1,"word-spacing":"wordSpacing",writingMode:1,"writing-mode":"writingMode",x1:0,x2:0,x:0,xChannelSelector:1,xHeight:1,"x-height":"xHeight",xlinkActuate:1,"xlink:actuate":"xlinkActuate",xlinkArcrole:1,"xlink:arcrole":"xlinkArcrole",xlinkHref:1,"xlink:href":"xlinkHref",xlinkRole:1,"xlink:role":"xlinkRole",xlinkShow:1,"xlink:show":"xlinkShow",xlinkTitle:1,"xlink:title":"xlinkTitle",xlinkType:1,"xlink:type":"xlinkType",xmlBase:1,"xml:base":"xmlBase",xmlLang:1,"xml:lang":"xmlLang",xmlns:0,"xml:space":"xmlSpace",xmlnsXlink:1,"xmlns:xlink":"xmlnsXlink",xmlSpace:1,y1:0,y2:0,y:0,yChannelSelector:1,z:0,zoomAndPan:1}});var lH=x((uV)=>{function xV(Z){return D1.hasOwnProperty(Z)?D1[Z]:null}function x1(Z,J,X,Y,G,W,H){this.acceptsBooleans=J===2||J===3||J===4,this.attributeName=Y,this.attributeNamespace=G,this.mustUseProperty=X,this.propertyName=Z,this.type=J,this.sanitizeURL=W,this.removeEmptyString=H}var D1={},bV=["children","dangerouslySetInnerHTML","defaultValue","defaultChecked","innerHTML","suppressContentEditableWarning","suppressHydrationWarning","style"];bV.forEach((Z)=>{D1[Z]=new x1(Z,0,!1,Z,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(([Z,J])=>{D1[Z]=new x1(Z,1,!1,J,null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach((Z)=>{D1[Z]=new x1(Z,2,!1,Z.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach((Z)=>{D1[Z]=new x1(Z,2,!1,Z,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"].forEach((Z)=>{D1[Z]=new x1(Z,3,!1,Z.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach((Z)=>{D1[Z]=new x1(Z,3,!0,Z,null,!1,!1)});["capture","download"].forEach((Z)=>{D1[Z]=new x1(Z,4,!1,Z,null,!1,!1)});["cols","rows","size","span"].forEach((Z)=>{D1[Z]=new x1(Z,6,!1,Z,null,!1,!1)});["rowSpan","start"].forEach((Z)=>{D1[Z]=new x1(Z,5,!1,Z.toLowerCase(),null,!1,!1)});var TZ=/[\-\:]([a-z])/g,PZ=(Z)=>Z[1].toUpperCase();["accent-height","alignment-baseline","arabic-form","baseline-shift","cap-height","clip-path","clip-rule","color-interpolation","color-interpolation-filters","color-profile","color-rendering","dominant-baseline","enable-background","fill-opacity","fill-rule","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","glyph-name","glyph-orientation-horizontal","glyph-orientation-vertical","horiz-adv-x","horiz-origin-x","image-rendering","letter-spacing","lighting-color","marker-end","marker-mid","marker-start","overline-position","overline-thickness","paint-order","panose-1","pointer-events","rendering-intent","shape-rendering","stop-color","stop-opacity","strikethrough-position","strikethrough-thickness","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke-width","text-anchor","text-decoration","text-rendering","underline-position","underline-thickness","unicode-bidi","unicode-range","units-per-em","v-alphabetic","v-hanging","v-ideographic","v-mathematical","vector-effect","vert-adv-y","vert-origin-x","vert-origin-y","word-spacing","writing-mode","xmlns:xlink","x-height"].forEach((Z)=>{let J=Z.replace(TZ,PZ);D1[J]=new x1(J,1,!1,Z,null,!1,!1)});["xlink:actuate","xlink:arcrole","xlink:role","xlink:show","xlink:title","xlink:type"].forEach((Z)=>{let J=Z.replace(TZ,PZ);D1[J]=new x1(J,1,!1,Z,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach((Z)=>{let J=Z.replace(TZ,PZ);D1[J]=new x1(J,1,!1,Z,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach((Z)=>{D1[Z]=new x1(Z,1,!1,Z.toLowerCase(),null,!1,!1)});var kV="xlinkHref";D1[kV]=new x1("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach((Z)=>{D1[Z]=new x1(Z,1,!1,Z.toLowerCase(),null,!0,!0)});var{CAMELCASE:gV,SAME:hV,possibleStandardNames:pH}=uH(),vV=":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",yV=vV+"\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040",mV=RegExp.prototype.test.bind(new RegExp("^(data|aria)-["+yV+"]*$")),fV=Object.keys(pH).reduce((Z,J)=>{let X=pH[J];if(X===hV)Z[J]=J;else if(X===gV)Z[J.toLowerCase()]=J;else Z[J]=X;return Z},{});uV.BOOLEAN=3;uV.BOOLEANISH_STRING=2;uV.NUMERIC=5;uV.OVERLOADED_BOOLEAN=4;uV.POSITIVE_NUMERIC=6;uV.RESERVED=0;uV.STRING=1;uV.getPropertyInfo=xV;uV.isCustomAttribute=mV;uV.possibleStandardNames=fV});var rH=x((vj,aH)=>{var dH=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,tV=/\n/g,eV=/^\s*/,ZA=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,JA=/^:\s*/,XA=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,YA=/^[;\s]*/,GA=/^\s+|\s+$/g,WA=`
|
|
10
|
+
`,cH="/",iH="*",L5="",HA="comment",QA="declaration";function KA(Z,J){if(typeof Z!=="string")throw TypeError("First argument must be a string");if(!Z)return[];J=J||{};var X=1,Y=1;function G(M){var F=M.match(tV);if(F)X+=F.length;var D=M.lastIndexOf(WA);Y=~D?M.length-D:Y+M.length}function W(){var M={line:X,column:Y};return function(F){return F.position=new H(M),U(),F}}function H(M){this.start=M,this.end={line:X,column:Y},this.source=J.source}H.prototype.content=Z;function Q(M){var F=Error(J.source+":"+X+":"+Y+": "+M);if(F.reason=M,F.filename=J.source,F.line=X,F.column=Y,F.source=Z,J.silent);else throw F}function K(M){var F=M.exec(Z);if(!F)return;var D=F[0];return G(D),Z=Z.slice(D.length),F}function U(){K(eV)}function $(M){var F;M=M||[];while(F=L())if(F!==!1)M.push(F);return M}function L(){var M=W();if(cH!=Z.charAt(0)||iH!=Z.charAt(1))return;var F=2;while(L5!=Z.charAt(F)&&(iH!=Z.charAt(F)||cH!=Z.charAt(F+1)))++F;if(F+=2,L5===Z.charAt(F-1))return Q("End of comment missing");var D=Z.slice(2,F-2);return Y+=2,G(D),Z=Z.slice(F),Y+=2,M({type:HA,comment:D})}function z(){var M=W(),F=K(ZA);if(!F)return;if(L(),!K(JA))return Q("property missing ':'");var D=K(XA),q=M({type:QA,property:nH(F[0].replace(dH,L5)),value:D?nH(D[0].replace(dH,L5)):L5});return K(YA),q}function B(){var M=[];$(M);var F;while(F=z())if(F!==!1)M.push(F),$(M);return M}return U(),B()}function nH(Z){return Z?Z.replace(GA,L5):L5}aH.exports=KA});var sH=x((x6)=>{var UA=x6&&x6.__importDefault||function(Z){return Z&&Z.__esModule?Z:{default:Z}};Object.defineProperty(x6,"__esModule",{value:!0});x6.default=LA;var $A=UA(rH());function LA(Z,J){let X=null;if(!Z||typeof Z!=="string")return X;let Y=(0,$A.default)(Z),G=typeof J==="function";return Y.forEach((W)=>{if(W.type!=="declaration")return;let{property:H,value:Q}=W;if(G)J(H,Q,W);else if(Q)X=X||{},X[H]=Q}),X}});var Z2=x((tH)=>{Object.defineProperty(tH,"__esModule",{value:!0});tH.camelCase=void 0;var BA=/^--[a-zA-Z0-9_-]+$/,zA=/-([a-z])/g,MA=/^[^-]+$/,FA=/^-(webkit|moz|ms|o|khtml)-/,NA=/^-(ms)-/,VA=function(Z){return!Z||MA.test(Z)||BA.test(Z)},AA=function(Z,J){return J.toUpperCase()},oH=function(Z,J){return"".concat(J,"-")},DA=function(Z,J){if(J===void 0)J={};if(VA(Z))return Z;if(Z=Z.toLowerCase(),J.reactCompat)Z=Z.replace(NA,oH);else Z=Z.replace(FA,oH);return Z.replace(zA,AA)};tH.camelCase=DA});var SZ=x((_Z,J2)=>{var qA=_Z&&_Z.__importDefault||function(Z){return Z&&Z.__esModule?Z:{default:Z}},RA=qA(sH()),IA=Z2();function wZ(Z,J){var X={};if(!Z||typeof Z!=="string")return X;return(0,RA.default)(Z,function(Y,G){if(Y&&G)X[(0,IA.camelCase)(Y,J)]=G}),X}wZ.default=wZ;J2.exports=wZ});import*as X2 from"react";var CZ=x((b1)=>{var OA=b1&&b1.__importDefault||function(Z){return Z&&Z.__esModule?Z:{default:Z}};Object.defineProperty(b1,"__esModule",{value:!0});b1.returnFirstArg=b1.canTextBeChildOfNode=b1.ELEMENTS_WITH_NO_TEXT_CHILDREN=b1.PRESERVE_CUSTOM_ATTRIBUTES=void 0;b1.isCustomComponent=wA;b1.setStyleProp=SA;var TA=OA(SZ()),PA=new Set(["annotation-xml","color-profile","font-face","font-face-src","font-face-uri","font-face-format","font-face-name","missing-glyph"]);function wA(Z,J){if(!Z.includes("-"))return Boolean(J&&typeof J.is==="string");if(PA.has(Z))return!1;return!0}var _A={reactCompat:!0};function SA(Z,J){if(typeof Z!=="string")return;if(!Z.trim()){J.style={};return}try{J.style=(0,TA.default)(Z,_A)}catch(X){J.style={}}}b1.PRESERVE_CUSTOM_ATTRIBUTES=Number(X2.version.split(".")[0])>=16;b1.ELEMENTS_WITH_NO_TEXT_CHILDREN=new Set(["tr","tbody","thead","tfoot","colgroup","table","head","html","frameset"]);var CA=function(Z){return!b1.ELEMENTS_WITH_NO_TEXT_CHILDREN.has(Z.name)};b1.canTextBeChildOfNode=CA;var EA=function(Z){return Z};b1.returnFirstArg=EA});var EZ=x((W2)=>{Object.defineProperty(W2,"__esModule",{value:!0});W2.default=kA;var b6=lH(),Y2=CZ(),jA=["checked","value"],xA=["input","select","textarea"],bA={reset:!0,submit:!0};function kA(Z,J){if(Z===void 0)Z={};var X={},Y=Boolean(Z.type&&bA[Z.type]);for(var G in Z){var W=Z[G];if((0,b6.isCustomAttribute)(G)){X[G]=W;continue}var H=G.toLowerCase(),Q=G2(H);if(Q){var K=(0,b6.getPropertyInfo)(Q);if(jA.includes(Q)&&xA.includes(J)&&!Y)Q=G2("default"+H);switch(X[Q]=W,K&&K.type){case b6.BOOLEAN:X[Q]=!0;break;case b6.OVERLOADED_BOOLEAN:if(W==="")X[Q]=!0;break}continue}if(Y2.PRESERVE_CUSTOM_ATTRIBUTES)X[G]=W}return(0,Y2.setStyleProp)(Z.style,X),X}function G2(Z){return b6.possibleStandardNames[Z]}});import*as y5 from"react";var Q2=x((g6)=>{var hA=g6&&g6.__importDefault||function(Z){return Z&&Z.__esModule?Z:{default:Z}};Object.defineProperty(g6,"__esModule",{value:!0});g6.default=H2;var vA=hA(EZ()),k6=CZ(),yA={cloneElement:y5.cloneElement,createElement:y5.createElement,isValidElement:y5.isValidElement};function H2(Z,J){if(J===void 0)J={};var X=[],Y=typeof J.replace==="function",G=J.transform||k6.returnFirstArg,W=J.library||yA,H=W.cloneElement,Q=W.createElement,K=W.isValidElement,U=Z.length;for(var $=0;$<U;$++){var L=Z[$];if(Y){var z=J.replace(L,$);if(K(z)){if(U>1)z=H(z,{key:z.key||$});X.push(G(z,L,$));continue}}if(L.type==="text"){var B=!L.data.trim().length;if(B&&L.parent&&!(0,k6.canTextBeChildOfNode)(L.parent))continue;if(J.trim&&B)continue;X.push(G(L.data,L,$));continue}var M=L,F={};if(mA(M))(0,k6.setStyleProp)(M.attribs.style,M.attribs),F=M.attribs;else if(M.attribs)F=(0,vA.default)(M.attribs,M.name);var D=void 0;switch(L.type){case"script":case"style":if(L.children[0])F.dangerouslySetInnerHTML={__html:L.children[0].data};break;case"tag":if(L.name==="textarea"&&L.children[0])F.defaultValue=L.children[0].data;else if(L.children&&L.children.length)D=H2(L.children,J);break;default:continue}if(U>1)F.key=$;X.push(G(Q(L.name,F,D),L,$))}return X.length===1?X[0]:X}function mA(Z){return k6.PRESERVE_CUSTOM_ATTRIBUTES&&Z.type==="tag"&&(0,k6.isCustomComponent)(Z.name,Z.attribs)}});var xZ=x((F1)=>{var jZ=F1&&F1.__importDefault||function(Z){return Z&&Z.__esModule?Z:{default:Z}};Object.defineProperty(F1,"__esModule",{value:!0});F1.htmlToDOM=F1.domToReact=F1.attributesToProps=F1.Text=F1.ProcessingInstruction=F1.Element=F1.Comment=void 0;F1.default=pA;var K2=jZ(fH());F1.htmlToDOM=K2.default;var fA=jZ(EZ());F1.attributesToProps=fA.default;var U2=jZ(Q2());F1.domToReact=U2.default;var $8=AZ();Object.defineProperty(F1,"Comment",{enumerable:!0,get:function(){return $8.Comment}});Object.defineProperty(F1,"Element",{enumerable:!0,get:function(){return $8.Element}});Object.defineProperty(F1,"ProcessingInstruction",{enumerable:!0,get:function(){return $8.ProcessingInstruction}});Object.defineProperty(F1,"Text",{enumerable:!0,get:function(){return $8.Text}});var uA={lowerCaseAttributeNames:!1};function pA(Z,J){if(typeof Z!=="string")throw TypeError("First argument must be a string");if(!Z)return[];return(0,U2.default)((0,K2.default)(Z,(J===null||J===void 0?void 0:J.htmlparser2)||uA),J)}});var XK=x((Cm,JK)=>{var i8=Object.prototype.hasOwnProperty,ZK=Object.prototype.toString,aQ=Object.defineProperty,rQ=Object.getOwnPropertyDescriptor,sQ=function(J){if(typeof Array.isArray==="function")return Array.isArray(J);return ZK.call(J)==="[object Array]"},oQ=function(J){if(!J||ZK.call(J)!=="[object Object]")return!1;var X=i8.call(J,"constructor"),Y=J.constructor&&J.constructor.prototype&&i8.call(J.constructor.prototype,"isPrototypeOf");if(J.constructor&&!X&&!Y)return!1;var G;for(G in J);return typeof G>"u"||i8.call(J,G)},tQ=function(J,X){if(aQ&&X.name==="__proto__")aQ(J,X.name,{enumerable:!0,configurable:!0,value:X.newValue,writable:!0});else J[X.name]=X.newValue},eQ=function(J,X){if(X==="__proto__"){if(!i8.call(J,X))return;else if(rQ)return rQ(J,X).value}return J[X]};JK.exports=function Z(){var J,X,Y,G,W,H,Q=arguments[0],K=1,U=arguments.length,$=!1;if(typeof Q==="boolean")$=Q,Q=arguments[1]||{},K=2;if(Q==null||typeof Q!=="object"&&typeof Q!=="function")Q={};for(;K<U;++K)if(J=arguments[K],J!=null){for(X in J)if(Y=eQ(Q,X),G=eQ(J,X),Q!==G){if($&&G&&(oQ(G)||(W=sQ(G)))){if(W)W=!1,H=Y&&sQ(Y)?Y:[];else H=Y&&oQ(Y)?Y:{};tQ(Q,{name:X,newValue:Z($,H,G)})}else if(typeof G<"u")tQ(Q,{name:X,newValue:G})}}return Q}});var rK={};U9(rK,{default:()=>TI,__values:()=>t8,__spreadArrays:()=>gK,__spreadArray:()=>hK,__spread:()=>kK,__setFunctionName:()=>CK,__runInitializers:()=>_K,__rewriteRelativeImportExtension:()=>aK,__rest:()=>OK,__read:()=>fJ,__propKey:()=>SK,__param:()=>PK,__metadata:()=>EK,__makeTemplateObject:()=>fK,__importStar:()=>uK,__importDefault:()=>pK,__generator:()=>xK,__extends:()=>IK,__exportStar:()=>bK,__esDecorate:()=>wK,__disposeResources:()=>nK,__decorate:()=>TK,__createBinding:()=>e8,__classPrivateFieldSet:()=>dK,__classPrivateFieldIn:()=>cK,__classPrivateFieldGet:()=>lK,__awaiter:()=>jK,__await:()=>s5,__asyncValues:()=>mK,__asyncGenerator:()=>vK,__asyncDelegator:()=>yK,__assign:()=>o8,__addDisposableResource:()=>iK});function IK(Z,J){if(typeof J!=="function"&&J!==null)throw TypeError("Class extends value "+String(J)+" is not a constructor or null");yJ(Z,J);function X(){this.constructor=Z}Z.prototype=J===null?Object.create(J):(X.prototype=J.prototype,new X)}function OK(Z,J){var X={};for(var Y in Z)if(Object.prototype.hasOwnProperty.call(Z,Y)&&J.indexOf(Y)<0)X[Y]=Z[Y];if(Z!=null&&typeof Object.getOwnPropertySymbols==="function"){for(var G=0,Y=Object.getOwnPropertySymbols(Z);G<Y.length;G++)if(J.indexOf(Y[G])<0&&Object.prototype.propertyIsEnumerable.call(Z,Y[G]))X[Y[G]]=Z[Y[G]]}return X}function TK(Z,J,X,Y){var G=arguments.length,W=G<3?J:Y===null?Y=Object.getOwnPropertyDescriptor(J,X):Y,H;if(typeof Reflect==="object"&&typeof Reflect.decorate==="function")W=Reflect.decorate(Z,J,X,Y);else for(var Q=Z.length-1;Q>=0;Q--)if(H=Z[Q])W=(G<3?H(W):G>3?H(J,X,W):H(J,X))||W;return G>3&&W&&Object.defineProperty(J,X,W),W}function PK(Z,J){return function(X,Y){J(X,Y,Z)}}function wK(Z,J,X,Y,G,W){function H(q){if(q!==void 0&&typeof q!=="function")throw TypeError("Function expected");return q}var Q=Y.kind,K=Q==="getter"?"get":Q==="setter"?"set":"value",U=!J&&Z?Y.static?Z:Z.prototype:null,$=J||(U?Object.getOwnPropertyDescriptor(U,Y.name):{}),L,z=!1;for(var B=X.length-1;B>=0;B--){var M={};for(var F in Y)M[F]=F==="access"?{}:Y[F];for(var F in Y.access)M.access[F]=Y.access[F];M.addInitializer=function(q){if(z)throw TypeError("Cannot add initializers after decoration has completed");W.push(H(q||null))};var D=(0,X[B])(Q==="accessor"?{get:$.get,set:$.set}:$[K],M);if(Q==="accessor"){if(D===void 0)continue;if(D===null||typeof D!=="object")throw TypeError("Object expected");if(L=H(D.get))$.get=L;if(L=H(D.set))$.set=L;if(L=H(D.init))G.unshift(L)}else if(L=H(D))if(Q==="field")G.unshift(L);else $[K]=L}if(U)Object.defineProperty(U,Y.name,$);z=!0}function _K(Z,J,X){var Y=arguments.length>2;for(var G=0;G<J.length;G++)X=Y?J[G].call(Z,X):J[G].call(Z);return Y?X:void 0}function SK(Z){return typeof Z==="symbol"?Z:"".concat(Z)}function CK(Z,J,X){if(typeof J==="symbol")J=J.description?"[".concat(J.description,"]"):"";return Object.defineProperty(Z,"name",{configurable:!0,value:X?"".concat(X," ",J):J})}function EK(Z,J){if(typeof Reflect==="object"&&typeof Reflect.metadata==="function")return Reflect.metadata(Z,J)}function jK(Z,J,X,Y){function G(W){return W instanceof X?W:new X(function(H){H(W)})}return new(X||(X=Promise))(function(W,H){function Q($){try{U(Y.next($))}catch(L){H(L)}}function K($){try{U(Y.throw($))}catch(L){H(L)}}function U($){$.done?W($.value):G($.value).then(Q,K)}U((Y=Y.apply(Z,J||[])).next())})}function xK(Z,J){var X={label:0,sent:function(){if(W[0]&1)throw W[1];return W[1]},trys:[],ops:[]},Y,G,W,H=Object.create((typeof Iterator==="function"?Iterator:Object).prototype);return H.next=Q(0),H.throw=Q(1),H.return=Q(2),typeof Symbol==="function"&&(H[Symbol.iterator]=function(){return this}),H;function Q(U){return function($){return K([U,$])}}function K(U){if(Y)throw TypeError("Generator is already executing.");while(H&&(H=0,U[0]&&(X=0)),X)try{if(Y=1,G&&(W=U[0]&2?G.return:U[0]?G.throw||((W=G.return)&&W.call(G),0):G.next)&&!(W=W.call(G,U[1])).done)return W;if(G=0,W)U=[U[0]&2,W.value];switch(U[0]){case 0:case 1:W=U;break;case 4:return X.label++,{value:U[1],done:!1};case 5:X.label++,G=U[1],U=[0];continue;case 7:U=X.ops.pop(),X.trys.pop();continue;default:if((W=X.trys,!(W=W.length>0&&W[W.length-1]))&&(U[0]===6||U[0]===2)){X=0;continue}if(U[0]===3&&(!W||U[1]>W[0]&&U[1]<W[3])){X.label=U[1];break}if(U[0]===6&&X.label<W[1]){X.label=W[1],W=U;break}if(W&&X.label<W[2]){X.label=W[2],X.ops.push(U);break}if(W[2])X.ops.pop();X.trys.pop();continue}U=J.call(Z,X)}catch($){U=[6,$],G=0}finally{Y=W=0}if(U[0]&5)throw U[1];return{value:U[0]?U[1]:void 0,done:!0}}}function bK(Z,J){for(var X in Z)if(X!=="default"&&!Object.prototype.hasOwnProperty.call(J,X))e8(J,Z,X)}function t8(Z){var J=typeof Symbol==="function"&&Symbol.iterator,X=J&&Z[J],Y=0;if(X)return X.call(Z);if(Z&&typeof Z.length==="number")return{next:function(){if(Z&&Y>=Z.length)Z=void 0;return{value:Z&&Z[Y++],done:!Z}}};throw TypeError(J?"Object is not iterable.":"Symbol.iterator is not defined.")}function fJ(Z,J){var X=typeof Symbol==="function"&&Z[Symbol.iterator];if(!X)return Z;var Y=X.call(Z),G,W=[],H;try{while((J===void 0||J-- >0)&&!(G=Y.next()).done)W.push(G.value)}catch(Q){H={error:Q}}finally{try{if(G&&!G.done&&(X=Y.return))X.call(Y)}finally{if(H)throw H.error}}return W}function kK(){for(var Z=[],J=0;J<arguments.length;J++)Z=Z.concat(fJ(arguments[J]));return Z}function gK(){for(var Z=0,J=0,X=arguments.length;J<X;J++)Z+=arguments[J].length;for(var Y=Array(Z),G=0,J=0;J<X;J++)for(var W=arguments[J],H=0,Q=W.length;H<Q;H++,G++)Y[G]=W[H];return Y}function hK(Z,J,X){if(X||arguments.length===2){for(var Y=0,G=J.length,W;Y<G;Y++)if(W||!(Y in J)){if(!W)W=Array.prototype.slice.call(J,0,Y);W[Y]=J[Y]}}return Z.concat(W||Array.prototype.slice.call(J))}function s5(Z){return this instanceof s5?(this.v=Z,this):new s5(Z)}function vK(Z,J,X){if(!Symbol.asyncIterator)throw TypeError("Symbol.asyncIterator is not defined.");var Y=X.apply(Z,J||[]),G,W=[];return G=Object.create((typeof AsyncIterator==="function"?AsyncIterator:Object).prototype),Q("next"),Q("throw"),Q("return",H),G[Symbol.asyncIterator]=function(){return this},G;function H(B){return function(M){return Promise.resolve(M).then(B,L)}}function Q(B,M){if(Y[B]){if(G[B]=function(F){return new Promise(function(D,q){W.push([B,F,D,q])>1||K(B,F)})},M)G[B]=M(G[B])}}function K(B,M){try{U(Y[B](M))}catch(F){z(W[0][3],F)}}function U(B){B.value instanceof s5?Promise.resolve(B.value.v).then($,L):z(W[0][2],B)}function $(B){K("next",B)}function L(B){K("throw",B)}function z(B,M){if(B(M),W.shift(),W.length)K(W[0][0],W[0][1])}}function yK(Z){var J,X;return J={},Y("next"),Y("throw",function(G){throw G}),Y("return"),J[Symbol.iterator]=function(){return this},J;function Y(G,W){J[G]=Z[G]?function(H){return(X=!X)?{value:s5(Z[G](H)),done:!1}:W?W(H):H}:W}}function mK(Z){if(!Symbol.asyncIterator)throw TypeError("Symbol.asyncIterator is not defined.");var J=Z[Symbol.asyncIterator],X;return J?J.call(Z):(Z=typeof t8==="function"?t8(Z):Z[Symbol.iterator](),X={},Y("next"),Y("throw"),Y("return"),X[Symbol.asyncIterator]=function(){return this},X);function Y(W){X[W]=Z[W]&&function(H){return new Promise(function(Q,K){H=Z[W](H),G(Q,K,H.done,H.value)})}}function G(W,H,Q,K){Promise.resolve(K).then(function(U){W({value:U,done:Q})},H)}}function fK(Z,J){if(Object.defineProperty)Object.defineProperty(Z,"raw",{value:J});else Z.raw=J;return Z}function uK(Z){if(Z&&Z.__esModule)return Z;var J={};if(Z!=null){for(var X=mJ(Z),Y=0;Y<X.length;Y++)if(X[Y]!=="default")e8(J,Z,X[Y])}return II(J,Z),J}function pK(Z){return Z&&Z.__esModule?Z:{default:Z}}function lK(Z,J,X,Y){if(X==="a"&&!Y)throw TypeError("Private accessor was defined without a getter");if(typeof J==="function"?Z!==J||!Y:!J.has(Z))throw TypeError("Cannot read private member from an object whose class did not declare it");return X==="m"?Y:X==="a"?Y.call(Z):Y?Y.value:J.get(Z)}function dK(Z,J,X,Y,G){if(Y==="m")throw TypeError("Private method is not writable");if(Y==="a"&&!G)throw TypeError("Private accessor was defined without a setter");if(typeof J==="function"?Z!==J||!G:!J.has(Z))throw TypeError("Cannot write private member to an object whose class did not declare it");return Y==="a"?G.call(Z,X):G?G.value=X:J.set(Z,X),X}function cK(Z,J){if(J===null||typeof J!=="object"&&typeof J!=="function")throw TypeError("Cannot use 'in' operator on non-object");return typeof Z==="function"?J===Z:Z.has(J)}function iK(Z,J,X){if(J!==null&&J!==void 0){if(typeof J!=="object"&&typeof J!=="function")throw TypeError("Object expected.");var Y,G;if(X){if(!Symbol.asyncDispose)throw TypeError("Symbol.asyncDispose is not defined.");Y=J[Symbol.asyncDispose]}if(Y===void 0){if(!Symbol.dispose)throw TypeError("Symbol.dispose is not defined.");if(Y=J[Symbol.dispose],X)G=Y}if(typeof Y!=="function")throw TypeError("Object not disposable.");if(G)Y=function(){try{G.call(this)}catch(W){return Promise.reject(W)}};Z.stack.push({value:J,dispose:Y,async:X})}else if(X)Z.stack.push({async:!0});return J}function nK(Z){function J(W){Z.error=Z.hasError?new OI(W,Z.error,"An error was suppressed during disposal."):W,Z.hasError=!0}var X,Y=0;function G(){while(X=Z.stack.pop())try{if(!X.async&&Y===1)return Y=0,Z.stack.push(X),Promise.resolve().then(G);if(X.dispose){var W=X.dispose.call(X.value);if(X.async)return Y|=2,Promise.resolve(W).then(G,function(H){return J(H),G()})}else Y|=1}catch(H){J(H)}if(Y===1)return Z.hasError?Promise.reject(Z.error):Promise.resolve();if(Z.hasError)throw Z.error}return G()}function aK(Z,J){if(typeof Z==="string"&&/^\.\.?\//.test(Z))return Z.replace(/\.(tsx)$|((?:\.d)?)((?:\.[^./]+?)?)\.([cm]?)ts$/i,function(X,Y,G,W,H){return Y?J?".jsx":".js":G&&(!W||!H)?X:G+W+"."+H.toLowerCase()+"js"});return Z}var yJ=function(Z,J){return yJ=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(X,Y){X.__proto__=Y}||function(X,Y){for(var G in Y)if(Object.prototype.hasOwnProperty.call(Y,G))X[G]=Y[G]},yJ(Z,J)},o8=function(){return o8=Object.assign||function(J){for(var X,Y=1,G=arguments.length;Y<G;Y++){X=arguments[Y];for(var W in X)if(Object.prototype.hasOwnProperty.call(X,W))J[W]=X[W]}return J},o8.apply(this,arguments)},e8,II,mJ=function(Z){return mJ=Object.getOwnPropertyNames||function(J){var X=[];for(var Y in J)if(Object.prototype.hasOwnProperty.call(J,Y))X[X.length]=Y;return X},mJ(Z)},OI,TI;var sK=LX(()=>{e8=Object.create?function(Z,J,X,Y){if(Y===void 0)Y=X;var G=Object.getOwnPropertyDescriptor(J,X);if(!G||("get"in G?!J.__esModule:G.writable||G.configurable))G={enumerable:!0,get:function(){return J[X]}};Object.defineProperty(Z,Y,G)}:function(Z,J,X,Y){if(Y===void 0)Y=X;Z[Y]=J[X]};II=Object.create?function(Z,J){Object.defineProperty(Z,"default",{enumerable:!0,value:J})}:function(Z,J){Z.default=J};OI=typeof SuppressedError==="function"?SuppressedError:function(Z,J,X){var Y=Error(X);return Y.name="SuppressedError",Y.error=Z,Y.suppressed=J,Y};TI={__extends:IK,__assign:o8,__rest:OK,__decorate:TK,__param:PK,__esDecorate:wK,__runInitializers:_K,__propKey:SK,__setFunctionName:CK,__metadata:EK,__awaiter:jK,__generator:xK,__createBinding:e8,__exportStar:bK,__values:t8,__read:fJ,__spread:kK,__spreadArrays:gK,__spreadArray:hK,__await:s5,__asyncGenerator:vK,__asyncDelegator:yK,__asyncValues:mK,__makeTemplateObject:fK,__importStar:uK,__importDefault:pK,__classPrivateFieldGet:lK,__classPrivateFieldSet:dK,__classPrivateFieldIn:cK,__addDisposableResource:iK,__disposeResources:nK,__rewriteRelativeImportExtension:aK}});var vU=x((Ru,hU)=>{/*! Axios v1.13.4 Copyright (c) 2026 Matt Zabriskie and contributors */function zU(Z,J){return function(){return Z.apply(J,arguments)}}var{toString:PI}=Object.prototype,{getPrototypeOf:aJ}=Object,{iterator:H7,toStringTag:MU}=Symbol,Q7=((Z)=>(J)=>{let X=PI.call(J);return Z[X]||(Z[X]=X.slice(8,-1).toLowerCase())})(Object.create(null)),B0=(Z)=>{return Z=Z.toLowerCase(),(J)=>Q7(J)===Z},K7=(Z)=>(J)=>typeof J===Z,{isArray:t5}=Array,o5=K7("undefined");function Y9(Z){return Z!==null&&!o5(Z)&&Z.constructor!==null&&!o5(Z.constructor)&&u1(Z.constructor.isBuffer)&&Z.constructor.isBuffer(Z)}var FU=B0("ArrayBuffer");function wI(Z){let J;if(typeof ArrayBuffer<"u"&&ArrayBuffer.isView)J=ArrayBuffer.isView(Z);else J=Z&&Z.buffer&&FU(Z.buffer);return J}var _I=K7("string"),u1=K7("function"),NU=K7("number"),G9=(Z)=>Z!==null&&typeof Z==="object",SI=(Z)=>Z===!0||Z===!1,J7=(Z)=>{if(Q7(Z)!=="object")return!1;let J=aJ(Z);return(J===null||J===Object.prototype||Object.getPrototypeOf(J)===null)&&!(MU in Z)&&!(H7 in Z)},CI=(Z)=>{if(!G9(Z)||Y9(Z))return!1;try{return Object.keys(Z).length===0&&Object.getPrototypeOf(Z)===Object.prototype}catch(J){return!1}},EI=B0("Date"),jI=B0("File"),xI=B0("Blob"),bI=B0("FileList"),kI=(Z)=>G9(Z)&&u1(Z.pipe),gI=(Z)=>{let J;return Z&&(typeof FormData==="function"&&Z instanceof FormData||u1(Z.append)&&((J=Q7(Z))==="formdata"||J==="object"&&u1(Z.toString)&&Z.toString()==="[object FormData]"))},hI=B0("URLSearchParams"),[vI,yI,mI,fI]=["ReadableStream","Request","Response","Headers"].map(B0),uI=(Z)=>Z.trim?Z.trim():Z.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function W9(Z,J,{allOwnKeys:X=!1}={}){if(Z===null||typeof Z>"u")return;let Y,G;if(typeof Z!=="object")Z=[Z];if(t5(Z))for(Y=0,G=Z.length;Y<G;Y++)J.call(null,Z[Y],Y,Z);else{if(Y9(Z))return;let W=X?Object.getOwnPropertyNames(Z):Object.keys(Z),H=W.length,Q;for(Y=0;Y<H;Y++)Q=W[Y],J.call(null,Z[Q],Q,Z)}}function VU(Z,J){if(Y9(Z))return null;J=J.toLowerCase();let X=Object.keys(Z),Y=X.length,G;while(Y-- >0)if(G=X[Y],J===G.toLowerCase())return G;return null}var D5=(()=>{if(typeof globalThis<"u")return globalThis;return typeof self<"u"?self:typeof window<"u"?window:global})(),AU=(Z)=>!o5(Z)&&Z!==D5;function dJ(){let{caseless:Z,skipUndefined:J}=AU(this)&&this||{},X={},Y=(G,W)=>{let H=Z&&VU(X,W)||W;if(J7(X[H])&&J7(G))X[H]=dJ(X[H],G);else if(J7(G))X[H]=dJ({},G);else if(t5(G))X[H]=G.slice();else if(!J||!o5(G))X[H]=G};for(let G=0,W=arguments.length;G<W;G++)arguments[G]&&W9(arguments[G],Y);return X}var pI=(Z,J,X,{allOwnKeys:Y}={})=>{return W9(J,(G,W)=>{if(X&&u1(G))Object.defineProperty(Z,W,{value:zU(G,X),writable:!0,enumerable:!0,configurable:!0});else Object.defineProperty(Z,W,{value:G,writable:!0,enumerable:!0,configurable:!0})},{allOwnKeys:Y}),Z},lI=(Z)=>{if(Z.charCodeAt(0)===65279)Z=Z.slice(1);return Z},dI=(Z,J,X,Y)=>{Z.prototype=Object.create(J.prototype,Y),Object.defineProperty(Z.prototype,"constructor",{value:Z,writable:!0,enumerable:!1,configurable:!0}),Object.defineProperty(Z,"super",{value:J.prototype}),X&&Object.assign(Z.prototype,X)},cI=(Z,J,X,Y)=>{let G,W,H,Q={};if(J=J||{},Z==null)return J;do{G=Object.getOwnPropertyNames(Z),W=G.length;while(W-- >0)if(H=G[W],(!Y||Y(H,Z,J))&&!Q[H])J[H]=Z[H],Q[H]=!0;Z=X!==!1&&aJ(Z)}while(Z&&(!X||X(Z,J))&&Z!==Object.prototype);return J},iI=(Z,J,X)=>{if(Z=String(Z),X===void 0||X>Z.length)X=Z.length;X-=J.length;let Y=Z.indexOf(J,X);return Y!==-1&&Y===X},nI=(Z)=>{if(!Z)return null;if(t5(Z))return Z;let J=Z.length;if(!NU(J))return null;let X=Array(J);while(J-- >0)X[J]=Z[J];return X},aI=((Z)=>{return(J)=>{return Z&&J instanceof Z}})(typeof Uint8Array<"u"&&aJ(Uint8Array)),rI=(Z,J)=>{let Y=(Z&&Z[H7]).call(Z),G;while((G=Y.next())&&!G.done){let W=G.value;J.call(Z,W[0],W[1])}},sI=(Z,J)=>{let X,Y=[];while((X=Z.exec(J))!==null)Y.push(X);return Y},oI=B0("HTMLFormElement"),tI=(Z)=>{return Z.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(X,Y,G){return Y.toUpperCase()+G})},oK=(({hasOwnProperty:Z})=>(J,X)=>Z.call(J,X))(Object.prototype),eI=B0("RegExp"),DU=(Z,J)=>{let X=Object.getOwnPropertyDescriptors(Z),Y={};W9(X,(G,W)=>{let H;if((H=J(G,W,Z))!==!1)Y[W]=H||G}),Object.defineProperties(Z,Y)},ZO=(Z)=>{DU(Z,(J,X)=>{if(u1(Z)&&["arguments","caller","callee"].indexOf(X)!==-1)return!1;let Y=Z[X];if(!u1(Y))return;if(J.enumerable=!1,"writable"in J){J.writable=!1;return}if(!J.set)J.set=()=>{throw Error("Can not rewrite read-only method '"+X+"'")}})},JO=(Z,J)=>{let X={},Y=(G)=>{G.forEach((W)=>{X[W]=!0})};return t5(Z)?Y(Z):Y(String(Z).split(J)),X},XO=()=>{},YO=(Z,J)=>{return Z!=null&&Number.isFinite(Z=+Z)?Z:J};function GO(Z){return!!(Z&&u1(Z.append)&&Z[MU]==="FormData"&&Z[H7])}var WO=(Z)=>{let J=[,,,,,,,,,,],X=(Y,G)=>{if(G9(Y)){if(J.indexOf(Y)>=0)return;if(Y9(Y))return Y;if(!("toJSON"in Y)){J[G]=Y;let W=t5(Y)?[]:{};return W9(Y,(H,Q)=>{let K=X(H,G+1);!o5(K)&&(W[Q]=K)}),J[G]=void 0,W}}return Y};return X(Z,0)},HO=B0("AsyncFunction"),QO=(Z)=>Z&&(G9(Z)||u1(Z))&&u1(Z.then)&&u1(Z.catch),qU=((Z,J)=>{if(Z)return setImmediate;return J?((X,Y)=>{return D5.addEventListener("message",({source:G,data:W})=>{if(G===D5&&W===X)Y.length&&Y.shift()()},!1),(G)=>{Y.push(G),D5.postMessage(X,"*")}})(`axios@${Math.random()}`,[]):(X)=>setTimeout(X)})(typeof setImmediate==="function",u1(D5.postMessage)),KO=typeof queueMicrotask<"u"?queueMicrotask.bind(D5):typeof process<"u"&&process.nextTick||qU,UO=(Z)=>Z!=null&&u1(Z[H7]),R={isArray:t5,isArrayBuffer:FU,isBuffer:Y9,isFormData:gI,isArrayBufferView:wI,isString:_I,isNumber:NU,isBoolean:SI,isObject:G9,isPlainObject:J7,isEmptyObject:CI,isReadableStream:vI,isRequest:yI,isResponse:mI,isHeaders:fI,isUndefined:o5,isDate:EI,isFile:jI,isBlob:xI,isRegExp:eI,isFunction:u1,isStream:kI,isURLSearchParams:hI,isTypedArray:aI,isFileList:bI,forEach:W9,merge:dJ,extend:pI,trim:uI,stripBOM:lI,inherits:dI,toFlatObject:cI,kindOf:Q7,kindOfTest:B0,endsWith:iI,toArray:nI,forEachEntry:rI,matchAll:sI,isHTMLForm:oI,hasOwnProperty:oK,hasOwnProp:oK,reduceDescriptors:DU,freezeMethods:ZO,toObjectSet:JO,toCamelCase:tI,noop:XO,toFiniteNumber:YO,findKey:VU,global:D5,isContextDefined:AU,isSpecCompliantForm:GO,toJSONObject:WO,isAsyncFn:HO,isThenable:QO,setImmediate:qU,asap:KO,isIterable:UO};class h1 extends Error{static from(Z,J,X,Y,G,W){let H=new h1(Z.message,J||Z.code,X,Y,G);return H.cause=Z,H.name=Z.name,W&&Object.assign(H,W),H}constructor(Z,J,X,Y,G){super(Z);if(this.name="AxiosError",this.isAxiosError=!0,J&&(this.code=J),X&&(this.config=X),Y&&(this.request=Y),G)this.response=G,this.status=G.status}toJSON(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:R.toJSONObject(this.config),code:this.code,status:this.status}}}h1.ERR_BAD_OPTION_VALUE="ERR_BAD_OPTION_VALUE";h1.ERR_BAD_OPTION="ERR_BAD_OPTION";h1.ECONNABORTED="ECONNABORTED";h1.ETIMEDOUT="ETIMEDOUT";h1.ERR_NETWORK="ERR_NETWORK";h1.ERR_FR_TOO_MANY_REDIRECTS="ERR_FR_TOO_MANY_REDIRECTS";h1.ERR_DEPRECATED="ERR_DEPRECATED";h1.ERR_BAD_RESPONSE="ERR_BAD_RESPONSE";h1.ERR_BAD_REQUEST="ERR_BAD_REQUEST";h1.ERR_CANCELED="ERR_CANCELED";h1.ERR_NOT_SUPPORT="ERR_NOT_SUPPORT";h1.ERR_INVALID_URL="ERR_INVALID_URL";var s=h1,$O=null;function cJ(Z){return R.isPlainObject(Z)||R.isArray(Z)}function RU(Z){return R.endsWith(Z,"[]")?Z.slice(0,-2):Z}function tK(Z,J,X){if(!Z)return J;return Z.concat(J).map(function(G,W){return G=RU(G),!X&&W?"["+G+"]":G}).join(X?".":"")}function LO(Z){return R.isArray(Z)&&!Z.some(cJ)}var BO=R.toFlatObject(R,{},null,function(J){return/^is[A-Z]/.test(J)});function U7(Z,J,X){if(!R.isObject(Z))throw TypeError("target must be an object");J=J||new FormData,X=R.toFlatObject(X,{metaTokens:!0,dots:!1,indexes:!1},!1,function(F,D){return!R.isUndefined(D[F])});let Y=X.metaTokens,G=X.visitor||$,W=X.dots,H=X.indexes,K=(X.Blob||typeof Blob<"u"&&Blob)&&R.isSpecCompliantForm(J);if(!R.isFunction(G))throw TypeError("visitor must be a function");function U(M){if(M===null)return"";if(R.isDate(M))return M.toISOString();if(R.isBoolean(M))return M.toString();if(!K&&R.isBlob(M))throw new s("Blob is not supported. Use a Buffer instead.");if(R.isArrayBuffer(M)||R.isTypedArray(M))return K&&typeof Blob==="function"?new Blob([M]):Buffer.from(M);return M}function $(M,F,D){let q=M;if(M&&!D&&typeof M==="object"){if(R.endsWith(F,"{}"))F=Y?F:F.slice(0,-2),M=JSON.stringify(M);else if(R.isArray(M)&&LO(M)||(R.isFileList(M)||R.endsWith(F,"[]"))&&(q=R.toArray(M)))return F=RU(F),q.forEach(function(O,w){!(R.isUndefined(O)||O===null)&&J.append(H===!0?tK([F],w,W):H===null?F:F+"[]",U(O))}),!1}if(cJ(M))return!0;return J.append(tK(D,F,W),U(M)),!1}let L=[],z=Object.assign(BO,{defaultVisitor:$,convertValue:U,isVisitable:cJ});function B(M,F){if(R.isUndefined(M))return;if(L.indexOf(M)!==-1)throw Error("Circular reference detected in "+F.join("."));L.push(M),R.forEach(M,function(q,P){if((!(R.isUndefined(q)||q===null)&&G.call(J,q,R.isString(P)?P.trim():P,F,z))===!0)B(q,F?F.concat(P):[P])}),L.pop()}if(!R.isObject(Z))throw TypeError("data must be an object");return B(Z),J}function eK(Z){let J={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\x00"};return encodeURIComponent(Z).replace(/[!'()~]|%20|%00/g,function(Y){return J[Y]})}function rJ(Z,J){this._pairs=[],Z&&U7(Z,this,J)}var IU=rJ.prototype;IU.append=function(J,X){this._pairs.push([J,X])};IU.toString=function(J){let X=J?function(Y){return J.call(this,Y,eK)}:eK;return this._pairs.map(function(G){return X(G[0])+"="+X(G[1])},"").join("&")};function zO(Z){return encodeURIComponent(Z).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function OU(Z,J,X){if(!J)return Z;let Y=X&&X.encode||zO,G=R.isFunction(X)?{serialize:X}:X,W=G&&G.serialize,H;if(W)H=W(J,G);else H=R.isURLSearchParams(J)?J.toString():new rJ(J,G).toString(Y);if(H){let Q=Z.indexOf("#");if(Q!==-1)Z=Z.slice(0,Q);Z+=(Z.indexOf("?")===-1?"?":"&")+H}return Z}class TU{constructor(){this.handlers=[]}use(Z,J,X){return this.handlers.push({fulfilled:Z,rejected:J,synchronous:X?X.synchronous:!1,runWhen:X?X.runWhen:null}),this.handlers.length-1}eject(Z){if(this.handlers[Z])this.handlers[Z]=null}clear(){if(this.handlers)this.handlers=[]}forEach(Z){R.forEach(this.handlers,function(X){if(X!==null)Z(X)})}}var ZU=TU,PU={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},MO=typeof URLSearchParams<"u"?URLSearchParams:rJ,FO=typeof FormData<"u"?FormData:null,NO=typeof Blob<"u"?Blob:null,VO={isBrowser:!0,classes:{URLSearchParams:MO,FormData:FO,Blob:NO},protocols:["http","https","file","blob","url","data"]},sJ=typeof window<"u"&&typeof document<"u",iJ=typeof navigator==="object"&&navigator||void 0,AO=sJ&&(!iJ||["ReactNative","NativeScript","NS"].indexOf(iJ.product)<0),DO=(()=>{return typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts==="function"})(),qO=sJ&&window.location.href||"http://localhost",RO=Object.freeze({__proto__:null,hasBrowserEnv:sJ,hasStandardBrowserWebWorkerEnv:DO,hasStandardBrowserEnv:AO,navigator:iJ,origin:qO}),S1={...RO,...VO};function IO(Z,J){return U7(Z,new S1.classes.URLSearchParams,{visitor:function(X,Y,G,W){if(S1.isNode&&R.isBuffer(X))return this.append(Y,X.toString("base64")),!1;return W.defaultVisitor.apply(this,arguments)},...J})}function OO(Z){return R.matchAll(/\w+|\[(\w*)]/g,Z).map((J)=>{return J[0]==="[]"?"":J[1]||J[0]})}function TO(Z){let J={},X=Object.keys(Z),Y,G=X.length,W;for(Y=0;Y<G;Y++)W=X[Y],J[W]=Z[W];return J}function wU(Z){function J(X,Y,G,W){let H=X[W++];if(H==="__proto__")return!0;let Q=Number.isFinite(+H),K=W>=X.length;if(H=!H&&R.isArray(G)?G.length:H,K){if(R.hasOwnProp(G,H))G[H]=[G[H],Y];else G[H]=Y;return!Q}if(!G[H]||!R.isObject(G[H]))G[H]=[];if(J(X,Y,G[H],W)&&R.isArray(G[H]))G[H]=TO(G[H]);return!Q}if(R.isFormData(Z)&&R.isFunction(Z.entries)){let X={};return R.forEachEntry(Z,(Y,G)=>{J(OO(Y),G,X,0)}),X}return null}function PO(Z,J,X){if(R.isString(Z))try{return(J||JSON.parse)(Z),R.trim(Z)}catch(Y){if(Y.name!=="SyntaxError")throw Y}return(X||JSON.stringify)(Z)}var oJ={transitional:PU,adapter:["xhr","http","fetch"],transformRequest:[function(J,X){let Y=X.getContentType()||"",G=Y.indexOf("application/json")>-1,W=R.isObject(J);if(W&&R.isHTMLForm(J))J=new FormData(J);if(R.isFormData(J))return G?JSON.stringify(wU(J)):J;if(R.isArrayBuffer(J)||R.isBuffer(J)||R.isStream(J)||R.isFile(J)||R.isBlob(J)||R.isReadableStream(J))return J;if(R.isArrayBufferView(J))return J.buffer;if(R.isURLSearchParams(J))return X.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),J.toString();let Q;if(W){if(Y.indexOf("application/x-www-form-urlencoded")>-1)return IO(J,this.formSerializer).toString();if((Q=R.isFileList(J))||Y.indexOf("multipart/form-data")>-1){let K=this.env&&this.env.FormData;return U7(Q?{"files[]":J}:J,K&&new K,this.formSerializer)}}if(W||G)return X.setContentType("application/json",!1),PO(J);return J}],transformResponse:[function(J){let X=this.transitional||oJ.transitional,Y=X&&X.forcedJSONParsing,G=this.responseType==="json";if(R.isResponse(J)||R.isReadableStream(J))return J;if(J&&R.isString(J)&&(Y&&!this.responseType||G)){let H=!(X&&X.silentJSONParsing)&&G;try{return JSON.parse(J,this.parseReviver)}catch(Q){if(H){if(Q.name==="SyntaxError")throw s.from(Q,s.ERR_BAD_RESPONSE,this,null,this.response);throw Q}}}return J}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:S1.classes.FormData,Blob:S1.classes.Blob},validateStatus:function(J){return J>=200&&J<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};R.forEach(["delete","get","head","post","put","patch"],(Z)=>{oJ.headers[Z]={}});var tJ=oJ,wO=R.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),_O=(Z)=>{let J={},X,Y,G;return Z&&Z.split(`
|
|
11
|
+
`).forEach(function(H){if(G=H.indexOf(":"),X=H.substring(0,G).trim().toLowerCase(),Y=H.substring(G+1).trim(),!X||J[X]&&wO[X])return;if(X==="set-cookie")if(J[X])J[X].push(Y);else J[X]=[Y];else J[X]=J[X]?J[X]+", "+Y:Y}),J},JU=Symbol("internals");function J9(Z){return Z&&String(Z).trim().toLowerCase()}function X7(Z){if(Z===!1||Z==null)return Z;return R.isArray(Z)?Z.map(X7):String(Z)}function SO(Z){let J=Object.create(null),X=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g,Y;while(Y=X.exec(Z))J[Y[1]]=Y[2];return J}var CO=(Z)=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(Z.trim());function uJ(Z,J,X,Y,G){if(R.isFunction(Y))return Y.call(this,J,X);if(G)J=X;if(!R.isString(J))return;if(R.isString(Y))return J.indexOf(Y)!==-1;if(R.isRegExp(Y))return Y.test(J)}function EO(Z){return Z.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(J,X,Y)=>{return X.toUpperCase()+Y})}function jO(Z,J){let X=R.toCamelCase(" "+J);["get","set","has"].forEach((Y)=>{Object.defineProperty(Z,Y+X,{value:function(G,W,H){return this[Y].call(this,J,G,W,H)},configurable:!0})})}class H9{constructor(Z){Z&&this.set(Z)}set(Z,J,X){let Y=this;function G(H,Q,K){let U=J9(Q);if(!U)throw Error("header name must be a non-empty string");let $=R.findKey(Y,U);if(!$||Y[$]===void 0||K===!0||K===void 0&&Y[$]!==!1)Y[$||Q]=X7(H)}let W=(H,Q)=>R.forEach(H,(K,U)=>G(K,U,Q));if(R.isPlainObject(Z)||Z instanceof this.constructor)W(Z,J);else if(R.isString(Z)&&(Z=Z.trim())&&!CO(Z))W(_O(Z),J);else if(R.isObject(Z)&&R.isIterable(Z)){let H={},Q,K;for(let U of Z){if(!R.isArray(U))throw TypeError("Object iterator must return a key-value pair");H[K=U[0]]=(Q=H[K])?R.isArray(Q)?[...Q,U[1]]:[Q,U[1]]:U[1]}W(H,J)}else Z!=null&&G(J,Z,X);return this}get(Z,J){if(Z=J9(Z),Z){let X=R.findKey(this,Z);if(X){let Y=this[X];if(!J)return Y;if(J===!0)return SO(Y);if(R.isFunction(J))return J.call(this,Y,X);if(R.isRegExp(J))return J.exec(Y);throw TypeError("parser must be boolean|regexp|function")}}}has(Z,J){if(Z=J9(Z),Z){let X=R.findKey(this,Z);return!!(X&&this[X]!==void 0&&(!J||uJ(this,this[X],X,J)))}return!1}delete(Z,J){let X=this,Y=!1;function G(W){if(W=J9(W),W){let H=R.findKey(X,W);if(H&&(!J||uJ(X,X[H],H,J)))delete X[H],Y=!0}}if(R.isArray(Z))Z.forEach(G);else G(Z);return Y}clear(Z){let J=Object.keys(this),X=J.length,Y=!1;while(X--){let G=J[X];if(!Z||uJ(this,this[G],G,Z,!0))delete this[G],Y=!0}return Y}normalize(Z){let J=this,X={};return R.forEach(this,(Y,G)=>{let W=R.findKey(X,G);if(W){J[W]=X7(Y),delete J[G];return}let H=Z?EO(G):String(G).trim();if(H!==G)delete J[G];J[H]=X7(Y),X[H]=!0}),this}concat(...Z){return this.constructor.concat(this,...Z)}toJSON(Z){let J=Object.create(null);return R.forEach(this,(X,Y)=>{X!=null&&X!==!1&&(J[Y]=Z&&R.isArray(X)?X.join(", "):X)}),J}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([Z,J])=>Z+": "+J).join(`
|
|
12
|
+
`)}getSetCookie(){return this.get("set-cookie")||[]}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(Z){return Z instanceof this?Z:new this(Z)}static concat(Z,...J){let X=new this(Z);return J.forEach((Y)=>X.set(Y)),X}static accessor(Z){let X=(this[JU]=this[JU]={accessors:{}}).accessors,Y=this.prototype;function G(W){let H=J9(W);if(!X[H])jO(Y,W),X[H]=!0}return R.isArray(Z)?Z.forEach(G):G(Z),this}}H9.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);R.reduceDescriptors(H9.prototype,({value:Z},J)=>{let X=J[0].toUpperCase()+J.slice(1);return{get:()=>Z,set(Y){this[X]=Y}}});R.freezeMethods(H9);var L0=H9;function pJ(Z,J){let X=this||tJ,Y=J||X,G=L0.from(Y.headers),W=Y.data;return R.forEach(Z,function(Q){W=Q.call(X,W,G.normalize(),J?J.status:void 0)}),G.normalize(),W}function _U(Z){return!!(Z&&Z.__CANCEL__)}class SU extends s{constructor(Z,J,X){super(Z==null?"canceled":Z,s.ERR_CANCELED,J,X);this.name="CanceledError",this.__CANCEL__=!0}}var Q9=SU;function CU(Z,J,X){let Y=X.config.validateStatus;if(!X.status||!Y||Y(X.status))Z(X);else J(new s("Request failed with status code "+X.status,[s.ERR_BAD_REQUEST,s.ERR_BAD_RESPONSE][Math.floor(X.status/100)-4],X.config,X.request,X))}function xO(Z){let J=/^([-+\w]{1,25})(:?\/\/|:)/.exec(Z);return J&&J[1]||""}function bO(Z,J){Z=Z||10;let X=Array(Z),Y=Array(Z),G=0,W=0,H;return J=J!==void 0?J:1000,function(K){let U=Date.now(),$=Y[W];if(!H)H=U;X[G]=K,Y[G]=U;let L=W,z=0;while(L!==G)z+=X[L++],L=L%Z;if(G=(G+1)%Z,G===W)W=(W+1)%Z;if(U-H<J)return;let B=$&&U-$;return B?Math.round(z*1000/B):void 0}}function kO(Z,J){let X=0,Y=1000/J,G,W,H=(U,$=Date.now())=>{if(X=$,G=null,W)clearTimeout(W),W=null;Z(...U)};return[(...U)=>{let $=Date.now(),L=$-X;if(L>=Y)H(U,$);else if(G=U,!W)W=setTimeout(()=>{W=null,H(G)},Y-L)},()=>G&&H(G)]}var W7=(Z,J,X=3)=>{let Y=0,G=bO(50,250);return kO((W)=>{let H=W.loaded,Q=W.lengthComputable?W.total:void 0,K=H-Y,U=G(K),$=H<=Q;Y=H;let L={loaded:H,total:Q,progress:Q?H/Q:void 0,bytes:K,rate:U?U:void 0,estimated:U&&Q&&$?(Q-H)/U:void 0,event:W,lengthComputable:Q!=null,[J?"download":"upload"]:!0};Z(L)},X)},XU=(Z,J)=>{let X=Z!=null;return[(Y)=>J[0]({lengthComputable:X,total:Z,loaded:Y}),J[1]]},YU=(Z)=>(...J)=>R.asap(()=>Z(...J)),gO=S1.hasStandardBrowserEnv?((Z,J)=>(X)=>{return X=new URL(X,S1.origin),Z.protocol===X.protocol&&Z.host===X.host&&(J||Z.port===X.port)})(new URL(S1.origin),S1.navigator&&/(msie|trident)/i.test(S1.navigator.userAgent)):()=>!0,hO=S1.hasStandardBrowserEnv?{write(Z,J,X,Y,G,W,H){if(typeof document>"u")return;let Q=[`${Z}=${encodeURIComponent(J)}`];if(R.isNumber(X))Q.push(`expires=${new Date(X).toUTCString()}`);if(R.isString(Y))Q.push(`path=${Y}`);if(R.isString(G))Q.push(`domain=${G}`);if(W===!0)Q.push("secure");if(R.isString(H))Q.push(`SameSite=${H}`);document.cookie=Q.join("; ")},read(Z){if(typeof document>"u")return null;let J=document.cookie.match(new RegExp("(?:^|; )"+Z+"=([^;]*)"));return J?decodeURIComponent(J[1]):null},remove(Z){this.write(Z,"",Date.now()-86400000,"/")}}:{write(){},read(){return null},remove(){}};function vO(Z){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(Z)}function yO(Z,J){return J?Z.replace(/\/?\/$/,"")+"/"+J.replace(/^\/+/,""):Z}function EU(Z,J,X){let Y=!vO(J);if(Z&&(Y||X==!1))return yO(Z,J);return J}var GU=(Z)=>Z instanceof L0?{...Z}:Z;function q5(Z,J){J=J||{};let X={};function Y(U,$,L,z){if(R.isPlainObject(U)&&R.isPlainObject($))return R.merge.call({caseless:z},U,$);else if(R.isPlainObject($))return R.merge({},$);else if(R.isArray($))return $.slice();return $}function G(U,$,L,z){if(!R.isUndefined($))return Y(U,$,L,z);else if(!R.isUndefined(U))return Y(void 0,U,L,z)}function W(U,$){if(!R.isUndefined($))return Y(void 0,$)}function H(U,$){if(!R.isUndefined($))return Y(void 0,$);else if(!R.isUndefined(U))return Y(void 0,U)}function Q(U,$,L){if(L in J)return Y(U,$);else if(L in Z)return Y(void 0,U)}let K={url:W,method:W,data:W,baseURL:H,transformRequest:H,transformResponse:H,paramsSerializer:H,timeout:H,timeoutMessage:H,withCredentials:H,withXSRFToken:H,adapter:H,responseType:H,xsrfCookieName:H,xsrfHeaderName:H,onUploadProgress:H,onDownloadProgress:H,decompress:H,maxContentLength:H,maxBodyLength:H,beforeRedirect:H,transport:H,httpAgent:H,httpsAgent:H,cancelToken:H,socketPath:H,responseEncoding:H,validateStatus:Q,headers:(U,$,L)=>G(GU(U),GU($),L,!0)};return R.forEach(Object.keys({...Z,...J}),function($){let L=K[$]||G,z=L(Z[$],J[$],$);R.isUndefined(z)&&L!==Q||(X[$]=z)}),X}var jU=(Z)=>{let J=q5({},Z),{data:X,withXSRFToken:Y,xsrfHeaderName:G,xsrfCookieName:W,headers:H,auth:Q}=J;if(J.headers=H=L0.from(H),J.url=OU(EU(J.baseURL,J.url,J.allowAbsoluteUrls),Z.params,Z.paramsSerializer),Q)H.set("Authorization","Basic "+btoa((Q.username||"")+":"+(Q.password?unescape(encodeURIComponent(Q.password)):"")));if(R.isFormData(X)){if(S1.hasStandardBrowserEnv||S1.hasStandardBrowserWebWorkerEnv)H.setContentType(void 0);else if(R.isFunction(X.getHeaders)){let K=X.getHeaders(),U=["content-type","content-length"];Object.entries(K).forEach(([$,L])=>{if(U.includes($.toLowerCase()))H.set($,L)})}}if(S1.hasStandardBrowserEnv){if(Y&&R.isFunction(Y)&&(Y=Y(J)),Y||Y!==!1&&gO(J.url)){let K=G&&W&&hO.read(W);if(K)H.set(G,K)}}return J},mO=typeof XMLHttpRequest<"u",fO=mO&&function(Z){return new Promise(function(X,Y){let G=jU(Z),W=G.data,H=L0.from(G.headers).normalize(),{responseType:Q,onUploadProgress:K,onDownloadProgress:U}=G,$,L,z,B,M;function F(){B&&B(),M&&M(),G.cancelToken&&G.cancelToken.unsubscribe($),G.signal&&G.signal.removeEventListener("abort",$)}let D=new XMLHttpRequest;D.open(G.method.toUpperCase(),G.url,!0),D.timeout=G.timeout;function q(){if(!D)return;let O=L0.from("getAllResponseHeaders"in D&&D.getAllResponseHeaders()),E={data:!Q||Q==="text"||Q==="json"?D.responseText:D.response,status:D.status,statusText:D.statusText,headers:O,config:Z,request:D};CU(function(k){X(k),F()},function(k){Y(k),F()},E),D=null}if("onloadend"in D)D.onloadend=q;else D.onreadystatechange=function(){if(!D||D.readyState!==4)return;if(D.status===0&&!(D.responseURL&&D.responseURL.indexOf("file:")===0))return;setTimeout(q)};if(D.onabort=function(){if(!D)return;Y(new s("Request aborted",s.ECONNABORTED,Z,D)),D=null},D.onerror=function(w){let E=w&&w.message?w.message:"Network Error",I=new s(E,s.ERR_NETWORK,Z,D);I.event=w||null,Y(I),D=null},D.ontimeout=function(){let w=G.timeout?"timeout of "+G.timeout+"ms exceeded":"timeout exceeded",E=G.transitional||PU;if(G.timeoutErrorMessage)w=G.timeoutErrorMessage;Y(new s(w,E.clarifyTimeoutError?s.ETIMEDOUT:s.ECONNABORTED,Z,D)),D=null},W===void 0&&H.setContentType(null),"setRequestHeader"in D)R.forEach(H.toJSON(),function(w,E){D.setRequestHeader(E,w)});if(!R.isUndefined(G.withCredentials))D.withCredentials=!!G.withCredentials;if(Q&&Q!=="json")D.responseType=G.responseType;if(U)[z,M]=W7(U,!0),D.addEventListener("progress",z);if(K&&D.upload)[L,B]=W7(K),D.upload.addEventListener("progress",L),D.upload.addEventListener("loadend",B);if(G.cancelToken||G.signal){if($=(O)=>{if(!D)return;Y(!O||O.type?new Q9(null,Z,D):O),D.abort(),D=null},G.cancelToken&&G.cancelToken.subscribe($),G.signal)G.signal.aborted?$():G.signal.addEventListener("abort",$)}let P=xO(G.url);if(P&&S1.protocols.indexOf(P)===-1){Y(new s("Unsupported protocol "+P+":",s.ERR_BAD_REQUEST,Z));return}D.send(W||null)})},uO=(Z,J)=>{let{length:X}=Z=Z?Z.filter(Boolean):[];if(J||X){let Y=new AbortController,G,W=function(U){if(!G){G=!0,Q();let $=U instanceof Error?U:this.reason;Y.abort($ instanceof s?$:new Q9($ instanceof Error?$.message:$))}},H=J&&setTimeout(()=>{H=null,W(new s(`timeout of ${J}ms exceeded`,s.ETIMEDOUT))},J),Q=()=>{if(Z)H&&clearTimeout(H),H=null,Z.forEach((U)=>{U.unsubscribe?U.unsubscribe(W):U.removeEventListener("abort",W)}),Z=null};Z.forEach((U)=>U.addEventListener("abort",W));let{signal:K}=Y;return K.unsubscribe=()=>R.asap(Q),K}},pO=uO,lO=function*(Z,J){let X=Z.byteLength;if(!J||X<J){yield Z;return}let Y=0,G;while(Y<X)G=Y+J,yield Z.slice(Y,G),Y=G},dO=async function*(Z,J){for await(let X of cO(Z))yield*lO(X,J)},cO=async function*(Z){if(Z[Symbol.asyncIterator]){yield*Z;return}let J=Z.getReader();try{for(;;){let{done:X,value:Y}=await J.read();if(X)break;yield Y}}finally{await J.cancel()}},WU=(Z,J,X,Y)=>{let G=dO(Z,J),W=0,H,Q=(K)=>{if(!H)H=!0,Y&&Y(K)};return new ReadableStream({async pull(K){try{let{done:U,value:$}=await G.next();if(U){Q(),K.close();return}let L=$.byteLength;if(X){let z=W+=L;X(z)}K.enqueue(new Uint8Array($))}catch(U){throw Q(U),U}},cancel(K){return Q(K),G.return()}},{highWaterMark:2})},HU=65536,{isFunction:Z7}=R,iO=(({Request:Z,Response:J})=>({Request:Z,Response:J}))(R.global),{ReadableStream:QU,TextEncoder:KU}=R.global,UU=(Z,...J)=>{try{return!!Z(...J)}catch(X){return!1}},nO=(Z)=>{Z=R.merge.call({skipUndefined:!0},iO,Z);let{fetch:J,Request:X,Response:Y}=Z,G=J?Z7(J):typeof fetch==="function",W=Z7(X),H=Z7(Y);if(!G)return!1;let Q=G&&Z7(QU),K=G&&(typeof KU==="function"?((M)=>(F)=>M.encode(F))(new KU):async(M)=>new Uint8Array(await new X(M).arrayBuffer())),U=W&&Q&&UU(()=>{let M=!1,F=new X(S1.origin,{body:new QU,method:"POST",get duplex(){return M=!0,"half"}}).headers.has("Content-Type");return M&&!F}),$=H&&Q&&UU(()=>R.isReadableStream(new Y("").body)),L={stream:$&&((M)=>M.body)};G&&(()=>{["text","arrayBuffer","blob","formData","stream"].forEach((M)=>{!L[M]&&(L[M]=(F,D)=>{let q=F&&F[M];if(q)return q.call(F);throw new s(`Response type '${M}' is not supported`,s.ERR_NOT_SUPPORT,D)})})})();let z=async(M)=>{if(M==null)return 0;if(R.isBlob(M))return M.size;if(R.isSpecCompliantForm(M))return(await new X(S1.origin,{method:"POST",body:M}).arrayBuffer()).byteLength;if(R.isArrayBufferView(M)||R.isArrayBuffer(M))return M.byteLength;if(R.isURLSearchParams(M))M=M+"";if(R.isString(M))return(await K(M)).byteLength},B=async(M,F)=>{let D=R.toFiniteNumber(M.getContentLength());return D==null?z(F):D};return async(M)=>{let{url:F,method:D,data:q,signal:P,cancelToken:O,timeout:w,onDownloadProgress:E,onUploadProgress:I,responseType:k,headers:l,withCredentials:y="same-origin",fetchOptions:a}=jU(M),c=J||fetch;k=k?(k+"").toLowerCase():"text";let p=pO([P,O&&O.toAbortSignal()],w),C=null,g=p&&p.unsubscribe&&(()=>{p.unsubscribe()}),A;try{if(I&&U&&D!=="get"&&D!=="head"&&(A=await B(l,q))!==0){let M1=new X(F,{method:"POST",body:q,duplex:"half"}),I1;if(R.isFormData(q)&&(I1=M1.headers.get("content-type")))l.setContentType(I1);if(M1.body){let[V,O1]=XU(A,W7(YU(I)));q=WU(M1.body,HU,V,O1)}}if(!R.isString(y))y=y?"include":"omit";let o=W&&"credentials"in X.prototype,n={...a,signal:p,method:D.toUpperCase(),headers:l.normalize().toJSON(),body:q,duplex:"half",credentials:o?y:void 0};C=W&&new X(F,n);let W1=await(W?c(C,a):c(F,n)),z1=$&&(k==="stream"||k==="response");if($&&(E||z1&&g)){let M1={};["status","statusText","headers"].forEach((z0)=>{M1[z0]=W1[z0]});let I1=R.toFiniteNumber(W1.headers.get("content-length")),[V,O1]=E&&XU(I1,W7(YU(E),!0))||[];W1=new Y(WU(W1.body,HU,V,()=>{O1&&O1(),g&&g()}),M1)}k=k||"text";let N=await L[R.findKey(L,k)||"text"](W1,M);return!z1&&g&&g(),await new Promise((M1,I1)=>{CU(M1,I1,{data:N,headers:L0.from(W1.headers),status:W1.status,statusText:W1.statusText,config:M,request:C})})}catch(o){if(g&&g(),o&&o.name==="TypeError"&&/Load failed|fetch/i.test(o.message))throw Object.assign(new s("Network Error",s.ERR_NETWORK,M,C),{cause:o.cause||o});throw s.from(o,o&&o.code,M,C)}}},aO=new Map,xU=(Z)=>{let J=Z&&Z.env||{},{fetch:X,Request:Y,Response:G}=J,W=[Y,G,X],H=W.length,Q=H,K,U,$=aO;while(Q--)K=W[Q],U=$.get(K),U===void 0&&$.set(K,U=Q?new Map:nO(J)),$=U;return U};xU();var eJ={http:$O,xhr:fO,fetch:{get:xU}};R.forEach(eJ,(Z,J)=>{if(Z){try{Object.defineProperty(Z,"name",{value:J})}catch(X){}Object.defineProperty(Z,"adapterName",{value:J})}});var $U=(Z)=>`- ${Z}`,rO=(Z)=>R.isFunction(Z)||Z===null||Z===!1;function sO(Z,J){Z=R.isArray(Z)?Z:[Z];let{length:X}=Z,Y,G,W={};for(let H=0;H<X;H++){Y=Z[H];let Q;if(G=Y,!rO(Y)){if(G=eJ[(Q=String(Y)).toLowerCase()],G===void 0)throw new s(`Unknown adapter '${Q}'`)}if(G&&(R.isFunction(G)||(G=G.get(J))))break;W[Q||"#"+H]=G}if(!G){let H=Object.entries(W).map(([K,U])=>`adapter ${K} `+(U===!1?"is not supported by the environment":"is not available in the build")),Q=X?H.length>1?`since :
|
|
13
|
+
`+H.map($U).join(`
|
|
14
|
+
`):" "+$U(H[0]):"as no adapter specified";throw new s("There is no suitable adapter to dispatch the request "+Q,"ERR_NOT_SUPPORT")}return G}var bU={getAdapter:sO,adapters:eJ};function lJ(Z){if(Z.cancelToken)Z.cancelToken.throwIfRequested();if(Z.signal&&Z.signal.aborted)throw new Q9(null,Z)}function LU(Z){if(lJ(Z),Z.headers=L0.from(Z.headers),Z.data=pJ.call(Z,Z.transformRequest),["post","put","patch"].indexOf(Z.method)!==-1)Z.headers.setContentType("application/x-www-form-urlencoded",!1);return bU.getAdapter(Z.adapter||tJ.adapter,Z)(Z).then(function(Y){return lJ(Z),Y.data=pJ.call(Z,Z.transformResponse,Y),Y.headers=L0.from(Y.headers),Y},function(Y){if(!_U(Y)){if(lJ(Z),Y&&Y.response)Y.response.data=pJ.call(Z,Z.transformResponse,Y.response),Y.response.headers=L0.from(Y.response.headers)}return Promise.reject(Y)})}var kU="1.13.4",$7={};["object","boolean","number","function","string","symbol"].forEach((Z,J)=>{$7[Z]=function(Y){return typeof Y===Z||"a"+(J<1?"n ":" ")+Z}});var BU={};$7.transitional=function(J,X,Y){function G(W,H){return"[Axios v"+kU+"] Transitional option '"+W+"'"+H+(Y?". "+Y:"")}return(W,H,Q)=>{if(J===!1)throw new s(G(H," has been removed"+(X?" in "+X:"")),s.ERR_DEPRECATED);if(X&&!BU[H])BU[H]=!0,console.warn(G(H," has been deprecated since v"+X+" and will be removed in the near future"));return J?J(W,H,Q):!0}};$7.spelling=function(J){return(X,Y)=>{return console.warn(`${Y} is likely a misspelling of ${J}`),!0}};function oO(Z,J,X){if(typeof Z!=="object")throw new s("options must be an object",s.ERR_BAD_OPTION_VALUE);let Y=Object.keys(Z),G=Y.length;while(G-- >0){let W=Y[G],H=J[W];if(H){let Q=Z[W],K=Q===void 0||H(Q,W,Z);if(K!==!0)throw new s("option "+W+" must be "+K,s.ERR_BAD_OPTION_VALUE);continue}if(X!==!0)throw new s("Unknown option "+W,s.ERR_BAD_OPTION)}}var Y7={assertOptions:oO,validators:$7},O0=Y7.validators;class X9{constructor(Z){this.defaults=Z||{},this.interceptors={request:new ZU,response:new ZU}}async request(Z,J){try{return await this._request(Z,J)}catch(X){if(X instanceof Error){let Y={};Error.captureStackTrace?Error.captureStackTrace(Y):Y=Error();let G=Y.stack?Y.stack.replace(/^.+\n/,""):"";try{if(!X.stack)X.stack=G;else if(G&&!String(X.stack).endsWith(G.replace(/^.+\n.+\n/,"")))X.stack+=`
|
|
15
|
+
`+G}catch(W){}}throw X}}_request(Z,J){if(typeof Z==="string")J=J||{},J.url=Z;else J=Z||{};J=q5(this.defaults,J);let{transitional:X,paramsSerializer:Y,headers:G}=J;if(X!==void 0)Y7.assertOptions(X,{silentJSONParsing:O0.transitional(O0.boolean),forcedJSONParsing:O0.transitional(O0.boolean),clarifyTimeoutError:O0.transitional(O0.boolean)},!1);if(Y!=null)if(R.isFunction(Y))J.paramsSerializer={serialize:Y};else Y7.assertOptions(Y,{encode:O0.function,serialize:O0.function},!0);if(J.allowAbsoluteUrls!==void 0);else if(this.defaults.allowAbsoluteUrls!==void 0)J.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls;else J.allowAbsoluteUrls=!0;Y7.assertOptions(J,{baseUrl:O0.spelling("baseURL"),withXsrfToken:O0.spelling("withXSRFToken")},!0),J.method=(J.method||this.defaults.method||"get").toLowerCase();let W=G&&R.merge(G.common,G[J.method]);G&&R.forEach(["delete","get","head","post","put","patch","common"],(B)=>{delete G[B]}),J.headers=L0.concat(W,G);let H=[],Q=!0;this.interceptors.request.forEach(function(M){if(typeof M.runWhen==="function"&&M.runWhen(J)===!1)return;Q=Q&&M.synchronous,H.unshift(M.fulfilled,M.rejected)});let K=[];this.interceptors.response.forEach(function(M){K.push(M.fulfilled,M.rejected)});let U,$=0,L;if(!Q){let B=[LU.bind(this),void 0];B.unshift(...H),B.push(...K),L=B.length,U=Promise.resolve(J);while($<L)U=U.then(B[$++],B[$++]);return U}L=H.length;let z=J;while($<L){let B=H[$++],M=H[$++];try{z=B(z)}catch(F){M.call(this,F);break}}try{U=LU.call(this,z)}catch(B){return Promise.reject(B)}$=0,L=K.length;while($<L)U=U.then(K[$++],K[$++]);return U}getUri(Z){Z=q5(this.defaults,Z);let J=EU(Z.baseURL,Z.url,Z.allowAbsoluteUrls);return OU(J,Z.params,Z.paramsSerializer)}}R.forEach(["delete","get","head","options"],function(J){X9.prototype[J]=function(X,Y){return this.request(q5(Y||{},{method:J,url:X,data:(Y||{}).data}))}});R.forEach(["post","put","patch"],function(J){function X(Y){return function(W,H,Q){return this.request(q5(Q||{},{method:J,headers:Y?{"Content-Type":"multipart/form-data"}:{},url:W,data:H}))}}X9.prototype[J]=X(),X9.prototype[J+"Form"]=X(!0)});var G7=X9;class ZX{constructor(Z){if(typeof Z!=="function")throw TypeError("executor must be a function.");let J;this.promise=new Promise(function(G){J=G});let X=this;this.promise.then((Y)=>{if(!X._listeners)return;let G=X._listeners.length;while(G-- >0)X._listeners[G](Y);X._listeners=null}),this.promise.then=(Y)=>{let G,W=new Promise((H)=>{X.subscribe(H),G=H}).then(Y);return W.cancel=function(){X.unsubscribe(G)},W},Z(function(G,W,H){if(X.reason)return;X.reason=new Q9(G,W,H),J(X.reason)})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(Z){if(this.reason){Z(this.reason);return}if(this._listeners)this._listeners.push(Z);else this._listeners=[Z]}unsubscribe(Z){if(!this._listeners)return;let J=this._listeners.indexOf(Z);if(J!==-1)this._listeners.splice(J,1)}toAbortSignal(){let Z=new AbortController,J=(X)=>{Z.abort(X)};return this.subscribe(J),Z.signal.unsubscribe=()=>this.unsubscribe(J),Z.signal}static source(){let Z;return{token:new ZX(function(Y){Z=Y}),cancel:Z}}}var tO=ZX;function eO(Z){return function(X){return Z.apply(null,X)}}function ZT(Z){return R.isObject(Z)&&Z.isAxiosError===!0}var nJ={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,WebServerIsDown:521,ConnectionTimedOut:522,OriginIsUnreachable:523,TimeoutOccurred:524,SslHandshakeFailed:525,InvalidSslCertificate:526};Object.entries(nJ).forEach(([Z,J])=>{nJ[J]=Z});var JT=nJ;function gU(Z){let J=new G7(Z),X=zU(G7.prototype.request,J);return R.extend(X,G7.prototype,J,{allOwnKeys:!0}),R.extend(X,J,null,{allOwnKeys:!0}),X.create=function(G){return gU(q5(Z,G))},X}var B1=gU(tJ);B1.Axios=G7;B1.CanceledError=Q9;B1.CancelToken=tO;B1.isCancel=_U;B1.VERSION=kU;B1.toFormData=U7;B1.AxiosError=s;B1.Cancel=B1.CanceledError;B1.all=function(J){return Promise.all(J)};B1.spread=eO;B1.isAxiosError=ZT;B1.mergeConfig=q5;B1.AxiosHeaders=L0;B1.formToJSON=(Z)=>wU(R.isHTMLForm(Z)?new FormData(Z):Z);B1.getAdapter=bU.getAdapter;B1.HttpStatusCode=JT;B1.default=B1;hU.exports=B1});var XX=x((mU)=>{Object.defineProperty(mU,"__esModule",{value:!0});mU.addAxiosDateTransformer=mU.createAxiosDateTransformer=void 0;var XT=(sK(),eU(rK)),YT=XT.__importDefault(vU()),GT=/^\d{4}-\d{2}-\d{2}(T\d{2}:\d{2}:\d{2}(?:\.\d*)?(?:[-+]\d{2}:?\d{2}|Z)?)?$/,WT=(Z)=>{return GT.test(Z)},HT=(Z,J)=>{return!J||J.length===0||J.includes(Z)},QT=(Z,J,X)=>{return typeof J==="string"&&WT(J)&&HT(Z,X)},yU=(Z,J)=>{if(typeof Z==="object"){for(let X in Z)if(QT(X,Z[X],J))Z[X]=new Date(Z[X]);else if(typeof Z[X]==="object")Z[X]=yU(Z[X],J)}return Z},KT=(Z,J)=>{if(Z.data)Z.data=yU(Z.data,J);return Z},UT=(Z={})=>{return mU.addAxiosDateTransformer(YT.default.create(Z),Z)};mU.createAxiosDateTransformer=UT;var $T=(Z,J)=>{let X=J===null||J===void 0?void 0:J.allowlist;return Z.interceptors.response.use((Y)=>KT(Y,X)),Z};mU.addAxiosDateTransformer=$T});import{lazy as Z$}from"react";var z7=new Map;function BX(Z,J){return Z$(()=>{if(z7.has(J))return z7.get(J);let X=Z().then((Y)=>Y);return z7.set(J,X),X})}var J$=()=>typeof window<"u",zX=()=>typeof process<"u"&&!!process.versions?.node,X$=()=>{try{return typeof Function("return import.meta")()<"u"}catch{return!1}},MX="__piedemo__",FX={PIE_API_SERVER:typeof process<"u"?process.env.NEXT_PUBLIC_PIE_API_SERVER:void 0,PIE_CENTRIFUGE_SERVER:typeof process<"u"?process.env.NEXT_PUBLIC_PIE_CENTRIFUGE_SERVER:void 0,PIE_ENABLE_RENDERING_LOG:typeof process<"u"?process.env.NEXT_PUBLIC_PIE_ENABLE_RENDERING_LOG:void 0,PIE_PAGE_PROCESSOR:typeof process<"u"?process.env.NEXT_PUBLIC_PIE_PAGE_PROCESSOR:void 0},b0=(Z,J="")=>{if(X$())return import.meta.env[Z]??J;if(zX()&&process.env)return process.env[Z]??J;return J},NX=()=>{if(J$())return window.location.hostname;if(zX())return process.env.HOSTNAME??"localhost";return"localhost"},T1=()=>{let Z=b0("NEXT_PUBLIC_PIE_API_SERVER")||b0("PIE_API_SERVER");return Z==="auto-api"?`https://api.${NX()}/`:Z},M7=()=>{let Z=b0("NEXT_PUBLIC_PIE_CENTRIFUGE_SERVER")||b0("PIE_CENTRIFUGE_SERVER");return Z==="auto-api"?`wss://centrifuge.${NX()}/connection/websocket`:Z},h=()=>b0("VITE_PIE_ENABLE_RENDERING_LOG","false")==="true"||b0("PIE_ENABLE_RENDERING_LOG","false")==="true"||(FX.PIE_ENABLE_RENDERING_LOG??"false")==="true",VX=()=>b0("VITE_PIE_PAGE_PROCESSOR")||b0("PIE_PAGE_PROCESSOR")||FX.PIE_PAGE_PROCESSOR;var F7=new Map,Y$=(Z)=>{if(!Z.name)throw Error("Component registration requires a name");if(!Z.component&&!Z.loader)throw Error(`Component "${Z.name}" requires component or loader`);let J={name:Z.name,component:Z.component,loader:Z.loader,metadata:Z.metadata,fallback:Z.fallback,isLazy:!1};if(!J.component&&J.loader)J.component=BX(J.loader,Z.name),J.loader=void 0,J.isLazy=!0;return J};function Z5(Z){let J=Y$(Z);if(h())console.log("[Registry] Registering component:",J.name,{isLazy:J.isLazy,hasMetadata:!!J.metadata,hasFallback:!!J.fallback});return F7.set(J.name,J),J.component}var AX=(Z)=>{let J=F7.get(Z);if(h())if(J)console.log("[Registry] Found component:",Z);else console.warn("[Registry] Component not found:",Z),console.log("[Registry] Available components:",Array.from(F7.keys()));return J};import{Suspense as K$,useContext as U$}from"react";import{createContext as G$}from"react";import{jsxDEV as Q$,Fragment as H$}from"react/jsx-dev-runtime";var W$=G$(Q$(H$,{},void 0,!1,void 0,this)),n1=W$;import{jsxDEV as DX}from"react/jsx-dev-runtime";function $$({uiConfig:Z,setUiAjaxConfiguration:J}){let X=U$(n1);if(h())console.log("[UI] Rendering component:",Z.card),console.log("[UI] Component data:",Z.data),console.log("[UI] Component content:",Z.content),console.log("[UI] Has setUiAjaxConfiguration:",!!J);let Y=AX(Z.card);if(!Y?.component){if(h())console.warn(`[UI] Component not found in registry: ${Z.card}`),console.log("[UI] Returning fallback component");return X}if(h())console.log("[UI] Found component in registry:",{name:Y.name,isLazy:Y.isLazy,hasMetadata:!!Y.metadata});let G=Y.component,W=DX(G,{data:Z.data,content:Z.content,setUiAjaxConfiguration:J},void 0,!1,void 0,this);if(Y.isLazy){if(h())console.log("[UI] Rendering lazy component with Suspense:",Y.name);return DX(K$,{fallback:Y.fallback??X,children:W},`${Y.name}`,!1,void 0,this)}if(h())console.log("[UI] Rendering component directly:",Y.name);return W}var C1=$$;var M0=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(Z){return this.listeners.add(Z),this.onSubscribe(),()=>{this.listeners.delete(Z),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}};var L$={setTimeout:(Z,J)=>setTimeout(Z,J),clearTimeout:(Z)=>clearTimeout(Z),setInterval:(Z,J)=>setInterval(Z,J),clearInterval:(Z)=>clearInterval(Z)},B$=class{#Z=L$;#J=!1;setTimeoutProvider(Z){this.#Z=Z}setTimeout(Z,J){return this.#Z.setTimeout(Z,J)}clearTimeout(Z){this.#Z.clearTimeout(Z)}setInterval(Z,J){return this.#Z.setInterval(Z,J)}clearInterval(Z){this.#Z.clearInterval(Z)}},F0=new B$;function qX(Z){setTimeout(Z,0)}var v1=typeof window>"u"||"Deno"in globalThis;function U1(){}function OX(Z,J){return typeof Z==="function"?Z(J):Z}function Y6(Z){return typeof Z==="number"&&Z>=0&&Z!==1/0}function $9(Z,J){return Math.max(Z+(J||0)-Date.now(),0)}function W0(Z,J){return typeof Z==="function"?Z(J):Z}function y1(Z,J){return typeof Z==="function"?Z(J):Z}function L9(Z,J){let{type:X="all",exact:Y,fetchStatus:G,predicate:W,queryKey:H,stale:Q}=Z;if(H){if(Y){if(J.queryHash!==G6(H,J.options))return!1}else if(!X5(J.queryKey,H))return!1}if(X!=="all"){let K=J.isActive();if(X==="active"&&!K)return!1;if(X==="inactive"&&K)return!1}if(typeof Q==="boolean"&&J.isStale()!==Q)return!1;if(G&&G!==J.state.fetchStatus)return!1;if(W&&!W(J))return!1;return!0}function B9(Z,J){let{exact:X,status:Y,predicate:G,mutationKey:W}=Z;if(W){if(!J.options.mutationKey)return!1;if(X){if(J5(J.options.mutationKey)!==J5(W))return!1}else if(!X5(J.options.mutationKey,W))return!1}if(Y&&J.state.status!==Y)return!1;if(G&&!G(J))return!1;return!0}function G6(Z,J){return(J?.queryKeyHashFn||J5)(Z)}function J5(Z){return JSON.stringify(Z,(J,X)=>N7(X)?Object.keys(X).sort().reduce((Y,G)=>{return Y[G]=X[G],Y},{}):X)}function X5(Z,J){if(Z===J)return!0;if(typeof Z!==typeof J)return!1;if(Z&&J&&typeof Z==="object"&&typeof J==="object")return Object.keys(J).every((X)=>X5(Z[X],J[X]));return!1}var z$=Object.prototype.hasOwnProperty;function V7(Z,J,X=0){if(Z===J)return Z;if(X>500)return J;let Y=RX(Z)&&RX(J);if(!Y&&!(N7(Z)&&N7(J)))return J;let W=(Y?Z:Object.keys(Z)).length,H=Y?J:Object.keys(J),Q=H.length,K=Y?Array(Q):{},U=0;for(let $=0;$<Q;$++){let L=Y?$:H[$],z=Z[L],B=J[L];if(z===B){if(K[L]=z,Y?$<W:z$.call(Z,L))U++;continue}if(z===null||B===null||typeof z!=="object"||typeof B!=="object"){K[L]=B;continue}let M=V7(z,B,X+1);if(K[L]=M,M===z)U++}return W===Q&&U===W?Z:K}function z9(Z,J){if(!J||Object.keys(Z).length!==Object.keys(J).length)return!1;for(let X in Z)if(Z[X]!==J[X])return!1;return!0}function RX(Z){return Array.isArray(Z)&&Z.length===Object.keys(Z).length}function N7(Z){if(!IX(Z))return!1;let J=Z.constructor;if(J===void 0)return!0;let X=J.prototype;if(!IX(X))return!1;if(!X.hasOwnProperty("isPrototypeOf"))return!1;if(Object.getPrototypeOf(Z)!==Object.prototype)return!1;return!0}function IX(Z){return Object.prototype.toString.call(Z)==="[object Object]"}function TX(Z){return new Promise((J)=>{F0.setTimeout(J,Z)})}function W6(Z,J,X){if(typeof X.structuralSharing==="function")return X.structuralSharing(Z,J);else if(X.structuralSharing!==!1)return V7(Z,J);return J}function PX(Z,J,X=0){let Y=[...Z,J];return X&&Y.length>X?Y.slice(1):Y}function wX(Z,J,X=0){let Y=[J,...Z];return X&&Y.length>X?Y.slice(0,-1):Y}var O5=Symbol();function M9(Z,J){if(!Z.queryFn&&J?.initialPromise)return()=>J.initialPromise;if(!Z.queryFn||Z.queryFn===O5)return()=>Promise.reject(Error(`Missing queryFn: '${Z.queryHash}'`));return Z.queryFn}function F9(Z,J){if(typeof Z==="function")return Z(...J);return!!Z}function _X(Z,J,X){let Y=!1,G;return Object.defineProperty(Z,"signal",{enumerable:!0,get:()=>{if(G??=J(),Y)return G;if(Y=!0,G.aborted)X();else G.addEventListener("abort",X,{once:!0});return G}}),Z}var M$=class extends M0{#Z;#J;#X;constructor(){super();this.#X=(Z)=>{if(!v1&&window.addEventListener){let J=()=>Z();return window.addEventListener("visibilitychange",J,!1),()=>{window.removeEventListener("visibilitychange",J)}}return}}onSubscribe(){if(!this.#J)this.setEventListener(this.#X)}onUnsubscribe(){if(!this.hasListeners())this.#J?.(),this.#J=void 0}setEventListener(Z){this.#X=Z,this.#J?.(),this.#J=Z((J)=>{if(typeof J==="boolean")this.setFocused(J);else this.onFocus()})}setFocused(Z){if(this.#Z!==Z)this.#Z=Z,this.onFocus()}onFocus(){let Z=this.isFocused();this.listeners.forEach((J)=>{J(Z)})}isFocused(){if(typeof this.#Z==="boolean")return this.#Z;return globalThis.document?.visibilityState!=="hidden"}},T5=new M$;function H6(){let Z,J,X=new Promise((G,W)=>{Z=G,J=W});X.status="pending",X.catch(()=>{});function Y(G){Object.assign(X,G),delete X.resolve,delete X.reject}return X.resolve=(G)=>{Y({status:"fulfilled",value:G}),Z(G)},X.reject=(G)=>{Y({status:"rejected",reason:G}),J(G)},X}var SX=qX;function F$(){let Z=[],J=0,X=(Q)=>{Q()},Y=(Q)=>{Q()},G=SX,W=(Q)=>{if(J)Z.push(Q);else G(()=>{X(Q)})},H=()=>{let Q=Z;if(Z=[],Q.length)G(()=>{Y(()=>{Q.forEach((K)=>{X(K)})})})};return{batch:(Q)=>{let K;J++;try{K=Q()}finally{if(J--,!J)H()}return K},batchCalls:(Q)=>{return(...K)=>{W(()=>{Q(...K)})}},schedule:W,setNotifyFunction:(Q)=>{X=Q},setBatchNotifyFunction:(Q)=>{Y=Q},setScheduler:(Q)=>{G=Q}}}var Y1=F$();var N$=class extends M0{#Z=!0;#J;#X;constructor(){super();this.#X=(Z)=>{if(!v1&&window.addEventListener){let J=()=>Z(!0),X=()=>Z(!1);return window.addEventListener("online",J,!1),window.addEventListener("offline",X,!1),()=>{window.removeEventListener("online",J),window.removeEventListener("offline",X)}}return}}onSubscribe(){if(!this.#J)this.setEventListener(this.#X)}onUnsubscribe(){if(!this.hasListeners())this.#J?.(),this.#J=void 0}setEventListener(Z){this.#X=Z,this.#J?.(),this.#J=Z(this.setOnline.bind(this))}setOnline(Z){if(this.#Z!==Z)this.#Z=Z,this.listeners.forEach((X)=>{X(Z)})}isOnline(){return this.#Z}},P5=new N$;function V$(Z){return Math.min(1000*2**Z,30000)}function A7(Z){return(Z??"online")==="online"?P5.isOnline():!0}var N9=class extends Error{constructor(Z){super("CancelledError");this.revert=Z?.revert,this.silent=Z?.silent}};function V9(Z){let J=!1,X=0,Y,G=H6(),W=()=>G.status!=="pending",H=(F)=>{if(!W()){let D=new N9(F);z(D),Z.onCancel?.(D)}},Q=()=>{J=!0},K=()=>{J=!1},U=()=>T5.isFocused()&&(Z.networkMode==="always"||P5.isOnline())&&Z.canRun(),$=()=>A7(Z.networkMode)&&Z.canRun(),L=(F)=>{if(!W())Y?.(),G.resolve(F)},z=(F)=>{if(!W())Y?.(),G.reject(F)},B=()=>{return new Promise((F)=>{Y=(D)=>{if(W()||U())F(D)},Z.onPause?.()}).then(()=>{if(Y=void 0,!W())Z.onContinue?.()})},M=()=>{if(W())return;let F,D=X===0?Z.initialPromise:void 0;try{F=D??Z.fn()}catch(q){F=Promise.reject(q)}Promise.resolve(F).then(L).catch((q)=>{if(W())return;let P=Z.retry??(v1?0:3),O=Z.retryDelay??V$,w=typeof O==="function"?O(X,q):O,E=P===!0||typeof P==="number"&&X<P||typeof P==="function"&&P(X,q);if(J||!E){z(q);return}X++,Z.onFail?.(X,q),TX(w).then(()=>{return U()?void 0:B()}).then(()=>{if(J)z(q);else M()})})};return{promise:G,status:()=>G.status,cancel:H,continue:()=>{return Y?.(),G},cancelRetry:Q,continueRetry:K,canStart:$,start:()=>{if($())M();else B().then(M);return G}}}var A9=class{#Z;destroy(){this.clearGcTimeout()}scheduleGc(){if(this.clearGcTimeout(),Y6(this.gcTime))this.#Z=F0.setTimeout(()=>{this.optionalRemove()},this.gcTime)}updateGcTime(Z){this.gcTime=Math.max(this.gcTime||0,Z??(v1?1/0:300000))}clearGcTimeout(){if(this.#Z)F0.clearTimeout(this.#Z),this.#Z=void 0}};var jX=class extends A9{#Z;#J;#X;#G;#Y;#Q;#H;constructor(Z){super();this.#H=!1,this.#Q=Z.defaultOptions,this.setOptions(Z.options),this.observers=[],this.#G=Z.client,this.#X=this.#G.getQueryCache(),this.queryKey=Z.queryKey,this.queryHash=Z.queryHash,this.#Z=EX(this.options),this.state=Z.state??this.#Z,this.scheduleGc()}get meta(){return this.options.meta}get promise(){return this.#Y?.promise}setOptions(Z){if(this.options={...this.#Q,...Z},this.updateGcTime(this.options.gcTime),this.state&&this.state.data===void 0){let J=EX(this.options);if(J.data!==void 0)this.setState(CX(J.data,J.dataUpdatedAt)),this.#Z=J}}optionalRemove(){if(!this.observers.length&&this.state.fetchStatus==="idle")this.#X.remove(this)}setData(Z,J){let X=W6(this.state.data,Z,this.options);return this.#W({data:X,type:"success",dataUpdatedAt:J?.updatedAt,manual:J?.manual}),X}setState(Z,J){this.#W({type:"setState",state:Z,setStateOptions:J})}cancel(Z){let J=this.#Y?.promise;return this.#Y?.cancel(Z),J?J.then(U1).catch(U1):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(this.#Z)}isActive(){return this.observers.some((Z)=>y1(Z.options.enabled,this)!==!1)}isDisabled(){if(this.getObserversCount()>0)return!this.isActive();return this.options.queryFn===O5||this.state.dataUpdateCount+this.state.errorUpdateCount===0}isStatic(){if(this.getObserversCount()>0)return this.observers.some((Z)=>W0(Z.options.staleTime,this)==="static");return!1}isStale(){if(this.getObserversCount()>0)return this.observers.some((Z)=>Z.getCurrentResult().isStale);return this.state.data===void 0||this.state.isInvalidated}isStaleByTime(Z=0){if(this.state.data===void 0)return!0;if(Z==="static")return!1;if(this.state.isInvalidated)return!0;return!$9(this.state.dataUpdatedAt,Z)}onFocus(){this.observers.find((J)=>J.shouldFetchOnWindowFocus())?.refetch({cancelRefetch:!1}),this.#Y?.continue()}onOnline(){this.observers.find((J)=>J.shouldFetchOnReconnect())?.refetch({cancelRefetch:!1}),this.#Y?.continue()}addObserver(Z){if(!this.observers.includes(Z))this.observers.push(Z),this.clearGcTimeout(),this.#X.notify({type:"observerAdded",query:this,observer:Z})}removeObserver(Z){if(this.observers.includes(Z)){if(this.observers=this.observers.filter((J)=>J!==Z),!this.observers.length){if(this.#Y)if(this.#H)this.#Y.cancel({revert:!0});else this.#Y.cancelRetry();this.scheduleGc()}this.#X.notify({type:"observerRemoved",query:this,observer:Z})}}getObserversCount(){return this.observers.length}invalidate(){if(!this.state.isInvalidated)this.#W({type:"invalidate"})}async fetch(Z,J){if(this.state.fetchStatus!=="idle"&&this.#Y?.status()!=="rejected"){if(this.state.data!==void 0&&J?.cancelRefetch)this.cancel({silent:!0});else if(this.#Y)return this.#Y.continueRetry(),this.#Y.promise}if(Z)this.setOptions(Z);if(!this.options.queryFn){let Q=this.observers.find((K)=>K.options.queryFn);if(Q)this.setOptions(Q.options)}let X=new AbortController,Y=(Q)=>{Object.defineProperty(Q,"signal",{enumerable:!0,get:()=>{return this.#H=!0,X.signal}})},G=()=>{let Q=M9(this.options,J),U=(()=>{let $={client:this.#G,queryKey:this.queryKey,meta:this.meta};return Y($),$})();if(this.#H=!1,this.options.persister)return this.options.persister(Q,U,this);return Q(U)},H=(()=>{let Q={fetchOptions:J,options:this.options,queryKey:this.queryKey,client:this.#G,state:this.state,fetchFn:G};return Y(Q),Q})();if(this.options.behavior?.onFetch(H,this),this.#J=this.state,this.state.fetchStatus==="idle"||this.state.fetchMeta!==H.fetchOptions?.meta)this.#W({type:"fetch",meta:H.fetchOptions?.meta});this.#Y=V9({initialPromise:J?.initialPromise,fn:H.fetchFn,onCancel:(Q)=>{if(Q instanceof N9&&Q.revert)this.setState({...this.#J,fetchStatus:"idle"});X.abort()},onFail:(Q,K)=>{this.#W({type:"failed",failureCount:Q,error:K})},onPause:()=>{this.#W({type:"pause"})},onContinue:()=>{this.#W({type:"continue"})},retry:H.options.retry,retryDelay:H.options.retryDelay,networkMode:H.options.networkMode,canRun:()=>!0});try{let Q=await this.#Y.start();if(Q===void 0)throw Error(`${this.queryHash} data is undefined`);return this.setData(Q),this.#X.config.onSuccess?.(Q,this),this.#X.config.onSettled?.(Q,this.state.error,this),Q}catch(Q){if(Q instanceof N9){if(Q.silent)return this.#Y.promise;else if(Q.revert){if(this.state.data===void 0)throw Q;return this.state.data}}throw this.#W({type:"error",error:Q}),this.#X.config.onError?.(Q,this),this.#X.config.onSettled?.(this.state.data,Q,this),Q}finally{this.scheduleGc()}}#W(Z){let J=(X)=>{switch(Z.type){case"failed":return{...X,fetchFailureCount:Z.failureCount,fetchFailureReason:Z.error};case"pause":return{...X,fetchStatus:"paused"};case"continue":return{...X,fetchStatus:"fetching"};case"fetch":return{...X,...D7(X.data,this.options),fetchMeta:Z.meta??null};case"success":let Y={...X,...CX(Z.data,Z.dataUpdatedAt),dataUpdateCount:X.dataUpdateCount+1,...!Z.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};return this.#J=Z.manual?Y:void 0,Y;case"error":let G=Z.error;return{...X,error:G,errorUpdateCount:X.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:X.fetchFailureCount+1,fetchFailureReason:G,fetchStatus:"idle",status:"error",isInvalidated:!0};case"invalidate":return{...X,isInvalidated:!0};case"setState":return{...X,...Z.state}}};this.state=J(this.state),Y1.batch(()=>{this.observers.forEach((X)=>{X.onQueryUpdate()}),this.#X.notify({query:this,type:"updated",action:Z})})}};function D7(Z,J){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:A7(J.networkMode)?"fetching":"paused",...Z===void 0&&{error:null,status:"pending"}}}function CX(Z,J){return{data:Z,dataUpdatedAt:J??Date.now(),error:null,isInvalidated:!1,status:"success"}}function EX(Z){let J=typeof Z.initialData==="function"?Z.initialData():Z.initialData,X=J!==void 0,Y=X?typeof Z.initialDataUpdatedAt==="function"?Z.initialDataUpdatedAt():Z.initialDataUpdatedAt:0;return{data:J,dataUpdateCount:0,dataUpdatedAt:X?Y??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:X?"success":"pending",fetchStatus:"idle"}}var R7=class extends M0{constructor(Z,J){super();this.options=J,this.#Z=Z,this.#W=null,this.#H=H6(),this.bindMethods(),this.setOptions(J)}#Z;#J=void 0;#X=void 0;#G=void 0;#Y;#Q;#H;#W;#F;#B;#z;#U;#$;#K;#M=new Set;bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){if(this.listeners.size===1){if(this.#J.addObserver(this),xX(this.#J,this.options))this.#L();else this.updateResult();this.#D()}}onUnsubscribe(){if(!this.hasListeners())this.destroy()}shouldFetchOnReconnect(){return q7(this.#J,this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return q7(this.#J,this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,this.#q(),this.#R(),this.#J.removeObserver(this)}setOptions(Z){let J=this.options,X=this.#J;if(this.options=this.#Z.defaultQueryOptions(Z),this.options.enabled!==void 0&&typeof this.options.enabled!=="boolean"&&typeof this.options.enabled!=="function"&&typeof y1(this.options.enabled,this.#J)!=="boolean")throw Error("Expected enabled to be a boolean or a callback that returns a boolean");if(this.#I(),this.#J.setOptions(this.options),J._defaulted&&!z9(this.options,J))this.#Z.getQueryCache().notify({type:"observerOptionsUpdated",query:this.#J,observer:this});let Y=this.hasListeners();if(Y&&bX(this.#J,X,this.options,J))this.#L();if(this.updateResult(),Y&&(this.#J!==X||y1(this.options.enabled,this.#J)!==y1(J.enabled,this.#J)||W0(this.options.staleTime,this.#J)!==W0(J.staleTime,this.#J)))this.#N();let G=this.#V();if(Y&&(this.#J!==X||y1(this.options.enabled,this.#J)!==y1(J.enabled,this.#J)||G!==this.#K))this.#A(G)}getOptimisticResult(Z){let J=this.#Z.getQueryCache().build(this.#Z,Z),X=this.createResult(J,Z);if(D$(this,X))this.#G=X,this.#Q=this.options,this.#Y=this.#J.state;return X}getCurrentResult(){return this.#G}trackResult(Z,J){return new Proxy(Z,{get:(X,Y)=>{if(this.trackProp(Y),J?.(Y),Y==="promise"){if(this.trackProp("data"),!this.options.experimental_prefetchInRender&&this.#H.status==="pending")this.#H.reject(Error("experimental_prefetchInRender feature flag is not enabled"))}return Reflect.get(X,Y)}})}trackProp(Z){this.#M.add(Z)}getCurrentQuery(){return this.#J}refetch({...Z}={}){return this.fetch({...Z})}fetchOptimistic(Z){let J=this.#Z.defaultQueryOptions(Z),X=this.#Z.getQueryCache().build(this.#Z,J);return X.fetch().then(()=>this.createResult(X,J))}fetch(Z){return this.#L({...Z,cancelRefetch:Z.cancelRefetch??!0}).then(()=>{return this.updateResult(),this.#G})}#L(Z){this.#I();let J=this.#J.fetch(this.options,Z);if(!Z?.throwOnError)J=J.catch(U1);return J}#N(){this.#q();let Z=W0(this.options.staleTime,this.#J);if(v1||this.#G.isStale||!Y6(Z))return;let X=$9(this.#G.dataUpdatedAt,Z)+1;this.#U=F0.setTimeout(()=>{if(!this.#G.isStale)this.updateResult()},X)}#V(){return(typeof this.options.refetchInterval==="function"?this.options.refetchInterval(this.#J):this.options.refetchInterval)??!1}#A(Z){if(this.#R(),this.#K=Z,v1||y1(this.options.enabled,this.#J)===!1||!Y6(this.#K)||this.#K===0)return;this.#$=F0.setInterval(()=>{if(this.options.refetchIntervalInBackground||T5.isFocused())this.#L()},this.#K)}#D(){this.#N(),this.#A(this.#V())}#q(){if(this.#U)F0.clearTimeout(this.#U),this.#U=void 0}#R(){if(this.#$)F0.clearInterval(this.#$),this.#$=void 0}createResult(Z,J){let X=this.#J,Y=this.options,G=this.#G,W=this.#Y,H=this.#Q,K=Z!==X?Z.state:this.#X,{state:U}=Z,$={...U},L=!1,z;if(J._optimisticResults){let l=this.hasListeners(),y=!l&&xX(Z,J),a=l&&bX(Z,X,J,Y);if(y||a)$={...$,...D7(U.data,Z.options)};if(J._optimisticResults==="isRestoring")$.fetchStatus="idle"}let{error:B,errorUpdatedAt:M,status:F}=$;z=$.data;let D=!1;if(J.placeholderData!==void 0&&z===void 0&&F==="pending"){let l;if(G?.isPlaceholderData&&J.placeholderData===H?.placeholderData)l=G.data,D=!0;else l=typeof J.placeholderData==="function"?J.placeholderData(this.#z?.state.data,this.#z):J.placeholderData;if(l!==void 0)F="success",z=W6(G?.data,l,J),L=!0}if(J.select&&z!==void 0&&!D)if(G&&z===W?.data&&J.select===this.#F)z=this.#B;else try{this.#F=J.select,z=J.select(z),z=W6(G?.data,z,J),this.#B=z,this.#W=null}catch(l){this.#W=l}if(this.#W)B=this.#W,z=this.#B,M=Date.now(),F="error";let q=$.fetchStatus==="fetching",P=F==="pending",O=F==="error",w=P&&q,E=z!==void 0,k={status:F,fetchStatus:$.fetchStatus,isPending:P,isSuccess:F==="success",isError:O,isInitialLoading:w,isLoading:w,data:z,dataUpdatedAt:$.dataUpdatedAt,error:B,errorUpdatedAt:M,failureCount:$.fetchFailureCount,failureReason:$.fetchFailureReason,errorUpdateCount:$.errorUpdateCount,isFetched:$.dataUpdateCount>0||$.errorUpdateCount>0,isFetchedAfterMount:$.dataUpdateCount>K.dataUpdateCount||$.errorUpdateCount>K.errorUpdateCount,isFetching:q,isRefetching:q&&!P,isLoadingError:O&&!E,isPaused:$.fetchStatus==="paused",isPlaceholderData:L,isRefetchError:O&&E,isStale:I7(Z,J),refetch:this.refetch,promise:this.#H,isEnabled:y1(J.enabled,Z)!==!1};if(this.options.experimental_prefetchInRender){let l=k.data!==void 0,y=k.status==="error"&&!l,a=(C)=>{if(y)C.reject(k.error);else if(l)C.resolve(k.data)},c=()=>{let C=this.#H=k.promise=H6();a(C)},p=this.#H;switch(p.status){case"pending":if(Z.queryHash===X.queryHash)a(p);break;case"fulfilled":if(y||k.data!==p.value)c();break;case"rejected":if(!y||k.error!==p.reason)c();break}}return k}updateResult(){let Z=this.#G,J=this.createResult(this.#J,this.options);if(this.#Y=this.#J.state,this.#Q=this.options,this.#Y.data!==void 0)this.#z=this.#J;if(z9(J,Z))return;this.#G=J;let X=()=>{if(!Z)return!0;let{notifyOnChangeProps:Y}=this.options,G=typeof Y==="function"?Y():Y;if(G==="all"||!G&&!this.#M.size)return!0;let W=new Set(G??this.#M);if(this.options.throwOnError)W.add("error");return Object.keys(this.#G).some((H)=>{let Q=H;return this.#G[Q]!==Z[Q]&&W.has(Q)})};this.#O({listeners:X()})}#I(){let Z=this.#Z.getQueryCache().build(this.#Z,this.options);if(Z===this.#J)return;let J=this.#J;if(this.#J=Z,this.#X=Z.state,this.hasListeners())J?.removeObserver(this),Z.addObserver(this)}onQueryUpdate(){if(this.updateResult(),this.hasListeners())this.#D()}#O(Z){Y1.batch(()=>{if(Z.listeners)this.listeners.forEach((J)=>{J(this.#G)});this.#Z.getQueryCache().notify({query:this.#J,type:"observerResultsUpdated"})})}};function A$(Z,J){return y1(J.enabled,Z)!==!1&&Z.state.data===void 0&&!(Z.state.status==="error"&&J.retryOnMount===!1)}function xX(Z,J){return A$(Z,J)||Z.state.data!==void 0&&q7(Z,J,J.refetchOnMount)}function q7(Z,J,X){if(y1(J.enabled,Z)!==!1&&W0(J.staleTime,Z)!=="static"){let Y=typeof X==="function"?X(Z):X;return Y==="always"||Y!==!1&&I7(Z,J)}return!1}function bX(Z,J,X,Y){return(Z!==J||y1(Y.enabled,Z)===!1)&&(!X.suspense||Z.state.status!=="error")&&I7(Z,X)}function I7(Z,J){return y1(J.enabled,Z)!==!1&&Z.isStaleByTime(W0(J.staleTime,Z))}function D$(Z,J){if(!z9(Z.getCurrentResult(),J))return!0;return!1}function O7(Z){return{onFetch:(J,X)=>{let Y=J.options,G=J.fetchOptions?.meta?.fetchMore?.direction,W=J.state.data?.pages||[],H=J.state.data?.pageParams||[],Q={pages:[],pageParams:[]},K=0,U=async()=>{let $=!1,L=(M)=>{_X(M,()=>J.signal,()=>$=!0)},z=M9(J.options,J.fetchOptions),B=async(M,F,D)=>{if($)return Promise.reject();if(F==null&&M.pages.length)return Promise.resolve(M);let P=(()=>{let I={client:J.client,queryKey:J.queryKey,pageParam:F,direction:D?"backward":"forward",meta:J.options.meta};return L(I),I})(),O=await z(P),{maxPages:w}=J.options,E=D?wX:PX;return{pages:E(M.pages,O,w),pageParams:E(M.pageParams,F,w)}};if(G&&W.length){let M=G==="backward",F=M?q$:kX,D={pages:W,pageParams:H},q=F(Y,D);Q=await B(D,q,M)}else{let M=Z??W.length;do{let F=K===0?H[0]??Y.initialPageParam:kX(Y,Q);if(K>0&&F==null)break;Q=await B(Q,F),K++}while(K<M)}return Q};if(J.options.persister)J.fetchFn=()=>{return J.options.persister?.(U,{client:J.client,queryKey:J.queryKey,meta:J.options.meta,signal:J.signal},X)};else J.fetchFn=U}}}function kX(Z,{pages:J,pageParams:X}){let Y=J.length-1;return J.length>0?Z.getNextPageParam(J[Y],J,X[Y],X):void 0}function q$(Z,{pages:J,pageParams:X}){return J.length>0?Z.getPreviousPageParam?.(J[0],J,X[0],X):void 0}var gX=class extends A9{#Z;#J;#X;#G;constructor(Z){super();this.#Z=Z.client,this.mutationId=Z.mutationId,this.#X=Z.mutationCache,this.#J=[],this.state=Z.state||R$(),this.setOptions(Z.options),this.scheduleGc()}setOptions(Z){this.options=Z,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(Z){if(!this.#J.includes(Z))this.#J.push(Z),this.clearGcTimeout(),this.#X.notify({type:"observerAdded",mutation:this,observer:Z})}removeObserver(Z){this.#J=this.#J.filter((J)=>J!==Z),this.scheduleGc(),this.#X.notify({type:"observerRemoved",mutation:this,observer:Z})}optionalRemove(){if(!this.#J.length)if(this.state.status==="pending")this.scheduleGc();else this.#X.remove(this)}continue(){return this.#G?.continue()??this.execute(this.state.variables)}async execute(Z){let J=()=>{this.#Y({type:"continue"})},X={client:this.#Z,meta:this.options.meta,mutationKey:this.options.mutationKey};this.#G=V9({fn:()=>{if(!this.options.mutationFn)return Promise.reject(Error("No mutationFn found"));return this.options.mutationFn(Z,X)},onFail:(W,H)=>{this.#Y({type:"failed",failureCount:W,error:H})},onPause:()=>{this.#Y({type:"pause"})},onContinue:J,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>this.#X.canRun(this)});let Y=this.state.status==="pending",G=!this.#G.canStart();try{if(Y)J();else{if(this.#Y({type:"pending",variables:Z,isPaused:G}),this.#X.config.onMutate)await this.#X.config.onMutate(Z,this,X);let H=await this.options.onMutate?.(Z,X);if(H!==this.state.context)this.#Y({type:"pending",context:H,variables:Z,isPaused:G})}let W=await this.#G.start();return await this.#X.config.onSuccess?.(W,Z,this.state.context,this,X),await this.options.onSuccess?.(W,Z,this.state.context,X),await this.#X.config.onSettled?.(W,null,this.state.variables,this.state.context,this,X),await this.options.onSettled?.(W,null,Z,this.state.context,X),this.#Y({type:"success",data:W}),W}catch(W){try{await this.#X.config.onError?.(W,Z,this.state.context,this,X)}catch(H){Promise.reject(H)}try{await this.options.onError?.(W,Z,this.state.context,X)}catch(H){Promise.reject(H)}try{await this.#X.config.onSettled?.(void 0,W,this.state.variables,this.state.context,this,X)}catch(H){Promise.reject(H)}try{await this.options.onSettled?.(void 0,W,Z,this.state.context,X)}catch(H){Promise.reject(H)}throw this.#Y({type:"error",error:W}),W}finally{this.#X.runNext(this)}}#Y(Z){let J=(X)=>{switch(Z.type){case"failed":return{...X,failureCount:Z.failureCount,failureReason:Z.error};case"pause":return{...X,isPaused:!0};case"continue":return{...X,isPaused:!1};case"pending":return{...X,context:Z.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:Z.isPaused,status:"pending",variables:Z.variables,submittedAt:Date.now()};case"success":return{...X,data:Z.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...X,data:void 0,error:Z.error,failureCount:X.failureCount+1,failureReason:Z.error,isPaused:!1,status:"error"}}};this.state=J(this.state),Y1.batch(()=>{this.#J.forEach((X)=>{X.onMutationUpdate(Z)}),this.#X.notify({mutation:this,type:"updated",action:Z})})}};function R$(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var hX=class extends M0{constructor(Z={}){super();this.config=Z,this.#Z=new Set,this.#J=new Map,this.#X=0}#Z;#J;#X;build(Z,J,X){let Y=new gX({client:Z,mutationCache:this,mutationId:++this.#X,options:Z.defaultMutationOptions(J),state:X});return this.add(Y),Y}add(Z){this.#Z.add(Z);let J=D9(Z);if(typeof J==="string"){let X=this.#J.get(J);if(X)X.push(Z);else this.#J.set(J,[Z])}this.notify({type:"added",mutation:Z})}remove(Z){if(this.#Z.delete(Z)){let J=D9(Z);if(typeof J==="string"){let X=this.#J.get(J);if(X){if(X.length>1){let Y=X.indexOf(Z);if(Y!==-1)X.splice(Y,1)}else if(X[0]===Z)this.#J.delete(J)}}}this.notify({type:"removed",mutation:Z})}canRun(Z){let J=D9(Z);if(typeof J==="string"){let Y=this.#J.get(J)?.find((G)=>G.state.status==="pending");return!Y||Y===Z}else return!0}runNext(Z){let J=D9(Z);if(typeof J==="string")return this.#J.get(J)?.find((Y)=>Y!==Z&&Y.state.isPaused)?.continue()??Promise.resolve();else return Promise.resolve()}clear(){Y1.batch(()=>{this.#Z.forEach((Z)=>{this.notify({type:"removed",mutation:Z})}),this.#Z.clear(),this.#J.clear()})}getAll(){return Array.from(this.#Z)}find(Z){let J={exact:!0,...Z};return this.getAll().find((X)=>B9(J,X))}findAll(Z={}){return this.getAll().filter((J)=>B9(Z,J))}notify(Z){Y1.batch(()=>{this.listeners.forEach((J)=>{J(Z)})})}resumePausedMutations(){let Z=this.getAll().filter((J)=>J.state.isPaused);return Y1.batch(()=>Promise.all(Z.map((J)=>J.continue().catch(U1))))}};function D9(Z){return Z.options.scope?.id}var vX=class extends M0{constructor(Z={}){super();this.config=Z,this.#Z=new Map}#Z;build(Z,J,X){let Y=J.queryKey,G=J.queryHash??G6(Y,J),W=this.get(G);if(!W)W=new jX({client:Z,queryKey:Y,queryHash:G,options:Z.defaultQueryOptions(J),state:X,defaultOptions:Z.getQueryDefaults(Y)}),this.add(W);return W}add(Z){if(!this.#Z.has(Z.queryHash))this.#Z.set(Z.queryHash,Z),this.notify({type:"added",query:Z})}remove(Z){let J=this.#Z.get(Z.queryHash);if(J){if(Z.destroy(),J===Z)this.#Z.delete(Z.queryHash);this.notify({type:"removed",query:Z})}}clear(){Y1.batch(()=>{this.getAll().forEach((Z)=>{this.remove(Z)})})}get(Z){return this.#Z.get(Z)}getAll(){return[...this.#Z.values()]}find(Z){let J={exact:!0,...Z};return this.getAll().find((X)=>L9(J,X))}findAll(Z={}){let J=this.getAll();return Object.keys(Z).length>0?J.filter((X)=>L9(Z,X)):J}notify(Z){Y1.batch(()=>{this.listeners.forEach((J)=>{J(Z)})})}onFocus(){Y1.batch(()=>{this.getAll().forEach((Z)=>{Z.onFocus()})})}onOnline(){Y1.batch(()=>{this.getAll().forEach((Z)=>{Z.onOnline()})})}};var T7=class{#Z;#J;#X;#G;#Y;#Q;#H;#W;constructor(Z={}){this.#Z=Z.queryCache||new vX,this.#J=Z.mutationCache||new hX,this.#X=Z.defaultOptions||{},this.#G=new Map,this.#Y=new Map,this.#Q=0}mount(){if(this.#Q++,this.#Q!==1)return;this.#H=T5.subscribe(async(Z)=>{if(Z)await this.resumePausedMutations(),this.#Z.onFocus()}),this.#W=P5.subscribe(async(Z)=>{if(Z)await this.resumePausedMutations(),this.#Z.onOnline()})}unmount(){if(this.#Q--,this.#Q!==0)return;this.#H?.(),this.#H=void 0,this.#W?.(),this.#W=void 0}isFetching(Z){return this.#Z.findAll({...Z,fetchStatus:"fetching"}).length}isMutating(Z){return this.#J.findAll({...Z,status:"pending"}).length}getQueryData(Z){let J=this.defaultQueryOptions({queryKey:Z});return this.#Z.get(J.queryHash)?.state.data}ensureQueryData(Z){let J=this.defaultQueryOptions(Z),X=this.#Z.build(this,J),Y=X.state.data;if(Y===void 0)return this.fetchQuery(Z);if(Z.revalidateIfStale&&X.isStaleByTime(W0(J.staleTime,X)))this.prefetchQuery(J);return Promise.resolve(Y)}getQueriesData(Z){return this.#Z.findAll(Z).map(({queryKey:J,state:X})=>{let Y=X.data;return[J,Y]})}setQueryData(Z,J,X){let Y=this.defaultQueryOptions({queryKey:Z}),W=this.#Z.get(Y.queryHash)?.state.data,H=OX(J,W);if(H===void 0)return;return this.#Z.build(this,Y).setData(H,{...X,manual:!0})}setQueriesData(Z,J,X){return Y1.batch(()=>this.#Z.findAll(Z).map(({queryKey:Y})=>[Y,this.setQueryData(Y,J,X)]))}getQueryState(Z){let J=this.defaultQueryOptions({queryKey:Z});return this.#Z.get(J.queryHash)?.state}removeQueries(Z){let J=this.#Z;Y1.batch(()=>{J.findAll(Z).forEach((X)=>{J.remove(X)})})}resetQueries(Z,J){let X=this.#Z;return Y1.batch(()=>{return X.findAll(Z).forEach((Y)=>{Y.reset()}),this.refetchQueries({type:"active",...Z},J)})}cancelQueries(Z,J={}){let X={revert:!0,...J},Y=Y1.batch(()=>this.#Z.findAll(Z).map((G)=>G.cancel(X)));return Promise.all(Y).then(U1).catch(U1)}invalidateQueries(Z,J={}){return Y1.batch(()=>{if(this.#Z.findAll(Z).forEach((X)=>{X.invalidate()}),Z?.refetchType==="none")return Promise.resolve();return this.refetchQueries({...Z,type:Z?.refetchType??Z?.type??"active"},J)})}refetchQueries(Z,J={}){let X={...J,cancelRefetch:J.cancelRefetch??!0},Y=Y1.batch(()=>this.#Z.findAll(Z).filter((G)=>!G.isDisabled()&&!G.isStatic()).map((G)=>{let W=G.fetch(void 0,X);if(!X.throwOnError)W=W.catch(U1);return G.state.fetchStatus==="paused"?Promise.resolve():W}));return Promise.all(Y).then(U1)}fetchQuery(Z){let J=this.defaultQueryOptions(Z);if(J.retry===void 0)J.retry=!1;let X=this.#Z.build(this,J);return X.isStaleByTime(W0(J.staleTime,X))?X.fetch(J):Promise.resolve(X.state.data)}prefetchQuery(Z){return this.fetchQuery(Z).then(U1).catch(U1)}fetchInfiniteQuery(Z){return Z.behavior=O7(Z.pages),this.fetchQuery(Z)}prefetchInfiniteQuery(Z){return this.fetchInfiniteQuery(Z).then(U1).catch(U1)}ensureInfiniteQueryData(Z){return Z.behavior=O7(Z.pages),this.ensureQueryData(Z)}resumePausedMutations(){if(P5.isOnline())return this.#J.resumePausedMutations();return Promise.resolve()}getQueryCache(){return this.#Z}getMutationCache(){return this.#J}getDefaultOptions(){return this.#X}setDefaultOptions(Z){this.#X=Z}setQueryDefaults(Z,J){this.#G.set(J5(Z),{queryKey:Z,defaultOptions:J})}getQueryDefaults(Z){let J=[...this.#G.values()],X={};return J.forEach((Y)=>{if(X5(Z,Y.queryKey))Object.assign(X,Y.defaultOptions)}),X}setMutationDefaults(Z,J){this.#Y.set(J5(Z),{mutationKey:Z,defaultOptions:J})}getMutationDefaults(Z){let J=[...this.#Y.values()],X={};return J.forEach((Y)=>{if(X5(Z,Y.mutationKey))Object.assign(X,Y.defaultOptions)}),X}defaultQueryOptions(Z){if(Z._defaulted)return Z;let J={...this.#X.queries,...this.getQueryDefaults(Z.queryKey),...Z,_defaulted:!0};if(!J.queryHash)J.queryHash=G6(J.queryKey,J);if(J.refetchOnReconnect===void 0)J.refetchOnReconnect=J.networkMode!=="always";if(J.throwOnError===void 0)J.throwOnError=!!J.suspense;if(!J.networkMode&&J.persister)J.networkMode="offlineFirst";if(J.queryFn===O5)J.enabled=!1;return J}defaultMutationOptions(Z){if(Z?._defaulted)return Z;return{...this.#X.mutations,...Z?.mutationKey&&this.getMutationDefaults(Z.mutationKey),...Z,_defaulted:!0}}clear(){this.#Z.clear(),this.#J.clear()}};import*as w5 from"react";import{jsx as I$}from"react/jsx-runtime";var P7=w5.createContext(void 0),w7=(Z)=>{let J=w5.useContext(P7);if(Z)return Z;if(!J)throw Error("No QueryClient set, use QueryClientProvider to set one");return J},H0=({client:Z,children:J})=>{return w5.useEffect(()=>{return Z.mount(),()=>{Z.unmount()}},[Z]),I$(P7.Provider,{value:Z,children:J})};import*as q9 from"react";var yX=q9.createContext(!1),mX=()=>q9.useContext(yX),Mw=yX.Provider;import*as Q6 from"react";import{jsx as Vw}from"react/jsx-runtime";function O$(){let Z=!1;return{clearReset:()=>{Z=!1},reset:()=>{Z=!0},isReset:()=>{return Z}}}var T$=Q6.createContext(O$()),fX=()=>Q6.useContext(T$);import*as uX from"react";var pX=(Z,J,X)=>{let Y=X?.state.error&&typeof Z.throwOnError==="function"?F9(Z.throwOnError,[X.state.error,X]):Z.throwOnError;if(Z.suspense||Z.experimental_prefetchInRender||Y){if(!J.isReset())Z.retryOnMount=!1}},lX=(Z)=>{uX.useEffect(()=>{Z.clearReset()},[Z])},dX=({result:Z,errorResetBoundary:J,throwOnError:X,query:Y,suspense:G})=>{return Z.isError&&!J.isReset()&&!Z.isFetching&&Y&&(G&&Z.data===void 0||F9(X,[Z.error,Y]))};var cX=(Z)=>{if(Z.suspense){let X=(G)=>G==="static"?G:Math.max(G??1000,1000),Y=Z.staleTime;if(Z.staleTime=typeof Y==="function"?(...G)=>X(Y(...G)):X(Y),typeof Z.gcTime==="number")Z.gcTime=Math.max(Z.gcTime,1000)}},iX=(Z,J)=>Z.isLoading&&Z.isFetching&&!J,nX=(Z,J)=>Z?.suspense&&J.isPending,_7=(Z,J,X)=>J.fetchOptimistic(Z).catch(()=>{X.clearReset()});import*as k0 from"react";function aX(Z,J,X){let Y=mX(),G=fX(),W=w7(X),H=W.defaultQueryOptions(Z);W.getDefaultOptions().queries?._experimental_beforeQuery?.(H);let Q=W.getQueryCache().get(H.queryHash);H._optimisticResults=Y?"isRestoring":"optimistic",cX(H),pX(H,G,Q),lX(G);let K=!W.getQueryCache().get(H.queryHash),[U]=k0.useState(()=>new J(W,H)),$=U.getOptimisticResult(H),L=!Y&&Z.subscribed!==!1;if(k0.useSyncExternalStore(k0.useCallback((z)=>{let B=L?U.subscribe(Y1.batchCalls(z)):U1;return U.updateResult(),B},[U,L]),()=>U.getCurrentResult(),()=>U.getCurrentResult()),k0.useEffect(()=>{U.setOptions(H)},[H,U]),nX(H,$))throw _7(H,U,G);if(dX({result:$,errorResetBoundary:G,throwOnError:H.throwOnError,query:Q,suspense:H.suspense}))throw $.error;if(W.getDefaultOptions().queries?._experimental_afterQuery?.(H,$),H.experimental_prefetchInRender&&!v1&&iX($,Y))(K?_7(H,U,G):Q?.promise)?.catch(U1).finally(()=>{U.updateResult()});return!H.notifyOnChangeProps?U.trackResult($):$}function K6(Z,J){return aX(Z,R7,J)}var h9=r(S7(),1),d3=r(j7(),1);import l3,{useState as QF,useContext as k3,useRef as KF,useEffect as g3,forwardRef as UF}from"react";var s$={animationIterationCount:!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};function U6(Z,J){var X=!s$[Z]&&typeof J==="number"&&J!==0;return X?J+"px":J}function $6(Z,J){return Object.keys(Z).reduce(function(X,Y){return X[Y]=J(Z[Y],Y),X},{})}function x7(Z){return $6(Z,function(J,X){return U6(X,Z[X])+" !important"})}var o$=/([a-z])?([A-Z])/g,t$=function(J,X,Y){return(X||"")+"-"+Y.toLowerCase()},b7=function(J){return J.replace(o$,t$)},e$=function(J){return Object.keys(J).reduce(function(X,Y){var G=b7(Y);if(/^ms-/.test(G))G="-".concat(G);return X[G]=J[Y],X},{})},LY=e$;var z3=r(RY(),1),M3=r(bY(),1),F3=r(i7(),1);var zG=r(hY(),1),MG=r(yY(),1),FG=r(fY(),1),NG=r(pY(),1),VG=r(cY(),1),AG=r(aY(),1),DG=r(oY(),1),qG=r(ZG(),1),RG=r(XG(),1),IG=r(GG(),1),OG=r(HG(),1),TG=r(BG(),1),b=["Webkit"],$4=["Moz"],H1=["ms"],P1=["Webkit","Moz"],N1=["Webkit","ms"],L6=["Webkit","Moz","ms"],PG={plugins:[zG.default,MG.default,FG.default,NG.default,VG.default,AG.default,DG.default,qG.default,RG.default,IG.default,OG.default,TG.default],prefixMap:{transform:N1,transformOrigin:N1,transformOriginX:N1,transformOriginY:N1,backfaceVisibility:b,perspective:b,perspectiveOrigin:b,transformStyle:b,transformOriginZ:b,animation:b,animationDelay:b,animationDirection:b,animationFillMode:b,animationDuration:b,animationIterationCount:b,animationName:b,animationPlayState:b,animationTimingFunction:b,appearance:P1,userSelect:L6,fontKerning:b,textEmphasisPosition:b,textEmphasis:b,textEmphasisStyle:b,textEmphasisColor:b,boxDecorationBreak:b,clipPath:b,maskImage:b,maskMode:b,maskRepeat:b,maskPosition:b,maskClip:b,maskOrigin:b,maskSize:b,maskComposite:b,mask:b,maskBorderSource:b,maskBorderMode:b,maskBorderSlice:b,maskBorderWidth:b,maskBorderOutset:b,maskBorderRepeat:b,maskBorder:b,maskType:b,textDecorationStyle:P1,textDecorationSkip:P1,textDecorationLine:P1,textDecorationColor:P1,filter:b,fontFeatureSettings:P1,breakAfter:L6,breakBefore:L6,breakInside:L6,columnCount:P1,columnFill:P1,columnGap:P1,columnRule:P1,columnRuleColor:P1,columnRuleStyle:P1,columnRuleWidth:P1,columns:P1,columnSpan:P1,columnWidth:P1,writingMode:N1,flex:N1,flexBasis:b,flexDirection:N1,flexGrow:b,flexFlow:N1,flexShrink:b,flexWrap:N1,alignContent:b,alignItems:b,alignSelf:b,justifyContent:b,order:b,transitionDelay:b,transitionDuration:b,transitionProperty:b,transitionTimingFunction:b,backdropFilter:b,scrollSnapType:N1,scrollSnapPointsX:N1,scrollSnapPointsY:N1,scrollSnapDestination:N1,scrollSnapCoordinate:N1,shapeImageThreshold:b,shapeImageMargin:b,shapeImageOutside:b,hyphens:L6,flowInto:N1,flowFrom:N1,regionFragment:N1,boxSizing:$4,textAlignLast:$4,tabSize:$4,wrapFlow:H1,wrapThrough:H1,wrapMargin:H1,touchAction:H1,gridTemplateColumns:H1,gridTemplateRows:H1,gridTemplateAreas:H1,gridTemplate:H1,gridAutoColumns:H1,gridAutoRows:H1,gridAutoFlow:H1,grid:H1,gridRowStart:H1,gridColumnStart:H1,gridRowEnd:H1,gridRow:H1,gridColumn:H1,gridColumnEnd:H1,gridColumnGap:H1,gridRowGap:H1,gridArea:H1,gridGap:H1,textSizeAdjust:N1,borderImage:b,borderImageOutset:b,borderImageRepeat:b,borderImageSlice:b,borderImageSource:b,borderImageWidth:b}};var eG=r(SG(),1),Z3=r(EG(),1),J3=r(bG(),1),X3=r(gG(),1),Y3=r(vG(),1),G3=r(mG(),1),W3=r(uG(),1),H3=r(dG(),1),Q3=r(iG(),1),K3=r(aG(),1),U3=r(sG(),1),$3=r(tG(),1),L3={plugins:[eG.default,Z3.default,J3.default,X3.default,Y3.default,G3.default,W3.default,H3.default,Q3.default,K3.default,U3.default,$3.default],prefixMap:{chrome:{transform:35,transformOrigin:35,transformOriginX:35,transformOriginY:35,backfaceVisibility:35,perspective:35,perspectiveOrigin:35,transformStyle:35,transformOriginZ:35,animation:42,animationDelay:42,animationDirection:42,animationFillMode:42,animationDuration:42,animationIterationCount:42,animationName:42,animationPlayState:42,animationTimingFunction:42,appearance:66,userSelect:53,fontKerning:32,textEmphasisPosition:66,textEmphasis:66,textEmphasisStyle:66,textEmphasisColor:66,boxDecorationBreak:66,clipPath:54,maskImage:66,maskMode:66,maskRepeat:66,maskPosition:66,maskClip:66,maskOrigin:66,maskSize:66,maskComposite:66,mask:66,maskBorderSource:66,maskBorderMode:66,maskBorderSlice:66,maskBorderWidth:66,maskBorderOutset:66,maskBorderRepeat:66,maskBorder:66,maskType:66,textDecorationStyle:56,textDecorationSkip:56,textDecorationLine:56,textDecorationColor:56,filter:52,fontFeatureSettings:47,breakAfter:49,breakBefore:49,breakInside:49,columnCount:49,columnFill:49,columnGap:49,columnRule:49,columnRuleColor:49,columnRuleStyle:49,columnRuleWidth:49,columns:49,columnSpan:49,columnWidth:49,writingMode:47},safari:{flex:8,flexBasis:8,flexDirection:8,flexGrow:8,flexFlow:8,flexShrink:8,flexWrap:8,alignContent:8,alignItems:8,alignSelf:8,justifyContent:8,order:8,transition:6,transitionDelay:6,transitionDuration:6,transitionProperty:6,transitionTimingFunction:6,transform:8,transformOrigin:8,transformOriginX:8,transformOriginY:8,backfaceVisibility:8,perspective:8,perspectiveOrigin:8,transformStyle:8,transformOriginZ:8,animation:8,animationDelay:8,animationDirection:8,animationFillMode:8,animationDuration:8,animationIterationCount:8,animationName:8,animationPlayState:8,animationTimingFunction:8,appearance:11,userSelect:11,backdropFilter:11,fontKerning:9,scrollSnapType:10.1,scrollSnapPointsX:10.1,scrollSnapPointsY:10.1,scrollSnapDestination:10.1,scrollSnapCoordinate:10.1,textEmphasisPosition:7,textEmphasis:7,textEmphasisStyle:7,textEmphasisColor:7,boxDecorationBreak:11,clipPath:11,maskImage:11,maskMode:11,maskRepeat:11,maskPosition:11,maskClip:11,maskOrigin:11,maskSize:11,maskComposite:11,mask:11,maskBorderSource:11,maskBorderMode:11,maskBorderSlice:11,maskBorderWidth:11,maskBorderOutset:11,maskBorderRepeat:11,maskBorder:11,maskType:11,textDecorationStyle:11,textDecorationSkip:11,textDecorationLine:11,textDecorationColor:11,shapeImageThreshold:10,shapeImageMargin:10,shapeImageOutside:10,filter:9,hyphens:11,flowInto:11,flowFrom:11,breakBefore:8,breakAfter:8,breakInside:8,regionFragment:11,columnCount:8,columnFill:8,columnGap:8,columnRule:8,columnRuleColor:8,columnRuleStyle:8,columnRuleWidth:8,columns:8,columnSpan:8,columnWidth:8,writingMode:10.1},firefox:{appearance:60,userSelect:60,boxSizing:28,textAlignLast:48,textDecorationStyle:35,textDecorationSkip:35,textDecorationLine:35,textDecorationColor:35,tabSize:60,hyphens:42,fontFeatureSettings:33,breakAfter:51,breakBefore:51,breakInside:51,columnCount:51,columnFill:51,columnGap:51,columnRule:51,columnRuleColor:51,columnRuleStyle:51,columnRuleWidth:51,columns:51,columnSpan:51,columnWidth:51},opera:{flex:16,flexBasis:16,flexDirection:16,flexGrow:16,flexFlow:16,flexShrink:16,flexWrap:16,alignContent:16,alignItems:16,alignSelf:16,justifyContent:16,order:16,transform:22,transformOrigin:22,transformOriginX:22,transformOriginY:22,backfaceVisibility:22,perspective:22,perspectiveOrigin:22,transformStyle:22,transformOriginZ:22,animation:29,animationDelay:29,animationDirection:29,animationFillMode:29,animationDuration:29,animationIterationCount:29,animationName:29,animationPlayState:29,animationTimingFunction:29,appearance:50,userSelect:40,fontKerning:19,textEmphasisPosition:50,textEmphasis:50,textEmphasisStyle:50,textEmphasisColor:50,boxDecorationBreak:50,clipPath:41,maskImage:50,maskMode:50,maskRepeat:50,maskPosition:50,maskClip:50,maskOrigin:50,maskSize:50,maskComposite:50,mask:50,maskBorderSource:50,maskBorderMode:50,maskBorderSlice:50,maskBorderWidth:50,maskBorderOutset:50,maskBorderRepeat:50,maskBorder:50,maskType:50,textDecorationStyle:43,textDecorationSkip:43,textDecorationLine:43,textDecorationColor:43,filter:39,fontFeatureSettings:34,breakAfter:36,breakBefore:36,breakInside:36,columnCount:36,columnFill:36,columnGap:36,columnRule:36,columnRuleColor:36,columnRuleStyle:36,columnRuleWidth:36,columns:36,columnSpan:36,columnWidth:36,writingMode:34},ie:{flex:10,flexDirection:10,flexFlow:10,flexWrap:10,transform:9,transformOrigin:9,transformOriginX:9,transformOriginY:9,userSelect:11,wrapFlow:11,wrapThrough:11,wrapMargin:11,scrollSnapType:11,scrollSnapPointsX:11,scrollSnapPointsY:11,scrollSnapDestination:11,scrollSnapCoordinate:11,touchAction:10,hyphens:11,flowInto:11,flowFrom:11,breakBefore:11,breakAfter:11,breakInside:11,regionFragment:11,gridTemplateColumns:11,gridTemplateRows:11,gridTemplateAreas:11,gridTemplate:11,gridAutoColumns:11,gridAutoRows:11,gridAutoFlow:11,grid:11,gridRowStart:11,gridColumnStart:11,gridRowEnd:11,gridRow:11,gridColumn:11,gridColumnEnd:11,gridColumnGap:11,gridRowGap:11,gridArea:11,gridGap:11,textSizeAdjust:11,writingMode:11},edge:{userSelect:17,wrapFlow:17,wrapThrough:17,wrapMargin:17,scrollSnapType:17,scrollSnapPointsX:17,scrollSnapPointsY:17,scrollSnapDestination:17,scrollSnapCoordinate:17,hyphens:17,flowInto:17,flowFrom:17,breakBefore:17,breakAfter:17,breakInside:17,regionFragment:17,gridTemplateColumns:15,gridTemplateRows:15,gridTemplateAreas:15,gridTemplate:15,gridAutoColumns:15,gridAutoRows:15,gridAutoFlow:15,grid:15,gridRowStart:15,gridColumnStart:15,gridRowEnd:15,gridRow:15,gridColumn:15,gridColumnEnd:15,gridColumnGap:15,gridRowGap:15,gridArea:15,gridGap:15},ios_saf:{flex:8.1,flexBasis:8.1,flexDirection:8.1,flexGrow:8.1,flexFlow:8.1,flexShrink:8.1,flexWrap:8.1,alignContent:8.1,alignItems:8.1,alignSelf:8.1,justifyContent:8.1,order:8.1,transition:6,transitionDelay:6,transitionDuration:6,transitionProperty:6,transitionTimingFunction:6,transform:8.1,transformOrigin:8.1,transformOriginX:8.1,transformOriginY:8.1,backfaceVisibility:8.1,perspective:8.1,perspectiveOrigin:8.1,transformStyle:8.1,transformOriginZ:8.1,animation:8.1,animationDelay:8.1,animationDirection:8.1,animationFillMode:8.1,animationDuration:8.1,animationIterationCount:8.1,animationName:8.1,animationPlayState:8.1,animationTimingFunction:8.1,appearance:11,userSelect:11,backdropFilter:11,fontKerning:11,scrollSnapType:10.3,scrollSnapPointsX:10.3,scrollSnapPointsY:10.3,scrollSnapDestination:10.3,scrollSnapCoordinate:10.3,boxDecorationBreak:11,clipPath:11,maskImage:11,maskMode:11,maskRepeat:11,maskPosition:11,maskClip:11,maskOrigin:11,maskSize:11,maskComposite:11,mask:11,maskBorderSource:11,maskBorderMode:11,maskBorderSlice:11,maskBorderWidth:11,maskBorderOutset:11,maskBorderRepeat:11,maskBorder:11,maskType:11,textSizeAdjust:11,textDecorationStyle:11,textDecorationSkip:11,textDecorationLine:11,textDecorationColor:11,shapeImageThreshold:10,shapeImageMargin:10,shapeImageOutside:10,filter:9,hyphens:11,flowInto:11,flowFrom:11,breakBefore:8.1,breakAfter:8.1,breakInside:8.1,regionFragment:11,columnCount:8.1,columnFill:8.1,columnGap:8.1,columnRule:8.1,columnRuleColor:8.1,columnRuleStyle:8.1,columnRuleWidth:8.1,columns:8.1,columnSpan:8.1,columnWidth:8.1,writingMode:10.3},android:{borderImage:4.2,borderImageOutset:4.2,borderImageRepeat:4.2,borderImageSlice:4.2,borderImageSource:4.2,borderImageWidth:4.2,flex:4.2,flexBasis:4.2,flexDirection:4.2,flexGrow:4.2,flexFlow:4.2,flexShrink:4.2,flexWrap:4.2,alignContent:4.2,alignItems:4.2,alignSelf:4.2,justifyContent:4.2,order:4.2,transition:4.2,transitionDelay:4.2,transitionDuration:4.2,transitionProperty:4.2,transitionTimingFunction:4.2,transform:4.4,transformOrigin:4.4,transformOriginX:4.4,transformOriginY:4.4,backfaceVisibility:4.4,perspective:4.4,perspectiveOrigin:4.4,transformStyle:4.4,transformOriginZ:4.4,animation:4.4,animationDelay:4.4,animationDirection:4.4,animationFillMode:4.4,animationDuration:4.4,animationIterationCount:4.4,animationName:4.4,animationPlayState:4.4,animationTimingFunction:4.4,appearance:62,userSelect:4.4,fontKerning:4.4,textEmphasisPosition:62,textEmphasis:62,textEmphasisStyle:62,textEmphasisColor:62,boxDecorationBreak:62,clipPath:4.4,maskImage:62,maskMode:62,maskRepeat:62,maskPosition:62,maskClip:62,maskOrigin:62,maskSize:62,maskComposite:62,mask:62,maskBorderSource:62,maskBorderMode:62,maskBorderSlice:62,maskBorderWidth:62,maskBorderOutset:62,maskBorderRepeat:62,maskBorder:62,maskType:62,filter:4.4,fontFeatureSettings:4.4,breakAfter:4.4,breakBefore:4.4,breakInside:4.4,columnCount:4.4,columnFill:4.4,columnGap:4.4,columnRule:4.4,columnRuleColor:4.4,columnRuleStyle:4.4,columnRuleWidth:4.4,columns:4.4,columnSpan:4.4,columnWidth:4.4,writingMode:4.4},and_chr:{appearance:62,textEmphasisPosition:62,textEmphasis:62,textEmphasisStyle:62,textEmphasisColor:62,boxDecorationBreak:62,maskImage:62,maskMode:62,maskRepeat:62,maskPosition:62,maskClip:62,maskOrigin:62,maskSize:62,maskComposite:62,mask:62,maskBorderSource:62,maskBorderMode:62,maskBorderSlice:62,maskBorderWidth:62,maskBorderOutset:62,maskBorderRepeat:62,maskBorder:62,maskType:62},and_uc:{flex:11.4,flexBasis:11.4,flexDirection:11.4,flexGrow:11.4,flexFlow:11.4,flexShrink:11.4,flexWrap:11.4,alignContent:11.4,alignItems:11.4,alignSelf:11.4,justifyContent:11.4,order:11.4,transform:11.4,transformOrigin:11.4,transformOriginX:11.4,transformOriginY:11.4,backfaceVisibility:11.4,perspective:11.4,perspectiveOrigin:11.4,transformStyle:11.4,transformOriginZ:11.4,animation:11.4,animationDelay:11.4,animationDirection:11.4,animationFillMode:11.4,animationDuration:11.4,animationIterationCount:11.4,animationName:11.4,animationPlayState:11.4,animationTimingFunction:11.4,appearance:11.4,userSelect:11.4,textEmphasisPosition:11.4,textEmphasis:11.4,textEmphasisStyle:11.4,textEmphasisColor:11.4,clipPath:11.4,maskImage:11.4,maskMode:11.4,maskRepeat:11.4,maskPosition:11.4,maskClip:11.4,maskOrigin:11.4,maskSize:11.4,maskComposite:11.4,mask:11.4,maskBorderSource:11.4,maskBorderMode:11.4,maskBorderSlice:11.4,maskBorderWidth:11.4,maskBorderOutset:11.4,maskBorderRepeat:11.4,maskBorder:11.4,maskType:11.4,textSizeAdjust:11.4,filter:11.4,hyphens:11.4,fontFeatureSettings:11.4,breakAfter:11.4,breakBefore:11.4,breakInside:11.4,columnCount:11.4,columnFill:11.4,columnGap:11.4,columnRule:11.4,columnRuleColor:11.4,columnRuleStyle:11.4,columnRuleWidth:11.4,columns:11.4,columnSpan:11.4,columnWidth:11.4,writingMode:11.4},op_mini:{}}};function w9(Z){if(typeof Symbol==="function"&&typeof Symbol.iterator==="symbol")w9=function(X){return typeof X};else w9=function(X){return X&&typeof Symbol==="function"&&X.constructor===Symbol&&X!==Symbol.prototype?"symbol":typeof X};return w9(Z)}var N3=z3.default(PG),IM=M3.default(L3,N3);function OM(Z){return Object.keys(Z).reduce(function(J,X){var Y=Z[X];if(Array.isArray(Y))Y=Y.join(";"+X+":");else if(Y&&w9(Y)==="object"&&typeof Y.toString==="function")Y=Y.toString();return J[X]=Y,J},{})}function TM(Z){return Object.keys(Z).reduce(function(J,X){var Y=Z[X];if(Array.isArray(Y))if(F3.default.canUseDOM)Y=Y[Y.length-1].toString();else Y=Y.join(";".concat(b7(X),":"));return J[X]=Y,J},{})}var B3,P9;function V3(Z){var J=Z||global&&global.navigator&&global.navigator.userAgent;if(!P9||J!==B3){if(J==="all")P9={prefix:N3,prefixedKeyframes:"keyframes"};else P9=new IM({userAgent:J});B3=J}return P9}function A3(Z){return V3(Z).prefixedKeyframes||"keyframes"}function _9(Z,J){var X=OM(Z),Y=V3(J),G=Y.prefix(X),W=TM(G);return W}function PM(Z){return Object.keys(Z).map(function(J){return J+": "+Z[J]+";"}).join(`
|
|
16
|
+
`)}function g0(Z,J,X){if(!J)return"";var Y=$6(J,function(Q,K){return U6(K,Q)}),G=_9(Y,X),W=LY(G),H=PM(W);return Z+"{"+H+"}"}var wM=function(J){return J===null||typeof J>"u"?"main":J.toString()},S9=wM;var _M=function(J,X,Y){var G=S9(X);return!!J&&!!J._radiumStyleState&&!!J._radiumStyleState[G]&&J._radiumStyleState[G][Y]},C9=_M;var SM=function(J){return typeof J.ref==="string"?J.ref:J.key},G5=SM;var CM=function(J){return J._lastRadiumState||J.state&&J.state._radiumStyleState||{}},B6=CM;function z6(Z){if(!Z)return"";var J=5381,X=Z.length-1;while(X)J=J*33^Z.charCodeAt(X),X-=1;return(J>>>0).toString(16)}function E9(Z){if(typeof Symbol==="function"&&typeof Symbol.iterator==="symbol")E9=function(X){return typeof X};else E9=function(X){return X&&typeof Symbol==="function"&&X.constructor===Symbol&&X!==Symbol.prototype?"symbol":typeof X};return E9(Z)}function j9(Z){return Z&&Z.constructor===Object&&Z.toString===Object.prototype.toString}function x9(Z){var J={};return Z.forEach(function(X){if(!X||E9(X)!=="object")return;if(Array.isArray(X))X=x9(X);Object.keys(X).forEach(function(Y){if(!j9(X[Y])||!j9(J[Y])){J[Y]=X[Y];return}if(Y.indexOf("@media")===0){var G=Y;while(!0)if(G+=" ",!J[G]){J[G]=X[Y];return}}J[Y]=x9([J[Y],X[Y]])})}),J}var EM=function(){};var D3=EM;function C4(Z){var{addCSS:J,config:X,style:Y}=Z,G=function(Q){var K=Q,U=K.__process(X.userAgent),$=U.animationName,L=U.css;return J(L),$},W=Object.keys(Y).reduce(function(H,Q){var K=Y[Q],U=Array.isArray(K);if(Q==="animationName"&&K&&(K.__radiumKeyframes||U))if(U)K=K.map(G).join(", ");else K=G(K);return H[Q]=K,H},{});return{style:W}}var jM=function(J){var{style:X,mergeStyles:Y}=J,G=Array.isArray(X)?Y(X):X;return{style:G}},q3=jM;function E4(Z){var{config:J,style:X}=Z,Y=_9(X,J.userAgent);return{style:Y}}function j4(Z){var{isNestedStyle:J,style:X}=Z,Y=Object.keys(X).reduce(function(G,W){var H=X[W];if(!J(H))G[W]=H;return G},{});return{style:Y}}var S5=[],b9=!1;function x4(){S5.forEach(function(Z){Z()})}var xM=function(J){if(S5.indexOf(J)===-1)S5.push(J);if(!b9)window.addEventListener("mouseup",x4),b9=!0;return{remove:function(){var Y=S5.indexOf(J);if(S5.splice(Y,1),S5.length===0&&b9)window.removeEventListener("mouseup",x4),b9=!1}}},R3={subscribe:xM,__triggerForTests:x4};var I3=function(J){return J===":hover"||J===":active"||J===":focus"},bM=function(J){var{ExecutionEnvironment:X,getComponentField:Y,getState:G,mergeStyles:W,props:H,setState:Q,style:K}=J,U={},$={};if(K[":hover"]){var L=H.onMouseEnter;$.onMouseEnter=function(w){L&&L(w),Q(":hover",!0)};var z=H.onMouseLeave;$.onMouseLeave=function(w){z&&z(w),Q(":hover",!1)}}if(K[":active"]){var B=H.onMouseDown;$.onMouseDown=function(w){B&&B(w),U._lastMouseDown=Date.now(),Q(":active","viamousedown")};var M=H.onKeyDown;$.onKeyDown=function(w){if(M&&M(w),w.key===" "||w.key==="Enter")Q(":active","viakeydown")};var F=H.onKeyUp;$.onKeyUp=function(w){if(F&&F(w),w.key===" "||w.key==="Enter")Q(":active",!1)}}if(K[":focus"]){var D=H.onFocus;$.onFocus=function(w){D&&D(w),Q(":focus",!0)};var q=H.onBlur;$.onBlur=function(w){q&&q(w),Q(":focus",!1)}}if(K[":active"]&&!Y("_radiumMouseUpListener")&&X.canUseEventListeners)U._radiumMouseUpListener=R3.subscribe(function(){Object.keys(Y("state")._radiumStyleState).forEach(function(w){if(G(":active",w)==="viamousedown")Q(":active",!1,w)})});var P=H.disabled?[K[":disabled"]]:Object.keys(K).filter(function(w){return I3(w)&&G(w)}).map(function(w){return K[w]}),O=W([K].concat(P));return O=Object.keys(O).reduce(function(w,E){if(!I3(E)&&E!==":disabled")w[E]=O[E];return w},{}),{componentFields:U,props:$,style:O}},O3=bM;function kM(Z){for(var J=1;J<arguments.length;J++){var X=arguments[J]!=null?arguments[J]:{},Y=Object.keys(X);if(typeof Object.getOwnPropertySymbols==="function")Y=Y.concat(Object.getOwnPropertySymbols(X).filter(function(G){return Object.getOwnPropertyDescriptor(X,G).enumerable}));Y.forEach(function(G){gM(Z,G,X[G])})}return Z}function gM(Z,J,X){if(J in Z)Object.defineProperty(Z,J,{value:X,enumerable:!0,configurable:!0,writable:!0});else Z[J]=X;return Z}var b4;function hM(Z){if(b4===void 0)b4=!!Z.canUseDOM&&!!window&&!!window.matchMedia&&function(J){return window.matchMedia(J)}||null;return b4}function T3(Z,J){return Object.keys(Z).filter(function(X){return J(Z[X],X)}).reduce(function(X,Y){return X[Y]=Z[Y],X},{})}function vM(Z){return Object.keys(Z).reduce(function(J,X){if(X.indexOf("@media")!==0)J[X]=Z[X];return J},{})}function yM(Z){var{addCSS:J,appendImportantToEachValue:X,cssRuleSetToString:Y,hash:G,isNestedStyle:W,style:H,userAgent:Q}=Z,K="";return Object.keys(H).filter(function(U){return U.indexOf("@media")===0}).map(function(U){var $=X(T3(H[U],function(M){return!W(M)}));if(!Object.keys($).length)return;var L=Y("",$,Q),z="rmq-"+G(U+L),B=U+"{ ."+z+L+"}";J(B),K+=(K?" ":"")+z}),K}function mM(Z){var{listener:J,listenersByQuery:X,matchMedia:Y,mediaQueryListsByQuery:G,query:W}=Z;W=W.replace("@media ","");var H=G[W];if(!H&&Y)G[W]=H=Y(W);if(!X||!X[W])H.addListener(J),X[W]={remove:function(){H.removeListener(J)}};return H}function k4(Z){var{ExecutionEnvironment:J,addCSS:X,appendImportantToEachValue:Y,config:G,cssRuleSetToString:W,getComponentField:H,getGlobalState:Q,hash:K,isNestedStyle:U,mergeStyles:$,props:L,setState:z,style:B}=Z,M=vM(B),F=yM({addCSS:X,appendImportantToEachValue:Y,cssRuleSetToString:W,hash:K,isNestedStyle:U,style:B,userAgent:G.userAgent}),D=F?{className:F+(L.className?" "+L.className:"")}:null,q=G.matchMedia||hM(J);if(!q)return{props:D,style:M};var P=kM({},H("_radiumMediaQueryListenersByQuery")),O=Q("mediaQueryListsByQuery")||{};return Object.keys(B).filter(function(w){return w.indexOf("@media")===0}).map(function(w){var E=T3(B[w],U);if(!Object.keys(E).length)return;var I=mM({listener:function(){return z(w,I.matches,"_all")},listenersByQuery:P,matchMedia:q,mediaQueryListsByQuery:O,query:w});if(I.matches)M=$([M,E])}),{componentFields:{_radiumMediaQueryListenersByQuery:P},globalState:{mediaQueryListsByQuery:O},props:D,style:M}}function g4(Z){var{addCSS:J,appendImportantToEachValue:X,config:Y,cssRuleSetToString:G,hash:W,props:H,style:Q}=Z,K=H.className,U=Object.keys(Q).reduce(function($,L){var z=Q[L];if(L===":visited"){z=X(z);var B=G("",z,Y.userAgent),M="rad-"+W(B),F="."+M+":visited"+B;J(F),K=(K?K+" ":"")+M}else $[L]=z;return $},{});return{props:K===H.className?null:{className:K},style:U}}var r1={checkProps:D3,keyframes:C4,mergeStyleArray:q3,prefix:E4,removeNestedStyles:j4,resolveInteractionStyles:O3,resolveMediaQueries:k4,visited:g4};var S3=r(i7(),1);import h0 from"react";function fM(Z,J){if(!(Z instanceof J))throw TypeError("Cannot call a class as a function")}function P3(Z,J){for(var X=0;X<J.length;X++){var Y=J[X];if(Y.enumerable=Y.enumerable||!1,Y.configurable=!0,"value"in Y)Y.writable=!0;Object.defineProperty(Z,Y.key,Y)}}function uM(Z,J,X){if(J)P3(Z.prototype,J);if(X)P3(Z,X);return Z}var w3=function(){function Z(J){fM(this,Z),this._userAgent=void 0,this._listeners=void 0,this._cssSet=void 0,this._userAgent=J,this._listeners=[],this._cssSet={}}return uM(Z,[{key:"subscribe",value:function(X){var Y=this;if(this._listeners.indexOf(X)===-1)this._listeners.push(X);return{remove:function(){var W=Y._listeners.indexOf(X);if(W>-1)Y._listeners.splice(W,1)}}}},{key:"addCSS",value:function(X){var Y=this;if(!this._cssSet[X])this._cssSet[X]=!0,this._emitChange();return{remove:function(){delete Y._cssSet[X],Y._emitChange()}}}},{key:"getCSS",value:function(){return Object.keys(this._cssSet).join(`
|
|
17
|
+
`)}},{key:"_emitChange",value:function(){this._listeners.forEach(function(X){return X()})}}]),Z}();function C5(Z){for(var J=1;J<arguments.length;J++){var X=arguments[J]!=null?arguments[J]:{},Y=Object.keys(X);if(typeof Object.getOwnPropertySymbols==="function")Y=Y.concat(Object.getOwnPropertySymbols(X).filter(function(G){return Object.getOwnPropertyDescriptor(X,G).enumerable}));Y.forEach(function(G){pM(Z,G,X[G])})}return Z}function pM(Z,J,X){if(J in Z)Object.defineProperty(Z,J,{value:X,enumerable:!0,configurable:!0,writable:!0});else Z[J]=X;return Z}function k9(Z){if(typeof Symbol==="function"&&typeof Symbol.iterator==="symbol")k9=function(X){return typeof X};else k9=function(X){return X&&typeof Symbol==="function"&&X.constructor===Symbol&&X!==Symbol.prototype?"symbol":typeof X};return k9(Z)}var C3={plugins:[r1.mergeStyleArray,r1.checkProps,r1.resolveMediaQueries,r1.resolveInteractionStyles,r1.keyframes,r1.visited,r1.removeNestedStyles,r1.prefix,r1.checkProps]},_3={},lM=!1,W5=null,dM=function(J){return J.type&&!J.type._isRadiumEnhanced},cM=function(J){var{children:X,component:Y,config:G,existingKeyMap:W,extraStateKeyMap:H}=J;if(!X)return X;var Q=k9(X);if(Q==="string"||Q==="number")return X;if(Q==="function")return function(){var z=X.apply(this,arguments);if(h0.isValidElement(z)){var B=G5(z);delete H[B];var M=W5(Y,z,G,W,!0,H),F=M.element;return F}return z};if(h0.Children.count(X)===1&&X.type){var K=h0.Children.only(X),U=G5(K);delete H[U];var $=W5(Y,K,G,W,!0,H),L=$.element;return L}return h0.Children.map(X,function(z){if(h0.isValidElement(z)){var B=G5(z);delete H[B];var M=W5(Y,z,G,W,!0,H),F=M.element;return F}return z})},iM=function(J){var{component:X,config:Y,existingKeyMap:G,props:W,extraStateKeyMap:H}=J,Q=W;return Object.keys(W).forEach(function(K){if(K==="children")return;var U=W[K];if(h0.isValidElement(U)){var $=G5(U);delete H[$],Q=C5({},Q);var L=W5(X,U,Y,G,!0,H),z=L.element;Q[K]=z}}),Q},nM=function(J){var{componentName:X,existingKeyMap:Y,renderedElement:G}=J,W=G5(G),H=S9(W),Q=!1,K=function(){if(Q)return H;if(Q=!0,Y[H]){var $;if(typeof G.type==="string")$=G.type;else if(G.type.constructor)$=G.type.constructor.displayName||G.type.constructor.name;throw Error("Radium requires each element with interactive styles to have a unique key, set using either the ref or key prop. "+(W?'Key "'+W+'" is a duplicate.':"Multiple elements have no key specified.")+' Component: "'+X+'". '+($?'Element: "'+$+'".':""))}return Y[H]=!0,H};return K},aM=function(J,X,Y,G){if(!J._radiumIsMounted)return;var W=B6(J),H={_radiumStyleState:C5({},W)};H._radiumStyleState[X]=C5({},H._radiumStyleState[X]),H._radiumStyleState[X][Y]=G,J._lastRadiumState=H._radiumStyleState,J.setState(H)},rM=function(J){var{component:X,config:Y,existingKeyMap:G,props:W,renderedElement:H}=J;if(!h0.isValidElement(H)||typeof H.type!=="string"||!W.style)return W;var Q=W,K=Y.plugins||C3.plugins,U=X.constructor.displayName||X.constructor.name,$=nM({renderedElement:H,existingKeyMap:G,componentName:U}),L=function(P){return X[P]},z=function(P){return _3[P]},B=function(P,O){return C9(X.state,O||$(),P)},M=function(P,O,w){return aM(X,w||$(),P,O)},F=function(P){var O=X._radiumStyleKeeper;if(!O){if(lM)return{remove:function(){}};throw Error("To use plugins requiring `addCSS` (e.g. keyframes, media queries), please wrap your application in the StyleRoot component. Component name: `"+U+"`.")}return O.addCSS(P)},D=W.style;if(K.forEach(function(q){var P=q({ExecutionEnvironment:S3.default,addCSS:F,appendImportantToEachValue:x7,componentName:U,config:Y,cssRuleSetToString:g0,getComponentField:L,getGlobalState:z,getState:B,hash:z6,mergeStyles:x9,props:Q,setState:M,isNestedStyle:j9,style:D})||{};D=P.style||D,Q=P.props&&Object.keys(P.props).length?C5({},Q,P.props):Q;var O=P.componentFields||{};Object.keys(O).forEach(function(E){X[E]=O[E]});var w=P.globalState||{};Object.keys(w).forEach(function(E){_3[E]=w[E]})}),D!==W.style)Q=C5({},Q,{style:D});return Q},sM=function(J,X,Y){if(typeof J.type==="string")X=C5({},X,{"data-radium":!0});return h0.cloneElement(J,X,Y)};W5=function(J,X){var Y=arguments.length>2&&arguments[2]!==void 0?arguments[2]:C3,G=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},W=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!1,H=arguments.length>5?arguments[5]:void 0;if(!H){var Q=B6(J);H=Object.keys(Q).reduce(function(B,M){if(M!=="main")B[M]=!0;return B},{})}if(Array.isArray(X)&&!X.props){var K=X.map(function(B){if(H){var M=G5(B);delete H[M]}return W5(J,B,Y,G,W,H).element});return{extraStateKeyMap:H,element:K}}if(!X||X.props&&X.props["data-radium"]||W&&!dM(X))return{extraStateKeyMap:H,element:X};var U=X.props.children,$=cM({children:U,component:J,config:Y,existingKeyMap:G,extraStateKeyMap:H}),L=iM({component:J,config:Y,existingKeyMap:G,extraStateKeyMap:H,props:X.props});if(L=rM({component:J,config:Y,existingKeyMap:G,props:L,renderedElement:X}),$===U&&L===X.props)return{extraStateKeyMap:H,element:X};var z=sM(X,L!==X.props?L:{},$);return{extraStateKeyMap:H,element:z}};var E3=W5;var x3=r(j7(),1);import g9,{useContext as j3}from"react";function h4(){return h4=Object.assign||function(Z){for(var J=1;J<arguments.length;J++){var X=arguments[J];for(var Y in X)if(Object.prototype.hasOwnProperty.call(X,Y))Z[Y]=X[Y]}return Z},h4.apply(this,arguments)}var M6=g9.createContext(void 0),E5=g9.createContext(void 0);function j5(Z){var J=g9.forwardRef(function(X,Y){var G=j3(E5),W=j3(M6);return g9.createElement(Z,h4({ref:Y},X,{radiumConfigContext:G,styleKeeperContext:W}))});return J.displayName="withRadiumContexts(".concat(Z.displayName||Z.name||"Component",")"),x3.default(J,Z)}function H5(Z){if(typeof Symbol==="function"&&typeof Symbol.iterator==="symbol")H5=function(X){return typeof X};else H5=function(X){return X&&typeof Symbol==="function"&&X.constructor===Symbol&&X!==Symbol.prototype?"symbol":typeof X};return H5(Z)}function y3(Z,J){if(!(Z instanceof J))throw TypeError("Cannot call a class as a function")}function b3(Z,J){for(var X=0;X<J.length;X++){var Y=J[X];if(Y.enumerable=Y.enumerable||!1,Y.configurable=!0,"value"in Y)Y.writable=!0;Object.defineProperty(Z,Y.key,Y)}}function oM(Z,J,X){if(J)b3(Z.prototype,J);if(X)b3(Z,X);return Z}function m3(Z,J){if(J&&(H5(J)==="object"||typeof J==="function"))return J;return f3(Z)}function f3(Z){if(Z===void 0)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return Z}function v0(Z,J,X){if(typeof Reflect<"u"&&Reflect.get)v0=Reflect.get;else v0=function(G,W,H){var Q=tM(G,W);if(!Q)return;var K=Object.getOwnPropertyDescriptor(Q,W);if(K.get)return K.get.call(H);return K.value};return v0(Z,J,X||Z)}function tM(Z,J){while(!Object.prototype.hasOwnProperty.call(Z,J))if(Z=N0(Z),Z===null)break;return Z}function N0(Z){return N0=Object.setPrototypeOf?Object.getPrototypeOf:function(X){return X.__proto__||Object.getPrototypeOf(X)},N0(Z)}function u3(Z,J){if(typeof J!=="function"&&J!==null)throw TypeError("Super expression must either be null or a function");if(Z.prototype=Object.create(J&&J.prototype,{constructor:{value:Z,writable:!0,configurable:!0}}),J)v4(Z,J)}function v4(Z,J){return v4=Object.setPrototypeOf||function(Y,G){return Y.__proto__=G,Y},v4(Z,J)}function eM(Z,J){return XF(Z)||JF(Z,J)||ZF()}function ZF(){throw TypeError("Invalid attempt to destructure non-iterable instance")}function JF(Z,J){var X=[],Y=!0,G=!1,W=void 0;try{for(var H=Z[Symbol.iterator](),Q;!(Y=(Q=H.next()).done);Y=!0)if(X.push(Q.value),J&&X.length===J)break}catch(K){G=!0,W=K}finally{try{if(!Y&&H.return!=null)H.return()}finally{if(G)throw W}}return X}function XF(Z){if(Array.isArray(Z))return Z}function y4(Z){for(var J=1;J<arguments.length;J++){var X=arguments[J]!=null?arguments[J]:{},Y=Object.keys(X);if(typeof Object.getOwnPropertySymbols==="function")Y=Y.concat(Object.getOwnPropertySymbols(X).filter(function(G){return Object.getOwnPropertyDescriptor(X,G).enumerable}));Y.forEach(function(G){YF(Z,G,X[G])})}return Z}function YF(Z,J,X){if(J in Z)Object.defineProperty(Z,J,{value:X,enumerable:!0,configurable:!0,writable:!0});else Z[J]=X;return Z}function p3(Z,J){if(Z==null)return{};var X=GF(Z,J),Y,G;if(Object.getOwnPropertySymbols){var W=Object.getOwnPropertySymbols(Z);for(G=0;G<W.length;G++){if(Y=W[G],J.indexOf(Y)>=0)continue;if(!Object.prototype.propertyIsEnumerable.call(Z,Y))continue;X[Y]=Z[Y]}}return X}function GF(Z,J){if(Z==null)return{};var X={},Y=Object.keys(Z),G,W;for(W=0;W<Y.length;W++){if(G=Y[W],J.indexOf(G)>=0)continue;X[G]=Z[G]}return X}function WF(Z){var J=HF(Z,"string");return H5(J)==="symbol"?J:String(J)}function HF(Z,J){if(H5(Z)!=="object"||Z===null)return Z;var X=Z[Symbol.toPrimitive];if(X!==void 0){var Y=X.call(Z,J||"default");if(H5(Y)!=="object")return Y;throw TypeError("@@toPrimitive must return a primitive value.")}return(J==="string"?String:Number)(Z)}var $F=["arguments","callee","caller","length","name","prototype","type"],v9,c3;function LF(Z,J){Object.getOwnPropertyNames(Z).forEach(function(X){if($F.indexOf(X)<0&&!J.hasOwnProperty(X)){var Y=Object.getOwnPropertyDescriptor(Z,X);Y&&Object.defineProperty(J,X,Y)}})}function BF(Z){var J=Z.prototype||{};return!Z.isReactComponent&&!J.isReactComponent&&!Z.render&&!J.render}function zF(Z){return typeof Z==="function"&&/^\s*class\s+/.test(Z.toString())}function MF(Z,J){c3.forEach(function(X){var Y=Object.getOwnPropertyDescriptor(Z,X),G=(Y||{}).value;if(!G)return;var W=Object.getOwnPropertyDescriptor(v9,X),H=(W||{}).value,Q=J.prototype[X];if(!Q&&G!==H)Y&&Object.defineProperty(J.prototype,X,Y),delete Z[X]})}function i3(Z){if(Z._extraRadiumStateKeys&&Z._extraRadiumStateKeys.length>0){var J=Z._extraRadiumStateKeys.reduce(function(X,Y){var G=X[Y],W=p3(X,[Y].map(WF));return W},B6(Z));Z._lastRadiumState=J,Z.setState({_radiumStyleState:J})}}function n3(Z){var{_radiumMouseUpListener:J,_radiumMediaQueryListenersByQuery:X}=Z;if(Z._radiumIsMounted=!1,J)J.remove();if(X)Object.keys(X).forEach(function(Y){X[Y].remove()},Z)}function a3(Z,J,X){var Y=Z||J||X;if(X&&Y!==X)Y=y4({},X,Y);return Y}function r3(Z,J,X,Y){var G=E3(Z,J,X),W=G.extraStateKeyMap,H=G.element;if(Z._extraRadiumStateKeys=Object.keys(W),Y)return l3.createElement(E5.Provider,{value:Y},H);return H}function h3(Z,J){var X=l3.forwardRef(function(Y,G){var W=Y.radiumConfig,H=p3(Y,["radiumConfig"]),Q=k3(E5),K=k3(M6),U=QF({_radiumStyleState:{}}),$=eM(U,2),L=$[0],z=$[1],B=KF({state:L,setState:z,_radiumMediaQueryListenersByQuery:void 0,_radiumMouseUpListener:void 0,_radiumIsMounted:!0,_lastRadiumState:void 0,_extraRadiumStateKeys:void 0,_radiumStyleKeeper:K}).current;B.state=L,g3(function(){return function(){n3(B)}},[B]);var M=B._extraRadiumStateKeys&&B._extraRadiumStateKeys.length>0;g3(function(){i3(B)},[M,B]);var F=Z(H,G),D=a3(W,Q,J);return r3(B,F,D,W)});return X._isRadiumEnhanced=!0,X.defaultProps=Z.defaultProps,d3.default(X,Z)}function FF(Z,J,X){var Y=function(G){u3(W,G);function W(){var H;y3(this,W),H=m3(this,N0(W).apply(this,arguments)),H.state=H.state||{},H._radiumStyleKeeper=H.props.styleKeeperContext,H._radiumMediaQueryListenersByQuery=H._radiumMediaQueryListenersByQuery,H._radiumMouseUpListener=H._radiumMouseUpListener,H._radiumIsMounted=!0,H._lastRadiumState=void 0,H._extraRadiumStateKeys=void 0,H.state._radiumStyleState={};var Q=f3(H);return MF(Q,J),H}return oM(W,[{key:"componentDidUpdate",value:function(Q,K,U){if(v0(N0(W.prototype),"componentDidUpdate",this))v0(N0(W.prototype),"componentDidUpdate",this).call(this,Q,K,U);i3(this)}},{key:"componentWillUnmount",value:function(){if(v0(N0(W.prototype),"componentWillUnmount",this))v0(N0(W.prototype),"componentWillUnmount",this).call(this);n3(this)}},{key:"render",value:function(){var Q=v0(N0(W.prototype),"render",this).call(this),K=a3(this.props.radiumConfig,this.props.radiumConfigContext,X);return r3(this,Q,K,this.props.radiumConfig)}}]),W}(J);if(Y._isRadiumEnhanced=!0,v9=Y.prototype,c3=Object.getOwnPropertyNames(v9).filter(function(G){return G!=="constructor"&&typeof v9[G]==="function"}),LF(Z,Y),Y.propTypes&&Y.propTypes.style)Y.propTypes=y4({},Y.propTypes,{style:h9.default.oneOfType([h9.default.array,h9.default.object])});return Y.displayName=Z.displayName||Z.name||"Component",j5(Y)}function NF(Z){return Z=function(J){function X(){var Y=Reflect.construct(J,arguments,this.constructor);return Y}return Reflect.setPrototypeOf(X.prototype,J.prototype),Reflect.setPrototypeOf(X,J),X}(Z),Z}var v3=UF(function(){return null}).$$typeof;function x5(Z){var J=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(v3&&Z.$$typeof===v3)return h3(Z.render,J);if(typeof Z!=="function")return VF(J,Z);var X=Z;if(BF(X))return h3(X,J);var Y=X;if(zF(Y))Y=NF(Y);if(Y===X)Y=function(G){u3(W,G);function W(){return y3(this,W),m3(this,N0(W).apply(this,arguments))}return W}(Y);return FF(X,Y,J)}function VF(Z,J){var X=y4({},Z,J);return function(Y){return x5(Y,X)}}var y9=r(S7(),1);import OF,{PureComponent as TF}from"react";function b5(Z){if(typeof Symbol==="function"&&typeof Symbol.iterator==="symbol")b5=function(X){return typeof X};else b5=function(X){return X&&typeof Symbol==="function"&&X.constructor===Symbol&&X!==Symbol.prototype?"symbol":typeof X};return b5(Z)}function AF(Z,J){if(!(Z instanceof J))throw TypeError("Cannot call a class as a function")}function s3(Z,J){for(var X=0;X<J.length;X++){var Y=J[X];if(Y.enumerable=Y.enumerable||!1,Y.configurable=!0,"value"in Y)Y.writable=!0;Object.defineProperty(Z,Y.key,Y)}}function DF(Z,J,X){if(J)s3(Z.prototype,J);if(X)s3(Z,X);return Z}function qF(Z,J){if(J&&(b5(J)==="object"||typeof J==="function"))return J;return RF(Z)}function RF(Z){if(Z===void 0)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return Z}function m4(Z){return m4=Object.setPrototypeOf?Object.getPrototypeOf:function(X){return X.__proto__||Object.getPrototypeOf(X)},m4(Z)}function IF(Z,J){if(typeof J!=="function"&&J!==null)throw TypeError("Super expression must either be null or a function");if(Z.prototype=Object.create(J&&J.prototype,{constructor:{value:Z,writable:!0,configurable:!0}}),J)f4(Z,J)}function f4(Z,J){return f4=Object.setPrototypeOf||function(Y,G){return Y.__proto__=G,Y},f4(Z,J)}var u4=function(Z){IF(J,Z);function J(){return AF(this,J),qF(this,m4(J).apply(this,arguments))}return DF(J,[{key:"_buildStyles",value:function(Y){var G=this,W=this.props.radiumConfig&&this.props.radiumConfig.userAgent||this.props.radiumConfigContext&&this.props.radiumConfigContext.userAgent,H=this.props.scopeSelector,Q=Object.keys(Y).reduce(function(U,$){if(b5(Y[$])!=="object")U[$]=Y[$];return U},{}),K=Object.keys(Q).length?g0(H||"",Q,W):"";return K+Object.keys(Y).reduce(function(U,$){var L=Y[$];if($==="mediaQueries")U+=G._buildMediaQueryString(L);else if(b5(Y[$])==="object"){var z=H?$.split(",").map(function(B){return H+" "+B.trim()}).join(","):$;U+=g0(z,L,W)}return U},"")}},{key:"_buildMediaQueryString",value:function(Y){var G=this,W="";return Object.keys(Y).forEach(function(H){W+="@media "+H+"{"+G._buildStyles(Y[H])+"}"}),W}},{key:"render",value:function(){if(!this.props.rules)return null;var Y=this._buildStyles(this.props.rules);return OF.createElement("style",{dangerouslySetInnerHTML:{__html:Y}})}}]),J}(TF);u4.propTypes={radiumConfig:y9.default.object,rules:y9.default.object,scopeSelector:y9.default.string};u4.defaultProps={scopeSelector:""};var o3=j5(u4);import f9,{useContext as gF,useRef as hF}from"react";import EF,{Component as jF}from"react";function m9(Z){if(typeof Symbol==="function"&&typeof Symbol.iterator==="symbol")m9=function(X){return typeof X};else m9=function(X){return X&&typeof Symbol==="function"&&X.constructor===Symbol&&X!==Symbol.prototype?"symbol":typeof X};return m9(Z)}function PF(Z,J){if(!(Z instanceof J))throw TypeError("Cannot call a class as a function")}function t3(Z,J){for(var X=0;X<J.length;X++){var Y=J[X];if(Y.enumerable=Y.enumerable||!1,Y.configurable=!0,"value"in Y)Y.writable=!0;Object.defineProperty(Z,Y.key,Y)}}function wF(Z,J,X){if(J)t3(Z.prototype,J);if(X)t3(Z,X);return Z}function _F(Z,J){if(J&&(m9(J)==="object"||typeof J==="function"))return J;return SF(Z)}function SF(Z){if(Z===void 0)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return Z}function p4(Z){return p4=Object.setPrototypeOf?Object.getPrototypeOf:function(X){return X.__proto__||Object.getPrototypeOf(X)},p4(Z)}function CF(Z,J){if(typeof J!=="function"&&J!==null)throw TypeError("Super expression must either be null or a function");if(Z.prototype=Object.create(J&&J.prototype,{constructor:{value:Z,writable:!0,configurable:!0}}),J)l4(Z,J)}function l4(Z,J){return l4=Object.setPrototypeOf||function(Y,G){return Y.__proto__=G,Y},l4(Z,J)}var xF=function(Z){CF(J,Z);function J(){var X;if(PF(this,J),X=_F(this,p4(J).apply(this,arguments)),X.styleKeeper=void 0,X._subscription=void 0,X._root=void 0,X._css=void 0,X._onChange=function(){var Y=X.styleKeeper.getCSS();if(Y!==X._css){if(X._root)X._root.innerHTML=Y;else throw Error("No root style object found, even after StyleSheet mount.");X._css=Y}},!X.props.styleKeeperContext)throw Error("StyleRoot is required to use StyleSheet");return X.styleKeeper=X.props.styleKeeperContext,X._css=X.styleKeeper.getCSS(),X}return wF(J,[{key:"componentDidMount",value:function(){this._subscription=this.styleKeeper.subscribe(this._onChange),this._onChange()}},{key:"shouldComponentUpdate",value:function(){return!1}},{key:"componentWillUnmount",value:function(){if(this._subscription)this._subscription.remove()}},{key:"render",value:function(){var Y=this;return EF.createElement("style",{dangerouslySetInnerHTML:{__html:this._css},ref:function(W){Y._root=W}})}}]),J}(jF),e3=j5(xF);function bF(Z,J){if(Z==null)return{};var X=kF(Z,J),Y,G;if(Object.getOwnPropertySymbols){var W=Object.getOwnPropertySymbols(Z);for(G=0;G<W.length;G++){if(Y=W[G],J.indexOf(Y)>=0)continue;if(!Object.prototype.propertyIsEnumerable.call(Z,Y))continue;X[Y]=Z[Y]}}return X}function kF(Z,J){if(Z==null)return{};var X={},Y=Object.keys(Z),G,W;for(W=0;W<Y.length;W++){if(G=Y[W],J.indexOf(G)>=0)continue;X[G]=Z[G]}return X}function vF(Z,J){var X=Z&&Z.userAgent||J&&J.userAgent;return new w3(X)}var yF=x5(function(Z){var J=Z.children,X=bF(Z,["children"]);return f9.createElement("div",X,J,f9.createElement(e3,null))}),mF=function(J){var X=J.radiumConfig,Y=gF(E5),G=hF(vF(X,Y));return f9.createElement(M6.Provider,{value:G.current},f9.createElement(yF,J))},V0=mF;function d4(Z,J){return{__radiumKeyframes:!0,__process:function(Y){var G=A3(Y),W=Object.keys(Z).map(function(K){return g0(K,Z[K],Y)}).join(`
|
|
18
|
+
`),H=(J?J+"-":"")+"radium-animation-"+z6(W),Q="@"+G+" "+H+` {
|
|
19
|
+
`+W+`
|
|
20
|
+
}
|
|
21
|
+
`;return{css:Q,animationName:H}}}}function k5(Z){return x5(Z)}k5.Plugins=r1;k5.Style=o3;k5.StyleRoot=V0;k5.getState=C9;k5.keyframes=d4;var u9=k5;function c4(Z){return{all:Z=Z||new Map,on:function(J,X){var Y=Z.get(J);Y?Y.push(X):Z.set(J,[X])},off:function(J,X){var Y=Z.get(J);Y&&(X?Y.splice(Y.indexOf(X)>>>0,1):Z.set(J,[]))},emit:function(J,X){var Y=Z.get(J);Y&&Y.slice().map(function(G){G(X)}),(Y=Z.get("*"))&&Y.slice().map(function(G){G(J,X)})}}}import{createContext as fF}from"react";var _0=c4(),uF=fF(_0),s1=uF;var Q0=Object.create(null);Q0.open="0";Q0.close="1";Q0.ping="2";Q0.pong="3";Q0.message="4";Q0.upgrade="5";Q0.noop="6";var F6=Object.create(null);Object.keys(Q0).forEach((Z)=>{F6[Q0[Z]]=Z});var N6={type:"error",data:"parser error"};var XW=typeof Blob==="function"||typeof Blob<"u"&&Object.prototype.toString.call(Blob)==="[object BlobConstructor]",YW=typeof ArrayBuffer==="function",GW=(Z)=>{return typeof ArrayBuffer.isView==="function"?ArrayBuffer.isView(Z):Z&&Z.buffer instanceof ArrayBuffer},V6=({type:Z,data:J},X,Y)=>{if(XW&&J instanceof Blob)if(X)return Y(J);else return ZW(J,Y);else if(YW&&(J instanceof ArrayBuffer||GW(J)))if(X)return Y(J);else return ZW(new Blob([J]),Y);return Y(Q0[Z]+(J||""))},ZW=(Z,J)=>{let X=new FileReader;return X.onload=function(){let Y=X.result.split(",")[1];J("b"+(Y||""))},X.readAsDataURL(Z)};function JW(Z){if(Z instanceof Uint8Array)return Z;else if(Z instanceof ArrayBuffer)return new Uint8Array(Z);else return new Uint8Array(Z.buffer,Z.byteOffset,Z.byteLength)}var i4;function WW(Z,J){if(XW&&Z.data instanceof Blob)return Z.data.arrayBuffer().then(JW).then(J);else if(YW&&(Z.data instanceof ArrayBuffer||GW(Z.data)))return J(JW(Z.data));V6(Z,!1,(X)=>{if(!i4)i4=new TextEncoder;J(i4.encode(X))})}var A6=typeof Uint8Array>"u"?[]:new Uint8Array(256);for(let Z=0;Z<64;Z++)A6["ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charCodeAt(Z)]=Z;var HW=(Z)=>{let J=Z.length*0.75,X=Z.length,Y,G=0,W,H,Q,K;if(Z[Z.length-1]==="="){if(J--,Z[Z.length-2]==="=")J--}let U=new ArrayBuffer(J),$=new Uint8Array(U);for(Y=0;Y<X;Y+=4)W=A6[Z.charCodeAt(Y)],H=A6[Z.charCodeAt(Y+1)],Q=A6[Z.charCodeAt(Y+2)],K=A6[Z.charCodeAt(Y+3)],$[G++]=W<<2|H>>4,$[G++]=(H&15)<<4|Q>>2,$[G++]=(Q&3)<<6|K&63;return U};var pF=typeof ArrayBuffer==="function",D6=(Z,J)=>{if(typeof Z!=="string")return{type:"message",data:QW(Z,J)};let X=Z.charAt(0);if(X==="b")return{type:"message",data:lF(Z.substring(1),J)};if(!F6[X])return N6;return Z.length>1?{type:F6[X],data:Z.substring(1)}:{type:F6[X]}},lF=(Z,J)=>{if(pF){let X=HW(Z);return QW(X,J)}else return{base64:!0,data:Z}},QW=(Z,J)=>{switch(J){case"blob":if(Z instanceof Blob)return Z;else return new Blob([Z]);case"arraybuffer":default:if(Z instanceof ArrayBuffer)return Z;else return Z.buffer}};var KW=String.fromCharCode(30),UW=(Z,J)=>{let X=Z.length,Y=Array(X),G=0;Z.forEach((W,H)=>{V6(W,!1,(Q)=>{if(Y[H]=Q,++G===X)J(Y.join(KW))})})},$W=(Z,J)=>{let X=Z.split(KW),Y=[];for(let G=0;G<X.length;G++){let W=D6(X[G],J);if(Y.push(W),W.type==="error")break}return Y};function LW(){return new TransformStream({transform(Z,J){WW(Z,(X)=>{let Y=X.length,G;if(Y<126)G=new Uint8Array(1),new DataView(G.buffer).setUint8(0,Y);else if(Y<65536){G=new Uint8Array(3);let W=new DataView(G.buffer);W.setUint8(0,126),W.setUint16(1,Y)}else{G=new Uint8Array(9);let W=new DataView(G.buffer);W.setUint8(0,127),W.setBigUint64(1,BigInt(Y))}if(Z.data&&typeof Z.data!=="string")G[0]|=128;J.enqueue(G),J.enqueue(X)})}})}var n4;function p9(Z){return Z.reduce((J,X)=>J+X.length,0)}function l9(Z,J){if(Z[0].length===J)return Z.shift();let X=new Uint8Array(J),Y=0;for(let G=0;G<J;G++)if(X[G]=Z[0][Y++],Y===Z[0].length)Z.shift(),Y=0;if(Z.length&&Y<Z[0].length)Z[0]=Z[0].slice(Y);return X}function BW(Z,J){if(!n4)n4=new TextDecoder;let X=[],Y=0,G=-1,W=!1;return new TransformStream({transform(H,Q){X.push(H);while(!0){if(Y===0){if(p9(X)<1)break;let K=l9(X,1);if(W=(K[0]&128)===128,G=K[0]&127,G<126)Y=3;else if(G===126)Y=1;else Y=2}else if(Y===1){if(p9(X)<2)break;let K=l9(X,2);G=new DataView(K.buffer,K.byteOffset,K.length).getUint16(0),Y=3}else if(Y===2){if(p9(X)<8)break;let K=l9(X,8),U=new DataView(K.buffer,K.byteOffset,K.length),$=U.getUint32(0);if($>Math.pow(2,21)-1){Q.enqueue(N6);break}G=$*Math.pow(2,32)+U.getUint32(4),Y=3}else{if(p9(X)<G)break;let K=l9(X,G);Q.enqueue(D6(W?K:n4.decode(K),J)),Y=0}if(G===0||G>Z){Q.enqueue(N6);break}}}})}var a4=4;function X1(Z){if(Z)return dF(Z)}function dF(Z){for(var J in X1.prototype)Z[J]=X1.prototype[J];return Z}X1.prototype.on=X1.prototype.addEventListener=function(Z,J){return this._callbacks=this._callbacks||{},(this._callbacks["$"+Z]=this._callbacks["$"+Z]||[]).push(J),this};X1.prototype.once=function(Z,J){function X(){this.off(Z,X),J.apply(this,arguments)}return X.fn=J,this.on(Z,X),this};X1.prototype.off=X1.prototype.removeListener=X1.prototype.removeAllListeners=X1.prototype.removeEventListener=function(Z,J){if(this._callbacks=this._callbacks||{},arguments.length==0)return this._callbacks={},this;var X=this._callbacks["$"+Z];if(!X)return this;if(arguments.length==1)return delete this._callbacks["$"+Z],this;var Y;for(var G=0;G<X.length;G++)if(Y=X[G],Y===J||Y.fn===J){X.splice(G,1);break}if(X.length===0)delete this._callbacks["$"+Z];return this};X1.prototype.emit=function(Z){this._callbacks=this._callbacks||{};var J=Array(arguments.length-1),X=this._callbacks["$"+Z];for(var Y=1;Y<arguments.length;Y++)J[Y-1]=arguments[Y];if(X){X=X.slice(0);for(var Y=0,G=X.length;Y<G;++Y)X[Y].apply(this,J)}return this};X1.prototype.emitReserved=X1.prototype.emit;X1.prototype.listeners=function(Z){return this._callbacks=this._callbacks||{},this._callbacks["$"+Z]||[]};X1.prototype.hasListeners=function(Z){return!!this.listeners(Z).length};var S0=(()=>{if(typeof Promise==="function"&&typeof Promise.resolve==="function")return(J)=>Promise.resolve().then(J);else return(J,X)=>X(J,0)})(),E1=(()=>{if(typeof self<"u")return self;else if(typeof window<"u")return window;else return Function("return this")()})(),zW="arraybuffer";function MW(){}function d9(Z,...J){return J.reduce((X,Y)=>{if(Z.hasOwnProperty(Y))X[Y]=Z[Y];return X},{})}var cF=E1.setTimeout,iF=E1.clearTimeout;function C0(Z,J){if(J.useNativeTimers)Z.setTimeoutFn=cF.bind(E1),Z.clearTimeoutFn=iF.bind(E1);else Z.setTimeoutFn=E1.setTimeout.bind(E1),Z.clearTimeoutFn=E1.clearTimeout.bind(E1)}var nF=1.33;function FW(Z){if(typeof Z==="string")return aF(Z);return Math.ceil((Z.byteLength||Z.size)*nF)}function aF(Z){let J=0,X=0;for(let Y=0,G=Z.length;Y<G;Y++)if(J=Z.charCodeAt(Y),J<128)X+=1;else if(J<2048)X+=2;else if(J<55296||J>=57344)X+=3;else Y++,X+=4;return X}function c9(){return Date.now().toString(36).substring(3)+Math.random().toString(36).substring(2,5)}function NW(Z){let J="";for(let X in Z)if(Z.hasOwnProperty(X)){if(J.length)J+="&";J+=encodeURIComponent(X)+"="+encodeURIComponent(Z[X])}return J}function VW(Z){let J={},X=Z.split("&");for(let Y=0,G=X.length;Y<G;Y++){let W=X[Y].split("=");J[decodeURIComponent(W[0])]=decodeURIComponent(W[1])}return J}class r4 extends Error{constructor(Z,J,X){super(Z);this.description=J,this.context=X,this.type="TransportError"}}class y0 extends X1{constructor(Z){super();this.writable=!1,C0(this,Z),this.opts=Z,this.query=Z.query,this.socket=Z.socket,this.supportsBinary=!Z.forceBase64}onError(Z,J,X){return super.emitReserved("error",new r4(Z,J,X)),this}open(){return this.readyState="opening",this.doOpen(),this}close(){if(this.readyState==="opening"||this.readyState==="open")this.doClose(),this.onClose();return this}send(Z){if(this.readyState==="open")this.write(Z)}onOpen(){this.readyState="open",this.writable=!0,super.emitReserved("open")}onData(Z){let J=D6(Z,this.socket.binaryType);this.onPacket(J)}onPacket(Z){super.emitReserved("packet",Z)}onClose(Z){this.readyState="closed",super.emitReserved("close",Z)}pause(Z){}createUri(Z,J={}){return Z+"://"+this._hostname()+this._port()+this.opts.path+this._query(J)}_hostname(){let Z=this.opts.hostname;return Z.indexOf(":")===-1?Z:"["+Z+"]"}_port(){if(this.opts.port&&(this.opts.secure&&Number(this.opts.port)!==443||!this.opts.secure&&Number(this.opts.port)!==80))return":"+this.opts.port;else return""}_query(Z){let J=NW(Z);return J.length?"?"+J:""}}class i9 extends y0{constructor(){super(...arguments);this._polling=!1}get name(){return"polling"}doOpen(){this._poll()}pause(Z){this.readyState="pausing";let J=()=>{this.readyState="paused",Z()};if(this._polling||!this.writable){let X=0;if(this._polling)X++,this.once("pollComplete",function(){--X||J()});if(!this.writable)X++,this.once("drain",function(){--X||J()})}else J()}_poll(){this._polling=!0,this.doPoll(),this.emitReserved("poll")}onData(Z){let J=(X)=>{if(this.readyState==="opening"&&X.type==="open")this.onOpen();if(X.type==="close")return this.onClose({description:"transport closed by the server"}),!1;this.onPacket(X)};if($W(Z,this.socket.binaryType).forEach(J),this.readyState!=="closed"){if(this._polling=!1,this.emitReserved("pollComplete"),this.readyState==="open")this._poll()}}doClose(){let Z=()=>{this.write([{type:"close"}])};if(this.readyState==="open")Z();else this.once("open",Z)}write(Z){this.writable=!1,UW(Z,(J)=>{this.doWrite(J,()=>{this.writable=!0,this.emitReserved("drain")})})}uri(){let Z=this.opts.secure?"https":"http",J=this.query||{};if(this.opts.timestampRequests!==!1)J[this.opts.timestampParam]=c9();if(!this.supportsBinary&&!J.sid)J.b64=1;return this.createUri(Z,J)}}var AW=!1;try{AW=typeof XMLHttpRequest<"u"&&"withCredentials"in new XMLHttpRequest}catch(Z){}var DW=AW;function rF(){}class RW extends i9{constructor(Z){super(Z);if(typeof location<"u"){let J=location.protocol==="https:",X=location.port;if(!X)X=J?"443":"80";this.xd=typeof location<"u"&&Z.hostname!==location.hostname||X!==Z.port}}doWrite(Z,J){let X=this.request({method:"POST",data:Z});X.on("success",J),X.on("error",(Y,G)=>{this.onError("xhr post error",Y,G)})}doPoll(){let Z=this.request();Z.on("data",this.onData.bind(this)),Z.on("error",(J,X)=>{this.onError("xhr poll error",J,X)}),this.pollXhr=Z}}class A0 extends X1{constructor(Z,J,X){super();this.createRequest=Z,C0(this,X),this._opts=X,this._method=X.method||"GET",this._uri=J,this._data=X.data!==void 0?X.data:null,this._create()}_create(){var Z;let J=d9(this._opts,"agent","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","autoUnref");J.xdomain=!!this._opts.xd;let X=this._xhr=this.createRequest(J);try{X.open(this._method,this._uri,!0);try{if(this._opts.extraHeaders){X.setDisableHeaderCheck&&X.setDisableHeaderCheck(!0);for(let Y in this._opts.extraHeaders)if(this._opts.extraHeaders.hasOwnProperty(Y))X.setRequestHeader(Y,this._opts.extraHeaders[Y])}}catch(Y){}if(this._method==="POST")try{X.setRequestHeader("Content-type","text/plain;charset=UTF-8")}catch(Y){}try{X.setRequestHeader("Accept","*/*")}catch(Y){}if((Z=this._opts.cookieJar)===null||Z===void 0||Z.addCookies(X),"withCredentials"in X)X.withCredentials=this._opts.withCredentials;if(this._opts.requestTimeout)X.timeout=this._opts.requestTimeout;X.onreadystatechange=()=>{var Y;if(X.readyState===3)(Y=this._opts.cookieJar)===null||Y===void 0||Y.parseCookies(X.getResponseHeader("set-cookie"));if(X.readyState!==4)return;if(X.status===200||X.status===1223)this._onLoad();else this.setTimeoutFn(()=>{this._onError(typeof X.status==="number"?X.status:0)},0)},X.send(this._data)}catch(Y){this.setTimeoutFn(()=>{this._onError(Y)},0);return}if(typeof document<"u")this._index=A0.requestsCount++,A0.requests[this._index]=this}_onError(Z){this.emitReserved("error",Z,this._xhr),this._cleanup(!0)}_cleanup(Z){if(typeof this._xhr>"u"||this._xhr===null)return;if(this._xhr.onreadystatechange=rF,Z)try{this._xhr.abort()}catch(J){}if(typeof document<"u")delete A0.requests[this._index];this._xhr=null}_onLoad(){let Z=this._xhr.responseText;if(Z!==null)this.emitReserved("data",Z),this.emitReserved("success"),this._cleanup()}abort(){this._cleanup()}}A0.requestsCount=0;A0.requests={};if(typeof document<"u"){if(typeof attachEvent==="function")attachEvent("onunload",qW);else if(typeof addEventListener==="function"){let Z="onpagehide"in E1?"pagehide":"unload";addEventListener(Z,qW,!1)}}function qW(){for(let Z in A0.requests)if(A0.requests.hasOwnProperty(Z))A0.requests[Z].abort()}var sF=function(){let Z=IW({xdomain:!1});return Z&&Z.responseType!==null}();class Q5 extends RW{constructor(Z){super(Z);let J=Z&&Z.forceBase64;this.supportsBinary=sF&&!J}request(Z={}){return Object.assign(Z,{xd:this.xd},this.opts),new A0(IW,this.uri(),Z)}}function IW(Z){let J=Z.xdomain;try{if(typeof XMLHttpRequest<"u"&&(!J||DW))return new XMLHttpRequest}catch(X){}if(!J)try{return new E1[["Active"].concat("Object").join("X")]("Microsoft.XMLHTTP")}catch(X){}}var OW=typeof navigator<"u"&&typeof navigator.product==="string"&&navigator.product.toLowerCase()==="reactnative";class TW extends y0{get name(){return"websocket"}doOpen(){let Z=this.uri(),J=this.opts.protocols,X=OW?{}:d9(this.opts,"agent","perMessageDeflate","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","localAddress","protocolVersion","origin","maxPayload","family","checkServerIdentity");if(this.opts.extraHeaders)X.headers=this.opts.extraHeaders;try{this.ws=this.createSocket(Z,J,X)}catch(Y){return this.emitReserved("error",Y)}this.ws.binaryType=this.socket.binaryType,this.addEventListeners()}addEventListeners(){this.ws.onopen=()=>{if(this.opts.autoUnref)this.ws._socket.unref();this.onOpen()},this.ws.onclose=(Z)=>this.onClose({description:"websocket connection closed",context:Z}),this.ws.onmessage=(Z)=>this.onData(Z.data),this.ws.onerror=(Z)=>this.onError("websocket error",Z)}write(Z){this.writable=!1;for(let J=0;J<Z.length;J++){let X=Z[J],Y=J===Z.length-1;V6(X,this.supportsBinary,(G)=>{try{this.doWrite(X,G)}catch(W){}if(Y)S0(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){if(typeof this.ws<"u")this.ws.onerror=()=>{},this.ws.close(),this.ws=null}uri(){let Z=this.opts.secure?"wss":"ws",J=this.query||{};if(this.opts.timestampRequests)J[this.opts.timestampParam]=c9();if(!this.supportsBinary)J.b64=1;return this.createUri(Z,J)}}var s4=E1.WebSocket||E1.MozWebSocket;class K5 extends TW{createSocket(Z,J,X){return!OW?J?new s4(Z,J):new s4(Z):new s4(Z,J,X)}doWrite(Z,J){this.ws.send(J)}}class q6 extends y0{get name(){return"webtransport"}doOpen(){try{this._transport=new WebTransport(this.createUri("https"),this.opts.transportOptions[this.name])}catch(Z){return this.emitReserved("error",Z)}this._transport.closed.then(()=>{this.onClose()}).catch((Z)=>{this.onError("webtransport error",Z)}),this._transport.ready.then(()=>{this._transport.createBidirectionalStream().then((Z)=>{let J=BW(Number.MAX_SAFE_INTEGER,this.socket.binaryType),X=Z.readable.pipeThrough(J).getReader(),Y=LW();Y.readable.pipeTo(Z.writable),this._writer=Y.writable.getWriter();let G=()=>{X.read().then(({done:H,value:Q})=>{if(H)return;this.onPacket(Q),G()}).catch((H)=>{})};G();let W={type:"open"};if(this.query.sid)W.data=`{"sid":"${this.query.sid}"}`;this._writer.write(W).then(()=>this.onOpen())})})}write(Z){this.writable=!1;for(let J=0;J<Z.length;J++){let X=Z[J],Y=J===Z.length-1;this._writer.write(X).then(()=>{if(Y)S0(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){var Z;(Z=this._transport)===null||Z===void 0||Z.close()}}var o4={websocket:K5,webtransport:q6,polling:Q5};var oF=/^(?:(?![^:@\/?#]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@\/?#]*)(?::([^:@\/?#]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,tF=["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"];function g5(Z){if(Z.length>8000)throw"URI too long";let J=Z,X=Z.indexOf("["),Y=Z.indexOf("]");if(X!=-1&&Y!=-1)Z=Z.substring(0,X)+Z.substring(X,Y).replace(/:/g,";")+Z.substring(Y,Z.length);let G=oF.exec(Z||""),W={},H=14;while(H--)W[tF[H]]=G[H]||"";if(X!=-1&&Y!=-1)W.source=J,W.host=W.host.substring(1,W.host.length-1).replace(/;/g,":"),W.authority=W.authority.replace("[","").replace("]","").replace(/;/g,":"),W.ipv6uri=!0;return W.pathNames=eF(W,W.path),W.queryKey=ZN(W,W.query),W}function eF(Z,J){let X=/\/{2,9}/g,Y=J.replace(X,"/").split("/");if(J.slice(0,1)=="/"||J.length===0)Y.splice(0,1);if(J.slice(-1)=="/")Y.splice(Y.length-1,1);return Y}function ZN(Z,J){let X={};return J.replace(/(?:^|&)([^&=]*)=?([^&]*)/g,function(Y,G,W){if(G)X[G]=W}),X}var t4=typeof addEventListener==="function"&&typeof removeEventListener==="function",n9=[];if(t4)addEventListener("offline",()=>{n9.forEach((Z)=>Z())},!1);class E0 extends X1{constructor(Z,J){super();if(this.binaryType=zW,this.writeBuffer=[],this._prevBufferLen=0,this._pingInterval=-1,this._pingTimeout=-1,this._maxPayload=-1,this._pingTimeoutTime=1/0,Z&&typeof Z==="object")J=Z,Z=null;if(Z){let X=g5(Z);if(J.hostname=X.host,J.secure=X.protocol==="https"||X.protocol==="wss",J.port=X.port,X.query)J.query=X.query}else if(J.host)J.hostname=g5(J.host).host;if(C0(this,J),this.secure=J.secure!=null?J.secure:typeof location<"u"&&location.protocol==="https:",J.hostname&&!J.port)J.port=this.secure?"443":"80";if(this.hostname=J.hostname||(typeof location<"u"?location.hostname:"localhost"),this.port=J.port||(typeof location<"u"&&location.port?location.port:this.secure?"443":"80"),this.transports=[],this._transportsByName={},J.transports.forEach((X)=>{let Y=X.prototype.name;this.transports.push(Y),this._transportsByName[Y]=X}),this.opts=Object.assign({path:"/engine.io",agent:!1,withCredentials:!1,upgrade:!0,timestampParam:"t",rememberUpgrade:!1,addTrailingSlash:!0,rejectUnauthorized:!0,perMessageDeflate:{threshold:1024},transportOptions:{},closeOnBeforeunload:!1},J),this.opts.path=this.opts.path.replace(/\/$/,"")+(this.opts.addTrailingSlash?"/":""),typeof this.opts.query==="string")this.opts.query=VW(this.opts.query);if(t4){if(this.opts.closeOnBeforeunload)this._beforeunloadEventListener=()=>{if(this.transport)this.transport.removeAllListeners(),this.transport.close()},addEventListener("beforeunload",this._beforeunloadEventListener,!1);if(this.hostname!=="localhost")this._offlineEventListener=()=>{this._onClose("transport close",{description:"network connection lost"})},n9.push(this._offlineEventListener)}if(this.opts.withCredentials)this._cookieJar=MW();this._open()}createTransport(Z){let J=Object.assign({},this.opts.query);if(J.EIO=a4,J.transport=Z,this.id)J.sid=this.id;let X=Object.assign({},this.opts,{query:J,socket:this,hostname:this.hostname,secure:this.secure,port:this.port},this.opts.transportOptions[Z]);return new this._transportsByName[Z](X)}_open(){if(this.transports.length===0){this.setTimeoutFn(()=>{this.emitReserved("error","No transports available")},0);return}let Z=this.opts.rememberUpgrade&&E0.priorWebsocketSuccess&&this.transports.indexOf("websocket")!==-1?"websocket":this.transports[0];this.readyState="opening";let J=this.createTransport(Z);J.open(),this.setTransport(J)}setTransport(Z){if(this.transport)this.transport.removeAllListeners();this.transport=Z,Z.on("drain",this._onDrain.bind(this)).on("packet",this._onPacket.bind(this)).on("error",this._onError.bind(this)).on("close",(J)=>this._onClose("transport close",J))}onOpen(){this.readyState="open",E0.priorWebsocketSuccess=this.transport.name==="websocket",this.emitReserved("open"),this.flush()}_onPacket(Z){if(this.readyState==="opening"||this.readyState==="open"||this.readyState==="closing")switch(this.emitReserved("packet",Z),this.emitReserved("heartbeat"),Z.type){case"open":this.onHandshake(JSON.parse(Z.data));break;case"ping":this._sendPacket("pong"),this.emitReserved("ping"),this.emitReserved("pong"),this._resetPingTimeout();break;case"error":let J=Error("server error");J.code=Z.data,this._onError(J);break;case"message":this.emitReserved("data",Z.data),this.emitReserved("message",Z.data);break}}onHandshake(Z){if(this.emitReserved("handshake",Z),this.id=Z.sid,this.transport.query.sid=Z.sid,this._pingInterval=Z.pingInterval,this._pingTimeout=Z.pingTimeout,this._maxPayload=Z.maxPayload,this.onOpen(),this.readyState==="closed")return;this._resetPingTimeout()}_resetPingTimeout(){this.clearTimeoutFn(this._pingTimeoutTimer);let Z=this._pingInterval+this._pingTimeout;if(this._pingTimeoutTime=Date.now()+Z,this._pingTimeoutTimer=this.setTimeoutFn(()=>{this._onClose("ping timeout")},Z),this.opts.autoUnref)this._pingTimeoutTimer.unref()}_onDrain(){if(this.writeBuffer.splice(0,this._prevBufferLen),this._prevBufferLen=0,this.writeBuffer.length===0)this.emitReserved("drain");else this.flush()}flush(){if(this.readyState!=="closed"&&this.transport.writable&&!this.upgrading&&this.writeBuffer.length){let Z=this._getWritablePackets();this.transport.send(Z),this._prevBufferLen=Z.length,this.emitReserved("flush")}}_getWritablePackets(){if(!(this._maxPayload&&this.transport.name==="polling"&&this.writeBuffer.length>1))return this.writeBuffer;let J=1;for(let X=0;X<this.writeBuffer.length;X++){let Y=this.writeBuffer[X].data;if(Y)J+=FW(Y);if(X>0&&J>this._maxPayload)return this.writeBuffer.slice(0,X);J+=2}return this.writeBuffer}_hasPingExpired(){if(!this._pingTimeoutTime)return!0;let Z=Date.now()>this._pingTimeoutTime;if(Z)this._pingTimeoutTime=0,S0(()=>{this._onClose("ping timeout")},this.setTimeoutFn);return Z}write(Z,J,X){return this._sendPacket("message",Z,J,X),this}send(Z,J,X){return this._sendPacket("message",Z,J,X),this}_sendPacket(Z,J,X,Y){if(typeof J==="function")Y=J,J=void 0;if(typeof X==="function")Y=X,X=null;if(this.readyState==="closing"||this.readyState==="closed")return;X=X||{},X.compress=X.compress!==!1;let G={type:Z,data:J,options:X};if(this.emitReserved("packetCreate",G),this.writeBuffer.push(G),Y)this.once("flush",Y);this.flush()}close(){let Z=()=>{this._onClose("forced close"),this.transport.close()},J=()=>{this.off("upgrade",J),this.off("upgradeError",J),Z()},X=()=>{this.once("upgrade",J),this.once("upgradeError",J)};if(this.readyState==="opening"||this.readyState==="open")if(this.readyState="closing",this.writeBuffer.length)this.once("drain",()=>{if(this.upgrading)X();else Z()});else if(this.upgrading)X();else Z();return this}_onError(Z){if(E0.priorWebsocketSuccess=!1,this.opts.tryAllTransports&&this.transports.length>1&&this.readyState==="opening")return this.transports.shift(),this._open();this.emitReserved("error",Z),this._onClose("transport error",Z)}_onClose(Z,J){if(this.readyState==="opening"||this.readyState==="open"||this.readyState==="closing"){if(this.clearTimeoutFn(this._pingTimeoutTimer),this.transport.removeAllListeners("close"),this.transport.close(),this.transport.removeAllListeners(),t4){if(this._beforeunloadEventListener)removeEventListener("beforeunload",this._beforeunloadEventListener,!1);if(this._offlineEventListener){let X=n9.indexOf(this._offlineEventListener);if(X!==-1)n9.splice(X,1)}}this.readyState="closed",this.id=null,this.emitReserved("close",Z,J),this.writeBuffer=[],this._prevBufferLen=0}}}E0.protocol=a4;class e4 extends E0{constructor(){super(...arguments);this._upgrades=[]}onOpen(){if(super.onOpen(),this.readyState==="open"&&this.opts.upgrade)for(let Z=0;Z<this._upgrades.length;Z++)this._probe(this._upgrades[Z])}_probe(Z){let J=this.createTransport(Z),X=!1;E0.priorWebsocketSuccess=!1;let Y=()=>{if(X)return;J.send([{type:"ping",data:"probe"}]),J.once("packet",($)=>{if(X)return;if($.type==="pong"&&$.data==="probe"){if(this.upgrading=!0,this.emitReserved("upgrading",J),!J)return;E0.priorWebsocketSuccess=J.name==="websocket",this.transport.pause(()=>{if(X)return;if(this.readyState==="closed")return;U(),this.setTransport(J),J.send([{type:"upgrade"}]),this.emitReserved("upgrade",J),J=null,this.upgrading=!1,this.flush()})}else{let L=Error("probe error");L.transport=J.name,this.emitReserved("upgradeError",L)}})};function G(){if(X)return;X=!0,U(),J.close(),J=null}let W=($)=>{let L=Error("probe error: "+$);L.transport=J.name,G(),this.emitReserved("upgradeError",L)};function H(){W("transport closed")}function Q(){W("socket closed")}function K($){if(J&&$.name!==J.name)G()}let U=()=>{J.removeListener("open",Y),J.removeListener("error",W),J.removeListener("close",H),this.off("close",Q),this.off("upgrading",K)};if(J.once("open",Y),J.once("error",W),J.once("close",H),this.once("close",Q),this.once("upgrading",K),this._upgrades.indexOf("webtransport")!==-1&&Z!=="webtransport")this.setTimeoutFn(()=>{if(!X)J.open()},200);else J.open()}onHandshake(Z){this._upgrades=this._filterUpgrades(Z.upgrades),super.onHandshake(Z)}_filterUpgrades(Z){let J=[];for(let X=0;X<Z.length;X++)if(~this.transports.indexOf(Z[X]))J.push(Z[X]);return J}}class R6 extends e4{constructor(Z,J={}){let X=typeof Z==="object"?Z:J;if(!X.transports||X.transports&&typeof X.transports[0]==="string")X.transports=(X.transports||["polling","websocket","webtransport"]).map((Y)=>o4[Y]).filter((Y)=>!!Y);super(Z,X)}}var EC=R6.protocol;function PW(Z,J="",X){let Y=Z;if(X=X||typeof location<"u"&&location,Z==null)Z=X.protocol+"//"+X.host;if(typeof Z==="string"){if(Z.charAt(0)==="/")if(Z.charAt(1)==="/")Z=X.protocol+Z;else Z=X.host+Z;if(!/^(https?|wss?):\/\//.test(Z))if(typeof X<"u")Z=X.protocol+"//"+Z;else Z="https://"+Z;Y=g5(Z)}if(!Y.port){if(/^(http|ws)$/.test(Y.protocol))Y.port="80";else if(/^(http|ws)s$/.test(Y.protocol))Y.port="443"}Y.path=Y.path||"/";let W=Y.host.indexOf(":")!==-1?"["+Y.host+"]":Y.host;return Y.id=Y.protocol+"://"+W+":"+Y.port+J,Y.href=Y.protocol+"://"+W+(X&&X.port===Y.port?"":":"+Y.port),Y}var YZ={};U9(YZ,{protocol:()=>EW,isPacketValid:()=>$N,PacketType:()=>d,Encoder:()=>jW,Decoder:()=>XZ});var XN=typeof ArrayBuffer==="function",YN=(Z)=>{return typeof ArrayBuffer.isView==="function"?ArrayBuffer.isView(Z):Z.buffer instanceof ArrayBuffer},wW=Object.prototype.toString,GN=typeof Blob==="function"||typeof Blob<"u"&&wW.call(Blob)==="[object BlobConstructor]",WN=typeof File==="function"||typeof File<"u"&&wW.call(File)==="[object FileConstructor]";function O6(Z){return XN&&(Z instanceof ArrayBuffer||YN(Z))||GN&&Z instanceof Blob||WN&&Z instanceof File}function I6(Z,J){if(!Z||typeof Z!=="object")return!1;if(Array.isArray(Z)){for(let X=0,Y=Z.length;X<Y;X++)if(I6(Z[X]))return!0;return!1}if(O6(Z))return!0;if(Z.toJSON&&typeof Z.toJSON==="function"&&arguments.length===1)return I6(Z.toJSON(),!0);for(let X in Z)if(Object.prototype.hasOwnProperty.call(Z,X)&&I6(Z[X]))return!0;return!1}function _W(Z){let J=[],X=Z.data,Y=Z;return Y.data=ZZ(X,J),Y.attachments=J.length,{packet:Y,buffers:J}}function ZZ(Z,J){if(!Z)return Z;if(O6(Z)){let X={_placeholder:!0,num:J.length};return J.push(Z),X}else if(Array.isArray(Z)){let X=Array(Z.length);for(let Y=0;Y<Z.length;Y++)X[Y]=ZZ(Z[Y],J);return X}else if(typeof Z==="object"&&!(Z instanceof Date)){let X={};for(let Y in Z)if(Object.prototype.hasOwnProperty.call(Z,Y))X[Y]=ZZ(Z[Y],J);return X}return Z}function SW(Z,J){return Z.data=JZ(Z.data,J),delete Z.attachments,Z}function JZ(Z,J){if(!Z)return Z;if(Z&&Z._placeholder===!0)if(typeof Z.num==="number"&&Z.num>=0&&Z.num<J.length)return J[Z.num];else throw Error("illegal attachments");else if(Array.isArray(Z))for(let X=0;X<Z.length;X++)Z[X]=JZ(Z[X],J);else if(typeof Z==="object"){for(let X in Z)if(Object.prototype.hasOwnProperty.call(Z,X))Z[X]=JZ(Z[X],J)}return Z}var CW=["connect","connect_error","disconnect","disconnecting","newListener","removeListener"],EW=5,d;(function(Z){Z[Z.CONNECT=0]="CONNECT",Z[Z.DISCONNECT=1]="DISCONNECT",Z[Z.EVENT=2]="EVENT",Z[Z.ACK=3]="ACK",Z[Z.CONNECT_ERROR=4]="CONNECT_ERROR",Z[Z.BINARY_EVENT=5]="BINARY_EVENT",Z[Z.BINARY_ACK=6]="BINARY_ACK"})(d||(d={}));class jW{constructor(Z){this.replacer=Z}encode(Z){if(Z.type===d.EVENT||Z.type===d.ACK){if(I6(Z))return this.encodeAsBinary({type:Z.type===d.EVENT?d.BINARY_EVENT:d.BINARY_ACK,nsp:Z.nsp,data:Z.data,id:Z.id})}return[this.encodeAsString(Z)]}encodeAsString(Z){let J=""+Z.type;if(Z.type===d.BINARY_EVENT||Z.type===d.BINARY_ACK)J+=Z.attachments+"-";if(Z.nsp&&Z.nsp!=="/")J+=Z.nsp+",";if(Z.id!=null)J+=Z.id;if(Z.data!=null)J+=JSON.stringify(Z.data,this.replacer);return J}encodeAsBinary(Z){let J=_W(Z),X=this.encodeAsString(J.packet),Y=J.buffers;return Y.unshift(X),Y}}class XZ extends X1{constructor(Z){super();this.reviver=Z}add(Z){let J;if(typeof Z==="string"){if(this.reconstructor)throw Error("got plaintext data when reconstructing a packet");J=this.decodeString(Z);let X=J.type===d.BINARY_EVENT;if(X||J.type===d.BINARY_ACK){if(J.type=X?d.EVENT:d.ACK,this.reconstructor=new xW(J),J.attachments===0)super.emitReserved("decoded",J)}else super.emitReserved("decoded",J)}else if(O6(Z)||Z.base64){if(!this.reconstructor)throw Error("got binary data when not reconstructing a packet");else if(J=this.reconstructor.takeBinaryData(Z),J)this.reconstructor=null,super.emitReserved("decoded",J)}else throw Error("Unknown type: "+Z)}decodeString(Z){let J=0,X={type:Number(Z.charAt(0))};if(d[X.type]===void 0)throw Error("unknown packet type "+X.type);if(X.type===d.BINARY_EVENT||X.type===d.BINARY_ACK){let G=J+1;while(Z.charAt(++J)!=="-"&&J!=Z.length);let W=Z.substring(G,J);if(W!=Number(W)||Z.charAt(J)!=="-")throw Error("Illegal attachments");X.attachments=Number(W)}if(Z.charAt(J+1)==="/"){let G=J+1;while(++J){if(Z.charAt(J)===",")break;if(J===Z.length)break}X.nsp=Z.substring(G,J)}else X.nsp="/";let Y=Z.charAt(J+1);if(Y!==""&&Number(Y)==Y){let G=J+1;while(++J){let W=Z.charAt(J);if(W==null||Number(W)!=W){--J;break}if(J===Z.length)break}X.id=Number(Z.substring(G,J+1))}if(Z.charAt(++J)){let G=this.tryParse(Z.substr(J));if(XZ.isPayloadValid(X.type,G))X.data=G;else throw Error("invalid payload")}return X}tryParse(Z){try{return JSON.parse(Z,this.reviver)}catch(J){return!1}}static isPayloadValid(Z,J){switch(Z){case d.CONNECT:return a9(J);case d.DISCONNECT:return J===void 0;case d.CONNECT_ERROR:return typeof J==="string"||a9(J);case d.EVENT:case d.BINARY_EVENT:return Array.isArray(J)&&(typeof J[0]==="number"||typeof J[0]==="string"&&CW.indexOf(J[0])===-1);case d.ACK:case d.BINARY_ACK:return Array.isArray(J)}}destroy(){if(this.reconstructor)this.reconstructor.finishedReconstruction(),this.reconstructor=null}}class xW{constructor(Z){this.packet=Z,this.buffers=[],this.reconPack=Z}takeBinaryData(Z){if(this.buffers.push(Z),this.buffers.length===this.reconPack.attachments){let J=SW(this.reconPack,this.buffers);return this.finishedReconstruction(),J}return null}finishedReconstruction(){this.reconPack=null,this.buffers=[]}}function HN(Z){return typeof Z==="string"}var QN=Number.isInteger||function(Z){return typeof Z==="number"&&isFinite(Z)&&Math.floor(Z)===Z};function KN(Z){return Z===void 0||QN(Z)}function a9(Z){return Object.prototype.toString.call(Z)==="[object Object]"}function UN(Z,J){switch(Z){case d.CONNECT:return J===void 0||a9(J);case d.DISCONNECT:return J===void 0;case d.EVENT:return Array.isArray(J)&&(typeof J[0]==="number"||typeof J[0]==="string"&&CW.indexOf(J[0])===-1);case d.ACK:return Array.isArray(J);case d.CONNECT_ERROR:return typeof J==="string"||a9(J);default:return!1}}function $N(Z){return HN(Z.nsp)&&KN(Z.id)&&UN(Z.type,Z.data)}function d1(Z,J,X){return Z.on(J,X),function(){Z.off(J,X)}}var LN=Object.freeze({connect:1,connect_error:1,disconnect:1,disconnecting:1,newListener:1,removeListener:1});class T6 extends X1{constructor(Z,J,X){super();if(this.connected=!1,this.recovered=!1,this.receiveBuffer=[],this.sendBuffer=[],this._queue=[],this._queueSeq=0,this.ids=0,this.acks={},this.flags={},this.io=Z,this.nsp=J,X&&X.auth)this.auth=X.auth;if(this._opts=Object.assign({},X),this.io._autoConnect)this.open()}get disconnected(){return!this.connected}subEvents(){if(this.subs)return;let Z=this.io;this.subs=[d1(Z,"open",this.onopen.bind(this)),d1(Z,"packet",this.onpacket.bind(this)),d1(Z,"error",this.onerror.bind(this)),d1(Z,"close",this.onclose.bind(this))]}get active(){return!!this.subs}connect(){if(this.connected)return this;if(this.subEvents(),!this.io._reconnecting)this.io.open();if(this.io._readyState==="open")this.onopen();return this}open(){return this.connect()}send(...Z){return Z.unshift("message"),this.emit.apply(this,Z),this}emit(Z,...J){var X,Y,G;if(LN.hasOwnProperty(Z))throw Error('"'+Z.toString()+'" is a reserved event name');if(J.unshift(Z),this._opts.retries&&!this.flags.fromQueue&&!this.flags.volatile)return this._addToQueue(J),this;let W={type:d.EVENT,data:J};if(W.options={},W.options.compress=this.flags.compress!==!1,typeof J[J.length-1]==="function"){let U=this.ids++,$=J.pop();this._registerAckCallback(U,$),W.id=U}let H=(Y=(X=this.io.engine)===null||X===void 0?void 0:X.transport)===null||Y===void 0?void 0:Y.writable,Q=this.connected&&!((G=this.io.engine)===null||G===void 0?void 0:G._hasPingExpired());if(this.flags.volatile&&!H);else if(Q)this.notifyOutgoingListeners(W),this.packet(W);else this.sendBuffer.push(W);return this.flags={},this}_registerAckCallback(Z,J){var X;let Y=(X=this.flags.timeout)!==null&&X!==void 0?X:this._opts.ackTimeout;if(Y===void 0){this.acks[Z]=J;return}let G=this.io.setTimeoutFn(()=>{delete this.acks[Z];for(let H=0;H<this.sendBuffer.length;H++)if(this.sendBuffer[H].id===Z)this.sendBuffer.splice(H,1);J.call(this,Error("operation has timed out"))},Y),W=(...H)=>{this.io.clearTimeoutFn(G),J.apply(this,H)};W.withError=!0,this.acks[Z]=W}emitWithAck(Z,...J){return new Promise((X,Y)=>{let G=(W,H)=>{return W?Y(W):X(H)};G.withError=!0,J.push(G),this.emit(Z,...J)})}_addToQueue(Z){let J;if(typeof Z[Z.length-1]==="function")J=Z.pop();let X={id:this._queueSeq++,tryCount:0,pending:!1,args:Z,flags:Object.assign({fromQueue:!0},this.flags)};Z.push((Y,...G)=>{if(X!==this._queue[0]);if(Y!==null){if(X.tryCount>this._opts.retries){if(this._queue.shift(),J)J(Y)}}else if(this._queue.shift(),J)J(null,...G);return X.pending=!1,this._drainQueue()}),this._queue.push(X),this._drainQueue()}_drainQueue(Z=!1){if(!this.connected||this._queue.length===0)return;let J=this._queue[0];if(J.pending&&!Z)return;J.pending=!0,J.tryCount++,this.flags=J.flags,this.emit.apply(this,J.args)}packet(Z){Z.nsp=this.nsp,this.io._packet(Z)}onopen(){if(typeof this.auth=="function")this.auth((Z)=>{this._sendConnectPacket(Z)});else this._sendConnectPacket(this.auth)}_sendConnectPacket(Z){this.packet({type:d.CONNECT,data:this._pid?Object.assign({pid:this._pid,offset:this._lastOffset},Z):Z})}onerror(Z){if(!this.connected)this.emitReserved("connect_error",Z)}onclose(Z,J){this.connected=!1,delete this.id,this.emitReserved("disconnect",Z,J),this._clearAcks()}_clearAcks(){Object.keys(this.acks).forEach((Z)=>{if(!this.sendBuffer.some((X)=>String(X.id)===Z)){let X=this.acks[Z];if(delete this.acks[Z],X.withError)X.call(this,Error("socket has been disconnected"))}})}onpacket(Z){if(Z.nsp!==this.nsp)return;switch(Z.type){case d.CONNECT:if(Z.data&&Z.data.sid)this.onconnect(Z.data.sid,Z.data.pid);else this.emitReserved("connect_error",Error("It seems you are trying to reach a Socket.IO server in v2.x with a v3.x client, but they are not compatible (more information here: https://socket.io/docs/v3/migrating-from-2-x-to-3-0/)"));break;case d.EVENT:case d.BINARY_EVENT:this.onevent(Z);break;case d.ACK:case d.BINARY_ACK:this.onack(Z);break;case d.DISCONNECT:this.ondisconnect();break;case d.CONNECT_ERROR:this.destroy();let X=Error(Z.data.message);X.data=Z.data.data,this.emitReserved("connect_error",X);break}}onevent(Z){let J=Z.data||[];if(Z.id!=null)J.push(this.ack(Z.id));if(this.connected)this.emitEvent(J);else this.receiveBuffer.push(Object.freeze(J))}emitEvent(Z){if(this._anyListeners&&this._anyListeners.length){let J=this._anyListeners.slice();for(let X of J)X.apply(this,Z)}if(super.emit.apply(this,Z),this._pid&&Z.length&&typeof Z[Z.length-1]==="string")this._lastOffset=Z[Z.length-1]}ack(Z){let J=this,X=!1;return function(...Y){if(X)return;X=!0,J.packet({type:d.ACK,id:Z,data:Y})}}onack(Z){let J=this.acks[Z.id];if(typeof J!=="function")return;if(delete this.acks[Z.id],J.withError)Z.data.unshift(null);J.apply(this,Z.data)}onconnect(Z,J){this.id=Z,this.recovered=J&&this._pid===J,this._pid=J,this.connected=!0,this.emitBuffered(),this._drainQueue(!0),this.emitReserved("connect")}emitBuffered(){this.receiveBuffer.forEach((Z)=>this.emitEvent(Z)),this.receiveBuffer=[],this.sendBuffer.forEach((Z)=>{this.notifyOutgoingListeners(Z),this.packet(Z)}),this.sendBuffer=[]}ondisconnect(){this.destroy(),this.onclose("io server disconnect")}destroy(){if(this.subs)this.subs.forEach((Z)=>Z()),this.subs=void 0;this.io._destroy(this)}disconnect(){if(this.connected)this.packet({type:d.DISCONNECT});if(this.destroy(),this.connected)this.onclose("io client disconnect");return this}close(){return this.disconnect()}compress(Z){return this.flags.compress=Z,this}get volatile(){return this.flags.volatile=!0,this}timeout(Z){return this.flags.timeout=Z,this}onAny(Z){return this._anyListeners=this._anyListeners||[],this._anyListeners.push(Z),this}prependAny(Z){return this._anyListeners=this._anyListeners||[],this._anyListeners.unshift(Z),this}offAny(Z){if(!this._anyListeners)return this;if(Z){let J=this._anyListeners;for(let X=0;X<J.length;X++)if(Z===J[X])return J.splice(X,1),this}else this._anyListeners=[];return this}listenersAny(){return this._anyListeners||[]}onAnyOutgoing(Z){return this._anyOutgoingListeners=this._anyOutgoingListeners||[],this._anyOutgoingListeners.push(Z),this}prependAnyOutgoing(Z){return this._anyOutgoingListeners=this._anyOutgoingListeners||[],this._anyOutgoingListeners.unshift(Z),this}offAnyOutgoing(Z){if(!this._anyOutgoingListeners)return this;if(Z){let J=this._anyOutgoingListeners;for(let X=0;X<J.length;X++)if(Z===J[X])return J.splice(X,1),this}else this._anyOutgoingListeners=[];return this}listenersAnyOutgoing(){return this._anyOutgoingListeners||[]}notifyOutgoingListeners(Z){if(this._anyOutgoingListeners&&this._anyOutgoingListeners.length){let J=this._anyOutgoingListeners.slice();for(let X of J)X.apply(this,Z.data)}}}function U5(Z){Z=Z||{},this.ms=Z.min||100,this.max=Z.max||1e4,this.factor=Z.factor||2,this.jitter=Z.jitter>0&&Z.jitter<=1?Z.jitter:0,this.attempts=0}U5.prototype.duration=function(){var Z=this.ms*Math.pow(this.factor,this.attempts++);if(this.jitter){var J=Math.random(),X=Math.floor(J*this.jitter*Z);Z=(Math.floor(J*10)&1)==0?Z-X:Z+X}return Math.min(Z,this.max)|0};U5.prototype.reset=function(){this.attempts=0};U5.prototype.setMin=function(Z){this.ms=Z};U5.prototype.setMax=function(Z){this.max=Z};U5.prototype.setJitter=function(Z){this.jitter=Z};class P6 extends X1{constructor(Z,J){var X;super();if(this.nsps={},this.subs=[],Z&&typeof Z==="object")J=Z,Z=void 0;J=J||{},J.path=J.path||"/socket.io",this.opts=J,C0(this,J),this.reconnection(J.reconnection!==!1),this.reconnectionAttempts(J.reconnectionAttempts||1/0),this.reconnectionDelay(J.reconnectionDelay||1000),this.reconnectionDelayMax(J.reconnectionDelayMax||5000),this.randomizationFactor((X=J.randomizationFactor)!==null&&X!==void 0?X:0.5),this.backoff=new U5({min:this.reconnectionDelay(),max:this.reconnectionDelayMax(),jitter:this.randomizationFactor()}),this.timeout(J.timeout==null?20000:J.timeout),this._readyState="closed",this.uri=Z;let Y=J.parser||YZ;if(this.encoder=new Y.Encoder,this.decoder=new Y.Decoder,this._autoConnect=J.autoConnect!==!1,this._autoConnect)this.open()}reconnection(Z){if(!arguments.length)return this._reconnection;if(this._reconnection=!!Z,!Z)this.skipReconnect=!0;return this}reconnectionAttempts(Z){if(Z===void 0)return this._reconnectionAttempts;return this._reconnectionAttempts=Z,this}reconnectionDelay(Z){var J;if(Z===void 0)return this._reconnectionDelay;return this._reconnectionDelay=Z,(J=this.backoff)===null||J===void 0||J.setMin(Z),this}randomizationFactor(Z){var J;if(Z===void 0)return this._randomizationFactor;return this._randomizationFactor=Z,(J=this.backoff)===null||J===void 0||J.setJitter(Z),this}reconnectionDelayMax(Z){var J;if(Z===void 0)return this._reconnectionDelayMax;return this._reconnectionDelayMax=Z,(J=this.backoff)===null||J===void 0||J.setMax(Z),this}timeout(Z){if(!arguments.length)return this._timeout;return this._timeout=Z,this}maybeReconnectOnOpen(){if(!this._reconnecting&&this._reconnection&&this.backoff.attempts===0)this.reconnect()}open(Z){if(~this._readyState.indexOf("open"))return this;this.engine=new R6(this.uri,this.opts);let J=this.engine,X=this;this._readyState="opening",this.skipReconnect=!1;let Y=d1(J,"open",function(){X.onopen(),Z&&Z()}),G=(H)=>{if(this.cleanup(),this._readyState="closed",this.emitReserved("error",H),Z)Z(H);else this.maybeReconnectOnOpen()},W=d1(J,"error",G);if(this._timeout!==!1){let H=this._timeout,Q=this.setTimeoutFn(()=>{Y(),G(Error("timeout")),J.close()},H);if(this.opts.autoUnref)Q.unref();this.subs.push(()=>{this.clearTimeoutFn(Q)})}return this.subs.push(Y),this.subs.push(W),this}connect(Z){return this.open(Z)}onopen(){this.cleanup(),this._readyState="open",this.emitReserved("open");let Z=this.engine;this.subs.push(d1(Z,"ping",this.onping.bind(this)),d1(Z,"data",this.ondata.bind(this)),d1(Z,"error",this.onerror.bind(this)),d1(Z,"close",this.onclose.bind(this)),d1(this.decoder,"decoded",this.ondecoded.bind(this)))}onping(){this.emitReserved("ping")}ondata(Z){try{this.decoder.add(Z)}catch(J){this.onclose("parse error",J)}}ondecoded(Z){S0(()=>{this.emitReserved("packet",Z)},this.setTimeoutFn)}onerror(Z){this.emitReserved("error",Z)}socket(Z,J){let X=this.nsps[Z];if(!X)X=new T6(this,Z,J),this.nsps[Z]=X;else if(this._autoConnect&&!X.active)X.connect();return X}_destroy(Z){let J=Object.keys(this.nsps);for(let X of J)if(this.nsps[X].active)return;this._close()}_packet(Z){let J=this.encoder.encode(Z);for(let X=0;X<J.length;X++)this.engine.write(J[X],Z.options)}cleanup(){this.subs.forEach((Z)=>Z()),this.subs.length=0,this.decoder.destroy()}_close(){this.skipReconnect=!0,this._reconnecting=!1,this.onclose("forced close")}disconnect(){return this._close()}onclose(Z,J){var X;if(this.cleanup(),(X=this.engine)===null||X===void 0||X.close(),this.backoff.reset(),this._readyState="closed",this.emitReserved("close",Z,J),this._reconnection&&!this.skipReconnect)this.reconnect()}reconnect(){if(this._reconnecting||this.skipReconnect)return this;let Z=this;if(this.backoff.attempts>=this._reconnectionAttempts)this.backoff.reset(),this.emitReserved("reconnect_failed"),this._reconnecting=!1;else{let J=this.backoff.duration();this._reconnecting=!0;let X=this.setTimeoutFn(()=>{if(Z.skipReconnect)return;if(this.emitReserved("reconnect_attempt",Z.backoff.attempts),Z.skipReconnect)return;Z.open((Y)=>{if(Y)Z._reconnecting=!1,Z.reconnect(),this.emitReserved("reconnect_error",Y);else Z.onreconnect()})},J);if(this.opts.autoUnref)X.unref();this.subs.push(()=>{this.clearTimeoutFn(X)})}}onreconnect(){let Z=this.backoff.attempts;this._reconnecting=!1,this.backoff.reset(),this.emitReserved("reconnect",Z)}}var w6={};function _6(Z,J){if(typeof Z==="object")J=Z,Z=void 0;J=J||{};let X=PW(Z,J.path||"/socket.io"),Y=X.source,G=X.id,W=X.path,H=w6[G]&&W in w6[G].nsps,Q=J.forceNew||J["force new connection"]||J.multiplex===!1||H,K;if(Q)K=new P6(Y,J);else{if(!w6[G])w6[G]=new P6(Y,J);K=w6[G]}if(X.query&&!J.query)J.query=X.queryKey;return K.socket(X.path,J)}Object.assign(_6,{Manager:P6,Socket:T6,io:_6,connect:_6});import{createContext as BN}from"react";var m0=()=>_6(T1(),{autoConnect:!1,transports:["websocket"]}),zN=BN(null),o1=zN;import{createContext as EN}from"react";function w1(Z,J,X,Y){function G(W){return W instanceof X?W:new X(function(H){H(W)})}return new(X||(X=Promise))(function(W,H){function Q($){try{U(Y.next($))}catch(L){H(L)}}function K($){try{U(Y.throw($))}catch(L){H(L)}}function U($){$.done?W($.value):G($.value).then(Q,K)}U((Y=Y.apply(Z,J||[])).next())})}function MN(Z){return Z&&Z.__esModule&&Object.prototype.hasOwnProperty.call(Z,"default")?Z.default:Z}var QZ={exports:{}},h5=typeof Reflect==="object"?Reflect:null,bW=h5&&typeof h5.apply==="function"?h5.apply:function(J,X,Y){return Function.prototype.apply.call(J,X,Y)},r9;if(h5&&typeof h5.ownKeys==="function")r9=h5.ownKeys;else if(Object.getOwnPropertySymbols)r9=function(J){return Object.getOwnPropertyNames(J).concat(Object.getOwnPropertySymbols(J))};else r9=function(J){return Object.getOwnPropertyNames(J)};function FN(Z){if(console&&console.warn)console.warn(Z)}var gW=Number.isNaN||function(J){return J!==J};function Z1(){Z1.init.call(this)}QZ.exports=Z1;QZ.exports.once=DN;Z1.EventEmitter=Z1;Z1.prototype._events=void 0;Z1.prototype._eventsCount=0;Z1.prototype._maxListeners=void 0;var kW=10;function Z8(Z){if(typeof Z!=="function")throw TypeError('The "listener" argument must be of type Function. Received type '+typeof Z)}Object.defineProperty(Z1,"defaultMaxListeners",{enumerable:!0,get:function(){return kW},set:function(Z){if(typeof Z!=="number"||Z<0||gW(Z))throw RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+Z+".");kW=Z}});Z1.init=function(){if(this._events===void 0||this._events===Object.getPrototypeOf(this)._events)this._events=Object.create(null),this._eventsCount=0;this._maxListeners=this._maxListeners||void 0};Z1.prototype.setMaxListeners=function(J){if(typeof J!=="number"||J<0||gW(J))throw RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+J+".");return this._maxListeners=J,this};function hW(Z){if(Z._maxListeners===void 0)return Z1.defaultMaxListeners;return Z._maxListeners}Z1.prototype.getMaxListeners=function(){return hW(this)};Z1.prototype.emit=function(J){var X=[];for(var Y=1;Y<arguments.length;Y++)X.push(arguments[Y]);var G=J==="error",W=this._events;if(W!==void 0)G=G&&W.error===void 0;else if(!G)return!1;if(G){var H;if(X.length>0)H=X[0];if(H instanceof Error)throw H;var Q=Error("Unhandled error."+(H?" ("+H.message+")":""));throw Q.context=H,Q}var K=W[J];if(K===void 0)return!1;if(typeof K==="function")bW(K,this,X);else{var U=K.length,$=uW(K,U);for(var Y=0;Y<U;++Y)bW($[Y],this,X)}return!0};function vW(Z,J,X,Y){var G,W,H;if(Z8(X),W=Z._events,W===void 0)W=Z._events=Object.create(null),Z._eventsCount=0;else{if(W.newListener!==void 0)Z.emit("newListener",J,X.listener?X.listener:X),W=Z._events;H=W[J]}if(H===void 0)H=W[J]=X,++Z._eventsCount;else{if(typeof H==="function")H=W[J]=Y?[X,H]:[H,X];else if(Y)H.unshift(X);else H.push(X);if(G=hW(Z),G>0&&H.length>G&&!H.warned){H.warned=!0;var Q=Error("Possible EventEmitter memory leak detected. "+H.length+" "+String(J)+" listeners added. Use emitter.setMaxListeners() to increase limit");Q.name="MaxListenersExceededWarning",Q.emitter=Z,Q.type=J,Q.count=H.length,FN(Q)}}return Z}Z1.prototype.addListener=function(J,X){return vW(this,J,X,!1)};Z1.prototype.on=Z1.prototype.addListener;Z1.prototype.prependListener=function(J,X){return vW(this,J,X,!0)};function NN(){if(!this.fired){if(this.target.removeListener(this.type,this.wrapFn),this.fired=!0,arguments.length===0)return this.listener.call(this.target);return this.listener.apply(this.target,arguments)}}function yW(Z,J,X){var Y={fired:!1,wrapFn:void 0,target:Z,type:J,listener:X},G=NN.bind(Y);return G.listener=X,Y.wrapFn=G,G}Z1.prototype.once=function(J,X){return Z8(X),this.on(J,yW(this,J,X)),this};Z1.prototype.prependOnceListener=function(J,X){return Z8(X),this.prependListener(J,yW(this,J,X)),this};Z1.prototype.removeListener=function(J,X){var Y,G,W,H,Q;if(Z8(X),G=this._events,G===void 0)return this;if(Y=G[J],Y===void 0)return this;if(Y===X||Y.listener===X){if(--this._eventsCount===0)this._events=Object.create(null);else if(delete G[J],G.removeListener)this.emit("removeListener",J,Y.listener||X)}else if(typeof Y!=="function"){W=-1;for(H=Y.length-1;H>=0;H--)if(Y[H]===X||Y[H].listener===X){Q=Y[H].listener,W=H;break}if(W<0)return this;if(W===0)Y.shift();else VN(Y,W);if(Y.length===1)G[J]=Y[0];if(G.removeListener!==void 0)this.emit("removeListener",J,Q||X)}return this};Z1.prototype.off=Z1.prototype.removeListener;Z1.prototype.removeAllListeners=function(J){var X,Y,G;if(Y=this._events,Y===void 0)return this;if(Y.removeListener===void 0){if(arguments.length===0)this._events=Object.create(null),this._eventsCount=0;else if(Y[J]!==void 0)if(--this._eventsCount===0)this._events=Object.create(null);else delete Y[J];return this}if(arguments.length===0){var W=Object.keys(Y),H;for(G=0;G<W.length;++G){if(H=W[G],H==="removeListener")continue;this.removeAllListeners(H)}return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if(X=Y[J],typeof X==="function")this.removeListener(J,X);else if(X!==void 0)for(G=X.length-1;G>=0;G--)this.removeListener(J,X[G]);return this};function mW(Z,J,X){var Y=Z._events;if(Y===void 0)return[];var G=Y[J];if(G===void 0)return[];if(typeof G==="function")return X?[G.listener||G]:[G];return X?AN(G):uW(G,G.length)}Z1.prototype.listeners=function(J){return mW(this,J,!0)};Z1.prototype.rawListeners=function(J){return mW(this,J,!1)};Z1.listenerCount=function(Z,J){if(typeof Z.listenerCount==="function")return Z.listenerCount(J);else return fW.call(Z,J)};Z1.prototype.listenerCount=fW;function fW(Z){var J=this._events;if(J!==void 0){var X=J[Z];if(typeof X==="function")return 1;else if(X!==void 0)return X.length}return 0}Z1.prototype.eventNames=function(){return this._eventsCount>0?r9(this._events):[]};function uW(Z,J){var X=Array(J);for(var Y=0;Y<J;++Y)X[Y]=Z[Y];return X}function VN(Z,J){for(;J+1<Z.length;J++)Z[J]=Z[J+1];Z.pop()}function AN(Z){var J=Array(Z.length);for(var X=0;X<J.length;++X)J[X]=Z[X].listener||Z[X];return J}function DN(Z,J){return new Promise(function(X,Y){function G(H){Z.removeListener(J,W),Y(H)}function W(){if(typeof Z.removeListener==="function")Z.removeListener("error",G);X([].slice.call(arguments))}if(pW(Z,J,W,{once:!0}),J!=="error")qN(Z,G,{once:!0})})}function qN(Z,J,X){if(typeof Z.on==="function")pW(Z,"error",J,X)}function pW(Z,J,X,Y){if(typeof Z.on==="function")if(Y.once)Z.once(J,X);else Z.on(J,X);else if(typeof Z.addEventListener==="function")Z.addEventListener(J,function G(W){if(Y.once)Z.removeEventListener(J,G);X(W)});else throw TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof Z)}var RN=QZ.exports,lW=MN(RN),G1;(function(Z){Z[Z.timeout=1]="timeout",Z[Z.transportClosed=2]="transportClosed",Z[Z.clientDisconnected=3]="clientDisconnected",Z[Z.clientClosed=4]="clientClosed",Z[Z.clientConnectToken=5]="clientConnectToken",Z[Z.clientRefreshToken=6]="clientRefreshToken",Z[Z.subscriptionUnsubscribed=7]="subscriptionUnsubscribed",Z[Z.subscriptionSubscribeToken=8]="subscriptionSubscribeToken",Z[Z.subscriptionRefreshToken=9]="subscriptionRefreshToken",Z[Z.transportWriteError=10]="transportWriteError",Z[Z.connectionClosed=11]="connectionClosed",Z[Z.badConfiguration=12]="badConfiguration"})(G1||(G1={}));var f0;(function(Z){Z[Z.connectCalled=0]="connectCalled",Z[Z.transportClosed=1]="transportClosed",Z[Z.noPing=2]="noPing",Z[Z.subscribeTimeout=3]="subscribeTimeout",Z[Z.unsubscribeError=4]="unsubscribeError"})(f0||(f0={}));var S6;(function(Z){Z[Z.disconnectCalled=0]="disconnectCalled",Z[Z.unauthorized=1]="unauthorized",Z[Z.badProtocol=2]="badProtocol",Z[Z.messageSizeLimit=3]="messageSizeLimit"})(S6||(S6={}));var s9;(function(Z){Z[Z.subscribeCalled=0]="subscribeCalled",Z[Z.transportClosed=1]="transportClosed"})(s9||(s9={}));var o9;(function(Z){Z[Z.unsubscribeCalled=0]="unsubscribeCalled",Z[Z.unauthorized=1]="unauthorized",Z[Z.clientClosed=2]="clientClosed"})(o9||(o9={}));var GZ;(function(Z){Z[Z.channelCompaction=1]="channelCompaction"})(GZ||(GZ={}));var $1;(function(Z){Z.Disconnected="disconnected",Z.Connecting="connecting",Z.Connected="connected"})($1||($1={}));var j1;(function(Z){Z.Unsubscribed="unsubscribed",Z.Subscribing="subscribing",Z.Subscribed="subscribed"})(j1||(j1={}));function IN(Z,J){return Z.lastIndexOf(J,0)===0}function dW(Z){if(Z===void 0||Z===null)return!1;return typeof Z==="function"}function ON(Z,J){if(globalThis.console){let X=globalThis.console[Z];if(dW(X))X.apply(globalThis.console,J)}}function TN(Z,J){return Math.floor(Math.random()*(J-Z+1)+Z)}function t9(Z,J,X){if(Z>31)Z=31;let Y=TN(0,Math.min(X,J*Math.pow(2,Z)));return Math.min(X,J+Y)}function PN(Z){return"error"in Z&&Z.error!==null}function e9(Z){return Math.min(Z*1000,2147483647)}class cW extends lW{constructor(Z,J,X){super();if(this._resubscribeTimeout=null,this._refreshTimeout=null,this.channel=J,this.state=j1.Unsubscribed,this._centrifuge=Z,this._token="",this._getToken=null,this._data=null,this._getData=null,this._recover=!1,this._offset=null,this._epoch=null,this._id=0,this._recoverable=!1,this._positioned=!1,this._joinLeave=!1,this._minResubscribeDelay=500,this._maxResubscribeDelay=20000,this._resubscribeTimeout=null,this._resubscribeAttempts=0,this._promises={},this._promiseId=0,this._inflight=!1,this._refreshTimeout=null,this._delta="",this._delta_negotiated=!1,this._tagsFilter=null,this._prevValue=null,this._unsubPromise=Promise.resolve(),this._setOptions(X),this._centrifuge._debugEnabled)this.on("state",(Y)=>{this._debug("subscription state",J,Y.oldState,"->",Y.newState)}),this.on("error",(Y)=>{this._debug("subscription error",J,Y)});else this.on("error",function(){Function.prototype()})}ready(Z){if(this.state===j1.Unsubscribed)return Promise.reject({code:G1.subscriptionUnsubscribed,message:this.state});if(this.state===j1.Subscribed)return Promise.resolve();return new Promise((J,X)=>{let Y={resolve:J,reject:X};if(Z)Y.timeout=setTimeout(function(){X({code:G1.timeout,message:"timeout"})},Z);this._promises[this._nextPromiseId()]=Y})}subscribe(){if(this._isSubscribed())return;this._resubscribeAttempts=0,this._setSubscribing(s9.subscribeCalled,"subscribe called")}unsubscribe(){this._unsubPromise=this._setUnsubscribed(o9.unsubscribeCalled,"unsubscribe called",!0)}publish(Z){return w1(this,void 0,void 0,function*(){return yield this._methodCall(),this._centrifuge.publish(this.channel,Z)})}presence(){return w1(this,void 0,void 0,function*(){return yield this._methodCall(),this._centrifuge.presence(this.channel)})}presenceStats(){return w1(this,void 0,void 0,function*(){return yield this._methodCall(),this._centrifuge.presenceStats(this.channel)})}history(Z){return w1(this,void 0,void 0,function*(){return yield this._methodCall(),this._centrifuge.history(this.channel,Z)})}setTagsFilter(Z){if(Z&&this._delta)throw Error("cannot use delta and tagsFilter together");this._tagsFilter=Z}setData(Z){this._data=Z}_methodCall(){if(this._isSubscribed())return Promise.resolve();if(this._isUnsubscribed())return Promise.reject({code:G1.subscriptionUnsubscribed,message:this.state});return new Promise((Z,J)=>{let X=this._centrifuge._config.timeout,Y=setTimeout(()=>{J({code:G1.timeout,message:"timeout"})},X);this._promises[this._nextPromiseId()]={timeout:Y,resolve:Z,reject:J}})}_nextPromiseId(){return++this._promiseId}_needRecover(){return this._recover===!0}_isUnsubscribed(){return this.state===j1.Unsubscribed}_isSubscribing(){return this.state===j1.Subscribing}_isSubscribed(){return this.state===j1.Subscribed}_setState(Z){if(this.state!==Z){let J=this.state;return this.state=Z,this.emit("state",{newState:Z,oldState:J,channel:this.channel}),!0}return!1}_usesToken(){return this._token!==""||this._getToken!==null}_clearSubscribingState(){this._resubscribeAttempts=0,this._clearResubscribeTimeout()}_clearSubscribedState(){this._clearRefreshTimeout()}_setSubscribed(Z){if(!this._isSubscribing())return;if(this._clearSubscribingState(),Z.id)this._id=Z.id;if(Z.recoverable)this._recover=!0,this._offset=Z.offset||0,this._epoch=Z.epoch||"";if(Z.delta)this._delta_negotiated=!0;else this._delta_negotiated=!1;this._setState(j1.Subscribed);let J=this._centrifuge._getSubscribeContext(this.channel,Z);this.emit("subscribed",J),this._resolvePromises();let X=Z.publications;if(X&&X.length>0)for(let Y in X){if(!X.hasOwnProperty(Y))continue;this._handlePublication(X[Y])}if(Z.expires===!0)this._refreshTimeout=setTimeout(()=>this._refresh(),e9(Z.ttl))}_setSubscribing(Z,J){return w1(this,void 0,void 0,function*(){if(this._isSubscribing())return;if(this._isSubscribed())this._clearSubscribedState();if(this._setState(j1.Subscribing))this.emit("subscribing",{channel:this.channel,code:Z,reason:J});if(this._centrifuge._transport&&this._centrifuge._transport.emulation())yield this._unsubPromise;if(!this._isSubscribing())return;this._subscribe()})}_subscribe(){if(this._debug("subscribing on",this.channel),!this._isTransportOpen())return this._debug("delay subscribe on",this.channel,"till connected"),null;if(this._inflight)return null;if(this._inflight=!0,this._canSubscribeWithoutGettingToken())return this._subscribeWithoutToken();return this._getSubscriptionToken().then((Z)=>this._handleTokenResponse(Z)).catch((Z)=>this._handleTokenError(Z)),null}_isTransportOpen(){return this._centrifuge._transportIsOpen}_canSubscribeWithoutGettingToken(){return!this._usesToken()||!!this._token}_subscribeWithoutToken(){if(this._getData)return this._getDataAndSubscribe(this._token),null;else return this._sendSubscribe(this._token)}_getDataAndSubscribe(Z){if(!this._getData){this._inflight=!1;return}this._getData({channel:this.channel}).then((J)=>{if(!this._isSubscribing()){this._inflight=!1;return}this._data=J,this._sendSubscribe(Z)}).catch((J)=>this._handleGetDataError(J))}_handleGetDataError(Z){if(!this._isSubscribing()){this._inflight=!1;return}if(Z instanceof D0){this._inflight=!1,this._failUnauthorized();return}this.emit("error",{type:"subscribeData",channel:this.channel,error:{code:G1.badConfiguration,message:(Z===null||Z===void 0?void 0:Z.toString())||""}}),this._inflight=!1,this._scheduleResubscribe()}_handleTokenResponse(Z){if(!this._isSubscribing()){this._inflight=!1;return}if(!Z){this._inflight=!1,this._failUnauthorized();return}if(this._token=Z,this._getData)this._getDataAndSubscribe(Z);else this._sendSubscribe(Z)}_handleTokenError(Z){if(!this._isSubscribing()){this._inflight=!1;return}if(Z instanceof D0){this._inflight=!1,this._failUnauthorized();return}this.emit("error",{type:"subscribeToken",channel:this.channel,error:{code:G1.subscriptionSubscribeToken,message:(Z===null||Z===void 0?void 0:Z.toString())||""}}),this._inflight=!1,this._scheduleResubscribe()}_sendSubscribe(Z){if(!this._isTransportOpen())return this._inflight=!1,null;let J=this._buildSubscribeCommand(Z);return this._centrifuge._call(J).then((X)=>{this._inflight=!1;let Y=X.reply.subscribe;if(this._handleSubscribeResponse(Y),X.next)X.next()},(X)=>{if(this._inflight=!1,this._handleSubscribeError(X.error),X.next)X.next()}),J}_buildSubscribeCommand(Z){let J={channel:this.channel};if(Z)J.token=Z;if(this._data)J.data=this._data;if(this._positioned)J.positioned=!0;if(this._recoverable)J.recoverable=!0;if(this._joinLeave)J.join_leave=!0;if(J.flag=GZ.channelCompaction,this._needRecover()){J.recover=!0;let X=this._getOffset();if(X)J.offset=X;let Y=this._getEpoch();if(Y)J.epoch=Y}if(this._delta)J.delta=this._delta;if(this._tagsFilter)J.tf=this._tagsFilter;return{subscribe:J}}_debug(...Z){this._centrifuge._debug(...Z)}_handleSubscribeError(Z){if(!this._isSubscribing())return;if(Z.code===G1.timeout){this._centrifuge._disconnect(f0.subscribeTimeout,"subscribe timeout",!0);return}this._subscribeError(Z)}_handleSubscribeResponse(Z){if(!this._isSubscribing())return;this._setSubscribed(Z)}_setUnsubscribed(Z,J,X){if(this._isUnsubscribed())return Promise.resolve();let Y=Promise.resolve();if(this._isSubscribed()){if(X)Y=this._centrifuge._unsubscribe(this);this._clearSubscribedState()}else if(this._isSubscribing()){if(this._inflight&&X)Y=this._centrifuge._unsubscribe(this);this._clearSubscribingState()}if(this._inflight=!1,this._setState(j1.Unsubscribed))this.emit("unsubscribed",{channel:this.channel,code:Z,reason:J});return this._rejectPromises({code:G1.subscriptionUnsubscribed,message:this.state}),Y}_handlePublication(Z){if(this._delta&&this._delta_negotiated){let{newData:X,newPrevValue:Y}=this._centrifuge._codec.applyDeltaIfNeeded(Z,this._prevValue);Z.data=X,this._prevValue=Y}let J=this._centrifuge._getPublicationContext(this.channel,Z);if(this.emit("publication",J),Z.offset)this._offset=Z.offset}_handleJoin(Z){let J=this._centrifuge._getJoinLeaveContext(Z.info);this.emit("join",{channel:this.channel,info:J})}_handleLeave(Z){let J=this._centrifuge._getJoinLeaveContext(Z.info);this.emit("leave",{channel:this.channel,info:J})}_resolvePromises(){for(let Z in this._promises){if(!this._promises.hasOwnProperty(Z))continue;if(this._promises[Z].timeout)clearTimeout(this._promises[Z].timeout);this._promises[Z].resolve(),delete this._promises[Z]}}_rejectPromises(Z){for(let J in this._promises){if(!this._promises.hasOwnProperty(J))continue;if(this._promises[J].timeout)clearTimeout(this._promises[J].timeout);this._promises[J].reject(Z),delete this._promises[J]}}_scheduleResubscribe(){if(!this._isSubscribing()){this._debug("not in subscribing state, skip resubscribe scheduling",this.channel);return}let Z=this,J=this._getResubscribeDelay();this._resubscribeTimeout=setTimeout(function(){if(Z._isSubscribing())Z._subscribe()},J),this._debug("resubscribe scheduled after "+J,this.channel)}_subscribeError(Z){if(!this._isSubscribing())return;if(Z.code<100||Z.code===109||Z.temporary===!0){if(Z.code===109)this._token="";let J={channel:this.channel,type:"subscribe",error:Z};if(this._centrifuge.state===$1.Connected)this.emit("error",J);this._scheduleResubscribe()}else this._setUnsubscribed(Z.code,Z.message,!1)}_getResubscribeDelay(){let Z=t9(this._resubscribeAttempts,this._minResubscribeDelay,this._maxResubscribeDelay);return this._resubscribeAttempts++,Z}_setOptions(Z){if(!Z)return;if(Z.since)this._offset=Z.since.offset||0,this._epoch=Z.since.epoch||"",this._recover=!0;if(Z.data)this._data=Z.data;if(Z.getData)this._getData=Z.getData;if(Z.minResubscribeDelay!==void 0)this._minResubscribeDelay=Z.minResubscribeDelay;if(Z.maxResubscribeDelay!==void 0)this._maxResubscribeDelay=Z.maxResubscribeDelay;if(Z.token)this._token=Z.token;if(Z.getToken)this._getToken=Z.getToken;if(Z.positioned===!0)this._positioned=!0;if(Z.recoverable===!0)this._recoverable=!0;if(Z.joinLeave===!0)this._joinLeave=!0;if(Z.delta){if(Z.delta!=="fossil")throw Error("unsupported delta format");this._delta=Z.delta}if(Z.tagsFilter)this._tagsFilter=Z.tagsFilter;if(this._tagsFilter&&this._delta)throw Error("cannot use delta and tagsFilter together")}_getOffset(){let Z=this._offset;if(Z!==null)return Z;return 0}_getEpoch(){let Z=this._epoch;if(Z!==null)return Z;return""}_clearRefreshTimeout(){if(this._refreshTimeout!==null)clearTimeout(this._refreshTimeout),this._refreshTimeout=null}_clearResubscribeTimeout(){if(this._resubscribeTimeout!==null)clearTimeout(this._resubscribeTimeout),this._resubscribeTimeout=null}_getSubscriptionToken(){this._debug("get subscription token for channel",this.channel);let Z={channel:this.channel},J=this._getToken;if(J===null)return this.emit("error",{type:"configuration",channel:this.channel,error:{code:G1.badConfiguration,message:"provide a function to get channel subscription token"}}),Promise.reject(new D0(""));return J(Z)}_refresh(){this._clearRefreshTimeout();let Z=this;this._getSubscriptionToken().then(function(J){if(!Z._isSubscribed())return;if(!J){Z._failUnauthorized();return}Z._token=J;let Y={sub_refresh:{channel:Z.channel,token:J}};Z._centrifuge._call(Y).then((G)=>{let W=G.reply.sub_refresh;if(Z._refreshResponse(W),G.next)G.next()},(G)=>{if(Z._refreshError(G.error),G.next)G.next()})}).catch(function(J){if(J instanceof D0){Z._failUnauthorized();return}Z.emit("error",{type:"refreshToken",channel:Z.channel,error:{code:G1.subscriptionRefreshToken,message:J!==void 0?J.toString():""}}),Z._refreshTimeout=setTimeout(()=>Z._refresh(),Z._getRefreshRetryDelay())})}_refreshResponse(Z){if(!this._isSubscribed())return;if(this._debug("subscription token refreshed, channel",this.channel),this._clearRefreshTimeout(),Z.expires===!0)this._refreshTimeout=setTimeout(()=>this._refresh(),e9(Z.ttl))}_refreshError(Z){if(!this._isSubscribed())return;if(Z.code<100||Z.temporary===!0)this.emit("error",{type:"refresh",channel:this.channel,error:Z}),this._refreshTimeout=setTimeout(()=>this._refresh(),this._getRefreshRetryDelay());else this._setUnsubscribed(Z.code,Z.message,!0)}_getRefreshRetryDelay(){return t9(0,1e4,20000)}_failUnauthorized(){this._setUnsubscribed(o9.unauthorized,"unauthorized",!0)}}class iW{constructor(Z,J){this.endpoint=Z,this.options=J,this._transport=null}name(){return"sockjs"}subName(){return"sockjs-"+this._transport.transport}emulation(){return!1}supported(){return this.options.sockjs!==null}initialize(Z,J){this._transport=new this.options.sockjs(this.endpoint,null,this.options.sockjsOptions),this._transport.onopen=()=>{J.onOpen()},this._transport.onerror=(X)=>{J.onError(X)},this._transport.onclose=(X)=>{J.onClose(X)},this._transport.onmessage=(X)=>{J.onMessage(X.data)}}close(){this._transport.close()}send(Z){this._transport.send(Z)}}class WZ{constructor(Z,J){this.endpoint=Z,this.options=J,this._transport=null}name(){return"websocket"}subName(){return"websocket"}emulation(){return!1}supported(){return this.options.websocket!==void 0&&this.options.websocket!==null}initialize(Z,J){let X="";if(Z==="protobuf")X="centrifuge-protobuf";if(X!=="")this._transport=new this.options.websocket(this.endpoint,X);else this._transport=new this.options.websocket(this.endpoint);if(Z==="protobuf")this._transport.binaryType="arraybuffer";this._transport.onopen=()=>{J.onOpen()},this._transport.onerror=(Y)=>{J.onError(Y)},this._transport.onclose=(Y)=>{J.onClose(Y)},this._transport.onmessage=(Y)=>{J.onMessage(Y.data)}}close(){this._transport.close()}send(Z){this._transport.send(Z)}}class nW{constructor(Z,J){this.endpoint=Z,this.options=J,this._abortController=null,this._utf8decoder=new TextDecoder,this._protocol="json"}name(){return"http_stream"}subName(){return"http_stream"}emulation(){return!0}_handleErrors(Z){if(!Z.ok)throw Error(Z.status);return Z}_fetchEventTarget(Z,J,X){let Y=new EventTarget,G=Z.options.fetch;return G(J,X).then(Z._handleErrors).then((W)=>{Y.dispatchEvent(new Event("open"));let H="",Q=0,K=new Uint8Array,U=W.body.getReader();return new Z.options.readableStream({start($){function L(){return U.read().then(({done:z,value:B})=>{if(z){Y.dispatchEvent(new Event("close")),$.close();return}try{if(Z._protocol==="json"){H+=Z._utf8decoder.decode(B);while(Q<H.length)if(H[Q]===`
|
|
22
|
+
`){let M=H.substring(0,Q);Y.dispatchEvent(new MessageEvent("message",{data:M})),H=H.substring(Q+1),Q=0}else++Q}else{let M=new Uint8Array(K.length+B.length);M.set(K),M.set(B,K.length),K=M;while(!0){let F=Z.options.decoder.decodeReply(K);if(F.ok){let D=K.slice(0,F.pos);Y.dispatchEvent(new MessageEvent("message",{data:D})),K=K.slice(F.pos);continue}break}}}catch(M){Y.dispatchEvent(new Event("error",{detail:M})),Y.dispatchEvent(new Event("close")),$.close();return}L()}).catch(function(z){Y.dispatchEvent(new Event("error",{detail:z})),Y.dispatchEvent(new Event("close")),$.close();return})}return L()}})}).catch((W)=>{Y.dispatchEvent(new Event("error",{detail:W})),Y.dispatchEvent(new Event("close"))}),Y}supported(){return this.options.fetch!==null&&this.options.readableStream!==null&&typeof TextDecoder<"u"&&typeof AbortController<"u"&&typeof EventTarget<"u"&&typeof Event<"u"&&typeof MessageEvent<"u"&&typeof Error<"u"}initialize(Z,J,X){this._protocol=Z,this._abortController=new AbortController;let Y,G;if(Z==="json")Y={Accept:"application/json","Content-Type":"application/json"},G=X;else Y={Accept:"application/octet-stream","Content-Type":"application/octet-stream"},G=X;let W={method:"POST",headers:Y,body:G,mode:"cors",credentials:"same-origin",signal:this._abortController.signal},H=this._fetchEventTarget(this,this.endpoint,W);H.addEventListener("open",()=>{J.onOpen()}),H.addEventListener("error",(Q)=>{this._abortController.abort(),J.onError(Q)}),H.addEventListener("close",()=>{this._abortController.abort(),J.onClose({code:4,reason:"connection closed"})}),H.addEventListener("message",(Q)=>{J.onMessage(Q.data)})}close(){this._abortController.abort()}send(Z,J,X){let Y,G,W={session:J,node:X,data:Z};if(this._protocol==="json")Y={"Content-Type":"application/json"},G=JSON.stringify(W);else Y={"Content-Type":"application/octet-stream"},G=this.options.encoder.encodeEmulationRequest(W);let H=this.options.fetch,Q={method:"POST",headers:Y,body:G,mode:"cors",credentials:"same-origin"};H(this.options.emulationEndpoint,Q)}}class aW{constructor(Z,J){this.endpoint=Z,this.options=J,this._protocol="json",this._transport=null,this._onClose=null}name(){return"sse"}subName(){return"sse"}emulation(){return!0}supported(){return this.options.eventsource!==null&&this.options.fetch!==null}initialize(Z,J,X){let Y;if(globalThis&&globalThis.document&&globalThis.document.baseURI)Y=new URL(this.endpoint,globalThis.document.baseURI);else Y=new URL(this.endpoint);Y.searchParams.append("cf_connect",X);let G={},W=new this.options.eventsource(Y.toString(),G);this._transport=W;let H=this;W.onopen=function(){J.onOpen()},W.onerror=function(Q){W.close(),J.onError(Q),J.onClose({code:4,reason:"connection closed"})},W.onmessage=function(Q){J.onMessage(Q.data)},H._onClose=function(){J.onClose({code:4,reason:"connection closed"})}}close(){if(this._transport.close(),this._onClose!==null)this._onClose()}send(Z,J,X){let Y={session:J,node:X,data:Z},G={"Content-Type":"application/json"},W=JSON.stringify(Y),H=this.options.fetch,Q={method:"POST",headers:G,body:W,mode:"cors",credentials:"same-origin"};H(this.options.emulationEndpoint,Q)}}class rW{constructor(Z,J){this.endpoint=Z,this.options=J,this._transport=null,this._stream=null,this._writer=null,this._utf8decoder=new TextDecoder,this._protocol="json"}name(){return"webtransport"}subName(){return"webtransport"}emulation(){return!1}supported(){return this.options.webtransport!==void 0&&this.options.webtransport!==null}initialize(Z,J){return w1(this,void 0,void 0,function*(){let X;if(globalThis&&globalThis.document&&globalThis.document.baseURI)X=new URL(this.endpoint,globalThis.document.baseURI);else X=new URL(this.endpoint);if(Z==="protobuf")X.searchParams.append("cf_protocol","protobuf");this._protocol=Z;let Y=new EventTarget;this._transport=new this.options.webtransport(X.toString()),this._transport.closed.then(()=>{J.onClose({code:4,reason:"connection closed"})}).catch(()=>{J.onClose({code:4,reason:"connection closed"})});try{yield this._transport.ready}catch(W){this.close();return}let G;try{G=yield this._transport.createBidirectionalStream()}catch(W){this.close();return}this._stream=G,this._writer=this._stream.writable.getWriter(),Y.addEventListener("close",()=>{J.onClose({code:4,reason:"connection closed"})}),Y.addEventListener("message",(W)=>{J.onMessage(W.data)}),this._startReading(Y),J.onOpen()})}_startReading(Z){return w1(this,void 0,void 0,function*(){let J=this._stream.readable.getReader(),X="",Y=0,G=new Uint8Array;try{while(!0){let{done:W,value:H}=yield J.read();if(H.length>0)if(this._protocol==="json"){X+=this._utf8decoder.decode(H);while(Y<X.length)if(X[Y]===`
|
|
23
|
+
`){let Q=X.substring(0,Y);Z.dispatchEvent(new MessageEvent("message",{data:Q})),X=X.substring(Y+1),Y=0}else++Y}else{let Q=new Uint8Array(G.length+H.length);Q.set(G),Q.set(H,G.length),G=Q;while(!0){let K=this.options.decoder.decodeReply(G);if(K.ok){let U=G.slice(0,K.pos);Z.dispatchEvent(new MessageEvent("message",{data:U})),G=G.slice(K.pos);continue}break}}if(W)break}}catch(W){Z.dispatchEvent(new Event("close"))}})}close(){return w1(this,void 0,void 0,function*(){try{if(this._writer)yield this._writer.close();this._transport.close()}catch(Z){}})}send(Z){return w1(this,void 0,void 0,function*(){let J;if(this._protocol==="json")J=new TextEncoder().encode(Z+`
|
|
24
|
+
`);else J=Z;try{yield this._writer.write(J)}catch(X){this.close()}})}}var wN=[-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,0,1,2,3,4,5,6,7,8,9,-1,-1,-1,-1,-1,-1,-1,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,-1,-1,-1,-1,36,-1,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,-1,-1,-1,63,-1];class sW{constructor(Z){this.a=Z,this.pos=0}haveBytes(){return this.pos<this.a.length}getByte(){let Z=this.a[this.pos];if(this.pos++,this.pos>this.a.length)throw RangeError("out of bounds");return Z}getChar(){return String.fromCharCode(this.getByte())}getInt(){let Z=0,J;while(this.haveBytes()&&(J=wN[127&this.getByte()])>=0)Z=(Z<<6)+J;return this.pos--,Z>>>0}}class oW{constructor(){this.a=[]}toByteArray(Z){if(Array.isArray(Z))return this.a;return new Uint8Array(this.a)}putArray(Z,J,X){for(let Y=J;Y<X;Y++)this.a.push(Z[Y])}}function _N(Z){let J=0,X=0,Y=0,G=0,W=0,H=Z.length;while(H>=16)J=J+Z[W+0]|0,X=X+Z[W+1]|0,Y=Y+Z[W+2]|0,G=G+Z[W+3]|0,J=J+Z[W+4]|0,X=X+Z[W+5]|0,Y=Y+Z[W+6]|0,G=G+Z[W+7]|0,J=J+Z[W+8]|0,X=X+Z[W+9]|0,Y=Y+Z[W+10]|0,G=G+Z[W+11]|0,J=J+Z[W+12]|0,X=X+Z[W+13]|0,Y=Y+Z[W+14]|0,G=G+Z[W+15]|0,W+=16,H-=16;while(H>=4)J=J+Z[W+0]|0,X=X+Z[W+1]|0,Y=Y+Z[W+2]|0,G=G+Z[W+3]|0,W+=4,H-=4;switch(G=((G+(Y<<8)|0)+(X<<16)|0)+(J<<24)|0,H){case 3:G=G+(Z[W+2]<<8)|0;case 2:G=G+(Z[W+1]<<16)|0;case 1:G=G+(Z[W+0]<<24)|0}return G>>>0}function SN(Z,J){let X=0,Y=new sW(J),G=Z.length,W=J.length,H=Y.getInt();if(Y.getChar()!==`
|
|
25
|
+
`)throw Error("size integer not terminated by '\\n'");let Q=new oW;while(Y.haveBytes()){let K=Y.getInt(),U;switch(Y.getChar()){case"@":if(U=Y.getInt(),Y.haveBytes()&&Y.getChar()!==",")throw Error("copy command not terminated by ','");if(X+=K,X>H)throw Error("copy exceeds output file size");if(U+K>G)throw Error("copy extends past end of input");Q.putArray(Z,U,U+K);break;case":":if(X+=K,X>H)throw Error("insert command gives an output larger than predicted");if(K>W)throw Error("insert count exceeds size of delta");Q.putArray(Y.a,Y.pos,Y.pos+K),Y.pos+=K;break;case";":{let $=Q.toByteArray(Z);if(K!==_N($))throw Error("bad checksum");if(X!==H)throw Error("generated size does not match predicted size");return $}default:throw Error("unknown delta operator")}}throw Error("unterminated delta")}class HZ{name(){return"json"}encodeCommands(Z){return Z.map((J)=>JSON.stringify(J)).join(`
|
|
26
|
+
`)}decodeReplies(Z){return Z.trim().split(`
|
|
27
|
+
`).map((J)=>JSON.parse(J))}applyDeltaIfNeeded(Z,J){let X,Y;if(Z.delta){let G=SN(J,new TextEncoder().encode(Z.data));X=JSON.parse(new TextDecoder().decode(G)),Y=G}else X=JSON.parse(Z.data),Y=new TextEncoder().encode(Z.data);return{newData:X,newPrevValue:Y}}}var CN={headers:{},token:"",getToken:null,data:null,getData:null,debug:!1,name:"js",version:"",fetch:null,readableStream:null,websocket:null,eventsource:null,sockjs:null,sockjsOptions:{},emulationEndpoint:"/emulation",minReconnectDelay:500,maxReconnectDelay:20000,timeout:5000,maxServerPingDelay:1e4,networkEventTarget:null};class D0 extends Error{constructor(Z){super(Z);this.name=this.constructor.name}}class $5 extends lW{constructor(Z,J){super();if(this._reconnectTimeout=null,this._refreshTimeout=null,this._serverPingTimeout=null,this.state=$1.Disconnected,this._transportIsOpen=!1,this._endpoint=Z,this._emulation=!1,this._transports=[],this._currentTransportIndex=0,this._triedAllTransports=!1,this._transportWasOpen=!1,this._transport=null,this._transportId=0,this._deviceWentOffline=!1,this._transportClosed=!0,this._codec=new HZ,this._reconnecting=!1,this._reconnectTimeout=null,this._reconnectAttempts=0,this._client=null,this._session="",this._node="",this._subs={},this._serverSubs={},this._commandId=0,this._commands=[],this._batching=!1,this._refreshRequired=!1,this._refreshTimeout=null,this._callbacks={},this._token="",this._data=null,this._dispatchPromise=Promise.resolve(),this._serverPing=0,this._serverPingTimeout=null,this._sendPong=!1,this._promises={},this._promiseId=0,this._debugEnabled=!1,this._networkEventsSet=!1,this._config=Object.assign(Object.assign({},CN),J),this._configure(),this._debugEnabled)this.on("state",(X)=>{this._debug("client state",X.oldState,"->",X.newState)}),this.on("error",(X)=>{this._debug("client error",X)});else this.on("error",function(){Function.prototype()})}newSubscription(Z,J){if(this.getSubscription(Z)!==null)throw Error("Subscription to the channel "+Z+" already exists");let X=new cW(this,Z,J);return this._subs[Z]=X,X}getSubscription(Z){return this._getSub(Z)}removeSubscription(Z){if(!Z)return;if(Z.state!==j1.Unsubscribed)Z.unsubscribe();this._removeSubscription(Z)}subscriptions(){return this._subs}ready(Z){return w1(this,void 0,void 0,function*(){switch(this.state){case $1.Disconnected:throw{code:G1.clientDisconnected,message:"client disconnected"};case $1.Connected:return;default:return new Promise((J,X)=>{let Y={resolve:J,reject:X};if(Z)Y.timeout=setTimeout(()=>{X({code:G1.timeout,message:"timeout"})},Z);this._promises[this._nextPromiseId()]=Y})}})}connect(){if(this._isConnected()){this._debug("connect called when already connected");return}if(this._isConnecting()){this._debug("connect called when already connecting");return}this._debug("connect called"),this._reconnectAttempts=0,this._startConnecting()}disconnect(){this._disconnect(S6.disconnectCalled,"disconnect called",!1)}setToken(Z){this._token=Z}setData(Z){this._data=Z}setHeaders(Z){this._config.headers=Z}send(Z){return w1(this,void 0,void 0,function*(){let J={send:{data:Z}};if(yield this._methodCall(),!this._transportSendCommands([J]))throw this._createErrorObject(G1.transportWriteError,"transport write error")})}rpc(Z,J){return w1(this,void 0,void 0,function*(){let X={rpc:{method:Z,data:J}};return yield this._methodCall(),{data:(yield this._callPromise(X,(G)=>G.rpc)).data}})}publish(Z,J){return w1(this,void 0,void 0,function*(){let X={publish:{channel:Z,data:J}};return yield this._methodCall(),yield this._callPromise(X,()=>({})),{}})}history(Z,J){return w1(this,void 0,void 0,function*(){let X={history:this._getHistoryRequest(Z,J)};yield this._methodCall();let Y=yield this._callPromise(X,(W)=>W.history),G=[];if(Y.publications)for(let W=0;W<Y.publications.length;W++)G.push(this._getPublicationContext(Z,Y.publications[W]));return{publications:G,epoch:Y.epoch||"",offset:Y.offset||0}})}presence(Z){return w1(this,void 0,void 0,function*(){let J={presence:{channel:Z}};yield this._methodCall();let Y=(yield this._callPromise(J,(G)=>G.presence)).presence;for(let G in Y)if(Object.prototype.hasOwnProperty.call(Y,G)){let W=Y[G],H=W.conn_info,Q=W.chan_info;if(H)W.connInfo=H;if(Q)W.chanInfo=Q}return{clients:Y}})}presenceStats(Z){return w1(this,void 0,void 0,function*(){let J={presence_stats:{channel:Z}};yield this._methodCall();let X=yield this._callPromise(J,(Y)=>{return Y.presence_stats});return{numUsers:X.num_users,numClients:X.num_clients}})}startBatching(){this._batching=!0}stopBatching(){let Z=this;Promise.resolve().then(function(){Promise.resolve().then(function(){Z._batching=!1,Z._flush()})})}_debug(...Z){if(!this._debugEnabled)return;ON("debug",Z)}_codecName(){return this._codec.name()}_formatOverride(){return}_configure(){if(!("Promise"in globalThis))throw Error("Promise polyfill required");if(!this._endpoint)throw Error("endpoint configuration required");if(this._config.token!==null)this._token=this._config.token;if(this._config.data!==null)this._data=this._config.data;if(this._codec=new HZ,this._formatOverride(),this._config.debug===!0||typeof localStorage<"u"&&typeof localStorage.getItem==="function"&&localStorage.getItem("centrifuge.debug"))this._debugEnabled=!0;if(this._debug("config",this._config),typeof this._endpoint==="string");else if(Array.isArray(this._endpoint)){this._transports=this._endpoint,this._emulation=!0;for(let Z in this._transports)if(this._transports.hasOwnProperty(Z)){let J=this._transports[Z];if(!J.endpoint||!J.transport)throw Error("malformed transport configuration");let X=J.transport;if(["websocket","http_stream","sse","sockjs","webtransport"].indexOf(X)<0)throw Error("unsupported transport name: "+X)}}else throw Error("unsupported url configuration type: only string or array of objects are supported")}_setState(Z){if(this.state!==Z){this._reconnecting=!1;let J=this.state;return this.state=Z,this.emit("state",{newState:Z,oldState:J}),!0}return!1}_isDisconnected(){return this.state===$1.Disconnected}_isConnecting(){return this.state===$1.Connecting}_isConnected(){return this.state===$1.Connected}_nextCommandId(){return++this._commandId}_setNetworkEvents(){if(this._networkEventsSet)return;let Z=null;if(this._config.networkEventTarget!==null)Z=this._config.networkEventTarget;else if(typeof globalThis.addEventListener<"u")Z=globalThis;if(Z)Z.addEventListener("offline",()=>{if(this._debug("offline event triggered"),this.state===$1.Connected||this.state===$1.Connecting)this._disconnect(f0.transportClosed,"transport closed",!0),this._deviceWentOffline=!0}),Z.addEventListener("online",()=>{if(this._debug("online event triggered"),this.state!==$1.Connecting)return;if(this._deviceWentOffline&&!this._transportClosed)this._deviceWentOffline=!1,this._transportClosed=!0;this._clearReconnectTimeout(),this._startReconnecting()}),this._networkEventsSet=!0}_getReconnectDelay(){let Z=t9(this._reconnectAttempts,this._config.minReconnectDelay,this._config.maxReconnectDelay);return this._reconnectAttempts+=1,Z}_clearOutgoingRequests(){for(let Z in this._callbacks)if(this._callbacks.hasOwnProperty(Z)){let J=this._callbacks[Z];clearTimeout(J.timeout);let X=J.errback;if(!X)continue;X({error:this._createErrorObject(G1.connectionClosed,"connection closed")})}this._callbacks={}}_clearConnectedState(){this._client=null,this._clearServerPingTimeout(),this._clearRefreshTimeout();for(let Z in this._subs){if(!this._subs.hasOwnProperty(Z))continue;let J=this._subs[Z];if(J.state===j1.Subscribed)J._setSubscribing(s9.transportClosed,"transport closed")}for(let Z in this._serverSubs)if(this._serverSubs.hasOwnProperty(Z))this.emit("subscribing",{channel:Z})}_handleWriteError(Z){for(let J of Z){let X=J.id;if(!(X in this._callbacks))continue;let Y=this._callbacks[X];clearTimeout(this._callbacks[X].timeout),delete this._callbacks[X];let G=Y.errback;G({error:this._createErrorObject(G1.transportWriteError,"transport write error")})}}_transportSendCommands(Z){if(!Z.length)return!0;if(!this._transport)return!1;try{this._transport.send(this._codec.encodeCommands(Z),this._session,this._node)}catch(J){return this._debug("error writing commands",J),this._handleWriteError(Z),!1}return!0}_initializeTransport(){let Z;if(this._config.websocket!==null)Z=this._config.websocket;else if(!(typeof globalThis.WebSocket!=="function"&&typeof globalThis.WebSocket!=="object"))Z=globalThis.WebSocket;let J=null;if(this._config.sockjs!==null)J=this._config.sockjs;else if(typeof globalThis.SockJS<"u")J=globalThis.SockJS;let X=null;if(this._config.eventsource!==null)X=this._config.eventsource;else if(typeof globalThis.EventSource<"u")X=globalThis.EventSource;let Y=null;if(this._config.fetch!==null)Y=this._config.fetch;else if(typeof globalThis.fetch<"u")Y=globalThis.fetch;let G=null;if(this._config.readableStream!==null)G=this._config.readableStream;else if(typeof globalThis.ReadableStream<"u")G=globalThis.ReadableStream;if(!this._emulation){if(IN(this._endpoint,"http"))throw Error("Provide explicit transport endpoints configuration in case of using HTTP (i.e. using array of TransportEndpoint instead of a single string), or use ws(s):// scheme in an endpoint if you aimed using WebSocket transport");else if(this._debug("client will use websocket"),this._transport=new WZ(this._endpoint,{websocket:Z}),!this._transport.supported())throw Error("WebSocket constructor not found, make sure it is available globally or passed as a dependency in Centrifuge options")}else{if(this._currentTransportIndex>=this._transports.length)this._triedAllTransports=!0,this._currentTransportIndex=0;let z=0;while(!0){if(z>=this._transports.length)throw Error("no supported transport found");let B=this._transports[this._currentTransportIndex],M=B.transport,F=B.endpoint;if(M==="websocket"){if(this._debug("trying websocket transport"),this._transport=new WZ(F,{websocket:Z}),!this._transport.supported()){this._debug("websocket transport not available"),this._currentTransportIndex++,z++;continue}}else if(M==="webtransport"){if(this._debug("trying webtransport transport"),this._transport=new rW(F,{webtransport:globalThis.WebTransport,decoder:this._codec,encoder:this._codec}),!this._transport.supported()){this._debug("webtransport transport not available"),this._currentTransportIndex++,z++;continue}}else if(M==="http_stream"){if(this._debug("trying http_stream transport"),this._transport=new nW(F,{fetch:Y,readableStream:G,emulationEndpoint:this._config.emulationEndpoint,decoder:this._codec,encoder:this._codec}),!this._transport.supported()){this._debug("http_stream transport not available"),this._currentTransportIndex++,z++;continue}}else if(M==="sse"){if(this._debug("trying sse transport"),this._transport=new aW(F,{eventsource:X,fetch:Y,emulationEndpoint:this._config.emulationEndpoint}),!this._transport.supported()){this._debug("sse transport not available"),this._currentTransportIndex++,z++;continue}}else if(M==="sockjs"){if(this._debug("trying sockjs"),this._transport=new iW(F,{sockjs:J,sockjsOptions:this._config.sockjsOptions}),!this._transport.supported()){this._debug("sockjs transport not available"),this._currentTransportIndex++,z++;continue}}else throw Error("unknown transport "+M);break}}let W=this,H=this._transport,Q=this._nextTransportId();W._debug("id of transport",Q);let K=!1,U=[];if(this._transport.emulation()){let z=W._sendConnect(!0);U.push(z)}this._setNetworkEvents();let $=this._codec.encodeCommands(U);this._transportClosed=!1;let L;L=setTimeout(function(){H.close()},this._config.timeout),this._transport.initialize(this._codecName(),{onOpen:function(){if(L)clearTimeout(L),L=null;if(W._transportId!=Q){W._debug("open callback from non-actual transport"),H.close();return}if(K=!0,W._debug(H.subName(),"transport open"),H.emulation())return;W._transportIsOpen=!0,W._transportWasOpen=!0,W.startBatching(),W._sendConnect(!1),W._sendSubscribeCommands(),W.stopBatching(),W.emit("__centrifuge_debug:connect_frame_sent",{})},onError:function(z){if(W._transportId!=Q){W._debug("error callback from non-actual transport");return}W._debug("transport level error",z)},onClose:function(z){if(L)clearTimeout(L),L=null;if(W._transportId!=Q){W._debug("close callback from non-actual transport");return}W._debug(H.subName(),"transport closed"),W._transportClosed=!0,W._transportIsOpen=!1;let B="connection closed",M=!0,F=0;if(z&&"code"in z&&z.code)F=z.code;if(z&&z.reason)try{let D=JSON.parse(z.reason);B=D.reason,M=D.reconnect}catch(D){if(B=z.reason,F>=3500&&F<4000||F>=4500&&F<5000)M=!1}if(F<3000){if(F===1009)F=S6.messageSizeLimit,B="message size limit exceeded",M=!1;else F=f0.transportClosed,B="transport closed";if(W._emulation&&!W._transportWasOpen){if(W._currentTransportIndex++,W._currentTransportIndex>=W._transports.length)W._triedAllTransports=!0,W._currentTransportIndex=0}}else W._transportWasOpen=!0;if(W._isConnecting()&&!K)W.emit("error",{type:"transport",error:{code:G1.transportClosed,message:"transport closed"},transport:H.name()});W._reconnecting=!1,W._disconnect(F,B,M)},onMessage:function(z){W._dataReceived(z)}},$),W.emit("__centrifuge_debug:transport_initialized",{})}_sendConnect(Z){let J=this._constructConnectCommand(),X=this;return this._call(J,Z).then((Y)=>{let G=Y.reply.connect;if(X._connectResponse(G),Y.next)Y.next()},(Y)=>{if(X._connectError(Y.error),Y.next)Y.next()}),J}_startReconnecting(){if(this._debug("start reconnecting"),!this._isConnecting()){this._debug("stop reconnecting: client not in connecting state");return}if(this._reconnecting){this._debug("reconnect already in progress, return from reconnect routine");return}if(this._transportClosed===!1){this._debug("waiting for transport close");return}this._reconnecting=!0;let Z=this._token==="";if(!(this._refreshRequired||Z&&this._config.getToken!==null)){if(this._config.getData)this._config.getData().then((Y)=>{if(!this._isConnecting())return;this._data=Y,this._initializeTransport()}).catch((Y)=>this._handleGetDataError(Y));else this._initializeTransport();return}let X=this;this._getToken().then(function(Y){if(!X._isConnecting())return;if(Y==null||Y==null){X._failUnauthorized();return}if(X._token=Y,X._debug("connection token refreshed"),X._config.getData)X._config.getData().then(function(G){if(!X._isConnecting())return;X._data=G,X._initializeTransport()}).catch((G)=>X._handleGetDataError(G));else X._initializeTransport()}).catch(function(Y){if(!X._isConnecting())return;if(Y instanceof D0){X._failUnauthorized();return}X.emit("error",{type:"connectToken",error:{code:G1.clientConnectToken,message:Y!==void 0?Y.toString():""}});let G=X._getReconnectDelay();X._debug("error on getting connection token, reconnect after "+G+" milliseconds",Y),X._reconnecting=!1,X._reconnectTimeout=setTimeout(()=>{X._startReconnecting()},G)})}_handleGetDataError(Z){if(Z instanceof D0){this._failUnauthorized();return}this.emit("error",{type:"connectData",error:{code:G1.badConfiguration,message:(Z===null||Z===void 0?void 0:Z.toString())||""}});let J=this._getReconnectDelay();this._debug("error on getting connect data, reconnect after "+J+" milliseconds",Z),this._reconnecting=!1,this._reconnectTimeout=setTimeout(()=>{this._startReconnecting()},J)}_connectError(Z){if(this.state!==$1.Connecting)return;if(Z.code===109)this._refreshRequired=!0;if(Z.code<100||Z.temporary===!0||Z.code===109)this.emit("error",{type:"connect",error:Z}),this._debug("closing transport due to connect error"),this._disconnect(Z.code,Z.message,!0);else this._disconnect(Z.code,Z.message,!1)}_scheduleReconnect(){if(!this._isConnecting())return;let Z=!1;if(this._emulation&&!this._transportWasOpen&&!this._triedAllTransports)Z=!0;let J=this._getReconnectDelay();if(Z)J=0;this._debug("reconnect after "+J+" milliseconds"),this._clearReconnectTimeout(),this._reconnectTimeout=setTimeout(()=>{this._startReconnecting()},J)}_constructConnectCommand(){let Z={};if(this._token)Z.token=this._token;if(this._data)Z.data=this._data;if(this._config.name)Z.name=this._config.name;if(this._config.version)Z.version=this._config.version;if(Object.keys(this._config.headers).length>0)Z.headers=this._config.headers;let J={},X=!1;for(let Y in this._serverSubs)if(this._serverSubs.hasOwnProperty(Y)&&this._serverSubs[Y].recoverable){X=!0;let G={recover:!0};if(this._serverSubs[Y].offset)G.offset=this._serverSubs[Y].offset;if(this._serverSubs[Y].epoch)G.epoch=this._serverSubs[Y].epoch;J[Y]=G}if(X)Z.subs=J;return{connect:Z}}_getHistoryRequest(Z,J){let X={channel:Z};if(J!==void 0){if(J.since){if(X.since={offset:J.since.offset},J.since.epoch)X.since.epoch=J.since.epoch}if(J.limit!==void 0)X.limit=J.limit;if(J.reverse===!0)X.reverse=!0}return X}_methodCall(){if(this._isConnected())return Promise.resolve();return new Promise((Z,J)=>{let X=setTimeout(function(){J({code:G1.timeout,message:"timeout"})},this._config.timeout);this._promises[this._nextPromiseId()]={timeout:X,resolve:Z,reject:J}})}_callPromise(Z,J){return new Promise((X,Y)=>{this._call(Z,!1).then((G)=>{var W;let H=J(G.reply);X(H),(W=G.next)===null||W===void 0||W.call(G)},(G)=>{var W;Y(G.error),(W=G.next)===null||W===void 0||W.call(G)})})}_dataReceived(Z){if(this._serverPing>0)this._waitServerPing();let J=this._codec.decodeReplies(Z);this._dispatchPromise=this._dispatchPromise.then(()=>{let X;this._dispatchPromise=new Promise((Y)=>{X=Y}),this._dispatchSynchronized(J,X)})}_dispatchSynchronized(Z,J){let X=Promise.resolve();for(let Y in Z)if(Z.hasOwnProperty(Y))X=X.then(()=>{return this._dispatchReply(Z[Y])});X=X.then(()=>{J()})}_dispatchReply(Z){let J,X=new Promise((G)=>{J=G});if(Z===void 0||Z===null)return this._debug("dispatch: got undefined or null reply"),J(),X;let Y=Z.id;if(Y&&Y>0)this._handleReply(Z,J);else if(!Z.push)this._handleServerPing(J);else this._handlePush(Z.push,J);return X}_call(Z,J){return new Promise((X,Y)=>{if(Z.id=this._nextCommandId(),this._registerCall(Z.id,X,Y),!J)this._addCommand(Z)})}_startConnecting(){if(this._debug("start connecting"),this._setState($1.Connecting))this.emit("connecting",{code:f0.connectCalled,reason:"connect called"});this._client=null,this._startReconnecting()}_disconnect(Z,J,X){if(this._isDisconnected())return;this._transportIsOpen=!1;let Y=this.state;this._reconnecting=!1;let G={code:Z,reason:J},W=!1;if(X)W=this._setState($1.Connecting);else W=this._setState($1.Disconnected),this._rejectPromises({code:G1.clientDisconnected,message:"disconnected"});if(this._clearOutgoingRequests(),Y===$1.Connecting)this._clearReconnectTimeout();if(Y===$1.Connected)this._clearConnectedState();if(W)if(this._isConnecting())this.emit("connecting",G);else this.emit("disconnected",G);if(this._transport){this._debug("closing existing transport");let H=this._transport;this._transport=null,H.close(),this._transportClosed=!0,this._nextTransportId()}else this._debug("no transport to close");this._scheduleReconnect()}_failUnauthorized(){this._disconnect(S6.unauthorized,"unauthorized",!1)}_getToken(){if(this._debug("get connection token"),!this._config.getToken)return this.emit("error",{type:"configuration",error:{code:G1.badConfiguration,message:"token expired but no getToken function set in the configuration"}}),Promise.reject(new D0(""));return this._config.getToken({})}_refresh(){let Z=this._client,J=this;this._getToken().then(function(X){if(Z!==J._client)return;if(!X){J._failUnauthorized();return}if(J._token=X,J._debug("connection token refreshed"),!J._isConnected())return;let Y={refresh:{token:J._token}};J._call(Y,!1).then((G)=>{let W=G.reply.refresh;if(J._refreshResponse(W),G.next)G.next()},(G)=>{if(J._refreshError(G.error),G.next)G.next()})}).catch(function(X){if(!J._isConnected())return;if(X instanceof D0){J._failUnauthorized();return}J.emit("error",{type:"refreshToken",error:{code:G1.clientRefreshToken,message:X!==void 0?X.toString():""}}),J._refreshTimeout=setTimeout(()=>J._refresh(),J._getRefreshRetryDelay())})}_refreshError(Z){if(Z.code<100||Z.temporary===!0)this.emit("error",{type:"refresh",error:Z}),this._refreshTimeout=setTimeout(()=>this._refresh(),this._getRefreshRetryDelay());else this._disconnect(Z.code,Z.message,!1)}_getRefreshRetryDelay(){return t9(0,5000,1e4)}_refreshResponse(Z){if(this._refreshTimeout)clearTimeout(this._refreshTimeout),this._refreshTimeout=null;if(Z.expires)this._client=Z.client,this._refreshTimeout=setTimeout(()=>this._refresh(),e9(Z.ttl))}_removeSubscription(Z){if(Z===null)return;delete this._subs[Z.channel]}_unsubscribe(Z){if(!this._transportIsOpen)return Promise.resolve();let X={unsubscribe:{channel:Z.channel}},Y=this;return new Promise((W,H)=>{this._call(X,!1).then((Q)=>{if(W(),Q.next)Q.next()},(Q)=>{if(W(),Q.next)Q.next();Y._disconnect(f0.unsubscribeError,"unsubscribe error",!0)})})}_getSub(Z,J){if(J&&J>0){for(let Y in this._subs)if(this._subs.hasOwnProperty(Y)){let G=this._subs[Y];if(G._id===J)return G}return null}let X=this._subs[Z];if(!X)return null;return X}_isServerSub(Z){return this._serverSubs[Z]!==void 0}_sendSubscribeCommands(){let Z=[];for(let J in this._subs){if(!this._subs.hasOwnProperty(J))continue;let X=this._subs[J];if(X._inflight===!0)continue;if(X.state===j1.Subscribing){let Y=X._subscribe();if(Y)Z.push(Y)}}return Z}_connectResponse(Z){if(this._transportIsOpen=!0,this._transportWasOpen=!0,this._reconnectAttempts=0,this._refreshRequired=!1,this._isConnected())return;if(this._client=Z.client,this._setState($1.Connected),this._refreshTimeout)clearTimeout(this._refreshTimeout);if(Z.expires)this._refreshTimeout=setTimeout(()=>this._refresh(),e9(Z.ttl));this._session=Z.session,this._node=Z.node,this.startBatching(),this._sendSubscribeCommands(),this.stopBatching();let J={client:Z.client,transport:this._transport.subName()};if(Z.data)J.data=Z.data;if(this.emit("connected",J),this._resolvePromises(),this._processServerSubs(Z.subs||{}),Z.ping&&Z.ping>0)this._serverPing=Z.ping*1000,this._sendPong=Z.pong===!0,this._waitServerPing();else this._serverPing=0}_processServerSubs(Z){for(let J in Z){if(!Z.hasOwnProperty(J))continue;let X=Z[J];this._serverSubs[J]={offset:X.offset,epoch:X.epoch,recoverable:X.recoverable||!1};let Y=this._getSubscribeContext(J,X);this.emit("subscribed",Y)}for(let J in Z){if(!Z.hasOwnProperty(J))continue;let X=Z[J];if(X.recovered){let Y=X.publications;if(Y&&Y.length>0){for(let G in Y)if(Y.hasOwnProperty(G))this._handlePublication(J,Y[G])}}}for(let J in this._serverSubs){if(!this._serverSubs.hasOwnProperty(J))continue;if(!Z[J])this.emit("unsubscribed",{channel:J}),delete this._serverSubs[J]}}_clearRefreshTimeout(){if(this._refreshTimeout!==null)clearTimeout(this._refreshTimeout),this._refreshTimeout=null}_clearReconnectTimeout(){if(this._reconnectTimeout!==null)clearTimeout(this._reconnectTimeout),this._reconnectTimeout=null}_clearServerPingTimeout(){if(this._serverPingTimeout!==null)clearTimeout(this._serverPingTimeout),this._serverPingTimeout=null}_waitServerPing(){if(this._config.maxServerPingDelay===0)return;if(!this._isConnected())return;this._clearServerPingTimeout(),this._serverPingTimeout=setTimeout(()=>{if(!this._isConnected())return;this._disconnect(f0.noPing,"no ping",!0)},this._serverPing+this._config.maxServerPingDelay)}_getSubscribeContext(Z,J){let X={channel:Z,positioned:!1,recoverable:!1,wasRecovering:!1,recovered:!1,hasRecoveredPublications:!1};if(J.recovered)X.recovered=!0;if(J.positioned)X.positioned=!0;if(J.recoverable)X.recoverable=!0;if(J.was_recovering)X.wasRecovering=!0;let Y="";if("epoch"in J)Y=J.epoch;let G=0;if("offset"in J)G=J.offset;if(X.positioned||X.recoverable)X.streamPosition={offset:G,epoch:Y};if(Array.isArray(J.publications)&&J.publications.length>0)X.hasRecoveredPublications=!0;if(J.data)X.data=J.data;return X}_handleReply(Z,J){let X=Z.id;if(!(X in this._callbacks)){J();return}let Y=this._callbacks[X];if(clearTimeout(this._callbacks[X].timeout),delete this._callbacks[X],!PN(Z)){let G=Y.callback;if(!G)return;G({reply:Z,next:J})}else{let G=Y.errback;if(!G){J();return}let W={code:Z.error.code,message:Z.error.message||"",temporary:Z.error.temporary||!1};G({error:W,next:J})}}_handleJoin(Z,J,X){let Y=this._getSub(Z,X);if(!Y&&Z){if(this._isServerSub(Z)){let G={channel:Z,info:this._getJoinLeaveContext(J.info)};this.emit("join",G)}return}Y._handleJoin(J)}_handleLeave(Z,J,X){let Y=this._getSub(Z,X);if(!Y&&Z){if(this._isServerSub(Z)){let G={channel:Z,info:this._getJoinLeaveContext(J.info)};this.emit("leave",G)}return}Y._handleLeave(J)}_handleUnsubscribe(Z,J){let X=this._getSub(Z,0);if(!X&&Z){if(this._isServerSub(Z))delete this._serverSubs[Z],this.emit("unsubscribed",{channel:Z});return}if(J.code<2500)X._setUnsubscribed(J.code,J.reason,!1);else X._setSubscribing(J.code,J.reason)}_handleSubscribe(Z,J){this._serverSubs[Z]={offset:J.offset,epoch:J.epoch,recoverable:J.recoverable||!1},this.emit("subscribed",this._getSubscribeContext(Z,J))}_handleDisconnect(Z){let J=Z.code,X=!0;if(J>=3500&&J<4000||J>=4500&&J<5000)X=!1;this._disconnect(J,Z.reason,X)}_getPublicationContext(Z,J){let X={channel:Z,data:J.data};if(J.offset)X.offset=J.offset;if(J.info)X.info=this._getJoinLeaveContext(J.info);if(J.tags)X.tags=J.tags;return X}_getJoinLeaveContext(Z){let J={client:Z.client,user:Z.user},X=Z.conn_info;if(X)J.connInfo=X;let Y=Z.chan_info;if(Y)J.chanInfo=Y;return J}_handlePublication(Z,J,X){let Y=this._getSub(Z,X);if(!Y&&Z){if(this._isServerSub(Z)){let G=this._getPublicationContext(Z,J);if(this.emit("publication",G),J.offset!==void 0)this._serverSubs[Z].offset=J.offset}return}Y._handlePublication(J)}_handleMessage(Z){this.emit("message",{data:Z.data})}_handleServerPing(Z){if(this._sendPong){let J={};this._transportSendCommands([J])}Z()}_handlePush(Z,J){let{channel:X,id:Y}=Z;if(Z.pub)this._handlePublication(X,Z.pub,Y);else if(Z.message)this._handleMessage(Z.message);else if(Z.join)this._handleJoin(X,Z.join,Y);else if(Z.leave)this._handleLeave(X,Z.leave,Y);else if(Z.unsubscribe)this._handleUnsubscribe(X,Z.unsubscribe);else if(Z.subscribe)this._handleSubscribe(X,Z.subscribe);else if(Z.disconnect)this._handleDisconnect(Z.disconnect);J()}_flush(){let Z=this._commands.slice(0);this._commands=[],this._transportSendCommands(Z)}_createErrorObject(Z,J,X){let Y={code:Z,message:J};if(X)Y.temporary=!0;return Y}_registerCall(Z,J,X){this._callbacks[Z]={callback:J,errback:X,timeout:null},this._callbacks[Z].timeout=setTimeout(()=>{if(delete this._callbacks[Z],dW(X))X({error:this._createErrorObject(G1.timeout,"timeout")})},this._config.timeout)}_addCommand(Z){if(this._batching)this._commands.push(Z);else this._transportSendCommands([Z])}_nextPromiseId(){return++this._promiseId}_nextTransportId(){return++this._transportId}_resolvePromises(){for(let Z in this._promises){if(!this._promises.hasOwnProperty(Z))continue;if(this._promises[Z].timeout)clearTimeout(this._promises[Z].timeout);this._promises[Z].resolve(),delete this._promises[Z]}}_rejectPromises(Z){for(let J in this._promises){if(!this._promises.hasOwnProperty(J))continue;if(this._promises[J].timeout)clearTimeout(this._promises[J].timeout);this._promises[J].reject(Z),delete this._promises[J]}}}$5.SubscriptionState=j1;$5.State=$1;$5.UnauthorizedError=D0;async function jN(){let Z=await fetch(T1()+"api/centrifuge/gen_token");if(!Z.ok){if(Z.status===403)throw new $5.UnauthorizedError("Backend is not answering");throw Error(`Unexpected status code ${Z.status}`)}return(await Z.json()).token}var u0=()=>M7()?new $5(M7()||"",{getToken:jN}):null,xN=EN(null),t1=xN;var q0=new T7;import{useContext as kN,useEffect as gN}from"react";import{useEffect as bN,useState as tW}from"react";function J8(Z){let[J,X]=tW(null),[Y,G]=tW(!1);return bN(()=>{if(!Y)G(!0),fetch(T1()+`api/support/${Z}`,{method:"GET"}).then((W)=>W.json()).then((W)=>{X(W)})},[]),J}var hN=({children:Z})=>{let J=kN(o1),X=J8("socketIO"),Y=(G)=>{window.sid=G.sid,console.log(`SocketIO initialized: ${window.sid}`)};return gN(()=>{if(!J)return;let G=()=>{console.log("SocketIO connected")},W=(H)=>{console.log(`SocketIO disconnected: ${H}`),J.connect()};if(X)J.on("pieinit",Y),J.on("connect",G),J.on("disconnect",W),J.connect();return()=>{if(X)J.off("pieinit",Y),J.off("connect",G),J.off("disconnect",W),J.disconnect()}},[J,X]),Z},p0=hN;import{useContext as vN,useEffect as yN}from"react";var mN=({children:Z})=>{let J=vN(t1),X=J8("centrifuge");return yN(()=>{if(!J)return;let Y=()=>{console.log("Centrifuge connected")},G=(W)=>{console.log("Centrifuge disconnected:",W)};if(X)J.on("connected",Y),J.on("disconnected",G),J.connect();return()=>{if(X)J.disconnect()}},[J,X]),Z},l0=mN;import{jsxDEV as j0,Fragment as uN}from"react/jsx-dev-runtime";var fN=({children:Z,fallback:J})=>{return j0(H0,{client:q0,children:j0(s1.Provider,{value:_0,children:j0(o1.Provider,{value:m0(),children:j0(t1.Provider,{value:u0(),children:j0(n1.Provider,{value:J??j0(uN,{},void 0,!1,void 0,this),children:j0(p0,{children:j0(l0,{children:j0(V0,{children:Z},void 0,!1,void 0,this)},void 0,!1,void 0,this)},void 0,!1,void 0,this)},void 0,!1,void 0,this)},void 0,!1,void 0,this)},void 0,!1,void 0,this)},void 0,!1,void 0,this)},void 0,!1,void 0,this)},pN=fN;import{useContext as KZ,useEffect as UZ}from"react";var lN=({card:Z,data:J,children:X,useSocketioSupport:Y=!1,useCentrifugeSupport:G=!1,useMittSupport:W=!1,centrifugeChannel:H=void 0,methods:Q=void 0})=>{if(h())console.log("[PieCard] Rendering card:",Z),console.log("[PieCard] Card data:",J),console.log("[PieCard] Component name:",J?.name),console.log("[PieCard] Real-time support:",{socketio:Y,centrifuge:G,mitt:W,centrifugeChannel:H}),console.log("[PieCard] Methods:",Q?Object.keys(Q):"none"),console.log("[PieCard] Has children:",!!X);let K=KZ(o1),U=KZ(t1),$=KZ(s1);if(UZ(()=>{if(!K||!Y||!Q||!J.name){if(h()&&Y)console.log("[PieCard] Socket.IO setup skipped:",{hasSocket:!!K,useSocketioSupport:Y,hasMethods:!!Q,hasDataName:!!J?.name});return}return Object.entries(Q).forEach(([L,z])=>{let B=`pie${L}_${J.name}`;if(h())console.log(`[PieCard] Socket.IO registering event: ${B}`);K.on(B,z)}),()=>{Object.entries(Q).forEach(([L,z])=>{let B=`pie${L}_${J.name}`;if(h())console.log(`[PieCard] Socket.IO unregistering event: ${B}`);K.off(B,z)})}},[K,Q,J.name]),UZ(()=>{if(!U||!G||!H||!Q||!J.name){if(h()&&G)console.log("[PieCard] Centrifuge setup skipped:",{hasCentrifuge:!!U,useCentrifugeSupport:G,hasCentrifugeChannel:!!H,hasMethods:!!Q,hasDataName:!!J?.name});return}let L=Object.entries(Q).map(([z,B])=>{let M=`pie${z}_${J.name}_${H}`;if(h())console.log(`[PieCard] Centrifuge subscribing to channel: ${M}`);let F=U.newSubscription(M);return F.on("publication",(D)=>{if(h())console.log(`[PieCard] Centrifuge received data on ${M}:`,D.data);B(D.data)}),F.subscribe(),F});return()=>{L.forEach((z)=>{if(h())console.log("[PieCard] Centrifuge unsubscribing from channel");z.unsubscribe(),U.removeSubscription(z)})}},[U,H,Q,J.name]),UZ(()=>{if(!$||!W||!Q||!J.name){if(h()&&W)console.log("[PieCard] Mitt setup skipped:",{hasMitt:!!$,useMittSupport:W,hasMethods:!!Q,hasDataName:!!J?.name});return}return Object.entries(Q).forEach(([L,z])=>{let B=`pie${L}_${J.name}`;if(h())console.log(`[PieCard] Mitt registering event: ${B}`);$.on(B,z)}),()=>{Object.entries(Q).forEach(([L,z])=>{let B=`pie${L}_${J.name}`;if(h())console.log(`[PieCard] Mitt unregistering event: ${B}`);$.off(B,z)})}},[$,Q,J.name]),h())console.log("[PieCard] Rendering complete, returning children");return X},K0=lN;function X8(Z){if(!Z)return{};let J={...Z};if("animationName"in J&&typeof J.animationName==="object"){let X="radiumAnimation_"+Math.random().toString(36).substring(2,8);J.animationName=u9.keyframes(J.animationName,X)}return J}import{jsxDEV as $Z}from"react/jsx-dev-runtime";var dN=({data:Z,content:J,setUiAjaxConfiguration:X})=>{let{name:Y,sx:G}=Z;return $Z(K0,{card:Y,data:Z,children:$Z("div",{style:X8(G),id:Y,children:J.map((W,H)=>{return $Z(C1,{uiConfig:W,setUiAjaxConfiguration:X},`children-${H}`,!1,void 0,this)})},void 0,!1,void 0,this)},void 0,!1,void 0,this)},eW=u9(dN);import{jsxDEV as ZH}from"react/jsx-dev-runtime";var cN=({data:Z,content:J,setUiAjaxConfiguration:X})=>{let{name:Y}=Z;return ZH(K0,{card:Y,data:Z,children:J.map((G,W)=>{return ZH(C1,{uiConfig:G,setUiAjaxConfiguration:X},`children-${W}`,!1,void 0,this)})},void 0,!1,void 0,this)},JH=cN;import{useContext as XH,useEffect as iN,useRef as nN,useState as YH}from"react";import{jsxDEV as GH}from"react/jsx-dev-runtime";var aN=({data:Z,content:J})=>{let{useLoader:X,noReturn:Y,returnType:G,useSocketioSupport:W,useCentrifugeSupport:H,useMittSupport:Q,centrifugeChannel:K}=Z,U=XH(n1),[$,L]=YH(!1),[z,B]=YH(null),M=nN(J),F=XH(s1),D=(O)=>{if(O===null)L(!0);else if(L(!1),!Y)M.current=O;if(!Y)B(O)},q=(O)=>{M.current=O.content,B(O.content)},P=(O)=>{if(O===null)L(!0);else if(L(!1),!Y)for(let w of O)F.emit(w.name,w.data)};if(iN(()=>{B(J),L(!1)},[J]),!z&&X)return U;return GH(K0,{card:"AjaxGroupCard",data:Z,methods:{changeContent:q},useSocketioSupport:W,useCentrifugeSupport:H,useMittSupport:Q,centrifugeChannel:K,children:GH(C1,{uiConfig:z??M.current,setUiAjaxConfiguration:G==="events"?P:D},void 0,!1,void 0,this)},void 0,!1,void 0,this)},WH=aN;function LZ(Z=1000){return new Promise((J)=>{let X=()=>{if(typeof window.sid<"u")J(null);else setTimeout(X,Z)};X()})}var Y8=(Z,J={},X=[],Y)=>{if(h())console.log("Registering AJAX: ",Y,J,X);if(!Y||!Z){if(h())console.warn("Registration FAILED: pathname or setUiAjaxConfiguration is missing!");return()=>{}}return async(G={})=>{if(X.includes("sid"))await LZ();let W=new FormData;for(let[Q,K]of Object.entries({...J,...G}))W.append(Q,K);for(let Q of X)if(Q==="sid"){if(!window.sid)throw Error("SocketIO isn't initialized properly");W.append("sid",window.sid)}else{let K=document.getElementsByName(Q);if(!K.length){if(h())console.warn(`No input found with name ${Q}`);continue}let U=K[0];if(U instanceof HTMLInputElement)if(U.type==="file"&&U.files)Array.from(U.files).forEach(($)=>W.append(Q,$));else W.append(Q,U.value);else if(U instanceof HTMLTextAreaElement)W.append(Q,U.value)}let H=T1()+"api/ajax_content"+Y;return Z(null),await fetch(H,{method:"POST",body:W}).then(async(Q)=>{let U=(Q.headers.get("content-type")||"").includes("application/json");if(!!Q.body?.getReader&&!U){let L=Q.body.getReader(),z=new TextDecoder,B="";while(!0){let{done:M,value:F}=await L.read();if(M)break;B+=z.decode(F,{stream:!0});let D=B.split(`
|
|
28
|
+
`);B=D.pop()??"";for(let q of D){let P=q.trim();if(!P)continue;try{let O=JSON.parse(P);Z([O])}catch(O){if(h())console.warn("Failed to parse streamed line:",P)}}}if(B.trim())try{let M=JSON.parse(B);Z([M])}catch(M){if(h())console.warn("Failed to parse final streamed line:",B)}return{}}else{let L=await Q.json();return Z(L),L}}).catch((Q)=>{if(h())console.error("AJAX request failed:",Q);return Z(null),Q})}};import{useMemo as lA}from"react";var bZ=r(xZ(),1),B5=r(xZ(),1),L8=bZ.default.default||bZ.default;import{jsxDEV as B8}from"react/jsx-dev-runtime";var dA=({data:Z,setUiAjaxConfiguration:J})=>{let{name:X,title:Y,iconUrl:G,iconPosition:W,sx:H,pathname:Q,kwargs:K,depsNames:U}=Z,$=lA(()=>Y8(J,K,U,Q),[J,K,U,Q]);return B8(K0,{card:"AjaxButtonCard",data:Z,children:B8("button",{id:X,className:"box-border flex min-h-12 w-full min-w-min cursor-pointer items-center justify-center rounded-[16px] border border-[#080318] bg-white text-center font-[TTForsTrial] text-[#080318] hover:bg-neutral-300",value:X,onClick:()=>$(),style:X8(H),type:"button",children:[G&&W==="start"&&B8("img",{src:G,alt:""},void 0,!1,void 0,this),L8(Y),G&&W==="end"&&B8("img",{src:G,alt:""},void 0,!1,void 0,this)]},void 0,!0,void 0,this)},void 0,!1,void 0,this)},$2=dA;import{forwardRef as QD,useEffect as KD,useImperativeHandle as UD,useRef as $D,useState as N8}from"react";import{useRef as cA,useState as iA}from"react";import{jsxDEV as nA}from"react/jsx-dev-runtime";function kZ(Z){let[J,X]=iA(!1),Y=cA(null);return nA("textarea",{ref:Y,...Z,onKeyUp:()=>{X(!1)},onKeyDown:(Q)=>{if(Q.key==="Enter"&&Q.shiftKey){if(X(!0),Y.current){let K=window.getComputedStyle(Y.current),U=parseFloat(K.lineHeight);Y.current.style.height=Y.current.scrollHeight+U+"px"}}if(Q.key==="Backspace"){if(X(!0),Y.current){let K=window.getComputedStyle(Y.current),U=parseFloat(K.lineHeight);if(Y.current.scrollHeight>U)Y.current.style.height=Y.current.scrollHeight-U+"px"}}Z.onKeyDown&&Z.onKeyDown(Q)},onBlur:(Q)=>{X(!1),Z.onBlur&&Z.onBlur(Q)},style:{resize:J?"vertical":"none",overflowY:"auto",...Z.style}},void 0,!1,void 0,this)}import{useRef as rA,useCallback as sA}from"react";import{jsxDEV as L2}from"react/jsx-dev-runtime";var aA=()=>L2("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:"1.5",stroke:"currentColor",className:"size-5",children:L2("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M6 12L3.269 3.126A59.768 59.768 0 0121.485 12 59.77 59.77 0 013.27 20.876L5.999 12zm0 0h7.5"},void 0,!1,void 0,this)},void 0,!1,void 0,this),B2=aA;import{jsxDEV as gZ}from"react/jsx-dev-runtime";var oA=({type:Z="button",onClick:J,icons:X})=>{let Y=rA(null),G=sA(()=>{let H=Y.current;if(H)H.style.transform="scale(0.8)",setTimeout(()=>{H.style.transform="scale(1)"},600)},[]);return gZ("button",{ref:Y,type:Z,onClick:(H)=>{if(J)J(H);G()},className:"mr-1.5 rounded-md p-1 text-gray-500 ring-0 hover:bg-gray-100 disabled:opacity-40 disabled:hover:bg-transparent",style:{transition:"transform 300ms ease"},children:X.sendIcon?gZ("img",{src:X.sendIcon,alt:""},void 0,!1,void 0,this):gZ(B2,{},void 0,!1,void 0,this)},void 0,!1,void 0,this)},z2=oA;import{jsxDEV as M2}from"react/jsx-dev-runtime";var tA=()=>M2("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:"1.5",stroke:"currentColor",className:"size-5",children:M2("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M18.375 12.739l-7.693 7.693a4.5 4.5 0 01-6.364-6.364l10.94-10.94A3 3 0 1119.5 7.372L8.552 18.32m.009-.01l-.01.01m5.699-9.941l-7.81 7.81a1.5 1.5 0 002.112 2.13"},void 0,!1,void 0,this)},void 0,!1,void 0,this),F2=tA;import{jsxDEV as z8}from"react/jsx-dev-runtime";var eA=({name:Z,accept:J,fileInputRef:X,onSelectFile:Y,icons:G})=>{return z8("button",{className:"rounded-md p-1 text-gray-500 ring-0 hover:bg-gray-100 disabled:opacity-40 disabled:hover:bg-transparent",type:"button",onClick:()=>{if(X.current)X.current.click()},children:[z8("input",{name:Z+MX+"file",className:"hidden",type:"file",accept:J,ref:X,onChange:(W)=>{if(W.target.files)Y(W.target.files[0])}},void 0,!1,void 0,this),G.attachFileIcon?z8("img",{src:G.attachFileIcon,alt:""},void 0,!1,void 0,this):z8(F2,{},void 0,!1,void 0,this)]},void 0,!0,void 0,this)},N2=eA;import{jsxDEV as V2}from"react/jsx-dev-runtime";var ZD=()=>V2("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:"1.5",stroke:"currentColor",className:"size-5 text-gray-500",children:V2("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M19.5 14.25v-2.625a3.375 3.375 0 00-3.375-3.375h-1.5A1.125 1.125 0 0113.5 7.125v-1.5a3.375 3.375 0 00-3.375-3.375H8.25m2.25 0H5.625c-.621 0-1.125.504-1.125 1.125v17.25c0 .621.504 1.125 1.125 1.125h12.75c.621 0 1.125-.504 1.125-1.125V11.25a9 9 0 00-9-9z"},void 0,!1,void 0,this)},void 0,!1,void 0,this),A2=ZD;import{jsxDEV as D2}from"react/jsx-dev-runtime";var JD=()=>D2("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:"1.5",stroke:"currentColor",className:"size-5",children:D2("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M6 18L18 6M6 6l12 12"},void 0,!1,void 0,this)},void 0,!1,void 0,this),M8=JD;import{jsxDEV as m5}from"react/jsx-dev-runtime";var XD=({name:Z,selectedFile:J,onDropFile:X})=>{return m5("div",{className:"flex w-full cursor-default flex-row items-center gap-2",children:[m5(A2,{},void 0,!1,void 0,this),m5("span",{className:"flex-1",children:J.name},void 0,!1,void 0,this),m5("input",{type:"hidden",name:Z,value:""},void 0,!1,void 0,this),m5("button",{className:"rounded-md p-1 text-gray-500 ring-0 hover:bg-gray-100 disabled:opacity-40 disabled:hover:bg-transparent",type:"button",onClick:X,children:m5(M8,{},void 0,!1,void 0,this)},void 0,!1,void 0,this)]},void 0,!0,void 0,this)},q2=XD;import{jsxDEV as hZ}from"react/jsx-dev-runtime";var YD=()=>hZ("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:"1.5",stroke:"currentColor",className:"size-5",children:[hZ("path",{d:"M8 5C8 2.79086 9.79086 1 12 1C14.2091 1 16 2.79086 16 5V12C16 14.2091 14.2091 16 12 16C9.79086 16 8 14.2091 8 12V5Z"},void 0,!1,void 0,this),hZ("path",{d:"M6.25 11.8438V12C6.25 13.525 6.8558 14.9875 7.93414 16.0659C9.01247 17.1442 10.475 17.75 12 17.75C13.525 17.75 14.9875 17.1442 16.0659 16.0659C17.1442 14.9875 17.75 13.525 17.75 12V11.8438C17.75 11.2915 18.1977 10.8438 18.75 10.8438H19.25C19.8023 10.8438 20.25 11.2915 20.25 11.8437V12C20.25 14.188 19.3808 16.2865 17.8336 17.8336C16.5842 19.0831 14.9753 19.8903 13.25 20.1548V22C13.25 22.5523 12.8023 23 12.25 23H11.75C11.1977 23 10.75 22.5523 10.75 22V20.1548C9.02471 19.8903 7.41579 19.0831 6.16637 17.8336C4.61919 16.2865 3.75 14.188 3.75 12V11.8438C3.75 11.2915 4.19772 10.8438 4.75 10.8438H5.25C5.80228 10.8438 6.25 11.2915 6.25 11.8438Z"},void 0,!1,void 0,this)]},void 0,!0,void 0,this),R2=YD;import{jsxDEV as h6}from"react/jsx-dev-runtime";var GD=({isListening:Z,toggleListening:J,icons:X})=>{return h6("button",{className:"rounded-md p-1 text-gray-500 ring-0 hover:bg-gray-100 disabled:opacity-40 disabled:hover:bg-transparent",type:"button",onClick:J,children:Z?X.cancelIcon?h6("img",{src:X.cancelIcon,alt:""},void 0,!1,void 0,this):h6(M8,{},void 0,!1,void 0,this):X.voiceRecordingIcon?h6("img",{src:X.voiceRecordingIcon,alt:""},void 0,!1,void 0,this):h6(R2,{},void 0,!1,void 0,this)},void 0,!1,void 0,this)},I2=GD;import{jsxDEV as vZ}from"react/jsx-dev-runtime";var WD=({option:Z,onClickOption:J})=>{return vZ("div",{className:"flex w-fit cursor-pointer flex-row place-content-center items-center gap-1 rounded-md border border-black bg-white px-2 py-1 text-black",onClick:()=>{J(Z.title)},style:Z.sx,children:[Z.iconPosition==="start"&&vZ("img",{src:Z.iconUrl,alt:""},void 0,!1,void 0,this),Z.title,Z.iconPosition==="end"&&vZ("img",{src:Z.iconUrl,alt:""},void 0,!1,void 0,this)]},void 0,!0,void 0,this)},F8=WD;import{jsxDEV as O2}from"react/jsx-dev-runtime";var HD=({options:Z,handleOptionClick:J})=>{return O2("div",{className:"flex w-full flex-row flex-wrap justify-start gap-[5px]",children:Z.map((X,Y)=>{return O2(F8,{option:X,onClickOption:J},Y,!1,void 0,this)})},void 0,!1,void 0,this)},yZ=HD;import{jsxDEV as U0}from"react/jsx-dev-runtime";var LD=QD(({name:Z,defaultValue:J,defaultOptions:X,isArea:Y,placeholder:G,fileAccept:W,optionsPosition:H,icons:Q,handleOptionClick:K,handleSendMessage:U,sx:$},L)=>{let z=$D(null),[B,M]=N8(null),[F,D]=N8(J),[q,P]=N8(X),[O,w]=N8(!1);UD(L,()=>({clear:()=>{if(D(""),M(null),z.current)z.current.value=""},setValue:(I)=>D(I),setOptions:(I)=>P(I)})),KD(()=>{D(J)},[J]);let E=()=>{};return U0("div",{className:"flex flex-col items-center gap-[0.1rem]",id:Z+"_chat_input",style:$,children:[q&&H==="top"&&U0(yZ,{options:q,handleOptionClick:K},void 0,!1,void 0,this),U0("div",{className:"stretch relative flex size-full flex-1 flex-row items-stretch gap-3 last:mb-2 md:mx-4 md:flex-col md:last:mb-6 lg:mx-auto",children:U0("div",{className:"flex w-full grow flex-row items-center rounded-md bg-transparent",children:[B?U0(q2,{name:Z,selectedFile:B,onDropFile:()=>{if(M(null),z.current)z.current.value=""}},void 0,!1,void 0,this):!Y?U0("input",{name:Z,value:F,onChange:(I)=>D(I.target.value),onKeyDown:(I)=>{if(I.key==="Enter")I.preventDefault(),U()},tabIndex:0,placeholder:G,className:"m-0 w-full resize-none border-0 bg-transparent outline-none",style:{maxHeight:200,height:"100%",overflowY:"hidden"}},void 0,!1,void 0,this):U0(kZ,{name:Z,value:F,onChange:(I)=>D(I.target.value),onKeyDown:(I)=>{if(I.key==="Enter"&&!I.shiftKey)I.preventDefault(),U()},tabIndex:0,rows:2,placeholder:G,className:"m-0 w-full resize-none border-0 bg-transparent p-0 pl-2 pr-7 outline-none md:pl-0",style:{maxHeight:200,height:"100%",minHeight:24}},void 0,!1,void 0,this),U0(I2,{isListening:O,toggleListening:E,icons:Q},void 0,!1,void 0,this),U0(N2,{name:Z,fileInputRef:z,accept:W,onSelectFile:M,icons:Q},void 0,!1,void 0,this),U0(z2,{onClick:U,icons:Q},void 0,!1,void 0,this)]},void 0,!0,void 0,this)},void 0,!1,void 0,this),q&&H==="bottom"&&U0(yZ,{options:q,handleOptionClick:K},void 0,!1,void 0,this)]},void 0,!0,void 0,this)}),T2=LD;import{useState as WI,useEffect as HI}from"react";function k1(){}function V8(){}function P2(Z,J){let X=J||{};return(Z[Z.length-1]===""?[...Z,""]:Z).join((X.padRight?" ":"")+","+(X.padLeft===!1?"":" ")).trim()}var BD=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,zD=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,MD={};function A8(Z,J){return((J||MD).jsx?zD:BD).test(Z)}var FD=/[ \t\n\f\r]/g;function mZ(Z){return typeof Z==="object"?Z.type==="text"?w2(Z.value):!1:w2(Z)}function w2(Z){return Z.replace(FD,"")===""}class i0{constructor(Z,J,X){if(this.normal=J,this.property=Z,X)this.space=X}}i0.prototype.normal={};i0.prototype.property={};i0.prototype.space=void 0;function fZ(Z,J){let X={},Y={};for(let G of Z)Object.assign(X,G.property),Object.assign(Y,G.normal);return new i0(X,Y,J)}function v6(Z){return Z.toLowerCase()}class q1{constructor(Z,J){this.attribute=J,this.property=Z}}q1.prototype.attribute="";q1.prototype.booleanish=!1;q1.prototype.boolean=!1;q1.prototype.commaOrSpaceSeparated=!1;q1.prototype.commaSeparated=!1;q1.prototype.defined=!1;q1.prototype.mustUseProperty=!1;q1.prototype.number=!1;q1.prototype.overloadedBoolean=!1;q1.prototype.property="";q1.prototype.spaceSeparated=!1;q1.prototype.space=void 0;var y6={};U9(y6,{spaceSeparated:()=>e,overloadedBoolean:()=>D8,number:()=>_,commaSeparated:()=>n0,commaOrSpaceSeparated:()=>f1,booleanish:()=>Q1,boolean:()=>f});var ND=0,f=z5(),Q1=z5(),D8=z5(),_=z5(),e=z5(),n0=z5(),f1=z5();function z5(){return 2**++ND}var uZ=Object.keys(y6);class f5 extends q1{constructor(Z,J,X,Y){let G=-1;super(Z,J);if(_2(this,"space",Y),typeof X==="number")while(++G<uZ.length){let W=uZ[G];_2(this,uZ[G],(X&y6[W])===y6[W])}}}f5.prototype.defined=!0;function _2(Z,J,X){if(X)Z[J]=X}function e1(Z){let J={},X={};for(let[Y,G]of Object.entries(Z.properties)){let W=new f5(Y,Z.transform(Z.attributes||{},Y),G,Z.space);if(Z.mustUseProperty&&Z.mustUseProperty.includes(Y))W.mustUseProperty=!0;J[Y]=W,X[v6(Y)]=Y,X[v6(W.attribute)]=Y}return new i0(J,X,Z.space)}var pZ=e1({properties:{ariaActiveDescendant:null,ariaAtomic:Q1,ariaAutoComplete:null,ariaBusy:Q1,ariaChecked:Q1,ariaColCount:_,ariaColIndex:_,ariaColSpan:_,ariaControls:e,ariaCurrent:null,ariaDescribedBy:e,ariaDetails:null,ariaDisabled:Q1,ariaDropEffect:e,ariaErrorMessage:null,ariaExpanded:Q1,ariaFlowTo:e,ariaGrabbed:Q1,ariaHasPopup:null,ariaHidden:Q1,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:e,ariaLevel:_,ariaLive:null,ariaModal:Q1,ariaMultiLine:Q1,ariaMultiSelectable:Q1,ariaOrientation:null,ariaOwns:e,ariaPlaceholder:null,ariaPosInSet:_,ariaPressed:Q1,ariaReadOnly:Q1,ariaRelevant:null,ariaRequired:Q1,ariaRoleDescription:e,ariaRowCount:_,ariaRowIndex:_,ariaRowSpan:_,ariaSelected:Q1,ariaSetSize:_,ariaSort:null,ariaValueMax:_,ariaValueMin:_,ariaValueNow:_,ariaValueText:null,role:null},transform(Z,J){return J==="role"?J:"aria-"+J.slice(4).toLowerCase()}});function q8(Z,J){return J in Z?Z[J]:J}function R8(Z,J){return q8(Z,J.toLowerCase())}var S2=e1({attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:n0,acceptCharset:e,accessKey:e,action:null,allow:null,allowFullScreen:f,allowPaymentRequest:f,allowUserMedia:f,alt:null,as:null,async:f,autoCapitalize:null,autoComplete:e,autoFocus:f,autoPlay:f,blocking:e,capture:null,charSet:null,checked:f,cite:null,className:e,cols:_,colSpan:null,content:null,contentEditable:Q1,controls:f,controlsList:e,coords:_|n0,crossOrigin:null,data:null,dateTime:null,decoding:null,default:f,defer:f,dir:null,dirName:null,disabled:f,download:D8,draggable:Q1,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:f,formTarget:null,headers:e,height:_,hidden:D8,high:_,href:null,hrefLang:null,htmlFor:e,httpEquiv:e,id:null,imageSizes:null,imageSrcSet:null,inert:f,inputMode:null,integrity:null,is:null,isMap:f,itemId:null,itemProp:e,itemRef:e,itemScope:f,itemType:e,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:f,low:_,manifest:null,max:null,maxLength:_,media:null,method:null,min:null,minLength:_,multiple:f,muted:f,name:null,nonce:null,noModule:f,noValidate:f,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:f,optimum:_,pattern:null,ping:e,placeholder:null,playsInline:f,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:f,referrerPolicy:null,rel:e,required:f,reversed:f,rows:_,rowSpan:_,sandbox:e,scope:null,scoped:f,seamless:f,selected:f,shadowRootClonable:f,shadowRootDelegatesFocus:f,shadowRootMode:null,shape:null,size:_,sizes:null,slot:null,span:_,spellCheck:Q1,src:null,srcDoc:null,srcLang:null,srcSet:null,start:_,step:null,style:null,tabIndex:_,target:null,title:null,translate:null,type:null,typeMustMatch:f,useMap:null,value:Q1,width:_,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:e,axis:null,background:null,bgColor:null,border:_,borderColor:null,bottomMargin:_,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:f,declare:f,event:null,face:null,frame:null,frameBorder:null,hSpace:_,leftMargin:_,link:null,longDesc:null,lowSrc:null,marginHeight:_,marginWidth:_,noResize:f,noHref:f,noShade:f,noWrap:f,object:null,profile:null,prompt:null,rev:null,rightMargin:_,rules:null,scheme:null,scrolling:Q1,standby:null,summary:null,text:null,topMargin:_,valueType:null,version:null,vAlign:null,vLink:null,vSpace:_,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:f,disableRemotePlayback:f,prefix:null,property:null,results:_,security:null,unselectable:null},space:"html",transform:R8});var C2=e1({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:f1,accentHeight:_,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:_,amplitude:_,arabicForm:null,ascent:_,attributeName:null,attributeType:null,azimuth:_,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:_,by:null,calcMode:null,capHeight:_,className:e,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:_,diffuseConstant:_,direction:null,display:null,dur:null,divisor:_,dominantBaseline:null,download:f,dx:null,dy:null,edgeMode:null,editable:null,elevation:_,enableBackground:null,end:null,event:null,exponent:_,externalResourcesRequired:null,fill:null,fillOpacity:_,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:n0,g2:n0,glyphName:n0,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:_,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:_,horizOriginX:_,horizOriginY:_,id:null,ideographic:_,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:_,k:_,k1:_,k2:_,k3:_,k4:_,kernelMatrix:f1,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:_,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:_,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:_,overlineThickness:_,paintOrder:null,panose1:null,path:null,pathLength:_,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:e,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:_,pointsAtY:_,pointsAtZ:_,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:f1,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:f1,rev:f1,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:f1,requiredFeatures:f1,requiredFonts:f1,requiredFormats:f1,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:_,specularExponent:_,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:_,strikethroughThickness:_,string:null,stroke:null,strokeDashArray:f1,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:_,strokeOpacity:_,strokeWidth:null,style:null,surfaceScale:_,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:f1,tabIndex:_,tableValues:null,target:null,targetX:_,targetY:_,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:f1,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:_,underlineThickness:_,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:_,values:null,vAlphabetic:_,vMathematical:_,vectorEffect:null,vHanging:_,vIdeographic:_,version:null,vertAdvY:_,vertOriginX:_,vertOriginY:_,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:_,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null},space:"svg",transform:q8});var lZ=e1({properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null},space:"xlink",transform(Z,J){return"xlink:"+J.slice(5).toLowerCase()}});var dZ=e1({attributes:{xmlnsxlink:"xmlns:xlink"},properties:{xmlnsXLink:null,xmlns:null},space:"xmlns",transform:R8});var cZ=e1({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:"xml",transform(Z,J){return"xml:"+J.slice(3).toLowerCase()}});var iZ={classId:"classID",dataType:"datatype",itemId:"itemID",strokeDashArray:"strokeDasharray",strokeDashOffset:"strokeDashoffset",strokeLineCap:"strokeLinecap",strokeLineJoin:"strokeLinejoin",strokeMiterLimit:"strokeMiterlimit",typeOf:"typeof",xLinkActuate:"xlinkActuate",xLinkArcRole:"xlinkArcrole",xLinkHref:"xlinkHref",xLinkRole:"xlinkRole",xLinkShow:"xlinkShow",xLinkTitle:"xlinkTitle",xLinkType:"xlinkType",xmlnsXLink:"xmlnsXlink"};var VD=/[A-Z]/g,E2=/-[a-z]/g,AD=/^data[-\w.:]+$/i;function nZ(Z,J){let X=v6(J),Y=J,G=q1;if(X in Z.normal)return Z.property[Z.normal[X]];if(X.length>4&&X.slice(0,4)==="data"&&AD.test(J)){if(J.charAt(4)==="-"){let W=J.slice(5).replace(E2,qD);Y="data"+W.charAt(0).toUpperCase()+W.slice(1)}else{let W=J.slice(4);if(!E2.test(W)){let H=W.replace(VD,DD);if(H.charAt(0)!=="-")H="-"+H;J="data"+H}}G=f5}return new G(Y,J)}function DD(Z){return"-"+Z.toLowerCase()}function qD(Z){return Z.charAt(1).toUpperCase()}var j2=fZ([pZ,S2,lZ,dZ,cZ],"html"),I8=fZ([pZ,C2,lZ,dZ,cZ],"svg");function x2(Z){return Z.join(" ").trim()}var h2=r(SZ(),1);var O8=b2("end"),u5=b2("start");function b2(Z){return J;function J(X){let Y=X&&X.position&&X.position[Z]||{};if(typeof Y.line==="number"&&Y.line>0&&typeof Y.column==="number"&&Y.column>0)return{line:Y.line,column:Y.column,offset:typeof Y.offset==="number"&&Y.offset>-1?Y.offset:void 0}}}function aZ(Z){let J=u5(Z),X=O8(Z);if(J&&X)return{start:J,end:X}}function a0(Z){if(!Z||typeof Z!=="object")return"";if("position"in Z||"type"in Z)return k2(Z.position);if("start"in Z||"end"in Z)return k2(Z);if("line"in Z||"column"in Z)return rZ(Z);return""}function rZ(Z){return g2(Z&&Z.line)+":"+g2(Z&&Z.column)}function k2(Z){return rZ(Z&&Z.start)+"-"+rZ(Z&&Z.end)}function g2(Z){return Z&&typeof Z==="number"?Z:1}class L1 extends Error{constructor(Z,J,X){super();if(typeof J==="string")X=J,J=void 0;let Y="",G={},W=!1;if(J)if("line"in J&&"column"in J)G={place:J};else if("start"in J&&"end"in J)G={place:J};else if("type"in J)G={ancestors:[J],place:J.position};else G={...J};if(typeof Z==="string")Y=Z;else if(!G.cause&&Z)W=!0,Y=Z.message,G.cause=Z;if(!G.ruleId&&!G.source&&typeof X==="string"){let Q=X.indexOf(":");if(Q===-1)G.ruleId=X;else G.source=X.slice(0,Q),G.ruleId=X.slice(Q+1)}if(!G.place&&G.ancestors&&G.ancestors){let Q=G.ancestors[G.ancestors.length-1];if(Q)G.place=Q.position}let H=G.place&&"start"in G.place?G.place.start:G.place;this.ancestors=G.ancestors||void 0,this.cause=G.cause||void 0,this.column=H?H.column:void 0,this.fatal=void 0,this.file="",this.message=Y,this.line=H?H.line:void 0,this.name=a0(G.place)||"1:1",this.place=G.place||void 0,this.reason=this.message,this.ruleId=G.ruleId||void 0,this.source=G.source||void 0,this.stack=W&&G.cause&&typeof G.cause.stack==="string"?G.cause.stack:"",this.actual=void 0,this.expected=void 0,this.note=void 0,this.url=void 0}}L1.prototype.file="";L1.prototype.name="";L1.prototype.reason="";L1.prototype.message="";L1.prototype.stack="";L1.prototype.column=void 0;L1.prototype.line=void 0;L1.prototype.ancestors=void 0;L1.prototype.cause=void 0;L1.prototype.fatal=void 0;L1.prototype.place=void 0;L1.prototype.ruleId=void 0;L1.prototype.source=void 0;var sZ={}.hasOwnProperty,RD=new Map,ID=/[A-Z]/g,OD=new Set(["table","tbody","thead","tfoot","tr"]),TD=new Set(["td","th"]),v2="https://github.com/syntax-tree/hast-util-to-jsx-runtime";function oZ(Z,J){if(!J||J.Fragment===void 0)throw TypeError("Expected `Fragment` in options");let X=J.filePath||void 0,Y;if(J.development){if(typeof J.jsxDEV!=="function")throw TypeError("Expected `jsxDEV` in options when `development: true`");Y=xD(X,J.jsxDEV)}else{if(typeof J.jsx!=="function")throw TypeError("Expected `jsx` in production options");if(typeof J.jsxs!=="function")throw TypeError("Expected `jsxs` in production options");Y=jD(X,J.jsx,J.jsxs)}let G={Fragment:J.Fragment,ancestors:[],components:J.components||{},create:Y,elementAttributeNameCase:J.elementAttributeNameCase||"react",evaluater:J.createEvaluater?J.createEvaluater():void 0,filePath:X,ignoreInvalidStyle:J.ignoreInvalidStyle||!1,passKeys:J.passKeys!==!1,passNode:J.passNode||!1,schema:J.space==="svg"?I8:j2,stylePropertyNameCase:J.stylePropertyNameCase||"dom",tableCellAlignToStyle:J.tableCellAlignToStyle!==!1},W=y2(G,Z,void 0);if(W&&typeof W!=="string")return W;return G.create(Z,G.Fragment,{children:W||void 0},void 0)}function y2(Z,J,X){if(J.type==="element")return PD(Z,J,X);if(J.type==="mdxFlowExpression"||J.type==="mdxTextExpression")return wD(Z,J);if(J.type==="mdxJsxFlowElement"||J.type==="mdxJsxTextElement")return SD(Z,J,X);if(J.type==="mdxjsEsm")return _D(Z,J);if(J.type==="root")return CD(Z,J,X);if(J.type==="text")return ED(Z,J)}function PD(Z,J,X){let Y=Z.schema,G=Y;if(J.tagName.toLowerCase()==="svg"&&Y.space==="html")G=I8,Z.schema=G;Z.ancestors.push(J);let W=f2(Z,J.tagName,!1),H=bD(Z,J),Q=eZ(Z,J);if(OD.has(J.tagName))Q=Q.filter(function(K){return typeof K==="string"?!mZ(K):!0});return m2(Z,H,W,J),tZ(H,Q),Z.ancestors.pop(),Z.schema=Y,Z.create(J,W,H,X)}function wD(Z,J){if(J.data&&J.data.estree&&Z.evaluater){let Y=J.data.estree.body[0];return k1(Y.type==="ExpressionStatement"),Z.evaluater.evaluateExpression(Y.expression)}m6(Z,J.position)}function _D(Z,J){if(J.data&&J.data.estree&&Z.evaluater)return Z.evaluater.evaluateProgram(J.data.estree);m6(Z,J.position)}function SD(Z,J,X){let Y=Z.schema,G=Y;if(J.name==="svg"&&Y.space==="html")G=I8,Z.schema=G;Z.ancestors.push(J);let W=J.name===null?Z.Fragment:f2(Z,J.name,!0),H=kD(Z,J),Q=eZ(Z,J);return m2(Z,H,W,J),tZ(H,Q),Z.ancestors.pop(),Z.schema=Y,Z.create(J,W,H,X)}function CD(Z,J,X){let Y={};return tZ(Y,eZ(Z,J)),Z.create(J,Z.Fragment,Y,X)}function ED(Z,J){return J.value}function m2(Z,J,X,Y){if(typeof X!=="string"&&X!==Z.Fragment&&Z.passNode)J.node=Y}function tZ(Z,J){if(J.length>0){let X=J.length>1?J:J[0];if(X)Z.children=X}}function jD(Z,J,X){return Y;function Y(G,W,H,Q){let U=Array.isArray(H.children)?X:J;return Q?U(W,H,Q):U(W,H)}}function xD(Z,J){return X;function X(Y,G,W,H){let Q=Array.isArray(W.children),K=u5(Y);return J(G,W,H,Q,{columnNumber:K?K.column-1:void 0,fileName:Z,lineNumber:K?K.line:void 0},void 0)}}function bD(Z,J){let X={},Y,G;for(G in J.properties)if(G!=="children"&&sZ.call(J.properties,G)){let W=gD(Z,G,J.properties[G]);if(W){let[H,Q]=W;if(Z.tableCellAlignToStyle&&H==="align"&&typeof Q==="string"&&TD.has(J.tagName))Y=Q;else X[H]=Q}}if(Y){let W=X.style||(X.style={});W[Z.stylePropertyNameCase==="css"?"text-align":"textAlign"]=Y}return X}function kD(Z,J){let X={};for(let Y of J.attributes)if(Y.type==="mdxJsxExpressionAttribute")if(Y.data&&Y.data.estree&&Z.evaluater){let W=Y.data.estree.body[0];k1(W.type==="ExpressionStatement");let H=W.expression;k1(H.type==="ObjectExpression");let Q=H.properties[0];k1(Q.type==="SpreadElement"),Object.assign(X,Z.evaluater.evaluateExpression(Q.argument))}else m6(Z,J.position);else{let G=Y.name,W;if(Y.value&&typeof Y.value==="object")if(Y.value.data&&Y.value.data.estree&&Z.evaluater){let Q=Y.value.data.estree.body[0];k1(Q.type==="ExpressionStatement"),W=Z.evaluater.evaluateExpression(Q.expression)}else m6(Z,J.position);else W=Y.value===null?!0:Y.value;X[G]=W}return X}function eZ(Z,J){let X=[],Y=-1,G=Z.passKeys?new Map:RD;while(++Y<J.children.length){let W=J.children[Y],H;if(Z.passKeys){let K=W.type==="element"?W.tagName:W.type==="mdxJsxFlowElement"||W.type==="mdxJsxTextElement"?W.name:void 0;if(K){let U=G.get(K)||0;H=K+"-"+U,G.set(K,U+1)}}let Q=y2(Z,W,H);if(Q!==void 0)X.push(Q)}return X}function gD(Z,J,X){let Y=nZ(Z.schema,J);if(X===null||X===void 0||typeof X==="number"&&Number.isNaN(X))return;if(Array.isArray(X))X=Y.commaSeparated?P2(X):x2(X);if(Y.property==="style"){let G=typeof X==="object"?X:hD(Z,String(X));if(Z.stylePropertyNameCase==="css")G=vD(G);return["style",G]}return[Z.elementAttributeNameCase==="react"&&Y.space?iZ[Y.property]||Y.property:Y.attribute,X]}function hD(Z,J){try{return h2.default(J,{reactCompat:!0})}catch(X){if(Z.ignoreInvalidStyle)return{};let Y=X,G=new L1("Cannot parse `style` attribute",{ancestors:Z.ancestors,cause:Y,ruleId:"style",source:"hast-util-to-jsx-runtime"});throw G.file=Z.filePath||void 0,G.url=v2+"#cannot-parse-style-attribute",G}}function f2(Z,J,X){let Y;if(!X)Y={type:"Literal",value:J};else if(J.includes(".")){let G=J.split("."),W=-1,H;while(++W<G.length){let Q=A8(G[W])?{type:"Identifier",name:G[W]}:{type:"Literal",value:G[W]};H=H?{type:"MemberExpression",object:H,property:Q,computed:Boolean(W&&Q.type==="Literal"),optional:!1}:Q}k1(H,"always a result"),Y=H}else Y=A8(J)&&!/^[a-z]/.test(J)?{type:"Identifier",name:J}:{type:"Literal",value:J};if(Y.type==="Literal"){let G=Y.value;return sZ.call(Z.components,G)?Z.components[G]:G}if(Z.evaluater)return Z.evaluater.evaluateExpression(Y);m6(Z)}function m6(Z,J){let X=new L1("Cannot handle MDX estrees without `createEvaluater`",{ancestors:Z.ancestors,place:J,ruleId:"mdx-estree",source:"hast-util-to-jsx-runtime"});throw X.file=Z.filePath||void 0,X.url=v2+"#cannot-handle-mdx-estrees-without-createevaluater",X}function vD(Z){let J={},X;for(X in Z)if(sZ.call(Z,X))J[yD(X)]=Z[X];return J}function yD(Z){let J=Z.replace(ID,mD);if(J.slice(0,3)==="ms-")J="-"+J;return J}function mD(Z){return"-"+Z.toLowerCase()}var f6={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"]};import{Fragment as dR,jsx as cR,jsxs as iR}from"react/jsx-runtime";import{useEffect as Kf,useState as Uf}from"react";var fD={};function ZJ(Z,J){let X=J||fD,Y=typeof X.includeImageAlt==="boolean"?X.includeImageAlt:!0,G=typeof X.includeHtml==="boolean"?X.includeHtml:!0;return p2(Z,Y,G)}function p2(Z,J,X){if(uD(Z)){if("value"in Z)return Z.type==="html"&&!X?"":Z.value;if(J&&"alt"in Z&&Z.alt)return Z.alt;if("children"in Z)return u2(Z.children,J,X)}if(Array.isArray(Z))return u2(Z,J,X);return""}function u2(Z,J,X){let Y=[],G=-1;while(++G<Z.length)Y[G]=p2(Z[G],J,X);return Y.join("")}function uD(Z){return Boolean(Z&&typeof Z==="object")}var l2=document.createElement("i");function p5(Z){let J="&"+Z+";";l2.innerHTML=J;let X=l2.textContent;if(X.charCodeAt(X.length-1)===59&&Z!=="semi")return!1;return X===J?!1:X}function R1(Z,J,X,Y){let G=Z.length,W=0,H;if(J<0)J=-J>G?0:G+J;else J=J>G?G:J;if(X=X>0?X:0,Y.length<1e4)H=Array.from(Y),H.unshift(J,X),Z.splice(...H);else{if(X)Z.splice(J,X);while(W<Y.length)H=Y.slice(W,W+1e4),H.unshift(J,0),Z.splice(...H),W+=1e4,J+=1e4}}function g1(Z,J){if(Z.length>0)return R1(Z,Z.length,0,J),Z;return J}var d2={}.hasOwnProperty;function c2(Z){let J={},X=-1;while(++X<Z.length)pD(J,Z[X]);return J}function pD(Z,J){let X;for(X in J){let G=(d2.call(Z,X)?Z[X]:void 0)||(Z[X]={}),W=J[X],H;if(W)for(H in W){if(!d2.call(G,H))G[H]=[];let Q=W[H];lD(G[H],Array.isArray(Q)?Q:Q?[Q]:[])}}}function lD(Z,J){let X=-1,Y=[];while(++X<J.length)(J[X].add==="after"?Z:Y).push(J[X]);R1(Z,0,0,Y)}function T8(Z,J){let X=Number.parseInt(Z,J);if(X<9||X===11||X>13&&X<32||X>126&&X<160||X>55295&&X<57344||X>64975&&X<65008||(X&65535)===65535||(X&65535)===65534||X>1114111)return"�";return String.fromCodePoint(X)}function x0(Z){return Z.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}var i1=r0(/[A-Za-z]/),V1=r0(/[\dA-Za-z]/),i2=r0(/[#-'*+\--9=?A-Z^-~]/);function u6(Z){return Z!==null&&(Z<32||Z===127)}var p6=r0(/\d/),n2=r0(/[\dA-Fa-f]/),a2=r0(/[!-/:-@[-`{-~]/);function j(Z){return Z!==null&&Z<-2}function K1(Z){return Z!==null&&(Z<0||Z===32)}function v(Z){return Z===-2||Z===-1||Z===32}var r2=r0(/\p{P}|\p{S}/u),s2=r0(/\s/);function r0(Z){return J;function J(X){return X!==null&&X>-1&&Z.test(String.fromCharCode(X))}}function Z0(Z){let J=[],X=-1,Y=0,G=0;while(++X<Z.length){let W=Z.charCodeAt(X),H="";if(W===37&&V1(Z.charCodeAt(X+1))&&V1(Z.charCodeAt(X+2)))G=2;else if(W<128){if(!/[!#$&-;=?-Z_a-z~]/.test(String.fromCharCode(W)))H=String.fromCharCode(W)}else if(W>55295&&W<57344){let Q=Z.charCodeAt(X+1);if(W<56320&&Q>56319&&Q<57344)H=String.fromCharCode(W,Q),G=1;else H="�"}else H=String.fromCharCode(W);if(H)J.push(Z.slice(Y,X),encodeURIComponent(H)),Y=X+G+1,H="";if(G)X+=G,G=0}return J.join("")+Z.slice(Y)}function u(Z,J,X,Y){let G=Y?Y-1:Number.POSITIVE_INFINITY,W=0;return H;function H(K){if(v(K))return Z.enter(X),Q(K);return J(K)}function Q(K){if(v(K)&&W++<G)return Z.consume(K),Q;return Z.exit(X),J(K)}}var o2={tokenize:dD};function dD(Z){let J=Z.attempt(this.parser.constructs.contentInitial,Y,G),X;return J;function Y(Q){if(Q===null){Z.consume(Q);return}return Z.enter("lineEnding"),Z.consume(Q),Z.exit("lineEnding"),u(Z,J,"linePrefix")}function G(Q){return Z.enter("paragraph"),W(Q)}function W(Q){let K=Z.enter("chunkText",{contentType:"text",previous:X});if(X)X.next=K;return X=K,H(Q)}function H(Q){if(Q===null){Z.exit("chunkText"),Z.exit("paragraph"),Z.consume(Q);return}if(j(Q))return Z.consume(Q),Z.exit("chunkText"),W;return Z.consume(Q),H}}var e2={tokenize:cD},t2={tokenize:iD};function cD(Z){let J=this,X=[],Y=0,G,W,H;return Q;function Q(O){if(Y<X.length){let w=X[Y];return J.containerState=w[1],Z.attempt(w[0].continuation,K,U)(O)}return U(O)}function K(O){if(Y++,J.containerState._closeFlow){if(J.containerState._closeFlow=void 0,G)P();let w=J.events.length,E=w,I;while(E--)if(J.events[E][0]==="exit"&&J.events[E][1].type==="chunkFlow"){I=J.events[E][1].end;break}q(Y);let k=w;while(k<J.events.length)J.events[k][1].end={...I},k++;return R1(J.events,E+1,0,J.events.slice(w)),J.events.length=k,U(O)}return Q(O)}function U(O){if(Y===X.length){if(!G)return z(O);if(G.currentConstruct&&G.currentConstruct.concrete)return M(O);J.interrupt=Boolean(G.currentConstruct&&!G._gfmTableDynamicInterruptHack)}return J.containerState={},Z.check(t2,$,L)(O)}function $(O){if(G)P();return q(Y),z(O)}function L(O){return J.parser.lazy[J.now().line]=Y!==X.length,H=J.now().offset,M(O)}function z(O){return J.containerState={},Z.attempt(t2,B,M)(O)}function B(O){return Y++,X.push([J.currentConstruct,J.containerState]),z(O)}function M(O){if(O===null){if(G)P();q(0),Z.consume(O);return}return G=G||J.parser.flow(J.now()),Z.enter("chunkFlow",{_tokenizer:G,contentType:"flow",previous:W}),F(O)}function F(O){if(O===null){D(Z.exit("chunkFlow"),!0),q(0),Z.consume(O);return}if(j(O))return Z.consume(O),D(Z.exit("chunkFlow")),Y=0,J.interrupt=void 0,Q;return Z.consume(O),F}function D(O,w){let E=J.sliceStream(O);if(w)E.push(null);if(O.previous=W,W)W.next=O;if(W=O,G.defineSkip(O.start),G.write(E),J.parser.lazy[O.start.line]){let I=G.events.length;while(I--)if(G.events[I][1].start.offset<H&&(!G.events[I][1].end||G.events[I][1].end.offset>H))return;let k=J.events.length,l=k,y,a;while(l--)if(J.events[l][0]==="exit"&&J.events[l][1].type==="chunkFlow"){if(y){a=J.events[l][1].end;break}y=!0}q(Y),I=k;while(I<J.events.length)J.events[I][1].end={...a},I++;R1(J.events,l+1,0,J.events.slice(k)),J.events.length=I}}function q(O){let w=X.length;while(w-- >O){let E=X[w];J.containerState=E[1],E[0].exit.call(J,Z)}X.length=O}function P(){G.write([null]),W=void 0,G=void 0,J.containerState._closeFlow=void 0}}function iD(Z,J,X){return u(Z,Z.attempt(this.parser.constructs.document,J,X),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}function JJ(Z){if(Z===null||K1(Z)||s2(Z))return 1;if(r2(Z))return 2}function l5(Z,J,X){let Y=[],G=-1;while(++G<Z.length){let W=Z[G].resolveAll;if(W&&!Y.includes(W))J=W(J,X),Y.push(W)}return J}var l6={name:"attention",resolveAll:nD,tokenize:aD};function nD(Z,J){let X=-1,Y,G,W,H,Q,K,U,$;while(++X<Z.length)if(Z[X][0]==="enter"&&Z[X][1].type==="attentionSequence"&&Z[X][1]._close){Y=X;while(Y--)if(Z[Y][0]==="exit"&&Z[Y][1].type==="attentionSequence"&&Z[Y][1]._open&&J.sliceSerialize(Z[Y][1]).charCodeAt(0)===J.sliceSerialize(Z[X][1]).charCodeAt(0)){if((Z[Y][1]._close||Z[X][1]._open)&&(Z[X][1].end.offset-Z[X][1].start.offset)%3&&!((Z[Y][1].end.offset-Z[Y][1].start.offset+Z[X][1].end.offset-Z[X][1].start.offset)%3))continue;K=Z[Y][1].end.offset-Z[Y][1].start.offset>1&&Z[X][1].end.offset-Z[X][1].start.offset>1?2:1;let L={...Z[Y][1].end},z={...Z[X][1].start};if(ZQ(L,-K),ZQ(z,K),H={type:K>1?"strongSequence":"emphasisSequence",start:L,end:{...Z[Y][1].end}},Q={type:K>1?"strongSequence":"emphasisSequence",start:{...Z[X][1].start},end:z},W={type:K>1?"strongText":"emphasisText",start:{...Z[Y][1].end},end:{...Z[X][1].start}},G={type:K>1?"strong":"emphasis",start:{...H.start},end:{...Q.end}},Z[Y][1].end={...H.start},Z[X][1].start={...Q.end},U=[],Z[Y][1].end.offset-Z[Y][1].start.offset)U=g1(U,[["enter",Z[Y][1],J],["exit",Z[Y][1],J]]);if(U=g1(U,[["enter",G,J],["enter",H,J],["exit",H,J],["enter",W,J]]),U=g1(U,l5(J.parser.constructs.insideSpan.null,Z.slice(Y+1,X),J)),U=g1(U,[["exit",W,J],["enter",Q,J],["exit",Q,J],["exit",G,J]]),Z[X][1].end.offset-Z[X][1].start.offset)$=2,U=g1(U,[["enter",Z[X][1],J],["exit",Z[X][1],J]]);else $=0;R1(Z,Y-1,X-Y+3,U),X=Y+U.length-$-2;break}}X=-1;while(++X<Z.length)if(Z[X][1].type==="attentionSequence")Z[X][1].type="data";return Z}function aD(Z,J){let X=this.parser.constructs.attentionMarkers.null,Y=this.previous,G=JJ(Y),W;return H;function H(K){return W=K,Z.enter("attentionSequence"),Q(K)}function Q(K){if(K===W)return Z.consume(K),Q;let U=Z.exit("attentionSequence"),$=JJ(K),L=!$||$===2&&G||X.includes(K),z=!G||G===2&&$||X.includes(Y);return U._open=Boolean(W===42?L:L&&(G||!z)),U._close=Boolean(W===42?z:z&&($||!L)),J(K)}}function ZQ(Z,J){Z.column+=J,Z.offset+=J,Z._bufferIndex+=J}var XJ={name:"autolink",tokenize:rD};function rD(Z,J,X){let Y=0;return G;function G(B){return Z.enter("autolink"),Z.enter("autolinkMarker"),Z.consume(B),Z.exit("autolinkMarker"),Z.enter("autolinkProtocol"),W}function W(B){if(i1(B))return Z.consume(B),H;if(B===64)return X(B);return U(B)}function H(B){if(B===43||B===45||B===46||V1(B))return Y=1,Q(B);return U(B)}function Q(B){if(B===58)return Z.consume(B),Y=0,K;if((B===43||B===45||B===46||V1(B))&&Y++<32)return Z.consume(B),Q;return Y=0,U(B)}function K(B){if(B===62)return Z.exit("autolinkProtocol"),Z.enter("autolinkMarker"),Z.consume(B),Z.exit("autolinkMarker"),Z.exit("autolink"),J;if(B===null||B===32||B===60||u6(B))return X(B);return Z.consume(B),K}function U(B){if(B===64)return Z.consume(B),$;if(i2(B))return Z.consume(B),U;return X(B)}function $(B){return V1(B)?L(B):X(B)}function L(B){if(B===46)return Z.consume(B),Y=0,$;if(B===62)return Z.exit("autolinkProtocol").type="autolinkEmail",Z.enter("autolinkMarker"),Z.consume(B),Z.exit("autolinkMarker"),Z.exit("autolink"),J;return z(B)}function z(B){if((B===45||V1(B))&&Y++<63){let M=B===45?z:L;return Z.consume(B),M}return X(B)}}var s0={partial:!0,tokenize:sD};function sD(Z,J,X){return Y;function Y(W){return v(W)?u(Z,G,"linePrefix")(W):G(W)}function G(W){return W===null||j(W)?J(W):X(W)}}var P8={continuation:{tokenize:tD},exit:eD,name:"blockQuote",tokenize:oD};function oD(Z,J,X){let Y=this;return G;function G(H){if(H===62){let Q=Y.containerState;if(!Q.open)Z.enter("blockQuote",{_container:!0}),Q.open=!0;return Z.enter("blockQuotePrefix"),Z.enter("blockQuoteMarker"),Z.consume(H),Z.exit("blockQuoteMarker"),W}return X(H)}function W(H){if(v(H))return Z.enter("blockQuotePrefixWhitespace"),Z.consume(H),Z.exit("blockQuotePrefixWhitespace"),Z.exit("blockQuotePrefix"),J;return Z.exit("blockQuotePrefix"),J(H)}}function tD(Z,J,X){let Y=this;return G;function G(H){if(v(H))return u(Z,W,"linePrefix",Y.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(H);return W(H)}function W(H){return Z.attempt(P8,J,X)(H)}}function eD(Z){Z.exit("blockQuote")}var w8={name:"characterEscape",tokenize:Zq};function Zq(Z,J,X){return Y;function Y(W){return Z.enter("characterEscape"),Z.enter("escapeMarker"),Z.consume(W),Z.exit("escapeMarker"),G}function G(W){if(a2(W))return Z.enter("characterEscapeValue"),Z.consume(W),Z.exit("characterEscapeValue"),Z.exit("characterEscape"),J;return X(W)}}var _8={name:"characterReference",tokenize:Jq};function Jq(Z,J,X){let Y=this,G=0,W,H;return Q;function Q(L){return Z.enter("characterReference"),Z.enter("characterReferenceMarker"),Z.consume(L),Z.exit("characterReferenceMarker"),K}function K(L){if(L===35)return Z.enter("characterReferenceMarkerNumeric"),Z.consume(L),Z.exit("characterReferenceMarkerNumeric"),U;return Z.enter("characterReferenceValue"),W=31,H=V1,$(L)}function U(L){if(L===88||L===120)return Z.enter("characterReferenceMarkerHexadecimal"),Z.consume(L),Z.exit("characterReferenceMarkerHexadecimal"),Z.enter("characterReferenceValue"),W=6,H=n2,$;return Z.enter("characterReferenceValue"),W=7,H=p6,$(L)}function $(L){if(L===59&&G){let z=Z.exit("characterReferenceValue");if(H===V1&&!p5(Y.sliceSerialize(z)))return X(L);return Z.enter("characterReferenceMarker"),Z.consume(L),Z.exit("characterReferenceMarker"),Z.exit("characterReference"),J}if(H(L)&&G++<W)return Z.consume(L),$;return X(L)}}var JQ={partial:!0,tokenize:Yq},S8={concrete:!0,name:"codeFenced",tokenize:Xq};function Xq(Z,J,X){let Y=this,G={partial:!0,tokenize:E},W=0,H=0,Q;return K;function K(I){return U(I)}function U(I){let k=Y.events[Y.events.length-1];return W=k&&k[1].type==="linePrefix"?k[2].sliceSerialize(k[1],!0).length:0,Q=I,Z.enter("codeFenced"),Z.enter("codeFencedFence"),Z.enter("codeFencedFenceSequence"),$(I)}function $(I){if(I===Q)return H++,Z.consume(I),$;if(H<3)return X(I);return Z.exit("codeFencedFenceSequence"),v(I)?u(Z,L,"whitespace")(I):L(I)}function L(I){if(I===null||j(I))return Z.exit("codeFencedFence"),Y.interrupt?J(I):Z.check(JQ,F,w)(I);return Z.enter("codeFencedFenceInfo"),Z.enter("chunkString",{contentType:"string"}),z(I)}function z(I){if(I===null||j(I))return Z.exit("chunkString"),Z.exit("codeFencedFenceInfo"),L(I);if(v(I))return Z.exit("chunkString"),Z.exit("codeFencedFenceInfo"),u(Z,B,"whitespace")(I);if(I===96&&I===Q)return X(I);return Z.consume(I),z}function B(I){if(I===null||j(I))return L(I);return Z.enter("codeFencedFenceMeta"),Z.enter("chunkString",{contentType:"string"}),M(I)}function M(I){if(I===null||j(I))return Z.exit("chunkString"),Z.exit("codeFencedFenceMeta"),L(I);if(I===96&&I===Q)return X(I);return Z.consume(I),M}function F(I){return Z.attempt(G,w,D)(I)}function D(I){return Z.enter("lineEnding"),Z.consume(I),Z.exit("lineEnding"),q}function q(I){return W>0&&v(I)?u(Z,P,"linePrefix",W+1)(I):P(I)}function P(I){if(I===null||j(I))return Z.check(JQ,F,w)(I);return Z.enter("codeFlowValue"),O(I)}function O(I){if(I===null||j(I))return Z.exit("codeFlowValue"),P(I);return Z.consume(I),O}function w(I){return Z.exit("codeFenced"),J(I)}function E(I,k,l){let y=0;return a;function a(A){return I.enter("lineEnding"),I.consume(A),I.exit("lineEnding"),c}function c(A){return I.enter("codeFencedFence"),v(A)?u(I,p,"linePrefix",Y.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(A):p(A)}function p(A){if(A===Q)return I.enter("codeFencedFenceSequence"),C(A);return l(A)}function C(A){if(A===Q)return y++,I.consume(A),C;if(y>=H)return I.exit("codeFencedFenceSequence"),v(A)?u(I,g,"whitespace")(A):g(A);return l(A)}function g(A){if(A===null||j(A))return I.exit("codeFencedFence"),k(A);return l(A)}}}function Yq(Z,J,X){let Y=this;return G;function G(H){if(H===null)return X(H);return Z.enter("lineEnding"),Z.consume(H),Z.exit("lineEnding"),W}function W(H){return Y.parser.lazy[Y.now().line]?X(H):J(H)}}var d6={name:"codeIndented",tokenize:Wq},Gq={partial:!0,tokenize:Hq};function Wq(Z,J,X){let Y=this;return G;function G(U){return Z.enter("codeIndented"),u(Z,W,"linePrefix",5)(U)}function W(U){let $=Y.events[Y.events.length-1];return $&&$[1].type==="linePrefix"&&$[2].sliceSerialize($[1],!0).length>=4?H(U):X(U)}function H(U){if(U===null)return K(U);if(j(U))return Z.attempt(Gq,H,K)(U);return Z.enter("codeFlowValue"),Q(U)}function Q(U){if(U===null||j(U))return Z.exit("codeFlowValue"),H(U);return Z.consume(U),Q}function K(U){return Z.exit("codeIndented"),J(U)}}function Hq(Z,J,X){let Y=this;return G;function G(H){if(Y.parser.lazy[Y.now().line])return X(H);if(j(H))return Z.enter("lineEnding"),Z.consume(H),Z.exit("lineEnding"),G;return u(Z,W,"linePrefix",5)(H)}function W(H){let Q=Y.events[Y.events.length-1];return Q&&Q[1].type==="linePrefix"&&Q[2].sliceSerialize(Q[1],!0).length>=4?J(H):j(H)?G(H):X(H)}}var YJ={name:"codeText",previous:Kq,resolve:Qq,tokenize:Uq};function Qq(Z){let J=Z.length-4,X=3,Y,G;if((Z[X][1].type==="lineEnding"||Z[X][1].type==="space")&&(Z[J][1].type==="lineEnding"||Z[J][1].type==="space")){Y=X;while(++Y<J)if(Z[Y][1].type==="codeTextData"){Z[X][1].type="codeTextPadding",Z[J][1].type="codeTextPadding",X+=2,J-=2;break}}Y=X-1,J++;while(++Y<=J)if(G===void 0){if(Y!==J&&Z[Y][1].type!=="lineEnding")G=Y}else if(Y===J||Z[Y][1].type==="lineEnding"){if(Z[G][1].type="codeTextData",Y!==G+2)Z[G][1].end=Z[Y-1][1].end,Z.splice(G+2,Y-G-2),J-=Y-G-2,Y=G+2;G=void 0}return Z}function Kq(Z){return Z!==96||this.events[this.events.length-1][1].type==="characterEscape"}function Uq(Z,J,X){let Y=this,G=0,W,H;return Q;function Q(z){return Z.enter("codeText"),Z.enter("codeTextSequence"),K(z)}function K(z){if(z===96)return Z.consume(z),G++,K;return Z.exit("codeTextSequence"),U(z)}function U(z){if(z===null)return X(z);if(z===32)return Z.enter("space"),Z.consume(z),Z.exit("space"),U;if(z===96)return H=Z.enter("codeTextSequence"),W=0,L(z);if(j(z))return Z.enter("lineEnding"),Z.consume(z),Z.exit("lineEnding"),U;return Z.enter("codeTextData"),$(z)}function $(z){if(z===null||z===32||z===96||j(z))return Z.exit("codeTextData"),U(z);return Z.consume(z),$}function L(z){if(z===96)return Z.consume(z),W++,L;if(W===G)return Z.exit("codeTextSequence"),Z.exit("codeText"),J(z);return H.type="codeTextData",$(z)}}class GJ{constructor(Z){this.left=Z?[...Z]:[],this.right=[]}get(Z){if(Z<0||Z>=this.left.length+this.right.length)throw RangeError("Cannot access index `"+Z+"` in a splice buffer of size `"+(this.left.length+this.right.length)+"`");if(Z<this.left.length)return this.left[Z];return this.right[this.right.length-Z+this.left.length-1]}get length(){return this.left.length+this.right.length}shift(){return this.setCursor(0),this.right.pop()}slice(Z,J){let X=J===null||J===void 0?Number.POSITIVE_INFINITY:J;if(X<this.left.length)return this.left.slice(Z,X);if(Z>this.left.length)return this.right.slice(this.right.length-X+this.left.length,this.right.length-Z+this.left.length).reverse();return this.left.slice(Z).concat(this.right.slice(this.right.length-X+this.left.length).reverse())}splice(Z,J,X){let Y=J||0;this.setCursor(Math.trunc(Z));let G=this.right.splice(this.right.length-Y,Number.POSITIVE_INFINITY);if(X)c6(this.left,X);return G.reverse()}pop(){return this.setCursor(Number.POSITIVE_INFINITY),this.left.pop()}push(Z){this.setCursor(Number.POSITIVE_INFINITY),this.left.push(Z)}pushMany(Z){this.setCursor(Number.POSITIVE_INFINITY),c6(this.left,Z)}unshift(Z){this.setCursor(0),this.right.push(Z)}unshiftMany(Z){this.setCursor(0),c6(this.right,Z.reverse())}setCursor(Z){if(Z===this.left.length||Z>this.left.length&&this.right.length===0||Z<0&&this.left.length===0)return;if(Z<this.left.length){let J=this.left.splice(Z,Number.POSITIVE_INFINITY);c6(this.right,J.reverse())}else{let J=this.right.splice(this.left.length+this.right.length-Z,Number.POSITIVE_INFINITY);c6(this.left,J.reverse())}}}function c6(Z,J){let X=0;if(J.length<1e4)Z.push(...J);else while(X<J.length)Z.push(...J.slice(X,X+1e4)),X+=1e4}function C8(Z){let J={},X=-1,Y,G,W,H,Q,K,U,$=new GJ(Z);while(++X<$.length){while(X in J)X=J[X];if(Y=$.get(X),X&&Y[1].type==="chunkFlow"&&$.get(X-1)[1].type==="listItemPrefix"){if(K=Y[1]._tokenizer.events,W=0,W<K.length&&K[W][1].type==="lineEndingBlank")W+=2;if(W<K.length&&K[W][1].type==="content")while(++W<K.length){if(K[W][1].type==="content")break;if(K[W][1].type==="chunkText")K[W][1]._isInFirstContentOfListItem=!0,W++}}if(Y[0]==="enter"){if(Y[1].contentType)Object.assign(J,$q($,X)),X=J[X],U=!0}else if(Y[1]._container){W=X,G=void 0;while(W--)if(H=$.get(W),H[1].type==="lineEnding"||H[1].type==="lineEndingBlank"){if(H[0]==="enter"){if(G)$.get(G)[1].type="lineEndingBlank";H[1].type="lineEnding",G=W}}else if(H[1].type==="linePrefix"||H[1].type==="listItemIndent");else break;if(G)Y[1].end={...$.get(G)[1].start},Q=$.slice(G,X),Q.unshift(Y),$.splice(G,X-G+1,Q)}}return R1(Z,0,Number.POSITIVE_INFINITY,$.slice(0)),!U}function $q(Z,J){let X=Z.get(J)[1],Y=Z.get(J)[2],G=J-1,W=[],H=X._tokenizer;if(!H){if(H=Y.parser[X.contentType](X.start),X._contentTypeTextTrailing)H._contentTypeTextTrailing=!0}let Q=H.events,K=[],U={},$,L,z=-1,B=X,M=0,F=0,D=[F];while(B){while(Z.get(++G)[1]!==B);if(W.push(G),!B._tokenizer){if($=Y.sliceStream(B),!B.next)$.push(null);if(L)H.defineSkip(B.start);if(B._isInFirstContentOfListItem)H._gfmTasklistFirstContentOfListItem=!0;if(H.write($),B._isInFirstContentOfListItem)H._gfmTasklistFirstContentOfListItem=void 0}L=B,B=B.next}B=X;while(++z<Q.length)if(Q[z][0]==="exit"&&Q[z-1][0]==="enter"&&Q[z][1].type===Q[z-1][1].type&&Q[z][1].start.line!==Q[z][1].end.line)F=z+1,D.push(F),B._tokenizer=void 0,B.previous=void 0,B=B.next;if(H.events=[],B)B._tokenizer=void 0,B.previous=void 0;else D.pop();z=D.length;while(z--){let q=Q.slice(D[z],D[z+1]),P=W.pop();K.push([P,P+q.length-1]),Z.splice(P,2,q)}K.reverse(),z=-1;while(++z<K.length)U[M+K[z][0]]=M+K[z][1],M+=K[z][1]-K[z][0]-1;return U}var WJ={resolve:Bq,tokenize:zq},Lq={partial:!0,tokenize:Mq};function Bq(Z){return C8(Z),Z}function zq(Z,J){let X;return Y;function Y(Q){return Z.enter("content"),X=Z.enter("chunkContent",{contentType:"content"}),G(Q)}function G(Q){if(Q===null)return W(Q);if(j(Q))return Z.check(Lq,H,W)(Q);return Z.consume(Q),G}function W(Q){return Z.exit("chunkContent"),Z.exit("content"),J(Q)}function H(Q){return Z.consume(Q),Z.exit("chunkContent"),X.next=Z.enter("chunkContent",{contentType:"content",previous:X}),X=X.next,G}}function Mq(Z,J,X){let Y=this;return G;function G(H){return Z.exit("chunkContent"),Z.enter("lineEnding"),Z.consume(H),Z.exit("lineEnding"),u(Z,W,"linePrefix")}function W(H){if(H===null||j(H))return X(H);let Q=Y.events[Y.events.length-1];if(!Y.parser.constructs.disable.null.includes("codeIndented")&&Q&&Q[1].type==="linePrefix"&&Q[2].sliceSerialize(Q[1],!0).length>=4)return J(H);return Z.interrupt(Y.parser.constructs.flow,X,J)(H)}}function E8(Z,J,X,Y,G,W,H,Q,K){let U=K||Number.POSITIVE_INFINITY,$=0;return L;function L(q){if(q===60)return Z.enter(Y),Z.enter(G),Z.enter(W),Z.consume(q),Z.exit(W),z;if(q===null||q===32||q===41||u6(q))return X(q);return Z.enter(Y),Z.enter(H),Z.enter(Q),Z.enter("chunkString",{contentType:"string"}),F(q)}function z(q){if(q===62)return Z.enter(W),Z.consume(q),Z.exit(W),Z.exit(G),Z.exit(Y),J;return Z.enter(Q),Z.enter("chunkString",{contentType:"string"}),B(q)}function B(q){if(q===62)return Z.exit("chunkString"),Z.exit(Q),z(q);if(q===null||q===60||j(q))return X(q);return Z.consume(q),q===92?M:B}function M(q){if(q===60||q===62||q===92)return Z.consume(q),B;return B(q)}function F(q){if(!$&&(q===null||q===41||K1(q)))return Z.exit("chunkString"),Z.exit(Q),Z.exit(H),Z.exit(Y),J(q);if($<U&&q===40)return Z.consume(q),$++,F;if(q===41)return Z.consume(q),$--,F;if(q===null||q===32||q===40||u6(q))return X(q);return Z.consume(q),q===92?D:F}function D(q){if(q===40||q===41||q===92)return Z.consume(q),F;return F(q)}}function j8(Z,J,X,Y,G,W){let H=this,Q=0,K;return U;function U(B){return Z.enter(Y),Z.enter(G),Z.consume(B),Z.exit(G),Z.enter(W),$}function $(B){if(Q>999||B===null||B===91||B===93&&!K||B===94&&!Q&&"_hiddenFootnoteSupport"in H.parser.constructs)return X(B);if(B===93)return Z.exit(W),Z.enter(G),Z.consume(B),Z.exit(G),Z.exit(Y),J;if(j(B))return Z.enter("lineEnding"),Z.consume(B),Z.exit("lineEnding"),$;return Z.enter("chunkString",{contentType:"string"}),L(B)}function L(B){if(B===null||B===91||B===93||j(B)||Q++>999)return Z.exit("chunkString"),$(B);if(Z.consume(B),!K)K=!v(B);return B===92?z:L}function z(B){if(B===91||B===92||B===93)return Z.consume(B),Q++,L;return L(B)}}function x8(Z,J,X,Y,G,W){let H;return Q;function Q(z){if(z===34||z===39||z===40)return Z.enter(Y),Z.enter(G),Z.consume(z),Z.exit(G),H=z===40?41:z,K;return X(z)}function K(z){if(z===H)return Z.enter(G),Z.consume(z),Z.exit(G),Z.exit(Y),J;return Z.enter(W),U(z)}function U(z){if(z===H)return Z.exit(W),K(H);if(z===null)return X(z);if(j(z))return Z.enter("lineEnding"),Z.consume(z),Z.exit("lineEnding"),u(Z,U,"linePrefix");return Z.enter("chunkString",{contentType:"string"}),$(z)}function $(z){if(z===H||z===null||j(z))return Z.exit("chunkString"),U(z);return Z.consume(z),z===92?L:$}function L(z){if(z===H||z===92)return Z.consume(z),$;return $(z)}}function M5(Z,J){let X;return Y;function Y(G){if(j(G))return Z.enter("lineEnding"),Z.consume(G),Z.exit("lineEnding"),X=!0,Y;if(v(G))return u(Z,Y,X?"linePrefix":"lineSuffix")(G);return J(G)}}var HJ={name:"definition",tokenize:Nq},Fq={partial:!0,tokenize:Vq};function Nq(Z,J,X){let Y=this,G;return W;function W(B){return Z.enter("definition"),H(B)}function H(B){return j8.call(Y,Z,Q,X,"definitionLabel","definitionLabelMarker","definitionLabelString")(B)}function Q(B){if(G=x0(Y.sliceSerialize(Y.events[Y.events.length-1][1]).slice(1,-1)),B===58)return Z.enter("definitionMarker"),Z.consume(B),Z.exit("definitionMarker"),K;return X(B)}function K(B){return K1(B)?M5(Z,U)(B):U(B)}function U(B){return E8(Z,$,X,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(B)}function $(B){return Z.attempt(Fq,L,L)(B)}function L(B){return v(B)?u(Z,z,"whitespace")(B):z(B)}function z(B){if(B===null||j(B))return Z.exit("definition"),Y.parser.defined.push(G),J(B);return X(B)}}function Vq(Z,J,X){return Y;function Y(Q){return K1(Q)?M5(Z,G)(Q):X(Q)}function G(Q){return x8(Z,W,X,"definitionTitle","definitionTitleMarker","definitionTitleString")(Q)}function W(Q){return v(Q)?u(Z,H,"whitespace")(Q):H(Q)}function H(Q){return Q===null||j(Q)?J(Q):X(Q)}}var QJ={name:"hardBreakEscape",tokenize:Aq};function Aq(Z,J,X){return Y;function Y(W){return Z.enter("hardBreakEscape"),Z.consume(W),G}function G(W){if(j(W))return Z.exit("hardBreakEscape"),J(W);return X(W)}}var KJ={name:"headingAtx",resolve:Dq,tokenize:qq};function Dq(Z,J){let X=Z.length-2,Y=3,G,W;if(Z[Y][1].type==="whitespace")Y+=2;if(X-2>Y&&Z[X][1].type==="whitespace")X-=2;if(Z[X][1].type==="atxHeadingSequence"&&(Y===X-1||X-4>Y&&Z[X-2][1].type==="whitespace"))X-=Y+1===X?2:4;if(X>Y)G={type:"atxHeadingText",start:Z[Y][1].start,end:Z[X][1].end},W={type:"chunkText",start:Z[Y][1].start,end:Z[X][1].end,contentType:"text"},R1(Z,Y,X-Y+1,[["enter",G,J],["enter",W,J],["exit",W,J],["exit",G,J]]);return Z}function qq(Z,J,X){let Y=0;return G;function G($){return Z.enter("atxHeading"),W($)}function W($){return Z.enter("atxHeadingSequence"),H($)}function H($){if($===35&&Y++<6)return Z.consume($),H;if($===null||K1($))return Z.exit("atxHeadingSequence"),Q($);return X($)}function Q($){if($===35)return Z.enter("atxHeadingSequence"),K($);if($===null||j($))return Z.exit("atxHeading"),J($);if(v($))return u(Z,Q,"whitespace")($);return Z.enter("atxHeadingText"),U($)}function K($){if($===35)return Z.consume($),K;return Z.exit("atxHeadingSequence"),Q($)}function U($){if($===null||$===35||K1($))return Z.exit("atxHeadingText"),Q($);return Z.consume($),U}}var XQ=["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"],UJ=["pre","script","style","textarea"];var $J={concrete:!0,name:"htmlFlow",resolveTo:Oq,tokenize:Tq},Rq={partial:!0,tokenize:wq},Iq={partial:!0,tokenize:Pq};function Oq(Z){let J=Z.length;while(J--)if(Z[J][0]==="enter"&&Z[J][1].type==="htmlFlow")break;if(J>1&&Z[J-2][1].type==="linePrefix")Z[J][1].start=Z[J-2][1].start,Z[J+1][1].start=Z[J-2][1].start,Z.splice(J-2,2);return Z}function Tq(Z,J,X){let Y=this,G,W,H,Q,K;return U;function U(V){return $(V)}function $(V){return Z.enter("htmlFlow"),Z.enter("htmlFlowData"),Z.consume(V),L}function L(V){if(V===33)return Z.consume(V),z;if(V===47)return Z.consume(V),W=!0,F;if(V===63)return Z.consume(V),G=3,Y.interrupt?J:N;if(i1(V))return Z.consume(V),H=String.fromCharCode(V),D;return X(V)}function z(V){if(V===45)return Z.consume(V),G=2,B;if(V===91)return Z.consume(V),G=5,Q=0,M;if(i1(V))return Z.consume(V),G=4,Y.interrupt?J:N;return X(V)}function B(V){if(V===45)return Z.consume(V),Y.interrupt?J:N;return X(V)}function M(V){if(V==="CDATA[".charCodeAt(Q++)){if(Z.consume(V),Q===6)return Y.interrupt?J:p;return M}return X(V)}function F(V){if(i1(V))return Z.consume(V),H=String.fromCharCode(V),D;return X(V)}function D(V){if(V===null||V===47||V===62||K1(V)){let O1=V===47,z0=H.toLowerCase();if(!O1&&!W&&UJ.includes(z0))return G=1,Y.interrupt?J(V):p(V);if(XQ.includes(H.toLowerCase())){if(G=6,O1)return Z.consume(V),q;return Y.interrupt?J(V):p(V)}return G=7,Y.interrupt&&!Y.parser.lazy[Y.now().line]?X(V):W?P(V):O(V)}if(V===45||V1(V))return Z.consume(V),H+=String.fromCharCode(V),D;return X(V)}function q(V){if(V===62)return Z.consume(V),Y.interrupt?J:p;return X(V)}function P(V){if(v(V))return Z.consume(V),P;return a(V)}function O(V){if(V===47)return Z.consume(V),a;if(V===58||V===95||i1(V))return Z.consume(V),w;if(v(V))return Z.consume(V),O;return a(V)}function w(V){if(V===45||V===46||V===58||V===95||V1(V))return Z.consume(V),w;return E(V)}function E(V){if(V===61)return Z.consume(V),I;if(v(V))return Z.consume(V),E;return O(V)}function I(V){if(V===null||V===60||V===61||V===62||V===96)return X(V);if(V===34||V===39)return Z.consume(V),K=V,k;if(v(V))return Z.consume(V),I;return l(V)}function k(V){if(V===K)return Z.consume(V),K=null,y;if(V===null||j(V))return X(V);return Z.consume(V),k}function l(V){if(V===null||V===34||V===39||V===47||V===60||V===61||V===62||V===96||K1(V))return E(V);return Z.consume(V),l}function y(V){if(V===47||V===62||v(V))return O(V);return X(V)}function a(V){if(V===62)return Z.consume(V),c;return X(V)}function c(V){if(V===null||j(V))return p(V);if(v(V))return Z.consume(V),c;return X(V)}function p(V){if(V===45&&G===2)return Z.consume(V),o;if(V===60&&G===1)return Z.consume(V),n;if(V===62&&G===4)return Z.consume(V),M1;if(V===63&&G===3)return Z.consume(V),N;if(V===93&&G===5)return Z.consume(V),z1;if(j(V)&&(G===6||G===7))return Z.exit("htmlFlowData"),Z.check(Rq,I1,C)(V);if(V===null||j(V))return Z.exit("htmlFlowData"),C(V);return Z.consume(V),p}function C(V){return Z.check(Iq,g,I1)(V)}function g(V){return Z.enter("lineEnding"),Z.consume(V),Z.exit("lineEnding"),A}function A(V){if(V===null||j(V))return C(V);return Z.enter("htmlFlowData"),p(V)}function o(V){if(V===45)return Z.consume(V),N;return p(V)}function n(V){if(V===47)return Z.consume(V),H="",W1;return p(V)}function W1(V){if(V===62){let O1=H.toLowerCase();if(UJ.includes(O1))return Z.consume(V),M1;return p(V)}if(i1(V)&&H.length<8)return Z.consume(V),H+=String.fromCharCode(V),W1;return p(V)}function z1(V){if(V===93)return Z.consume(V),N;return p(V)}function N(V){if(V===62)return Z.consume(V),M1;if(V===45&&G===2)return Z.consume(V),N;return p(V)}function M1(V){if(V===null||j(V))return Z.exit("htmlFlowData"),I1(V);return Z.consume(V),M1}function I1(V){return Z.exit("htmlFlow"),J(V)}}function Pq(Z,J,X){let Y=this;return G;function G(H){if(j(H))return Z.enter("lineEnding"),Z.consume(H),Z.exit("lineEnding"),W;return X(H)}function W(H){return Y.parser.lazy[Y.now().line]?X(H):J(H)}}function wq(Z,J,X){return Y;function Y(G){return Z.enter("lineEnding"),Z.consume(G),Z.exit("lineEnding"),Z.attempt(s0,J,X)}}var LJ={name:"htmlText",tokenize:_q};function _q(Z,J,X){let Y=this,G,W,H;return Q;function Q(N){return Z.enter("htmlText"),Z.enter("htmlTextData"),Z.consume(N),K}function K(N){if(N===33)return Z.consume(N),U;if(N===47)return Z.consume(N),E;if(N===63)return Z.consume(N),O;if(i1(N))return Z.consume(N),l;return X(N)}function U(N){if(N===45)return Z.consume(N),$;if(N===91)return Z.consume(N),W=0,M;if(i1(N))return Z.consume(N),P;return X(N)}function $(N){if(N===45)return Z.consume(N),B;return X(N)}function L(N){if(N===null)return X(N);if(N===45)return Z.consume(N),z;if(j(N))return H=L,n(N);return Z.consume(N),L}function z(N){if(N===45)return Z.consume(N),B;return L(N)}function B(N){return N===62?o(N):N===45?z(N):L(N)}function M(N){if(N==="CDATA[".charCodeAt(W++))return Z.consume(N),W===6?F:M;return X(N)}function F(N){if(N===null)return X(N);if(N===93)return Z.consume(N),D;if(j(N))return H=F,n(N);return Z.consume(N),F}function D(N){if(N===93)return Z.consume(N),q;return F(N)}function q(N){if(N===62)return o(N);if(N===93)return Z.consume(N),q;return F(N)}function P(N){if(N===null||N===62)return o(N);if(j(N))return H=P,n(N);return Z.consume(N),P}function O(N){if(N===null)return X(N);if(N===63)return Z.consume(N),w;if(j(N))return H=O,n(N);return Z.consume(N),O}function w(N){return N===62?o(N):O(N)}function E(N){if(i1(N))return Z.consume(N),I;return X(N)}function I(N){if(N===45||V1(N))return Z.consume(N),I;return k(N)}function k(N){if(j(N))return H=k,n(N);if(v(N))return Z.consume(N),k;return o(N)}function l(N){if(N===45||V1(N))return Z.consume(N),l;if(N===47||N===62||K1(N))return y(N);return X(N)}function y(N){if(N===47)return Z.consume(N),o;if(N===58||N===95||i1(N))return Z.consume(N),a;if(j(N))return H=y,n(N);if(v(N))return Z.consume(N),y;return o(N)}function a(N){if(N===45||N===46||N===58||N===95||V1(N))return Z.consume(N),a;return c(N)}function c(N){if(N===61)return Z.consume(N),p;if(j(N))return H=c,n(N);if(v(N))return Z.consume(N),c;return y(N)}function p(N){if(N===null||N===60||N===61||N===62||N===96)return X(N);if(N===34||N===39)return Z.consume(N),G=N,C;if(j(N))return H=p,n(N);if(v(N))return Z.consume(N),p;return Z.consume(N),g}function C(N){if(N===G)return Z.consume(N),G=void 0,A;if(N===null)return X(N);if(j(N))return H=C,n(N);return Z.consume(N),C}function g(N){if(N===null||N===34||N===39||N===60||N===61||N===96)return X(N);if(N===47||N===62||K1(N))return y(N);return Z.consume(N),g}function A(N){if(N===47||N===62||K1(N))return y(N);return X(N)}function o(N){if(N===62)return Z.consume(N),Z.exit("htmlTextData"),Z.exit("htmlText"),J;return X(N)}function n(N){return Z.exit("htmlTextData"),Z.enter("lineEnding"),Z.consume(N),Z.exit("lineEnding"),W1}function W1(N){return v(N)?u(Z,z1,"linePrefix",Y.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(N):z1(N)}function z1(N){return Z.enter("htmlTextData"),H(N)}}var F5={name:"labelEnd",resolveAll:jq,resolveTo:xq,tokenize:bq},Sq={tokenize:kq},Cq={tokenize:gq},Eq={tokenize:hq};function jq(Z){let J=-1,X=[];while(++J<Z.length){let Y=Z[J][1];if(X.push(Z[J]),Y.type==="labelImage"||Y.type==="labelLink"||Y.type==="labelEnd"){let G=Y.type==="labelImage"?4:2;Y.type="data",J+=G}}if(Z.length!==X.length)R1(Z,0,Z.length,X);return Z}function xq(Z,J){let X=Z.length,Y=0,G,W,H,Q;while(X--)if(G=Z[X][1],W){if(G.type==="link"||G.type==="labelLink"&&G._inactive)break;if(Z[X][0]==="enter"&&G.type==="labelLink")G._inactive=!0}else if(H){if(Z[X][0]==="enter"&&(G.type==="labelImage"||G.type==="labelLink")&&!G._balanced){if(W=X,G.type!=="labelLink"){Y=2;break}}}else if(G.type==="labelEnd")H=X;let K={type:Z[W][1].type==="labelLink"?"link":"image",start:{...Z[W][1].start},end:{...Z[Z.length-1][1].end}},U={type:"label",start:{...Z[W][1].start},end:{...Z[H][1].end}},$={type:"labelText",start:{...Z[W+Y+2][1].end},end:{...Z[H-2][1].start}};return Q=[["enter",K,J],["enter",U,J]],Q=g1(Q,Z.slice(W+1,W+Y+3)),Q=g1(Q,[["enter",$,J]]),Q=g1(Q,l5(J.parser.constructs.insideSpan.null,Z.slice(W+Y+4,H-3),J)),Q=g1(Q,[["exit",$,J],Z[H-2],Z[H-1],["exit",U,J]]),Q=g1(Q,Z.slice(H+1)),Q=g1(Q,[["exit",K,J]]),R1(Z,W,Z.length,Q),Z}function bq(Z,J,X){let Y=this,G=Y.events.length,W,H;while(G--)if((Y.events[G][1].type==="labelImage"||Y.events[G][1].type==="labelLink")&&!Y.events[G][1]._balanced){W=Y.events[G][1];break}return Q;function Q(z){if(!W)return X(z);if(W._inactive)return L(z);return H=Y.parser.defined.includes(x0(Y.sliceSerialize({start:W.end,end:Y.now()}))),Z.enter("labelEnd"),Z.enter("labelMarker"),Z.consume(z),Z.exit("labelMarker"),Z.exit("labelEnd"),K}function K(z){if(z===40)return Z.attempt(Sq,$,H?$:L)(z);if(z===91)return Z.attempt(Cq,$,H?U:L)(z);return H?$(z):L(z)}function U(z){return Z.attempt(Eq,$,L)(z)}function $(z){return J(z)}function L(z){return W._balanced=!0,X(z)}}function kq(Z,J,X){return Y;function Y(L){return Z.enter("resource"),Z.enter("resourceMarker"),Z.consume(L),Z.exit("resourceMarker"),G}function G(L){return K1(L)?M5(Z,W)(L):W(L)}function W(L){if(L===41)return $(L);return E8(Z,H,Q,"resourceDestination","resourceDestinationLiteral","resourceDestinationLiteralMarker","resourceDestinationRaw","resourceDestinationString",32)(L)}function H(L){return K1(L)?M5(Z,K)(L):$(L)}function Q(L){return X(L)}function K(L){if(L===34||L===39||L===40)return x8(Z,U,X,"resourceTitle","resourceTitleMarker","resourceTitleString")(L);return $(L)}function U(L){return K1(L)?M5(Z,$)(L):$(L)}function $(L){if(L===41)return Z.enter("resourceMarker"),Z.consume(L),Z.exit("resourceMarker"),Z.exit("resource"),J;return X(L)}}function gq(Z,J,X){let Y=this;return G;function G(Q){return j8.call(Y,Z,W,H,"reference","referenceMarker","referenceString")(Q)}function W(Q){return Y.parser.defined.includes(x0(Y.sliceSerialize(Y.events[Y.events.length-1][1]).slice(1,-1)))?J(Q):X(Q)}function H(Q){return X(Q)}}function hq(Z,J,X){return Y;function Y(W){return Z.enter("reference"),Z.enter("referenceMarker"),Z.consume(W),Z.exit("referenceMarker"),G}function G(W){if(W===93)return Z.enter("referenceMarker"),Z.consume(W),Z.exit("referenceMarker"),Z.exit("reference"),J;return X(W)}}var BJ={name:"labelStartImage",resolveAll:F5.resolveAll,tokenize:vq};function vq(Z,J,X){let Y=this;return G;function G(Q){return Z.enter("labelImage"),Z.enter("labelImageMarker"),Z.consume(Q),Z.exit("labelImageMarker"),W}function W(Q){if(Q===91)return Z.enter("labelMarker"),Z.consume(Q),Z.exit("labelMarker"),Z.exit("labelImage"),H;return X(Q)}function H(Q){return Q===94&&"_hiddenFootnoteSupport"in Y.parser.constructs?X(Q):J(Q)}}var zJ={name:"labelStartLink",resolveAll:F5.resolveAll,tokenize:yq};function yq(Z,J,X){let Y=this;return G;function G(H){return Z.enter("labelLink"),Z.enter("labelMarker"),Z.consume(H),Z.exit("labelMarker"),Z.exit("labelLink"),W}function W(H){return H===94&&"_hiddenFootnoteSupport"in Y.parser.constructs?X(H):J(H)}}var i6={name:"lineEnding",tokenize:mq};function mq(Z,J){return X;function X(Y){return Z.enter("lineEnding"),Z.consume(Y),Z.exit("lineEnding"),u(Z,J,"linePrefix")}}var N5={name:"thematicBreak",tokenize:fq};function fq(Z,J,X){let Y=0,G;return W;function W(U){return Z.enter("thematicBreak"),H(U)}function H(U){return G=U,Q(U)}function Q(U){if(U===G)return Z.enter("thematicBreakSequence"),K(U);if(Y>=3&&(U===null||j(U)))return Z.exit("thematicBreak"),J(U);return X(U)}function K(U){if(U===G)return Z.consume(U),Y++,K;return Z.exit("thematicBreakSequence"),v(U)?u(Z,Q,"whitespace")(U):Q(U)}}var _1={continuation:{tokenize:dq},exit:iq,name:"list",tokenize:lq},uq={partial:!0,tokenize:nq},pq={partial:!0,tokenize:cq};function lq(Z,J,X){let Y=this,G=Y.events[Y.events.length-1],W=G&&G[1].type==="linePrefix"?G[2].sliceSerialize(G[1],!0).length:0,H=0;return Q;function Q(B){let M=Y.containerState.type||(B===42||B===43||B===45?"listUnordered":"listOrdered");if(M==="listUnordered"?!Y.containerState.marker||B===Y.containerState.marker:p6(B)){if(!Y.containerState.type)Y.containerState.type=M,Z.enter(M,{_container:!0});if(M==="listUnordered")return Z.enter("listItemPrefix"),B===42||B===45?Z.check(N5,X,U)(B):U(B);if(!Y.interrupt||B===49)return Z.enter("listItemPrefix"),Z.enter("listItemValue"),K(B)}return X(B)}function K(B){if(p6(B)&&++H<10)return Z.consume(B),K;if((!Y.interrupt||H<2)&&(Y.containerState.marker?B===Y.containerState.marker:B===41||B===46))return Z.exit("listItemValue"),U(B);return X(B)}function U(B){return Z.enter("listItemMarker"),Z.consume(B),Z.exit("listItemMarker"),Y.containerState.marker=Y.containerState.marker||B,Z.check(s0,Y.interrupt?X:$,Z.attempt(uq,z,L))}function $(B){return Y.containerState.initialBlankLine=!0,W++,z(B)}function L(B){if(v(B))return Z.enter("listItemPrefixWhitespace"),Z.consume(B),Z.exit("listItemPrefixWhitespace"),z;return X(B)}function z(B){return Y.containerState.size=W+Y.sliceSerialize(Z.exit("listItemPrefix"),!0).length,J(B)}}function dq(Z,J,X){let Y=this;return Y.containerState._closeFlow=void 0,Z.check(s0,G,W);function G(Q){return Y.containerState.furtherBlankLines=Y.containerState.furtherBlankLines||Y.containerState.initialBlankLine,u(Z,J,"listItemIndent",Y.containerState.size+1)(Q)}function W(Q){if(Y.containerState.furtherBlankLines||!v(Q))return Y.containerState.furtherBlankLines=void 0,Y.containerState.initialBlankLine=void 0,H(Q);return Y.containerState.furtherBlankLines=void 0,Y.containerState.initialBlankLine=void 0,Z.attempt(pq,J,H)(Q)}function H(Q){return Y.containerState._closeFlow=!0,Y.interrupt=void 0,u(Z,Z.attempt(_1,J,X),"linePrefix",Y.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(Q)}}function cq(Z,J,X){let Y=this;return u(Z,G,"listItemIndent",Y.containerState.size+1);function G(W){let H=Y.events[Y.events.length-1];return H&&H[1].type==="listItemIndent"&&H[2].sliceSerialize(H[1],!0).length===Y.containerState.size?J(W):X(W)}}function iq(Z){Z.exit(this.containerState.type)}function nq(Z,J,X){let Y=this;return u(Z,G,"listItemPrefixWhitespace",Y.parser.constructs.disable.null.includes("codeIndented")?void 0:5);function G(W){let H=Y.events[Y.events.length-1];return!v(W)&&H&&H[1].type==="listItemPrefixWhitespace"?J(W):X(W)}}var b8={name:"setextUnderline",resolveTo:aq,tokenize:rq};function aq(Z,J){let X=Z.length,Y,G,W;while(X--)if(Z[X][0]==="enter"){if(Z[X][1].type==="content"){Y=X;break}if(Z[X][1].type==="paragraph")G=X}else{if(Z[X][1].type==="content")Z.splice(X,1);if(!W&&Z[X][1].type==="definition")W=X}let H={type:"setextHeading",start:{...Z[Y][1].start},end:{...Z[Z.length-1][1].end}};if(Z[G][1].type="setextHeadingText",W)Z.splice(G,0,["enter",H,J]),Z.splice(W+1,0,["exit",Z[Y][1],J]),Z[Y][1].end={...Z[W][1].end};else Z[Y][1]=H;return Z.push(["exit",H,J]),Z}function rq(Z,J,X){let Y=this,G;return W;function W(U){let $=Y.events.length,L;while($--)if(Y.events[$][1].type!=="lineEnding"&&Y.events[$][1].type!=="linePrefix"&&Y.events[$][1].type!=="content"){L=Y.events[$][1].type==="paragraph";break}if(!Y.parser.lazy[Y.now().line]&&(Y.interrupt||L))return Z.enter("setextHeadingLine"),G=U,H(U);return X(U)}function H(U){return Z.enter("setextHeadingLineSequence"),Q(U)}function Q(U){if(U===G)return Z.consume(U),Q;return Z.exit("setextHeadingLineSequence"),v(U)?u(Z,K,"lineSuffix")(U):K(U)}function K(U){if(U===null||j(U))return Z.exit("setextHeadingLine"),J(U);return X(U)}}var YQ={tokenize:sq};function sq(Z){let J=this,X=Z.attempt(s0,Y,Z.attempt(this.parser.constructs.flowInitial,G,u(Z,Z.attempt(this.parser.constructs.flow,G,Z.attempt(WJ,G)),"linePrefix")));return X;function Y(W){if(W===null){Z.consume(W);return}return Z.enter("lineEndingBlank"),Z.consume(W),Z.exit("lineEndingBlank"),J.currentConstruct=void 0,X}function G(W){if(W===null){Z.consume(W);return}return Z.enter("lineEnding"),Z.consume(W),Z.exit("lineEnding"),J.currentConstruct=void 0,X}}var GQ={resolveAll:KQ()},WQ=QQ("string"),HQ=QQ("text");function QQ(Z){return{resolveAll:KQ(Z==="text"?oq:void 0),tokenize:J};function J(X){let Y=this,G=this.parser.constructs[Z],W=X.attempt(G,H,Q);return H;function H($){return U($)?W($):Q($)}function Q($){if($===null){X.consume($);return}return X.enter("data"),X.consume($),K}function K($){if(U($))return X.exit("data"),W($);return X.consume($),K}function U($){if($===null)return!0;let L=G[$],z=-1;if(L)while(++z<L.length){let B=L[z];if(!B.previous||B.previous.call(Y,Y.previous))return!0}return!1}}}function KQ(Z){return J;function J(X,Y){let G=-1,W;while(++G<=X.length)if(W===void 0){if(X[G]&&X[G][1].type==="data")W=G,G++}else if(!X[G]||X[G][1].type!=="data"){if(G!==W+2)X[W][1].end=X[G-1][1].end,X.splice(W+2,G-W-2),G=W+2;W=void 0}return Z?Z(X,Y):X}}function oq(Z,J){let X=0;while(++X<=Z.length)if((X===Z.length||Z[X][1].type==="lineEnding")&&Z[X-1][1].type==="data"){let Y=Z[X-1][1],G=J.sliceStream(Y),W=G.length,H=-1,Q=0,K;while(W--){let U=G[W];if(typeof U==="string"){H=U.length;while(U.charCodeAt(H-1)===32)Q++,H--;if(H)break;H=-1}else if(U===-2)K=!0,Q++;else if(U===-1);else{W++;break}}if(J._contentTypeTextTrailing&&X===Z.length)Q=0;if(Q){let U={type:X===Z.length||K||Q<2?"lineSuffix":"hardBreakTrailing",start:{_bufferIndex:W?H:Y.start._bufferIndex+H,_index:Y.start._index+W,line:Y.end.line,column:Y.end.column-Q,offset:Y.end.offset-Q},end:{...Y.end}};if(Y.end={...U.start},Y.start.offset===Y.end.offset)Object.assign(Y,U);else Z.splice(X,0,["enter",U,J],["exit",U,J]),X+=2}X++}return Z}var MJ={};U9(MJ,{text:()=>YR,string:()=>XR,insideSpan:()=>GR,flowInitial:()=>ZR,flow:()=>JR,document:()=>tq,disable:()=>HR,contentInitial:()=>eq,attentionMarkers:()=>WR});var tq={[42]:_1,[43]:_1,[45]:_1,[48]:_1,[49]:_1,[50]:_1,[51]:_1,[52]:_1,[53]:_1,[54]:_1,[55]:_1,[56]:_1,[57]:_1,[62]:P8},eq={[91]:HJ},ZR={[-2]:d6,[-1]:d6,[32]:d6},JR={[35]:KJ,[42]:N5,[45]:[b8,N5],[60]:$J,[61]:b8,[95]:N5,[96]:S8,[126]:S8},XR={[38]:_8,[92]:w8},YR={[-5]:i6,[-4]:i6,[-3]:i6,[33]:BJ,[38]:_8,[42]:l6,[60]:[XJ,LJ],[91]:zJ,[92]:[QJ,w8],[93]:F5,[95]:l6,[96]:YJ},GR={null:[l6,GQ]},WR={null:[42,95]},HR={null:[]};function UQ(Z,J,X){let Y={_bufferIndex:-1,_index:0,line:X&&X.line||1,column:X&&X.column||1,offset:X&&X.offset||0},G={},W=[],H=[],Q=[],K=!0,U={attempt:y(k),check:y(l),consume:w,enter:E,exit:I,interrupt:y(l,{interrupt:!0})},$={code:null,containerState:{},defineSkip:q,events:[],now:D,parser:Z,previous:null,sliceSerialize:M,sliceStream:F,write:B},L=J.tokenize.call($,U),z;if(J.resolveAll)W.push(J);return $;function B(C){if(H=g1(H,C),P(),H[H.length-1]!==null)return[];return a(J,0),$.events=l5(W,$.events,$),$.events}function M(C,g){return KR(F(C),g)}function F(C){return QR(H,C)}function D(){let{_bufferIndex:C,_index:g,line:A,column:o,offset:n}=Y;return{_bufferIndex:C,_index:g,line:A,column:o,offset:n}}function q(C){G[C.line]=C.column,p()}function P(){let C;while(Y._index<H.length){let g=H[Y._index];if(typeof g==="string"){if(C=Y._index,Y._bufferIndex<0)Y._bufferIndex=0;while(Y._index===C&&Y._bufferIndex<g.length)O(g.charCodeAt(Y._bufferIndex))}else O(g)}}function O(C){K=void 0,z=C,L=L(C)}function w(C){if(j(C))Y.line++,Y.column=1,Y.offset+=C===-3?2:1,p();else if(C!==-1)Y.column++,Y.offset++;if(Y._bufferIndex<0)Y._index++;else if(Y._bufferIndex++,Y._bufferIndex===H[Y._index].length)Y._bufferIndex=-1,Y._index++;$.previous=C,K=!0}function E(C,g){let A=g||{};return A.type=C,A.start=D(),$.events.push(["enter",A,$]),Q.push(A),A}function I(C){let g=Q.pop();return g.end=D(),$.events.push(["exit",g,$]),g}function k(C,g){a(C,g.from)}function l(C,g){g.restore()}function y(C,g){return A;function A(o,n,W1){let z1,N,M1,I1;return Array.isArray(o)?O1(o):("tokenize"in o)?O1([o]):V(o);function V(A1){return e5;function e5(T0){let t0=T0!==null&&A1[T0],R5=T0!==null&&A1.null,B7=[...Array.isArray(t0)?t0:t0?[t0]:[],...Array.isArray(R5)?R5:R5?[R5]:[]];return O1(B7)(T0)}}function O1(A1){if(z1=A1,N=0,A1.length===0)return W1;return z0(A1[N])}function z0(A1){return e5;function e5(T0){if(I1=c(),M1=A1,!A1.partial)$.currentConstruct=A1;if(A1.name&&$.parser.constructs.disable.null.includes(A1.name))return K9(T0);return A1.tokenize.call(g?Object.assign(Object.create($),g):$,U,L7,K9)(T0)}}function L7(A1){return K=!0,C(M1,I1),n}function K9(A1){if(K=!0,I1.restore(),++N<z1.length)return z0(z1[N]);return W1}}}function a(C,g){if(C.resolveAll&&!W.includes(C))W.push(C);if(C.resolve)R1($.events,g,$.events.length-g,C.resolve($.events.slice(g),$));if(C.resolveTo)$.events=C.resolveTo($.events,$)}function c(){let C=D(),g=$.previous,A=$.currentConstruct,o=$.events.length,n=Array.from(Q);return{from:o,restore:W1};function W1(){Y=C,$.previous=g,$.currentConstruct=A,$.events.length=o,Q=n,p()}}function p(){if(Y.line in G&&Y.column<2)Y.column=G[Y.line],Y.offset+=G[Y.line]-1}}function QR(Z,J){let X=J.start._index,Y=J.start._bufferIndex,G=J.end._index,W=J.end._bufferIndex,H;if(X===G)H=[Z[X].slice(Y,W)];else{if(H=Z.slice(X,G),Y>-1){let Q=H[0];if(typeof Q==="string")H[0]=Q.slice(Y);else H.shift()}if(W>0)H.push(Z[G].slice(0,W))}return H}function KR(Z,J){let X=-1,Y=[],G;while(++X<Z.length){let W=Z[X],H;if(typeof W==="string")H=W;else switch(W){case-5:{H="\r";break}case-4:{H=`
|
|
29
|
+
`;break}case-3:{H=`\r
|
|
30
|
+
`;break}case-2:{H=J?" ":"\t";break}case-1:{if(!J&&G)continue;H=" ";break}default:H=String.fromCharCode(W)}G=W===-2,Y.push(H)}return Y.join("")}function FJ(Z){let Y={constructs:c2([MJ,...(Z||{}).extensions||[]]),content:G(o2),defined:[],document:G(e2),flow:G(YQ),lazy:{},string:G(WQ),text:G(HQ)};return Y;function G(W){return H;function H(Q){return UQ(Y,W,Q)}}}function NJ(Z){while(!C8(Z));return Z}var $Q=/[\0\t\n\r]/g;function VJ(){let Z=1,J="",X=!0,Y;return G;function G(W,H,Q){let K=[],U,$,L,z,B;if(W=J+(typeof W==="string"?W.toString():new TextDecoder(H||void 0).decode(W)),L=0,J="",X){if(W.charCodeAt(0)===65279)L++;X=void 0}while(L<W.length){if($Q.lastIndex=L,U=$Q.exec(W),z=U&&U.index!==void 0?U.index:W.length,B=W.charCodeAt(z),!U){J=W.slice(L);break}if(B===10&&L===z&&Y)K.push(-3),Y=void 0;else{if(Y)K.push(-5),Y=void 0;if(L<z)K.push(W.slice(L,z)),Z+=z-L;switch(B){case 0:{K.push(65533),Z++;break}case 9:{$=Math.ceil(Z/4)*4,K.push(-2);while(Z++<$)K.push(-1);break}case 10:{K.push(-4),Z=1;break}default:Y=!0,Z=1}}L=z+1}if(Q){if(Y)K.push(-5);if(J)K.push(J);K.push(null)}return K}}var UR=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function LQ(Z){return Z.replace(UR,$R)}function $R(Z,J,X){if(J)return J;if(X.charCodeAt(0)===35){let G=X.charCodeAt(1),W=G===120||G===88;return T8(X.slice(W?2:1),W?16:10)}return p5(X)||Z}var zQ={}.hasOwnProperty;function AJ(Z,J,X){if(typeof J!=="string")X=J,J=void 0;return LR(X)(NJ(FJ(X).document().write(VJ()(Z,J,!0))))}function LR(Z){let J={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:W(HX),autolinkProtocol:y,autolinkEmail:y,atxHeading:W(YX),blockQuote:W(T0),characterEscape:y,characterReference:y,codeFenced:W(t0),codeFencedFenceInfo:H,codeFencedFenceMeta:H,codeIndented:W(t0,H),codeText:W(R5,H),codeTextData:y,data:y,codeFlowValue:y,definition:W(B7),definitionDestinationString:H,definitionLabelString:H,definitionTitleString:H,emphasis:W(lU),hardBreakEscape:W(GX),hardBreakTrailing:W(GX),htmlFlow:W(WX,H),htmlFlowData:y,htmlText:W(WX,H),htmlTextData:y,image:W(dU),label:H,link:W(HX),listItem:W(cU),listItemValue:z,listOrdered:W(QX,L),listUnordered:W(QX),paragraph:W(iU),reference:V,referenceString:H,resourceDestinationString:H,resourceTitleString:H,setextHeading:W(YX),strong:W(nU),thematicBreak:W(rU)},exit:{atxHeading:K(),atxHeadingSequence:E,autolink:K(),autolinkEmail:e5,autolinkProtocol:A1,blockQuote:K(),characterEscapeValue:a,characterReferenceMarkerHexadecimal:z0,characterReferenceMarkerNumeric:z0,characterReferenceValue:L7,characterReference:K9,codeFenced:K(D),codeFencedFence:F,codeFencedFenceInfo:B,codeFencedFenceMeta:M,codeFlowValue:a,codeIndented:K(q),codeText:K(A),codeTextData:a,data:a,definition:K(),definitionDestinationString:w,definitionLabelString:P,definitionTitleString:O,emphasis:K(),hardBreakEscape:K(p),hardBreakTrailing:K(p),htmlFlow:K(C),htmlFlowData:a,htmlText:K(g),htmlTextData:a,image:K(n),label:z1,labelText:W1,lineEnding:c,link:K(o),listItem:K(),listOrdered:K(),listUnordered:K(),paragraph:K(),referenceString:O1,resourceDestinationString:N,resourceTitleString:M1,resource:I1,setextHeading:K(l),setextHeadingLineSequence:k,setextHeadingText:I,strong:K(),thematicBreak:K()}};MQ(J,(Z||{}).mdastExtensions||[]);let X={};return Y;function Y(T){let S={type:"root",children:[]},m={stack:[S],tokenStack:[],config:J,enter:Q,exit:U,buffer:H,resume:$,data:X},t=[],J1=-1;while(++J1<T.length)if(T[J1][1].type==="listOrdered"||T[J1][1].type==="listUnordered")if(T[J1][0]==="enter")t.push(J1);else{let G0=t.pop();J1=G(T,G0,J1)}J1=-1;while(++J1<T.length){let G0=J[T[J1][0]];if(zQ.call(G0,T[J1][1].type))G0[T[J1][1].type].call(Object.assign({sliceSerialize:T[J1][2].sliceSerialize},m),T[J1][1])}if(m.tokenStack.length>0){let G0=m.tokenStack[m.tokenStack.length-1];(G0[1]||BQ).call(m,void 0,G0[0])}S.position={start:o0(T.length>0?T[0][1].start:{line:1,column:1,offset:0}),end:o0(T.length>0?T[T.length-2][1].end:{line:1,column:1,offset:0})},J1=-1;while(++J1<J.transforms.length)S=J.transforms[J1](S)||S;return S}function G(T,S,m){let t=S-1,J1=-1,G0=!1,e0,P0,Z6,J6;while(++t<=m){let p1=T[t];switch(p1[1].type){case"listUnordered":case"listOrdered":case"blockQuote":{if(p1[0]==="enter")J1++;else J1--;J6=void 0;break}case"lineEndingBlank":{if(p1[0]==="enter"){if(e0&&!J6&&!J1&&!Z6)Z6=t;J6=void 0}break}case"linePrefix":case"listItemValue":case"listItemMarker":case"listItemPrefix":case"listItemPrefixWhitespace":break;default:J6=void 0}if(!J1&&p1[0]==="enter"&&p1[1].type==="listItemPrefix"||J1===-1&&p1[0]==="exit"&&(p1[1].type==="listUnordered"||p1[1].type==="listOrdered")){if(e0){let I5=t;P0=void 0;while(I5--){let w0=T[I5];if(w0[1].type==="lineEnding"||w0[1].type==="lineEndingBlank"){if(w0[0]==="exit")continue;if(P0)T[P0][1].type="lineEndingBlank",G0=!0;w0[1].type="lineEnding",P0=I5}else if(w0[1].type==="linePrefix"||w0[1].type==="blockQuotePrefix"||w0[1].type==="blockQuotePrefixWhitespace"||w0[1].type==="blockQuoteMarker"||w0[1].type==="listItemIndent");else break}if(Z6&&(!P0||Z6<P0))e0._spread=!0;e0.end=Object.assign({},P0?T[P0][1].start:p1[1].end),T.splice(P0||t,0,["exit",e0,p1[2]]),t++,m++}if(p1[1].type==="listItemPrefix"){let I5={type:"listItem",_spread:!1,start:Object.assign({},p1[1].start),end:void 0};e0=I5,T.splice(t,0,["enter",I5,p1[2]]),t++,m++,Z6=void 0,J6=!0}}}return T[S][1]._spread=G0,m}function W(T,S){return m;function m(t){if(Q.call(this,T(t),t),S)S.call(this,t)}}function H(){this.stack.push({type:"fragment",children:[]})}function Q(T,S,m){this.stack[this.stack.length-1].children.push(T),this.stack.push(T),this.tokenStack.push([S,m||void 0]),T.position={start:o0(S.start),end:void 0}}function K(T){return S;function S(m){if(T)T.call(this,m);U.call(this,m)}}function U(T,S){let m=this.stack.pop(),t=this.tokenStack.pop();if(!t)throw Error("Cannot close `"+T.type+"` ("+a0({start:T.start,end:T.end})+"): it’s not open");else if(t[0].type!==T.type)if(S)S.call(this,T,t[0]);else(t[1]||BQ).call(this,T,t[0]);m.position.end=o0(T.end)}function $(){return ZJ(this.stack.pop())}function L(){this.data.expectingFirstListItemValue=!0}function z(T){if(this.data.expectingFirstListItemValue){let S=this.stack[this.stack.length-2];S.start=Number.parseInt(this.sliceSerialize(T),10),this.data.expectingFirstListItemValue=void 0}}function B(){let T=this.resume(),S=this.stack[this.stack.length-1];S.lang=T}function M(){let T=this.resume(),S=this.stack[this.stack.length-1];S.meta=T}function F(){if(this.data.flowCodeInside)return;this.buffer(),this.data.flowCodeInside=!0}function D(){let T=this.resume(),S=this.stack[this.stack.length-1];S.value=T.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,""),this.data.flowCodeInside=void 0}function q(){let T=this.resume(),S=this.stack[this.stack.length-1];S.value=T.replace(/(\r?\n|\r)$/g,"")}function P(T){let S=this.resume(),m=this.stack[this.stack.length-1];m.label=S,m.identifier=x0(this.sliceSerialize(T)).toLowerCase()}function O(){let T=this.resume(),S=this.stack[this.stack.length-1];S.title=T}function w(){let T=this.resume(),S=this.stack[this.stack.length-1];S.url=T}function E(T){let S=this.stack[this.stack.length-1];if(!S.depth){let m=this.sliceSerialize(T).length;S.depth=m}}function I(){this.data.setextHeadingSlurpLineEnding=!0}function k(T){let S=this.stack[this.stack.length-1];S.depth=this.sliceSerialize(T).codePointAt(0)===61?1:2}function l(){this.data.setextHeadingSlurpLineEnding=void 0}function y(T){let m=this.stack[this.stack.length-1].children,t=m[m.length-1];if(!t||t.type!=="text")t=aU(),t.position={start:o0(T.start),end:void 0},m.push(t);this.stack.push(t)}function a(T){let S=this.stack.pop();S.value+=this.sliceSerialize(T),S.position.end=o0(T.end)}function c(T){let S=this.stack[this.stack.length-1];if(this.data.atHardBreak){let m=S.children[S.children.length-1];m.position.end=o0(T.end),this.data.atHardBreak=void 0;return}if(!this.data.setextHeadingSlurpLineEnding&&J.canContainEols.includes(S.type))y.call(this,T),a.call(this,T)}function p(){this.data.atHardBreak=!0}function C(){let T=this.resume(),S=this.stack[this.stack.length-1];S.value=T}function g(){let T=this.resume(),S=this.stack[this.stack.length-1];S.value=T}function A(){let T=this.resume(),S=this.stack[this.stack.length-1];S.value=T}function o(){let T=this.stack[this.stack.length-1];if(this.data.inReference){let S=this.data.referenceType||"shortcut";T.type+="Reference",T.referenceType=S,delete T.url,delete T.title}else delete T.identifier,delete T.label;this.data.referenceType=void 0}function n(){let T=this.stack[this.stack.length-1];if(this.data.inReference){let S=this.data.referenceType||"shortcut";T.type+="Reference",T.referenceType=S,delete T.url,delete T.title}else delete T.identifier,delete T.label;this.data.referenceType=void 0}function W1(T){let S=this.sliceSerialize(T),m=this.stack[this.stack.length-2];m.label=LQ(S),m.identifier=x0(S).toLowerCase()}function z1(){let T=this.stack[this.stack.length-1],S=this.resume(),m=this.stack[this.stack.length-1];if(this.data.inReference=!0,m.type==="link"){let t=T.children;m.children=t}else m.alt=S}function N(){let T=this.resume(),S=this.stack[this.stack.length-1];S.url=T}function M1(){let T=this.resume(),S=this.stack[this.stack.length-1];S.title=T}function I1(){this.data.inReference=void 0}function V(){this.data.referenceType="collapsed"}function O1(T){let S=this.resume(),m=this.stack[this.stack.length-1];m.label=S,m.identifier=x0(this.sliceSerialize(T)).toLowerCase(),this.data.referenceType="full"}function z0(T){this.data.characterReferenceType=T.type}function L7(T){let S=this.sliceSerialize(T),m=this.data.characterReferenceType,t;if(m)t=T8(S,m==="characterReferenceMarkerNumeric"?10:16),this.data.characterReferenceType=void 0;else t=p5(S);let J1=this.stack[this.stack.length-1];J1.value+=t}function K9(T){let S=this.stack.pop();S.position.end=o0(T.end)}function A1(T){a.call(this,T);let S=this.stack[this.stack.length-1];S.url=this.sliceSerialize(T)}function e5(T){a.call(this,T);let S=this.stack[this.stack.length-1];S.url="mailto:"+this.sliceSerialize(T)}function T0(){return{type:"blockquote",children:[]}}function t0(){return{type:"code",lang:null,meta:null,value:""}}function R5(){return{type:"inlineCode",value:""}}function B7(){return{type:"definition",identifier:"",label:null,title:null,url:""}}function lU(){return{type:"emphasis",children:[]}}function YX(){return{type:"heading",depth:0,children:[]}}function GX(){return{type:"break"}}function WX(){return{type:"html",value:""}}function dU(){return{type:"image",title:null,url:"",alt:null}}function HX(){return{type:"link",title:null,url:"",children:[]}}function QX(T){return{type:"list",ordered:T.type==="listOrdered",start:null,spread:T._spread,children:[]}}function cU(T){return{type:"listItem",spread:T._spread,checked:null,children:[]}}function iU(){return{type:"paragraph",children:[]}}function nU(){return{type:"strong",children:[]}}function aU(){return{type:"text",value:""}}function rU(){return{type:"thematicBreak"}}}function o0(Z){return{line:Z.line,column:Z.column,offset:Z.offset}}function MQ(Z,J){let X=-1;while(++X<J.length){let Y=J[X];if(Array.isArray(Y))MQ(Z,Y);else BR(Z,Y)}}function BR(Z,J){let X;for(X in J)if(zQ.call(J,X))switch(X){case"canContainEols":{let Y=J[X];if(Y)Z[X].push(...Y);break}case"transforms":{let Y=J[X];if(Y)Z[X].push(...Y);break}case"enter":case"exit":{let Y=J[X];if(Y)Object.assign(Z[X],Y);break}}}function BQ(Z,J){if(Z)throw Error("Cannot close `"+Z.type+"` ("+a0({start:Z.start,end:Z.end})+"): a different token (`"+J.type+"`, "+a0({start:J.start,end:J.end})+") is open");else throw Error("Cannot close document, a token (`"+J.type+"`, "+a0({start:J.start,end:J.end})+") is still open")}function k8(Z){let J=this;J.parser=X;function X(Y){return AJ(Y,{...J.data("settings"),...Z,extensions:J.data("micromarkExtensions")||[],mdastExtensions:J.data("fromMarkdownExtensions")||[]})}}function FQ(Z,J){let X={type:"element",tagName:"blockquote",properties:{},children:Z.wrap(Z.all(J),!0)};return Z.patch(J,X),Z.applyData(J,X)}function NQ(Z,J){let X={type:"element",tagName:"br",properties:{},children:[]};return Z.patch(J,X),[Z.applyData(J,X),{type:"text",value:`
|
|
31
|
+
`}]}function VQ(Z,J){let X=J.value?J.value+`
|
|
32
|
+
`:"",Y={},G=J.lang?J.lang.split(/\s+/):[];if(G.length>0)Y.className=["language-"+G[0]];let W={type:"element",tagName:"code",properties:Y,children:[{type:"text",value:X}]};if(J.meta)W.data={meta:J.meta};return Z.patch(J,W),W=Z.applyData(J,W),W={type:"element",tagName:"pre",properties:{},children:[W]},Z.patch(J,W),W}function AQ(Z,J){let X={type:"element",tagName:"del",properties:{},children:Z.all(J)};return Z.patch(J,X),Z.applyData(J,X)}function DQ(Z,J){let X={type:"element",tagName:"em",properties:{},children:Z.all(J)};return Z.patch(J,X),Z.applyData(J,X)}function qQ(Z,J){let X=typeof Z.options.clobberPrefix==="string"?Z.options.clobberPrefix:"user-content-",Y=String(J.identifier).toUpperCase(),G=Z0(Y.toLowerCase()),W=Z.footnoteOrder.indexOf(Y),H,Q=Z.footnoteCounts.get(Y);if(Q===void 0)Q=0,Z.footnoteOrder.push(Y),H=Z.footnoteOrder.length;else H=W+1;Q+=1,Z.footnoteCounts.set(Y,Q);let K={type:"element",tagName:"a",properties:{href:"#"+X+"fn-"+G,id:X+"fnref-"+G+(Q>1?"-"+Q:""),dataFootnoteRef:!0,ariaDescribedBy:["footnote-label"]},children:[{type:"text",value:String(H)}]};Z.patch(J,K);let U={type:"element",tagName:"sup",properties:{},children:[K]};return Z.patch(J,U),Z.applyData(J,U)}function RQ(Z,J){let X={type:"element",tagName:"h"+J.depth,properties:{},children:Z.all(J)};return Z.patch(J,X),Z.applyData(J,X)}function IQ(Z,J){if(Z.options.allowDangerousHtml){let X={type:"raw",value:J.value};return Z.patch(J,X),Z.applyData(J,X)}return}function g8(Z,J){let X=J.referenceType,Y="]";if(X==="collapsed")Y+="[]";else if(X==="full")Y+="["+(J.label||J.identifier)+"]";if(J.type==="imageReference")return[{type:"text",value:"!["+J.alt+Y}];let G=Z.all(J),W=G[0];if(W&&W.type==="text")W.value="["+W.value;else G.unshift({type:"text",value:"["});let H=G[G.length-1];if(H&&H.type==="text")H.value+=Y;else G.push({type:"text",value:Y});return G}function OQ(Z,J){let X=String(J.identifier).toUpperCase(),Y=Z.definitionById.get(X);if(!Y)return g8(Z,J);let G={src:Z0(Y.url||""),alt:J.alt};if(Y.title!==null&&Y.title!==void 0)G.title=Y.title;let W={type:"element",tagName:"img",properties:G,children:[]};return Z.patch(J,W),Z.applyData(J,W)}function TQ(Z,J){let X={src:Z0(J.url)};if(J.alt!==null&&J.alt!==void 0)X.alt=J.alt;if(J.title!==null&&J.title!==void 0)X.title=J.title;let Y={type:"element",tagName:"img",properties:X,children:[]};return Z.patch(J,Y),Z.applyData(J,Y)}function PQ(Z,J){let X={type:"text",value:J.value.replace(/\r?\n|\r/g," ")};Z.patch(J,X);let Y={type:"element",tagName:"code",properties:{},children:[X]};return Z.patch(J,Y),Z.applyData(J,Y)}function wQ(Z,J){let X=String(J.identifier).toUpperCase(),Y=Z.definitionById.get(X);if(!Y)return g8(Z,J);let G={href:Z0(Y.url||"")};if(Y.title!==null&&Y.title!==void 0)G.title=Y.title;let W={type:"element",tagName:"a",properties:G,children:Z.all(J)};return Z.patch(J,W),Z.applyData(J,W)}function _Q(Z,J){let X={href:Z0(J.url)};if(J.title!==null&&J.title!==void 0)X.title=J.title;let Y={type:"element",tagName:"a",properties:X,children:Z.all(J)};return Z.patch(J,Y),Z.applyData(J,Y)}function SQ(Z,J,X){let Y=Z.all(J),G=X?zR(X):CQ(J),W={},H=[];if(typeof J.checked==="boolean"){let $=Y[0],L;if($&&$.type==="element"&&$.tagName==="p")L=$;else L={type:"element",tagName:"p",properties:{},children:[]},Y.unshift(L);if(L.children.length>0)L.children.unshift({type:"text",value:" "});L.children.unshift({type:"element",tagName:"input",properties:{type:"checkbox",checked:J.checked,disabled:!0},children:[]}),W.className=["task-list-item"]}let Q=-1;while(++Q<Y.length){let $=Y[Q];if(G||Q!==0||$.type!=="element"||$.tagName!=="p")H.push({type:"text",value:`
|
|
33
|
+
`});if($.type==="element"&&$.tagName==="p"&&!G)H.push(...$.children);else H.push($)}let K=Y[Y.length-1];if(K&&(G||K.type!=="element"||K.tagName!=="p"))H.push({type:"text",value:`
|
|
34
|
+
`});let U={type:"element",tagName:"li",properties:W,children:H};return Z.patch(J,U),Z.applyData(J,U)}function zR(Z){let J=!1;if(Z.type==="list"){J=Z.spread||!1;let X=Z.children,Y=-1;while(!J&&++Y<X.length)J=CQ(X[Y])}return J}function CQ(Z){let J=Z.spread;return J===null||J===void 0?Z.children.length>1:J}function EQ(Z,J){let X={},Y=Z.all(J),G=-1;if(typeof J.start==="number"&&J.start!==1)X.start=J.start;while(++G<Y.length){let H=Y[G];if(H.type==="element"&&H.tagName==="li"&&H.properties&&Array.isArray(H.properties.className)&&H.properties.className.includes("task-list-item")){X.className=["contains-task-list"];break}}let W={type:"element",tagName:J.ordered?"ol":"ul",properties:X,children:Z.wrap(Y,!0)};return Z.patch(J,W),Z.applyData(J,W)}function jQ(Z,J){let X={type:"element",tagName:"p",properties:{},children:Z.all(J)};return Z.patch(J,X),Z.applyData(J,X)}function xQ(Z,J){let X={type:"root",children:Z.wrap(Z.all(J))};return Z.patch(J,X),Z.applyData(J,X)}function bQ(Z,J){let X={type:"element",tagName:"strong",properties:{},children:Z.all(J)};return Z.patch(J,X),Z.applyData(J,X)}function kQ(Z,J){let X=Z.all(J),Y=X.shift(),G=[];if(Y){let H={type:"element",tagName:"thead",properties:{},children:Z.wrap([Y],!0)};Z.patch(J.children[0],H),G.push(H)}if(X.length>0){let H={type:"element",tagName:"tbody",properties:{},children:Z.wrap(X,!0)},Q=u5(J.children[1]),K=O8(J.children[J.children.length-1]);if(Q&&K)H.position={start:Q,end:K};G.push(H)}let W={type:"element",tagName:"table",properties:{},children:Z.wrap(G,!0)};return Z.patch(J,W),Z.applyData(J,W)}function gQ(Z,J,X){let Y=X?X.children:void 0,W=(Y?Y.indexOf(J):1)===0?"th":"td",H=X&&X.type==="table"?X.align:void 0,Q=H?H.length:J.children.length,K=-1,U=[];while(++K<Q){let L=J.children[K],z={},B=H?H[K]:void 0;if(B)z.align=B;let M={type:"element",tagName:W,properties:z,children:[]};if(L)M.children=Z.all(L),Z.patch(L,M),M=Z.applyData(L,M);U.push(M)}let $={type:"element",tagName:"tr",properties:{},children:Z.wrap(U,!0)};return Z.patch(J,$),Z.applyData(J,$)}function hQ(Z,J){let X={type:"element",tagName:"td",properties:{},children:Z.all(J)};return Z.patch(J,X),Z.applyData(J,X)}function yQ(Z){let J=String(Z),X=/\r?\n|\r/g,Y=X.exec(J),G=0,W=[];while(Y)W.push(vQ(J.slice(G,Y.index),G>0,!0),Y[0]),G=Y.index+Y[0].length,Y=X.exec(J);return W.push(vQ(J.slice(G),G>0,!1)),W.join("")}function vQ(Z,J,X){let Y=0,G=Z.length;if(J){let W=Z.codePointAt(Y);while(W===9||W===32)Y++,W=Z.codePointAt(Y)}if(X){let W=Z.codePointAt(G-1);while(W===9||W===32)G--,W=Z.codePointAt(G-1)}return G>Y?Z.slice(Y,G):""}function mQ(Z,J){let X={type:"text",value:yQ(String(J.value))};return Z.patch(J,X),Z.applyData(J,X)}function fQ(Z,J){let X={type:"element",tagName:"hr",properties:{},children:[]};return Z.patch(J,X),Z.applyData(J,X)}var uQ={blockquote:FQ,break:NQ,code:VQ,delete:AQ,emphasis:DQ,footnoteReference:qQ,heading:RQ,html:IQ,imageReference:OQ,image:TQ,inlineCode:PQ,linkReference:wQ,link:_Q,listItem:SQ,list:EQ,paragraph:jQ,root:xQ,strong:bQ,table:kQ,tableCell:hQ,tableRow:gQ,text:mQ,thematicBreak:fQ,toml:h8,yaml:h8,definition:h8,footnoteDefinition:h8};function h8(){return}var v8=-1,d5=0,V5=1,c5=2,n6=3,a6=4,r6=5,s6=6,y8=7,m8=8;var pQ=typeof self==="object"?self:globalThis,MR=(Z,J)=>{let X=(G,W)=>{return Z.set(W,G),G},Y=(G)=>{if(Z.has(G))return Z.get(G);let[W,H]=J[G];switch(W){case d5:case v8:return X(H,G);case V5:{let Q=X([],G);for(let K of H)Q.push(Y(K));return Q}case c5:{let Q=X({},G);for(let[K,U]of H)Q[Y(K)]=Y(U);return Q}case n6:return X(new Date(H),G);case a6:{let{source:Q,flags:K}=H;return X(new RegExp(Q,K),G)}case r6:{let Q=X(new Map,G);for(let[K,U]of H)Q.set(Y(K),Y(U));return Q}case s6:{let Q=X(new Set,G);for(let K of H)Q.add(Y(K));return Q}case y8:{let{name:Q,message:K}=H;return X(new pQ[Q](K),G)}case m8:return X(BigInt(H),G);case"BigInt":return X(Object(BigInt(H)),G);case"ArrayBuffer":return X(new Uint8Array(H).buffer,H);case"DataView":{let{buffer:Q}=new Uint8Array(H);return X(new DataView(Q),H)}}return X(new pQ[W](H),G)};return Y},DJ=(Z)=>MR(new Map,Z)(0);var i5="",{toString:FR}={},{keys:NR}=Object,o6=(Z)=>{let J=typeof Z;if(J!=="object"||!Z)return[d5,J];let X=FR.call(Z).slice(8,-1);switch(X){case"Array":return[V5,i5];case"Object":return[c5,i5];case"Date":return[n6,i5];case"RegExp":return[a6,i5];case"Map":return[r6,i5];case"Set":return[s6,i5];case"DataView":return[V5,X]}if(X.includes("Array"))return[V5,X];if(X.includes("Error"))return[y8,X];return[c5,X]},f8=([Z,J])=>Z===d5&&(J==="function"||J==="symbol"),VR=(Z,J,X,Y)=>{let G=(H,Q)=>{let K=Y.push(H)-1;return X.set(Q,K),K},W=(H)=>{if(X.has(H))return X.get(H);let[Q,K]=o6(H);switch(Q){case d5:{let $=H;switch(K){case"bigint":Q=m8,$=H.toString();break;case"function":case"symbol":if(Z)throw TypeError("unable to serialize "+K);$=null;break;case"undefined":return G([v8],H)}return G([Q,$],H)}case V5:{if(K){let z=H;if(K==="DataView")z=new Uint8Array(H.buffer);else if(K==="ArrayBuffer")z=new Uint8Array(H);return G([K,[...z]],H)}let $=[],L=G([Q,$],H);for(let z of H)$.push(W(z));return L}case c5:{if(K)switch(K){case"BigInt":return G([K,H.toString()],H);case"Boolean":case"Number":case"String":return G([K,H.valueOf()],H)}if(J&&"toJSON"in H)return W(H.toJSON());let $=[],L=G([Q,$],H);for(let z of NR(H))if(Z||!f8(o6(H[z])))$.push([W(z),W(H[z])]);return L}case n6:return G([Q,H.toISOString()],H);case a6:{let{source:$,flags:L}=H;return G([Q,{source:$,flags:L}],H)}case r6:{let $=[],L=G([Q,$],H);for(let[z,B]of H)if(Z||!(f8(o6(z))||f8(o6(B))))$.push([W(z),W(B)]);return L}case s6:{let $=[],L=G([Q,$],H);for(let z of H)if(Z||!f8(o6(z)))$.push(W(z));return L}}let{message:U}=H;return G([Q,{name:K,message:U}],H)};return W},qJ=(Z,{json:J,lossy:X}={})=>{let Y=[];return VR(!(J||X),!!J,new Map,Y)(Z),Y};var n5=typeof structuredClone==="function"?(Z,J)=>J&&(("json"in J)||("lossy"in J))?DJ(qJ(Z,J)):structuredClone(Z):(Z,J)=>DJ(qJ(Z,J));function AR(Z,J){let X=[{type:"text",value:"↩"}];if(J>1)X.push({type:"element",tagName:"sup",properties:{},children:[{type:"text",value:String(J)}]});return X}function DR(Z,J){return"Back to reference "+(Z+1)+(J>1?"-"+J:"")}function lQ(Z){let J=typeof Z.options.clobberPrefix==="string"?Z.options.clobberPrefix:"user-content-",X=Z.options.footnoteBackContent||AR,Y=Z.options.footnoteBackLabel||DR,G=Z.options.footnoteLabel||"Footnotes",W=Z.options.footnoteLabelTagName||"h2",H=Z.options.footnoteLabelProperties||{className:["sr-only"]},Q=[],K=-1;while(++K<Z.footnoteOrder.length){let U=Z.footnoteById.get(Z.footnoteOrder[K]);if(!U)continue;let $=Z.all(U),L=String(U.identifier).toUpperCase(),z=Z0(L.toLowerCase()),B=0,M=[],F=Z.footnoteCounts.get(L);while(F!==void 0&&++B<=F){if(M.length>0)M.push({type:"text",value:" "});let P=typeof X==="string"?X:X(K,B);if(typeof P==="string")P={type:"text",value:P};M.push({type:"element",tagName:"a",properties:{href:"#"+J+"fnref-"+z+(B>1?"-"+B:""),dataFootnoteBackref:"",ariaLabel:typeof Y==="string"?Y:Y(K,B),className:["data-footnote-backref"]},children:Array.isArray(P)?P:[P]})}let D=$[$.length-1];if(D&&D.type==="element"&&D.tagName==="p"){let P=D.children[D.children.length-1];if(P&&P.type==="text")P.value+=" ";else D.children.push({type:"text",value:" "});D.children.push(...M)}else $.push(...M);let q={type:"element",tagName:"li",properties:{id:J+"fn-"+z},children:Z.wrap($,!0)};Z.patch(U,q),Q.push(q)}if(Q.length===0)return;return{type:"element",tagName:"section",properties:{dataFootnotes:!0,className:["footnotes"]},children:[{type:"element",tagName:W,properties:{...n5(H),id:"footnote-label"},children:[{type:"text",value:G}]},{type:"text",value:`
|
|
35
|
+
`},{type:"element",tagName:"ol",properties:{},children:Z.wrap(Q,!0)},{type:"text",value:`
|
|
36
|
+
`}]}}var u8=function(Z){if(Z===null||Z===void 0)return OR;if(typeof Z==="function")return p8(Z);if(typeof Z==="object")return Array.isArray(Z)?qR(Z):RR(Z);if(typeof Z==="string")return IR(Z);throw Error("Expected function, string, or object as test")};function qR(Z){let J=[],X=-1;while(++X<Z.length)J[X]=u8(Z[X]);return p8(Y);function Y(...G){let W=-1;while(++W<J.length)if(J[W].apply(this,G))return!0;return!1}}function RR(Z){let J=Z;return p8(X);function X(Y){let G=Y,W;for(W in Z)if(G[W]!==J[W])return!1;return!0}}function IR(Z){return p8(J);function J(X){return X&&X.type===Z}}function p8(Z){return J;function J(X,Y,G){return Boolean(TR(X)&&Z.call(this,X,typeof Y==="number"?Y:void 0,G||void 0))}}function OR(){return!0}function TR(Z){return Z!==null&&typeof Z==="object"&&"type"in Z}function dQ(Z){return Z}var cQ=[],RJ=!0,l8=!1,IJ="skip";function OJ(Z,J,X,Y){let G;if(typeof J==="function"&&typeof X!=="function")Y=X,X=J;else G=J;let W=u8(G),H=Y?-1:1;Q(Z,void 0,[])();function Q(K,U,$){let L=K&&typeof K==="object"?K:{};if(typeof L.type==="string"){let B=typeof L.tagName==="string"?L.tagName:typeof L.name==="string"?L.name:void 0;Object.defineProperty(z,"name",{value:"node ("+dQ(K.type+(B?"<"+B+">":""))+")"})}return z;function z(){let B=cQ,M,F,D;if(!J||W(K,U,$[$.length-1]||void 0)){if(B=PR(X(K,$)),B[0]===l8)return B}if("children"in K&&K.children){let q=K;if(q.children&&B[0]!==IJ){F=(Y?q.children.length:-1)+H,D=$.concat(q);while(F>-1&&F<q.children.length){let P=q.children[F];if(M=Q(P,F,D)(),M[0]===l8)return M;F=typeof M[1]==="number"?M[1]:F+H}}}return B}}}function PR(Z){if(Array.isArray(Z))return Z;if(typeof Z==="number")return[RJ,Z];return Z===null||Z===void 0?cQ:[Z]}function t6(Z,J,X,Y){let G,W,H;if(typeof J==="function"&&typeof X!=="function")W=void 0,H=J,G=X;else W=J,H=X,G=Y;OJ(Z,W,Q,G);function Q(K,U){let $=U[U.length-1],L=$?$.children.indexOf(K):void 0;return H(K,L,$)}}var TJ={}.hasOwnProperty,wR={};function nQ(Z,J){let X=J||wR,Y=new Map,G=new Map,W=new Map,H={...uQ,...X.handlers},Q={all:U,applyData:SR,definitionById:Y,footnoteById:G,footnoteCounts:W,footnoteOrder:[],handlers:H,one:K,options:X,patch:_R,wrap:ER};return t6(Z,function($){if($.type==="definition"||$.type==="footnoteDefinition"){let L=$.type==="definition"?Y:G,z=String($.identifier).toUpperCase();if(!L.has(z))L.set(z,$)}}),Q;function K($,L){let z=$.type,B=Q.handlers[z];if(TJ.call(Q.handlers,z)&&B)return B(Q,$,L);if(Q.options.passThrough&&Q.options.passThrough.includes(z)){if("children"in $){let{children:F,...D}=$,q=n5(D);return q.children=Q.all($),q}return n5($)}return(Q.options.unknownHandler||CR)(Q,$,L)}function U($){let L=[];if("children"in $){let z=$.children,B=-1;while(++B<z.length){let M=Q.one(z[B],$);if(M){if(B&&z[B-1].type==="break"){if(!Array.isArray(M)&&M.type==="text")M.value=iQ(M.value);if(!Array.isArray(M)&&M.type==="element"){let F=M.children[0];if(F&&F.type==="text")F.value=iQ(F.value)}}if(Array.isArray(M))L.push(...M);else L.push(M)}}}return L}}function _R(Z,J){if(Z.position)J.position=aZ(Z)}function SR(Z,J){let X=J;if(Z&&Z.data){let Y=Z.data.hName,G=Z.data.hChildren,W=Z.data.hProperties;if(typeof Y==="string")if(X.type==="element")X.tagName=Y;else{let H="children"in X?X.children:[X];X={type:"element",tagName:Y,properties:{},children:H}}if(X.type==="element"&&W)Object.assign(X.properties,n5(W));if("children"in X&&X.children&&G!==null&&G!==void 0)X.children=G}return X}function CR(Z,J){let X=J.data||{},Y="value"in J&&!(TJ.call(X,"hProperties")||TJ.call(X,"hChildren"))?{type:"text",value:J.value}:{type:"element",tagName:"div",properties:{},children:Z.all(J)};return Z.patch(J,Y),Z.applyData(J,Y)}function ER(Z,J){let X=[],Y=-1;if(J)X.push({type:"text",value:`
|
|
37
|
+
`});while(++Y<Z.length){if(Y)X.push({type:"text",value:`
|
|
38
|
+
`});X.push(Z[Y])}if(J&&Z.length>0)X.push({type:"text",value:`
|
|
39
|
+
`});return X}function iQ(Z){let J=0,X=Z.charCodeAt(J);while(X===9||X===32)J++,X=Z.charCodeAt(J);return Z.slice(J)}function d8(Z,J){let X=nQ(Z,J),Y=X.one(Z,void 0),G=lQ(X),W=Array.isArray(Y)?{type:"root",children:Y}:Y||{type:"root",children:[]};if(G)k1("children"in W),W.children.push({type:"text",value:`
|
|
40
|
+
`},G);return W}function c8(Z,J){if(Z&&"run"in Z)return async function(X,Y){let G=d8(X,{file:Y,...J});await Z.run(G,Y)};return function(X,Y){return d8(X,{file:Y,...Z||J})}}function PJ(Z){if(Z)throw Z}var a8=r(XK(),1);function e6(Z){if(typeof Z!=="object"||Z===null)return!1;let J=Object.getPrototypeOf(Z);return(J===null||J===Object.prototype||Object.getPrototypeOf(J)===null)&&!(Symbol.toStringTag in Z)&&!(Symbol.iterator in Z)}function wJ(){let Z=[],J={run:X,use:Y};return J;function X(...G){let W=-1,H=G.pop();if(typeof H!=="function")throw TypeError("Expected function as last argument, not "+H);Q(null,...G);function Q(K,...U){let $=Z[++W],L=-1;if(K){H(K);return}while(++L<G.length)if(U[L]===null||U[L]===void 0)U[L]=G[L];if(G=U,$)YK($,Q)(...U);else H(null,...U)}}function Y(G){if(typeof G!=="function")throw TypeError("Expected `middelware` to be a function, not "+G);return Z.push(G),J}}function YK(Z,J){let X;return Y;function Y(...H){let Q=Z.length>H.length,K;if(Q)H.push(G);try{K=Z.apply(this,H)}catch(U){let $=U;if(Q&&X)throw $;return G($)}if(!Q)if(K&&K.then&&typeof K.then==="function")K.then(W,G);else if(K instanceof Error)G(K);else W(K)}function G(H,...Q){if(!X)X=!0,J(H,...Q)}function W(H){G(null,H)}}var $0={basename:jR,dirname:xR,extname:bR,join:kR,sep:"/"};function jR(Z,J){if(J!==void 0&&typeof J!=="string")throw TypeError('"ext" argument must be a string');Z9(Z);let X=0,Y=-1,G=Z.length,W;if(J===void 0||J.length===0||J.length>Z.length){while(G--)if(Z.codePointAt(G)===47){if(W){X=G+1;break}}else if(Y<0)W=!0,Y=G+1;return Y<0?"":Z.slice(X,Y)}if(J===Z)return"";let H=-1,Q=J.length-1;while(G--)if(Z.codePointAt(G)===47){if(W){X=G+1;break}}else{if(H<0)W=!0,H=G+1;if(Q>-1)if(Z.codePointAt(G)===J.codePointAt(Q--)){if(Q<0)Y=G}else Q=-1,Y=H}if(X===Y)Y=H;else if(Y<0)Y=Z.length;return Z.slice(X,Y)}function xR(Z){if(Z9(Z),Z.length===0)return".";let J=-1,X=Z.length,Y;while(--X)if(Z.codePointAt(X)===47){if(Y){J=X;break}}else if(!Y)Y=!0;return J<0?Z.codePointAt(0)===47?"/":".":J===1&&Z.codePointAt(0)===47?"//":Z.slice(0,J)}function bR(Z){Z9(Z);let J=Z.length,X=-1,Y=0,G=-1,W=0,H;while(J--){let Q=Z.codePointAt(J);if(Q===47){if(H){Y=J+1;break}continue}if(X<0)H=!0,X=J+1;if(Q===46){if(G<0)G=J;else if(W!==1)W=1}else if(G>-1)W=-1}if(G<0||X<0||W===0||W===1&&G===X-1&&G===Y+1)return"";return Z.slice(G,X)}function kR(...Z){let J=-1,X;while(++J<Z.length)if(Z9(Z[J]),Z[J])X=X===void 0?Z[J]:X+"/"+Z[J];return X===void 0?".":gR(X)}function gR(Z){Z9(Z);let J=Z.codePointAt(0)===47,X=hR(Z,!J);if(X.length===0&&!J)X=".";if(X.length>0&&Z.codePointAt(Z.length-1)===47)X+="/";return J?"/"+X:X}function hR(Z,J){let X="",Y=0,G=-1,W=0,H=-1,Q,K;while(++H<=Z.length){if(H<Z.length)Q=Z.codePointAt(H);else if(Q===47)break;else Q=47;if(Q===47){if(G===H-1||W===1);else if(G!==H-1&&W===2){if(X.length<2||Y!==2||X.codePointAt(X.length-1)!==46||X.codePointAt(X.length-2)!==46){if(X.length>2){if(K=X.lastIndexOf("/"),K!==X.length-1){if(K<0)X="",Y=0;else X=X.slice(0,K),Y=X.length-1-X.lastIndexOf("/");G=H,W=0;continue}}else if(X.length>0){X="",Y=0,G=H,W=0;continue}}if(J)X=X.length>0?X+"/..":"..",Y=2}else{if(X.length>0)X+="/"+Z.slice(G+1,H);else X=Z.slice(G+1,H);Y=H-G-1}G=H,W=0}else if(Q===46&&W>-1)W++;else W=-1}return X}function Z9(Z){if(typeof Z!=="string")throw TypeError("Path must be a string. Received "+JSON.stringify(Z))}var GK={cwd:vR};function vR(){return"/"}function a5(Z){return Boolean(Z!==null&&typeof Z==="object"&&"href"in Z&&Z.href&&"protocol"in Z&&Z.protocol&&Z.auth===void 0)}function WK(Z){if(typeof Z==="string")Z=new URL(Z);else if(!a5(Z)){let J=TypeError('The "path" argument must be of type string or an instance of URL. Received `'+Z+"`");throw J.code="ERR_INVALID_ARG_TYPE",J}if(Z.protocol!=="file:"){let J=TypeError("The URL must be of scheme file");throw J.code="ERR_INVALID_URL_SCHEME",J}return yR(Z)}function yR(Z){if(Z.hostname!==""){let Y=TypeError('File URL host must be "localhost" or empty on darwin');throw Y.code="ERR_INVALID_FILE_URL_HOST",Y}let J=Z.pathname,X=-1;while(++X<J.length)if(J.codePointAt(X)===37&&J.codePointAt(X+1)===50){let Y=J.codePointAt(X+2);if(Y===70||Y===102){let G=TypeError("File URL path must not include encoded / characters");throw G.code="ERR_INVALID_FILE_URL_PATH",G}}return decodeURIComponent(J)}var _J=["history","path","basename","stem","extname","dirname"];class r5{constructor(Z){let J;if(!Z)J={};else if(a5(Z))J={path:Z};else if(typeof Z==="string"||mR(Z))J={value:Z};else J=Z;this.cwd="cwd"in J?"":GK.cwd(),this.data={},this.history=[],this.messages=[],this.value,this.map,this.result,this.stored;let X=-1;while(++X<_J.length){let G=_J[X];if(G in J&&J[G]!==void 0&&J[G]!==null)this[G]=G==="history"?[...J[G]]:J[G]}let Y;for(Y in J)if(!_J.includes(Y))this[Y]=J[Y]}get basename(){return typeof this.path==="string"?$0.basename(this.path):void 0}set basename(Z){CJ(Z,"basename"),SJ(Z,"basename"),this.path=$0.join(this.dirname||"",Z)}get dirname(){return typeof this.path==="string"?$0.dirname(this.path):void 0}set dirname(Z){HK(this.basename,"dirname"),this.path=$0.join(Z||"",this.basename)}get extname(){return typeof this.path==="string"?$0.extname(this.path):void 0}set extname(Z){if(SJ(Z,"extname"),HK(this.dirname,"extname"),Z){if(Z.codePointAt(0)!==46)throw Error("`extname` must start with `.`");if(Z.includes(".",1))throw Error("`extname` cannot contain multiple dots")}this.path=$0.join(this.dirname,this.stem+(Z||""))}get path(){return this.history[this.history.length-1]}set path(Z){if(a5(Z))Z=WK(Z);if(CJ(Z,"path"),this.path!==Z)this.history.push(Z)}get stem(){return typeof this.path==="string"?$0.basename(this.path,this.extname):void 0}set stem(Z){CJ(Z,"stem"),SJ(Z,"stem"),this.path=$0.join(this.dirname||"",Z+(this.extname||""))}fail(Z,J,X){let Y=this.message(Z,J,X);throw Y.fatal=!0,Y}info(Z,J,X){let Y=this.message(Z,J,X);return Y.fatal=void 0,Y}message(Z,J,X){let Y=new L1(Z,J,X);if(this.path)Y.name=this.path+":"+Y.name,Y.file=this.path;return Y.fatal=!1,this.messages.push(Y),Y}toString(Z){if(this.value===void 0)return"";if(typeof this.value==="string")return this.value;return new TextDecoder(Z||void 0).decode(this.value)}}function SJ(Z,J){if(Z&&Z.includes($0.sep))throw Error("`"+J+"` cannot be a path: did not expect `"+$0.sep+"`")}function CJ(Z,J){if(!Z)throw Error("`"+J+"` cannot be empty")}function HK(Z,J){if(!Z)throw Error("Setting `"+J+"` requires `path` to be set too")}function mR(Z){return Boolean(Z&&typeof Z==="object"&&"byteLength"in Z&&"byteOffset"in Z)}var QK=function(Z){let Y=this.constructor.prototype,G=Y[Z],W=function(){return G.apply(W,arguments)};return Object.setPrototypeOf(W,Y),W};var fR={}.hasOwnProperty;class bJ extends QK{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=wJ()}copy(){let Z=new bJ,J=-1;while(++J<this.attachers.length){let X=this.attachers[J];Z.use(...X)}return Z.data(a8.default(!0,{},this.namespace)),Z}data(Z,J){if(typeof Z==="string"){if(arguments.length===2)return xJ("data",this.frozen),this.namespace[Z]=J,this;return fR.call(this.namespace,Z)&&this.namespace[Z]||void 0}if(Z)return xJ("data",this.frozen),this.namespace=Z,this;return this.namespace}freeze(){if(this.frozen)return this;let Z=this;while(++this.freezeIndex<this.attachers.length){let[J,...X]=this.attachers[this.freezeIndex];if(X[0]===!1)continue;if(X[0]===!0)X[0]=void 0;let Y=J.call(Z,...X);if(typeof Y==="function")this.transformers.use(Y)}return this.frozen=!0,this.freezeIndex=Number.POSITIVE_INFINITY,this}parse(Z){this.freeze();let J=n8(Z),X=this.parser||this.Parser;return EJ("parse",X),X(String(J),J)}process(Z,J){let X=this;return this.freeze(),EJ("process",this.parser||this.Parser),jJ("process",this.compiler||this.Compiler),J?Y(void 0,J):new Promise(Y);function Y(G,W){let H=n8(Z),Q=X.parse(H);X.run(Q,H,function(U,$,L){if(U||!$||!L)return K(U);let z=$,B=X.stringify(z,L);if(pR(B))L.value=B;else L.result=B;K(U,L)});function K(U,$){if(U||!$)W(U);else if(G)G($);else k1(J,"`done` is defined if `resolve` is not"),J(void 0,$)}}}processSync(Z){let J=!1,X;return this.freeze(),EJ("processSync",this.parser||this.Parser),jJ("processSync",this.compiler||this.Compiler),this.process(Z,Y),UK("processSync","process",J),k1(X,"we either bailed on an error or have a tree"),X;function Y(G,W){J=!0,PJ(G),X=W}}run(Z,J,X){KK(Z),this.freeze();let Y=this.transformers;if(!X&&typeof J==="function")X=J,J=void 0;return X?G(void 0,X):new Promise(G);function G(W,H){k1(typeof J!=="function","`file` can’t be a `done` anymore, we checked");let Q=n8(J);Y.run(Z,Q,K);function K(U,$,L){let z=$||Z;if(U)H(U);else if(W)W(z);else k1(X,"`done` is defined if `resolve` is not"),X(void 0,z,L)}}}runSync(Z,J){let X=!1,Y;return this.run(Z,J,G),UK("runSync","run",X),k1(Y,"we either bailed on an error or have a tree"),Y;function G(W,H){PJ(W),Y=H,X=!0}}stringify(Z,J){this.freeze();let X=n8(J),Y=this.compiler||this.Compiler;return jJ("stringify",Y),KK(Z),Y(Z,X)}use(Z,...J){let X=this.attachers,Y=this.namespace;if(xJ("use",this.frozen),Z===null||Z===void 0);else if(typeof Z==="function")Q(Z,J);else if(typeof Z==="object")if(Array.isArray(Z))H(Z);else W(Z);else throw TypeError("Expected usable value, not `"+Z+"`");return this;function G(K){if(typeof K==="function")Q(K,[]);else if(typeof K==="object")if(Array.isArray(K)){let[U,...$]=K;Q(U,$)}else W(K);else throw TypeError("Expected usable value, not `"+K+"`")}function W(K){if(!("plugins"in K)&&!("settings"in K))throw Error("Expected usable value but received an empty preset, which is probably a mistake: presets typically come with `plugins` and sometimes with `settings`, but this has neither");if(H(K.plugins),K.settings)Y.settings=a8.default(!0,Y.settings,K.settings)}function H(K){let U=-1;if(K===null||K===void 0);else if(Array.isArray(K))while(++U<K.length){let $=K[U];G($)}else throw TypeError("Expected a list of plugins, not `"+K+"`")}function Q(K,U){let $=-1,L=-1;while(++$<X.length)if(X[$][0]===K){L=$;break}if(L===-1)X.push([K,...U]);else if(U.length>0){let[z,...B]=U,M=X[L][1];if(e6(M)&&e6(z))z=a8.default(!0,M,z);X[L]=[K,z,...B]}}}}var kJ=new bJ().freeze();function EJ(Z,J){if(typeof J!=="function")throw TypeError("Cannot `"+Z+"` without `parser`")}function jJ(Z,J){if(typeof J!=="function")throw TypeError("Cannot `"+Z+"` without `compiler`")}function xJ(Z,J){if(J)throw Error("Cannot call `"+Z+"` on a frozen processor.\nCreate a new processor first, by calling it: use `processor()` instead of `processor`.")}function KK(Z){if(!e6(Z)||typeof Z.type!=="string")throw TypeError("Expected node, got `"+Z+"`")}function UK(Z,J,X){if(!X)throw Error("`"+Z+"` finished async. Use `"+J+"` instead")}function n8(Z){return uR(Z)?Z:new r5(Z)}function uR(Z){return Boolean(Z&&typeof Z==="object"&&"message"in Z&&"messages"in Z)}function pR(Z){return typeof Z==="string"||lR(Z)}function lR(Z){return Boolean(Z&&typeof Z==="object"&&"byteLength"in Z&&"byteOffset"in Z)}var nR="https://github.com/remarkjs/react-markdown/blob/main/changelog.md",$K=[],LK={allowDangerousHtml:!0},aR=/^(https?|ircs?|mailto|xmpp)$/i,rR=[{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 gJ(Z){let J=sR(Z),X=oR(Z);return tR(J.runSync(J.parse(X),X),Z)}function sR(Z){let J=Z.rehypePlugins||$K,X=Z.remarkPlugins||$K,Y=Z.remarkRehypeOptions?{...Z.remarkRehypeOptions,...LK}:LK;return kJ().use(k8).use(X).use(c8,Y).use(J)}function oR(Z){let J=Z.children||"",X=new r5;if(typeof J==="string")X.value=J;else V8("Unexpected value `"+J+"` for `children` prop, expected `string`");return X}function tR(Z,J){let{allowedElements:X,allowElement:Y,components:G,disallowedElements:W,skipHtml:H,unwrapDisallowed:Q}=J,K=J.urlTransform||BK;for(let $ of rR)if(Object.hasOwn(J,$.from))V8("Unexpected `"+$.from+"` prop, "+($.to?"use `"+$.to+"` instead":"remove it")+" (see <"+nR+"#"+$.id+"> for more info)");if(X&&W)V8("Unexpected combined `allowedElements` and `disallowedElements`, expected one or the other");return t6(Z,U),oZ(Z,{Fragment:dR,components:G,ignoreInvalidStyle:!0,jsx:cR,jsxs:iR,passKeys:!0,passNode:!0});function U($,L,z){if($.type==="raw"&&z&&typeof L==="number"){if(H)z.children.splice(L,1);else z.children[L]={type:"text",value:$.value};return L}if($.type==="element"){let B;for(B in f6)if(Object.hasOwn(f6,B)&&Object.hasOwn($.properties,B)){let M=$.properties[B],F=f6[B];if(F===null||F.includes($.tagName))$.properties[B]=K(String(M||""),B,$)}}if($.type==="element"){let B=X?!X.includes($.tagName):W?W.includes($.tagName):!1;if(!B&&Y&&typeof L==="number")B=!Y($,L,z);if(B&&z&&typeof L==="number"){if(Q&&$.children)z.children.splice(L,1,...$.children);else z.children.splice(L,1);return L}}}}function BK(Z){let J=Z.indexOf(":"),X=Z.indexOf("?"),Y=Z.indexOf("#"),G=Z.indexOf("/");if(J===-1||G!==-1&&J>G||X!==-1&&J>X||Y!==-1&&J>Y||aR.test(Z.slice(0,J)))return Z;return""}import eR from"rehype-highlight";import"highlight.js/styles/github.css";import{useEffect as ZI,useState as JI}from"react";import{jsxDEV as zK}from"react/jsx-dev-runtime";function XI({children:Z}){let[J,X]=JI(Z);return ZI(()=>{X(Z)},[Z]),zK("div",{className:"max-w-full first:mt-0",children:zK(gJ,{rehypePlugins:[eR],children:J},void 0,!1,void 0,this)},void 0,!1,void 0,this)}var MK=XI;import{jsxDEV as FK}from"react/jsx-dev-runtime";var YI=()=>FK("svg",{width:"30",height:"30",viewBox:"0 0 16 16",xmlns:"http://www.w3.org/2000/svg",children:FK("path",{d:"m 8 1 c -1.65625 0 -3 1.34375 -3 3 s 1.34375 3 3 3 s 3 -1.34375 3 -3 s -1.34375 -3 -3 -3 z m -1.5 7 c -2.492188 0 -4.5 2.007812 -4.5 4.5 v 0.5 c 0 1.109375 0.890625 2 2 2 h 8 c 1.109375 0 2 -0.890625 2 -2 v -0.5 c 0 -2.492188 -2.007812 -4.5 -4.5 -4.5 z m 0 0",fill:"#2e3436"},void 0,!1,void 0,this)},void 0,!1,void 0,this),NK=YI;import{jsxDEV as r8}from"react/jsx-dev-runtime";function GI({username:Z,avatar:J}){return r8("div",{className:"w-[30px]",children:r8("div",{className:"relative flex size-[30px] items-center justify-center rounded-sm p-1 text-white",children:J?r8("img",{src:J,className:"absolute inset-0 rounded",alt:Z},void 0,!1,void 0,this):r8(NK,{},void 0,!1,void 0,this)},void 0,!1,void 0,this)},void 0,!1,void 0,this)}var hJ=GI;import{jsxDEV as J0}from"react/jsx-dev-runtime";var QI=({message:Z,handleOptionClick:J,setUiAjaxConfiguration:X})=>{let[Y,G]=WI(!1);return HI(()=>{let W=setTimeout(()=>{if(Y)G(!1)},1000);return()=>clearTimeout(W)},[Y]),J0("div",{className:"group w-full border-b border-black/10",id:Z.id,children:J0("div",{className:`flex gap-4 p-4 text-base md:max-w-2xl md:gap-6 md:py-6 lg:max-w-3xl xl:max-w-5xl ${Z.align==="center"?"m-auto":""} ${Z.align==="right"?"ml-auto justify-end":""} ${Z.align==="left"?"mr-auto":""} `,children:[(Z.align==="left"||Z.align==="center")&&J0("div",{className:"relative flex shrink-0 flex-col items-end",children:J0(hJ,{username:Z.username,avatar:Z.avatar},void 0,!1,void 0,this)},void 0,!1,void 0,this),J0("div",{className:"relative flex w-[calc(100%-50px)] flex-col gap-1 md:gap-3 lg:w-[calc(100%-115px)]",children:[J0("div",{className:`markdown light prose w-full break-words dark:prose-invert first:mt-0 ${Z.align==="right"?"flex justify-end self-end":""}`,children:typeof Z.content==="string"?Z.parseMode.toLowerCase()==="markdown"?J0(MK,{children:Z.content},Date.now()+Math.random(),!1,void 0,this):Z.parseMode.toLowerCase()==="html"?L8(Z.content):Z.content:J0(C1,{uiConfig:Z.content,setUiAjaxConfiguration:X},void 0,!1,void 0,this)},void 0,!1,void 0,this),J0("div",{className:"flex flex-row flex-wrap justify-start gap-1",children:Z.options.map((W,H)=>J0(F8,{onClickOption:J,option:W},H,!1,void 0,this))},void 0,!1,void 0,this)]},void 0,!0,void 0,this),Z.align==="right"&&J0("div",{className:"relative flex shrink-0 flex-col items-end",children:J0(hJ,{username:Z.username,avatar:Z.avatar},void 0,!1,void 0,this)},void 0,!1,void 0,this)]},void 0,!0,void 0,this)},void 0,!1,void 0,this)},VK=QI;import{forwardRef as KI,useEffect as UI,useImperativeHandle as $I,useRef as LI,useState as BI}from"react";import{jsxDEV as AK}from"react/jsx-dev-runtime";var zI=KI(({name:Z,handleOptionClick:J,defaultMessages:X,sx:Y,setUiAjaxConfiguration:G},W)=>{let[H,Q]=BI(X),K=LI(null),U=()=>{if(K.current)K.current.scrollTop=K.current.scrollHeight};return UI(()=>{U()},[H]),$I(W,()=>({setMessages:($)=>Q($),addMessage:($)=>Q((L)=>[...L,$]),scrollToBottom:U})),AK("div",{id:Z+"_messages",className:"flex flex-col items-center overflow-y-scroll",style:Y,ref:K,children:H.map(($)=>AK(VK,{message:$,handleOptionClick:J,setUiAjaxConfiguration:G},$.id,!1,void 0,this))},void 0,!1,void 0,this)}),DK=zI;import{useEffect as MI,useMemo as FI,useRef as qK,useState as NI}from"react";import{jsxDEV as s8}from"react/jsx-dev-runtime";var VI=({data:Z,setUiAjaxConfiguration:J})=>{let{name:X,defaultValue:Y,defaultMessages:G,defaultOptions:W,isArea:H,fileAccept:Q,placeholder:K,icons:U,optionsPosition:$,sxMap:L={container:{},chatInput:{},messages:{}},depsNames:z,pathname:B,kwargs:M,useSocketioSupport:F,useCentrifugeSupport:D,centrifugeChannel:q}=Z,P=qK(null),O=qK(null),[w,E]=NI(!1),I=FI(()=>Y8(J,M,z,B),[J,M,z,B]);MI(()=>{if(w)requestAnimationFrame(()=>{I(),E(!1)})},[w]);let k=(C)=>{if(P.current)P.current.setValue(C),E(!0)},l=()=>{if(P.current)P.current.clear()},y=(C)=>{if(P.current)P.current.setOptions(C.options)},a=(C)=>{if(O.current)O.current.addMessage(C.message)},c=(C)=>{if(O.current)O.current.setMessages(C.messages)},p=()=>{E(!0)};return s8(K0,{card:"ChatCard",data:Z,methods:{clearInput:l,setOptions:y,addMessage:a,setMessages:c},useSocketioSupport:F,useCentrifugeSupport:D,centrifugeChannel:q,children:s8("div",{className:"flex size-full flex-col",style:L.container,children:[s8(DK,{ref:O,name:X,defaultMessages:G,sx:L.messages,handleOptionClick:k,setUiAjaxConfiguration:J},void 0,!1,void 0,this),s8(T2,{ref:P,name:X,isArea:H,defaultOptions:W,placeholder:K,defaultValue:Y,fileAccept:Q,sx:L.chatInput,handleSendMessage:p,handleOptionClick:k,optionsPosition:$,icons:U},void 0,!1,void 0,this)]},void 0,!0,void 0,this)},void 0,!1,void 0,this)},RK=VI;var vJ=!1;function AI(){if(vJ){if(h())console.log("[PieUI] Components already initialized");return}if(h())console.log("[PieUI] Initializing built-in components...");if(Z5({name:"SequenceCard",component:eW,metadata:{author:"PieData",description:"Simple div with styles joining few components"}}),Z5({name:"UnionCard",component:JH,metadata:{author:"PieData",description:"Renders one of many components"}}),Z5({name:"AjaxGroupCard",component:WH,metadata:{author:"PieData",description:"Group card with AJAX support"}}),Z5({name:"AjaxButtonCard",component:$2,metadata:{author:"PieData",description:"Button with AJAX support"}}),Z5({name:"ChatCard",component:RK,metadata:{author:"PieData"}}),vJ=!0,h())console.log("[PieUI] Built-in components initialized successfully")}function A5(){return vJ}import{jsxDEV as I0,Fragment as qI}from"react/jsx-dev-runtime";var DI=({uiConfig:Z,fallback:J})=>{if(!A5())throw Error("Pie components are not initialized. Use initializePieComponents() at the top of page file");return I0(H0,{client:q0,children:I0(s1.Provider,{value:_0,children:I0(o1.Provider,{value:m0(),children:I0(t1.Provider,{value:u0(),children:I0(n1.Provider,{value:J??I0(qI,{},void 0,!1,void 0,this),children:I0(p0,{children:I0(l0,{children:I0(V0,{children:I0(C1,{uiConfig:Z},void 0,!1,void 0,this)},void 0,!1,void 0,this)},void 0,!1,void 0,this)},void 0,!1,void 0,this)},void 0,!1,void 0,this)},void 0,!1,void 0,this)},void 0,!1,void 0,this)},void 0,!1,void 0,this)},void 0,!1,void 0,this)},RI=DI;import{useMemo as BT}from"react";var fU=r(XX(),1);import{jsxDEV as X0,Fragment as FT}from"react/jsx-dev-runtime";var zT=({location:Z,fallback:J,onError:X})=>{let Y=BT(()=>fU.createAxiosDateTransformer({baseURL:T1()}),[]);if(h())console.log("[PieRoot] Rendering with location:",Z),console.log("[PieRoot] API_SERVER:",T1()),console.log("[PieRoot] Fallback provided:",!!J);if(!T1())throw Error("Set PIE_API_SERVER and PIE_CENTRIFUGE_SERVER");if(!A5())throw Error("Pie components are not initialized. Use initializePieComponents() at the top of page file");let{data:G,isLoading:W,error:H}=K6({queryKey:["uiConfig",Z.pathname+Z.search],queryFn:async()=>{let Q="/api/content"+Z.pathname+Z.search;if(h())console.log("[PieRoot] Fetching UI configuration from:",Q);let K=await Y.get(Q,{headers:{"Access-Control-Allow-Origin":"*","Access-Control-Allow-Methods":"GET,PUT,POST,DELETE,PATCH,OPTIONS","Content-type":"application/json"},withCredentials:!0});if(h())console.log("[PieRoot] Received UI configuration:",K.data);return K.data},staleTime:1/0,gcTime:1/0,refetchOnWindowFocus:!1,refetchOnMount:!1,refetchOnReconnect:!1,retry:!0,retryDelay:(Q)=>Math.min(1000*2**Q,30000)});if(H){if(h())console.error("[PieRoot] Error fetching UI configuration:",H),console.error("[PieRoot] Error details:",{message:H.message,status:H.response?.status,data:H.response?.data});return X?.(),J}if(W||!G){if(h())console.log("[PieRoot] Loading state:",{isLoading:W,hasUiConfiguration:!!G});return J}if(h())console.log("[PieRoot] UI configuration loaded successfully:",G),console.log("[PieRoot] Rendering UI with configuration");return X0(H0,{client:q0,children:X0(s1.Provider,{value:_0,children:X0(o1.Provider,{value:m0(),children:X0(t1.Provider,{value:u0(),children:X0(n1.Provider,{value:J??X0(FT,{},void 0,!1,void 0,this),children:X0(p0,{children:X0(l0,{children:X0(V0,{children:X0(C1,{uiConfig:G},void 0,!1,void 0,this)},void 0,!1,void 0,this)},void 0,!1,void 0,this)},void 0,!1,void 0,this)},void 0,!1,void 0,this)},void 0,!1,void 0,this)},void 0,!1,void 0,this)},void 0,!1,void 0,this)},void 0,!1,void 0,this)},MT=(Z)=>X0(H0,{client:q0,children:X0(zT,{...Z},void 0,!1,void 0,this)},void 0,!1,void 0,this),NT=MT;import{useMemo as AT}from"react";var pU=r(XX(),1);import{useEffect as VT}from"react";var uU=()=>{return VT(()=>{if(window.Telegram.WebApp.ready(),VX()==="telegram_expanded"&&(window.Telegram.WebApp.platform==="ios"||window.Telegram.WebApp.platform==="android"))window.Telegram.WebApp.expand()}),window.Telegram.WebApp};import{jsxDEV as Y0,Fragment as RT}from"react/jsx-dev-runtime";var DT=({location:Z,fallback:J,onError:X})=>{let Y=AT(()=>pU.createAxiosDateTransformer({baseURL:T1()}),[]);if(h())console.log("[PieRoot] Rendering with location:",Z),console.log("[PieRoot] API_SERVER:",T1()),console.log("[PieRoot] Fallback provided:",!!J);if(!T1())throw Error("Set PIE_API_SERVER and PIE_CENTRIFUGE_SERVER");if(!A5())throw Error("Pie components are not initialized. Use initializePieComponents() at the top of page file");let G=uU(),{data:W,isLoading:H,error:Q}=K6({queryKey:["uiConfig",Z.pathname+Z.search,G?.initData],queryFn:async()=>{let K=Z.search?"&":"?",U=G?.initData?`${K}initData=${encodeURIComponent(G.initData)}`:"",$="/api/content"+Z.pathname+Z.search+U;if(h())console.log("[PieRoot] Fetching UI configuration from:",$);let L=await Y.get($,{headers:{"Access-Control-Allow-Origin":"*","Access-Control-Allow-Methods":"GET,PUT,POST,DELETE,PATCH,OPTIONS","Content-type":"application/json"},withCredentials:!0});if(h())console.log("[PieRoot] Received UI configuration:",L.data);return L.data},staleTime:1/0,gcTime:1/0,refetchOnWindowFocus:!1,refetchOnMount:!1,refetchOnReconnect:!1,retry:!0,retryDelay:(K)=>Math.min(1000*2**K,30000)});if(Q){if(h())console.error("[PieRoot] Error fetching UI configuration:",Q),console.error("[PieRoot] Error details:",{message:Q.message,status:Q.response?.status,data:Q.response?.data});return X?.(),J}if(H||!W){if(h())console.log("[PieRoot] Loading state:",{isLoading:H,hasUiConfiguration:!!W});return J}if(h())console.log("[PieRoot] UI configuration loaded successfully:",W),console.log("[PieRoot] Rendering UI with configuration");return Y0(H0,{client:q0,children:Y0(s1.Provider,{value:_0,children:Y0(o1.Provider,{value:m0(),children:Y0(t1.Provider,{value:u0(),children:Y0(n1.Provider,{value:J??Y0(RT,{},void 0,!1,void 0,this),children:Y0(p0,{children:Y0(l0,{children:Y0(V0,{children:Y0(C1,{uiConfig:W},void 0,!1,void 0,this)},void 0,!1,void 0,this)},void 0,!1,void 0,this)},void 0,!1,void 0,this)},void 0,!1,void 0,this)},void 0,!1,void 0,this)},void 0,!1,void 0,this)},void 0,!1,void 0,this)},void 0,!1,void 0,this)},qT=(Z)=>Y0(H0,{client:q0,children:Y0(DT,{...Z},void 0,!1,void 0,this)},void 0,!1,void 0,this),IT=qT;export{Z5 as registerPieComponent,A5 as isPieComponentsInitialized,AI as initializePieComponents,C1 as UI,IT as PieTelegramRoot,RI as PieStaticRoot,NT as PieRoot,K0 as PieCard,pN as PieBaseRoot};
|